Quantcast
Channel: 🎛️ Dash - Plotly Community Forum
Viewing all articles
Browse latest Browse all 6271

Dash DataTable Multiline Overflow

$
0
0

Hi!

I’m trying to handle overflow in a DataTable by breaking the contents into multiple lines. The latest code snippet I was able to find is the following:

dash_table.DataTable(
            style_table={'width': '100%'},
            style_data={'whiteSpace': 'normal'},
            content_style='grow',
            css=[{
                'selector': '.dash-cell div.dash-cell-value',
                'rule': 'display: inline; white-space: inherit; overflow: inherit; text-overflow: inherit;'
            }],
            data=df_election.to_dict('rows'),
            columns=[{'id': c, 'name': c} for c in df_election.columns]
        ),

When I try to use the same, I get the following error:

TypeError: The dash_table.DataTable component (version 4.6.0) received an unexpected keyword argument: content_style

Without the content_style line overflow is not handled at all.

I’d appreciate any help with this. Thanks in advance!

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 6271

Trending Articles