@yuneta/gobj-ui 7.23.142 → 7.23.144
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 +40 -0
- package/dist/gobj-ui.cjs.js +1225 -213
- package/dist/gobj-ui.es.js +1225 -215
- package/index.js +2 -0
- package/package.json +1 -1
- package/src/c_yui_json_pad.css +94 -0
- package/src/c_yui_json_pad.js +907 -0
- package/src/c_yui_treedb_topic_with_form.js +14 -0
- package/src/json_view_helpers.js +56 -1
- package/src/json_view_helpers.test.js +43 -0
- package/src/yui_icons.css +12 -0
- package/src/yui_json_pad.js +109 -0
package/dist/gobj-ui.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as gobj_js from "@yuneta/gobj-js";
|
|
2
|
-
import { SDATA, SDATA_END, clean_name, createElement2, createOneHtml, create_template_record, data_type_t, debounce, delete_from_list, duplicate_objects, empty_json, empty_string, escapeHtml, event_flag_t, gclass_create, gclass_find_by_name, gclass_flag_t, getPositionRelativeToBody, gobj_bottom_gobj, gobj_change_state, gobj_command, gobj_create, gobj_create_pure_child, gobj_create_service, gobj_current_state, gobj_destroy, gobj_find_child, gobj_find_service, gobj_full_name, gobj_gclass_name, gobj_is_destroying, gobj_is_playing, gobj_is_pure_child, gobj_is_running, gobj_is_service, gobj_is_volatil, gobj_match_children, gobj_name, gobj_parent, gobj_post_event, gobj_publish_event, gobj_read_attr, gobj_read_bool_attr, gobj_read_integer_attr, gobj_read_pointer_attr, gobj_read_str_attr, gobj_save_persistent_attrs, gobj_send_event, gobj_set_trace_machine_format, gobj_short_name, gobj_start, gobj_start_tree, gobj_stop, gobj_stop_children, gobj_subscribe_event, gobj_unsubscribe_event, gobj_write_attr, gobj_write_bool_attr, gobj_write_integer_attr, gobj_write_str_attr, gobj_yuno, gobj_yuno_name, is_array, is_boolean, is_date, is_gobj, is_null, is_number, is_object, is_string, json_deep_copy, json_object_size, json_object_update, json_object_update_missing, json_size, kw_clone_by_keys, kw_flag_t, kw_get_dict, kw_get_dict_value, kw_get_int, kw_get_local_storage_value, kw_get_str, kw_has_key, kw_set_dict_value, kw_set_local_storage_value, kwid_find_one_record, kwid_get_ids, kwid_new_dict, log_error, log_warning, msg_iev_get_stack, parseBoolean, parseSVG, refresh_language, safeSrc, sdata_flag_t, set_console_log_enabled, set_log_callback, sprintf, str_in_list, template_get_field_desc, trace_msg, treedb_decoder_fkey, treedb_encoder_fkey, treedb_get_field_desc, treedb_hook_data_size } from "@yuneta/gobj-js";
|
|
2
|
+
import { SDATA, SDATA_END, clean_name, createElement2, createOneHtml, create_template_record, data_type_t, debounce, delete_from_list, duplicate_objects, empty_json, empty_string, escapeHtml, event_flag_t, flat_diff, gclass_create, gclass_find_by_name, gclass_flag_t, getPositionRelativeToBody, gobj_bottom_gobj, gobj_change_state, gobj_command, gobj_create, gobj_create_pure_child, gobj_create_service, gobj_current_state, gobj_destroy, gobj_find_child, gobj_find_service, gobj_full_name, gobj_gclass_name, gobj_is_destroying, gobj_is_playing, gobj_is_pure_child, gobj_is_running, gobj_is_service, gobj_is_volatil, gobj_match_children, gobj_name, gobj_parent, gobj_post_event, gobj_publish_event, gobj_read_attr, gobj_read_bool_attr, gobj_read_integer_attr, gobj_read_pointer_attr, gobj_read_str_attr, gobj_save_persistent_attrs, gobj_send_event, gobj_set_trace_machine_format, gobj_short_name, gobj_start, gobj_start_tree, gobj_stop, gobj_stop_children, gobj_subscribe_event, gobj_unsubscribe_event, gobj_write_attr, gobj_write_bool_attr, gobj_write_integer_attr, gobj_write_str_attr, gobj_yuno, gobj_yuno_name, is_array, is_boolean, is_date, is_gobj, is_null, is_number, is_object, is_string, json2flat, json_deep_copy, json_object_size, json_object_update, json_object_update_missing, json_size, kw_clone_by_keys, kw_flag_t, kw_get_dict, kw_get_dict_value, kw_get_int, kw_get_local_storage_value, kw_get_str, kw_has_key, kw_set_dict_value, kw_set_local_storage_value, kwid_find_one_record, kwid_get_ids, kwid_new_dict, log_error, log_warning, msg_iev_get_stack, parseBoolean, parseSVG, refresh_language, safeSrc, sdata_flag_t, set_console_log_enabled, set_log_callback, sprintf, str_in_list, template_get_field_desc, trace_msg, treedb_decoder_fkey, treedb_encoder_fkey, treedb_get_field_desc, treedb_hook_data_size } from "@yuneta/gobj-js";
|
|
3
3
|
import i18next, { t } from "i18next";
|
|
4
4
|
import TomSelect from "tom-select";
|
|
5
5
|
import { createJSONEditor } from "vanilla-jsoneditor";
|
|
@@ -866,7 +866,7 @@ function secondary_nav_renders(item, layout) {
|
|
|
866
866
|
/***************************************************************
|
|
867
867
|
* Constants
|
|
868
868
|
***************************************************************/
|
|
869
|
-
var GCLASS_NAME$
|
|
869
|
+
var GCLASS_NAME$22 = "C_YUI_SHELL";
|
|
870
870
|
var __last_shell__ = null;
|
|
871
871
|
var ZONE_IDS = [
|
|
872
872
|
"top",
|
|
@@ -888,7 +888,7 @@ var LAYER_DEFS = [
|
|
|
888
888
|
/***************************************************************
|
|
889
889
|
* Attrs
|
|
890
890
|
***************************************************************/
|
|
891
|
-
var attrs_table$
|
|
891
|
+
var attrs_table$22 = [
|
|
892
892
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
893
893
|
SDATA(data_type_t.DTP_JSON, "config", 0, null, "Shell declarative config (zones, menu, stages, toolbar)"),
|
|
894
894
|
SDATA(data_type_t.DTP_STRING, "default_route", 0, "", "Fallback route if hash is empty"),
|
|
@@ -899,7 +899,7 @@ var attrs_table$21 = [
|
|
|
899
899
|
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "Root HTMLElement of the shell"),
|
|
900
900
|
SDATA_END()
|
|
901
901
|
];
|
|
902
|
-
var PRIVATE_DATA$
|
|
902
|
+
var PRIVATE_DATA$22 = {
|
|
903
903
|
zones: {},
|
|
904
904
|
layers: {},
|
|
905
905
|
stages: {},
|
|
@@ -922,23 +922,23 @@ var PRIVATE_DATA$21 = {
|
|
|
922
922
|
conn_nodes: [],
|
|
923
923
|
active_dropdown: null
|
|
924
924
|
};
|
|
925
|
-
var __gclass__$
|
|
925
|
+
var __gclass__$22 = null;
|
|
926
926
|
/******************************
|
|
927
927
|
* Framework Methods
|
|
928
928
|
******************************/
|
|
929
929
|
/***************************************************************
|
|
930
930
|
* Framework Method: Create
|
|
931
931
|
***************************************************************/
|
|
932
|
-
function mt_create$
|
|
932
|
+
function mt_create$22(gobj) {
|
|
933
933
|
const subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
934
934
|
if (subscriber) gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
935
935
|
__last_shell__ = gobj;
|
|
936
|
-
build_ui$
|
|
936
|
+
build_ui$19(gobj);
|
|
937
937
|
}
|
|
938
938
|
/***************************************************************
|
|
939
939
|
* Framework Method: Start
|
|
940
940
|
***************************************************************/
|
|
941
|
-
function mt_start$
|
|
941
|
+
function mt_start$20(gobj) {
|
|
942
942
|
let config = gobj_read_attr(gobj, "config") || {};
|
|
943
943
|
let priv = gobj.priv;
|
|
944
944
|
if (!validate_config(config)) {
|
|
@@ -1007,7 +1007,7 @@ function mt_start$19(gobj) {
|
|
|
1007
1007
|
/***************************************************************
|
|
1008
1008
|
* Framework Method: Stop
|
|
1009
1009
|
***************************************************************/
|
|
1010
|
-
function mt_stop$
|
|
1010
|
+
function mt_stop$20(gobj) {
|
|
1011
1011
|
let priv = gobj.priv;
|
|
1012
1012
|
if (!priv) return 0;
|
|
1013
1013
|
close_toolbar_dropdown(gobj);
|
|
@@ -1048,7 +1048,7 @@ function mt_stop$19(gobj) {
|
|
|
1048
1048
|
/***************************************************************
|
|
1049
1049
|
* Framework Method: Destroy
|
|
1050
1050
|
***************************************************************/
|
|
1051
|
-
function mt_destroy$
|
|
1051
|
+
function mt_destroy$22(gobj) {
|
|
1052
1052
|
close_toolbar_dropdown(gobj);
|
|
1053
1053
|
let $container = gobj_read_attr(gobj, "$container");
|
|
1054
1054
|
if ($container && $container.parentNode) $container.parentNode.removeChild($container);
|
|
@@ -1164,7 +1164,7 @@ function check_route_unique(route_owner, item, menu_id) {
|
|
|
1164
1164
|
/************************************************************
|
|
1165
1165
|
* Build the DOM: layers → base → zones
|
|
1166
1166
|
************************************************************/
|
|
1167
|
-
function build_ui$
|
|
1167
|
+
function build_ui$19(gobj) {
|
|
1168
1168
|
let priv = gobj.priv;
|
|
1169
1169
|
let shell_cfg = (gobj_read_attr(gobj, "config") || {}).shell || {};
|
|
1170
1170
|
let $container = createElement2(["div", { class: "C_YUI_SHELL yui-shell" }]);
|
|
@@ -2551,14 +2551,14 @@ function ac_nav_item_close(gobj, event, kw, src) {
|
|
|
2551
2551
|
/***************************************************************
|
|
2552
2552
|
* FSM
|
|
2553
2553
|
***************************************************************/
|
|
2554
|
-
var gmt$
|
|
2555
|
-
mt_create: mt_create$
|
|
2556
|
-
mt_start: mt_start$
|
|
2557
|
-
mt_stop: mt_stop$
|
|
2558
|
-
mt_destroy: mt_destroy$
|
|
2554
|
+
var gmt$22 = {
|
|
2555
|
+
mt_create: mt_create$22,
|
|
2556
|
+
mt_start: mt_start$20,
|
|
2557
|
+
mt_stop: mt_stop$20,
|
|
2558
|
+
mt_destroy: mt_destroy$22
|
|
2559
2559
|
};
|
|
2560
|
-
function create_gclass$
|
|
2561
|
-
if (__gclass__$
|
|
2560
|
+
function create_gclass$22(gclass_name) {
|
|
2561
|
+
if (__gclass__$22) {
|
|
2562
2562
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
2563
2563
|
return -1;
|
|
2564
2564
|
}
|
|
@@ -2587,12 +2587,12 @@ function create_gclass$21(gclass_name) {
|
|
|
2587
2587
|
["EV_ROUTE_CHANGED", event_flag_t.EVF_OUTPUT_EVENT | event_flag_t.EVF_PUBLIC_EVENT | event_flag_t.EVF_NO_WARN_SUBS],
|
|
2588
2588
|
["EV_LANGUAGE_CHANGED", event_flag_t.EVF_OUTPUT_EVENT | event_flag_t.EVF_PUBLIC_EVENT | event_flag_t.EVF_NO_WARN_SUBS]
|
|
2589
2589
|
];
|
|
2590
|
-
__gclass__$
|
|
2591
|
-
if (!__gclass__$
|
|
2590
|
+
__gclass__$22 = gclass_create(gclass_name, event_types, states, gmt$22, 0, attrs_table$22, PRIVATE_DATA$22, 0, 0, 0, gclass_flag_t.gcflag_no_check_output_events);
|
|
2591
|
+
if (!__gclass__$22) return -1;
|
|
2592
2592
|
return 0;
|
|
2593
2593
|
}
|
|
2594
2594
|
function register_c_yui_shell() {
|
|
2595
|
-
return create_gclass$
|
|
2595
|
+
return create_gclass$22(GCLASS_NAME$22);
|
|
2596
2596
|
}
|
|
2597
2597
|
/***************************************************************
|
|
2598
2598
|
* Public helpers — exported alongside register_c_yui_shell().
|
|
@@ -2685,7 +2685,7 @@ function yui_shell_last_route_under(shell_gobj, route) {
|
|
|
2685
2685
|
function yui_shell_of(gobj) {
|
|
2686
2686
|
let g = gobj;
|
|
2687
2687
|
while (g) {
|
|
2688
|
-
if (gobj_gclass_name(g) === GCLASS_NAME$
|
|
2688
|
+
if (gobj_gclass_name(g) === GCLASS_NAME$22) return g;
|
|
2689
2689
|
g = gobj_parent(g);
|
|
2690
2690
|
}
|
|
2691
2691
|
return __last_shell__;
|
|
@@ -3439,7 +3439,7 @@ function yui_shell_confirm_yesnocancel(shell, message, opts) {
|
|
|
3439
3439
|
/***************************************************************
|
|
3440
3440
|
* Constants
|
|
3441
3441
|
***************************************************************/
|
|
3442
|
-
var GCLASS_NAME$
|
|
3442
|
+
var GCLASS_NAME$21 = "C_YUI_WINDOW";
|
|
3443
3443
|
var WC_MIN = "<svg viewBox=\"0 0 16 16\" aria-hidden=\"true\"><rect x=\"3\" y=\"11\" width=\"10\" height=\"1.6\" rx=\"0.8\" fill=\"currentColor\"/></svg>";
|
|
3444
3444
|
var WC_MAX = "<svg viewBox=\"0 0 16 16\" aria-hidden=\"true\"><rect x=\"3.3\" y=\"3.3\" width=\"9.4\" height=\"9.4\" rx=\"1.6\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\"/></svg>";
|
|
3445
3445
|
var WC_RESTORE = "<svg viewBox=\"0 0 16 16\" aria-hidden=\"true\"><rect x=\"5.2\" y=\"3\" width=\"7.8\" height=\"7.8\" rx=\"1.3\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.4\"/><rect x=\"3\" y=\"5.2\" width=\"7.8\" height=\"7.8\" rx=\"1.3\" fill=\"var(--bulma-scheme-main)\" stroke=\"currentColor\" stroke-width=\"1.4\"/></svg>";
|
|
@@ -3448,7 +3448,7 @@ var MOBILE_MAX = 768;
|
|
|
3448
3448
|
/***************************************************************
|
|
3449
3449
|
* Data
|
|
3450
3450
|
***************************************************************/
|
|
3451
|
-
var attrs_table$
|
|
3451
|
+
var attrs_table$21 = [
|
|
3452
3452
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
3453
3453
|
SDATA(data_type_t.DTP_POINTER, "$parent", 0, null, "$container will be appended to $parent if not null, else to document.body"),
|
|
3454
3454
|
SDATA(data_type_t.DTP_INTEGER, "x", 0, "300", "X position"),
|
|
@@ -3486,21 +3486,21 @@ var attrs_table$20 = [
|
|
|
3486
3486
|
SDATA(data_type_t.DTP_POINTER, "win_resize_handler", 0, null, "Internal: native window 'resize' listener"),
|
|
3487
3487
|
SDATA_END()
|
|
3488
3488
|
];
|
|
3489
|
-
var PRIVATE_DATA$
|
|
3490
|
-
var __gclass__$
|
|
3489
|
+
var PRIVATE_DATA$21 = { prevSize: 0 };
|
|
3490
|
+
var __gclass__$21 = null;
|
|
3491
3491
|
/******************************
|
|
3492
3492
|
* Framework Methods
|
|
3493
3493
|
******************************/
|
|
3494
3494
|
/***************************************************************
|
|
3495
3495
|
* Framework Method: Create
|
|
3496
3496
|
***************************************************************/
|
|
3497
|
-
function mt_create$
|
|
3497
|
+
function mt_create$21(gobj) {
|
|
3498
3498
|
const subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
3499
3499
|
if (subscriber) gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
3500
3500
|
let window_id = "window-" + clean_name(gobj_short_name(gobj));
|
|
3501
3501
|
gobj_write_attr(gobj, "window_id", window_id);
|
|
3502
3502
|
let manager = resolve_manager(gobj);
|
|
3503
|
-
build_ui$
|
|
3503
|
+
build_ui$18(gobj);
|
|
3504
3504
|
if (manager) {
|
|
3505
3505
|
let $c = gobj_read_attr(gobj, "$container");
|
|
3506
3506
|
if ($c) $c.addEventListener("pointerdown", function() {
|
|
@@ -3534,7 +3534,7 @@ function mt_create$20(gobj) {
|
|
|
3534
3534
|
/***************************************************************
|
|
3535
3535
|
* Framework Method: Destroy
|
|
3536
3536
|
***************************************************************/
|
|
3537
|
-
function mt_destroy$
|
|
3537
|
+
function mt_destroy$21(gobj) {
|
|
3538
3538
|
let manager = gobj_read_pointer_attr(gobj, "manager");
|
|
3539
3539
|
if (manager) gobj_send_event(manager, "EV_UNREGISTER_WINDOW", { window: gobj }, gobj);
|
|
3540
3540
|
let back_overlay = gobj_read_attr(gobj, "back_overlay");
|
|
@@ -3707,7 +3707,7 @@ function do_minimize(gobj) {
|
|
|
3707
3707
|
/************************************************************
|
|
3708
3708
|
* Build UI
|
|
3709
3709
|
************************************************************/
|
|
3710
|
-
function build_ui$
|
|
3710
|
+
function build_ui$18(gobj) {
|
|
3711
3711
|
ensure_window_style();
|
|
3712
3712
|
let mobile = is_mobile$4();
|
|
3713
3713
|
let header = gobj_read_attr(gobj, "header");
|
|
@@ -4268,15 +4268,15 @@ function ac_close(gobj, event, kw, src) {
|
|
|
4268
4268
|
/***************************
|
|
4269
4269
|
* FSM
|
|
4270
4270
|
***************************/
|
|
4271
|
-
var gmt$
|
|
4272
|
-
mt_create: mt_create$
|
|
4273
|
-
mt_destroy: mt_destroy$
|
|
4271
|
+
var gmt$21 = {
|
|
4272
|
+
mt_create: mt_create$21,
|
|
4273
|
+
mt_destroy: mt_destroy$21
|
|
4274
4274
|
};
|
|
4275
4275
|
/***************************************************************
|
|
4276
4276
|
* Create the GClass
|
|
4277
4277
|
***************************************************************/
|
|
4278
|
-
function create_gclass$
|
|
4279
|
-
if (__gclass__$
|
|
4278
|
+
function create_gclass$21(gclass_name) {
|
|
4279
|
+
if (__gclass__$21) {
|
|
4280
4280
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
4281
4281
|
return -1;
|
|
4282
4282
|
}
|
|
@@ -4311,15 +4311,15 @@ function create_gclass$20(gclass_name) {
|
|
|
4311
4311
|
["EV_HIDE", 0],
|
|
4312
4312
|
["EV_CLOSE_WINDOW", 0]
|
|
4313
4313
|
];
|
|
4314
|
-
__gclass__$
|
|
4315
|
-
if (!__gclass__$
|
|
4314
|
+
__gclass__$21 = gclass_create(gclass_name, event_types, states, gmt$21, 0, attrs_table$21, PRIVATE_DATA$21, 0, 0, 0, 0);
|
|
4315
|
+
if (!__gclass__$21) return -1;
|
|
4316
4316
|
return 0;
|
|
4317
4317
|
}
|
|
4318
4318
|
/***************************************************************
|
|
4319
4319
|
* Register GClass
|
|
4320
4320
|
***************************************************************/
|
|
4321
4321
|
function register_c_yui_window() {
|
|
4322
|
-
return create_gclass$
|
|
4322
|
+
return create_gclass$21(GCLASS_NAME$21);
|
|
4323
4323
|
}
|
|
4324
4324
|
//#endregion
|
|
4325
4325
|
//#region src/c_yui_window_manager.js
|
|
@@ -4357,13 +4357,13 @@ function register_c_yui_window() {
|
|
|
4357
4357
|
/***************************************************************
|
|
4358
4358
|
* Constants
|
|
4359
4359
|
***************************************************************/
|
|
4360
|
-
var GCLASS_NAME$
|
|
4360
|
+
var GCLASS_NAME$20 = "C_YUI_WINDOW_MANAGER";
|
|
4361
4361
|
var DOCK_Z = 1e6;
|
|
4362
4362
|
var WC_X = "<svg viewBox=\"0 0 16 16\" aria-hidden=\"true\"><path d=\"M4.5 4.5 L11.5 11.5 M11.5 4.5 L4.5 11.5\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\"/></svg>";
|
|
4363
4363
|
/***************************************************************
|
|
4364
4364
|
* Data
|
|
4365
4365
|
***************************************************************/
|
|
4366
|
-
var attrs_table$
|
|
4366
|
+
var attrs_table$20 = [
|
|
4367
4367
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
4368
4368
|
SDATA(data_type_t.DTP_STRING, "dock_mode", 0, "floating", "floating | inline | responsive (floating on wide screens, inline on narrow)"),
|
|
4369
4369
|
SDATA(data_type_t.DTP_STRING, "dock_corner", 0, "bottom-left", "Floating placement: top-left | top-right | bottom-left | bottom-right"),
|
|
@@ -4373,20 +4373,20 @@ var attrs_table$19 = [
|
|
|
4373
4373
|
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "Internal: the dock element"),
|
|
4374
4374
|
SDATA_END()
|
|
4375
4375
|
];
|
|
4376
|
-
var PRIVATE_DATA$
|
|
4376
|
+
var PRIVATE_DATA$20 = {
|
|
4377
4377
|
windows: null,
|
|
4378
4378
|
z: 0,
|
|
4379
4379
|
mql: null,
|
|
4380
4380
|
mql_handler: null
|
|
4381
4381
|
};
|
|
4382
|
-
var __gclass__$
|
|
4382
|
+
var __gclass__$20 = null;
|
|
4383
4383
|
/******************************
|
|
4384
4384
|
* Framework Methods
|
|
4385
4385
|
******************************/
|
|
4386
4386
|
/***************************************************************
|
|
4387
4387
|
* Framework Method: Create
|
|
4388
4388
|
***************************************************************/
|
|
4389
|
-
function mt_create$
|
|
4389
|
+
function mt_create$20(gobj) {
|
|
4390
4390
|
let priv = gobj.priv;
|
|
4391
4391
|
priv.windows = [];
|
|
4392
4392
|
priv.z = 10;
|
|
@@ -4405,7 +4405,7 @@ function mt_create$19(gobj) {
|
|
|
4405
4405
|
/***************************************************************
|
|
4406
4406
|
* Framework Method: Destroy
|
|
4407
4407
|
***************************************************************/
|
|
4408
|
-
function mt_destroy$
|
|
4408
|
+
function mt_destroy$20(gobj) {
|
|
4409
4409
|
let priv = gobj.priv;
|
|
4410
4410
|
if (priv.mql && priv.mql_handler) {
|
|
4411
4411
|
priv.mql.removeEventListener("change", priv.mql_handler);
|
|
@@ -4774,19 +4774,19 @@ function ac_focus_window(gobj, event, kw, src) {
|
|
|
4774
4774
|
/***************************
|
|
4775
4775
|
* FSM
|
|
4776
4776
|
***************************/
|
|
4777
|
-
var gmt$
|
|
4778
|
-
mt_create: mt_create$
|
|
4779
|
-
mt_destroy: mt_destroy$
|
|
4777
|
+
var gmt$20 = {
|
|
4778
|
+
mt_create: mt_create$20,
|
|
4779
|
+
mt_destroy: mt_destroy$20
|
|
4780
4780
|
};
|
|
4781
4781
|
/***************************************************************
|
|
4782
4782
|
* Create the GClass
|
|
4783
4783
|
***************************************************************/
|
|
4784
|
-
function create_gclass$
|
|
4785
|
-
if (__gclass__$
|
|
4784
|
+
function create_gclass$20(gclass_name) {
|
|
4785
|
+
if (__gclass__$20) {
|
|
4786
4786
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
4787
4787
|
return -1;
|
|
4788
4788
|
}
|
|
4789
|
-
__gclass__$
|
|
4789
|
+
__gclass__$20 = gclass_create(gclass_name, [
|
|
4790
4790
|
["EV_REGISTER_WINDOW", 0],
|
|
4791
4791
|
["EV_UNREGISTER_WINDOW", 0],
|
|
4792
4792
|
["EV_MINIMIZE_WINDOW", 0],
|
|
@@ -4812,15 +4812,15 @@ function create_gclass$19(gclass_name) {
|
|
|
4812
4812
|
ac_focus_window,
|
|
4813
4813
|
null
|
|
4814
4814
|
]
|
|
4815
|
-
]]], gmt$
|
|
4816
|
-
if (!__gclass__$
|
|
4815
|
+
]]], gmt$20, 0, attrs_table$20, PRIVATE_DATA$20, 0, 0, 0, 0);
|
|
4816
|
+
if (!__gclass__$20) return -1;
|
|
4817
4817
|
return 0;
|
|
4818
4818
|
}
|
|
4819
4819
|
/***************************************************************
|
|
4820
4820
|
* Register GClass
|
|
4821
4821
|
***************************************************************/
|
|
4822
4822
|
function register_c_yui_window_manager() {
|
|
4823
|
-
return create_gclass$
|
|
4823
|
+
return create_gclass$20(GCLASS_NAME$20);
|
|
4824
4824
|
}
|
|
4825
4825
|
//#endregion
|
|
4826
4826
|
//#region src/pager_helpers.js
|
|
@@ -4906,11 +4906,11 @@ function pager_back_action(stack, back_on_root) {
|
|
|
4906
4906
|
/***************************************************************
|
|
4907
4907
|
* Constants
|
|
4908
4908
|
***************************************************************/
|
|
4909
|
-
var GCLASS_NAME$
|
|
4909
|
+
var GCLASS_NAME$19 = "C_YUI_PAGER";
|
|
4910
4910
|
/***************************************************************
|
|
4911
4911
|
* Data
|
|
4912
4912
|
***************************************************************/
|
|
4913
|
-
var attrs_table$
|
|
4913
|
+
var attrs_table$19 = [
|
|
4914
4914
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
4915
4915
|
SDATA(data_type_t.DTP_STRING, "root_title", 0, "", "Title shown on the root page"),
|
|
4916
4916
|
SDATA(data_type_t.DTP_BOOLEAN, "back_on_root", 0, true, "On the root page the back affordance emits EV_PAGER_EXIT"),
|
|
@@ -4918,18 +4918,18 @@ var attrs_table$18 = [
|
|
|
4918
4918
|
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "HTMLElement root, mounted by the parent"),
|
|
4919
4919
|
SDATA_END()
|
|
4920
4920
|
];
|
|
4921
|
-
var PRIVATE_DATA$
|
|
4922
|
-
var __gclass__$
|
|
4921
|
+
var PRIVATE_DATA$19 = { stack: null };
|
|
4922
|
+
var __gclass__$19 = null;
|
|
4923
4923
|
/******************************
|
|
4924
4924
|
* Framework Methods
|
|
4925
4925
|
******************************/
|
|
4926
4926
|
/***************************************************************
|
|
4927
4927
|
* Framework Method: Create
|
|
4928
4928
|
***************************************************************/
|
|
4929
|
-
function mt_create$
|
|
4929
|
+
function mt_create$19(gobj) {
|
|
4930
4930
|
let priv = gobj.priv;
|
|
4931
4931
|
priv.stack = [];
|
|
4932
|
-
build_ui$
|
|
4932
|
+
build_ui$17(gobj);
|
|
4933
4933
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
4934
4934
|
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
4935
4935
|
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
@@ -4937,17 +4937,17 @@ function mt_create$18(gobj) {
|
|
|
4937
4937
|
/***************************************************************
|
|
4938
4938
|
* Framework Method: Start
|
|
4939
4939
|
***************************************************************/
|
|
4940
|
-
function mt_start$
|
|
4940
|
+
function mt_start$19(gobj) {}
|
|
4941
4941
|
/***************************************************************
|
|
4942
4942
|
* Framework Method: Stop
|
|
4943
4943
|
***************************************************************/
|
|
4944
|
-
function mt_stop$
|
|
4944
|
+
function mt_stop$19(gobj) {
|
|
4945
4945
|
gobj_stop_children(gobj);
|
|
4946
4946
|
}
|
|
4947
4947
|
/***************************************************************
|
|
4948
4948
|
* Framework Method: Destroy
|
|
4949
4949
|
***************************************************************/
|
|
4950
|
-
function mt_destroy$
|
|
4950
|
+
function mt_destroy$19(gobj) {
|
|
4951
4951
|
destroy_ui$12(gobj);
|
|
4952
4952
|
}
|
|
4953
4953
|
/***************************
|
|
@@ -4956,7 +4956,7 @@ function mt_destroy$18(gobj) {
|
|
|
4956
4956
|
/************************************************************
|
|
4957
4957
|
* Build UI
|
|
4958
4958
|
************************************************************/
|
|
4959
|
-
function build_ui$
|
|
4959
|
+
function build_ui$17(gobj) {
|
|
4960
4960
|
let $container = createElement2([
|
|
4961
4961
|
"div",
|
|
4962
4962
|
{
|
|
@@ -5108,7 +5108,7 @@ function ac_push_page(gobj, event, kw, src) {
|
|
|
5108
5108
|
let priv = gobj.priv;
|
|
5109
5109
|
let resolved = resolve_panel$1(kw.content);
|
|
5110
5110
|
if (!resolved.$el) {
|
|
5111
|
-
log_error(`${GCLASS_NAME$
|
|
5111
|
+
log_error(`${GCLASS_NAME$19}: EV_PUSH_PAGE without content`);
|
|
5112
5112
|
return -1;
|
|
5113
5113
|
}
|
|
5114
5114
|
let $body = gobj_read_attr(gobj, "$container").querySelector(".yui-pager-body");
|
|
@@ -5161,7 +5161,7 @@ function ac_replace_page(gobj, event, kw, src) {
|
|
|
5161
5161
|
let priv = gobj.priv;
|
|
5162
5162
|
let resolved = resolve_panel$1(kw.content);
|
|
5163
5163
|
if (!resolved.$el) {
|
|
5164
|
-
log_error(`${GCLASS_NAME$
|
|
5164
|
+
log_error(`${GCLASS_NAME$19}: EV_REPLACE_PAGE without content`);
|
|
5165
5165
|
return -1;
|
|
5166
5166
|
}
|
|
5167
5167
|
let $body = gobj_read_attr(gobj, "$container").querySelector(".yui-pager-body");
|
|
@@ -5228,17 +5228,17 @@ function ac_resize$5(gobj, event, kw, src) {
|
|
|
5228
5228
|
/***************************
|
|
5229
5229
|
* FSM
|
|
5230
5230
|
***************************/
|
|
5231
|
-
var gmt$
|
|
5232
|
-
mt_create: mt_create$
|
|
5233
|
-
mt_start: mt_start$
|
|
5234
|
-
mt_stop: mt_stop$
|
|
5235
|
-
mt_destroy: mt_destroy$
|
|
5231
|
+
var gmt$19 = {
|
|
5232
|
+
mt_create: mt_create$19,
|
|
5233
|
+
mt_start: mt_start$19,
|
|
5234
|
+
mt_stop: mt_stop$19,
|
|
5235
|
+
mt_destroy: mt_destroy$19
|
|
5236
5236
|
};
|
|
5237
5237
|
/***************************************************************
|
|
5238
5238
|
* Create the GClass
|
|
5239
5239
|
***************************************************************/
|
|
5240
|
-
function create_gclass$
|
|
5241
|
-
if (__gclass__$
|
|
5240
|
+
function create_gclass$19(gclass_name) {
|
|
5241
|
+
if (__gclass__$19) {
|
|
5242
5242
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
5243
5243
|
return -1;
|
|
5244
5244
|
}
|
|
@@ -5303,15 +5303,15 @@ function create_gclass$18(gclass_name) {
|
|
|
5303
5303
|
["EV_PAGE_DISCARD", event_flag_t.EVF_OUTPUT_EVENT],
|
|
5304
5304
|
["EV_PAGER_EXIT", event_flag_t.EVF_OUTPUT_EVENT]
|
|
5305
5305
|
];
|
|
5306
|
-
__gclass__$
|
|
5307
|
-
if (!__gclass__$
|
|
5306
|
+
__gclass__$19 = gclass_create(gclass_name, event_types, states, gmt$19, 0, attrs_table$19, PRIVATE_DATA$19, 0, 0, 0, 0);
|
|
5307
|
+
if (!__gclass__$19) return -1;
|
|
5308
5308
|
return 0;
|
|
5309
5309
|
}
|
|
5310
5310
|
/***************************************************************
|
|
5311
5311
|
* Register GClass
|
|
5312
5312
|
***************************************************************/
|
|
5313
5313
|
function register_c_yui_pager() {
|
|
5314
|
-
return create_gclass$
|
|
5314
|
+
return create_gclass$19(GCLASS_NAME$19);
|
|
5315
5315
|
}
|
|
5316
5316
|
//#endregion
|
|
5317
5317
|
//#region src/wizard_helpers.js
|
|
@@ -5432,11 +5432,11 @@ function wizard_should_validate(linear, has_gobj) {
|
|
|
5432
5432
|
/***************************************************************
|
|
5433
5433
|
* Constants
|
|
5434
5434
|
***************************************************************/
|
|
5435
|
-
var GCLASS_NAME$
|
|
5435
|
+
var GCLASS_NAME$18 = "C_YUI_WIZARD";
|
|
5436
5436
|
/***************************************************************
|
|
5437
5437
|
* Data
|
|
5438
5438
|
***************************************************************/
|
|
5439
|
-
var attrs_table$
|
|
5439
|
+
var attrs_table$18 = [
|
|
5440
5440
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
5441
5441
|
SDATA(data_type_t.DTP_STRING, "confirm_label", 0, "confirm", "i18n key of the last-step primary button"),
|
|
5442
5442
|
SDATA(data_type_t.DTP_STRING, "next_label", 0, "next", "i18n key of the primary button (not last step)"),
|
|
@@ -5446,26 +5446,26 @@ var attrs_table$17 = [
|
|
|
5446
5446
|
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "HTMLElement root, mounted by the parent"),
|
|
5447
5447
|
SDATA_END()
|
|
5448
5448
|
];
|
|
5449
|
-
var PRIVATE_DATA$
|
|
5449
|
+
var PRIVATE_DATA$18 = {
|
|
5450
5450
|
steps: null,
|
|
5451
5451
|
idx: 0,
|
|
5452
5452
|
acc: null,
|
|
5453
5453
|
awaiting: false
|
|
5454
5454
|
};
|
|
5455
|
-
var __gclass__$
|
|
5455
|
+
var __gclass__$18 = null;
|
|
5456
5456
|
/******************************
|
|
5457
5457
|
* Framework Methods
|
|
5458
5458
|
******************************/
|
|
5459
5459
|
/***************************************************************
|
|
5460
5460
|
* Framework Method: Create
|
|
5461
5461
|
***************************************************************/
|
|
5462
|
-
function mt_create$
|
|
5462
|
+
function mt_create$18(gobj) {
|
|
5463
5463
|
let priv = gobj.priv;
|
|
5464
5464
|
priv.steps = [];
|
|
5465
5465
|
priv.idx = 0;
|
|
5466
5466
|
priv.acc = null;
|
|
5467
5467
|
priv.awaiting = false;
|
|
5468
|
-
build_ui$
|
|
5468
|
+
build_ui$16(gobj);
|
|
5469
5469
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
5470
5470
|
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
5471
5471
|
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
@@ -5473,17 +5473,17 @@ function mt_create$17(gobj) {
|
|
|
5473
5473
|
/***************************************************************
|
|
5474
5474
|
* Framework Method: Start
|
|
5475
5475
|
***************************************************************/
|
|
5476
|
-
function mt_start$
|
|
5476
|
+
function mt_start$18(gobj) {}
|
|
5477
5477
|
/***************************************************************
|
|
5478
5478
|
* Framework Method: Stop
|
|
5479
5479
|
***************************************************************/
|
|
5480
|
-
function mt_stop$
|
|
5480
|
+
function mt_stop$18(gobj) {
|
|
5481
5481
|
gobj_stop_children(gobj);
|
|
5482
5482
|
}
|
|
5483
5483
|
/***************************************************************
|
|
5484
5484
|
* Framework Method: Destroy
|
|
5485
5485
|
***************************************************************/
|
|
5486
|
-
function mt_destroy$
|
|
5486
|
+
function mt_destroy$18(gobj) {
|
|
5487
5487
|
destroy_ui$11(gobj);
|
|
5488
5488
|
}
|
|
5489
5489
|
/***************************
|
|
@@ -5492,7 +5492,7 @@ function mt_destroy$17(gobj) {
|
|
|
5492
5492
|
/************************************************************
|
|
5493
5493
|
* Build UI
|
|
5494
5494
|
************************************************************/
|
|
5495
|
-
function build_ui$
|
|
5495
|
+
function build_ui$16(gobj) {
|
|
5496
5496
|
let $container = createElement2([
|
|
5497
5497
|
"div",
|
|
5498
5498
|
{
|
|
@@ -5693,7 +5693,7 @@ function ac_set_steps(gobj, event, kw, src) {
|
|
|
5693
5693
|
let priv = gobj.priv;
|
|
5694
5694
|
let steps_in = kw && kw.steps || [];
|
|
5695
5695
|
if (steps_in.length === 0) {
|
|
5696
|
-
log_error(`${GCLASS_NAME$
|
|
5696
|
+
log_error(`${GCLASS_NAME$18}: EV_SET_STEPS with no steps`);
|
|
5697
5697
|
return -1;
|
|
5698
5698
|
}
|
|
5699
5699
|
let $body = gobj_read_attr(gobj, "$container").querySelector(".yui-wizard-body");
|
|
@@ -5703,7 +5703,7 @@ function ac_set_steps(gobj, event, kw, src) {
|
|
|
5703
5703
|
let st = steps_in[i];
|
|
5704
5704
|
let resolved = resolve_panel(st.content);
|
|
5705
5705
|
if (!resolved.$el) {
|
|
5706
|
-
log_error(`${GCLASS_NAME$
|
|
5706
|
+
log_error(`${GCLASS_NAME$18}: step '${st.id}' has no content`);
|
|
5707
5707
|
return -1;
|
|
5708
5708
|
}
|
|
5709
5709
|
resolved.$el.classList.add("is-hidden");
|
|
@@ -5837,17 +5837,17 @@ function ac_resize$4(gobj, event, kw, src) {
|
|
|
5837
5837
|
/***************************
|
|
5838
5838
|
* FSM
|
|
5839
5839
|
***************************/
|
|
5840
|
-
var gmt$
|
|
5841
|
-
mt_create: mt_create$
|
|
5842
|
-
mt_start: mt_start$
|
|
5843
|
-
mt_stop: mt_stop$
|
|
5844
|
-
mt_destroy: mt_destroy$
|
|
5840
|
+
var gmt$18 = {
|
|
5841
|
+
mt_create: mt_create$18,
|
|
5842
|
+
mt_start: mt_start$18,
|
|
5843
|
+
mt_stop: mt_stop$18,
|
|
5844
|
+
mt_destroy: mt_destroy$18
|
|
5845
5845
|
};
|
|
5846
5846
|
/***************************************************************
|
|
5847
5847
|
* Create the GClass
|
|
5848
5848
|
***************************************************************/
|
|
5849
|
-
function create_gclass$
|
|
5850
|
-
if (__gclass__$
|
|
5849
|
+
function create_gclass$18(gclass_name) {
|
|
5850
|
+
if (__gclass__$18) {
|
|
5851
5851
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
5852
5852
|
return -1;
|
|
5853
5853
|
}
|
|
@@ -5925,15 +5925,15 @@ function create_gclass$17(gclass_name) {
|
|
|
5925
5925
|
["EV_WIZARD_CANCEL", event_flag_t.EVF_OUTPUT_EVENT],
|
|
5926
5926
|
["EV_STEP_VALIDATE", event_flag_t.EVF_OUTPUT_EVENT | event_flag_t.EVF_NO_WARN_SUBS]
|
|
5927
5927
|
];
|
|
5928
|
-
__gclass__$
|
|
5929
|
-
if (!__gclass__$
|
|
5928
|
+
__gclass__$18 = gclass_create(gclass_name, event_types, states, gmt$18, 0, attrs_table$18, PRIVATE_DATA$18, 0, 0, 0, 0);
|
|
5929
|
+
if (!__gclass__$18) return -1;
|
|
5930
5930
|
return 0;
|
|
5931
5931
|
}
|
|
5932
5932
|
/***************************************************************
|
|
5933
5933
|
* Register GClass
|
|
5934
5934
|
***************************************************************/
|
|
5935
5935
|
function register_c_yui_wizard() {
|
|
5936
|
-
return create_gclass$
|
|
5936
|
+
return create_gclass$18(GCLASS_NAME$18);
|
|
5937
5937
|
}
|
|
5938
5938
|
//#endregion
|
|
5939
5939
|
//#region src/yui_tabulator_i18n.js
|
|
@@ -7048,6 +7048,60 @@ function count_branches(value) {
|
|
|
7048
7048
|
for (let v of entries) if (has_branch(v)) n++;
|
|
7049
7049
|
return n;
|
|
7050
7050
|
}
|
|
7051
|
+
/************************************************************
|
|
7052
|
+
* What differs between two documents: one row per id of
|
|
7053
|
+
* their flat form (json2flat), sorted by id in natural order,
|
|
7054
|
+
* so `[2]` comes before `[10]`:
|
|
7055
|
+
*
|
|
7056
|
+
* [{id, kind: "added"|"removed"|"changed", from?, to?}]
|
|
7057
|
+
*
|
|
7058
|
+
* `from` is the first document's value and `to` the second's:
|
|
7059
|
+
* an added row has no `from`, a removed row no `to`.
|
|
7060
|
+
*
|
|
7061
|
+
* Two roots that are not containers of the same kind have no
|
|
7062
|
+
* ids in common to compare by: they are one value each, and
|
|
7063
|
+
* the row that says they differ has the empty id.
|
|
7064
|
+
*
|
|
7065
|
+
* Throws what json2flat throws (a document too deep).
|
|
7066
|
+
************************************************************/
|
|
7067
|
+
function json_diff_rows(doc_a, doc_b) {
|
|
7068
|
+
const kind_of = (v) => {
|
|
7069
|
+
if (Array.isArray(v)) return "array";
|
|
7070
|
+
if (v !== null && typeof v === "object") return "object";
|
|
7071
|
+
return "scalar";
|
|
7072
|
+
};
|
|
7073
|
+
let kind_a = kind_of(doc_a);
|
|
7074
|
+
if (kind_a === "scalar" || kind_a !== kind_of(doc_b)) {
|
|
7075
|
+
if (JSON.stringify(doc_a) === JSON.stringify(doc_b)) return [];
|
|
7076
|
+
return [{
|
|
7077
|
+
id: "",
|
|
7078
|
+
kind: "changed",
|
|
7079
|
+
from: doc_a,
|
|
7080
|
+
to: doc_b
|
|
7081
|
+
}];
|
|
7082
|
+
}
|
|
7083
|
+
let diff = flat_diff(json2flat(doc_a), json2flat(doc_b));
|
|
7084
|
+
let rows = [];
|
|
7085
|
+
for (const id of Object.keys(diff.added)) rows.push({
|
|
7086
|
+
id,
|
|
7087
|
+
kind: "added",
|
|
7088
|
+
to: diff.added[id]
|
|
7089
|
+
});
|
|
7090
|
+
for (const id of Object.keys(diff.removed)) rows.push({
|
|
7091
|
+
id,
|
|
7092
|
+
kind: "removed",
|
|
7093
|
+
from: diff.removed[id]
|
|
7094
|
+
});
|
|
7095
|
+
for (const id of Object.keys(diff.changed)) rows.push({
|
|
7096
|
+
id,
|
|
7097
|
+
kind: "changed",
|
|
7098
|
+
from: diff.changed[id].from,
|
|
7099
|
+
to: diff.changed[id].to
|
|
7100
|
+
});
|
|
7101
|
+
const collator = new Intl.Collator("en", { numeric: true });
|
|
7102
|
+
rows.sort((x, y) => collator.compare(x.id, y.id));
|
|
7103
|
+
return rows;
|
|
7104
|
+
}
|
|
7051
7105
|
//#endregion
|
|
7052
7106
|
//#region src/c_yui_form.js
|
|
7053
7107
|
/***********************************************************************
|
|
@@ -7061,11 +7115,11 @@ function count_branches(value) {
|
|
|
7061
7115
|
/***************************************************************
|
|
7062
7116
|
* Constants
|
|
7063
7117
|
***************************************************************/
|
|
7064
|
-
var GCLASS_NAME$
|
|
7118
|
+
var GCLASS_NAME$17 = "C_YUI_FORM";
|
|
7065
7119
|
/***************************************************************
|
|
7066
7120
|
* Data
|
|
7067
7121
|
***************************************************************/
|
|
7068
|
-
var attrs_table$
|
|
7122
|
+
var attrs_table$17 = [
|
|
7069
7123
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of publishing messages"),
|
|
7070
7124
|
SDATA(data_type_t.DTP_POINTER, "$parent", 0, null, "$container will be appended to $parent if not null, else do it manually"),
|
|
7071
7125
|
SDATA(data_type_t.DTP_POINTER, "template", 0, "<div>You must supply a template for form</div>", "Template for form, object -> TEMPLATE, array -> DESC"),
|
|
@@ -7095,41 +7149,41 @@ var attrs_table$16 = [
|
|
|
7095
7149
|
SDATA(data_type_t.DTP_BOOLEAN, "changes", 0, false, "Indicates if changes have been made"),
|
|
7096
7150
|
SDATA_END()
|
|
7097
7151
|
];
|
|
7098
|
-
var PRIVATE_DATA$
|
|
7099
|
-
var __gclass__$
|
|
7152
|
+
var PRIVATE_DATA$17 = {};
|
|
7153
|
+
var __gclass__$17 = null;
|
|
7100
7154
|
/***************************
|
|
7101
7155
|
* Framework Methods
|
|
7102
7156
|
***************************/
|
|
7103
7157
|
/************************************************************
|
|
7104
7158
|
* Framework Method create
|
|
7105
7159
|
************************************************************/
|
|
7106
|
-
function mt_create$
|
|
7160
|
+
function mt_create$17(gobj) {
|
|
7107
7161
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
7108
7162
|
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
7109
7163
|
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
7110
7164
|
let name = clean_name(gobj_name(gobj));
|
|
7111
7165
|
gobj_write_attr(gobj, "form_id", "form" + name);
|
|
7112
|
-
build_ui$
|
|
7166
|
+
build_ui$15(gobj);
|
|
7113
7167
|
}
|
|
7114
7168
|
/************************************************************
|
|
7115
7169
|
* Framework Method destroy
|
|
7116
7170
|
* In this point, all children
|
|
7117
7171
|
* and subscriptions are already deleted.
|
|
7118
7172
|
************************************************************/
|
|
7119
|
-
function mt_destroy$
|
|
7173
|
+
function mt_destroy$17(gobj) {
|
|
7120
7174
|
destroy_ui$10(gobj);
|
|
7121
7175
|
}
|
|
7122
7176
|
/************************************************************
|
|
7123
7177
|
* Framework Method start
|
|
7124
7178
|
************************************************************/
|
|
7125
|
-
function mt_start$
|
|
7179
|
+
function mt_start$17(gobj) {
|
|
7126
7180
|
let record = gobj_read_attr(gobj, "record");
|
|
7127
7181
|
if (record) gobj_send_event(gobj, "EV_LOAD_RECORD", record, gobj);
|
|
7128
7182
|
}
|
|
7129
7183
|
/************************************************************
|
|
7130
7184
|
* Framework Method stop
|
|
7131
7185
|
************************************************************/
|
|
7132
|
-
function mt_stop$
|
|
7186
|
+
function mt_stop$17(gobj) {}
|
|
7133
7187
|
/***************************
|
|
7134
7188
|
* Local Methods
|
|
7135
7189
|
***************************/
|
|
@@ -7384,7 +7438,7 @@ function build_toolbar(gobj) {
|
|
|
7384
7438
|
/************************************************************
|
|
7385
7439
|
* Build UI
|
|
7386
7440
|
************************************************************/
|
|
7387
|
-
function build_ui$
|
|
7441
|
+
function build_ui$15(gobj) {
|
|
7388
7442
|
let $container = createElement2([
|
|
7389
7443
|
"div",
|
|
7390
7444
|
{
|
|
@@ -9402,18 +9456,18 @@ function cmd_get_picked_files(gobj, cmd, kw, src) {
|
|
|
9402
9456
|
data: files
|
|
9403
9457
|
};
|
|
9404
9458
|
}
|
|
9405
|
-
var gmt$
|
|
9406
|
-
mt_create: mt_create$
|
|
9407
|
-
mt_start: mt_start$
|
|
9408
|
-
mt_stop: mt_stop$
|
|
9409
|
-
mt_destroy: mt_destroy$
|
|
9459
|
+
var gmt$17 = {
|
|
9460
|
+
mt_create: mt_create$17,
|
|
9461
|
+
mt_start: mt_start$17,
|
|
9462
|
+
mt_stop: mt_stop$17,
|
|
9463
|
+
mt_destroy: mt_destroy$17,
|
|
9410
9464
|
mt_command_parser: mt_command_parser$2
|
|
9411
9465
|
};
|
|
9412
9466
|
/***************************************************************
|
|
9413
9467
|
* Create the GClass
|
|
9414
9468
|
***************************************************************/
|
|
9415
|
-
function create_gclass$
|
|
9416
|
-
if (__gclass__$
|
|
9469
|
+
function create_gclass$17(gclass_name) {
|
|
9470
|
+
if (__gclass__$17) {
|
|
9417
9471
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
9418
9472
|
return -1;
|
|
9419
9473
|
}
|
|
@@ -9511,16 +9565,16 @@ function create_gclass$16(gclass_name) {
|
|
|
9511
9565
|
["EV_HIDE", 0],
|
|
9512
9566
|
["EV_TIMEOUT", 0]
|
|
9513
9567
|
];
|
|
9514
|
-
__gclass__$
|
|
9515
|
-
if (!__gclass__$
|
|
9568
|
+
__gclass__$17 = gclass_create(gclass_name, event_types, states, gmt$17, 0, attrs_table$17, PRIVATE_DATA$17, 0, 0, 0, 0);
|
|
9569
|
+
if (!__gclass__$17) return -1;
|
|
9516
9570
|
return 0;
|
|
9517
9571
|
}
|
|
9518
9572
|
/***************************************************************
|
|
9519
9573
|
* Register GClass
|
|
9520
9574
|
***************************************************************/
|
|
9521
9575
|
function register_c_yui_form() {
|
|
9522
|
-
if (gclass_find_by_name(GCLASS_NAME$
|
|
9523
|
-
return create_gclass$
|
|
9576
|
+
if (gclass_find_by_name(GCLASS_NAME$17, false)) return 0;
|
|
9577
|
+
return create_gclass$17(GCLASS_NAME$17);
|
|
9524
9578
|
}
|
|
9525
9579
|
//#endregion
|
|
9526
9580
|
//#region src/lib_maplibre.js
|
|
@@ -9758,12 +9812,12 @@ function yui_maplibre_relocalize(map, t) {
|
|
|
9758
9812
|
/***************************************************************
|
|
9759
9813
|
* Constants
|
|
9760
9814
|
***************************************************************/
|
|
9761
|
-
var GCLASS_NAME$
|
|
9815
|
+
var GCLASS_NAME$16 = "C_YUI_MAP";
|
|
9762
9816
|
var GESTURE_HINT_MS = 2e3;
|
|
9763
9817
|
/***************************************************************
|
|
9764
9818
|
* Data
|
|
9765
9819
|
***************************************************************/
|
|
9766
|
-
var attrs_table$
|
|
9820
|
+
var attrs_table$16 = [
|
|
9767
9821
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
9768
9822
|
SDATA(data_type_t.DTP_JSON, "devices", "[]", null, "List of devices"),
|
|
9769
9823
|
SDATA(data_type_t.DTP_JSON, "map_settings", 0, {
|
|
@@ -9784,7 +9838,7 @@ var attrs_table$15 = [
|
|
|
9784
9838
|
SDATA(data_type_t.DTP_INTEGER, "timeout_idle", 0, 5, "Idle timeout in seconds"),
|
|
9785
9839
|
SDATA_END()
|
|
9786
9840
|
];
|
|
9787
|
-
var PRIVATE_DATA$
|
|
9841
|
+
var PRIVATE_DATA$16 = {
|
|
9788
9842
|
xmap: null,
|
|
9789
9843
|
gesture_hint_timer: null,
|
|
9790
9844
|
geojson: null,
|
|
@@ -9794,21 +9848,21 @@ var PRIVATE_DATA$15 = {
|
|
|
9794
9848
|
markers: {},
|
|
9795
9849
|
draggedFeature: null
|
|
9796
9850
|
};
|
|
9797
|
-
var __gclass__$
|
|
9851
|
+
var __gclass__$16 = null;
|
|
9798
9852
|
/******************************
|
|
9799
9853
|
* Framework Methods
|
|
9800
9854
|
******************************/
|
|
9801
9855
|
/***************************************************************
|
|
9802
9856
|
* Framework Method: Create
|
|
9803
9857
|
***************************************************************/
|
|
9804
|
-
function mt_create$
|
|
9858
|
+
function mt_create$16(gobj) {
|
|
9805
9859
|
let priv = gobj.priv;
|
|
9806
9860
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
9807
9861
|
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
9808
9862
|
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
9809
9863
|
let map_settings = json_deep_copy(gobj_read_attr(gobj, "map_settings"));
|
|
9810
9864
|
let $map = gobj_read_attr(gobj, "$map");
|
|
9811
|
-
if ($map) $map.classList.add(GCLASS_NAME$
|
|
9865
|
+
if ($map) $map.classList.add(GCLASS_NAME$16);
|
|
9812
9866
|
Object.assign(map_settings, {
|
|
9813
9867
|
container: $map,
|
|
9814
9868
|
cooperativeGestures: true,
|
|
@@ -9887,7 +9941,7 @@ function ac_language_changed$9(gobj, event, kw, src) {
|
|
|
9887
9941
|
* in OUR dom -- cannot touch any of it. The shell says when the
|
|
9888
9942
|
* language changed and this view rewrites those strings.
|
|
9889
9943
|
***************************************************************/
|
|
9890
|
-
function mt_start$
|
|
9944
|
+
function mt_start$16(gobj) {
|
|
9891
9945
|
let shell = yui_shell_of(gobj);
|
|
9892
9946
|
if (shell) gobj_subscribe_event(shell, "EV_LANGUAGE_CHANGED", {}, gobj);
|
|
9893
9947
|
return 0;
|
|
@@ -9895,7 +9949,7 @@ function mt_start$15(gobj) {
|
|
|
9895
9949
|
/***************************************************************
|
|
9896
9950
|
* Framework Method: Stop
|
|
9897
9951
|
***************************************************************/
|
|
9898
|
-
function mt_stop$
|
|
9952
|
+
function mt_stop$16(gobj) {
|
|
9899
9953
|
let shell = yui_shell_of(gobj);
|
|
9900
9954
|
if (shell) gobj_unsubscribe_event(shell, "EV_LANGUAGE_CHANGED", {}, gobj);
|
|
9901
9955
|
return 0;
|
|
@@ -9903,7 +9957,7 @@ function mt_stop$15(gobj) {
|
|
|
9903
9957
|
/***************************************************************
|
|
9904
9958
|
* Framework Method: Destroy
|
|
9905
9959
|
***************************************************************/
|
|
9906
|
-
function mt_destroy$
|
|
9960
|
+
function mt_destroy$16(gobj) {
|
|
9907
9961
|
let priv = gobj.priv;
|
|
9908
9962
|
if (priv.gesture_hint_timer) {
|
|
9909
9963
|
clearTimeout(priv.gesture_hint_timer);
|
|
@@ -10367,21 +10421,21 @@ function ac_hide$10(gobj, event, kw, src) {
|
|
|
10367
10421
|
/***************************
|
|
10368
10422
|
* FSM
|
|
10369
10423
|
***************************/
|
|
10370
|
-
var gmt$
|
|
10371
|
-
mt_create: mt_create$
|
|
10372
|
-
mt_start: mt_start$
|
|
10373
|
-
mt_stop: mt_stop$
|
|
10374
|
-
mt_destroy: mt_destroy$
|
|
10424
|
+
var gmt$16 = {
|
|
10425
|
+
mt_create: mt_create$16,
|
|
10426
|
+
mt_start: mt_start$16,
|
|
10427
|
+
mt_stop: mt_stop$16,
|
|
10428
|
+
mt_destroy: mt_destroy$16
|
|
10375
10429
|
};
|
|
10376
10430
|
/***************************************************************
|
|
10377
10431
|
* Create the GClass
|
|
10378
10432
|
***************************************************************/
|
|
10379
|
-
function create_gclass$
|
|
10380
|
-
if (__gclass__$
|
|
10433
|
+
function create_gclass$16(gclass_name) {
|
|
10434
|
+
if (__gclass__$16) {
|
|
10381
10435
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
10382
10436
|
return -1;
|
|
10383
10437
|
}
|
|
10384
|
-
__gclass__$
|
|
10438
|
+
__gclass__$16 = gclass_create(gclass_name, [
|
|
10385
10439
|
["EV_LANGUAGE_CHANGED", 0],
|
|
10386
10440
|
["EV_EDIT_MAP", 0],
|
|
10387
10441
|
["EV_CONTROL_MAP", 0],
|
|
@@ -10431,15 +10485,15 @@ function create_gclass$15(gclass_name) {
|
|
|
10431
10485
|
ac_hide$10,
|
|
10432
10486
|
null
|
|
10433
10487
|
]
|
|
10434
|
-
]]], gmt$
|
|
10435
|
-
if (!__gclass__$
|
|
10488
|
+
]]], gmt$16, 0, attrs_table$16, PRIVATE_DATA$16, 0, 0, 0, 0);
|
|
10489
|
+
if (!__gclass__$16) return -1;
|
|
10436
10490
|
return 0;
|
|
10437
10491
|
}
|
|
10438
10492
|
/***************************************************************
|
|
10439
10493
|
* Register GClass
|
|
10440
10494
|
***************************************************************/
|
|
10441
10495
|
function register_c_yui_map() {
|
|
10442
|
-
return create_gclass$
|
|
10496
|
+
return create_gclass$16(GCLASS_NAME$16);
|
|
10443
10497
|
}
|
|
10444
10498
|
//#endregion
|
|
10445
10499
|
//#region src/c_yui_uplot.js
|
|
@@ -10514,11 +10568,11 @@ function themed_axes(axes) {
|
|
|
10514
10568
|
/***************************************************************
|
|
10515
10569
|
* Constants
|
|
10516
10570
|
***************************************************************/
|
|
10517
|
-
var GCLASS_NAME$
|
|
10571
|
+
var GCLASS_NAME$15 = "C_YUI_UPLOT";
|
|
10518
10572
|
/***************************************************************
|
|
10519
10573
|
* Data
|
|
10520
10574
|
***************************************************************/
|
|
10521
|
-
var attrs_table$
|
|
10575
|
+
var attrs_table$15 = [
|
|
10522
10576
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
10523
10577
|
SDATA(data_type_t.DTP_STRING, "title", 0, "", "Chart title"),
|
|
10524
10578
|
SDATA(data_type_t.DTP_INTEGER, "width", 0, 800, "Chart width"),
|
|
@@ -10536,16 +10590,16 @@ var attrs_table$14 = [
|
|
|
10536
10590
|
SDATA(data_type_t.DTP_INTEGER, "timeout_idle", 0, 5, "Idle timeout (seconds)"),
|
|
10537
10591
|
SDATA_END()
|
|
10538
10592
|
];
|
|
10539
|
-
var PRIVATE_DATA$
|
|
10540
|
-
var __gclass__$
|
|
10593
|
+
var PRIVATE_DATA$15 = { theme_observer: null };
|
|
10594
|
+
var __gclass__$15 = null;
|
|
10541
10595
|
/******************************
|
|
10542
10596
|
* Framework Methods
|
|
10543
10597
|
******************************/
|
|
10544
10598
|
/***************************************************************
|
|
10545
10599
|
* Framework Method: Create
|
|
10546
10600
|
***************************************************************/
|
|
10547
|
-
function mt_create$
|
|
10548
|
-
build_ui$
|
|
10601
|
+
function mt_create$15(gobj) {
|
|
10602
|
+
build_ui$14(gobj);
|
|
10549
10603
|
gobj.priv.theme_observer = yui_watch_theme(gobj);
|
|
10550
10604
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
10551
10605
|
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
@@ -10554,15 +10608,15 @@ function mt_create$14(gobj) {
|
|
|
10554
10608
|
/***************************************************************
|
|
10555
10609
|
* Framework Method: Start
|
|
10556
10610
|
***************************************************************/
|
|
10557
|
-
function mt_start$
|
|
10611
|
+
function mt_start$15(gobj) {}
|
|
10558
10612
|
/***************************************************************
|
|
10559
10613
|
* Framework Method: Stop
|
|
10560
10614
|
***************************************************************/
|
|
10561
|
-
function mt_stop$
|
|
10615
|
+
function mt_stop$15(gobj) {}
|
|
10562
10616
|
/***************************************************************
|
|
10563
10617
|
* Framework Method: Destroy
|
|
10564
10618
|
***************************************************************/
|
|
10565
|
-
function mt_destroy$
|
|
10619
|
+
function mt_destroy$15(gobj) {
|
|
10566
10620
|
if (gobj.priv.theme_observer) {
|
|
10567
10621
|
gobj.priv.theme_observer.disconnect();
|
|
10568
10622
|
gobj.priv.theme_observer = null;
|
|
@@ -10580,7 +10634,7 @@ function mt_destroy$14(gobj) {
|
|
|
10580
10634
|
/************************************************************
|
|
10581
10635
|
* Build UI
|
|
10582
10636
|
************************************************************/
|
|
10583
|
-
function build_ui$
|
|
10637
|
+
function build_ui$14(gobj) {
|
|
10584
10638
|
let $container = gobj_read_attr(gobj, "$container");
|
|
10585
10639
|
if (!$container) {
|
|
10586
10640
|
$container = createElement2(["div", {
|
|
@@ -10737,7 +10791,7 @@ function ac_del_serie(gobj, event, kw, src) {
|
|
|
10737
10791
|
/******************************************************
|
|
10738
10792
|
*
|
|
10739
10793
|
******************************************************/
|
|
10740
|
-
function ac_clear(gobj, event, kw, src) {
|
|
10794
|
+
function ac_clear$1(gobj, event, kw, src) {
|
|
10741
10795
|
let uplot = gobj_read_attr(gobj, "uplot");
|
|
10742
10796
|
uplot.setData([[]]);
|
|
10743
10797
|
for (let idx = uplot.series.length - 1; idx > 0; idx--) uplot.delSeries(idx);
|
|
@@ -10746,21 +10800,21 @@ function ac_clear(gobj, event, kw, src) {
|
|
|
10746
10800
|
/***************************
|
|
10747
10801
|
* FSM
|
|
10748
10802
|
***************************/
|
|
10749
|
-
var gmt$
|
|
10750
|
-
mt_create: mt_create$
|
|
10751
|
-
mt_start: mt_start$
|
|
10752
|
-
mt_stop: mt_stop$
|
|
10753
|
-
mt_destroy: mt_destroy$
|
|
10803
|
+
var gmt$15 = {
|
|
10804
|
+
mt_create: mt_create$15,
|
|
10805
|
+
mt_start: mt_start$15,
|
|
10806
|
+
mt_stop: mt_stop$15,
|
|
10807
|
+
mt_destroy: mt_destroy$15
|
|
10754
10808
|
};
|
|
10755
10809
|
/***************************************************************
|
|
10756
10810
|
* Create the GClass
|
|
10757
10811
|
***************************************************************/
|
|
10758
|
-
function create_gclass$
|
|
10759
|
-
if (__gclass__$
|
|
10812
|
+
function create_gclass$15(gclass_name) {
|
|
10813
|
+
if (__gclass__$15) {
|
|
10760
10814
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
10761
10815
|
return -1;
|
|
10762
10816
|
}
|
|
10763
|
-
__gclass__$
|
|
10817
|
+
__gclass__$15 = gclass_create(gclass_name, [
|
|
10764
10818
|
["EV_LOAD_DATA", 0],
|
|
10765
10819
|
["EV_ADD_SERIE", 0],
|
|
10766
10820
|
["EV_DEL_SERIE", 0],
|
|
@@ -10784,7 +10838,7 @@ function create_gclass$14(gclass_name) {
|
|
|
10784
10838
|
],
|
|
10785
10839
|
[
|
|
10786
10840
|
"EV_CLEAR",
|
|
10787
|
-
ac_clear,
|
|
10841
|
+
ac_clear$1,
|
|
10788
10842
|
null
|
|
10789
10843
|
],
|
|
10790
10844
|
[
|
|
@@ -10792,15 +10846,15 @@ function create_gclass$14(gclass_name) {
|
|
|
10792
10846
|
ac_theme$4,
|
|
10793
10847
|
null
|
|
10794
10848
|
]
|
|
10795
|
-
]]], gmt$
|
|
10796
|
-
if (!__gclass__$
|
|
10849
|
+
]]], gmt$15, 0, attrs_table$15, PRIVATE_DATA$15, 0, 0, 0, 0);
|
|
10850
|
+
if (!__gclass__$15) return -1;
|
|
10797
10851
|
return 0;
|
|
10798
10852
|
}
|
|
10799
10853
|
/***************************************************************
|
|
10800
10854
|
* Register GClass
|
|
10801
10855
|
***************************************************************/
|
|
10802
10856
|
function register_c_yui_uplot() {
|
|
10803
|
-
return create_gclass$
|
|
10857
|
+
return create_gclass$15(GCLASS_NAME$15);
|
|
10804
10858
|
}
|
|
10805
10859
|
//#endregion
|
|
10806
10860
|
//#region src/yui_toolbar.js
|
|
@@ -11890,7 +11944,7 @@ function ensure_drag_canvas_patch() {
|
|
|
11890
11944
|
/***************************************************************
|
|
11891
11945
|
* Constants
|
|
11892
11946
|
***************************************************************/
|
|
11893
|
-
var GCLASS_NAME$
|
|
11947
|
+
var GCLASS_NAME$14 = "C_YUI_JSON_GRAPH";
|
|
11894
11948
|
var FOLD_SWALLOWED_EVENTS$1 = [
|
|
11895
11949
|
"pointerdown",
|
|
11896
11950
|
"pointerup",
|
|
@@ -11950,7 +12004,7 @@ function layout_label(key) {
|
|
|
11950
12004
|
/***************************************************************
|
|
11951
12005
|
* Data
|
|
11952
12006
|
***************************************************************/
|
|
11953
|
-
var attrs_table$
|
|
12007
|
+
var attrs_table$14 = [
|
|
11954
12008
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
11955
12009
|
SDATA(data_type_t.DTP_STRING, "path", 0, "", "Root path label"),
|
|
11956
12010
|
SDATA(data_type_t.DTP_JSON, "json_data", 0, null, "JSON data to visualize"),
|
|
@@ -11960,7 +12014,7 @@ var attrs_table$13 = [
|
|
|
11960
12014
|
SDATA(data_type_t.DTP_STRING, "layout", 0, "json-tree", "Layout key (see LAYOUTS)"),
|
|
11961
12015
|
SDATA_END()
|
|
11962
12016
|
];
|
|
11963
|
-
var PRIVATE_DATA$
|
|
12017
|
+
var PRIVATE_DATA$14 = {
|
|
11964
12018
|
canvas_id: "",
|
|
11965
12019
|
graph: null,
|
|
11966
12020
|
node_counter: 0,
|
|
@@ -11985,7 +12039,7 @@ var PRIVATE_DATA$13 = {
|
|
|
11985
12039
|
center_posted: false,
|
|
11986
12040
|
pending_keep: null
|
|
11987
12041
|
};
|
|
11988
|
-
var __gclass__$
|
|
12042
|
+
var __gclass__$14 = null;
|
|
11989
12043
|
var __layout_registered__$1 = false;
|
|
11990
12044
|
/***************************************************************
|
|
11991
12045
|
* Type colours, ONE EXPLICIT PALETTE PER THEME and not a
|
|
@@ -12090,7 +12144,7 @@ function type_color(type, dark) {
|
|
|
12090
12144
|
/***************************************************************
|
|
12091
12145
|
* Framework Method: Create
|
|
12092
12146
|
***************************************************************/
|
|
12093
|
-
function mt_create$
|
|
12147
|
+
function mt_create$14(gobj) {
|
|
12094
12148
|
let priv = gobj.priv;
|
|
12095
12149
|
priv.collapsed = /* @__PURE__ */ new Set();
|
|
12096
12150
|
priv.reserved = /* @__PURE__ */ new Map();
|
|
@@ -12102,7 +12156,7 @@ function mt_create$13(gobj) {
|
|
|
12102
12156
|
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
12103
12157
|
priv.theme = yui_theme_now();
|
|
12104
12158
|
priv.theme_observer = yui_watch_theme(gobj);
|
|
12105
|
-
build_ui$
|
|
12159
|
+
build_ui$13(gobj);
|
|
12106
12160
|
ensure_drag_canvas_patch();
|
|
12107
12161
|
ensure_pinch_zoom_patch();
|
|
12108
12162
|
if (!__layout_registered__$1) {
|
|
@@ -12113,18 +12167,18 @@ function mt_create$13(gobj) {
|
|
|
12113
12167
|
/***************************************************************
|
|
12114
12168
|
* Framework Method: Start
|
|
12115
12169
|
***************************************************************/
|
|
12116
|
-
function mt_start$
|
|
12170
|
+
function mt_start$14(gobj) {
|
|
12117
12171
|
build_graph$4(gobj);
|
|
12118
12172
|
load_json(gobj);
|
|
12119
12173
|
}
|
|
12120
12174
|
/***************************************************************
|
|
12121
12175
|
* Framework Method: Stop
|
|
12122
12176
|
***************************************************************/
|
|
12123
|
-
function mt_stop$
|
|
12177
|
+
function mt_stop$14(gobj) {}
|
|
12124
12178
|
/***************************************************************
|
|
12125
12179
|
* Framework Method: Destroy
|
|
12126
12180
|
***************************************************************/
|
|
12127
|
-
function mt_destroy$
|
|
12181
|
+
function mt_destroy$14(gobj) {
|
|
12128
12182
|
if (gobj.priv.find_timer) {
|
|
12129
12183
|
clearTimeout(gobj.priv.find_timer);
|
|
12130
12184
|
gobj.priv.find_timer = null;
|
|
@@ -12154,7 +12208,7 @@ function mt_destroy$13(gobj) {
|
|
|
12154
12208
|
/************************************************************
|
|
12155
12209
|
* Build UI
|
|
12156
12210
|
************************************************************/
|
|
12157
|
-
function build_ui$
|
|
12211
|
+
function build_ui$13(gobj) {
|
|
12158
12212
|
let priv = gobj.priv;
|
|
12159
12213
|
let $toolbar = make_toolbar$5(gobj);
|
|
12160
12214
|
let $container = createElement2([
|
|
@@ -13376,17 +13430,17 @@ function ac_hide$9(gobj, event, kw, src) {
|
|
|
13376
13430
|
/***************************
|
|
13377
13431
|
* FSM
|
|
13378
13432
|
***************************/
|
|
13379
|
-
var gmt$
|
|
13380
|
-
mt_create: mt_create$
|
|
13381
|
-
mt_start: mt_start$
|
|
13382
|
-
mt_stop: mt_stop$
|
|
13383
|
-
mt_destroy: mt_destroy$
|
|
13433
|
+
var gmt$14 = {
|
|
13434
|
+
mt_create: mt_create$14,
|
|
13435
|
+
mt_start: mt_start$14,
|
|
13436
|
+
mt_stop: mt_stop$14,
|
|
13437
|
+
mt_destroy: mt_destroy$14
|
|
13384
13438
|
};
|
|
13385
13439
|
/***************************************************************
|
|
13386
13440
|
* Create the GClass
|
|
13387
13441
|
***************************************************************/
|
|
13388
|
-
function create_gclass$
|
|
13389
|
-
if (__gclass__$
|
|
13442
|
+
function create_gclass$14(gclass_name) {
|
|
13443
|
+
if (__gclass__$14) {
|
|
13390
13444
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
13391
13445
|
return -1;
|
|
13392
13446
|
}
|
|
@@ -13503,16 +13557,16 @@ function create_gclass$13(gclass_name) {
|
|
|
13503
13557
|
["EV_HIDE", 0],
|
|
13504
13558
|
["EV_JSON_ITEM_CLICKED", event_flag_t.EVF_OUTPUT_EVENT]
|
|
13505
13559
|
];
|
|
13506
|
-
__gclass__$
|
|
13507
|
-
if (!__gclass__$
|
|
13560
|
+
__gclass__$14 = gclass_create(gclass_name, event_types, states, gmt$14, 0, attrs_table$14, PRIVATE_DATA$14, 0, 0, 0, 0);
|
|
13561
|
+
if (!__gclass__$14) return -1;
|
|
13508
13562
|
return 0;
|
|
13509
13563
|
}
|
|
13510
13564
|
/***************************************************************
|
|
13511
13565
|
* Register GClass
|
|
13512
13566
|
***************************************************************/
|
|
13513
13567
|
function register_c_yui_json_graph() {
|
|
13514
|
-
if (gclass_find_by_name(GCLASS_NAME$
|
|
13515
|
-
return create_gclass$
|
|
13568
|
+
if (gclass_find_by_name(GCLASS_NAME$14, false)) return 0;
|
|
13569
|
+
return create_gclass$14(GCLASS_NAME$14);
|
|
13516
13570
|
}
|
|
13517
13571
|
//#endregion
|
|
13518
13572
|
//#region src/c_yui_json.js
|
|
@@ -13577,7 +13631,7 @@ function register_c_yui_json_graph() {
|
|
|
13577
13631
|
/***************************************************************
|
|
13578
13632
|
* Constants
|
|
13579
13633
|
***************************************************************/
|
|
13580
|
-
var GCLASS_NAME$
|
|
13634
|
+
var GCLASS_NAME$13 = "C_YUI_JSON";
|
|
13581
13635
|
var MAX_RENDER_ROWS = 5e3;
|
|
13582
13636
|
var MAX_TEXT_CHARS = 2e6;
|
|
13583
13637
|
var MAX_LABEL_CHARS = 40;
|
|
@@ -13602,7 +13656,7 @@ var VIEW_MODE_STORAGE_KEY = "yui_json_view_mode";
|
|
|
13602
13656
|
/***************************************************************
|
|
13603
13657
|
* Data
|
|
13604
13658
|
***************************************************************/
|
|
13605
|
-
var attrs_table$
|
|
13659
|
+
var attrs_table$13 = [
|
|
13606
13660
|
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
13607
13661
|
SDATA(data_type_t.DTP_STRING, "title", 0, "", "Optional header title (i18n key)"),
|
|
13608
13662
|
SDATA(data_type_t.DTP_JSON, "json_data", 0, null, "Initial JSON to render (usually already collapsed)"),
|
|
@@ -13610,7 +13664,7 @@ var attrs_table$12 = [
|
|
|
13610
13664
|
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "HTMLElement root, mounted by the parent"),
|
|
13611
13665
|
SDATA_END()
|
|
13612
13666
|
];
|
|
13613
|
-
var PRIVATE_DATA$
|
|
13667
|
+
var PRIVATE_DATA$13 = {
|
|
13614
13668
|
root: null,
|
|
13615
13669
|
expanded: null,
|
|
13616
13670
|
pending: null,
|
|
@@ -13627,14 +13681,14 @@ var PRIVATE_DATA$12 = {
|
|
|
13627
13681
|
$collapse_btn: null,
|
|
13628
13682
|
$mode_btns: null
|
|
13629
13683
|
};
|
|
13630
|
-
var __gclass__$
|
|
13684
|
+
var __gclass__$13 = null;
|
|
13631
13685
|
/******************************
|
|
13632
13686
|
* Framework Methods
|
|
13633
13687
|
******************************/
|
|
13634
13688
|
/***************************************************************
|
|
13635
13689
|
* Framework Method: Create
|
|
13636
13690
|
***************************************************************/
|
|
13637
|
-
function mt_create$
|
|
13691
|
+
function mt_create$13(gobj) {
|
|
13638
13692
|
let priv = gobj.priv;
|
|
13639
13693
|
priv.expanded = /* @__PURE__ */ new Set();
|
|
13640
13694
|
priv.pending = /* @__PURE__ */ new Set();
|
|
@@ -13642,7 +13696,7 @@ function mt_create$12(gobj) {
|
|
|
13642
13696
|
priv.search = "";
|
|
13643
13697
|
let json_data = gobj_read_attr(gobj, "json_data");
|
|
13644
13698
|
if (json_data !== null && json_data !== void 0) priv.root = json_deep_copy(json_data);
|
|
13645
|
-
build_ui$
|
|
13699
|
+
build_ui$12(gobj);
|
|
13646
13700
|
resolve_initial_view_mode(gobj);
|
|
13647
13701
|
apply_view_mode$1(gobj);
|
|
13648
13702
|
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
@@ -13652,19 +13706,19 @@ function mt_create$12(gobj) {
|
|
|
13652
13706
|
/***************************************************************
|
|
13653
13707
|
* Framework Method: Start
|
|
13654
13708
|
***************************************************************/
|
|
13655
|
-
function mt_start$
|
|
13709
|
+
function mt_start$13(gobj) {
|
|
13656
13710
|
render_view$1(gobj);
|
|
13657
13711
|
}
|
|
13658
13712
|
/***************************************************************
|
|
13659
13713
|
* Framework Method: Stop
|
|
13660
13714
|
***************************************************************/
|
|
13661
|
-
function mt_stop$
|
|
13715
|
+
function mt_stop$13(gobj) {
|
|
13662
13716
|
teardown_graph_child$1(gobj);
|
|
13663
13717
|
}
|
|
13664
13718
|
/***************************************************************
|
|
13665
13719
|
* Framework Method: Destroy
|
|
13666
13720
|
***************************************************************/
|
|
13667
|
-
function mt_destroy$
|
|
13721
|
+
function mt_destroy$13(gobj) {
|
|
13668
13722
|
destroy_ui$7(gobj);
|
|
13669
13723
|
}
|
|
13670
13724
|
/***************************
|
|
@@ -13673,7 +13727,7 @@ function mt_destroy$12(gobj) {
|
|
|
13673
13727
|
/************************************************************
|
|
13674
13728
|
* Build UI
|
|
13675
13729
|
************************************************************/
|
|
13676
|
-
function build_ui$
|
|
13730
|
+
function build_ui$12(gobj) {
|
|
13677
13731
|
let priv = gobj.priv;
|
|
13678
13732
|
let $toolbar = make_toolbar$4(gobj);
|
|
13679
13733
|
let $container = createElement2([
|
|
@@ -14068,7 +14122,7 @@ function render_text(gobj) {
|
|
|
14068
14122
|
return;
|
|
14069
14123
|
}
|
|
14070
14124
|
let dump = json_text_dump(priv.root, MAX_TEXT_CHARS);
|
|
14071
|
-
if (dump.error) log_error(`${GCLASS_NAME$
|
|
14125
|
+
if (dump.error) log_error(`${GCLASS_NAME$13}: cannot dump the document as text: ${dump.error}`);
|
|
14072
14126
|
let $pre = createElement2([
|
|
14073
14127
|
"pre",
|
|
14074
14128
|
{ class: "JSON_TEXT_BODY" },
|
|
@@ -14451,7 +14505,7 @@ function ac_subtree_error(gobj, event, kw, src) {
|
|
|
14451
14505
|
let path = kw.path || "";
|
|
14452
14506
|
priv.pending.delete(path);
|
|
14453
14507
|
priv.errors.set(path, kw.error || "error");
|
|
14454
|
-
log_error(`${GCLASS_NAME$
|
|
14508
|
+
log_error(`${GCLASS_NAME$13}: subtree load failed at '${path}': ${kw.error || ""}`);
|
|
14455
14509
|
render_view$1(gobj);
|
|
14456
14510
|
return 0;
|
|
14457
14511
|
}
|
|
@@ -14526,14 +14580,14 @@ function ac_copy_all$1(gobj, event, kw, src) {
|
|
|
14526
14580
|
if (priv.root === null || priv.root === void 0) return 0;
|
|
14527
14581
|
let dump = json_text_dump(priv.root, 0);
|
|
14528
14582
|
if (dump.error) {
|
|
14529
|
-
log_error(`${GCLASS_NAME$
|
|
14583
|
+
log_error(`${GCLASS_NAME$13}: cannot copy the document: ${dump.error}`);
|
|
14530
14584
|
return -1;
|
|
14531
14585
|
}
|
|
14532
14586
|
let text = dump.text;
|
|
14533
14587
|
if (navigator.clipboard && navigator.clipboard.writeText) navigator.clipboard.writeText(text).catch(function(e) {
|
|
14534
|
-
log_error(`${GCLASS_NAME$
|
|
14588
|
+
log_error(`${GCLASS_NAME$13}: clipboard write failed: ${e}`);
|
|
14535
14589
|
});
|
|
14536
|
-
else log_error(`${GCLASS_NAME$
|
|
14590
|
+
else log_error(`${GCLASS_NAME$13}: clipboard API unavailable`);
|
|
14537
14591
|
return 0;
|
|
14538
14592
|
}
|
|
14539
14593
|
/************************************************************
|
|
@@ -14549,7 +14603,7 @@ function ac_set_view_mode$1(gobj, event, kw, src) {
|
|
|
14549
14603
|
let mode = kw.mode;
|
|
14550
14604
|
if (mode === void 0 || mode === null || mode === "") mode = VIEWS$1[(VIEWS$1.findIndex((v) => v.mode === current_view_mode$1(gobj)) + 1) % VIEWS$1.length].mode;
|
|
14551
14605
|
else if (!VIEWS$1.some((v) => v.mode === mode)) {
|
|
14552
|
-
log_error(`${GCLASS_NAME$
|
|
14606
|
+
log_error(`${GCLASS_NAME$13}: unknown view_mode '${mode}'`);
|
|
14553
14607
|
return -1;
|
|
14554
14608
|
}
|
|
14555
14609
|
if (mode === current_view_mode$1(gobj)) return 0;
|
|
@@ -14615,17 +14669,17 @@ function ac_refresh$5(gobj, event, kw, src) {
|
|
|
14615
14669
|
/***************************
|
|
14616
14670
|
* FSM
|
|
14617
14671
|
***************************/
|
|
14618
|
-
var gmt$
|
|
14619
|
-
mt_create: mt_create$
|
|
14620
|
-
mt_start: mt_start$
|
|
14621
|
-
mt_stop: mt_stop$
|
|
14622
|
-
mt_destroy: mt_destroy$
|
|
14672
|
+
var gmt$13 = {
|
|
14673
|
+
mt_create: mt_create$13,
|
|
14674
|
+
mt_start: mt_start$13,
|
|
14675
|
+
mt_stop: mt_stop$13,
|
|
14676
|
+
mt_destroy: mt_destroy$13
|
|
14623
14677
|
};
|
|
14624
14678
|
/***************************************************************
|
|
14625
14679
|
* Create the GClass
|
|
14626
14680
|
***************************************************************/
|
|
14627
|
-
function create_gclass$
|
|
14628
|
-
if (__gclass__$
|
|
14681
|
+
function create_gclass$13(gclass_name) {
|
|
14682
|
+
if (__gclass__$13) {
|
|
14629
14683
|
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
14630
14684
|
return -1;
|
|
14631
14685
|
}
|
|
@@ -14755,16 +14809,895 @@ function create_gclass$12(gclass_name) {
|
|
|
14755
14809
|
["EV_HIDE", 0],
|
|
14756
14810
|
["EV_EXPAND_PATH", event_flag_t.EVF_OUTPUT_EVENT | event_flag_t.EVF_NO_WARN_SUBS]
|
|
14757
14811
|
];
|
|
14758
|
-
__gclass__$
|
|
14759
|
-
if (!__gclass__$
|
|
14812
|
+
__gclass__$13 = gclass_create(gclass_name, event_types, states, gmt$13, 0, attrs_table$13, PRIVATE_DATA$13, 0, 0, 0, 0);
|
|
14813
|
+
if (!__gclass__$13) return -1;
|
|
14760
14814
|
return 0;
|
|
14761
14815
|
}
|
|
14762
14816
|
/***************************************************************
|
|
14763
14817
|
* Register GClass
|
|
14764
14818
|
***************************************************************/
|
|
14765
14819
|
function register_c_yui_json() {
|
|
14766
|
-
if (gclass_find_by_name(GCLASS_NAME$
|
|
14820
|
+
if (gclass_find_by_name(GCLASS_NAME$13, false)) return 0;
|
|
14767
14821
|
if (!gclass_find_by_name("C_YUI_JSON_GRAPH", false)) register_c_yui_json_graph();
|
|
14822
|
+
return create_gclass$13(GCLASS_NAME$13);
|
|
14823
|
+
}
|
|
14824
|
+
//#endregion
|
|
14825
|
+
//#region src/c_yui_json_pad.js
|
|
14826
|
+
/***********************************************************************
|
|
14827
|
+
* c_yui_json_pad.js
|
|
14828
|
+
*
|
|
14829
|
+
* C_YUI_JSON_PAD -- a pad to paste JSON from OUTSIDE and read it
|
|
14830
|
+
* with the library's own viewer, and a second one to compare it
|
|
14831
|
+
* with.
|
|
14832
|
+
*
|
|
14833
|
+
* The viewer (C_YUI_JSON: the lazy tree, the raw text and the
|
|
14834
|
+
* graph) only ever showed what an app fetched. A JSON that came
|
|
14835
|
+
* from anywhere else -- a log line, a config file, an answer copied
|
|
14836
|
+
* from a terminal -- had to be read in whatever the operator had
|
|
14837
|
+
* at hand. This is the blank page for it: paste, and read it the
|
|
14838
|
+
* way every other document of the app is read.
|
|
14839
|
+
*
|
|
14840
|
+
* Two documents are the other half of the job: the config that
|
|
14841
|
+
* works and the one that does not, a record before and after. The
|
|
14842
|
+
* second pane is there on demand ("second json"), and "compare"
|
|
14843
|
+
* puts their differences in place of the two viewers -- one row
|
|
14844
|
+
* per id of the flat form (json2flat), the form a person reads
|
|
14845
|
+
* when two configurations disagree.
|
|
14846
|
+
*
|
|
14847
|
+
* DOM (UPPER_SNAKE logical classes):
|
|
14848
|
+
*
|
|
14849
|
+
* JSON_PAD the root
|
|
14850
|
+
* JSON_PAD_TOOLBAR the notice and the two toggles
|
|
14851
|
+
* JSON_PAD_NOTICE "json not kept": the storage refused
|
|
14852
|
+
* JSON_PAD_SECOND show / hide the second pane
|
|
14853
|
+
* JSON_PAD_COMPARE show / hide the differences
|
|
14854
|
+
* JSON_PAD_PANES the panes, side by side (stacked when
|
|
14855
|
+
* the pad is narrow)
|
|
14856
|
+
* JSON_PAD_PANE JSON_PAD_PANE_A / JSON_PAD_PANE_B
|
|
14857
|
+
* JSON_PAD_BAR the text area and its two buttons
|
|
14858
|
+
* JSON_PAD_INPUT where the text goes
|
|
14859
|
+
* JSON_PAD_VIEW read what is in the text area
|
|
14860
|
+
* JSON_PAD_CLEAR empty the pane
|
|
14861
|
+
* JSON_PAD_ERROR "invalid JSON" and the parser's reason
|
|
14862
|
+
* JSON_PAD_BODY the pane's C_YUI_JSON child
|
|
14863
|
+
* JSON_PAD_DIFF the differences: JSON_PAD_DIFF_SUMMARY
|
|
14864
|
+
* and JSON_PAD_DIFF_TABLE, one
|
|
14865
|
+
* JSON_PAD_DIFF_ROW per id
|
|
14866
|
+
*
|
|
14867
|
+
* Every way in is an event, and a pane event names its pane
|
|
14868
|
+
* (`pane`: "a" or "b"):
|
|
14869
|
+
*
|
|
14870
|
+
* EV_PASTE {pane, text} a paste ANYWHERE in a pane replaces
|
|
14871
|
+
* its document and shows it at once --
|
|
14872
|
+
* a pane holds one document, not a
|
|
14873
|
+
* text to edit
|
|
14874
|
+
* EV_VIEW {pane} the text area as it is (typed, or
|
|
14875
|
+
* edited after a paste); also Ctrl+Enter
|
|
14876
|
+
* EV_CLEAR {pane} back to a blank pane
|
|
14877
|
+
* EV_TEXT_CHANGED {pane} the text area was edited: keep it
|
|
14878
|
+
* EV_TOGGLE_SECOND show / hide the second pane
|
|
14879
|
+
* EV_TOGGLE_DIFF show / hide the differences
|
|
14880
|
+
*
|
|
14881
|
+
* FSM: the states are the LAYOUT -- ST_SINGLE (one pane), ST_DUAL
|
|
14882
|
+
* (two), ST_DIFF (two, with their differences in place of the
|
|
14883
|
+
* viewers). Comparing needs two panes, so EV_TOGGLE_DIFF is not
|
|
14884
|
+
* defined in ST_SINGLE and its button is not on screen there.
|
|
14885
|
+
* EV_EXPAND_PATH, which a viewer publishes when a `__collapsed__`
|
|
14886
|
+
* sentinel is opened, is answered with EV_SUBTREE_ERROR to the
|
|
14887
|
+
* viewer that asked: a pasted document has no backend to fetch the
|
|
14888
|
+
* rest from -- the source truncated it, and the pad says so. It is
|
|
14889
|
+
* not defined in ST_DIFF, where no viewer is on screen.
|
|
14890
|
+
*
|
|
14891
|
+
* What is kept: both texts and the layout, in localStorage under
|
|
14892
|
+
* `storage_key` (empty: nothing is kept), written when a text is
|
|
14893
|
+
* pasted, viewed, cleared or edited and when the layout changes,
|
|
14894
|
+
* so the next pad opens as this one was left. localStorage is per
|
|
14895
|
+
* browser and per origin, and has a quota: a text too big for it
|
|
14896
|
+
* is not kept, the toolbar says so, and the log says why.
|
|
14897
|
+
*
|
|
14898
|
+
* Hosted by setup_json_pad() (yui_json_pad.js) in a C_YUI_WINDOW;
|
|
14899
|
+
* any host can mount `$container` itself.
|
|
14900
|
+
*
|
|
14901
|
+
* Copyright (c) 2026, ArtGins.
|
|
14902
|
+
* All Rights Reserved.
|
|
14903
|
+
***********************************************************************/
|
|
14904
|
+
/***************************************************************
|
|
14905
|
+
* Constants
|
|
14906
|
+
***************************************************************/
|
|
14907
|
+
var GCLASS_NAME$12 = "C_YUI_JSON_PAD";
|
|
14908
|
+
var PANES = ["a", "b"];
|
|
14909
|
+
var MODE_OF_STATE = {
|
|
14910
|
+
ST_SINGLE: "single",
|
|
14911
|
+
ST_DUAL: "dual",
|
|
14912
|
+
ST_DIFF: "diff"
|
|
14913
|
+
};
|
|
14914
|
+
var KIND_TAG = {
|
|
14915
|
+
added: () => [
|
|
14916
|
+
"span",
|
|
14917
|
+
{
|
|
14918
|
+
class: "tag is-success is-light",
|
|
14919
|
+
i18n: "added"
|
|
14920
|
+
},
|
|
14921
|
+
"added"
|
|
14922
|
+
],
|
|
14923
|
+
removed: () => [
|
|
14924
|
+
"span",
|
|
14925
|
+
{
|
|
14926
|
+
class: "tag is-danger is-light",
|
|
14927
|
+
i18n: "removed"
|
|
14928
|
+
},
|
|
14929
|
+
"removed"
|
|
14930
|
+
],
|
|
14931
|
+
changed: () => [
|
|
14932
|
+
"span",
|
|
14933
|
+
{
|
|
14934
|
+
class: "tag is-warning is-light",
|
|
14935
|
+
i18n: "changed"
|
|
14936
|
+
},
|
|
14937
|
+
"changed"
|
|
14938
|
+
]
|
|
14939
|
+
};
|
|
14940
|
+
/***************************************************************
|
|
14941
|
+
* Data
|
|
14942
|
+
***************************************************************/
|
|
14943
|
+
var attrs_table$12 = [
|
|
14944
|
+
SDATA(data_type_t.DTP_POINTER, "subscriber", 0, null, "Subscriber of output events"),
|
|
14945
|
+
SDATA(data_type_t.DTP_STRING, "storage_key", 0, "yui_json_pad", "localStorage key the two texts and the layout are kept under. Empty: nothing is kept"),
|
|
14946
|
+
SDATA(data_type_t.DTP_POINTER, "$container", 0, null, "HTMLElement root, mounted by the host"),
|
|
14947
|
+
SDATA_END()
|
|
14948
|
+
];
|
|
14949
|
+
var PRIVATE_DATA$12 = {
|
|
14950
|
+
panes: null,
|
|
14951
|
+
$compare: null,
|
|
14952
|
+
$notice: null,
|
|
14953
|
+
$diff: null
|
|
14954
|
+
};
|
|
14955
|
+
var __gclass__$12 = null;
|
|
14956
|
+
/******************************
|
|
14957
|
+
* Framework Methods
|
|
14958
|
+
******************************/
|
|
14959
|
+
/***************************************************************
|
|
14960
|
+
* Framework Method: Create
|
|
14961
|
+
***************************************************************/
|
|
14962
|
+
function mt_create$12(gobj) {
|
|
14963
|
+
let priv = gobj.priv;
|
|
14964
|
+
let subscriber = gobj_read_pointer_attr(gobj, "subscriber");
|
|
14965
|
+
if (!subscriber) subscriber = gobj_parent(gobj);
|
|
14966
|
+
gobj_subscribe_event(gobj, null, {}, subscriber);
|
|
14967
|
+
build_ui$11(gobj);
|
|
14968
|
+
for (const id of PANES) {
|
|
14969
|
+
let pane = priv.panes[id];
|
|
14970
|
+
pane.gobj_json = gobj_create_pure_child(`json_pad_view_${id}`, "C_YUI_JSON", {}, gobj);
|
|
14971
|
+
let $view = pane.gobj_json ? gobj_read_attr(pane.gobj_json, "$container") : null;
|
|
14972
|
+
if (!$view) {
|
|
14973
|
+
log_error(`${gobj_short_name(gobj)}: C_YUI_JSON without $container`);
|
|
14974
|
+
continue;
|
|
14975
|
+
}
|
|
14976
|
+
pane.$body.appendChild($view);
|
|
14977
|
+
}
|
|
14978
|
+
}
|
|
14979
|
+
/***************************************************************
|
|
14980
|
+
* Framework Method: Start
|
|
14981
|
+
***************************************************************/
|
|
14982
|
+
function mt_start$12(gobj) {
|
|
14983
|
+
let priv = gobj.priv;
|
|
14984
|
+
for (const id of PANES) if (priv.panes[id].gobj_json) gobj_start(priv.panes[id].gobj_json);
|
|
14985
|
+
restore_state(gobj);
|
|
14986
|
+
priv.panes.a.$input.focus();
|
|
14987
|
+
}
|
|
14988
|
+
/***************************************************************
|
|
14989
|
+
* Framework Method: Stop
|
|
14990
|
+
***************************************************************/
|
|
14991
|
+
function mt_stop$12(gobj) {
|
|
14992
|
+
let priv = gobj.priv;
|
|
14993
|
+
save_state(gobj);
|
|
14994
|
+
for (const id of PANES) {
|
|
14995
|
+
let gobj_json = priv.panes[id].gobj_json;
|
|
14996
|
+
if (gobj_json && gobj_is_running(gobj_json)) gobj_stop(gobj_json);
|
|
14997
|
+
}
|
|
14998
|
+
}
|
|
14999
|
+
/***************************************************************
|
|
15000
|
+
* Framework Method: Destroy
|
|
15001
|
+
***************************************************************/
|
|
15002
|
+
function mt_destroy$12(gobj) {}
|
|
15003
|
+
/***************************
|
|
15004
|
+
* Local Methods
|
|
15005
|
+
***************************/
|
|
15006
|
+
/***************************************************************
|
|
15007
|
+
* A button of the pad: an icon, its label, and an event.
|
|
15008
|
+
***************************************************************/
|
|
15009
|
+
function pad_button(gobj, cls, icon, key, event_name, kw) {
|
|
15010
|
+
return [
|
|
15011
|
+
"button",
|
|
15012
|
+
{
|
|
15013
|
+
class: `${cls} button`,
|
|
15014
|
+
type: "button",
|
|
15015
|
+
title: t(key),
|
|
15016
|
+
"data-i18n-title": key,
|
|
15017
|
+
"aria-label": t(key),
|
|
15018
|
+
"data-i18n-aria-label": key
|
|
15019
|
+
},
|
|
15020
|
+
[yui_toolbar_icon(icon), [
|
|
15021
|
+
"span",
|
|
15022
|
+
{
|
|
15023
|
+
style: "padding-left:5px;",
|
|
15024
|
+
i18n: key
|
|
15025
|
+
},
|
|
15026
|
+
key
|
|
15027
|
+
]],
|
|
15028
|
+
{ click: (evt) => {
|
|
15029
|
+
evt.stopPropagation();
|
|
15030
|
+
gobj_send_event(gobj, event_name, { ...kw }, gobj);
|
|
15031
|
+
} }
|
|
15032
|
+
];
|
|
15033
|
+
}
|
|
15034
|
+
/***************************************************************
|
|
15035
|
+
* The toolbar, the two panes, and the differences.
|
|
15036
|
+
***************************************************************/
|
|
15037
|
+
function build_ui$11(gobj) {
|
|
15038
|
+
let priv = gobj.priv;
|
|
15039
|
+
priv.$notice = createElement2([
|
|
15040
|
+
"div",
|
|
15041
|
+
{
|
|
15042
|
+
class: "JSON_PAD_NOTICE is-hidden has-text-danger is-size-7",
|
|
15043
|
+
role: "status"
|
|
15044
|
+
},
|
|
15045
|
+
[[
|
|
15046
|
+
"span",
|
|
15047
|
+
{
|
|
15048
|
+
style: "font-weight:600;",
|
|
15049
|
+
i18n: "json not kept"
|
|
15050
|
+
},
|
|
15051
|
+
"json not kept"
|
|
15052
|
+
]]
|
|
15053
|
+
]);
|
|
15054
|
+
priv.$compare = createElement2(pad_button(gobj, "JSON_PAD_COMPARE is-hidden", "yi-right-left", "compare", "EV_TOGGLE_DIFF", {}));
|
|
15055
|
+
priv.panes = {
|
|
15056
|
+
a: build_pane(gobj, "a", "first json"),
|
|
15057
|
+
b: build_pane(gobj, "b", "second json")
|
|
15058
|
+
};
|
|
15059
|
+
priv.panes.b.$pane.classList.add("is-hidden");
|
|
15060
|
+
priv.$diff = createElement2([
|
|
15061
|
+
"div",
|
|
15062
|
+
{ class: "JSON_PAD_DIFF is-hidden" },
|
|
15063
|
+
[]
|
|
15064
|
+
]);
|
|
15065
|
+
let $container = createElement2([
|
|
15066
|
+
"div",
|
|
15067
|
+
{ class: "C_YUI_JSON_PAD JSON_PAD" },
|
|
15068
|
+
[
|
|
15069
|
+
[
|
|
15070
|
+
"div",
|
|
15071
|
+
{ class: "JSON_PAD_TOOLBAR" },
|
|
15072
|
+
[
|
|
15073
|
+
priv.$notice,
|
|
15074
|
+
pad_button(gobj, "JSON_PAD_SECOND", "yi-columns", "second json", "EV_TOGGLE_SECOND", {}),
|
|
15075
|
+
priv.$compare
|
|
15076
|
+
]
|
|
15077
|
+
],
|
|
15078
|
+
[
|
|
15079
|
+
"div",
|
|
15080
|
+
{ class: "JSON_PAD_PANES" },
|
|
15081
|
+
[priv.panes.a.$pane, priv.panes.b.$pane]
|
|
15082
|
+
],
|
|
15083
|
+
priv.$diff
|
|
15084
|
+
]
|
|
15085
|
+
]);
|
|
15086
|
+
gobj_write_attr(gobj, "$container", $container);
|
|
15087
|
+
press_toggle(gobj, ".JSON_PAD_SECOND", false);
|
|
15088
|
+
press_toggle(gobj, ".JSON_PAD_COMPARE", false);
|
|
15089
|
+
}
|
|
15090
|
+
/***************************************************************
|
|
15091
|
+
* One pane: the text area and its buttons, the error line, and
|
|
15092
|
+
* the body its viewer is mounted in. `name_key` names the pane
|
|
15093
|
+
* for a reader (its text area's title and aria-label).
|
|
15094
|
+
***************************************************************/
|
|
15095
|
+
function build_pane(gobj, id, name_key) {
|
|
15096
|
+
let pane = {
|
|
15097
|
+
$pane: null,
|
|
15098
|
+
$input: null,
|
|
15099
|
+
$error: null,
|
|
15100
|
+
$reason: null,
|
|
15101
|
+
$body: null,
|
|
15102
|
+
gobj_json: null,
|
|
15103
|
+
doc: null,
|
|
15104
|
+
has_doc: false
|
|
15105
|
+
};
|
|
15106
|
+
pane.$input = createElement2([
|
|
15107
|
+
"textarea",
|
|
15108
|
+
{
|
|
15109
|
+
class: "JSON_PAD_INPUT textarea",
|
|
15110
|
+
rows: 3,
|
|
15111
|
+
spellcheck: "false",
|
|
15112
|
+
placeholder: t("paste json here"),
|
|
15113
|
+
"data-i18n-placeholder": "paste json here",
|
|
15114
|
+
title: t(name_key),
|
|
15115
|
+
"data-i18n-title": name_key,
|
|
15116
|
+
"aria-label": t(name_key),
|
|
15117
|
+
"data-i18n-aria-label": name_key,
|
|
15118
|
+
style: "font-family:monospace; resize:vertical; min-height:4.5em;"
|
|
15119
|
+
},
|
|
15120
|
+
"",
|
|
15121
|
+
{
|
|
15122
|
+
keydown: (evt) => {
|
|
15123
|
+
if ((evt.ctrlKey || evt.metaKey) && evt.key === "Enter") {
|
|
15124
|
+
evt.preventDefault();
|
|
15125
|
+
gobj_send_event(gobj, "EV_VIEW", { pane: id }, gobj);
|
|
15126
|
+
}
|
|
15127
|
+
},
|
|
15128
|
+
change: () => {
|
|
15129
|
+
gobj_send_event(gobj, "EV_TEXT_CHANGED", { pane: id }, gobj);
|
|
15130
|
+
}
|
|
15131
|
+
}
|
|
15132
|
+
]);
|
|
15133
|
+
pane.$reason = createElement2([
|
|
15134
|
+
"span",
|
|
15135
|
+
{
|
|
15136
|
+
class: "JSON_PAD_ERROR_REASON",
|
|
15137
|
+
style: "margin-left:.5em; font-family:monospace;"
|
|
15138
|
+
},
|
|
15139
|
+
""
|
|
15140
|
+
]);
|
|
15141
|
+
pane.$error = createElement2([
|
|
15142
|
+
"div",
|
|
15143
|
+
{
|
|
15144
|
+
class: "JSON_PAD_ERROR is-hidden has-text-danger is-size-7",
|
|
15145
|
+
role: "alert"
|
|
15146
|
+
},
|
|
15147
|
+
[[
|
|
15148
|
+
"span",
|
|
15149
|
+
{
|
|
15150
|
+
class: "JSON_PAD_ERROR_LABEL",
|
|
15151
|
+
style: "font-weight:600;",
|
|
15152
|
+
i18n: "invalid json"
|
|
15153
|
+
},
|
|
15154
|
+
"invalid json"
|
|
15155
|
+
], pane.$reason]
|
|
15156
|
+
]);
|
|
15157
|
+
pane.$body = createElement2([
|
|
15158
|
+
"div",
|
|
15159
|
+
{
|
|
15160
|
+
class: "JSON_PAD_BODY",
|
|
15161
|
+
style: "flex:1 1 auto; min-height:0; display:flex; flex-direction:column;"
|
|
15162
|
+
},
|
|
15163
|
+
[]
|
|
15164
|
+
]);
|
|
15165
|
+
pane.$pane = createElement2([
|
|
15166
|
+
"div",
|
|
15167
|
+
{ class: `JSON_PAD_PANE JSON_PAD_PANE_${id.toUpperCase()}` },
|
|
15168
|
+
[
|
|
15169
|
+
[
|
|
15170
|
+
"div",
|
|
15171
|
+
{
|
|
15172
|
+
class: "JSON_PAD_BAR",
|
|
15173
|
+
style: "display:flex; gap:.5rem; align-items:flex-start;"
|
|
15174
|
+
},
|
|
15175
|
+
[[
|
|
15176
|
+
"div",
|
|
15177
|
+
{ style: "flex:1 1 auto; min-width:0;" },
|
|
15178
|
+
[pane.$input]
|
|
15179
|
+
], [
|
|
15180
|
+
"div",
|
|
15181
|
+
{ style: "flex:0 0 auto; display:flex; flex-direction:column; gap:.5rem;" },
|
|
15182
|
+
[pad_button(gobj, "JSON_PAD_VIEW", "yi-eye", "view", "EV_VIEW", { pane: id }), pad_button(gobj, "JSON_PAD_CLEAR", "yi-broom", "clear", "EV_CLEAR", { pane: id })]
|
|
15183
|
+
]]
|
|
15184
|
+
],
|
|
15185
|
+
pane.$error,
|
|
15186
|
+
pane.$body
|
|
15187
|
+
],
|
|
15188
|
+
{ paste: (evt) => {
|
|
15189
|
+
let text = evt.clipboardData ? evt.clipboardData.getData("text") : "";
|
|
15190
|
+
if (!text) return;
|
|
15191
|
+
evt.preventDefault();
|
|
15192
|
+
gobj_send_event(gobj, "EV_PASTE", {
|
|
15193
|
+
pane: id,
|
|
15194
|
+
text
|
|
15195
|
+
}, gobj);
|
|
15196
|
+
} }
|
|
15197
|
+
]);
|
|
15198
|
+
return pane;
|
|
15199
|
+
}
|
|
15200
|
+
/***************************************************************
|
|
15201
|
+
* The pane a pane event names.
|
|
15202
|
+
***************************************************************/
|
|
15203
|
+
function pane_of(gobj, kw) {
|
|
15204
|
+
let priv = gobj.priv;
|
|
15205
|
+
let id = kw ? kw.pane : void 0;
|
|
15206
|
+
if (!PANES.includes(id)) {
|
|
15207
|
+
log_error(`${gobj_short_name(gobj)}: no pane '${id}'`);
|
|
15208
|
+
return null;
|
|
15209
|
+
}
|
|
15210
|
+
return priv.panes[id];
|
|
15211
|
+
}
|
|
15212
|
+
/***************************************************************
|
|
15213
|
+
* A toggle of the toolbar, pressed or not -- for the eye and
|
|
15214
|
+
* for a reader.
|
|
15215
|
+
***************************************************************/
|
|
15216
|
+
function press_toggle(gobj, selector, on) {
|
|
15217
|
+
let $container = gobj_read_attr(gobj, "$container");
|
|
15218
|
+
set_pressed_state($container, selector, on);
|
|
15219
|
+
$container.querySelectorAll(selector).forEach(($el) => {
|
|
15220
|
+
$el.setAttribute("aria-pressed", on ? "true" : "false");
|
|
15221
|
+
});
|
|
15222
|
+
}
|
|
15223
|
+
/***************************************************************
|
|
15224
|
+
* Read `text` as JSON and show it in `pane`, or say why it is
|
|
15225
|
+
* not. A text that is not JSON leaves the last document up.
|
|
15226
|
+
***************************************************************/
|
|
15227
|
+
function show_text(gobj, pane, text) {
|
|
15228
|
+
let src = String(text || "").trim();
|
|
15229
|
+
if (!src) {
|
|
15230
|
+
clear_pane(gobj, pane, false);
|
|
15231
|
+
return 0;
|
|
15232
|
+
}
|
|
15233
|
+
let doc;
|
|
15234
|
+
try {
|
|
15235
|
+
doc = JSON.parse(src);
|
|
15236
|
+
} catch (e) {
|
|
15237
|
+
log_warning(`${gobj_short_name(gobj)}: the pasted text is not JSON: ${e.message}`);
|
|
15238
|
+
pane.$reason.textContent = e.message;
|
|
15239
|
+
pane.$error.classList.remove("is-hidden");
|
|
15240
|
+
return -1;
|
|
15241
|
+
}
|
|
15242
|
+
pane.$error.classList.add("is-hidden");
|
|
15243
|
+
pane.$reason.textContent = "";
|
|
15244
|
+
pane.doc = doc;
|
|
15245
|
+
pane.has_doc = true;
|
|
15246
|
+
gobj_send_event(pane.gobj_json, "EV_SET_JSON", { json: doc }, gobj);
|
|
15247
|
+
return 0;
|
|
15248
|
+
}
|
|
15249
|
+
/***************************************************************
|
|
15250
|
+
* A blank pane again; `with_text` empties the text area too.
|
|
15251
|
+
***************************************************************/
|
|
15252
|
+
function clear_pane(gobj, pane, with_text) {
|
|
15253
|
+
if (with_text) pane.$input.value = "";
|
|
15254
|
+
pane.$error.classList.add("is-hidden");
|
|
15255
|
+
pane.$reason.textContent = "";
|
|
15256
|
+
pane.doc = null;
|
|
15257
|
+
pane.has_doc = false;
|
|
15258
|
+
gobj_send_event(pane.gobj_json, "EV_SET_JSON", { json: null }, gobj);
|
|
15259
|
+
}
|
|
15260
|
+
/***************************************************************
|
|
15261
|
+
* A pane changed its document: the differences follow it, and
|
|
15262
|
+
* the texts are kept.
|
|
15263
|
+
***************************************************************/
|
|
15264
|
+
function document_changed(gobj) {
|
|
15265
|
+
if (gobj_current_state(gobj) === "ST_DIFF") render_diff(gobj);
|
|
15266
|
+
save_state(gobj);
|
|
15267
|
+
}
|
|
15268
|
+
/***************************************************************
|
|
15269
|
+
* Enter one of the three layouts. The state IS the layout;
|
|
15270
|
+
* this is what the screen shows for it.
|
|
15271
|
+
***************************************************************/
|
|
15272
|
+
function enter_layout(gobj, state) {
|
|
15273
|
+
let priv = gobj.priv;
|
|
15274
|
+
let $container = gobj_read_attr(gobj, "$container");
|
|
15275
|
+
let second = state !== "ST_SINGLE";
|
|
15276
|
+
let diff = state === "ST_DIFF";
|
|
15277
|
+
gobj_change_state(gobj, state);
|
|
15278
|
+
priv.panes.b.$pane.classList.toggle("is-hidden", !second);
|
|
15279
|
+
priv.$compare.classList.toggle("is-hidden", !second);
|
|
15280
|
+
press_toggle(gobj, ".JSON_PAD_SECOND", second);
|
|
15281
|
+
press_toggle(gobj, ".JSON_PAD_COMPARE", diff);
|
|
15282
|
+
$container.classList.toggle("is-comparing", diff);
|
|
15283
|
+
for (const id of PANES) priv.panes[id].$body.classList.toggle("is-hidden", diff);
|
|
15284
|
+
priv.$diff.classList.toggle("is-hidden", !diff);
|
|
15285
|
+
if (diff) render_diff(gobj);
|
|
15286
|
+
else for (const id of PANES) {
|
|
15287
|
+
if (id === "b" && !second) continue;
|
|
15288
|
+
gobj_send_event(priv.panes[id].gobj_json, "EV_REFRESH", {}, gobj);
|
|
15289
|
+
}
|
|
15290
|
+
save_state(gobj);
|
|
15291
|
+
}
|
|
15292
|
+
/***************************************************************
|
|
15293
|
+
* The differences of the two documents, in place of the two
|
|
15294
|
+
* viewers. Only a pane that shows a document takes part: a
|
|
15295
|
+
* text that is not JSON leaves its last document, as on screen.
|
|
15296
|
+
***************************************************************/
|
|
15297
|
+
function render_diff(gobj) {
|
|
15298
|
+
let priv = gobj.priv;
|
|
15299
|
+
let a = priv.panes.a;
|
|
15300
|
+
let b = priv.panes.b;
|
|
15301
|
+
priv.$diff.replaceChildren();
|
|
15302
|
+
if (!a.has_doc || !b.has_doc) {
|
|
15303
|
+
priv.$diff.appendChild(createElement2([
|
|
15304
|
+
"p",
|
|
15305
|
+
{
|
|
15306
|
+
class: "JSON_PAD_DIFF_MESSAGE",
|
|
15307
|
+
i18n: "compare needs two json"
|
|
15308
|
+
},
|
|
15309
|
+
"compare needs two json"
|
|
15310
|
+
]));
|
|
15311
|
+
return 0;
|
|
15312
|
+
}
|
|
15313
|
+
let rows;
|
|
15314
|
+
try {
|
|
15315
|
+
rows = json_diff_rows(a.doc, b.doc);
|
|
15316
|
+
} catch (e) {
|
|
15317
|
+
log_warning(`${gobj_short_name(gobj)}: cannot compare: ${e.message}`);
|
|
15318
|
+
priv.$diff.appendChild(createElement2([
|
|
15319
|
+
"p",
|
|
15320
|
+
{ class: "JSON_PAD_DIFF_MESSAGE has-text-danger" },
|
|
15321
|
+
[[
|
|
15322
|
+
"span",
|
|
15323
|
+
{
|
|
15324
|
+
style: "font-weight:600;",
|
|
15325
|
+
i18n: "cannot compare"
|
|
15326
|
+
},
|
|
15327
|
+
"cannot compare"
|
|
15328
|
+
], [
|
|
15329
|
+
"span",
|
|
15330
|
+
{
|
|
15331
|
+
class: "JSON_PAD_DIFF_REASON",
|
|
15332
|
+
style: "margin-left:.5em; font-family:monospace;"
|
|
15333
|
+
},
|
|
15334
|
+
e.message
|
|
15335
|
+
]]
|
|
15336
|
+
]));
|
|
15337
|
+
return -1;
|
|
15338
|
+
}
|
|
15339
|
+
if (rows.length === 0) {
|
|
15340
|
+
priv.$diff.appendChild(createElement2([
|
|
15341
|
+
"p",
|
|
15342
|
+
{
|
|
15343
|
+
class: "JSON_PAD_DIFF_MESSAGE has-text-success",
|
|
15344
|
+
i18n: "no differences"
|
|
15345
|
+
},
|
|
15346
|
+
"no differences"
|
|
15347
|
+
]));
|
|
15348
|
+
return 0;
|
|
15349
|
+
}
|
|
15350
|
+
let count = {
|
|
15351
|
+
added: 0,
|
|
15352
|
+
removed: 0,
|
|
15353
|
+
changed: 0
|
|
15354
|
+
};
|
|
15355
|
+
for (const row of rows) count[row.kind]++;
|
|
15356
|
+
let value_cell = (cls, row, side) => {
|
|
15357
|
+
let has = Object.prototype.hasOwnProperty.call(row, side);
|
|
15358
|
+
return [
|
|
15359
|
+
"td",
|
|
15360
|
+
{ class: cls },
|
|
15361
|
+
has ? JSON.stringify(row[side]) : ""
|
|
15362
|
+
];
|
|
15363
|
+
};
|
|
15364
|
+
priv.$diff.appendChild(createElement2([
|
|
15365
|
+
"div",
|
|
15366
|
+
{ class: "JSON_PAD_DIFF_SUMMARY" },
|
|
15367
|
+
[
|
|
15368
|
+
"removed",
|
|
15369
|
+
"added",
|
|
15370
|
+
"changed"
|
|
15371
|
+
].map((kind) => {
|
|
15372
|
+
return [
|
|
15373
|
+
"span",
|
|
15374
|
+
{ class: "JSON_PAD_DIFF_COUNT" },
|
|
15375
|
+
[KIND_TAG[kind](), [
|
|
15376
|
+
"strong",
|
|
15377
|
+
{},
|
|
15378
|
+
String(count[kind])
|
|
15379
|
+
]]
|
|
15380
|
+
];
|
|
15381
|
+
})
|
|
15382
|
+
]));
|
|
15383
|
+
priv.$diff.appendChild(createElement2([
|
|
15384
|
+
"table",
|
|
15385
|
+
{ class: "JSON_PAD_DIFF_TABLE table is-fullwidth is-narrow is-hoverable" },
|
|
15386
|
+
[[
|
|
15387
|
+
"thead",
|
|
15388
|
+
{},
|
|
15389
|
+
[[
|
|
15390
|
+
"tr",
|
|
15391
|
+
{},
|
|
15392
|
+
[
|
|
15393
|
+
[
|
|
15394
|
+
"th",
|
|
15395
|
+
{},
|
|
15396
|
+
""
|
|
15397
|
+
],
|
|
15398
|
+
[
|
|
15399
|
+
"th",
|
|
15400
|
+
{ i18n: "path" },
|
|
15401
|
+
"path"
|
|
15402
|
+
],
|
|
15403
|
+
[
|
|
15404
|
+
"th",
|
|
15405
|
+
{ i18n: "first json" },
|
|
15406
|
+
"first json"
|
|
15407
|
+
],
|
|
15408
|
+
[
|
|
15409
|
+
"th",
|
|
15410
|
+
{ i18n: "second json" },
|
|
15411
|
+
"second json"
|
|
15412
|
+
]
|
|
15413
|
+
]
|
|
15414
|
+
]]
|
|
15415
|
+
], [
|
|
15416
|
+
"tbody",
|
|
15417
|
+
{},
|
|
15418
|
+
rows.map((row) => {
|
|
15419
|
+
return [
|
|
15420
|
+
"tr",
|
|
15421
|
+
{ class: `JSON_PAD_DIFF_ROW JSON_PAD_DIFF_${row.kind.toUpperCase()}` },
|
|
15422
|
+
[
|
|
15423
|
+
[
|
|
15424
|
+
"td",
|
|
15425
|
+
{},
|
|
15426
|
+
[KIND_TAG[row.kind]()]
|
|
15427
|
+
],
|
|
15428
|
+
[
|
|
15429
|
+
"td",
|
|
15430
|
+
{ class: "JSON_PAD_DIFF_PATH" },
|
|
15431
|
+
row.id
|
|
15432
|
+
],
|
|
15433
|
+
value_cell("JSON_PAD_DIFF_FROM", row, "from"),
|
|
15434
|
+
value_cell("JSON_PAD_DIFF_TO", row, "to")
|
|
15435
|
+
]
|
|
15436
|
+
];
|
|
15437
|
+
})
|
|
15438
|
+
]]
|
|
15439
|
+
]));
|
|
15440
|
+
return 0;
|
|
15441
|
+
}
|
|
15442
|
+
/***************************************************************
|
|
15443
|
+
* Keep both texts and the layout.
|
|
15444
|
+
***************************************************************/
|
|
15445
|
+
function save_state(gobj) {
|
|
15446
|
+
let priv = gobj.priv;
|
|
15447
|
+
let key = gobj_read_str_attr(gobj, "storage_key");
|
|
15448
|
+
if (!key) return 0;
|
|
15449
|
+
let ret = kw_set_local_storage_value(key, {
|
|
15450
|
+
a: priv.panes.a.$input.value,
|
|
15451
|
+
b: priv.panes.b.$input.value,
|
|
15452
|
+
mode: MODE_OF_STATE[gobj_current_state(gobj)] || "single"
|
|
15453
|
+
});
|
|
15454
|
+
priv.$notice.classList.toggle("is-hidden", ret === 0);
|
|
15455
|
+
return ret;
|
|
15456
|
+
}
|
|
15457
|
+
/***************************************************************
|
|
15458
|
+
* The pad as the last one was left: its texts, shown, and its
|
|
15459
|
+
* layout -- through the same events a reader would send.
|
|
15460
|
+
***************************************************************/
|
|
15461
|
+
function restore_state(gobj) {
|
|
15462
|
+
let priv = gobj.priv;
|
|
15463
|
+
let key = gobj_read_str_attr(gobj, "storage_key");
|
|
15464
|
+
if (!key) return 0;
|
|
15465
|
+
let kept = kw_get_local_storage_value(key, null, false);
|
|
15466
|
+
if (kept === null || kept === void 0) return 0;
|
|
15467
|
+
if (typeof kept !== "object" || Array.isArray(kept)) {
|
|
15468
|
+
log_warning(`${gobj_short_name(gobj)}: '${key}' in localStorage is not what the pad keeps`);
|
|
15469
|
+
return -1;
|
|
15470
|
+
}
|
|
15471
|
+
for (const id of PANES) if (typeof kept[id] === "string") priv.panes[id].$input.value = kept[id];
|
|
15472
|
+
for (const id of PANES) if (priv.panes[id].$input.value.trim()) gobj_send_event(gobj, "EV_VIEW", { pane: id }, gobj);
|
|
15473
|
+
if (kept.mode === "dual" || kept.mode === "diff") gobj_send_event(gobj, "EV_TOGGLE_SECOND", {}, gobj);
|
|
15474
|
+
if (kept.mode === "diff") gobj_send_event(gobj, "EV_TOGGLE_DIFF", {}, gobj);
|
|
15475
|
+
return 0;
|
|
15476
|
+
}
|
|
15477
|
+
/***************************
|
|
15478
|
+
* Actions
|
|
15479
|
+
***************************/
|
|
15480
|
+
/***************************************************************
|
|
15481
|
+
* A paste: it becomes the pane's text area and its document
|
|
15482
|
+
* at once.
|
|
15483
|
+
***************************************************************/
|
|
15484
|
+
function ac_paste(gobj, event, kw, src) {
|
|
15485
|
+
let pane = pane_of(gobj, kw);
|
|
15486
|
+
if (!pane) return -1;
|
|
15487
|
+
let text = typeof kw.text === "string" ? kw.text : "";
|
|
15488
|
+
pane.$input.value = text;
|
|
15489
|
+
let ret = show_text(gobj, pane, text);
|
|
15490
|
+
document_changed(gobj);
|
|
15491
|
+
return ret;
|
|
15492
|
+
}
|
|
15493
|
+
/***************************************************************
|
|
15494
|
+
* The pane's text area as it is now.
|
|
15495
|
+
***************************************************************/
|
|
15496
|
+
function ac_view(gobj, event, kw, src) {
|
|
15497
|
+
let pane = pane_of(gobj, kw);
|
|
15498
|
+
if (!pane) return -1;
|
|
15499
|
+
let ret = show_text(gobj, pane, pane.$input.value);
|
|
15500
|
+
document_changed(gobj);
|
|
15501
|
+
return ret;
|
|
15502
|
+
}
|
|
15503
|
+
/***************************************************************
|
|
15504
|
+
* A blank pane again.
|
|
15505
|
+
***************************************************************/
|
|
15506
|
+
function ac_clear(gobj, event, kw, src) {
|
|
15507
|
+
let pane = pane_of(gobj, kw);
|
|
15508
|
+
if (!pane) return -1;
|
|
15509
|
+
clear_pane(gobj, pane, true);
|
|
15510
|
+
pane.$input.focus();
|
|
15511
|
+
document_changed(gobj);
|
|
15512
|
+
return 0;
|
|
15513
|
+
}
|
|
15514
|
+
/***************************************************************
|
|
15515
|
+
* A text area was edited and left: keep what it holds. What
|
|
15516
|
+
* is SHOWN changes only with a view, as before.
|
|
15517
|
+
***************************************************************/
|
|
15518
|
+
function ac_text_changed(gobj, event, kw, src) {
|
|
15519
|
+
if (!pane_of(gobj, kw)) return -1;
|
|
15520
|
+
save_state(gobj);
|
|
15521
|
+
return 0;
|
|
15522
|
+
}
|
|
15523
|
+
/***************************************************************
|
|
15524
|
+
* The second pane, beside the first.
|
|
15525
|
+
***************************************************************/
|
|
15526
|
+
function ac_show_second(gobj, event, kw, src) {
|
|
15527
|
+
let priv = gobj.priv;
|
|
15528
|
+
enter_layout(gobj, "ST_DUAL");
|
|
15529
|
+
priv.panes.b.$input.focus();
|
|
15530
|
+
return 0;
|
|
15531
|
+
}
|
|
15532
|
+
/***************************************************************
|
|
15533
|
+
* One pane again. Its text is kept: hiding is not clearing.
|
|
15534
|
+
***************************************************************/
|
|
15535
|
+
function ac_hide_second(gobj, event, kw, src) {
|
|
15536
|
+
enter_layout(gobj, "ST_SINGLE");
|
|
15537
|
+
return 0;
|
|
15538
|
+
}
|
|
15539
|
+
/***************************************************************
|
|
15540
|
+
* The differences, in place of the viewers.
|
|
15541
|
+
***************************************************************/
|
|
15542
|
+
function ac_show_diff(gobj, event, kw, src) {
|
|
15543
|
+
enter_layout(gobj, "ST_DIFF");
|
|
15544
|
+
return 0;
|
|
15545
|
+
}
|
|
15546
|
+
/***************************************************************
|
|
15547
|
+
* The viewers again.
|
|
15548
|
+
***************************************************************/
|
|
15549
|
+
function ac_hide_diff(gobj, event, kw, src) {
|
|
15550
|
+
enter_layout(gobj, "ST_DUAL");
|
|
15551
|
+
return 0;
|
|
15552
|
+
}
|
|
15553
|
+
/***************************************************************
|
|
15554
|
+
* A viewer asks for a `__collapsed__` subtree. A pasted
|
|
15555
|
+
* document has no backend to ask for it: the SOURCE truncated
|
|
15556
|
+
* it, and that is the answer, to the viewer that asked.
|
|
15557
|
+
***************************************************************/
|
|
15558
|
+
function ac_expand_path(gobj, event, kw, src) {
|
|
15559
|
+
gobj_send_event(src, "EV_SUBTREE_ERROR", {
|
|
15560
|
+
path: kw && kw.path || "",
|
|
15561
|
+
error: t("collapsed in the source")
|
|
15562
|
+
}, gobj);
|
|
15563
|
+
return 0;
|
|
15564
|
+
}
|
|
15565
|
+
/***************************************************************
|
|
15566
|
+
* FSM
|
|
15567
|
+
***************************************************************/
|
|
15568
|
+
var gmt$12 = {
|
|
15569
|
+
mt_create: mt_create$12,
|
|
15570
|
+
mt_start: mt_start$12,
|
|
15571
|
+
mt_stop: mt_stop$12,
|
|
15572
|
+
mt_destroy: mt_destroy$12
|
|
15573
|
+
};
|
|
15574
|
+
/***************************************************************
|
|
15575
|
+
* Create the GClass
|
|
15576
|
+
***************************************************************/
|
|
15577
|
+
function create_gclass$12(gclass_name) {
|
|
15578
|
+
if (__gclass__$12) {
|
|
15579
|
+
log_error(`GClass ALREADY created: ${gclass_name}`);
|
|
15580
|
+
return -1;
|
|
15581
|
+
}
|
|
15582
|
+
__gclass__$12 = gclass_create(gclass_name, [
|
|
15583
|
+
["EV_PASTE", 0],
|
|
15584
|
+
["EV_VIEW", 0],
|
|
15585
|
+
["EV_CLEAR", 0],
|
|
15586
|
+
["EV_TEXT_CHANGED", 0],
|
|
15587
|
+
["EV_TOGGLE_SECOND", 0],
|
|
15588
|
+
["EV_TOGGLE_DIFF", 0],
|
|
15589
|
+
["EV_EXPAND_PATH", 0]
|
|
15590
|
+
], [
|
|
15591
|
+
["ST_SINGLE", [
|
|
15592
|
+
[
|
|
15593
|
+
"EV_PASTE",
|
|
15594
|
+
ac_paste,
|
|
15595
|
+
null
|
|
15596
|
+
],
|
|
15597
|
+
[
|
|
15598
|
+
"EV_VIEW",
|
|
15599
|
+
ac_view,
|
|
15600
|
+
null
|
|
15601
|
+
],
|
|
15602
|
+
[
|
|
15603
|
+
"EV_CLEAR",
|
|
15604
|
+
ac_clear,
|
|
15605
|
+
null
|
|
15606
|
+
],
|
|
15607
|
+
[
|
|
15608
|
+
"EV_TEXT_CHANGED",
|
|
15609
|
+
ac_text_changed,
|
|
15610
|
+
null
|
|
15611
|
+
],
|
|
15612
|
+
[
|
|
15613
|
+
"EV_TOGGLE_SECOND",
|
|
15614
|
+
ac_show_second,
|
|
15615
|
+
null
|
|
15616
|
+
],
|
|
15617
|
+
[
|
|
15618
|
+
"EV_EXPAND_PATH",
|
|
15619
|
+
ac_expand_path,
|
|
15620
|
+
null
|
|
15621
|
+
]
|
|
15622
|
+
]],
|
|
15623
|
+
["ST_DUAL", [
|
|
15624
|
+
[
|
|
15625
|
+
"EV_PASTE",
|
|
15626
|
+
ac_paste,
|
|
15627
|
+
null
|
|
15628
|
+
],
|
|
15629
|
+
[
|
|
15630
|
+
"EV_VIEW",
|
|
15631
|
+
ac_view,
|
|
15632
|
+
null
|
|
15633
|
+
],
|
|
15634
|
+
[
|
|
15635
|
+
"EV_CLEAR",
|
|
15636
|
+
ac_clear,
|
|
15637
|
+
null
|
|
15638
|
+
],
|
|
15639
|
+
[
|
|
15640
|
+
"EV_TEXT_CHANGED",
|
|
15641
|
+
ac_text_changed,
|
|
15642
|
+
null
|
|
15643
|
+
],
|
|
15644
|
+
[
|
|
15645
|
+
"EV_TOGGLE_SECOND",
|
|
15646
|
+
ac_hide_second,
|
|
15647
|
+
null
|
|
15648
|
+
],
|
|
15649
|
+
[
|
|
15650
|
+
"EV_TOGGLE_DIFF",
|
|
15651
|
+
ac_show_diff,
|
|
15652
|
+
null
|
|
15653
|
+
],
|
|
15654
|
+
[
|
|
15655
|
+
"EV_EXPAND_PATH",
|
|
15656
|
+
ac_expand_path,
|
|
15657
|
+
null
|
|
15658
|
+
]
|
|
15659
|
+
]],
|
|
15660
|
+
["ST_DIFF", [
|
|
15661
|
+
[
|
|
15662
|
+
"EV_PASTE",
|
|
15663
|
+
ac_paste,
|
|
15664
|
+
null
|
|
15665
|
+
],
|
|
15666
|
+
[
|
|
15667
|
+
"EV_VIEW",
|
|
15668
|
+
ac_view,
|
|
15669
|
+
null
|
|
15670
|
+
],
|
|
15671
|
+
[
|
|
15672
|
+
"EV_CLEAR",
|
|
15673
|
+
ac_clear,
|
|
15674
|
+
null
|
|
15675
|
+
],
|
|
15676
|
+
[
|
|
15677
|
+
"EV_TEXT_CHANGED",
|
|
15678
|
+
ac_text_changed,
|
|
15679
|
+
null
|
|
15680
|
+
],
|
|
15681
|
+
[
|
|
15682
|
+
"EV_TOGGLE_SECOND",
|
|
15683
|
+
ac_hide_second,
|
|
15684
|
+
null
|
|
15685
|
+
],
|
|
15686
|
+
[
|
|
15687
|
+
"EV_TOGGLE_DIFF",
|
|
15688
|
+
ac_hide_diff,
|
|
15689
|
+
null
|
|
15690
|
+
]
|
|
15691
|
+
]]
|
|
15692
|
+
], gmt$12, 0, attrs_table$12, PRIVATE_DATA$12, 0, 0, 0, 0);
|
|
15693
|
+
if (!__gclass__$12) return -1;
|
|
15694
|
+
return 0;
|
|
15695
|
+
}
|
|
15696
|
+
/***************************************************************
|
|
15697
|
+
* Register GClass
|
|
15698
|
+
***************************************************************/
|
|
15699
|
+
function register_c_yui_json_pad() {
|
|
15700
|
+
if (!gclass_find_by_name("C_YUI_JSON", false)) register_c_yui_json();
|
|
14768
15701
|
return create_gclass$12(GCLASS_NAME$12);
|
|
14769
15702
|
}
|
|
14770
15703
|
//#endregion
|
|
@@ -21343,7 +22276,7 @@ function register_c_yui_nav() {
|
|
|
21343
22276
|
}
|
|
21344
22277
|
//#endregion
|
|
21345
22278
|
//#region src/shell_route_map.js
|
|
21346
|
-
var WIN_NAME$
|
|
22279
|
+
var WIN_NAME$2 = "shell-route-map-window";
|
|
21347
22280
|
var __show_refs__ = true;
|
|
21348
22281
|
var __open_modal__ = null;
|
|
21349
22282
|
function scroll_to_current($body) {
|
|
@@ -21683,7 +22616,7 @@ function mark_current_row($body, hash, t) {
|
|
|
21683
22616
|
***************************************************************/
|
|
21684
22617
|
function yui_shell_show_route_map(shell, opts) {
|
|
21685
22618
|
let t = opts && opts.t || i18next.t.bind(i18next);
|
|
21686
|
-
let existing = gobj_find_service(WIN_NAME$
|
|
22619
|
+
let existing = gobj_find_service(WIN_NAME$2, false);
|
|
21687
22620
|
if (existing && is_gobj(existing)) {
|
|
21688
22621
|
gobj_send_event(existing, "EV_CLOSE_WINDOW", {}, shell);
|
|
21689
22622
|
return null;
|
|
@@ -21698,7 +22631,7 @@ function yui_shell_show_route_map(shell, opts) {
|
|
|
21698
22631
|
let win_ref = { gobj: null };
|
|
21699
22632
|
let $body = build_body(shell, t);
|
|
21700
22633
|
let $parent = yui_shell_popup_layer(shell) || typeof document !== "undefined" && document.getElementById("top-layer") || null;
|
|
21701
|
-
let win = gobj_create_service(WIN_NAME$
|
|
22634
|
+
let win = gobj_create_service(WIN_NAME$2, "C_YUI_WINDOW", {
|
|
21702
22635
|
$parent,
|
|
21703
22636
|
subscriber: null,
|
|
21704
22637
|
modal: false,
|
|
@@ -25396,6 +26329,14 @@ function create_tabulator(gobj) {
|
|
|
25396
26329
|
let remembered_size = load_page_size(gobj);
|
|
25397
26330
|
if (remembered_size !== null && tabulator_settings.pagination) tabulator_settings.paginationSize = remembered_size;
|
|
25398
26331
|
gobj.priv._page_size = tabulator_settings.paginationSize;
|
|
26332
|
+
let pkey_col = columns.find((c) => c && c.field === pkey);
|
|
26333
|
+
if (pkey_col && !tabulator_settings.initialSort && !gobj_read_bool_attr(gobj, "with_remote_paging")) {
|
|
26334
|
+
if (!pkey_col.sorter) pkey_col.sorter = "alphanum";
|
|
26335
|
+
tabulator_settings.initialSort = [{
|
|
26336
|
+
column: pkey,
|
|
26337
|
+
dir: "asc"
|
|
26338
|
+
}];
|
|
26339
|
+
}
|
|
25399
26340
|
Object.assign(tabulator_settings, {
|
|
25400
26341
|
index: pkey,
|
|
25401
26342
|
columns,
|
|
@@ -74568,7 +75509,7 @@ function build_dev_panel() {
|
|
|
74568
75509
|
* Copyright (c) 2026, ArtGins.
|
|
74569
75510
|
* All Rights Reserved.
|
|
74570
75511
|
***********************************************************************/
|
|
74571
|
-
var WIN_NAME = "Frontend-View-Window";
|
|
75512
|
+
var WIN_NAME$1 = "Frontend-View-Window";
|
|
74572
75513
|
/******************************
|
|
74573
75514
|
* Public API
|
|
74574
75515
|
******************************/
|
|
@@ -74585,7 +75526,7 @@ var WIN_NAME = "Frontend-View-Window";
|
|
|
74585
75526
|
* Returns the window gobj, or null.
|
|
74586
75527
|
************************************************************/
|
|
74587
75528
|
function setup_frontend_view(self) {
|
|
74588
|
-
if (gobj_find_service(WIN_NAME, false)) return null;
|
|
75529
|
+
if (gobj_find_service(WIN_NAME$1, false)) return null;
|
|
74589
75530
|
let $body = createElement2([
|
|
74590
75531
|
"div",
|
|
74591
75532
|
{
|
|
@@ -74594,7 +75535,7 @@ function setup_frontend_view(self) {
|
|
|
74594
75535
|
},
|
|
74595
75536
|
[]
|
|
74596
75537
|
]);
|
|
74597
|
-
let win = gobj_create_service(WIN_NAME, "C_YUI_WINDOW", {
|
|
75538
|
+
let win = gobj_create_service(WIN_NAME$1, "C_YUI_WINDOW", {
|
|
74598
75539
|
$parent: typeof document !== "undefined" && document.getElementById("top-layer") || null,
|
|
74599
75540
|
subscriber: null,
|
|
74600
75541
|
modal: false,
|
|
@@ -74626,6 +75567,75 @@ function setup_frontend_view(self) {
|
|
|
74626
75567
|
return win;
|
|
74627
75568
|
}
|
|
74628
75569
|
//#endregion
|
|
74629
|
-
|
|
75570
|
+
//#region src/yui_json_pad.js
|
|
75571
|
+
/***********************************************************************
|
|
75572
|
+
* yui_json_pad.js
|
|
75573
|
+
*
|
|
75574
|
+
* JSON viewer -- a blank C_YUI_JSON_PAD in a floating window,
|
|
75575
|
+
* to paste JSON from outside and read it with the library's own
|
|
75576
|
+
* viewer. Peer of the frontend view (yui_frontend_view.js), and
|
|
75577
|
+
* opened the same way: an entry of the account menu.
|
|
75578
|
+
*
|
|
75579
|
+
* Copyright (c) 2026, ArtGins.
|
|
75580
|
+
* All Rights Reserved.
|
|
75581
|
+
***********************************************************************/
|
|
75582
|
+
var WIN_NAME = "Json-Viewer-Window";
|
|
75583
|
+
/******************************
|
|
75584
|
+
* Public API
|
|
75585
|
+
******************************/
|
|
75586
|
+
/************************************************************
|
|
75587
|
+
* Open a blank JSON pad (C_YUI_JSON_PAD) inside a non-modal
|
|
75588
|
+
* C_YUI_WINDOW, the same shape as the frontend view.
|
|
75589
|
+
*
|
|
75590
|
+
* Self-contained: it registers C_YUI_JSON_PAD (and the
|
|
75591
|
+
* C_YUI_JSON it hosts) if the app did not, so an app gets the
|
|
75592
|
+
* viewer with one menu entry and one action.
|
|
75593
|
+
*
|
|
75594
|
+
* Returns the window gobj, or null.
|
|
75595
|
+
************************************************************/
|
|
75596
|
+
function setup_json_pad(self) {
|
|
75597
|
+
if (gobj_find_service(WIN_NAME, false)) return null;
|
|
75598
|
+
if (!gclass_find_by_name("C_YUI_JSON_PAD", false)) register_c_yui_json_pad();
|
|
75599
|
+
let $body = createElement2([
|
|
75600
|
+
"div",
|
|
75601
|
+
{
|
|
75602
|
+
class: "YJSONPAD_BODY",
|
|
75603
|
+
style: "height:100%; display:flex; flex-direction:column;"
|
|
75604
|
+
},
|
|
75605
|
+
[]
|
|
75606
|
+
]);
|
|
75607
|
+
let win = gobj_create_service(WIN_NAME, "C_YUI_WINDOW", {
|
|
75608
|
+
$parent: typeof document !== "undefined" && document.getElementById("top-layer") || null,
|
|
75609
|
+
subscriber: null,
|
|
75610
|
+
modal: false,
|
|
75611
|
+
showMax: true,
|
|
75612
|
+
showFooter: false,
|
|
75613
|
+
resizable: true,
|
|
75614
|
+
center: false,
|
|
75615
|
+
auto_save_size_and_position: true,
|
|
75616
|
+
width: 900,
|
|
75617
|
+
height: 640,
|
|
75618
|
+
logical_class: "JSON_VIEWER_WINDOW",
|
|
75619
|
+
title: "json viewer",
|
|
75620
|
+
icon: "yi-code",
|
|
75621
|
+
body: $body,
|
|
75622
|
+
manager: gobj_find_service("__window_manager__", false) || null
|
|
75623
|
+
}, self);
|
|
75624
|
+
if (!win) {
|
|
75625
|
+
log_error("yui_json_pad: cannot create the json-viewer window");
|
|
75626
|
+
return null;
|
|
75627
|
+
}
|
|
75628
|
+
let pad = gobj_create_pure_child("json_pad", "C_YUI_JSON_PAD", {}, win);
|
|
75629
|
+
let $pad = pad ? gobj_read_attr(pad, "$container") : null;
|
|
75630
|
+
if (!$pad) {
|
|
75631
|
+
log_error("yui_json_pad: C_YUI_JSON_PAD without $container");
|
|
75632
|
+
return win;
|
|
75633
|
+
}
|
|
75634
|
+
$body.appendChild($pad);
|
|
75635
|
+
gobj_start_tree(win);
|
|
75636
|
+
return win;
|
|
75637
|
+
}
|
|
75638
|
+
//#endregion
|
|
75639
|
+
export { EditControl, MarkerControl, YUI_FILE_ACCEPT, YUI_PERIODS, YUI_PERIODS_DEFAULT, YUI_ROLLING, addClasses, apply_dev_traces, attach_clear, build_dev_panel, dev_window_was_open, disableElements, enableElements, epoch_to_local_input, epoch_to_ms, expose_view_container, fmt_epoch, getStrokeColor, infer_period, info_traffic, inject_svg_icons, is_current_period, iso_week, local_input_to_epoch, ms_to_epoch, period_bounds, period_bounds_epoch, period_label, period_name, period_shift, period_spec, period_start, refresh_clear, register_c_g6_nodes_tree, register_c_yui_form, register_c_yui_fsm_graph, register_c_yui_gclass, register_c_yui_gobj_tree_js, register_c_yui_json, register_c_yui_json_graph, register_c_yui_json_pad, register_c_yui_map, register_c_yui_nav, register_c_yui_pager, register_c_yui_period, register_c_yui_schema_editor, register_c_yui_service_view, register_c_yui_shell, register_c_yui_treedb_graph, register_c_yui_treedb_schema, register_c_yui_treedb_topic_with_form, register_c_yui_treedb_topics, register_c_yui_uplot, register_c_yui_window, register_c_yui_window_manager, register_c_yui_wizard, removeChildElements, removeClasses, rolling_bounds, safe_locale, set_active_state, set_cancel_state, set_pressed_state, set_submit_state, setup_dev, setup_frontend_view, setup_json_pad, toggleClasses, yui_array_buffer_to_base64, yui_asset_element, yui_asset_id, yui_asset_ids, yui_asset_missing, yui_asset_src, yui_file_control, yui_file_id_label, yui_file_read, yui_file_sha256, yui_file_size_label, yui_files_manifest, yui_is_dark, yui_mount_service_view, yui_shell_close_drawer, yui_shell_close_dropdown, yui_shell_confirm_danger, yui_shell_confirm_ok, yui_shell_confirm_yesno, yui_shell_confirm_yesnocancel, yui_shell_navigate, yui_shell_open_drawer, yui_shell_overlay_dismissed, yui_shell_pop_escape, yui_shell_push_escape, yui_shell_refresh_avatars, yui_shell_register_event_handler, yui_shell_register_overlay, yui_shell_set_avatar_provider, yui_shell_set_connection_state, yui_shell_set_sub_routes, yui_shell_set_toolbar_item_badge, yui_shell_set_toolbar_item_icon, yui_shell_set_translator, yui_shell_show_error, yui_shell_show_info, yui_shell_show_modal, yui_shell_show_route_map, yui_shell_show_warning, yui_shell_toggle_drawer, yui_shell_unpark_route, yui_theme_now, yui_toolbar, yui_watch_theme };
|
|
74630
75640
|
|
|
74631
75641
|
//# sourceMappingURL=gobj-ui.es.js.map
|