question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Column width problem

See original GitHub issue

Hi folks, first of all, thanks for this awesome component, but we have a little problem with it.

If we add items to template.projection ({column}) and react rerender the table everything looks fine.

But if we remove items of template.projection, the width of deleted column is splitting to each remaining column and ignore the width information on other TableHeaderColumn.

 <BootstrapTable height="250" data={data} striped={true} hover={true} condensed={true}>
    <TableHeaderColumn dataField="articleNumber" width="60" dataFormat={this.excludedFormatter}>       
        {labels.new_action}</TableHeaderColumn>
    <TableHeaderColumn dataField="articleNumber" width="115" isKey={true}
        filter={{type: "TextFilter", placeholder: labels.new_articleNumber}}/>
    <TableHeaderColumn dataField="description"
        filter={{type: "TextFilter", placeholder: labels.new_description}}/>
    {column}
</BootstrapTable>

column =

        let column = filter.concat(template.projection).map(headline => {
            return (
                <TableHeaderColumn dataField={headline} width="80">{headline}</TableHeaderColumn>
            );
        });

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

4reactions
AllenFangcommented, Jan 22, 2017

hi there, sorry for lately fixing, check react-bootstrap-table@2.10.0-beta.1 by npm install react-bootstrap-table@2.10.0-beta.1 and I thought this beta release already fixed couples unalign problem, if it work and stability, I’ll consider to forward to production as soon as possible.

Let me know if the problems still there. thanks

0reactions
AllenFangcommented, Sep 10, 2016

@markortiz, thanks, I’ll try it out, sorry for lately fixing, busy on work 😭

Read more comments on GitHub >

github_iconTop Results From Across the Web

column-width - CSS: Cascading Style Sheets - MDN Web Docs
If the width of the container is narrower than the specified value, the single column's width will be smaller than the declared column...
Read more >
The column width is not the same when printed in Excel
Depending on the fonts you use, column widths and row heights may appear differently when you print or view a worksheet in print...
Read more >
How to fix the width of columns in the table ? - GeeksforGeeks
The width of the columns i.e. td in a table can be fixed very easily. This can be done by adding the width...
Read more >
Column width won't adjust - Google Groups
1. Disable auto resizing (Options... on the Table tab). · 2. Disable any exact width for the entire table. · 3. Clear any...
Read more >
Column Width % Error - WordPress.org
[This thread is closed.] Hi, I am trying to create a page layout using the “Column Width (%)” setting. I have 6 columns...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found