@xuda.io/runtime-bundle 1.0.1102 → 1.0.1104
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-slim.js
CHANGED
|
@@ -11614,17 +11614,22 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
11614
11614
|
|
|
11615
11615
|
const add_execute_queue = async function (type) {
|
|
11616
11616
|
if (!elem_val.$elm?.data?.()?.xuData) return;
|
|
11617
|
-
|
|
11618
|
-
|
|
11619
|
-
|
|
11620
|
-
|
|
11621
|
-
|
|
11622
|
-
|
|
11623
|
-
|
|
11624
|
-
|
|
11617
|
+
try {
|
|
11618
|
+
const obj = {
|
|
11619
|
+
ui_type: elem_val.$elm.data().xuData.ui_type,
|
|
11620
|
+
SESSION_ID,
|
|
11621
|
+
fields_arr,
|
|
11622
|
+
elem_key,
|
|
11623
|
+
elem_val,
|
|
11624
|
+
};
|
|
11625
11625
|
|
|
11626
|
-
|
|
11627
|
-
|
|
11626
|
+
new_job = await func.UI.worker.add_to_queue(SESSION_ID, 'gui event', type, obj, new_job, elem_val.$elm);
|
|
11627
|
+
|
|
11628
|
+
if (glb.DEBUG_MODE) {
|
|
11629
|
+
console.log(type + '>>>', new_job, obj);
|
|
11630
|
+
}
|
|
11631
|
+
} catch (error) {
|
|
11632
|
+
debugger;
|
|
11628
11633
|
}
|
|
11629
11634
|
};
|
|
11630
11635
|
//////////// process render first ///////////////
|
|
@@ -12195,31 +12200,59 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
12195
12200
|
},
|
|
12196
12201
|
[`xu-teleport`]: {
|
|
12197
12202
|
to: async function ($elm, val) {
|
|
12198
|
-
if (
|
|
12199
|
-
if (
|
|
12200
|
-
|
|
12201
|
-
|
|
12202
|
-
|
|
12203
|
-
|
|
12204
|
-
|
|
12205
|
-
|
|
12206
|
-
|
|
12207
|
-
|
|
12208
|
-
} else {
|
|
12209
|
-
$elm.data('xuTeleportData', []).attr('hidden', true);
|
|
12210
|
-
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
12211
|
-
const $to_container = $(val.value);
|
|
12212
|
-
if (!$to_container?.length) {
|
|
12213
|
-
return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
12203
|
+
if (!glb.new_xu_render) {
|
|
12204
|
+
if (val.value) {
|
|
12205
|
+
// parent_infoP.is_xu_teleport;
|
|
12206
|
+
if ($elm?.parent()?.data()?.xuData?.length) {
|
|
12207
|
+
$elm.parent().data('xuTeleportData', []);
|
|
12208
|
+
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
12209
|
+
const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $(val.value), node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
12210
|
+
|
|
12211
|
+
$elm.parent().data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
12212
|
+
$teleport_elm.attr('xu-teleport-parent-id', $elm.parent().attr('xu-ui-id'));
|
|
12214
12213
|
}
|
|
12215
|
-
|
|
12214
|
+
$elm.remove();
|
|
12215
|
+
} else {
|
|
12216
|
+
$elm.data('xuTeleportData', []).attr('hidden', true);
|
|
12217
|
+
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
12218
|
+
const $to_container = $(val.value);
|
|
12219
|
+
if (!$to_container?.length) {
|
|
12220
|
+
return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
12221
|
+
}
|
|
12222
|
+
const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $to_container, node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
12216
12223
|
|
|
12217
|
-
|
|
12218
|
-
|
|
12224
|
+
$elm.data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
12225
|
+
$teleport_elm.attr('xu-teleport-parent-id', $elm.attr('xu-ui-id'));
|
|
12226
|
+
}
|
|
12219
12227
|
}
|
|
12220
12228
|
}
|
|
12229
|
+
return { abort: true };
|
|
12221
12230
|
}
|
|
12222
|
-
|
|
12231
|
+
|
|
12232
|
+
if (val.value) {
|
|
12233
|
+
// // parent_infoP.is_xu_teleport;
|
|
12234
|
+
// if ($elm?.parent()?.data()?.xuData?.length) {
|
|
12235
|
+
// $elm.parent().data('xuTeleportData', []);
|
|
12236
|
+
// for (const [key, node] of Object.entries(nodeP.children)) {
|
|
12237
|
+
// const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $(val.value), node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
12238
|
+
// $elm.parent().data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
12239
|
+
// $teleport_elm.attr('xu-teleport-parent-id', $elm.parent().attr('xu-ui-id'));
|
|
12240
|
+
// }
|
|
12241
|
+
// $elm.remove();
|
|
12242
|
+
// } else {
|
|
12243
|
+
// $elm.data('xuTeleportData', []).attr('hidden', true);
|
|
12244
|
+
// for (const [key, node] of Object.entries(nodeP.children)) {
|
|
12245
|
+
// const $to_container = $(val.value);
|
|
12246
|
+
// if (!$to_container?.length) {
|
|
12247
|
+
// return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
12248
|
+
// }
|
|
12249
|
+
// const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $to_container, node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
12250
|
+
// $elm.data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
12251
|
+
// $teleport_elm.attr('xu-teleport-parent-id', $elm.attr('xu-ui-id'));
|
|
12252
|
+
// }
|
|
12253
|
+
// }
|
|
12254
|
+
}
|
|
12255
|
+
return {};
|
|
12223
12256
|
},
|
|
12224
12257
|
'xu-render': async function ($elm, val) {
|
|
12225
12258
|
let ret = await common_fx['xu-render']($elm, val, true);
|
|
@@ -9339,17 +9339,22 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
9339
9339
|
|
|
9340
9340
|
const add_execute_queue = async function (type) {
|
|
9341
9341
|
if (!elem_val.$elm?.data?.()?.xuData) return;
|
|
9342
|
-
|
|
9343
|
-
|
|
9344
|
-
|
|
9345
|
-
|
|
9346
|
-
|
|
9347
|
-
|
|
9348
|
-
|
|
9349
|
-
|
|
9342
|
+
try {
|
|
9343
|
+
const obj = {
|
|
9344
|
+
ui_type: elem_val.$elm.data().xuData.ui_type,
|
|
9345
|
+
SESSION_ID,
|
|
9346
|
+
fields_arr,
|
|
9347
|
+
elem_key,
|
|
9348
|
+
elem_val,
|
|
9349
|
+
};
|
|
9350
9350
|
|
|
9351
|
-
|
|
9352
|
-
|
|
9351
|
+
new_job = await func.UI.worker.add_to_queue(SESSION_ID, 'gui event', type, obj, new_job, elem_val.$elm);
|
|
9352
|
+
|
|
9353
|
+
if (glb.DEBUG_MODE) {
|
|
9354
|
+
console.log(type + '>>>', new_job, obj);
|
|
9355
|
+
}
|
|
9356
|
+
} catch (error) {
|
|
9357
|
+
debugger;
|
|
9353
9358
|
}
|
|
9354
9359
|
};
|
|
9355
9360
|
//////////// process render first ///////////////
|
|
@@ -9920,31 +9925,59 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
9920
9925
|
},
|
|
9921
9926
|
[`xu-teleport`]: {
|
|
9922
9927
|
to: async function ($elm, val) {
|
|
9923
|
-
if (
|
|
9924
|
-
if (
|
|
9925
|
-
|
|
9926
|
-
|
|
9927
|
-
|
|
9928
|
-
|
|
9929
|
-
|
|
9930
|
-
|
|
9931
|
-
|
|
9932
|
-
|
|
9933
|
-
} else {
|
|
9934
|
-
$elm.data('xuTeleportData', []).attr('hidden', true);
|
|
9935
|
-
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
9936
|
-
const $to_container = $(val.value);
|
|
9937
|
-
if (!$to_container?.length) {
|
|
9938
|
-
return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
9928
|
+
if (!glb.new_xu_render) {
|
|
9929
|
+
if (val.value) {
|
|
9930
|
+
// parent_infoP.is_xu_teleport;
|
|
9931
|
+
if ($elm?.parent()?.data()?.xuData?.length) {
|
|
9932
|
+
$elm.parent().data('xuTeleportData', []);
|
|
9933
|
+
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
9934
|
+
const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $(val.value), node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
9935
|
+
|
|
9936
|
+
$elm.parent().data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
9937
|
+
$teleport_elm.attr('xu-teleport-parent-id', $elm.parent().attr('xu-ui-id'));
|
|
9939
9938
|
}
|
|
9940
|
-
|
|
9939
|
+
$elm.remove();
|
|
9940
|
+
} else {
|
|
9941
|
+
$elm.data('xuTeleportData', []).attr('hidden', true);
|
|
9942
|
+
for (const [key, node] of Object.entries(nodeP.children)) {
|
|
9943
|
+
const $to_container = $(val.value);
|
|
9944
|
+
if (!$to_container?.length) {
|
|
9945
|
+
return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
9946
|
+
}
|
|
9947
|
+
const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $to_container, node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
9941
9948
|
|
|
9942
|
-
|
|
9943
|
-
|
|
9949
|
+
$elm.data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
9950
|
+
$teleport_elm.attr('xu-teleport-parent-id', $elm.attr('xu-ui-id'));
|
|
9951
|
+
}
|
|
9944
9952
|
}
|
|
9945
9953
|
}
|
|
9954
|
+
return { abort: true };
|
|
9946
9955
|
}
|
|
9947
|
-
|
|
9956
|
+
|
|
9957
|
+
if (val.value) {
|
|
9958
|
+
// // parent_infoP.is_xu_teleport;
|
|
9959
|
+
// if ($elm?.parent()?.data()?.xuData?.length) {
|
|
9960
|
+
// $elm.parent().data('xuTeleportData', []);
|
|
9961
|
+
// for (const [key, node] of Object.entries(nodeP.children)) {
|
|
9962
|
+
// const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $(val.value), node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
9963
|
+
// $elm.parent().data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
9964
|
+
// $teleport_elm.attr('xu-teleport-parent-id', $elm.parent().attr('xu-ui-id'));
|
|
9965
|
+
// }
|
|
9966
|
+
// $elm.remove();
|
|
9967
|
+
// } else {
|
|
9968
|
+
// $elm.data('xuTeleportData', []).attr('hidden', true);
|
|
9969
|
+
// for (const [key, node] of Object.entries(nodeP.children)) {
|
|
9970
|
+
// const $to_container = $(val.value);
|
|
9971
|
+
// if (!$to_container?.length) {
|
|
9972
|
+
// return console.error(`container ${val.value} for xuTeleportData not found`);
|
|
9973
|
+
// }
|
|
9974
|
+
// const $teleport_elm = await func.UI.screen.render_ui_tree(SESSION_ID, $to_container, node, parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, node, null, $root_container);
|
|
9975
|
+
// $elm.data().xuTeleportData.push($teleport_elm.attr('xu-ui-id'));
|
|
9976
|
+
// $teleport_elm.attr('xu-teleport-parent-id', $elm.attr('xu-ui-id'));
|
|
9977
|
+
// }
|
|
9978
|
+
// }
|
|
9979
|
+
}
|
|
9980
|
+
return {};
|
|
9948
9981
|
},
|
|
9949
9982
|
'xu-render': async function ($elm, val) {
|
|
9950
9983
|
let ret = await common_fx['xu-render']($elm, val, true);
|