Let the page buttons make way: a Page buttons setting that gives their room to the tiles, chevrons and dots instead of words, and a warning in the editor for pages nothing leads to (0.2.82)
GitHub issue #9 asked to drop the Previous/Next bar when Go to page tiles do the navigation and to give the tiles the whole screen. Page buttons is a setting the screen owns (on by default): a row in the Screen group of the settings page, switch.<screen>_page_buttons in Home Assistant, and a row in the editor's Screen settings. Without the bar, and on a screen with one page, place_page moves and sizes the three rows so they reach the bottom margin (Guition 108 -> 122 px, CYD 52 -> 61 px); a card keeps its circle, name and state in its middle and the single analog clock keeps its dial. With page buttons and swiping both off, the editor says where the Go to page tiles lead and which pages that leaves out of reach. The bar itself: each half of the band under the tiles is one key with an MDI chevron and lights up under a finger, and a dot per page sits between them; the screen's settings page uses the same pager. App 0.2.82, firmware 0.2.69. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -215,6 +215,29 @@ icons sit off-center in the browser); run `generate_packages.py` afterward.
|
||||
The `MDI_GLYPH_*` substitutions are retired: `TILEn_ICON` in manual
|
||||
profiles must come from the set. No changed preferences or keys.
|
||||
|
||||
### Compatibility 0.2.82 / firmware 0.2.69
|
||||
|
||||
Page buttons (GitHub issue #9): a setting the screen owns, `page_buttons`, on by default. It has a preference record
|
||||
of its own (`0x50474231`), the switch "Page buttons" in both profiles, and `SETTING_RULES`, `SETTING_ENTITIES` and
|
||||
`SETTINGS_BESIDE_BLOCK` entries in the app. Like Dark mode it never travels in the layout message, and a screen
|
||||
without the entity shows no row for it.
|
||||
|
||||
- Firmware: `place_page` places the three rows itself (`runtime_tiles::rows`). With the bar on screen (more than one
|
||||
page and `page_buttons` on) they keep the profile's places (`Widgets::base_y`, `base_height`). Without it they share
|
||||
the room down to the bottom edge, keeping the side margin: Guition 108 → 122 px, CYD 52 → 61 px. `tile_scroll`
|
||||
grows with them. A large card keeps its profile places for the circle, name and state, lowered by half the growth;
|
||||
the single analog clock keeps the profile's dial. `page_buttons_changed()` (called from `apply_screen_settings`)
|
||||
places the page again when the bar comes or goes. `check_tile_geometry` checks that every card lies inside the tile
|
||||
area, clear of the bar and within the bottom margin.
|
||||
- Page bar: `page_prev` and `page_next` are the two halves of the band under the tiles, running from
|
||||
`SCROLL_Y + SCROLL_H` to the bottom (Guition 240×60, CYD 160×36). Each holds a chevron in `materialdesign_icons_mini`
|
||||
(F0141/F0142). `page_number` is a non-clickable `obj` that holds the dots (`settings_screen::page_dots`), so LVGL's
|
||||
hit test gives every point of the band to one of the halves. The settings page's pager uses the same chevrons and
|
||||
dots, with a dimmed chevron where it leads nowhere.
|
||||
- Editor: `strandedPages()` (`model/layout.ts`) and `pageReachWarning()` (`store.ts`) warn when page buttons and
|
||||
swiping are both off and the Go to page tiles leave a page out of reach, or give it no way back to page 1. The
|
||||
warning shows above the pages and under the Screen card.
|
||||
|
||||
### Compatibility 0.2.78 / firmware 0.2.65
|
||||
|
||||
Repeated navigation tiles: the same `screen.page_<n>` may sit on several pages of one screen. Firmware 0.2.65 accepts
|
||||
|
||||
Reference in New Issue
Block a user