Page motion
Going in and coming back: a page grows over the last, and a swipe from the edge takes it away.
Desktop
arkui::swipe · arkui::history
On the desktop, two fingers sideways over the page go back and forward (arkui::swipe). In a browser the browser's own back does it.
arkui::swipe
Two fingers sideways as back and forward, with the arrow drawn over the page as they go.
Swipe::feed, tick, allow, active, offset, arrowband(…)view(page, swipe, now)FAR, LET_GO, QUIET, BACK, STRETCH
Rules
- It goes when the fingers lift, and only where there is somewhere to go.
- In a browser the browser's own back does this instead.
arkui::history
Back and forward every way an app is asked: the browser's buttons, ^O and ^I, and two fingers sideways. The router and the swipe, wired once.
History::new(), go(by), can_go(by), wheel(delta, now), tick(now), active(), sync(&place), replace_next(), poll(ready), view(page, now)scrolled(&place, y), arrive(&place) -> y: back and forward land where a page was leftwheel() -> Subscription<ScrollDelta>
Rules
- A jump and a swipe both move the bar; the app arrives by its next poll, the road the back button takes.
- The arrow shows only where there is somewhere to go.
Mobile
Where
ui/Motion.kt: PageFrame, Moving, PageBack, Hero
How
- PageBack(motion, blocked, toFirst): the edge swipe, following the finger.
- Hero carries a picture from the card to the page's header.
Nothing shared for this on iOS yet.