@sme.up/ketchup 6.0.0 → 6.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{cell-utils-a78d6fac.js → cell-utils-fe64a28c.js} +2 -2
- package/dist/cjs/{f-button-ac179257.js → f-button-5b69d882.js} +4 -4
- package/dist/cjs/f-cell-3a740c48.js +418 -0
- package/dist/cjs/f-checkbox-57443ca3.js +29 -0
- package/dist/cjs/{f-chip-b00897d7.js → f-chip-02e83f82.js} +3 -3
- package/dist/cjs/{f-image-89f25556.js → f-image-2a61ece2.js} +2 -2
- package/dist/cjs/{f-paginator-utils-8fa501b3.js → f-paginator-utils-09126bdd.js} +5 -5
- package/dist/cjs/{f-text-field-e1e45ade.js → f-text-field-9ee20a67.js} +3 -3
- package/dist/cjs/{index-eb556444.js → index-06b131ea.js} +6 -4
- package/dist/cjs/ketchup.cjs.js +3 -3
- package/dist/cjs/kup-accordion.cjs.entry.js +4 -4
- package/dist/cjs/kup-autocomplete_25.cjs.entry.js +209 -193
- package/dist/cjs/kup-box.cjs.entry.js +1306 -0
- package/dist/cjs/kup-calendar.cjs.entry.js +7 -7
- package/dist/cjs/kup-cell.cjs.entry.js +10 -9
- package/dist/cjs/kup-dash-list.cjs.entry.js +4 -4
- package/dist/cjs/kup-dash_2.cjs.entry.js +4 -7
- package/dist/cjs/{kup-form-editor.cjs.entry.js → kup-dashboard.cjs.entry.js} +123 -148
- package/dist/cjs/kup-drawer.cjs.entry.js +4 -4
- package/dist/cjs/{kup-box_2.cjs.entry.js → kup-echart.cjs.entry.js} +53 -1338
- package/dist/cjs/kup-family-tree.cjs.entry.js +410 -0
- package/dist/cjs/kup-form.cjs.entry.js +480 -0
- package/dist/cjs/kup-iframe.cjs.entry.js +3 -3
- package/dist/cjs/kup-image-list.cjs.entry.js +73 -11
- package/dist/cjs/kup-lazy.cjs.entry.js +4 -4
- package/dist/cjs/kup-magic-box.cjs.entry.js +4 -4
- package/dist/cjs/{kup-manager-7a941909.js → kup-manager-02acbb37.js} +407 -7
- package/dist/cjs/kup-nav-bar.cjs.entry.js +3 -3
- package/dist/cjs/kup-numeric-picker.cjs.entry.js +3 -3
- package/dist/cjs/kup-photo-frame.cjs.entry.js +5 -5
- 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 +5 -5
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{utils-6287d878.js → utils-4b208b48.js} +1 -1
- package/dist/collection/assets/dashboard.js +113 -0
- package/dist/collection/assets/data-table.js +15 -0
- package/dist/collection/assets/family-tree.js +2437 -0
- package/dist/collection/assets/form.js +433 -0
- package/dist/collection/assets/grid.js +17 -0
- package/dist/collection/assets/index.js +14 -6
- package/dist/collection/collection-manifest.json +4 -3
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.js +135 -129
- package/dist/collection/components/kup-box/kup-box.js +13 -2
- package/dist/collection/components/kup-button/kup-button.js +1 -0
- package/dist/collection/components/kup-combobox/kup-combobox.js +16 -13
- package/dist/collection/components/kup-dashboard/kup-dashboard-declarations.js +10 -0
- package/dist/collection/components/{kup-form-editor/kup-form-editor.css → kup-dashboard/kup-dashboard.css} +7 -6
- package/dist/collection/components/{kup-form-editor/kup-form-editor.js → kup-dashboard/kup-dashboard.js} +148 -149
- package/dist/collection/components/kup-data-table/kup-data-table.js +7 -6
- package/dist/collection/components/kup-drawer/kup-drawer.css +5 -8
- package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.js +1 -0
- package/dist/collection/components/kup-family-tree/kup-family-tree-declarations.js +12 -0
- package/dist/collection/components/kup-family-tree/kup-family-tree.css +101 -0
- package/dist/collection/components/kup-family-tree/kup-family-tree.js +666 -0
- package/dist/collection/components/kup-form/kup-form-declarations.js +25 -0
- package/dist/collection/components/kup-form/kup-form.css +99 -0
- package/dist/collection/components/kup-form/kup-form.js +647 -0
- package/dist/collection/components/kup-grid/kup-grid.js +1 -4
- package/dist/collection/components/kup-image-list/kup-image-list-state.js +9 -0
- package/dist/collection/components/kup-image-list/kup-image-list.css +0 -6
- package/dist/collection/components/kup-image-list/kup-image-list.js +113 -1
- package/dist/collection/components/kup-lazy/kup-lazy.css +13 -6
- package/dist/collection/components/kup-list/kup-list-helper.js +9 -3
- package/dist/collection/components/kup-photo-frame/kup-photo-frame.css +13 -3
- package/dist/collection/components/kup-photo-frame/kup-photo-frame.js +1 -1
- 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 +27 -0
- package/dist/collection/components/kup-time-picker/kup-time-picker.js +0 -6
- package/dist/collection/components/kup-tree/kup-tree.js +10 -4
- package/dist/collection/f-components/f-button/f-button.js +2 -2
- package/dist/collection/f-components/f-cell/f-cell-declarations.js +5 -1
- package/dist/collection/f-components/f-cell/f-cell.js +34 -114
- package/dist/collection/f-components/f-text-field/f-text-field.js +1 -1
- package/dist/collection/managers/kup-data/kup-data-node-helper.js +69 -0
- package/dist/collection/managers/kup-data/kup-data.js +109 -1
- package/dist/collection/managers/kup-language/kup-language-declarations.js +11 -0
- package/dist/collection/managers/kup-objects/kup-objects.js +10 -0
- package/dist/collection/managers/kup-theme/kup-theme-declarations.js +20 -3
- package/dist/collection/types/GenericTypes.js +3 -2
- package/dist/esm/{cell-utils-964da6b5.js → cell-utils-cb5d4149.js} +2 -2
- package/dist/esm/{f-button-871a544b.js → f-button-fd44ef70.js} +4 -4
- package/dist/esm/{f-cell-521ef17a.js → f-cell-7b159a22.js} +48 -283
- package/dist/esm/f-checkbox-c51c4a75.js +27 -0
- package/dist/esm/{f-chip-1dda722f.js → f-chip-c2e4c522.js} +3 -3
- package/dist/esm/{f-image-c468d8ae.js → f-image-2ab4b9aa.js} +2 -2
- package/dist/esm/{f-paginator-utils-7dff8ff0.js → f-paginator-utils-ef537d82.js} +5 -5
- package/dist/esm/{f-text-field-d6c61c73.js → f-text-field-41c575eb.js} +3 -3
- package/dist/esm/{index-baeab1ac.js → index-ad6ab214.js} +6 -4
- package/dist/esm/ketchup.js +3 -3
- package/dist/esm/kup-accordion.entry.js +4 -4
- package/dist/esm/kup-autocomplete_25.entry.js +199 -183
- package/dist/esm/kup-box.entry.js +1302 -0
- package/dist/esm/kup-calendar.entry.js +7 -7
- package/dist/esm/kup-cell.entry.js +9 -8
- package/dist/esm/kup-dash-list.entry.js +4 -4
- package/dist/esm/kup-dash_2.entry.js +4 -7
- package/dist/esm/{kup-form-editor.entry.js → kup-dashboard.entry.js} +123 -148
- package/dist/esm/kup-drawer.entry.js +4 -4
- package/dist/esm/{kup-box_2.entry.js → kup-echart.entry.js} +54 -1338
- package/dist/esm/kup-family-tree.entry.js +406 -0
- package/dist/esm/kup-form.entry.js +476 -0
- package/dist/esm/kup-iframe.entry.js +3 -3
- package/dist/esm/kup-image-list.entry.js +72 -10
- package/dist/esm/kup-lazy.entry.js +4 -4
- package/dist/esm/kup-magic-box.entry.js +4 -4
- package/dist/esm/{kup-manager-58b075b4.js → kup-manager-22a475e6.js} +404 -8
- package/dist/esm/kup-nav-bar.entry.js +3 -3
- package/dist/esm/kup-numeric-picker.entry.js +3 -3
- package/dist/esm/kup-photo-frame.entry.js +5 -5
- 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 +5 -5
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{utils-d7e4b3c2.js → utils-2c1f4122.js} +1 -1
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/p-06c6cc68.js +1 -0
- package/dist/ketchup/{p-3c11e615.entry.js → p-0dacd4bc.entry.js} +1 -1
- package/dist/ketchup/{p-fac1a08b.entry.js → p-1959f835.entry.js} +1 -1
- package/dist/ketchup/p-1c44dc62.entry.js +1 -0
- package/dist/ketchup/{p-f09f2f98.entry.js → p-264b1b19.entry.js} +1 -1
- package/dist/ketchup/p-38d7584e.js +1 -0
- package/dist/ketchup/{p-f71a1675.entry.js → p-42080355.entry.js} +1 -1
- package/dist/ketchup/p-4bc9f98b.entry.js +1 -0
- package/dist/ketchup/p-578583db.entry.js +1 -0
- package/dist/ketchup/p-5866d507.entry.js +1 -0
- package/dist/ketchup/p-61059e9d.entry.js +9 -0
- package/dist/ketchup/{p-a615a92b.entry.js → p-664be494.entry.js} +1 -1
- package/dist/ketchup/{p-d2ee56dd.entry.js → p-67cd575d.entry.js} +1 -1
- package/dist/ketchup/{p-e0035c58.js → p-682a367a.js} +1 -1
- package/dist/ketchup/p-6ccf7eb2.entry.js +1 -0
- package/dist/ketchup/p-7230ab97.entry.js +1 -0
- package/dist/ketchup/p-752b4cef.entry.js +1 -0
- package/dist/ketchup/{p-954cc340.entry.js → p-7de3e7ac.entry.js} +1 -1
- package/dist/ketchup/p-928c5c36.js +1 -0
- package/dist/ketchup/{p-6dff70f8.entry.js → p-9b36497d.entry.js} +1 -1
- package/dist/ketchup/{p-99e0d768.entry.js → p-b982d137.entry.js} +1 -1
- package/dist/ketchup/{p-8cdf61a4.js → p-c0219e5e.js} +1 -1
- package/dist/ketchup/p-c55fd0a7.entry.js +1 -0
- package/dist/ketchup/p-cd5cfa7c.js +1 -0
- package/dist/ketchup/p-d154b3a0.entry.js +1 -0
- package/dist/ketchup/p-d2affb6f.entry.js +27 -0
- package/dist/ketchup/p-d3b542b3.js +2 -0
- package/dist/ketchup/{p-7454cb92.js → p-d6c12c6c.js} +1 -1
- package/dist/ketchup/p-da0eab60.entry.js +1 -0
- package/dist/ketchup/{p-7eff4eee.js → p-dc62a30f.js} +1 -1
- package/dist/ketchup/p-e9366aaf.entry.js +39 -0
- package/dist/ketchup/{p-44ec4f03.js → p-edae3076.js} +1 -1
- package/dist/ketchup/p-fc2b1229.js +30 -0
- package/dist/types/components/kup-autocomplete/kup-autocomplete.d.ts +1 -16
- package/dist/types/components/{kup-form-editor/kup-form-editor-declarations.d.ts → kup-dashboard/kup-dashboard-declarations.d.ts} +9 -27
- package/dist/types/components/{kup-form-editor/kup-form-editor.d.ts → kup-dashboard/kup-dashboard.d.ts} +12 -9
- package/dist/types/components/kup-family-tree/kup-family-tree-declarations.d.ts +33 -0
- package/dist/types/components/kup-family-tree/kup-family-tree.d.ts +61 -0
- package/dist/types/components/kup-form/kup-form-declarations.d.ts +60 -0
- package/dist/types/components/kup-form/kup-form.d.ts +63 -0
- package/dist/types/components/kup-image-list/kup-image-list-state.d.ts +6 -0
- package/dist/types/components/kup-image-list/kup-image-list.d.ts +17 -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 +5 -0
- package/dist/types/components/kup-time-picker/kup-time-picker.d.ts +0 -6
- package/dist/types/components/kup-tree/kup-tree-declarations.d.ts +2 -0
- package/dist/types/components.d.ts +460 -241
- package/dist/types/f-components/f-cell/f-cell-declarations.d.ts +4 -1
- package/dist/types/f-components/f-text-field/f-text-field-declarations.d.ts +1 -0
- package/dist/types/managers/kup-data/kup-data-declarations.d.ts +8 -0
- package/dist/types/managers/kup-data/kup-data-node-helper.d.ts +15 -1
- package/dist/types/managers/kup-data/kup-data.d.ts +7 -1
- package/dist/types/managers/kup-language/kup-language-declarations.d.ts +11 -1
- package/dist/types/managers/kup-objects/kup-objects.d.ts +6 -0
- package/dist/types/types/GenericTypes.d.ts +3 -2
- package/package.json +2 -2
- package/dist/cjs/f-cell-69294bca.js +0 -653
- package/dist/cjs/kup-field.cjs.entry.js +0 -241
- package/dist/collection/assets/form-editor.js +0 -338
- package/dist/collection/components/kup-field/kup-field-declarations.js +0 -15
- package/dist/collection/components/kup-field/kup-field.css +0 -48
- package/dist/collection/components/kup-field/kup-field.js +0 -514
- package/dist/collection/components/kup-form-editor/kup-form-editor-declarations.js +0 -23
- package/dist/esm/kup-field.entry.js +0 -237
- package/dist/ketchup/p-1ae66cc5.js +0 -1
- package/dist/ketchup/p-34b74425.js +0 -1
- package/dist/ketchup/p-4ffbc3ff.js +0 -1
- package/dist/ketchup/p-5264a3e6.entry.js +0 -1
- package/dist/ketchup/p-65974e48.entry.js +0 -1
- package/dist/ketchup/p-65b46587.entry.js +0 -40
- package/dist/ketchup/p-80968627.entry.js +0 -1
- package/dist/ketchup/p-a0f6e25c.entry.js +0 -1
- package/dist/ketchup/p-aca0e54b.js +0 -30
- package/dist/ketchup/p-b8939a8b.entry.js +0 -1
- package/dist/ketchup/p-bfc3bac7.js +0 -1
- package/dist/ketchup/p-c5ce8951.entry.js +0 -1
- package/dist/ketchup/p-cad1e097.entry.js +0 -9
- package/dist/ketchup/p-db71436b.entry.js +0 -27
- package/dist/ketchup/p-e1039cf2.entry.js +0 -1
- package/dist/ketchup/p-ea10176c.entry.js +0 -1
- package/dist/types/components/kup-field/kup-field-declarations.d.ts +0 -25
- package/dist/types/components/kup-field/kup-field.d.ts +0 -90
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
2
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
3
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
|
+
};
|
|
6
|
+
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
7
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
8
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
9
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
10
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
11
|
+
};
|
|
12
|
+
var _KupAutocomplete_instances, _KupAutocomplete_doConsistencyCheck, _KupAutocomplete_elStyle, _KupAutocomplete_listEl, _KupAutocomplete_kupManager, _KupAutocomplete_textfieldWrapper, _KupAutocomplete_textfieldEl, _KupAutocomplete_clickCb, _KupAutocomplete_inputTimeout, _KupAutocomplete_openList, _KupAutocomplete_closeList, _KupAutocomplete_isListOpened, _KupAutocomplete_consistencyCheck, _KupAutocomplete_prepList;
|
|
1
13
|
import { Component, Element, Event, forceUpdate, h, Host, Listen, Method, Prop, State, } from '@stencil/core';
|
|
2
14
|
import { kupManagerInstance, } from '../../managers/kup-manager/kup-manager';
|
|
3
15
|
import { FTextField } from '../../f-components/f-text-field/f-text-field';
|
|
@@ -11,6 +23,7 @@ import { componentWrapperId } from '../../variables/GenericVariables';
|
|
|
11
23
|
import { KupDynamicPositionPlacement } from '../../managers/kup-dynamic-position/kup-dynamic-position-declarations';
|
|
12
24
|
export class KupAutocomplete {
|
|
13
25
|
constructor() {
|
|
26
|
+
_KupAutocomplete_instances.add(this);
|
|
14
27
|
/*-------------------------------------------------*/
|
|
15
28
|
/* S t a t e s */
|
|
16
29
|
/*-------------------------------------------------*/
|
|
@@ -78,34 +91,35 @@ export class KupAutocomplete {
|
|
|
78
91
|
/*-------------------------------------------------*/
|
|
79
92
|
/* I n t e r n a l V a r i a b l e s */
|
|
80
93
|
/*-------------------------------------------------*/
|
|
81
|
-
this
|
|
82
|
-
this
|
|
83
|
-
this
|
|
94
|
+
_KupAutocomplete_doConsistencyCheck.set(this, true);
|
|
95
|
+
_KupAutocomplete_elStyle.set(this, undefined);
|
|
96
|
+
_KupAutocomplete_listEl.set(this, null);
|
|
84
97
|
/**
|
|
85
98
|
* Instance of the KupManager class.
|
|
86
99
|
*/
|
|
87
|
-
this
|
|
88
|
-
this
|
|
89
|
-
this
|
|
90
|
-
this
|
|
100
|
+
_KupAutocomplete_kupManager.set(this, kupManagerInstance());
|
|
101
|
+
_KupAutocomplete_textfieldWrapper.set(this, undefined);
|
|
102
|
+
_KupAutocomplete_textfieldEl.set(this, undefined);
|
|
103
|
+
_KupAutocomplete_clickCb.set(this, null);
|
|
104
|
+
_KupAutocomplete_inputTimeout.set(this, void 0);
|
|
91
105
|
}
|
|
92
106
|
onKupBlur() {
|
|
93
107
|
this.kupBlur.emit({
|
|
94
108
|
comp: this,
|
|
95
109
|
id: this.rootElement.id,
|
|
96
110
|
value: this.value,
|
|
97
|
-
inputValue: this.
|
|
111
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
98
112
|
});
|
|
99
113
|
}
|
|
100
114
|
onKupChange(value) {
|
|
101
|
-
this
|
|
102
|
-
const ret = this.
|
|
115
|
+
__classPrivateFieldSet(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
116
|
+
const ret = __classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, value, true);
|
|
103
117
|
if (ret.exists || this.allowInconsistentValues) {
|
|
104
118
|
this.kupChange.emit({
|
|
105
119
|
comp: this,
|
|
106
120
|
id: this.rootElement.id,
|
|
107
121
|
value: this.value,
|
|
108
|
-
inputValue: this.
|
|
122
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
109
123
|
});
|
|
110
124
|
}
|
|
111
125
|
}
|
|
@@ -114,7 +128,7 @@ export class KupAutocomplete {
|
|
|
114
128
|
comp: this,
|
|
115
129
|
id: this.rootElement.id,
|
|
116
130
|
value: this.value,
|
|
117
|
-
inputValue: this.
|
|
131
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
118
132
|
});
|
|
119
133
|
}
|
|
120
134
|
onKupFocus() {
|
|
@@ -122,82 +136,78 @@ export class KupAutocomplete {
|
|
|
122
136
|
comp: this,
|
|
123
137
|
id: this.rootElement.id,
|
|
124
138
|
value: this.value,
|
|
125
|
-
inputValue: this.
|
|
139
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
126
140
|
});
|
|
127
141
|
}
|
|
128
142
|
onKupInput() {
|
|
129
|
-
this
|
|
130
|
-
this.
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
this.listEl.filter = this.displayedValue;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
if (this.textfieldEl.value.length >= this.minimumChars) {
|
|
143
|
+
__classPrivateFieldSet(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
144
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value, false);
|
|
145
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
146
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value.length >= this.minimumChars) {
|
|
137
147
|
this.kupInput.emit({
|
|
138
148
|
comp: this,
|
|
139
149
|
id: this.rootElement.id,
|
|
140
150
|
value: this.value,
|
|
141
|
-
inputValue: this.
|
|
151
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
142
152
|
});
|
|
143
153
|
}
|
|
144
154
|
}
|
|
145
155
|
onKupIconClick() {
|
|
146
|
-
if (this.
|
|
147
|
-
this.
|
|
156
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f").classList.contains('toggled')) {
|
|
157
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
148
158
|
}
|
|
149
159
|
else {
|
|
150
|
-
this.
|
|
160
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, true);
|
|
151
161
|
}
|
|
152
162
|
this.kupIconClick.emit({
|
|
153
163
|
comp: this,
|
|
154
164
|
id: this.rootElement.id,
|
|
155
165
|
value: this.value,
|
|
156
|
-
inputValue: this.
|
|
157
|
-
open: this.
|
|
166
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
167
|
+
open: __classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f").classList.contains('toggled'),
|
|
158
168
|
});
|
|
159
169
|
}
|
|
160
170
|
onKupItemClick(e) {
|
|
161
171
|
this.onKupChange(e.detail.selected.id);
|
|
162
|
-
this.
|
|
163
|
-
if (this
|
|
164
|
-
this.
|
|
172
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
173
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f")) {
|
|
174
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
165
175
|
}
|
|
166
176
|
this.kupItemClick.emit({
|
|
167
177
|
comp: this,
|
|
168
178
|
id: this.rootElement.id,
|
|
169
179
|
value: this.value,
|
|
170
|
-
inputValue: this.
|
|
180
|
+
inputValue: __classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value,
|
|
171
181
|
});
|
|
172
182
|
}
|
|
173
183
|
/*-------------------------------------------------*/
|
|
174
184
|
/* L i s t e n e r s */
|
|
175
185
|
/*-------------------------------------------------*/
|
|
176
186
|
listenKeydown(e) {
|
|
177
|
-
if (this.
|
|
187
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_isListOpened).call(this)) {
|
|
178
188
|
switch (e.key) {
|
|
179
189
|
case 'ArrowDown':
|
|
180
190
|
e.preventDefault();
|
|
181
191
|
e.stopPropagation();
|
|
182
|
-
this.
|
|
192
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").focusNext();
|
|
183
193
|
break;
|
|
184
194
|
case 'ArrowUp':
|
|
185
195
|
e.preventDefault();
|
|
186
196
|
e.stopPropagation();
|
|
187
|
-
this.
|
|
197
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").focusPrevious();
|
|
188
198
|
break;
|
|
189
199
|
case 'Enter':
|
|
190
200
|
e.preventDefault();
|
|
191
201
|
e.stopPropagation();
|
|
192
|
-
this.
|
|
193
|
-
this.
|
|
194
|
-
this.
|
|
202
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").select().then(() => {
|
|
203
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
204
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
195
205
|
});
|
|
196
206
|
break;
|
|
197
207
|
case 'Escape':
|
|
198
208
|
e.preventDefault();
|
|
199
209
|
e.stopPropagation();
|
|
200
|
-
this.
|
|
210
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
201
211
|
break;
|
|
202
212
|
}
|
|
203
213
|
}
|
|
@@ -206,14 +216,14 @@ export class KupAutocomplete {
|
|
|
206
216
|
case 'ArrowDown':
|
|
207
217
|
e.preventDefault();
|
|
208
218
|
e.stopPropagation();
|
|
209
|
-
this.
|
|
210
|
-
this.
|
|
219
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
220
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").focusNext();
|
|
211
221
|
break;
|
|
212
222
|
case 'ArrowUp':
|
|
213
223
|
e.preventDefault();
|
|
214
224
|
e.stopPropagation();
|
|
215
|
-
this.
|
|
216
|
-
this.
|
|
225
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_openList).call(this, false);
|
|
226
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").focusPrevious();
|
|
217
227
|
break;
|
|
218
228
|
}
|
|
219
229
|
}
|
|
@@ -246,7 +256,7 @@ export class KupAutocomplete {
|
|
|
246
256
|
* Sets the focus to the component.
|
|
247
257
|
*/
|
|
248
258
|
async setFocus() {
|
|
249
|
-
this.
|
|
259
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").focus();
|
|
250
260
|
}
|
|
251
261
|
/**
|
|
252
262
|
* Sets the props to the component.
|
|
@@ -260,81 +270,16 @@ export class KupAutocomplete {
|
|
|
260
270
|
* @param {string} value - Value of the component.
|
|
261
271
|
*/
|
|
262
272
|
async setValue(value) {
|
|
263
|
-
this
|
|
264
|
-
this.
|
|
265
|
-
}
|
|
266
|
-
/*-------------------------------------------------*/
|
|
267
|
-
/* P r i v a t e M e t h o d s */
|
|
268
|
-
/*-------------------------------------------------*/
|
|
269
|
-
openList(forceOpen) {
|
|
270
|
-
if (forceOpen != true &&
|
|
271
|
-
this.textfieldEl.value.length < this.minimumChars) {
|
|
272
|
-
this.closeList();
|
|
273
|
-
return false;
|
|
274
|
-
}
|
|
275
|
-
this.textfieldWrapper.classList.add('toggled');
|
|
276
|
-
this.listEl.menuVisible = true;
|
|
277
|
-
const elStyle = this.listEl.style;
|
|
278
|
-
elStyle.height = 'auto';
|
|
279
|
-
elStyle.minWidth = this.textfieldWrapper.clientWidth + 'px';
|
|
280
|
-
if (this.kupManager.dynamicPosition.isRegistered(this.listEl)) {
|
|
281
|
-
this.kupManager.dynamicPosition.changeAnchor(this.listEl, this.textfieldWrapper);
|
|
282
|
-
}
|
|
283
|
-
else {
|
|
284
|
-
this.kupManager.dynamicPosition.register(this.listEl, this.textfieldWrapper, 0, KupDynamicPositionPlacement.AUTO, true);
|
|
285
|
-
}
|
|
286
|
-
this.kupManager.dynamicPosition.start(this.listEl);
|
|
287
|
-
if (!this.clickCb) {
|
|
288
|
-
this.clickCb = {
|
|
289
|
-
cb: () => {
|
|
290
|
-
this.closeList();
|
|
291
|
-
},
|
|
292
|
-
el: this.listEl,
|
|
293
|
-
};
|
|
294
|
-
}
|
|
295
|
-
this.kupManager.addClickCallback(this.clickCb, true);
|
|
296
|
-
return true;
|
|
297
|
-
}
|
|
298
|
-
closeList() {
|
|
299
|
-
this.textfieldWrapper.classList.remove('toggled');
|
|
300
|
-
this.listEl.menuVisible = false;
|
|
301
|
-
this.kupManager.dynamicPosition.stop(this.listEl);
|
|
302
|
-
this.kupManager.removeClickCallback(this.clickCb);
|
|
303
|
-
}
|
|
304
|
-
isListOpened() {
|
|
305
|
-
return this.listEl.menuVisible == true;
|
|
306
|
-
}
|
|
307
|
-
consistencyCheck(e, idIn) {
|
|
308
|
-
if (!this.doConsistencyCheck) {
|
|
309
|
-
return;
|
|
310
|
-
}
|
|
311
|
-
this.doConsistencyCheck = false;
|
|
312
|
-
const ret = consistencyCheck(idIn, this.data['kup-list'], this.listEl, this.selectMode, this.displayMode, e);
|
|
313
|
-
if (ret.exists || this.allowInconsistentValues) {
|
|
314
|
-
this.value = ret.value;
|
|
315
|
-
this.displayedValue = ret.displayedValue;
|
|
316
|
-
if (this.listEl != null && !this.serverHandledFilter) {
|
|
317
|
-
this.listEl.filter = this.displayedValue;
|
|
318
|
-
}
|
|
319
|
-
}
|
|
320
|
-
else {
|
|
321
|
-
this.displayedValue = idIn;
|
|
322
|
-
if (this.listEl != null && !this.serverHandledFilter) {
|
|
323
|
-
this.listEl.filter = idIn;
|
|
324
|
-
}
|
|
325
|
-
}
|
|
326
|
-
return ret;
|
|
327
|
-
}
|
|
328
|
-
prepList() {
|
|
329
|
-
return (h("kup-list", Object.assign({ displayMode: this.displayMode }, this.data['kup-list'], { isMenu: true, "onkup-list-click": (e) => this.onKupItemClick(e), ref: (el) => (this.listEl = el) })));
|
|
273
|
+
__classPrivateFieldSet(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
274
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, value, true);
|
|
330
275
|
}
|
|
331
276
|
/*-------------------------------------------------*/
|
|
332
277
|
/* L i f e c y c l e H o o k s */
|
|
333
278
|
/*-------------------------------------------------*/
|
|
334
279
|
componentWillLoad() {
|
|
335
|
-
this.
|
|
336
|
-
this.
|
|
337
|
-
this
|
|
280
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").debug.logLoad(this, false);
|
|
281
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").theme.register(this);
|
|
282
|
+
__classPrivateFieldSet(this, _KupAutocomplete_doConsistencyCheck, true, "f");
|
|
338
283
|
this.value = this.initialValue;
|
|
339
284
|
if (!this.data) {
|
|
340
285
|
this.data = {
|
|
@@ -344,43 +289,44 @@ export class KupAutocomplete {
|
|
|
344
289
|
}
|
|
345
290
|
}
|
|
346
291
|
componentDidLoad() {
|
|
347
|
-
this.
|
|
348
|
-
this.
|
|
292
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_consistencyCheck).call(this, this.value, true);
|
|
293
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").debug.logLoad(this, true);
|
|
349
294
|
}
|
|
350
295
|
componentWillRender() {
|
|
351
|
-
this.
|
|
296
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").debug.logRender(this, false);
|
|
352
297
|
}
|
|
353
298
|
componentDidRender() {
|
|
354
299
|
const root = this.rootElement.shadowRoot;
|
|
355
300
|
if (root) {
|
|
356
301
|
const f = root.querySelector('.f-text-field');
|
|
357
302
|
if (f) {
|
|
358
|
-
this
|
|
359
|
-
this
|
|
303
|
+
__classPrivateFieldSet(this, _KupAutocomplete_textfieldWrapper, f, "f");
|
|
304
|
+
__classPrivateFieldSet(this, _KupAutocomplete_textfieldEl, f.querySelector('input'), "f");
|
|
360
305
|
FTextFieldMDC(f);
|
|
361
306
|
}
|
|
362
307
|
}
|
|
363
|
-
this.
|
|
308
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").debug.logRender(this, true);
|
|
364
309
|
}
|
|
365
310
|
render() {
|
|
366
311
|
const fullHeight = this.rootElement.classList.contains('kup-full-height');
|
|
367
312
|
const fullWidth = this.rootElement.classList.contains('kup-full-width');
|
|
368
|
-
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: this
|
|
369
|
-
h("style", null, this.
|
|
370
|
-
h("div", { id: componentWrapperId, style: this
|
|
313
|
+
return (h(Host, { class: `${fullHeight ? 'kup-full-height' : ''} ${fullWidth ? 'kup-full-width' : ''}`, style: __classPrivateFieldGet(this, _KupAutocomplete_elStyle, "f") },
|
|
314
|
+
h("style", null, __classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").theme.setKupStyle(this.rootElement)),
|
|
315
|
+
h("div", { id: componentWrapperId, style: __classPrivateFieldGet(this, _KupAutocomplete_elStyle, "f") },
|
|
371
316
|
h(FTextField, Object.assign({}, this.data['kup-text-field'], { disabled: this.disabled, fullHeight: fullHeight, fullWidth: fullWidth, icon: this.showDropDownIcon
|
|
372
317
|
? KupThemeIconValues.DROPDOWN
|
|
373
318
|
: null, trailingIcon: true, value: this.displayedValue, onBlur: () => this.onKupBlur(), onClick: () => this.onKupClick(), onChange: (e) => this.onKupChange(e.target.value), onFocus: () => this.onKupFocus(), onInput: () => {
|
|
374
|
-
window.clearTimeout(this
|
|
375
|
-
this
|
|
376
|
-
}, onIconClick: () => this.onKupIconClick() })
|
|
319
|
+
window.clearTimeout(__classPrivateFieldGet(this, _KupAutocomplete_inputTimeout, "f"));
|
|
320
|
+
__classPrivateFieldSet(this, _KupAutocomplete_inputTimeout, window.setTimeout(() => this.onKupInput(), this.inputDelay), "f");
|
|
321
|
+
}, onIconClick: () => this.onKupIconClick() }))),
|
|
322
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_prepList).call(this)));
|
|
377
323
|
}
|
|
378
324
|
disconnectedCallback() {
|
|
379
|
-
if (this
|
|
380
|
-
this.
|
|
381
|
-
this.
|
|
325
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f")) {
|
|
326
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.unregister([__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f")]);
|
|
327
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").remove();
|
|
382
328
|
}
|
|
383
|
-
this.
|
|
329
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").theme.unregister(this);
|
|
384
330
|
}
|
|
385
331
|
static get is() { return "kup-autocomplete"; }
|
|
386
332
|
static get encapsulation() { return "shadow"; }
|
|
@@ -931,3 +877,63 @@ export class KupAutocomplete {
|
|
|
931
877
|
"passive": false
|
|
932
878
|
}]; }
|
|
933
879
|
}
|
|
880
|
+
_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) {
|
|
881
|
+
if (forceOpen != true &&
|
|
882
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldEl, "f").value.length < this.minimumChars) {
|
|
883
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
884
|
+
return false;
|
|
885
|
+
}
|
|
886
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f").classList.add('toggled');
|
|
887
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").menuVisible = true;
|
|
888
|
+
const elStyle = __classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").style;
|
|
889
|
+
elStyle.height = 'auto';
|
|
890
|
+
elStyle.minWidth = __classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f").clientWidth + 'px';
|
|
891
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.isRegistered(__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"))) {
|
|
892
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.changeAnchor(__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"), __classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f"));
|
|
893
|
+
}
|
|
894
|
+
else {
|
|
895
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.register(__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"), __classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f"), 0, KupDynamicPositionPlacement.AUTO, true);
|
|
896
|
+
}
|
|
897
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.start(__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"));
|
|
898
|
+
if (!__classPrivateFieldGet(this, _KupAutocomplete_clickCb, "f")) {
|
|
899
|
+
__classPrivateFieldSet(this, _KupAutocomplete_clickCb, {
|
|
900
|
+
cb: () => {
|
|
901
|
+
__classPrivateFieldGet(this, _KupAutocomplete_instances, "m", _KupAutocomplete_closeList).call(this);
|
|
902
|
+
},
|
|
903
|
+
el: __classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"),
|
|
904
|
+
}, "f");
|
|
905
|
+
}
|
|
906
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").addClickCallback(__classPrivateFieldGet(this, _KupAutocomplete_clickCb, "f"), true);
|
|
907
|
+
return true;
|
|
908
|
+
}, _KupAutocomplete_closeList = function _KupAutocomplete_closeList() {
|
|
909
|
+
__classPrivateFieldGet(this, _KupAutocomplete_textfieldWrapper, "f").classList.remove('toggled');
|
|
910
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").menuVisible = false;
|
|
911
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").dynamicPosition.stop(__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"));
|
|
912
|
+
__classPrivateFieldGet(this, _KupAutocomplete_kupManager, "f").removeClickCallback(__classPrivateFieldGet(this, _KupAutocomplete_clickCb, "f"));
|
|
913
|
+
}, _KupAutocomplete_isListOpened = function _KupAutocomplete_isListOpened() {
|
|
914
|
+
return __classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").menuVisible == true;
|
|
915
|
+
}, _KupAutocomplete_consistencyCheck = function _KupAutocomplete_consistencyCheck(idIn, setValue) {
|
|
916
|
+
if (!__classPrivateFieldGet(this, _KupAutocomplete_doConsistencyCheck, "f")) {
|
|
917
|
+
return;
|
|
918
|
+
}
|
|
919
|
+
__classPrivateFieldSet(this, _KupAutocomplete_doConsistencyCheck, false, "f");
|
|
920
|
+
const ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet(this, _KupAutocomplete_listEl, "f"), this.selectMode, this.displayMode);
|
|
921
|
+
if (ret.exists || this.allowInconsistentValues) {
|
|
922
|
+
if (setValue) {
|
|
923
|
+
this.value = ret.value;
|
|
924
|
+
this.displayedValue = ret.displayedValue;
|
|
925
|
+
}
|
|
926
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f") != null && !this.serverHandledFilter) {
|
|
927
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").filter = ret.value;
|
|
928
|
+
}
|
|
929
|
+
}
|
|
930
|
+
else {
|
|
931
|
+
this.displayedValue = idIn;
|
|
932
|
+
if (__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f") != null && !this.serverHandledFilter) {
|
|
933
|
+
__classPrivateFieldGet(this, _KupAutocomplete_listEl, "f").filter = ret.value;
|
|
934
|
+
}
|
|
935
|
+
}
|
|
936
|
+
return ret;
|
|
937
|
+
}, _KupAutocomplete_prepList = function _KupAutocomplete_prepList() {
|
|
938
|
+
return (h("kup-list", Object.assign({ displayMode: this.displayMode }, this.data['kup-list'], { isMenu: true, "onkup-list-click": (e) => this.onKupItemClick(e), ref: (el) => (__classPrivateFieldSet(this, _KupAutocomplete_listEl, el, "f")) })));
|
|
939
|
+
};
|
|
@@ -17,6 +17,7 @@ import { FCell } from '../../f-components/f-cell/f-cell';
|
|
|
17
17
|
import { FPaginator } from '../../f-components/f-paginator/f-paginator';
|
|
18
18
|
import { FPaginatorMode } from '../../f-components/f-paginator/f-paginator-declarations';
|
|
19
19
|
import { pageChange, rowsPerPageChange, } from '../../f-components/f-paginator/f-paginator-utils';
|
|
20
|
+
import { FTextFieldMDC } from '../../f-components/f-text-field/f-text-field-mdc';
|
|
20
21
|
export class KupBox {
|
|
21
22
|
constructor() {
|
|
22
23
|
/*-------------------------------------------------*/
|
|
@@ -939,7 +940,9 @@ export class KupBox {
|
|
|
939
940
|
if (!this.kanban.columns || this.kanban.columns.length === 0) {
|
|
940
941
|
this.kupManager.debug.logMessage(this, 'No columns to group by detected.', KupDebugCategory.ERROR);
|
|
941
942
|
return {
|
|
942
|
-
jsx: (h("
|
|
943
|
+
jsx: (h("div", { id: "empty-data-message", class: "box-wrapper" },
|
|
944
|
+
h("div", { ref: (el) => this.rowsRefs.push(el) }),
|
|
945
|
+
this.kupManager.language.translate(KupLanguageGeneric.EMPTY_DATA))),
|
|
943
946
|
style: { 'grid-template-columns': `repeat(1, 1fr)` },
|
|
944
947
|
};
|
|
945
948
|
}
|
|
@@ -1154,6 +1157,13 @@ export class KupBox {
|
|
|
1154
1157
|
this.kupManager.debug.logRender(this, false);
|
|
1155
1158
|
}
|
|
1156
1159
|
componentDidRender() {
|
|
1160
|
+
const root = this.rootElement.shadowRoot;
|
|
1161
|
+
if (root) {
|
|
1162
|
+
const fs = root.querySelectorAll('.f-text-field');
|
|
1163
|
+
for (let index = 0; index < fs.length; index++) {
|
|
1164
|
+
FTextFieldMDC(fs[index]);
|
|
1165
|
+
}
|
|
1166
|
+
}
|
|
1157
1167
|
this.checkScrollOnHover();
|
|
1158
1168
|
this.persistState();
|
|
1159
1169
|
this.didRenderInteractables();
|
|
@@ -1205,7 +1215,8 @@ export class KupBox {
|
|
|
1205
1215
|
let boxContent = null;
|
|
1206
1216
|
let containerStyle = {};
|
|
1207
1217
|
if (this.rows.length === 0) {
|
|
1208
|
-
boxContent = (h("
|
|
1218
|
+
boxContent = (h("div", { id: "empty-data-message", class: "box-wrapper" },
|
|
1219
|
+
h("div", { class: "box", ref: (el) => this.rowsRefs.push(el) }, this.kupManager.language.translate(KupLanguageGeneric.EMPTY_DATA))));
|
|
1209
1220
|
containerStyle = { 'grid-template-columns': `repeat(1, 1fr)` };
|
|
1210
1221
|
}
|
|
1211
1222
|
else if (isKanban) {
|
|
@@ -202,6 +202,7 @@ export class KupButton {
|
|
|
202
202
|
: false,
|
|
203
203
|
styling: this.styling,
|
|
204
204
|
showSpinner: this.showSpinner,
|
|
205
|
+
title: this.rootElement.title,
|
|
205
206
|
toggable: this.toggable,
|
|
206
207
|
trailingIcon: this.trailingIcon,
|
|
207
208
|
warning: this.rootElement.classList.contains('kup-warning')
|
|
@@ -88,7 +88,7 @@ export class KupCombobox {
|
|
|
88
88
|
});
|
|
89
89
|
}
|
|
90
90
|
onKupChange(value) {
|
|
91
|
-
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this,
|
|
91
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, value, true);
|
|
92
92
|
this.kupChange.emit({
|
|
93
93
|
comp: this,
|
|
94
94
|
id: this.rootElement.id,
|
|
@@ -121,14 +121,14 @@ export class KupCombobox {
|
|
|
121
121
|
});
|
|
122
122
|
}
|
|
123
123
|
onKupInput() {
|
|
124
|
-
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this,
|
|
124
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, __classPrivateFieldGet(this, _KupCombobox_textfieldEl, "f").value, false);
|
|
125
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
125
126
|
this.kupInput.emit({
|
|
126
127
|
comp: this,
|
|
127
128
|
id: this.rootElement.id,
|
|
128
129
|
value: this.value,
|
|
129
130
|
inputValue: __classPrivateFieldGet(this, _KupCombobox_textfieldEl, "f").value,
|
|
130
131
|
});
|
|
131
|
-
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_openList).call(this);
|
|
132
132
|
}
|
|
133
133
|
onKupIconClick() {
|
|
134
134
|
if (__classPrivateFieldGet(this, _KupCombobox_textfieldWrapper, "f").classList.contains('toggled')) {
|
|
@@ -254,7 +254,7 @@ export class KupCombobox {
|
|
|
254
254
|
* @param {string} value - Value to be set.
|
|
255
255
|
*/
|
|
256
256
|
async setValue(value) {
|
|
257
|
-
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this,
|
|
257
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, value, true);
|
|
258
258
|
}
|
|
259
259
|
/*-------------------------------------------------*/
|
|
260
260
|
/* L i f e c y c l e H o o k s */
|
|
@@ -271,7 +271,7 @@ export class KupCombobox {
|
|
|
271
271
|
}
|
|
272
272
|
}
|
|
273
273
|
componentDidLoad() {
|
|
274
|
-
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this,
|
|
274
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_consistencyCheck).call(this, this.value, true);
|
|
275
275
|
__classPrivateFieldGet(this, _KupCombobox_kupManager, "f").debug.logLoad(this, true);
|
|
276
276
|
}
|
|
277
277
|
componentWillRender() {
|
|
@@ -297,7 +297,8 @@ export class KupCombobox {
|
|
|
297
297
|
h("div", { id: componentWrapperId, style: __classPrivateFieldGet(this, _KupCombobox_elStyle, "f") },
|
|
298
298
|
h(FTextField, Object.assign({}, this.data['kup-text-field'], { disabled: this.disabled, fullHeight: fullHeight, fullWidth: fullWidth, icon: this.showDropDownIcon
|
|
299
299
|
? KupThemeIconValues.DROPDOWN
|
|
300
|
-
: 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() })
|
|
300
|
+
: 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() }))),
|
|
301
|
+
__classPrivateFieldGet(this, _KupCombobox_instances, "m", _KupCombobox_prepList).call(this)));
|
|
301
302
|
}
|
|
302
303
|
disconnectedCallback() {
|
|
303
304
|
if (__classPrivateFieldGet(this, _KupCombobox_listEl, "f")) {
|
|
@@ -808,20 +809,22 @@ _KupCombobox_kupManager = new WeakMap(), _KupCombobox_elStyle = new WeakMap(), _
|
|
|
808
809
|
__classPrivateFieldGet(this, _KupCombobox_kupManager, "f").removeClickCallback(__classPrivateFieldGet(this, _KupCombobox_clickCb, "f"));
|
|
809
810
|
}, _KupCombobox_isListOpened = function _KupCombobox_isListOpened() {
|
|
810
811
|
return __classPrivateFieldGet(this, _KupCombobox_listEl, "f").menuVisible == true;
|
|
811
|
-
}, _KupCombobox_consistencyCheck = function _KupCombobox_consistencyCheck(
|
|
812
|
-
let ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet(this, _KupCombobox_listEl, "f"), this.selectMode, this.displayMode
|
|
813
|
-
if (ret.exists
|
|
814
|
-
|
|
815
|
-
|
|
812
|
+
}, _KupCombobox_consistencyCheck = function _KupCombobox_consistencyCheck(idIn, setValue) {
|
|
813
|
+
let ret = consistencyCheck(idIn, this.data['kup-list'], __classPrivateFieldGet(this, _KupCombobox_listEl, "f"), this.selectMode, this.displayMode);
|
|
814
|
+
if (ret.exists) {
|
|
815
|
+
if (setValue) {
|
|
816
|
+
this.value = ret.value;
|
|
817
|
+
this.displayedValue = ret.displayedValue;
|
|
818
|
+
}
|
|
816
819
|
if (__classPrivateFieldGet(this, _KupCombobox_listEl, "f") != null) {
|
|
817
|
-
__classPrivateFieldGet(this, _KupCombobox_listEl, "f").filter =
|
|
820
|
+
__classPrivateFieldGet(this, _KupCombobox_listEl, "f").filter = ret.value;
|
|
818
821
|
}
|
|
819
822
|
}
|
|
820
823
|
else {
|
|
821
824
|
this.value = idIn;
|
|
822
825
|
this.displayedValue = idIn;
|
|
823
826
|
if (__classPrivateFieldGet(this, _KupCombobox_listEl, "f") != null) {
|
|
824
|
-
__classPrivateFieldGet(this, _KupCombobox_listEl, "f").filter =
|
|
827
|
+
__classPrivateFieldGet(this, _KupCombobox_listEl, "f").filter = ret.value;
|
|
825
828
|
}
|
|
826
829
|
}
|
|
827
830
|
return ret;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Props of the kup-dashboard component.
|
|
3
|
+
* Used to export every prop in an object.
|
|
4
|
+
*/
|
|
5
|
+
export var KupDashboardProps;
|
|
6
|
+
(function (KupDashboardProps) {
|
|
7
|
+
KupDashboardProps["customStyle"] = "Custom style of the component.";
|
|
8
|
+
KupDashboardProps["data"] = "The data of the component.";
|
|
9
|
+
KupDashboardProps["enableDesign"] = "When set to true, the component is in design mode and it is draggable.";
|
|
10
|
+
})(KupDashboardProps || (KupDashboardProps = {}));
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
height: 100%;
|
|
4
4
|
}
|
|
5
5
|
|
|
6
|
+
#kup-component {
|
|
7
|
+
height: 100%;
|
|
8
|
+
}
|
|
9
|
+
|
|
6
10
|
.header {
|
|
7
11
|
display: flex;
|
|
8
12
|
flex-direction: row;
|
|
@@ -14,17 +18,19 @@
|
|
|
14
18
|
|
|
15
19
|
.form {
|
|
16
20
|
display: grid;
|
|
17
|
-
|
|
21
|
+
height: 100%;
|
|
18
22
|
}
|
|
19
23
|
|
|
20
24
|
.form-dropzone {
|
|
21
25
|
padding: 1em;
|
|
26
|
+
grid-gap: 0.5em;
|
|
22
27
|
border: 1px solid var(--kup-primary-color);
|
|
23
28
|
}
|
|
24
29
|
|
|
25
30
|
.section {
|
|
26
31
|
display: flex;
|
|
27
32
|
flex-direction: column;
|
|
33
|
+
overflow: auto;
|
|
28
34
|
}
|
|
29
35
|
|
|
30
36
|
.section-header {
|
|
@@ -51,7 +57,6 @@
|
|
|
51
57
|
|
|
52
58
|
.section-dropzone {
|
|
53
59
|
border: 1px solid var(--kup-primary-color);
|
|
54
|
-
min-height: 100px;
|
|
55
60
|
}
|
|
56
61
|
|
|
57
62
|
.section-draggable {
|
|
@@ -65,10 +70,6 @@
|
|
|
65
70
|
margin: 0.5em;
|
|
66
71
|
}
|
|
67
72
|
|
|
68
|
-
.component-draggable {
|
|
69
|
-
border: 1px solid var(--kup-secondary-color);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
73
|
.layout-row {
|
|
73
74
|
grid-auto-flow: column;
|
|
74
75
|
grid-template-columns: min-content;
|