@sme.up/ketchup 4.0.0 → 4.1.0
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/dist/cjs/{cell-utils-1f89a299.js → cell-utils-841a7769.js} +2 -2
- package/dist/cjs/{f-chip-2d58c8f7.js → f-chip-b9f489ff.js} +7 -5
- package/dist/cjs/{f-image-5f4f29ca.js → f-image-0c3e6aa7.js} +3 -4
- package/dist/cjs/{index-3c471303.js → index-0416afab.js} +73 -64
- package/dist/cjs/ketchup.cjs.js +3 -3
- package/dist/cjs/kup-accordion.cjs.entry.js +5 -5
- package/dist/cjs/kup-autocomplete_29.cjs.entry.js +1014 -1103
- package/dist/cjs/kup-calendar.cjs.entry.js +8 -8
- package/dist/cjs/kup-dash-list.cjs.entry.js +6 -6
- package/dist/cjs/kup-dash_2.cjs.entry.js +106 -62
- package/dist/cjs/kup-drawer.cjs.entry.js +4 -4
- package/dist/cjs/kup-field.cjs.entry.js +3 -3
- package/dist/cjs/kup-iframe.cjs.entry.js +4 -4
- package/dist/cjs/kup-lazy.cjs.entry.js +4 -4
- package/dist/cjs/kup-magic-box.cjs.entry.js +21 -30
- package/dist/cjs/{kup-manager-59ad8bdc.js → kup-manager-828bd598.js} +599 -519
- package/dist/cjs/kup-nav-bar.cjs.entry.js +4 -4
- package/dist/cjs/{kup-objects-59ea949c.js → kup-objects-89f38d6a.js} +7 -29
- package/dist/cjs/kup-probe.cjs.entry.js +3 -3
- package/dist/cjs/kup-qlik.cjs.entry.js +3 -3
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{utils-2af73538.js → utils-5192ee20.js} +1 -1
- package/dist/collection/assets/data-table.js +1 -0
- package/dist/collection/collection-manifest.json +2 -3
- package/dist/collection/components/kup-accordion/kup-accordion.js +14 -14
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.css +9 -0
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.js +20 -23
- package/dist/collection/components/kup-badge/kup-badge.js +12 -12
- package/dist/collection/components/kup-box/kup-box.css +30 -30
- package/dist/collection/components/kup-box/kup-box.js +181 -171
- package/dist/collection/components/kup-button/kup-button.css +8 -5
- package/dist/collection/components/kup-button/kup-button.js +26 -26
- package/dist/collection/components/kup-button-list/kup-button-list.css +8 -5
- package/dist/collection/components/kup-button-list/kup-button-list.js +18 -18
- package/dist/collection/components/kup-calendar/kup-calendar.css +8 -6
- package/dist/collection/components/kup-calendar/kup-calendar.js +30 -30
- package/dist/collection/components/kup-card/kup-card-helper.js +2 -1
- package/dist/collection/components/kup-card/kup-card.css +20 -1
- package/dist/collection/components/kup-card/kup-card.js +26 -26
- package/dist/collection/components/kup-chart/kup-chart.js +40 -40
- package/dist/collection/components/kup-checkbox/kup-checkbox.js +18 -18
- package/dist/collection/components/kup-chip/kup-chip.css +0 -1
- package/dist/collection/components/kup-chip/kup-chip.js +14 -14
- package/dist/collection/components/kup-color-picker/kup-color-picker.css +6 -9
- package/dist/collection/components/kup-color-picker/kup-color-picker.js +32 -40
- package/dist/collection/components/kup-combobox/kup-combobox.css +9 -0
- package/dist/collection/components/kup-combobox/kup-combobox.js +20 -23
- package/dist/collection/components/kup-dash-list/kup-dash-list.js +2 -2
- package/dist/collection/components/kup-data-table/kup-data-table-declarations.js +1 -0
- package/dist/collection/components/kup-data-table/kup-data-table-helper.js +25 -46
- package/dist/collection/components/kup-data-table/kup-data-table.css +83 -87
- package/dist/collection/components/kup-data-table/kup-data-table.js +364 -531
- package/dist/collection/components/kup-date-picker/kup-date-picker.css +2373 -5
- package/dist/collection/components/kup-date-picker/kup-date-picker.js +72 -104
- package/dist/collection/components/kup-drawer/kup-drawer.js +8 -8
- package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.css +13 -5
- package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.js +38 -43
- package/dist/collection/components/kup-field/kup-field.js +20 -20
- package/dist/collection/components/kup-gauge/kup-gauge.js +16 -16
- package/dist/collection/components/kup-grid/kup-grid.css +2 -1
- package/dist/collection/components/kup-grid/kup-grid.js +12 -12
- package/dist/collection/components/kup-iframe/kup-iframe.js +4 -4
- package/dist/collection/components/kup-image/kup-image.js +24 -24
- package/dist/collection/components/kup-lazy/kup-lazy.js +16 -16
- package/dist/collection/components/kup-list/kup-list-declarations.js +1 -1
- package/dist/collection/components/kup-list/kup-list.css +4 -0
- package/dist/collection/components/kup-list/kup-list.js +38 -47
- package/dist/collection/components/kup-magic-box/kup-magic-box.css +11 -6
- package/dist/collection/components/kup-magic-box/kup-magic-box.js +27 -36
- package/dist/collection/components/kup-nav-bar/kup-nav-bar.js +10 -10
- package/dist/collection/components/kup-paginator/kup-paginator.css +8 -5
- package/dist/collection/components/kup-probe/kup-probe.js +8 -8
- package/dist/collection/components/kup-progress-bar/kup-progress-bar.js +20 -20
- package/dist/collection/components/kup-radio/kup-radio.js +16 -16
- package/dist/collection/components/kup-rating/kup-rating.js +14 -14
- package/dist/collection/components/kup-spinner/kup-spinner.js +22 -22
- package/dist/collection/components/kup-switch/kup-switch.js +16 -16
- package/dist/collection/components/kup-tab-bar/kup-tab-bar.js +12 -12
- package/dist/collection/components/kup-text-field/kup-text-field.js +48 -48
- package/dist/collection/components/kup-time-picker/kup-time-picker.css +2376 -0
- package/dist/collection/components/kup-time-picker/kup-time-picker.js +50 -83
- package/dist/collection/components/kup-tooltip/kup-tooltip.js +18 -12
- package/dist/collection/components/kup-tree/kup-tree.css +10 -10
- package/dist/collection/components/kup-tree/kup-tree.js +96 -66
- package/dist/collection/f-components/f-button/f-button.js +4 -2
- package/dist/collection/f-components/f-image/f-image.js +1 -2
- package/dist/collection/f-components/f-text-field/f-text-field.js +8 -6
- package/dist/collection/utils/kup-column-menu/kup-column-menu.js +11 -3
- package/dist/collection/utils/kup-debug/kup-debug.js +25 -27
- package/dist/collection/utils/kup-dynamic-position/kup-dynamic-position.js +3 -5
- package/dist/collection/utils/kup-interact/kup-interact-declarations.js +48 -0
- package/dist/collection/utils/kup-interact/kup-interact.js +362 -0
- package/dist/collection/utils/kup-manager/kup-manager.js +18 -6
- package/dist/collection/utils/kup-objects/kup-objects.js +7 -29
- package/dist/collection/utils/kup-scroll-on-hover/kup-scroll-on-hover.js +60 -62
- package/dist/collection/utils/kup-toolbar/kup-toolbar.js +16 -18
- package/dist/esm/{cell-utils-cb612463.js → cell-utils-de384721.js} +2 -2
- package/dist/esm/{f-chip-125d5dd6.js → f-chip-d585b63e.js} +7 -5
- package/dist/esm/{f-image-68b34fab.js → f-image-23548d00.js} +3 -4
- package/dist/esm/{index-bf2824a6.js → index-51694018.js} +73 -64
- package/dist/esm/ketchup.js +3 -3
- package/dist/esm/kup-accordion.entry.js +5 -5
- package/dist/esm/kup-autocomplete_29.entry.js +818 -907
- package/dist/esm/kup-calendar.entry.js +8 -8
- package/dist/esm/kup-dash-list.entry.js +6 -6
- package/dist/esm/kup-dash_2.entry.js +106 -62
- package/dist/esm/kup-drawer.entry.js +4 -4
- package/dist/esm/kup-field.entry.js +3 -3
- package/dist/esm/kup-iframe.entry.js +4 -4
- package/dist/esm/kup-lazy.entry.js +4 -4
- package/dist/esm/kup-magic-box.entry.js +21 -30
- package/dist/esm/{kup-manager-e7d7b353.js → kup-manager-583f2815.js} +595 -520
- package/dist/esm/kup-nav-bar.entry.js +4 -4
- package/dist/esm/{kup-objects-d38d2fa2.js → kup-objects-5968aefd.js} +7 -29
- package/dist/esm/kup-probe.entry.js +3 -3
- package/dist/esm/kup-qlik.entry.js +3 -3
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{utils-13dd007a.js → utils-a1dd14c3.js} +1 -1
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/{p-64ea7e37.entry.js → p-0e91c9c9.entry.js} +1 -1
- package/dist/ketchup/{p-0320e24e.entry.js → p-0f2b6a24.entry.js} +1 -1
- package/dist/ketchup/{p-a5424073.js → p-361d9431.js} +1 -1
- package/dist/ketchup/p-565785ce.js +1 -0
- package/dist/ketchup/{p-7896031c.entry.js → p-57eb45ac.entry.js} +1 -1
- package/dist/ketchup/{p-08c7a092.js → p-6f5d8830.js} +1 -1
- package/dist/ketchup/{p-9c858a38.entry.js → p-802d8906.entry.js} +1 -1
- package/dist/ketchup/p-850b9e67.entry.js +1 -0
- package/dist/ketchup/{p-a12a5690.entry.js → p-88a5787a.entry.js} +1 -1
- package/dist/ketchup/p-8ed2b7bf.entry.js +1 -0
- package/dist/ketchup/{p-ee89966f.entry.js → p-90a0c2b7.entry.js} +2 -2
- package/dist/ketchup/{p-876da4c2.entry.js → p-94c0dd8c.entry.js} +1 -1
- package/dist/ketchup/p-9ec3c377.entry.js +45 -0
- package/dist/ketchup/p-b30f34d8.js +1 -0
- package/dist/ketchup/p-b6a47512.entry.js +1 -0
- package/dist/ketchup/p-bfaf8a82.js +1 -0
- package/dist/ketchup/{p-940ab57a.entry.js → p-ca0ebdcc.entry.js} +1 -1
- package/dist/ketchup/p-d5a3a4ed.js +1 -0
- package/dist/ketchup/{p-c7ee1fbc.js → p-ee7b190c.js} +1 -1
- package/dist/ketchup/{p-b0724035.entry.js → p-f6b54fa1.entry.js} +1 -1
- package/dist/types/components/kup-box/kup-box-declarations.d.ts +11 -2
- package/dist/types/components/kup-box/kup-box.d.ts +8 -4
- package/dist/types/components/kup-color-picker/kup-color-picker.d.ts +0 -1
- package/dist/types/components/kup-data-table/kup-data-table-declarations.d.ts +12 -4
- package/dist/types/components/kup-data-table/kup-data-table-helper.d.ts +0 -2
- package/dist/types/components/kup-data-table/kup-data-table.d.ts +16 -49
- package/dist/types/components/kup-date-picker/kup-date-picker.d.ts +11 -14
- package/dist/types/components/kup-dropdown-button/kup-dropdown-button.d.ts +0 -4
- package/dist/types/components/kup-list/kup-list-declarations.d.ts +1 -1
- package/dist/types/components/kup-list/kup-list.d.ts +2 -3
- package/dist/types/components/kup-magic-box/kup-magic-box.d.ts +1 -0
- package/dist/types/components/kup-time-picker/kup-time-picker.d.ts +7 -11
- package/dist/types/components/kup-tree/kup-tree-declarations.d.ts +4 -4
- package/dist/types/components/kup-tree/kup-tree.d.ts +3 -0
- package/dist/types/components.d.ts +84 -121
- package/dist/types/utils/kup-dynamic-position/kup-dynamic-position.d.ts +2 -2
- package/dist/types/utils/kup-interact/kup-interact-declarations.d.ts +127 -0
- package/dist/types/utils/kup-interact/kup-interact.d.ts +93 -0
- package/dist/types/utils/kup-manager/kup-manager-declarations.d.ts +21 -4
- package/dist/types/utils/kup-manager/kup-manager.d.ts +2 -2
- package/dist/types/utils/kup-objects/kup-objects.d.ts +1 -7
- package/package.json +3 -3
- package/dist/cjs/drag-and-drop-4787ff6f.js +0 -281
- package/dist/cjs/kup-grid.cjs.entry.js +0 -130
- package/dist/collection/assets/images/drag-multiple.js +0 -1
- package/dist/collection/components/kup-layout/kup-layout.css +0 -53
- package/dist/collection/components/kup-layout/kup-layout.js +0 -156
- package/dist/collection/utils/drag-and-drop.js +0 -109
- package/dist/collection/utils/kup-dialog/kup-dialog-declarations.js +0 -36
- package/dist/collection/utils/kup-dialog/kup-dialog.js +0 -310
- package/dist/esm/drag-and-drop-321cb4ca.js +0 -265
- package/dist/esm/kup-grid.entry.js +0 -126
- package/dist/ketchup/p-00fe1e3e.js +0 -1
- package/dist/ketchup/p-1165f4ea.entry.js +0 -1
- package/dist/ketchup/p-170d3cba.js +0 -1
- package/dist/ketchup/p-18cb3ba3.js +0 -1
- package/dist/ketchup/p-23541a97.entry.js +0 -45
- package/dist/ketchup/p-8fb9d9b2.entry.js +0 -1
- package/dist/ketchup/p-b14e77f0.js +0 -1
- package/dist/ketchup/p-d24cfdea.entry.js +0 -1
- package/dist/ketchup/p-fcd2fd8f.js +0 -1
- package/dist/ketchup/p-fce3b9d8.entry.js +0 -1
- package/dist/types/assets/images/drag-multiple.d.ts +0 -1
- package/dist/types/components/kup-layout/kup-layout.d.ts +0 -25
- package/dist/types/utils/drag-and-drop.d.ts +0 -53
- package/dist/types/utils/kup-dialog/kup-dialog-declarations.d.ts +0 -43
- package/dist/types/utils/kup-dialog/kup-dialog.d.ts +0 -50
|
@@ -12,10 +12,11 @@ import { KupColumnMenu } from '../../utils/kup-column-menu/kup-column-menu';
|
|
|
12
12
|
import { FiltersColumnMenu } from '../../utils/filters/filters-column-menu';
|
|
13
13
|
import { KupGlobalFilterMode, } from '../../utils/filters/filters-declarations';
|
|
14
14
|
import { FiltersTreeItems } from '../../utils/filters/filters-tree-items';
|
|
15
|
-
import { kupDynamicPositionAttribute,
|
|
15
|
+
import { kupDynamicPositionAttribute, } from '../../utils/kup-dynamic-position/kup-dynamic-position-declarations';
|
|
16
16
|
import { KupLanguageGeneric, KupLanguageSearch, KupLanguageTotals, } from '../../utils/kup-language/kup-language-declarations';
|
|
17
17
|
import { componentWrapperId } from '../../variables/GenericVariables';
|
|
18
18
|
import { KupThemeIconValues } from '../../utils/kup-theme/kup-theme-declarations';
|
|
19
|
+
import { KupPointerEventTypes } from '../../utils/kup-interact/kup-interact-declarations';
|
|
19
20
|
export class KupTree {
|
|
20
21
|
constructor() {
|
|
21
22
|
/*-------------------------------------------------*/
|
|
@@ -182,6 +183,8 @@ export class KupTree {
|
|
|
182
183
|
this.totalMenuCoords = null;
|
|
183
184
|
this.contentRefs = [];
|
|
184
185
|
this.oldWidth = null;
|
|
186
|
+
this.hold = false;
|
|
187
|
+
this.interactableTouch = [];
|
|
185
188
|
}
|
|
186
189
|
initWithPersistedState() {
|
|
187
190
|
if (this.store && this.stateId) {
|
|
@@ -341,16 +344,6 @@ export class KupTree {
|
|
|
341
344
|
this.columnMenuCard.layoutNumber = 12;
|
|
342
345
|
this.columnMenuCard.sizeX = 'auto';
|
|
343
346
|
this.columnMenuCard.sizeY = 'auto';
|
|
344
|
-
this.columnMenuCard.tabIndex = -1;
|
|
345
|
-
this.columnMenuCard.onblur = () => {
|
|
346
|
-
if (this.kupManager.utilities.lastPointerDownPath.includes(this.columnMenuCard)) {
|
|
347
|
-
this.columnMenuCard.focus();
|
|
348
|
-
}
|
|
349
|
-
else {
|
|
350
|
-
this.closeColumnMenu();
|
|
351
|
-
}
|
|
352
|
-
};
|
|
353
|
-
this.columnMenuCard.onclick = (e) => e.stopPropagation();
|
|
354
347
|
this.columnMenuCard.addEventListener('kup-card-click', (e) => {
|
|
355
348
|
this.kupTreeColumnMenu.emit({
|
|
356
349
|
comp: this,
|
|
@@ -880,7 +873,7 @@ export class KupTree {
|
|
|
880
873
|
};
|
|
881
874
|
icon = h("span", { style: iconStyle, class: "kup-icon obj-icon" });
|
|
882
875
|
}
|
|
883
|
-
const _hasTooltip = this.kupManager.objects.
|
|
876
|
+
const _hasTooltip = !this.kupManager.objects.isEmptyKupObj(cell.obj);
|
|
884
877
|
let title = undefined;
|
|
885
878
|
if (_hasTooltip) {
|
|
886
879
|
classObj['is-obj'] = true;
|
|
@@ -1311,7 +1304,7 @@ export class KupTree {
|
|
|
1311
1304
|
}));
|
|
1312
1305
|
}
|
|
1313
1306
|
}
|
|
1314
|
-
const _hasTooltip = this.kupManager.objects.
|
|
1307
|
+
const _hasTooltip = !this.kupManager.objects.isEmptyKupObj(treeNodeData.obj);
|
|
1315
1308
|
let title = undefined;
|
|
1316
1309
|
if (_hasTooltip && this.kupManager.debug.isDebug()) {
|
|
1317
1310
|
title =
|
|
@@ -1340,7 +1333,7 @@ export class KupTree {
|
|
|
1340
1333
|
'mdc-ripple-surface': this.ripple &&
|
|
1341
1334
|
!this.showColumns &&
|
|
1342
1335
|
!treeNodeData.disabled,
|
|
1343
|
-
'is-obj': this.kupManager.objects.
|
|
1336
|
+
'is-obj': !this.kupManager.objects.isEmptyKupObj(treeNodeData.obj),
|
|
1344
1337
|
}, style: treeNodeData.style || null, title: title, onDblClick: () => {
|
|
1345
1338
|
this.onKupTreeNodeDblClick(treeNodeData, treeNodePath);
|
|
1346
1339
|
} }, this.getToolTipEventHandlers(treeNodeData, cell, _hasTooltip)), this.asAccordion && !treeNodeDepth
|
|
@@ -1480,7 +1473,7 @@ export class KupTree {
|
|
|
1480
1473
|
separator: true,
|
|
1481
1474
|
});
|
|
1482
1475
|
}
|
|
1483
|
-
totalMenu = (h("kup-list", { class: `
|
|
1476
|
+
totalMenu = (h("kup-list", { class: `total-menu`, data: listData, id: "totals-menu", "is-menu": true, keyboardNavigation: true, "menu-visible": true, "onkup-list-click": (event) => this.onTotalsChange(event, column) }));
|
|
1484
1477
|
}
|
|
1485
1478
|
let value;
|
|
1486
1479
|
if (menuLabel === TotalLabel.COUNT ||
|
|
@@ -1499,14 +1492,52 @@ export class KupTree {
|
|
|
1499
1492
|
nodesCell,
|
|
1500
1493
|
footerCells)));
|
|
1501
1494
|
}
|
|
1495
|
+
didLoadInteractables() {
|
|
1496
|
+
this.interactableTouch.push(this.treeWrapperRef);
|
|
1497
|
+
const tapCb = (e) => {
|
|
1498
|
+
if (this.hold) {
|
|
1499
|
+
this.hold = false;
|
|
1500
|
+
return;
|
|
1501
|
+
}
|
|
1502
|
+
switch (e.button) {
|
|
1503
|
+
// right click
|
|
1504
|
+
case 2:
|
|
1505
|
+
this.kupTreeContextMenu.emit({
|
|
1506
|
+
comp: this,
|
|
1507
|
+
id: this.rootElement.id,
|
|
1508
|
+
details: this.contextMenuHandler(e),
|
|
1509
|
+
});
|
|
1510
|
+
break;
|
|
1511
|
+
}
|
|
1512
|
+
};
|
|
1513
|
+
const holdCb = (e) => {
|
|
1514
|
+
if (e.pointerType === 'pen' || e.pointerType === 'touch') {
|
|
1515
|
+
this.hold = true;
|
|
1516
|
+
this.kupTreeContextMenu.emit({
|
|
1517
|
+
comp: this,
|
|
1518
|
+
id: this.rootElement.id,
|
|
1519
|
+
details: this.contextMenuHandler(e),
|
|
1520
|
+
});
|
|
1521
|
+
}
|
|
1522
|
+
};
|
|
1523
|
+
this.kupManager.interact.on(this.treeWrapperRef, KupPointerEventTypes.TAP, tapCb);
|
|
1524
|
+
this.kupManager.interact.on(this.treeWrapperRef, KupPointerEventTypes.HOLD, holdCb);
|
|
1525
|
+
}
|
|
1502
1526
|
totalMenuPosition() {
|
|
1503
1527
|
if (this.rootElement.shadowRoot) {
|
|
1504
|
-
|
|
1528
|
+
const menu = this.rootElement.shadowRoot.querySelector('#totals-menu');
|
|
1505
1529
|
if (menu) {
|
|
1506
|
-
this.kupManager.dynamicPosition.register(menu, this.totalMenuCoords
|
|
1530
|
+
this.kupManager.dynamicPosition.register(menu, this.totalMenuCoords);
|
|
1531
|
+
this.kupManager.utilities.pointerDownCallbacks.add({
|
|
1532
|
+
cb: () => {
|
|
1533
|
+
this.closeTotalMenu();
|
|
1534
|
+
this.kupManager.dynamicPosition.stop(menu);
|
|
1535
|
+
},
|
|
1536
|
+
onlyOnce: true,
|
|
1537
|
+
el: menu,
|
|
1538
|
+
});
|
|
1507
1539
|
this.kupManager.dynamicPosition.start(menu);
|
|
1508
|
-
menu.
|
|
1509
|
-
setTimeout(() => menu.focus(), 0);
|
|
1540
|
+
menu.menuVisible = true;
|
|
1510
1541
|
}
|
|
1511
1542
|
}
|
|
1512
1543
|
}
|
|
@@ -1587,6 +1618,7 @@ export class KupTree {
|
|
|
1587
1618
|
this.hdlTreeNodeClick(null, tn, this.selectedNodeString, true);
|
|
1588
1619
|
}
|
|
1589
1620
|
}
|
|
1621
|
+
this.didLoadInteractables();
|
|
1590
1622
|
this.kupDidLoad.emit({ comp: this, id: this.rootElement.id });
|
|
1591
1623
|
this.kupManager.resize.observe(this.rootElement);
|
|
1592
1624
|
this.kupManager.debug.logLoad(this, true);
|
|
@@ -1665,11 +1697,9 @@ export class KupTree {
|
|
|
1665
1697
|
h("div", { class: "wrapper", ref: (el) => (this.treeWrapperRef =
|
|
1666
1698
|
el) },
|
|
1667
1699
|
filterField,
|
|
1668
|
-
h("table", { class: "kup-tree", "data-show-columns": this.showColumns, onContextMenu: (e) =>
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
details: this.contextMenuHandler(e),
|
|
1672
|
-
}) },
|
|
1700
|
+
h("table", { class: "kup-tree", "data-show-columns": this.showColumns, onContextMenu: (e) => {
|
|
1701
|
+
e.preventDefault();
|
|
1702
|
+
} },
|
|
1673
1703
|
h("thead", { class: {
|
|
1674
1704
|
'header--is-visible': visibleHeader,
|
|
1675
1705
|
} },
|
|
@@ -1718,8 +1748,8 @@ export class KupTree {
|
|
|
1718
1748
|
"optional": false,
|
|
1719
1749
|
"docs": {
|
|
1720
1750
|
"tags": [{
|
|
1721
|
-
"
|
|
1722
|
-
"
|
|
1751
|
+
"name": "default",
|
|
1752
|
+
"text": "false"
|
|
1723
1753
|
}],
|
|
1724
1754
|
"text": "When enabled, the first level of depth will give an accordion look to nodes."
|
|
1725
1755
|
},
|
|
@@ -1777,11 +1807,11 @@ export class KupTree {
|
|
|
1777
1807
|
"optional": false,
|
|
1778
1808
|
"docs": {
|
|
1779
1809
|
"tags": [{
|
|
1780
|
-
"
|
|
1781
|
-
"
|
|
1810
|
+
"name": "default",
|
|
1811
|
+
"text": "\"\""
|
|
1782
1812
|
}, {
|
|
1783
|
-
"
|
|
1784
|
-
"
|
|
1813
|
+
"name": "see",
|
|
1814
|
+
"text": "https://ketchup.smeup.com/ketchup-showcase/#/customization"
|
|
1785
1815
|
}],
|
|
1786
1816
|
"text": "Custom style of the component."
|
|
1787
1817
|
},
|
|
@@ -1852,8 +1882,8 @@ export class KupTree {
|
|
|
1852
1882
|
"optional": false,
|
|
1853
1883
|
"docs": {
|
|
1854
1884
|
"tags": [{
|
|
1855
|
-
"
|
|
1856
|
-
"
|
|
1885
|
+
"name": "see",
|
|
1886
|
+
"text": "useDynamicExpansion"
|
|
1857
1887
|
}],
|
|
1858
1888
|
"text": "Function that gets invoked when a new set of nodes must be loaded as children of a node.\n\nWhen useDynamicExpansion is set, the tree component will have two different behaviors depending on the value of this prop.\n1 - If this prop is set to null, no callback to download data is available:\n the component will emit an event requiring the parent to load the children of the given node.\n2 - If this prop is set to have a callback, then the component will automatically make requests to load children of\n a given node. After the load has been completed, a different event will be fired to alert the parent of the change."
|
|
1859
1889
|
},
|
|
@@ -1912,8 +1942,8 @@ export class KupTree {
|
|
|
1912
1942
|
"optional": false,
|
|
1913
1943
|
"docs": {
|
|
1914
1944
|
"tags": [{
|
|
1915
|
-
"
|
|
1916
|
-
"
|
|
1945
|
+
"name": "default",
|
|
1946
|
+
"text": "KupTreeExpansionMode.DROPDOWN"
|
|
1917
1947
|
}],
|
|
1918
1948
|
"text": "Behavior of nodes' expansion: it can be chosen between expanding a node by clicking on the dropdown icon, or by clicking on the whole node."
|
|
1919
1949
|
},
|
|
@@ -2013,8 +2043,8 @@ export class KupTree {
|
|
|
2013
2043
|
"optional": false,
|
|
2014
2044
|
"docs": {
|
|
2015
2045
|
"tags": [{
|
|
2016
|
-
"
|
|
2017
|
-
"
|
|
2046
|
+
"name": "default",
|
|
2047
|
+
"text": "false;"
|
|
2018
2048
|
}],
|
|
2019
2049
|
"text": "Experimental feature: when active, the tree will try to prevent horizontal overflowing elements by setting a width on the content of the table cells.\nIt works only on cells of the main column."
|
|
2020
2050
|
},
|
|
@@ -2052,8 +2082,8 @@ export class KupTree {
|
|
|
2052
2082
|
"optional": false,
|
|
2053
2083
|
"docs": {
|
|
2054
2084
|
"tags": [{
|
|
2055
|
-
"
|
|
2056
|
-
"
|
|
2085
|
+
"name": "default",
|
|
2086
|
+
"text": "true"
|
|
2057
2087
|
}],
|
|
2058
2088
|
"text": "When enabled displays Material's ripple effect on nodes (only when no columns are displayed)."
|
|
2059
2089
|
},
|
|
@@ -2166,8 +2196,8 @@ export class KupTree {
|
|
|
2166
2196
|
"optional": false,
|
|
2167
2197
|
"docs": {
|
|
2168
2198
|
"tags": [{
|
|
2169
|
-
"
|
|
2170
|
-
"
|
|
2199
|
+
"name": "see",
|
|
2200
|
+
"text": "showColumns"
|
|
2171
2201
|
}],
|
|
2172
2202
|
"text": "Flag: shows the header of the tree when the tree is displayed as a table."
|
|
2173
2203
|
},
|
|
@@ -2243,8 +2273,8 @@ export class KupTree {
|
|
|
2243
2273
|
"optional": false,
|
|
2244
2274
|
"docs": {
|
|
2245
2275
|
"tags": [{
|
|
2246
|
-
"
|
|
2247
|
-
"
|
|
2276
|
+
"name": "see",
|
|
2277
|
+
"text": "dynamicExpansionCallback"
|
|
2248
2278
|
}],
|
|
2249
2279
|
"text": "When the component must use the dynamic expansion feature to open its nodes, it means that not all the nodes of the\ntree have been passed inside the data property.\n\nTherefore, when expanding a node, the tree must emit an event (or run a given callback)\nand wait for the child nodes to be downloaded from the server.\n\nFor more information:"
|
|
2250
2280
|
},
|
|
@@ -2378,32 +2408,32 @@ export class KupTree {
|
|
|
2378
2408
|
"composed": true,
|
|
2379
2409
|
"docs": {
|
|
2380
2410
|
"tags": [{
|
|
2381
|
-
"
|
|
2382
|
-
"
|
|
2411
|
+
"name": "event",
|
|
2412
|
+
"text": "kup-tree-nodeexpand"
|
|
2383
2413
|
}, {
|
|
2384
|
-
"
|
|
2385
|
-
"
|
|
2414
|
+
"name": "type",
|
|
2415
|
+
"text": "{object}"
|
|
2386
2416
|
}, {
|
|
2387
|
-
"
|
|
2388
|
-
"
|
|
2417
|
+
"name": "property",
|
|
2418
|
+
"text": "{TreeNodePath} treeNodePath - The array of indexes to retrieve the current treeNode inside the data prop."
|
|
2389
2419
|
}, {
|
|
2390
|
-
"
|
|
2391
|
-
"
|
|
2420
|
+
"name": "property",
|
|
2421
|
+
"text": "{TreeNode} treeNode - Reference to the TreeNode data object which is being expanded (passed through the data prop)."
|
|
2392
2422
|
}, {
|
|
2393
|
-
"
|
|
2394
|
-
"
|
|
2423
|
+
"name": "property",
|
|
2424
|
+
"text": "{boolean} usesDynamicExpansion - Flag to notify that the component is running in dynamicExpansion mode."
|
|
2395
2425
|
}, {
|
|
2396
|
-
"
|
|
2397
|
-
"
|
|
2426
|
+
"name": "property",
|
|
2427
|
+
"text": "{boolean} dynamicExpansionRequireChildren - Flag to notify that the current dynamicExpansion event\nrequires the parent component to add TreeNode children to the given TreeNode."
|
|
2398
2428
|
}, {
|
|
2399
|
-
"
|
|
2400
|
-
"
|
|
2429
|
+
"name": "see",
|
|
2430
|
+
"text": "useDynamicExpansion *"
|
|
2401
2431
|
}, {
|
|
2402
|
-
"
|
|
2403
|
-
"
|
|
2432
|
+
"name": "see",
|
|
2433
|
+
"text": "dynamicExpansionCallback *"
|
|
2404
2434
|
}, {
|
|
2405
|
-
"
|
|
2406
|
-
"
|
|
2435
|
+
"name": "since",
|
|
2436
|
+
"text": "1.0.0"
|
|
2407
2437
|
}],
|
|
2408
2438
|
"text": "Fired when a node expansion ion has been triggered.\nContains additional data when the tree is using the dynamicExpansion feature."
|
|
2409
2439
|
},
|
|
@@ -2648,8 +2678,8 @@ export class KupTree {
|
|
|
2648
2678
|
"signature": "(descriptions?: boolean) => Promise<GenericObject>",
|
|
2649
2679
|
"parameters": [{
|
|
2650
2680
|
"tags": [{
|
|
2651
|
-
"
|
|
2652
|
-
"
|
|
2681
|
+
"name": "param",
|
|
2682
|
+
"text": "descriptions - When provided and true, the result will be the list of props with their description."
|
|
2653
2683
|
}],
|
|
2654
2684
|
"text": "- When provided and true, the result will be the list of props with their description."
|
|
2655
2685
|
}],
|
|
@@ -2680,8 +2710,8 @@ export class KupTree {
|
|
|
2680
2710
|
"signature": "(column: string) => Promise<void>",
|
|
2681
2711
|
"parameters": [{
|
|
2682
2712
|
"tags": [{
|
|
2683
|
-
"
|
|
2684
|
-
"
|
|
2713
|
+
"name": "param",
|
|
2714
|
+
"text": "column - Name of the column."
|
|
2685
2715
|
}],
|
|
2686
2716
|
"text": "- Name of the column."
|
|
2687
2717
|
}],
|
|
@@ -2748,8 +2778,8 @@ export class KupTree {
|
|
|
2748
2778
|
"signature": "(props: GenericObject) => Promise<void>",
|
|
2749
2779
|
"parameters": [{
|
|
2750
2780
|
"tags": [{
|
|
2751
|
-
"
|
|
2752
|
-
"
|
|
2781
|
+
"name": "param",
|
|
2782
|
+
"text": "props - Object containing props that will be set to the component."
|
|
2753
2783
|
}],
|
|
2754
2784
|
"text": "- Object containing props that will be set to the component."
|
|
2755
2785
|
}],
|
|
@@ -5,7 +5,7 @@ const dom = document.documentElement;
|
|
|
5
5
|
/*-------------------------------------------------*/
|
|
6
6
|
/* C o m p o n e n t */
|
|
7
7
|
/*-------------------------------------------------*/
|
|
8
|
-
export const FButton = (props) => {
|
|
8
|
+
export const FButton = (props, children) => {
|
|
9
9
|
if (!props.styling) {
|
|
10
10
|
props.styling = FButtonStyling.RAISED;
|
|
11
11
|
}
|
|
@@ -16,7 +16,9 @@ export const FButton = (props) => {
|
|
|
16
16
|
(props.styling.toLowerCase() === FButtonStyling.RAISED &&
|
|
17
17
|
props.icon &&
|
|
18
18
|
(props.label === null || props.label === undefined)));
|
|
19
|
-
return (h("div", Object.assign({ class: `f-button--wrapper ${props.danger ? 'kup-danger' : ''} ${props.fullHeight ? 'kup-full-height' : ''} ${props.fullWidth ? 'kup-full-width' : ''} ${props.info ? 'kup-info' : ''} ${props.large ? 'kup-large' : ''} ${props.pulsating ? 'kup-pulsating' : ''} ${props.shaped ? 'kup-shaped' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.slim ? 'kup-slim' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
19
|
+
return (h("div", Object.assign({ class: `f-button--wrapper ${props.danger ? 'kup-danger' : ''} ${props.fullHeight ? 'kup-full-height' : ''} ${props.fullWidth ? 'kup-full-width' : ''} ${props.info ? 'kup-info' : ''} ${props.large ? 'kup-large' : ''} ${props.pulsating ? 'kup-pulsating' : ''} ${props.shaped ? 'kup-shaped' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.slim ? 'kup-slim' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
20
|
+
isIconButton ? renderIconButton(props) : renderButton(props),
|
|
21
|
+
children));
|
|
20
22
|
};
|
|
21
23
|
/*-------------------------------------------------*/
|
|
22
24
|
/* M e t h o d s */
|
|
@@ -55,8 +55,7 @@ function createIcon(props) {
|
|
|
55
55
|
: `var(${KupThemeColorValues.ICON})`,
|
|
56
56
|
};
|
|
57
57
|
if (props.resource.indexOf('--kup') > -1) {
|
|
58
|
-
let themeIcon = props.resource.replace('--
|
|
59
|
-
themeIcon = themeIcon.replace('-icon', '');
|
|
58
|
+
let themeIcon = props.resource.replace('--', '');
|
|
60
59
|
classObj['kup-icon'] = true;
|
|
61
60
|
classObj[themeIcon] = true;
|
|
62
61
|
}
|
|
@@ -3,12 +3,14 @@ import { KupThemeIconValues } from '../../utils/kup-theme/kup-theme-declarations
|
|
|
3
3
|
/*-------------------------------------------------*/
|
|
4
4
|
/* C o m p o n e n t */
|
|
5
5
|
/*-------------------------------------------------*/
|
|
6
|
-
export const FTextField = (props) => {
|
|
7
|
-
return (h("div", Object.assign({ class: `f-text-field--wrapper ${props.danger ? 'kup-danger' : ''} ${props.fullHeight ? 'kup-full-height' : ''} ${props.fullWidth ? 'kup-full-width' : ''} ${props.info ? 'kup-info' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.shaped ? 'kup-shaped' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
export const FTextField = (props, children) => {
|
|
7
|
+
return (h("div", Object.assign({ class: `f-text-field--wrapper ${props.danger ? 'kup-danger' : ''} ${props.fullHeight ? 'kup-full-height' : ''} ${props.fullWidth ? 'kup-full-width' : ''} ${props.info ? 'kup-info' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.shaped ? 'kup-shaped' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
8
|
+
props.leadingLabel || props.trailingLabel ? (h("div", { class: `mdc-form-field ${props.leadingLabel ? 'mdc-form-field--align-end' : ''}` }, [
|
|
9
|
+
setContent(props),
|
|
10
|
+
setHelper(props),
|
|
11
|
+
h("label", null, props.label),
|
|
12
|
+
])) : ([setContent(props), setHelper(props)]),
|
|
13
|
+
children));
|
|
12
14
|
};
|
|
13
15
|
/*-------------------------------------------------*/
|
|
14
16
|
/* M e t h o d s */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { KupDynamicPositionPlacement } from '../kup-dynamic-position/kup-dynamic-position-declarations';
|
|
1
|
+
import { KupDynamicPositionPlacement, } from '../kup-dynamic-position/kup-dynamic-position-declarations';
|
|
2
2
|
import { treeMainColumnName } from '../../components/kup-tree/kup-tree-declarations';
|
|
3
3
|
import { unsetTooltip } from '../helpers';
|
|
4
4
|
import { FiltersColumnMenu } from '../filters/filters-column-menu';
|
|
@@ -39,6 +39,7 @@ export class KupColumnMenu {
|
|
|
39
39
|
*/
|
|
40
40
|
close(card) {
|
|
41
41
|
card.menuVisible = false;
|
|
42
|
+
dom.ketchup.dynamicPosition.stop(card);
|
|
42
43
|
}
|
|
43
44
|
/**
|
|
44
45
|
* Function called to reposition the column menu card to the appropriate column.
|
|
@@ -56,6 +57,13 @@ export class KupColumnMenu {
|
|
|
56
57
|
else {
|
|
57
58
|
dom.ketchup.dynamicPosition.register(card, wrapper, 0, KupDynamicPositionPlacement.BOTTOM, true);
|
|
58
59
|
}
|
|
60
|
+
dom.ketchup.utilities.pointerDownCallbacks.add({
|
|
61
|
+
cb: () => {
|
|
62
|
+
this.close(card);
|
|
63
|
+
},
|
|
64
|
+
onlyOnce: true,
|
|
65
|
+
el: card,
|
|
66
|
+
});
|
|
59
67
|
dom.ketchup.dynamicPosition.start(card);
|
|
60
68
|
card.menuVisible = true;
|
|
61
69
|
}
|
|
@@ -263,7 +271,7 @@ export class KupColumnMenu {
|
|
|
263
271
|
prepSwitch(comp, column) {
|
|
264
272
|
const props = [];
|
|
265
273
|
if (!FiltersColumnMenu.isTree(comp)) {
|
|
266
|
-
if (!dom.ketchup.objects.
|
|
274
|
+
if (!dom.ketchup.objects.isEmptyKupObj(column.obj)) {
|
|
267
275
|
props.push({
|
|
268
276
|
'data-storage': {
|
|
269
277
|
columnName: column.name,
|
|
@@ -538,7 +546,7 @@ export class KupColumnMenu {
|
|
|
538
546
|
eventHandlers(cardEvent, comp) {
|
|
539
547
|
const card = cardEvent.detail.card
|
|
540
548
|
? cardEvent.detail.card
|
|
541
|
-
: cardEvent.detail.comp;
|
|
549
|
+
: cardEvent.detail.comp.rootElement;
|
|
542
550
|
const compEvent = cardEvent.detail.event;
|
|
543
551
|
const compID = compEvent.detail.id;
|
|
544
552
|
const subcomp = compEvent.target;
|
|
@@ -1,17 +1,15 @@
|
|
|
1
|
-
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver,
|
|
2
|
-
if (
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return value;
|
|
1
|
+
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
2
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
3
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
4
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
5
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
7
6
|
};
|
|
8
|
-
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver,
|
|
9
|
-
if (!
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
return privateMap.get(receiver);
|
|
7
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
8
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
9
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
10
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
13
11
|
};
|
|
14
|
-
var
|
|
12
|
+
var _KupDebug_debugWidget;
|
|
15
13
|
import { KupCardFamily } from '../../components/kup-card/kup-card-declarations';
|
|
16
14
|
import { KupLanguageDebug } from '../kup-language/kup-language-declarations';
|
|
17
15
|
import { KupDebugCategory, KupDebugLogColor, } from './kup-debug-declarations';
|
|
@@ -28,7 +26,7 @@ export class KupDebug {
|
|
|
28
26
|
* @param {number} logLimit - Maximum amount of logs stored, when they exceed the number specified in logLimit the cache will be automatically cleared.
|
|
29
27
|
*/
|
|
30
28
|
constructor(active, autoprint, logLimit) {
|
|
31
|
-
|
|
29
|
+
_KupDebug_debugWidget.set(this, void 0);
|
|
32
30
|
this.active = active ? true : false;
|
|
33
31
|
this.autoPrint = autoprint ? true : false;
|
|
34
32
|
this.container = document.createElement('div');
|
|
@@ -36,9 +34,9 @@ export class KupDebug {
|
|
|
36
34
|
document.body.appendChild(this.container);
|
|
37
35
|
this.logLimit = logLimit ? logLimit : 250;
|
|
38
36
|
this.logs = [];
|
|
39
|
-
__classPrivateFieldSet(this,
|
|
37
|
+
__classPrivateFieldSet(this, _KupDebug_debugWidget, null, "f");
|
|
40
38
|
document.addEventListener('kup-language-change', () => {
|
|
41
|
-
if (this.active && __classPrivateFieldGet(this,
|
|
39
|
+
if (this.active && __classPrivateFieldGet(this, _KupDebug_debugWidget, "f")) {
|
|
42
40
|
this.hideWidget();
|
|
43
41
|
this.showWidget();
|
|
44
42
|
}
|
|
@@ -200,20 +198,20 @@ export class KupDebug {
|
|
|
200
198
|
debugWidget.sizeY = 'auto';
|
|
201
199
|
debugWidget.addEventListener('kup-card-event', (e) => this.handleEvents(e));
|
|
202
200
|
this.container.append(debugWidget);
|
|
203
|
-
__classPrivateFieldSet(this,
|
|
201
|
+
__classPrivateFieldSet(this, _KupDebug_debugWidget, debugWidget, "f");
|
|
204
202
|
}
|
|
205
203
|
/**
|
|
206
204
|
* Closes the debug widget.
|
|
207
205
|
*/
|
|
208
206
|
hideWidget() {
|
|
209
|
-
__classPrivateFieldGet(this,
|
|
210
|
-
__classPrivateFieldSet(this,
|
|
207
|
+
__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").remove();
|
|
208
|
+
__classPrivateFieldSet(this, _KupDebug_debugWidget, null, "f");
|
|
211
209
|
}
|
|
212
210
|
/**
|
|
213
211
|
* Clears all the printed logs inside the debug widget.
|
|
214
212
|
*/
|
|
215
213
|
widgetClear() {
|
|
216
|
-
const children = Array.prototype.slice.call(__classPrivateFieldGet(this,
|
|
214
|
+
const children = Array.prototype.slice.call(__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").children, 0);
|
|
217
215
|
for (let index = 0; index < children.length; index++) {
|
|
218
216
|
children[index].remove();
|
|
219
217
|
}
|
|
@@ -277,7 +275,7 @@ export class KupDebug {
|
|
|
277
275
|
}
|
|
278
276
|
slots.reverse();
|
|
279
277
|
for (let index = 0; index < slots.length; index++) {
|
|
280
|
-
__classPrivateFieldGet(this,
|
|
278
|
+
__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").append(slots[index]);
|
|
281
279
|
}
|
|
282
280
|
}
|
|
283
281
|
/**
|
|
@@ -352,13 +350,13 @@ export class KupDebug {
|
|
|
352
350
|
}
|
|
353
351
|
if (this.active) {
|
|
354
352
|
document.dispatchEvent(new CustomEvent('kup-debug-active'));
|
|
355
|
-
if (!__classPrivateFieldGet(this,
|
|
353
|
+
if (!__classPrivateFieldGet(this, _KupDebug_debugWidget, "f")) {
|
|
356
354
|
this.showWidget();
|
|
357
355
|
}
|
|
358
356
|
}
|
|
359
357
|
else {
|
|
360
358
|
document.dispatchEvent(new CustomEvent('kup-debug-inactive'));
|
|
361
|
-
if (__classPrivateFieldGet(this,
|
|
359
|
+
if (__classPrivateFieldGet(this, _KupDebug_debugWidget, "f")) {
|
|
362
360
|
this.hideWidget();
|
|
363
361
|
}
|
|
364
362
|
}
|
|
@@ -378,7 +376,7 @@ export class KupDebug {
|
|
|
378
376
|
break;
|
|
379
377
|
case 'kup-debug-clear':
|
|
380
378
|
this.widgetClear();
|
|
381
|
-
__classPrivateFieldGet(this,
|
|
379
|
+
__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").refresh();
|
|
382
380
|
break;
|
|
383
381
|
case 'kup-debug-dl-props':
|
|
384
382
|
this.getProps().then((res) => {
|
|
@@ -402,7 +400,7 @@ export class KupDebug {
|
|
|
402
400
|
case 'kup-debug-print':
|
|
403
401
|
this.widgetClear();
|
|
404
402
|
this.widgetPrint();
|
|
405
|
-
__classPrivateFieldGet(this,
|
|
403
|
+
__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").refresh();
|
|
406
404
|
break;
|
|
407
405
|
}
|
|
408
406
|
break;
|
|
@@ -560,10 +558,10 @@ export class KupDebug {
|
|
|
560
558
|
this.dump();
|
|
561
559
|
}
|
|
562
560
|
this.logs.push(log);
|
|
563
|
-
if (this.autoPrint && __classPrivateFieldGet(this,
|
|
561
|
+
if (this.autoPrint && __classPrivateFieldGet(this, _KupDebug_debugWidget, "f")) {
|
|
564
562
|
this.widgetClear();
|
|
565
563
|
this.widgetPrint();
|
|
566
|
-
__classPrivateFieldGet(this,
|
|
564
|
+
__classPrivateFieldGet(this, _KupDebug_debugWidget, "f").refresh();
|
|
567
565
|
}
|
|
568
566
|
}
|
|
569
567
|
switch (category) {
|
|
@@ -678,4 +676,4 @@ export class KupDebug {
|
|
|
678
676
|
}
|
|
679
677
|
}
|
|
680
678
|
}
|
|
681
|
-
|
|
679
|
+
_KupDebug_debugWidget = new WeakMap();
|
|
@@ -33,9 +33,7 @@ export class KupDynamicPosition {
|
|
|
33
33
|
*/
|
|
34
34
|
register(el, anchorEl, margin, placement, detach) {
|
|
35
35
|
if (this.isRegistered(el)) {
|
|
36
|
-
|
|
37
|
-
this.changeAnchor(el, anchorEl);
|
|
38
|
-
}
|
|
36
|
+
this.changeAnchor(el, anchorEl);
|
|
39
37
|
return;
|
|
40
38
|
}
|
|
41
39
|
el.setAttribute(kupDynamicPositionAttribute, '');
|
|
@@ -49,7 +47,7 @@ export class KupDynamicPosition {
|
|
|
49
47
|
else {
|
|
50
48
|
el.style.position = 'fixed';
|
|
51
49
|
}
|
|
52
|
-
el.style.zIndex =
|
|
50
|
+
el.style.zIndex = `calc(var(--kup-navbar-zindex) - 1)`;
|
|
53
51
|
el.kupDynamicPosition = {
|
|
54
52
|
anchor: anchorEl,
|
|
55
53
|
detach: detach ? true : false,
|
|
@@ -74,7 +72,7 @@ export class KupDynamicPosition {
|
|
|
74
72
|
/**
|
|
75
73
|
* Changes the anchor point of the given element.
|
|
76
74
|
* @param {KupDynamicPositionElement} elements - Dynamically positioned element previously registered.
|
|
77
|
-
* @param {
|
|
75
|
+
* @param {KupDynamicPositionAnchor} anchorEl - New anchor point.
|
|
78
76
|
*/
|
|
79
77
|
changeAnchor(el, anchorEl) {
|
|
80
78
|
el.kupDynamicPosition.anchor = anchorEl;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HTML Attribute attached to dialogs.
|
|
3
|
+
* Referenced by kup-theme.css
|
|
4
|
+
*/
|
|
5
|
+
export const kupDialogAttribute = 'kup-dialog';
|
|
6
|
+
/**
|
|
7
|
+
* CSS class attached to resizable dialogs.
|
|
8
|
+
* Referenced by kup-theme.css
|
|
9
|
+
*/
|
|
10
|
+
export const kupDialogResizableClass = 'kup-resizable';
|
|
11
|
+
/**
|
|
12
|
+
* Drag & drop variables.
|
|
13
|
+
*/
|
|
14
|
+
export const kupDropEvent = 'kup-drop';
|
|
15
|
+
export const kupDragActiveAttr = 'kup-drag-active';
|
|
16
|
+
export const kupDragOverAttr = 'kup-drag-over';
|
|
17
|
+
export const kupDraggableAttr = 'kup-draggable';
|
|
18
|
+
export const kupDraggableCellAttr = 'kup-draggable-cell';
|
|
19
|
+
export const kupDraggableColumnAttr = 'kup-draggable-column';
|
|
20
|
+
export const kupDraggableRowAttr = 'kup-draggable-row';
|
|
21
|
+
/**
|
|
22
|
+
* Available effects fro dragging.
|
|
23
|
+
*/
|
|
24
|
+
export var KupDragEffect;
|
|
25
|
+
(function (KupDragEffect) {
|
|
26
|
+
KupDragEffect["BADGE"] = "badge";
|
|
27
|
+
KupDragEffect["CLONE"] = "clone";
|
|
28
|
+
KupDragEffect["MOVE"] = "move";
|
|
29
|
+
KupDragEffect["NONE"] = "none";
|
|
30
|
+
})(KupDragEffect || (KupDragEffect = {}));
|
|
31
|
+
/**
|
|
32
|
+
* Supported types of pointer events.
|
|
33
|
+
*/
|
|
34
|
+
export var KupPointerEventTypes;
|
|
35
|
+
(function (KupPointerEventTypes) {
|
|
36
|
+
KupPointerEventTypes["DOUBLETAP"] = "doubletap";
|
|
37
|
+
KupPointerEventTypes["HOLD"] = "hold";
|
|
38
|
+
KupPointerEventTypes["TAP"] = "tap";
|
|
39
|
+
})(KupPointerEventTypes || (KupPointerEventTypes = {}));
|
|
40
|
+
/**
|
|
41
|
+
* Supported types of drop event.
|
|
42
|
+
*/
|
|
43
|
+
export var KupDropEventTypes;
|
|
44
|
+
(function (KupDropEventTypes) {
|
|
45
|
+
KupDropEventTypes["BOX"] = "text/kup-box-drag";
|
|
46
|
+
KupDropEventTypes["DATATABLE"] = "text/kup-data-table-row-drag";
|
|
47
|
+
KupDropEventTypes["MAGICBOX"] = "text/kup-magic-box-drag";
|
|
48
|
+
})(KupDropEventTypes || (KupDropEventTypes = {}));
|