@yuneta/gobj-ui 7.23.88 → 7.23.89

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
@@ -2211,6 +2211,33 @@ metadata (`__md_treedb__`).
2211
2211
 
2212
2212
  ## Conventions
2213
2213
 
2214
+ ### Colour: a brand token as INK takes `-on-scheme`, as a FILL it does not
2215
+
2216
+ A Bulma brand colour (`--bulma-link`, `--bulma-danger`, …) is built to carry
2217
+ **white text on it**, so it is the wrong colour to write WITH: measured
2218
+ against the scheme background, the raw tokens as ink are
2219
+
2220
+ | token | raw, light | raw, dark | `-on-scheme`, light | `-on-scheme`, dark |
2221
+ |---|---|---|---|---|
2222
+ | `link` | 5.16 | **3.51** | 6.33 | 5.65 |
2223
+ | `danger` | **2.80** | 6.46 | 5.83 | 6.46 |
2224
+ | `success` | **2.14** | 8.48 | 8.14 | 8.48 |
2225
+ | `warning` | **1.75** | 10.38 | 7.09 | 10.38 |
2226
+ | `info` | **1.73** | 10.46 | 7.66 | 10.46 |
2227
+ | `primary` | **1.95** | 9.28 | 6.45 | 9.28 |
2228
+
2229
+ — every one of them fails the 4.5:1 of small text in one scheme or the other
2230
+ (`link` in dark, the rest in light). So:
2231
+
2232
+ - **ink** (`color`, a glyph, a thin border that MARKS a state):
2233
+ `var(--bulma-<name>-on-scheme, var(--bulma-<name>, #fallback))`;
2234
+ - **fill** (`background`, a chip, a pressed button): the raw token, paired
2235
+ with `--bulma-<name>-invert` for the text on it. A darkened background
2236
+ under inverted text is a button nobody asked for.
2237
+
2238
+ Bulma computes `-on-scheme` per scheme: the same hue, darkened on a light
2239
+ page (`warning` goes to 23% lightness), unchanged on a dark one.
2240
+
2214
2241
  ### i18n: a string must be able to CHANGE language, not just be translated once
2215
2242
 
2216
2243
  Passing a string through `t()` is **not** enough. `refresh_language()` only
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yuneta/gobj-ui",
3
- "version": "7.23.88",
3
+ "version": "7.23.89",
4
4
  "type": "module",
5
5
  "main": "dist/gobj-ui.cjs.js",
6
6
  "module": "dist/gobj-ui.es.js",
@@ -164,7 +164,7 @@
164
164
 
165
165
  .C_YUI_JSON .JSON_TOGGLE_REMOTE i {
166
166
  font-size: 0.8em;
167
- color: var(--bulma-link, #3273dc);
167
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #3273dc));
168
168
  }
169
169
 
170
170
  .C_YUI_JSON .JSON_KEY {
@@ -195,7 +195,7 @@
195
195
  }
196
196
 
197
197
  .C_YUI_JSON .JSON_STUB {
198
- color: var(--bulma-link, #3273dc);
198
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #3273dc));
199
199
  font-weight: 600;
200
200
  }
201
201
 
@@ -286,6 +286,12 @@
286
286
  /* Bulma's `.button.is-active` only borrows the :active border, which on a
287
287
  * three-way switch is not enough to say WHICH view you are looking at.
288
288
  * Fill it instead — the mark has to survive a glance. */
289
+ /* The raw `--bulma-link` on purpose, and not `-on-scheme`: this is a
290
+ * FILL. The `-on-scheme` variants exist for a brand colour used as
291
+ * INK -- they darken it on a light scheme so text can sit on the
292
+ * page -- and a darkened fill under `link-invert` text is a button
293
+ * nobody asked for. Ink takes `-on-scheme`; a background takes the
294
+ * raw token and pairs it with `-invert`. */
289
295
  .C_YUI_JSON .JSON_VIEW_MODE.is-active {
290
296
  background-color: var(--bulma-link, #3273dc);
291
297
  border-color: var(--bulma-link, #3273dc);
@@ -228,7 +228,9 @@
228
228
  }
229
229
 
230
230
  /*--- per-item state class (item.class) — generic disconnected tint ---*/
231
- .yui-nav-tabs .tabs li.yui-nav-disconnected a { color: var(--bulma-danger, #f14668); }
231
+ .yui-nav-tabs .tabs li.yui-nav-disconnected a {
232
+ color: var(--bulma-danger-on-scheme, var(--bulma-danger, #f14668));
233
+ }
232
234
 
233
235
  /*--- cards (section-index landing grid, mounted as a stage view) ---*/
234
236
  .yui-nav-cards {
@@ -261,11 +263,11 @@
261
263
  }
262
264
  .yui-nav-cards .yui-nav-card:hover,
263
265
  .yui-nav-cards .yui-nav-card:focus-visible {
264
- border-color: var(--bulma-link, #485fc7);
265
- color: var(--bulma-link, #485fc7);
266
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
267
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
266
268
  }
267
269
  .yui-nav-cards .yui-nav-card.is-active {
268
- border-color: var(--bulma-link, #485fc7);
270
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
269
271
  }
270
272
  .yui-nav-cards .yui-nav-card[data-disabled="1"] {
271
273
  opacity: 0.5;
@@ -629,7 +631,7 @@
629
631
  align-items: center;
630
632
  flex: 0 0 auto;
631
633
  visibility: hidden;
632
- color: var(--bulma-link, #485fc7);
634
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
633
635
  }
634
636
  .yui-toolbar-dropdown-item.is-selected .yui-toolbar-dropdown-check {
635
637
  visibility: visible;
@@ -27,8 +27,8 @@
27
27
  }
28
28
  /* Selected (clicked) card: link-coloured border + soft ring. */
29
29
  .TREEDB_TOPIC_CARD.is-selected {
30
- border-color: var(--bulma-link, #485fc7);
31
- box-shadow: 0 0 0 2px var(--bulma-link, #485fc7) inset;
30
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
31
+ box-shadow: 0 0 0 2px var(--bulma-link-on-scheme, var(--bulma-link, #485fc7)) inset;
32
32
  }
33
33
  .TREEDB_TOPIC_CARD .TREEDB_TOPIC_CARD_NAME {
34
34
  font-weight: 600;
@@ -57,7 +57,7 @@
57
57
  .TREEDB_TOPIC_CARD_ACTIONS > a:hover,
58
58
  .TREEDB_TOPIC_CARD_ACTIONS > a:focus-visible {
59
59
  background: var(--bulma-background, #f5f5f5);
60
- color: var(--bulma-link, #485fc7);
60
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
61
61
  }
62
62
 
63
63
  /* Routed topic-info panel. */
@@ -124,7 +124,7 @@ a.ROUTEMAP_LINK .ROUTEMAP_NAME {
124
124
  }
125
125
  .ROUTEMAP_ROUTE {
126
126
  background: transparent;
127
- color: var(--bulma-link, #485fc7);
127
+ color: var(--bulma-link-on-scheme, var(--bulma-link, #485fc7));
128
128
  padding: 0;
129
129
  font-size: 0.8rem;
130
130
  }
package/src/tabulator.css CHANGED
@@ -224,7 +224,7 @@
224
224
  background-color: var(--bulma-grey-darker, #2b2f38);
225
225
  color: var(--bulma-text-strong, #f5f6f7) !important;
226
226
  caret-color: var(--bulma-text-strong, #f5f6f7);
227
- border-color: var(--bulma-link, #4a9eff);
227
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #4a9eff));
228
228
  }
229
229
 
230
230
  [data-theme=dark] .tabulator-row .tabulator-cell.tabulator-editing input::placeholder,
@@ -263,7 +263,7 @@
263
263
 
264
264
  .tabulator .tabulator-header .tabulator-col .tabulator-header-filter input:focus,
265
265
  .tabulator .tabulator-header .tabulator-col .tabulator-header-filter select:focus {
266
- border-color: var(--bulma-link, #4a9eff);
266
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #4a9eff));
267
267
  outline: none;
268
268
  }
269
269
 
@@ -373,7 +373,7 @@
373
373
  background-color: var(--bulma-grey-darker, #2b2f38);
374
374
  color: var(--bulma-text-strong, #f5f6f7) !important;
375
375
  caret-color: var(--bulma-text-strong, #f5f6f7);
376
- border-color: var(--bulma-link, #4a9eff);
376
+ border-color: var(--bulma-link-on-scheme, var(--bulma-link, #4a9eff));
377
377
  }
378
378
  [data-theme=system] .tabulator-row .tabulator-cell.tabulator-editing input::placeholder,
379
379
  [data-theme=system] .tabulator .tabulator-header .tabulator-header-filter input::placeholder {