@kodaris/krubble-components 1.0.61 → 1.0.63
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/custom-elements.json +1271 -460
- package/dist/form/checkbox/checkbox.d.ts +71 -0
- package/dist/form/checkbox/checkbox.d.ts.map +1 -0
- package/dist/form/checkbox/checkbox.js +304 -0
- package/dist/form/checkbox/checkbox.js.map +1 -0
- package/dist/form/index.d.ts +2 -0
- package/dist/form/index.d.ts.map +1 -1
- package/dist/form/index.js +2 -0
- package/dist/form/index.js.map +1 -1
- package/dist/form/radio-cards/radio-cards.d.ts +81 -0
- package/dist/form/radio-cards/radio-cards.d.ts.map +1 -0
- package/dist/form/radio-cards/radio-cards.js +388 -0
- package/dist/form/radio-cards/radio-cards.js.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/krubble-components.bundled.js +892 -210
- package/dist/krubble-components.bundled.js.map +1 -1
- package/dist/krubble-components.bundled.min.js +384 -117
- package/dist/krubble-components.bundled.min.js.map +1 -1
- package/dist/krubble-components.umd.js +891 -209
- package/dist/krubble-components.umd.js.map +1 -1
- package/dist/krubble-components.umd.min.js +342 -75
- package/dist/krubble-components.umd.min.js.map +1 -1
- package/package.json +17 -1
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
96
96
|
*/function e$3(e,r){return (n,s,i)=>{const o=t=>t.renderRoot?.querySelector(e)??null;return e$4(n,s,{get(){return o(this)}})}}
|
|
97
97
|
|
|
98
|
-
var __decorate$
|
|
98
|
+
var __decorate$n = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
99
99
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
100
100
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
101
101
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -202,13 +202,13 @@
|
|
|
202
202
|
padding: 16px 16px 8px 16px;
|
|
203
203
|
}
|
|
204
204
|
`;
|
|
205
|
-
__decorate$
|
|
205
|
+
__decorate$n([
|
|
206
206
|
n$1({ type: String })
|
|
207
207
|
], exports.KRAccordion.prototype, "header", void 0);
|
|
208
|
-
__decorate$
|
|
208
|
+
__decorate$n([
|
|
209
209
|
n$1({ type: Boolean, reflect: true })
|
|
210
210
|
], exports.KRAccordion.prototype, "expanded", void 0);
|
|
211
|
-
exports.KRAccordion = __decorate$
|
|
211
|
+
exports.KRAccordion = __decorate$n([
|
|
212
212
|
t$1('kr-accordion')
|
|
213
213
|
], exports.KRAccordion);
|
|
214
214
|
|
|
@@ -225,7 +225,7 @@
|
|
|
225
225
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
226
226
|
*/const e$1=e$2(class extends i$1{constructor(t$1){if(super(t$1),t$1.type!==t.ATTRIBUTE||"class"!==t$1.name||t$1.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter(s=>t[s]).join(" ")+" "}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(" ").split(/\s/).filter(t=>""!==t)));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)));}return E}});
|
|
227
227
|
|
|
228
|
-
var __decorate$
|
|
228
|
+
var __decorate$m = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
229
229
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
230
230
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
231
231
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -423,23 +423,23 @@
|
|
|
423
423
|
outline-offset: 2px;
|
|
424
424
|
}
|
|
425
425
|
`;
|
|
426
|
-
__decorate$
|
|
426
|
+
__decorate$m([
|
|
427
427
|
n$1({ type: String })
|
|
428
428
|
], exports.KRAlert.prototype, "type", void 0);
|
|
429
|
-
__decorate$
|
|
429
|
+
__decorate$m([
|
|
430
430
|
n$1({ type: String })
|
|
431
431
|
], exports.KRAlert.prototype, "title", void 0);
|
|
432
|
-
__decorate$
|
|
432
|
+
__decorate$m([
|
|
433
433
|
n$1({ type: Boolean })
|
|
434
434
|
], exports.KRAlert.prototype, "dismissible", void 0);
|
|
435
|
-
__decorate$
|
|
435
|
+
__decorate$m([
|
|
436
436
|
n$1({ type: Boolean })
|
|
437
437
|
], exports.KRAlert.prototype, "visible", void 0);
|
|
438
|
-
exports.KRAlert = __decorate$
|
|
438
|
+
exports.KRAlert = __decorate$m([
|
|
439
439
|
t$1('kr-alert')
|
|
440
440
|
], exports.KRAlert);
|
|
441
441
|
|
|
442
|
-
var __decorate$
|
|
442
|
+
var __decorate$l = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
443
443
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
444
444
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
445
445
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -938,40 +938,40 @@
|
|
|
938
938
|
height: 22px;
|
|
939
939
|
}
|
|
940
940
|
`;
|
|
941
|
-
__decorate$
|
|
941
|
+
__decorate$l([
|
|
942
942
|
n$1({ type: String, reflect: true })
|
|
943
943
|
], exports.KRButton.prototype, "variant", void 0);
|
|
944
|
-
__decorate$
|
|
944
|
+
__decorate$l([
|
|
945
945
|
n$1({ type: String, reflect: true })
|
|
946
946
|
], exports.KRButton.prototype, "color", void 0);
|
|
947
|
-
__decorate$
|
|
947
|
+
__decorate$l([
|
|
948
948
|
n$1({ type: String, reflect: true })
|
|
949
949
|
], exports.KRButton.prototype, "size", void 0);
|
|
950
|
-
__decorate$
|
|
950
|
+
__decorate$l([
|
|
951
951
|
n$1({ type: Boolean, reflect: true })
|
|
952
952
|
], exports.KRButton.prototype, "disabled", void 0);
|
|
953
|
-
__decorate$
|
|
953
|
+
__decorate$l([
|
|
954
954
|
n$1({ type: String })
|
|
955
955
|
], exports.KRButton.prototype, "href", void 0);
|
|
956
|
-
__decorate$
|
|
956
|
+
__decorate$l([
|
|
957
957
|
n$1({ type: String })
|
|
958
958
|
], exports.KRButton.prototype, "target", void 0);
|
|
959
|
-
__decorate$
|
|
959
|
+
__decorate$l([
|
|
960
960
|
n$1({ type: Array })
|
|
961
961
|
], exports.KRButton.prototype, "options", void 0);
|
|
962
|
-
__decorate$
|
|
962
|
+
__decorate$l([
|
|
963
963
|
n$1({ type: String, reflect: true, attribute: 'icon-position' })
|
|
964
964
|
], exports.KRButton.prototype, "iconPosition", void 0);
|
|
965
|
-
__decorate$
|
|
965
|
+
__decorate$l([
|
|
966
966
|
r$1()
|
|
967
967
|
], exports.KRButton.prototype, "_state", void 0);
|
|
968
|
-
__decorate$
|
|
968
|
+
__decorate$l([
|
|
969
969
|
r$1()
|
|
970
970
|
], exports.KRButton.prototype, "_stateText", void 0);
|
|
971
|
-
__decorate$
|
|
971
|
+
__decorate$l([
|
|
972
972
|
r$1()
|
|
973
973
|
], exports.KRButton.prototype, "_dropdownOpened", void 0);
|
|
974
|
-
exports.KRButton = __decorate$
|
|
974
|
+
exports.KRButton = __decorate$l([
|
|
975
975
|
t$1('kr-button')
|
|
976
976
|
], exports.KRButton);
|
|
977
977
|
|
|
@@ -981,7 +981,7 @@
|
|
|
981
981
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
982
982
|
*/class e extends i$1{constructor(i){if(super(i),this.it=A,i.type!==t.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(r){if(r===A||null==r)return this._t=void 0,this.it=r;if(r===E)return r;if("string"!=typeof r)throw Error(this.constructor.directiveName+"() called with a non-string value");if(r===this.it)return this._t;this.it=r;const s=[r];return s.raw=s,this._t={_$litType$:this.constructor.resultType,strings:s,values:[]}}}e.directiveName="unsafeHTML",e.resultType=1;const o$2=e$2(e);
|
|
983
983
|
|
|
984
|
-
var __decorate$
|
|
984
|
+
var __decorate$k = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
985
985
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
986
986
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
987
987
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -1215,26 +1215,26 @@
|
|
|
1215
1215
|
.hljs-property { color: #005cc5; }
|
|
1216
1216
|
|
|
1217
1217
|
`];
|
|
1218
|
-
__decorate$
|
|
1218
|
+
__decorate$k([
|
|
1219
1219
|
n$1({ type: String })
|
|
1220
1220
|
], exports.KRCodeDemo.prototype, "language", void 0);
|
|
1221
|
-
__decorate$
|
|
1221
|
+
__decorate$k([
|
|
1222
1222
|
r$1()
|
|
1223
1223
|
], exports.KRCodeDemo.prototype, "code", void 0);
|
|
1224
|
-
__decorate$
|
|
1224
|
+
__decorate$k([
|
|
1225
1225
|
r$1()
|
|
1226
1226
|
], exports.KRCodeDemo.prototype, "activeTab", void 0);
|
|
1227
|
-
__decorate$
|
|
1227
|
+
__decorate$k([
|
|
1228
1228
|
r$1()
|
|
1229
1229
|
], exports.KRCodeDemo.prototype, "copied", void 0);
|
|
1230
|
-
__decorate$
|
|
1230
|
+
__decorate$k([
|
|
1231
1231
|
r$1()
|
|
1232
1232
|
], exports.KRCodeDemo.prototype, "highlightedCode", void 0);
|
|
1233
|
-
exports.KRCodeDemo = __decorate$
|
|
1233
|
+
exports.KRCodeDemo = __decorate$k([
|
|
1234
1234
|
t$1('kr-code-demo')
|
|
1235
1235
|
], exports.KRCodeDemo);
|
|
1236
1236
|
|
|
1237
|
-
var __decorate$
|
|
1237
|
+
var __decorate$j = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1238
1238
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1239
1239
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1240
1240
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -1403,10 +1403,10 @@
|
|
|
1403
1403
|
margin: 4px 0;
|
|
1404
1404
|
}
|
|
1405
1405
|
`;
|
|
1406
|
-
__decorate$
|
|
1406
|
+
__decorate$j([
|
|
1407
1407
|
r$1()
|
|
1408
1408
|
], exports.KRContextMenu.prototype, "items", void 0);
|
|
1409
|
-
exports.KRContextMenu = __decorate$
|
|
1409
|
+
exports.KRContextMenu = __decorate$j([
|
|
1410
1410
|
t$1('kr-context-menu')
|
|
1411
1411
|
], exports.KRContextMenu);
|
|
1412
1412
|
|
|
@@ -1416,7 +1416,7 @@
|
|
|
1416
1416
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1417
1417
|
*/const n="important",i=" !"+n,o$1=e$2(class extends i$1{constructor(t$1){if(super(t$1),t$1.type!==t.ATTRIBUTE||"style"!==t$1.name||t$1.strings?.length>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce((e,r)=>{const s=t[r];return null==s?e:e+`${r=r.includes("-")?r:r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`},"")}update(e,[r]){const{style:s}=e.element;if(void 0===this.ft)return this.ft=new Set(Object.keys(r)),this.render(r);for(const t of this.ft)null==r[t]&&(this.ft.delete(t),t.includes("-")?s.removeProperty(t):s[t]=null);for(const t in r){const e=r[t];if(null!=e){this.ft.add(t);const r="string"==typeof e&&e.endsWith(i);t.includes("-")||r?s.setProperty(t,r?e.slice(0,-11):e,r?n:""):s[t]=e;}}return E}});
|
|
1418
1418
|
|
|
1419
|
-
var __decorate$
|
|
1419
|
+
var __decorate$i = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1420
1420
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1421
1421
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1422
1422
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -1443,7 +1443,7 @@
|
|
|
1443
1443
|
font-weight: 600;
|
|
1444
1444
|
}
|
|
1445
1445
|
`;
|
|
1446
|
-
KRDialogHeader = __decorate$
|
|
1446
|
+
KRDialogHeader = __decorate$i([
|
|
1447
1447
|
t$1('kr-dialog-header')
|
|
1448
1448
|
], KRDialogHeader);
|
|
1449
1449
|
let KRDialogContent = class KRDialogContent extends i$2 {
|
|
@@ -1459,7 +1459,7 @@
|
|
|
1459
1459
|
flex: 1 1 auto;
|
|
1460
1460
|
}
|
|
1461
1461
|
`;
|
|
1462
|
-
KRDialogContent = __decorate$
|
|
1462
|
+
KRDialogContent = __decorate$i([
|
|
1463
1463
|
t$1('kr-dialog-content')
|
|
1464
1464
|
], KRDialogContent);
|
|
1465
1465
|
let KRDialogFooter = class KRDialogFooter extends i$2 {
|
|
@@ -1479,7 +1479,7 @@
|
|
|
1479
1479
|
justify-content: flex-end;
|
|
1480
1480
|
}
|
|
1481
1481
|
`;
|
|
1482
|
-
KRDialogFooter = __decorate$
|
|
1482
|
+
KRDialogFooter = __decorate$i([
|
|
1483
1483
|
t$1('kr-dialog-footer')
|
|
1484
1484
|
], KRDialogFooter);
|
|
1485
1485
|
/**
|
|
@@ -1687,23 +1687,23 @@
|
|
|
1687
1687
|
font-weight: 600;
|
|
1688
1688
|
}
|
|
1689
1689
|
`;
|
|
1690
|
-
__decorate$
|
|
1690
|
+
__decorate$i([
|
|
1691
1691
|
r$1()
|
|
1692
1692
|
], exports.KRDialog.prototype, "_contentElement", void 0);
|
|
1693
|
-
__decorate$
|
|
1693
|
+
__decorate$i([
|
|
1694
1694
|
n$1({ type: Boolean, reflect: true })
|
|
1695
1695
|
], exports.KRDialog.prototype, "opened", void 0);
|
|
1696
|
-
__decorate$
|
|
1696
|
+
__decorate$i([
|
|
1697
1697
|
n$1({ type: String })
|
|
1698
1698
|
], exports.KRDialog.prototype, "label", void 0);
|
|
1699
|
-
__decorate$
|
|
1699
|
+
__decorate$i([
|
|
1700
1700
|
n$1({ type: String })
|
|
1701
1701
|
], exports.KRDialog.prototype, "width", void 0);
|
|
1702
|
-
exports.KRDialog = __decorate$
|
|
1702
|
+
exports.KRDialog = __decorate$i([
|
|
1703
1703
|
t$1('kr-dialog')
|
|
1704
1704
|
], exports.KRDialog);
|
|
1705
1705
|
|
|
1706
|
-
var __decorate$
|
|
1706
|
+
var __decorate$h = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1707
1707
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1708
1708
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1709
1709
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -2223,47 +2223,47 @@
|
|
|
2223
2223
|
border-top: 1px solid #e5e7eb;
|
|
2224
2224
|
}
|
|
2225
2225
|
`;
|
|
2226
|
-
__decorate$
|
|
2226
|
+
__decorate$h([
|
|
2227
2227
|
n$1({ type: Object })
|
|
2228
2228
|
], exports.KRDateRangePicker.prototype, "value", void 0);
|
|
2229
|
-
__decorate$
|
|
2229
|
+
__decorate$h([
|
|
2230
2230
|
n$1({ type: Array })
|
|
2231
2231
|
], exports.KRDateRangePicker.prototype, "relativeOptions", void 0);
|
|
2232
|
-
__decorate$
|
|
2232
|
+
__decorate$h([
|
|
2233
2233
|
n$1({ type: Boolean })
|
|
2234
2234
|
], exports.KRDateRangePicker.prototype, "disabled", void 0);
|
|
2235
|
-
__decorate$
|
|
2235
|
+
__decorate$h([
|
|
2236
2236
|
n$1({ type: Boolean })
|
|
2237
2237
|
], exports.KRDateRangePicker.prototype, "invalid", void 0);
|
|
2238
|
-
__decorate$
|
|
2238
|
+
__decorate$h([
|
|
2239
2239
|
n$1({ type: String })
|
|
2240
2240
|
], exports.KRDateRangePicker.prototype, "placeholder", void 0);
|
|
2241
|
-
__decorate$
|
|
2241
|
+
__decorate$h([
|
|
2242
2242
|
n$1({ type: String })
|
|
2243
2243
|
], exports.KRDateRangePicker.prototype, "startDate", void 0);
|
|
2244
|
-
__decorate$
|
|
2244
|
+
__decorate$h([
|
|
2245
2245
|
n$1({ type: String })
|
|
2246
2246
|
], exports.KRDateRangePicker.prototype, "endDate", void 0);
|
|
2247
|
-
__decorate$
|
|
2247
|
+
__decorate$h([
|
|
2248
2248
|
n$1({ type: String })
|
|
2249
2249
|
], exports.KRDateRangePicker.prototype, "mode", void 0);
|
|
2250
|
-
__decorate$
|
|
2250
|
+
__decorate$h([
|
|
2251
2251
|
r$1()
|
|
2252
2252
|
], exports.KRDateRangePicker.prototype, "_isOpen", void 0);
|
|
2253
|
-
__decorate$
|
|
2253
|
+
__decorate$h([
|
|
2254
2254
|
r$1()
|
|
2255
2255
|
], exports.KRDateRangePicker.prototype, "_activeTab", void 0);
|
|
2256
|
-
__decorate$
|
|
2256
|
+
__decorate$h([
|
|
2257
2257
|
r$1()
|
|
2258
2258
|
], exports.KRDateRangePicker.prototype, "_tempStartDate", void 0);
|
|
2259
|
-
__decorate$
|
|
2259
|
+
__decorate$h([
|
|
2260
2260
|
r$1()
|
|
2261
2261
|
], exports.KRDateRangePicker.prototype, "_tempEndDate", void 0);
|
|
2262
|
-
exports.KRDateRangePicker = __decorate$
|
|
2262
|
+
exports.KRDateRangePicker = __decorate$h([
|
|
2263
2263
|
t$1('kr-date-range-picker')
|
|
2264
2264
|
], exports.KRDateRangePicker);
|
|
2265
2265
|
|
|
2266
|
-
var __decorate$
|
|
2266
|
+
var __decorate$g = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
2267
2267
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
2268
2268
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
2269
2269
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -2565,23 +2565,23 @@
|
|
|
2565
2565
|
`;
|
|
2566
2566
|
/** Track active snackbars for stacking */
|
|
2567
2567
|
exports.KRSnackbar.activeSnackbars = [];
|
|
2568
|
-
__decorate$
|
|
2568
|
+
__decorate$g([
|
|
2569
2569
|
n$1({ type: String })
|
|
2570
2570
|
], exports.KRSnackbar.prototype, "type", void 0);
|
|
2571
|
-
__decorate$
|
|
2571
|
+
__decorate$g([
|
|
2572
2572
|
n$1({ type: String })
|
|
2573
2573
|
], exports.KRSnackbar.prototype, "title", void 0);
|
|
2574
|
-
__decorate$
|
|
2574
|
+
__decorate$g([
|
|
2575
2575
|
n$1({ type: String })
|
|
2576
2576
|
], exports.KRSnackbar.prototype, "message", void 0);
|
|
2577
|
-
__decorate$
|
|
2577
|
+
__decorate$g([
|
|
2578
2578
|
n$1({ type: Number })
|
|
2579
2579
|
], exports.KRSnackbar.prototype, "duration", void 0);
|
|
2580
|
-
exports.KRSnackbar = KRSnackbar_1 = __decorate$
|
|
2580
|
+
exports.KRSnackbar = KRSnackbar_1 = __decorate$g([
|
|
2581
2581
|
t$1('kr-snackbar')
|
|
2582
2582
|
], exports.KRSnackbar);
|
|
2583
2583
|
|
|
2584
|
-
var __decorate$
|
|
2584
|
+
var __decorate$f = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
2585
2585
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
2586
2586
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
2587
2587
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -2884,20 +2884,20 @@
|
|
|
2884
2884
|
}
|
|
2885
2885
|
`,
|
|
2886
2886
|
];
|
|
2887
|
-
__decorate$
|
|
2887
|
+
__decorate$f([
|
|
2888
2888
|
n$1({ type: String, attribute: 'active-tab-id' })
|
|
2889
2889
|
], exports.KRTabGroup.prototype, "activeTabId", void 0);
|
|
2890
|
-
__decorate$
|
|
2890
|
+
__decorate$f([
|
|
2891
2891
|
n$1({ type: Boolean })
|
|
2892
2892
|
], exports.KRTabGroup.prototype, "justified", void 0);
|
|
2893
|
-
__decorate$
|
|
2893
|
+
__decorate$f([
|
|
2894
2894
|
n$1({ type: String, reflect: true })
|
|
2895
2895
|
], exports.KRTabGroup.prototype, "size", void 0);
|
|
2896
|
-
exports.KRTabGroup = __decorate$
|
|
2896
|
+
exports.KRTabGroup = __decorate$f([
|
|
2897
2897
|
t$1('kr-tab-group')
|
|
2898
2898
|
], exports.KRTabGroup);
|
|
2899
2899
|
|
|
2900
|
-
var __decorate$
|
|
2900
|
+
var __decorate$e = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
2901
2901
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
2902
2902
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
2903
2903
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -2978,35 +2978,35 @@
|
|
|
2978
2978
|
}
|
|
2979
2979
|
`,
|
|
2980
2980
|
];
|
|
2981
|
-
__decorate$
|
|
2981
|
+
__decorate$e([
|
|
2982
2982
|
n$1({ type: String, reflect: true })
|
|
2983
2983
|
], exports.KRTab.prototype, "id", void 0);
|
|
2984
|
-
__decorate$
|
|
2984
|
+
__decorate$e([
|
|
2985
2985
|
n$1({ type: String })
|
|
2986
2986
|
], exports.KRTab.prototype, "label", void 0);
|
|
2987
|
-
__decorate$
|
|
2987
|
+
__decorate$e([
|
|
2988
2988
|
n$1({ type: String })
|
|
2989
2989
|
], exports.KRTab.prototype, "badge", void 0);
|
|
2990
|
-
__decorate$
|
|
2990
|
+
__decorate$e([
|
|
2991
2991
|
n$1({ type: String, attribute: 'badge-background' })
|
|
2992
2992
|
], exports.KRTab.prototype, "badgeBackground", void 0);
|
|
2993
|
-
__decorate$
|
|
2993
|
+
__decorate$e([
|
|
2994
2994
|
n$1({ type: String, attribute: 'badge-color' })
|
|
2995
2995
|
], exports.KRTab.prototype, "badgeColor", void 0);
|
|
2996
|
-
__decorate$
|
|
2996
|
+
__decorate$e([
|
|
2997
2997
|
n$1({ type: Boolean })
|
|
2998
2998
|
], exports.KRTab.prototype, "disabled", void 0);
|
|
2999
|
-
__decorate$
|
|
2999
|
+
__decorate$e([
|
|
3000
3000
|
n$1({ type: Boolean })
|
|
3001
3001
|
], exports.KRTab.prototype, "dismissible", void 0);
|
|
3002
|
-
__decorate$
|
|
3002
|
+
__decorate$e([
|
|
3003
3003
|
n$1({ type: Boolean, reflect: true })
|
|
3004
3004
|
], exports.KRTab.prototype, "active", void 0);
|
|
3005
|
-
exports.KRTab = __decorate$
|
|
3005
|
+
exports.KRTab = __decorate$e([
|
|
3006
3006
|
t$1('kr-tab')
|
|
3007
3007
|
], exports.KRTab);
|
|
3008
3008
|
|
|
3009
|
-
var __decorate$
|
|
3009
|
+
var __decorate$d = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
3010
3010
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3011
3011
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
3012
3012
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -3478,47 +3478,47 @@
|
|
|
3478
3478
|
`];
|
|
3479
3479
|
// Enable form association
|
|
3480
3480
|
exports.KRSelectField.formAssociated = true;
|
|
3481
|
-
__decorate$
|
|
3481
|
+
__decorate$d([
|
|
3482
3482
|
n$1({ type: String })
|
|
3483
3483
|
], exports.KRSelectField.prototype, "label", void 0);
|
|
3484
|
-
__decorate$
|
|
3484
|
+
__decorate$d([
|
|
3485
3485
|
n$1({ type: String })
|
|
3486
3486
|
], exports.KRSelectField.prototype, "name", void 0);
|
|
3487
|
-
__decorate$
|
|
3487
|
+
__decorate$d([
|
|
3488
3488
|
n$1({ type: String })
|
|
3489
3489
|
], exports.KRSelectField.prototype, "value", void 0);
|
|
3490
|
-
__decorate$
|
|
3490
|
+
__decorate$d([
|
|
3491
3491
|
n$1({ type: String })
|
|
3492
3492
|
], exports.KRSelectField.prototype, "placeholder", void 0);
|
|
3493
|
-
__decorate$
|
|
3493
|
+
__decorate$d([
|
|
3494
3494
|
n$1({ type: Boolean })
|
|
3495
3495
|
], exports.KRSelectField.prototype, "disabled", void 0);
|
|
3496
|
-
__decorate$
|
|
3496
|
+
__decorate$d([
|
|
3497
3497
|
n$1({ type: Boolean })
|
|
3498
3498
|
], exports.KRSelectField.prototype, "required", void 0);
|
|
3499
|
-
__decorate$
|
|
3499
|
+
__decorate$d([
|
|
3500
3500
|
n$1({ type: Boolean })
|
|
3501
3501
|
], exports.KRSelectField.prototype, "readonly", void 0);
|
|
3502
|
-
__decorate$
|
|
3502
|
+
__decorate$d([
|
|
3503
3503
|
n$1({ type: String })
|
|
3504
3504
|
], exports.KRSelectField.prototype, "hint", void 0);
|
|
3505
|
-
__decorate$
|
|
3505
|
+
__decorate$d([
|
|
3506
3506
|
r$1()
|
|
3507
3507
|
], exports.KRSelectField.prototype, "_isOpen", void 0);
|
|
3508
|
-
__decorate$
|
|
3508
|
+
__decorate$d([
|
|
3509
3509
|
r$1()
|
|
3510
3510
|
], exports.KRSelectField.prototype, "_highlightedIndex", void 0);
|
|
3511
|
-
__decorate$
|
|
3511
|
+
__decorate$d([
|
|
3512
3512
|
r$1()
|
|
3513
3513
|
], exports.KRSelectField.prototype, "_touched", void 0);
|
|
3514
|
-
__decorate$
|
|
3514
|
+
__decorate$d([
|
|
3515
3515
|
e$3('.select-trigger')
|
|
3516
3516
|
], exports.KRSelectField.prototype, "_triggerElement", void 0);
|
|
3517
|
-
exports.KRSelectField = __decorate$
|
|
3517
|
+
exports.KRSelectField = __decorate$d([
|
|
3518
3518
|
t$1('kr-select-field')
|
|
3519
3519
|
], exports.KRSelectField);
|
|
3520
3520
|
|
|
3521
|
-
var __decorate$
|
|
3521
|
+
var __decorate$c = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
3522
3522
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3523
3523
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
3524
3524
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -3555,13 +3555,13 @@
|
|
|
3555
3555
|
display: none;
|
|
3556
3556
|
}
|
|
3557
3557
|
`;
|
|
3558
|
-
__decorate$
|
|
3558
|
+
__decorate$c([
|
|
3559
3559
|
n$1({ type: String })
|
|
3560
3560
|
], exports.KRSelectOption.prototype, "value", void 0);
|
|
3561
|
-
__decorate$
|
|
3561
|
+
__decorate$c([
|
|
3562
3562
|
n$1({ type: Boolean })
|
|
3563
3563
|
], exports.KRSelectOption.prototype, "disabled", void 0);
|
|
3564
|
-
exports.KRSelectOption = __decorate$
|
|
3564
|
+
exports.KRSelectOption = __decorate$c([
|
|
3565
3565
|
t$1('kr-select-option')
|
|
3566
3566
|
], exports.KRSelectOption);
|
|
3567
3567
|
|
|
@@ -4609,7 +4609,7 @@
|
|
|
4609
4609
|
}
|
|
4610
4610
|
}
|
|
4611
4611
|
|
|
4612
|
-
var __decorate$
|
|
4612
|
+
var __decorate$b = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
4613
4613
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4614
4614
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4615
4615
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -6886,59 +6886,59 @@
|
|
|
6886
6886
|
}
|
|
6887
6887
|
|
|
6888
6888
|
`];
|
|
6889
|
-
__decorate$
|
|
6889
|
+
__decorate$b([
|
|
6890
6890
|
r$1()
|
|
6891
6891
|
], exports.KRTable.prototype, "_data", void 0);
|
|
6892
|
-
__decorate$
|
|
6892
|
+
__decorate$b([
|
|
6893
6893
|
r$1()
|
|
6894
6894
|
], exports.KRTable.prototype, "_dataState", void 0);
|
|
6895
|
-
__decorate$
|
|
6895
|
+
__decorate$b([
|
|
6896
6896
|
r$1()
|
|
6897
6897
|
], exports.KRTable.prototype, "_page", void 0);
|
|
6898
|
-
__decorate$
|
|
6898
|
+
__decorate$b([
|
|
6899
6899
|
r$1()
|
|
6900
6900
|
], exports.KRTable.prototype, "_pageSize", void 0);
|
|
6901
|
-
__decorate$
|
|
6901
|
+
__decorate$b([
|
|
6902
6902
|
r$1()
|
|
6903
6903
|
], exports.KRTable.prototype, "_totalItems", void 0);
|
|
6904
|
-
__decorate$
|
|
6904
|
+
__decorate$b([
|
|
6905
6905
|
r$1()
|
|
6906
6906
|
], exports.KRTable.prototype, "_totalPages", void 0);
|
|
6907
|
-
__decorate$
|
|
6907
|
+
__decorate$b([
|
|
6908
6908
|
r$1()
|
|
6909
6909
|
], exports.KRTable.prototype, "_searchQuery", void 0);
|
|
6910
|
-
__decorate$
|
|
6910
|
+
__decorate$b([
|
|
6911
6911
|
r$1()
|
|
6912
6912
|
], exports.KRTable.prototype, "_canScrollLeft", void 0);
|
|
6913
|
-
__decorate$
|
|
6913
|
+
__decorate$b([
|
|
6914
6914
|
r$1()
|
|
6915
6915
|
], exports.KRTable.prototype, "_canScrollRight", void 0);
|
|
6916
|
-
__decorate$
|
|
6916
|
+
__decorate$b([
|
|
6917
6917
|
r$1()
|
|
6918
6918
|
], exports.KRTable.prototype, "_canScrollHorizontal", void 0);
|
|
6919
|
-
__decorate$
|
|
6919
|
+
__decorate$b([
|
|
6920
6920
|
r$1()
|
|
6921
6921
|
], exports.KRTable.prototype, "_columnPickerOpen", void 0);
|
|
6922
|
-
__decorate$
|
|
6922
|
+
__decorate$b([
|
|
6923
6923
|
r$1()
|
|
6924
6924
|
], exports.KRTable.prototype, "_filterPanelOpened", void 0);
|
|
6925
|
-
__decorate$
|
|
6925
|
+
__decorate$b([
|
|
6926
6926
|
r$1()
|
|
6927
6927
|
], exports.KRTable.prototype, "_filterPanelTab", void 0);
|
|
6928
|
-
__decorate$
|
|
6928
|
+
__decorate$b([
|
|
6929
6929
|
r$1()
|
|
6930
6930
|
], exports.KRTable.prototype, "_buckets", void 0);
|
|
6931
|
-
__decorate$
|
|
6931
|
+
__decorate$b([
|
|
6932
6932
|
r$1()
|
|
6933
6933
|
], exports.KRTable.prototype, "_sorts", void 0);
|
|
6934
|
-
__decorate$
|
|
6934
|
+
__decorate$b([
|
|
6935
6935
|
n$1({ type: Object })
|
|
6936
6936
|
], exports.KRTable.prototype, "def", void 0);
|
|
6937
|
-
exports.KRTable = __decorate$
|
|
6937
|
+
exports.KRTable = __decorate$b([
|
|
6938
6938
|
t$1('kr-table')
|
|
6939
6939
|
], exports.KRTable);
|
|
6940
6940
|
|
|
6941
|
-
var __decorate$
|
|
6941
|
+
var __decorate$a = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
6942
6942
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
6943
6943
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
6944
6944
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -7058,17 +7058,17 @@
|
|
|
7058
7058
|
stroke-linecap: round;
|
|
7059
7059
|
}
|
|
7060
7060
|
`;
|
|
7061
|
-
__decorate$
|
|
7061
|
+
__decorate$a([
|
|
7062
7062
|
n$1({ type: String, reflect: true })
|
|
7063
7063
|
], exports.KRSpinner.prototype, "size", void 0);
|
|
7064
|
-
__decorate$
|
|
7064
|
+
__decorate$a([
|
|
7065
7065
|
n$1({ type: String, reflect: true })
|
|
7066
7066
|
], exports.KRSpinner.prototype, "color", void 0);
|
|
7067
|
-
exports.KRSpinner = __decorate$
|
|
7067
|
+
exports.KRSpinner = __decorate$a([
|
|
7068
7068
|
t$1('kr-spinner')
|
|
7069
7069
|
], exports.KRSpinner);
|
|
7070
7070
|
|
|
7071
|
-
var __decorate$
|
|
7071
|
+
var __decorate$9 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
7072
7072
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
7073
7073
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7074
7074
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -7159,17 +7159,17 @@
|
|
|
7159
7159
|
}
|
|
7160
7160
|
}
|
|
7161
7161
|
`;
|
|
7162
|
-
__decorate$
|
|
7162
|
+
__decorate$9([
|
|
7163
7163
|
n$1({ type: String, reflect: true })
|
|
7164
7164
|
], exports.KRProgressBar.prototype, "color", void 0);
|
|
7165
|
-
__decorate$
|
|
7165
|
+
__decorate$9([
|
|
7166
7166
|
n$1({ type: String, reflect: true })
|
|
7167
7167
|
], exports.KRProgressBar.prototype, "trackColor", void 0);
|
|
7168
|
-
exports.KRProgressBar = __decorate$
|
|
7168
|
+
exports.KRProgressBar = __decorate$9([
|
|
7169
7169
|
t$1('kr-progress-bar')
|
|
7170
7170
|
], exports.KRProgressBar);
|
|
7171
7171
|
|
|
7172
|
-
var __decorate$
|
|
7172
|
+
var __decorate$8 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
7173
7173
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
7174
7174
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7175
7175
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -7637,23 +7637,23 @@
|
|
|
7637
7637
|
}
|
|
7638
7638
|
`;
|
|
7639
7639
|
exports.KRFilePreview._activePreview = null;
|
|
7640
|
-
__decorate$
|
|
7640
|
+
__decorate$8([
|
|
7641
7641
|
n$1({ type: String })
|
|
7642
7642
|
], exports.KRFilePreview.prototype, "src", void 0);
|
|
7643
|
-
__decorate$
|
|
7643
|
+
__decorate$8([
|
|
7644
7644
|
n$1({ type: String })
|
|
7645
7645
|
], exports.KRFilePreview.prototype, "name", void 0);
|
|
7646
|
-
__decorate$
|
|
7646
|
+
__decorate$8([
|
|
7647
7647
|
r$1()
|
|
7648
7648
|
], exports.KRFilePreview.prototype, "_zoomLevel", void 0);
|
|
7649
|
-
__decorate$
|
|
7649
|
+
__decorate$8([
|
|
7650
7650
|
r$1()
|
|
7651
7651
|
], exports.KRFilePreview.prototype, "_textContent", void 0);
|
|
7652
|
-
exports.KRFilePreview = KRFilePreview_1 = __decorate$
|
|
7652
|
+
exports.KRFilePreview = KRFilePreview_1 = __decorate$8([
|
|
7653
7653
|
t$1('kr-file-preview')
|
|
7654
7654
|
], exports.KRFilePreview);
|
|
7655
7655
|
|
|
7656
|
-
var __decorate$
|
|
7656
|
+
var __decorate$7 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
7657
7657
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
7658
7658
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7659
7659
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -7896,13 +7896,13 @@
|
|
|
7896
7896
|
padding: 20px;
|
|
7897
7897
|
}
|
|
7898
7898
|
`;
|
|
7899
|
-
__decorate$
|
|
7899
|
+
__decorate$7([
|
|
7900
7900
|
n$1({ type: Array })
|
|
7901
7901
|
], exports.KRFileList.prototype, "files", void 0);
|
|
7902
|
-
__decorate$
|
|
7902
|
+
__decorate$7([
|
|
7903
7903
|
n$1({ type: String, attribute: 'empty-message' })
|
|
7904
7904
|
], exports.KRFileList.prototype, "emptyMessage", void 0);
|
|
7905
|
-
exports.KRFileList = __decorate$
|
|
7905
|
+
exports.KRFileList = __decorate$7([
|
|
7906
7906
|
t$1('kr-file-list')
|
|
7907
7907
|
], exports.KRFileList);
|
|
7908
7908
|
|
|
@@ -7924,7 +7924,7 @@
|
|
|
7924
7924
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
7925
7925
|
*/const l=e$2(class extends i$1{constructor(r$1){if(super(r$1),r$1.type!==t.PROPERTY&&r$1.type!==t.ATTRIBUTE&&r$1.type!==t.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!r(r$1))throw Error("`live` bindings can only contain a single expression")}render(r){return r}update(i,[t$1]){if(t$1===E||t$1===A)return t$1;const o=i.element,l=i.name;if(i.type===t.PROPERTY){if(t$1===o[l])return E}else if(i.type===t.BOOLEAN_ATTRIBUTE){if(!!t$1===o.hasAttribute(l))return E}else if(i.type===t.ATTRIBUTE&&o.getAttribute(l)===t$1+"")return E;return p(i),t$1}});
|
|
7926
7926
|
|
|
7927
|
-
var __decorate$
|
|
7927
|
+
var __decorate$6 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
7928
7928
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
7929
7929
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7930
7930
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -8177,59 +8177,59 @@
|
|
|
8177
8177
|
`;
|
|
8178
8178
|
// Enable form association
|
|
8179
8179
|
exports.KRTextField.formAssociated = true;
|
|
8180
|
-
__decorate$
|
|
8180
|
+
__decorate$6([
|
|
8181
8181
|
n$1({ type: String })
|
|
8182
8182
|
], exports.KRTextField.prototype, "label", void 0);
|
|
8183
|
-
__decorate$
|
|
8183
|
+
__decorate$6([
|
|
8184
8184
|
n$1({ type: String })
|
|
8185
8185
|
], exports.KRTextField.prototype, "name", void 0);
|
|
8186
|
-
__decorate$
|
|
8186
|
+
__decorate$6([
|
|
8187
8187
|
n$1({ type: String })
|
|
8188
8188
|
], exports.KRTextField.prototype, "value", void 0);
|
|
8189
|
-
__decorate$
|
|
8189
|
+
__decorate$6([
|
|
8190
8190
|
n$1({ type: String })
|
|
8191
8191
|
], exports.KRTextField.prototype, "placeholder", void 0);
|
|
8192
|
-
__decorate$
|
|
8192
|
+
__decorate$6([
|
|
8193
8193
|
n$1({ type: String })
|
|
8194
8194
|
], exports.KRTextField.prototype, "type", void 0);
|
|
8195
|
-
__decorate$
|
|
8195
|
+
__decorate$6([
|
|
8196
8196
|
n$1({ type: Boolean })
|
|
8197
8197
|
], exports.KRTextField.prototype, "required", void 0);
|
|
8198
|
-
__decorate$
|
|
8198
|
+
__decorate$6([
|
|
8199
8199
|
n$1({ type: Boolean })
|
|
8200
8200
|
], exports.KRTextField.prototype, "disabled", void 0);
|
|
8201
|
-
__decorate$
|
|
8201
|
+
__decorate$6([
|
|
8202
8202
|
n$1({ type: Boolean })
|
|
8203
8203
|
], exports.KRTextField.prototype, "readonly", void 0);
|
|
8204
|
-
__decorate$
|
|
8204
|
+
__decorate$6([
|
|
8205
8205
|
n$1({ type: Number })
|
|
8206
8206
|
], exports.KRTextField.prototype, "minlength", void 0);
|
|
8207
|
-
__decorate$
|
|
8207
|
+
__decorate$6([
|
|
8208
8208
|
n$1({ type: Number })
|
|
8209
8209
|
], exports.KRTextField.prototype, "maxlength", void 0);
|
|
8210
|
-
__decorate$
|
|
8210
|
+
__decorate$6([
|
|
8211
8211
|
n$1({ type: String })
|
|
8212
8212
|
], exports.KRTextField.prototype, "pattern", void 0);
|
|
8213
|
-
__decorate$
|
|
8213
|
+
__decorate$6([
|
|
8214
8214
|
n$1({ type: String })
|
|
8215
8215
|
], exports.KRTextField.prototype, "autocomplete", void 0);
|
|
8216
|
-
__decorate$
|
|
8216
|
+
__decorate$6([
|
|
8217
8217
|
n$1({ type: String })
|
|
8218
8218
|
], exports.KRTextField.prototype, "hint", void 0);
|
|
8219
|
-
__decorate$
|
|
8219
|
+
__decorate$6([
|
|
8220
8220
|
e$3('input')
|
|
8221
8221
|
], exports.KRTextField.prototype, "_input", void 0);
|
|
8222
|
-
__decorate$
|
|
8222
|
+
__decorate$6([
|
|
8223
8223
|
r$1()
|
|
8224
8224
|
], exports.KRTextField.prototype, "_touched", void 0);
|
|
8225
|
-
__decorate$
|
|
8225
|
+
__decorate$6([
|
|
8226
8226
|
r$1()
|
|
8227
8227
|
], exports.KRTextField.prototype, "_dirty", void 0);
|
|
8228
|
-
exports.KRTextField = __decorate$
|
|
8228
|
+
exports.KRTextField = __decorate$6([
|
|
8229
8229
|
t$1('kr-text-field')
|
|
8230
8230
|
], exports.KRTextField);
|
|
8231
8231
|
|
|
8232
|
-
var __decorate$
|
|
8232
|
+
var __decorate$5 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
8233
8233
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
8234
8234
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
8235
8235
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -8487,59 +8487,59 @@
|
|
|
8487
8487
|
`;
|
|
8488
8488
|
// Enable form association
|
|
8489
8489
|
exports.KRTextareaField.formAssociated = true;
|
|
8490
|
-
__decorate$
|
|
8490
|
+
__decorate$5([
|
|
8491
8491
|
n$1({ type: String })
|
|
8492
8492
|
], exports.KRTextareaField.prototype, "label", void 0);
|
|
8493
|
-
__decorate$
|
|
8493
|
+
__decorate$5([
|
|
8494
8494
|
n$1({ type: String })
|
|
8495
8495
|
], exports.KRTextareaField.prototype, "name", void 0);
|
|
8496
|
-
__decorate$
|
|
8496
|
+
__decorate$5([
|
|
8497
8497
|
n$1({ type: String })
|
|
8498
8498
|
], exports.KRTextareaField.prototype, "value", void 0);
|
|
8499
|
-
__decorate$
|
|
8499
|
+
__decorate$5([
|
|
8500
8500
|
n$1({ type: String })
|
|
8501
8501
|
], exports.KRTextareaField.prototype, "placeholder", void 0);
|
|
8502
|
-
__decorate$
|
|
8502
|
+
__decorate$5([
|
|
8503
8503
|
n$1({ type: Boolean })
|
|
8504
8504
|
], exports.KRTextareaField.prototype, "required", void 0);
|
|
8505
|
-
__decorate$
|
|
8505
|
+
__decorate$5([
|
|
8506
8506
|
n$1({ type: Boolean })
|
|
8507
8507
|
], exports.KRTextareaField.prototype, "disabled", void 0);
|
|
8508
|
-
__decorate$
|
|
8508
|
+
__decorate$5([
|
|
8509
8509
|
n$1({ type: Boolean })
|
|
8510
8510
|
], exports.KRTextareaField.prototype, "readonly", void 0);
|
|
8511
|
-
__decorate$
|
|
8511
|
+
__decorate$5([
|
|
8512
8512
|
n$1({ type: Number })
|
|
8513
8513
|
], exports.KRTextareaField.prototype, "rows", void 0);
|
|
8514
|
-
__decorate$
|
|
8514
|
+
__decorate$5([
|
|
8515
8515
|
n$1({ type: Number })
|
|
8516
8516
|
], exports.KRTextareaField.prototype, "cols", void 0);
|
|
8517
|
-
__decorate$
|
|
8517
|
+
__decorate$5([
|
|
8518
8518
|
n$1({ type: Number })
|
|
8519
8519
|
], exports.KRTextareaField.prototype, "minlength", void 0);
|
|
8520
|
-
__decorate$
|
|
8520
|
+
__decorate$5([
|
|
8521
8521
|
n$1({ type: Number })
|
|
8522
8522
|
], exports.KRTextareaField.prototype, "maxlength", void 0);
|
|
8523
|
-
__decorate$
|
|
8523
|
+
__decorate$5([
|
|
8524
8524
|
n$1({ type: String })
|
|
8525
8525
|
], exports.KRTextareaField.prototype, "autocomplete", void 0);
|
|
8526
|
-
__decorate$
|
|
8526
|
+
__decorate$5([
|
|
8527
8527
|
n$1({ type: String })
|
|
8528
8528
|
], exports.KRTextareaField.prototype, "hint", void 0);
|
|
8529
|
-
__decorate$
|
|
8529
|
+
__decorate$5([
|
|
8530
8530
|
e$3('textarea')
|
|
8531
8531
|
], exports.KRTextareaField.prototype, "_textarea", void 0);
|
|
8532
|
-
__decorate$
|
|
8532
|
+
__decorate$5([
|
|
8533
8533
|
r$1()
|
|
8534
8534
|
], exports.KRTextareaField.prototype, "_touched", void 0);
|
|
8535
|
-
__decorate$
|
|
8535
|
+
__decorate$5([
|
|
8536
8536
|
r$1()
|
|
8537
8537
|
], exports.KRTextareaField.prototype, "_dirty", void 0);
|
|
8538
|
-
exports.KRTextareaField = __decorate$
|
|
8538
|
+
exports.KRTextareaField = __decorate$5([
|
|
8539
8539
|
t$1('kr-textarea-field')
|
|
8540
8540
|
], exports.KRTextareaField);
|
|
8541
8541
|
|
|
8542
|
-
var __decorate$
|
|
8542
|
+
var __decorate$4 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
8543
8543
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
8544
8544
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
8545
8545
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -8596,17 +8596,17 @@
|
|
|
8596
8596
|
color: black;
|
|
8597
8597
|
}
|
|
8598
8598
|
`;
|
|
8599
|
-
__decorate$
|
|
8599
|
+
__decorate$4([
|
|
8600
8600
|
n$1({ type: String })
|
|
8601
8601
|
], KRDetailField.prototype, "label", void 0);
|
|
8602
|
-
__decorate$
|
|
8602
|
+
__decorate$4([
|
|
8603
8603
|
n$1({ type: String })
|
|
8604
8604
|
], KRDetailField.prototype, "value", void 0);
|
|
8605
|
-
KRDetailField = __decorate$
|
|
8605
|
+
KRDetailField = __decorate$4([
|
|
8606
8606
|
t$1('kr-detail-field')
|
|
8607
8607
|
], KRDetailField);
|
|
8608
8608
|
|
|
8609
|
-
var __decorate$
|
|
8609
|
+
var __decorate$3 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
8610
8610
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
8611
8611
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
8612
8612
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -9102,53 +9102,53 @@
|
|
|
9102
9102
|
}
|
|
9103
9103
|
`;
|
|
9104
9104
|
exports.KRAutoSuggest.formAssociated = true;
|
|
9105
|
-
__decorate$
|
|
9105
|
+
__decorate$3([
|
|
9106
9106
|
n$1({ type: String })
|
|
9107
9107
|
], exports.KRAutoSuggest.prototype, "label", void 0);
|
|
9108
|
-
__decorate$
|
|
9108
|
+
__decorate$3([
|
|
9109
9109
|
n$1({ type: String })
|
|
9110
9110
|
], exports.KRAutoSuggest.prototype, "name", void 0);
|
|
9111
|
-
__decorate$
|
|
9111
|
+
__decorate$3([
|
|
9112
9112
|
n$1({ type: String })
|
|
9113
9113
|
], exports.KRAutoSuggest.prototype, "value", void 0);
|
|
9114
|
-
__decorate$
|
|
9114
|
+
__decorate$3([
|
|
9115
9115
|
n$1({ type: String })
|
|
9116
9116
|
], exports.KRAutoSuggest.prototype, "placeholder", void 0);
|
|
9117
|
-
__decorate$
|
|
9117
|
+
__decorate$3([
|
|
9118
9118
|
n$1({ type: Boolean })
|
|
9119
9119
|
], exports.KRAutoSuggest.prototype, "disabled", void 0);
|
|
9120
|
-
__decorate$
|
|
9120
|
+
__decorate$3([
|
|
9121
9121
|
n$1({ type: Boolean })
|
|
9122
9122
|
], exports.KRAutoSuggest.prototype, "readonly", void 0);
|
|
9123
|
-
__decorate$
|
|
9123
|
+
__decorate$3([
|
|
9124
9124
|
n$1({ type: Boolean })
|
|
9125
9125
|
], exports.KRAutoSuggest.prototype, "required", void 0);
|
|
9126
|
-
__decorate$
|
|
9126
|
+
__decorate$3([
|
|
9127
9127
|
n$1({ type: String })
|
|
9128
9128
|
], exports.KRAutoSuggest.prototype, "hint", void 0);
|
|
9129
|
-
__decorate$
|
|
9129
|
+
__decorate$3([
|
|
9130
9130
|
n$1({ type: Array })
|
|
9131
9131
|
], exports.KRAutoSuggest.prototype, "options", void 0);
|
|
9132
|
-
__decorate$
|
|
9132
|
+
__decorate$3([
|
|
9133
9133
|
n$1({ attribute: false })
|
|
9134
9134
|
], exports.KRAutoSuggest.prototype, "fetch", void 0);
|
|
9135
|
-
__decorate$
|
|
9135
|
+
__decorate$3([
|
|
9136
9136
|
r$1()
|
|
9137
9137
|
], exports.KRAutoSuggest.prototype, "_isOpen", void 0);
|
|
9138
|
-
__decorate$
|
|
9138
|
+
__decorate$3([
|
|
9139
9139
|
r$1()
|
|
9140
9140
|
], exports.KRAutoSuggest.prototype, "_highlightedIndex", void 0);
|
|
9141
|
-
__decorate$
|
|
9141
|
+
__decorate$3([
|
|
9142
9142
|
r$1()
|
|
9143
9143
|
], exports.KRAutoSuggest.prototype, "_touched", void 0);
|
|
9144
|
-
__decorate$
|
|
9144
|
+
__decorate$3([
|
|
9145
9145
|
e$3('input')
|
|
9146
9146
|
], exports.KRAutoSuggest.prototype, "_input", void 0);
|
|
9147
|
-
exports.KRAutoSuggest = __decorate$
|
|
9147
|
+
exports.KRAutoSuggest = __decorate$3([
|
|
9148
9148
|
t$1('kr-auto-suggest')
|
|
9149
9149
|
], exports.KRAutoSuggest);
|
|
9150
9150
|
|
|
9151
|
-
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
9151
|
+
var __decorate$2 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
9152
9152
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
9153
9153
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
9154
9154
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
@@ -9806,70 +9806,752 @@
|
|
|
9806
9806
|
}
|
|
9807
9807
|
`;
|
|
9808
9808
|
exports.KRComboBox.formAssociated = true;
|
|
9809
|
-
__decorate([
|
|
9809
|
+
__decorate$2([
|
|
9810
9810
|
n$1({ type: String })
|
|
9811
9811
|
], exports.KRComboBox.prototype, "label", void 0);
|
|
9812
|
-
__decorate([
|
|
9812
|
+
__decorate$2([
|
|
9813
9813
|
n$1({ type: String })
|
|
9814
9814
|
], exports.KRComboBox.prototype, "name", void 0);
|
|
9815
|
-
__decorate([
|
|
9815
|
+
__decorate$2([
|
|
9816
9816
|
n$1({ type: String })
|
|
9817
9817
|
], exports.KRComboBox.prototype, "value", void 0);
|
|
9818
|
-
__decorate([
|
|
9818
|
+
__decorate$2([
|
|
9819
9819
|
n$1({ type: String })
|
|
9820
9820
|
], exports.KRComboBox.prototype, "placeholder", void 0);
|
|
9821
|
-
__decorate([
|
|
9821
|
+
__decorate$2([
|
|
9822
9822
|
n$1({ type: Boolean })
|
|
9823
9823
|
], exports.KRComboBox.prototype, "disabled", void 0);
|
|
9824
|
-
__decorate([
|
|
9824
|
+
__decorate$2([
|
|
9825
9825
|
n$1({ type: Boolean })
|
|
9826
9826
|
], exports.KRComboBox.prototype, "readonly", void 0);
|
|
9827
|
-
__decorate([
|
|
9827
|
+
__decorate$2([
|
|
9828
9828
|
n$1({ type: Boolean })
|
|
9829
9829
|
], exports.KRComboBox.prototype, "required", void 0);
|
|
9830
|
-
__decorate([
|
|
9830
|
+
__decorate$2([
|
|
9831
9831
|
n$1({ type: String })
|
|
9832
9832
|
], exports.KRComboBox.prototype, "hint", void 0);
|
|
9833
|
-
__decorate([
|
|
9833
|
+
__decorate$2([
|
|
9834
9834
|
n$1({ attribute: 'option-value' })
|
|
9835
9835
|
], exports.KRComboBox.prototype, "optionValue", void 0);
|
|
9836
|
-
__decorate([
|
|
9836
|
+
__decorate$2([
|
|
9837
9837
|
n$1({ attribute: 'option-label' })
|
|
9838
9838
|
], exports.KRComboBox.prototype, "optionLabel", void 0);
|
|
9839
|
-
__decorate([
|
|
9839
|
+
__decorate$2([
|
|
9840
9840
|
n$1({ type: Array })
|
|
9841
9841
|
], exports.KRComboBox.prototype, "options", void 0);
|
|
9842
|
-
__decorate([
|
|
9842
|
+
__decorate$2([
|
|
9843
9843
|
n$1({ attribute: false })
|
|
9844
9844
|
], exports.KRComboBox.prototype, "fetch", void 0);
|
|
9845
|
-
__decorate([
|
|
9845
|
+
__decorate$2([
|
|
9846
9846
|
n$1({ attribute: false })
|
|
9847
9847
|
], exports.KRComboBox.prototype, "fetchSelection", void 0);
|
|
9848
|
-
__decorate([
|
|
9848
|
+
__decorate$2([
|
|
9849
9849
|
r$1()
|
|
9850
9850
|
], exports.KRComboBox.prototype, "_isOpen", void 0);
|
|
9851
|
-
__decorate([
|
|
9851
|
+
__decorate$2([
|
|
9852
9852
|
r$1()
|
|
9853
9853
|
], exports.KRComboBox.prototype, "_highlightedIndex", void 0);
|
|
9854
|
-
__decorate([
|
|
9854
|
+
__decorate$2([
|
|
9855
9855
|
r$1()
|
|
9856
9856
|
], exports.KRComboBox.prototype, "_touched", void 0);
|
|
9857
|
-
__decorate([
|
|
9857
|
+
__decorate$2([
|
|
9858
9858
|
r$1()
|
|
9859
9859
|
], exports.KRComboBox.prototype, "_searchQuery", void 0);
|
|
9860
|
-
__decorate([
|
|
9860
|
+
__decorate$2([
|
|
9861
9861
|
r$1()
|
|
9862
9862
|
], exports.KRComboBox.prototype, "_loading", void 0);
|
|
9863
|
-
__decorate([
|
|
9863
|
+
__decorate$2([
|
|
9864
9864
|
e$3('.trigger')
|
|
9865
9865
|
], exports.KRComboBox.prototype, "_triggerElement", void 0);
|
|
9866
|
-
__decorate([
|
|
9866
|
+
__decorate$2([
|
|
9867
9867
|
e$3('.search__input')
|
|
9868
9868
|
], exports.KRComboBox.prototype, "_searchInput", void 0);
|
|
9869
|
-
exports.KRComboBox = __decorate([
|
|
9869
|
+
exports.KRComboBox = __decorate$2([
|
|
9870
9870
|
t$1('kr-combo-box')
|
|
9871
9871
|
], exports.KRComboBox);
|
|
9872
9872
|
|
|
9873
|
+
var __decorate$1 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
9874
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
9875
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
9876
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
9877
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
9878
|
+
};
|
|
9879
|
+
/**
|
|
9880
|
+
* A card-style radio group for selecting between a small number of options.
|
|
9881
|
+
* Each option renders as a bordered card with a radio indicator, label, and optional description.
|
|
9882
|
+
*
|
|
9883
|
+
* Uses ElementInternals for form association, allowing the component
|
|
9884
|
+
* to participate in form submission, validation, and reset.
|
|
9885
|
+
*
|
|
9886
|
+
* @element kr-radio-cards
|
|
9887
|
+
* @fires change - Fired when the selected value changes
|
|
9888
|
+
*/
|
|
9889
|
+
exports.KRRadioCards = class KRRadioCards extends i$2 {
|
|
9890
|
+
constructor() {
|
|
9891
|
+
super();
|
|
9892
|
+
this._focusedIndex = -1;
|
|
9893
|
+
/**
|
|
9894
|
+
* The label text above the cards
|
|
9895
|
+
*/
|
|
9896
|
+
this.label = '';
|
|
9897
|
+
/**
|
|
9898
|
+
* The input name for form submission
|
|
9899
|
+
*/
|
|
9900
|
+
this.name = '';
|
|
9901
|
+
/**
|
|
9902
|
+
* The currently selected value
|
|
9903
|
+
*/
|
|
9904
|
+
this.value = '';
|
|
9905
|
+
/**
|
|
9906
|
+
* The card options to display
|
|
9907
|
+
*/
|
|
9908
|
+
this.options = [];
|
|
9909
|
+
/**
|
|
9910
|
+
* Whether the field is disabled
|
|
9911
|
+
*/
|
|
9912
|
+
this.disabled = false;
|
|
9913
|
+
/**
|
|
9914
|
+
* Whether the field is required
|
|
9915
|
+
*/
|
|
9916
|
+
this.required = false;
|
|
9917
|
+
/**
|
|
9918
|
+
* Helper text shown below the cards
|
|
9919
|
+
*/
|
|
9920
|
+
this.hint = '';
|
|
9921
|
+
/**
|
|
9922
|
+
* Layout direction: 'row' or 'column'
|
|
9923
|
+
*/
|
|
9924
|
+
this.direction = 'row';
|
|
9925
|
+
this._touched = false;
|
|
9926
|
+
this._handleInvalid = (e) => {
|
|
9927
|
+
e.preventDefault();
|
|
9928
|
+
this._touched = true;
|
|
9929
|
+
};
|
|
9930
|
+
this._internals = this.attachInternals();
|
|
9931
|
+
}
|
|
9932
|
+
// Form-associated custom element callbacks
|
|
9933
|
+
get form() {
|
|
9934
|
+
return this._internals.form;
|
|
9935
|
+
}
|
|
9936
|
+
get validity() {
|
|
9937
|
+
return this._internals.validity;
|
|
9938
|
+
}
|
|
9939
|
+
get validationMessage() {
|
|
9940
|
+
return this._internals.validationMessage;
|
|
9941
|
+
}
|
|
9942
|
+
get willValidate() {
|
|
9943
|
+
return this._internals.willValidate;
|
|
9944
|
+
}
|
|
9945
|
+
checkValidity() {
|
|
9946
|
+
return this._internals.checkValidity();
|
|
9947
|
+
}
|
|
9948
|
+
reportValidity() {
|
|
9949
|
+
return this._internals.reportValidity();
|
|
9950
|
+
}
|
|
9951
|
+
formResetCallback() {
|
|
9952
|
+
this.value = '';
|
|
9953
|
+
this._touched = false;
|
|
9954
|
+
this._internals.setFormValue('');
|
|
9955
|
+
this._internals.setValidity({});
|
|
9956
|
+
}
|
|
9957
|
+
formStateRestoreCallback(state) {
|
|
9958
|
+
this.value = state;
|
|
9959
|
+
}
|
|
9960
|
+
connectedCallback() {
|
|
9961
|
+
super.connectedCallback();
|
|
9962
|
+
this.addEventListener('invalid', this._handleInvalid);
|
|
9963
|
+
}
|
|
9964
|
+
disconnectedCallback() {
|
|
9965
|
+
super.disconnectedCallback();
|
|
9966
|
+
this.removeEventListener('invalid', this._handleInvalid);
|
|
9967
|
+
}
|
|
9968
|
+
firstUpdated() {
|
|
9969
|
+
this._updateValidity();
|
|
9970
|
+
}
|
|
9971
|
+
updated(changedProperties) {
|
|
9972
|
+
if (changedProperties.has('required') || changedProperties.has('value')) {
|
|
9973
|
+
this._updateValidity();
|
|
9974
|
+
}
|
|
9975
|
+
}
|
|
9976
|
+
_updateValidity() {
|
|
9977
|
+
if (this.required && !this.value) {
|
|
9978
|
+
this._internals.setValidity({ valueMissing: true }, 'Please select an option');
|
|
9979
|
+
}
|
|
9980
|
+
else {
|
|
9981
|
+
this._internals.setValidity({});
|
|
9982
|
+
}
|
|
9983
|
+
}
|
|
9984
|
+
_handleCardClick(e, option) {
|
|
9985
|
+
if (this.disabled || option.disabled) {
|
|
9986
|
+
return;
|
|
9987
|
+
}
|
|
9988
|
+
this.value = option.value;
|
|
9989
|
+
this._touched = true;
|
|
9990
|
+
this._internals.setFormValue(this.value);
|
|
9991
|
+
this._updateValidity();
|
|
9992
|
+
this.dispatchEvent(new Event('change', { bubbles: true, composed: true }));
|
|
9993
|
+
}
|
|
9994
|
+
_handleKeyDown(e, index) {
|
|
9995
|
+
if (this.disabled) {
|
|
9996
|
+
return;
|
|
9997
|
+
}
|
|
9998
|
+
if (e.key === ' ' || e.key === 'Enter') {
|
|
9999
|
+
e.preventDefault();
|
|
10000
|
+
if (!this.options[index].disabled) {
|
|
10001
|
+
this._handleCardClick(e, this.options[index]);
|
|
10002
|
+
}
|
|
10003
|
+
return;
|
|
10004
|
+
}
|
|
10005
|
+
let nextIndex = -1;
|
|
10006
|
+
if (this.direction === 'row') {
|
|
10007
|
+
if (e.key === 'ArrowRight') {
|
|
10008
|
+
nextIndex = this._findNextEnabledIndex(index, 1);
|
|
10009
|
+
}
|
|
10010
|
+
else if (e.key === 'ArrowLeft') {
|
|
10011
|
+
nextIndex = this._findNextEnabledIndex(index, -1);
|
|
10012
|
+
}
|
|
10013
|
+
}
|
|
10014
|
+
else {
|
|
10015
|
+
if (e.key === 'ArrowDown') {
|
|
10016
|
+
nextIndex = this._findNextEnabledIndex(index, 1);
|
|
10017
|
+
}
|
|
10018
|
+
else if (e.key === 'ArrowUp') {
|
|
10019
|
+
nextIndex = this._findNextEnabledIndex(index, -1);
|
|
10020
|
+
}
|
|
10021
|
+
}
|
|
10022
|
+
if (nextIndex >= 0) {
|
|
10023
|
+
e.preventDefault();
|
|
10024
|
+
this._focusedIndex = nextIndex;
|
|
10025
|
+
const cards = this.shadowRoot?.querySelectorAll('.card');
|
|
10026
|
+
if (cards[nextIndex]) {
|
|
10027
|
+
cards[nextIndex].focus();
|
|
10028
|
+
}
|
|
10029
|
+
}
|
|
10030
|
+
}
|
|
10031
|
+
_findNextEnabledIndex(current, step) {
|
|
10032
|
+
let next = current + step;
|
|
10033
|
+
while (next >= 0 && next < this.options.length) {
|
|
10034
|
+
if (!this.options[next].disabled) {
|
|
10035
|
+
return next;
|
|
10036
|
+
}
|
|
10037
|
+
next += step;
|
|
10038
|
+
}
|
|
10039
|
+
return -1;
|
|
10040
|
+
}
|
|
10041
|
+
render() {
|
|
10042
|
+
return b `
|
|
10043
|
+
<div class="wrapper">
|
|
10044
|
+
${this.label
|
|
10045
|
+
? b `
|
|
10046
|
+
<label>
|
|
10047
|
+
${this.label}
|
|
10048
|
+
${this.required ? b `<span class="required" aria-hidden="true">*</span>` : A}
|
|
10049
|
+
</label>
|
|
10050
|
+
`
|
|
10051
|
+
: A}
|
|
10052
|
+
<div
|
|
10053
|
+
class=${e$1({
|
|
10054
|
+
'cards': true,
|
|
10055
|
+
'cards--row': this.direction === 'row',
|
|
10056
|
+
'cards--column': this.direction === 'column',
|
|
10057
|
+
})}
|
|
10058
|
+
role="radiogroup"
|
|
10059
|
+
aria-label=${this.label}
|
|
10060
|
+
>
|
|
10061
|
+
${this.options.map((option, index) => {
|
|
10062
|
+
const isSelected = option.value === this.value;
|
|
10063
|
+
const isDisabled = this.disabled || !!option.disabled;
|
|
10064
|
+
return b `
|
|
10065
|
+
<div
|
|
10066
|
+
class=${e$1({
|
|
10067
|
+
'card': true,
|
|
10068
|
+
'card--selected': isSelected,
|
|
10069
|
+
'card--disabled': isDisabled,
|
|
10070
|
+
})}
|
|
10071
|
+
role="radio"
|
|
10072
|
+
aria-checked=${isSelected}
|
|
10073
|
+
aria-disabled=${isDisabled}
|
|
10074
|
+
tabindex=${isDisabled ? -1 : 0}
|
|
10075
|
+
@click=${(e) => this._handleCardClick(e, option)}
|
|
10076
|
+
@keydown=${(e) => this._handleKeyDown(e, index)}
|
|
10077
|
+
>
|
|
10078
|
+
<div class="card__radio">
|
|
10079
|
+
${isSelected ? b `<div class="card__radio-dot"></div>` : A}
|
|
10080
|
+
</div>
|
|
10081
|
+
<div class="card__content">
|
|
10082
|
+
<div class="card__label">${option.label}</div>
|
|
10083
|
+
${option.description
|
|
10084
|
+
? b `<div class="card__description">${option.description}</div>`
|
|
10085
|
+
: A}
|
|
10086
|
+
</div>
|
|
10087
|
+
</div>
|
|
10088
|
+
`;
|
|
10089
|
+
})}
|
|
10090
|
+
</div>
|
|
10091
|
+
${this._touched && this.required && !this.value
|
|
10092
|
+
? b `<div class="validation-message">Please select an option</div>`
|
|
10093
|
+
: this.hint
|
|
10094
|
+
? b `<div class="hint">${this.hint}</div>`
|
|
10095
|
+
: A}
|
|
10096
|
+
</div>
|
|
10097
|
+
`;
|
|
10098
|
+
}
|
|
10099
|
+
};
|
|
10100
|
+
exports.KRRadioCards.styles = [krBaseCSS, i$5 `
|
|
10101
|
+
:host {
|
|
10102
|
+
display: block;
|
|
10103
|
+
font-family: inherit;
|
|
10104
|
+
}
|
|
10105
|
+
|
|
10106
|
+
.wrapper {
|
|
10107
|
+
display: flex;
|
|
10108
|
+
flex-direction: column;
|
|
10109
|
+
gap: 6px;
|
|
10110
|
+
}
|
|
10111
|
+
|
|
10112
|
+
label {
|
|
10113
|
+
font-size: 14px;
|
|
10114
|
+
font-weight: 500;
|
|
10115
|
+
color: black;
|
|
10116
|
+
}
|
|
10117
|
+
|
|
10118
|
+
.required {
|
|
10119
|
+
color: var(--kr-radio-cards-required-color, #ef4444);
|
|
10120
|
+
margin-left: 0.125rem;
|
|
10121
|
+
}
|
|
10122
|
+
|
|
10123
|
+
.cards {
|
|
10124
|
+
display: flex;
|
|
10125
|
+
gap: 12px;
|
|
10126
|
+
}
|
|
10127
|
+
|
|
10128
|
+
.cards--row {
|
|
10129
|
+
flex-direction: row;
|
|
10130
|
+
}
|
|
10131
|
+
|
|
10132
|
+
.cards--column {
|
|
10133
|
+
flex-direction: column;
|
|
10134
|
+
}
|
|
10135
|
+
|
|
10136
|
+
.card {
|
|
10137
|
+
flex: 1;
|
|
10138
|
+
display: flex;
|
|
10139
|
+
align-items: flex-start;
|
|
10140
|
+
gap: 12px;
|
|
10141
|
+
padding: 16px;
|
|
10142
|
+
border: 1px solid var(--kr-radio-cards-border-color, #0000003d);
|
|
10143
|
+
border-radius: 8px;
|
|
10144
|
+
background-color: var(--kr-radio-cards-bg, #fff);
|
|
10145
|
+
cursor: pointer;
|
|
10146
|
+
transition: border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
|
|
10147
|
+
}
|
|
10148
|
+
|
|
10149
|
+
.card:hover:not(.card--disabled) {
|
|
10150
|
+
border-color: var(--kr-radio-cards-hover-border-color, #9ca3af);
|
|
10151
|
+
}
|
|
10152
|
+
|
|
10153
|
+
.card:focus-visible {
|
|
10154
|
+
outline: none;
|
|
10155
|
+
box-shadow: 0 0 0 3px rgba(22, 48, 82, 0.1);
|
|
10156
|
+
}
|
|
10157
|
+
|
|
10158
|
+
.card--selected {
|
|
10159
|
+
border-color: var(--kr-radio-cards-selected-border-color, var(--kr-primary));
|
|
10160
|
+
background-color: var(--kr-radio-cards-selected-bg, rgba(22, 48, 82, 0.06));
|
|
10161
|
+
}
|
|
10162
|
+
|
|
10163
|
+
.card--selected:hover {
|
|
10164
|
+
border-color: var(--kr-radio-cards-selected-border-color, var(--kr-primary));
|
|
10165
|
+
}
|
|
10166
|
+
|
|
10167
|
+
.card--disabled {
|
|
10168
|
+
opacity: 0.5;
|
|
10169
|
+
cursor: not-allowed;
|
|
10170
|
+
}
|
|
10171
|
+
|
|
10172
|
+
.card__radio {
|
|
10173
|
+
flex-shrink: 0;
|
|
10174
|
+
width: 18px;
|
|
10175
|
+
height: 18px;
|
|
10176
|
+
border: 2px solid var(--kr-radio-cards-radio-border-color, #0000003d);
|
|
10177
|
+
border-radius: 50%;
|
|
10178
|
+
margin-top: 1px;
|
|
10179
|
+
display: flex;
|
|
10180
|
+
align-items: center;
|
|
10181
|
+
justify-content: center;
|
|
10182
|
+
transition: border-color 0.2s;
|
|
10183
|
+
}
|
|
10184
|
+
|
|
10185
|
+
.card--selected .card__radio {
|
|
10186
|
+
border-color: var(--kr-radio-cards-radio-selected-color, var(--kr-primary));
|
|
10187
|
+
}
|
|
10188
|
+
|
|
10189
|
+
.card__radio-dot {
|
|
10190
|
+
width: 10px;
|
|
10191
|
+
height: 10px;
|
|
10192
|
+
border-radius: 50%;
|
|
10193
|
+
background-color: var(--kr-radio-cards-radio-selected-color, var(--kr-primary));
|
|
10194
|
+
}
|
|
10195
|
+
|
|
10196
|
+
.card__content {
|
|
10197
|
+
display: flex;
|
|
10198
|
+
flex-direction: column;
|
|
10199
|
+
gap: 4px;
|
|
10200
|
+
min-width: 0;
|
|
10201
|
+
}
|
|
10202
|
+
|
|
10203
|
+
.card__label {
|
|
10204
|
+
font-size: 14px;
|
|
10205
|
+
font-weight: 600;
|
|
10206
|
+
color: var(--kr-radio-cards-label-color, #000);
|
|
10207
|
+
}
|
|
10208
|
+
|
|
10209
|
+
.card__description {
|
|
10210
|
+
font-size: 14px;
|
|
10211
|
+
color: var(--kr-radio-cards-description-color, #4d525c);
|
|
10212
|
+
}
|
|
10213
|
+
|
|
10214
|
+
.hint {
|
|
10215
|
+
font-size: 0.75rem;
|
|
10216
|
+
color: var(--kr-radio-cards-helper-color, #6b7280);
|
|
10217
|
+
}
|
|
10218
|
+
|
|
10219
|
+
.validation-message {
|
|
10220
|
+
font-size: 0.75rem;
|
|
10221
|
+
color: var(--kr-radio-cards-error-color, #ef4444);
|
|
10222
|
+
}
|
|
10223
|
+
`];
|
|
10224
|
+
exports.KRRadioCards.formAssociated = true;
|
|
10225
|
+
__decorate$1([
|
|
10226
|
+
n$1({ type: String })
|
|
10227
|
+
], exports.KRRadioCards.prototype, "label", void 0);
|
|
10228
|
+
__decorate$1([
|
|
10229
|
+
n$1({ type: String })
|
|
10230
|
+
], exports.KRRadioCards.prototype, "name", void 0);
|
|
10231
|
+
__decorate$1([
|
|
10232
|
+
n$1({ type: String })
|
|
10233
|
+
], exports.KRRadioCards.prototype, "value", void 0);
|
|
10234
|
+
__decorate$1([
|
|
10235
|
+
n$1({ attribute: false })
|
|
10236
|
+
], exports.KRRadioCards.prototype, "options", void 0);
|
|
10237
|
+
__decorate$1([
|
|
10238
|
+
n$1({ type: Boolean })
|
|
10239
|
+
], exports.KRRadioCards.prototype, "disabled", void 0);
|
|
10240
|
+
__decorate$1([
|
|
10241
|
+
n$1({ type: Boolean })
|
|
10242
|
+
], exports.KRRadioCards.prototype, "required", void 0);
|
|
10243
|
+
__decorate$1([
|
|
10244
|
+
n$1({ type: String })
|
|
10245
|
+
], exports.KRRadioCards.prototype, "hint", void 0);
|
|
10246
|
+
__decorate$1([
|
|
10247
|
+
n$1({ type: String })
|
|
10248
|
+
], exports.KRRadioCards.prototype, "direction", void 0);
|
|
10249
|
+
__decorate$1([
|
|
10250
|
+
r$1()
|
|
10251
|
+
], exports.KRRadioCards.prototype, "_touched", void 0);
|
|
10252
|
+
exports.KRRadioCards = __decorate$1([
|
|
10253
|
+
t$1('kr-radio-cards')
|
|
10254
|
+
], exports.KRRadioCards);
|
|
10255
|
+
|
|
10256
|
+
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
10257
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
10258
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
10259
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
10260
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
10261
|
+
};
|
|
10262
|
+
/**
|
|
10263
|
+
* A checkbox component that works with native browser forms.
|
|
10264
|
+
*
|
|
10265
|
+
* Uses ElementInternals for form association, allowing the component
|
|
10266
|
+
* to participate in form submission, validation, and reset.
|
|
10267
|
+
*
|
|
10268
|
+
* @element kr-checkbox
|
|
10269
|
+
* @fires change - Fired when the checked state changes
|
|
10270
|
+
*/
|
|
10271
|
+
exports.KRCheckbox = class KRCheckbox extends i$2 {
|
|
10272
|
+
constructor() {
|
|
10273
|
+
super();
|
|
10274
|
+
/**
|
|
10275
|
+
* The checkbox label text
|
|
10276
|
+
*/
|
|
10277
|
+
this.label = '';
|
|
10278
|
+
/**
|
|
10279
|
+
* The input name for form submission
|
|
10280
|
+
*/
|
|
10281
|
+
this.name = '';
|
|
10282
|
+
/**
|
|
10283
|
+
* The value submitted when checked
|
|
10284
|
+
*/
|
|
10285
|
+
this.value = 'on';
|
|
10286
|
+
/**
|
|
10287
|
+
* Whether the checkbox is checked
|
|
10288
|
+
*/
|
|
10289
|
+
this.checked = false;
|
|
10290
|
+
/**
|
|
10291
|
+
* Whether the checkbox is disabled
|
|
10292
|
+
*/
|
|
10293
|
+
this.disabled = false;
|
|
10294
|
+
/**
|
|
10295
|
+
* Whether the checkbox is required
|
|
10296
|
+
*/
|
|
10297
|
+
this.required = false;
|
|
10298
|
+
/**
|
|
10299
|
+
* Helper text shown below the checkbox
|
|
10300
|
+
*/
|
|
10301
|
+
this.hint = '';
|
|
10302
|
+
this._touched = false;
|
|
10303
|
+
this._handleInvalid = (e) => {
|
|
10304
|
+
e.preventDefault();
|
|
10305
|
+
this._touched = true;
|
|
10306
|
+
};
|
|
10307
|
+
this._internals = this.attachInternals();
|
|
10308
|
+
}
|
|
10309
|
+
// Form-associated custom element callbacks
|
|
10310
|
+
get form() {
|
|
10311
|
+
return this._internals.form;
|
|
10312
|
+
}
|
|
10313
|
+
get validity() {
|
|
10314
|
+
return this._internals.validity;
|
|
10315
|
+
}
|
|
10316
|
+
get validationMessage() {
|
|
10317
|
+
return this._internals.validationMessage;
|
|
10318
|
+
}
|
|
10319
|
+
get willValidate() {
|
|
10320
|
+
return this._internals.willValidate;
|
|
10321
|
+
}
|
|
10322
|
+
checkValidity() {
|
|
10323
|
+
return this._internals.checkValidity();
|
|
10324
|
+
}
|
|
10325
|
+
reportValidity() {
|
|
10326
|
+
return this._internals.reportValidity();
|
|
10327
|
+
}
|
|
10328
|
+
formResetCallback() {
|
|
10329
|
+
this.checked = false;
|
|
10330
|
+
this._touched = false;
|
|
10331
|
+
this._internals.setFormValue('');
|
|
10332
|
+
this._internals.setValidity({});
|
|
10333
|
+
}
|
|
10334
|
+
formStateRestoreCallback(state) {
|
|
10335
|
+
this.checked = state === this.value;
|
|
10336
|
+
}
|
|
10337
|
+
connectedCallback() {
|
|
10338
|
+
super.connectedCallback();
|
|
10339
|
+
this.addEventListener('invalid', this._handleInvalid);
|
|
10340
|
+
}
|
|
10341
|
+
disconnectedCallback() {
|
|
10342
|
+
super.disconnectedCallback();
|
|
10343
|
+
this.removeEventListener('invalid', this._handleInvalid);
|
|
10344
|
+
}
|
|
10345
|
+
firstUpdated() {
|
|
10346
|
+
this._syncFormValue();
|
|
10347
|
+
this._updateValidity();
|
|
10348
|
+
}
|
|
10349
|
+
updated(changedProperties) {
|
|
10350
|
+
if (changedProperties.has('checked') || changedProperties.has('value')) {
|
|
10351
|
+
this._syncFormValue();
|
|
10352
|
+
}
|
|
10353
|
+
if (changedProperties.has('required') || changedProperties.has('checked')) {
|
|
10354
|
+
this._updateValidity();
|
|
10355
|
+
}
|
|
10356
|
+
}
|
|
10357
|
+
_syncFormValue() {
|
|
10358
|
+
if (this.checked) {
|
|
10359
|
+
this._internals.setFormValue(this.value);
|
|
10360
|
+
}
|
|
10361
|
+
else {
|
|
10362
|
+
this._internals.setFormValue('');
|
|
10363
|
+
}
|
|
10364
|
+
}
|
|
10365
|
+
_updateValidity() {
|
|
10366
|
+
if (this.required && !this.checked) {
|
|
10367
|
+
this._internals.setValidity({ valueMissing: true }, 'This field is required');
|
|
10368
|
+
}
|
|
10369
|
+
else {
|
|
10370
|
+
this._internals.setValidity({});
|
|
10371
|
+
}
|
|
10372
|
+
}
|
|
10373
|
+
_handleClick(e) {
|
|
10374
|
+
if (this.disabled) {
|
|
10375
|
+
return;
|
|
10376
|
+
}
|
|
10377
|
+
this.checked = !this.checked;
|
|
10378
|
+
this._touched = true;
|
|
10379
|
+
this.dispatchEvent(new Event('change', { bubbles: true, composed: true }));
|
|
10380
|
+
}
|
|
10381
|
+
_handleKeyDown(e) {
|
|
10382
|
+
if (this.disabled) {
|
|
10383
|
+
return;
|
|
10384
|
+
}
|
|
10385
|
+
if (e.key === ' ' || e.key === 'Enter') {
|
|
10386
|
+
e.preventDefault();
|
|
10387
|
+
this._handleClick(e);
|
|
10388
|
+
}
|
|
10389
|
+
}
|
|
10390
|
+
render() {
|
|
10391
|
+
return b `
|
|
10392
|
+
<div class="wrapper">
|
|
10393
|
+
<div
|
|
10394
|
+
class=${e$1({
|
|
10395
|
+
'checkbox': true,
|
|
10396
|
+
'checkbox--disabled': this.disabled,
|
|
10397
|
+
})}
|
|
10398
|
+
role="checkbox"
|
|
10399
|
+
aria-checked=${this.checked}
|
|
10400
|
+
aria-disabled=${this.disabled}
|
|
10401
|
+
aria-label=${this.label}
|
|
10402
|
+
tabindex=${this.disabled ? -1 : 0}
|
|
10403
|
+
@click=${this._handleClick}
|
|
10404
|
+
@keydown=${this._handleKeyDown}
|
|
10405
|
+
>
|
|
10406
|
+
<div class=${e$1({
|
|
10407
|
+
'checkbox__box': true,
|
|
10408
|
+
'checkbox__box--checked': this.checked,
|
|
10409
|
+
'checkbox__box--invalid': this._touched && this.required && !this.checked,
|
|
10410
|
+
})}>
|
|
10411
|
+
<svg class=${e$1({
|
|
10412
|
+
'checkbox__check': true,
|
|
10413
|
+
'checkbox__check--hidden': !this.checked,
|
|
10414
|
+
})} viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="3" stroke-linecap="round" stroke-linejoin="round">
|
|
10415
|
+
<polyline points="20 6 9 17 4 12"></polyline>
|
|
10416
|
+
</svg>
|
|
10417
|
+
</div>
|
|
10418
|
+
${this.label
|
|
10419
|
+
? b `
|
|
10420
|
+
<span class="checkbox__label">
|
|
10421
|
+
${this.label}
|
|
10422
|
+
${this.required ? b `<span class="required" aria-hidden="true">*</span>` : A}
|
|
10423
|
+
</span>
|
|
10424
|
+
`
|
|
10425
|
+
: A}
|
|
10426
|
+
</div>
|
|
10427
|
+
${this._touched && this.required && !this.checked
|
|
10428
|
+
? b `<div class="validation-message">This field is required</div>`
|
|
10429
|
+
: this.hint
|
|
10430
|
+
? b `<div class="hint">${this.hint}</div>`
|
|
10431
|
+
: A}
|
|
10432
|
+
</div>
|
|
10433
|
+
`;
|
|
10434
|
+
}
|
|
10435
|
+
focus() {
|
|
10436
|
+
this.shadowRoot?.querySelector('.checkbox')?.focus();
|
|
10437
|
+
}
|
|
10438
|
+
blur() {
|
|
10439
|
+
this.shadowRoot?.querySelector('.checkbox')?.blur();
|
|
10440
|
+
}
|
|
10441
|
+
};
|
|
10442
|
+
exports.KRCheckbox.styles = [krBaseCSS, i$5 `
|
|
10443
|
+
:host {
|
|
10444
|
+
display: inline-block;
|
|
10445
|
+
font-family: inherit;
|
|
10446
|
+
}
|
|
10447
|
+
|
|
10448
|
+
.wrapper {
|
|
10449
|
+
display: flex;
|
|
10450
|
+
flex-direction: column;
|
|
10451
|
+
gap: 6px;
|
|
10452
|
+
}
|
|
10453
|
+
|
|
10454
|
+
.checkbox {
|
|
10455
|
+
display: inline-flex;
|
|
10456
|
+
align-items: center;
|
|
10457
|
+
gap: 8px;
|
|
10458
|
+
cursor: pointer;
|
|
10459
|
+
}
|
|
10460
|
+
|
|
10461
|
+
.checkbox--disabled {
|
|
10462
|
+
opacity: 0.5;
|
|
10463
|
+
cursor: not-allowed;
|
|
10464
|
+
}
|
|
10465
|
+
|
|
10466
|
+
.checkbox__box {
|
|
10467
|
+
flex-shrink: 0;
|
|
10468
|
+
width: 18px;
|
|
10469
|
+
height: 18px;
|
|
10470
|
+
border: 2px solid var(--kr-checkbox-border-color, #0000003d);
|
|
10471
|
+
border-radius: 4px;
|
|
10472
|
+
background-color: var(--kr-checkbox-bg, #fff);
|
|
10473
|
+
display: flex;
|
|
10474
|
+
align-items: center;
|
|
10475
|
+
justify-content: center;
|
|
10476
|
+
transition: border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
|
|
10477
|
+
}
|
|
10478
|
+
|
|
10479
|
+
.checkbox:focus-visible .checkbox__box {
|
|
10480
|
+
outline: none;
|
|
10481
|
+
box-shadow: 0 0 0 3px rgba(22, 48, 82, 0.1);
|
|
10482
|
+
}
|
|
10483
|
+
|
|
10484
|
+
.checkbox__box--checked {
|
|
10485
|
+
border-color: var(--kr-checkbox-checked-border-color, var(--kr-primary));
|
|
10486
|
+
background-color: var(--kr-checkbox-checked-bg, var(--kr-primary));
|
|
10487
|
+
}
|
|
10488
|
+
|
|
10489
|
+
.checkbox__box--invalid {
|
|
10490
|
+
border-color: var(--kr-checkbox-error-border-color, #ef4444);
|
|
10491
|
+
}
|
|
10492
|
+
|
|
10493
|
+
.checkbox__check {
|
|
10494
|
+
width: 12px;
|
|
10495
|
+
height: 12px;
|
|
10496
|
+
color: var(--kr-checkbox-check-color, #fff);
|
|
10497
|
+
}
|
|
10498
|
+
|
|
10499
|
+
.checkbox__check--hidden {
|
|
10500
|
+
visibility: hidden;
|
|
10501
|
+
}
|
|
10502
|
+
|
|
10503
|
+
.checkbox__label {
|
|
10504
|
+
font-size: 14px;
|
|
10505
|
+
color: var(--kr-checkbox-label-color, #000);
|
|
10506
|
+
user-select: none;
|
|
10507
|
+
}
|
|
10508
|
+
|
|
10509
|
+
.required {
|
|
10510
|
+
color: var(--kr-checkbox-required-color, #ef4444);
|
|
10511
|
+
margin-left: 0.125rem;
|
|
10512
|
+
}
|
|
10513
|
+
|
|
10514
|
+
.hint {
|
|
10515
|
+
font-size: 0.75rem;
|
|
10516
|
+
color: var(--kr-checkbox-helper-color, #6b7280);
|
|
10517
|
+
margin-left: 26px;
|
|
10518
|
+
}
|
|
10519
|
+
|
|
10520
|
+
.validation-message {
|
|
10521
|
+
font-size: 0.75rem;
|
|
10522
|
+
color: var(--kr-checkbox-error-color, #ef4444);
|
|
10523
|
+
margin-left: 26px;
|
|
10524
|
+
}
|
|
10525
|
+
`];
|
|
10526
|
+
exports.KRCheckbox.formAssociated = true;
|
|
10527
|
+
__decorate([
|
|
10528
|
+
n$1({ type: String })
|
|
10529
|
+
], exports.KRCheckbox.prototype, "label", void 0);
|
|
10530
|
+
__decorate([
|
|
10531
|
+
n$1({ type: String })
|
|
10532
|
+
], exports.KRCheckbox.prototype, "name", void 0);
|
|
10533
|
+
__decorate([
|
|
10534
|
+
n$1({ type: String })
|
|
10535
|
+
], exports.KRCheckbox.prototype, "value", void 0);
|
|
10536
|
+
__decorate([
|
|
10537
|
+
n$1({ type: Boolean })
|
|
10538
|
+
], exports.KRCheckbox.prototype, "checked", void 0);
|
|
10539
|
+
__decorate([
|
|
10540
|
+
n$1({ type: Boolean })
|
|
10541
|
+
], exports.KRCheckbox.prototype, "disabled", void 0);
|
|
10542
|
+
__decorate([
|
|
10543
|
+
n$1({ type: Boolean })
|
|
10544
|
+
], exports.KRCheckbox.prototype, "required", void 0);
|
|
10545
|
+
__decorate([
|
|
10546
|
+
n$1({ type: String })
|
|
10547
|
+
], exports.KRCheckbox.prototype, "hint", void 0);
|
|
10548
|
+
__decorate([
|
|
10549
|
+
r$1()
|
|
10550
|
+
], exports.KRCheckbox.prototype, "_touched", void 0);
|
|
10551
|
+
exports.KRCheckbox = __decorate([
|
|
10552
|
+
t$1('kr-checkbox')
|
|
10553
|
+
], exports.KRCheckbox);
|
|
10554
|
+
|
|
9873
10555
|
exports.KRDialogRef = KRDialogRef;
|
|
9874
10556
|
exports.KRQuery = KRQuery;
|
|
9875
10557
|
exports.KR_OPERATORS = KR_OPERATORS;
|