Comments (4)
Brilliant. Thanks for the help. :-)
from basictable.
@Vertigrator are the widths set inline or via CSS? If it's set with CSS you could override with your own CSS (which could work with inline too with !important
. Alternatively I could add some events so users can create their own callback to do this.
from basictable.
The widths were inline, added by SharePoint automatically. So what I did was use javascript to remove all the width attributes after the page loads. I hate rich text editors that try to be smart by adding things like this that we don't want.
// Remove all the width attributes that SharePoint adds to tables $(document).ready(function ($) { $('.epa .main-content table th, .epa .main-content table td').each(function () { $(this).removeAttr("width"); }); });
from basictable.
Ah I see, yes if you have no control over that - unfortunately. BTW based on your sample from the other issue it looks like the widths are set in the style attribute rather than the width attribute. You also don't have to do a .each
for jQuery as it'll apply to all instances (not vanilla js though) so you could just do:
$('.epa .main-content table th, .epa .main-content table td').css('width', '');
from basictable.
Related Issues (18)
- Table gets stuck when resizing
- Adding rowspan attribute in <td> table heading not work correctly in mobile
- Table not getting back to normal mode after responsive change HOT 1
- Issue with AJAX HOT 1
- Demo page - tableWrapper should be corrected to tableWrap HOT 1
- feature_request(dependencies): vanilla JavaScript or Cash instead of JQuery HOT 3
- First column header throws error HOT 3
- Multiple span.bt-content inside td HOT 3
- how can i use other titles for footer in table?
- Add thead > td support HOT 1
- feature_request(thead): support tables without thead HOT 1
- feature_request(breakpoints): orientation breakpoint HOT 1
- `forceResponsive: false` always switches to stacked immediately HOT 2
- Move no necessary dependencies to devDependencies HOT 2
- Multiple tables HOT 2
- problem with datatable. HOT 1
- Issue with dynamic table HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from basictable.