@db-ux/wc-core-components 4.4.2 → 4.5.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/CHANGELOG.md +20 -0
- package/dist/cjs/db-accordion-item.cjs.entry.js +11 -6
- package/dist/cjs/db-accordion.cjs.entry.js +12 -8
- package/dist/cjs/db-badge.cjs.entry.js +11 -7
- package/dist/cjs/db-brand.cjs.entry.js +11 -7
- package/dist/cjs/db-button.cjs.entry.js +11 -7
- package/dist/cjs/db-card.cjs.entry.js +11 -6
- package/dist/cjs/db-checkbox.cjs.entry.js +59 -36
- package/dist/cjs/db-custom-button.cjs.entry.js +57 -0
- package/dist/cjs/db-custom-select-dropdown_5.cjs.entry.js +89 -47
- package/dist/cjs/db-custom-select-form-field.cjs.entry.js +11 -6
- package/dist/cjs/db-custom-select.cjs.entry.js +133 -110
- package/dist/cjs/db-divider.cjs.entry.js +11 -6
- package/dist/cjs/db-drawer.cjs.entry.js +12 -8
- package/dist/cjs/db-header.cjs.entry.js +13 -9
- package/dist/cjs/db-icon.cjs.entry.js +11 -6
- package/dist/cjs/db-infotext.cjs.entry.js +11 -7
- package/dist/cjs/db-link.cjs.entry.js +11 -7
- package/dist/cjs/db-navigation-item.cjs.entry.js +13 -9
- package/dist/cjs/db-navigation.cjs.entry.js +11 -6
- package/dist/cjs/db-notification.cjs.entry.js +12 -8
- package/dist/cjs/db-page.cjs.entry.js +11 -6
- package/dist/cjs/db-popover.cjs.entry.js +14 -10
- package/dist/cjs/db-radio.cjs.entry.js +39 -16
- package/dist/cjs/db-section.cjs.entry.js +11 -6
- package/dist/cjs/db-select.cjs.entry.js +54 -31
- package/dist/cjs/db-stack.cjs.entry.js +11 -6
- package/dist/cjs/db-switch.cjs.entry.js +64 -24
- package/dist/cjs/db-tab-item_3.cjs.entry.js +29 -15
- package/dist/cjs/db-tabs.cjs.entry.js +12 -8
- package/dist/cjs/db-textarea.cjs.entry.js +52 -29
- package/dist/cjs/db-tooltip.cjs.entry.js +25 -12
- package/dist/cjs/db-ux.cjs.js +3 -3
- package/dist/cjs/{document-click-listener-Bb3Tinb8.js → document-click-listener-B2-xKJv3.js} +1 -1
- package/dist/cjs/{document-scroll-listener-unypEU42.js → document-scroll-listener-ChQ7XZRk.js} +1 -1
- package/dist/cjs/{floating-components-ogUqz72V.js → floating-components-pYaTeNhp.js} +65 -15
- package/dist/cjs/{form-components-LsqVohyb.js → form-components-_ncB_U2D.js} +1 -1
- package/dist/cjs/{index-CsHqnQII.js → index-2_9ESkQu.js} +6 -7
- package/dist/cjs/{index-CEqZnn9s.js → index-CSMPhlzz.js} +2 -2
- package/dist/cjs/index.cjs.js +5 -5
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{navigation-DauGE-qj.js → navigation-BztJmEHf.js} +1 -1
- package/dist/collection/collection-manifest.json +2 -1
- package/dist/collection/components/accordion/accordion.js +34 -6
- package/dist/collection/components/accordion-item/accordion-item.js +33 -4
- package/dist/collection/components/badge/badge.js +60 -6
- package/dist/collection/components/brand/brand.js +33 -5
- package/dist/collection/components/button/button.js +59 -5
- package/dist/collection/components/card/card.js +33 -4
- package/dist/collection/components/checkbox/checkbox.js +87 -40
- package/dist/collection/components/custom-button/custom-button.js +394 -0
- package/dist/collection/components/custom-button/index.js +2 -0
- package/dist/collection/components/custom-button/model.js +1 -0
- package/dist/collection/components/custom-select/custom-select.js +157 -110
- package/dist/collection/components/custom-select-dropdown/custom-select-dropdown.js +33 -4
- package/dist/collection/components/custom-select-form-field/custom-select-form-field.js +33 -4
- package/dist/collection/components/custom-select-list/custom-select-list.js +33 -4
- package/dist/collection/components/custom-select-list-item/custom-select-list-item.js +33 -4
- package/dist/collection/components/divider/divider.js +33 -4
- package/dist/collection/components/drawer/drawer.js +34 -6
- package/dist/collection/components/header/header.js +33 -5
- package/dist/collection/components/icon/icon.js +33 -4
- package/dist/collection/components/infotext/infotext.js +59 -5
- package/dist/collection/components/input/input.js +80 -33
- package/dist/collection/components/link/link.js +33 -5
- package/dist/collection/components/navigation/navigation.js +33 -4
- package/dist/collection/components/navigation-item/navigation-item.js +33 -5
- package/dist/collection/components/notification/notification.js +34 -6
- package/dist/collection/components/page/page.js +33 -4
- package/dist/collection/components/popover/popover.js +34 -6
- package/dist/collection/components/radio/radio.js +60 -13
- package/dist/collection/components/section/section.js +33 -4
- package/dist/collection/components/select/select.js +81 -34
- package/dist/collection/components/stack/stack.js +33 -4
- package/dist/collection/components/switch/switch.js +118 -50
- package/dist/collection/components/tab-item/tab-item.js +33 -5
- package/dist/collection/components/tab-list/tab-list.js +33 -4
- package/dist/collection/components/tab-panel/tab-panel.js +33 -4
- package/dist/collection/components/tabs/tabs.js +34 -6
- package/dist/collection/components/tag/tag.js +33 -5
- package/dist/collection/components/textarea/textarea.js +79 -32
- package/dist/collection/components/tooltip/tooltip.js +71 -8
- package/dist/collection/index.js +2 -0
- package/dist/collection/utils/floating-components.js +65 -15
- package/dist/collection/utils/index.js +6 -7
- package/dist/custom-elements.json +19735 -1796
- package/dist/db-ux/db-ux.esm.js +1 -1
- package/dist/db-ux/index.esm.js +1 -1
- package/dist/db-ux/p-00df7d53.entry.js +1 -0
- package/dist/db-ux/p-064ddad6.entry.js +1 -0
- package/dist/db-ux/p-0ff173fb.entry.js +1 -0
- package/dist/db-ux/p-1519dbbb.entry.js +1 -0
- package/dist/db-ux/p-16281dcb.entry.js +1 -0
- package/dist/db-ux/p-27eb6e88.entry.js +1 -0
- package/dist/db-ux/p-2898ebe6.entry.js +1 -0
- package/dist/db-ux/p-2e940d2e.entry.js +1 -0
- package/dist/db-ux/p-309259be.entry.js +1 -0
- package/dist/db-ux/p-4183b8e1.entry.js +1 -0
- package/dist/db-ux/p-4284c37f.entry.js +1 -0
- package/dist/db-ux/p-432ceb90.entry.js +1 -0
- package/dist/db-ux/p-503d5103.entry.js +1 -0
- package/dist/db-ux/p-6794144b.entry.js +1 -0
- package/dist/db-ux/p-6cb4232d.entry.js +1 -0
- package/dist/db-ux/p-6da70f61.entry.js +1 -0
- package/dist/db-ux/p-766057ea.entry.js +1 -0
- package/dist/db-ux/p-7a146dee.entry.js +1 -0
- package/dist/db-ux/p-7e274359.entry.js +1 -0
- package/dist/db-ux/p-Bs7RfNRP.js +2 -0
- package/dist/db-ux/p-CHLgQ9vn.js +1 -0
- package/dist/db-ux/{p-CAEpg8tJ.js → p-D5mInaY7.js} +1 -1
- package/dist/db-ux/p-D_roHmuC.js +1 -0
- package/dist/db-ux/p-DfYL98sI.js +1 -0
- package/dist/db-ux/p-aad9c604.entry.js +1 -0
- package/dist/db-ux/p-ad3d2cff.entry.js +1 -0
- package/dist/db-ux/p-b218b08b.entry.js +1 -0
- package/dist/db-ux/p-bfe27311.entry.js +1 -0
- package/dist/db-ux/p-c1cf7ea4.entry.js +1 -0
- package/dist/db-ux/{p-sP2NlPcu.js → p-cNk4ImpW.js} +1 -1
- package/dist/db-ux/p-cd8557dd.entry.js +1 -0
- package/dist/db-ux/p-d2674cff.entry.js +1 -0
- package/dist/db-ux/p-d4e79c33.entry.js +1 -0
- package/dist/db-ux/p-e19f2640.entry.js +1 -0
- package/dist/db-ux/p-e3def528.entry.js +1 -0
- package/dist/db-ux/p-e6b17374.entry.js +1 -0
- package/dist/db-ux/p-ea7219af.entry.js +1 -0
- package/dist/db-ux/p-xkoBSP8R.js +1 -0
- package/dist/esm/db-accordion-item.entry.js +11 -6
- package/dist/esm/db-accordion.entry.js +12 -8
- package/dist/esm/db-badge.entry.js +11 -7
- package/dist/esm/db-brand.entry.js +11 -7
- package/dist/esm/db-button.entry.js +11 -7
- package/dist/esm/db-card.entry.js +11 -6
- package/dist/esm/db-checkbox.entry.js +60 -37
- package/dist/esm/db-custom-button.entry.js +55 -0
- package/dist/esm/db-custom-select-dropdown_5.entry.js +90 -48
- package/dist/esm/db-custom-select-form-field.entry.js +11 -6
- package/dist/esm/db-custom-select.entry.js +134 -111
- package/dist/esm/db-divider.entry.js +11 -6
- package/dist/esm/db-drawer.entry.js +12 -8
- package/dist/esm/db-header.entry.js +13 -9
- package/dist/esm/db-icon.entry.js +11 -6
- package/dist/esm/db-infotext.entry.js +11 -7
- package/dist/esm/db-link.entry.js +11 -7
- package/dist/esm/db-navigation-item.entry.js +13 -9
- package/dist/esm/db-navigation.entry.js +11 -6
- package/dist/esm/db-notification.entry.js +12 -8
- package/dist/esm/db-page.entry.js +11 -6
- package/dist/esm/db-popover.entry.js +14 -10
- package/dist/esm/db-radio.entry.js +39 -16
- package/dist/esm/db-section.entry.js +11 -6
- package/dist/esm/db-select.entry.js +55 -32
- package/dist/esm/db-stack.entry.js +11 -6
- package/dist/esm/db-switch.entry.js +64 -24
- package/dist/esm/db-tab-item_3.entry.js +29 -15
- package/dist/esm/db-tabs.entry.js +12 -8
- package/dist/esm/db-textarea.entry.js +53 -30
- package/dist/esm/db-tooltip.entry.js +25 -12
- package/dist/esm/db-ux.js +4 -4
- package/dist/esm/{document-click-listener-CmYoXpGE.js → document-click-listener-D7W_VE5O.js} +1 -1
- package/dist/esm/{document-scroll-listener-65bHuFAN.js → document-scroll-listener-DOBe3Oa9.js} +1 -1
- package/dist/esm/{floating-components-G-TursYV.js → floating-components-DfYL98sI.js} +65 -15
- package/dist/esm/{form-components-BLsiOrPI.js → form-components-D6LQfJvq.js} +1 -1
- package/dist/esm/{index-BrThqi62.js → index-Bs7RfNRP.js} +2 -2
- package/dist/esm/{index-C4x0SOcx.js → index-xkoBSP8R.js} +6 -7
- package/dist/esm/index.js +5 -5
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{navigation--UdC9CzO.js → navigation-DgsMCdfn.js} +1 -1
- package/dist/types/components/accordion/accordion.d.ts +1 -0
- package/dist/types/components/accordion-item/accordion-item.d.ts +1 -0
- package/dist/types/components/badge/badge.d.ts +2 -0
- package/dist/types/components/badge/model.d.ts +2 -2
- package/dist/types/components/brand/brand.d.ts +1 -0
- package/dist/types/components/button/button.d.ts +2 -0
- package/dist/types/components/button/model.d.ts +8 -10
- package/dist/types/components/card/card.d.ts +1 -0
- package/dist/types/components/checkbox/checkbox.d.ts +5 -1
- package/dist/types/components/custom-button/custom-button.d.ts +29 -0
- package/dist/types/components/custom-button/index.d.ts +2 -0
- package/dist/types/components/custom-button/model.d.ts +6 -0
- package/dist/types/components/custom-select/custom-select.d.ts +5 -1
- package/dist/types/components/custom-select-dropdown/custom-select-dropdown.d.ts +1 -0
- package/dist/types/components/custom-select-form-field/custom-select-form-field.d.ts +1 -0
- package/dist/types/components/custom-select-list/custom-select-list.d.ts +1 -0
- package/dist/types/components/custom-select-list-item/custom-select-list-item.d.ts +1 -0
- package/dist/types/components/divider/divider.d.ts +1 -0
- package/dist/types/components/drawer/drawer.d.ts +1 -0
- package/dist/types/components/header/header.d.ts +1 -0
- package/dist/types/components/icon/icon.d.ts +1 -0
- package/dist/types/components/infotext/infotext.d.ts +2 -0
- package/dist/types/components/infotext/model.d.ts +2 -2
- package/dist/types/components/input/input.d.ts +5 -1
- package/dist/types/components/link/link.d.ts +1 -0
- package/dist/types/components/navigation/navigation.d.ts +1 -0
- package/dist/types/components/navigation-item/navigation-item.d.ts +1 -0
- package/dist/types/components/notification/model.d.ts +2 -2
- package/dist/types/components/notification/notification.d.ts +1 -0
- package/dist/types/components/page/page.d.ts +1 -0
- package/dist/types/components/popover/popover.d.ts +1 -0
- package/dist/types/components/radio/radio.d.ts +4 -0
- package/dist/types/components/section/section.d.ts +1 -0
- package/dist/types/components/select/select.d.ts +5 -1
- package/dist/types/components/stack/stack.d.ts +1 -0
- package/dist/types/components/switch/model.d.ts +1 -1
- package/dist/types/components/switch/switch.d.ts +7 -1
- package/dist/types/components/tab-item/tab-item.d.ts +1 -0
- package/dist/types/components/tab-list/tab-list.d.ts +1 -0
- package/dist/types/components/tab-panel/tab-panel.d.ts +1 -0
- package/dist/types/components/tabs/tabs.d.ts +1 -0
- package/dist/types/components/tag/model.d.ts +2 -6
- package/dist/types/components/tag/tag.d.ts +1 -0
- package/dist/types/components/textarea/textarea.d.ts +5 -1
- package/dist/types/components/tooltip/model.d.ts +3 -3
- package/dist/types/components/tooltip/tooltip.d.ts +3 -0
- package/dist/types/components.d.ts +146 -6
- package/dist/types/index.d.ts +2 -0
- package/dist/types/shared/model.d.ts +17 -3
- package/dist/types/stencil-public-runtime.d.ts +3 -1
- package/dist/vscode.html-custom-data.json +1981 -245
- package/dist/web-types.json +3299 -648
- package/package.json +4 -4
- package/dist/db-ux/p-07bf3657.entry.js +0 -1
- package/dist/db-ux/p-0a89cbcd.entry.js +0 -1
- package/dist/db-ux/p-15539d9d.entry.js +0 -1
- package/dist/db-ux/p-41cb4673.entry.js +0 -1
- package/dist/db-ux/p-460073dd.entry.js +0 -1
- package/dist/db-ux/p-4a9b9909.entry.js +0 -1
- package/dist/db-ux/p-4ec09cf1.entry.js +0 -1
- package/dist/db-ux/p-57205dfd.entry.js +0 -1
- package/dist/db-ux/p-5775bf7a.entry.js +0 -1
- package/dist/db-ux/p-5bcde39a.entry.js +0 -1
- package/dist/db-ux/p-6341aaa9.entry.js +0 -1
- package/dist/db-ux/p-64573104.entry.js +0 -1
- package/dist/db-ux/p-6b63156d.entry.js +0 -1
- package/dist/db-ux/p-70822a27.entry.js +0 -1
- package/dist/db-ux/p-710a430d.entry.js +0 -1
- package/dist/db-ux/p-72d712b0.entry.js +0 -1
- package/dist/db-ux/p-7b7f4d03.entry.js +0 -1
- package/dist/db-ux/p-7bd4c573.entry.js +0 -1
- package/dist/db-ux/p-819cf20a.entry.js +0 -1
- package/dist/db-ux/p-87fdbcfb.entry.js +0 -1
- package/dist/db-ux/p-9051e26c.entry.js +0 -1
- package/dist/db-ux/p-934a708c.entry.js +0 -1
- package/dist/db-ux/p-9ffa5c48.entry.js +0 -1
- package/dist/db-ux/p-BhXdfCpU.js +0 -1
- package/dist/db-ux/p-BrThqi62.js +0 -2
- package/dist/db-ux/p-C4x0SOcx.js +0 -1
- package/dist/db-ux/p-G-TursYV.js +0 -1
- package/dist/db-ux/p-RHqkTr-_.js +0 -1
- package/dist/db-ux/p-a9af70eb.entry.js +0 -1
- package/dist/db-ux/p-aa8383a3.entry.js +0 -1
- package/dist/db-ux/p-ba1f69bd.entry.js +0 -1
- package/dist/db-ux/p-d273b998.entry.js +0 -1
- package/dist/db-ux/p-da4ee6ee.entry.js +0 -1
- package/dist/db-ux/p-e584e927.entry.js +0 -1
- package/dist/db-ux/p-fe185f98.entry.js +0 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
4
|
var constants = require('./constants-bMY2_d8A.js');
|
|
5
|
-
var index$1 = require('./index-
|
|
6
|
-
var formComponents = require('./form-components-
|
|
5
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
6
|
+
var formComponents = require('./form-components-_ncB_U2D.js');
|
|
7
7
|
|
|
8
8
|
const DBSelect = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -104,6 +104,15 @@ const DBSelect = class {
|
|
|
104
104
|
// Default: show empty option for non-required selects
|
|
105
105
|
return !this.required;
|
|
106
106
|
}
|
|
107
|
+
resetIds() {
|
|
108
|
+
var _a, _b, _c;
|
|
109
|
+
const mId = (_c = (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) !== null && _c !== void 0 ? _c : `select-${index$1.uuid()}`;
|
|
110
|
+
this._id = mId;
|
|
111
|
+
this._messageId = mId + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
112
|
+
this._validMessageId = mId + constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX;
|
|
113
|
+
this._invalidMessageId = mId + constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
|
|
114
|
+
this._placeholderId = mId + constants.DEFAULT_PLACEHOLDER_ID_SUFFIX;
|
|
115
|
+
}
|
|
107
116
|
/**
|
|
108
117
|
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
109
118
|
* @param element the ref for the component
|
|
@@ -115,12 +124,16 @@ const DBSelect = class {
|
|
|
115
124
|
const attributes = parent.attributes;
|
|
116
125
|
for (let i = 0; i < attributes.length; i++) {
|
|
117
126
|
const attr = attributes.item(i);
|
|
118
|
-
if (attr &&
|
|
127
|
+
if (attr && attr.name !== 'data-density' &&
|
|
119
128
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
120
129
|
element.setAttribute(attr.name, attr.value);
|
|
121
130
|
parent.removeAttribute(attr.name);
|
|
122
131
|
}
|
|
123
|
-
if (attr && attr.name
|
|
132
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
133
|
+
element.setAttribute(attr.name, attr.value);
|
|
134
|
+
parent.removeAttribute(attr.name);
|
|
135
|
+
}
|
|
136
|
+
else if (attr && attr.name === "class") {
|
|
124
137
|
const isWebComponent = attr.value.includes("hydrated");
|
|
125
138
|
const value = attr.value.replace("hydrated", "").trim();
|
|
126
139
|
const currentClass = element.getAttribute("class");
|
|
@@ -137,16 +150,25 @@ const DBSelect = class {
|
|
|
137
150
|
}
|
|
138
151
|
}
|
|
139
152
|
watch0Fn() {
|
|
153
|
+
var _a, _b;
|
|
154
|
+
if ((_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) {
|
|
155
|
+
this.resetIds();
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
watch0() {
|
|
159
|
+
this.watch0Fn();
|
|
160
|
+
}
|
|
161
|
+
watch1Fn() {
|
|
140
162
|
var _a;
|
|
141
163
|
this._invalidMessage =
|
|
142
164
|
this.invalidMessage ||
|
|
143
165
|
((_a = this._ref) === null || _a === void 0 ? void 0 : _a.validationMessage) ||
|
|
144
166
|
constants.DEFAULT_INVALID_MESSAGE;
|
|
145
167
|
}
|
|
146
|
-
|
|
147
|
-
this.
|
|
168
|
+
watch1() {
|
|
169
|
+
this.watch1Fn();
|
|
148
170
|
}
|
|
149
|
-
|
|
171
|
+
watch2Fn() {
|
|
150
172
|
if (this._id && this.initialized) {
|
|
151
173
|
const messageId = this._id + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
152
174
|
const placeholderId = this._id + constants.DEFAULT_PLACEHOLDER_ID_SUFFIX;
|
|
@@ -167,16 +189,16 @@ const DBSelect = class {
|
|
|
167
189
|
this.initialized = false;
|
|
168
190
|
}
|
|
169
191
|
}
|
|
170
|
-
watch1() {
|
|
171
|
-
this.watch1Fn();
|
|
172
|
-
}
|
|
173
|
-
watch2Fn() {
|
|
174
|
-
this._value = this.value;
|
|
175
|
-
}
|
|
176
192
|
watch2() {
|
|
177
193
|
this.watch2Fn();
|
|
178
194
|
}
|
|
179
195
|
watch3Fn() {
|
|
196
|
+
this._value = this.value;
|
|
197
|
+
}
|
|
198
|
+
watch3() {
|
|
199
|
+
this.watch3Fn();
|
|
200
|
+
}
|
|
201
|
+
watch4Fn() {
|
|
180
202
|
// If angular uses ngModel value and _value are null
|
|
181
203
|
// then the value will be set afterward and the _ref will be refreshed
|
|
182
204
|
const addResetListener = true;
|
|
@@ -196,24 +218,19 @@ const DBSelect = class {
|
|
|
196
218
|
}, controller.signal);
|
|
197
219
|
}
|
|
198
220
|
}
|
|
199
|
-
|
|
200
|
-
this.
|
|
221
|
+
watch4() {
|
|
222
|
+
this.watch4Fn();
|
|
201
223
|
}
|
|
202
224
|
componentDidLoad() {
|
|
203
|
-
var _a;
|
|
204
225
|
this.enableAttributePassing(this._ref, "db-select");
|
|
205
226
|
this.initialized = true;
|
|
206
|
-
|
|
207
|
-
this._id = mId;
|
|
208
|
-
this._messageId = mId + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
209
|
-
this._validMessageId = mId + constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX;
|
|
210
|
-
this._invalidMessageId = mId + constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
|
|
211
|
-
this._placeholderId = mId + constants.DEFAULT_PLACEHOLDER_ID_SUFFIX;
|
|
227
|
+
this.resetIds();
|
|
212
228
|
this._invalidMessage = this.invalidMessage || constants.DEFAULT_INVALID_MESSAGE;
|
|
213
229
|
this.watch0Fn();
|
|
214
230
|
this.watch1Fn();
|
|
215
231
|
this.watch2Fn();
|
|
216
232
|
this.watch3Fn();
|
|
233
|
+
this.watch4Fn();
|
|
217
234
|
}
|
|
218
235
|
disconnectedCallback() {
|
|
219
236
|
var _a;
|
|
@@ -221,32 +238,38 @@ const DBSelect = class {
|
|
|
221
238
|
}
|
|
222
239
|
render() {
|
|
223
240
|
var _a, _b, _c, _d, _e;
|
|
224
|
-
return (index.h("div", { key: '
|
|
241
|
+
return (index.h("div", { key: '0e3ebb6a472cbd86ec971d96062c6779e11c9ff4', class: index$1.cls("db-select", this.className), "data-variant": this.variant, "data-hide-label": index$1.getHideProp(this.showLabel), "data-hide-asterisk": index$1.getHideProp(this.showRequiredAsterisk), "data-icon": this.icon, "data-show-icon": index$1.getBooleanAsString(this.showIcon) }, index.h("label", { key: '7d22cdb4c487037568a185719165efeaf4825b38', htmlFor: this._id }, (_a = this.label) !== null && _a !== void 0 ? _a : constants.DEFAULT_LABEL), index.h("select", { key: '6a4e62ac9f68e9ec0cf8379b812b8868bf47beb0', "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
|
|
225
242
|
this._ref = el;
|
|
226
243
|
}, required: index$1.getBoolean(this.required, "required"), disabled: index$1.getBoolean(this.disabled, "disabled"), id: this._id, name: this.name, size: this.size,
|
|
227
244
|
/* @ts-ignore */
|
|
228
245
|
value: (_b = this.value) !== null && _b !== void 0 ? _b : this._value, autocomplete: this.autocomplete, multiple: this.multiple, onInput: (event) => this.handleInput(event), onClick: (event) => this.handleClick(event), onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event), "aria-describedby": (_c = this.ariaDescribedBy) !== null && _c !== void 0 ? _c : this._descByIds }, this.variant === "floating" || !!this.placeholder ? (index.h("option", { class: "placeholder", value: "", "data-show-empty-option": index$1.getBooleanAsString(this.shouldShowEmptyOption()) })) : null, ((_d = this.options) === null || _d === void 0 ? void 0 : _d.length) ? ((_e = this.options) === null || _e === void 0 ? void 0 : _e.map((option) => {
|
|
229
246
|
var _a;
|
|
230
247
|
return (index.h(index.Fragment, null, option.options ? (index.h("optgroup", { label: this.getOptionLabel(option), key: undefined }, (_a = option.options) === null || _a === void 0 ? void 0 : _a.map((optgroupOption) => (index.h("option", { value: optgroupOption.value, selected: optgroupOption.selected, disabled: optgroupOption.disabled, key: undefined }, this.getOptionLabel(optgroupOption)))))) : (index.h("option", { value: option.value, disabled: option.disabled, selected: option.selected, key: undefined }, this.getOptionLabel(option)))));
|
|
231
|
-
})) : (index.h("slot", null))), this.placeholder ? (index.h("span", { class: "db-select-placeholder", id: this._placeholderId }, this.placeholder)) : null, index$1.stringPropVisible(this.message, this.showMessage) ? (index.h("db-infotext", { size: "small", icon: this.messageIcon, id: this._messageId }, this.message)) : null, this.hasValidState() ? (index.h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, this.validMessage || constants.DEFAULT_VALID_MESSAGE)) : null, index.h("db-infotext", { key: '
|
|
248
|
+
})) : (index.h("slot", null))), this.placeholder ? (index.h("span", { class: "db-select-placeholder", id: this._placeholderId }, this.placeholder)) : null, index$1.stringPropVisible(this.message, this.showMessage) ? (index.h("db-infotext", { size: "small", icon: this.messageIcon, id: this._messageId }, this.message)) : null, this.hasValidState() ? (index.h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, this.validMessage || constants.DEFAULT_VALID_MESSAGE)) : null, index.h("db-infotext", { key: '736b83b341e8161f463a3131fc6cb39f6c966fc7', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), index.h("span", { key: '1353c1a7cf3ae895b6108bc4800ab40ca808c596', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
|
|
232
249
|
}
|
|
233
250
|
static get watchers() { return {
|
|
234
|
-
"
|
|
251
|
+
"id": [{
|
|
235
252
|
"watch0": 0
|
|
253
|
+
}],
|
|
254
|
+
"propOverrides?.id": [{
|
|
255
|
+
"watch0": 0
|
|
256
|
+
}],
|
|
257
|
+
"_ref": [{
|
|
258
|
+
"watch1": 0
|
|
236
259
|
}, {
|
|
237
|
-
"
|
|
260
|
+
"watch4": 0
|
|
238
261
|
}],
|
|
239
262
|
"invalidMessage": [{
|
|
240
|
-
"
|
|
263
|
+
"watch1": 0
|
|
241
264
|
}],
|
|
242
265
|
"_id": [{
|
|
243
|
-
"
|
|
266
|
+
"watch2": 0
|
|
244
267
|
}],
|
|
245
268
|
"initialized": [{
|
|
246
|
-
"
|
|
269
|
+
"watch2": 0
|
|
247
270
|
}],
|
|
248
271
|
"value": [{
|
|
249
|
-
"
|
|
272
|
+
"watch3": 0
|
|
250
273
|
}]
|
|
251
274
|
}; }
|
|
252
275
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
var index$1 = require('./index-
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
5
5
|
|
|
6
6
|
const DBStack = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -18,12 +18,16 @@ const DBStack = class {
|
|
|
18
18
|
const attributes = parent.attributes;
|
|
19
19
|
for (let i = 0; i < attributes.length; i++) {
|
|
20
20
|
const attr = attributes.item(i);
|
|
21
|
-
if (attr &&
|
|
21
|
+
if (attr && attr.name !== 'data-density' &&
|
|
22
22
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
23
23
|
element.setAttribute(attr.name, attr.value);
|
|
24
24
|
parent.removeAttribute(attr.name);
|
|
25
25
|
}
|
|
26
|
-
if (attr && attr.name
|
|
26
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
27
|
+
element.setAttribute(attr.name, attr.value);
|
|
28
|
+
parent.removeAttribute(attr.name);
|
|
29
|
+
}
|
|
30
|
+
else if (attr && attr.name === "class") {
|
|
27
31
|
const isWebComponent = attr.value.includes("hydrated");
|
|
28
32
|
const value = attr.value.replace("hydrated", "").trim();
|
|
29
33
|
const currentClass = element.getAttribute("class");
|
|
@@ -43,9 +47,10 @@ const DBStack = class {
|
|
|
43
47
|
this.enableAttributePassing(this._ref, "db-stack");
|
|
44
48
|
}
|
|
45
49
|
render() {
|
|
46
|
-
|
|
50
|
+
var _a, _b;
|
|
51
|
+
return (index.h("div", { key: '6927a665a08e7383c992d2b93d264a991e871969', class: index$1.cls("db-stack", this.className), ref: (el) => {
|
|
47
52
|
this._ref = el;
|
|
48
|
-
}, id: this.id, "data-gap": this.gap, "data-variant": this.variant, "data-direction": this.direction, "data-alignment": this.alignment, "data-justify-content": this.justifyContent, "data-wrap": index$1.getBooleanAsString(this.wrap) }, index.h("slot", { key: '
|
|
53
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-gap": this.gap, "data-variant": this.variant, "data-direction": this.direction, "data-alignment": this.alignment, "data-justify-content": this.justifyContent, "data-wrap": index$1.getBooleanAsString(this.wrap) }, index.h("slot", { key: '0c5f39afc50167b38e39797c240f32a696d93adb' })));
|
|
49
54
|
}
|
|
50
55
|
};
|
|
51
56
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
4
|
var constants = require('./constants-bMY2_d8A.js');
|
|
5
|
-
var index$1 = require('./index-
|
|
6
|
-
var formComponents = require('./form-components-
|
|
5
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
6
|
+
var formComponents = require('./form-components-_ncB_U2D.js');
|
|
7
7
|
|
|
8
8
|
const DBSwitch = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -84,6 +84,14 @@ const DBSwitch = class {
|
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
|
+
resetIds() {
|
|
88
|
+
var _a, _b, _c;
|
|
89
|
+
const mId = (_c = (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) !== null && _c !== void 0 ? _c : `switch-${index$1.uuid()}`;
|
|
90
|
+
this._id = mId;
|
|
91
|
+
this._messageId = `${mId}${constants.DEFAULT_MESSAGE_ID_SUFFIX}`;
|
|
92
|
+
this._validMessageId = `${mId}${constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX}`;
|
|
93
|
+
this._invalidMessageId = `${mId}${constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX}`;
|
|
94
|
+
}
|
|
87
95
|
/**
|
|
88
96
|
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
89
97
|
* @param element the ref for the component
|
|
@@ -95,12 +103,16 @@ const DBSwitch = class {
|
|
|
95
103
|
const attributes = parent.attributes;
|
|
96
104
|
for (let i = 0; i < attributes.length; i++) {
|
|
97
105
|
const attr = attributes.item(i);
|
|
98
|
-
if (attr &&
|
|
106
|
+
if (attr && attr.name !== 'data-density' &&
|
|
99
107
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
100
108
|
element.setAttribute(attr.name, attr.value);
|
|
101
109
|
parent.removeAttribute(attr.name);
|
|
102
110
|
}
|
|
103
|
-
if (attr && attr.name
|
|
111
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
112
|
+
element.setAttribute(attr.name, attr.value);
|
|
113
|
+
parent.removeAttribute(attr.name);
|
|
114
|
+
}
|
|
115
|
+
else if (attr && attr.name === "class") {
|
|
104
116
|
const isWebComponent = attr.value.includes("hydrated");
|
|
105
117
|
const value = attr.value.replace("hydrated", "").trim();
|
|
106
118
|
const currentClass = element.getAttribute("class");
|
|
@@ -117,12 +129,31 @@ const DBSwitch = class {
|
|
|
117
129
|
}
|
|
118
130
|
}
|
|
119
131
|
watch0Fn() {
|
|
120
|
-
|
|
132
|
+
var _a, _b;
|
|
133
|
+
if ((_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) {
|
|
134
|
+
this.resetIds();
|
|
135
|
+
}
|
|
121
136
|
}
|
|
122
137
|
watch0() {
|
|
123
138
|
this.watch0Fn();
|
|
124
139
|
}
|
|
125
140
|
watch1Fn() {
|
|
141
|
+
this.handleValidation();
|
|
142
|
+
}
|
|
143
|
+
watch1() {
|
|
144
|
+
this.watch1Fn();
|
|
145
|
+
}
|
|
146
|
+
watch2Fn() {
|
|
147
|
+
var _a;
|
|
148
|
+
this._invalidMessage =
|
|
149
|
+
this.invalidMessage ||
|
|
150
|
+
((_a = this._ref) === null || _a === void 0 ? void 0 : _a.validationMessage) ||
|
|
151
|
+
constants.DEFAULT_INVALID_MESSAGE;
|
|
152
|
+
}
|
|
153
|
+
watch2() {
|
|
154
|
+
this.watch2Fn();
|
|
155
|
+
}
|
|
156
|
+
watch3Fn() {
|
|
126
157
|
if (this._ref) {
|
|
127
158
|
const defaultChecked = undefined;
|
|
128
159
|
let controller = this.abortController;
|
|
@@ -138,54 +169,63 @@ const DBSwitch = class {
|
|
|
138
169
|
}, controller.signal);
|
|
139
170
|
}
|
|
140
171
|
}
|
|
141
|
-
|
|
142
|
-
this.
|
|
172
|
+
watch3() {
|
|
173
|
+
this.watch3Fn();
|
|
143
174
|
}
|
|
144
175
|
componentDidLoad() {
|
|
145
|
-
var _a;
|
|
146
176
|
this.enableAttributePassing(this._ref, "db-switch");
|
|
147
|
-
this.
|
|
148
|
-
this._messageId = `${this._id}${constants.DEFAULT_MESSAGE_ID_SUFFIX}`;
|
|
149
|
-
this._validMessageId = `${this._id}${constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX}`;
|
|
150
|
-
this._invalidMessageId = `${this._id}${constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX}`;
|
|
177
|
+
this.resetIds();
|
|
151
178
|
this.handleValidation();
|
|
179
|
+
this._invalidMessage = this.invalidMessage || constants.DEFAULT_INVALID_MESSAGE;
|
|
152
180
|
this.watch0Fn();
|
|
153
181
|
this.watch1Fn();
|
|
182
|
+
this.watch2Fn();
|
|
183
|
+
this.watch3Fn();
|
|
154
184
|
}
|
|
155
185
|
disconnectedCallback() {
|
|
156
186
|
var _a;
|
|
157
187
|
(_a = this.abortController) === null || _a === void 0 ? void 0 : _a.abort();
|
|
158
188
|
}
|
|
159
189
|
render() {
|
|
160
|
-
var _a, _b
|
|
161
|
-
return (index.h("div", { key: '
|
|
190
|
+
var _a, _b;
|
|
191
|
+
return (index.h("div", { key: '5d55932625984fa62f0ee9d86f3d89f5b63f9072', class: index$1.cls("db-switch", this.className), "data-visual-aid": index$1.getBooleanAsString(this.visualAid), "data-size": this.size, "data-hide-label": index$1.getHideProp(this.showLabel), "data-variant": this.variant, "data-hide-asterisk": index$1.getHideProp(this.showRequiredAsterisk), "data-custom-validity": this.validation }, index.h("label", { key: '711ab3c882dbd490e19400ecf5d926f5bf80e95e', htmlFor: this._id }, index.h("input", { key: 'aa50031870b7ee76e1f1e6f9bd5dd14b9013de18', type: "checkbox", role: "switch", id: this._id, ref: (el) => {
|
|
162
192
|
this._ref = el;
|
|
163
|
-
}, checked: index$1.getBoolean(this.checked, "checked"), value: this.value, disabled: index$1.getBoolean(this.disabled, "disabled"), "aria-invalid": this.validation === "invalid" ? "true" : undefined, "aria-describedby": this._descByIds, name: this.name, required: index$1.getBoolean(this.required, "required"), "data-aid-icon": (_a = this.iconLeading) !== null && _a !== void 0 ? _a : this.icon, "data-aid-icon-trailing": this.iconTrailing, onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event), onKeyDown: (event) => this.handleKeyDown(event) }), this.label ? this.label : index.h("slot", null)), index$1.stringPropVisible(this.message, this.showMessage) ? (index.h("db-infotext", { size: "small", semantic: "adaptive", id: this._messageId, icon: this.messageIcon }, this.message)) : null, this.hasValidState() ? (index.h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, (_b = this.validMessage) !== null && _b !== void 0 ? _b : constants.DEFAULT_VALID_MESSAGE)) : null, index.h("db-infotext", { key: '
|
|
193
|
+
}, checked: index$1.getBoolean(this.checked, "checked"), value: this.value, disabled: index$1.getBoolean(this.disabled, "disabled"), "aria-invalid": this.validation === "invalid" ? "true" : undefined, "aria-describedby": this._descByIds, name: this.name, required: index$1.getBoolean(this.required, "required"), "data-aid-icon": (_a = this.iconLeading) !== null && _a !== void 0 ? _a : this.icon, "data-aid-icon-trailing": this.iconTrailing, onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event), onKeyDown: (event) => this.handleKeyDown(event) }), this.label ? this.label : index.h("slot", null)), index$1.stringPropVisible(this.message, this.showMessage) ? (index.h("db-infotext", { size: "small", semantic: "adaptive", id: this._messageId, icon: this.messageIcon }, this.message)) : null, this.hasValidState() ? (index.h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, (_b = this.validMessage) !== null && _b !== void 0 ? _b : constants.DEFAULT_VALID_MESSAGE)) : null, index.h("db-infotext", { key: '95f846f3de48f29bef0406c3c19d0314a2a0cfc6', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), index.h("span", { key: '297a64a0c5b5faf97a3f685ab78eea7145fe700e', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
|
|
164
194
|
}
|
|
165
195
|
static get watchers() { return {
|
|
166
|
-
"
|
|
196
|
+
"id": [{
|
|
167
197
|
"watch0": 0
|
|
168
198
|
}],
|
|
169
|
-
"
|
|
199
|
+
"propOverrides?.id": [{
|
|
170
200
|
"watch0": 0
|
|
171
201
|
}],
|
|
202
|
+
"validation": [{
|
|
203
|
+
"watch1": 0
|
|
204
|
+
}],
|
|
205
|
+
"required": [{
|
|
206
|
+
"watch1": 0
|
|
207
|
+
}],
|
|
172
208
|
"message": [{
|
|
173
|
-
"
|
|
209
|
+
"watch1": 0
|
|
174
210
|
}],
|
|
175
211
|
"showMessage": [{
|
|
176
|
-
"
|
|
212
|
+
"watch1": 0
|
|
177
213
|
}],
|
|
178
214
|
"validMessage": [{
|
|
179
|
-
"
|
|
215
|
+
"watch1": 0
|
|
180
216
|
}],
|
|
181
217
|
"invalidMessage": [{
|
|
182
|
-
"
|
|
218
|
+
"watch1": 0
|
|
219
|
+
}, {
|
|
220
|
+
"watch2": 0
|
|
183
221
|
}],
|
|
184
222
|
"checked": [{
|
|
185
|
-
"
|
|
223
|
+
"watch1": 0
|
|
186
224
|
}],
|
|
187
225
|
"_ref": [{
|
|
188
|
-
"
|
|
226
|
+
"watch2": 0
|
|
227
|
+
}, {
|
|
228
|
+
"watch3": 0
|
|
189
229
|
}]
|
|
190
230
|
}; }
|
|
191
231
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
var index$1 = require('./index-
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
5
5
|
|
|
6
6
|
const DBTabItem = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -44,12 +44,16 @@ const DBTabItem = class {
|
|
|
44
44
|
const attributes = parent.attributes;
|
|
45
45
|
for (let i = 0; i < attributes.length; i++) {
|
|
46
46
|
const attr = attributes.item(i);
|
|
47
|
-
if (attr &&
|
|
47
|
+
if (attr && attr.name !== 'data-density' &&
|
|
48
48
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
49
49
|
element.setAttribute(attr.name, attr.value);
|
|
50
50
|
parent.removeAttribute(attr.name);
|
|
51
51
|
}
|
|
52
|
-
if (attr && attr.name
|
|
52
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
53
|
+
element.setAttribute(attr.name, attr.value);
|
|
54
|
+
parent.removeAttribute(attr.name);
|
|
55
|
+
}
|
|
56
|
+
else if (attr && attr.name === "class") {
|
|
53
57
|
const isWebComponent = attr.value.includes("hydrated");
|
|
54
58
|
const value = attr.value.replace("hydrated", "").trim();
|
|
55
59
|
const currentClass = element.getAttribute("class");
|
|
@@ -109,10 +113,10 @@ const DBTabItem = class {
|
|
|
109
113
|
}
|
|
110
114
|
}
|
|
111
115
|
render() {
|
|
112
|
-
var _a, _b;
|
|
113
|
-
return (index.h("li", { key: '
|
|
116
|
+
var _a, _b, _c, _d, _e, _f;
|
|
117
|
+
return (index.h("li", { key: 'aa5a73d9a5f1482623ebdb8a79846b478ecf9fd1', class: index$1.cls("db-tab-item", this.className), role: "none" }, index.h("label", { key: 'b6148c23f64ffd2d9153db7e8e3d39a90f009da3', htmlFor: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-icon": (_c = this.iconLeading) !== null && _c !== void 0 ? _c : this.icon, "data-icon-trailing": this.iconTrailing, "data-show-icon": index$1.getBooleanAsString((_d = this.showIconLeading) !== null && _d !== void 0 ? _d : this.showIcon), "data-show-icon-trailing": index$1.getBooleanAsString(this.showIconTrailing), "data-no-text": index$1.getBooleanAsString(this.noText) }, index.h("input", { key: 'c7d167364eaa4f9cee156d9260553b14d60ffb13', type: "radio", role: "tab", disabled: index$1.getBoolean(this.disabled, "disabled"), "aria-selected": this._selected, checked: index$1.getBoolean(this.checked, "checked"), ref: (el) => {
|
|
114
118
|
this._ref = el;
|
|
115
|
-
}, name: this._name, id: this.id, onInput: (event) => this.handleChange(event) }), this.label ? this.label : null, index.h("slot", { key: '
|
|
119
|
+
}, name: this._name, id: (_e = this.id) !== null && _e !== void 0 ? _e : (_f = this.propOverrides) === null || _f === void 0 ? void 0 : _f.id, onInput: (event) => this.handleChange(event) }), this.label ? this.label : null, index.h("slot", { key: 'aab78a92118a8ea9b7ffcb446ead8211294a6e6c' }))));
|
|
116
120
|
}
|
|
117
121
|
static get watchers() { return {
|
|
118
122
|
"_ref": [{
|
|
@@ -145,12 +149,16 @@ const DBTabList = class {
|
|
|
145
149
|
const attributes = parent.attributes;
|
|
146
150
|
for (let i = 0; i < attributes.length; i++) {
|
|
147
151
|
const attr = attributes.item(i);
|
|
148
|
-
if (attr &&
|
|
152
|
+
if (attr && attr.name !== 'data-density' &&
|
|
149
153
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
150
154
|
element.setAttribute(attr.name, attr.value);
|
|
151
155
|
parent.removeAttribute(attr.name);
|
|
152
156
|
}
|
|
153
|
-
if (attr && attr.name
|
|
157
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
158
|
+
element.setAttribute(attr.name, attr.value);
|
|
159
|
+
parent.removeAttribute(attr.name);
|
|
160
|
+
}
|
|
161
|
+
else if (attr && attr.name === "class") {
|
|
154
162
|
const isWebComponent = attr.value.includes("hydrated");
|
|
155
163
|
const value = attr.value.replace("hydrated", "").trim();
|
|
156
164
|
const currentClass = element.getAttribute("class");
|
|
@@ -170,9 +178,10 @@ const DBTabList = class {
|
|
|
170
178
|
this.enableAttributePassing(this._ref, "db-tab-list");
|
|
171
179
|
}
|
|
172
180
|
render() {
|
|
173
|
-
|
|
181
|
+
var _a, _b;
|
|
182
|
+
return (index.h("div", { key: '9d2121250cb2a12971ea33774d8ff9e79117d18e', class: index$1.cls("db-tab-list", this.className), ref: (el) => {
|
|
174
183
|
this._ref = el;
|
|
175
|
-
}, id: this.id }, index.h("ul", { key: '
|
|
184
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, index.h("ul", { key: 'db93a3777f11ee39e15633b0b5ae501b0526d73d', role: "tablist" }, index.h("slot", { key: '14d45a6c1693c5c2bdb2d422397e6ddeb93bf5b3' }))));
|
|
176
185
|
}
|
|
177
186
|
};
|
|
178
187
|
|
|
@@ -191,12 +200,16 @@ const DBTabPanel = class {
|
|
|
191
200
|
const attributes = parent.attributes;
|
|
192
201
|
for (let i = 0; i < attributes.length; i++) {
|
|
193
202
|
const attr = attributes.item(i);
|
|
194
|
-
if (attr &&
|
|
203
|
+
if (attr && attr.name !== 'data-density' &&
|
|
195
204
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
196
205
|
element.setAttribute(attr.name, attr.value);
|
|
197
206
|
parent.removeAttribute(attr.name);
|
|
198
207
|
}
|
|
199
|
-
if (attr && attr.name
|
|
208
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
209
|
+
element.setAttribute(attr.name, attr.value);
|
|
210
|
+
parent.removeAttribute(attr.name);
|
|
211
|
+
}
|
|
212
|
+
else if (attr && attr.name === "class") {
|
|
200
213
|
const isWebComponent = attr.value.includes("hydrated");
|
|
201
214
|
const value = attr.value.replace("hydrated", "").trim();
|
|
202
215
|
const currentClass = element.getAttribute("class");
|
|
@@ -216,9 +229,10 @@ const DBTabPanel = class {
|
|
|
216
229
|
this.enableAttributePassing(this._ref, "db-tab-panel");
|
|
217
230
|
}
|
|
218
231
|
render() {
|
|
219
|
-
|
|
232
|
+
var _a, _b;
|
|
233
|
+
return (index.h("section", { key: '3cae700e240af4818416120b8c85fc91839c7fa1', class: index$1.cls("db-tab-panel", this.className), role: "tabpanel", ref: (el) => {
|
|
220
234
|
this._ref = el;
|
|
221
|
-
}, id: this.id }, this.content ? this.content : null, index.h("slot", { key: '
|
|
235
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, this.content ? this.content : null, index.h("slot", { key: '25595de165921a31119ffd785bd5c569c42fa557' })));
|
|
222
236
|
}
|
|
223
237
|
};
|
|
224
238
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
var index$1 = require('./index-
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
5
5
|
|
|
6
6
|
const DBTabs = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -145,12 +145,16 @@ const DBTabs = class {
|
|
|
145
145
|
const attributes = parent.attributes;
|
|
146
146
|
for (let i = 0; i < attributes.length; i++) {
|
|
147
147
|
const attr = attributes.item(i);
|
|
148
|
-
if (attr &&
|
|
148
|
+
if (attr && attr.name !== 'data-density' &&
|
|
149
149
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
150
150
|
element.setAttribute(attr.name, attr.value);
|
|
151
151
|
parent.removeAttribute(attr.name);
|
|
152
152
|
}
|
|
153
|
-
if (attr && attr.name
|
|
153
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
154
|
+
element.setAttribute(attr.name, attr.value);
|
|
155
|
+
parent.removeAttribute(attr.name);
|
|
156
|
+
}
|
|
157
|
+
else if (attr && attr.name === "class") {
|
|
154
158
|
const isWebComponent = attr.value.includes("hydrated");
|
|
155
159
|
const value = attr.value.replace("hydrated", "").trim();
|
|
156
160
|
const currentClass = element.getAttribute("class");
|
|
@@ -203,11 +207,11 @@ const DBTabs = class {
|
|
|
203
207
|
this._resizeObserver = undefined;
|
|
204
208
|
}
|
|
205
209
|
render() {
|
|
206
|
-
var _a, _b, _c, _d;
|
|
207
|
-
return (index.h("div", { key: '
|
|
210
|
+
var _a, _b, _c, _d, _e, _f;
|
|
211
|
+
return (index.h("div", { key: '6d273b967668288248c3853be80261a877d3ae04', class: index$1.cls("db-tabs", this.className), ref: (el) => {
|
|
208
212
|
this._ref = el;
|
|
209
|
-
}, id: this.id, "data-orientation": this.orientation, "data-scroll-behavior": this.behavior, "data-alignment": (
|
|
210
|
-
|
|
213
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-orientation": this.orientation, "data-scroll-behavior": this.behavior, "data-alignment": (_c = this.alignment) !== null && _c !== void 0 ? _c : "start", "data-width": (_d = this.width) !== null && _d !== void 0 ? _d : "auto", onInput: (event) => this.handleChange(event), onChange: (event) => this.handleChange(event) }, this.showScrollLeft ? (index.h("db-button", { class: "tabs-scroll-left", variant: "ghost", icon: "chevron_left", type: "button", noText: true, onClick: () => this.scroll(true) }, "Scroll left")) : null, this.tabs ? (index.h(index.Fragment, null, index.h("db-tab-list", null, (_e = this.convertTabs()) === null || _e === void 0 ? void 0 : _e.map((tab, index$1) => (index.h("db-tab-item", { key: this.name + "tab-item" + index$1, active: tab.active, label: tab.label, iconTrailing: tab.iconTrailing, icon: tab.icon, noText: tab.noText })))), (_f = this.convertTabs()) === null || _f === void 0 ? void 0 :
|
|
214
|
+
_f.map((tab, index$1) => (index.h("db-tab-panel", { key: this.name + "tab-panel" + index$1, content: tab.content }, tab.children))))) : null, this.showScrollRight ? (index.h("db-button", { class: "tabs-scroll-right", variant: "ghost", icon: "chevron_right", type: "button", noText: true, onClick: () => this.scroll() }, "Scroll right")) : null, index.h("slot", { key: '04f5d96f32695ae2661ace77827ee783eb0f23d0' })));
|
|
211
215
|
}
|
|
212
216
|
static get watchers() { return {
|
|
213
217
|
"_ref": [{
|