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

[BUG] dbc.Modal(style) is passed to fade-modal-show layer instead modal #2838

Closed
luggie opened this issue Apr 23, 2024 · 1 comment
Closed

Comments

@luggie
Copy link

luggie commented Apr 23, 2024

dash                      2.16.1
dash_ag_grid              31.0.1
dash-bootstrap-components 1.6.0
dash-bootstrap-templates  1.1.2
dash-core-components      2.0.0
dash-html-components      2.0.0
dash-split                0.0.4
dash-table                5.0.0
dash-testing-stub         0.0.2

Expected behavior in test app:
Modal should appear according to style parameters.

from dash import Dash, html
import dash_bootstrap_components as dbc

app = Dash(__name__, external_stylesheets=[dbc.themes.BOOTSTRAP])

app.layout = html.Div([
    dbc.Modal(
        [
            dbc.ModalHeader("Header"),
            dbc.ModalBody("This is the content of the modal"),
            dbc.ModalFooter(
                dbc.Button("Close", id="close", className="ml-auto")
            ),
        ],
        id="modal",
        is_open=True,
        style={
            "position": "absolute",
            "top": "10px",
            "left": "10px",
        }
    )
])


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

Instead, the style parameters are passed to the fade-modal-show layer:

Screenshot from 2024-04-23 10-36-29

Is this intended? If so, why?

@T4rk1n
Copy link
Contributor

T4rk1n commented Apr 23, 2024

I don't think this is a bug with dash, try reporting on https://github.com/facultyai/dash-bootstrap-components

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