Commit 659f40a
committed
Tweak the styling to make the sidebar less greedy
By the looks of things, with #77, the issue is that there is a Vertical that
is width auto, which contains a Tree that is width auto, and a label that is
width 100%. The intention seems to be that the sidebar should be as wide as
the tree is, and the tree should be as wide as its content needs; meanwhile
the label should be the full width of its container.
At some point recently it seems the balance in this setup has changed and
the 100% label is making its auto-width container extra greedy.
Given that there's no simple way of saying "be 100% of my parent but don't
put pressure on its width calculation if it's width auto" this commit
changes things so that the label itself is also width auto, and tries to
ensure that the background looks like it did before.
The fundamental fix for this probably needs to be in Textual's layout code,
but this will fix Trogon itself in the meanwhile.
Fixes #77.1 parent a2d8874 commit 659f40a
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
49 | | - | |
| 48 | + | |
50 | 49 | | |
51 | 50 | | |
52 | 51 | | |
53 | 52 | | |
54 | 53 | | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
0 commit comments