@sme.up/ketchup 9.6.0 → 9.6.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-button-623dfcc3.js → f-button-4c346ca8.js} +1 -1
- package/dist/cjs/{f-cell-9c718d83.js → f-cell-8f3d12fd.js} +5 -5
- package/dist/cjs/{f-chip-c8efad5b.js → f-chip-a6c800be.js} +2 -2
- package/dist/cjs/{f-image-b61cc967.js → f-image-40476fa6.js} +1 -1
- package/dist/cjs/{f-paginator-utils-67dbc14c.js → f-paginator-utils-c652ceaa.js} +6 -6
- package/dist/cjs/{f-text-field-a09b1705.js → f-text-field-1f77ef23.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 +2 -2
- package/dist/cjs/kup-autocomplete_27.cjs.entry.js +91 -66
- package/dist/cjs/kup-box.cjs.entry.js +76 -14
- package/dist/cjs/kup-calendar.cjs.entry.js +8 -6
- package/dist/cjs/kup-card-list.cjs.entry.js +1 -1
- package/dist/cjs/kup-cell.cjs.entry.js +6 -6
- package/dist/cjs/kup-dashboard.cjs.entry.js +4 -4
- 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 +3 -3
- package/dist/cjs/kup-grid.cjs.entry.js +1 -1
- package/dist/cjs/kup-iframe.cjs.entry.js +1 -1
- package/dist/cjs/kup-image-list.cjs.entry.js +6 -6
- package/dist/cjs/kup-lazy.cjs.entry.js +1 -1
- package/dist/cjs/kup-magic-box.cjs.entry.js +2 -2
- package/dist/cjs/{kup-manager-227c4be2.js → kup-manager-08f1585b.js} +54 -41
- 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-photo-frame.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 +3 -3
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/assets/index.js +4 -0
- package/dist/collection/assets/planner-example-4.js +4 -4
- package/dist/collection/assets/planner-example-5.js +3175 -0
- package/dist/collection/components/kup-box/kup-box-declarations.js +11 -0
- package/dist/collection/components/kup-box/kup-box-state.js +2 -0
- package/dist/collection/components/kup-box/kup-box.js +169 -9
- package/dist/collection/components/kup-calendar/kup-calendar.js +4 -2
- package/dist/collection/components/kup-card/built-in/kup-card-openai.js +29 -1
- package/dist/collection/components/kup-card/kup-card.css +7 -0
- package/dist/collection/components/kup-data-table/kup-data-table.js +14 -17
- package/dist/collection/managers/kup-openai/kup-openai.js +53 -40
- package/dist/components/kup-autocomplete2.js +99 -74
- package/dist/components/kup-box2.js +74 -8
- package/dist/components/kup-button-list.js +1 -1
- package/dist/components/kup-button.js +1 -1
- package/dist/components/kup-calendar.js +5 -3
- package/dist/components/kup-card.js +1 -1
- 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 +1 -1
- 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-dropdown-button.js +1 -1
- package/dist/components/kup-family-tree.js +1 -1
- package/dist/components/kup-form.js +1 -1
- package/dist/components/kup-gauge.js +1 -1
- package/dist/components/kup-image-list.js +1 -1
- package/dist/components/kup-image.js +1 -1
- package/dist/components/kup-list.js +1 -1
- package/dist/components/kup-magic-box.js +1 -1
- package/dist/components/kup-manager.js +54 -41
- package/dist/components/kup-numeric-picker.js +1 -1
- package/dist/components/kup-planner.js +1 -1
- package/dist/components/kup-progress-bar.js +1 -1
- package/dist/components/kup-radio.js +1 -1
- package/dist/components/kup-rating.js +1 -1
- package/dist/components/kup-snackbar.js +1 -1
- 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-tree.js +1 -1
- package/dist/esm/{f-button-121958b3.js → f-button-90a7ea86.js} +1 -1
- package/dist/esm/{f-cell-959b83db.js → f-cell-fdd338c5.js} +5 -5
- package/dist/esm/{f-chip-915ddf53.js → f-chip-4e6341a6.js} +2 -2
- package/dist/esm/{f-image-98371dac.js → f-image-5210f0b3.js} +1 -1
- package/dist/esm/{f-paginator-utils-f5f4c666.js → f-paginator-utils-3f179999.js} +3 -3
- package/dist/esm/{f-text-field-0df308e4.js → f-text-field-8429a853.js} +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/ketchup.js +1 -1
- package/dist/esm/kup-accordion.entry.js +2 -2
- package/dist/esm/kup-autocomplete_27.entry.js +91 -66
- package/dist/esm/kup-box.entry.js +76 -14
- package/dist/esm/kup-calendar.entry.js +8 -6
- package/dist/esm/kup-card-list.entry.js +1 -1
- package/dist/esm/kup-cell.entry.js +6 -6
- package/dist/esm/kup-dashboard.entry.js +4 -4
- 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 +3 -3
- package/dist/esm/kup-grid.entry.js +1 -1
- package/dist/esm/kup-iframe.entry.js +1 -1
- package/dist/esm/kup-image-list.entry.js +6 -6
- package/dist/esm/kup-lazy.entry.js +1 -1
- package/dist/esm/kup-magic-box.entry.js +2 -2
- package/dist/esm/{kup-manager-33b051d6.js → kup-manager-8b39f876.js} +54 -41
- package/dist/esm/kup-nav-bar.entry.js +1 -1
- package/dist/esm/kup-numeric-picker.entry.js +2 -2
- package/dist/esm/kup-photo-frame.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 +3 -3
- 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-02820c2b.entry.js +1 -0
- package/dist/ketchup/{p-9d8d5070.entry.js → p-09d853c3.entry.js} +1 -1
- package/dist/ketchup/{p-81996620.entry.js → p-14e1a36b.entry.js} +1 -1
- package/dist/ketchup/{p-0a4595bd.entry.js → p-1936c6cd.entry.js} +1 -1
- package/dist/ketchup/{p-eb37ea7e.entry.js → p-318c9ecd.entry.js} +1 -1
- package/dist/ketchup/{p-e43d4ccc.js → p-35d503e2.js} +1 -1
- package/dist/ketchup/p-35dce86e.entry.js +1 -0
- package/dist/ketchup/{p-3ce8ce77.entry.js → p-4c20fefd.entry.js} +1 -1
- package/dist/ketchup/{p-9f31a129.entry.js → p-4eb70dd2.entry.js} +1 -1
- package/dist/ketchup/{p-3ff9a661.entry.js → p-5739cdc2.entry.js} +1 -1
- package/dist/ketchup/{p-41d6466e.entry.js → p-5ab3a88a.entry.js} +1 -1
- package/dist/ketchup/{p-7bda0684.js → p-5e16c9d3.js} +1 -1
- package/dist/ketchup/{p-a9b06bb8.js → p-6780a391.js} +1 -1
- package/dist/ketchup/{p-c1ade766.entry.js → p-67930d7c.entry.js} +1 -1
- package/dist/ketchup/{p-0dd0ae49.entry.js → p-6953f769.entry.js} +1 -1
- package/dist/ketchup/{p-babbffa4.entry.js → p-7d2fd8bd.entry.js} +1 -1
- package/dist/ketchup/{p-773bcc69.entry.js → p-8257141a.entry.js} +1 -1
- package/dist/ketchup/{p-9e63f56b.entry.js → p-82694fad.entry.js} +1 -1
- package/dist/ketchup/{p-ccc637ee.js → p-86f9b0d9.js} +1 -1
- package/dist/ketchup/{p-d5254caf.entry.js → p-8ea68d14.entry.js} +1 -1
- package/dist/ketchup/{p-4bf5e04f.entry.js → p-98c72335.entry.js} +1 -1
- package/dist/ketchup/{p-d15d1083.entry.js → p-ab8cac45.entry.js} +1 -1
- package/dist/ketchup/p-c089b961.js +1 -0
- package/dist/ketchup/{p-f0b882f4.entry.js → p-cdb24584.entry.js} +1 -1
- package/dist/ketchup/{p-ea625b2a.entry.js → p-d466d6d1.entry.js} +1 -1
- package/dist/ketchup/{p-b086727d.entry.js → p-ee30e274.entry.js} +1 -1
- package/dist/ketchup/{p-610a03d4.js → p-f31530fc.js} +2 -2
- package/dist/ketchup/{p-2f4055ba.entry.js → p-f353805e.entry.js} +1 -1
- package/dist/ketchup/p-f515308d.entry.js +9 -0
- package/dist/ketchup/{p-68e9379a.js → p-f9766625.js} +1 -1
- package/dist/types/components/kup-box/kup-box-declarations.d.ts +12 -0
- package/dist/types/components/kup-box/kup-box-state.d.ts +2 -0
- package/dist/types/components/kup-box/kup-box.d.ts +26 -1
- package/dist/types/components/kup-calendar/kup-calendar-declarations.d.ts +1 -0
- package/dist/types/components/kup-card/kup-card-declarations.d.ts +1 -0
- package/dist/types/components.d.ts +48 -6
- package/dist/types/managers/kup-openai/kup-openai-declarations.d.ts +7 -0
- package/dist/types/managers/kup-openai/kup-openai.d.ts +8 -12
- package/package.json +1 -1
- package/dist/ketchup/p-102866cd.js +0 -1
- package/dist/ketchup/p-6001882e.entry.js +0 -9
- package/dist/ketchup/p-662d2f9b.entry.js +0 -1
- package/dist/ketchup/p-d1268ac7.entry.js +0 -1
|
@@ -17,6 +17,9 @@ export var KupBoxProps;
|
|
|
17
17
|
KupBoxProps["kanban"] = "Displays the boxlist as a Kanban.";
|
|
18
18
|
KupBoxProps["layout"] = "How the field will be displayed. If not present, a default one will be created.";
|
|
19
19
|
KupBoxProps["lazyLoadRows"] = "When set to true, extra rows will be automatically loaded once the last row enters the viewport.";
|
|
20
|
+
KupBoxProps["loadMoreLimit"] = "Sets a maximum limit of new records which can be required by the load more functionality.";
|
|
21
|
+
KupBoxProps["loadMoreMode"] = "Establish the modality of how many new records will be downloaded. This property is regulated also by loadMoreStep.";
|
|
22
|
+
KupBoxProps["loadMoreStep"] = "The number of records which will be requested to be downloaded when clicking on the load more button. This property is regulated also by loadMoreMode.";
|
|
20
23
|
KupBoxProps["multiSelection"] = "Enable multi selection.";
|
|
21
24
|
KupBoxProps["pageSelected"] = "Current page number.";
|
|
22
25
|
KupBoxProps["pagination"] = "Enables pagination.";
|
|
@@ -24,6 +27,7 @@ export var KupBoxProps;
|
|
|
24
27
|
KupBoxProps["scrollOnHover"] = "Activates the scroll on hover function.";
|
|
25
28
|
KupBoxProps["selectBox"] = "Automatically selects the box at the specified index.";
|
|
26
29
|
KupBoxProps["selectedRowsState"] = "Multiple selection.";
|
|
30
|
+
KupBoxProps["showLoadMore"] = "If set to true, displays the button to load more records.";
|
|
27
31
|
KupBoxProps["showSelection"] = "If enabled, highlights the selected box/boxes.";
|
|
28
32
|
KupBoxProps["sortBy"] = "If sorting is enabled, specifies which column to sort.";
|
|
29
33
|
KupBoxProps["sortEnabled"] = "Enable sorting.";
|
|
@@ -31,3 +35,10 @@ export var KupBoxProps;
|
|
|
31
35
|
KupBoxProps["store"] = "";
|
|
32
36
|
KupBoxProps["swipeDisabled"] = "Disable swipe.";
|
|
33
37
|
})(KupBoxProps || (KupBoxProps = {}));
|
|
38
|
+
//---- *NEXT functionality AKA load more ----
|
|
39
|
+
export var LoadMoreMode;
|
|
40
|
+
(function (LoadMoreMode) {
|
|
41
|
+
LoadMoreMode["CONSTANT"] = "constant";
|
|
42
|
+
LoadMoreMode["CONSTANT_INCREMENT"] = "constant_increment";
|
|
43
|
+
LoadMoreMode["PROGRESSIVE_THRESHOLD"] = "progressive_threshold";
|
|
44
|
+
})(LoadMoreMode || (LoadMoreMode = {}));
|
|
@@ -14,10 +14,10 @@ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (
|
|
|
14
14
|
throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
15
15
|
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
16
16
|
};
|
|
17
|
-
var _KupBox_instances, _KupBox_intObserver, _KupBox_rowsRefs, _KupBox_navBarHeight, _KupBox_didRenderObservers, _KupBox_setObserver;
|
|
17
|
+
var _KupBox_instances, _KupBox_intObserver, _KupBox_rowsRefs, _KupBox_navBarHeight, _KupBox_loadMoreEventCounter, _KupBox_loadMoreEventPreviousQuantity, _KupBox_didRenderObservers, _KupBox_setObserver, _KupBox_onLoadMoreClick;
|
|
18
18
|
import { forceUpdate, h, Host, } from "@stencil/core";
|
|
19
19
|
import { SortMode, } from "../kup-data-table/kup-data-table-declarations";
|
|
20
|
-
import { KupBoxProps, } from "./kup-box-declarations";
|
|
20
|
+
import { KupBoxProps, LoadMoreMode, } from "./kup-box-declarations";
|
|
21
21
|
import { getColumnByName } from "../../utils/cell-utils";
|
|
22
22
|
import { filterRows, sortRows, paginateRows, } from "../kup-data-table/kup-data-table-helper";
|
|
23
23
|
import { kupManagerInstance, } from "../../managers/kup-manager/kup-manager";
|
|
@@ -32,7 +32,6 @@ import { KupThemeIconValues } from "../../managers/kup-theme/kup-theme-declarati
|
|
|
32
32
|
import { KupDragEffect, kupDraggableAttr, KupDropEventTypes, KupPointerEventTypes, } from "../../managers/kup-interact/kup-interact-declarations";
|
|
33
33
|
import { FCell } from "../../f-components/f-cell/f-cell";
|
|
34
34
|
import { FPaginator } from "../../f-components/f-paginator/f-paginator";
|
|
35
|
-
import { FPaginatorMode } from "../../f-components/f-paginator/f-paginator-declarations";
|
|
36
35
|
import { pageChange, rowsPerPageChange, } from "../../f-components/f-paginator/f-paginator-utils";
|
|
37
36
|
import { FTextFieldMDC } from "../../f-components/f-text-field/f-text-field-mdc";
|
|
38
37
|
export class KupBox {
|
|
@@ -58,6 +57,8 @@ export class KupBox {
|
|
|
58
57
|
_KupBox_intObserver.set(this, undefined);
|
|
59
58
|
_KupBox_rowsRefs.set(this, []);
|
|
60
59
|
_KupBox_navBarHeight.set(this, 0);
|
|
60
|
+
_KupBox_loadMoreEventCounter.set(this, 0);
|
|
61
|
+
_KupBox_loadMoreEventPreviousQuantity.set(this, 0);
|
|
61
62
|
this.collapsedSection = {};
|
|
62
63
|
this.selectedRows = [];
|
|
63
64
|
this.rowActionMenuOpened = undefined;
|
|
@@ -77,6 +78,9 @@ export class KupBox {
|
|
|
77
78
|
this.kanban = null;
|
|
78
79
|
this.layout = undefined;
|
|
79
80
|
this.lazyLoadRows = false;
|
|
81
|
+
this.loadMoreLimit = 1000;
|
|
82
|
+
this.loadMoreMode = LoadMoreMode.PROGRESSIVE_THRESHOLD;
|
|
83
|
+
this.loadMoreStep = 60;
|
|
80
84
|
this.multiSelection = false;
|
|
81
85
|
this.pageSelected = 1;
|
|
82
86
|
this.pagination = false;
|
|
@@ -84,6 +88,7 @@ export class KupBox {
|
|
|
84
88
|
this.scrollOnHover = false;
|
|
85
89
|
this.selectBox = undefined;
|
|
86
90
|
this.selectedRowsState = undefined;
|
|
91
|
+
this.showLoadMore = false;
|
|
87
92
|
this.showSelection = true;
|
|
88
93
|
this.sortBy = undefined;
|
|
89
94
|
this.sortEnabled = false;
|
|
@@ -105,6 +110,8 @@ export class KupBox {
|
|
|
105
110
|
this.selectedRowsState = this.state.selectedRowsState;
|
|
106
111
|
this.pageSelected = this.state.pageSelected;
|
|
107
112
|
this.rowsPerPage = this.state.rowsPerPage;
|
|
113
|
+
this.loadMoreLimit = state.loadMoreLimit;
|
|
114
|
+
this.showLoadMore = state.showLoadMore;
|
|
108
115
|
}
|
|
109
116
|
}
|
|
110
117
|
}
|
|
@@ -135,6 +142,14 @@ export class KupBox {
|
|
|
135
142
|
this.state.selectedRowsState = selectedRowsState;
|
|
136
143
|
somethingChanged = true;
|
|
137
144
|
}
|
|
145
|
+
if (!this.kupManager.objects.deepEqual(this.state.loadMoreLimit, this.loadMoreLimit)) {
|
|
146
|
+
this.state.loadMoreLimit = this.loadMoreLimit;
|
|
147
|
+
somethingChanged = true;
|
|
148
|
+
}
|
|
149
|
+
if (!this.kupManager.objects.deepEqual(this.state.showLoadMore, this.showLoadMore)) {
|
|
150
|
+
this.state.showLoadMore = this.showLoadMore;
|
|
151
|
+
somethingChanged = true;
|
|
152
|
+
}
|
|
138
153
|
if (!this.state.load) {
|
|
139
154
|
this.state.load = true;
|
|
140
155
|
return;
|
|
@@ -1164,10 +1179,18 @@ export class KupBox {
|
|
|
1164
1179
|
} })));
|
|
1165
1180
|
}
|
|
1166
1181
|
let paginator = null;
|
|
1167
|
-
|
|
1168
|
-
|
|
1182
|
+
// paginaltorPos prop not managed yet
|
|
1183
|
+
const top = true;
|
|
1184
|
+
if (this.showLoadMore || (!this.lazyLoadRows && this.pagination)) {
|
|
1185
|
+
paginator = (h(FPaginator, { id: top ? 'top-paginator' : 'bottom-paginator', currentPage: this.currentPage, max: this.filteredRows.length,
|
|
1186
|
+
// mode={FPaginatorMode.SIMPLE}
|
|
1187
|
+
perPage: this.currentRowsPerPage
|
|
1169
1188
|
? this.currentRowsPerPage
|
|
1170
|
-
: this.rowsPerPage,
|
|
1189
|
+
: this.rowsPerPage, onLoadMore: this.showLoadMore
|
|
1190
|
+
? () => {
|
|
1191
|
+
__classPrivateFieldGet(this, _KupBox_instances, "m", _KupBox_onLoadMoreClick).call(this);
|
|
1192
|
+
}
|
|
1193
|
+
: null, onNextPage: () => this.handlePageChange(this.currentPage + 1), onPrevPage: () => this.handlePageChange(this.currentPage - 1), onPageChange: (e) => this.handlePageChange(e.detail.value), onRowsChange: (e) => this.handleRowsPerPageChange(e.detail.value) }));
|
|
1171
1194
|
}
|
|
1172
1195
|
let boxContent = null;
|
|
1173
1196
|
let containerStyle = {};
|
|
@@ -1531,6 +1554,78 @@ export class KupBox {
|
|
|
1531
1554
|
"reflect": false,
|
|
1532
1555
|
"defaultValue": "false"
|
|
1533
1556
|
},
|
|
1557
|
+
"loadMoreLimit": {
|
|
1558
|
+
"type": "number",
|
|
1559
|
+
"mutable": false,
|
|
1560
|
+
"complexType": {
|
|
1561
|
+
"original": "number",
|
|
1562
|
+
"resolved": "number",
|
|
1563
|
+
"references": {}
|
|
1564
|
+
},
|
|
1565
|
+
"required": false,
|
|
1566
|
+
"optional": false,
|
|
1567
|
+
"docs": {
|
|
1568
|
+
"tags": [],
|
|
1569
|
+
"text": "Sets a maximum limit of new records which can be required by the load more functionality."
|
|
1570
|
+
},
|
|
1571
|
+
"attribute": "load-more-limit",
|
|
1572
|
+
"reflect": false,
|
|
1573
|
+
"defaultValue": "1000"
|
|
1574
|
+
},
|
|
1575
|
+
"loadMoreMode": {
|
|
1576
|
+
"type": "string",
|
|
1577
|
+
"mutable": false,
|
|
1578
|
+
"complexType": {
|
|
1579
|
+
"original": "LoadMoreMode",
|
|
1580
|
+
"resolved": "LoadMoreMode.CONSTANT | LoadMoreMode.CONSTANT_INCREMENT | LoadMoreMode.PROGRESSIVE_THRESHOLD",
|
|
1581
|
+
"references": {
|
|
1582
|
+
"LoadMoreMode": {
|
|
1583
|
+
"location": "import",
|
|
1584
|
+
"path": "./kup-box-declarations",
|
|
1585
|
+
"id": "src/components/kup-box/kup-box-declarations.ts::LoadMoreMode"
|
|
1586
|
+
}
|
|
1587
|
+
}
|
|
1588
|
+
},
|
|
1589
|
+
"required": false,
|
|
1590
|
+
"optional": false,
|
|
1591
|
+
"docs": {
|
|
1592
|
+
"tags": [{
|
|
1593
|
+
"name": "see",
|
|
1594
|
+
"text": "loadMoreStep *"
|
|
1595
|
+
}, {
|
|
1596
|
+
"name": "see",
|
|
1597
|
+
"text": "loadMoreLimit"
|
|
1598
|
+
}],
|
|
1599
|
+
"text": "Establish the modality of how many new records will be downloaded.\r\n\r\nThis property is regulated also by loadMoreStep."
|
|
1600
|
+
},
|
|
1601
|
+
"attribute": "load-more-mode",
|
|
1602
|
+
"reflect": false,
|
|
1603
|
+
"defaultValue": "LoadMoreMode.PROGRESSIVE_THRESHOLD"
|
|
1604
|
+
},
|
|
1605
|
+
"loadMoreStep": {
|
|
1606
|
+
"type": "number",
|
|
1607
|
+
"mutable": false,
|
|
1608
|
+
"complexType": {
|
|
1609
|
+
"original": "number",
|
|
1610
|
+
"resolved": "number",
|
|
1611
|
+
"references": {}
|
|
1612
|
+
},
|
|
1613
|
+
"required": false,
|
|
1614
|
+
"optional": false,
|
|
1615
|
+
"docs": {
|
|
1616
|
+
"tags": [{
|
|
1617
|
+
"name": "see",
|
|
1618
|
+
"text": "loadMoreMode *"
|
|
1619
|
+
}, {
|
|
1620
|
+
"name": "see",
|
|
1621
|
+
"text": "loadMoreLimit"
|
|
1622
|
+
}],
|
|
1623
|
+
"text": "The number of records which will be requested to be downloaded when clicking on the load more button.\r\n\r\nThis property is regulated also by loadMoreMode."
|
|
1624
|
+
},
|
|
1625
|
+
"attribute": "load-more-step",
|
|
1626
|
+
"reflect": false,
|
|
1627
|
+
"defaultValue": "60"
|
|
1628
|
+
},
|
|
1534
1629
|
"multiSelection": {
|
|
1535
1630
|
"type": "boolean",
|
|
1536
1631
|
"mutable": false,
|
|
@@ -1675,6 +1770,24 @@ export class KupBox {
|
|
|
1675
1770
|
"attribute": "selected-rows-state",
|
|
1676
1771
|
"reflect": false
|
|
1677
1772
|
},
|
|
1773
|
+
"showLoadMore": {
|
|
1774
|
+
"type": "boolean",
|
|
1775
|
+
"mutable": false,
|
|
1776
|
+
"complexType": {
|
|
1777
|
+
"original": "boolean",
|
|
1778
|
+
"resolved": "boolean",
|
|
1779
|
+
"references": {}
|
|
1780
|
+
},
|
|
1781
|
+
"required": false,
|
|
1782
|
+
"optional": false,
|
|
1783
|
+
"docs": {
|
|
1784
|
+
"tags": [],
|
|
1785
|
+
"text": "If set to true, displays the button to load more records."
|
|
1786
|
+
},
|
|
1787
|
+
"attribute": "show-load-more",
|
|
1788
|
+
"reflect": false,
|
|
1789
|
+
"defaultValue": "false"
|
|
1790
|
+
},
|
|
1678
1791
|
"showSelection": {
|
|
1679
1792
|
"type": "boolean",
|
|
1680
1793
|
"mutable": false,
|
|
@@ -1977,6 +2090,27 @@ export class KupBox {
|
|
|
1977
2090
|
}
|
|
1978
2091
|
}
|
|
1979
2092
|
}
|
|
2093
|
+
}, {
|
|
2094
|
+
"method": "kupLoadMoreClick",
|
|
2095
|
+
"name": "kup-box-loadmoreclick",
|
|
2096
|
+
"bubbles": true,
|
|
2097
|
+
"cancelable": false,
|
|
2098
|
+
"composed": true,
|
|
2099
|
+
"docs": {
|
|
2100
|
+
"tags": [],
|
|
2101
|
+
"text": ""
|
|
2102
|
+
},
|
|
2103
|
+
"complexType": {
|
|
2104
|
+
"original": "KupBoxLoadMoreClickEventPayload",
|
|
2105
|
+
"resolved": "KupBoxLoadMoreClickEventPayload",
|
|
2106
|
+
"references": {
|
|
2107
|
+
"KupBoxLoadMoreClickEventPayload": {
|
|
2108
|
+
"location": "import",
|
|
2109
|
+
"path": "./kup-box-declarations",
|
|
2110
|
+
"id": "src/components/kup-box/kup-box-declarations.ts::KupBoxLoadMoreClickEventPayload"
|
|
2111
|
+
}
|
|
2112
|
+
}
|
|
2113
|
+
}
|
|
1980
2114
|
}];
|
|
1981
2115
|
}
|
|
1982
2116
|
static get methods() {
|
|
@@ -2131,7 +2265,7 @@ export class KupBox {
|
|
|
2131
2265
|
}];
|
|
2132
2266
|
}
|
|
2133
2267
|
}
|
|
2134
|
-
_KupBox_intObserver = new WeakMap(), _KupBox_rowsRefs = new WeakMap(), _KupBox_navBarHeight = new WeakMap(), _KupBox_instances = new WeakSet(), _KupBox_didRenderObservers = function _KupBox_didRenderObservers() {
|
|
2268
|
+
_KupBox_intObserver = new WeakMap(), _KupBox_rowsRefs = new WeakMap(), _KupBox_navBarHeight = new WeakMap(), _KupBox_loadMoreEventCounter = new WeakMap(), _KupBox_loadMoreEventPreviousQuantity = new WeakMap(), _KupBox_instances = new WeakSet(), _KupBox_didRenderObservers = function _KupBox_didRenderObservers() {
|
|
2135
2269
|
if (this.lazyLoadRows &&
|
|
2136
2270
|
this.currentRowsPerPage < this.data.rows.length) {
|
|
2137
2271
|
__classPrivateFieldGet(this, _KupBox_intObserver, "f").observe(__classPrivateFieldGet(this, _KupBox_rowsRefs, "f")[__classPrivateFieldGet(this, _KupBox_rowsRefs, "f").length - 1]);
|
|
@@ -2142,11 +2276,11 @@ _KupBox_intObserver = new WeakMap(), _KupBox_rowsRefs = new WeakMap(), _KupBox_n
|
|
|
2142
2276
|
if (entry.isIntersecting) {
|
|
2143
2277
|
this.kupManager.debug.logMessage(this, 'Last row entering the viewport, loading more elements.');
|
|
2144
2278
|
const delta = this.data.rows.length - this.currentRowsPerPage;
|
|
2145
|
-
if (delta <
|
|
2279
|
+
if (delta < this.loadMoreStep) {
|
|
2146
2280
|
this.currentRowsPerPage += delta;
|
|
2147
2281
|
}
|
|
2148
2282
|
else {
|
|
2149
|
-
this.currentRowsPerPage +=
|
|
2283
|
+
this.currentRowsPerPage += this.loadMoreStep;
|
|
2150
2284
|
}
|
|
2151
2285
|
entry.target.classList.remove('last-row');
|
|
2152
2286
|
__classPrivateFieldGet(this, _KupBox_intObserver, "f").unobserve(entry.target);
|
|
@@ -2158,4 +2292,30 @@ _KupBox_intObserver = new WeakMap(), _KupBox_rowsRefs = new WeakMap(), _KupBox_n
|
|
|
2158
2292
|
rootMargin: '-' + __classPrivateFieldGet(this, _KupBox_navBarHeight, "f") + 'px 0px 0px 0px',
|
|
2159
2293
|
};
|
|
2160
2294
|
__classPrivateFieldSet(this, _KupBox_intObserver, new IntersectionObserver(callback, options), "f");
|
|
2295
|
+
}, _KupBox_onLoadMoreClick = function _KupBox_onLoadMoreClick() {
|
|
2296
|
+
var _a;
|
|
2297
|
+
let loadItems = 0;
|
|
2298
|
+
switch (this.loadMoreMode) {
|
|
2299
|
+
case LoadMoreMode.CONSTANT:
|
|
2300
|
+
loadItems = this.loadMoreStep;
|
|
2301
|
+
break;
|
|
2302
|
+
case LoadMoreMode.CONSTANT_INCREMENT:
|
|
2303
|
+
loadItems =
|
|
2304
|
+
this.loadMoreStep * (__classPrivateFieldGet(this, _KupBox_loadMoreEventCounter, "f") + 1);
|
|
2305
|
+
break;
|
|
2306
|
+
case LoadMoreMode.PROGRESSIVE_THRESHOLD:
|
|
2307
|
+
loadItems =
|
|
2308
|
+
Math.max(__classPrivateFieldGet(this, _KupBox_loadMoreEventPreviousQuantity, "f"), this.loadMoreStep) * Math.min(__classPrivateFieldGet(this, _KupBox_loadMoreEventCounter, "f") + 1, 2);
|
|
2309
|
+
break;
|
|
2310
|
+
}
|
|
2311
|
+
if (loadItems > this.loadMoreLimit) {
|
|
2312
|
+
loadItems = this.loadMoreLimit;
|
|
2313
|
+
}
|
|
2314
|
+
this.kupLoadMoreClick.emit({
|
|
2315
|
+
comp: this,
|
|
2316
|
+
id: this.rootElement.id,
|
|
2317
|
+
loadItems: loadItems,
|
|
2318
|
+
});
|
|
2319
|
+
__classPrivateFieldSet(this, _KupBox_loadMoreEventPreviousQuantity, loadItems, "f");
|
|
2320
|
+
__classPrivateFieldSet(this, _KupBox_loadMoreEventCounter, (_a = __classPrivateFieldGet(this, _KupBox_loadMoreEventCounter, "f"), _a++, _a), "f");
|
|
2161
2321
|
};
|
|
@@ -138,6 +138,7 @@ export class KupCalendar {
|
|
|
138
138
|
}
|
|
139
139
|
},
|
|
140
140
|
eventDrop: ({ event, oldEvent }) => {
|
|
141
|
+
var _a;
|
|
141
142
|
this.kupCalendarEventDrop.emit({
|
|
142
143
|
comp: this,
|
|
143
144
|
id: this.rootElement.id,
|
|
@@ -149,6 +150,7 @@ export class KupCalendar {
|
|
|
149
150
|
start: event.start,
|
|
150
151
|
end: event.end,
|
|
151
152
|
},
|
|
153
|
+
row: (_a = oldEvent.extendedProps) === null || _a === void 0 ? void 0 : _a.row,
|
|
152
154
|
});
|
|
153
155
|
},
|
|
154
156
|
events: this.getEvents(),
|
|
@@ -355,11 +357,11 @@ export class KupCalendar {
|
|
|
355
357
|
this.kupManager.debug.logRender(this, true);
|
|
356
358
|
}
|
|
357
359
|
render() {
|
|
358
|
-
return (h(Host, { key: '
|
|
360
|
+
return (h(Host, { key: '256712f0367d8a4979fbe5cf01230ef6919cbe30' }, h("style", { key: '483bc12677fbf0feb94f0322d050d3e92b76aa96' }, this.kupManager.theme.setKupStyle(this.rootElement)), h("div", { key: 'd396f95087febb8439ba747250dbde5c966664a9', id: componentWrapperId }, h("div", { key: '218107d205ccc74759b902682fbb4ffc38b4e6af', class: "navigation" }, !this.hideNavigation ? (h("div", { class: "navigation__left" }, h(FButton, { icon: "chevron_left", onClick: () => this.onPrev(), title: this.kupManager.language.translate(KupLanguageGeneric.PREVIOUS), wrapperClass: "navigation__prev" }), h(FButton, { icon: "calendar", onClick: () => this.onToday(), title: this.kupManager.language.translate(KupLanguageGeneric.TODAY), wrapperClass: "navigation__today" }), h(FButton, { icon: "chevron_right", onClick: () => this.onNext(), title: this.kupManager.language.translate(KupLanguageGeneric.NEXT), wrapperClass: "navigation__next" }))) : null, h("div", { key: '35207cde78644377b8a90dc0798da7cb3a8fb028', class: `navigation__title ${this.hideNavigation
|
|
359
361
|
? 'navigation__title--centered'
|
|
360
362
|
: ''}`, ref: (el) => {
|
|
361
363
|
this.navTitle = el;
|
|
362
|
-
} }), !this.hideNavigation ? (h("div", { class: "navigation__right" }, h(FChip, Object.assign({}, this.setChipProps())))) : null), h("div", { key: '
|
|
364
|
+
} }), !this.hideNavigation ? (h("div", { class: "navigation__right" }, h(FChip, Object.assign({}, this.setChipProps())))) : null), h("div", { key: '0cc18bfc6befd69d45d4ba0c119fc5a4c2437d36', class: "calendar", ref: (el) => (this.calendarContainer = el) }))));
|
|
363
365
|
}
|
|
364
366
|
disconnectedCallback() {
|
|
365
367
|
if (this.calendar) {
|
|
@@ -3,6 +3,7 @@ import { KupCardCSSClasses, } from "../kup-card-declarations";
|
|
|
3
3
|
import { FButtonStyling } from "../../../f-components/f-button/f-button-declarations";
|
|
4
4
|
import { FImage } from "../../../f-components/f-image/f-image";
|
|
5
5
|
import { FButton } from "../../../f-components/f-button/f-button";
|
|
6
|
+
const dom = document.documentElement;
|
|
6
7
|
let inputArea = null;
|
|
7
8
|
let clearButton = null;
|
|
8
9
|
let submitButton = null;
|
|
@@ -41,12 +42,39 @@ export function prepareOpenAIInterface(component) {
|
|
|
41
42
|
h("div", { class: "text" }, "Your AI assistant is currently offline!"),
|
|
42
43
|
];
|
|
43
44
|
};
|
|
45
|
+
const getTextFormatted = (m) => {
|
|
46
|
+
if (m.type == 'request') {
|
|
47
|
+
return [h("div", { class: "paragraph" }, m.text)];
|
|
48
|
+
}
|
|
49
|
+
let result = [];
|
|
50
|
+
let matches = m.funs;
|
|
51
|
+
let text = m.text;
|
|
52
|
+
let lastIndex = 0;
|
|
53
|
+
for (const match of matches) {
|
|
54
|
+
result.push(h("div", { class: "paragraph" }, text.slice(lastIndex, match.index)));
|
|
55
|
+
let fun = match[0].trim();
|
|
56
|
+
if (fun.startsWith('#[')) {
|
|
57
|
+
fun = fun.replace('#[', '');
|
|
58
|
+
}
|
|
59
|
+
if (fun.endsWith(']#')) {
|
|
60
|
+
fun = fun.replace(']#', '');
|
|
61
|
+
}
|
|
62
|
+
result.push(h("div", { class: "fun", title: "Execute FUN.", onClick: () => {
|
|
63
|
+
if (dom.ketchup.openAI.onFunClick) {
|
|
64
|
+
dom.ketchup.openAI.onFunClick(fun);
|
|
65
|
+
}
|
|
66
|
+
} }, fun));
|
|
67
|
+
lastIndex = match.index + match[0].length;
|
|
68
|
+
}
|
|
69
|
+
result.push(h("div", { class: "paragraph" }, text.slice(lastIndex)));
|
|
70
|
+
return result;
|
|
71
|
+
};
|
|
44
72
|
const readyJsx = () => {
|
|
45
73
|
const genChat = () => {
|
|
46
74
|
const nodes = [];
|
|
47
75
|
if (options.messages && options.messages.length > 0) {
|
|
48
76
|
options.messages.forEach((m) => {
|
|
49
|
-
nodes.push(h("div", { class: "message-container" }, h("div", { class: m.type }, m
|
|
77
|
+
nodes.push(h("div", { class: "message-container" }, h("div", { class: m.type }, getTextFormatted(m)), h(FButton, { icon: "content-copy", onClick: () => {
|
|
50
78
|
navigator.clipboard.writeText(m.text);
|
|
51
79
|
}, title: "Copy text to clipboard.", wrapperClass: "copy" })));
|
|
52
80
|
});
|
|
@@ -1178,6 +1178,13 @@
|
|
|
1178
1178
|
right: 0;
|
|
1179
1179
|
transition: background-color 125ms ease, opacity 250ms ease;
|
|
1180
1180
|
}
|
|
1181
|
+
.built-in-layout-7 .fun {
|
|
1182
|
+
font-weight: bold;
|
|
1183
|
+
}
|
|
1184
|
+
.built-in-layout-7 .fun:hover {
|
|
1185
|
+
text-decoration: underline;
|
|
1186
|
+
cursor: pointer;
|
|
1187
|
+
}
|
|
1181
1188
|
|
|
1182
1189
|
.collapsible-layout-1 {
|
|
1183
1190
|
color: var(--kup-text-color);
|
|
@@ -14,7 +14,7 @@ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (
|
|
|
14
14
|
throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
15
15
|
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
16
16
|
};
|
|
17
|
-
var _KupDataTable_instances, _KupDataTable_initialized, _KupDataTable_rows, _KupDataTable_rowsLength, _KupDataTable_paginatedRows, _KupDataTable_paginatedRowsLength, _KupDataTable_footer, _KupDataTable_kupManager, _KupDataTable_renderedRows, _KupDataTable_loadMoreEventCounter, _KupDataTable_loadMoreEventPreviousQuantity, _KupDataTable_theadRef, _KupDataTable_tableRef, _KupDataTable_originalData, _KupDataTable_tableAreaRef, _KupDataTable_stickyTheadRef, _KupDataTable_customizeTopButtonRef, _KupDataTable_customizeTopPanelRef, _KupDataTable_sizedColumns, _KupDataTable_intObserver, _KupDataTable_navBarHeight, _KupDataTable_theadIntersecting, _KupDataTable_tableIntersecting, _KupDataTable_isSafariBrowser, _KupDataTable_isRestoringState, _KupDataTable_globalFilterTimeout, _KupDataTable_totalMenuCoords, _KupDataTable_clickTimeout, _KupDataTable_thRefs, _KupDataTable_rowsRefs, _KupDataTable_oldWidth, _KupDataTable_hold, _KupDataTable_interactableDrag, _KupDataTable_interactableDrop, _KupDataTable_interactableResize, _KupDataTable_interactableTouch, _KupDataTable_dropareaRef, _KupDataTable_removeDropareaRef, _KupDataTable_groupsDropareaRef, _KupDataTable_clickCb, _KupDataTable_clickCbCustomPanel, _KupDataTable_clickCbDropCard, _KupDataTable_resizeTimeout, _KupDataTable_columnMenuInstance, _KupDataTable_filtersColumnMenuInstance, _KupDataTable_filtersRowsInstance, _KupDataTable_detailCard, _KupDataTable_insertCard, _KupDataTable_confirmDeleteCard, _KupDataTable_confirmDeleteDialog, _KupDataTable_columnMenuCard, _KupDataTable_columnDropCard, _KupDataTable_columnDropCardAnchor, _KupDataTable_insertCount, _KupDataTable_BUTTON_CANCEL_ID, _KupDataTable_BUTTON_SUBMIT_ID, _KupDataTable_FIELDS_FORM_ID, _KupDataTable_MESSAGE_ID, _KupDataTable_MESSAGE_WRAPPER_ID, _KupDataTable_INSERT_PREFIX, _KupDataTable_closeDropCard, _KupDataTable_createDropCard, _KupDataTable_calculateData, _KupDataTable_getRow, _KupDataTable__getRow, _KupDataTable_getTransposedData, _KupDataTable_setTransposedData, _KupDataTable_switchToTotalsMatrix, _KupDataTable_setObjForTotalsMatrix, _KupDataTable_stickyHeaderPosition, _KupDataTable_updateStickyHeaderSize, _KupDataTable_setObserver, _KupDataTable_didLoadInteractables, _KupDataTable_didRenderInteractables, _KupDataTable_didLoadObservers, _KupDataTable_didRenderObservers, _KupDataTable_didLoadEventHandling, _KupDataTable_scrollStickyHeader, _KupDataTable_checkScrollOnHover, _KupDataTable_customizePanelPosition, _KupDataTable_rowsPointLength, _KupDataTable_paginatedRowsPointLength, _KupDataTable__rowsLength,
|
|
17
|
+
var _KupDataTable_instances, _KupDataTable_initialized, _KupDataTable_rows, _KupDataTable_rowsLength, _KupDataTable_paginatedRows, _KupDataTable_paginatedRowsLength, _KupDataTable_footer, _KupDataTable_kupManager, _KupDataTable_renderedRows, _KupDataTable_loadMoreEventCounter, _KupDataTable_loadMoreEventPreviousQuantity, _KupDataTable_theadRef, _KupDataTable_tableRef, _KupDataTable_originalData, _KupDataTable_tableAreaRef, _KupDataTable_stickyTheadRef, _KupDataTable_customizeTopButtonRef, _KupDataTable_customizeTopPanelRef, _KupDataTable_sizedColumns, _KupDataTable_intObserver, _KupDataTable_navBarHeight, _KupDataTable_theadIntersecting, _KupDataTable_tableIntersecting, _KupDataTable_isSafariBrowser, _KupDataTable_isRestoringState, _KupDataTable_globalFilterTimeout, _KupDataTable_totalMenuCoords, _KupDataTable_clickTimeout, _KupDataTable_thRefs, _KupDataTable_rowsRefs, _KupDataTable_oldWidth, _KupDataTable_hold, _KupDataTable_interactableDrag, _KupDataTable_interactableDrop, _KupDataTable_interactableResize, _KupDataTable_interactableTouch, _KupDataTable_dropareaRef, _KupDataTable_removeDropareaRef, _KupDataTable_groupsDropareaRef, _KupDataTable_clickCb, _KupDataTable_clickCbCustomPanel, _KupDataTable_clickCbDropCard, _KupDataTable_resizeTimeout, _KupDataTable_columnMenuInstance, _KupDataTable_filtersColumnMenuInstance, _KupDataTable_filtersRowsInstance, _KupDataTable_detailCard, _KupDataTable_insertCard, _KupDataTable_confirmDeleteCard, _KupDataTable_confirmDeleteDialog, _KupDataTable_columnMenuCard, _KupDataTable_columnDropCard, _KupDataTable_columnDropCardAnchor, _KupDataTable_insertCount, _KupDataTable_BUTTON_CANCEL_ID, _KupDataTable_BUTTON_SUBMIT_ID, _KupDataTable_FIELDS_FORM_ID, _KupDataTable_MESSAGE_ID, _KupDataTable_MESSAGE_WRAPPER_ID, _KupDataTable_INSERT_PREFIX, _KupDataTable_closeDropCard, _KupDataTable_createDropCard, _KupDataTable_calculateData, _KupDataTable_getRow, _KupDataTable__getRow, _KupDataTable_getTransposedData, _KupDataTable_setTransposedData, _KupDataTable_switchToTotalsMatrix, _KupDataTable_setObjForTotalsMatrix, _KupDataTable_stickyHeaderPosition, _KupDataTable_updateStickyHeaderSize, _KupDataTable_setObserver, _KupDataTable_didLoadInteractables, _KupDataTable_didRenderInteractables, _KupDataTable_didLoadObservers, _KupDataTable_didRenderObservers, _KupDataTable_didLoadEventHandling, _KupDataTable_scrollStickyHeader, _KupDataTable_checkScrollOnHover, _KupDataTable_customizePanelPosition, _KupDataTable_rowsPointLength, _KupDataTable_paginatedRowsPointLength, _KupDataTable__rowsLength, _KupDataTable_resetSelectedRows, _KupDataTable_getSizedColumns, _KupDataTable_rowDetail, _KupDataTable_rowInsertForm, _KupDataTable_rowsDelete, _KupDataTable_getEventDetails, _KupDataTable_clickHandler, _KupDataTable_contextMenuHandler, _KupDataTable_dblClickHandler, _KupDataTable_initRows, _KupDataTable_filterRows, _KupDataTable_isGrouping, _KupDataTable_hasRowActions, _KupDataTable_removeGroup, _KupDataTable_hasTotals, _KupDataTable_tableHasAutoWidth, _KupDataTable_forceGroupExpansion, _KupDataTable_forceRowGroupExpansion, _KupDataTable_adjustPaginator, _KupDataTable_composeFixedCellStyleAndClass, _KupDataTable_updateFixedRowsAndColumnsCssVariables, _KupDataTable_onColumnSort, _KupDataTable_onRemoveFilter, _KupDataTable_getFilterValueForTooltip, _KupDataTable_onGlobalFilterChange, _KupDataTable_handlePageChange, _KupDataTable_handleRowsPerPageChange, _KupDataTable_onRowClick, _KupDataTable_selectColumn, _KupDataTable_deselectColumn, _KupDataTable_onDefaultRowActionClick, _KupDataTable_onRowActionExpanderClick, _KupDataTable_handleRowSelect, _KupDataTable_onRowExpand, _KupDataTable_onSelectAll, _KupDataTable_openTotalMenu, _KupDataTable_closeTotalMenu, _KupDataTable_isOpenedTotalMenuForColumn, _KupDataTable_groupRows, _KupDataTable_onLoadMoreClick, _KupDataTable_adjustGroupState, _KupDataTable_adjustGroupStateFromRow, _KupDataTable_sortRows, _KupDataTable_getSortIcon, _KupDataTable_getSortDecode, _KupDataTable_calculateColspan, _KupDataTable_isGroupExpanded, _KupDataTable_handleColumnSort, _KupDataTable_moveSortedColumns, _KupDataTable_applyLineBreaks, _KupDataTable_composeHeaderCellClassAndStyle, _KupDataTable_renderHeader, _KupDataTable_renderStickyHeader, _KupDataTable_totalMenuPosition, _KupDataTable_onTotalMenuOpen, _KupDataTable_renderRow, _KupDataTable_renderActions, _KupDataTable_onCustomSettingsClick, _KupDataTable_openCustomSettings, _KupDataTable_closeCustomSettings, _KupDataTable_renderPaginator, _KupDataTable_columnRemoveArea, _KupDataTable_columnGroupArea, _KupDataTable_hideShowColumnDropArea, _KupDataTable_handleColumnGroup, _KupDataTable_transcodeItem, _KupDataTable_createListData, _KupDataTable_FONTSIZE_CODES, _KupDataTable_FONTSIZE_DECODES, _KupDataTable_FONTSIZE_ICONS, _KupDataTable_getFontSizeCodeFromDecode, _KupDataTable_renderFontSizePanel, _KupDataTable_DENSITY_DECODES, _KupDataTable_DENSITY_ICONS, _KupDataTable_getDensityCodeFromDecode, _KupDataTable_renderDensityPanel, _KupDataTable_GRID_CODES, _KupDataTable_GRID_DECODES, _KupDataTable_GRID_ICONS, _KupDataTable_getGridCodeFromDecode, _KupDataTable_renderTransposeSwitch, _KupDataTable_renderTotalsMatrix, _KupDataTable_renderGridPanel;
|
|
18
18
|
import { forceUpdate, h, Host, } from "@stencil/core";
|
|
19
19
|
import { FixedCellsClasses, FixedCellsCSSVarsBase, GroupLabelDisplayMode, LoadMoreMode, PaginatorPos, ShowGrid, SortMode, TotalMode, TotalLabel, KupDataTableProps, fieldColumn, iconColumn, keyColumn, SelectionMode, } from "./kup-data-table-declarations";
|
|
20
20
|
import { getColumnByName } from "../../utils/cell-utils";
|
|
@@ -818,7 +818,6 @@ export class KupDataTable {
|
|
|
818
818
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_didRenderObservers).call(this);
|
|
819
819
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_didRenderInteractables).call(this);
|
|
820
820
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_hideShowColumnDropArea).call(this, false);
|
|
821
|
-
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_setDynPosElements).call(this);
|
|
822
821
|
if (this.headerIsPersistent &&
|
|
823
822
|
this.tableHeight === undefined &&
|
|
824
823
|
this.tableWidth === undefined) {
|
|
@@ -1105,7 +1104,10 @@ export class KupDataTable {
|
|
|
1105
1104
|
' Open AI ' +
|
|
1106
1105
|
'(' +
|
|
1107
1106
|
__classPrivateFieldGet(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EXPERIMENTAL_FEAT) +
|
|
1108
|
-
')', icon: "open-ai", "onkup-button-click": () => __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").openAI.show(
|
|
1107
|
+
')', icon: "open-ai", "onkup-button-click": () => __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").openAI.show({
|
|
1108
|
+
context: this.rootElement.tagName,
|
|
1109
|
+
dataset: this.data,
|
|
1110
|
+
}) })) : null), totalsMatrix));
|
|
1109
1111
|
}
|
|
1110
1112
|
render() {
|
|
1111
1113
|
__classPrivateFieldSet(this, _KupDataTable_thRefs, [], "f");
|
|
@@ -1115,7 +1117,7 @@ export class KupDataTable {
|
|
|
1115
1117
|
__classPrivateFieldSet(this, _KupDataTable_sizedColumns, __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_getSizedColumns).call(this), "f");
|
|
1116
1118
|
let rows = null;
|
|
1117
1119
|
if (__classPrivateFieldGet(this, _KupDataTable_paginatedRowsLength, "f") === 0) {
|
|
1118
|
-
rows = (h("tr", { key: '
|
|
1120
|
+
rows = (h("tr", { key: '9335ea21f2b6bdbd150ae6225485da12d48cf1e1', ref: (el) => __classPrivateFieldGet(this, _KupDataTable_rowsRefs, "f").push(el) }, h("td", { key: '40a2bffa4968d9de85c760a2b75edaa00162d911', colSpan: __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_calculateColspan).call(this) }, this.emptyDataLabel)));
|
|
1119
1121
|
}
|
|
1120
1122
|
else {
|
|
1121
1123
|
rows = [];
|
|
@@ -1179,7 +1181,7 @@ export class KupDataTable {
|
|
|
1179
1181
|
for (let i = 0; i < chipsData.length; i++) {
|
|
1180
1182
|
props.onIconClick.push(() => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_removeGroup).call(this, i));
|
|
1181
1183
|
}
|
|
1182
|
-
groupChips = h(FChip, Object.assign({ key: '
|
|
1184
|
+
groupChips = h(FChip, Object.assign({ key: '61ab9155ed4ac49adca414c297c1b98b984e579f' }, props));
|
|
1183
1185
|
}
|
|
1184
1186
|
}
|
|
1185
1187
|
const tableClass = {
|
|
@@ -1212,7 +1214,7 @@ export class KupDataTable {
|
|
|
1212
1214
|
if (this.headerIsPersistent &&
|
|
1213
1215
|
this.tableHeight === undefined &&
|
|
1214
1216
|
this.tableWidth === undefined) {
|
|
1215
|
-
stickyEl = (h("sticky-header", { key: '
|
|
1217
|
+
stickyEl = (h("sticky-header", { key: '0c6567b602e3efaf000e125cf5c33ccbe8f6eb72', class: "hover-scrolling-child", hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_stickyTheadRef, el, "f")) }, h("thead-sticky", { key: '9d9fdbba7d9562c167d4da9c1349849984dcf8d9' }, h("tr-sticky", { key: '32a5070049fd847130e388a19cfca4fd389d7575' }, stickyHeader))));
|
|
1216
1218
|
}
|
|
1217
1219
|
let belowClass = 'below-wrapper';
|
|
1218
1220
|
if (this.tableHeight !== undefined || this.tableWidth !== undefined) {
|
|
@@ -1235,11 +1237,11 @@ export class KupDataTable {
|
|
|
1235
1237
|
}
|
|
1236
1238
|
}
|
|
1237
1239
|
};
|
|
1238
|
-
const compCreated = (h(Host, { key: '
|
|
1240
|
+
const compCreated = (h(Host, { key: '4801724ab5230c778c411c614d664aa1129f456d', "onKup-cell-input": autoselectOnAction, "onKup-cell-update": autoselectOnAction }, h("style", { key: 'cc1e4c9d1e7ead054d92776378c37735c0bbebf8' }, __classPrivateFieldGet(this, _KupDataTable_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { key: 'bdf2452f9219c630121c520580e11e782cc79c08', id: componentWrapperId }, h("div", { key: '0cf23b0bb3fd233fbfee9cebd5f09acff32484c2', class: "above-wrapper" }, this.globalFilter ? (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) => {
|
|
1239
1241
|
const t = event.target;
|
|
1240
1242
|
window.clearTimeout(__classPrivateFieldGet(this, _KupDataTable_globalFilterTimeout, "f"));
|
|
1241
1243
|
__classPrivateFieldSet(this, _KupDataTable_globalFilterTimeout, window.setTimeout(() => __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_onGlobalFilterChange).call(this, t), 600, t), "f");
|
|
1242
|
-
} }))) : null, paginatorTop), h("div", { key: '
|
|
1244
|
+
} }))) : null, paginatorTop), h("div", { key: '26916a65abbf6324ccfee2dcd6d1ab4214bca5cc', class: "group-wrapper" }, groupChips), h("div", { key: '5c3f4d390bf371cf7b006c6b087fa02a3ef1af06', class: "actions-wrapper" }, this.insertMode !== '' ? (h(FButton, { icon: "plus", onClick: async () => {
|
|
1243
1245
|
var _a;
|
|
1244
1246
|
if (this.insertMode === 'form') {
|
|
1245
1247
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_rowInsertForm).call(this);
|
|
@@ -1287,9 +1289,9 @@ export class KupDataTable {
|
|
|
1287
1289
|
id: this.rootElement.id,
|
|
1288
1290
|
selectedRows: this.selectedRows,
|
|
1289
1291
|
});
|
|
1290
|
-
}, styling: FButtonStyling.OUTLINED, title: "History", wrapperClass: "history-button" })) : null), h("div", { key: '
|
|
1292
|
+
}, styling: FButtonStyling.OUTLINED, title: "History", wrapperClass: "history-button" })) : null), h("div", { key: 'c87846c5daeb2297668a7fff518601892a509e1d', class: "droparea", ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_dropareaRef, el, "f")) }, this.showGroups ? __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_columnGroupArea).call(this) : null, this.removableColumns
|
|
1291
1293
|
? __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_columnRemoveArea).call(this)
|
|
1292
|
-
: null), h("div", { key: '
|
|
1294
|
+
: null), h("div", { key: '9354ce51cd005c435b9b7f1d314709c6b99690c6', style: elStyle, class: belowClass, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_tableAreaRef, el, "f")) }, this.showCustomization
|
|
1293
1295
|
? [
|
|
1294
1296
|
h("div", { class: "settings-trigger", onClick: () => {
|
|
1295
1297
|
__classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_onCustomSettingsClick).call(this);
|
|
@@ -1298,11 +1300,11 @@ export class KupDataTable {
|
|
|
1298
1300
|
} }, h(FImage, { color: `var(${KupThemeColorValues.TITLE})`, resource: "settings", sizeX: "10px" })),
|
|
1299
1301
|
this.renderCustomizePanel(),
|
|
1300
1302
|
]
|
|
1301
|
-
: null, h("table", { key: '
|
|
1303
|
+
: null, h("table", { key: '9c6e5b310a757cf81dd6a8eac749f2bffdd78ceb', class: tableClass, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_tableRef, el, "f")), onMouseLeave: (ev) => {
|
|
1302
1304
|
ev.stopPropagation();
|
|
1303
1305
|
}, onContextMenu: (e) => {
|
|
1304
1306
|
e.preventDefault();
|
|
1305
|
-
} }, h("thead", { key: '
|
|
1307
|
+
} }, h("thead", { key: '5d59c9afbb81ebfc999e190230fd33572da4b568', hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet(this, _KupDataTable_theadRef, el, "f")) }, h("tr", { key: '0f356d0dd3883abf72456bb31e875ceb0e23093b' }, header)), h("tbody", { key: '9c828bc56d24b00ae46c11697dcec623a8e7bbba' }, rows), this.showFooter || __classPrivateFieldGet(this, _KupDataTable_instances, "m", _KupDataTable_hasTotals).call(this)
|
|
1306
1308
|
? this.renderFooter()
|
|
1307
1309
|
: null), stickyEl), paginatorBottom)));
|
|
1308
1310
|
return compCreated;
|
|
@@ -4039,11 +4041,6 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
4039
4041
|
}
|
|
4040
4042
|
}
|
|
4041
4043
|
return count;
|
|
4042
|
-
}, _KupDataTable_setDynPosElements = function _KupDataTable_setDynPosElements() {
|
|
4043
|
-
// Column menu
|
|
4044
|
-
if (__classPrivateFieldGet(this, _KupDataTable_columnMenuCard, "f") && __classPrivateFieldGet(this, _KupDataTable_columnMenuCard, "f").data) {
|
|
4045
|
-
__classPrivateFieldGet(this, _KupDataTable_columnMenuCard, "f").data = __classPrivateFieldGet(this, _KupDataTable_columnMenuInstance, "f").prepData(this, getColumnByName(this.getVisibleColumns(), this.columnMenuAnchor), __classPrivateFieldGet(this, _KupDataTable_columnMenuCard, "f").data);
|
|
4046
|
-
}
|
|
4047
4044
|
}, _KupDataTable_resetSelectedRows = function _KupDataTable_resetSelectedRows() {
|
|
4048
4045
|
if (this.getRows().length === 0)
|
|
4049
4046
|
return;
|