@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.
Files changed (255) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/cjs/db-accordion-item.cjs.entry.js +11 -6
  3. package/dist/cjs/db-accordion.cjs.entry.js +12 -8
  4. package/dist/cjs/db-badge.cjs.entry.js +11 -7
  5. package/dist/cjs/db-brand.cjs.entry.js +11 -7
  6. package/dist/cjs/db-button.cjs.entry.js +11 -7
  7. package/dist/cjs/db-card.cjs.entry.js +11 -6
  8. package/dist/cjs/db-checkbox.cjs.entry.js +59 -36
  9. package/dist/cjs/db-custom-button.cjs.entry.js +57 -0
  10. package/dist/cjs/db-custom-select-dropdown_5.cjs.entry.js +89 -47
  11. package/dist/cjs/db-custom-select-form-field.cjs.entry.js +11 -6
  12. package/dist/cjs/db-custom-select.cjs.entry.js +133 -110
  13. package/dist/cjs/db-divider.cjs.entry.js +11 -6
  14. package/dist/cjs/db-drawer.cjs.entry.js +12 -8
  15. package/dist/cjs/db-header.cjs.entry.js +13 -9
  16. package/dist/cjs/db-icon.cjs.entry.js +11 -6
  17. package/dist/cjs/db-infotext.cjs.entry.js +11 -7
  18. package/dist/cjs/db-link.cjs.entry.js +11 -7
  19. package/dist/cjs/db-navigation-item.cjs.entry.js +13 -9
  20. package/dist/cjs/db-navigation.cjs.entry.js +11 -6
  21. package/dist/cjs/db-notification.cjs.entry.js +12 -8
  22. package/dist/cjs/db-page.cjs.entry.js +11 -6
  23. package/dist/cjs/db-popover.cjs.entry.js +14 -10
  24. package/dist/cjs/db-radio.cjs.entry.js +39 -16
  25. package/dist/cjs/db-section.cjs.entry.js +11 -6
  26. package/dist/cjs/db-select.cjs.entry.js +54 -31
  27. package/dist/cjs/db-stack.cjs.entry.js +11 -6
  28. package/dist/cjs/db-switch.cjs.entry.js +64 -24
  29. package/dist/cjs/db-tab-item_3.cjs.entry.js +29 -15
  30. package/dist/cjs/db-tabs.cjs.entry.js +12 -8
  31. package/dist/cjs/db-textarea.cjs.entry.js +52 -29
  32. package/dist/cjs/db-tooltip.cjs.entry.js +25 -12
  33. package/dist/cjs/db-ux.cjs.js +3 -3
  34. package/dist/cjs/{document-click-listener-Bb3Tinb8.js → document-click-listener-B2-xKJv3.js} +1 -1
  35. package/dist/cjs/{document-scroll-listener-unypEU42.js → document-scroll-listener-ChQ7XZRk.js} +1 -1
  36. package/dist/cjs/{floating-components-ogUqz72V.js → floating-components-pYaTeNhp.js} +65 -15
  37. package/dist/cjs/{form-components-LsqVohyb.js → form-components-_ncB_U2D.js} +1 -1
  38. package/dist/cjs/{index-CsHqnQII.js → index-2_9ESkQu.js} +6 -7
  39. package/dist/cjs/{index-CEqZnn9s.js → index-CSMPhlzz.js} +2 -2
  40. package/dist/cjs/index.cjs.js +5 -5
  41. package/dist/cjs/loader.cjs.js +2 -2
  42. package/dist/cjs/{navigation-DauGE-qj.js → navigation-BztJmEHf.js} +1 -1
  43. package/dist/collection/collection-manifest.json +2 -1
  44. package/dist/collection/components/accordion/accordion.js +34 -6
  45. package/dist/collection/components/accordion-item/accordion-item.js +33 -4
  46. package/dist/collection/components/badge/badge.js +60 -6
  47. package/dist/collection/components/brand/brand.js +33 -5
  48. package/dist/collection/components/button/button.js +59 -5
  49. package/dist/collection/components/card/card.js +33 -4
  50. package/dist/collection/components/checkbox/checkbox.js +87 -40
  51. package/dist/collection/components/custom-button/custom-button.js +394 -0
  52. package/dist/collection/components/custom-button/index.js +2 -0
  53. package/dist/collection/components/custom-button/model.js +1 -0
  54. package/dist/collection/components/custom-select/custom-select.js +157 -110
  55. package/dist/collection/components/custom-select-dropdown/custom-select-dropdown.js +33 -4
  56. package/dist/collection/components/custom-select-form-field/custom-select-form-field.js +33 -4
  57. package/dist/collection/components/custom-select-list/custom-select-list.js +33 -4
  58. package/dist/collection/components/custom-select-list-item/custom-select-list-item.js +33 -4
  59. package/dist/collection/components/divider/divider.js +33 -4
  60. package/dist/collection/components/drawer/drawer.js +34 -6
  61. package/dist/collection/components/header/header.js +33 -5
  62. package/dist/collection/components/icon/icon.js +33 -4
  63. package/dist/collection/components/infotext/infotext.js +59 -5
  64. package/dist/collection/components/input/input.js +80 -33
  65. package/dist/collection/components/link/link.js +33 -5
  66. package/dist/collection/components/navigation/navigation.js +33 -4
  67. package/dist/collection/components/navigation-item/navigation-item.js +33 -5
  68. package/dist/collection/components/notification/notification.js +34 -6
  69. package/dist/collection/components/page/page.js +33 -4
  70. package/dist/collection/components/popover/popover.js +34 -6
  71. package/dist/collection/components/radio/radio.js +60 -13
  72. package/dist/collection/components/section/section.js +33 -4
  73. package/dist/collection/components/select/select.js +81 -34
  74. package/dist/collection/components/stack/stack.js +33 -4
  75. package/dist/collection/components/switch/switch.js +118 -50
  76. package/dist/collection/components/tab-item/tab-item.js +33 -5
  77. package/dist/collection/components/tab-list/tab-list.js +33 -4
  78. package/dist/collection/components/tab-panel/tab-panel.js +33 -4
  79. package/dist/collection/components/tabs/tabs.js +34 -6
  80. package/dist/collection/components/tag/tag.js +33 -5
  81. package/dist/collection/components/textarea/textarea.js +79 -32
  82. package/dist/collection/components/tooltip/tooltip.js +71 -8
  83. package/dist/collection/index.js +2 -0
  84. package/dist/collection/utils/floating-components.js +65 -15
  85. package/dist/collection/utils/index.js +6 -7
  86. package/dist/custom-elements.json +19735 -1796
  87. package/dist/db-ux/db-ux.esm.js +1 -1
  88. package/dist/db-ux/index.esm.js +1 -1
  89. package/dist/db-ux/p-00df7d53.entry.js +1 -0
  90. package/dist/db-ux/p-064ddad6.entry.js +1 -0
  91. package/dist/db-ux/p-0ff173fb.entry.js +1 -0
  92. package/dist/db-ux/p-1519dbbb.entry.js +1 -0
  93. package/dist/db-ux/p-16281dcb.entry.js +1 -0
  94. package/dist/db-ux/p-27eb6e88.entry.js +1 -0
  95. package/dist/db-ux/p-2898ebe6.entry.js +1 -0
  96. package/dist/db-ux/p-2e940d2e.entry.js +1 -0
  97. package/dist/db-ux/p-309259be.entry.js +1 -0
  98. package/dist/db-ux/p-4183b8e1.entry.js +1 -0
  99. package/dist/db-ux/p-4284c37f.entry.js +1 -0
  100. package/dist/db-ux/p-432ceb90.entry.js +1 -0
  101. package/dist/db-ux/p-503d5103.entry.js +1 -0
  102. package/dist/db-ux/p-6794144b.entry.js +1 -0
  103. package/dist/db-ux/p-6cb4232d.entry.js +1 -0
  104. package/dist/db-ux/p-6da70f61.entry.js +1 -0
  105. package/dist/db-ux/p-766057ea.entry.js +1 -0
  106. package/dist/db-ux/p-7a146dee.entry.js +1 -0
  107. package/dist/db-ux/p-7e274359.entry.js +1 -0
  108. package/dist/db-ux/p-Bs7RfNRP.js +2 -0
  109. package/dist/db-ux/p-CHLgQ9vn.js +1 -0
  110. package/dist/db-ux/{p-CAEpg8tJ.js → p-D5mInaY7.js} +1 -1
  111. package/dist/db-ux/p-D_roHmuC.js +1 -0
  112. package/dist/db-ux/p-DfYL98sI.js +1 -0
  113. package/dist/db-ux/p-aad9c604.entry.js +1 -0
  114. package/dist/db-ux/p-ad3d2cff.entry.js +1 -0
  115. package/dist/db-ux/p-b218b08b.entry.js +1 -0
  116. package/dist/db-ux/p-bfe27311.entry.js +1 -0
  117. package/dist/db-ux/p-c1cf7ea4.entry.js +1 -0
  118. package/dist/db-ux/{p-sP2NlPcu.js → p-cNk4ImpW.js} +1 -1
  119. package/dist/db-ux/p-cd8557dd.entry.js +1 -0
  120. package/dist/db-ux/p-d2674cff.entry.js +1 -0
  121. package/dist/db-ux/p-d4e79c33.entry.js +1 -0
  122. package/dist/db-ux/p-e19f2640.entry.js +1 -0
  123. package/dist/db-ux/p-e3def528.entry.js +1 -0
  124. package/dist/db-ux/p-e6b17374.entry.js +1 -0
  125. package/dist/db-ux/p-ea7219af.entry.js +1 -0
  126. package/dist/db-ux/p-xkoBSP8R.js +1 -0
  127. package/dist/esm/db-accordion-item.entry.js +11 -6
  128. package/dist/esm/db-accordion.entry.js +12 -8
  129. package/dist/esm/db-badge.entry.js +11 -7
  130. package/dist/esm/db-brand.entry.js +11 -7
  131. package/dist/esm/db-button.entry.js +11 -7
  132. package/dist/esm/db-card.entry.js +11 -6
  133. package/dist/esm/db-checkbox.entry.js +60 -37
  134. package/dist/esm/db-custom-button.entry.js +55 -0
  135. package/dist/esm/db-custom-select-dropdown_5.entry.js +90 -48
  136. package/dist/esm/db-custom-select-form-field.entry.js +11 -6
  137. package/dist/esm/db-custom-select.entry.js +134 -111
  138. package/dist/esm/db-divider.entry.js +11 -6
  139. package/dist/esm/db-drawer.entry.js +12 -8
  140. package/dist/esm/db-header.entry.js +13 -9
  141. package/dist/esm/db-icon.entry.js +11 -6
  142. package/dist/esm/db-infotext.entry.js +11 -7
  143. package/dist/esm/db-link.entry.js +11 -7
  144. package/dist/esm/db-navigation-item.entry.js +13 -9
  145. package/dist/esm/db-navigation.entry.js +11 -6
  146. package/dist/esm/db-notification.entry.js +12 -8
  147. package/dist/esm/db-page.entry.js +11 -6
  148. package/dist/esm/db-popover.entry.js +14 -10
  149. package/dist/esm/db-radio.entry.js +39 -16
  150. package/dist/esm/db-section.entry.js +11 -6
  151. package/dist/esm/db-select.entry.js +55 -32
  152. package/dist/esm/db-stack.entry.js +11 -6
  153. package/dist/esm/db-switch.entry.js +64 -24
  154. package/dist/esm/db-tab-item_3.entry.js +29 -15
  155. package/dist/esm/db-tabs.entry.js +12 -8
  156. package/dist/esm/db-textarea.entry.js +53 -30
  157. package/dist/esm/db-tooltip.entry.js +25 -12
  158. package/dist/esm/db-ux.js +4 -4
  159. package/dist/esm/{document-click-listener-CmYoXpGE.js → document-click-listener-D7W_VE5O.js} +1 -1
  160. package/dist/esm/{document-scroll-listener-65bHuFAN.js → document-scroll-listener-DOBe3Oa9.js} +1 -1
  161. package/dist/esm/{floating-components-G-TursYV.js → floating-components-DfYL98sI.js} +65 -15
  162. package/dist/esm/{form-components-BLsiOrPI.js → form-components-D6LQfJvq.js} +1 -1
  163. package/dist/esm/{index-BrThqi62.js → index-Bs7RfNRP.js} +2 -2
  164. package/dist/esm/{index-C4x0SOcx.js → index-xkoBSP8R.js} +6 -7
  165. package/dist/esm/index.js +5 -5
  166. package/dist/esm/loader.js +3 -3
  167. package/dist/esm/{navigation--UdC9CzO.js → navigation-DgsMCdfn.js} +1 -1
  168. package/dist/types/components/accordion/accordion.d.ts +1 -0
  169. package/dist/types/components/accordion-item/accordion-item.d.ts +1 -0
  170. package/dist/types/components/badge/badge.d.ts +2 -0
  171. package/dist/types/components/badge/model.d.ts +2 -2
  172. package/dist/types/components/brand/brand.d.ts +1 -0
  173. package/dist/types/components/button/button.d.ts +2 -0
  174. package/dist/types/components/button/model.d.ts +8 -10
  175. package/dist/types/components/card/card.d.ts +1 -0
  176. package/dist/types/components/checkbox/checkbox.d.ts +5 -1
  177. package/dist/types/components/custom-button/custom-button.d.ts +29 -0
  178. package/dist/types/components/custom-button/index.d.ts +2 -0
  179. package/dist/types/components/custom-button/model.d.ts +6 -0
  180. package/dist/types/components/custom-select/custom-select.d.ts +5 -1
  181. package/dist/types/components/custom-select-dropdown/custom-select-dropdown.d.ts +1 -0
  182. package/dist/types/components/custom-select-form-field/custom-select-form-field.d.ts +1 -0
  183. package/dist/types/components/custom-select-list/custom-select-list.d.ts +1 -0
  184. package/dist/types/components/custom-select-list-item/custom-select-list-item.d.ts +1 -0
  185. package/dist/types/components/divider/divider.d.ts +1 -0
  186. package/dist/types/components/drawer/drawer.d.ts +1 -0
  187. package/dist/types/components/header/header.d.ts +1 -0
  188. package/dist/types/components/icon/icon.d.ts +1 -0
  189. package/dist/types/components/infotext/infotext.d.ts +2 -0
  190. package/dist/types/components/infotext/model.d.ts +2 -2
  191. package/dist/types/components/input/input.d.ts +5 -1
  192. package/dist/types/components/link/link.d.ts +1 -0
  193. package/dist/types/components/navigation/navigation.d.ts +1 -0
  194. package/dist/types/components/navigation-item/navigation-item.d.ts +1 -0
  195. package/dist/types/components/notification/model.d.ts +2 -2
  196. package/dist/types/components/notification/notification.d.ts +1 -0
  197. package/dist/types/components/page/page.d.ts +1 -0
  198. package/dist/types/components/popover/popover.d.ts +1 -0
  199. package/dist/types/components/radio/radio.d.ts +4 -0
  200. package/dist/types/components/section/section.d.ts +1 -0
  201. package/dist/types/components/select/select.d.ts +5 -1
  202. package/dist/types/components/stack/stack.d.ts +1 -0
  203. package/dist/types/components/switch/model.d.ts +1 -1
  204. package/dist/types/components/switch/switch.d.ts +7 -1
  205. package/dist/types/components/tab-item/tab-item.d.ts +1 -0
  206. package/dist/types/components/tab-list/tab-list.d.ts +1 -0
  207. package/dist/types/components/tab-panel/tab-panel.d.ts +1 -0
  208. package/dist/types/components/tabs/tabs.d.ts +1 -0
  209. package/dist/types/components/tag/model.d.ts +2 -6
  210. package/dist/types/components/tag/tag.d.ts +1 -0
  211. package/dist/types/components/textarea/textarea.d.ts +5 -1
  212. package/dist/types/components/tooltip/model.d.ts +3 -3
  213. package/dist/types/components/tooltip/tooltip.d.ts +3 -0
  214. package/dist/types/components.d.ts +146 -6
  215. package/dist/types/index.d.ts +2 -0
  216. package/dist/types/shared/model.d.ts +17 -3
  217. package/dist/types/stencil-public-runtime.d.ts +3 -1
  218. package/dist/vscode.html-custom-data.json +1981 -245
  219. package/dist/web-types.json +3299 -648
  220. package/package.json +4 -4
  221. package/dist/db-ux/p-07bf3657.entry.js +0 -1
  222. package/dist/db-ux/p-0a89cbcd.entry.js +0 -1
  223. package/dist/db-ux/p-15539d9d.entry.js +0 -1
  224. package/dist/db-ux/p-41cb4673.entry.js +0 -1
  225. package/dist/db-ux/p-460073dd.entry.js +0 -1
  226. package/dist/db-ux/p-4a9b9909.entry.js +0 -1
  227. package/dist/db-ux/p-4ec09cf1.entry.js +0 -1
  228. package/dist/db-ux/p-57205dfd.entry.js +0 -1
  229. package/dist/db-ux/p-5775bf7a.entry.js +0 -1
  230. package/dist/db-ux/p-5bcde39a.entry.js +0 -1
  231. package/dist/db-ux/p-6341aaa9.entry.js +0 -1
  232. package/dist/db-ux/p-64573104.entry.js +0 -1
  233. package/dist/db-ux/p-6b63156d.entry.js +0 -1
  234. package/dist/db-ux/p-70822a27.entry.js +0 -1
  235. package/dist/db-ux/p-710a430d.entry.js +0 -1
  236. package/dist/db-ux/p-72d712b0.entry.js +0 -1
  237. package/dist/db-ux/p-7b7f4d03.entry.js +0 -1
  238. package/dist/db-ux/p-7bd4c573.entry.js +0 -1
  239. package/dist/db-ux/p-819cf20a.entry.js +0 -1
  240. package/dist/db-ux/p-87fdbcfb.entry.js +0 -1
  241. package/dist/db-ux/p-9051e26c.entry.js +0 -1
  242. package/dist/db-ux/p-934a708c.entry.js +0 -1
  243. package/dist/db-ux/p-9ffa5c48.entry.js +0 -1
  244. package/dist/db-ux/p-BhXdfCpU.js +0 -1
  245. package/dist/db-ux/p-BrThqi62.js +0 -2
  246. package/dist/db-ux/p-C4x0SOcx.js +0 -1
  247. package/dist/db-ux/p-G-TursYV.js +0 -1
  248. package/dist/db-ux/p-RHqkTr-_.js +0 -1
  249. package/dist/db-ux/p-a9af70eb.entry.js +0 -1
  250. package/dist/db-ux/p-aa8383a3.entry.js +0 -1
  251. package/dist/db-ux/p-ba1f69bd.entry.js +0 -1
  252. package/dist/db-ux/p-d273b998.entry.js +0 -1
  253. package/dist/db-ux/p-da4ee6ee.entry.js +0 -1
  254. package/dist/db-ux/p-e584e927.entry.js +0 -1
  255. package/dist/db-ux/p-fe185f98.entry.js +0 -1
@@ -21,12 +21,16 @@ export class DBCard {
21
21
  const attributes = parent.attributes;
22
22
  for (let i = 0; i < attributes.length; i++) {
23
23
  const attr = attributes.item(i);
24
- if (attr &&
24
+ if (attr && attr.name !== 'data-density' &&
25
25
  (attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
26
26
  element.setAttribute(attr.name, attr.value);
27
27
  parent.removeAttribute(attr.name);
28
28
  }
29
- if (attr && attr.name === "class") {
29
+ else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
30
+ element.setAttribute(attr.name, attr.value);
31
+ parent.removeAttribute(attr.name);
32
+ }
33
+ else if (attr && attr.name === "class") {
30
34
  const isWebComponent = attr.value.includes("hydrated");
31
35
  const value = attr.value.replace("hydrated", "").trim();
32
36
  const currentClass = element.getAttribute("class");
@@ -46,9 +50,10 @@ export class DBCard {
46
50
  this.enableAttributePassing(this._ref, "db-card");
47
51
  }
48
52
  render() {
49
- return (h("div", { key: '823ca29890a1a4f29f4ff4f7bb1829e77314546b', class: cls("db-card", this.className), ref: (el) => {
53
+ var _a, _b;
54
+ return (h("div", { key: 'fc177f67efe5de971fcc6eeeb069473788988c1a', class: cls("db-card", this.className), ref: (el) => {
50
55
  this._ref = el;
51
- }, id: this.id, "data-behavior": this.behavior, "data-elevation-level": this.elevationLevel, "data-spacing": this.spacing, onClick: (event) => this.handleClick(event) }, h("slot", { key: '532b03614fa83513efc8f97b6a9a7faceff62039' })));
56
+ }, 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) }, h("slot", { key: 'cffa2e7b3427e279ef5ae1b3d00ff923e5c819c6' })));
52
57
  }
53
58
  static get is() { return "db-card"; }
54
59
  static get properties() {
@@ -79,6 +84,30 @@ export class DBCard {
79
84
  "reflect": false,
80
85
  "attribute": "id"
81
86
  },
87
+ "propOverrides": {
88
+ "type": "unknown",
89
+ "mutable": false,
90
+ "complexType": {
91
+ "original": "DBCardProps[\"propOverrides\"]",
92
+ "resolved": "{ id?: string; }",
93
+ "references": {
94
+ "DBCardProps": {
95
+ "location": "import",
96
+ "path": "./model",
97
+ "id": "src/components/card/model.ts::DBCardProps",
98
+ "referenceLocation": "DBCardProps"
99
+ }
100
+ }
101
+ },
102
+ "required": false,
103
+ "optional": false,
104
+ "docs": {
105
+ "tags": [],
106
+ "text": ""
107
+ },
108
+ "getter": false,
109
+ "setter": false
110
+ },
82
111
  "className": {
83
112
  "type": "string",
84
113
  "mutable": false,
@@ -68,6 +68,14 @@ export class DBCheckbox {
68
68
  this.focus.emit(event);
69
69
  }
70
70
  }
71
+ resetIds() {
72
+ var _a, _b, _c;
73
+ 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-${uuid()}`;
74
+ this._id = mId;
75
+ this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;
76
+ this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;
77
+ this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
78
+ }
71
79
  /**
72
80
  * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
73
81
  * @param element the ref for the component
@@ -79,12 +87,16 @@ export class DBCheckbox {
79
87
  const attributes = parent.attributes;
80
88
  for (let i = 0; i < attributes.length; i++) {
81
89
  const attr = attributes.item(i);
82
- if (attr &&
90
+ if (attr && attr.name !== 'data-density' &&
83
91
  (attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
84
92
  element.setAttribute(attr.name, attr.value);
85
93
  parent.removeAttribute(attr.name);
86
94
  }
87
- if (attr && attr.name === "class") {
95
+ else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
96
+ element.setAttribute(attr.name, attr.value);
97
+ parent.removeAttribute(attr.name);
98
+ }
99
+ else if (attr && attr.name === "class") {
88
100
  const isWebComponent = attr.value.includes("hydrated");
89
101
  const value = attr.value.replace("hydrated", "").trim();
90
102
  const currentClass = element.getAttribute("class");
@@ -101,16 +113,25 @@ export class DBCheckbox {
101
113
  }
102
114
  }
103
115
  watch0Fn() {
116
+ var _a, _b;
117
+ if ((_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id) {
118
+ this.resetIds();
119
+ }
120
+ }
121
+ watch0() {
122
+ this.watch0Fn();
123
+ }
124
+ watch1Fn() {
104
125
  var _a;
105
126
  this._invalidMessage =
106
127
  this.invalidMessage ||
107
128
  ((_a = this._ref) === null || _a === void 0 ? void 0 : _a.validationMessage) ||
108
129
  DEFAULT_INVALID_MESSAGE;
109
130
  }
110
- watch0() {
111
- this.watch0Fn();
131
+ watch1() {
132
+ this.watch1Fn();
112
133
  }
113
- watch1Fn() {
134
+ watch2Fn() {
114
135
  if (this._id) {
115
136
  const messageId = this._id + DEFAULT_MESSAGE_ID_SUFFIX;
116
137
  this._messageId = messageId;
@@ -122,10 +143,10 @@ export class DBCheckbox {
122
143
  this.handleValidation();
123
144
  }
124
145
  }
125
- watch1() {
126
- this.watch1Fn();
146
+ watch2() {
147
+ this.watch2Fn();
127
148
  }
128
- watch2Fn() {
149
+ watch3Fn() {
129
150
  if (this._ref) {
130
151
  if (this.indeterminate !== undefined) {
131
152
  // When indeterminate is set, the value of the checked prop only impacts the form submitted values.
@@ -134,10 +155,10 @@ export class DBCheckbox {
134
155
  }
135
156
  }
136
157
  }
137
- watch2() {
138
- this.watch2Fn();
158
+ watch3() {
159
+ this.watch3Fn();
139
160
  }
140
- watch3Fn() {
161
+ watch4Fn() {
141
162
  if (this.initialized && this._ref) {
142
163
  // in angular this must be set via native element
143
164
  if (this.checked != undefined) {
@@ -146,10 +167,10 @@ export class DBCheckbox {
146
167
  this.initialized = false;
147
168
  }
148
169
  }
149
- watch3() {
150
- this.watch3Fn();
170
+ watch4() {
171
+ this.watch4Fn();
151
172
  }
152
- watch4Fn() {
173
+ watch5Fn() {
153
174
  if (this._ref) {
154
175
  const defaultChecked = undefined;
155
176
  let controller = this.abortController;
@@ -165,24 +186,20 @@ export class DBCheckbox {
165
186
  }, controller.signal);
166
187
  }
167
188
  }
168
- watch4() {
169
- this.watch4Fn();
189
+ watch5() {
190
+ this.watch5Fn();
170
191
  }
171
192
  componentDidLoad() {
172
- var _a;
173
193
  this.enableAttributePassing(this._ref, "db-checkbox");
174
194
  this.initialized = true;
175
- const mId = (_a = this.id) !== null && _a !== void 0 ? _a : `checkbox-${uuid()}`;
176
- this._id = mId;
177
- this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;
178
- this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;
179
- this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;
195
+ this.resetIds();
180
196
  this._invalidMessage = this.invalidMessage || DEFAULT_INVALID_MESSAGE;
181
197
  this.watch0Fn();
182
198
  this.watch1Fn();
183
199
  this.watch2Fn();
184
200
  this.watch3Fn();
185
201
  this.watch4Fn();
202
+ this.watch5Fn();
186
203
  }
187
204
  disconnectedCallback() {
188
205
  var _a;
@@ -190,18 +207,18 @@ export class DBCheckbox {
190
207
  }
191
208
  render() {
192
209
  var _a;
193
- return (h("div", { key: 'a7cda04be04a1c763f8a7aa6918a212ffe8e0003', class: cls("db-checkbox", this.className), "data-size": this.size, "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-hide-label": getHideProp(this.showLabel) }, h("label", { key: 'a3195afb100309cb33b8471025b868db5bfdc7c5', htmlFor: this._id }, h("input", { key: '937c3f7cd98f519fd8034c644491f55caafb2411', type: "checkbox", "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
210
+ return (h("div", { key: '433618f3dbf837b2b8febeb5b3acd77b0cebbc24', class: cls("db-checkbox", this.className), "data-size": this.size, "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-hide-label": getHideProp(this.showLabel) }, h("label", { key: '02b767c372314a2dc32b90fec28a0a2d4caa67c1', htmlFor: this._id }, h("input", { key: '1fc78fbb4079f69ed7bde43097ff3125ec67edf9', type: "checkbox", "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
194
211
  this._ref = el;
195
- }, id: this._id, name: this.name, checked: getBoolean(this.checked, "checked"), disabled: getBoolean(this.disabled, "disabled"), value: this.value, required: 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 : h("slot", null)), stringPropVisible(this.message, this.showMessage) ? (h("db-infotext", { size: "small", icon: this.messageIcon, id: this._messageId }, this.message)) : null, this.hasValidState() ? (h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, this.validMessage || DEFAULT_VALID_MESSAGE)) : null, h("db-infotext", { key: 'ae673ae94efc3d0abd19f8f067befebea3b3139b', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: 'e32b0d1e2647e03068b5ee09f3183b25fc82b7e7', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
212
+ }, id: this._id, name: this.name, checked: getBoolean(this.checked, "checked"), disabled: getBoolean(this.disabled, "disabled"), value: this.value, required: 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 : h("slot", null)), stringPropVisible(this.message, this.showMessage) ? (h("db-infotext", { size: "small", icon: this.messageIcon, id: this._messageId }, this.message)) : null, this.hasValidState() ? (h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, this.validMessage || DEFAULT_VALID_MESSAGE)) : null, h("db-infotext", { key: '1bc15384adefeb0a9749ebe60ee8e130e9258321', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: '9daadc858ce041949b5470e6914c2c22f5a2918e', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
196
213
  }
197
214
  static get is() { return "db-checkbox"; }
198
215
  static get properties() {
199
216
  return {
200
- "id": {
217
+ "invalidMessage": {
201
218
  "type": "string",
202
219
  "mutable": false,
203
220
  "complexType": {
204
- "original": "DBCheckboxProps[\"id\"]",
221
+ "original": "DBCheckboxProps[\"invalidMessage\"]",
205
222
  "resolved": "string",
206
223
  "references": {
207
224
  "DBCheckboxProps": {
@@ -221,13 +238,13 @@ export class DBCheckbox {
221
238
  "getter": false,
222
239
  "setter": false,
223
240
  "reflect": false,
224
- "attribute": "id"
241
+ "attribute": "invalid-message"
225
242
  },
226
- "invalidMessage": {
243
+ "id": {
227
244
  "type": "string",
228
245
  "mutable": false,
229
246
  "complexType": {
230
- "original": "DBCheckboxProps[\"invalidMessage\"]",
247
+ "original": "DBCheckboxProps[\"id\"]",
231
248
  "resolved": "string",
232
249
  "references": {
233
250
  "DBCheckboxProps": {
@@ -247,7 +264,31 @@ export class DBCheckbox {
247
264
  "getter": false,
248
265
  "setter": false,
249
266
  "reflect": false,
250
- "attribute": "invalid-message"
267
+ "attribute": "id"
268
+ },
269
+ "propOverrides": {
270
+ "type": "unknown",
271
+ "mutable": false,
272
+ "complexType": {
273
+ "original": "DBCheckboxProps[\"propOverrides\"]",
274
+ "resolved": "{ id?: string; }",
275
+ "references": {
276
+ "DBCheckboxProps": {
277
+ "location": "import",
278
+ "path": "./model",
279
+ "id": "src/components/checkbox/model.ts::DBCheckboxProps",
280
+ "referenceLocation": "DBCheckboxProps"
281
+ }
282
+ }
283
+ },
284
+ "required": false,
285
+ "optional": false,
286
+ "docs": {
287
+ "tags": [],
288
+ "text": ""
289
+ },
290
+ "getter": false,
291
+ "setter": false
251
292
  },
252
293
  "message": {
253
294
  "type": "string",
@@ -756,22 +797,19 @@ export class DBCheckbox {
756
797
  }
757
798
  static get watchers() {
758
799
  return [{
759
- "propName": "_ref",
800
+ "propName": "id",
760
801
  "methodName": "watch0"
761
802
  }, {
762
- "propName": "invalidMessage",
803
+ "propName": "propOverrides?.id",
763
804
  "methodName": "watch0"
764
805
  }, {
765
- "propName": "_id",
806
+ "propName": "_ref",
766
807
  "methodName": "watch1"
767
808
  }, {
768
- "propName": "initialized",
769
- "methodName": "watch2"
770
- }, {
771
- "propName": "_ref",
772
- "methodName": "watch2"
809
+ "propName": "invalidMessage",
810
+ "methodName": "watch1"
773
811
  }, {
774
- "propName": "indeterminate",
812
+ "propName": "_id",
775
813
  "methodName": "watch2"
776
814
  }, {
777
815
  "propName": "initialized",
@@ -780,11 +818,20 @@ export class DBCheckbox {
780
818
  "propName": "_ref",
781
819
  "methodName": "watch3"
782
820
  }, {
783
- "propName": "checked",
821
+ "propName": "indeterminate",
784
822
  "methodName": "watch3"
823
+ }, {
824
+ "propName": "initialized",
825
+ "methodName": "watch4"
785
826
  }, {
786
827
  "propName": "_ref",
787
828
  "methodName": "watch4"
829
+ }, {
830
+ "propName": "checked",
831
+ "methodName": "watch4"
832
+ }, {
833
+ "propName": "_ref",
834
+ "methodName": "watch5"
788
835
  }];
789
836
  }
790
837
  }