@xuda.io/runtime-bundle 1.0.831 → 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 +141 -117
- package/js/xuda-runtime-bundle.min.js +1 -1
- package/js/xuda-runtime-slim.js +142 -118
- package/js/xuda-runtime-slim.min.es.js +142 -118
- package/js/xuda-runtime-slim.min.js +1 -1
- package/package.json +1 -1
|
@@ -12270,12 +12270,12 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12270
12270
|
|
|
12271
12271
|
$div.hover(
|
|
12272
12272
|
function (e) {
|
|
12273
|
-
|
|
12274
|
-
func.UI.screen.hover_in(SESSION_ID, null, $container, paramsP, is_skeleton);
|
|
12273
|
+
hover_in();
|
|
12274
|
+
// func.UI.screen.hover_in(SESSION_ID, null, $container, paramsP, is_skeleton);
|
|
12275
12275
|
},
|
|
12276
12276
|
function (e) {
|
|
12277
|
-
func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
12278
|
-
|
|
12277
|
+
// func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
12278
|
+
hover_out();
|
|
12279
12279
|
},
|
|
12280
12280
|
);
|
|
12281
12281
|
}
|
|
@@ -12434,12 +12434,12 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12434
12434
|
|
|
12435
12435
|
$div.hover(
|
|
12436
12436
|
function (e) {
|
|
12437
|
-
|
|
12438
|
-
func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
12437
|
+
hover_in($div);
|
|
12438
|
+
// func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
12439
12439
|
},
|
|
12440
12440
|
function (e) {
|
|
12441
|
-
func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
12442
|
-
|
|
12441
|
+
// func.UI.screen.hover_out(SESSION_ID, $container, is_skeleton, paramsP);
|
|
12442
|
+
hover_out();
|
|
12443
12443
|
},
|
|
12444
12444
|
);
|
|
12445
12445
|
|
|
@@ -12447,7 +12447,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12447
12447
|
if (ret.abort || nodeP.tagName === 'svg') return await done();
|
|
12448
12448
|
// check if iterator made to prevent children render
|
|
12449
12449
|
|
|
12450
|
-
const
|
|
12450
|
+
const observer_inViewport = new IntersectionObserver(
|
|
12451
12451
|
function (entries) {
|
|
12452
12452
|
entries.forEach((entry) => {
|
|
12453
12453
|
if (entry.isIntersecting) {
|
|
@@ -12458,7 +12458,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12458
12458
|
$(entry.target).trigger('inViewport');
|
|
12459
12459
|
|
|
12460
12460
|
// Optional: stop observing once triggered
|
|
12461
|
-
|
|
12461
|
+
observer_inViewport.unobserve(entry.target);
|
|
12462
12462
|
}
|
|
12463
12463
|
});
|
|
12464
12464
|
},
|
|
@@ -12467,6 +12467,23 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12467
12467
|
},
|
|
12468
12468
|
);
|
|
12469
12469
|
|
|
12470
|
+
const observer_outViewport = new IntersectionObserver(
|
|
12471
|
+
function (entries) {
|
|
12472
|
+
entries.forEach((entry) => {
|
|
12473
|
+
if (!entry.isIntersecting) {
|
|
12474
|
+
// Element is OUT of viewport - trigger custom event
|
|
12475
|
+
$(entry.target).trigger('outViewport');
|
|
12476
|
+
|
|
12477
|
+
// Optional: stop observing once triggered
|
|
12478
|
+
observer_outViewport.unobserve(entry.target);
|
|
12479
|
+
}
|
|
12480
|
+
});
|
|
12481
|
+
},
|
|
12482
|
+
{
|
|
12483
|
+
threshold: 0, // Trigger when element is completely out of view
|
|
12484
|
+
},
|
|
12485
|
+
);
|
|
12486
|
+
|
|
12470
12487
|
// const render_child = async function () {
|
|
12471
12488
|
// await iterate_child($div, nodeP, parent_infoP, $root_container);
|
|
12472
12489
|
// };
|
|
@@ -12475,13 +12492,20 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
12475
12492
|
// console.log('on>>', 'inViewport_' + $div.attr('xu-ui-id'));
|
|
12476
12493
|
// $div.on('inViewport_' + $div.attr('xu-ui-id'), function () {
|
|
12477
12494
|
$div.on('inViewport', function () {
|
|
12478
|
-
|
|
12495
|
+
hover_in($div);
|
|
12496
|
+
// func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP, is_skeleton);
|
|
12479
12497
|
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);
|
|
12480
12498
|
// render_child();
|
|
12481
12499
|
// iterate_child($div, nodeP, parent_infoP, null, $root_container);
|
|
12482
12500
|
});
|
|
12483
12501
|
|
|
12484
|
-
|
|
12502
|
+
$div.on('outViewport', function () {
|
|
12503
|
+
$div.empty();
|
|
12504
|
+
observer_inViewport.observe($div[0]);
|
|
12505
|
+
});
|
|
12506
|
+
|
|
12507
|
+
observer_inViewport.observe($div[0]);
|
|
12508
|
+
observer_outViewport.observe($div[0]);
|
|
12485
12509
|
} else {
|
|
12486
12510
|
// await render_child();
|
|
12487
12511
|
await iterate_child($div, nodeP, parent_infoP, $root_container);
|
|
@@ -12533,127 +12557,127 @@ func.UI.screen.refresh_document_changes_for_realtime_update = async function (SE
|
|
|
12533
12557
|
}
|
|
12534
12558
|
};
|
|
12535
12559
|
|
|
12536
|
-
func.UI.screen.hover_in = function (SESSION_ID, $div, $container, paramsP, is_skeleton) {
|
|
12537
|
-
|
|
12560
|
+
// func.UI.screen.hover_in = function (SESSION_ID, $div, $container, paramsP, is_skeleton) {
|
|
12561
|
+
// if (is_skeleton || EXP_BUSY) return;
|
|
12538
12562
|
|
|
12539
|
-
|
|
12540
|
-
|
|
12563
|
+
// var _session = SESSION_OBJ[SESSION_ID];
|
|
12564
|
+
// var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
12541
12565
|
|
|
12542
|
-
|
|
12543
|
-
|
|
12544
|
-
|
|
12545
|
-
|
|
12546
|
-
|
|
12547
|
-
|
|
12548
|
-
if ($el.length > 1) {
|
|
12549
|
-
console.warn('Multiple elements for xu-ui-id: ' + id, $el);
|
|
12550
|
-
}
|
|
12566
|
+
// const _$ = function ($elm) {
|
|
12567
|
+
// try {
|
|
12568
|
+
// const id = $elm.attr('xu-ui-id');
|
|
12569
|
+
// if (!id) return $elm;
|
|
12570
|
+
// const $el = $(`[xu-ui-id="${id}"]`); // $("#" + id);
|
|
12551
12571
|
|
|
12552
|
-
|
|
12553
|
-
|
|
12554
|
-
|
|
12555
|
-
}
|
|
12556
|
-
};
|
|
12572
|
+
// if ($el.length > 1) {
|
|
12573
|
+
// console.warn('Multiple elements for xu-ui-id: ' + id, $el);
|
|
12574
|
+
// }
|
|
12557
12575
|
|
|
12558
|
-
|
|
12559
|
-
|
|
12560
|
-
|
|
12561
|
-
|
|
12562
|
-
|
|
12563
|
-
$.each($div[0].attributes, function (index, attr) {
|
|
12564
|
-
attributes[attr.name] = attr.value;
|
|
12565
|
-
});
|
|
12576
|
+
// return $($el[0]);
|
|
12577
|
+
// } catch (e) {
|
|
12578
|
+
// console.error(e);
|
|
12579
|
+
// }
|
|
12580
|
+
// };
|
|
12566
12581
|
|
|
12567
|
-
|
|
12568
|
-
|
|
12569
|
-
|
|
12570
|
-
|
|
12571
|
-
|
|
12572
|
-
|
|
12573
|
-
|
|
12574
|
-
|
|
12575
|
-
try {
|
|
12576
|
-
const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
12577
|
-
_ds.data_feed.rows[row_idx][_iterate_info.iterator_key] = _iterate_info._key;
|
|
12578
|
-
} catch (err) {
|
|
12579
|
-
console.error(err);
|
|
12580
|
-
}
|
|
12581
|
-
}
|
|
12582
|
+
// CLIENT_ACTIVITY_TS = Date.now();
|
|
12583
|
+
// if (_$($container)?.data()?.xuData?.debug_info) _$($container).data().xuData.debug_info.hover_item = $div.attr('xu-ui-id');
|
|
12584
|
+
// if (!_ds) return;
|
|
12585
|
+
// ///////// SET Attributes///////////
|
|
12586
|
+
// let attributes = {};
|
|
12587
|
+
// $.each($div[0].attributes, function (index, attr) {
|
|
12588
|
+
// attributes[attr.name] = attr.value;
|
|
12589
|
+
// });
|
|
12582
12590
|
|
|
12583
|
-
|
|
12584
|
-
|
|
12585
|
-
|
|
12586
|
-
|
|
12587
|
-
|
|
12588
|
-
|
|
12589
|
-
|
|
12590
|
-
|
|
12591
|
-
|
|
12592
|
-
|
|
12593
|
-
|
|
12591
|
+
// SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = attributes;
|
|
12592
|
+
// //////////////////////////////////
|
|
12593
|
+
// if (!$div.data()?.xuData) return;
|
|
12594
|
+
// const _iterate_info = $div.data().xuData.iterate_info;
|
|
12595
|
+
// if (_iterate_info) {
|
|
12596
|
+
// if (_iterate_info.is_key_dynamic_field) {
|
|
12597
|
+
// _ds.dynamic_fields[_iterate_info.iterator_key].value = _iterate_info._key;
|
|
12598
|
+
// } else {
|
|
12599
|
+
// try {
|
|
12600
|
+
// const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
12601
|
+
// _ds.data_feed.rows[row_idx][_iterate_info.iterator_key] = _iterate_info._key;
|
|
12602
|
+
// } catch (err) {
|
|
12603
|
+
// console.error(err);
|
|
12604
|
+
// }
|
|
12605
|
+
// }
|
|
12594
12606
|
|
|
12595
|
-
|
|
12596
|
-
|
|
12597
|
-
|
|
12607
|
+
// if (_iterate_info.is_val_dynamic_field) {
|
|
12608
|
+
// _ds.dynamic_fields[_iterate_info.iterator_val].value = _iterate_info._val;
|
|
12609
|
+
// } else {
|
|
12610
|
+
// try {
|
|
12611
|
+
// const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
12612
|
+
// _ds.data_feed.rows[row_idx][_iterate_info.iterator_val] = _iterate_info._val;
|
|
12613
|
+
// } catch (err) {
|
|
12614
|
+
// console.error(err);
|
|
12615
|
+
// }
|
|
12616
|
+
// }
|
|
12617
|
+
// }
|
|
12598
12618
|
|
|
12599
|
-
|
|
12600
|
-
|
|
12619
|
+
// if ($div && _$($div) && _ds && paramsP.renderType === 'grid') {
|
|
12620
|
+
// func.UI.worker.add_to_queue(SESSION_ID, 'gui event', 'update_datasource', { currentRecordId: _$($div).data().xuData.currentRecordId }, null, null, paramsP.dsSessionP);
|
|
12621
|
+
// }
|
|
12601
12622
|
|
|
12602
|
-
|
|
12603
|
-
|
|
12604
|
-
|
|
12605
|
-
|
|
12606
|
-
|
|
12607
|
-
|
|
12608
|
-
|
|
12609
|
-
|
|
12610
|
-
|
|
12611
|
-
|
|
12612
|
-
|
|
12613
|
-
|
|
12614
|
-
|
|
12615
|
-
|
|
12623
|
+
// const set_value = function (field_id, value) {
|
|
12624
|
+
// var currentRecordId = _$($div).data().xuData.currentRecordId;
|
|
12625
|
+
|
|
12626
|
+
// func.UI.worker.add_to_queue(
|
|
12627
|
+
// SESSION_ID,
|
|
12628
|
+
// 'gui event',
|
|
12629
|
+
// 'update_datasource',
|
|
12630
|
+
// {
|
|
12631
|
+
// currentRecordId,
|
|
12632
|
+
// field_id,
|
|
12633
|
+
// field_value: value,
|
|
12634
|
+
// },
|
|
12635
|
+
// null,
|
|
12636
|
+
// null,
|
|
12637
|
+
// paramsP.dsSessionP,
|
|
12638
|
+
// );
|
|
12639
|
+
// };
|
|
12616
12640
|
|
|
12617
|
-
|
|
12618
|
-
|
|
12619
|
-
|
|
12620
|
-
|
|
12621
|
-
|
|
12622
|
-
|
|
12623
|
-
|
|
12624
|
-
|
|
12625
|
-
|
|
12626
|
-
};
|
|
12627
|
-
func.UI.screen.hover_out = function (SESSION_ID, $container, is_skeleton, paramsP) {
|
|
12628
|
-
|
|
12641
|
+
// if ($div?.data()?.iterate_info) {
|
|
12642
|
+
// var data = $div.data().xuData.iterate_info;
|
|
12643
|
+
// if (data.iterator_key) {
|
|
12644
|
+
// set_value(data.iterator_key, data._key);
|
|
12645
|
+
// }
|
|
12646
|
+
// if (data.iterator_val) {
|
|
12647
|
+
// set_value(data.iterator_val, data._val);
|
|
12648
|
+
// }
|
|
12649
|
+
// }
|
|
12650
|
+
// };
|
|
12651
|
+
// func.UI.screen.hover_out = function (SESSION_ID, $container, is_skeleton, paramsP) {
|
|
12652
|
+
// if (is_skeleton || EXP_BUSY) return;
|
|
12629
12653
|
|
|
12630
|
-
|
|
12631
|
-
|
|
12654
|
+
// var _session = SESSION_OBJ[SESSION_ID];
|
|
12655
|
+
// var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
12632
12656
|
|
|
12633
|
-
|
|
12634
|
-
|
|
12635
|
-
|
|
12636
|
-
|
|
12637
|
-
|
|
12657
|
+
// const _$ = function ($elm) {
|
|
12658
|
+
// try {
|
|
12659
|
+
// const id = $elm.attr('xu-ui-id');
|
|
12660
|
+
// if (!id) return $elm;
|
|
12661
|
+
// const $el = $(`[xu-ui-id="${id}"]`); // $("#" + id);
|
|
12638
12662
|
|
|
12639
|
-
|
|
12640
|
-
|
|
12641
|
-
|
|
12663
|
+
// if ($el.length > 1) {
|
|
12664
|
+
// console.warn('Multiple elements for xu-ui-id: ' + id, $el);
|
|
12665
|
+
// }
|
|
12642
12666
|
|
|
12643
|
-
|
|
12644
|
-
|
|
12645
|
-
|
|
12646
|
-
|
|
12647
|
-
|
|
12667
|
+
// return $($el[0]);
|
|
12668
|
+
// } catch (e) {
|
|
12669
|
+
// console.error(e);
|
|
12670
|
+
// }
|
|
12671
|
+
// };
|
|
12648
12672
|
|
|
12649
|
-
|
|
12650
|
-
|
|
12651
|
-
|
|
12652
|
-
|
|
12653
|
-
|
|
12654
|
-
|
|
12655
|
-
|
|
12656
|
-
};
|
|
12673
|
+
// CLIENT_ACTIVITY_TS = Date.now();
|
|
12674
|
+
// if (_$($container)?.data()?.xuData?.debug_info) {
|
|
12675
|
+
// _$($container).data().xuData.debug_info.hover_item = null;
|
|
12676
|
+
// }
|
|
12677
|
+
// if (_ds?.data_system) {
|
|
12678
|
+
// SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = {};
|
|
12679
|
+
// }
|
|
12680
|
+
// };
|
|
12657
12681
|
func.UI.component = {};
|
|
12658
12682
|
|
|
12659
12683
|
func.UI.component.create_app_modal_component = function (
|