Commit dca2bea
committed
fix: the More menu was clipped out of existence
The strip carried `overflow: hidden` as a safety net for the frame before
the tabs are measured. The dropdowns are absolutely positioned inside that
box and hang below the row, so the clip removed them — the More button did
nothing when clicked, and every other tab's menu was gone with it.
It now clips only while measuring, when a full set of tabs is deliberately
on screen to be sized. Once the widths are known nothing renders past the
edge anyway, because the tabs that do not fit are not in the DOM.
Worth recording how this got through: the earlier check read
getBoundingClientRect() on the panel and found a sensible box on screen.
A clipped element still reports its layout box, so that proves nothing
about whether anyone can see it. The check now asks whether the panel is
hit-testable — elementFromPoint at its own centre has to land inside it —
and walks its ancestors for anything still clipping.
Verified: no clipping ancestor, elementFromPoint at the panel centre
returns a link inside it, five sections listed. Tabs stay clear of the
search box and the strip never overflows at 1400, 1150 or 950px. All 14
tests pass.1 parent 56592b9 commit dca2bea
3 files changed
Lines changed: 20 additions & 3 deletions
File tree
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
43 | 48 | | |
44 | 49 | | |
45 | 50 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
66 | 65 | | |
67 | 66 | | |
68 | | - | |
69 | 67 | | |
70 | 68 | | |
71 | 69 | | |
| |||
234 | 232 | | |
235 | 233 | | |
236 | 234 | | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
237 | 242 | | |
238 | 243 | | |
239 | 244 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
118 | 125 | | |
119 | 126 | | |
120 | 127 | | |
| |||
0 commit comments