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.

Header row overlaps Dropdown when fixed_rows is set

See original GitHub issue

Hi all,

Here’s a minimal example:

import dash
import dash_core_components as dcc
import dash_html_components as html
import dash_table

app = dash.Dash(__name__, eager_loading=True)

app.layout = html.Div([
    # Note that "one" isn't visible because the table header overlaps it
    dcc.Dropdown(id='dropdown', options=[{'label': c, 'value': c} for c in ['one', 'two', 'three']]),

    dash_table.DataTable(
        id='table',
        fixed_rows=dict(headers=True, data=0),
        columns=[{'name': c, 'id': c} for c in ['A', 'B']],
        data=[
            {'A': 'aa', 'B': 'bb'},
        ],
    ),
])

if __name__ == '__main__':
    app.run_server(debug=True)

When opening the dropdown I see the following:

bug

I.e., the table header overlaps the Dropdown, which is clearly wrong.

Here’s the output of conda list dash - I’m pretty much on the lastest versions:

dash                      1.9.1
dash-core-components      1.8.1
dash-dangerously-set-inner-html 0.0.2
dash-html-components      1.0.2
dash-renderer             1.2.4
dash-table                4.6.1
dash_utils                0.19

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:1
  • Comments:5

github_iconTop GitHub Comments

1reaction
swt2ccommented, Dec 18, 2020

I’m seeing something similar, but with a DatePickerRange and a DataTable with fixed headers. When opening the DatePicker, the DataTable’s header is on top of the DatePicker.

0reactions
RedwoodDowlingkerrcommented, Nov 1, 2021

@swt2c Hi, I just found a solution from another thread. add the following to datepickerrange style.

style={‘position’: ‘relative’, ‘zIndex’: ‘999’}

Read more comments on GitHub >

github_iconTop Results From Across the Web

Datatable header overlaps on dropdown list - Dash Python
This happens because with fixed rows the header must be absolutely positioned and is given a z-index to behave visually correctly in respect...
Read more >
Why does my section and header overlap? How would I fix this?
The top left should have a navigation bar with a dropdown menu, and I'm trying to put a showcase under that which covers...
Read more >
Why does my header overlap other elements when i mark its ...
I want my header to stay fixed on top. Without the position:fixed my code works as expected (where the header stays on top...
Read more >
Overlapping Rows in Elementor - YouTube
In the previous video, I talked about overlapping columns and I just thought that there should be a sequel because it's all about...
Read more >
How to Overlap Modules and Rows to Create Unique Layouts ...
Method 1: Overlapping Modules with Modules. Overlapping a module with another module is extremely simple to do. Here is an example of how...
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