summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/playlists.md19
1 files changed, 17 insertions, 2 deletions
diff --git a/docs/playlists.md b/docs/playlists.md
index c450815..badbc99 100644
--- a/docs/playlists.md
+++ b/docs/playlists.md
@@ -819,8 +819,23 @@ The codebase has no context menu and no dropdown outside the account menu in
instant it was wheeled or its scrollbar dragged, and no track below the fold
could be reached. Measured by `menu_scroll_probe.py`; `playlist_ui_probe.py`
cannot see it, because `.click()` scrolls nothing.
-- flips its anchor when it would open past the viewport edge, which on a phone
- is most of the time.
+- **measures where it can go, and is given exactly that much room.** It opens at
+ the pointer when the list fits below it, flips above when it does not and there
+ is more room there, and in either case its `max-height` is the distance from
+ where it was just placed to the bottom of the window. The stylesheet's
+ `max-height: calc(100vh - 16px)` is only a floor: it says how *tall* the panel
+ may be and nothing about where its *bottom* lands, so a panel opened 300 px
+ down the window ran 300 px past the bottom of it. It scrolled — and its last
+ rows scrolled into a part of itself that is off the screen, which no further
+ scrolling brings back. That was the "the last track cannot be reached" report,
+ and it is the second of two defects with that one symptom; the first, above,
+ hid it. Both are measured by `menu_scroll_probe.py`.
+- **re-measures when a submenu opens.** The height changes inside `MenuItems`'
+ own state, and `loadItems` arrives later still, so `MenuItems` reports upward
+ rather than `Menu` watching for it: a `ResizeObserver` on the panel would be an
+ observer on the very box the callback resizes, and the browser breaks that loop
+ by raising an error. Without the report a two-row menu opened low keeps the
+ 192 px it was measured for and threads sixty tracks through that porthole.
- submenus **expand in place**, downward, at every width. This is the
correction: the proposal wanted a flyout with a sheet on a coarse pointer, and
the account menu's language list (`app.js`) already shows the simpler answer.