On a phone, magpie web's pages sat in a strip under the header that
scrolled sideways, with nothing to show that more pages lay past its
edge. Agents, Library and the rest looked missing. The pages are now a
tab bar at the foot, as an iPhone app's (HIG): each tab its mark over its
word, the page open marked. Five tabs at most: with more pages than
that, the fifth is More, and its menu lists the rest with their marks
and a tick on the open one. More is marked while one of them is open,
and it carries the dot when one of them has one. phonetabs.js does
this. app.js loads it lazily only on a phone, so the core script
doesn't grow. A status line comes up over the bar. The bar is only for
the window, never the tray panel (body.panel).
Agents still isn't shown in gateway mode on a machine with no agents,
as designed (Settings > General > Gateway mode brings it back). Library
has been shown in gateway mode since f285426ac.
Tests: phone-tabs.test.cjs (new) runs at 390x844 in chromium and webkit,
in en, zh, zh-TW, ja and de, with gateway mode on and off. It checks:
- five tabs with More fifth, at the foot, 44px tall;
- nothing scrolls sideways;
- every page is reached from the bar or from More, and More's menu opens
above the bar;
- the bar covers no page content and no status line;
- a desktop browser has no More.
reader.cjs gets openPage() (the tab, or More's menu). mobile-web,
phone-no-sideways, routing-held-dot and name-suffix-saved open pages
through it. phone-web checks the bar at the foot. old-webkit lists
phonetabs.js as lazy. market-more waits for the view's own foot, not the
window's, which is now above the bar. group-from-model-add wheels Add
wholly into the view before its press, because at 600x420 WebKit took a
press on Add's half-hidden middle as one on the header.
Run on mote:
- The whole GUI suite once (450 files, concurrency 3). 33 red files
were then run on this change's base and on the branch. The reds only
on the branch were the four tests that tapped tabs now under More,
phone-web's old label check, market-more, group-from-model-add (webkit
600x420), and the panel tests agent-menu-label, zcode-models and
panel-fit-tabs (webkit). The panel tests are web:true at 360-380px, so
the bar's padding reached the panel. It is now scoped :not(.panel).
- After the fixes: phone-web, market-more, group-from-model-add,
agent-menu-label, zcode-models, panel-fit-tabs, phone-tabs,
mobile-web, phone-no-sideways, routing-held-dot, name-suffix-saved,
old-webkit and i18n-keys. All are green except reds already filed on
main: #5919 (old-webkit :has), #5869 (phone-no-sideways de 375) and
#5215 (tray-cell-click, a web:false panel test). mobile-web's 900/1280
desktop screenshots need git, so they were run with BASE_REF set to a
commit of the base's assets: 30/30 pass in both engines, so the
desktop is unchanged.
- gofmt, go vet for darwin, linux (nogui) and windows, and go test
./internal/gui.
- Again at the pushed head, rebased on origin/main ca7a39291: the 13
GUI files above (239 pass; reds only #5919, #5869 and mobile-web's
git-less desktop compare), gofmt, vet on all three, and go test
./internal/gui ok. TestCoreScriptBudget was over at the old base
662546e78 and passes here: app.js is ~430 bytes smaller.
- Rebased again on 388ca9ad4 (two agent commits touching app.js and
i18n.js): the budget tests, i18n-keys, phone-tabs and phone-web
pass (34 of 34). Then onto 0baa223ec (Kun; a one-line app.js change)
with no further run before the push.
Broken by hand:
- Without layoutNav's import of phonetabs.js, phone-tabs is 20 of 24 red.
- Without :not(.panel), panel-fit-tabs (webkit, 5 languages) and
agent-menu-label go red.
Not tried: a real iPhone's Safari, or the LAN share opened on a real
phone.