@sme.up/ketchup 10.1.0 → 10.1.2
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/{f-cell-83ca2b8b.js → f-cell-66dc3984.js} +4 -4
- package/dist/cjs/{f-chip-286f1c8d.js → f-chip-90155c76.js} +1 -1
- package/dist/cjs/{f-object-field-0986026c.js → f-object-field-902b9d05.js} +2 -2
- package/dist/cjs/{f-paginator-utils-ee281217.js → f-paginator-utils-7df7d997.js} +13 -4
- package/dist/cjs/{f-text-field-463a6dbe.js → f-text-field-80716a60.js} +1 -1
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/ketchup.cjs.js +1 -1
- package/dist/cjs/kup-accordion.cjs.entry.js +1 -1
- package/dist/cjs/kup-activity-timeline.cjs.entry.js +2 -2
- package/dist/cjs/kup-autocomplete_28.cjs.entry.js +79 -57
- package/dist/cjs/kup-box.cjs.entry.js +7 -7
- package/dist/cjs/kup-calendar.cjs.entry.js +3 -3
- package/dist/cjs/kup-card-list.cjs.entry.js +1 -1
- package/dist/cjs/kup-cell.cjs.entry.js +5 -5
- package/dist/cjs/kup-dashboard.cjs.entry.js +2 -2
- package/dist/cjs/{kup-data-table-helper-c7d3445e.js → kup-data-table-helper-02d1e529.js} +28 -65
- package/dist/cjs/kup-drawer.cjs.entry.js +1 -1
- package/dist/cjs/kup-echart.cjs.entry.js +1 -1
- package/dist/cjs/kup-editor.cjs.entry.js +1 -1
- package/dist/cjs/kup-family-tree.cjs.entry.js +1 -1
- package/dist/cjs/kup-grid.cjs.entry.js +1 -1
- package/dist/cjs/kup-htm.cjs.entry.js +1 -1
- package/dist/cjs/kup-iframe.cjs.entry.js +1 -1
- package/dist/cjs/kup-image-list.cjs.entry.js +5 -5
- package/dist/cjs/kup-input-panel.cjs.entry.js +5 -5
- package/dist/cjs/kup-lazy.cjs.entry.js +1 -1
- package/dist/cjs/kup-magic-box.cjs.entry.js +1 -1
- package/dist/cjs/{kup-manager-f41ad314.js → kup-manager-d67049ad.js} +33 -9
- package/dist/cjs/kup-nav-bar.cjs.entry.js +1 -1
- package/dist/cjs/kup-numeric-picker.cjs.entry.js +2 -2
- package/dist/cjs/kup-object-field.cjs.entry.js +3 -3
- package/dist/cjs/kup-pdf.cjs.entry.js +1 -1
- package/dist/cjs/kup-planner.cjs.entry.js +2 -2
- package/dist/cjs/kup-probe.cjs.entry.js +1 -1
- package/dist/cjs/kup-qlik.cjs.entry.js +1 -1
- package/dist/cjs/kup-snackbar.cjs.entry.js +1 -1
- package/dist/cjs/kup-txt.cjs.entry.js +1 -1
- package/dist/cjs/kup-typography-list.cjs.entry.js +1 -1
- package/dist/cjs/kup-typography.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/kup-calendar/kup-calendar.css +18 -1
- package/dist/collection/components/kup-card/built-in/kup-card-clock.js +4 -2
- package/dist/collection/components/kup-card/kup-card.css +27 -0
- package/dist/collection/components/kup-card/standard/kup-card-standard.js +8 -6
- package/dist/collection/components/kup-combobox/kup-combobox.js +1 -1
- package/dist/collection/components/kup-data-table/kup-data-table.js +11 -11
- package/dist/collection/components/kup-date-picker/kup-date-picker.js +4 -6
- package/dist/collection/components/kup-list/kup-list.js +4 -3
- package/dist/collection/components/kup-time-picker/kup-time-picker.js +50 -9
- package/dist/collection/f-components/f-paginator/f-paginator.js +10 -2
- package/dist/collection/managers/kup-data/kup-data.js +4 -0
- package/dist/collection/managers/kup-dynamic-position/kup-dynamic-position.js +12 -1
- package/dist/collection/managers/kup-language/kup-language-declarations.js +1 -2
- package/dist/collection/utils/filters/filters-column-menu.js +8 -22
- package/dist/collection/utils/filters/filters-declarations.js +1 -1
- package/dist/collection/utils/filters/filters-rows.js +19 -42
- package/dist/collection/utils/filters/filters.js +7 -4
- package/dist/collection/utils/kup-column-menu/kup-column-menu-declarations.js +0 -2
- package/dist/collection/utils/kup-column-menu/kup-column-menu.js +10 -10
- package/dist/components/index.js +1 -1
- package/dist/components/kup-accordion.js +2 -2
- package/dist/components/kup-activity-timeline.js +2 -2
- package/dist/components/kup-autocomplete.js +1 -1
- package/dist/components/kup-badge.js +1 -1
- package/dist/components/kup-box.js +1 -1
- package/dist/components/kup-button-list.js +1 -1
- package/dist/components/kup-button.js +1 -1
- package/dist/components/kup-calendar.js +3 -3
- package/dist/components/kup-card-list.js +3 -3
- package/dist/components/kup-card.js +1 -1
- package/dist/components/kup-cell.js +2 -2
- package/dist/components/kup-chart.js +1 -1
- package/dist/components/kup-checkbox.js +1 -1
- package/dist/components/kup-chip.js +1 -1
- package/dist/components/kup-color-picker.js +1 -1
- package/dist/components/kup-combobox.js +1 -1
- package/dist/components/kup-dashboard.js +2 -2
- package/dist/components/kup-data-table.js +1 -1
- package/dist/components/kup-date-picker.js +1 -1
- package/dist/components/kup-dialog.js +1 -1
- package/dist/components/kup-drawer.js +2 -2
- package/dist/components/kup-dropdown-button.js +1 -1
- package/dist/components/kup-echart.js +1 -1
- package/dist/components/kup-editor.js +1 -1
- package/dist/components/kup-family-tree.js +3 -3
- package/dist/components/kup-form.js +1 -1
- package/dist/components/kup-gauge.js +1 -1
- package/dist/components/kup-grid.js +1 -1
- package/dist/components/kup-htm.js +2 -2
- package/dist/components/kup-iframe.js +2 -2
- package/dist/components/kup-image-list.js +2 -2
- package/dist/components/kup-image.js +1 -1
- package/dist/components/kup-input-panel.js +3 -3
- package/dist/components/kup-lazy.js +2 -2
- package/dist/components/kup-list.js +1 -1
- package/dist/components/kup-magic-box.js +4 -4
- package/dist/components/kup-nav-bar.js +2 -2
- package/dist/components/kup-numeric-picker.js +2 -2
- package/dist/components/kup-object-field.js +2 -2
- package/dist/components/kup-pdf.js +2 -2
- package/dist/components/kup-planner.js +2 -2
- package/dist/components/kup-probe.js +2 -2
- package/dist/components/kup-progress-bar.js +1 -1
- package/dist/components/kup-qlik.js +2 -2
- package/dist/components/kup-radio.js +1 -1
- package/dist/components/kup-rating.js +1 -1
- package/dist/components/kup-snackbar.js +2 -2
- package/dist/components/kup-spinner.js +1 -1
- package/dist/components/kup-switch.js +1 -1
- package/dist/components/kup-tab-bar.js +1 -1
- package/dist/components/kup-text-field.js +1 -1
- package/dist/components/kup-time-picker.js +1 -1
- package/dist/components/kup-toolbar.js +1 -1
- package/dist/components/kup-tree.js +1 -1
- package/dist/components/kup-txt.js +2 -2
- package/dist/components/kup-typography-list.js +2 -2
- package/dist/components/kup-typography.js +2 -2
- package/dist/components/{p-e30483fa.js → p-05429a55.js} +2 -2
- package/dist/components/{p-ef8026e9.js → p-0c219ec5.js} +113 -118
- package/dist/components/{p-0ac9fd6c.js → p-72305403.js} +2 -2
- package/dist/components/{p-09b28008.js → p-7b052cb9.js} +2 -2
- package/dist/components/{p-5f307bf2.js → p-8b050302.js} +2 -2
- package/dist/components/{p-a3f73a90.js → p-ab7c8404.js} +34 -10
- package/dist/esm/{f-cell-82b9ae70.js → f-cell-50d54fdf.js} +4 -4
- package/dist/esm/{f-chip-f98be128.js → f-chip-c31b2c02.js} +1 -1
- package/dist/esm/{f-object-field-1a4f54ea.js → f-object-field-80e6eb02.js} +2 -2
- package/dist/esm/{f-paginator-utils-2fc5cd18.js → f-paginator-utils-a835dde6.js} +13 -4
- package/dist/esm/{f-text-field-e766e681.js → f-text-field-6b05bfbc.js} +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/ketchup.js +1 -1
- package/dist/esm/kup-accordion.entry.js +1 -1
- package/dist/esm/kup-activity-timeline.entry.js +2 -2
- package/dist/esm/kup-autocomplete_28.entry.js +79 -57
- package/dist/esm/kup-box.entry.js +7 -7
- package/dist/esm/kup-calendar.entry.js +3 -3
- package/dist/esm/kup-card-list.entry.js +1 -1
- package/dist/esm/kup-cell.entry.js +5 -5
- package/dist/esm/kup-dashboard.entry.js +2 -2
- package/dist/esm/{kup-data-table-helper-e350cc90.js → kup-data-table-helper-1b2c70b8.js} +28 -65
- package/dist/esm/kup-drawer.entry.js +1 -1
- package/dist/esm/kup-echart.entry.js +1 -1
- package/dist/esm/kup-editor.entry.js +1 -1
- package/dist/esm/kup-family-tree.entry.js +1 -1
- package/dist/esm/kup-grid.entry.js +1 -1
- package/dist/esm/kup-htm.entry.js +1 -1
- package/dist/esm/kup-iframe.entry.js +1 -1
- package/dist/esm/kup-image-list.entry.js +5 -5
- package/dist/esm/kup-input-panel.entry.js +5 -5
- package/dist/esm/kup-lazy.entry.js +1 -1
- package/dist/esm/kup-magic-box.entry.js +1 -1
- package/dist/esm/{kup-manager-6c75d73b.js → kup-manager-5fbf0037.js} +34 -10
- package/dist/esm/kup-nav-bar.entry.js +1 -1
- package/dist/esm/kup-numeric-picker.entry.js +2 -2
- package/dist/esm/kup-object-field.entry.js +3 -3
- package/dist/esm/kup-pdf.entry.js +1 -1
- package/dist/esm/kup-planner.entry.js +2 -2
- package/dist/esm/kup-probe.entry.js +1 -1
- package/dist/esm/kup-qlik.entry.js +1 -1
- package/dist/esm/kup-snackbar.entry.js +1 -1
- package/dist/esm/kup-txt.entry.js +1 -1
- package/dist/esm/kup-typography-list.entry.js +1 -1
- package/dist/esm/kup-typography.entry.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/ketchup/index.esm.js +1 -1
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/{p-60cdaa75.entry.js → p-05aea063.entry.js} +1 -1
- package/dist/ketchup/{p-ce31744e.entry.js → p-08691abd.entry.js} +1 -1
- package/dist/ketchup/{p-cdf92c8b.entry.js → p-1374d2f7.entry.js} +1 -1
- package/dist/ketchup/{p-f648a3cb.entry.js → p-17279bd4.entry.js} +1 -1
- package/dist/ketchup/{p-03d1cafc.entry.js → p-1aa03e7f.entry.js} +1 -1
- package/dist/ketchup/{p-97fe2d0c.entry.js → p-1e53c21d.entry.js} +1 -1
- package/dist/ketchup/{p-d8ef1613.entry.js → p-268af1b3.entry.js} +1 -1
- package/dist/ketchup/{p-4bbc1e40.entry.js → p-27e9313b.entry.js} +1 -1
- package/dist/ketchup/{p-bdd3e0a4.entry.js → p-34f29123.entry.js} +1 -1
- package/dist/ketchup/{p-93d6f4a9.entry.js → p-4608b0e6.entry.js} +1 -1
- package/dist/ketchup/{p-e7f6ca6c.entry.js → p-487909b5.entry.js} +1 -1
- package/dist/ketchup/{p-bc37db5b.entry.js → p-5635bfbf.entry.js} +1 -1
- package/dist/ketchup/{p-fe190410.entry.js → p-5f20e6ce.entry.js} +1 -1
- package/dist/ketchup/{p-a781d278.entry.js → p-7966fa12.entry.js} +1 -1
- package/dist/ketchup/p-7b5a2535.entry.js +9 -0
- package/dist/ketchup/{p-2d3a89a0.entry.js → p-7fc0ee16.entry.js} +1 -1
- package/dist/ketchup/{p-5ee25762.js → p-816de1ef.js} +1 -1
- package/dist/ketchup/{p-865ce089.entry.js → p-82badc23.entry.js} +1 -1
- package/dist/ketchup/{p-7c078bc1.entry.js → p-84ca2ebd.entry.js} +1 -1
- package/dist/ketchup/p-90a0de6c.js +21 -0
- package/dist/ketchup/p-9106b93f.js +1 -0
- package/dist/ketchup/p-9278528b.entry.js +1 -0
- package/dist/ketchup/{p-153b7eda.js → p-a6cf4320.js} +1 -1
- package/dist/ketchup/{p-2133fdbb.entry.js → p-a9fa88cc.entry.js} +1 -1
- package/dist/ketchup/p-ab911e2d.js +1 -0
- package/dist/ketchup/{p-543f99d3.entry.js → p-b16c12ab.entry.js} +1 -1
- package/dist/ketchup/{p-53596bee.entry.js → p-b1a73691.entry.js} +1 -1
- package/dist/ketchup/{p-3f41285f.entry.js → p-b2ab5bdc.entry.js} +1 -1
- package/dist/ketchup/{p-7585373e.entry.js → p-bdbcb755.entry.js} +1 -1
- package/dist/ketchup/p-cf2bf043.entry.js +1 -0
- package/dist/ketchup/{p-9b92dd8f.entry.js → p-d08d30c0.entry.js} +1 -1
- package/dist/ketchup/{p-4c0d6ec5.entry.js → p-e0fec6c7.entry.js} +1 -1
- package/dist/ketchup/p-e736bf6f.js +1 -0
- package/dist/ketchup/{p-50b0da0c.entry.js → p-e8823224.entry.js} +1 -1
- package/dist/ketchup/{p-7a4f5182.js → p-ee85055c.js} +1 -1
- package/dist/ketchup/{p-7fbb8a80.entry.js → p-f705d641.entry.js} +1 -1
- package/dist/ketchup/{p-60e8333c.entry.js → p-febf0250.entry.js} +1 -1
- package/dist/types/components/kup-time-picker/kup-time-picker.d.ts +7 -1
- package/dist/types/components.d.ts +10 -0
- package/dist/types/f-components/f-paginator/f-paginator-declarations.d.ts +1 -0
- package/dist/types/managers/kup-language/kup-language-declarations.d.ts +1 -2
- package/dist/types/utils/filters/filters.d.ts +2 -0
- package/dist/types/utils/kup-column-menu/kup-column-menu-declarations.d.ts +1 -3
- package/package.json +1 -1
- package/dist/ketchup/p-1206f77c.entry.js +0 -9
- package/dist/ketchup/p-35e17994.entry.js +0 -1
- package/dist/ketchup/p-7a36e244.js +0 -1
- package/dist/ketchup/p-c5614700.js +0 -21
- package/dist/ketchup/p-d104a456.js +0 -1
- package/dist/ketchup/p-eb908331.entry.js +0 -1
- package/dist/ketchup/p-f8c8cc84.js +0 -1
|
@@ -1359,7 +1359,7 @@ export class KupDataTable {
|
|
|
1359
1359
|
}
|
|
1360
1360
|
let rows = null;
|
|
1361
1361
|
if (__classPrivateFieldGet(this, _KupDataTable_paginatedRowsLength, "f") === 0) {
|
|
1362
|
-
rows = (h("tr", { key: '
|
|
1362
|
+
rows = (h("tr", { key: 'ea30d657d452f653830e1e1f66b5008d4f2750a8', ref: (el) => __classPrivateFieldGet(this, _KupDataTable_rowsRefs, "f").push(el) }, h("td", { key: '2a626690b99a48a3bd57e33a1a44b5777ce9fab5', colSpan: __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_calculateColspan).call(this) }, this.emptyDataLabel)));
|
|
1363
1363
|
}
|
|
1364
1364
|
else {
|
|
1365
1365
|
rows = [];
|
|
@@ -1424,7 +1424,7 @@ export class KupDataTable {
|
|
|
1424
1424
|
for (let i = 0; i < chipsData.length; i++) {
|
|
1425
1425
|
props.onIconClick.push(() => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_removeGroup).call(this, i));
|
|
1426
1426
|
}
|
|
1427
|
-
groupChips = h(FChip, Object.assign({ key: '
|
|
1427
|
+
groupChips = h(FChip, Object.assign({ key: '9d0eb6f3b9839467a794e3c47f69c80c29ce7cb3' }, props));
|
|
1428
1428
|
}
|
|
1429
1429
|
}
|
|
1430
1430
|
const tableClass = {
|
|
@@ -1456,7 +1456,7 @@ export class KupDataTable {
|
|
|
1456
1456
|
if (this.headerIsPersistent &&
|
|
1457
1457
|
this.tableHeight === undefined &&
|
|
1458
1458
|
this.tableWidth === undefined) {
|
|
1459
|
-
stickyEl = (h("sticky-header", { key: '
|
|
1459
|
+
stickyEl = (h("sticky-header", { key: '6b2b15b4385868240dfd25952bdb73b4a741622e', class: "hover-scrolling-child", hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_stickyTheadRef, el, "f")) }, h("thead-sticky", { key: '3e04b58f8d4eaa1a74fa5c73b793e7530a4330a3' }, h("tr-sticky", { key: '9845f4d6ae194aa477c298cd968c94844dc96f43' }, stickyHeader))));
|
|
1460
1460
|
}
|
|
1461
1461
|
let belowClass = 'below-wrapper';
|
|
1462
1462
|
if (!!this.tableHeight || !!this.tableWidth) {
|
|
@@ -1502,7 +1502,7 @@ export class KupDataTable {
|
|
|
1502
1502
|
const useGlobalFilter = !this.legacyLook &&
|
|
1503
1503
|
(this.globalFilter ||
|
|
1504
1504
|
this.getRows().length > __classPrivateFieldGet(this, _KupDataTable_DEFAULT_ROWS_FOR_GLOBAL_FILTER, "f"));
|
|
1505
|
-
const compCreated = (h(Host, { key: '
|
|
1505
|
+
const compCreated = (h(Host, { key: '81f74f20c67ec6257b42550b0d2db73331d96c07', "onKup-drop": (e) => {
|
|
1506
1506
|
this.kupDataTableDrop.emit(e.detail);
|
|
1507
1507
|
}, "onKup-cell-input": (e) => {
|
|
1508
1508
|
autoselectOnAction(e);
|
|
@@ -1517,11 +1517,11 @@ export class KupDataTable {
|
|
|
1517
1517
|
this.kupDataTableObjectFieldOpenSearchMenu.emit(e.detail);
|
|
1518
1518
|
}, "onKup-objectfield-selectedmenuitem": (e) => {
|
|
1519
1519
|
this.kupDataTableObjectFieldSelectedMenuItem.emit(e.detail);
|
|
1520
|
-
} }, h("style", { key: '
|
|
1520
|
+
} }, h("style", { key: '8c92d3bc0a8e1326b5ddbc7bdaa3260d601f53c3' }, __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").theme.setKupStyle(this.rootElement)), this.updatableData ? __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_renderUpdateButtons).call(this) : null, h("div", { key: '89e186b2a02d79de60a5fc7feffb0282ecd5a24d', id: componentWrapperId, class: wrapClass }, h("div", { key: '8452e8191ab0b8e215c2b9b4901cb1be22217c26', class: "group-wrapper" }, groupChips), h("div", { key: 'e3da08d27329bf8a011511e9f71015db2b572749', class: "actions-wrapper", style: actionWrapperWidth }, useGlobalFilter ? (h("div", { id: "global-filter" }, h(FTextField, { fullWidth: true, icon: KupThemeIconValues.SEARCH, label: __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageSearch.SEARCH), value: this.globalFilterValue, onInput: (event) => {
|
|
1521
1521
|
const t = event.target;
|
|
1522
1522
|
window.clearTimeout(__classPrivateFieldGet(this, _KupDataTable_globalFilterTimeout, "f"));
|
|
1523
1523
|
__classPrivateFieldSet(this, _KupDataTable_globalFilterTimeout, window.setTimeout(() => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_onGlobalFilterChange).call(this, t), 600, t), "f");
|
|
1524
|
-
} }))) : null, h("div", { key: '
|
|
1524
|
+
} }))) : null, h("div", { key: '753ac29c5b69f2dfddd67cb6da36d8cb26cef314', class: "above-wrapper paginator-top" }, paginatorTop), this.insertMode !== '' &&
|
|
1525
1525
|
this.selectedRows.length > 0 ? (h(FButton, { icon: "save", onClick: () => {
|
|
1526
1526
|
this.kupSave.emit({
|
|
1527
1527
|
comp: this,
|
|
@@ -1571,9 +1571,9 @@ export class KupDataTable {
|
|
|
1571
1571
|
this.data.rows.unshift(row);
|
|
1572
1572
|
await this.refresh(true);
|
|
1573
1573
|
}
|
|
1574
|
-
}, sizing: KupComponentSizing.MEDIUM, styling: FButtonStyling.RAISED, title: "Insert row", wrapperClass: "insert-button" })) : null), h("div", { key: '
|
|
1574
|
+
}, sizing: KupComponentSizing.MEDIUM, styling: FButtonStyling.RAISED, title: "Insert row", wrapperClass: "insert-button" })) : null), h("div", { key: '2d6a2b4c9b87c32a50d0f4d138295b73a37f96fc', class: "droparea", ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_dropareaRef, el, "f")) }, this.showGroups ? __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_columnGroupArea).call(this) : null, this.removableColumns
|
|
1575
1575
|
? __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_columnRemoveArea).call(this)
|
|
1576
|
-
: null), h("div", { key: '
|
|
1576
|
+
: null), h("div", { key: 'fb0a474697046649a11d2986dba9c80cca413561', style: elStyle, class: belowClass, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_tableAreaRef, el, "f")) }, this.showCustomization
|
|
1577
1577
|
? [
|
|
1578
1578
|
h("div", { class: "settings-trigger", onClick: () => {
|
|
1579
1579
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_onCustomSettingsClick).call(this);
|
|
@@ -1582,7 +1582,7 @@ export class KupDataTable {
|
|
|
1582
1582
|
} }, h(FImage, { color: `var(${KupThemeColorValues.TITLE})`, resource: "settings", sizeX: "10px" })),
|
|
1583
1583
|
this.renderCustomizePanel(),
|
|
1584
1584
|
]
|
|
1585
|
-
: null, h("table", { key: '
|
|
1585
|
+
: null, h("table", { key: '0a507c2b3807f911389bda77eeb9bceee0da6fee', class: tableClass, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_tableRef, el, "f")), onMouseLeave: (ev) => {
|
|
1586
1586
|
ev.stopPropagation();
|
|
1587
1587
|
}, onPointerDown: (e) => {
|
|
1588
1588
|
__classPrivateFieldSet(this, _KupDataTable_lastPointerDetails, __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").getEventPath(e.target, this.rootElement), e), "f");
|
|
@@ -1590,7 +1590,7 @@ export class KupDataTable {
|
|
|
1590
1590
|
__classPrivateFieldSet(this, _KupDataTable_lastPointerDetails, __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").getEventPath(e.target, this.rootElement), e), "f");
|
|
1591
1591
|
}, onContextMenu: (e) => {
|
|
1592
1592
|
e.preventDefault();
|
|
1593
|
-
} }, h("thead", { key: '
|
|
1593
|
+
} }, h("thead", { key: '9754f63d55e351c03547bbd07cb606a14b2bfd00', hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_theadRef, el, "f")) }, h("tr", { key: 'dc314b347496493f6900b6677d95a51153faf73c' }, header)), h("tbody", { key: 'a350636de75f0ab072c80f54558c150e228a9bff' }, rows), this.showFooter || __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_hasTotals).call(this)
|
|
1594
1594
|
? this.renderFooter()
|
|
1595
1595
|
: null), stickyEl), paginatorBottom)));
|
|
1596
1596
|
return compCreated;
|
|
@@ -6381,7 +6381,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
6381
6381
|
? () => {
|
|
6382
6382
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_onLoadMoreClick).call(this);
|
|
6383
6383
|
}
|
|
6384
|
-
: null, onNextPage: () => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage + 1), onPrevPage: () => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage - 1), onPageChange: (e) => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, e.detail.value), onRowsChange: (e) => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handleRowsPerPageChange).call(this, e.detail.value) })) : null)));
|
|
6384
|
+
: null, onNextPage: () => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage + 1), onPrevPage: () => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage - 1), onPageChange: (e) => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, e.detail.value), onRowsChange: (e) => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_handleRowsPerPageChange).call(this, e.detail.value), showMaxPages: true })) : null)));
|
|
6385
6385
|
}, _KupDataTable_columnRemoveArea = function _KupDataTable_columnRemoveArea() {
|
|
6386
6386
|
return (h("div", { class: "droparea__remove", ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_removeDropareaRef, el, "f")) }, h(FImage, { resource: "delete", color: `var(${KupThemeColorValues.DANGER})`, sizeX: "30px", sizeY: "50px" }), h(FImage, { resource: "delete-empty", color: `var(${KupThemeColorValues.DANGER})`, sizeX: "30px", sizeY: "50px" })));
|
|
6387
6387
|
}, _KupDataTable_columnGroupArea = function _KupDataTable_columnGroupArea() {
|
|
@@ -10,7 +10,6 @@ import { FTextFieldMDC } from "../../f-components/f-text-field/f-text-field-mdc"
|
|
|
10
10
|
import { KupDynamicPositionPlacement } from "../../managers/kup-dynamic-position/kup-dynamic-position-declarations";
|
|
11
11
|
import { KupCardFamily, } from "../kup-card/kup-card-declarations";
|
|
12
12
|
import { getProps } from "../../utils/utils";
|
|
13
|
-
import { FILTER_ANALYZER } from "../../utils/filters/filters-declarations";
|
|
14
13
|
export class KupDatePicker {
|
|
15
14
|
constructor() {
|
|
16
15
|
/*-------------------------------------------------*/
|
|
@@ -59,7 +58,8 @@ export class KupDatePicker {
|
|
|
59
58
|
this.setFocus();
|
|
60
59
|
}
|
|
61
60
|
async onKupClearIconClick() {
|
|
62
|
-
this.
|
|
61
|
+
this.notISOvalue = '';
|
|
62
|
+
this.ISOvalue = '';
|
|
63
63
|
this.kupChange.emit({
|
|
64
64
|
comp: this,
|
|
65
65
|
id: this.rootElement.id,
|
|
@@ -189,8 +189,6 @@ export class KupDatePicker {
|
|
|
189
189
|
this.notISOvalue = newValue;
|
|
190
190
|
this.ISOvalue = '';
|
|
191
191
|
if (eventDetailValue) {
|
|
192
|
-
const isValidFilter = this.isAlphanumeric(eventDetailValue) ||
|
|
193
|
-
eventDetailValue.match(FILTER_ANALYZER);
|
|
194
192
|
if (this.kupManager.dates.isIsoDate(eventDetailValue)) {
|
|
195
193
|
if (!isOnInputEvent) {
|
|
196
194
|
this.ISOvalue = eventDetailValue;
|
|
@@ -199,7 +197,7 @@ export class KupDatePicker {
|
|
|
199
197
|
}
|
|
200
198
|
}
|
|
201
199
|
}
|
|
202
|
-
else if (!
|
|
200
|
+
else if (!this.isAlphanumeric(eventDetailValue) &&
|
|
203
201
|
this.kupManager.dates.isValidFormattedStringDate(eventDetailValue)) {
|
|
204
202
|
if (!this.appendSelection) {
|
|
205
203
|
newValue = this.kupManager.dates.format(this.kupManager.dates.normalize(eventDetailValue), KupDatesFormats.ISO_DATE);
|
|
@@ -393,7 +391,7 @@ export class KupDatePicker {
|
|
|
393
391
|
showPreviousNextMonthDays: this.showPreviousNextMonthDays,
|
|
394
392
|
},
|
|
395
393
|
};
|
|
396
|
-
return (h(Host, { key: '
|
|
394
|
+
return (h(Host, { key: 'a34c724df5cebefad71037b7433ce6ddd48843d9' }, h("style", { key: '58bed40aa79d827b144b2142f4ff316b1005c2fc' }, this.kupManager.theme.setKupStyle(this.rootElement)), h("div", { key: 'b1a2a5028dc887c0199724f468ab28c9aa097af4', id: componentWrapperId }, h(FTextField, Object.assign({ key: 'a084c9d9246cfc7178b8a8128431a452531756a3' }, textfieldData, { disabled: this.disabled, fullHeight: fullHeight, fullWidth: fullWidth, maxLength: (_a = textfieldData.maxLength) !== null && _a !== void 0 ? _a : 10, id: this.rootElement.id + '_text-field', value: this.getDateForOutput(), onBlur: () => this.onKupBlur(), onChange: (e) => this.onKupChange(e), onClearIconClick: () => this.onKupClearIconClick(), onClick: () => this.onKupClick(), onFocus: () => this.onKupFocus(), onIconClick: () => this.onKupIconClick(), onKeyDown: (e) => this.onKupTextFieldSubmit(e), onInput: (e) => this.onKupInput(e) }), h("div", { key: '13923ba29c9fa87fc2afc37f673b6144fe6726bb', id: this.rootElement.id + '_card', class: "kup-date-picker-card" }, h("kup-card", { key: 'f6ca569f4a012218fa6ca1f3ceab7add60bebeb2', ref: (el) => (this.pickerContainerEl = el), data: cardData, layoutFamily: KupCardFamily.BUILT_IN, sizeX: "300px", sizeY: "auto", isMenu: true, "onkup-card-click": (ev) => {
|
|
397
395
|
if (ev.detail.value != null &&
|
|
398
396
|
ev.detail.value != '')
|
|
399
397
|
this.onKupDatePickerItemClick(ev.detail.value);
|
|
@@ -294,7 +294,7 @@ export class KupList {
|
|
|
294
294
|
}
|
|
295
295
|
__classPrivateFieldSet(this, _KupList_radios, [], "f");
|
|
296
296
|
let index = 0;
|
|
297
|
-
return (h(Host, { key: '
|
|
297
|
+
return (h(Host, { key: '019466462728adce2c66ee71c4fd95713d89e3a5' }, h("style", { key: 'f609290da0c5808fa0845d91ef3131bfa19926cd' }, __classPrivateFieldGet(this, _KupList_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { key: 'e414b17c9d7900edf727da873bec99f1e3442d25', id: "kup-component", class: wrapperClass, onKeyDown: __classPrivateFieldGet(this, _KupList_listenKeydown, "f") }, this.showFilter ? (h("div", { class: filterClass }, __classPrivateFieldGet(this, _KupList_instances, "m", _KupList_createFilterComponent).call(this))) : null, h("div", { key: '5c20fc00e945da4693ea4421d94dd3177fdcf0bc', class: listScrollClass }, h("ul", { key: '336830edca97a6399815349a569b7b7367a070a1', class: componentClass, role: roleAttr, "aria-multiselectable": ariaMultiSelectable }, this.data
|
|
298
298
|
.filter((item) => __classPrivateFieldGet(this, _KupList_instances, "m", _KupList_itemCompliant).call(this, item))
|
|
299
299
|
.map((item) => __classPrivateFieldGet(this, _KupList_instances, "m", _KupList_renderListItem).call(this, item, index++)))))));
|
|
300
300
|
}
|
|
@@ -1055,11 +1055,12 @@ _KupList_kupManager = new WeakMap(), _KupList_inputEl = new WeakMap(), _KupList_
|
|
|
1055
1055
|
this.roleType = KupListRole.LISTBOX;
|
|
1056
1056
|
}
|
|
1057
1057
|
}, _KupList_itemCompliant = function _KupList_itemCompliant(item) {
|
|
1058
|
+
var _a, _b;
|
|
1058
1059
|
if (!this.filter) {
|
|
1059
1060
|
return true;
|
|
1060
1061
|
}
|
|
1061
|
-
return (item.id.toLowerCase().indexOf(this.filter.toLowerCase()) >= 0 ||
|
|
1062
|
-
item.value.toLowerCase().indexOf(this.filter.toLowerCase()) >= 0);
|
|
1062
|
+
return (((_a = item.id) === null || _a === void 0 ? void 0 : _a.toLowerCase().indexOf(this.filter.toLowerCase())) >= 0 ||
|
|
1063
|
+
((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLowerCase().indexOf(this.filter.toLowerCase())) >= 0);
|
|
1063
1064
|
}, _KupList_createFilterComponent = function _KupList_createFilterComponent() {
|
|
1064
1065
|
return (h("div", { id: "global-filter", class: "filter" }, h(FTextField, { fullWidth: true, label: __classPrivateFieldGet(this, _KupList_kupManager, "f").language.translate(KupLanguageSearch.SEARCH), icon: KupThemeIconValues.SEARCH, value: this.filter, onInput: (event) => {
|
|
1065
1066
|
this.onFilterValueChange(event);
|
|
@@ -9,6 +9,7 @@ import { FTextFieldMDC } from "../../f-components/f-text-field/f-text-field-mdc"
|
|
|
9
9
|
import { KupCardFamily, } from "../kup-card/kup-card-declarations";
|
|
10
10
|
import { KupDynamicPositionPlacement } from "../../managers/kup-dynamic-position/kup-dynamic-position-declarations";
|
|
11
11
|
import { KupDatesFormats } from "../../managers/kup-dates/kup-dates-declarations";
|
|
12
|
+
import { FILTER_ANALYZER } from "../../utils/filters/filters-declarations";
|
|
12
13
|
export class KupTimePicker {
|
|
13
14
|
constructor() {
|
|
14
15
|
/*-------------------------------------------------*/
|
|
@@ -26,6 +27,7 @@ export class KupTimePicker {
|
|
|
26
27
|
this.pickerKupEl = undefined;
|
|
27
28
|
this.clickCb = null;
|
|
28
29
|
this.value = '';
|
|
30
|
+
this.appendSelection = false;
|
|
29
31
|
this.clockVariant = true;
|
|
30
32
|
this.customStyle = '';
|
|
31
33
|
this.data = {};
|
|
@@ -55,12 +57,12 @@ export class KupTimePicker {
|
|
|
55
57
|
});
|
|
56
58
|
this.setFocus();
|
|
57
59
|
}
|
|
58
|
-
onKupClearIconClick() {
|
|
59
|
-
this.
|
|
60
|
+
async onKupClearIconClick() {
|
|
61
|
+
this.value = '';
|
|
60
62
|
this.kupChange.emit({
|
|
61
63
|
comp: this,
|
|
62
64
|
id: this.rootElement.id,
|
|
63
|
-
value: this.
|
|
65
|
+
value: await this.getValue(),
|
|
64
66
|
});
|
|
65
67
|
this.kupClearIconClick.emit({
|
|
66
68
|
comp: this,
|
|
@@ -201,11 +203,13 @@ export class KupTimePicker {
|
|
|
201
203
|
}
|
|
202
204
|
refreshPickerValue(eventDetailValue, eventToRaise) {
|
|
203
205
|
let newValue = null;
|
|
204
|
-
|
|
206
|
+
const isValidFilter = FILTER_ANALYZER.test(eventDetailValue);
|
|
207
|
+
if (this.kupManager.dates.isValidFormattedStringTime(eventDetailValue, this.manageSeconds) ||
|
|
208
|
+
isValidFilter) {
|
|
205
209
|
this.value = eventDetailValue;
|
|
206
210
|
newValue = this.value;
|
|
207
211
|
}
|
|
208
|
-
if (newValue != null) {
|
|
212
|
+
if (newValue != null && eventToRaise) {
|
|
209
213
|
eventToRaise.emit({
|
|
210
214
|
comp: this,
|
|
211
215
|
id: this.rootElement.id,
|
|
@@ -227,7 +231,17 @@ export class KupTimePicker {
|
|
|
227
231
|
if (newValue == null) {
|
|
228
232
|
return;
|
|
229
233
|
}
|
|
230
|
-
this.
|
|
234
|
+
if (this.appendSelection && newValue) {
|
|
235
|
+
// Append behavior: combine current value with the new one
|
|
236
|
+
const currentValue = this.textfieldEl.value;
|
|
237
|
+
const formattedDate = this.kupManager.dates.timeStringToFormattedString(newValue, this.manageSeconds);
|
|
238
|
+
const combinedValue = currentValue + formattedDate;
|
|
239
|
+
this.refreshPickerValue(combinedValue, undefined);
|
|
240
|
+
}
|
|
241
|
+
else {
|
|
242
|
+
// Default behavior: replace the entire value
|
|
243
|
+
this.value = newValue;
|
|
244
|
+
}
|
|
231
245
|
}
|
|
232
246
|
getPickerValueSelected() {
|
|
233
247
|
return this.value;
|
|
@@ -311,10 +325,13 @@ export class KupTimePicker {
|
|
|
311
325
|
return idConc.indexOf('#' + id + '#') >= 0;
|
|
312
326
|
}
|
|
313
327
|
prepTimePicker() {
|
|
328
|
+
const startingValue = this.kupManager.dates.isValidFormattedStringTime(this.value, this.manageSeconds)
|
|
329
|
+
? this.getTimeForOutput()
|
|
330
|
+
: '';
|
|
314
331
|
if (this.clockVariant) {
|
|
315
332
|
const data = {
|
|
316
333
|
options: {
|
|
317
|
-
initialValue:
|
|
334
|
+
initialValue: startingValue,
|
|
318
335
|
manageSeconds: this.manageSeconds,
|
|
319
336
|
hoursActive: this.hoursActive,
|
|
320
337
|
minutesActive: this.minutesActive,
|
|
@@ -327,7 +344,7 @@ export class KupTimePicker {
|
|
|
327
344
|
} }));
|
|
328
345
|
}
|
|
329
346
|
else {
|
|
330
|
-
return (h("kup-list", { ref: (el) => (this.pickerKupEl = el), data: this.createTimeListData(
|
|
347
|
+
return (h("kup-list", { ref: (el) => (this.pickerKupEl = el), data: this.createTimeListData(startingValue), "is-menu": true, "onkup-list-click": (e) => this.onKupTimePickerItemClick(e, e.detail.selected.id), id: this.rootElement.id + '_list' }));
|
|
331
348
|
}
|
|
332
349
|
}
|
|
333
350
|
createTimeListData(value) {
|
|
@@ -369,6 +386,9 @@ export class KupTimePicker {
|
|
|
369
386
|
if (this.value == null || this.value.trim() == '') {
|
|
370
387
|
return '';
|
|
371
388
|
}
|
|
389
|
+
if (FILTER_ANALYZER.test(this.value)) {
|
|
390
|
+
return this.value;
|
|
391
|
+
}
|
|
372
392
|
let v1 = this.kupManager.dates.timeStringToFormattedString(this.value, this.manageSeconds);
|
|
373
393
|
return v1;
|
|
374
394
|
}
|
|
@@ -407,7 +427,7 @@ export class KupTimePicker {
|
|
|
407
427
|
this.kupManager.debug.logRender(this, true);
|
|
408
428
|
}
|
|
409
429
|
render() {
|
|
410
|
-
return (h(Host, { key: '
|
|
430
|
+
return (h(Host, { key: '3f6acf44358187ab49855ca4be0e34245b20e8e9' }, h("style", { key: '0d82d42fee59676ac79dda83487ea09df4c0278f' }, this.kupManager.theme.setKupStyle(this.rootElement)), h("div", { key: 'd4a2fae6357fbce735b13157261ed054e9402bd6', id: componentWrapperId }, this.prepTextfield(this.getTimeForOutput()))));
|
|
411
431
|
}
|
|
412
432
|
disconnectedCallback() {
|
|
413
433
|
this.kupManager.dates.unregister(this);
|
|
@@ -430,6 +450,27 @@ export class KupTimePicker {
|
|
|
430
450
|
}
|
|
431
451
|
static get properties() {
|
|
432
452
|
return {
|
|
453
|
+
"appendSelection": {
|
|
454
|
+
"type": "boolean",
|
|
455
|
+
"mutable": false,
|
|
456
|
+
"complexType": {
|
|
457
|
+
"original": "boolean",
|
|
458
|
+
"resolved": "boolean",
|
|
459
|
+
"references": {}
|
|
460
|
+
},
|
|
461
|
+
"required": false,
|
|
462
|
+
"optional": false,
|
|
463
|
+
"docs": {
|
|
464
|
+
"tags": [{
|
|
465
|
+
"name": "default",
|
|
466
|
+
"text": "false"
|
|
467
|
+
}],
|
|
468
|
+
"text": "When set to true, the selected date will be appended to the current value\r\ninstead of replacing it."
|
|
469
|
+
},
|
|
470
|
+
"attribute": "append-selection",
|
|
471
|
+
"reflect": false,
|
|
472
|
+
"defaultValue": "false"
|
|
473
|
+
},
|
|
433
474
|
"clockVariant": {
|
|
434
475
|
"type": "boolean",
|
|
435
476
|
"mutable": false,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
+
import { ItemsDisplayMode, } from "../../components/kup-list/kup-list-declarations";
|
|
2
3
|
import { KupLanguageGeneric, KupLanguagePage, KupLanguageRow, } from "../../managers/kup-language/kup-language-declarations";
|
|
3
4
|
import { FButton } from "../f-button/f-button";
|
|
4
5
|
import { FButtonStyling } from "../f-button/f-button-declarations";
|
|
@@ -10,7 +11,10 @@ const dom = document.documentElement;
|
|
|
10
11
|
/*-------------------------------------------------*/
|
|
11
12
|
export const FPaginator = (props) => {
|
|
12
13
|
if (!props.perPage) {
|
|
13
|
-
props.perPage =
|
|
14
|
+
props.perPage = 1000;
|
|
15
|
+
}
|
|
16
|
+
if (props.perPage > props.max) {
|
|
17
|
+
props.perPage = props.max;
|
|
14
18
|
}
|
|
15
19
|
const maxNumberOfPage = Math.ceil(props.max / props.perPage);
|
|
16
20
|
const pageItems = getPageItems(props, maxNumberOfPage);
|
|
@@ -18,6 +22,7 @@ export const FPaginator = (props) => {
|
|
|
18
22
|
const dataPageSelector = {
|
|
19
23
|
'kup-list': {
|
|
20
24
|
data: pageItems,
|
|
25
|
+
displayMode: ItemsDisplayMode.CODE,
|
|
21
26
|
},
|
|
22
27
|
'kup-text-field': {
|
|
23
28
|
label: dom.ketchup.language.translate(KupLanguagePage.PAGE),
|
|
@@ -27,11 +32,13 @@ export const FPaginator = (props) => {
|
|
|
27
32
|
inputType: 'number',
|
|
28
33
|
max: maxNumberOfPage,
|
|
29
34
|
min: 1,
|
|
35
|
+
size: 5,
|
|
30
36
|
},
|
|
31
37
|
};
|
|
32
38
|
const dataRowsSelector = {
|
|
33
39
|
'kup-list': {
|
|
34
40
|
data: rowsPerPageItems,
|
|
41
|
+
displayMode: ItemsDisplayMode.CODE,
|
|
35
42
|
},
|
|
36
43
|
'kup-text-field': {
|
|
37
44
|
label: dom.ketchup.language.translate(KupLanguageRow.ROWS) +
|
|
@@ -43,9 +50,10 @@ export const FPaginator = (props) => {
|
|
|
43
50
|
inputType: 'number',
|
|
44
51
|
max: props.max,
|
|
45
52
|
min: 1,
|
|
53
|
+
size: 5,
|
|
46
54
|
},
|
|
47
55
|
};
|
|
48
|
-
return (h("div", Object.assign({ class: `f-paginator ${props.mode ? props.mode : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }), props.onLoadMore ? (h(FButton, { icon: "plus", onClick: props.onLoadMore, label: dom.ketchup.language.translate(KupLanguageGeneric.LOAD_MORE), sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "load-more-button kup-neutral" })) : null, h("kup-combobox", { class: "rows-selector", data: dataRowsSelector, initialValue: props.perPage.toString(), "onkup-combobox-change": props.onRowsChange }), h("kup-combobox", { class: "page-selector", data: dataPageSelector, initialValue: props.currentPage.toString(), "onkup-combobox-change": props.onPageChange }), h("div", { class: "arrow-wrapper" }, props.mode !== FPaginatorMode.SIMPLE ? (h(FButton, { icon: "chevron_left", disabled: isPrevPageDisabled(props), onClick: props.onPrevPage, sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "kup-neutral prev-page" })) : null, props.mode !== FPaginatorMode.SIMPLE ? (h(FButton, { icon: "chevron_right", disabled: isNextPageDisabled(props), onClick: props.onNextPage, sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "kup-neutral next-page" })) : null)));
|
|
56
|
+
return (h("div", Object.assign({ class: `f-paginator ${props.mode ? props.mode : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }), props.onLoadMore ? (h(FButton, { icon: "plus", onClick: props.onLoadMore, label: dom.ketchup.language.translate(KupLanguageGeneric.LOAD_MORE), sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "load-more-button kup-neutral" })) : null, h("kup-combobox", { class: "rows-selector", data: dataRowsSelector, displayMode: ItemsDisplayMode.CODE, initialValue: props.perPage.toString(), initialValueDecode: props.perPage.toString(), "onkup-combobox-change": props.onRowsChange }), h("kup-combobox", { class: "page-selector", data: dataPageSelector, displayMode: ItemsDisplayMode.CODE, initialValue: props.currentPage.toString(), initialValueDecode: props.currentPage.toString(), "onkup-combobox-change": props.onPageChange }), props.showMaxPages ? (h("div", { class: "max-page-wrapper" }, h("label", { htmlFor: "page-selector" }, '/ ' + maxNumberOfPage))) : null, h("div", { class: "arrow-wrapper" }, props.mode !== FPaginatorMode.SIMPLE ? (h(FButton, { icon: "chevron_left", disabled: isPrevPageDisabled(props), onClick: props.onPrevPage, sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "kup-neutral prev-page" })) : null, props.mode !== FPaginatorMode.SIMPLE ? (h(FButton, { icon: "chevron_right", disabled: isNextPageDisabled(props), onClick: props.onNextPage, sizing: KupComponentSizing.SMALL, styling: FButtonStyling.FLAT, wrapperClass: "kup-neutral next-page" })) : null)));
|
|
49
57
|
};
|
|
50
58
|
function getPageItems(props, maxNumberOfPage) {
|
|
51
59
|
const pageItems = [];
|
|
@@ -30,6 +30,7 @@ export class KupData {
|
|
|
30
30
|
return replaceCell(dataset, cell, columns);
|
|
31
31
|
},
|
|
32
32
|
getType(cell, shape) {
|
|
33
|
+
var _a;
|
|
33
34
|
const obj = cell.obj;
|
|
34
35
|
if (shape) {
|
|
35
36
|
switch (shape.toUpperCase()) {
|
|
@@ -136,6 +137,9 @@ export class KupData {
|
|
|
136
137
|
else if (dom.ketchup.objects.isVoCodver(obj)) {
|
|
137
138
|
return FCellTypes.ICON;
|
|
138
139
|
}
|
|
140
|
+
else if (((_a = cell.data) === null || _a === void 0 ? void 0 : _a.maxLength) >= 256) {
|
|
141
|
+
return FCellTypes.MEMO;
|
|
142
|
+
}
|
|
139
143
|
else {
|
|
140
144
|
return FCellTypes.STRING;
|
|
141
145
|
}
|
|
@@ -69,7 +69,18 @@ export class KupDynamicPosition {
|
|
|
69
69
|
const target = mutations[0].target;
|
|
70
70
|
if (target.classList.contains(kupDynamicPositionActiveClass)) {
|
|
71
71
|
self.addRepositionListeners(el);
|
|
72
|
-
self.run(el)
|
|
72
|
+
// Call self.run(el) only after the element's dimensions are valid
|
|
73
|
+
const ro = new ResizeObserver((entries) => {
|
|
74
|
+
for (const entry of entries) {
|
|
75
|
+
const newH = entry.contentRect.height;
|
|
76
|
+
const newW = entry.contentRect.width;
|
|
77
|
+
if (newH > 0 && newW > 0) {
|
|
78
|
+
self.run(el);
|
|
79
|
+
ro.unobserve(el);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
ro.observe(el);
|
|
73
84
|
}
|
|
74
85
|
});
|
|
75
86
|
mutObserver.observe(el, {
|
|
@@ -194,9 +194,8 @@ export var KupLanguageRow;
|
|
|
194
194
|
*/
|
|
195
195
|
export var KupLanguageSearch;
|
|
196
196
|
(function (KupLanguageSearch) {
|
|
197
|
-
KupLanguageSearch["FROM"] = "searchFrom";
|
|
198
197
|
KupLanguageSearch["SEARCH"] = "searchSearch";
|
|
199
|
-
KupLanguageSearch["
|
|
198
|
+
KupLanguageSearch["TOOLTIP"] = "searchTooltip";
|
|
200
199
|
})(KupLanguageSearch || (KupLanguageSearch = {}));
|
|
201
200
|
/**
|
|
202
201
|
* Footer totals decodes (tree and data table).
|
|
@@ -133,25 +133,15 @@ export class FiltersColumnMenu extends Filters {
|
|
|
133
133
|
* @param {string} remFilter - Removed filter.
|
|
134
134
|
*/
|
|
135
135
|
removeCheckboxFilter(filters = {}, column, remFilter) {
|
|
136
|
-
|
|
136
|
+
var _a;
|
|
137
|
+
if (!filters || !remFilter || !filters[column]) {
|
|
137
138
|
return;
|
|
138
139
|
}
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
filter.checkBoxes = [];
|
|
145
|
-
}
|
|
146
|
-
let index = Filters.indexOfValueInValuesArray(filter.checkBoxes, remFilter);
|
|
147
|
-
if (index >= 0) {
|
|
148
|
-
let chs = [];
|
|
149
|
-
for (let i = 0; i < filter.checkBoxes.length; i++) {
|
|
150
|
-
if (i != index) {
|
|
151
|
-
chs[chs.length] = filter.checkBoxes[i];
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
filter.checkBoxes = [...chs];
|
|
140
|
+
const filter = filters[column];
|
|
141
|
+
filter.checkBoxes = (_a = filter.checkBoxes) !== null && _a !== void 0 ? _a : [];
|
|
142
|
+
filter.checkBoxes = filter.checkBoxes.filter((item) => item.value !== remFilter);
|
|
143
|
+
if (filter.checkBoxes.length === 0) {
|
|
144
|
+
delete filters[column];
|
|
155
145
|
}
|
|
156
146
|
}
|
|
157
147
|
isColumnNumeric(column) {
|
|
@@ -216,10 +206,6 @@ export class FiltersColumnMenu extends Filters {
|
|
|
216
206
|
* @param {string} column - Name of the column.
|
|
217
207
|
*/
|
|
218
208
|
removeFilter(filters = {}, column) {
|
|
219
|
-
filters[column]
|
|
220
|
-
textField: '',
|
|
221
|
-
textFieldTmp: '',
|
|
222
|
-
checkBoxes: [],
|
|
223
|
-
};
|
|
209
|
+
delete filters[column];
|
|
224
210
|
}
|
|
225
211
|
}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* @property {string} 4 - Either % or null: indicates the string must finish with the given string.
|
|
10
10
|
* This regex ignores spaces at the beginning, at the end, and between the operator and the quoted value.
|
|
11
11
|
*/
|
|
12
|
-
export const FILTER_ANALYZER = /^\s*(
|
|
12
|
+
export const FILTER_ANALYZER = /^\s*(<=|>=|!|>|<)?\s*'?(%)?(.*?)(%)?'?\s*$/;
|
|
13
13
|
export var KupGlobalFilterMode;
|
|
14
14
|
(function (KupGlobalFilterMode) {
|
|
15
15
|
KupGlobalFilterMode["SIMPLE"] = "simple";
|
|
@@ -75,64 +75,41 @@ export class FiltersRows extends Filters {
|
|
|
75
75
|
if (!this.hasFilters(filters, columns, columnFilters)) {
|
|
76
76
|
return true;
|
|
77
77
|
}
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
for (let i = 0; i < keys.length; i++) {
|
|
81
|
-
let key = keys[i];
|
|
78
|
+
// Filters must match for every key in filters
|
|
79
|
+
return Object.keys(filters).every((key) => {
|
|
82
80
|
const cell = cells[key];
|
|
81
|
+
const currentColumn = getColumnByName(columns, key);
|
|
83
82
|
if (!cell) {
|
|
84
83
|
return false;
|
|
85
84
|
}
|
|
86
85
|
let filterValue = columnFilters.getTextFilterValue(filters, key);
|
|
86
|
+
let checkboxValues = columnFilters.getCheckBoxFilterValues(filters, key);
|
|
87
87
|
const _filterIsNegative = this.filterIsNegative(filterValue);
|
|
88
|
-
let b1 =
|
|
88
|
+
let b1 = (filterValue !== '' &&
|
|
89
|
+
this.isFilterCompliantForCell(cell, filterValue)) ||
|
|
90
|
+
checkboxValues.some((f) => this.isFilterCompliantForCell(cell, f.value)) ||
|
|
91
|
+
checkboxValues.some((f) => this.isFilterCompliantForCell(cell, f.displayedValue)) ||
|
|
92
|
+
// There are no filters to check -> the element is valid
|
|
93
|
+
!columnFilters.hasFiltersForColumn(filters, currentColumn);
|
|
89
94
|
let b2 = _filterIsNegative;
|
|
90
95
|
if (!kupObjects.isNumber(cell.obj) &&
|
|
91
96
|
!kupObjects.isDate(cell.obj) &&
|
|
92
97
|
!kupObjects.isTime(cell.obj) &&
|
|
93
98
|
!kupObjects.isTimestamp(cell.obj)) {
|
|
94
|
-
b2 =
|
|
99
|
+
b2 =
|
|
100
|
+
(filterValue !== '' &&
|
|
101
|
+
this.isFilterCompliantForCellObj(cell, filterValue)) ||
|
|
102
|
+
checkboxValues.some((f) => this.isFilterCompliantForCellObj(cell, f.value)) ||
|
|
103
|
+
// There are no filters to check -> the element is valid
|
|
104
|
+
!columnFilters.hasFiltersForColumn(filters, currentColumn);
|
|
95
105
|
}
|
|
96
106
|
if (_filterIsNegative) {
|
|
97
|
-
|
|
98
|
-
return false;
|
|
99
|
-
}
|
|
107
|
+
return b1 && b2;
|
|
100
108
|
}
|
|
101
109
|
else {
|
|
102
|
-
|
|
103
|
-
return false;
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
let filterValues = columnFilters.getCheckBoxFilterValues(filters, key);
|
|
107
|
-
if (filterValues.length == 0) {
|
|
108
|
-
continue;
|
|
109
|
-
}
|
|
110
|
-
let retValue = false;
|
|
111
|
-
for (let i = 0; i < filterValues.length; i++) {
|
|
112
|
-
let fv = filterValues[i];
|
|
113
|
-
if (fv == null || fv.value == null) {
|
|
114
|
-
continue;
|
|
115
|
-
}
|
|
116
|
-
if (cell.value != null) {
|
|
117
|
-
if (cell.value.toLowerCase().trim() ==
|
|
118
|
-
fv.value.toLowerCase().trim()) {
|
|
119
|
-
retValue = true;
|
|
120
|
-
break;
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
if (cell.obj != null) {
|
|
124
|
-
if (cell.obj.k.toLowerCase().trim() ==
|
|
125
|
-
fv.value.toLowerCase().trim()) {
|
|
126
|
-
retValue = true;
|
|
127
|
-
break;
|
|
128
|
-
}
|
|
129
|
-
}
|
|
110
|
+
return b1 || b2;
|
|
130
111
|
}
|
|
131
|
-
|
|
132
|
-
return false;
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
return true;
|
|
112
|
+
});
|
|
136
113
|
}
|
|
137
114
|
hasFilters(filters = {}, columns, columnFilters) {
|
|
138
115
|
if (filters == null) {
|
|
@@ -47,9 +47,9 @@ export class Filters {
|
|
|
47
47
|
else if (dom.ketchup.objects.isTime(smeupObj)) {
|
|
48
48
|
let manageSeconds = dom.ketchup.objects.isTimeWithSeconds(smeupObj);
|
|
49
49
|
if (dom.ketchup.dates.isValidFormattedStringTime(value, manageSeconds)) {
|
|
50
|
-
return dom.ketchup.dates.
|
|
50
|
+
return dom.ketchup.dates.timeStringToFormattedString(value, manageSeconds, manageSeconds
|
|
51
51
|
? KupDatesFormats.ISO_TIME
|
|
52
|
-
: KupDatesFormats.ISO_TIME_WITHOUT_SECONDS
|
|
52
|
+
: KupDatesFormats.ISO_TIME_WITHOUT_SECONDS);
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
else if (dom.ketchup.objects.isTimestamp(smeupObj)) {
|
|
@@ -83,6 +83,7 @@ export class Filters {
|
|
|
83
83
|
* Determines if a value matches a given filter.
|
|
84
84
|
*
|
|
85
85
|
* Filter expressions follow the format `[operator]'filter'` with these rules:
|
|
86
|
+
* - filter = includes match
|
|
86
87
|
* - 'filter' = exact phrase match
|
|
87
88
|
* - '' = matches empty value
|
|
88
89
|
* - 'filter%' = starts with "filter"
|
|
@@ -124,6 +125,7 @@ export class Filters {
|
|
|
124
125
|
* - `%` at both: contains
|
|
125
126
|
*
|
|
126
127
|
* Examples:
|
|
128
|
+
* - `text`: includes match
|
|
127
129
|
* - `'text'`: exact match
|
|
128
130
|
* - `''`: matches empty
|
|
129
131
|
* - `!''`: matches non-empty
|
|
@@ -260,7 +262,7 @@ export class Filters {
|
|
|
260
262
|
const normValue = this.normalizeValue(value, obj);
|
|
261
263
|
let valueDate = null;
|
|
262
264
|
if (normValue != null) {
|
|
263
|
-
valueDate = dom.ketchup.dates.toDate(value);
|
|
265
|
+
valueDate = dom.ketchup.dates.toDate(value, defaultFormat);
|
|
264
266
|
}
|
|
265
267
|
if (filterMatch && valueDate) {
|
|
266
268
|
const [_, operator, _startWildcard, dateStr, _endWildcard] = filterMatch;
|
|
@@ -287,7 +289,8 @@ export class Filters {
|
|
|
287
289
|
// If we got here, we either don't have a valid filter pattern or date
|
|
288
290
|
// Format the value for string comparison
|
|
289
291
|
if (!dom.ketchup.dates.isValidFormattedStringDate(normalizedFilter, defaultFormat) &&
|
|
290
|
-
!dom.ketchup.dates.isValidFormattedStringDate(normalizedFilter)
|
|
292
|
+
!dom.ketchup.dates.isValidFormattedStringDate(normalizedFilter) &&
|
|
293
|
+
!dom.ketchup.dates.isValidFormattedStringTime(value, dom.ketchup.objects.isTimeWithSeconds(obj))) {
|
|
291
294
|
value = dom.ketchup.dates.format(value);
|
|
292
295
|
}
|
|
293
296
|
}
|
|
@@ -15,6 +15,4 @@ export var KupColumnMenuIds;
|
|
|
15
15
|
KupColumnMenuIds["SWITCH_KEY"] = "key";
|
|
16
16
|
KupColumnMenuIds["TEXTFIELD_FILTER"] = "filter";
|
|
17
17
|
KupColumnMenuIds["TEXTFIELD_FORMULA"] = "formula";
|
|
18
|
-
KupColumnMenuIds["TEXTFIELD_FROM"] = "filter-from";
|
|
19
|
-
KupColumnMenuIds["TEXTFIELD_TO"] = "filter-to";
|
|
20
18
|
})(KupColumnMenuIds || (KupColumnMenuIds = {}));
|