@xuda.io/runtime-bundle 1.0.830 → 1.0.832
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 +145 -121
- package/js/xuda-runtime-bundle.min.js +1 -1
- package/js/xuda-runtime-slim.js +146 -122
- package/js/xuda-runtime-slim.min.es.js +146 -122
- package/js/xuda-runtime-slim.min.js +1 -1
- package/package.json +1 -1
|
@@ -27848,7 +27848,7 @@ func.UI.worker.execute = async function (SESSION_ID, queue_obj) {
|
|
|
27848
27848
|
render_viewport: async function () {
|
|
27849
27849
|
const { nodeP, $div, parent_infoP, $root_container, jobNoP, is_skeleton, paramsP, $container } = queue_obj?.paramsP || {};
|
|
27850
27850
|
if (nodeP?.children?.length) {
|
|
27851
|
-
func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
27851
|
+
// func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
27852
27852
|
// setTimeout(async () => {
|
|
27853
27853
|
for await (const [key, val] of Object.entries(nodeP.children)) {
|
|
27854
27854
|
const ret = await func.UI.screen.render_ui_tree(SESSION_ID, $div, nodeP.children[key], parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, nodeP, null, $root_container);
|
|
@@ -27856,9 +27856,9 @@ func.UI.worker.execute = async function (SESSION_ID, queue_obj) {
|
|
|
27856
27856
|
// return func.UI.worker.delete_job(SESSION_ID, queue_obj.job_num);
|
|
27857
27857
|
// }, 1000);
|
|
27858
27858
|
}
|
|
27859
|
-
setTimeout(async () => {
|
|
27860
|
-
|
|
27861
|
-
}, 10000);
|
|
27859
|
+
// setTimeout(async () => {
|
|
27860
|
+
return func.UI.worker.delete_job(SESSION_ID, queue_obj.job_num);
|
|
27861
|
+
// }, 10000);
|
|
27862
27862
|
},
|
|
27863
27863
|
};
|
|
27864
27864
|
|
|
@@ -34229,12 +34229,12 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34229
34229
|
|
|
34230
34230
|
$div.hover(
|
|
34231
34231
|
function (e) {
|
|
34232
|
-
|
|
34233
|
-
func.UI.screen.hover_in(SESSION_ID, null, $container, paramsP, is_skeleton);
|
|
34232
|
+
hover_in();
|
|
34233
|
+
// func.UI.screen.hover_in(SESSION_ID, null, $container, paramsP, is_skeleton);
|
|
34234
34234
|
},
|
|
34235
34235
|
function (e) {
|
|
34236
|
-
func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
34237
|
-
|
|
34236
|
+
// func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
34237
|
+
hover_out();
|
|
34238
34238
|
},
|
|
34239
34239
|
);
|
|
34240
34240
|
}
|
|
@@ -34393,12 +34393,12 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34393
34393
|
|
|
34394
34394
|
$div.hover(
|
|
34395
34395
|
function (e) {
|
|
34396
|
-
|
|
34397
|
-
func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
34396
|
+
hover_in($div);
|
|
34397
|
+
// func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
34398
34398
|
},
|
|
34399
34399
|
function (e) {
|
|
34400
|
-
func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
34401
|
-
|
|
34400
|
+
// func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
34401
|
+
hover_out();
|
|
34402
34402
|
},
|
|
34403
34403
|
);
|
|
34404
34404
|
|
|
@@ -34406,7 +34406,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34406
34406
|
if (ret.abort || nodeP.tagName === 'svg') return await done();
|
|
34407
34407
|
// check if iterator made to prevent children render
|
|
34408
34408
|
|
|
34409
|
-
const
|
|
34409
|
+
const observer_inViewport = new IntersectionObserver(
|
|
34410
34410
|
function (entries) {
|
|
34411
34411
|
entries.forEach((entry) => {
|
|
34412
34412
|
if (entry.isIntersecting) {
|
|
@@ -34417,7 +34417,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34417
34417
|
$(entry.target).trigger('inViewport');
|
|
34418
34418
|
|
|
34419
34419
|
// Optional: stop observing once triggered
|
|
34420
|
-
|
|
34420
|
+
observer_inViewport.unobserve(entry.target);
|
|
34421
34421
|
}
|
|
34422
34422
|
});
|
|
34423
34423
|
},
|
|
@@ -34426,6 +34426,23 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34426
34426
|
},
|
|
34427
34427
|
);
|
|
34428
34428
|
|
|
34429
|
+
const observer_outViewport = new IntersectionObserver(
|
|
34430
|
+
function (entries) {
|
|
34431
|
+
entries.forEach((entry) => {
|
|
34432
|
+
if (!entry.isIntersecting) {
|
|
34433
|
+
// Element is OUT of viewport - trigger custom event
|
|
34434
|
+
$(entry.target).trigger('outViewport');
|
|
34435
|
+
|
|
34436
|
+
// Optional: stop observing once triggered
|
|
34437
|
+
observer_outViewport.unobserve(entry.target);
|
|
34438
|
+
}
|
|
34439
|
+
});
|
|
34440
|
+
},
|
|
34441
|
+
{
|
|
34442
|
+
threshold: 0, // Trigger when element is completely out of view
|
|
34443
|
+
},
|
|
34444
|
+
);
|
|
34445
|
+
|
|
34429
34446
|
// const render_child = async function () {
|
|
34430
34447
|
// await iterate_child($div, nodeP, parent_infoP, $root_container);
|
|
34431
34448
|
// };
|
|
@@ -34434,13 +34451,20 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34434
34451
|
// console.log('on>>', 'inViewport_' + $div.attr('xu-ui-id'));
|
|
34435
34452
|
// $div.on('inViewport_' + $div.attr('xu-ui-id'), function () {
|
|
34436
34453
|
$div.on('inViewport', function () {
|
|
34437
|
-
|
|
34454
|
+
hover_in($div);
|
|
34455
|
+
// func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
34438
34456
|
func.UI.worker.add_to_queue(SESSION_ID, 'gui event', 'render_viewport', { $div, nodeP, parent_infoP, $root_container, paramsP, jobNoP, is_skeleton, keyP, refreshed_ds, parent_nodeP, check_existP, $container }, null, null, paramsP.dsSessionP);
|
|
34439
34457
|
// render_child();
|
|
34440
34458
|
// iterate_child($div, nodeP, parent_infoP, null, $root_container);
|
|
34441
34459
|
});
|
|
34442
34460
|
|
|
34443
|
-
|
|
34461
|
+
$div.on('outViewport', function () {
|
|
34462
|
+
$div.empty();
|
|
34463
|
+
observer_inViewport.observe($div[0]);
|
|
34464
|
+
});
|
|
34465
|
+
|
|
34466
|
+
observer_inViewport.observe($div[0]);
|
|
34467
|
+
observer_outViewport.observe($div[0]);
|
|
34444
34468
|
} else {
|
|
34445
34469
|
// await render_child();
|
|
34446
34470
|
await iterate_child($div, nodeP, parent_infoP, $root_container);
|
|
@@ -34492,127 +34516,127 @@ func.UI.screen.refresh_document_changes_for_realtime_update = async function (SE
|
|
|
34492
34516
|
}
|
|
34493
34517
|
};
|
|
34494
34518
|
|
|
34495
|
-
func.UI.screen.hover_in = function (SESSION_ID, $div, $container, paramsP, is_skeleton) {
|
|
34496
|
-
|
|
34519
|
+
// func.UI.screen.hover_in = function (SESSION_ID, $div, $container, paramsP, is_skeleton) {
|
|
34520
|
+
// if (is_skeleton || EXP_BUSY) return;
|
|
34497
34521
|
|
|
34498
|
-
|
|
34499
|
-
|
|
34522
|
+
// var _session = SESSION_OBJ[SESSION_ID];
|
|
34523
|
+
// var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
34500
34524
|
|
|
34501
|
-
|
|
34502
|
-
|
|
34503
|
-
|
|
34504
|
-
|
|
34505
|
-
|
|
34525
|
+
// const _$ = function ($elm) {
|
|
34526
|
+
// try {
|
|
34527
|
+
// const id = $elm.attr('xu-ui-id');
|
|
34528
|
+
// if (!id) return $elm;
|
|
34529
|
+
// const $el = $(`[xu-ui-id="${id}"]`); // $("#" + id);
|
|
34506
34530
|
|
|
34507
|
-
|
|
34508
|
-
|
|
34509
|
-
|
|
34531
|
+
// if ($el.length > 1) {
|
|
34532
|
+
// console.warn('Multiple elements for xu-ui-id: ' + id, $el);
|
|
34533
|
+
// }
|
|
34510
34534
|
|
|
34511
|
-
|
|
34512
|
-
|
|
34513
|
-
|
|
34514
|
-
|
|
34515
|
-
|
|
34535
|
+
// return $($el[0]);
|
|
34536
|
+
// } catch (e) {
|
|
34537
|
+
// console.error(e);
|
|
34538
|
+
// }
|
|
34539
|
+
// };
|
|
34516
34540
|
|
|
34517
|
-
|
|
34518
|
-
|
|
34519
|
-
|
|
34520
|
-
|
|
34521
|
-
|
|
34522
|
-
|
|
34523
|
-
|
|
34524
|
-
|
|
34541
|
+
// CLIENT_ACTIVITY_TS = Date.now();
|
|
34542
|
+
// if (_$($container)?.data()?.xuData?.debug_info) _$($container).data().xuData.debug_info.hover_item = $div.attr('xu-ui-id');
|
|
34543
|
+
// if (!_ds) return;
|
|
34544
|
+
// ///////// SET Attributes///////////
|
|
34545
|
+
// let attributes = {};
|
|
34546
|
+
// $.each($div[0].attributes, function (index, attr) {
|
|
34547
|
+
// attributes[attr.name] = attr.value;
|
|
34548
|
+
// });
|
|
34525
34549
|
|
|
34526
|
-
|
|
34527
|
-
|
|
34528
|
-
|
|
34529
|
-
|
|
34530
|
-
|
|
34531
|
-
|
|
34532
|
-
|
|
34533
|
-
|
|
34534
|
-
|
|
34535
|
-
|
|
34536
|
-
|
|
34537
|
-
|
|
34538
|
-
|
|
34539
|
-
|
|
34540
|
-
|
|
34550
|
+
// SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = attributes;
|
|
34551
|
+
// //////////////////////////////////
|
|
34552
|
+
// if (!$div.data()?.xuData) return;
|
|
34553
|
+
// const _iterate_info = $div.data().xuData.iterate_info;
|
|
34554
|
+
// if (_iterate_info) {
|
|
34555
|
+
// if (_iterate_info.is_key_dynamic_field) {
|
|
34556
|
+
// _ds.dynamic_fields[_iterate_info.iterator_key].value = _iterate_info._key;
|
|
34557
|
+
// } else {
|
|
34558
|
+
// try {
|
|
34559
|
+
// const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
34560
|
+
// _ds.data_feed.rows[row_idx][_iterate_info.iterator_key] = _iterate_info._key;
|
|
34561
|
+
// } catch (err) {
|
|
34562
|
+
// console.error(err);
|
|
34563
|
+
// }
|
|
34564
|
+
// }
|
|
34541
34565
|
|
|
34542
|
-
|
|
34543
|
-
|
|
34544
|
-
|
|
34545
|
-
|
|
34546
|
-
|
|
34547
|
-
|
|
34548
|
-
|
|
34549
|
-
|
|
34550
|
-
|
|
34551
|
-
|
|
34552
|
-
|
|
34566
|
+
// if (_iterate_info.is_val_dynamic_field) {
|
|
34567
|
+
// _ds.dynamic_fields[_iterate_info.iterator_val].value = _iterate_info._val;
|
|
34568
|
+
// } else {
|
|
34569
|
+
// try {
|
|
34570
|
+
// const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
34571
|
+
// _ds.data_feed.rows[row_idx][_iterate_info.iterator_val] = _iterate_info._val;
|
|
34572
|
+
// } catch (err) {
|
|
34573
|
+
// console.error(err);
|
|
34574
|
+
// }
|
|
34575
|
+
// }
|
|
34576
|
+
// }
|
|
34553
34577
|
|
|
34554
|
-
|
|
34555
|
-
|
|
34556
|
-
|
|
34578
|
+
// if ($div && _$($div) && _ds && paramsP.renderType === 'grid') {
|
|
34579
|
+
// func.UI.worker.add_to_queue(SESSION_ID, 'gui event', 'update_datasource', { currentRecordId: _$($div).data().xuData.currentRecordId }, null, null, paramsP.dsSessionP);
|
|
34580
|
+
// }
|
|
34557
34581
|
|
|
34558
|
-
|
|
34559
|
-
|
|
34582
|
+
// const set_value = function (field_id, value) {
|
|
34583
|
+
// var currentRecordId = _$($div).data().xuData.currentRecordId;
|
|
34560
34584
|
|
|
34561
|
-
|
|
34562
|
-
|
|
34563
|
-
|
|
34564
|
-
|
|
34565
|
-
|
|
34566
|
-
|
|
34567
|
-
|
|
34568
|
-
|
|
34569
|
-
|
|
34570
|
-
|
|
34571
|
-
|
|
34572
|
-
|
|
34573
|
-
|
|
34574
|
-
|
|
34585
|
+
// func.UI.worker.add_to_queue(
|
|
34586
|
+
// SESSION_ID,
|
|
34587
|
+
// 'gui event',
|
|
34588
|
+
// 'update_datasource',
|
|
34589
|
+
// {
|
|
34590
|
+
// currentRecordId,
|
|
34591
|
+
// field_id,
|
|
34592
|
+
// field_value: value,
|
|
34593
|
+
// },
|
|
34594
|
+
// null,
|
|
34595
|
+
// null,
|
|
34596
|
+
// paramsP.dsSessionP,
|
|
34597
|
+
// );
|
|
34598
|
+
// };
|
|
34575
34599
|
|
|
34576
|
-
|
|
34577
|
-
|
|
34578
|
-
|
|
34579
|
-
|
|
34580
|
-
|
|
34581
|
-
|
|
34582
|
-
|
|
34583
|
-
|
|
34584
|
-
|
|
34585
|
-
};
|
|
34586
|
-
func.UI.screen.hover_out = function (SESSION_ID, $container, is_skeleton, paramsP) {
|
|
34587
|
-
|
|
34600
|
+
// if ($div?.data()?.iterate_info) {
|
|
34601
|
+
// var data = $div.data().xuData.iterate_info;
|
|
34602
|
+
// if (data.iterator_key) {
|
|
34603
|
+
// set_value(data.iterator_key, data._key);
|
|
34604
|
+
// }
|
|
34605
|
+
// if (data.iterator_val) {
|
|
34606
|
+
// set_value(data.iterator_val, data._val);
|
|
34607
|
+
// }
|
|
34608
|
+
// }
|
|
34609
|
+
// };
|
|
34610
|
+
// func.UI.screen.hover_out = function (SESSION_ID, $container, is_skeleton, paramsP) {
|
|
34611
|
+
// if (is_skeleton || EXP_BUSY) return;
|
|
34588
34612
|
|
|
34589
|
-
|
|
34590
|
-
|
|
34613
|
+
// var _session = SESSION_OBJ[SESSION_ID];
|
|
34614
|
+
// var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
34591
34615
|
|
|
34592
|
-
|
|
34593
|
-
|
|
34594
|
-
|
|
34595
|
-
|
|
34596
|
-
|
|
34616
|
+
// const _$ = function ($elm) {
|
|
34617
|
+
// try {
|
|
34618
|
+
// const id = $elm.attr('xu-ui-id');
|
|
34619
|
+
// if (!id) return $elm;
|
|
34620
|
+
// const $el = $(`[xu-ui-id="${id}"]`); // $("#" + id);
|
|
34597
34621
|
|
|
34598
|
-
|
|
34599
|
-
|
|
34600
|
-
|
|
34622
|
+
// if ($el.length > 1) {
|
|
34623
|
+
// console.warn('Multiple elements for xu-ui-id: ' + id, $el);
|
|
34624
|
+
// }
|
|
34601
34625
|
|
|
34602
|
-
|
|
34603
|
-
|
|
34604
|
-
|
|
34605
|
-
|
|
34606
|
-
|
|
34626
|
+
// return $($el[0]);
|
|
34627
|
+
// } catch (e) {
|
|
34628
|
+
// console.error(e);
|
|
34629
|
+
// }
|
|
34630
|
+
// };
|
|
34607
34631
|
|
|
34608
|
-
|
|
34609
|
-
|
|
34610
|
-
|
|
34611
|
-
|
|
34612
|
-
|
|
34613
|
-
|
|
34614
|
-
|
|
34615
|
-
};
|
|
34632
|
+
// CLIENT_ACTIVITY_TS = Date.now();
|
|
34633
|
+
// if (_$($container)?.data()?.xuData?.debug_info) {
|
|
34634
|
+
// _$($container).data().xuData.debug_info.hover_item = null;
|
|
34635
|
+
// }
|
|
34636
|
+
// if (_ds?.data_system) {
|
|
34637
|
+
// SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = {};
|
|
34638
|
+
// }
|
|
34639
|
+
// };
|
|
34616
34640
|
func.UI.component = {};
|
|
34617
34641
|
|
|
34618
34642
|
func.UI.component.create_app_modal_component = function (
|