@sme.up/ketchup 8.0.0 → 8.0.1
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-49b2c37c.js → f-button-c0ede055.js} +2 -2
- package/dist/cjs/{f-cell-9a6bc55c.js → f-cell-1c17dbac.js} +17 -10
- package/dist/cjs/{f-checkbox-593f72c3.js → f-checkbox-1148e791.js} +1 -1
- package/dist/cjs/{f-chip-dee84122.js → f-chip-bace36bb.js} +3 -3
- package/dist/cjs/{f-image-27f965ff.js → f-image-22174590.js} +2 -2
- package/dist/cjs/{f-paginator-utils-4a30189d.js → f-paginator-utils-e21e1f06.js} +3 -3
- package/dist/cjs/{f-text-field-04a663b4.js → f-text-field-503f2bb0.js} +83 -9
- package/dist/cjs/{index-74433248.js → index-1f177abc.js} +0 -3
- package/dist/cjs/ketchup.cjs.js +2 -2
- package/dist/cjs/kup-accordion.cjs.entry.js +3 -3
- package/dist/cjs/kup-autocomplete_27.cjs.entry.js +778 -740
- package/dist/cjs/kup-box.cjs.entry.js +10 -10
- package/dist/cjs/kup-calendar.cjs.entry.js +5 -5
- package/dist/cjs/kup-cell.cjs.entry.js +7 -7
- package/dist/cjs/kup-dash-list.cjs.entry.js +3 -4
- package/dist/cjs/kup-dash_2.cjs.entry.js +2 -2
- package/dist/cjs/kup-dashboard.cjs.entry.js +6 -6
- package/dist/cjs/kup-drawer.cjs.entry.js +2 -2
- package/dist/cjs/kup-echart.cjs.entry.js +2 -2
- package/dist/cjs/kup-family-tree.cjs.entry.js +4 -4
- package/dist/cjs/kup-iframe.cjs.entry.js +2 -2
- package/dist/cjs/kup-image-list.cjs.entry.js +8 -8
- package/dist/cjs/kup-lazy.cjs.entry.js +2 -2
- package/dist/cjs/kup-magic-box.cjs.entry.js +3 -3
- package/dist/cjs/{kup-manager-2ff5d258.js → kup-manager-b994cf71.js} +88 -16
- package/dist/cjs/kup-nav-bar.cjs.entry.js +2 -2
- package/dist/cjs/kup-numeric-picker.cjs.entry.js +3 -3
- package/dist/cjs/kup-photo-frame.cjs.entry.js +2 -2
- package/dist/cjs/kup-planner.cjs.entry.js +3 -3
- package/dist/cjs/kup-probe.cjs.entry.js +2 -2
- package/dist/cjs/kup-qlik.cjs.entry.js +2 -2
- package/dist/cjs/kup-snackbar.cjs.entry.js +12 -4
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/assets/data-table.js +44 -0
- package/dist/collection/components/kup-dash-list/kup-dash-list.js +1 -3
- package/dist/collection/components/kup-data-table/kup-data-table-state.js +1 -1
- package/dist/collection/components/kup-snackbar/kup-snackbar.js +27 -0
- package/dist/collection/components/kup-text-field/kup-text-field-declarations.js +3 -0
- package/dist/collection/components/kup-text-field/kup-text-field.js +109 -10
- package/dist/collection/f-components/f-cell/f-cell.js +12 -5
- package/dist/collection/f-components/f-text-field/f-text-field.js +80 -6
- package/dist/collection/managers/kup-math/kup-math.js +85 -4
- package/dist/collection/utils/utils.js +1 -10
- package/dist/components/kup-autocomplete2.js +543 -349
- package/dist/components/kup-dash-list.js +2 -3
- 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-echart2.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-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 +8 -0
- 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-744cf1f6.js → f-button-c377973d.js} +2 -2
- package/dist/esm/{f-cell-b319c869.js → f-cell-e5a98bc8.js} +17 -10
- package/dist/esm/{f-checkbox-ec85b437.js → f-checkbox-9b3f5f5b.js} +1 -1
- package/dist/esm/{f-chip-7e3e4180.js → f-chip-c8a18c48.js} +3 -3
- package/dist/esm/{f-image-098c26ce.js → f-image-5cbdf39d.js} +2 -2
- package/dist/esm/{f-paginator-utils-674cb2ae.js → f-paginator-utils-a1dab059.js} +3 -3
- package/dist/esm/{f-text-field-c38ef113.js → f-text-field-dafb7c8b.js} +83 -9
- package/dist/esm/{index-b326ffc9.js → index-8bd38435.js} +1 -3
- package/dist/esm/ketchup.js +3 -3
- package/dist/esm/kup-accordion.entry.js +3 -3
- package/dist/esm/kup-autocomplete_27.entry.js +778 -740
- package/dist/esm/kup-box.entry.js +10 -10
- package/dist/esm/kup-calendar.entry.js +5 -5
- package/dist/esm/kup-cell.entry.js +7 -7
- package/dist/esm/kup-dash-list.entry.js +3 -4
- package/dist/esm/kup-dash_2.entry.js +2 -2
- package/dist/esm/kup-dashboard.entry.js +6 -6
- package/dist/esm/kup-drawer.entry.js +2 -2
- package/dist/esm/kup-echart.entry.js +2 -2
- package/dist/esm/kup-family-tree.entry.js +4 -4
- package/dist/esm/kup-iframe.entry.js +2 -2
- package/dist/esm/kup-image-list.entry.js +8 -8
- package/dist/esm/kup-lazy.entry.js +2 -2
- package/dist/esm/kup-magic-box.entry.js +3 -3
- package/dist/esm/{kup-manager-b41eb2a8.js → kup-manager-3594cde8.js} +88 -16
- package/dist/esm/kup-nav-bar.entry.js +2 -2
- package/dist/esm/kup-numeric-picker.entry.js +3 -3
- package/dist/esm/kup-photo-frame.entry.js +2 -2
- package/dist/esm/kup-planner.entry.js +3 -3
- package/dist/esm/kup-probe.entry.js +2 -2
- package/dist/esm/kup-qlik.entry.js +2 -2
- package/dist/esm/kup-snackbar.entry.js +12 -4
- package/dist/esm/loader.js +3 -3
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/{p-3efe7f43.entry.js → p-017418e7.entry.js} +1 -1
- package/dist/ketchup/{p-395e1960.entry.js → p-22e72f06.entry.js} +1 -1
- package/dist/ketchup/{p-77e3d537.js → p-2d32e3cd.js} +1 -1
- package/dist/ketchup/{p-5ce2b4fc.entry.js → p-31abf4b6.entry.js} +1 -1
- package/dist/ketchup/{p-b244f5ca.entry.js → p-37ada0f0.entry.js} +1 -1
- package/dist/ketchup/{p-a877a87b.entry.js → p-38f16697.entry.js} +2 -2
- package/dist/ketchup/{p-9700eb32.js → p-4638fbff.js} +1 -1
- package/dist/ketchup/{p-af82131e.entry.js → p-473d2bea.entry.js} +1 -1
- package/dist/ketchup/{p-da891093.entry.js → p-4c56e199.entry.js} +1 -1
- package/dist/ketchup/{p-a9b7533b.entry.js → p-5205286a.entry.js} +1 -1
- package/dist/ketchup/p-61319cfa.js +1 -0
- package/dist/ketchup/{p-ef614656.js → p-6762d447.js} +1 -1
- package/dist/ketchup/p-6c726886.entry.js +1 -0
- package/dist/ketchup/{p-0b91f5f8.entry.js → p-7be5ef32.entry.js} +1 -1
- package/dist/ketchup/{p-3b41aca7.entry.js → p-7f4f5f0f.entry.js} +1 -1
- package/dist/ketchup/{p-b032f47d.entry.js → p-80815edf.entry.js} +1 -1
- package/dist/ketchup/p-8b248655.js +1 -0
- package/dist/ketchup/{p-d4ece435.js → p-9dcfbb1e.js} +2 -2
- package/dist/ketchup/{p-c26975bf.js → p-9f9b6656.js} +1 -1
- package/dist/ketchup/{p-4325d965.entry.js → p-9fc6a9a8.entry.js} +1 -1
- package/dist/ketchup/{p-940a5feb.js → p-acaa171f.js} +3 -3
- package/dist/ketchup/{p-4ae2ca6f.entry.js → p-afff7a6e.entry.js} +1 -1
- package/dist/ketchup/{p-bd42562d.entry.js → p-b718af72.entry.js} +1 -1
- package/dist/ketchup/p-bf4a881b.js +1 -0
- package/dist/ketchup/{p-d739710a.entry.js → p-ce5b6ce7.entry.js} +1 -1
- package/dist/ketchup/p-cf322853.entry.js +1 -0
- package/dist/ketchup/{p-bb17c1ba.entry.js → p-d1164680.entry.js} +1 -1
- package/dist/ketchup/p-d4eb9a76.entry.js +1 -0
- package/dist/ketchup/p-d76be079.entry.js +1 -0
- package/dist/ketchup/{p-e02b5141.entry.js → p-ed7e118e.entry.js} +1 -1
- package/dist/ketchup/{p-a7e19620.entry.js → p-ef0b4f19.entry.js} +1 -1
- package/dist/types/components/kup-data-table/kup-data-table-state.d.ts +1 -1
- package/dist/types/components/kup-snackbar/kup-snackbar.d.ts +5 -0
- package/dist/types/components/kup-text-field/kup-text-field-declarations.d.ts +3 -0
- package/dist/types/components/kup-text-field/kup-text-field.d.ts +20 -2
- package/dist/types/components.d.ts +34 -0
- package/dist/types/f-components/f-text-field/f-text-field-declarations.d.ts +3 -0
- package/dist/types/managers/kup-math/kup-math-declarations.d.ts +6 -0
- package/dist/types/managers/kup-math/kup-math.d.ts +26 -2
- package/dist/types/utils/utils.d.ts +0 -1
- package/package.json +1 -1
- package/dist/ketchup/p-0b0b61cb.entry.js +0 -1
- package/dist/ketchup/p-5d398e42.js +0 -1
- package/dist/ketchup/p-c8b7790a.entry.js +0 -1
- package/dist/ketchup/p-c968e93d.entry.js +0 -1
- package/dist/ketchup/p-d98fdb9b.js +0 -1
- package/dist/ketchup/p-df316daf.entry.js +0 -1
- package/dist/ketchup/p-e714f4dc.js +0 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, f as forceUpdate, h, H as Host, g as getElement$1, a as getAssetPath } from './index-
|
|
2
|
-
import { k as kupManagerInstance, g as getProps, s as setProps, K as KupThemeIconValues, a as KupDynamicPositionPlacement, b as KupThemeColorValues, c as KupDebugCategory, F as FCellShapes, d as FCellPadding, e as getMonthsAsStringByLocale, f as KupDatesFormats, D as DateTimeFormatOptionsMonth, h as KupCardBuiltInClockElements, i as KupCardCSSClasses, j as KupLanguageTotals, l as KupLanguageGeneric, m as KupLanguageColumn, n as KupDataNewColumnTypes, o as KupCardSubEvents, p as KupCardIds, q as KupLanguageRow, r as KupCardFamily, t as KupCardProps, u as getColumnByName, v as KupDates, w as formatToNumber, x as KupDatesNormalize, y as KupObjects, z as identify, G as GroupLabelDisplayMode, S as SelectionMode, A as KupLanguageGrouping, B as KupLanguageCheckbox, C as getValueForDisplay2, E as Filters, H as getValueForDisplay, I as KupLanguageSearch, J as FilterInterval, L as LoadMoreMode, P as PaginatorPos, M as ShowGrid, T as TotalLabel, N as TotalMode, O as numberToFormattedStringNumber, Q as kupDynamicPositionAttribute, R as KupPointerEventTypes, U as kupDraggableColumnAttr, V as kupDragActiveAttr, W as KupDragEffect, X as kupDraggableCellAttr, Y as KupDropEventTypes, Z as FixedCellsCSSVarsBase, _ as KupLanguageFontsize, $ as KupLanguageDensity, a0 as KupLanguageGrid, a1 as KupDataTableProps, a2 as FixedCellsClasses, a3 as SortMode, a4 as iconColumn, a5 as keyColumn, a6 as fieldColumn, a7 as FCellTypes, a8 as unformattedStringToFormattedStringNumber, a9 as
|
|
3
|
-
import { F as FTextField } from './f-text-field-
|
|
1
|
+
import { r as registerInstance, c as createEvent, f as forceUpdate, h, H as Host, g as getElement$1, a as getAssetPath } from './index-8bd38435.js';
|
|
2
|
+
import { k as kupManagerInstance, g as getProps, s as setProps, K as KupThemeIconValues, a as KupDynamicPositionPlacement, b as KupThemeColorValues, c as KupDebugCategory, F as FCellShapes, d as FCellPadding, e as getMonthsAsStringByLocale, f as KupDatesFormats, D as DateTimeFormatOptionsMonth, h as KupCardBuiltInClockElements, i as KupCardCSSClasses, j as KupLanguageTotals, l as KupLanguageGeneric, m as KupLanguageColumn, n as KupDataNewColumnTypes, o as KupCardSubEvents, p as KupCardIds, q as KupLanguageRow, r as KupCardFamily, t as KupCardProps, u as getColumnByName, v as KupDates, w as formatToNumber, x as KupDatesNormalize, y as KupObjects, z as identify, G as GroupLabelDisplayMode, S as SelectionMode, A as KupLanguageGrouping, B as KupLanguageCheckbox, C as getValueForDisplay2, E as Filters, H as getValueForDisplay, I as KupLanguageSearch, J as FilterInterval, L as LoadMoreMode, P as PaginatorPos, M as ShowGrid, T as TotalLabel, N as TotalMode, O as numberToFormattedStringNumber, Q as kupDynamicPositionAttribute, R as KupPointerEventTypes, U as kupDraggableColumnAttr, V as kupDragActiveAttr, W as KupDragEffect, X as kupDraggableCellAttr, Y as KupDropEventTypes, Z as FixedCellsCSSVarsBase, _ as KupLanguageFontsize, $ as KupLanguageDensity, a0 as KupLanguageGrid, a1 as KupDataTableProps, a2 as FixedCellsClasses, a3 as SortMode, a4 as iconColumn, a5 as keyColumn, a6 as fieldColumn, a7 as FCellTypes, a8 as unformattedStringToFormattedStringNumber, a9 as formattedStringToUnformattedStringNumber, aa as formattedStringToCustomUnformattedStringTime, ab as isValidFormattedStringTime, ac as formatTime, ad as unformattedStringToFormattedStringTime, ae as addColumnValueFromRow, af as KupGlobalFilterMode } from './kup-manager-3594cde8.js';
|
|
3
|
+
import { F as FTextField } from './f-text-field-dafb7c8b.js';
|
|
4
4
|
import { F as FTextFieldMDC } from './f-text-field-mdc-cee583ea.js';
|
|
5
|
-
import { I as ItemsDisplayMode, F as FCell, K as KupListRole, a as KupListProps, b as FSwitch } from './f-cell-
|
|
5
|
+
import { I as ItemsDisplayMode, F as FCell, K as KupListRole, a as KupListProps, b as FSwitch } from './f-cell-e5a98bc8.js';
|
|
6
6
|
import { c as componentWrapperId } from './GenericVariables-665de00a.js';
|
|
7
|
-
import { F as FImage } from './f-image-
|
|
8
|
-
import { F as FButton } from './f-button-
|
|
7
|
+
import { F as FImage } from './f-image-5cbdf39d.js';
|
|
8
|
+
import { F as FButton } from './f-button-c377973d.js';
|
|
9
9
|
import { F as FButtonStyling } from './f-button-declarations-b1b4cac4.js';
|
|
10
|
-
import { F as FChipType, a as FChip } from './f-chip-
|
|
10
|
+
import { F as FChipType, a as FChip } from './f-chip-c8a18c48.js';
|
|
11
11
|
import { M as MDCRipple } from './component-120651a0.js';
|
|
12
|
-
import { F as FCheckbox } from './f-checkbox-
|
|
13
|
-
import { F as FiltersColumnMenu, a as FiltersRows, c as calcTotals, n as normalizeRows, p as paginateRows, f as filterRows, g as groupRows, s as sortRows, b as FPaginator, d as pageChange, r as rowsPerPageChange, t as treeMainColumnName, K as KupTreeExpansionMode, e as KupTreeProps } from './f-paginator-utils-
|
|
12
|
+
import { F as FCheckbox } from './f-checkbox-9b3f5f5b.js';
|
|
13
|
+
import { F as FiltersColumnMenu, a as FiltersRows, c as calcTotals, n as normalizeRows, p as paginateRows, f as filterRows, g as groupRows, s as sortRows, b as FPaginator, d as pageChange, r as rowsPerPageChange, t as treeMainColumnName, K as KupTreeExpansionMode, e as KupTreeProps } from './f-paginator-utils-a1dab059.js';
|
|
14
14
|
import './tslib.es6-8c2af864.js';
|
|
15
15
|
|
|
16
16
|
/**
|
|
@@ -164,7 +164,7 @@ function getItemByDisplayMode(listData, id, displayMode, setSelected) {
|
|
|
164
164
|
|
|
165
165
|
const kupAutocompleteCss = ":host{display:block;width:max-content}.kup-icon{transition:transform 0.15s}.toggled .kup-icon.kup-dropdown-icon{transform:rotate(-180deg)}.kup-icon.kup-dropdown-icon{-webkit-mask:var(--kup-dropdown-icon);mask:var(--kup-dropdown-icon)}.f-text-field{position:relative}:host(.kup-full-height){height:100%}:host(.kup-full-height) #kup-component,:host(.kup-full-height) .f-text-field,:host(.kup-full-height) .mdc-text-field{height:100%}:host(.kup-full-width){width:100%}:host(.kup-full-width) #kup-component{width:100%}:host(.kup-danger){--kup-textfield-primary-color:var(--kup-danger-color);--kup-textfield-primary-color-rgb:var(--kup-danger-color-rgb)}:host(.kup-info){--kup-textfield-primary-color:var(--kup-info-color);--kup-textfield-primary-color-rgb:var(--kup-info-color-rgb)}:host(.kup-secondary){--kup-textfield-primary-color:var(--kup-secondary-color);--kup-textfield-primary-color-rgb:var(--kup-secondary-color-rgb)}:host(.kup-success){--kup-textfield-primary-color:var(--kup-success-color);--kup-textfield-primary-color-rgb:var(--kup-success-color-rgb)}:host(.kup-warning){--kup-textfield-primary-color:var(--kup-warning-color);--kup-textfield-primary-color-rgb:var(--kup-warning-color-rgb)}";
|
|
166
166
|
|
|
167
|
-
var __classPrivateFieldGet$
|
|
167
|
+
var __classPrivateFieldGet$7 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
168
168
|
if (kind === "a" && !f)
|
|
169
169
|
throw new TypeError("Private accessor was defined without a getter");
|
|
170
170
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -225,18 +225,18 @@ const KupAutocomplete = class {
|
|
|
225
225
|
comp: this,
|
|
226
226
|
id: this.rootElement.id,
|
|
227
227
|
value: this.value,
|
|
228
|
-
inputValue: __classPrivateFieldGet$
|
|
228
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
229
229
|
});
|
|
230
230
|
}
|
|
231
231
|
onKupChange(value) {
|
|
232
232
|
__classPrivateFieldSet$4(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
233
|
-
const ret = __classPrivateFieldGet$
|
|
233
|
+
const ret = __classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, value, true);
|
|
234
234
|
if (ret.exists || this.allowInconsistentValues) {
|
|
235
235
|
this.kupChange.emit({
|
|
236
236
|
comp: this,
|
|
237
237
|
id: this.rootElement.id,
|
|
238
238
|
value: this.value,
|
|
239
|
-
inputValue: __classPrivateFieldGet$
|
|
239
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
240
240
|
node: ret.node,
|
|
241
241
|
});
|
|
242
242
|
}
|
|
@@ -246,7 +246,7 @@ const KupAutocomplete = class {
|
|
|
246
246
|
comp: this,
|
|
247
247
|
id: this.rootElement.id,
|
|
248
248
|
value: this.value,
|
|
249
|
-
inputValue: __classPrivateFieldGet$
|
|
249
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
250
250
|
});
|
|
251
251
|
}
|
|
252
252
|
onKupFocus() {
|
|
@@ -254,51 +254,51 @@ const KupAutocomplete = class {
|
|
|
254
254
|
comp: this,
|
|
255
255
|
id: this.rootElement.id,
|
|
256
256
|
value: this.value,
|
|
257
|
-
inputValue: __classPrivateFieldGet$
|
|
257
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
258
258
|
});
|
|
259
259
|
}
|
|
260
260
|
onKupInput() {
|
|
261
261
|
__classPrivateFieldSet$4(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
262
|
-
const ret = __classPrivateFieldGet$
|
|
263
|
-
__classPrivateFieldGet$
|
|
264
|
-
if (__classPrivateFieldGet$
|
|
262
|
+
const ret = __classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value, false);
|
|
263
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
264
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value.length >= this.minimumChars) {
|
|
265
265
|
this.kupInput.emit({
|
|
266
266
|
comp: this,
|
|
267
267
|
id: this.rootElement.id,
|
|
268
268
|
value: this.value,
|
|
269
|
-
inputValue: __classPrivateFieldGet$
|
|
269
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
270
270
|
node: ret.node,
|
|
271
271
|
});
|
|
272
272
|
}
|
|
273
273
|
}
|
|
274
274
|
onKupIconClick() {
|
|
275
|
-
if (__classPrivateFieldGet$
|
|
276
|
-
__classPrivateFieldGet$
|
|
275
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f").classList.contains('toggled')) {
|
|
276
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
277
277
|
}
|
|
278
278
|
else {
|
|
279
279
|
if (this.showDropDownIcon) {
|
|
280
|
-
__classPrivateFieldGet$
|
|
280
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, true);
|
|
281
281
|
}
|
|
282
282
|
}
|
|
283
283
|
this.kupIconClick.emit({
|
|
284
284
|
comp: this,
|
|
285
285
|
id: this.rootElement.id,
|
|
286
286
|
value: this.value,
|
|
287
|
-
inputValue: __classPrivateFieldGet$
|
|
288
|
-
open: __classPrivateFieldGet$
|
|
287
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
288
|
+
open: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f").classList.contains('toggled'),
|
|
289
289
|
});
|
|
290
290
|
}
|
|
291
291
|
onKupItemClick(e) {
|
|
292
292
|
this.onKupChange(e.detail.selected.id);
|
|
293
|
-
__classPrivateFieldGet$
|
|
294
|
-
if (__classPrivateFieldGet$
|
|
295
|
-
__classPrivateFieldGet$
|
|
293
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
294
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f")) {
|
|
295
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
296
296
|
}
|
|
297
297
|
this.kupItemClick.emit({
|
|
298
298
|
comp: this,
|
|
299
299
|
id: this.rootElement.id,
|
|
300
300
|
value: this.value,
|
|
301
|
-
inputValue: __classPrivateFieldGet$
|
|
301
|
+
inputValue: __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
302
302
|
node: e.detail.selected,
|
|
303
303
|
});
|
|
304
304
|
}
|
|
@@ -306,30 +306,30 @@ const KupAutocomplete = class {
|
|
|
306
306
|
/* L i s t e n e r s */
|
|
307
307
|
/*-------------------------------------------------*/
|
|
308
308
|
listenKeydown(e) {
|
|
309
|
-
if (__classPrivateFieldGet$
|
|
309
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_isListOpened).call(this)) {
|
|
310
310
|
switch (e.key) {
|
|
311
311
|
case 'ArrowDown':
|
|
312
312
|
e.preventDefault();
|
|
313
313
|
e.stopPropagation();
|
|
314
|
-
__classPrivateFieldGet$
|
|
314
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").focusNext();
|
|
315
315
|
break;
|
|
316
316
|
case 'ArrowUp':
|
|
317
317
|
e.preventDefault();
|
|
318
318
|
e.stopPropagation();
|
|
319
|
-
__classPrivateFieldGet$
|
|
319
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").focusPrevious();
|
|
320
320
|
break;
|
|
321
321
|
case 'Enter':
|
|
322
322
|
e.preventDefault();
|
|
323
323
|
e.stopPropagation();
|
|
324
|
-
__classPrivateFieldGet$
|
|
325
|
-
__classPrivateFieldGet$
|
|
326
|
-
__classPrivateFieldGet$
|
|
324
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").select().then(() => {
|
|
325
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
326
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
327
327
|
});
|
|
328
328
|
break;
|
|
329
329
|
case 'Escape':
|
|
330
330
|
e.preventDefault();
|
|
331
331
|
e.stopPropagation();
|
|
332
|
-
__classPrivateFieldGet$
|
|
332
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
333
333
|
break;
|
|
334
334
|
}
|
|
335
335
|
}
|
|
@@ -338,14 +338,14 @@ const KupAutocomplete = class {
|
|
|
338
338
|
case 'ArrowDown':
|
|
339
339
|
e.preventDefault();
|
|
340
340
|
e.stopPropagation();
|
|
341
|
-
__classPrivateFieldGet$
|
|
342
|
-
__classPrivateFieldGet$
|
|
341
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
342
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").focusNext();
|
|
343
343
|
break;
|
|
344
344
|
case 'ArrowUp':
|
|
345
345
|
e.preventDefault();
|
|
346
346
|
e.stopPropagation();
|
|
347
|
-
__classPrivateFieldGet$
|
|
348
|
-
__classPrivateFieldGet$
|
|
347
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
348
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").focusPrevious();
|
|
349
349
|
break;
|
|
350
350
|
}
|
|
351
351
|
}
|
|
@@ -378,7 +378,7 @@ const KupAutocomplete = class {
|
|
|
378
378
|
* Sets the focus to the component.
|
|
379
379
|
*/
|
|
380
380
|
async setFocus() {
|
|
381
|
-
__classPrivateFieldGet$
|
|
381
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
382
382
|
}
|
|
383
383
|
/**
|
|
384
384
|
* Sets the props to the component.
|
|
@@ -393,14 +393,14 @@ const KupAutocomplete = class {
|
|
|
393
393
|
*/
|
|
394
394
|
async setValue(value) {
|
|
395
395
|
__classPrivateFieldSet$4(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
396
|
-
__classPrivateFieldGet$
|
|
396
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, value, true);
|
|
397
397
|
}
|
|
398
398
|
/*-------------------------------------------------*/
|
|
399
399
|
/* L i f e c y c l e H o o k s */
|
|
400
400
|
/*-------------------------------------------------*/
|
|
401
401
|
componentWillLoad() {
|
|
402
|
-
__classPrivateFieldGet$
|
|
403
|
-
__classPrivateFieldGet$
|
|
402
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").debug.logLoad(this, false);
|
|
403
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").theme.register(this);
|
|
404
404
|
__classPrivateFieldSet$4(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
405
405
|
this.value = this.initialValue;
|
|
406
406
|
if (!this.data) {
|
|
@@ -411,11 +411,11 @@ const KupAutocomplete = class {
|
|
|
411
411
|
}
|
|
412
412
|
}
|
|
413
413
|
componentDidLoad() {
|
|
414
|
-
__classPrivateFieldGet$
|
|
415
|
-
__classPrivateFieldGet$
|
|
414
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, this.value, true);
|
|
415
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").debug.logLoad(this, true);
|
|
416
416
|
}
|
|
417
417
|
componentWillRender() {
|
|
418
|
-
__classPrivateFieldGet$
|
|
418
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").debug.logRender(this, false);
|
|
419
419
|
}
|
|
420
420
|
componentDidRender() {
|
|
421
421
|
const root = this.rootElement.shadowRoot;
|
|
@@ -427,81 +427,81 @@ const KupAutocomplete = class {
|
|
|
427
427
|
FTextFieldMDC(f);
|
|
428
428
|
}
|
|
429
429
|
}
|
|
430
|
-
__classPrivateFieldGet$
|
|
430
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").debug.logRender(this, true);
|
|
431
431
|
}
|
|
432
432
|
render() {
|
|
433
433
|
const fullHeight = this.rootElement.classList.contains('kup-full-height');
|
|
434
434
|
const fullWidth = this.rootElement.classList.contains('kup-full-width');
|
|
435
|
-
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: __classPrivateFieldGet$
|
|
435
|
+
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: __classPrivateFieldGet$7(this, _KupAutocomplete_elStyle, "f") }, h("style", null, __classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { id: componentWrapperId, style: __classPrivateFieldGet$7(this, _KupAutocomplete_elStyle, "f") }, h(FTextField, Object.assign({ icon: this.showDropDownIcon
|
|
436
436
|
? KupThemeIconValues.DROPDOWN
|
|
437
437
|
: null, trailingIcon: true }, this.data['kup-text-field'], { disabled: this.disabled, fullHeight: fullHeight, fullWidth: fullWidth, value: this.displayedValue, onBlur: () => this.onKupBlur(), onClick: () => this.onKupClick(), onChange: (e) => this.onKupChange(e.target.value), onFocus: () => this.onKupFocus(), onInput: () => {
|
|
438
|
-
window.clearTimeout(__classPrivateFieldGet$
|
|
438
|
+
window.clearTimeout(__classPrivateFieldGet$7(this, _KupAutocomplete_inputTimeout, "f"));
|
|
439
439
|
__classPrivateFieldSet$4(this, _KupAutocomplete_inputTimeout, window.setTimeout(() => this.onKupInput(), this.inputDelay), "f");
|
|
440
|
-
}, onIconClick: () => this.onKupIconClick() }))), __classPrivateFieldGet$
|
|
440
|
+
}, onIconClick: () => this.onKupIconClick() }))), __classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_prepList).call(this)));
|
|
441
441
|
}
|
|
442
442
|
disconnectedCallback() {
|
|
443
|
-
if (__classPrivateFieldGet$
|
|
444
|
-
__classPrivateFieldGet$
|
|
445
|
-
__classPrivateFieldGet$
|
|
443
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f")) {
|
|
444
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.unregister([__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f")]);
|
|
445
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").remove();
|
|
446
446
|
}
|
|
447
|
-
__classPrivateFieldGet$
|
|
447
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").theme.unregister(this);
|
|
448
448
|
}
|
|
449
449
|
get rootElement() { return getElement$1(this); }
|
|
450
450
|
};
|
|
451
451
|
_KupAutocomplete_doConsistencyCheck = new WeakMap(), _KupAutocomplete_elStyle = new WeakMap(), _KupAutocomplete_listEl = new WeakMap(), _KupAutocomplete_kupManager = new WeakMap(), _KupAutocomplete_textfieldWrapper = new WeakMap(), _KupAutocomplete_textfieldEl = new WeakMap(), _KupAutocomplete_clickCb = new WeakMap(), _KupAutocomplete_inputTimeout = new WeakMap(), _KupAutocomplete_instances = new WeakSet(), _KupAutocomplete_openList = function _KupAutocomplete_openList(forceOpen) {
|
|
452
452
|
if (forceOpen != true &&
|
|
453
|
-
__classPrivateFieldGet$
|
|
454
|
-
__classPrivateFieldGet$
|
|
453
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldEl, "f").value.length < this.minimumChars) {
|
|
454
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
455
455
|
return false;
|
|
456
456
|
}
|
|
457
|
-
__classPrivateFieldGet$
|
|
458
|
-
__classPrivateFieldGet$
|
|
459
|
-
const elStyle = __classPrivateFieldGet$
|
|
457
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f").classList.add('toggled');
|
|
458
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").menuVisible = true;
|
|
459
|
+
const elStyle = __classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").style;
|
|
460
460
|
elStyle.height = 'auto';
|
|
461
|
-
elStyle.minWidth = __classPrivateFieldGet$
|
|
462
|
-
if (__classPrivateFieldGet$
|
|
463
|
-
__classPrivateFieldGet$
|
|
461
|
+
elStyle.minWidth = __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f").clientWidth + 'px';
|
|
462
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.isRegistered(__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"))) {
|
|
463
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.changeAnchor(__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"), __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f"));
|
|
464
464
|
}
|
|
465
465
|
else {
|
|
466
|
-
__classPrivateFieldGet$
|
|
466
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"), __classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f"), 0, KupDynamicPositionPlacement.AUTO, true);
|
|
467
467
|
}
|
|
468
|
-
__classPrivateFieldGet$
|
|
469
|
-
if (!__classPrivateFieldGet$
|
|
468
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"));
|
|
469
|
+
if (!__classPrivateFieldGet$7(this, _KupAutocomplete_clickCb, "f")) {
|
|
470
470
|
__classPrivateFieldSet$4(this, _KupAutocomplete_clickCb, {
|
|
471
471
|
cb: () => {
|
|
472
|
-
__classPrivateFieldGet$
|
|
472
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
473
473
|
},
|
|
474
|
-
el: __classPrivateFieldGet$
|
|
474
|
+
el: __classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"),
|
|
475
475
|
}, "f");
|
|
476
476
|
}
|
|
477
|
-
__classPrivateFieldGet$
|
|
477
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").addClickCallback(__classPrivateFieldGet$7(this, _KupAutocomplete_clickCb, "f"), true);
|
|
478
478
|
return true;
|
|
479
479
|
}, _KupAutocomplete_closeList = function _KupAutocomplete_closeList() {
|
|
480
|
-
__classPrivateFieldGet$
|
|
481
|
-
__classPrivateFieldGet$
|
|
482
|
-
__classPrivateFieldGet$
|
|
483
|
-
__classPrivateFieldGet$
|
|
480
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_textfieldWrapper, "f").classList.remove('toggled');
|
|
481
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").menuVisible = false;
|
|
482
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").dynamicPosition.stop(__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"));
|
|
483
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_kupManager, "f").removeClickCallback(__classPrivateFieldGet$7(this, _KupAutocomplete_clickCb, "f"));
|
|
484
484
|
}, _KupAutocomplete_isListOpened = function _KupAutocomplete_isListOpened() {
|
|
485
|
-
return __classPrivateFieldGet$
|
|
485
|
+
return __classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").menuVisible == true;
|
|
486
486
|
}, _KupAutocomplete_consistencyCheck = function _KupAutocomplete_consistencyCheck(idIn, setValue) {
|
|
487
|
-
if (!__classPrivateFieldGet$
|
|
487
|
+
if (!__classPrivateFieldGet$7(this, _KupAutocomplete_doConsistencyCheck, "f")) {
|
|
488
488
|
return;
|
|
489
489
|
}
|
|
490
490
|
__classPrivateFieldSet$4(this, _KupAutocomplete_doConsistencyCheck, false, "f");
|
|
491
|
-
const ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet$
|
|
491
|
+
const ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f"), this.selectMode, this.displayMode);
|
|
492
492
|
if (ret.exists || this.allowInconsistentValues) {
|
|
493
493
|
if (setValue) {
|
|
494
494
|
this.value = ret.value;
|
|
495
495
|
this.displayedValue = ret.displayedValue;
|
|
496
496
|
}
|
|
497
|
-
if (__classPrivateFieldGet$
|
|
498
|
-
__classPrivateFieldGet$
|
|
497
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f") != null && !this.serverHandledFilter) {
|
|
498
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").filter = ret.value;
|
|
499
499
|
}
|
|
500
500
|
}
|
|
501
501
|
else {
|
|
502
502
|
this.displayedValue = idIn;
|
|
503
|
-
if (__classPrivateFieldGet$
|
|
504
|
-
__classPrivateFieldGet$
|
|
503
|
+
if (__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f") != null && !this.serverHandledFilter) {
|
|
504
|
+
__classPrivateFieldGet$7(this, _KupAutocomplete_listEl, "f").filter = ret.value;
|
|
505
505
|
}
|
|
506
506
|
}
|
|
507
507
|
return ret;
|
|
@@ -6447,7 +6447,7 @@ var KupChipProps;
|
|
|
6447
6447
|
|
|
6448
6448
|
const kupChipCss = ":host{display:block}";
|
|
6449
6449
|
|
|
6450
|
-
var __classPrivateFieldGet$
|
|
6450
|
+
var __classPrivateFieldGet$6 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
6451
6451
|
if (kind === "a" && !f)
|
|
6452
6452
|
throw new TypeError("Private accessor was defined without a getter");
|
|
6453
6453
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -6516,7 +6516,7 @@ const KupChip = class {
|
|
|
6516
6516
|
this.kupChange.emit({
|
|
6517
6517
|
comp: this,
|
|
6518
6518
|
id: this.rootElement.id,
|
|
6519
|
-
stringifiedValues: __classPrivateFieldGet$
|
|
6519
|
+
stringifiedValues: __classPrivateFieldGet$6(this, _KupChip_instances, "m", _KupChip_stringifiedValues).call(this),
|
|
6520
6520
|
});
|
|
6521
6521
|
this.refresh();
|
|
6522
6522
|
}
|
|
@@ -6633,11 +6633,11 @@ const KupChip = class {
|
|
|
6633
6633
|
props.onIconClick.push((chip) => this.onKupIconClick(chip));
|
|
6634
6634
|
}
|
|
6635
6635
|
return (h(Host, { "onKup-autocomplete-itemclick": (e) => {
|
|
6636
|
-
__classPrivateFieldGet$
|
|
6636
|
+
__classPrivateFieldGet$6(this, _KupChip_instances, "m", _KupChip_changeHandler).call(this, e);
|
|
6637
6637
|
}, "onKup-combobox-itemclick": (e) => {
|
|
6638
|
-
__classPrivateFieldGet$
|
|
6638
|
+
__classPrivateFieldGet$6(this, _KupChip_instances, "m", _KupChip_changeHandler).call(this, e);
|
|
6639
6639
|
}, "onKup-textfield-change": (e) => {
|
|
6640
|
-
__classPrivateFieldGet$
|
|
6640
|
+
__classPrivateFieldGet$6(this, _KupChip_instances, "m", _KupChip_changeHandler).call(this, e);
|
|
6641
6641
|
} }, h("style", null, this.kupManager.theme.setKupStyle(this.rootElement)), h("div", { id: componentWrapperId }, ((_a = this.data) === null || _a === void 0 ? void 0 : _a.length) > 0 ? h(FChip, Object.assign({}, props)) : null, h("slot", { name: "field" }))));
|
|
6642
6642
|
}
|
|
6643
6643
|
disconnectedCallback() {
|
|
@@ -6675,7 +6675,7 @@ _KupChip_instances = new WeakSet(), _KupChip_changeHandler =
|
|
|
6675
6675
|
this.kupChange.emit({
|
|
6676
6676
|
comp: this,
|
|
6677
6677
|
id: this.rootElement.id,
|
|
6678
|
-
stringifiedValues: __classPrivateFieldGet$
|
|
6678
|
+
stringifiedValues: __classPrivateFieldGet$6(this, _KupChip_instances, "m", _KupChip_stringifiedValues).call(this),
|
|
6679
6679
|
});
|
|
6680
6680
|
}
|
|
6681
6681
|
}
|
|
@@ -6964,7 +6964,7 @@ var KupComboboxProps;
|
|
|
6964
6964
|
|
|
6965
6965
|
const kupComboboxCss = ":host{display:block;font-size:var(--kup-font-size);width:max-content}:host([is-select]) #kup-component{transition:background-color 0.2s}:host([is-select]) #kup-component:hover{background-color:rgba(var(--kup-text-color-rgb), 0.1)}:host([is-select]) .mdc-text-field:not(.mdc-text-field--disabled) input{cursor:pointer}.kup-icon{transition:transform 0.15s}.toggled .kup-icon.kup-dropdown-icon{transform:rotate(-180deg)}.kup-icon.kup-dropdown-icon{-webkit-mask:var(--kup-dropdown-icon);mask:var(--kup-dropdown-icon)}.f-text-field{position:relative}:host(.kup-full-height){height:100%}:host(.kup-full-height) #kup-component,:host(.kup-full-height) .f-text-field,:host(.kup-full-height) .mdc-text-field{height:100%}:host(.kup-full-width){width:100%}:host(.kup-full-width) #kup-component{width:100%}:host(.kup-danger){--kup-textfield-primary-color:var(--kup-danger-color);--kup-textfield-primary-color-rgb:var(--kup-danger-color-rgb)}:host(.kup-info){--kup-textfield-primary-color:var(--kup-info-color);--kup-textfield-primary-color-rgb:var(--kup-info-color-rgb)}:host(.kup-secondary){--kup-textfield-primary-color:var(--kup-secondary-color);--kup-textfield-primary-color-rgb:var(--kup-secondary-color-rgb)}:host(.kup-success){--kup-textfield-primary-color:var(--kup-success-color);--kup-textfield-primary-color-rgb:var(--kup-success-color-rgb)}:host(.kup-warning){--kup-textfield-primary-color:var(--kup-warning-color);--kup-textfield-primary-color-rgb:var(--kup-warning-color-rgb)}";
|
|
6966
6966
|
|
|
6967
|
-
var __classPrivateFieldGet$
|
|
6967
|
+
var __classPrivateFieldGet$5 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
6968
6968
|
if (kind === "a" && !f)
|
|
6969
6969
|
throw new TypeError("Private accessor was defined without a getter");
|
|
6970
6970
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -7020,33 +7020,33 @@ const KupCombobox = class {
|
|
|
7020
7020
|
comp: this,
|
|
7021
7021
|
id: this.rootElement.id,
|
|
7022
7022
|
value: this.value,
|
|
7023
|
-
inputValue: __classPrivateFieldGet$
|
|
7023
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7024
7024
|
});
|
|
7025
7025
|
}
|
|
7026
7026
|
onKupChange(value) {
|
|
7027
|
-
let ret = __classPrivateFieldGet$
|
|
7027
|
+
let ret = __classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, value, true);
|
|
7028
7028
|
this.kupChange.emit({
|
|
7029
7029
|
comp: this,
|
|
7030
7030
|
id: this.rootElement.id,
|
|
7031
7031
|
value: this.value,
|
|
7032
|
-
inputValue: __classPrivateFieldGet$
|
|
7032
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7033
7033
|
node: ret.node,
|
|
7034
7034
|
});
|
|
7035
7035
|
}
|
|
7036
7036
|
onKupClick() {
|
|
7037
7037
|
if (this.isSelect == true) {
|
|
7038
|
-
if (__classPrivateFieldGet$
|
|
7039
|
-
__classPrivateFieldGet$
|
|
7038
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").classList.contains('toggled')) {
|
|
7039
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7040
7040
|
}
|
|
7041
7041
|
else {
|
|
7042
|
-
__classPrivateFieldGet$
|
|
7042
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
7043
7043
|
}
|
|
7044
7044
|
}
|
|
7045
7045
|
this.kupClick.emit({
|
|
7046
7046
|
comp: this,
|
|
7047
7047
|
id: this.rootElement.id,
|
|
7048
7048
|
value: this.value,
|
|
7049
|
-
inputValue: __classPrivateFieldGet$
|
|
7049
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7050
7050
|
});
|
|
7051
7051
|
}
|
|
7052
7052
|
onKupFocus() {
|
|
@@ -7054,47 +7054,47 @@ const KupCombobox = class {
|
|
|
7054
7054
|
comp: this,
|
|
7055
7055
|
id: this.rootElement.id,
|
|
7056
7056
|
value: this.value,
|
|
7057
|
-
inputValue: __classPrivateFieldGet$
|
|
7057
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7058
7058
|
});
|
|
7059
7059
|
}
|
|
7060
7060
|
onKupInput() {
|
|
7061
|
-
let ret = __classPrivateFieldGet$
|
|
7062
|
-
__classPrivateFieldGet$
|
|
7061
|
+
let ret = __classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value, false);
|
|
7062
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
7063
7063
|
this.kupInput.emit({
|
|
7064
7064
|
comp: this,
|
|
7065
7065
|
id: this.rootElement.id,
|
|
7066
7066
|
value: this.value,
|
|
7067
|
-
inputValue: __classPrivateFieldGet$
|
|
7067
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7068
7068
|
node: ret.node,
|
|
7069
7069
|
});
|
|
7070
7070
|
}
|
|
7071
7071
|
onKupIconClick() {
|
|
7072
|
-
if (__classPrivateFieldGet$
|
|
7073
|
-
__classPrivateFieldGet$
|
|
7072
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").classList.contains('toggled')) {
|
|
7073
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7074
7074
|
}
|
|
7075
7075
|
else {
|
|
7076
|
-
__classPrivateFieldGet$
|
|
7076
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
7077
7077
|
}
|
|
7078
7078
|
this.kupIconClick.emit({
|
|
7079
7079
|
comp: this,
|
|
7080
7080
|
id: this.rootElement.id,
|
|
7081
7081
|
value: this.value,
|
|
7082
|
-
inputValue: __classPrivateFieldGet$
|
|
7083
|
-
open: __classPrivateFieldGet$
|
|
7082
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7083
|
+
open: __classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").classList.contains('toggled'),
|
|
7084
7084
|
});
|
|
7085
7085
|
}
|
|
7086
7086
|
onKupItemClick(e) {
|
|
7087
7087
|
this.onKupChange(e.detail.selected.id);
|
|
7088
|
-
__classPrivateFieldGet$
|
|
7089
|
-
if (__classPrivateFieldGet$
|
|
7090
|
-
__classPrivateFieldGet$
|
|
7088
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7089
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f")) {
|
|
7090
|
+
__classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").focus();
|
|
7091
7091
|
}
|
|
7092
7092
|
this.kupItemClick.emit({
|
|
7093
7093
|
comp: this,
|
|
7094
7094
|
id: this.rootElement.id,
|
|
7095
7095
|
node: e.detail.selected,
|
|
7096
7096
|
value: this.value,
|
|
7097
|
-
inputValue: __classPrivateFieldGet$
|
|
7097
|
+
inputValue: __classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").value,
|
|
7098
7098
|
});
|
|
7099
7099
|
}
|
|
7100
7100
|
/*-------------------------------------------------*/
|
|
@@ -7107,30 +7107,30 @@ const KupCombobox = class {
|
|
|
7107
7107
|
/* L i s t e n e r s */
|
|
7108
7108
|
/*-------------------------------------------------*/
|
|
7109
7109
|
listenKeydown(e) {
|
|
7110
|
-
if (__classPrivateFieldGet$
|
|
7110
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_isListOpened).call(this)) {
|
|
7111
7111
|
switch (e.key) {
|
|
7112
7112
|
case 'ArrowDown':
|
|
7113
7113
|
e.preventDefault();
|
|
7114
7114
|
e.stopPropagation();
|
|
7115
|
-
__classPrivateFieldGet$
|
|
7115
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").focusNext();
|
|
7116
7116
|
break;
|
|
7117
7117
|
case 'ArrowUp':
|
|
7118
7118
|
e.preventDefault();
|
|
7119
7119
|
e.stopPropagation();
|
|
7120
|
-
__classPrivateFieldGet$
|
|
7120
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").focusPrevious();
|
|
7121
7121
|
break;
|
|
7122
7122
|
case 'Enter':
|
|
7123
7123
|
e.preventDefault();
|
|
7124
7124
|
e.stopPropagation();
|
|
7125
|
-
__classPrivateFieldGet$
|
|
7126
|
-
__classPrivateFieldGet$
|
|
7127
|
-
__classPrivateFieldGet$
|
|
7125
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").select().then(() => {
|
|
7126
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7127
|
+
__classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").focus();
|
|
7128
7128
|
});
|
|
7129
7129
|
break;
|
|
7130
7130
|
case 'Escape':
|
|
7131
7131
|
e.preventDefault();
|
|
7132
7132
|
e.stopPropagation();
|
|
7133
|
-
__classPrivateFieldGet$
|
|
7133
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7134
7134
|
break;
|
|
7135
7135
|
}
|
|
7136
7136
|
}
|
|
@@ -7139,14 +7139,14 @@ const KupCombobox = class {
|
|
|
7139
7139
|
case 'ArrowDown':
|
|
7140
7140
|
e.preventDefault();
|
|
7141
7141
|
e.stopPropagation();
|
|
7142
|
-
__classPrivateFieldGet$
|
|
7143
|
-
__classPrivateFieldGet$
|
|
7142
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
7143
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").focusNext();
|
|
7144
7144
|
break;
|
|
7145
7145
|
case 'ArrowUp':
|
|
7146
7146
|
e.preventDefault();
|
|
7147
7147
|
e.stopPropagation();
|
|
7148
|
-
__classPrivateFieldGet$
|
|
7149
|
-
__classPrivateFieldGet$
|
|
7148
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
7149
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").focusPrevious();
|
|
7150
7150
|
break;
|
|
7151
7151
|
}
|
|
7152
7152
|
}
|
|
@@ -7179,7 +7179,7 @@ const KupCombobox = class {
|
|
|
7179
7179
|
* Sets the focus to the component.
|
|
7180
7180
|
*/
|
|
7181
7181
|
async setFocus() {
|
|
7182
|
-
__classPrivateFieldGet$
|
|
7182
|
+
__classPrivateFieldGet$5(this, _KupCombobox_textfieldEl, "f").focus();
|
|
7183
7183
|
}
|
|
7184
7184
|
/**
|
|
7185
7185
|
* Sets the props to the component.
|
|
@@ -7193,14 +7193,14 @@ const KupCombobox = class {
|
|
|
7193
7193
|
* @param {string} value - Value to be set.
|
|
7194
7194
|
*/
|
|
7195
7195
|
async setValue(value) {
|
|
7196
|
-
__classPrivateFieldGet$
|
|
7196
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, value, true);
|
|
7197
7197
|
}
|
|
7198
7198
|
/*-------------------------------------------------*/
|
|
7199
7199
|
/* L i f e c y c l e H o o k s */
|
|
7200
7200
|
/*-------------------------------------------------*/
|
|
7201
7201
|
componentWillLoad() {
|
|
7202
|
-
__classPrivateFieldGet$
|
|
7203
|
-
__classPrivateFieldGet$
|
|
7202
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").debug.logLoad(this, false);
|
|
7203
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").theme.register(this);
|
|
7204
7204
|
this.value = this.initialValue;
|
|
7205
7205
|
if (!this.data) {
|
|
7206
7206
|
this.data = {
|
|
@@ -7210,11 +7210,11 @@ const KupCombobox = class {
|
|
|
7210
7210
|
}
|
|
7211
7211
|
}
|
|
7212
7212
|
componentDidLoad() {
|
|
7213
|
-
__classPrivateFieldGet$
|
|
7214
|
-
__classPrivateFieldGet$
|
|
7213
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, this.value, true);
|
|
7214
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").debug.logLoad(this, true);
|
|
7215
7215
|
}
|
|
7216
7216
|
componentWillRender() {
|
|
7217
|
-
__classPrivateFieldGet$
|
|
7217
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").debug.logRender(this, false);
|
|
7218
7218
|
}
|
|
7219
7219
|
componentDidRender() {
|
|
7220
7220
|
const root = this.rootElement.shadowRoot;
|
|
@@ -7226,21 +7226,21 @@ const KupCombobox = class {
|
|
|
7226
7226
|
FTextFieldMDC(f);
|
|
7227
7227
|
}
|
|
7228
7228
|
}
|
|
7229
|
-
__classPrivateFieldGet$
|
|
7229
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").debug.logRender(this, true);
|
|
7230
7230
|
}
|
|
7231
7231
|
render() {
|
|
7232
7232
|
const fullHeight = this.rootElement.classList.contains('kup-full-height');
|
|
7233
7233
|
const fullWidth = this.rootElement.classList.contains('kup-full-width');
|
|
7234
|
-
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: __classPrivateFieldGet$
|
|
7234
|
+
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: __classPrivateFieldGet$5(this, _KupCombobox_elStyle, "f") }, h("style", null, __classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { id: componentWrapperId, style: __classPrivateFieldGet$5(this, _KupCombobox_elStyle, "f") }, h(FTextField, Object.assign({}, this.data['kup-text-field'], { disabled: this.disabled, fullHeight: fullHeight, fullWidth: fullWidth, icon: this.showDropDownIcon
|
|
7235
7235
|
? KupThemeIconValues.DROPDOWN
|
|
7236
|
-
: null, readOnly: this.isSelect, trailingIcon: true, value: this.displayedValue, onBlur: () => this.onKupBlur(), onClick: () => this.onKupClick(), onChange: (e) => this.onKupChange(e.target.value), onFocus: () => this.onKupFocus(), onInput: () => this.onKupInput(), onIconClick: () => this.onKupIconClick() }))), __classPrivateFieldGet$
|
|
7236
|
+
: null, readOnly: this.isSelect, trailingIcon: true, value: this.displayedValue, onBlur: () => this.onKupBlur(), onClick: () => this.onKupClick(), onChange: (e) => this.onKupChange(e.target.value), onFocus: () => this.onKupFocus(), onInput: () => this.onKupInput(), onIconClick: () => this.onKupIconClick() }))), __classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_prepList).call(this)));
|
|
7237
7237
|
}
|
|
7238
7238
|
disconnectedCallback() {
|
|
7239
|
-
if (__classPrivateFieldGet$
|
|
7240
|
-
__classPrivateFieldGet$
|
|
7241
|
-
__classPrivateFieldGet$
|
|
7239
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f")) {
|
|
7240
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.unregister([__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f")]);
|
|
7241
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").remove();
|
|
7242
7242
|
}
|
|
7243
|
-
__classPrivateFieldGet$
|
|
7243
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").theme.unregister(this);
|
|
7244
7244
|
}
|
|
7245
7245
|
get rootElement() { return getElement$1(this); }
|
|
7246
7246
|
static get watchers() { return {
|
|
@@ -7248,54 +7248,54 @@ const KupCombobox = class {
|
|
|
7248
7248
|
}; }
|
|
7249
7249
|
};
|
|
7250
7250
|
_KupCombobox_kupManager = new WeakMap(), _KupCombobox_elStyle = new WeakMap(), _KupCombobox_listEl = new WeakMap(), _KupCombobox_textfieldWrapper = new WeakMap(), _KupCombobox_textfieldEl = new WeakMap(), _KupCombobox_clickCb = new WeakMap(), _KupCombobox_instances = new WeakSet(), _KupCombobox_openList = function _KupCombobox_openList() {
|
|
7251
|
-
if (__classPrivateFieldGet$
|
|
7251
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_isListOpened).call(this)) {
|
|
7252
7252
|
return;
|
|
7253
7253
|
}
|
|
7254
|
-
__classPrivateFieldGet$
|
|
7255
|
-
__classPrivateFieldGet$
|
|
7256
|
-
__classPrivateFieldGet$
|
|
7257
|
-
const elStyle = __classPrivateFieldGet$
|
|
7254
|
+
__classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").classList.add('toggled');
|
|
7255
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").menuVisible = true;
|
|
7256
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").filter = '';
|
|
7257
|
+
const elStyle = __classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").style;
|
|
7258
7258
|
elStyle.height = 'auto';
|
|
7259
|
-
elStyle.minWidth = __classPrivateFieldGet$
|
|
7260
|
-
if (__classPrivateFieldGet$
|
|
7261
|
-
__classPrivateFieldGet$
|
|
7259
|
+
elStyle.minWidth = __classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").clientWidth + 'px';
|
|
7260
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.isRegistered(__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"))) {
|
|
7261
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.changeAnchor(__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"), __classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f"));
|
|
7262
7262
|
}
|
|
7263
7263
|
else {
|
|
7264
|
-
__classPrivateFieldGet$
|
|
7264
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"), __classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f"), 0, KupDynamicPositionPlacement.AUTO, true);
|
|
7265
7265
|
}
|
|
7266
|
-
__classPrivateFieldGet$
|
|
7267
|
-
if (!__classPrivateFieldGet$
|
|
7266
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"));
|
|
7267
|
+
if (!__classPrivateFieldGet$5(this, _KupCombobox_clickCb, "f")) {
|
|
7268
7268
|
__classPrivateFieldSet$3(this, _KupCombobox_clickCb, {
|
|
7269
7269
|
cb: () => {
|
|
7270
|
-
__classPrivateFieldGet$
|
|
7270
|
+
__classPrivateFieldGet$5(this, _KupCombobox_instances, "m", _KupCombobox_closeList).call(this);
|
|
7271
7271
|
},
|
|
7272
|
-
el: __classPrivateFieldGet$
|
|
7272
|
+
el: __classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"),
|
|
7273
7273
|
}, "f");
|
|
7274
7274
|
}
|
|
7275
|
-
__classPrivateFieldGet$
|
|
7275
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").addClickCallback(__classPrivateFieldGet$5(this, _KupCombobox_clickCb, "f"), true);
|
|
7276
7276
|
}, _KupCombobox_closeList = function _KupCombobox_closeList() {
|
|
7277
|
-
__classPrivateFieldGet$
|
|
7278
|
-
__classPrivateFieldGet$
|
|
7279
|
-
__classPrivateFieldGet$
|
|
7280
|
-
__classPrivateFieldGet$
|
|
7277
|
+
__classPrivateFieldGet$5(this, _KupCombobox_textfieldWrapper, "f").classList.remove('toggled');
|
|
7278
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").menuVisible = false;
|
|
7279
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").dynamicPosition.stop(__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"));
|
|
7280
|
+
__classPrivateFieldGet$5(this, _KupCombobox_kupManager, "f").removeClickCallback(__classPrivateFieldGet$5(this, _KupCombobox_clickCb, "f"));
|
|
7281
7281
|
}, _KupCombobox_isListOpened = function _KupCombobox_isListOpened() {
|
|
7282
|
-
return __classPrivateFieldGet$
|
|
7282
|
+
return __classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").menuVisible == true;
|
|
7283
7283
|
}, _KupCombobox_consistencyCheck = function _KupCombobox_consistencyCheck(idIn, setValue) {
|
|
7284
|
-
let ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet$
|
|
7284
|
+
let ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet$5(this, _KupCombobox_listEl, "f"), this.selectMode, this.displayMode);
|
|
7285
7285
|
if (ret.exists) {
|
|
7286
7286
|
if (setValue) {
|
|
7287
7287
|
this.value = ret.value;
|
|
7288
7288
|
this.displayedValue = ret.displayedValue;
|
|
7289
7289
|
}
|
|
7290
|
-
if (__classPrivateFieldGet$
|
|
7291
|
-
__classPrivateFieldGet$
|
|
7290
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f") != null) {
|
|
7291
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").filter = ret.value;
|
|
7292
7292
|
}
|
|
7293
7293
|
}
|
|
7294
7294
|
else {
|
|
7295
7295
|
this.value = idIn;
|
|
7296
7296
|
this.displayedValue = idIn;
|
|
7297
|
-
if (__classPrivateFieldGet$
|
|
7298
|
-
__classPrivateFieldGet$
|
|
7297
|
+
if (__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f") != null) {
|
|
7298
|
+
__classPrivateFieldGet$5(this, _KupCombobox_listEl, "f").filter = ret.value;
|
|
7299
7299
|
}
|
|
7300
7300
|
}
|
|
7301
7301
|
return ret;
|
|
@@ -7310,8 +7310,8 @@ class KupDataTableState {
|
|
|
7310
7310
|
this.expandGroups = false;
|
|
7311
7311
|
this.groupLabelDisplay = GroupLabelDisplayMode.BOTH;
|
|
7312
7312
|
this.density = 'small';
|
|
7313
|
-
this.enableSortableColumns = false;
|
|
7314
7313
|
this.enableExtraColumns = true;
|
|
7314
|
+
this.enableSortableColumns = false;
|
|
7315
7315
|
this.forceOneLine = false;
|
|
7316
7316
|
this.globalFilter = false;
|
|
7317
7317
|
this.globalFilterValue = '';
|
|
@@ -8081,7 +8081,7 @@ class KupColumnMenu {
|
|
|
8081
8081
|
|
|
8082
8082
|
const kupDataTableCss = ":host{--kup_datatable_background_color:var(\n --kup-datatable-background-color,\n var(--kup-background-color)\n );--kup_datatable_border:var(\n --kup-datatable-border,\n 1px solid var(--kup-border-color)\n );--kup_datatable_color:var(--kup-datatable-color, var(--kup-text-color));--kup_datatable_font_family:var(\n --kup-datatable-font-family,\n var(--kup-font-family)\n );--kup_datatable_font_family_monospace:var(\n --kup-datatable-font-family-monospace,\n var(--kup-font-family-monospace)\n );--kup_datatable_font_size:var(\n --kup-datatable-font-size,\n var(--kup-font-size)\n );--kup_datatable_th_border:var(\n --kup-datatable-th-border,\n 1px solid var(--kup-border-color)\n );--kup_datatable_th_resize_handle_width:var(\n --kup-datatable-th-resize-handle-width,\n 3px\n );display:block;font-family:var(--kup_datatable_font_family);font-size:var(--kup_datatable_font_size);position:relative}:host([kup-toolbar]) .settings-trigger{height:12px}:host([kup-toolbar]) .customize-panel{visibility:visible}:host([force-one-line]) .f-cell__text{white-space:nowrap}table{background-color:var(--kup_datatable_background_color);border-spacing:0;border-collapse:separate;color:var(--kup_datatable_color);min-width:intrinsic;min-width:-moz-max-content;min-width:-webkit-max-content;text-align:left;width:100%}table.auto-width{min-width:auto;width:0}table>tbody>tr.focus td:first-of-type,table>tbody>tr[kup-drag-over] td:first-of-type{box-shadow:inset 4px 0px 0px 0px var(--kup-secondary-color)}table>tbody>tr>td:first-of-type,table>tbody>tr>td.placeholder~td:not(.placeholder){border-left:var(--kup_datatable_border)}table>tbody>tr>td:last-of-type{border-right:var(--kup_datatable_border)}table>tbody>tr:last-of-type>td{border-bottom:var(--kup_datatable_border)}table.border-top>tbody>tr:first-of-type>td{border-top:var(--kup_datatable_border)}table.row-separation>tbody>tr>td{border-bottom:var(--kup_datatable_border)}table.column-separation>tbody>tr>td{border-right:var(--kup_datatable_border)}table.noGrid,table.noGrid td{border:none}table tfoot td{border-bottom:var(--kup_datatable_border);border-right:var(--kup_datatable_border);box-sizing:border-box;height:36px;text-align:right;font-weight:bold;padding:0.5em 0.3125em}table tfoot td:hover{background-color:var(--kup_datatable_background_color)}table tfoot td:first-of-type{border-left:var(--kup_datatable_border)}#global-filter{margin:0.5em 0px;min-width:140px;width:100%}.kup-icon:not(.f-image){background-color:var(--kup-title-color);margin:0 0.25em;height:1.25em;width:1.25em}.kup-icon:not(.f-image).kup-ascending-icon,.kup-icon:not(.f-image).kup-descending-icon,.kup-icon:not(.f-image).kup-key-icon,.kup-icon:not(.f-image).kup-filter-remove-icon{height:auto}.kup-icon:not(.f-image).kup-collapsed-icon,.kup-icon:not(.f-image).kup-expanded-icon{float:left}.kup-icon:not(.f-image).kup-filter-remove-icon,.kup-icon:not(.f-image).kup-key-icon{margin:0 0.25em}.below-wrapper{backface-visibility:hidden;height:auto;overflow:auto}.below-wrapper.custom-size{overflow:unset}.below-wrapper:not(.custom-size){overflow-x:auto}.density-dense tbody>tr.group td{padding-top:0.25em;padding-bottom:0.25em}.density-wide tbody>tr.group>td{padding-top:0.75em;padding-bottom:0.75em}.fontsize-small{font-size:calc(var(--kup_datatable_font_size) * 0.75);transition:font-size 0.1s}.fontsize-small .group-cell-content>span:before{font-size:calc(var(--kup_datatable_font_size) * 1) !important}.fontsize-big{font-size:calc(var(--kup_datatable_font_size) * 1.25);transition:font-size 0.1s}.fontsize-big .group-cell-content>span:before{font-size:calc(var(--kup_datatable_font_size) * 1.5) !important}th{background-color:var(--kup-title-background-color);border:var(--kup_datatable_th_border);border-left:0 none;border-bottom-width:2px;box-sizing:border-box;top:0;touch-action:none;transition:background-color 0.25s ease;user-select:none}th:first-of-type{border-left:var(--kup_datatable_th_border)}.header-cell__content{color:var(--kup-title-color);display:flex;justify-content:space-between;padding:0.5em 0.3125em;text-overflow:ellipsis;white-space:nowrap}.header-cell--centered .header-cell__content{justify-content:center}.header-cell--is-number .header-cell__content{justify-content:flex-end}.header-cell__title{overflow:hidden;text-overflow:ellipsis;user-select:none}.header-cell__icons{display:flex}.header-cell__drag-handler{background:rgba(var(--kup-title-color-rgb), 0.25);height:100%;position:absolute;right:0;top:0;touch-action:none;user-select:none;width:var(--kup_datatable_th_resize_handle_width)}.header-cell__drag-handler:hover{background:rgba(var(--kup-title-color-rgb), 0.5)}.header-cell--sortable{cursor:pointer}.header-cell--is-icon{width:30px}tbody{cursor:auto}tbody td{height:0;padding:0}tbody td>*{border:none !important}tbody tr kup-button{max-width:max-content}tbody tr[kup-draggable]{opacity:0.5}tbody tr.selected td{background-color:rgba(var(--kup-primary-color-rgb), 0.175)}tbody tr:hover:not(.group):not(.selected) td{color:var(--kup-hover-color);background-color:var(--kup-hover-background-color)}tbody tr.group{background:var(--kup-title-background-color);border-top:var(--kup_datatable_border);color:var(--kup-title-color);font-weight:bold;cursor:pointer}tbody tr.group.group-label{border-bottom:none}tbody tr.group.group-total{border-top:none;line-height:0.5em}tbody tr.group>td{padding:0.5em 0}tbody tr.group>td .group-cell-content .indent{float:left;margin-left:0.25em}tbody tr.group>td .group-cell-content>span{display:inline-flex;outline:none;margin-left:0.25em}tbody tr.group>td.total{text-align:right;padding:0.5em 0.3125em}tbody tr.group>td.total.negative-number{color:var(--kup-danger-color)}tbody tr>td{box-sizing:border-box;transition:box-shadow 0.1s}tbody tr>td .row-expander{margin-right:0.5em}tbody tr>td .row-action{margin-right:0.2em}tbody tr [row-select-cell]{min-height:40px}tbody tr td[row-action-cell]{width:calc(3em * var(--kup_datatable_row_actions))}tbody tr td[row-action-cell] .f-image{cursor:pointer;margin-left:0.75em;display:inline-block;opacity:1;transition:0.25s ease-in-out}tbody tr td[row-action-cell] .f-image:hover{opacity:0.5}.above-wrapper{display:flex;width:100%}.kup-icon.overlay-action{display:none;position:absolute;top:0.5em;left:calc(50% - 0.625em)}th:hover .kup-icon.overlay-action{display:block}thead th{position:relative}th.obj:hover span:not(.overlay-action){opacity:0.5}.hidden span{color:transparent;position:relative;text-overflow:ellipsis;transition:color 200ms}.hidden span:hover{color:var(--kup_datatable_color)}.group-wrapper{--kup-chip-margin:0 4px}.totals-value{font-weight:bold}.settings-trigger{cursor:pointer;display:block;width:32px;height:0;border-top-left-radius:25px 30px;border-top-right-radius:25px 30px;background-color:var(--kup-border-color);transition:height 0.25s}.settings-trigger.toggled{background-color:var(--kup-primary-color)}.settings-trigger.toggled .f-image__icon{background:var(--kup-text-on-primary-color) !important}.indent{display:inline-block;height:1em;width:2em}.indent~kup-image,.indent~kup-button{margin:0;vertical-align:middle}.indent~kup-image{display:inline-block}.indent~kup-button,.indent~kup-checkbox{display:inline-block}.actions-wrapper{display:flex}.insert-button,.delete-button,.save-button{padding:1em 0.5em}.kup-icon.kup-ascending-icon{-webkit-mask:var(--kup-ascending-icon);mask:var(--kup-ascending-icon)}.kup-icon.kup-collapsed-icon{-webkit-mask:var(--kup-collapsed-icon);mask:var(--kup-collapsed-icon)}.kup-icon.kup-descending-icon{-webkit-mask:var(--kup-descending-icon);mask:var(--kup-descending-icon)}.kup-icon.kup-expanded-icon{-webkit-mask:var(--kup-expanded-icon);mask:var(--kup-expanded-icon)}.kup-icon.kup-filter-remove-icon{-webkit-mask:var(--kup-filter-remove-icon);mask:var(--kup-filter-remove-icon)}.kup-icon.kup-key-icon{-webkit-mask:var(--kup-key-icon);mask:var(--kup-key-icon)}.paginator-wrapper{display:flex;flex-flow:wrap;min-width:max-content}.paginator-tabs{width:100%}.paginator-tabs kup-paginator{display:inline-flex}.paginator-tabs kup-button{position:relative;height:100%;margin-left:0.25em;float:right}.paginator-tabs .load-more-button{margin:0.5em 0px 0px}sticky-header{display:none}.persistent-header~sticky-header{background:var(--kup-title-background-color);border-bottom:2px solid var(--kup-border-color);box-shadow:0px 0px 7.5px 0px rgba(128, 128, 128, 0.5);color:var(--kup-title-color);display:block;opacity:0;overflow:hidden;pointer-events:none;position:fixed;top:0;transition:opacity 0.25s ease-in-out;z-index:10}.persistent-header~sticky-header.activated{opacity:1;pointer-events:all}.persistent-header~sticky-header[hidden]{display:none}.persistent-header~sticky-header tr-sticky{display:inline-flex}.persistent-header~sticky-header th-sticky{box-sizing:border-box;display:inline-flex;padding:0 0.3125em}.persistent-header~sticky-header th-sticky .header-cell__content{width:100%}.fixed-column,.fixed-row{background-color:var(--kup_datatable_background_color);color:var(--kup-text-color);position:sticky}thead .fixed-column,thead .fixed-row,tfoot .fixed-column,tfoot .fixed-row{z-index:10}table.custom-size th{position:sticky;top:0;z-index:10}table.custom-size th.fixed-column{z-index:11}tr:hover .fixed-row,tr:hover .fixed-column{color:var(--kup-hover-color);background-color:var(--kup-hover-background-color)}tr.selected .fixed-column,tr.selected .fixed-row{background-color:var(--kup_datatable_background_color);background-image:linear-gradient(to right, rgba(var(--kup-primary-color-rgb), 0.175) 0%, rgba(var(--kup-primary-color-rgb), 0.175) 0.1%, rgba(var(--kup-primary-color-rgb), 0.175))}.fixed-row{top:0;z-index:4}.fixed-column{left:0;z-index:6}.fixed-column.fixed-row{z-index:8}thead tr .fixed-column,thead tr:hover:not(.group):not(.selected) .fixed-column{background-color:var(--kup-title-background-color);color:var(--kup-title-color)}tfoot tr:hover:not(.group):not(.selected) .fixed-row,tfoot tr:hover:not(.group):not(.selected) .fixed-column{color:var(--kup-text-color);background-color:var(--kup_datatable_background_color)}:host([drag-enabled]) tr{touch-action:none}th[kup-drag-over]{background-color:rgba(var(--kup-success-color-rgb), 0.25)}th[kup-draggable]{cursor:grabbing !important;opacity:0.5}.droparea{animation:fade-in 0.25s ease-out;background:var(--kup_datatable_background_color);border-radius:8px;box-shadow:var(--kup-box-shadow);display:none;padding:1em 0.5em}.droparea--visible{display:flex}.droparea__groups{border:2px dashed var(--kup-text-color)}.droparea__remove{border:2px dashed var(--kup-danger-color)}.droparea__groups,.droparea__remove{background:var(--kup_datatable_background_color);box-shadow:var(--kup-box-shadow);display:block;height:50px;margin:0 0.5em;opacity:0.5;position:relative;transition:opacity 0.25s;width:50px}.droparea__groups .f-image,.droparea__remove .f-image{width:100%;position:absolute}.droparea__groups .f-image:first-of-type,.droparea__remove .f-image:first-of-type{opacity:1}.droparea__groups .f-image:last-of-type,.droparea__remove .f-image:last-of-type{opacity:0}.droparea__groups[kup-drag-over],.droparea__remove[kup-drag-over]{opacity:1}.droparea__groups[kup-drag-over] .f-image:first-of-type,.droparea__remove[kup-drag-over] .f-image:first-of-type{opacity:0}.droparea__groups[kup-drag-over] .f-image:last-of-type,.droparea__remove[kup-drag-over] .f-image:last-of-type{opacity:1}:host(.kup-cross-selection) #kup-component th.selected{box-shadow:inset 0px 4px 0px 0px var(--kup-secondary-color)}:host(.kup-cross-selection) #kup-component td.selected{background-color:rgba(var(--kup-text-color-rgb), 0.075)}:host(.kup-cross-selection) #kup-component td.selected.fixed-column,:host(.kup-cross-selection) #kup-component td.selected.fixed-row{background-color:var(--kup_datatable_background_color);background-image:linear-gradient(to right, rgba(var(--kup-text-color-rgb), 0.075) 0%, rgba(var(--kup-text-color-rgb), 0.075) 0.1%, rgba(var(--kup-text-color-rgb), 0.075))}:host(.kup-cross-selection) #kup-component tr.selected td{background-color:rgba(var(--kup-text-color-rgb), 0.075)}:host(.kup-cross-selection) #kup-component tr.selected td:first-of-type{box-shadow:inset 4px 0px 0px 0px var(--kup-secondary-color)}:host(.kup-cross-selection) #kup-component tr.selected td.selected{background-color:rgba(var(--kup-text-color-rgb), 0.15)}:host(.kup-cross-selection) #kup-component tr.selected td.fixed-column,:host(.kup-cross-selection) #kup-component tr.selected td.fixed-row{background-color:var(--kup_datatable_background_color);background-image:linear-gradient(to right, rgba(var(--kup-text-color-rgb), 0.075) 0%, rgba(var(--kup-text-color-rgb), 0.075) 0.1%, rgba(var(--kup-text-color-rgb), 0.075))}:host(.kup-cross-selection) #kup-component tr.selected td.fixed-column.selected,:host(.kup-cross-selection) #kup-component tr.selected td.fixed-row.selected{background-image:linear-gradient(to right, rgba(var(--kup-text-color-rgb), 0.15) 0%, rgba(var(--kup-text-color-rgb), 0.15) 0.1%, rgba(var(--kup-text-color-rgb), 0.15))}:host(.kup-layout-fixed) #kup-component table{table-layout:fixed;width:100%}tr.clickable{cursor:pointer}";
|
|
8083
8083
|
|
|
8084
|
-
var __classPrivateFieldGet$
|
|
8084
|
+
var __classPrivateFieldGet$4 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
8085
8085
|
if (kind === "a" && !f)
|
|
8086
8086
|
throw new TypeError("Private accessor was defined without a getter");
|
|
8087
8087
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -8193,18 +8193,18 @@ const KupDataTable = class {
|
|
|
8193
8193
|
_KupDataTable_MESSAGE_WRAPPER_ID.set(this, 'messageWrapper');
|
|
8194
8194
|
_KupDataTable_INSERT_PREFIX.set(this, 'insert_');
|
|
8195
8195
|
_KupDataTable_stickyHeaderPosition.set(this, () => {
|
|
8196
|
-
if (__classPrivateFieldGet$
|
|
8197
|
-
if (__classPrivateFieldGet$
|
|
8198
|
-
if (!__classPrivateFieldGet$
|
|
8199
|
-
__classPrivateFieldGet$
|
|
8200
|
-
__classPrivateFieldGet$
|
|
8196
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f")) {
|
|
8197
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_tableIntersecting, "f")) {
|
|
8198
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_theadIntersecting, "f")) {
|
|
8199
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_updateStickyHeaderSize).call(this);
|
|
8200
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").classList.add('activated');
|
|
8201
8201
|
}
|
|
8202
8202
|
else {
|
|
8203
|
-
__classPrivateFieldGet$
|
|
8203
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").classList.remove('activated');
|
|
8204
8204
|
}
|
|
8205
8205
|
}
|
|
8206
8206
|
else {
|
|
8207
|
-
__classPrivateFieldGet$
|
|
8207
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").classList.remove('activated');
|
|
8208
8208
|
}
|
|
8209
8209
|
}
|
|
8210
8210
|
});
|
|
@@ -8298,7 +8298,7 @@ const KupDataTable = class {
|
|
|
8298
8298
|
if (this.store && this.stateId) {
|
|
8299
8299
|
const state = this.store.getState(this.stateId);
|
|
8300
8300
|
if (state != null) {
|
|
8301
|
-
__classPrivateFieldGet$
|
|
8301
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Initializing stateId ' + this.stateId);
|
|
8302
8302
|
// *** PROPS ***
|
|
8303
8303
|
this.filters = Object.assign({}, state.filters);
|
|
8304
8304
|
this.groups = [...state.groups];
|
|
@@ -8334,116 +8334,116 @@ const KupDataTable = class {
|
|
|
8334
8334
|
persistState() {
|
|
8335
8335
|
if (this.store && this.stateId) {
|
|
8336
8336
|
let somethingChanged = false;
|
|
8337
|
-
if (!__classPrivateFieldGet$
|
|
8337
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.filters, this.filters)) {
|
|
8338
8338
|
this.state.filters = Object.assign({}, this.filters);
|
|
8339
8339
|
somethingChanged = true;
|
|
8340
8340
|
}
|
|
8341
|
-
if (!__classPrivateFieldGet$
|
|
8341
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.groups, this.groups)) {
|
|
8342
8342
|
this.state.groups = [...this.groups];
|
|
8343
8343
|
somethingChanged = true;
|
|
8344
8344
|
}
|
|
8345
|
-
if (!__classPrivateFieldGet$
|
|
8345
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.sort, this.sort)) {
|
|
8346
8346
|
this.state.sort = [...this.sort];
|
|
8347
8347
|
somethingChanged = true;
|
|
8348
8348
|
}
|
|
8349
|
-
if (!__classPrivateFieldGet$
|
|
8349
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.expandGroups, this.expandGroups)) {
|
|
8350
8350
|
this.state.expandGroups = this.expandGroups;
|
|
8351
8351
|
somethingChanged = true;
|
|
8352
8352
|
}
|
|
8353
|
-
if (!__classPrivateFieldGet$
|
|
8353
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.groupLabelDisplay, this.groupLabelDisplay)) {
|
|
8354
8354
|
this.state.groupLabelDisplay = this.groupLabelDisplay;
|
|
8355
8355
|
somethingChanged = true;
|
|
8356
8356
|
}
|
|
8357
|
-
if (!__classPrivateFieldGet$
|
|
8357
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.density, this.density)) {
|
|
8358
8358
|
this.state.density = this.density;
|
|
8359
8359
|
somethingChanged = true;
|
|
8360
8360
|
}
|
|
8361
|
-
if (!__classPrivateFieldGet$
|
|
8361
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.enableExtraColumns, this.enableExtraColumns)) {
|
|
8362
8362
|
this.state.enableExtraColumns = this.enableExtraColumns;
|
|
8363
8363
|
somethingChanged = true;
|
|
8364
8364
|
}
|
|
8365
|
-
if (!__classPrivateFieldGet$
|
|
8365
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.enableSortableColumns, this.enableSortableColumns)) {
|
|
8366
8366
|
this.state.enableSortableColumns = this.enableSortableColumns;
|
|
8367
8367
|
somethingChanged = true;
|
|
8368
8368
|
}
|
|
8369
|
-
if (!__classPrivateFieldGet$
|
|
8369
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.forceOneLine, this.forceOneLine)) {
|
|
8370
8370
|
this.state.forceOneLine = this.forceOneLine;
|
|
8371
8371
|
somethingChanged = true;
|
|
8372
8372
|
}
|
|
8373
|
-
if (!__classPrivateFieldGet$
|
|
8373
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.globalFilter, this.globalFilter)) {
|
|
8374
8374
|
this.state.globalFilter = this.globalFilter;
|
|
8375
8375
|
somethingChanged = true;
|
|
8376
8376
|
}
|
|
8377
|
-
if (!__classPrivateFieldGet$
|
|
8377
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.globalFilterValue, this.globalFilterValue)) {
|
|
8378
8378
|
this.state.globalFilterValue = this.globalFilterValue;
|
|
8379
8379
|
somethingChanged = true;
|
|
8380
8380
|
}
|
|
8381
|
-
if (!__classPrivateFieldGet$
|
|
8381
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.headerIsPersistent, this.headerIsPersistent)) {
|
|
8382
8382
|
this.state.headerIsPersistent = this.headerIsPersistent;
|
|
8383
8383
|
somethingChanged = true;
|
|
8384
8384
|
}
|
|
8385
|
-
if (!__classPrivateFieldGet$
|
|
8385
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.lazyLoadRows, this.lazyLoadRows)) {
|
|
8386
8386
|
this.state.lazyLoadRows = this.lazyLoadRows;
|
|
8387
8387
|
somethingChanged = true;
|
|
8388
8388
|
}
|
|
8389
|
-
if (!__classPrivateFieldGet$
|
|
8389
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.loadMoreLimit, this.loadMoreLimit)) {
|
|
8390
8390
|
this.state.loadMoreLimit = this.loadMoreLimit;
|
|
8391
8391
|
somethingChanged = true;
|
|
8392
8392
|
}
|
|
8393
|
-
if (!__classPrivateFieldGet$
|
|
8393
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.selection, this.selection)) {
|
|
8394
8394
|
this.state.selection = this.selection;
|
|
8395
8395
|
somethingChanged = true;
|
|
8396
8396
|
}
|
|
8397
|
-
if (!__classPrivateFieldGet$
|
|
8397
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.rowsPerPage, this.currentRowsPerPage)) {
|
|
8398
8398
|
this.state.rowsPerPage = this.currentRowsPerPage;
|
|
8399
8399
|
somethingChanged = true;
|
|
8400
8400
|
}
|
|
8401
|
-
if (!__classPrivateFieldGet$
|
|
8401
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.showFilters, this.showFilters)) {
|
|
8402
8402
|
this.state.showFilters = this.showFilters;
|
|
8403
8403
|
somethingChanged = true;
|
|
8404
8404
|
}
|
|
8405
|
-
if (!__classPrivateFieldGet$
|
|
8405
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.showGroups, this.showGroups)) {
|
|
8406
8406
|
this.state.showGroups = this.showGroups;
|
|
8407
8407
|
somethingChanged = true;
|
|
8408
8408
|
}
|
|
8409
|
-
if (!__classPrivateFieldGet$
|
|
8409
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.showHeader, this.showHeader)) {
|
|
8410
8410
|
this.state.showHeader = this.showHeader;
|
|
8411
8411
|
somethingChanged = true;
|
|
8412
8412
|
}
|
|
8413
|
-
if (!__classPrivateFieldGet$
|
|
8413
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.showLoadMore, this.showLoadMore)) {
|
|
8414
8414
|
this.state.showLoadMore = this.showLoadMore;
|
|
8415
8415
|
somethingChanged = true;
|
|
8416
8416
|
}
|
|
8417
|
-
if (!__classPrivateFieldGet$
|
|
8417
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.sortEnabled, this.sortEnabled)) {
|
|
8418
8418
|
this.state.sortEnabled = this.sortEnabled;
|
|
8419
8419
|
somethingChanged = true;
|
|
8420
8420
|
}
|
|
8421
|
-
if (!__classPrivateFieldGet$
|
|
8421
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.sortableColumnsMutateData, this.sortableColumnsMutateData)) {
|
|
8422
8422
|
this.state.sortableColumnsMutateData =
|
|
8423
8423
|
this.sortableColumnsMutateData;
|
|
8424
8424
|
somethingChanged = true;
|
|
8425
8425
|
}
|
|
8426
|
-
if (!__classPrivateFieldGet$
|
|
8426
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.pageSelected, this.currentPage)) {
|
|
8427
8427
|
this.state.pageSelected = this.currentPage;
|
|
8428
8428
|
somethingChanged = true;
|
|
8429
8429
|
}
|
|
8430
|
-
if (!__classPrivateFieldGet$
|
|
8430
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.dragEnabled, this.dragEnabled)) {
|
|
8431
8431
|
this.state.dragEnabled = this.dragEnabled;
|
|
8432
8432
|
somethingChanged = true;
|
|
8433
8433
|
}
|
|
8434
|
-
if (!__classPrivateFieldGet$
|
|
8434
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.dropEnabled, this.dropEnabled)) {
|
|
8435
8435
|
this.state.dropEnabled = this.dropEnabled;
|
|
8436
8436
|
somethingChanged = true;
|
|
8437
8437
|
}
|
|
8438
|
-
if (!__classPrivateFieldGet$
|
|
8438
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.showFooter, this.showFooter)) {
|
|
8439
8439
|
this.state.showFooter = this.showFooter;
|
|
8440
8440
|
somethingChanged = true;
|
|
8441
8441
|
}
|
|
8442
|
-
if (!__classPrivateFieldGet$
|
|
8442
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.totals, this.totals)) {
|
|
8443
8443
|
this.state.totals = Object.assign({}, this.totals);
|
|
8444
8444
|
somethingChanged = true;
|
|
8445
8445
|
}
|
|
8446
|
-
if (!__classPrivateFieldGet$
|
|
8446
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.deepEqual(this.state.selectRowsById, this.selectedRows.reduce((accumulator, row, currentIndex) => {
|
|
8447
8447
|
const prefix = currentIndex > 0 ? ';' : '';
|
|
8448
8448
|
return accumulator + prefix + row.id;
|
|
8449
8449
|
}, ''))) {
|
|
@@ -8458,7 +8458,7 @@ const KupDataTable = class {
|
|
|
8458
8458
|
return;
|
|
8459
8459
|
}
|
|
8460
8460
|
if (somethingChanged) {
|
|
8461
|
-
__classPrivateFieldGet$
|
|
8461
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Persisting stateId ' + this.stateId);
|
|
8462
8462
|
this.store.persistState(this.stateId, this.state);
|
|
8463
8463
|
}
|
|
8464
8464
|
}
|
|
@@ -8467,33 +8467,33 @@ const KupDataTable = class {
|
|
|
8467
8467
|
this.currentRowsPerPage = newValue;
|
|
8468
8468
|
}
|
|
8469
8469
|
expandGroupsHandler() {
|
|
8470
|
-
if (!__classPrivateFieldGet$
|
|
8470
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_isRestoringState, "f")) {
|
|
8471
8471
|
this.recalculateRows();
|
|
8472
8472
|
// reset group state
|
|
8473
8473
|
this.groupState = {};
|
|
8474
|
-
__classPrivateFieldGet$
|
|
8474
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_forceGroupExpansion).call(this);
|
|
8475
8475
|
}
|
|
8476
8476
|
}
|
|
8477
8477
|
filtersChanged() {
|
|
8478
8478
|
this.expandGroupsHandler();
|
|
8479
8479
|
}
|
|
8480
8480
|
recalculateRows() {
|
|
8481
|
-
if (!__classPrivateFieldGet$
|
|
8482
|
-
__classPrivateFieldGet$
|
|
8481
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_isRestoringState, "f")) {
|
|
8482
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_initRows).call(this);
|
|
8483
8483
|
}
|
|
8484
8484
|
}
|
|
8485
8485
|
identifyAndInitRows() {
|
|
8486
8486
|
identify(this.getRows());
|
|
8487
8487
|
this.expandGroupsHandler();
|
|
8488
|
-
__classPrivateFieldGet$
|
|
8488
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_resetSelectedRows).call(this);
|
|
8489
8489
|
}
|
|
8490
8490
|
recalculateRowsAndUndoSelections() {
|
|
8491
|
-
if (!__classPrivateFieldGet$
|
|
8491
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_isRestoringState, "f")) {
|
|
8492
8492
|
this.recalculateRows();
|
|
8493
8493
|
// reset group state
|
|
8494
8494
|
this.groupState = {};
|
|
8495
|
-
__classPrivateFieldGet$
|
|
8496
|
-
__classPrivateFieldGet$
|
|
8495
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_forceGroupExpansion).call(this);
|
|
8496
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_resetSelectedRows).call(this);
|
|
8497
8497
|
}
|
|
8498
8498
|
}
|
|
8499
8499
|
controlFixedRowsColumns() {
|
|
@@ -8509,8 +8509,8 @@ const KupDataTable = class {
|
|
|
8509
8509
|
}
|
|
8510
8510
|
}
|
|
8511
8511
|
recalculateData() {
|
|
8512
|
-
if (__classPrivateFieldGet$
|
|
8513
|
-
__classPrivateFieldGet$
|
|
8512
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_initialized, "f")) {
|
|
8513
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_calculateData).call(this);
|
|
8514
8514
|
}
|
|
8515
8515
|
}
|
|
8516
8516
|
/**
|
|
@@ -8518,14 +8518,14 @@ const KupDataTable = class {
|
|
|
8518
8518
|
*/
|
|
8519
8519
|
async closeColumnMenu() {
|
|
8520
8520
|
this.columnMenuAnchor = null;
|
|
8521
|
-
if (__classPrivateFieldGet$
|
|
8522
|
-
__classPrivateFieldGet$
|
|
8521
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f")) {
|
|
8522
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").data = null;
|
|
8523
8523
|
}
|
|
8524
|
-
__classPrivateFieldGet$
|
|
8524
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").close(__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"));
|
|
8525
8525
|
this.kupDataTableColumnMenu.emit({
|
|
8526
8526
|
comp: this,
|
|
8527
8527
|
id: this.rootElement.id,
|
|
8528
|
-
card: __classPrivateFieldGet$
|
|
8528
|
+
card: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"),
|
|
8529
8529
|
event: null,
|
|
8530
8530
|
open: false,
|
|
8531
8531
|
});
|
|
@@ -8568,8 +8568,8 @@ const KupDataTable = class {
|
|
|
8568
8568
|
* Closes the insert new record card (called by backend, on success)
|
|
8569
8569
|
*/
|
|
8570
8570
|
async closeInsertCard() {
|
|
8571
|
-
if (__classPrivateFieldGet$
|
|
8572
|
-
__classPrivateFieldGet$
|
|
8571
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f")) {
|
|
8572
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").remove();
|
|
8573
8573
|
__classPrivateFieldSet$2(this, _KupDataTable_insertCard, null, "f");
|
|
8574
8574
|
}
|
|
8575
8575
|
}
|
|
@@ -8577,8 +8577,8 @@ const KupDataTable = class {
|
|
|
8577
8577
|
* Closes the delete confirm card (called by backend, on success)
|
|
8578
8578
|
*/
|
|
8579
8579
|
async closeConfirmDeleteCard() {
|
|
8580
|
-
if (__classPrivateFieldGet$
|
|
8581
|
-
__classPrivateFieldGet$
|
|
8580
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteDialog, "f")) {
|
|
8581
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteDialog, "f").close();
|
|
8582
8582
|
__classPrivateFieldSet$2(this, _KupDataTable_confirmDeleteCard, null, "f");
|
|
8583
8583
|
__classPrivateFieldSet$2(this, _KupDataTable_confirmDeleteDialog, null, "f");
|
|
8584
8584
|
}
|
|
@@ -8588,23 +8588,23 @@ const KupDataTable = class {
|
|
|
8588
8588
|
*/
|
|
8589
8589
|
async getCards() {
|
|
8590
8590
|
const obj = {};
|
|
8591
|
-
if (__classPrivateFieldGet$
|
|
8591
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f")) {
|
|
8592
8592
|
obj['insertCard'] = {
|
|
8593
|
-
el: __classPrivateFieldGet$
|
|
8594
|
-
messageWrapper: __classPrivateFieldGet$
|
|
8595
|
-
message: __classPrivateFieldGet$
|
|
8596
|
-
submitButton: __classPrivateFieldGet$
|
|
8597
|
-
cancelButton: __classPrivateFieldGet$
|
|
8598
|
-
form: __classPrivateFieldGet$
|
|
8593
|
+
el: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f"),
|
|
8594
|
+
messageWrapper: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_WRAPPER_ID, "f")),
|
|
8595
|
+
message: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_ID, "f")),
|
|
8596
|
+
submitButton: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_SUBMIT_ID, "f")),
|
|
8597
|
+
cancelButton: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_CANCEL_ID, "f")),
|
|
8598
|
+
form: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_FIELDS_FORM_ID, "f")),
|
|
8599
8599
|
};
|
|
8600
8600
|
}
|
|
8601
|
-
if (__classPrivateFieldGet$
|
|
8601
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f")) {
|
|
8602
8602
|
obj['confirmDeleteCard'] = {
|
|
8603
|
-
el: __classPrivateFieldGet$
|
|
8604
|
-
messageWrapper: __classPrivateFieldGet$
|
|
8605
|
-
message: __classPrivateFieldGet$
|
|
8606
|
-
submitButton: __classPrivateFieldGet$
|
|
8607
|
-
cancelButton: __classPrivateFieldGet$
|
|
8603
|
+
el: __classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f"),
|
|
8604
|
+
messageWrapper: __classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_WRAPPER_ID, "f")),
|
|
8605
|
+
message: __classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_ID, "f")),
|
|
8606
|
+
submitButton: __classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_SUBMIT_ID, "f")),
|
|
8607
|
+
cancelButton: __classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").querySelector('#' + __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_CANCEL_ID, "f")),
|
|
8608
8608
|
};
|
|
8609
8609
|
}
|
|
8610
8610
|
/*
|
|
@@ -8658,7 +8658,7 @@ const KupDataTable = class {
|
|
|
8658
8658
|
* @param {KupDataColumn} column - Column to hide.
|
|
8659
8659
|
*/
|
|
8660
8660
|
async hideColumn(column) {
|
|
8661
|
-
__classPrivateFieldGet$
|
|
8661
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").data.column.hide(this.data, [column.name]);
|
|
8662
8662
|
this.kupColumnRemove.emit({
|
|
8663
8663
|
comp: this,
|
|
8664
8664
|
id: this.rootElement.id,
|
|
@@ -8673,7 +8673,7 @@ const KupDataTable = class {
|
|
|
8673
8673
|
* @returns {string|KupDataColumn} Returns the new column created or a string containing the error message if something went wrong.
|
|
8674
8674
|
*/
|
|
8675
8675
|
async newColumn(type, options) {
|
|
8676
|
-
const result = __classPrivateFieldGet$
|
|
8676
|
+
const result = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").data.column.new(this.data, type, options);
|
|
8677
8677
|
this.refresh();
|
|
8678
8678
|
return result;
|
|
8679
8679
|
}
|
|
@@ -8683,40 +8683,40 @@ const KupDataTable = class {
|
|
|
8683
8683
|
*/
|
|
8684
8684
|
async openColumnMenu(column) {
|
|
8685
8685
|
this.columnMenuAnchor = column;
|
|
8686
|
-
if (!__classPrivateFieldGet$
|
|
8686
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f")) {
|
|
8687
8687
|
__classPrivateFieldSet$2(this, _KupDataTable_columnMenuCard, document.createElement('kup-card'), "f");
|
|
8688
|
-
__classPrivateFieldGet$
|
|
8689
|
-
__classPrivateFieldGet$
|
|
8690
|
-
__classPrivateFieldGet$
|
|
8691
|
-
__classPrivateFieldGet$
|
|
8692
|
-
__classPrivateFieldGet$
|
|
8688
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").isMenu = true;
|
|
8689
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").layoutNumber = 12;
|
|
8690
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").sizeX = 'auto';
|
|
8691
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").sizeY = 'auto';
|
|
8692
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").addEventListener('kup-card-click', (e) => {
|
|
8693
8693
|
this.kupDataTableColumnMenu.emit({
|
|
8694
8694
|
comp: this,
|
|
8695
8695
|
id: this.rootElement.id,
|
|
8696
|
-
card: __classPrivateFieldGet$
|
|
8696
|
+
card: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"),
|
|
8697
8697
|
event: e,
|
|
8698
|
-
open: __classPrivateFieldGet$
|
|
8698
|
+
open: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").menuVisible,
|
|
8699
8699
|
});
|
|
8700
8700
|
});
|
|
8701
|
-
__classPrivateFieldGet$
|
|
8702
|
-
__classPrivateFieldGet$
|
|
8701
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").addEventListener('kup-card-event', (e) => {
|
|
8702
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").eventHandlers(e, this);
|
|
8703
8703
|
this.kupDataTableColumnMenu.emit({
|
|
8704
8704
|
comp: this,
|
|
8705
8705
|
id: this.rootElement.id,
|
|
8706
|
-
card: __classPrivateFieldGet$
|
|
8706
|
+
card: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"),
|
|
8707
8707
|
event: e,
|
|
8708
|
-
open: __classPrivateFieldGet$
|
|
8708
|
+
open: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").menuVisible,
|
|
8709
8709
|
});
|
|
8710
8710
|
});
|
|
8711
8711
|
}
|
|
8712
|
-
__classPrivateFieldGet$
|
|
8713
|
-
__classPrivateFieldGet$
|
|
8714
|
-
__classPrivateFieldGet$
|
|
8715
|
-
__classPrivateFieldGet$
|
|
8712
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").setAttribute('data-column', column);
|
|
8713
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").data = __classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").prepData(this, getColumnByName(this.getVisibleColumns(), column));
|
|
8714
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").open(this, column);
|
|
8715
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").reposition(this, __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"));
|
|
8716
8716
|
this.kupDataTableColumnMenu.emit({
|
|
8717
8717
|
comp: this,
|
|
8718
8718
|
id: this.rootElement.id,
|
|
8719
|
-
card: __classPrivateFieldGet$
|
|
8719
|
+
card: __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f"),
|
|
8720
8720
|
event: null,
|
|
8721
8721
|
open: true,
|
|
8722
8722
|
});
|
|
@@ -8726,7 +8726,7 @@ const KupDataTable = class {
|
|
|
8726
8726
|
*/
|
|
8727
8727
|
async refresh(recalcRows) {
|
|
8728
8728
|
if (recalcRows) {
|
|
8729
|
-
__classPrivateFieldGet$
|
|
8729
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_initRows).call(this);
|
|
8730
8730
|
}
|
|
8731
8731
|
forceUpdate(this);
|
|
8732
8732
|
}
|
|
@@ -8735,8 +8735,8 @@ const KupDataTable = class {
|
|
|
8735
8735
|
*/
|
|
8736
8736
|
async resizeCallback() {
|
|
8737
8737
|
if (this.lazyLoadCells &&
|
|
8738
|
-
this.rootElement.clientWidth !== __classPrivateFieldGet$
|
|
8739
|
-
window.clearTimeout(__classPrivateFieldGet$
|
|
8738
|
+
this.rootElement.clientWidth !== __classPrivateFieldGet$4(this, _KupDataTable_oldWidth, "f")) {
|
|
8739
|
+
window.clearTimeout(__classPrivateFieldGet$4(this, _KupDataTable_resizeTimeout, "f"));
|
|
8740
8740
|
__classPrivateFieldSet$2(this, _KupDataTable_resizeTimeout, window.setTimeout(() => this.refresh(), 300), "f");
|
|
8741
8741
|
}
|
|
8742
8742
|
}
|
|
@@ -8751,7 +8751,7 @@ const KupDataTable = class {
|
|
|
8751
8751
|
if (!column) {
|
|
8752
8752
|
return;
|
|
8753
8753
|
}
|
|
8754
|
-
const row = __classPrivateFieldGet$
|
|
8754
|
+
const row = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getRow).call(this, rowId);
|
|
8755
8755
|
if (!row) {
|
|
8756
8756
|
return;
|
|
8757
8757
|
}
|
|
@@ -8809,7 +8809,7 @@ const KupDataTable = class {
|
|
|
8809
8809
|
this.selectedRows = [];
|
|
8810
8810
|
for (let index = 0; index < rowsIdentifiers.length; index++) {
|
|
8811
8811
|
const id = rowsIdentifiers[index];
|
|
8812
|
-
this.selectedRows.push(__classPrivateFieldGet$
|
|
8812
|
+
this.selectedRows.push(__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getRow).call(this, id));
|
|
8813
8813
|
}
|
|
8814
8814
|
if (emitEvent !== false) {
|
|
8815
8815
|
this.kupRowSelected.emit({
|
|
@@ -8823,12 +8823,12 @@ const KupDataTable = class {
|
|
|
8823
8823
|
}
|
|
8824
8824
|
//---- Lifecycle hooks ----
|
|
8825
8825
|
componentWillLoad() {
|
|
8826
|
-
__classPrivateFieldGet$
|
|
8827
|
-
__classPrivateFieldGet$
|
|
8828
|
-
__classPrivateFieldGet$
|
|
8829
|
-
__classPrivateFieldGet$
|
|
8826
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logLoad(this, false);
|
|
8827
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.register(this);
|
|
8828
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").theme.register(this);
|
|
8829
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").toolbar.register(this.rootElement);
|
|
8830
8830
|
if (!this.emptyDataLabel) {
|
|
8831
|
-
this.emptyDataLabel = __classPrivateFieldGet$
|
|
8831
|
+
this.emptyDataLabel = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EMPTY_DATA);
|
|
8832
8832
|
}
|
|
8833
8833
|
__classPrivateFieldSet$2(this, _KupDataTable_columnMenuInstance, new KupColumnMenu(), "f");
|
|
8834
8834
|
__classPrivateFieldSet$2(this, _KupDataTable_filtersColumnMenuInstance, new FiltersColumnMenu(), "f");
|
|
@@ -8852,18 +8852,18 @@ const KupDataTable = class {
|
|
|
8852
8852
|
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, 0, "f");
|
|
8853
8853
|
}
|
|
8854
8854
|
if (document.querySelector('.topbar')) {
|
|
8855
|
-
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, __classPrivateFieldGet$
|
|
8855
|
+
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, __classPrivateFieldGet$4(this, _KupDataTable_navBarHeight, "f") + document.querySelector('.topbar').clientHeight, "f");
|
|
8856
8856
|
}
|
|
8857
|
-
__classPrivateFieldGet$
|
|
8857
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_setObserver).call(this);
|
|
8858
8858
|
//this.recalculateRows();
|
|
8859
8859
|
// Detects is the browser is Safari. If needed, this function can be moved into an external file and then imported into components
|
|
8860
8860
|
__classPrivateFieldSet$2(this, _KupDataTable_isSafariBrowser, CSS.supports('position', '-webkit-sticky') ||
|
|
8861
8861
|
!!(window && window.safari), "f");
|
|
8862
|
-
__classPrivateFieldGet$
|
|
8862
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_calculateData).call(this);
|
|
8863
8863
|
__classPrivateFieldSet$2(this, _KupDataTable_initialized, true, "f");
|
|
8864
8864
|
}
|
|
8865
8865
|
componentWillRender() {
|
|
8866
|
-
__classPrivateFieldGet$
|
|
8866
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logRender(this, false);
|
|
8867
8867
|
}
|
|
8868
8868
|
componentDidRender() {
|
|
8869
8869
|
const root = this.rootElement.shadowRoot;
|
|
@@ -8874,40 +8874,40 @@ const KupDataTable = class {
|
|
|
8874
8874
|
}
|
|
8875
8875
|
}
|
|
8876
8876
|
if (this.showCustomization) {
|
|
8877
|
-
__classPrivateFieldGet$
|
|
8878
|
-
}
|
|
8879
|
-
__classPrivateFieldGet$
|
|
8880
|
-
__classPrivateFieldGet$
|
|
8881
|
-
__classPrivateFieldGet$
|
|
8882
|
-
__classPrivateFieldGet$
|
|
8883
|
-
__classPrivateFieldGet$
|
|
8884
|
-
__classPrivateFieldGet$
|
|
8877
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_customizePanelPosition).call(this);
|
|
8878
|
+
}
|
|
8879
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_totalMenuPosition).call(this);
|
|
8880
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_checkScrollOnHover).call(this);
|
|
8881
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_didRenderObservers).call(this);
|
|
8882
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_didRenderInteractables).call(this);
|
|
8883
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hideShowColumnDropArea).call(this, false);
|
|
8884
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_setDynPosElements).call(this);
|
|
8885
8885
|
if (this.headerIsPersistent &&
|
|
8886
8886
|
this.tableHeight === undefined &&
|
|
8887
8887
|
this.tableWidth === undefined) {
|
|
8888
|
-
__classPrivateFieldGet$
|
|
8888
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_updateStickyHeaderSize).call(this);
|
|
8889
8889
|
}
|
|
8890
|
-
setTimeout(() => __classPrivateFieldGet$
|
|
8890
|
+
setTimeout(() => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_updateFixedRowsAndColumnsCssVariables).call(this), 50);
|
|
8891
8891
|
// *** Store
|
|
8892
8892
|
if (this.lazyLoadCells) {
|
|
8893
8893
|
this.persistState();
|
|
8894
8894
|
}
|
|
8895
8895
|
// ***
|
|
8896
8896
|
__classPrivateFieldSet$2(this, _KupDataTable_oldWidth, this.rootElement.clientWidth, "f");
|
|
8897
|
-
__classPrivateFieldGet$
|
|
8897
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logRender(this, true);
|
|
8898
8898
|
}
|
|
8899
8899
|
componentDidLoad() {
|
|
8900
|
-
__classPrivateFieldGet$
|
|
8901
|
-
__classPrivateFieldGet$
|
|
8902
|
-
__classPrivateFieldGet$
|
|
8900
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_didLoadObservers).call(this);
|
|
8901
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_didLoadEventHandling).call(this);
|
|
8902
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_didLoadInteractables).call(this);
|
|
8903
8903
|
this.lazyLoadCells = true;
|
|
8904
8904
|
this.kupDidLoad.emit({ comp: this, id: this.rootElement.id });
|
|
8905
|
-
__classPrivateFieldGet$
|
|
8906
|
-
__classPrivateFieldGet$
|
|
8905
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").resize.observe(this.rootElement);
|
|
8906
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logLoad(this, true);
|
|
8907
8907
|
}
|
|
8908
8908
|
resetCurrentPage() {
|
|
8909
8909
|
this.currentPage = 1;
|
|
8910
|
-
__classPrivateFieldGet$
|
|
8910
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_resetSelectedRows).call(this);
|
|
8911
8911
|
}
|
|
8912
8912
|
getColumns() {
|
|
8913
8913
|
return this.data && this.data.columns
|
|
@@ -8918,7 +8918,7 @@ const KupDataTable = class {
|
|
|
8918
8918
|
// TODO: change into `visible ?? true` when TS dependency has been updated
|
|
8919
8919
|
const visibleColumns = this.getColumns().filter(({ visible }) => visible !== undefined ? visible : true);
|
|
8920
8920
|
// check grouping
|
|
8921
|
-
if (__classPrivateFieldGet$
|
|
8921
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)) {
|
|
8922
8922
|
// filtering column based on group visibility
|
|
8923
8923
|
return visibleColumns.filter((column) => {
|
|
8924
8924
|
// check if in group
|
|
@@ -8942,7 +8942,7 @@ const KupDataTable = class {
|
|
|
8942
8942
|
return visibleColumns;
|
|
8943
8943
|
}
|
|
8944
8944
|
getGroupByName(column) {
|
|
8945
|
-
if (!__classPrivateFieldGet$
|
|
8945
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)) {
|
|
8946
8946
|
return null;
|
|
8947
8947
|
}
|
|
8948
8948
|
for (let group of this.groups) {
|
|
@@ -8953,7 +8953,7 @@ const KupDataTable = class {
|
|
|
8953
8953
|
return null;
|
|
8954
8954
|
}
|
|
8955
8955
|
getColumnValues(column) {
|
|
8956
|
-
return __classPrivateFieldGet$
|
|
8956
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_filtersRowsInstance, "f").getColumnValues(this, column, this.globalFilterValue, __classPrivateFieldGet$4(this, _KupDataTable_filtersColumnMenuInstance, "f"));
|
|
8957
8957
|
}
|
|
8958
8958
|
getRows() {
|
|
8959
8959
|
return this.data && this.data.rows ? this.data.rows : [];
|
|
@@ -8968,7 +8968,7 @@ const KupDataTable = class {
|
|
|
8968
8968
|
}
|
|
8969
8969
|
async defaultSortingFunction(columns, receivingColumnIndex, sortedColumnIndex, useNewObject = false) {
|
|
8970
8970
|
const toSort = !useNewObject ? columns : [...columns];
|
|
8971
|
-
__classPrivateFieldGet$
|
|
8971
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_moveSortedColumns).call(this, toSort, receivingColumnIndex, sortedColumnIndex);
|
|
8972
8972
|
return toSort;
|
|
8973
8973
|
}
|
|
8974
8974
|
areTotalsSelected(column) {
|
|
@@ -8976,7 +8976,7 @@ const KupDataTable = class {
|
|
|
8976
8976
|
}
|
|
8977
8977
|
onTotalsChange(event, column) {
|
|
8978
8978
|
// close menu
|
|
8979
|
-
__classPrivateFieldGet$
|
|
8979
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeTotalMenu).call(this);
|
|
8980
8980
|
if (column) {
|
|
8981
8981
|
// must do this
|
|
8982
8982
|
// otherwise does not fire the watcher
|
|
@@ -8999,14 +8999,14 @@ const KupDataTable = class {
|
|
|
8999
8999
|
let selectRowCell = null;
|
|
9000
9000
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
9001
9001
|
extraCells++;
|
|
9002
|
-
const fixedCellStyle = __classPrivateFieldGet$
|
|
9002
|
+
const fixedCellStyle = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, extraCells, 0, extraCells);
|
|
9003
9003
|
selectRowCell = (h("td", { class: fixedCellStyle ? fixedCellStyle.fixedCellClasses : null, style: fixedCellStyle ? fixedCellStyle.fixedCellStyle : null }));
|
|
9004
9004
|
}
|
|
9005
9005
|
// Action cell
|
|
9006
9006
|
let actionsCell = null;
|
|
9007
|
-
if (__classPrivateFieldGet$
|
|
9007
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
9008
9008
|
extraCells++;
|
|
9009
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
9009
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, extraCells, 0, extraCells);
|
|
9010
9010
|
actionsCell = (h("td", { class: selectionStyleAndClass
|
|
9011
9011
|
? selectionStyleAndClass.fixedCellClasses
|
|
9012
9012
|
: {}, style: selectionStyleAndClass
|
|
@@ -9014,19 +9014,19 @@ const KupDataTable = class {
|
|
|
9014
9014
|
: {} }));
|
|
9015
9015
|
}
|
|
9016
9016
|
const footerCells = this.getVisibleColumns().map((column, columnIndex) => {
|
|
9017
|
-
const fixedCellStyle = __classPrivateFieldGet$
|
|
9017
|
+
const fixedCellStyle = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, columnIndex + 1 + extraCells, 0, extraCells);
|
|
9018
9018
|
let totalMenu = undefined;
|
|
9019
9019
|
let menuLabel = TotalLabel.CALC;
|
|
9020
9020
|
const translation = {
|
|
9021
|
-
[TotalLabel.AVERAGE]: __classPrivateFieldGet$
|
|
9022
|
-
[TotalLabel.CALC]: __classPrivateFieldGet$
|
|
9023
|
-
[TotalLabel.CANC]: __classPrivateFieldGet$
|
|
9024
|
-
[TotalLabel.COUNT]: __classPrivateFieldGet$
|
|
9025
|
-
[TotalLabel.DISTINCT]: __classPrivateFieldGet$
|
|
9026
|
-
[TotalLabel.MATH]: __classPrivateFieldGet$
|
|
9027
|
-
[TotalLabel.MAX]: __classPrivateFieldGet$
|
|
9028
|
-
[TotalLabel.MIN]: __classPrivateFieldGet$
|
|
9029
|
-
[TotalLabel.SUM]: __classPrivateFieldGet$
|
|
9021
|
+
[TotalLabel.AVERAGE]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.AVERAGE),
|
|
9022
|
+
[TotalLabel.CALC]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.CALCULATE),
|
|
9023
|
+
[TotalLabel.CANC]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.CANCEL),
|
|
9024
|
+
[TotalLabel.COUNT]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.COUNT),
|
|
9025
|
+
[TotalLabel.DISTINCT]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.DISTINCT),
|
|
9026
|
+
[TotalLabel.MATH]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.FORMULA),
|
|
9027
|
+
[TotalLabel.MAX]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.MAXIMUM),
|
|
9028
|
+
[TotalLabel.MIN]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.MINIMUM),
|
|
9029
|
+
[TotalLabel.SUM]: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageTotals.SUM),
|
|
9030
9030
|
};
|
|
9031
9031
|
if (this.totals) {
|
|
9032
9032
|
const totalValue = this.totals[column.name];
|
|
@@ -9058,7 +9058,7 @@ const KupDataTable = class {
|
|
|
9058
9058
|
}
|
|
9059
9059
|
}
|
|
9060
9060
|
}
|
|
9061
|
-
if (__classPrivateFieldGet$
|
|
9061
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isOpenedTotalMenuForColumn).call(this, column.name)) {
|
|
9062
9062
|
const listData = [
|
|
9063
9063
|
{
|
|
9064
9064
|
id: TotalMode.COUNT,
|
|
@@ -9069,7 +9069,7 @@ const KupDataTable = class {
|
|
|
9069
9069
|
value: translation[TotalLabel.DISTINCT],
|
|
9070
9070
|
},
|
|
9071
9071
|
];
|
|
9072
|
-
if (__classPrivateFieldGet$
|
|
9072
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isNumber(column.obj)) {
|
|
9073
9073
|
// TODO Move these objects in declarations
|
|
9074
9074
|
listData.push({
|
|
9075
9075
|
id: TotalMode.SUM,
|
|
@@ -9086,7 +9086,7 @@ const KupDataTable = class {
|
|
|
9086
9086
|
value: translation[TotalLabel.MAX],
|
|
9087
9087
|
});
|
|
9088
9088
|
}
|
|
9089
|
-
else if (__classPrivateFieldGet$
|
|
9089
|
+
else if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isDate(column.obj)) {
|
|
9090
9090
|
listData.push({
|
|
9091
9091
|
id: TotalMode.MIN,
|
|
9092
9092
|
separator: true,
|
|
@@ -9111,14 +9111,14 @@ const KupDataTable = class {
|
|
|
9111
9111
|
}
|
|
9112
9112
|
// TODO please use getValueForDisplay
|
|
9113
9113
|
let value;
|
|
9114
|
-
const footerValue = __classPrivateFieldGet$
|
|
9114
|
+
const footerValue = __classPrivateFieldGet$4(this, _KupDataTable_footer, "f")[column.name];
|
|
9115
9115
|
if (menuLabel === TotalLabel.COUNT ||
|
|
9116
9116
|
menuLabel === TotalLabel.DISTINCT) {
|
|
9117
9117
|
value = footerValue;
|
|
9118
9118
|
}
|
|
9119
9119
|
else if ((menuLabel === TotalLabel.MAX ||
|
|
9120
9120
|
menuLabel === TotalLabel.MIN) &&
|
|
9121
|
-
__classPrivateFieldGet$
|
|
9121
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isDate(column.obj)) {
|
|
9122
9122
|
if (footerValue) {
|
|
9123
9123
|
value = footerValue;
|
|
9124
9124
|
}
|
|
@@ -9142,38 +9142,38 @@ const KupDataTable = class {
|
|
|
9142
9142
|
let transpose = undefined;
|
|
9143
9143
|
let totalsMatrix = undefined;
|
|
9144
9144
|
if (this.openedCustomSettings) {
|
|
9145
|
-
density = __classPrivateFieldGet$
|
|
9146
|
-
fontsize = __classPrivateFieldGet$
|
|
9147
|
-
grid = __classPrivateFieldGet$
|
|
9148
|
-
transpose = __classPrivateFieldGet$
|
|
9145
|
+
density = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderDensityPanel).call(this);
|
|
9146
|
+
fontsize = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderFontSizePanel).call(this);
|
|
9147
|
+
grid = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderGridPanel).call(this);
|
|
9148
|
+
transpose = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderTransposeSwitch).call(this);
|
|
9149
9149
|
if (this.totals && this.groups.length > 0) {
|
|
9150
|
-
totalsMatrix = __classPrivateFieldGet$
|
|
9150
|
+
totalsMatrix = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderTotalsMatrix).call(this);
|
|
9151
9151
|
}
|
|
9152
9152
|
}
|
|
9153
9153
|
return (h("kup-card", { customStyle: "::slotted(kup-switch) { width: max-content !important; } ::slotted(*) { margin: auto !important; } ::slotted(.customize-element) { margin: auto !important; padding: 0 1em 1em 1em !important; width: max-content !important; } ::slotted(.customize-element):nth-child(1) { padding-top: 1em !important; }", isMenu: true, layoutFamily: KupCardFamily.FREE, ref: (el) => {
|
|
9154
9154
|
__classPrivateFieldSet$2(this, _KupDataTable_customizeTopPanelRef, el, "f");
|
|
9155
|
-
}, sizeX: "360px", sizeY: "300px" }, density, grid, fontsize, transpose, h("kup-switch", { class: "customize-element", checked: this.dragEnabled, label: __classPrivateFieldGet$
|
|
9155
|
+
}, sizeX: "360px", sizeY: "300px" }, density, grid, fontsize, transpose, h("kup-switch", { class: "customize-element", checked: this.dragEnabled, label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.DRAG_AND_DROP), leadingLabel: true, "onkup-switch-change": () => (this.dragEnabled = !this.dragEnabled) }), h("kup-switch", { class: "customize-element", checked: this.editableData, label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EDITABLE), leadingLabel: true, "onkup-switch-change": () => (this.editableData = !this.editableData) }), h("kup-button", { title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.TOGGLE) +
|
|
9156
9156
|
' Magic Box ' +
|
|
9157
9157
|
'(' +
|
|
9158
|
-
__classPrivateFieldGet$
|
|
9159
|
-
')', icon: "auto-fix", "onkup-button-click": () => __classPrivateFieldGet$
|
|
9158
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EXPERIMENTAL_FEAT) +
|
|
9159
|
+
')', icon: "auto-fix", "onkup-button-click": () => __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").toggleMagicBox() }), totalsMatrix));
|
|
9160
9160
|
}
|
|
9161
9161
|
render() {
|
|
9162
9162
|
__classPrivateFieldSet$2(this, _KupDataTable_thRefs, [], "f");
|
|
9163
9163
|
__classPrivateFieldSet$2(this, _KupDataTable_rowsRefs, [], "f");
|
|
9164
9164
|
__classPrivateFieldSet$2(this, _KupDataTable_renderedRows, [], "f");
|
|
9165
9165
|
let elStyle = undefined;
|
|
9166
|
-
__classPrivateFieldSet$2(this, _KupDataTable_sizedColumns, __classPrivateFieldGet$
|
|
9166
|
+
__classPrivateFieldSet$2(this, _KupDataTable_sizedColumns, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getSizedColumns).call(this), "f");
|
|
9167
9167
|
let rows = null;
|
|
9168
|
-
if (__classPrivateFieldGet$
|
|
9169
|
-
rows = (h("tr", { ref: (el) => __classPrivateFieldGet$
|
|
9168
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_paginatedRowsLength, "f") === 0) {
|
|
9169
|
+
rows = (h("tr", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").push(el) }, h("td", { colSpan: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_calculateColspan).call(this) }, this.emptyDataLabel)));
|
|
9170
9170
|
}
|
|
9171
9171
|
else {
|
|
9172
9172
|
rows = [];
|
|
9173
|
-
__classPrivateFieldGet$
|
|
9173
|
+
__classPrivateFieldGet$4(this, _KupDataTable_paginatedRows, "f")
|
|
9174
9174
|
// We must pass the previous element of the array to check if we must hide or display the value of the cell
|
|
9175
9175
|
// When the column has specified the parameter hideValuesRepetitions
|
|
9176
|
-
.map((row, rowIndex, currentArray) => __classPrivateFieldGet$
|
|
9176
|
+
.map((row, rowIndex, currentArray) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderRow).call(this, row, 0, rowIndex + 1, rowIndex > 0 ? currentArray[rowIndex - 1] : null))
|
|
9177
9177
|
.forEach((jsxRow) => {
|
|
9178
9178
|
if (Array.isArray(jsxRow)) {
|
|
9179
9179
|
jsxRow.forEach((jr) => rows.push(jr));
|
|
@@ -9185,24 +9185,24 @@ const KupDataTable = class {
|
|
|
9185
9185
|
}
|
|
9186
9186
|
// header
|
|
9187
9187
|
// for multi selection purposes, this should be called before this.renderedRows has been evaluated
|
|
9188
|
-
const header = __classPrivateFieldGet$
|
|
9189
|
-
const stickyHeader = __classPrivateFieldGet$
|
|
9188
|
+
const header = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderHeader).call(this);
|
|
9189
|
+
const stickyHeader = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderStickyHeader).call(this);
|
|
9190
9190
|
let paginatorTop = undefined;
|
|
9191
9191
|
let paginatorBottom = undefined;
|
|
9192
|
-
if ((!this.lazyLoadRows && __classPrivateFieldGet$
|
|
9192
|
+
if ((!this.lazyLoadRows && __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f") > this.rowsPerPage) ||
|
|
9193
9193
|
this.showCustomization ||
|
|
9194
9194
|
this.showLoadMore) {
|
|
9195
9195
|
if (PaginatorPos.TOP === this.paginatorPos ||
|
|
9196
9196
|
PaginatorPos.BOTH === this.paginatorPos) {
|
|
9197
|
-
paginatorTop = __classPrivateFieldGet$
|
|
9197
|
+
paginatorTop = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderPaginator).call(this, true);
|
|
9198
9198
|
}
|
|
9199
9199
|
if (PaginatorPos.BOTTOM === this.paginatorPos ||
|
|
9200
9200
|
PaginatorPos.BOTH === this.paginatorPos) {
|
|
9201
|
-
paginatorBottom = __classPrivateFieldGet$
|
|
9201
|
+
paginatorBottom = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderPaginator).call(this, false);
|
|
9202
9202
|
}
|
|
9203
9203
|
}
|
|
9204
9204
|
let groupChips = null;
|
|
9205
|
-
if (__classPrivateFieldGet$
|
|
9205
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)) {
|
|
9206
9206
|
const chipsData = [];
|
|
9207
9207
|
for (let index = 0; index < this.groups.length; index++) {
|
|
9208
9208
|
const group = this.groups[index];
|
|
@@ -9215,7 +9215,7 @@ const KupDataTable = class {
|
|
|
9215
9215
|
});
|
|
9216
9216
|
}
|
|
9217
9217
|
else {
|
|
9218
|
-
__classPrivateFieldGet$
|
|
9218
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Grouped for a non-existent column! (' +
|
|
9219
9219
|
group.column +
|
|
9220
9220
|
')', KupDebugCategory.WARNING);
|
|
9221
9221
|
}
|
|
@@ -9228,7 +9228,7 @@ const KupDataTable = class {
|
|
|
9228
9228
|
onIconClick: [],
|
|
9229
9229
|
};
|
|
9230
9230
|
for (let i = 0; i < chipsData.length; i++) {
|
|
9231
|
-
props.onIconClick.push(() => __classPrivateFieldGet$
|
|
9231
|
+
props.onIconClick.push(() => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_removeGroup).call(this, i));
|
|
9232
9232
|
}
|
|
9233
9233
|
groupChips = h(FChip, Object.assign({}, props));
|
|
9234
9234
|
}
|
|
@@ -9236,7 +9236,7 @@ const KupDataTable = class {
|
|
|
9236
9236
|
const tableClass = {
|
|
9237
9237
|
// Class to specify whether the table should have width: auto or not.
|
|
9238
9238
|
// Mandatory to check with custom column size.
|
|
9239
|
-
'auto-width': __classPrivateFieldGet$
|
|
9239
|
+
'auto-width': __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_tableHasAutoWidth).call(this),
|
|
9240
9240
|
'column-separation': ShowGrid.COMPLETE === this.showGrid ||
|
|
9241
9241
|
ShowGrid.COL === this.showGrid,
|
|
9242
9242
|
// When there are columns with a specified width, we must add table-layout: fixed to force the table to respect them
|
|
@@ -9286,17 +9286,17 @@ const KupDataTable = class {
|
|
|
9286
9286
|
}
|
|
9287
9287
|
}
|
|
9288
9288
|
};
|
|
9289
|
-
const compCreated = (h(Host, { "onKup-cell-input": autoselectOnAction, "onKup-cell-update": autoselectOnAction }, h("style", null, __classPrivateFieldGet$
|
|
9289
|
+
const compCreated = (h(Host, { "onKup-cell-input": autoselectOnAction, "onKup-cell-update": autoselectOnAction }, h("style", null, __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { id: componentWrapperId }, h("div", { class: "above-wrapper" }, this.globalFilter ? (h("div", { id: "global-filter" }, h(FTextField, { fullWidth: true, icon: KupThemeIconValues.SEARCH, label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageSearch.SEARCH), value: this.globalFilterValue, onInput: (event) => {
|
|
9290
9290
|
const t = event.target;
|
|
9291
|
-
window.clearTimeout(__classPrivateFieldGet$
|
|
9292
|
-
__classPrivateFieldSet$2(this, _KupDataTable_globalFilterTimeout, window.setTimeout(() => __classPrivateFieldGet$
|
|
9291
|
+
window.clearTimeout(__classPrivateFieldGet$4(this, _KupDataTable_globalFilterTimeout, "f"));
|
|
9292
|
+
__classPrivateFieldSet$2(this, _KupDataTable_globalFilterTimeout, window.setTimeout(() => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onGlobalFilterChange).call(this, t), 600, t), "f");
|
|
9293
9293
|
} }))) : null, paginatorTop), h("div", { class: "group-wrapper" }, groupChips), h("div", { class: "actions-wrapper" }, this.insertMode !== '' ? (h(FButton, { icon: "plus", onClick: async () => {
|
|
9294
9294
|
var _a;
|
|
9295
9295
|
if (this.insertMode === 'form') {
|
|
9296
|
-
__classPrivateFieldGet$
|
|
9296
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_rowInsertForm).call(this);
|
|
9297
9297
|
}
|
|
9298
9298
|
else {
|
|
9299
|
-
__classPrivateFieldSet$2(this, _KupDataTable_insertCount, (_a = __classPrivateFieldGet$
|
|
9299
|
+
__classPrivateFieldSet$2(this, _KupDataTable_insertCount, (_a = __classPrivateFieldGet$4(this, _KupDataTable_insertCount, "f"), _a++, _a), "f");
|
|
9300
9300
|
const cells = {};
|
|
9301
9301
|
for (let index = 0; index < this.data.columns.length; index++) {
|
|
9302
9302
|
const column = this.data.columns[index];
|
|
@@ -9310,8 +9310,8 @@ const KupDataTable = class {
|
|
|
9310
9310
|
}
|
|
9311
9311
|
const row = {
|
|
9312
9312
|
cells,
|
|
9313
|
-
id: __classPrivateFieldGet$
|
|
9314
|
-
__classPrivateFieldGet$
|
|
9313
|
+
id: __classPrivateFieldGet$4(this, _KupDataTable_INSERT_PREFIX, "f") +
|
|
9314
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCount, "f"),
|
|
9315
9315
|
};
|
|
9316
9316
|
this.data.rows.unshift(row);
|
|
9317
9317
|
await this.refresh(true);
|
|
@@ -9325,13 +9325,13 @@ const KupDataTable = class {
|
|
|
9325
9325
|
});
|
|
9326
9326
|
}, styling: FButtonStyling.OUTLINED, title: "Save", wrapperClass: "save-button" })) : null, this.showDeleteButton &&
|
|
9327
9327
|
this.selectedRows.length > 0 ? (h(FButton, { icon: "delete", onClick: () => {
|
|
9328
|
-
__classPrivateFieldGet$
|
|
9329
|
-
}, styling: FButtonStyling.OUTLINED, title: "Delete selected rows", wrapperClass: "delete-button" })) : null), h("div", { class: "droparea", ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_dropareaRef, el, "f")) }, this.showGroups ? __classPrivateFieldGet$
|
|
9330
|
-
? __classPrivateFieldGet$
|
|
9328
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_rowsDelete).call(this);
|
|
9329
|
+
}, styling: FButtonStyling.OUTLINED, title: "Delete selected rows", wrapperClass: "delete-button" })) : null), h("div", { class: "droparea", ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_dropareaRef, el, "f")) }, this.showGroups ? __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_columnGroupArea).call(this) : null, this.removableColumns
|
|
9330
|
+
? __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_columnRemoveArea).call(this)
|
|
9331
9331
|
: null), h("div", { style: elStyle, class: belowClass, ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_tableAreaRef, el, "f")) }, this.showCustomization
|
|
9332
9332
|
? [
|
|
9333
9333
|
h("div", { class: "settings-trigger", onClick: () => {
|
|
9334
|
-
__classPrivateFieldGet$
|
|
9334
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onCustomSettingsClick).call(this);
|
|
9335
9335
|
}, ref: (el) => {
|
|
9336
9336
|
__classPrivateFieldSet$2(this, _KupDataTable_customizeTopButtonRef, el, "f");
|
|
9337
9337
|
} }, h(FImage, { color: `var(${KupThemeColorValues.TITLE})`, resource: "settings", sizeX: "10px" })),
|
|
@@ -9341,29 +9341,29 @@ const KupDataTable = class {
|
|
|
9341
9341
|
ev.stopPropagation();
|
|
9342
9342
|
}, onContextMenu: (e) => {
|
|
9343
9343
|
e.preventDefault();
|
|
9344
|
-
} }, h("thead", { hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_theadRef, el, "f")) }, h("tr", null, header)), h("tbody", null, rows), this.showFooter || __classPrivateFieldGet$
|
|
9344
|
+
} }, h("thead", { hidden: !this.showHeader, ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_theadRef, el, "f")) }, h("tr", null, header)), h("tbody", null, rows), this.showFooter || __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasTotals).call(this)
|
|
9345
9345
|
? this.renderFooter()
|
|
9346
9346
|
: null), stickyEl), paginatorBottom)));
|
|
9347
9347
|
return compCreated;
|
|
9348
9348
|
}
|
|
9349
9349
|
disconnectedCallback() {
|
|
9350
|
-
__classPrivateFieldGet$
|
|
9351
|
-
__classPrivateFieldGet$
|
|
9352
|
-
__classPrivateFieldGet$
|
|
9350
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.unregister(__classPrivateFieldGet$4(this, _KupDataTable_interactableDrag, "f").concat(__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f"), __classPrivateFieldGet$4(this, _KupDataTable_interactableResize, "f"), __classPrivateFieldGet$4(this, _KupDataTable_interactableTouch, "f")));
|
|
9351
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.unregister(this);
|
|
9352
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").theme.unregister(this);
|
|
9353
9353
|
const dynamicPositionElements = this.rootElement.shadowRoot.querySelectorAll('[' + kupDynamicPositionAttribute + ']');
|
|
9354
9354
|
if (dynamicPositionElements.length > 0) {
|
|
9355
|
-
__classPrivateFieldGet$
|
|
9355
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.unregister(Array.prototype.slice.call(dynamicPositionElements));
|
|
9356
9356
|
}
|
|
9357
|
-
if (__classPrivateFieldGet$
|
|
9358
|
-
__classPrivateFieldGet$
|
|
9357
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f")) {
|
|
9358
|
+
__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f").remove();
|
|
9359
9359
|
}
|
|
9360
|
-
if (__classPrivateFieldGet$
|
|
9361
|
-
__classPrivateFieldGet$
|
|
9360
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f")) {
|
|
9361
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").remove();
|
|
9362
9362
|
}
|
|
9363
9363
|
if (this.scrollOnHover) {
|
|
9364
|
-
__classPrivateFieldGet$
|
|
9364
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").scrollOnHover.unregister(__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f"));
|
|
9365
9365
|
}
|
|
9366
|
-
__classPrivateFieldGet$
|
|
9366
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").resize.unobserve(this.rootElement);
|
|
9367
9367
|
this.kupDidUnload.emit({ comp: this, id: this.rootElement.id });
|
|
9368
9368
|
}
|
|
9369
9369
|
get rootElement() { return getElement$1(this); }
|
|
@@ -9384,16 +9384,16 @@ const KupDataTable = class {
|
|
|
9384
9384
|
}; }
|
|
9385
9385
|
};
|
|
9386
9386
|
_KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _KupDataTable_rowsLength = new WeakMap(), _KupDataTable_paginatedRows = new WeakMap(), _KupDataTable_paginatedRowsLength = new WeakMap(), _KupDataTable_footer = new WeakMap(), _KupDataTable_kupManager = new WeakMap(), _KupDataTable_renderedRows = new WeakMap(), _KupDataTable_loadMoreEventCounter = new WeakMap(), _KupDataTable_loadMoreEventPreviousQuantity = new WeakMap(), _KupDataTable_theadRef = new WeakMap(), _KupDataTable_tableRef = new WeakMap(), _KupDataTable_originalData = new WeakMap(), _KupDataTable_tableAreaRef = new WeakMap(), _KupDataTable_stickyTheadRef = new WeakMap(), _KupDataTable_customizeTopButtonRef = new WeakMap(), _KupDataTable_customizeTopPanelRef = new WeakMap(), _KupDataTable_sizedColumns = new WeakMap(), _KupDataTable_intObserver = new WeakMap(), _KupDataTable_navBarHeight = new WeakMap(), _KupDataTable_theadIntersecting = new WeakMap(), _KupDataTable_tableIntersecting = new WeakMap(), _KupDataTable_isSafariBrowser = new WeakMap(), _KupDataTable_isRestoringState = new WeakMap(), _KupDataTable_globalFilterTimeout = new WeakMap(), _KupDataTable_totalMenuCoords = new WeakMap(), _KupDataTable_clickTimeout = new WeakMap(), _KupDataTable_thRefs = new WeakMap(), _KupDataTable_rowsRefs = new WeakMap(), _KupDataTable_oldWidth = new WeakMap(), _KupDataTable_hold = new WeakMap(), _KupDataTable_interactableDrag = new WeakMap(), _KupDataTable_interactableDrop = new WeakMap(), _KupDataTable_interactableResize = new WeakMap(), _KupDataTable_interactableTouch = new WeakMap(), _KupDataTable_dropareaRef = new WeakMap(), _KupDataTable_removeDropareaRef = new WeakMap(), _KupDataTable_groupsDropareaRef = new WeakMap(), _KupDataTable_clickCb = new WeakMap(), _KupDataTable_clickCbCustomPanel = new WeakMap(), _KupDataTable_clickCbDropCard = new WeakMap(), _KupDataTable_resizeTimeout = new WeakMap(), _KupDataTable_columnMenuInstance = new WeakMap(), _KupDataTable_filtersColumnMenuInstance = new WeakMap(), _KupDataTable_filtersRowsInstance = new WeakMap(), _KupDataTable_detailCard = new WeakMap(), _KupDataTable_insertCard = new WeakMap(), _KupDataTable_confirmDeleteCard = new WeakMap(), _KupDataTable_confirmDeleteDialog = new WeakMap(), _KupDataTable_columnMenuCard = new WeakMap(), _KupDataTable_columnDropCard = new WeakMap(), _KupDataTable_columnDropCardAnchor = new WeakMap(), _KupDataTable_insertCount = new WeakMap(), _KupDataTable_BUTTON_CANCEL_ID = new WeakMap(), _KupDataTable_BUTTON_SUBMIT_ID = new WeakMap(), _KupDataTable_FIELDS_FORM_ID = new WeakMap(), _KupDataTable_MESSAGE_ID = new WeakMap(), _KupDataTable_MESSAGE_WRAPPER_ID = new WeakMap(), _KupDataTable_INSERT_PREFIX = new WeakMap(), _KupDataTable_stickyHeaderPosition = new WeakMap(), _KupDataTable_FONTSIZE_CODES = new WeakMap(), _KupDataTable_FONTSIZE_DECODES = new WeakMap(), _KupDataTable_FONTSIZE_ICONS = new WeakMap(), _KupDataTable_DENSITY_DECODES = new WeakMap(), _KupDataTable_DENSITY_ICONS = new WeakMap(), _KupDataTable_GRID_CODES = new WeakMap(), _KupDataTable_GRID_DECODES = new WeakMap(), _KupDataTable_GRID_ICONS = new WeakMap(), _KupDataTable_instances = new WeakSet(), _KupDataTable_closeDropCard = function _KupDataTable_closeDropCard() {
|
|
9387
|
-
__classPrivateFieldGet$
|
|
9388
|
-
__classPrivateFieldGet$
|
|
9389
|
-
__classPrivateFieldGet$
|
|
9387
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.stop(__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f"));
|
|
9388
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").removeClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCbDropCard, "f"));
|
|
9389
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").remove();
|
|
9390
9390
|
__classPrivateFieldSet$2(this, _KupDataTable_columnDropCard, null, "f");
|
|
9391
9391
|
}, _KupDataTable_createDropCard = function _KupDataTable_createDropCard(starter, receiving) {
|
|
9392
|
-
if (__classPrivateFieldGet$
|
|
9393
|
-
__classPrivateFieldGet$
|
|
9392
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f")) {
|
|
9393
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeDropCard).call(this);
|
|
9394
9394
|
}
|
|
9395
9395
|
__classPrivateFieldSet$2(this, _KupDataTable_columnDropCard, document.createElement('kup-card'), "f");
|
|
9396
|
-
__classPrivateFieldGet$
|
|
9396
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").data = {
|
|
9397
9397
|
options: {
|
|
9398
9398
|
data: this.data,
|
|
9399
9399
|
enableFormula: this.enableColumnsFormula,
|
|
@@ -9402,46 +9402,46 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9402
9402
|
receivingColumn: receiving,
|
|
9403
9403
|
starterColumn: starter,
|
|
9404
9404
|
formulaCb: () => {
|
|
9405
|
-
__classPrivateFieldGet$
|
|
9405
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeDropCard).call(this);
|
|
9406
9406
|
this.refresh();
|
|
9407
9407
|
},
|
|
9408
9408
|
mergeCb: () => {
|
|
9409
9409
|
this.newColumn(KupDataNewColumnTypes.CONCATENATE, {
|
|
9410
9410
|
columns: [receiving.name, starter.name],
|
|
9411
9411
|
});
|
|
9412
|
-
__classPrivateFieldGet$
|
|
9412
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeDropCard).call(this);
|
|
9413
9413
|
},
|
|
9414
9414
|
moveCb: () => {
|
|
9415
|
-
__classPrivateFieldGet$
|
|
9416
|
-
__classPrivateFieldGet$
|
|
9415
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handleColumnSort).call(this, receiving, starter);
|
|
9416
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeDropCard).call(this);
|
|
9417
9417
|
},
|
|
9418
9418
|
},
|
|
9419
9419
|
};
|
|
9420
|
-
__classPrivateFieldGet$
|
|
9421
|
-
__classPrivateFieldGet$
|
|
9422
|
-
__classPrivateFieldGet$
|
|
9423
|
-
__classPrivateFieldGet$
|
|
9424
|
-
__classPrivateFieldGet$
|
|
9425
|
-
__classPrivateFieldGet$
|
|
9426
|
-
__classPrivateFieldGet$
|
|
9420
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").layoutFamily = KupCardFamily.BUILT_IN;
|
|
9421
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").layoutNumber = 3;
|
|
9422
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").isMenu = true;
|
|
9423
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").sizeX = '280px';
|
|
9424
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").sizeY = 'auto';
|
|
9425
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f"), __classPrivateFieldGet$4(this, _KupDataTable_columnDropCardAnchor, "f"), 0, KupDynamicPositionPlacement.AUTO, true);
|
|
9426
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f"));
|
|
9427
9427
|
__classPrivateFieldSet$2(this, _KupDataTable_clickCbDropCard, {
|
|
9428
9428
|
cb: () => {
|
|
9429
|
-
__classPrivateFieldGet$
|
|
9429
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeDropCard).call(this);
|
|
9430
9430
|
},
|
|
9431
|
-
el: __classPrivateFieldGet$
|
|
9431
|
+
el: __classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f"),
|
|
9432
9432
|
}, "f");
|
|
9433
|
-
__classPrivateFieldGet$
|
|
9434
|
-
__classPrivateFieldGet$
|
|
9433
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").addClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCbDropCard, "f"), true);
|
|
9434
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnDropCard, "f").menuVisible = true;
|
|
9435
9435
|
}, _KupDataTable_calculateData = function _KupDataTable_calculateData() {
|
|
9436
9436
|
if (!this.transpose) {
|
|
9437
9437
|
// restore
|
|
9438
|
-
if (__classPrivateFieldGet$
|
|
9439
|
-
this.data = Object.assign({}, __classPrivateFieldGet$
|
|
9438
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_originalData, "f")) {
|
|
9439
|
+
this.data = Object.assign({}, __classPrivateFieldGet$4(this, _KupDataTable_originalData, "f"));
|
|
9440
9440
|
}
|
|
9441
9441
|
}
|
|
9442
9442
|
else {
|
|
9443
9443
|
// transpose
|
|
9444
|
-
__classPrivateFieldGet$
|
|
9444
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_setTransposedData).call(this);
|
|
9445
9445
|
}
|
|
9446
9446
|
}, _KupDataTable_getRow = function _KupDataTable_getRow(id) {
|
|
9447
9447
|
let row = null;
|
|
@@ -9458,26 +9458,26 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9458
9458
|
row = rows.find((row) => row.id === id);
|
|
9459
9459
|
}
|
|
9460
9460
|
};
|
|
9461
|
-
if (__classPrivateFieldGet$
|
|
9462
|
-
__classPrivateFieldGet$
|
|
9461
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this) && typeof id === 'string') {
|
|
9462
|
+
__classPrivateFieldGet$4(this, _KupDataTable_paginatedRows, "f").forEach((row) => search(row.group.children));
|
|
9463
9463
|
}
|
|
9464
9464
|
else {
|
|
9465
|
-
test(__classPrivateFieldGet$
|
|
9465
|
+
test(__classPrivateFieldGet$4(this, _KupDataTable_rows, "f"));
|
|
9466
9466
|
}
|
|
9467
9467
|
return row;
|
|
9468
9468
|
}, _KupDataTable_getTransposedData = function _KupDataTable_getTransposedData(column) {
|
|
9469
9469
|
if (column) {
|
|
9470
9470
|
this.filters = {};
|
|
9471
9471
|
}
|
|
9472
|
-
return __classPrivateFieldGet$
|
|
9472
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").data.transpose(this.data, column);
|
|
9473
9473
|
}, _KupDataTable_setTransposedData = function _KupDataTable_setTransposedData() {
|
|
9474
9474
|
// transpose
|
|
9475
9475
|
__classPrivateFieldSet$2(this, _KupDataTable_originalData, Object.assign({}, this.data), "f");
|
|
9476
9476
|
if (this.data.columns.length > 0) {
|
|
9477
|
-
this.data = __classPrivateFieldGet$
|
|
9477
|
+
this.data = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getTransposedData).call(this, this.data.columns[0].name);
|
|
9478
9478
|
}
|
|
9479
9479
|
}, _KupDataTable_switchToTotalsMatrix = function _KupDataTable_switchToTotalsMatrix() {
|
|
9480
|
-
if (__classPrivateFieldGet$
|
|
9480
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_rows, "f").length === 0 || !__classPrivateFieldGet$4(this, _KupDataTable_rows, "f")[0].group)
|
|
9481
9481
|
return;
|
|
9482
9482
|
// calc totals matrix data
|
|
9483
9483
|
const totalsMatrixData = {};
|
|
@@ -9485,9 +9485,9 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9485
9485
|
// note that the sorting of the columns depends on the totals selection
|
|
9486
9486
|
// the first column is the one that is selected first in the totals, and so on...
|
|
9487
9487
|
const ids = [];
|
|
9488
|
-
ids.push(__classPrivateFieldGet$
|
|
9489
|
-
Object.keys(__classPrivateFieldGet$
|
|
9490
|
-
if (__classPrivateFieldGet$
|
|
9488
|
+
ids.push(__classPrivateFieldGet$4(this, _KupDataTable_rows, "f")[0].group.column);
|
|
9489
|
+
Object.keys(__classPrivateFieldGet$4(this, _KupDataTable_rows, "f")[0].group.totals).forEach((columnKey) => {
|
|
9490
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_rows, "f")[0].group.column !== columnKey)
|
|
9491
9491
|
ids.push(columnKey);
|
|
9492
9492
|
});
|
|
9493
9493
|
// calc columns
|
|
@@ -9517,7 +9517,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9517
9517
|
totalMode + ' ' + currentColumn.title;
|
|
9518
9518
|
}
|
|
9519
9519
|
}
|
|
9520
|
-
__classPrivateFieldGet$
|
|
9520
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_setObjForTotalsMatrix).call(this, currentColumn, this.totals);
|
|
9521
9521
|
}
|
|
9522
9522
|
totalsMatrixColumns.push(currentColumn);
|
|
9523
9523
|
}
|
|
@@ -9528,15 +9528,15 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9528
9528
|
// calc rows
|
|
9529
9529
|
const totalsMatrixRows = [];
|
|
9530
9530
|
let index = 0;
|
|
9531
|
-
__classPrivateFieldGet$
|
|
9531
|
+
__classPrivateFieldGet$4(this, _KupDataTable_rows, "f").forEach((row) => {
|
|
9532
9532
|
const cells = {};
|
|
9533
9533
|
ids.forEach((id) => {
|
|
9534
9534
|
let totalValue = row.group.totals[id];
|
|
9535
9535
|
if (!totalValue) {
|
|
9536
9536
|
totalValue = row.group.id;
|
|
9537
9537
|
}
|
|
9538
|
-
if (__classPrivateFieldGet$
|
|
9539
|
-
totalValue = __classPrivateFieldGet$
|
|
9538
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dates.isValid(totalValue, KupDatesFormats.ISO_DATE)) {
|
|
9539
|
+
totalValue = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dates.format(totalValue);
|
|
9540
9540
|
}
|
|
9541
9541
|
cells[id] = {
|
|
9542
9542
|
value: String(totalValue),
|
|
@@ -9576,13 +9576,13 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9576
9576
|
}, _KupDataTable_setObjForTotalsMatrix = function _KupDataTable_setObjForTotalsMatrix(column, totals) {
|
|
9577
9577
|
const obj = column.obj;
|
|
9578
9578
|
const totalMode = totals[column.name];
|
|
9579
|
-
if (__classPrivateFieldGet$
|
|
9579
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isDate(obj)) {
|
|
9580
9580
|
// check if min or max totals mode
|
|
9581
9581
|
if (totalMode === TotalMode.MAX || totalMode === TotalMode.MIN) {
|
|
9582
9582
|
return;
|
|
9583
9583
|
}
|
|
9584
9584
|
}
|
|
9585
|
-
else if (__classPrivateFieldGet$
|
|
9585
|
+
else if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isNumber(obj)) {
|
|
9586
9586
|
// check if percentage
|
|
9587
9587
|
if (obj.p && obj.p.toUpperCase() === 'P') {
|
|
9588
9588
|
if (totalMode !== TotalMode.COUNT &&
|
|
@@ -9610,14 +9610,14 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9610
9610
|
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, 0, "f");
|
|
9611
9611
|
}
|
|
9612
9612
|
if (topBar) {
|
|
9613
|
-
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, __classPrivateFieldGet$
|
|
9614
|
-
}
|
|
9615
|
-
if (__classPrivateFieldGet$
|
|
9616
|
-
__classPrivateFieldGet$
|
|
9617
|
-
const widthTable = __classPrivateFieldGet$
|
|
9618
|
-
__classPrivateFieldGet$
|
|
9619
|
-
const thCollection = __classPrivateFieldGet$
|
|
9620
|
-
const thStickyCollection = __classPrivateFieldGet$
|
|
9613
|
+
__classPrivateFieldSet$2(this, _KupDataTable_navBarHeight, __classPrivateFieldGet$4(this, _KupDataTable_navBarHeight, "f") + topBar.clientHeight, "f");
|
|
9614
|
+
}
|
|
9615
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f")) {
|
|
9616
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").style.top = __classPrivateFieldGet$4(this, _KupDataTable_navBarHeight, "f") + 'px';
|
|
9617
|
+
const widthTable = __classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f").offsetWidth;
|
|
9618
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").style.maxWidth = widthTable + 'px';
|
|
9619
|
+
const thCollection = __classPrivateFieldGet$4(this, _KupDataTable_theadRef, "f").querySelectorAll('th');
|
|
9620
|
+
const thStickyCollection = __classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").querySelectorAll('th-sticky');
|
|
9621
9621
|
for (let i = 0; i < thCollection.length; i++) {
|
|
9622
9622
|
const widthTH = thCollection[i].offsetWidth;
|
|
9623
9623
|
thStickyCollection[i].style.width = widthTH + 'px';
|
|
@@ -9628,8 +9628,8 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9628
9628
|
entries.forEach((entry) => {
|
|
9629
9629
|
if (entry.target.tagName === 'TR') {
|
|
9630
9630
|
if (entry.isIntersecting) {
|
|
9631
|
-
__classPrivateFieldGet$
|
|
9632
|
-
const delta = __classPrivateFieldGet$
|
|
9631
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Last row entering the viewport, loading more elements.');
|
|
9632
|
+
const delta = __classPrivateFieldGet$4(this, _KupDataTable_rows, "f").length - this.currentRowsPerPage;
|
|
9633
9633
|
if (delta < this.loadMoreStep) {
|
|
9634
9634
|
this.currentRowsPerPage += delta;
|
|
9635
9635
|
}
|
|
@@ -9643,7 +9643,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9643
9643
|
if (entry.isIntersecting) {
|
|
9644
9644
|
__classPrivateFieldSet$2(this, _KupDataTable_theadIntersecting, true, "f");
|
|
9645
9645
|
}
|
|
9646
|
-
else if (entry.boundingClientRect.bottom > __classPrivateFieldGet$
|
|
9646
|
+
else if (entry.boundingClientRect.bottom > __classPrivateFieldGet$4(this, _KupDataTable_navBarHeight, "f")) {
|
|
9647
9647
|
//If the thead is not intersecting but it still is inside the viewport, is to be considered intersected
|
|
9648
9648
|
__classPrivateFieldSet$2(this, _KupDataTable_theadIntersecting, true, "f");
|
|
9649
9649
|
}
|
|
@@ -9662,19 +9662,19 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9662
9662
|
if (this.tableHeight === undefined &&
|
|
9663
9663
|
this.tableWidth === undefined &&
|
|
9664
9664
|
this.headerIsPersistent) {
|
|
9665
|
-
__classPrivateFieldGet$
|
|
9665
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyHeaderPosition, "f").call(this);
|
|
9666
9666
|
}
|
|
9667
9667
|
});
|
|
9668
9668
|
};
|
|
9669
9669
|
const options = {
|
|
9670
9670
|
threshold: 0,
|
|
9671
|
-
rootMargin: '-' + __classPrivateFieldGet$
|
|
9671
|
+
rootMargin: '-' + __classPrivateFieldGet$4(this, _KupDataTable_navBarHeight, "f") + 'px 0px 0px 0px',
|
|
9672
9672
|
};
|
|
9673
9673
|
__classPrivateFieldSet$2(this, _KupDataTable_intObserver, new IntersectionObserver(callback, options), "f");
|
|
9674
9674
|
}, _KupDataTable_didLoadInteractables = function _KupDataTable_didLoadInteractables() {
|
|
9675
|
-
__classPrivateFieldGet$
|
|
9675
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableTouch, "f").push(__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"));
|
|
9676
9676
|
const tapCb = (e) => {
|
|
9677
|
-
if (__classPrivateFieldGet$
|
|
9677
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_hold, "f")) {
|
|
9678
9678
|
__classPrivateFieldSet$2(this, _KupDataTable_hold, false, "f");
|
|
9679
9679
|
return;
|
|
9680
9680
|
}
|
|
@@ -9687,11 +9687,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9687
9687
|
for (const key in e) {
|
|
9688
9688
|
clone[key] = e[key];
|
|
9689
9689
|
}
|
|
9690
|
-
__classPrivateFieldGet$
|
|
9690
|
+
__classPrivateFieldGet$4(this, _KupDataTable_clickTimeout, "f").push(setTimeout(() => {
|
|
9691
9691
|
this.kupDataTableClick.emit({
|
|
9692
9692
|
comp: this,
|
|
9693
9693
|
id: this.rootElement.id,
|
|
9694
|
-
details: __classPrivateFieldGet$
|
|
9694
|
+
details: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_clickHandler).call(this, clone),
|
|
9695
9695
|
});
|
|
9696
9696
|
}, 300));
|
|
9697
9697
|
break;
|
|
@@ -9700,7 +9700,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9700
9700
|
this.kupDataTableContextMenu.emit({
|
|
9701
9701
|
comp: this,
|
|
9702
9702
|
id: this.rootElement.id,
|
|
9703
|
-
details: __classPrivateFieldGet$
|
|
9703
|
+
details: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_contextMenuHandler).call(this, e),
|
|
9704
9704
|
});
|
|
9705
9705
|
break;
|
|
9706
9706
|
}
|
|
@@ -9709,17 +9709,17 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9709
9709
|
switch (e.button) {
|
|
9710
9710
|
// left click
|
|
9711
9711
|
case 0:
|
|
9712
|
-
for (let index = 0; index < __classPrivateFieldGet$
|
|
9713
|
-
clearTimeout(__classPrivateFieldGet$
|
|
9714
|
-
__classPrivateFieldGet$
|
|
9715
|
-
__classPrivateFieldGet$
|
|
9712
|
+
for (let index = 0; index < __classPrivateFieldGet$4(this, _KupDataTable_clickTimeout, "f").length; index++) {
|
|
9713
|
+
clearTimeout(__classPrivateFieldGet$4(this, _KupDataTable_clickTimeout, "f")[index]);
|
|
9714
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Cleared clickHandler timeout(' +
|
|
9715
|
+
__classPrivateFieldGet$4(this, _KupDataTable_clickTimeout, "f")[index] +
|
|
9716
9716
|
').');
|
|
9717
9717
|
}
|
|
9718
9718
|
__classPrivateFieldSet$2(this, _KupDataTable_clickTimeout, [], "f");
|
|
9719
9719
|
this.kupDataTableDblClick.emit({
|
|
9720
9720
|
comp: this,
|
|
9721
9721
|
id: this.rootElement.id,
|
|
9722
|
-
details: __classPrivateFieldGet$
|
|
9722
|
+
details: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_dblClickHandler).call(this, e),
|
|
9723
9723
|
});
|
|
9724
9724
|
break;
|
|
9725
9725
|
}
|
|
@@ -9730,40 +9730,40 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9730
9730
|
this.kupDataTableContextMenu.emit({
|
|
9731
9731
|
comp: this,
|
|
9732
9732
|
id: this.rootElement.id,
|
|
9733
|
-
details: __classPrivateFieldGet$
|
|
9733
|
+
details: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_contextMenuHandler).call(this, e),
|
|
9734
9734
|
});
|
|
9735
9735
|
}
|
|
9736
9736
|
};
|
|
9737
|
-
__classPrivateFieldGet$
|
|
9738
|
-
__classPrivateFieldGet$
|
|
9739
|
-
__classPrivateFieldGet$
|
|
9737
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.on(__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"), KupPointerEventTypes.TAP, tapCb);
|
|
9738
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.on(__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"), KupPointerEventTypes.DOUBLETAP, doubletapCb);
|
|
9739
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.on(__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"), KupPointerEventTypes.HOLD, holdCb);
|
|
9740
9740
|
}, _KupDataTable_didRenderInteractables = function _KupDataTable_didRenderInteractables() {
|
|
9741
9741
|
if (this.showGroups) {
|
|
9742
|
-
if (!__classPrivateFieldGet$
|
|
9743
|
-
__classPrivateFieldGet$
|
|
9744
|
-
__classPrivateFieldGet$
|
|
9742
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").includes(__classPrivateFieldGet$4(this, _KupDataTable_groupsDropareaRef, "f"))) {
|
|
9743
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").push(__classPrivateFieldGet$4(this, _KupDataTable_groupsDropareaRef, "f"));
|
|
9744
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.dropzone(__classPrivateFieldGet$4(this, _KupDataTable_groupsDropareaRef, "f"), {
|
|
9745
9745
|
accept: `[${kupDraggableColumnAttr}]`,
|
|
9746
9746
|
}, null, {
|
|
9747
9747
|
drop: (e) => {
|
|
9748
9748
|
const draggedTh = e.relatedTarget;
|
|
9749
9749
|
const grouped = getColumnByName(this.getColumns(), draggedTh.dataset.column);
|
|
9750
|
-
__classPrivateFieldGet$
|
|
9751
|
-
__classPrivateFieldGet$
|
|
9750
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handleColumnGroup).call(this, grouped);
|
|
9751
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").removeAttribute(kupDragActiveAttr);
|
|
9752
9752
|
},
|
|
9753
9753
|
});
|
|
9754
9754
|
}
|
|
9755
9755
|
}
|
|
9756
9756
|
if (this.removableColumns) {
|
|
9757
|
-
if (!__classPrivateFieldGet$
|
|
9758
|
-
__classPrivateFieldGet$
|
|
9759
|
-
__classPrivateFieldGet$
|
|
9757
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").includes(__classPrivateFieldGet$4(this, _KupDataTable_removeDropareaRef, "f"))) {
|
|
9758
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").push(__classPrivateFieldGet$4(this, _KupDataTable_removeDropareaRef, "f"));
|
|
9759
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.dropzone(__classPrivateFieldGet$4(this, _KupDataTable_removeDropareaRef, "f"), {
|
|
9760
9760
|
accept: `[${kupDraggableColumnAttr}]`,
|
|
9761
9761
|
}, null, {
|
|
9762
9762
|
drop: (e) => {
|
|
9763
9763
|
const draggedTh = e.relatedTarget;
|
|
9764
9764
|
const deleted = getColumnByName(this.getColumns(), draggedTh.dataset.column);
|
|
9765
9765
|
this.hideColumn(deleted);
|
|
9766
|
-
__classPrivateFieldGet$
|
|
9766
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").removeAttribute(kupDragActiveAttr);
|
|
9767
9767
|
},
|
|
9768
9768
|
});
|
|
9769
9769
|
}
|
|
@@ -9796,7 +9796,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9796
9796
|
__classPrivateFieldSet$2(this, _KupDataTable_columnDropCardAnchor, e.target, "f");
|
|
9797
9797
|
if (receiving && starter) {
|
|
9798
9798
|
if (onlySort) {
|
|
9799
|
-
__classPrivateFieldGet$
|
|
9799
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handleColumnSort).call(this, receiving, starter);
|
|
9800
9800
|
}
|
|
9801
9801
|
else if (onlyMerge) {
|
|
9802
9802
|
this.newColumn(KupDataNewColumnTypes.CONCATENATE, {
|
|
@@ -9804,17 +9804,17 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9804
9804
|
});
|
|
9805
9805
|
}
|
|
9806
9806
|
else {
|
|
9807
|
-
__classPrivateFieldGet$
|
|
9807
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_createDropCard).call(this, starter, receiving);
|
|
9808
9808
|
}
|
|
9809
9809
|
}
|
|
9810
|
-
__classPrivateFieldGet$
|
|
9810
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").removeAttribute(kupDragActiveAttr);
|
|
9811
9811
|
};
|
|
9812
9812
|
const startCb = (e) => {
|
|
9813
9813
|
const draggable = e.target;
|
|
9814
|
-
__classPrivateFieldGet$
|
|
9814
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hideShowColumnDropArea).call(this, true, draggable);
|
|
9815
9815
|
};
|
|
9816
9816
|
const endCb = () => {
|
|
9817
|
-
__classPrivateFieldGet$
|
|
9817
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hideShowColumnDropArea).call(this, false);
|
|
9818
9818
|
};
|
|
9819
9819
|
const dropCallbacks = {
|
|
9820
9820
|
drop: dropCb,
|
|
@@ -9823,14 +9823,14 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9823
9823
|
start: startCb,
|
|
9824
9824
|
end: endCb,
|
|
9825
9825
|
};
|
|
9826
|
-
for (let index = 0; index < __classPrivateFieldGet$
|
|
9827
|
-
const th = __classPrivateFieldGet$
|
|
9828
|
-
if (th && !__classPrivateFieldGet$
|
|
9829
|
-
__classPrivateFieldGet$
|
|
9830
|
-
__classPrivateFieldGet$
|
|
9826
|
+
for (let index = 0; index < __classPrivateFieldGet$4(this, _KupDataTable_thRefs, "f").length; index++) {
|
|
9827
|
+
const th = __classPrivateFieldGet$4(this, _KupDataTable_thRefs, "f")[index];
|
|
9828
|
+
if (th && !__classPrivateFieldGet$4(this, _KupDataTable_interactableDrag, "f").includes(th)) {
|
|
9829
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableDrag, "f").push(th);
|
|
9830
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.dropzone(th, {
|
|
9831
9831
|
accept: `[${kupDraggableColumnAttr}]`,
|
|
9832
9832
|
}, null, dropCallbacks);
|
|
9833
|
-
__classPrivateFieldGet$
|
|
9833
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.draggable(th, {
|
|
9834
9834
|
cursorChecker() {
|
|
9835
9835
|
return null;
|
|
9836
9836
|
},
|
|
@@ -9850,11 +9850,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9850
9850
|
const callbacks = {
|
|
9851
9851
|
move: moveCb,
|
|
9852
9852
|
};
|
|
9853
|
-
for (let index = 0; index < __classPrivateFieldGet$
|
|
9854
|
-
const th = __classPrivateFieldGet$
|
|
9855
|
-
if (th && !__classPrivateFieldGet$
|
|
9856
|
-
__classPrivateFieldGet$
|
|
9857
|
-
__classPrivateFieldGet$
|
|
9853
|
+
for (let index = 0; index < __classPrivateFieldGet$4(this, _KupDataTable_thRefs, "f").length; index++) {
|
|
9854
|
+
const th = __classPrivateFieldGet$4(this, _KupDataTable_thRefs, "f")[index];
|
|
9855
|
+
if (th && !__classPrivateFieldGet$4(this, _KupDataTable_interactableResize, "f").includes(th)) {
|
|
9856
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableResize, "f").push(th);
|
|
9857
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.resizable(th, {
|
|
9858
9858
|
allowFrom: '.header-cell__drag-handler',
|
|
9859
9859
|
edges: {
|
|
9860
9860
|
left: false,
|
|
@@ -9868,8 +9868,8 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9868
9868
|
}
|
|
9869
9869
|
}
|
|
9870
9870
|
if (this.dragEnabled) {
|
|
9871
|
-
for (let index = 0; index < __classPrivateFieldGet$
|
|
9872
|
-
const row = __classPrivateFieldGet$
|
|
9871
|
+
for (let index = 0; index < __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").length; index++) {
|
|
9872
|
+
const row = __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f")[index];
|
|
9873
9873
|
const dataCb = () => {
|
|
9874
9874
|
const cellEl = this.rootElement.shadowRoot.querySelector('td:hover');
|
|
9875
9875
|
return {
|
|
@@ -9882,9 +9882,9 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9882
9882
|
selectedRows: this.selectedRows,
|
|
9883
9883
|
};
|
|
9884
9884
|
};
|
|
9885
|
-
if (row && !__classPrivateFieldGet$
|
|
9886
|
-
__classPrivateFieldGet$
|
|
9887
|
-
__classPrivateFieldGet$
|
|
9885
|
+
if (row && !__classPrivateFieldGet$4(this, _KupDataTable_interactableDrag, "f").includes(row)) {
|
|
9886
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableDrag, "f").push(row);
|
|
9887
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.draggable(row, {
|
|
9888
9888
|
allowFrom: 'td',
|
|
9889
9889
|
cursorChecker() {
|
|
9890
9890
|
return null;
|
|
@@ -9899,11 +9899,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9899
9899
|
const dataCb = () => {
|
|
9900
9900
|
const cell = this.rootElement.shadowRoot.querySelector('td:hover');
|
|
9901
9901
|
if (!cell) {
|
|
9902
|
-
__classPrivateFieldGet$
|
|
9902
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, "Couldn't find cell hovered to retrieve dropzone informations!", KupDebugCategory.WARNING);
|
|
9903
9903
|
return;
|
|
9904
9904
|
}
|
|
9905
|
-
const path = __classPrivateFieldGet$
|
|
9906
|
-
const receivingDetails = __classPrivateFieldGet$
|
|
9905
|
+
const path = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").getEventPath(cell, this.rootElement);
|
|
9906
|
+
const receivingDetails = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, path);
|
|
9907
9907
|
return {
|
|
9908
9908
|
cell: receivingDetails.cell,
|
|
9909
9909
|
column: receivingDetails.column,
|
|
@@ -9911,11 +9911,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9911
9911
|
row: receivingDetails.row,
|
|
9912
9912
|
};
|
|
9913
9913
|
};
|
|
9914
|
-
for (let index = 0; index < __classPrivateFieldGet$
|
|
9915
|
-
const row = __classPrivateFieldGet$
|
|
9916
|
-
if (row && !__classPrivateFieldGet$
|
|
9917
|
-
__classPrivateFieldGet$
|
|
9918
|
-
__classPrivateFieldGet$
|
|
9914
|
+
for (let index = 0; index < __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").length; index++) {
|
|
9915
|
+
const row = __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f")[index];
|
|
9916
|
+
if (row && !__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").includes(row)) {
|
|
9917
|
+
__classPrivateFieldGet$4(this, _KupDataTable_interactableDrop, "f").push(row);
|
|
9918
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").interact.dropzone(row, {
|
|
9919
9919
|
accept: `[${kupDraggableCellAttr}]`,
|
|
9920
9920
|
}, {
|
|
9921
9921
|
callback: dataCb,
|
|
@@ -9929,44 +9929,44 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9929
9929
|
if (this.headerIsPersistent &&
|
|
9930
9930
|
this.tableHeight === undefined &&
|
|
9931
9931
|
this.tableWidth === undefined) {
|
|
9932
|
-
__classPrivateFieldGet$
|
|
9933
|
-
__classPrivateFieldGet$
|
|
9932
|
+
__classPrivateFieldGet$4(this, _KupDataTable_intObserver, "f").observe(__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"));
|
|
9933
|
+
__classPrivateFieldGet$4(this, _KupDataTable_intObserver, "f").observe(__classPrivateFieldGet$4(this, _KupDataTable_theadRef, "f"));
|
|
9934
9934
|
}
|
|
9935
9935
|
}, _KupDataTable_didRenderObservers = function _KupDataTable_didRenderObservers() {
|
|
9936
|
-
if (__classPrivateFieldGet$
|
|
9937
|
-
__classPrivateFieldGet$
|
|
9936
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_paginatedRowsLength, "f") < __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f") && this.lazyLoadRows) {
|
|
9937
|
+
__classPrivateFieldGet$4(this, _KupDataTable_intObserver, "f").observe(__classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f")[__classPrivateFieldGet$4(this, _KupDataTable_paginatedRowsLength, "f") - 1]);
|
|
9938
9938
|
}
|
|
9939
9939
|
}, _KupDataTable_didLoadEventHandling = function _KupDataTable_didLoadEventHandling() {
|
|
9940
|
-
__classPrivateFieldGet$
|
|
9940
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f").addEventListener('scroll', () => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_scrollStickyHeader).call(this));
|
|
9941
9941
|
}, _KupDataTable_scrollStickyHeader = function _KupDataTable_scrollStickyHeader() {
|
|
9942
|
-
if (!__classPrivateFieldGet$
|
|
9942
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f")) {
|
|
9943
9943
|
return;
|
|
9944
9944
|
}
|
|
9945
|
-
__classPrivateFieldGet$
|
|
9945
|
+
__classPrivateFieldGet$4(this, _KupDataTable_stickyTheadRef, "f").scrollLeft = __classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f").scrollLeft;
|
|
9946
9946
|
}, _KupDataTable_checkScrollOnHover = function _KupDataTable_checkScrollOnHover() {
|
|
9947
|
-
if (!__classPrivateFieldGet$
|
|
9947
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").scrollOnHover.isRegistered(__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f"))) {
|
|
9948
9948
|
if (this.scrollOnHover &&
|
|
9949
9949
|
this.tableHeight === undefined &&
|
|
9950
9950
|
this.tableWidth === undefined) {
|
|
9951
|
-
__classPrivateFieldGet$
|
|
9951
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").scrollOnHover.register(__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f"));
|
|
9952
9952
|
}
|
|
9953
9953
|
}
|
|
9954
9954
|
else {
|
|
9955
9955
|
if (!this.scrollOnHover &&
|
|
9956
9956
|
(this.tableHeight !== undefined ||
|
|
9957
9957
|
this.tableWidth !== undefined)) {
|
|
9958
|
-
__classPrivateFieldGet$
|
|
9958
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").scrollOnHover.unregister(__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f"));
|
|
9959
9959
|
}
|
|
9960
9960
|
}
|
|
9961
9961
|
}, _KupDataTable_customizePanelPosition = function _KupDataTable_customizePanelPosition() {
|
|
9962
|
-
if (__classPrivateFieldGet$
|
|
9963
|
-
!__classPrivateFieldGet$
|
|
9964
|
-
__classPrivateFieldGet$
|
|
9962
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_customizeTopButtonRef, "f") &&
|
|
9963
|
+
!__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.isRegistered(__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f"))) {
|
|
9964
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f"), __classPrivateFieldGet$4(this, _KupDataTable_customizeTopButtonRef, "f"), 0, KupDynamicPositionPlacement.BOTTOM, true);
|
|
9965
9965
|
}
|
|
9966
9966
|
}, _KupDataTable_rowsPointLength = function _KupDataTable_rowsPointLength() {
|
|
9967
|
-
return __classPrivateFieldGet$
|
|
9967
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable__rowsLength).call(this, __classPrivateFieldGet$4(this, _KupDataTable_rows, "f"));
|
|
9968
9968
|
}, _KupDataTable_paginatedRowsPointLength = function _KupDataTable_paginatedRowsPointLength() {
|
|
9969
|
-
return __classPrivateFieldGet$
|
|
9969
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable__rowsLength).call(this, __classPrivateFieldGet$4(this, _KupDataTable_paginatedRows, "f"));
|
|
9970
9970
|
}, _KupDataTable__rowsLength = function _KupDataTable__rowsLength(r) {
|
|
9971
9971
|
if (r == null) {
|
|
9972
9972
|
return 0;
|
|
@@ -9979,14 +9979,14 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
9979
9979
|
}
|
|
9980
9980
|
count += 1;
|
|
9981
9981
|
if (row.group != null) {
|
|
9982
|
-
count += __classPrivateFieldGet$
|
|
9982
|
+
count += __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable__rowsLength).call(this, row.group.children);
|
|
9983
9983
|
}
|
|
9984
9984
|
}
|
|
9985
9985
|
return count;
|
|
9986
9986
|
}, _KupDataTable_setDynPosElements = function _KupDataTable_setDynPosElements() {
|
|
9987
9987
|
// Column menu
|
|
9988
|
-
if (__classPrivateFieldGet$
|
|
9989
|
-
__classPrivateFieldGet$
|
|
9988
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f") && __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").data) {
|
|
9989
|
+
__classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").data = __classPrivateFieldGet$4(this, _KupDataTable_columnMenuInstance, "f").prepData(this, getColumnByName(this.getVisibleColumns(), this.columnMenuAnchor), __classPrivateFieldGet$4(this, _KupDataTable_columnMenuCard, "f").data);
|
|
9990
9990
|
}
|
|
9991
9991
|
}, _KupDataTable_resetSelectedRows = function _KupDataTable_resetSelectedRows() {
|
|
9992
9992
|
if (this.getRows().length === 0)
|
|
@@ -10010,7 +10010,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10010
10010
|
return undefined;
|
|
10011
10011
|
}
|
|
10012
10012
|
}, _KupDataTable_rowDetail = function _KupDataTable_rowDetail(row, x, y) {
|
|
10013
|
-
const transposedData = __classPrivateFieldGet$
|
|
10013
|
+
const transposedData = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getTransposedData).call(this);
|
|
10014
10014
|
const cardData = {
|
|
10015
10015
|
button: [
|
|
10016
10016
|
{
|
|
@@ -10039,7 +10039,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10039
10039
|
showHeader: false,
|
|
10040
10040
|
},
|
|
10041
10041
|
],
|
|
10042
|
-
text: [__classPrivateFieldGet$
|
|
10042
|
+
text: [__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.DETAIL)],
|
|
10043
10043
|
};
|
|
10044
10044
|
const columns = cardData.datatable[0].data.columns;
|
|
10045
10045
|
const rows = cardData.datatable[0].data.rows;
|
|
@@ -10063,7 +10063,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10063
10063
|
currentColumn.visible = true;
|
|
10064
10064
|
}
|
|
10065
10065
|
else {
|
|
10066
|
-
__classPrivateFieldGet$
|
|
10066
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Invalid column name on row ID (' +
|
|
10067
10067
|
row.id +
|
|
10068
10068
|
"), couldn't set current record!", KupDebugCategory.WARNING);
|
|
10069
10069
|
}
|
|
@@ -10072,7 +10072,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10072
10072
|
for (let index = 0; index < rows.length; index++) {
|
|
10073
10073
|
const column = this.data.columns.find((x) => x.name === rows[index].transposedColumnName);
|
|
10074
10074
|
if (!column) {
|
|
10075
|
-
__classPrivateFieldGet$
|
|
10075
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").debug.logMessage(this, 'Column not found on row name (' + column + ')!', KupDebugCategory.WARNING);
|
|
10076
10076
|
return;
|
|
10077
10077
|
}
|
|
10078
10078
|
const editable = rows[index].cells[row.id].isEditable
|
|
@@ -10096,8 +10096,8 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10096
10096
|
resource: editable ? 'edit-key' : 'key-variant',
|
|
10097
10097
|
},
|
|
10098
10098
|
title: editable
|
|
10099
|
-
? __classPrivateFieldGet$
|
|
10100
|
-
: __classPrivateFieldGet$
|
|
10099
|
+
? __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.EDITABLE_KEY)
|
|
10100
|
+
: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.KEY),
|
|
10101
10101
|
value: editable ? 'edit-key' : 'key-variant',
|
|
10102
10102
|
};
|
|
10103
10103
|
}
|
|
@@ -10112,7 +10112,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10112
10112
|
color: `var(${KupThemeColorValues.TEXT})`,
|
|
10113
10113
|
resource: 'pencil',
|
|
10114
10114
|
},
|
|
10115
|
-
title: __classPrivateFieldGet$
|
|
10115
|
+
title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EDITABLE_FIELD),
|
|
10116
10116
|
value: 'pencil',
|
|
10117
10117
|
};
|
|
10118
10118
|
}
|
|
@@ -10134,35 +10134,35 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10134
10134
|
}
|
|
10135
10135
|
rows[index].cells[iconColumn.toUpperCase()] = iconCell;
|
|
10136
10136
|
}
|
|
10137
|
-
if (!__classPrivateFieldGet$
|
|
10137
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f")) {
|
|
10138
10138
|
__classPrivateFieldSet$2(this, _KupDataTable_detailCard, document.createElement('kup-card'), "f");
|
|
10139
|
-
__classPrivateFieldGet$
|
|
10140
|
-
__classPrivateFieldGet$
|
|
10141
|
-
__classPrivateFieldGet$
|
|
10142
|
-
__classPrivateFieldGet$
|
|
10139
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").layoutFamily = KupCardFamily.DIALOG;
|
|
10140
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").layoutNumber = 4;
|
|
10141
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").sizeX = 'auto';
|
|
10142
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").sizeY = 'auto';
|
|
10143
10143
|
}
|
|
10144
10144
|
else {
|
|
10145
|
-
const children = Array.prototype.slice.call(__classPrivateFieldGet$
|
|
10145
|
+
const children = Array.prototype.slice.call(__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").children, 0);
|
|
10146
10146
|
for (let index = 0; index < children.length; index++) {
|
|
10147
10147
|
children[index].remove();
|
|
10148
10148
|
}
|
|
10149
10149
|
}
|
|
10150
|
-
__classPrivateFieldGet$
|
|
10151
|
-
__classPrivateFieldGet$
|
|
10152
|
-
__classPrivateFieldGet$
|
|
10153
|
-
__classPrivateFieldGet$
|
|
10154
|
-
__classPrivateFieldGet$
|
|
10155
|
-
__classPrivateFieldGet$
|
|
10156
|
-
__classPrivateFieldGet$
|
|
10157
|
-
this.rootElement.shadowRoot.append(__classPrivateFieldGet$
|
|
10150
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").data = cardData;
|
|
10151
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").style.position = 'fixed';
|
|
10152
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").style.left = '0';
|
|
10153
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").style.top = '0';
|
|
10154
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").setAttribute('data-x', x.toString());
|
|
10155
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").setAttribute('data-y', y.toString());
|
|
10156
|
+
__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f").style.transform = 'translate(' + x + 'px,' + y + 'px)';
|
|
10157
|
+
this.rootElement.shadowRoot.append(__classPrivateFieldGet$4(this, _KupDataTable_detailCard, "f"));
|
|
10158
10158
|
}, _KupDataTable_rowInsertForm = function _KupDataTable_rowInsertForm() {
|
|
10159
10159
|
const CARD_WIDTH = 400;
|
|
10160
10160
|
const CARD_HEIGHT = 400;
|
|
10161
10161
|
__classPrivateFieldSet$2(this, _KupDataTable_insertCard, document.createElement('kup-card'), "f");
|
|
10162
|
-
__classPrivateFieldGet$
|
|
10163
|
-
__classPrivateFieldGet$
|
|
10164
|
-
__classPrivateFieldGet$
|
|
10165
|
-
__classPrivateFieldGet$
|
|
10162
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").layoutFamily = KupCardFamily.FREE;
|
|
10163
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").layoutNumber = 1;
|
|
10164
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").sizeX = CARD_WIDTH + 'px';
|
|
10165
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").sizeY = CARD_HEIGHT + 'px';
|
|
10166
10166
|
const style = document.createElement('style');
|
|
10167
10167
|
style.innerText =
|
|
10168
10168
|
'kup-form { max-height: 40vh; overflow: auto; } .page-wrapper { display: grid; } ' +
|
|
@@ -10170,24 +10170,24 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10170
10170
|
'.message-wrapper { display: none; justify-content: start; padding-top: 5px; padding-bottom: 5px; } ' +
|
|
10171
10171
|
'.errorIcon { --kup-icon-color: var(--kup-danger-color); } ' +
|
|
10172
10172
|
'.message { background-color: var(--kup-danger-color); color: white; padding: 3px; } ';
|
|
10173
|
-
__classPrivateFieldGet$
|
|
10173
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").append(style);
|
|
10174
10174
|
const pageWrapper = document.createElement('div');
|
|
10175
10175
|
pageWrapper.className = 'page-wrapper';
|
|
10176
10176
|
const buttonWrapper = document.createElement('div');
|
|
10177
10177
|
buttonWrapper.className = 'button-wrapper';
|
|
10178
10178
|
const cancel = document.createElement('kup-button');
|
|
10179
10179
|
const confirm = document.createElement('kup-button');
|
|
10180
|
-
cancel.id = __classPrivateFieldGet$
|
|
10180
|
+
cancel.id = __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_CANCEL_ID, "f");
|
|
10181
10181
|
cancel.icon = 'clear';
|
|
10182
|
-
cancel.label = __classPrivateFieldGet$
|
|
10182
|
+
cancel.label = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.ABORT);
|
|
10183
10183
|
cancel.styling = FButtonStyling.FLAT;
|
|
10184
10184
|
cancel.addEventListener('kup-button-click', () => {
|
|
10185
|
-
__classPrivateFieldGet$
|
|
10185
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").remove();
|
|
10186
10186
|
__classPrivateFieldSet$2(this, _KupDataTable_insertCard, null, "f");
|
|
10187
10187
|
});
|
|
10188
|
-
confirm.id = __classPrivateFieldGet$
|
|
10188
|
+
confirm.id = __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_SUBMIT_ID, "f");
|
|
10189
10189
|
confirm.icon = 'check';
|
|
10190
|
-
confirm.label = __classPrivateFieldGet$
|
|
10190
|
+
confirm.label = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.CONFIRM);
|
|
10191
10191
|
let innerComp = document.createElement('kup-spinner');
|
|
10192
10192
|
innerComp.slot = 'spinner';
|
|
10193
10193
|
innerComp.dimensions = '0.6em';
|
|
@@ -10206,7 +10206,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10206
10206
|
buttonWrapper.append(cancel);
|
|
10207
10207
|
buttonWrapper.append(confirm);
|
|
10208
10208
|
const form = document.createElement('kup-form');
|
|
10209
|
-
form.id = __classPrivateFieldGet$
|
|
10209
|
+
form.id = __classPrivateFieldGet$4(this, _KupDataTable_FIELDS_FORM_ID, "f");
|
|
10210
10210
|
const row = {
|
|
10211
10211
|
cells: {},
|
|
10212
10212
|
id: '0',
|
|
@@ -10226,7 +10226,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10226
10226
|
};
|
|
10227
10227
|
const messageWrapper = document.createElement('div');
|
|
10228
10228
|
messageWrapper.className = 'message-wrapper';
|
|
10229
|
-
messageWrapper.id = __classPrivateFieldGet$
|
|
10229
|
+
messageWrapper.id = __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_WRAPPER_ID, "f");
|
|
10230
10230
|
const icon = document.createElement('kup-image');
|
|
10231
10231
|
icon.className = 'errorIcon';
|
|
10232
10232
|
icon.resource = 'cancel';
|
|
@@ -10235,43 +10235,43 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10235
10235
|
messageWrapper.append(icon);
|
|
10236
10236
|
const message = document.createElement('span');
|
|
10237
10237
|
message.className = 'message';
|
|
10238
|
-
message.id = __classPrivateFieldGet$
|
|
10238
|
+
message.id = __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_ID, "f");
|
|
10239
10239
|
let msg = '';
|
|
10240
10240
|
message.innerText = msg;
|
|
10241
10241
|
messageWrapper.append(message);
|
|
10242
10242
|
pageWrapper.append(messageWrapper);
|
|
10243
10243
|
pageWrapper.append(form);
|
|
10244
10244
|
pageWrapper.append(buttonWrapper);
|
|
10245
|
-
__classPrivateFieldGet$
|
|
10246
|
-
__classPrivateFieldGet$
|
|
10247
|
-
this.rootElement.shadowRoot.append(__classPrivateFieldGet$
|
|
10245
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").append(pageWrapper);
|
|
10246
|
+
__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f").data = {};
|
|
10247
|
+
this.rootElement.shadowRoot.append(__classPrivateFieldGet$4(this, _KupDataTable_insertCard, "f"));
|
|
10248
10248
|
}, _KupDataTable_rowsDelete = function _KupDataTable_rowsDelete() {
|
|
10249
10249
|
const createDeleteCard = () => {
|
|
10250
10250
|
__classPrivateFieldSet$2(this, _KupDataTable_confirmDeleteDialog, document.createElement('kup-dialog'), "f");
|
|
10251
10251
|
__classPrivateFieldSet$2(this, _KupDataTable_confirmDeleteCard, document.createElement('kup-card'), "f");
|
|
10252
|
-
__classPrivateFieldGet$
|
|
10253
|
-
__classPrivateFieldGet$
|
|
10254
|
-
__classPrivateFieldGet$
|
|
10255
|
-
__classPrivateFieldGet$
|
|
10252
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").layoutFamily = KupCardFamily.FREE;
|
|
10253
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").layoutNumber = 1;
|
|
10254
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").sizeX = 'auto';
|
|
10255
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").sizeY = 'auto';
|
|
10256
10256
|
const style = document.createElement('style');
|
|
10257
10257
|
style.innerText =
|
|
10258
10258
|
'.button-wrapper, .message-wrapper { display: flex; justify-content: space-around; z-index: var(--kup-card-zindex); } .message-wrapper { padding-bottom: 20px; }';
|
|
10259
10259
|
const messageWrapper = document.createElement('div');
|
|
10260
10260
|
messageWrapper.className = 'message-wrapper';
|
|
10261
|
-
messageWrapper.id = __classPrivateFieldGet$
|
|
10261
|
+
messageWrapper.id = __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_WRAPPER_ID, "f");
|
|
10262
10262
|
const message = document.createElement('span');
|
|
10263
10263
|
message.className = 'message';
|
|
10264
|
-
message.id = __classPrivateFieldGet$
|
|
10265
|
-
let msg = __classPrivateFieldGet$
|
|
10264
|
+
message.id = __classPrivateFieldGet$4(this, _KupDataTable_MESSAGE_ID, "f");
|
|
10265
|
+
let msg = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.CONFIRM_DELETE_X_ROWS);
|
|
10266
10266
|
msg = msg.replace('{0}', this.selectedRows.length + '');
|
|
10267
10267
|
message.innerText = msg;
|
|
10268
10268
|
messageWrapper.append(message);
|
|
10269
10269
|
const buttonWrapper = document.createElement('div');
|
|
10270
10270
|
buttonWrapper.className = 'button-wrapper';
|
|
10271
10271
|
const confirm = document.createElement('kup-button');
|
|
10272
|
-
confirm.id = __classPrivateFieldGet$
|
|
10272
|
+
confirm.id = __classPrivateFieldGet$4(this, _KupDataTable_BUTTON_SUBMIT_ID, "f");
|
|
10273
10273
|
confirm.icon = 'check';
|
|
10274
|
-
confirm.label = __classPrivateFieldGet$
|
|
10274
|
+
confirm.label = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.CONFIRM);
|
|
10275
10275
|
let innerComp = document.createElement('kup-spinner');
|
|
10276
10276
|
innerComp.slot = 'spinner';
|
|
10277
10277
|
innerComp.dimensions = '0.6em';
|
|
@@ -10286,17 +10286,17 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10286
10286
|
});
|
|
10287
10287
|
});
|
|
10288
10288
|
buttonWrapper.append(confirm);
|
|
10289
|
-
__classPrivateFieldGet$
|
|
10290
|
-
__classPrivateFieldGet$
|
|
10291
|
-
__classPrivateFieldGet$
|
|
10292
|
-
__classPrivateFieldGet$
|
|
10293
|
-
__classPrivateFieldGet$
|
|
10294
|
-
document.querySelector('body').append(__classPrivateFieldGet$
|
|
10289
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").append(style);
|
|
10290
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").append(messageWrapper);
|
|
10291
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").append(buttonWrapper);
|
|
10292
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f").data = {};
|
|
10293
|
+
__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteDialog, "f").append(__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteCard, "f"));
|
|
10294
|
+
document.querySelector('body').append(__classPrivateFieldGet$4(this, _KupDataTable_confirmDeleteDialog, "f"));
|
|
10295
10295
|
};
|
|
10296
10296
|
const insertRowsIds = [];
|
|
10297
10297
|
const startingRows = [];
|
|
10298
10298
|
this.selectedRows.forEach((row) => {
|
|
10299
|
-
if (row.id.indexOf(__classPrivateFieldGet$
|
|
10299
|
+
if (row.id.indexOf(__classPrivateFieldGet$4(this, _KupDataTable_INSERT_PREFIX, "f")) > -1) {
|
|
10300
10300
|
insertRowsIds.push(row.id);
|
|
10301
10301
|
}
|
|
10302
10302
|
else {
|
|
@@ -10401,15 +10401,15 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10401
10401
|
tr: tr ? tr : null,
|
|
10402
10402
|
};
|
|
10403
10403
|
}, _KupDataTable_clickHandler = function _KupDataTable_clickHandler(e) {
|
|
10404
|
-
const details = __classPrivateFieldGet$
|
|
10404
|
+
const details = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").getEventPath(e.target, this.rootElement), e);
|
|
10405
10405
|
if (details.area === 'header') {
|
|
10406
10406
|
if (details.th && details.column) {
|
|
10407
10407
|
if (details.filterRemove) {
|
|
10408
|
-
__classPrivateFieldGet$
|
|
10408
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onRemoveFilter).call(this, details.column);
|
|
10409
10409
|
return details;
|
|
10410
10410
|
}
|
|
10411
10411
|
else if (this.sortEnabled) {
|
|
10412
|
-
__classPrivateFieldGet$
|
|
10412
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onColumnSort).call(this, e, details.column.name);
|
|
10413
10413
|
return details;
|
|
10414
10414
|
}
|
|
10415
10415
|
}
|
|
@@ -10424,22 +10424,22 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10424
10424
|
}
|
|
10425
10425
|
details.tr.classList.add('focus');
|
|
10426
10426
|
if (e.ctrlKey || e.metaKey) {
|
|
10427
|
-
__classPrivateFieldGet$
|
|
10427
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_rowDetail).call(this, Object.assign({}, details.row), e.clientX, e.clientY);
|
|
10428
10428
|
return details;
|
|
10429
10429
|
}
|
|
10430
10430
|
}
|
|
10431
10431
|
if (details.tr && details.row && details.isGroupRow) {
|
|
10432
|
-
__classPrivateFieldGet$
|
|
10432
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onRowExpand).call(this, details.row);
|
|
10433
10433
|
return details;
|
|
10434
10434
|
}
|
|
10435
10435
|
if (details.td && details.row && !details.textfield) {
|
|
10436
|
-
__classPrivateFieldGet$
|
|
10436
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onRowClick).call(this, details.row, details.td, true);
|
|
10437
10437
|
return details;
|
|
10438
10438
|
}
|
|
10439
10439
|
}
|
|
10440
10440
|
return details;
|
|
10441
10441
|
}, _KupDataTable_contextMenuHandler = function _KupDataTable_contextMenuHandler(e) {
|
|
10442
|
-
const details = __classPrivateFieldGet$
|
|
10442
|
+
const details = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").getEventPath(e.target, this.rootElement), e);
|
|
10443
10443
|
if (details.area === 'header') {
|
|
10444
10444
|
if (details.th && details.column) {
|
|
10445
10445
|
this.openColumnMenu(details.column.name);
|
|
@@ -10449,34 +10449,34 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10449
10449
|
else if (details.area === 'footer') {
|
|
10450
10450
|
if (details.td && details.column) {
|
|
10451
10451
|
__classPrivateFieldSet$2(this, _KupDataTable_totalMenuCoords, { x: e.clientX, y: e.clientY }, "f");
|
|
10452
|
-
__classPrivateFieldGet$
|
|
10452
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onTotalMenuOpen).call(this, details.column);
|
|
10453
10453
|
return details;
|
|
10454
10454
|
}
|
|
10455
10455
|
}
|
|
10456
10456
|
return details;
|
|
10457
10457
|
}, _KupDataTable_dblClickHandler = function _KupDataTable_dblClickHandler(e) {
|
|
10458
|
-
const details = __classPrivateFieldGet$
|
|
10458
|
+
const details = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getEventDetails).call(this, __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").getEventPath(e.target, this.rootElement), e);
|
|
10459
10459
|
if (details.area === 'body') {
|
|
10460
10460
|
if (this.selection == SelectionMode.MULTIPLE) {
|
|
10461
|
-
__classPrivateFieldGet$
|
|
10461
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_resetSelectedRows).call(this);
|
|
10462
10462
|
}
|
|
10463
10463
|
if (this.selection == SelectionMode.SINGLE ||
|
|
10464
10464
|
this.selection == SelectionMode.MULTIPLE) {
|
|
10465
|
-
__classPrivateFieldGet$
|
|
10465
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onRowClick).call(this, details.row, details.td, false);
|
|
10466
10466
|
}
|
|
10467
10467
|
}
|
|
10468
10468
|
return details;
|
|
10469
10469
|
}, _KupDataTable_initRows = function _KupDataTable_initRows() {
|
|
10470
|
-
__classPrivateFieldGet$
|
|
10471
|
-
__classPrivateFieldSet$2(this, _KupDataTable_footer, calcTotals(normalizeRows(this.getColumns(), __classPrivateFieldGet$
|
|
10472
|
-
__classPrivateFieldGet$
|
|
10473
|
-
__classPrivateFieldGet$
|
|
10474
|
-
__classPrivateFieldGet$
|
|
10475
|
-
__classPrivateFieldSet$2(this, _KupDataTable_paginatedRows, paginateRows(__classPrivateFieldGet$
|
|
10476
|
-
__classPrivateFieldSet$2(this, _KupDataTable_paginatedRowsLength, __classPrivateFieldGet$
|
|
10470
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_filterRows).call(this);
|
|
10471
|
+
__classPrivateFieldSet$2(this, _KupDataTable_footer, calcTotals(normalizeRows(this.getColumns(), __classPrivateFieldGet$4(this, _KupDataTable_rows, "f")), this.totals), "f");
|
|
10472
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_groupRows).call(this);
|
|
10473
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_sortRows).call(this);
|
|
10474
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_adjustPaginator).call(this);
|
|
10475
|
+
__classPrivateFieldSet$2(this, _KupDataTable_paginatedRows, paginateRows(__classPrivateFieldGet$4(this, _KupDataTable_rows, "f"), this.currentPage, this.currentRowsPerPage, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)), "f");
|
|
10476
|
+
__classPrivateFieldSet$2(this, _KupDataTable_paginatedRowsLength, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_paginatedRowsPointLength).call(this), "f");
|
|
10477
10477
|
}, _KupDataTable_filterRows = function _KupDataTable_filterRows() {
|
|
10478
10478
|
__classPrivateFieldSet$2(this, _KupDataTable_rows, filterRows(this.getRows(), this.filters, this.globalFilterValue, this.getColumns()), "f");
|
|
10479
|
-
__classPrivateFieldSet$2(this, _KupDataTable_rowsLength, __classPrivateFieldGet$
|
|
10479
|
+
__classPrivateFieldSet$2(this, _KupDataTable_rowsLength, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_rowsPointLength).call(this), "f");
|
|
10480
10480
|
}, _KupDataTable_isGrouping = function _KupDataTable_isGrouping() {
|
|
10481
10481
|
return this.groups && this.groups.length > 0;
|
|
10482
10482
|
}, _KupDataTable_hasRowActions = function _KupDataTable_hasRowActions() {
|
|
@@ -10490,19 +10490,19 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10490
10490
|
}, _KupDataTable_hasTotals = function _KupDataTable_hasTotals() {
|
|
10491
10491
|
return this.totals && Object.keys(this.totals).length > 0;
|
|
10492
10492
|
}, _KupDataTable_tableHasAutoWidth = function _KupDataTable_tableHasAutoWidth() {
|
|
10493
|
-
if (!__classPrivateFieldGet$
|
|
10493
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")) {
|
|
10494
10494
|
return;
|
|
10495
10495
|
}
|
|
10496
10496
|
const visibleCols = this.getVisibleColumns();
|
|
10497
10497
|
// Before checking each column, controls that visible columns are as many as items with custom sizes.
|
|
10498
10498
|
// If there are more visible columns, it means that the width of the table will be set to auto.
|
|
10499
|
-
if (visibleCols.length <= __classPrivateFieldGet$
|
|
10499
|
+
if (visibleCols.length <= __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f").length) {
|
|
10500
10500
|
let found = false;
|
|
10501
10501
|
// Each visible column must have its own width for the table to have a auto width
|
|
10502
10502
|
for (let i = 0; i < visibleCols.length; i++) {
|
|
10503
10503
|
found = false;
|
|
10504
|
-
for (let j = 0; j < __classPrivateFieldGet$
|
|
10505
|
-
if (visibleCols[i].name === __classPrivateFieldGet$
|
|
10504
|
+
for (let j = 0; j < __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f").length; j++) {
|
|
10505
|
+
if (visibleCols[i].name === __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")[j].name) {
|
|
10506
10506
|
found = true;
|
|
10507
10507
|
break;
|
|
10508
10508
|
}
|
|
@@ -10515,8 +10515,8 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10515
10515
|
}
|
|
10516
10516
|
return false;
|
|
10517
10517
|
}, _KupDataTable_forceGroupExpansion = function _KupDataTable_forceGroupExpansion() {
|
|
10518
|
-
__classPrivateFieldGet$
|
|
10519
|
-
__classPrivateFieldGet$
|
|
10518
|
+
__classPrivateFieldGet$4(this, _KupDataTable_rows, "f").forEach((row) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_forceRowGroupExpansion).call(this, row));
|
|
10519
|
+
__classPrivateFieldGet$4(this, _KupDataTable_paginatedRows, "f").forEach((row) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_forceRowGroupExpansion).call(this, row));
|
|
10520
10520
|
}, _KupDataTable_forceRowGroupExpansion = function _KupDataTable_forceRowGroupExpansion(row) {
|
|
10521
10521
|
// check if row is group
|
|
10522
10522
|
if (!row.group) {
|
|
@@ -10537,10 +10537,10 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10537
10537
|
}
|
|
10538
10538
|
this.groupState[row.group.id] = groupState;
|
|
10539
10539
|
if (row.group.children) {
|
|
10540
|
-
row.group.children.forEach((childRow) => __classPrivateFieldGet$
|
|
10540
|
+
row.group.children.forEach((childRow) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_forceRowGroupExpansion).call(this, childRow));
|
|
10541
10541
|
}
|
|
10542
10542
|
}, _KupDataTable_adjustPaginator = function _KupDataTable_adjustPaginator() {
|
|
10543
|
-
const numberOfRows = __classPrivateFieldGet$
|
|
10543
|
+
const numberOfRows = __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f");
|
|
10544
10544
|
// check if current page is valid
|
|
10545
10545
|
const numberOfPages = Math.ceil(numberOfRows / this.currentRowsPerPage);
|
|
10546
10546
|
if (this.currentPage > numberOfPages) {
|
|
@@ -10549,7 +10549,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10549
10549
|
this.resetCurrentPage();
|
|
10550
10550
|
}
|
|
10551
10551
|
}, _KupDataTable_composeFixedCellStyleAndClass = function _KupDataTable_composeFixedCellStyleAndClass(columnCssIndex, rowCssIndex, extraCellsCount = 0) {
|
|
10552
|
-
if (__classPrivateFieldGet$
|
|
10552
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)) {
|
|
10553
10553
|
return undefined;
|
|
10554
10554
|
}
|
|
10555
10555
|
//-- Controls if there are fixed rows or columns --
|
|
@@ -10586,20 +10586,20 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10586
10586
|
}, _KupDataTable_updateFixedRowsAndColumnsCssVariables = function _KupDataTable_updateFixedRowsAndColumnsCssVariables() {
|
|
10587
10587
|
// [ffbf] - Using getBoundingClientRect is mandatory since Firefox return a wrong value for ele.offsetHeight and witdh values
|
|
10588
10588
|
// When grouping, the fixed rows and columns are not sticky
|
|
10589
|
-
if (__classPrivateFieldGet$
|
|
10589
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this) || !__classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f"))
|
|
10590
10590
|
return false;
|
|
10591
10591
|
let toRet = false;
|
|
10592
10592
|
if (this.fixedRows >= 1) {
|
|
10593
|
-
let currentRow = __classPrivateFieldGet$
|
|
10593
|
+
let currentRow = __classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").querySelector('tbody > tr:first-of-type');
|
|
10594
10594
|
// The height must start from the height of the header. BUT not on Safari.
|
|
10595
10595
|
// Safari handles the sticky position on the tables in a different way, making it start from the tbody element
|
|
10596
10596
|
// and not on the table with a specified position of sticky. There fore in that case we must set initial height to 0.
|
|
10597
|
-
let previousHeight = !__classPrivateFieldGet$
|
|
10598
|
-
? __classPrivateFieldGet$
|
|
10597
|
+
let previousHeight = !__classPrivateFieldGet$4(this, _KupDataTable_isSafariBrowser, "f")
|
|
10598
|
+
? __classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").querySelector('thead > tr:first-of-type > th:first-of-type').getBoundingClientRect().height // [ffbf]
|
|
10599
10599
|
: 0;
|
|
10600
10600
|
// [CSSCount] - I must start from 1 since we are referencing html elements e not array (with CSS selectors starting from 1)
|
|
10601
10601
|
for (let i = 1; i <= this.fixedRows && currentRow; i++) {
|
|
10602
|
-
__classPrivateFieldGet$
|
|
10602
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f").style.setProperty(FixedCellsCSSVarsBase.rows + i, previousHeight + 'px');
|
|
10603
10603
|
previousHeight += currentRow.children[0].getBoundingClientRect().height; // [ffbf]
|
|
10604
10604
|
currentRow =
|
|
10605
10605
|
currentRow.nextElementSibling;
|
|
@@ -10607,14 +10607,14 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10607
10607
|
toRet = true;
|
|
10608
10608
|
}
|
|
10609
10609
|
if (this.fixedColumns >= 1) {
|
|
10610
|
-
let currentCell = __classPrivateFieldGet$
|
|
10610
|
+
let currentCell = __classPrivateFieldGet$4(this, _KupDataTable_tableRef, "f").querySelector('tbody > tr:first-of-type > td:first-of-type');
|
|
10611
10611
|
let previousWidth = 0;
|
|
10612
10612
|
const totalFixedColumns = this.fixedColumns +
|
|
10613
|
-
(__classPrivateFieldGet$
|
|
10613
|
+
(__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this) ? 1 : 0) +
|
|
10614
10614
|
(this.selection === SelectionMode.MULTIPLE_CHECKBOX ? 1 : 0);
|
|
10615
10615
|
// @See [CSSCount]
|
|
10616
10616
|
for (let i = 1; i <= totalFixedColumns && currentCell; i++) {
|
|
10617
|
-
__classPrivateFieldGet$
|
|
10617
|
+
__classPrivateFieldGet$4(this, _KupDataTable_tableAreaRef, "f").style.setProperty(FixedCellsCSSVarsBase.columns + i, previousWidth + 'px');
|
|
10618
10618
|
previousWidth += currentCell.getBoundingClientRect().width; // [ffbf]
|
|
10619
10619
|
currentCell =
|
|
10620
10620
|
currentCell.nextElementSibling;
|
|
@@ -10662,10 +10662,10 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10662
10662
|
// resetting current page
|
|
10663
10663
|
this.resetCurrentPage();
|
|
10664
10664
|
const newFilters = Object.assign({}, this.filters);
|
|
10665
|
-
__classPrivateFieldGet$
|
|
10665
|
+
__classPrivateFieldGet$4(this, _KupDataTable_filtersColumnMenuInstance, "f").removeFilter(newFilters, column.name);
|
|
10666
10666
|
this.filters = newFilters;
|
|
10667
10667
|
}, _KupDataTable_getFilterValueForTooltip = function _KupDataTable_getFilterValueForTooltip(column) {
|
|
10668
|
-
return __classPrivateFieldGet$
|
|
10668
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_filtersColumnMenuInstance, "f").getFilterValueForTooltip(this.filters, column);
|
|
10669
10669
|
}, _KupDataTable_onGlobalFilterChange = function _KupDataTable_onGlobalFilterChange(inputEl) {
|
|
10670
10670
|
this.resetCurrentPage();
|
|
10671
10671
|
if (inputEl) {
|
|
@@ -10676,15 +10676,15 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10676
10676
|
this.globalFilterValue = '';
|
|
10677
10677
|
}
|
|
10678
10678
|
}, _KupDataTable_handlePageChange = function _KupDataTable_handlePageChange(pageNumber) {
|
|
10679
|
-
const newPage = pageChange(pageNumber, __classPrivateFieldGet$
|
|
10679
|
+
const newPage = pageChange(pageNumber, __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f"), this.currentRowsPerPage);
|
|
10680
10680
|
if (newPage) {
|
|
10681
10681
|
this.currentPage = newPage;
|
|
10682
10682
|
}
|
|
10683
10683
|
}, _KupDataTable_handleRowsPerPageChange = function _KupDataTable_handleRowsPerPageChange(rowsNumber) {
|
|
10684
|
-
const newRows = rowsPerPageChange(rowsNumber, __classPrivateFieldGet$
|
|
10684
|
+
const newRows = rowsPerPageChange(rowsNumber, __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f"));
|
|
10685
10685
|
if (newRows) {
|
|
10686
10686
|
this.currentRowsPerPage = newRows;
|
|
10687
|
-
__classPrivateFieldGet$
|
|
10687
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_adjustPaginator).call(this);
|
|
10688
10688
|
}
|
|
10689
10689
|
}, _KupDataTable_onRowClick = function _KupDataTable_onRowClick(row, td, emitEvent) {
|
|
10690
10690
|
// selecting row
|
|
@@ -10714,9 +10714,9 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10714
10714
|
if (!row.unselectable &&
|
|
10715
10715
|
this.selection !== SelectionMode.NONE &&
|
|
10716
10716
|
clickedColumn) {
|
|
10717
|
-
__classPrivateFieldGet$
|
|
10717
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_deselectColumn).call(this, this.selectedColumn);
|
|
10718
10718
|
this.selectedColumn = clickedColumn;
|
|
10719
|
-
__classPrivateFieldGet$
|
|
10719
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_selectColumn).call(this, this.selectedColumn);
|
|
10720
10720
|
if (emitEvent !== false) {
|
|
10721
10721
|
// emit event
|
|
10722
10722
|
this.kupRowSelected.emit({
|
|
@@ -10791,7 +10791,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10791
10791
|
}, _KupDataTable_onSelectAll = function _KupDataTable_onSelectAll({ target }) {
|
|
10792
10792
|
if (target.checked) {
|
|
10793
10793
|
// select all rows
|
|
10794
|
-
this.selectedRows = __classPrivateFieldGet$
|
|
10794
|
+
this.selectedRows = __classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f");
|
|
10795
10795
|
// triggering event
|
|
10796
10796
|
this.kupRowSelected.emit({
|
|
10797
10797
|
comp: this,
|
|
@@ -10803,21 +10803,21 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10803
10803
|
}
|
|
10804
10804
|
else {
|
|
10805
10805
|
// deselect all rows
|
|
10806
|
-
__classPrivateFieldGet$
|
|
10806
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_resetSelectedRows).call(this);
|
|
10807
10807
|
}
|
|
10808
10808
|
}, _KupDataTable_openTotalMenu = function _KupDataTable_openTotalMenu(column) {
|
|
10809
10809
|
this.openedTotalMenu = column.name;
|
|
10810
10810
|
}, _KupDataTable_closeTotalMenu = function _KupDataTable_closeTotalMenu() {
|
|
10811
10811
|
this.openedTotalMenu = null;
|
|
10812
|
-
__classPrivateFieldGet$
|
|
10812
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").removeClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCb, "f"));
|
|
10813
10813
|
}, _KupDataTable_isOpenedTotalMenuForColumn = function _KupDataTable_isOpenedTotalMenuForColumn(column) {
|
|
10814
10814
|
return this.openedTotalMenu === column;
|
|
10815
10815
|
}, _KupDataTable_groupRows = function _KupDataTable_groupRows() {
|
|
10816
|
-
if (!__classPrivateFieldGet$
|
|
10816
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGrouping).call(this)) {
|
|
10817
10817
|
return;
|
|
10818
10818
|
}
|
|
10819
|
-
__classPrivateFieldSet$2(this, _KupDataTable_rows, groupRows(this.getColumns(), __classPrivateFieldGet$
|
|
10820
|
-
__classPrivateFieldGet$
|
|
10819
|
+
__classPrivateFieldSet$2(this, _KupDataTable_rows, groupRows(this.getColumns(), __classPrivateFieldGet$4(this, _KupDataTable_rows, "f"), this.groups, this.totals), "f");
|
|
10820
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_adjustGroupState).call(this);
|
|
10821
10821
|
}, _KupDataTable_onLoadMoreClick = function _KupDataTable_onLoadMoreClick() {
|
|
10822
10822
|
var _a;
|
|
10823
10823
|
let loadItems = 0;
|
|
@@ -10827,11 +10827,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10827
10827
|
break;
|
|
10828
10828
|
case LoadMoreMode.CONSTANT_INCREMENT:
|
|
10829
10829
|
loadItems =
|
|
10830
|
-
this.loadMoreStep * (__classPrivateFieldGet$
|
|
10830
|
+
this.loadMoreStep * (__classPrivateFieldGet$4(this, _KupDataTable_loadMoreEventCounter, "f") + 1);
|
|
10831
10831
|
break;
|
|
10832
10832
|
case LoadMoreMode.PROGRESSIVE_THRESHOLD:
|
|
10833
10833
|
loadItems =
|
|
10834
|
-
Math.max(__classPrivateFieldGet$
|
|
10834
|
+
Math.max(__classPrivateFieldGet$4(this, _KupDataTable_loadMoreEventPreviousQuantity, "f"), this.loadMoreStep) * Math.min(__classPrivateFieldGet$4(this, _KupDataTable_loadMoreEventCounter, "f") + 1, 2);
|
|
10835
10835
|
break;
|
|
10836
10836
|
}
|
|
10837
10837
|
if (loadItems > this.loadMoreLimit) {
|
|
@@ -10843,15 +10843,15 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10843
10843
|
loadItems: loadItems,
|
|
10844
10844
|
});
|
|
10845
10845
|
__classPrivateFieldSet$2(this, _KupDataTable_loadMoreEventPreviousQuantity, loadItems, "f");
|
|
10846
|
-
__classPrivateFieldSet$2(this, _KupDataTable_loadMoreEventCounter, (_a = __classPrivateFieldGet$
|
|
10846
|
+
__classPrivateFieldSet$2(this, _KupDataTable_loadMoreEventCounter, (_a = __classPrivateFieldGet$4(this, _KupDataTable_loadMoreEventCounter, "f"), _a++, _a), "f");
|
|
10847
10847
|
}, _KupDataTable_adjustGroupState = function _KupDataTable_adjustGroupState() {
|
|
10848
|
-
if (!__classPrivateFieldGet$
|
|
10849
|
-
__classPrivateFieldGet$
|
|
10850
|
-
!__classPrivateFieldGet$
|
|
10848
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_rows, "f") ||
|
|
10849
|
+
__classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f") === 0 ||
|
|
10850
|
+
!__classPrivateFieldGet$4(this, _KupDataTable_rows, "f")[0].hasOwnProperty('group')) {
|
|
10851
10851
|
// no grouping
|
|
10852
10852
|
return;
|
|
10853
10853
|
}
|
|
10854
|
-
__classPrivateFieldGet$
|
|
10854
|
+
__classPrivateFieldGet$4(this, _KupDataTable_rows, "f").forEach((r) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_adjustGroupStateFromRow).call(this, r));
|
|
10855
10855
|
}, _KupDataTable_adjustGroupStateFromRow = function _KupDataTable_adjustGroupStateFromRow(row) {
|
|
10856
10856
|
if (!row || !row.hasOwnProperty('group')) {
|
|
10857
10857
|
// not a groping row, nothing to do
|
|
@@ -10868,9 +10868,9 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10868
10868
|
// update expanded
|
|
10869
10869
|
group.expanded = groupFromState.expanded;
|
|
10870
10870
|
}
|
|
10871
|
-
group.children.forEach((child) => __classPrivateFieldGet$
|
|
10871
|
+
group.children.forEach((child) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_adjustGroupStateFromRow).call(this, child));
|
|
10872
10872
|
}, _KupDataTable_sortRows = function _KupDataTable_sortRows() {
|
|
10873
|
-
__classPrivateFieldSet$2(this, _KupDataTable_rows, sortRows(__classPrivateFieldGet$
|
|
10873
|
+
__classPrivateFieldSet$2(this, _KupDataTable_rows, sortRows(__classPrivateFieldGet$4(this, _KupDataTable_rows, "f"), this.sort), "f");
|
|
10874
10874
|
}, _KupDataTable_getSortIcon = function _KupDataTable_getSortIcon(columnName) {
|
|
10875
10875
|
// check if column in sort array
|
|
10876
10876
|
for (let sortObj of this.sort) {
|
|
@@ -10896,7 +10896,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10896
10896
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
10897
10897
|
colSpan += 1;
|
|
10898
10898
|
}
|
|
10899
|
-
if (__classPrivateFieldGet$
|
|
10899
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
10900
10900
|
colSpan += 1;
|
|
10901
10901
|
}
|
|
10902
10902
|
return colSpan;
|
|
@@ -10926,7 +10926,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10926
10926
|
sourceColumn: this.data.columns[sortedColIndex],
|
|
10927
10927
|
targetColumn: this.data.columns[receivingColIndex],
|
|
10928
10928
|
});
|
|
10929
|
-
__classPrivateFieldGet$
|
|
10929
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_moveSortedColumns).call(this, this.data.columns, receivingColIndex, sortedColIndex);
|
|
10930
10930
|
}
|
|
10931
10931
|
}, _KupDataTable_moveSortedColumns = function _KupDataTable_moveSortedColumns(columns, receivingColumnIndex, sortedColumnIndex) {
|
|
10932
10932
|
const remove = columns.splice(sortedColumnIndex, 1);
|
|
@@ -10939,25 +10939,25 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10939
10939
|
.map((chunk, index) => (index !== 0 ? [h("br", null), chunk] : chunk));
|
|
10940
10940
|
}, _KupDataTable_composeHeaderCellClassAndStyle = function _KupDataTable_composeHeaderCellClassAndStyle(columnIndex, extraCells = 0, column) {
|
|
10941
10941
|
let columnClass = { ['header-cell']: true }, thStyle = column.style ? Object.assign({}, column.style) : {};
|
|
10942
|
-
if (__classPrivateFieldGet$
|
|
10943
|
-
__classPrivateFieldGet$
|
|
10944
|
-
__classPrivateFieldGet$
|
|
10945
|
-
__classPrivateFieldGet$
|
|
10946
|
-
__classPrivateFieldGet$
|
|
10947
|
-
__classPrivateFieldGet$
|
|
10948
|
-
__classPrivateFieldGet$
|
|
10949
|
-
__classPrivateFieldGet$
|
|
10950
|
-
__classPrivateFieldGet$
|
|
10942
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isBar(column.obj) ||
|
|
10943
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isButton(column.obj) ||
|
|
10944
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isChart(column.obj) ||
|
|
10945
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isCheckbox(column.obj) ||
|
|
10946
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isImage(column.obj) ||
|
|
10947
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isIcon(column.obj) ||
|
|
10948
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isProgressBar(column.obj) ||
|
|
10949
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isRadio(column.obj) ||
|
|
10950
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isVoCodver(column.obj)) {
|
|
10951
10951
|
columnClass['header-cell--centered'] = true;
|
|
10952
10952
|
}
|
|
10953
|
-
if (__classPrivateFieldGet$
|
|
10953
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isNumber(column.obj)) {
|
|
10954
10954
|
columnClass['header-cell--is-number'] = true;
|
|
10955
10955
|
}
|
|
10956
|
-
if (__classPrivateFieldGet$
|
|
10956
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isIcon(column.obj)) {
|
|
10957
10957
|
columnClass['header-cell--is-icon'] = true;
|
|
10958
10958
|
}
|
|
10959
10959
|
// For fixed cells styles and classes
|
|
10960
|
-
const fixedCellStyle = __classPrivateFieldGet$
|
|
10960
|
+
const fixedCellStyle = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, columnIndex + 1 + extraCells, 0, extraCells);
|
|
10961
10961
|
if (fixedCellStyle) {
|
|
10962
10962
|
columnClass = Object.assign(Object.assign({}, columnClass), fixedCellStyle.fixedCellClasses);
|
|
10963
10963
|
thStyle = Object.assign(Object.assign({}, thStyle), fixedCellStyle.fixedCellStyle);
|
|
@@ -10972,24 +10972,24 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10972
10972
|
let multiSelectColumn = null;
|
|
10973
10973
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
10974
10974
|
specialExtraCellsCount++;
|
|
10975
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
10975
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, 0, specialExtraCellsCount - 1);
|
|
10976
10976
|
const style = Object.assign({ width: '30px', margin: '0 auto' }, (selectionStyleAndClass
|
|
10977
10977
|
? selectionStyleAndClass.fixedCellStyle
|
|
10978
10978
|
: {}));
|
|
10979
10979
|
multiSelectColumn = (h("th", { class: selectionStyleAndClass
|
|
10980
10980
|
? selectionStyleAndClass.fixedCellClasses
|
|
10981
|
-
: {}, style: style }, h("kup-checkbox", { "onkup-checkbox-change": (e) => __classPrivateFieldGet$
|
|
10981
|
+
: {}, style: style }, h("kup-checkbox", { "onkup-checkbox-change": (e) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onSelectAll).call(this, e), title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.SELECTED) +
|
|
10982
10982
|
`: ${this.selectedRows.length},` +
|
|
10983
|
-
__classPrivateFieldGet$
|
|
10984
|
-
`: ${__classPrivateFieldGet$
|
|
10983
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.RENDERED) +
|
|
10984
|
+
`: ${__classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f").length}`, checked: this.selectedRows.length > 0 &&
|
|
10985
10985
|
this.selectedRows.length ===
|
|
10986
|
-
__classPrivateFieldGet$
|
|
10986
|
+
__classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f").length })));
|
|
10987
10987
|
}
|
|
10988
10988
|
// Renders action column
|
|
10989
10989
|
let actionsColumn = null;
|
|
10990
|
-
if (__classPrivateFieldGet$
|
|
10990
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
10991
10991
|
specialExtraCellsCount++;
|
|
10992
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
10992
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, 0, specialExtraCellsCount - 1);
|
|
10993
10993
|
actionsColumn = (h("th", { class: selectionStyleAndClass
|
|
10994
10994
|
? selectionStyleAndClass.fixedCellClasses
|
|
10995
10995
|
: {}, style: selectionStyleAndClass
|
|
@@ -10998,26 +10998,26 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
10998
10998
|
}
|
|
10999
10999
|
// Renders normal cells
|
|
11000
11000
|
const dataColumns = this.getVisibleColumns().map((column, columnIndex) => {
|
|
11001
|
-
const { columnClass, thStyle } = __classPrivateFieldGet$
|
|
11001
|
+
const { columnClass, thStyle } = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeHeaderCellClassAndStyle).call(this, columnIndex, specialExtraCellsCount, column);
|
|
11002
11002
|
let filter = null;
|
|
11003
|
-
if (__classPrivateFieldGet$
|
|
11004
|
-
const svgLabel = __classPrivateFieldGet$
|
|
11003
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_filtersColumnMenuInstance, "f").hasFiltersForColumn(this.filters, column)) {
|
|
11004
|
+
const svgLabel = __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.REMOVE_FILTERS) + `: '${__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getFilterValueForTooltip).call(this, column)}'`;
|
|
11005
11005
|
filter = (h("span", { title: svgLabel, class: `kup-icon ${KupThemeIconValues.FILTER_REMOVE.replace('--', '')}` }));
|
|
11006
11006
|
}
|
|
11007
11007
|
let sortIcon = null;
|
|
11008
|
-
let iconClass = __classPrivateFieldGet$
|
|
11008
|
+
let iconClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getSortIcon).call(this, column.name);
|
|
11009
11009
|
if (iconClass !== '') {
|
|
11010
|
-
sortIcon = (h("span", { class: iconClass, title: __classPrivateFieldGet$
|
|
11010
|
+
sortIcon = (h("span", { class: iconClass, title: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getSortDecode).call(this, column.name) }));
|
|
11011
11011
|
}
|
|
11012
11012
|
columnClass['header-cell--sortable'] = true;
|
|
11013
11013
|
let keyIcon = null;
|
|
11014
11014
|
if (column.isKey) {
|
|
11015
|
-
keyIcon = (h("span", { class: `kup-icon ${KupThemeIconValues.KEY.replace('--', '')}`, title: __classPrivateFieldGet$
|
|
11015
|
+
keyIcon = (h("span", { class: `kup-icon ${KupThemeIconValues.KEY.replace('--', '')}`, title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.KEY) }));
|
|
11016
11016
|
}
|
|
11017
11017
|
// Sets custom columns width
|
|
11018
|
-
if (__classPrivateFieldGet$
|
|
11019
|
-
for (let i = 0; i < __classPrivateFieldGet$
|
|
11020
|
-
const currentCol = __classPrivateFieldGet$
|
|
11018
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")) {
|
|
11019
|
+
for (let i = 0; i < __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f").length; i++) {
|
|
11020
|
+
const currentCol = __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")[i];
|
|
11021
11021
|
if (currentCol.name === column.name) {
|
|
11022
11022
|
const width = currentCol.size + '';
|
|
11023
11023
|
if (width.indexOf('ch') < 1) {
|
|
@@ -11030,7 +11030,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11030
11030
|
}
|
|
11031
11031
|
}
|
|
11032
11032
|
}
|
|
11033
|
-
return (h("th", { ref: (el) => __classPrivateFieldGet$
|
|
11033
|
+
return (h("th", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_thRefs, "f").push(el), "data-cell": column, "data-column": column.name, class: columnClass, style: thStyle, title: column.name }, h("div", { class: "header-cell__content" }, h("span", { class: "header-cell__title" }, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_applyLineBreaks).call(this, column.title)), h("span", { class: "header-cell__icons" }, keyIcon, sortIcon, filter)), this.resizableColumns ? (h("span", { class: "header-cell__drag-handler" })) : null));
|
|
11034
11034
|
});
|
|
11035
11035
|
return [multiSelectColumn, actionsColumn, ...dataColumns];
|
|
11036
11036
|
// return [multiSelectColumn, groupColumn, actionsColumn, ...dataColumns];
|
|
@@ -11039,24 +11039,24 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11039
11039
|
let multiSelectColumn = null;
|
|
11040
11040
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
11041
11041
|
specialExtraCellsCount++;
|
|
11042
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
11042
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, 0, specialExtraCellsCount - 1);
|
|
11043
11043
|
const style = Object.assign({ width: '30px', margin: '0 auto' }, (selectionStyleAndClass
|
|
11044
11044
|
? selectionStyleAndClass.fixedCellStyle
|
|
11045
11045
|
: {}));
|
|
11046
11046
|
multiSelectColumn = (h("th-sticky", { class: selectionStyleAndClass
|
|
11047
11047
|
? selectionStyleAndClass.fixedCellClasses
|
|
11048
|
-
: null, style: style }, h("kup-checkbox", { "onkup-checkbox-change": (e) => __classPrivateFieldGet$
|
|
11048
|
+
: null, style: style }, h("kup-checkbox", { "onkup-checkbox-change": (e) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onSelectAll).call(this, e), title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.SELECTED) +
|
|
11049
11049
|
`: ${this.selectedRows.length},` +
|
|
11050
|
-
__classPrivateFieldGet$
|
|
11051
|
-
`: ${__classPrivateFieldGet$
|
|
11050
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageRow.RENDERED) +
|
|
11051
|
+
`: ${__classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f").length}`, checked: this.selectedRows.length > 0 &&
|
|
11052
11052
|
this.selectedRows.length ===
|
|
11053
|
-
__classPrivateFieldGet$
|
|
11053
|
+
__classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f").length })));
|
|
11054
11054
|
}
|
|
11055
11055
|
// Empty cell for the actions
|
|
11056
11056
|
let actionsColumn = null;
|
|
11057
|
-
if (__classPrivateFieldGet$
|
|
11057
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
11058
11058
|
specialExtraCellsCount++;
|
|
11059
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
11059
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, 0, specialExtraCellsCount - 1);
|
|
11060
11060
|
actionsColumn = (h("th-sticky", { class: selectionStyleAndClass
|
|
11061
11061
|
? selectionStyleAndClass.fixedCellClasses
|
|
11062
11062
|
: null, style: selectionStyleAndClass
|
|
@@ -11065,29 +11065,29 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11065
11065
|
}
|
|
11066
11066
|
// Composes normal header cells
|
|
11067
11067
|
const dataColumns = this.getVisibleColumns().map((column, columnIndex) => {
|
|
11068
|
-
const { columnClass, thStyle } = __classPrivateFieldGet$
|
|
11069
|
-
return (h("th-sticky", { class: columnClass, style: thStyle }, h("div", { class: "header-cell__content" }, h("span", { class: "header-cell__title" }, __classPrivateFieldGet$
|
|
11068
|
+
const { columnClass, thStyle } = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeHeaderCellClassAndStyle).call(this, columnIndex, specialExtraCellsCount, column);
|
|
11069
|
+
return (h("th-sticky", { class: columnClass, style: thStyle }, h("div", { class: "header-cell__content" }, h("span", { class: "header-cell__title" }, __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_applyLineBreaks).call(this, column.title)))));
|
|
11070
11070
|
});
|
|
11071
11071
|
return [multiSelectColumn, actionsColumn, ...dataColumns];
|
|
11072
11072
|
}, _KupDataTable_totalMenuPosition = function _KupDataTable_totalMenuPosition() {
|
|
11073
11073
|
if (this.rootElement.shadowRoot) {
|
|
11074
11074
|
const menu = this.rootElement.shadowRoot.querySelector('#totals-menu');
|
|
11075
11075
|
if (menu) {
|
|
11076
|
-
__classPrivateFieldGet$
|
|
11076
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.register(menu, __classPrivateFieldGet$4(this, _KupDataTable_totalMenuCoords, "f"));
|
|
11077
11077
|
__classPrivateFieldSet$2(this, _KupDataTable_clickCb, {
|
|
11078
11078
|
cb: () => {
|
|
11079
|
-
__classPrivateFieldGet$
|
|
11079
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeTotalMenu).call(this);
|
|
11080
11080
|
},
|
|
11081
11081
|
el: menu,
|
|
11082
11082
|
}, "f");
|
|
11083
|
-
__classPrivateFieldGet$
|
|
11084
|
-
__classPrivateFieldGet$
|
|
11083
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").addClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCb, "f"), true);
|
|
11084
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.start(menu);
|
|
11085
11085
|
menu.menuVisible = true;
|
|
11086
11086
|
}
|
|
11087
11087
|
}
|
|
11088
11088
|
}, _KupDataTable_onTotalMenuOpen = function _KupDataTable_onTotalMenuOpen(column) {
|
|
11089
|
-
__classPrivateFieldGet$
|
|
11090
|
-
__classPrivateFieldGet$
|
|
11089
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeTotalMenu).call(this);
|
|
11090
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_openTotalMenu).call(this, column);
|
|
11091
11091
|
}, _KupDataTable_renderRow = function _KupDataTable_renderRow(row, level = 0, rowCssIndex = 0, previousRow) {
|
|
11092
11092
|
const visibleColumns = this.getVisibleColumns();
|
|
11093
11093
|
let rowActionsCount = 0;
|
|
@@ -11119,17 +11119,17 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11119
11119
|
for (let i = 0; i < level; i++) {
|
|
11120
11120
|
indent.push(h("span", { class: "indent" }));
|
|
11121
11121
|
}
|
|
11122
|
-
if (__classPrivateFieldGet$
|
|
11122
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasTotals).call(this)) {
|
|
11123
11123
|
//const colSpan = this.multiSelection ? 2 : 1;
|
|
11124
11124
|
const cells = [];
|
|
11125
|
-
if (__classPrivateFieldGet$
|
|
11125
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
11126
11126
|
cells.push(h("td", null));
|
|
11127
11127
|
}
|
|
11128
11128
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
11129
11129
|
cells.push(h("td", null));
|
|
11130
11130
|
}
|
|
11131
11131
|
// adding 'grouping' cell
|
|
11132
|
-
const grouplabelcell = (h("td", { colSpan: __classPrivateFieldGet$
|
|
11132
|
+
const grouplabelcell = (h("td", { colSpan: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_calculateColspan).call(this) }, h("span", { class: "group-cell-content" }, indent, h("span", { class: iconClass }), h("span", { class: "text" }, composedGroupLabel))));
|
|
11133
11133
|
// adding 'totals grouping' cells
|
|
11134
11134
|
for (let column of visibleColumns) {
|
|
11135
11135
|
let totalClass = 'total';
|
|
@@ -11144,11 +11144,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11144
11144
|
value = totalValue;
|
|
11145
11145
|
}
|
|
11146
11146
|
else {
|
|
11147
|
-
if (__classPrivateFieldGet$
|
|
11147
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").objects.isDate(column.obj)) {
|
|
11148
11148
|
if (totalValue) {
|
|
11149
|
-
if (__classPrivateFieldGet$
|
|
11149
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dates.isValid(totalValue, KupDatesFormats.ISO_DATE)) {
|
|
11150
11150
|
value =
|
|
11151
|
-
__classPrivateFieldGet$
|
|
11151
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dates.format(totalValue);
|
|
11152
11152
|
}
|
|
11153
11153
|
else {
|
|
11154
11154
|
console.warn(`invalid date: ${totalValue}`);
|
|
@@ -11161,18 +11161,18 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11161
11161
|
}
|
|
11162
11162
|
cells.push(h("td", { class: totalClass }, value));
|
|
11163
11163
|
}
|
|
11164
|
-
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$
|
|
11165
|
-
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$
|
|
11164
|
+
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").push(el), "data-row": row, class: "group group-label" }, grouplabelcell));
|
|
11165
|
+
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").push(el), "data-row": row, class: "group group-total" }, cells));
|
|
11166
11166
|
}
|
|
11167
11167
|
else {
|
|
11168
|
-
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$
|
|
11168
|
+
jsxRows.push(h("tr", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").push(el), "data-row": row, class: "group" }, h("td", { colSpan: __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_calculateColspan).call(this) }, h("span", { class: "group-cell-content" }, indent, h("span", { class: iconClass }), h("span", { class: "text" }, composedGroupLabel)))));
|
|
11169
11169
|
}
|
|
11170
11170
|
// if group is expanded, add children
|
|
11171
|
-
if (__classPrivateFieldGet$
|
|
11171
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_isGroupExpanded).call(this, row)) {
|
|
11172
11172
|
row.group.children
|
|
11173
11173
|
// We must pass the previous element of the array to check if we must hide or display the value of the cell
|
|
11174
11174
|
// When the column has specified the parameter hideValuesRepetitions
|
|
11175
|
-
.map((row, groupRowIndex, currentArray) => __classPrivateFieldGet$
|
|
11175
|
+
.map((row, groupRowIndex, currentArray) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderRow).call(this, row, level + 1, groupRowIndex, groupRowIndex > 0
|
|
11176
11176
|
? currentArray[groupRowIndex - 1]
|
|
11177
11177
|
: undefined))
|
|
11178
11178
|
.forEach((jsxRow) => {
|
|
@@ -11199,11 +11199,11 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11199
11199
|
let selectRowCell = null;
|
|
11200
11200
|
if (this.selection === SelectionMode.MULTIPLE_CHECKBOX) {
|
|
11201
11201
|
specialExtraCellsCount++;
|
|
11202
|
-
const selectionStyleAndClass = __classPrivateFieldGet$
|
|
11202
|
+
const selectionStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, rowCssIndex, specialExtraCellsCount - 1);
|
|
11203
11203
|
const props = {
|
|
11204
11204
|
checked: this.selectedRows.includes(row),
|
|
11205
11205
|
onChange: () => {
|
|
11206
|
-
__classPrivateFieldGet$
|
|
11206
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handleRowSelect).call(this, row);
|
|
11207
11207
|
},
|
|
11208
11208
|
};
|
|
11209
11209
|
selectRowCell = (h("td", { "row-select-cell": true, class: selectionStyleAndClass
|
|
@@ -11215,18 +11215,18 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11215
11215
|
// Renders action cell
|
|
11216
11216
|
// If active, this can be either the first or second cell
|
|
11217
11217
|
let rowActionsCell = null;
|
|
11218
|
-
if (__classPrivateFieldGet$
|
|
11218
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_hasRowActions).call(this)) {
|
|
11219
11219
|
// Increments
|
|
11220
11220
|
specialExtraCellsCount++;
|
|
11221
|
-
const actionsStyleAndClass = __classPrivateFieldGet$
|
|
11221
|
+
const actionsStyleAndClass = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, specialExtraCellsCount, rowCssIndex, specialExtraCellsCount - 1);
|
|
11222
11222
|
rowActionsCount += this.rowActions.length;
|
|
11223
|
-
const defaultRowActions = __classPrivateFieldGet$
|
|
11223
|
+
const defaultRowActions = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderActions).call(this, this.rowActions, row, 'default');
|
|
11224
11224
|
let rowActionExpander = null;
|
|
11225
11225
|
let variableActions = null;
|
|
11226
11226
|
if (row.actions) {
|
|
11227
11227
|
rowActionsCount += row.actions.length;
|
|
11228
11228
|
// adding variable actions
|
|
11229
|
-
variableActions = __classPrivateFieldGet$
|
|
11229
|
+
variableActions = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_renderActions).call(this, row.actions, row, 'variable');
|
|
11230
11230
|
}
|
|
11231
11231
|
else {
|
|
11232
11232
|
// adding expander
|
|
@@ -11235,10 +11235,10 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11235
11235
|
resource: 'chevron-right',
|
|
11236
11236
|
sizeX: '1.5em',
|
|
11237
11237
|
sizeY: '1.5em',
|
|
11238
|
-
title: __classPrivateFieldGet$
|
|
11238
|
+
title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EXPAND),
|
|
11239
11239
|
wrapperClass: 'expander',
|
|
11240
11240
|
onClick: (e) => {
|
|
11241
|
-
__classPrivateFieldGet$
|
|
11241
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onRowActionExpanderClick).call(this, e, row);
|
|
11242
11242
|
},
|
|
11243
11243
|
};
|
|
11244
11244
|
rowActionsCount++;
|
|
@@ -11287,18 +11287,18 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11287
11287
|
let cellClass = null;
|
|
11288
11288
|
let cellStyle = Object.assign({}, cell.style);
|
|
11289
11289
|
//-- For fixed cells --
|
|
11290
|
-
const fixedStyles = __classPrivateFieldGet$
|
|
11290
|
+
const fixedStyles = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_composeFixedCellStyleAndClass).call(this, cellIndex + 1 + specialExtraCellsCount, rowCssIndex, specialExtraCellsCount);
|
|
11291
11291
|
if (fixedStyles) {
|
|
11292
11292
|
cellStyle = Object.assign(cellStyle ? cellStyle : {}, fixedStyles.fixedCellStyle);
|
|
11293
11293
|
cellClass = Object.assign(Object.assign({}, cellClass), fixedStyles.fixedCellClasses);
|
|
11294
11294
|
}
|
|
11295
11295
|
// Controls if there are columns with a specified width
|
|
11296
|
-
if (__classPrivateFieldGet$
|
|
11296
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")) {
|
|
11297
11297
|
let colWidth = '';
|
|
11298
11298
|
// Search if this column has a specified width
|
|
11299
|
-
for (let j = 0; j < __classPrivateFieldGet$
|
|
11300
|
-
if (name === __classPrivateFieldGet$
|
|
11301
|
-
colWidth = __classPrivateFieldGet$
|
|
11299
|
+
for (let j = 0; j < __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f").length; j++) {
|
|
11300
|
+
if (name === __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")[j].name) {
|
|
11301
|
+
colWidth = __classPrivateFieldGet$4(this, _KupDataTable_sizedColumns, "f")[j].size;
|
|
11302
11302
|
break;
|
|
11303
11303
|
}
|
|
11304
11304
|
}
|
|
@@ -11320,7 +11320,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11320
11320
|
return (h("td", Object.assign({ title: title, colSpan: cell.span && cell.span.col ? cell.span.col : null, rowSpan: cell.span && cell.span.row ? cell.span.row : null, "data-cell": cell, "data-column": name, "data-row": row, style: cellStyle, class: cellClass }, eventHandlers), jsxCell));
|
|
11321
11321
|
});
|
|
11322
11322
|
// adding row to rendered rows
|
|
11323
|
-
__classPrivateFieldGet$
|
|
11323
|
+
__classPrivateFieldGet$4(this, _KupDataTable_renderedRows, "f").push(row);
|
|
11324
11324
|
const rowClass = {
|
|
11325
11325
|
selected: this.selectedRows.includes(row),
|
|
11326
11326
|
};
|
|
@@ -11330,7 +11330,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11330
11330
|
const style = {
|
|
11331
11331
|
'--kup_datatable_row_actions': rowActionsCount,
|
|
11332
11332
|
};
|
|
11333
|
-
return (h("tr", { ref: (el) => __classPrivateFieldGet$
|
|
11333
|
+
return (h("tr", { ref: (el) => __classPrivateFieldGet$4(this, _KupDataTable_rowsRefs, "f").push(el), "data-row": row, class: rowClass, style: style }, selectRowCell, rowActionsCell, cells));
|
|
11334
11334
|
}
|
|
11335
11335
|
}, _KupDataTable_renderActions = function _KupDataTable_renderActions(actions, row, type) {
|
|
11336
11336
|
return actions.map((action, index) => {
|
|
@@ -11341,7 +11341,7 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11341
11341
|
sizeY: '1.5em',
|
|
11342
11342
|
title: action.text,
|
|
11343
11343
|
wrapperClass: 'action',
|
|
11344
|
-
onClick: () => __classPrivateFieldGet$
|
|
11344
|
+
onClick: () => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onDefaultRowActionClick).call(this, {
|
|
11345
11345
|
action,
|
|
11346
11346
|
row,
|
|
11347
11347
|
index,
|
|
@@ -11352,58 +11352,58 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11352
11352
|
});
|
|
11353
11353
|
}, _KupDataTable_onCustomSettingsClick = function _KupDataTable_onCustomSettingsClick() {
|
|
11354
11354
|
if (!this.openedCustomSettings) {
|
|
11355
|
-
__classPrivateFieldGet$
|
|
11355
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_openCustomSettings).call(this);
|
|
11356
11356
|
}
|
|
11357
11357
|
else {
|
|
11358
|
-
__classPrivateFieldGet$
|
|
11358
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeCustomSettings).call(this);
|
|
11359
11359
|
}
|
|
11360
11360
|
}, _KupDataTable_openCustomSettings = function _KupDataTable_openCustomSettings() {
|
|
11361
|
-
__classPrivateFieldGet$
|
|
11362
|
-
__classPrivateFieldGet$
|
|
11363
|
-
__classPrivateFieldGet$
|
|
11361
|
+
__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f").menuVisible = true;
|
|
11362
|
+
__classPrivateFieldGet$4(this, _KupDataTable_customizeTopButtonRef, "f").classList.add('toggled');
|
|
11363
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f"));
|
|
11364
11364
|
this.openedCustomSettings = true;
|
|
11365
|
-
if (!__classPrivateFieldGet$
|
|
11365
|
+
if (!__classPrivateFieldGet$4(this, _KupDataTable_clickCbCustomPanel, "f")) {
|
|
11366
11366
|
__classPrivateFieldSet$2(this, _KupDataTable_clickCbCustomPanel, {
|
|
11367
11367
|
cb: () => {
|
|
11368
|
-
__classPrivateFieldGet$
|
|
11368
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_closeCustomSettings).call(this);
|
|
11369
11369
|
},
|
|
11370
|
-
el: __classPrivateFieldGet$
|
|
11370
|
+
el: __classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f"),
|
|
11371
11371
|
}, "f");
|
|
11372
11372
|
}
|
|
11373
|
-
__classPrivateFieldGet$
|
|
11373
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").addClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCbCustomPanel, "f"), true);
|
|
11374
11374
|
}, _KupDataTable_closeCustomSettings = function _KupDataTable_closeCustomSettings() {
|
|
11375
|
-
__classPrivateFieldGet$
|
|
11376
|
-
if (__classPrivateFieldGet$
|
|
11375
|
+
__classPrivateFieldGet$4(this, _KupDataTable_customizeTopButtonRef, "f").classList.remove('toggled');
|
|
11376
|
+
if (__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f") == null) {
|
|
11377
11377
|
return;
|
|
11378
11378
|
}
|
|
11379
|
-
__classPrivateFieldGet$
|
|
11379
|
+
__classPrivateFieldGet$4(this, _KupDataTable_customizeTopPanelRef, "f").menuVisible = false;
|
|
11380
11380
|
this.openedCustomSettings = false;
|
|
11381
|
-
__classPrivateFieldGet$
|
|
11381
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").removeClickCallback(__classPrivateFieldGet$4(this, _KupDataTable_clickCbCustomPanel, "f"));
|
|
11382
11382
|
}, _KupDataTable_renderPaginator = function _KupDataTable_renderPaginator(top) {
|
|
11383
11383
|
return (h("div", { class: "paginator-wrapper" }, h("div", { class: "paginator-tabs" }, this.showLoadMore ||
|
|
11384
11384
|
(!this.lazyLoadRows &&
|
|
11385
|
-
__classPrivateFieldGet$
|
|
11385
|
+
__classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f") > this.rowsPerPage) ? (h(FPaginator, { id: top ? 'top-paginator' : 'bottom-paginator', currentPage: this.currentPage, max: __classPrivateFieldGet$4(this, _KupDataTable_rowsLength, "f"), perPage: this.currentRowsPerPage
|
|
11386
11386
|
? this.currentRowsPerPage
|
|
11387
11387
|
: this.rowsPerPage, onLoadMore: this.showLoadMore
|
|
11388
11388
|
? () => {
|
|
11389
|
-
__classPrivateFieldGet$
|
|
11389
|
+
__classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_onLoadMoreClick).call(this);
|
|
11390
11390
|
}
|
|
11391
|
-
: null, onNextPage: () => __classPrivateFieldGet$
|
|
11391
|
+
: null, onNextPage: () => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage + 1), onPrevPage: () => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, this.currentPage - 1), onPageChange: (e) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handlePageChange).call(this, e.detail.value), onRowsChange: (e) => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_handleRowsPerPageChange).call(this, e.detail.value) })) : null)));
|
|
11392
11392
|
}, _KupDataTable_columnRemoveArea = function _KupDataTable_columnRemoveArea() {
|
|
11393
11393
|
return (h("div", { class: "droparea__remove", ref: (el) => (__classPrivateFieldSet$2(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" })));
|
|
11394
11394
|
}, _KupDataTable_columnGroupArea = function _KupDataTable_columnGroupArea() {
|
|
11395
11395
|
return (h("div", { class: "droparea__groups", ref: (el) => (__classPrivateFieldSet$2(this, _KupDataTable_groupsDropareaRef, el, "f")) }, h(FImage, { resource: "bookmark", color: `var(${KupThemeColorValues.TEXT})`, sizeX: "30px", sizeY: "50px" }), h(FImage, { resource: "book", color: `var(${KupThemeColorValues.TEXT})`, sizeX: "30px", sizeY: "50px" })));
|
|
11396
11396
|
}, _KupDataTable_hideShowColumnDropArea = function _KupDataTable_hideShowColumnDropArea(show, th) {
|
|
11397
11397
|
if (show && th && (this.removableColumns || this.showGroups)) {
|
|
11398
|
-
__classPrivateFieldGet$
|
|
11399
|
-
__classPrivateFieldGet$
|
|
11400
|
-
__classPrivateFieldGet$
|
|
11401
|
-
__classPrivateFieldGet$
|
|
11402
|
-
th.clientWidth / 2 - __classPrivateFieldGet$
|
|
11398
|
+
__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f").classList.add('droparea--visible');
|
|
11399
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f"), th, 10, KupDynamicPositionPlacement.TOP);
|
|
11400
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f"));
|
|
11401
|
+
__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f").style.marginLeft =
|
|
11402
|
+
th.clientWidth / 2 - __classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f").clientWidth / 2 + 'px';
|
|
11403
11403
|
}
|
|
11404
11404
|
else {
|
|
11405
|
-
__classPrivateFieldGet$
|
|
11406
|
-
+__classPrivateFieldGet$
|
|
11405
|
+
__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f").classList.remove('droparea--visible');
|
|
11406
|
+
+__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").dynamicPosition.stop(__classPrivateFieldGet$4(this, _KupDataTable_dropareaRef, "f"));
|
|
11407
11407
|
}
|
|
11408
11408
|
}, _KupDataTable_handleColumnGroup = function _KupDataTable_handleColumnGroup(column2group) {
|
|
11409
11409
|
// Get sorted column current position
|
|
@@ -11471,19 +11471,19 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11471
11471
|
icon: icons[i],
|
|
11472
11472
|
id: codes[i],
|
|
11473
11473
|
selected: selectedCode == codes[i],
|
|
11474
|
-
value: __classPrivateFieldGet$
|
|
11474
|
+
value: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(value),
|
|
11475
11475
|
};
|
|
11476
11476
|
}
|
|
11477
11477
|
}
|
|
11478
11478
|
return listItems;
|
|
11479
11479
|
}, _KupDataTable_getFontSizeCodeFromDecode = function _KupDataTable_getFontSizeCodeFromDecode(decode) {
|
|
11480
|
-
return __classPrivateFieldGet$
|
|
11480
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_transcodeItem).call(this, decode, __classPrivateFieldGet$4(this, _KupDataTable_FONTSIZE_DECODES, "f"), __classPrivateFieldGet$4(this, _KupDataTable_FONTSIZE_CODES, "f"));
|
|
11481
11481
|
}, _KupDataTable_renderFontSizePanel = function _KupDataTable_renderFontSizePanel() {
|
|
11482
|
-
const listItems = __classPrivateFieldGet$
|
|
11482
|
+
const listItems = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_createListData).call(this, __classPrivateFieldGet$4(this, _KupDataTable_FONTSIZE_CODES, "f"), __classPrivateFieldGet$4(this, _KupDataTable_FONTSIZE_ICONS, "f"), this.fontsize);
|
|
11483
11483
|
const listData = { data: listItems, showIcons: true };
|
|
11484
11484
|
const textfieldData = {
|
|
11485
11485
|
trailingIcon: true,
|
|
11486
|
-
label: __classPrivateFieldGet$
|
|
11486
|
+
label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageFontsize.LABEL),
|
|
11487
11487
|
icon: 'arrow_drop_down',
|
|
11488
11488
|
};
|
|
11489
11489
|
const data = { 'kup-text-field': textfieldData, 'kup-list': listData };
|
|
@@ -11500,22 +11500,22 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11500
11500
|
text = KupLanguageFontsize.SMALL;
|
|
11501
11501
|
break;
|
|
11502
11502
|
}
|
|
11503
|
-
return (h("div", { class: "customize-element fontsize-panel" }, h("kup-combobox", { isSelect: true, data: data, initialValue: __classPrivateFieldGet$
|
|
11503
|
+
return (h("div", { class: "customize-element fontsize-panel" }, h("kup-combobox", { isSelect: true, data: data, initialValue: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(text), "onkup-combobox-itemclick": (e) => {
|
|
11504
11504
|
e.stopPropagation();
|
|
11505
|
-
this.fontsize = __classPrivateFieldGet$
|
|
11505
|
+
this.fontsize = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getFontSizeCodeFromDecode).call(this, e.detail.node.id);
|
|
11506
11506
|
} })));
|
|
11507
11507
|
}, _KupDataTable_getDensityCodeFromDecode = function _KupDataTable_getDensityCodeFromDecode(decode) {
|
|
11508
|
-
return __classPrivateFieldGet$
|
|
11508
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_transcodeItem).call(this, decode, __classPrivateFieldGet$4(this, _KupDataTable_DENSITY_DECODES, "f"), [
|
|
11509
11509
|
'dense',
|
|
11510
11510
|
'medium',
|
|
11511
11511
|
'wide',
|
|
11512
11512
|
]);
|
|
11513
11513
|
}, _KupDataTable_renderDensityPanel = function _KupDataTable_renderDensityPanel() {
|
|
11514
|
-
const listItems = __classPrivateFieldGet$
|
|
11514
|
+
const listItems = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_createListData).call(this, ['dense', 'medium', 'wide'], __classPrivateFieldGet$4(this, _KupDataTable_DENSITY_ICONS, "f"), this.density);
|
|
11515
11515
|
const listData = { data: listItems, showIcons: true };
|
|
11516
11516
|
const textfieldData = {
|
|
11517
11517
|
trailingIcon: true,
|
|
11518
|
-
label: __classPrivateFieldGet$
|
|
11518
|
+
label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageDensity.LABEL),
|
|
11519
11519
|
icon: 'arrow_drop_down',
|
|
11520
11520
|
};
|
|
11521
11521
|
const data = { 'kup-text-field': textfieldData, 'kup-list': listData };
|
|
@@ -11532,14 +11532,14 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11532
11532
|
text = KupLanguageDensity.WIDE;
|
|
11533
11533
|
break;
|
|
11534
11534
|
}
|
|
11535
|
-
return (h("div", { class: "customize-element density-panel" }, h("kup-combobox", { isSelect: true, initialValue: __classPrivateFieldGet$
|
|
11535
|
+
return (h("div", { class: "customize-element density-panel" }, h("kup-combobox", { isSelect: true, initialValue: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(text), selectMode: ItemsDisplayMode.DESCRIPTION, data: data, "onkup-combobox-itemclick": (e) => {
|
|
11536
11536
|
e.stopPropagation();
|
|
11537
|
-
this.density = __classPrivateFieldGet$
|
|
11537
|
+
this.density = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getDensityCodeFromDecode).call(this, e.detail.node.id);
|
|
11538
11538
|
} })));
|
|
11539
11539
|
}, _KupDataTable_getGridCodeFromDecode = function _KupDataTable_getGridCodeFromDecode(decode) {
|
|
11540
|
-
return __classPrivateFieldGet$
|
|
11540
|
+
return __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_transcodeItem).call(this, decode, __classPrivateFieldGet$4(this, _KupDataTable_GRID_DECODES, "f"), __classPrivateFieldGet$4(this, _KupDataTable_GRID_CODES, "f"));
|
|
11541
11541
|
}, _KupDataTable_renderTransposeSwitch = function _KupDataTable_renderTransposeSwitch() {
|
|
11542
|
-
return (h("div", { class: "customize-element grid-panel" }, h("kup-switch", { checked: this.transpose, label: __classPrivateFieldGet$
|
|
11542
|
+
return (h("div", { class: "customize-element grid-panel" }, h("kup-switch", { checked: this.transpose, label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.TRANSPOSE_DATA), leadingLabel: true, "onkup-switch-change": (e) => {
|
|
11543
11543
|
e.stopPropagation();
|
|
11544
11544
|
if (e.detail.value === 'on') {
|
|
11545
11545
|
this.transpose = true;
|
|
@@ -11549,16 +11549,16 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11549
11549
|
}
|
|
11550
11550
|
} })));
|
|
11551
11551
|
}, _KupDataTable_renderTotalsMatrix = function _KupDataTable_renderTotalsMatrix() {
|
|
11552
|
-
return (h("div", { class: "customize-element grid-panel" }, h("kup-button", { title: __classPrivateFieldGet$
|
|
11552
|
+
return (h("div", { class: "customize-element grid-panel" }, h("kup-button", { title: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.TOTALS_TABLE) +
|
|
11553
11553
|
' (' +
|
|
11554
|
-
__classPrivateFieldGet$
|
|
11555
|
-
')', label: __classPrivateFieldGet$
|
|
11554
|
+
__classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.EXPERIMENTAL_FEAT) +
|
|
11555
|
+
')', label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGeneric.TOTALS_TABLE), icon: "exposure", "onkup-button-click": () => __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_switchToTotalsMatrix).call(this) })));
|
|
11556
11556
|
}, _KupDataTable_renderGridPanel = function _KupDataTable_renderGridPanel() {
|
|
11557
|
-
const listItems = __classPrivateFieldGet$
|
|
11557
|
+
const listItems = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_createListData).call(this, __classPrivateFieldGet$4(this, _KupDataTable_GRID_CODES, "f"), __classPrivateFieldGet$4(this, _KupDataTable_GRID_ICONS, "f"), this.showGrid);
|
|
11558
11558
|
const listData = { data: listItems, showIcons: true };
|
|
11559
11559
|
const textfieldData = {
|
|
11560
11560
|
trailingIcon: true,
|
|
11561
|
-
label: __classPrivateFieldGet$
|
|
11561
|
+
label: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(KupLanguageGrid.LABEL),
|
|
11562
11562
|
icon: 'arrow_drop_down',
|
|
11563
11563
|
};
|
|
11564
11564
|
const data = { 'kup-text-field': textfieldData, 'kup-list': listData };
|
|
@@ -11578,9 +11578,9 @@ _KupDataTable_initialized = new WeakMap(), _KupDataTable_rows = new WeakMap(), _
|
|
|
11578
11578
|
text = KupLanguageGrid.ROW;
|
|
11579
11579
|
break;
|
|
11580
11580
|
}
|
|
11581
|
-
return (h("div", { class: "customize-element grid-panel" }, h("kup-combobox", { isSelect: true, initialValue: __classPrivateFieldGet$
|
|
11581
|
+
return (h("div", { class: "customize-element grid-panel" }, h("kup-combobox", { isSelect: true, initialValue: __classPrivateFieldGet$4(this, _KupDataTable_kupManager, "f").language.translate(text), data: data, "onkup-combobox-itemclick": (e) => {
|
|
11582
11582
|
e.stopPropagation();
|
|
11583
|
-
const grid = __classPrivateFieldGet$
|
|
11583
|
+
const grid = __classPrivateFieldGet$4(this, _KupDataTable_instances, "m", _KupDataTable_getGridCodeFromDecode).call(this, e.detail.value);
|
|
11584
11584
|
this.showGrid = grid;
|
|
11585
11585
|
} })));
|
|
11586
11586
|
};
|
|
@@ -11984,7 +11984,7 @@ var KupDialogProps;
|
|
|
11984
11984
|
|
|
11985
11985
|
const kupDialogCss = ":host{--kup_dialog_header_height:var(--kup-dialog-header-height, 2em);box-sizing:border-box;display:block;height:var(--kup_dialog_height);left:var(--kup_dialog_left);min-height:var(--kup_dialog_height);min-width:var(--kup_dialog_width);position:absolute;top:var(--kup_dialog_top);transition:opacity 0.25s ease-in;width:var(--kup_dialog_width)}#kup-component{height:100%;width:100%}[fade-in]{opacity:0}[fade-in] ::slotted{display:none}.header{background-color:var(--kup-title-background-color);color:var(--kup-title-color);display:flex;flex-direction:row;height:var(--kup_dialog_header_height);position:relative;width:100%}.header__title{font-weight:bold;line-height:2em;padding-left:0.5em;padding-right:2em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.header__close.f-image{--kup-icon-color:var(--kup-title-color);cursor:pointer;margin-right:0;transition:opacity 0.25s;position:absolute;right:0;background:var(--kup-title-background-color)}.header__close.f-image:hover{opacity:0.5}.content{height:calc(100% - var(--kup_dialog_header_height));overflow:auto;user-select:text}";
|
|
11986
11986
|
|
|
11987
|
-
var __classPrivateFieldGet$
|
|
11987
|
+
var __classPrivateFieldGet$3 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
11988
11988
|
if (kind === "a" && !f)
|
|
11989
11989
|
throw new TypeError("Private accessor was defined without a getter");
|
|
11990
11990
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -12067,12 +12067,12 @@ const KupDialog = class {
|
|
|
12067
12067
|
/* L i f e c y c l e H o o k s */
|
|
12068
12068
|
/*-------------------------------------------------*/
|
|
12069
12069
|
componentWillLoad() {
|
|
12070
|
-
__classPrivateFieldGet$
|
|
12071
|
-
__classPrivateFieldGet$
|
|
12070
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").debug.logLoad(this, false);
|
|
12071
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").theme.register(this);
|
|
12072
12072
|
}
|
|
12073
12073
|
componentDidLoad() {
|
|
12074
12074
|
var _a;
|
|
12075
|
-
__classPrivateFieldGet$
|
|
12075
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").interact.dialogify(this.rootElement, __classPrivateFieldGet$3(this, _KupDialog_header, "f") ? __classPrivateFieldGet$3(this, _KupDialog_header, "f") : null, !this.resizable);
|
|
12076
12076
|
if ((_a = this.autoCenter) === null || _a === void 0 ? void 0 : _a.onReady) {
|
|
12077
12077
|
this.recalcPosition().then(() => {
|
|
12078
12078
|
this.rootElement.removeAttribute('fade-in');
|
|
@@ -12082,7 +12082,7 @@ const KupDialog = class {
|
|
|
12082
12082
|
this.rootElement.removeAttribute('fade-in');
|
|
12083
12083
|
}
|
|
12084
12084
|
if (this.modal) {
|
|
12085
|
-
__classPrivateFieldGet$
|
|
12085
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").interact.showModalBackdrop(this.modal.closeOnBackdropClick
|
|
12086
12086
|
? () => {
|
|
12087
12087
|
this.close();
|
|
12088
12088
|
}
|
|
@@ -12092,13 +12092,13 @@ const KupDialog = class {
|
|
|
12092
12092
|
comp: this,
|
|
12093
12093
|
id: this.rootElement.id,
|
|
12094
12094
|
});
|
|
12095
|
-
__classPrivateFieldGet$
|
|
12095
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").debug.logLoad(this, true);
|
|
12096
12096
|
}
|
|
12097
12097
|
componentWillRender() {
|
|
12098
|
-
__classPrivateFieldGet$
|
|
12098
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").debug.logRender(this, false);
|
|
12099
12099
|
}
|
|
12100
12100
|
componentDidRender() {
|
|
12101
|
-
__classPrivateFieldGet$
|
|
12101
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").debug.logRender(this, true);
|
|
12102
12102
|
}
|
|
12103
12103
|
render() {
|
|
12104
12104
|
var _a;
|
|
@@ -12106,13 +12106,13 @@ const KupDialog = class {
|
|
|
12106
12106
|
'--kup_dialog_height': this.sizeY ? this.sizeY : 'auto',
|
|
12107
12107
|
'--kup_dialog_width': this.sizeX ? this.sizeX : 'auto',
|
|
12108
12108
|
};
|
|
12109
|
-
return (h(Host, { "fade-in": true, style: style }, h("style", null, __classPrivateFieldGet$
|
|
12109
|
+
return (h(Host, { "fade-in": true, style: style }, h("style", null, __classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { id: componentWrapperId }, this.header ? (h("div", { class: "header", ref: (el) => (__classPrivateFieldSet$1(this, _KupDialog_header, el, "f")) }, this.header.title ? (h("div", { class: "header__title" }, this.header.title)) : null, ((_a = this.header.icons) === null || _a === void 0 ? void 0 : _a.close) ? (h(FImage, { onClick: () => this.close(), sizeX: "1.25em", sizeY: "100%", resource: "clear", wrapperClass: "header__close" })) : null)) : null, h("div", { class: "content" }, h("slot", null)))));
|
|
12110
12110
|
}
|
|
12111
12111
|
disconnectedCallback() {
|
|
12112
12112
|
if (this.modal) {
|
|
12113
|
-
__classPrivateFieldGet$
|
|
12113
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").interact.hideModalBackdrop();
|
|
12114
12114
|
}
|
|
12115
|
-
__classPrivateFieldGet$
|
|
12115
|
+
__classPrivateFieldGet$3(this, _KupDialog_kupManager, "f").theme.unregister(this);
|
|
12116
12116
|
}
|
|
12117
12117
|
get rootElement() { return getElement$1(this); }
|
|
12118
12118
|
};
|
|
@@ -14238,7 +14238,7 @@ KupImage.style = kupImageCss;
|
|
|
14238
14238
|
|
|
14239
14239
|
const kupListCss = ":host{--kup_list_background:var(\n --kup-list-background,\n var(--kup-background-color)\n );--kup_list_color:var(--kup-list-color, var(--kup-text-color));--kup_list_font_family:var(--kup-list-font-family, var(--kup-font-family));--kup_list_font_size:var(--kup-list-font-size, var(--kup-font-size));--kup_list_font_weight:var(--kup-list-font-weight, 400);--kup_list_group_item_height:var(--kup-list-group-item-height, 3em);--kup_list_item_height:var(--kup-list-item-height, 2.5em);--kup_list_item_padding_left:var(--kup-list-item-padding, 0.75em);--kup_list_item_padding_right:var(--kup-list-item-padding, 0.75em);--kup_list_max_height_as_menu:var(--kup-list-max-height-as-menu, 33vh);--kup_list_primary_color:var(\n --kup-list-primary-color,\n var(--kup-primary-color)\n );--kup_list_primary_color_rgb:var(\n --kup-list-primary-color-rgb,\n var(--kup-primary-color-rgb)\n );--kup_list_separator_color:var(\n --kup-list-separator-color,\n rgba(var(--kup-text-color-rgb), 0.25)\n );--kup_list_transition:var(--kup-list-transition, 120ms);display:block;font-family:var(--kup_list_font_family);font-size:var(--kup_list_font_size);outline:none}.list{background:var(--kup_list_background);color:var(--kup_list_color);font-weight:var(--kup_list_font_weight);letter-spacing:0.009375em;line-height:1.5em;list-style-type:none;margin:0;padding:0.5em 0;text-decoration:inherit;text-transform:inherit}.list--empty{padding:0}.list .list-item{display:-ms-flexbox;display:flex;height:var(--kup_list_item_height);position:relative;-ms-flex-align:center;align-items:center;-ms-flex-pack:start;justify-content:flex-start;padding-left:var(--kup_list_item_padding_left);padding-right:calc(var(--kup_list_item_padding_left) + var(--kup_list_item_expand_padding, 0px));overflow:hidden;outline:none;transition:background-color var(--kup_list_transition), color var(--kup_list_transition)}.list .list-item[role=checkbox],.list .list-item[role=radio]{height:var(--kup_list_group_item_height)}.list .list-item.list-item--activated,.list .list-item.list-item--activated .list-item__graphic,.list .list-item.list-item--selected,.list .list-item.list-item--selected .list-item__graphic{background-color:rgba(var(--kup_list_primary_color_rgb), 0.175);color:var(--kup_list_primary_color)}.list .list-item .list-item__text{-o-text-overflow:ellipsis;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.list .list-item .list-item__primary-text{-o-text-overflow:ellipsis;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;margin-top:0;line-height:normal;margin-bottom:-1.5em;display:block}.list .list-item .list-item__primary-text:before{display:inline-block;width:0;height:1.5em;content:\"\";vertical-align:0}.list .list-item .list-item__primary-text:after{display:inline-block;width:0;height:2em;content:\"\";vertical-align:-2em}.list .list-item .list-item__secondary-text{-moz-osx-font-smoothing:grayscale;-o-text-overflow:ellipsis;-webkit-font-smoothing:antialiased;display:block;font-size:0.875em;font-weight:400;letter-spacing:0.0178571429em;line-height:1.25em;text-decoration:inherit;text-transform:inherit;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;margin-top:0;line-height:normal;color:var(--kup_list_color);opacity:0.75}.list .list-item .kup-icon{margin:0;margin-right:0.75em}.list .list-item kup-checkbox{margin:0}.list .list-divider{background-color:var(--kup_list_separator_color);height:1px;padding:0;background-clip:content-box}.list.list--two-line .list-item{height:3.6em}.list.list--two-line .list-item__text{-ms-flex-item-align:start;align-self:flex-start}.list:not(.list--non-interactive)>:not(.list-item--disabled).list-item{cursor:pointer}.list:not(.list--non-interactive)>:not(.list-item--disabled).list-item label{cursor:pointer}.list:not(.list--non-interactive) .list-item:not(.list-item--selected):hover,.list:not(.list--non-interactive) .list-item:not(.list-item--selected).list-item--focused{background-color:var(--kup-hover-background-color);color:var(--kup-hover-color)}.list.text-hidden .list-item__text{display:none}.kup-menu{animation:fade-in 0.25s ease-out;background-color:var(--kup-background-color);box-shadow:var(--kup-box-shadow);color:var(--kup-text-color);display:none;max-height:var(--kup_list_max_height_as_menu);overflow:auto;position:relative;transform:none;transform-origin:unset;transition:height 0.2s;user-select:none;will-change:unset}.kup-menu.visible{display:block}.kup-menu .list-item__text{user-select:none}:host([nested-list]){--kup_list_item_expand_padding:1.5em;max-width:250px}:host([nested-list]) .kup-menu{max-height:unset;overflow:visible}:host([nested-list]) kup-list{display:none;left:100%;position:absolute;top:0}:host([nested-list]) .list-item{overflow:visible}:host([nested-list]) .list-item__expand-icon{position:absolute;right:0}:host([nested-list]) .list-item:hover kup-list{display:block}:host(.kup-paddingless) .list{padding:0}:host(.kup-danger){--kup-list-primary-color:var(--kup-danger-color);--kup-list-primary-color-rgb:var(--kup-danger-color-rgb)}:host(.kup-info){--kup-list-primary-color:var(--kup-info-color);--kup-list-primary-color-rgb:var(--kup-info-color-rgb)}:host(.kup-secondary){--kup-list-primary-color:var(--kup-secondary-color);--kup-list-primary-color-rgb:var(--kup-secondary-color-rgb)}:host(.kup-success){--kup-list-primary-color:var(--kup-success-color);--kup-list-primary-color-rgb:var(--kup-success-color-rgb)}:host(.kup-warning){--kup-list-primary-color:var(--kup-warning-color);--kup-list-primary-color-rgb:var(--kup-warning-color-rgb)}";
|
|
14240
14240
|
|
|
14241
|
-
var __classPrivateFieldGet$
|
|
14241
|
+
var __classPrivateFieldGet$2 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
14242
14242
|
if (kind === "a" && !f)
|
|
14243
14243
|
throw new TypeError("Private accessor was defined without a getter");
|
|
14244
14244
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
@@ -14299,7 +14299,7 @@ const KupList = class {
|
|
|
14299
14299
|
});
|
|
14300
14300
|
}
|
|
14301
14301
|
onKupClick(index) {
|
|
14302
|
-
__classPrivateFieldGet$
|
|
14302
|
+
__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_handleSelection).call(this, index);
|
|
14303
14303
|
}
|
|
14304
14304
|
/*-------------------------------------------------*/
|
|
14305
14305
|
/* L i s t e n e r s */
|
|
@@ -14320,7 +14320,7 @@ const KupList = class {
|
|
|
14320
14320
|
case 'Enter':
|
|
14321
14321
|
e.preventDefault();
|
|
14322
14322
|
e.stopPropagation();
|
|
14323
|
-
__classPrivateFieldGet$
|
|
14323
|
+
__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_handleSelection).call(this, this.focused);
|
|
14324
14324
|
break;
|
|
14325
14325
|
}
|
|
14326
14326
|
}
|
|
@@ -14346,10 +14346,10 @@ const KupList = class {
|
|
|
14346
14346
|
else {
|
|
14347
14347
|
this.focused++;
|
|
14348
14348
|
}
|
|
14349
|
-
if (this.focused > __classPrivateFieldGet$
|
|
14349
|
+
if (this.focused > __classPrivateFieldGet$2(this, _KupList_listItems, "f").length - 1) {
|
|
14350
14350
|
this.focused = 0;
|
|
14351
14351
|
}
|
|
14352
|
-
__classPrivateFieldGet$
|
|
14352
|
+
__classPrivateFieldGet$2(this, _KupList_listItems, "f")[this.focused].focus();
|
|
14353
14353
|
}
|
|
14354
14354
|
/**
|
|
14355
14355
|
* Focuses the previous element of the list.
|
|
@@ -14370,9 +14370,9 @@ const KupList = class {
|
|
|
14370
14370
|
this.focused--;
|
|
14371
14371
|
}
|
|
14372
14372
|
if (this.focused < 0) {
|
|
14373
|
-
this.focused = __classPrivateFieldGet$
|
|
14373
|
+
this.focused = __classPrivateFieldGet$2(this, _KupList_listItems, "f").length - 1;
|
|
14374
14374
|
}
|
|
14375
|
-
__classPrivateFieldGet$
|
|
14375
|
+
__classPrivateFieldGet$2(this, _KupList_listItems, "f")[this.focused].focus();
|
|
14376
14376
|
}
|
|
14377
14377
|
/**
|
|
14378
14378
|
* Used to retrieve component's props values.
|
|
@@ -14409,7 +14409,7 @@ const KupList = class {
|
|
|
14409
14409
|
if (index === undefined) {
|
|
14410
14410
|
index = this.focused;
|
|
14411
14411
|
}
|
|
14412
|
-
__classPrivateFieldGet$
|
|
14412
|
+
__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_handleSelection).call(this, index);
|
|
14413
14413
|
}
|
|
14414
14414
|
/**
|
|
14415
14415
|
* Sets the props to the component.
|
|
@@ -14422,8 +14422,8 @@ const KupList = class {
|
|
|
14422
14422
|
/* L i f e c y c l e H o o k s */
|
|
14423
14423
|
/*-------------------------------------------------*/
|
|
14424
14424
|
componentWillLoad() {
|
|
14425
|
-
__classPrivateFieldGet$
|
|
14426
|
-
__classPrivateFieldGet$
|
|
14425
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").debug.logLoad(this, false);
|
|
14426
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").theme.register(this);
|
|
14427
14427
|
for (let index = 0; index < this.data.length; index++) {
|
|
14428
14428
|
const el = this.data[index];
|
|
14429
14429
|
if (el.selected) {
|
|
@@ -14432,10 +14432,10 @@ const KupList = class {
|
|
|
14432
14432
|
}
|
|
14433
14433
|
}
|
|
14434
14434
|
componentDidLoad() {
|
|
14435
|
-
__classPrivateFieldGet$
|
|
14435
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").debug.logLoad(this, true);
|
|
14436
14436
|
}
|
|
14437
14437
|
componentWillRender() {
|
|
14438
|
-
__classPrivateFieldGet$
|
|
14438
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").debug.logRender(this, false);
|
|
14439
14439
|
}
|
|
14440
14440
|
componentDidRender() {
|
|
14441
14441
|
if (this.isMenu &&
|
|
@@ -14446,7 +14446,7 @@ const KupList = class {
|
|
|
14446
14446
|
this.rootElement.focus();
|
|
14447
14447
|
}, 0);
|
|
14448
14448
|
}
|
|
14449
|
-
__classPrivateFieldGet$
|
|
14449
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").debug.logRender(this, true);
|
|
14450
14450
|
}
|
|
14451
14451
|
render() {
|
|
14452
14452
|
__classPrivateFieldSet(this, _KupList_listItems, [], "f");
|
|
@@ -14458,7 +14458,7 @@ const KupList = class {
|
|
|
14458
14458
|
wrapperClass += ' visible';
|
|
14459
14459
|
}
|
|
14460
14460
|
}
|
|
14461
|
-
__classPrivateFieldGet$
|
|
14461
|
+
__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_checkRoleType).call(this);
|
|
14462
14462
|
if (this.selectable != true) {
|
|
14463
14463
|
componentClass += ' list--non-interactive';
|
|
14464
14464
|
}
|
|
@@ -14473,17 +14473,17 @@ const KupList = class {
|
|
|
14473
14473
|
}
|
|
14474
14474
|
let roleAttr = this.roleType;
|
|
14475
14475
|
let ariaMultiSelectable = 'false';
|
|
14476
|
-
if (__classPrivateFieldGet$
|
|
14476
|
+
if (__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isMultiSelection).call(this)) {
|
|
14477
14477
|
ariaMultiSelectable = 'true';
|
|
14478
14478
|
}
|
|
14479
14479
|
__classPrivateFieldSet(this, _KupList_radios, [], "f");
|
|
14480
14480
|
let index = 0;
|
|
14481
|
-
return (h(Host, null, h("style", null, __classPrivateFieldGet$
|
|
14482
|
-
.filter((item) => __classPrivateFieldGet$
|
|
14483
|
-
.map((item) => __classPrivateFieldGet$
|
|
14481
|
+
return (h(Host, null, h("style", null, __classPrivateFieldGet$2(this, _KupList_kupManager, "f").theme.setKupStyle(this.rootElement)), h("div", { id: "kup-component", class: wrapperClass }, h("ul", { class: componentClass, role: roleAttr, "aria-multiselectable": ariaMultiSelectable }, this.data
|
|
14482
|
+
.filter((item) => __classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_itemCompliant).call(this, item))
|
|
14483
|
+
.map((item) => __classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_renderListItem).call(this, item, index++))))));
|
|
14484
14484
|
}
|
|
14485
14485
|
disconnectedCallback() {
|
|
14486
|
-
__classPrivateFieldGet$
|
|
14486
|
+
__classPrivateFieldGet$2(this, _KupList_kupManager, "f").theme.unregister(this);
|
|
14487
14487
|
}
|
|
14488
14488
|
get rootElement() { return getElement$1(this); }
|
|
14489
14489
|
};
|
|
@@ -14534,7 +14534,7 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14534
14534
|
if (this.showIcons == true &&
|
|
14535
14535
|
item.icon != null &&
|
|
14536
14536
|
item.icon.trim() != '') {
|
|
14537
|
-
imageTag = __classPrivateFieldGet$
|
|
14537
|
+
imageTag = __classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_getIconTag).call(this, item.icon);
|
|
14538
14538
|
}
|
|
14539
14539
|
let primaryTextTag = [
|
|
14540
14540
|
getIdOfItemByDisplayMode(item, this.displayMode, ' - '),
|
|
@@ -14550,9 +14550,9 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14550
14550
|
}
|
|
14551
14551
|
let classAttr = 'list-item';
|
|
14552
14552
|
let tabIndexAttr = item.selected == true ? '0' : '-1';
|
|
14553
|
-
if (!__classPrivateFieldGet$
|
|
14553
|
+
if (!__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isNested).call(this) &&
|
|
14554
14554
|
item.selected == true &&
|
|
14555
|
-
__classPrivateFieldGet$
|
|
14555
|
+
__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isListBoxRule).call(this)) {
|
|
14556
14556
|
classAttr += ' list-item--selected';
|
|
14557
14557
|
}
|
|
14558
14558
|
if (this.focused === index) {
|
|
@@ -14568,7 +14568,7 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14568
14568
|
imageTag,
|
|
14569
14569
|
h("span", { class: "list-item__text" }, primaryTextTag, secTextTag),
|
|
14570
14570
|
];
|
|
14571
|
-
if (__classPrivateFieldGet$
|
|
14571
|
+
if (__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isRadioButtonRule).call(this)) {
|
|
14572
14572
|
roleAttr = 'radio';
|
|
14573
14573
|
ariaCheckedAttr = item.selected == true ? 'true' : 'false';
|
|
14574
14574
|
let dataTmp = [
|
|
@@ -14582,12 +14582,12 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14582
14582
|
display: 'none',
|
|
14583
14583
|
};
|
|
14584
14584
|
innerSpanTag = [
|
|
14585
|
-
h("span", { class: "list-item__graphic" }, h("input", { type: "radio", style: trickForMDC }), h("kup-radio", { data: dataTmp, id: this.rootElement.id + '_' + index, ref: (el) => (__classPrivateFieldGet$
|
|
14585
|
+
h("span", { class: "list-item__graphic" }, h("input", { type: "radio", style: trickForMDC }), h("kup-radio", { data: dataTmp, id: this.rootElement.id + '_' + index, ref: (el) => (__classPrivateFieldGet$2(this, _KupList_radios, "f")[index] = el) })),
|
|
14586
14586
|
imageTag,
|
|
14587
14587
|
h("label", { class: "list-item__text", htmlFor: this.rootElement.id + '_' + index }, primaryTextTag, secTextTag),
|
|
14588
14588
|
];
|
|
14589
14589
|
}
|
|
14590
|
-
else if (__classPrivateFieldGet$
|
|
14590
|
+
else if (__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isCheckBoxRule).call(this)) {
|
|
14591
14591
|
roleAttr = 'checkbox';
|
|
14592
14592
|
ariaCheckedAttr = item.selected == true ? 'true' : 'false';
|
|
14593
14593
|
let checkedAttr = item.selected == true ? true : false;
|
|
@@ -14605,14 +14605,14 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14605
14605
|
vNodes.push(h("li", { role: "separator", class: "list-divider" }));
|
|
14606
14606
|
}
|
|
14607
14607
|
vNodes.push(h("li", { ref: (el) => {
|
|
14608
|
-
__classPrivateFieldGet$
|
|
14608
|
+
__classPrivateFieldGet$2(this, _KupList_listItems, "f").push(el);
|
|
14609
14609
|
}, class: classAttr, role: roleAttr, tabindex: tabIndexAttr, "data-id": item.id, "aria-selected": ariaSelectedAttr, "aria-checked": ariaCheckedAttr, onBlur: !this.selectable
|
|
14610
14610
|
? (e) => e.stopPropagation()
|
|
14611
14611
|
: () => this.onKupBlur(), onFocus: !this.selectable
|
|
14612
14612
|
? (e) => e.stopPropagation()
|
|
14613
14613
|
: () => this.onKupFocus(), onClick: !this.selectable
|
|
14614
14614
|
? (e) => e.stopPropagation()
|
|
14615
|
-
: __classPrivateFieldGet$
|
|
14615
|
+
: __classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isNested).call(this)
|
|
14616
14616
|
? (e) => {
|
|
14617
14617
|
e.stopPropagation();
|
|
14618
14618
|
this.onKupClick(index);
|
|
@@ -14633,7 +14633,7 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14633
14633
|
};
|
|
14634
14634
|
return (h(FImage, Object.assign({}, propsFImage, { resource: icon, wrapperClass: `icon-button__icon kup-icon` })));
|
|
14635
14635
|
}, _KupList_isMultiSelection = function _KupList_isMultiSelection() {
|
|
14636
|
-
return __classPrivateFieldGet$
|
|
14636
|
+
return __classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isCheckBoxRule).call(this);
|
|
14637
14637
|
}, _KupList_isCheckBoxRule = function _KupList_isCheckBoxRule() {
|
|
14638
14638
|
return this.roleType == KupListRole.GROUP;
|
|
14639
14639
|
}, _KupList_isRadioButtonRule = function _KupList_isRadioButtonRule() {
|
|
@@ -14641,7 +14641,7 @@ _KupList_kupManager = new WeakMap(), _KupList_radios = new WeakMap(), _KupList_l
|
|
|
14641
14641
|
}, _KupList_isListBoxRule = function _KupList_isListBoxRule() {
|
|
14642
14642
|
return this.roleType == KupListRole.LISTBOX;
|
|
14643
14643
|
}, _KupList_checkRoleType = function _KupList_checkRoleType() {
|
|
14644
|
-
if (!__classPrivateFieldGet$
|
|
14644
|
+
if (!__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isCheckBoxRule).call(this) && !__classPrivateFieldGet$2(this, _KupList_instances, "m", _KupList_isRadioButtonRule).call(this)) {
|
|
14645
14645
|
this.roleType = KupListRole.LISTBOX;
|
|
14646
14646
|
}
|
|
14647
14647
|
}, _KupList_itemCompliant = function _KupList_itemCompliant(item) {
|
|
@@ -15629,11 +15629,13 @@ KupTabBar.style = kupTabBarCss;
|
|
|
15629
15629
|
*/
|
|
15630
15630
|
var KupTextFieldProps;
|
|
15631
15631
|
(function (KupTextFieldProps) {
|
|
15632
|
+
KupTextFieldProps["allowNegative"] = "When true, could be input negative numbers. It has effect only with number input type.";
|
|
15632
15633
|
KupTextFieldProps["customStyle"] = "Custom style of the component.";
|
|
15633
15634
|
KupTextFieldProps["decimals"] = "Number of decimals (should be used when inputType is number).";
|
|
15634
15635
|
KupTextFieldProps["disabled"] = "When set to true, the component is disabled.";
|
|
15635
15636
|
KupTextFieldProps["emitSubmitEventOnEnter"] = "When the text field is part of the autocomplete component and the list is opened, enter key selects the item and doesn't submit.";
|
|
15636
15637
|
KupTextFieldProps["fullWidth"] = "When set to true, the component will be rendered at full width.";
|
|
15638
|
+
KupTextFieldProps["group"] = "When true, the number will be formatted with group separator. It has effect only with number input type.";
|
|
15637
15639
|
KupTextFieldProps["helper"] = "When set, its content will be shown as a help text below the field.";
|
|
15638
15640
|
KupTextFieldProps["helperEnabled"] = "When true, the helper will be displayed.";
|
|
15639
15641
|
KupTextFieldProps["helperWhenFocused"] = "When set, the helper will be shown only when the field is focused.";
|
|
@@ -15641,6 +15643,7 @@ var KupTextFieldProps;
|
|
|
15641
15643
|
KupTextFieldProps["initialValue"] = "Sets the initial value of the component";
|
|
15642
15644
|
KupTextFieldProps["inputMode"] = "The HTML inputmode of the input element. It has no effect on text areas.";
|
|
15643
15645
|
KupTextFieldProps["inputType"] = "The HTML type of the input element. It has no effect on text areas.";
|
|
15646
|
+
KupTextFieldProps["integers"] = "Number of integers (should be used when inputType is number).";
|
|
15644
15647
|
KupTextFieldProps["isClearable"] = "Enables a clear trailing icon.";
|
|
15645
15648
|
KupTextFieldProps["label"] = "When set, its content will be shown as a label.";
|
|
15646
15649
|
KupTextFieldProps["leadingLabel"] = "When set to true, the label will be on the left of the component.";
|
|
@@ -15658,6 +15661,14 @@ var KupTextFieldProps;
|
|
|
15658
15661
|
|
|
15659
15662
|
const kupTextFieldCss = ":host{display:block;font-size:var(--kup-font-size)}:host([full-width]){width:100%}:host([full-width]) #kup-component{width:100%}:host(.kup-full-height){height:100%}:host(.kup-full-height) #kup-component,:host(.kup-full-height) .f-text-field,:host(.kup-full-height) .mdc-text-field{height:100%}:host(.kup-shaped) #kup-component .mdc-text-field.mdc-text-field--filled{border-radius:16px 16px 0 0}:host(.kup-shaped) #kup-component .mdc-text-field.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-radius:28px 0 0 28px;width:28px}:host(.kup-shaped) #kup-component .mdc-text-field.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-radius:0 28px 28px 0;width:28px}";
|
|
15660
15663
|
|
|
15664
|
+
var __classPrivateFieldGet$1 = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
15665
|
+
if (kind === "a" && !f)
|
|
15666
|
+
throw new TypeError("Private accessor was defined without a getter");
|
|
15667
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
15668
|
+
throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
15669
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
15670
|
+
};
|
|
15671
|
+
var _KupTextField_instances, _KupTextField_getValueForOutput, _KupTextField_setValueFromEventTaget;
|
|
15661
15672
|
const KupTextField = class {
|
|
15662
15673
|
constructor(hostRef) {
|
|
15663
15674
|
registerInstance(this, hostRef);
|
|
@@ -15669,16 +15680,19 @@ const KupTextField = class {
|
|
|
15669
15680
|
this.kupIconClick = createEvent(this, "kup-textfield-iconclick", 6);
|
|
15670
15681
|
this.kupClearIconClick = createEvent(this, "kup-textfield-cleariconclick", 6);
|
|
15671
15682
|
this.kupTextFieldSubmit = createEvent(this, "kup-textfield-submit", 6);
|
|
15683
|
+
_KupTextField_instances.add(this);
|
|
15672
15684
|
/**
|
|
15673
15685
|
* Instance of the KupManager class.
|
|
15674
15686
|
*/
|
|
15675
15687
|
this.kupManager = kupManagerInstance();
|
|
15676
15688
|
this.value = '';
|
|
15689
|
+
this.allowNegative = false;
|
|
15677
15690
|
this.customStyle = '';
|
|
15678
15691
|
this.decimals = null;
|
|
15679
15692
|
this.disabled = false;
|
|
15680
15693
|
this.emitSubmitEventOnEnter = true;
|
|
15681
15694
|
this.fullWidth = false;
|
|
15695
|
+
this.group = false;
|
|
15682
15696
|
this.helper = null;
|
|
15683
15697
|
this.helperEnabled = true;
|
|
15684
15698
|
this.helperWhenFocused = false;
|
|
@@ -15686,6 +15700,7 @@ const KupTextField = class {
|
|
|
15686
15700
|
this.initialValue = '';
|
|
15687
15701
|
this.inputMode = null;
|
|
15688
15702
|
this.inputType = 'text';
|
|
15703
|
+
this.integers = null;
|
|
15689
15704
|
this.isClearable = false;
|
|
15690
15705
|
this.label = null;
|
|
15691
15706
|
this.leadingLabel = false;
|
|
@@ -15702,35 +15717,36 @@ const KupTextField = class {
|
|
|
15702
15717
|
}
|
|
15703
15718
|
onKupBlur(event) {
|
|
15704
15719
|
const { target } = event;
|
|
15720
|
+
__classPrivateFieldGet$1(this, _KupTextField_instances, "m", _KupTextField_setValueFromEventTaget).call(this, target);
|
|
15705
15721
|
this.kupBlur.emit({
|
|
15706
15722
|
comp: this,
|
|
15707
15723
|
id: this.rootElement.id,
|
|
15708
|
-
value:
|
|
15724
|
+
value: this.value,
|
|
15709
15725
|
});
|
|
15710
15726
|
}
|
|
15711
15727
|
onKupChange(event) {
|
|
15712
15728
|
const { target } = event;
|
|
15713
|
-
this.
|
|
15729
|
+
__classPrivateFieldGet$1(this, _KupTextField_instances, "m", _KupTextField_setValueFromEventTaget).call(this, target);
|
|
15714
15730
|
this.kupChange.emit({
|
|
15715
15731
|
comp: this,
|
|
15716
15732
|
id: this.rootElement.id,
|
|
15717
|
-
value:
|
|
15733
|
+
value: this.value,
|
|
15718
15734
|
});
|
|
15719
15735
|
}
|
|
15720
15736
|
onKupClick(event) {
|
|
15721
15737
|
const { target } = event;
|
|
15738
|
+
__classPrivateFieldGet$1(this, _KupTextField_instances, "m", _KupTextField_setValueFromEventTaget).call(this, target);
|
|
15722
15739
|
this.kupClick.emit({
|
|
15723
15740
|
comp: this,
|
|
15724
15741
|
id: this.rootElement.id,
|
|
15725
|
-
value:
|
|
15742
|
+
value: this.value,
|
|
15726
15743
|
});
|
|
15727
15744
|
}
|
|
15728
|
-
onKupFocus(
|
|
15729
|
-
const { target } = event;
|
|
15745
|
+
onKupFocus(_event) {
|
|
15730
15746
|
this.kupFocus.emit({
|
|
15731
15747
|
comp: this,
|
|
15732
15748
|
id: this.rootElement.id,
|
|
15733
|
-
value:
|
|
15749
|
+
value: this.value,
|
|
15734
15750
|
});
|
|
15735
15751
|
}
|
|
15736
15752
|
onKupInput(event) {
|
|
@@ -15758,12 +15774,14 @@ const KupTextField = class {
|
|
|
15758
15774
|
});
|
|
15759
15775
|
}
|
|
15760
15776
|
onKeyDown(event) {
|
|
15777
|
+
const { target } = event;
|
|
15761
15778
|
if (event.key === 'Enter') {
|
|
15762
15779
|
if (this.emitSubmitEventOnEnter == true) {
|
|
15780
|
+
__classPrivateFieldGet$1(this, _KupTextField_instances, "m", _KupTextField_setValueFromEventTaget).call(this, target);
|
|
15763
15781
|
this.kupTextFieldSubmit.emit({
|
|
15764
15782
|
comp: this,
|
|
15765
15783
|
id: this.rootElement.id,
|
|
15766
|
-
value: this.
|
|
15784
|
+
value: this.value,
|
|
15767
15785
|
});
|
|
15768
15786
|
}
|
|
15769
15787
|
}
|
|
@@ -15783,6 +15801,9 @@ const KupTextField = class {
|
|
|
15783
15801
|
* Returns the component's internal value.
|
|
15784
15802
|
*/
|
|
15785
15803
|
async getValue() {
|
|
15804
|
+
if (this.inputType == 'number') {
|
|
15805
|
+
return formattedStringToUnformattedStringNumber(this.value, '');
|
|
15806
|
+
}
|
|
15786
15807
|
return this.value;
|
|
15787
15808
|
}
|
|
15788
15809
|
/**
|
|
@@ -15810,7 +15831,7 @@ const KupTextField = class {
|
|
|
15810
15831
|
async setValue(value) {
|
|
15811
15832
|
this.value = value;
|
|
15812
15833
|
try {
|
|
15813
|
-
this.inputEl.value =
|
|
15834
|
+
this.inputEl.value = __classPrivateFieldGet$1(this, _KupTextField_instances, "m", _KupTextField_getValueForOutput).call(this);
|
|
15814
15835
|
}
|
|
15815
15836
|
catch (error) {
|
|
15816
15837
|
this.kupManager.debug.logMessage(this, "Couldn't set value on input element: '" + value + "'", KupDebugCategory.WARNING);
|
|
@@ -15846,6 +15867,7 @@ const KupTextField = class {
|
|
|
15846
15867
|
}
|
|
15847
15868
|
render() {
|
|
15848
15869
|
const props = {
|
|
15870
|
+
allowNegative: this.allowNegative,
|
|
15849
15871
|
danger: this.rootElement.classList.contains('kup-danger')
|
|
15850
15872
|
? true
|
|
15851
15873
|
: false,
|
|
@@ -15855,6 +15877,7 @@ const KupTextField = class {
|
|
|
15855
15877
|
? true
|
|
15856
15878
|
: false,
|
|
15857
15879
|
fullWidth: this.fullWidth,
|
|
15880
|
+
group: this.group,
|
|
15858
15881
|
helper: this.helper,
|
|
15859
15882
|
helperEnabled: this.helperEnabled,
|
|
15860
15883
|
helperWhenFocused: this.helperWhenFocused,
|
|
@@ -15864,6 +15887,7 @@ const KupTextField = class {
|
|
|
15864
15887
|
: false,
|
|
15865
15888
|
inputMode: this.inputMode,
|
|
15866
15889
|
inputType: this.inputType,
|
|
15890
|
+
integers: this.integers,
|
|
15867
15891
|
isClearable: this.isClearable,
|
|
15868
15892
|
label: this.label,
|
|
15869
15893
|
leadingLabel: this.leadingLabel,
|
|
@@ -15906,6 +15930,20 @@ const KupTextField = class {
|
|
|
15906
15930
|
}
|
|
15907
15931
|
get rootElement() { return getElement$1(this); }
|
|
15908
15932
|
};
|
|
15933
|
+
_KupTextField_instances = new WeakSet(), _KupTextField_getValueForOutput = function _KupTextField_getValueForOutput() {
|
|
15934
|
+
if (this.value == null || this.value.trim() == '') {
|
|
15935
|
+
return '';
|
|
15936
|
+
}
|
|
15937
|
+
let v1 = unformattedStringToFormattedStringNumber(this.value, this.decimals, '');
|
|
15938
|
+
return v1;
|
|
15939
|
+
}, _KupTextField_setValueFromEventTaget = function _KupTextField_setValueFromEventTaget(target) {
|
|
15940
|
+
if (this.inputType == 'number') {
|
|
15941
|
+
this.value = formattedStringToUnformattedStringNumber(target.value, '');
|
|
15942
|
+
}
|
|
15943
|
+
else {
|
|
15944
|
+
this.value = target.value;
|
|
15945
|
+
}
|
|
15946
|
+
};
|
|
15909
15947
|
KupTextField.style = kupTextFieldCss;
|
|
15910
15948
|
|
|
15911
15949
|
/**
|