@xuda.io/runtime-bundle 1.0.1419 → 1.0.1420
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/js/xuda-runtime-bundle.js +21 -8
- package/js/xuda-runtime-bundle.min.js +1 -1
- package/js/xuda-runtime-slim.js +21 -8
- package/js/xuda-runtime-slim.min.es.js +21 -8
- package/js/xuda-runtime-slim.min.js +2 -2
- package/js/xuda-server-bundle.min.mjs +1 -1
- package/js/xuda-server-bundle.mjs +2 -4
- package/js/xuda-worker-bundle.js +2 -4
- package/js/xuda-worker-bundle.min.js +1 -1
- package/package.json +1 -1
|
@@ -28079,6 +28079,9 @@ func.runtime.ui.get_meta = function (xu_ui_id, key) {
|
|
|
28079
28079
|
return key ? entry[key] : entry;
|
|
28080
28080
|
};
|
|
28081
28081
|
func.runtime.ui.delete_meta = function (xu_ui_id) {
|
|
28082
|
+
if (func.runtime.ui._meta_store[xu_ui_id]) {
|
|
28083
|
+
console.info('[xu-render-debug] delete_meta called for', xu_ui_id, new Error().stack?.split('\n').slice(1, 4).join(' <- '));
|
|
28084
|
+
}
|
|
28082
28085
|
delete func.runtime.ui._meta_store[xu_ui_id];
|
|
28083
28086
|
// clean reverse lookup
|
|
28084
28087
|
for (const id in func.runtime.ui._element_id_to_xu_ui_id) {
|
|
@@ -30511,6 +30514,7 @@ func.UI.worker.execute = async function (SESSION_ID, queue_obj) {
|
|
|
30511
30514
|
const perf_end = func.runtime?.perf?.start?.(SESSION_ID, 'execute_xu_render_attributes');
|
|
30512
30515
|
const live_context = fx.get_live_element_context(queue_obj.paramsP?.elem_key, queue_obj.elementP || queue_obj.paramsP?.elem_val?.$elm, queue_obj.paramsP);
|
|
30513
30516
|
const _data = live_context.data;
|
|
30517
|
+
console.info('[xu-render-debug] execute_xu_render_attributes', { elem_key: queue_obj.paramsP?.elem_key, has_live_elm: !!live_context.$elm?.length, has_data: !!_data, has_xuData: !!_data?.xuData, has_paramsP: !!_data?.xuData?.paramsP, attr_value: queue_obj.paramsP?.attr_value, elm_tag: func.runtime.ui.get_first_node(live_context.$elm)?.tagName, data_keys: Object.keys(_data || {}), xuData_keys: Object.keys(_data?.xuData || {}) });
|
|
30514
30518
|
try {
|
|
30515
30519
|
if (_data?.xuData?.paramsP) {
|
|
30516
30520
|
const live_xu_data = _data.xuData;
|
|
@@ -33762,6 +33766,7 @@ func.runtime.ui.refresh_xu_attributes = async function (options) {
|
|
|
33762
33766
|
const attr_value = await func.common.get_cast_val(options.SESSION_ID, 'refresh xu-attributes', 'xu-render', 'bool', res.result);
|
|
33763
33767
|
|
|
33764
33768
|
const _elm_node = func.runtime.ui.get_first_node($elm);
|
|
33769
|
+
console.info('[xu-render-debug] refresh has_xu_exp_render', { elem_key, attr_value, elm_tag: _elm_node?.tagName, exp_value: xuAttributes['xu-exp:xu-render'], result: res.result });
|
|
33765
33770
|
if (!attr_value && _elm_node?.tagName === 'XURENDER') continue;
|
|
33766
33771
|
|
|
33767
33772
|
if (attr_value && _elm_node?.tagName !== 'XURENDER') {
|
|
@@ -36657,6 +36662,8 @@ func.runtime.widgets = func.runtime.widgets || {};
|
|
|
36657
36662
|
|
|
36658
36663
|
func.runtime.render.handle_legacy_xu_render = async function (options) {
|
|
36659
36664
|
const value = await func.common.get_cast_val(options.SESSION_ID, 'common fx', 'xu-render', 'bool', options.val.value);
|
|
36665
|
+
const _xu_ui_id_dbg = func.runtime.ui.get_attr(options.$elm, 'xu-ui-id');
|
|
36666
|
+
console.info('[xu-render-debug] handle_legacy_xu_render called', { value, is_init: options.is_init, xu_ui_id: _xu_ui_id_dbg, elm_tag: func.runtime.ui.get_first_node(options.$elm)?.tagName });
|
|
36660
36667
|
|
|
36661
36668
|
const init_render = function () {
|
|
36662
36669
|
if (!value) {
|
|
@@ -36675,11 +36682,9 @@ func.runtime.render.handle_legacy_xu_render = async function (options) {
|
|
|
36675
36682
|
const snapshot_xuAttributes = options.nodeP.attributes || {};
|
|
36676
36683
|
const xu_ui_id = func.runtime.ui.get_attr(options.$elm, 'xu-ui-id');
|
|
36677
36684
|
|
|
36685
|
+
console.info('[xu-render-debug] init_render hiding', { xu_ui_id, has_snapshot_xuData: !!snapshot_xuData, has_paramsP: !!snapshot_xuData?.paramsP, has_original_data_obj: !!original_data_obj, snapshot_xuAttributes_keys: Object.keys(snapshot_xuAttributes) });
|
|
36686
|
+
|
|
36678
36687
|
// Remove original element from DOM WITHOUT deleting _meta_store.
|
|
36679
|
-
// Using func.runtime.ui.remove() would call delete_meta(xu_ui_id),
|
|
36680
|
-
// wiping the meta entry before create_xu_render_placeholder can write it.
|
|
36681
|
-
// The XURENDER placeholder reuses the same xu-ui-id, so the meta entry
|
|
36682
|
-
// will be overwritten below — no orphaned data.
|
|
36683
36688
|
const _elm_node = func.runtime.ui.get_first_node(options.$elm);
|
|
36684
36689
|
if (_elm_node?.remove) {
|
|
36685
36690
|
_elm_node.remove();
|
|
@@ -36694,6 +36699,10 @@ func.runtime.render.handle_legacy_xu_render = async function (options) {
|
|
|
36694
36699
|
xuAttributes: snapshot_xuAttributes,
|
|
36695
36700
|
});
|
|
36696
36701
|
|
|
36702
|
+
// Verify data was written correctly
|
|
36703
|
+
const verify_meta = func.runtime.ui._meta_store[xu_ui_id];
|
|
36704
|
+
console.info('[xu-render-debug] init_render DONE', { xu_ui_id, meta_exists: !!verify_meta, has_xuData: !!verify_meta?.xuData, has_paramsP: !!verify_meta?.xuData?.paramsP, has_original_data_obj: !!verify_meta?.xuData?.original_data_obj, has_xuAttributes: !!verify_meta?.xuAttributes });
|
|
36705
|
+
|
|
36697
36706
|
return { abort: true };
|
|
36698
36707
|
}
|
|
36699
36708
|
return {};
|
|
@@ -36725,12 +36734,18 @@ func.runtime.render.handle_legacy_xu_render = async function (options) {
|
|
|
36725
36734
|
if (value) {
|
|
36726
36735
|
try {
|
|
36727
36736
|
const elm_node = func.runtime.ui.get_first_node(options.$elm);
|
|
36737
|
+
const _post_xu_ui_id = func.runtime.ui.get_attr(options.$elm, 'xu-ui-id');
|
|
36738
|
+
const _post_meta = func.runtime.ui._meta_store[_post_xu_ui_id];
|
|
36739
|
+
const _post_data = func.runtime.ui.get_data(options.$elm);
|
|
36740
|
+
console.info('[xu-render-debug] post_render value=true', { xu_ui_id: _post_xu_ui_id, elm_tag: elm_node?.tagName, meta_exists: !!_post_meta, has_xuData: !!_post_data?.xuData, has_paramsP: !!_post_data?.xuData?.paramsP, has_original_data_obj: !!_post_data?.xuData?.original_data_obj, xuData_keys: Object.keys(_post_data?.xuData || {}), data_keys: Object.keys(_post_data || {}) });
|
|
36728
36741
|
if (elm_node?.tagName !== 'XURENDER' && elm_node) {
|
|
36742
|
+
console.info('[xu-render-debug] post_render SKIP: not XURENDER tag', elm_node?.tagName);
|
|
36729
36743
|
return func.events.delete_job(options.SESSION_ID, options.jobNoP);
|
|
36730
36744
|
}
|
|
36731
36745
|
|
|
36732
36746
|
const original_data_obj = func.runtime.ui.get_data(options.$elm).xuData.original_data_obj;
|
|
36733
36747
|
if (!original_data_obj) {
|
|
36748
|
+
console.info('[xu-render-debug] post_render SKIP: no original_data_obj');
|
|
36734
36749
|
func.events.delete_job(options.SESSION_ID, options.jobNoP);
|
|
36735
36750
|
return { delete_job: options.jobNoP };
|
|
36736
36751
|
}
|
|
@@ -37639,10 +37654,8 @@ func.datasource.create = async function (
|
|
|
37639
37654
|
|
|
37640
37655
|
var run_at = _prog_obj?.properties?.runAt;
|
|
37641
37656
|
|
|
37642
|
-
if (
|
|
37643
|
-
|
|
37644
|
-
run_at = 'client';
|
|
37645
|
-
}
|
|
37657
|
+
if (_session.opt.app_computing_mode === 'main') {
|
|
37658
|
+
run_at = 'client';
|
|
37646
37659
|
}
|
|
37647
37660
|
|
|
37648
37661
|
if (_prog_obj?.properties.menuType === 'globals') {
|