Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overflowing pane container #6757

Open
1 task
droumis opened this issue Apr 18, 2024 · 3 comments
Open
1 task

Overflowing pane container #6757

droumis opened this issue Apr 18, 2024 · 3 comments
Milestone

Comments

@droumis
Copy link
Member

droumis commented Apr 18, 2024

ALL software version info

panel 1.4.1

Description of expected behavior and the observed behavior

While trying to get a tabulator table to fit within widgetbox in a sidebar. I found that the table overflows the pane container. This is not specific to sidebar.

Complete, minimal, self-contained example code that reproduces the issue

import pandas as pd
import numpy as np
import panel as pn; pn.extension('tabulator')

vals = np.arange(100)
df = pd.DataFrame({f'column{l}':vals for l in np.arange(5)})

widget = pn.WidgetBox(
    pn.pane.Alert('Tabulator overflows pane container', alert_type='warning'),
    pn.widgets.Tabulator(df,
                         layout='fit_data_fill',
                         pagination='local',
                         page_size=10,
                        ),
    pn.pane.Alert('Tabulator overflows pane container', alert_type='warning'),
)

template = pn.template.FastGridTemplate(
    sidebar=[widget],
    main=[widget],
)
template.servable();

Stack traceback and/or browser JavaScript console output

Screenshots or screencasts of the bug in action

image

  • I may be interested in making a pull request to address this
@droumis droumis added the TRIAGE Default label for untriaged issues label Apr 18, 2024
@droumis droumis changed the title Tabulator overflows pane container Overflowing pane container Apr 18, 2024
@droumis
Copy link
Member Author

droumis commented Apr 18, 2024

Same with Accordion

image

@droumis
Copy link
Member Author

droumis commented Apr 18, 2024

image

@philippjfr philippjfr added type: bug and removed TRIAGE Default label for untriaged issues labels May 14, 2024
@philippjfr philippjfr added this to the v1.4.3 milestone May 14, 2024
@philippjfr philippjfr modified the milestones: v1.4.3, v1.4.4 May 30, 2024
@philippjfr philippjfr modified the milestones: v1.4.4, v1.4.x Jun 7, 2024
@ahuang11
Copy link
Contributor

ahuang11 commented Sep 10, 2024

To get around this, I think you can set sizing_mode="stretch_width" on Tabulator

image

Tried manually adding width: calc(100% - 20px) and it seems to work too.
image

@philippjfr philippjfr modified the milestones: v1.5.x, v1.6.0 Jan 20, 2025
@philippjfr philippjfr modified the milestones: v1.6.0, v1.6.1 Jan 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants