@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
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @db-ux/wc-core-components
|
|
2
2
|
|
|
3
|
+
## 4.5.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- feat: add `wrap` property for possible inline components (badge, button, infotext, tooltip) besides link and navigation-item, which already have the `wrap` property - [see commit c08970c](https://github.com/db-ux-design-system/core-web/commit/c08970c640f24abee93ed17de258f4e15fa7cb7f)
|
|
8
|
+
|
|
9
|
+
- feat: add `propOverrides` property for components to provide a possibility for avoiding duplicated `id` property on Angular and Web Components - [see commit 9720ebb](https://github.com/db-ux-design-system/core-web/commit/9720ebb9c47302ed0d9939ce219a7d876ba0155c)
|
|
10
|
+
|
|
11
|
+
- feat: add DBCustomButton for development to style `<a>` or `<label><input/>` children - [see commit a50323b](https://github.com/db-ux-design-system/core-web/commit/a50323b21363981c02bbabf7828a6f2d94f11e4d)
|
|
12
|
+
|
|
13
|
+
## 4.4.3
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- fix: icon color for DBTag with semantic property set - [see commit 89c4ad7](https://github.com/db-ux-design-system/core-web/commit/89c4ad7274cdadaccc0aedc106d6f2c781e6ce8a)
|
|
18
|
+
|
|
19
|
+
- fix: issue with DBCustomSelect not working properly with customValidity="no-validation" - [see commit 758ecb9](https://github.com/db-ux-design-system/core-web/commit/758ecb90f82a6c3d648728fa92c92474600b9941)
|
|
20
|
+
|
|
21
|
+
- fix: issue with floating-components (tooltip, popover, etc.) inside other absolute or fixed elements - [see commit e6d934f](https://github.com/db-ux-design-system/core-web/commit/e6d934f0c0a4af0b6dd57f81773831a2431b94e1)
|
|
22
|
+
|
|
3
23
|
## 4.4.2
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
|
@@ -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 DBAccordionItem = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -42,12 +42,16 @@ const DBAccordionItem = class {
|
|
|
42
42
|
const attributes = parent.attributes;
|
|
43
43
|
for (let i = 0; i < attributes.length; i++) {
|
|
44
44
|
const attr = attributes.item(i);
|
|
45
|
-
if (attr &&
|
|
45
|
+
if (attr && attr.name !== 'data-density' &&
|
|
46
46
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
47
47
|
element.setAttribute(attr.name, attr.value);
|
|
48
48
|
parent.removeAttribute(attr.name);
|
|
49
49
|
}
|
|
50
|
-
if (attr && attr.name
|
|
50
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
51
|
+
element.setAttribute(attr.name, attr.value);
|
|
52
|
+
parent.removeAttribute(attr.name);
|
|
53
|
+
}
|
|
54
|
+
else if (attr && attr.name === "class") {
|
|
51
55
|
const isWebComponent = attr.value.includes("hydrated");
|
|
52
56
|
const value = attr.value.replace("hydrated", "").trim();
|
|
53
57
|
const currentClass = element.getAttribute("class");
|
|
@@ -86,9 +90,10 @@ const DBAccordionItem = class {
|
|
|
86
90
|
this.watch1Fn();
|
|
87
91
|
}
|
|
88
92
|
render() {
|
|
89
|
-
|
|
93
|
+
var _a, _b;
|
|
94
|
+
return (index.h("li", { key: 'd326ba8af9e635f673d1016cd16ef9a9a8b1503c', class: index$1.cls("db-accordion-item", this.className), id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, index.h("details", { key: '6f15470fcdaf103df318c251e941fed9fd79c4ee', "aria-disabled": index$1.getBooleanAsString(this.disabled), ref: (el) => {
|
|
90
95
|
this._ref = el;
|
|
91
|
-
}, name: this._name, open: this._open }, index.h("summary", { key: '
|
|
96
|
+
}, name: this._name, open: this._open }, index.h("summary", { key: 'db41f2b1f85dfdecf9ab37b35b04efb2e83d69af', onClick: (event) => this.handleToggle(event) }, this.headlinePlain ? this.headlinePlain : null, !this.headlinePlain ? index.h("slot", { name: "headline" }) : null), index.h("div", { key: '00a6fed4fdb26de2c998d991a6dfaee6caa3ca92' }, this.text ? this.text : index.h("slot", null)))));
|
|
92
97
|
}
|
|
93
98
|
static get watchers() { return {
|
|
94
99
|
"_ref": [{
|
|
@@ -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 DBAccordion = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -33,12 +33,16 @@ const DBAccordion = class {
|
|
|
33
33
|
const attributes = parent.attributes;
|
|
34
34
|
for (let i = 0; i < attributes.length; i++) {
|
|
35
35
|
const attr = attributes.item(i);
|
|
36
|
-
if (attr &&
|
|
36
|
+
if (attr && attr.name !== 'data-density' &&
|
|
37
37
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
38
38
|
element.setAttribute(attr.name, attr.value);
|
|
39
39
|
parent.removeAttribute(attr.name);
|
|
40
40
|
}
|
|
41
|
-
if (attr && attr.name
|
|
41
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
42
|
+
element.setAttribute(attr.name, attr.value);
|
|
43
|
+
parent.removeAttribute(attr.name);
|
|
44
|
+
}
|
|
45
|
+
else if (attr && attr.name === "class") {
|
|
42
46
|
const isWebComponent = attr.value.includes("hydrated");
|
|
43
47
|
const value = attr.value.replace("hydrated", "").trim();
|
|
44
48
|
const currentClass = element.getAttribute("class");
|
|
@@ -125,11 +129,11 @@ const DBAccordion = class {
|
|
|
125
129
|
this.watch2Fn();
|
|
126
130
|
}
|
|
127
131
|
render() {
|
|
128
|
-
var _a;
|
|
129
|
-
return (index.h("ul", { key: '
|
|
132
|
+
var _a, _b, _c;
|
|
133
|
+
return (index.h("ul", { key: 'ea919e6fa79f820a40ece5ee3305dad84f113d1d', class: index$1.cls("db-accordion", this.className), ref: (el) => {
|
|
130
134
|
this._ref = el;
|
|
131
|
-
}, id: this.id, "data-variant": this.variant }, !this.items ? index.h("slot", null) : null, this.items
|
|
132
|
-
? (
|
|
135
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-variant": this.variant }, !this.items ? index.h("slot", null) : null, this.items
|
|
136
|
+
? (_c = this.convertItems()) === null || _c === void 0 ? void 0 : _c.map((item, index$1) => (index.h("db-accordion-item", { key: `accordion-item-${index$1}`, headlinePlain: item.headlinePlain, disabled: item.disabled, text: item.text })))
|
|
133
137
|
: null));
|
|
134
138
|
}
|
|
135
139
|
static get watchers() { return {
|
|
@@ -1,8 +1,8 @@
|
|
|
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-
|
|
5
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
6
6
|
|
|
7
7
|
const DBBadge = class {
|
|
8
8
|
constructor(hostRef) {
|
|
@@ -20,12 +20,16 @@ const DBBadge = class {
|
|
|
20
20
|
const attributes = parent.attributes;
|
|
21
21
|
for (let i = 0; i < attributes.length; i++) {
|
|
22
22
|
const attr = attributes.item(i);
|
|
23
|
-
if (attr &&
|
|
23
|
+
if (attr && attr.name !== 'data-density' &&
|
|
24
24
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
25
25
|
element.setAttribute(attr.name, attr.value);
|
|
26
26
|
parent.removeAttribute(attr.name);
|
|
27
27
|
}
|
|
28
|
-
if (attr && attr.name
|
|
28
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
29
|
+
element.setAttribute(attr.name, attr.value);
|
|
30
|
+
parent.removeAttribute(attr.name);
|
|
31
|
+
}
|
|
32
|
+
else if (attr && attr.name === "class") {
|
|
29
33
|
const isWebComponent = attr.value.includes("hydrated");
|
|
30
34
|
const value = attr.value.replace("hydrated", "").trim();
|
|
31
35
|
const currentClass = element.getAttribute("class");
|
|
@@ -65,10 +69,10 @@ const DBBadge = class {
|
|
|
65
69
|
this.watch0Fn();
|
|
66
70
|
}
|
|
67
71
|
render() {
|
|
68
|
-
var _a, _b;
|
|
69
|
-
return (index.h("span", { key: '
|
|
72
|
+
var _a, _b, _c, _d;
|
|
73
|
+
return (index.h("span", { key: '285ff83ac5c79c7e1c6328aba89e1825f57dd78a', class: index$1.cls("db-badge", this.className), ref: (el) => {
|
|
70
74
|
this._ref = el;
|
|
71
|
-
}, id: this.id, "data-semantic": this.semantic, "data-size": this.size, "data-emphasis": this.emphasis, "data-placement": this.placement, "data-label": ((
|
|
75
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-semantic": this.semantic, "data-size": this.size, "data-emphasis": this.emphasis, "data-placement": this.placement, "data-wrap": index$1.getBooleanAsString(this.wrap), "data-label": ((_c = this.placement) === null || _c === void 0 ? void 0 : _c.startsWith("corner")) && ((_d = this.label) !== null && _d !== void 0 ? _d : constants.DEFAULT_LABEL) }, this.text ? this.text : index.h("slot", null)));
|
|
72
76
|
}
|
|
73
77
|
static get watchers() { return {
|
|
74
78
|
"_ref": [{
|
|
@@ -1,8 +1,8 @@
|
|
|
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-
|
|
5
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
6
6
|
|
|
7
7
|
const DBBrand = class {
|
|
8
8
|
constructor(hostRef) {
|
|
@@ -19,12 +19,16 @@ const DBBrand = class {
|
|
|
19
19
|
const attributes = parent.attributes;
|
|
20
20
|
for (let i = 0; i < attributes.length; i++) {
|
|
21
21
|
const attr = attributes.item(i);
|
|
22
|
-
if (attr &&
|
|
22
|
+
if (attr && attr.name !== 'data-density' &&
|
|
23
23
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
24
24
|
element.setAttribute(attr.name, attr.value);
|
|
25
25
|
parent.removeAttribute(attr.name);
|
|
26
26
|
}
|
|
27
|
-
if (attr && attr.name
|
|
27
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
28
|
+
element.setAttribute(attr.name, attr.value);
|
|
29
|
+
parent.removeAttribute(attr.name);
|
|
30
|
+
}
|
|
31
|
+
else if (attr && attr.name === "class") {
|
|
28
32
|
const isWebComponent = attr.value.includes("hydrated");
|
|
29
33
|
const value = attr.value.replace("hydrated", "").trim();
|
|
30
34
|
const currentClass = element.getAttribute("class");
|
|
@@ -44,10 +48,10 @@ const DBBrand = class {
|
|
|
44
48
|
this.enableAttributePassing(this._ref, "db-brand");
|
|
45
49
|
}
|
|
46
50
|
render() {
|
|
47
|
-
var _a;
|
|
48
|
-
return (index.h("div", { key: '
|
|
51
|
+
var _a, _b, _c;
|
|
52
|
+
return (index.h("div", { key: '2dbff45d3e8c3dbe6f1993c3401a12f15628984d', class: index$1.cls("db-brand", this.className), ref: (el) => {
|
|
49
53
|
this._ref = el;
|
|
50
|
-
}, "data-icon": this.hideLogo ? "none" : (_a = this.icon) !== null && _a !== void 0 ? _a : constants.DEFAULT_ICON, "data-show-icon": index$1.getBooleanAsString(this.showIcon), id: this.id }, this.text ? this.text : index.h("slot", null)));
|
|
54
|
+
}, "data-icon": this.hideLogo ? "none" : (_a = this.icon) !== null && _a !== void 0 ? _a : constants.DEFAULT_ICON, "data-show-icon": index$1.getBooleanAsString(this.showIcon), id: (_b = this.id) !== null && _b !== void 0 ? _b : (_c = this.propOverrides) === null || _c === void 0 ? void 0 : _c.id }, this.text ? this.text : index.h("slot", null)));
|
|
51
55
|
}
|
|
52
56
|
};
|
|
53
57
|
|
|
@@ -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 DBButton = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -28,12 +28,16 @@ const DBButton = class {
|
|
|
28
28
|
const attributes = parent.attributes;
|
|
29
29
|
for (let i = 0; i < attributes.length; i++) {
|
|
30
30
|
const attr = attributes.item(i);
|
|
31
|
-
if (attr &&
|
|
31
|
+
if (attr && attr.name !== 'data-density' &&
|
|
32
32
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
33
33
|
element.setAttribute(attr.name, attr.value);
|
|
34
34
|
parent.removeAttribute(attr.name);
|
|
35
35
|
}
|
|
36
|
-
if (attr && attr.name
|
|
36
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
37
|
+
element.setAttribute(attr.name, attr.value);
|
|
38
|
+
parent.removeAttribute(attr.name);
|
|
39
|
+
}
|
|
40
|
+
else if (attr && attr.name === "class") {
|
|
37
41
|
const isWebComponent = attr.value.includes("hydrated");
|
|
38
42
|
const value = attr.value.replace("hydrated", "").trim();
|
|
39
43
|
const currentClass = element.getAttribute("class");
|
|
@@ -53,10 +57,10 @@ const DBButton = class {
|
|
|
53
57
|
this.enableAttributePassing(this._ref, "db-button");
|
|
54
58
|
}
|
|
55
59
|
render() {
|
|
56
|
-
var _a, _b;
|
|
57
|
-
return (index.h("button", { key: '
|
|
60
|
+
var _a, _b, _c, _d;
|
|
61
|
+
return (index.h("button", { key: '8bd02e4a26046fa1b62f26449e961b2ba7edf377', class: index$1.cls("db-button", this.className), ref: (el) => {
|
|
58
62
|
this._ref = el;
|
|
59
|
-
}, id: this.id, type: this.getButtonType(), disabled: index$1.getBoolean(this.disabled, "disabled"), "data-icon": (
|
|
63
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, type: this.getButtonType(), disabled: index$1.getBoolean(this.disabled, "disabled"), "data-icon": (_c = this.iconLeading) !== null && _c !== void 0 ? _c : this.icon, "data-show-icon": index$1.getBooleanAsString((_d = this.showIconLeading) !== null && _d !== void 0 ? _d : this.showIcon), "data-icon-trailing": this.iconTrailing, "data-show-icon-trailing": index$1.getBooleanAsString(this.showIconTrailing), "data-size": this.size, "data-width": this.width, "data-variant": this.variant, "data-wrap": index$1.getBooleanAsString(this.wrap), "data-no-text": index$1.getBooleanAsString(this.noText), name: this.name, form: this.form, value: this.value }, this.text ? this.text : index.h("slot", null)));
|
|
60
64
|
}
|
|
61
65
|
};
|
|
62
66
|
|
|
@@ -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 DBCard = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -24,12 +24,16 @@ const DBCard = class {
|
|
|
24
24
|
const attributes = parent.attributes;
|
|
25
25
|
for (let i = 0; i < attributes.length; i++) {
|
|
26
26
|
const attr = attributes.item(i);
|
|
27
|
-
if (attr &&
|
|
27
|
+
if (attr && attr.name !== 'data-density' &&
|
|
28
28
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
29
29
|
element.setAttribute(attr.name, attr.value);
|
|
30
30
|
parent.removeAttribute(attr.name);
|
|
31
31
|
}
|
|
32
|
-
if (attr && attr.name
|
|
32
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
33
|
+
element.setAttribute(attr.name, attr.value);
|
|
34
|
+
parent.removeAttribute(attr.name);
|
|
35
|
+
}
|
|
36
|
+
else if (attr && attr.name === "class") {
|
|
33
37
|
const isWebComponent = attr.value.includes("hydrated");
|
|
34
38
|
const value = attr.value.replace("hydrated", "").trim();
|
|
35
39
|
const currentClass = element.getAttribute("class");
|
|
@@ -49,9 +53,10 @@ const DBCard = class {
|
|
|
49
53
|
this.enableAttributePassing(this._ref, "db-card");
|
|
50
54
|
}
|
|
51
55
|
render() {
|
|
52
|
-
|
|
56
|
+
var _a, _b;
|
|
57
|
+
return (index.h("div", { key: 'fc177f67efe5de971fcc6eeeb069473788988c1a', class: index$1.cls("db-card", this.className), ref: (el) => {
|
|
53
58
|
this._ref = el;
|
|
54
|
-
}, id: this.id, "data-behavior": this.behavior, "data-elevation-level": this.elevationLevel, "data-spacing": this.spacing, onClick: (event) => this.handleClick(event) }, index.h("slot", { key: '
|
|
59
|
+
}, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-behavior": this.behavior, "data-elevation-level": this.elevationLevel, "data-spacing": this.spacing, onClick: (event) => this.handleClick(event) }, index.h("slot", { key: 'cffa2e7b3427e279ef5ae1b3d00ff923e5c819c6' })));
|
|
55
60
|
}
|
|
56
61
|
};
|
|
57
62
|
|
|
@@ -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 DBCheckbox = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -71,6 +71,14 @@ const DBCheckbox = class {
|
|
|
71
71
|
this.focus.emit(event);
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
+
resetIds() {
|
|
75
|
+
var _a, _b, _c;
|
|
76
|
+
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 : `checkbox-${index$1.uuid()}`;
|
|
77
|
+
this._id = mId;
|
|
78
|
+
this._messageId = mId + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
79
|
+
this._validMessageId = mId + constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX;
|
|
80
|
+
this._invalidMessageId = mId + constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
|
|
81
|
+
}
|
|
74
82
|
/**
|
|
75
83
|
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
76
84
|
* @param element the ref for the component
|
|
@@ -82,12 +90,16 @@ const DBCheckbox = class {
|
|
|
82
90
|
const attributes = parent.attributes;
|
|
83
91
|
for (let i = 0; i < attributes.length; i++) {
|
|
84
92
|
const attr = attributes.item(i);
|
|
85
|
-
if (attr &&
|
|
93
|
+
if (attr && attr.name !== 'data-density' &&
|
|
86
94
|
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
87
95
|
element.setAttribute(attr.name, attr.value);
|
|
88
96
|
parent.removeAttribute(attr.name);
|
|
89
97
|
}
|
|
90
|
-
if (attr && attr.name
|
|
98
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
99
|
+
element.setAttribute(attr.name, attr.value);
|
|
100
|
+
parent.removeAttribute(attr.name);
|
|
101
|
+
}
|
|
102
|
+
else if (attr && attr.name === "class") {
|
|
91
103
|
const isWebComponent = attr.value.includes("hydrated");
|
|
92
104
|
const value = attr.value.replace("hydrated", "").trim();
|
|
93
105
|
const currentClass = element.getAttribute("class");
|
|
@@ -104,16 +116,25 @@ const DBCheckbox = class {
|
|
|
104
116
|
}
|
|
105
117
|
}
|
|
106
118
|
watch0Fn() {
|
|
119
|
+
var _a, _b;
|
|
120
|
+
if ((_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) {
|
|
121
|
+
this.resetIds();
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
watch0() {
|
|
125
|
+
this.watch0Fn();
|
|
126
|
+
}
|
|
127
|
+
watch1Fn() {
|
|
107
128
|
var _a;
|
|
108
129
|
this._invalidMessage =
|
|
109
130
|
this.invalidMessage ||
|
|
110
131
|
((_a = this._ref) === null || _a === void 0 ? void 0 : _a.validationMessage) ||
|
|
111
132
|
constants.DEFAULT_INVALID_MESSAGE;
|
|
112
133
|
}
|
|
113
|
-
|
|
114
|
-
this.
|
|
134
|
+
watch1() {
|
|
135
|
+
this.watch1Fn();
|
|
115
136
|
}
|
|
116
|
-
|
|
137
|
+
watch2Fn() {
|
|
117
138
|
if (this._id) {
|
|
118
139
|
const messageId = this._id + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
119
140
|
this._messageId = messageId;
|
|
@@ -125,10 +146,10 @@ const DBCheckbox = class {
|
|
|
125
146
|
this.handleValidation();
|
|
126
147
|
}
|
|
127
148
|
}
|
|
128
|
-
|
|
129
|
-
this.
|
|
149
|
+
watch2() {
|
|
150
|
+
this.watch2Fn();
|
|
130
151
|
}
|
|
131
|
-
|
|
152
|
+
watch3Fn() {
|
|
132
153
|
if (this._ref) {
|
|
133
154
|
if (this.indeterminate !== undefined) {
|
|
134
155
|
// When indeterminate is set, the value of the checked prop only impacts the form submitted values.
|
|
@@ -137,10 +158,10 @@ const DBCheckbox = class {
|
|
|
137
158
|
}
|
|
138
159
|
}
|
|
139
160
|
}
|
|
140
|
-
|
|
141
|
-
this.
|
|
161
|
+
watch3() {
|
|
162
|
+
this.watch3Fn();
|
|
142
163
|
}
|
|
143
|
-
|
|
164
|
+
watch4Fn() {
|
|
144
165
|
if (this.initialized && this._ref) {
|
|
145
166
|
// in angular this must be set via native element
|
|
146
167
|
if (this.checked != undefined) {
|
|
@@ -149,10 +170,10 @@ const DBCheckbox = class {
|
|
|
149
170
|
this.initialized = false;
|
|
150
171
|
}
|
|
151
172
|
}
|
|
152
|
-
|
|
153
|
-
this.
|
|
173
|
+
watch4() {
|
|
174
|
+
this.watch4Fn();
|
|
154
175
|
}
|
|
155
|
-
|
|
176
|
+
watch5Fn() {
|
|
156
177
|
if (this._ref) {
|
|
157
178
|
const defaultChecked = undefined;
|
|
158
179
|
let controller = this.abortController;
|
|
@@ -168,24 +189,20 @@ const DBCheckbox = class {
|
|
|
168
189
|
}, controller.signal);
|
|
169
190
|
}
|
|
170
191
|
}
|
|
171
|
-
|
|
172
|
-
this.
|
|
192
|
+
watch5() {
|
|
193
|
+
this.watch5Fn();
|
|
173
194
|
}
|
|
174
195
|
componentDidLoad() {
|
|
175
|
-
var _a;
|
|
176
196
|
this.enableAttributePassing(this._ref, "db-checkbox");
|
|
177
197
|
this.initialized = true;
|
|
178
|
-
|
|
179
|
-
this._id = mId;
|
|
180
|
-
this._messageId = mId + constants.DEFAULT_MESSAGE_ID_SUFFIX;
|
|
181
|
-
this._validMessageId = mId + constants.DEFAULT_VALID_MESSAGE_ID_SUFFIX;
|
|
182
|
-
this._invalidMessageId = mId + constants.DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
|
|
198
|
+
this.resetIds();
|
|
183
199
|
this._invalidMessage = this.invalidMessage || constants.DEFAULT_INVALID_MESSAGE;
|
|
184
200
|
this.watch0Fn();
|
|
185
201
|
this.watch1Fn();
|
|
186
202
|
this.watch2Fn();
|
|
187
203
|
this.watch3Fn();
|
|
188
204
|
this.watch4Fn();
|
|
205
|
+
this.watch5Fn();
|
|
189
206
|
}
|
|
190
207
|
disconnectedCallback() {
|
|
191
208
|
var _a;
|
|
@@ -193,36 +210,42 @@ const DBCheckbox = class {
|
|
|
193
210
|
}
|
|
194
211
|
render() {
|
|
195
212
|
var _a;
|
|
196
|
-
return (index.h("div", { key: '
|
|
213
|
+
return (index.h("div", { key: '433618f3dbf837b2b8febeb5b3acd77b0cebbc24', class: index$1.cls("db-checkbox", this.className), "data-size": this.size, "data-hide-asterisk": index$1.getHideProp(this.showRequiredAsterisk), "data-hide-label": index$1.getHideProp(this.showLabel) }, index.h("label", { key: '02b767c372314a2dc32b90fec28a0a2d4caa67c1', htmlFor: this._id }, index.h("input", { key: '1fc78fbb4079f69ed7bde43097ff3125ec67edf9', type: "checkbox", "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
|
|
197
214
|
this._ref = el;
|
|
198
|
-
}, id: this._id, name: this.name, checked: index$1.getBoolean(this.checked, "checked"), disabled: index$1.getBoolean(this.disabled, "disabled"), value: this.value, required: index$1.getBoolean(this.required, "required"), onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event), "aria-describedby": (_a = this.ariaDescribedBy) !== null && _a !== void 0 ? _a : this._descByIds }), this.label ? this.label : index.h("slot", 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: '
|
|
215
|
+
}, id: this._id, name: this.name, checked: index$1.getBoolean(this.checked, "checked"), disabled: index$1.getBoolean(this.disabled, "disabled"), value: this.value, required: index$1.getBoolean(this.required, "required"), onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event), "aria-describedby": (_a = this.ariaDescribedBy) !== null && _a !== void 0 ? _a : this._descByIds }), this.label ? this.label : index.h("slot", 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: '1bc15384adefeb0a9749ebe60ee8e130e9258321', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), index.h("span", { key: '9daadc858ce041949b5470e6914c2c22f5a2918e', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
|
|
199
216
|
}
|
|
200
217
|
static get watchers() { return {
|
|
201
|
-
"
|
|
218
|
+
"id": [{
|
|
202
219
|
"watch0": 0
|
|
203
|
-
},
|
|
204
|
-
|
|
220
|
+
}],
|
|
221
|
+
"propOverrides?.id": [{
|
|
222
|
+
"watch0": 0
|
|
223
|
+
}],
|
|
224
|
+
"_ref": [{
|
|
225
|
+
"watch1": 0
|
|
205
226
|
}, {
|
|
206
227
|
"watch3": 0
|
|
207
228
|
}, {
|
|
208
229
|
"watch4": 0
|
|
230
|
+
}, {
|
|
231
|
+
"watch5": 0
|
|
209
232
|
}],
|
|
210
233
|
"invalidMessage": [{
|
|
211
|
-
"
|
|
234
|
+
"watch1": 0
|
|
212
235
|
}],
|
|
213
236
|
"_id": [{
|
|
214
|
-
"
|
|
237
|
+
"watch2": 0
|
|
215
238
|
}],
|
|
216
239
|
"initialized": [{
|
|
217
|
-
"watch2": 0
|
|
218
|
-
}, {
|
|
219
240
|
"watch3": 0
|
|
241
|
+
}, {
|
|
242
|
+
"watch4": 0
|
|
220
243
|
}],
|
|
221
244
|
"indeterminate": [{
|
|
222
|
-
"
|
|
245
|
+
"watch3": 0
|
|
223
246
|
}],
|
|
224
247
|
"checked": [{
|
|
225
|
-
"
|
|
248
|
+
"watch4": 0
|
|
226
249
|
}]
|
|
227
250
|
}; }
|
|
228
251
|
};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var index = require('./index-CSMPhlzz.js');
|
|
4
|
+
var index$1 = require('./index-2_9ESkQu.js');
|
|
5
|
+
|
|
6
|
+
const DBCustomButton = class {
|
|
7
|
+
constructor(hostRef) {
|
|
8
|
+
index.registerInstance(this, hostRef);
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
12
|
+
* @param element the ref for the component
|
|
13
|
+
* @param customElementSelector the custom element like `my-component`
|
|
14
|
+
*/
|
|
15
|
+
enableAttributePassing(element, customElementSelector) {
|
|
16
|
+
const parent = element === null || element === void 0 ? void 0 : element.closest(customElementSelector);
|
|
17
|
+
if (element && parent) {
|
|
18
|
+
const attributes = parent.attributes;
|
|
19
|
+
for (let i = 0; i < attributes.length; i++) {
|
|
20
|
+
const attr = attributes.item(i);
|
|
21
|
+
if (attr && attr.name !== 'data-density' &&
|
|
22
|
+
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
23
|
+
element.setAttribute(attr.name, attr.value);
|
|
24
|
+
parent.removeAttribute(attr.name);
|
|
25
|
+
}
|
|
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") {
|
|
31
|
+
const isWebComponent = attr.value.includes("hydrated");
|
|
32
|
+
const value = attr.value.replace("hydrated", "").trim();
|
|
33
|
+
const currentClass = element.getAttribute("class");
|
|
34
|
+
element.setAttribute(attr.name, `${currentClass ? `${currentClass} ` : ""}${value}`);
|
|
35
|
+
if (isWebComponent) {
|
|
36
|
+
// Stencil is using this class for lazy loading component
|
|
37
|
+
parent.setAttribute("class", "hydrated");
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
parent.removeAttribute(attr.name);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
componentDidLoad() {
|
|
47
|
+
this.enableAttributePassing(this._ref, "db-custom-button");
|
|
48
|
+
}
|
|
49
|
+
render() {
|
|
50
|
+
var _a, _b, _c, _d;
|
|
51
|
+
return (index.h("div", { key: 'ee954dad8cd0baff52172a1ec9553c43673d0fa4', class: index$1.cls("db-custom-button", this.className), ref: (el) => {
|
|
52
|
+
this._ref = el;
|
|
53
|
+
}, id: (_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-show-icon": index$1.getBooleanAsString((_d = this.showIconLeading) !== null && _d !== void 0 ? _d : this.showIcon), "data-icon-trailing": this.iconTrailing, "data-show-icon-trailing": index$1.getBooleanAsString(this.showIconTrailing), "data-size": this.size, "data-width": this.width, "data-variant": this.variant, "data-no-text": index$1.getBooleanAsString(this.noText) }, index.h("slot", { key: 'accbe2a436c60ecb945aea8b008453e3a264fd2b' })));
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
exports.db_custom_button = DBCustomButton;
|