@yuneta/gobj-ui 7.32.5 → 7.32.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3249,6 +3249,10 @@ A row of that topic with `"icon": "yi-u-transformer"` shows that drawing.
3249
3249
  - **The drawing is a MASK**, like the library's: painted with `currentColor`,
3250
3250
  one colour, the shapes' alpha only. A multicolour svg comes out as a
3251
3251
  silhouette.
3252
+ - **It is 1em tall, like every icon.** A drawing that is wider than tall gets
3253
+ a wider box, from its viewBox (`svg_icon_width()`), up to 1.25em
3254
+ (`USER_ICON_MAX_WIDTH`, the widest icon of the library). A wider drawing
3255
+ is drawn smaller, so that it does not push the controls of its row aside.
3252
3256
  - **The svg is rebuilt, never inserted.** `yui_svg_sanitize()` parses it and
3253
3257
  writes a new one from the shapes alone (`path`, `circle`, `rect`, `ellipse`,
3254
3258
  `line`, `polyline`, `polygon`, `g`) and their geometric and stroke
@@ -4495,6 +4499,23 @@ text is in the yunetas `CLAUDE.md` ("JS GUI conventions"); in short:
4495
4499
  - **One icon shape per meaning** (chevron = open/close one thing, shafted
4496
4500
  arrow = step or back, tree box = one level, double chevron = all). Never
4497
4501
  reuse a glyph because it is there.
4502
+ - **Every icon is 1em tall** (`yui_icons.css`, 7.32.6+). The box of an icon
4503
+ is 1em wide. A glyph that is wider than tall gets a wider box, its viewBox
4504
+ width over its height: `yi-file-csv` (576 x 512) is 1.125em wide, and
4505
+ `yi-code` (640 x 512) is 1.25em. A new icon that is wider than tall goes
4506
+ into the list of its width, and `yui_icons.test.js` names an icon that is
4507
+ missing from it:
4508
+
4509
+ ```css
4510
+ .yi-file-csv::before,
4511
+ .yi-sitemap::before {
4512
+ width: 1.125em;
4513
+ }
4514
+ ```
4515
+
4516
+ A Bulma `.icon` grows to hold a wide glyph. Up to 7.32.5 every box was a
4517
+ 1em square, and a wide glyph was drawn smaller to fit: in one row of tool
4518
+ buttons, `yi-code` was 80% of the height of the others.
4498
4519
  - **Bulma helpers carry `!important`** (`.is-hidden`, `.is-flex`): toggle
4499
4520
  `is-hidden`, or use `style.setProperty('display', 'none', 'important')`.
4500
4521
  - **Data goes into the DOM as text, never as a string.** `createElement2()`
@@ -4587,7 +4608,7 @@ the tables of `gui_treedb` and `gui_agent`. Other tables can obey it too.
4587
4608
  a control has none, for example the action buttons or the selection
4588
4609
  checkbox.
4589
4610
  2. The footer shows the paginator at all times, also when all the rows fit
4590
- in one page.
4611
+ in one page. On a phone the paginator takes one line (see below).
4591
4612
  3. The table holds all its rows in the browser and pages them there. This
4592
4613
  is local pagination.
4593
4614
  4. Each toolbar above the table takes one row. When the row does not fit,
@@ -4620,10 +4641,31 @@ since 7.32.4. Up to 7.32.0 it hid the paginator when all the rows fit, and
4620
4641
  its toolbar wrapped into two rows on a phone. Up to 7.32.3 the columns of a
4621
4642
  document, a hook, a file and a time had no filter.
4622
4643
 
4644
+ The paginator on a phone takes one line, from `tabulator.css` (7.32.6+),
4645
+ for every table of an app that imports it. At the mobile width of Bulma
4646
+ (768 px and less):
4647
+
4648
+ - First, Prev, Next and Last show the icons of the period navigator
4649
+ (`C_YUI_PERIOD`): `yi-backward-step`, `yi-chevron-left`,
4650
+ `yi-chevron-right` and `yi-forward-step`. Each button keeps its name in
4651
+ the table's language: Tabulator writes "First Page" and the others as
4652
+ `title` and `aria-label`.
4653
+ - The label "Rows per page" is hidden. The select keeps the same text as its
4654
+ `title` and `aria-label`.
4655
+ - Of the numbered pages, only the current one shows. The steps and the ends
4656
+ reach the others.
4657
+ - Each icon is `YUI_TOOLBAR_ICON_SIZE` (1.25rem), the size of the icons of
4658
+ the toolbar above the table, in a 2rem button.
4659
+
4660
+ Up to 7.32.5 the words took three lines of the footer on a 390 px phone.
4661
+ `tabulator.css` takes the masks from `yui_icons.css` as custom properties
4662
+ (`--yi-backward-step` and the others), so the app must import it. Every app
4663
+ of the ecosystem does.
4664
+
4623
4665
  How to make sure that a table obeys it: open the DEPLOYED page at 390 px.
4624
4666
  Each control of the toolbar is on one line, the paginator
4625
- (`.tabulator-paginator`) has a width with one page of rows, and each column
4626
- of data has a filter box.
4667
+ (`.tabulator-paginator`) has a width with one page of rows and is one line,
4668
+ and each column of data has a filter box.
4627
4669
 
4628
4670
  Why each point:
4629
4671