@yuneta/gobj-ui 7.28.3 → 7.29.1
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 +18 -18
- package/dist/gobj-ui.cjs.js +6 -6
- package/dist/gobj-ui.es.js +6 -6
- package/package.json +2 -2
- package/scripts/validate-locales.mjs +3 -3
- package/src/c_g6_nodes_tree.js +3 -3
- package/src/c_yui_gobj_tree_js.js +1 -1
- package/src/c_yui_shell.js +2 -2
- package/src/c_yui_treedb_graph.js +1 -1
- package/src/c_yui_treedb_schema.js +1 -1
- package/src/c_yui_treedb_topics.js +1 -1
- package/src/data_as_text.wiring.test.js +7 -8
- package/src/form_close_asks_for_edits.wiring.test.js +2 -2
- package/src/form_json_editor_names.js +1 -1
- package/src/form_json_editor_names.wiring.test.js +1 -1
- package/src/form_table_edits_ask.wiring.test.js +1 -1
- package/src/form_table_validator.wiring.test.js +2 -2
- package/src/form_template_field.wiring.test.js +2 -2
- package/src/g6_canvas_tab_order.wiring.test.js +4 -4
- package/src/g6_long_press_clock.test.js +2 -2
- package/src/g6_nodes_tree_controls.test.js +4 -4
- package/src/g6_nodes_tree_focus.wiring.test.js +3 -3
- package/src/g6_nodes_tree_i18n_keys.test.js +2 -2
- package/src/g6_patches_first_graph.wiring.test.js +1 -1
- package/src/gclass_head_text.wiring.test.js +3 -3
- package/src/gobj_tree_remote.wiring.test.js +2 -2
- package/src/i18n_key_functions.js +3 -3
- package/src/i18n_key_functions.test.js +29 -29
- package/src/lib_graph.css +1 -1
- package/src/lib_maplibre_relocalize.test.js +1 -1
- package/src/modal_guard_back.wiring.test.js +2 -2
- package/src/named_controls.wiring.test.js +8 -8
- package/src/nav_item_badge.wiring.test.js +2 -2
- package/src/overlay_marker_after_back.wiring.test.js +8 -14
- package/src/route_map_model.test.js +2 -2
- package/src/route_resolver.test.js +9 -9
- package/src/schema_editor_openers.wiring.test.js +1 -2
- package/src/schema_editor_reload.wiring.test.js +4 -4
- package/src/schema_import.js +1 -1
- package/src/schema_import.test.js +3 -3
- package/src/schema_validate.test.js +1 -1
- package/src/selector_from_data.wiring.test.js +1 -1
- package/src/shell_toolbar_helpers.test.js +1 -1
- package/src/table_editor_name.wiring.test.js +2 -2
- package/src/tabulator.css +1 -1
- package/src/tabulator_css.test.js +1 -1
- package/src/treedb_json_drill.wiring.test.js +2 -2
- package/src/treedb_topics_transport.wiring.test.js +1 -1
- package/src/uplot_ink.test.js +1 -1
- package/src/window_layer.wiring.test.js +6 -6
- package/src/yui_asset.test.js +1 -1
- package/src/yui_badge.test.js +1 -1
- package/src/yui_dev.js +2 -2
- package/src/yui_dev_controls.test.js +2 -2
- package/src/yui_dev_copy.test.js +2 -2
- package/src/yui_row_search.test.js +6 -6
- package/src/yui_selector.js +1 -1
- package/src/yui_tab_routes.test.js +5 -5
- package/src/yui_tabulator_i18n.test.js +1 -1
- package/vite-plugin-yuneta-html.js +1 -1
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/***********************************************************************
|
|
3
3
|
* selector_from_data.wiring.test.js
|
|
4
4
|
*
|
|
5
|
-
* A NAME IS DATA, NOT A SELECTOR
|
|
5
|
+
* A NAME IS DATA, NOT A SELECTOR.
|
|
6
6
|
*
|
|
7
7
|
* The G6 views gave their canvas mount the id
|
|
8
8
|
* `<prefix><gobj name>` and found it again with
|
|
@@ -59,7 +59,7 @@ test("classify: null/undefined are 'action'", () => {
|
|
|
59
59
|
test("validate brand: ok with logo + wordmark", () => {
|
|
60
60
|
let r = validate_toolbar_item({
|
|
61
61
|
id: "brand", type: "brand",
|
|
62
|
-
logo: "/wm.svg", wordmark: "
|
|
62
|
+
logo: "/wm.svg", wordmark: "MyApp",
|
|
63
63
|
action: { type: "navigate", route: "/welcome" }
|
|
64
64
|
});
|
|
65
65
|
expect(r.ok).toBe(true);
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* table_editor_name.wiring.test.js
|
|
3
3
|
*
|
|
4
4
|
* The box Tabulator draws in a cell while it is edited had no
|
|
5
|
-
* name: no label, no aria-label, no title (
|
|
6
|
-
* in the alarms of
|
|
5
|
+
* name: no label, no aria-label, no title (seen
|
|
6
|
+
* in the alarms of a consumer app's device). Both tables of the
|
|
7
7
|
* library that edit in place -- a table field of C_YUI_FORM and
|
|
8
8
|
* the inline editing of C_YUI_TREEDB_TOPIC_WITH_FORM -- now name
|
|
9
9
|
* it after its column, asked at the moment of editing: Tabulator
|
package/src/tabulator.css
CHANGED
|
@@ -189,7 +189,7 @@
|
|
|
189
189
|
*
|
|
190
190
|
* A box to type in, never a box to TICK: a checkbox or a radio given the
|
|
191
191
|
* whole cell is drawn as a square the size of the cell -- the tickCross
|
|
192
|
-
* editor of a boolean (
|
|
192
|
+
* editor of a boolean (an app's "validated") opened as a huge empty
|
|
193
193
|
* box on a phone, which read as broken. Those keep their own size.
|
|
194
194
|
* ==================================================================== */
|
|
195
195
|
.tabulator-row .tabulator-cell.tabulator-editing input:not([type=checkbox]):not([type=radio]),
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* The stylesheet of the tables: an editor fills its cell only when
|
|
5
5
|
* it is a box to TYPE in. A checkbox or a radio given width and
|
|
6
6
|
* height 100% is drawn as a square the size of the cell (the
|
|
7
|
-
* tickCross editor of
|
|
7
|
+
* tickCross editor of an app's "validated" opened as a huge
|
|
8
8
|
* empty box on a phone, gobj-ui 7.26.36).
|
|
9
9
|
*
|
|
10
10
|
* Read as text, as the window layer's invariants are: jsdom applies
|
|
@@ -317,7 +317,7 @@ for(const gclass of ["C_YUI_TREEDB_TOPICS", "C_YUI_TREEDB_GRAPH"]) {
|
|
|
317
317
|
test("a failure with no word from the backend draws the fallback KEY, translated", async () => {
|
|
318
318
|
/* "print-tranger failed" travelled as `error`, which the
|
|
319
319
|
* viewer draws as it came: the raw key, in English, in every
|
|
320
|
-
* language
|
|
320
|
+
* language. As `i18n` it is drawn with
|
|
321
321
|
* t() and carries data-i18n, so it changes language too. */
|
|
322
322
|
const i18next = (await import("i18next")).default;
|
|
323
323
|
i18next.addResourceBundle("en", "translation",
|
|
@@ -370,7 +370,7 @@ for(const gclass of ["C_YUI_TREEDB_TOPICS", "C_YUI_TREEDB_GRAPH"]) {
|
|
|
370
370
|
}
|
|
371
371
|
|
|
372
372
|
/*
|
|
373
|
-
*
|
|
373
|
+
* Two consumer apps hear the edge from the SHELL
|
|
374
374
|
* (EV_CONNECTION_STATE), not from a host that forwards the transport.
|
|
375
375
|
*/
|
|
376
376
|
describe("C_YUI_TREEDB_TOPICS: the shell's 'down' answers a drill in flight", () => {
|
|
@@ -137,7 +137,7 @@ beforeAll(() => {
|
|
|
137
137
|
{}, 0, [SDATA_END()], {}, 0, 0, 0, 0
|
|
138
138
|
);
|
|
139
139
|
/* An app that subscribes to EVERY event of its shell and declares
|
|
140
|
-
* none of the new ones:
|
|
140
|
+
* none of the new ones: the shape of two consumer apps. */
|
|
141
141
|
gclass_create("C_TEST_APP", [], [["ST_IDLE", []]], {}, 0, [SDATA_END()], {}, 0, 0, 0, 0);
|
|
142
142
|
/* An app that DOES declare it: it must still be told. */
|
|
143
143
|
gclass_create(
|
package/src/uplot_ink.test.js
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* C_YUI_UPLOT inked only the axes it was handed: by default one,
|
|
8
8
|
* the X. In the dark scheme the values of every Y axis of the
|
|
9
9
|
* library were black on near-black (a user's report, the cards of
|
|
10
|
-
*
|
|
10
|
+
* a consumer app).
|
|
11
11
|
*
|
|
12
12
|
* Copyright (c) 2026, ArtGins.
|
|
13
13
|
* All Rights Reserved.
|
|
@@ -8,15 +8,15 @@
|
|
|
8
8
|
* shell (a stacking context of its own) and the dialog of its own
|
|
9
9
|
* close opened under it.
|
|
10
10
|
*
|
|
11
|
-
* And that the place FOLLOWS the shell
|
|
11
|
+
* And that the place FOLLOWS the shell: a window
|
|
12
12
|
* parented to the app outlives a logout that destroys the shell.
|
|
13
13
|
* From 7.26.31 to 7.26.34 it stayed in the destroyed shell's layer,
|
|
14
14
|
* alive and detached, and the next shell never placed it again: the
|
|
15
|
-
* developer window of gui_agent, gui_treedb and
|
|
15
|
+
* developer window of gui_agent, gui_treedb and an app vanished
|
|
16
16
|
* after a logout and a login. The dock, the same.
|
|
17
17
|
*
|
|
18
|
-
* The gclass viewer opened from such a window follows it
|
|
19
|
-
*
|
|
18
|
+
* The gclass viewer opened from such a window follows it:
|
|
19
|
+
* up to 7.26.41 it was told the element its
|
|
20
20
|
* opener hung from as its `$parent` -- the body, between a logout and
|
|
21
21
|
* the next login -- and stayed there after the login, above the new
|
|
22
22
|
* shell's dialogs. And with two shells alive, destroying the last one
|
|
@@ -390,7 +390,7 @@ describe("the stacking of the windows", () => {
|
|
|
390
390
|
});
|
|
391
391
|
});
|
|
392
392
|
|
|
393
|
-
describe("the title of a dock chip changes language
|
|
393
|
+
describe("the title of a dock chip changes language", () => {
|
|
394
394
|
/* A window with a DATA half (a device id) and a KIND half (a key):
|
|
395
395
|
* the toggle's title and aria-label are COMPOSED, so no key carries
|
|
396
396
|
* them. Up to 7.26.35 they stayed in the language the window was
|
|
@@ -430,7 +430,7 @@ describe("the title of a dock chip changes language (REV-CLOUD V23, QA of estado
|
|
|
430
430
|
});
|
|
431
431
|
});
|
|
432
432
|
|
|
433
|
-
describe("
|
|
433
|
+
describe("a gclass viewer opened from a window goes where its opener goes", () => {
|
|
434
434
|
/* A view inside a window parented to the app: the frontend view in
|
|
435
435
|
* the developer window, whose `gclass` button opens the viewer. */
|
|
436
436
|
function window_with_a_view(name, kw)
|
package/src/yui_asset.test.js
CHANGED
|
@@ -46,7 +46,7 @@ test("reads every id out of an array fkey, in order", () => {
|
|
|
46
46
|
});
|
|
47
47
|
|
|
48
48
|
/*
|
|
49
|
-
* `fkey_only_id` is a normal way to read a node --
|
|
49
|
+
* `fkey_only_id` is a normal way to read a node -- one app reads every
|
|
50
50
|
* device that way -- and it collapses a link to the bare id. Reading only
|
|
51
51
|
* the `topic^id^hook` form made every such link look like no link at all.
|
|
52
52
|
*/
|
package/src/yui_badge.test.js
CHANGED
|
@@ -86,7 +86,7 @@ describe("badge_node", () => {
|
|
|
86
86
|
test("the host's classes, its tone and its text as text; no live region of its own", () => {
|
|
87
87
|
/* It said "3" with no context, missed the first count while
|
|
88
88
|
* hidden, and was not in the tree inside a <button>: the shell
|
|
89
|
-
* says the change now
|
|
89
|
+
* says the change now. */
|
|
90
90
|
let $b = createElement2(badge_node(3, "warning", "X_BADGE yui-badge", "who"));
|
|
91
91
|
expect($b.tagName).toBe("SPAN");
|
|
92
92
|
expect($b.getAttribute("role")).toBe(null);
|
package/src/yui_dev.js
CHANGED
|
@@ -77,8 +77,8 @@ const TRAFFIC_TS_FIELDS = {
|
|
|
77
77
|
* them. They are published HERE, as data: a consumer's `validate-locales`
|
|
78
78
|
* (gobj-ui 7.26.27+) reads an exported `*_I18N_KEYS` array of every module
|
|
79
79
|
* the app mounts and asks the locales for each key -- it used to be a
|
|
80
|
-
* comment each consumer copied by hand, and
|
|
81
|
-
*
|
|
80
|
+
* comment each consumer copied by hand, and one app lacked 35 of them.
|
|
81
|
+
* A key added to the window goes in this list. */
|
|
82
82
|
export const YUI_DEV_I18N_KEYS = [
|
|
83
83
|
"automata", "both", "browser console only", "clear",
|
|
84
84
|
"clear captured traffic", "collapsed", "console", "copied", "copy",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* yui_dev_controls.test.js
|
|
3
3
|
*
|
|
4
4
|
* Every control of the Developer window is NAMED, and every
|
|
5
|
-
* name changes language (
|
|
5
|
+
* name changes language (nine buttons had a
|
|
6
6
|
* `title` and no `aria-label` -- simple mach, the three of
|
|
7
7
|
* Output, the three of Expand, copy and clear).
|
|
8
8
|
*
|
|
@@ -105,7 +105,7 @@ describe("the Developer window's controls", () => {
|
|
|
105
105
|
expect(wrong).toEqual([]);
|
|
106
106
|
});
|
|
107
107
|
|
|
108
|
-
it("names the nine buttons
|
|
108
|
+
it("names the nine buttons a review found without one", () => {
|
|
109
109
|
const sel = [
|
|
110
110
|
'[data-toggle="automata-simple"]',
|
|
111
111
|
'[data-output="window"]', '[data-output="console"]', '[data-output="both"]',
|
package/src/yui_dev_copy.test.js
CHANGED
|
@@ -38,12 +38,12 @@ describe("entry_shown_lines", () => {
|
|
|
38
38
|
it("copies a closed branch as its one-line summary", () => {
|
|
39
39
|
const $e = painted({
|
|
40
40
|
result: 0,
|
|
41
|
-
comment: "
|
|
41
|
+
comment: "db_history^1620: 524 nodos",
|
|
42
42
|
data: {places: [1, 2, 3], families: [4], devices: [5, 6]},
|
|
43
43
|
});
|
|
44
44
|
expect(entry_shown_lines($e)).toEqual([
|
|
45
45
|
" • result: 0",
|
|
46
|
-
" • comment:
|
|
46
|
+
" • comment: db_history^1620: 524 nodos",
|
|
47
47
|
" ▸ data {places:[…],families:[…],devices:[…]}",
|
|
48
48
|
]);
|
|
49
49
|
});
|
|
@@ -4,11 +4,11 @@ import {row_matches, is_fkey_ref, is_hook_size} from "./yui_row_search.js";
|
|
|
4
4
|
|
|
5
5
|
describe("row_matches", () => {
|
|
6
6
|
const row = {
|
|
7
|
-
id: "
|
|
7
|
+
id: "E00000042",
|
|
8
8
|
name: "",
|
|
9
9
|
place: [
|
|
10
10
|
{
|
|
11
|
-
id: "es.
|
|
11
|
+
id: "es.city.site-a.local-13-gate",
|
|
12
12
|
topic_name: "places",
|
|
13
13
|
hook_name: "devices"
|
|
14
14
|
}
|
|
@@ -20,7 +20,7 @@ describe("row_matches", () => {
|
|
|
20
20
|
};
|
|
21
21
|
|
|
22
22
|
it("finds a plain field", () => {
|
|
23
|
-
expect(row_matches(row, "
|
|
23
|
+
expect(row_matches(row, "e00000042")).toBe(true);
|
|
24
24
|
});
|
|
25
25
|
|
|
26
26
|
it("finds a number", () => {
|
|
@@ -28,7 +28,7 @@ describe("row_matches", () => {
|
|
|
28
28
|
});
|
|
29
29
|
|
|
30
30
|
it("finds a value INSIDE an fkey, which is the whole point", () => {
|
|
31
|
-
expect(row_matches(row, "local-13-
|
|
31
|
+
expect(row_matches(row, "local-13-gate")).toBe(true);
|
|
32
32
|
});
|
|
33
33
|
|
|
34
34
|
it("does NOT match the structural halves of an fkey", () => {
|
|
@@ -80,10 +80,10 @@ describe("row_matches, on a table loaded with hook_size", () => {
|
|
|
80
80
|
const loaded = {
|
|
81
81
|
id: "places-madrid",
|
|
82
82
|
devices: [
|
|
83
|
-
{id: "
|
|
83
|
+
{id: "E00000042", topic_name: "devices", hook_name: "places"}
|
|
84
84
|
]
|
|
85
85
|
};
|
|
86
|
-
expect(row_matches(loaded, "
|
|
86
|
+
expect(row_matches(loaded, "e00000042")).toBe(true);
|
|
87
87
|
});
|
|
88
88
|
});
|
|
89
89
|
|
package/src/yui_selector.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* - `%` `^` `"` `\` and the rest make it INVALID: querySelector
|
|
15
15
|
* THROWS a SyntaxError, out of whatever action was running.
|
|
16
16
|
*
|
|
17
|
-
*
|
|
17
|
+
* The gobj tree found its canvas with
|
|
18
18
|
* `querySelector("#" + id)`, and gui_agent named the window
|
|
19
19
|
* `node~key` -- every open logged "no canvas mount" and the
|
|
20
20
|
* canvas never resized; a `^` in the key (`%5E`) threw out of
|
|
@@ -25,19 +25,19 @@ const US = String.fromCharCode(31); /* the composite-id separator */
|
|
|
25
25
|
|
|
26
26
|
describe("yui_tab_split_subpath", () => {
|
|
27
27
|
test("a bare tab tail is all id", () => {
|
|
28
|
-
expect(yui_tab_split_subpath("
|
|
28
|
+
expect(yui_tab_split_subpath("node1")).toEqual({id: "node1", tail: ""});
|
|
29
29
|
});
|
|
30
30
|
|
|
31
31
|
test("a deep tail keeps the id and hands the rest back", () => {
|
|
32
|
-
expect(yui_tab_split_subpath("
|
|
33
|
-
.toEqual({id: "
|
|
32
|
+
expect(yui_tab_split_subpath("node1/treedb_authzs/__graphs__"))
|
|
33
|
+
.toEqual({id: "node1", tail: "treedb_authzs/__graphs__"});
|
|
34
34
|
});
|
|
35
35
|
|
|
36
36
|
test("a composite id survives the url it travelled in", () => {
|
|
37
37
|
/* 0x1F joins the two halves of these ids and reaches the url
|
|
38
38
|
* percent-encoded. */
|
|
39
|
-
expect(yui_tab_split_subpath("
|
|
40
|
-
.toEqual({id: "
|
|
39
|
+
expect(yui_tab_split_subpath("node-a%1F1630/treedb_authzs/__graphs__"))
|
|
40
|
+
.toEqual({id: "node-a" + US + "1630",
|
|
41
41
|
tail: "treedb_authzs/__graphs__"});
|
|
42
42
|
});
|
|
43
43
|
|
|
@@ -122,7 +122,7 @@ describe("yui_tabulator_name_row_selects", () => {
|
|
|
122
122
|
describe("yui_tabulator_name_editor", () => {
|
|
123
123
|
/* Tabulator calls a FUNCTION editorParams with the cell when it starts
|
|
124
124
|
* editing it, and every built-in editor writes the elementAttributes
|
|
125
|
-
* it answers onto the box it draws (
|
|
125
|
+
* it answers onto the box it draws (the editable
|
|
126
126
|
* cells had no name). */
|
|
127
127
|
it("names the editor after the column, asked at the moment of editing", () => {
|
|
128
128
|
let lang = "en";
|
|
@@ -101,7 +101,7 @@ export function yunetaHtmlPlugin(options = {}) {
|
|
|
101
101
|
* with `<script src="/<name>.js">`. Same-origin URL
|
|
102
102
|
* satisfies 'self'; an inline block does not.
|
|
103
103
|
*
|
|
104
|
-
* See `
|
|
104
|
+
* See an application's `gui/public/anti-fouc.js` for the
|
|
105
105
|
* canonical pre-paint pattern (theme bootstrap from
|
|
106
106
|
* localStorage + matchMedia fallback).
|
|
107
107
|
*
|