Skip to content

Widgets overlap #5459

Closed Answered by TomJGooding
AndyDralle asked this question in Q&A
Jan 7, 2025 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

The problem is that the Input widget default CSS has width: 100%, whereas in this layout instead we want the available width.

You can add something like this to your app class if you don't want a separate CSS file:

    CSS = """
    Input { width: 1fr; }
    """

https://textual.textualize.io/guide/styles/#fr-units

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@AndyDralle
Comment options

Answer selected by AndyDralle
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants