@db-ux/wc-core-components 4.7.0-tabs-34782eb → 4.7.1

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 (168) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/agent/Tabs.md +30 -30
  3. package/dist/cjs/db-accordion-item.cjs.entry.js +2 -2
  4. package/dist/cjs/db-accordion.cjs.entry.js +1 -1
  5. package/dist/cjs/db-badge.cjs.entry.js +1 -1
  6. package/dist/cjs/db-brand.cjs.entry.js +1 -1
  7. package/dist/cjs/db-button.cjs.entry.js +1 -1
  8. package/dist/cjs/db-card.cjs.entry.js +2 -2
  9. package/dist/cjs/db-checkbox.cjs.entry.js +2 -2
  10. package/dist/cjs/db-custom-button.cjs.entry.js +2 -2
  11. package/dist/cjs/db-custom-select-dropdown_5.cjs.entry.js +9 -9
  12. package/dist/cjs/db-custom-select-form-field.cjs.entry.js +2 -2
  13. package/dist/cjs/db-custom-select.cjs.entry.js +5 -5
  14. package/dist/cjs/db-divider.cjs.entry.js +1 -1
  15. package/dist/cjs/db-drawer.cjs.entry.js +3 -3
  16. package/dist/cjs/db-header.cjs.entry.js +2 -2
  17. package/dist/cjs/db-icon.cjs.entry.js +1 -1
  18. package/dist/cjs/db-infotext.cjs.entry.js +1 -1
  19. package/dist/cjs/db-link.cjs.entry.js +1 -1
  20. package/dist/cjs/db-navigation-item.cjs.entry.js +1 -1
  21. package/dist/cjs/db-navigation.cjs.entry.js +2 -2
  22. package/dist/cjs/db-notification.cjs.entry.js +2 -2
  23. package/dist/cjs/db-page.cjs.entry.js +2 -2
  24. package/dist/cjs/db-popover.cjs.entry.js +2 -2
  25. package/dist/cjs/db-radio.cjs.entry.js +1 -1
  26. package/dist/cjs/db-section.cjs.entry.js +2 -2
  27. package/dist/cjs/db-select.cjs.entry.js +2 -2
  28. package/dist/cjs/db-stack.cjs.entry.js +2 -2
  29. package/dist/cjs/db-switch.cjs.entry.js +2 -2
  30. package/dist/cjs/db-tab-item_3.cjs.entry.js +67 -133
  31. package/dist/cjs/db-tabs.cjs.entry.js +123 -373
  32. package/dist/cjs/db-textarea.cjs.entry.js +2 -2
  33. package/dist/cjs/db-tooltip.cjs.entry.js +4 -3
  34. package/dist/cjs/db-ux.cjs.js +1 -1
  35. package/dist/cjs/index.cjs.js +2 -2
  36. package/dist/cjs/loader.cjs.js +1 -1
  37. package/dist/collection/components/accordion/accordion.js +1 -1
  38. package/dist/collection/components/accordion-item/accordion-item.js +2 -2
  39. package/dist/collection/components/badge/badge.js +1 -1
  40. package/dist/collection/components/brand/brand.js +1 -1
  41. package/dist/collection/components/button/button.js +1 -1
  42. package/dist/collection/components/card/card.js +2 -2
  43. package/dist/collection/components/checkbox/checkbox.js +2 -2
  44. package/dist/collection/components/custom-button/custom-button.js +2 -2
  45. package/dist/collection/components/custom-select/custom-select.js +5 -5
  46. package/dist/collection/components/custom-select-dropdown/custom-select-dropdown.js +2 -2
  47. package/dist/collection/components/custom-select-form-field/custom-select-form-field.js +2 -2
  48. package/dist/collection/components/custom-select-list/custom-select-list.js +2 -2
  49. package/dist/collection/components/custom-select-list-item/custom-select-list-item.js +1 -1
  50. package/dist/collection/components/divider/divider.js +1 -1
  51. package/dist/collection/components/drawer/drawer.js +3 -3
  52. package/dist/collection/components/header/header.js +2 -2
  53. package/dist/collection/components/icon/icon.js +1 -1
  54. package/dist/collection/components/infotext/infotext.js +1 -1
  55. package/dist/collection/components/input/input.js +2 -2
  56. package/dist/collection/components/link/link.js +1 -1
  57. package/dist/collection/components/navigation/navigation.js +2 -2
  58. package/dist/collection/components/navigation-item/navigation-item.js +1 -1
  59. package/dist/collection/components/notification/notification.js +2 -2
  60. package/dist/collection/components/page/page.js +2 -2
  61. package/dist/collection/components/popover/popover.js +2 -2
  62. package/dist/collection/components/radio/radio.js +1 -1
  63. package/dist/collection/components/section/section.js +2 -2
  64. package/dist/collection/components/select/select.js +2 -2
  65. package/dist/collection/components/stack/stack.js +2 -2
  66. package/dist/collection/components/switch/switch.js +2 -2
  67. package/dist/collection/components/tab-item/tab-item.js +129 -198
  68. package/dist/collection/components/tab-list/tab-list.js +12 -74
  69. package/dist/collection/components/tab-panel/tab-panel.js +2 -80
  70. package/dist/collection/components/tabs/tabs.js +167 -504
  71. package/dist/collection/components/tag/tag.js +2 -2
  72. package/dist/collection/components/textarea/textarea.js +2 -2
  73. package/dist/collection/components/tooltip/tooltip.js +4 -3
  74. package/dist/collection/shared/model.js +1 -1
  75. package/dist/custom-elements.json +2998 -3898
  76. package/dist/db-ux/db-ux.esm.js +1 -1
  77. package/dist/db-ux/index.esm.js +1 -1
  78. package/dist/db-ux/{p-9b518eb4.entry.js → p-0e0c3c72.entry.js} +1 -1
  79. package/dist/db-ux/{p-61784f7a.entry.js → p-12a2c502.entry.js} +1 -1
  80. package/dist/db-ux/{p-b7087f0b.entry.js → p-13157b54.entry.js} +1 -1
  81. package/dist/db-ux/p-202323c2.entry.js +1 -0
  82. package/dist/db-ux/p-21068628.entry.js +1 -0
  83. package/dist/db-ux/{p-b06fe221.entry.js → p-212bde1e.entry.js} +1 -1
  84. package/dist/db-ux/{p-01c278b9.entry.js → p-2355324e.entry.js} +1 -1
  85. package/dist/db-ux/p-377987d0.entry.js +1 -0
  86. package/dist/db-ux/p-3d5d49ff.entry.js +1 -0
  87. package/dist/db-ux/p-452a8b6b.entry.js +1 -0
  88. package/dist/db-ux/p-4de2c697.entry.js +1 -0
  89. package/dist/db-ux/{p-f08b14d9.entry.js → p-5cb74480.entry.js} +1 -1
  90. package/dist/db-ux/{p-071ae423.entry.js → p-5f5eb78d.entry.js} +1 -1
  91. package/dist/db-ux/p-605013f0.entry.js +1 -0
  92. package/dist/db-ux/p-6f9e146e.entry.js +1 -0
  93. package/dist/db-ux/{p-328faf6b.entry.js → p-70823b80.entry.js} +1 -1
  94. package/dist/db-ux/{p-70e6d32f.entry.js → p-761c9ddf.entry.js} +1 -1
  95. package/dist/db-ux/p-7fa91164.entry.js +1 -0
  96. package/dist/db-ux/p-8e84712d.entry.js +1 -0
  97. package/dist/db-ux/{p-ffe614c8.entry.js → p-980a6afe.entry.js} +1 -1
  98. package/dist/db-ux/{p-6c26b0ba.entry.js → p-a65d0d23.entry.js} +1 -1
  99. package/dist/db-ux/p-a9efbb0b.entry.js +1 -0
  100. package/dist/db-ux/{p-07c7ecc9.entry.js → p-abb0885d.entry.js} +1 -1
  101. package/dist/db-ux/{p-9a895c18.entry.js → p-ba8464d2.entry.js} +1 -1
  102. package/dist/db-ux/p-bd66d144.entry.js +1 -0
  103. package/dist/db-ux/{p-74a45768.entry.js → p-bed8d029.entry.js} +1 -1
  104. package/dist/db-ux/{p-ee43015b.entry.js → p-c76089f6.entry.js} +1 -1
  105. package/dist/db-ux/{p-44a0407b.entry.js → p-c7bf8d05.entry.js} +1 -1
  106. package/dist/db-ux/{p-43a9623f.entry.js → p-d85b1c15.entry.js} +1 -1
  107. package/dist/db-ux/{p-d93b9d58.entry.js → p-d8b38722.entry.js} +1 -1
  108. package/dist/db-ux/p-dd08f6e4.entry.js +1 -0
  109. package/dist/esm/db-accordion-item.entry.js +2 -2
  110. package/dist/esm/db-accordion.entry.js +1 -1
  111. package/dist/esm/db-badge.entry.js +1 -1
  112. package/dist/esm/db-brand.entry.js +1 -1
  113. package/dist/esm/db-button.entry.js +1 -1
  114. package/dist/esm/db-card.entry.js +2 -2
  115. package/dist/esm/db-checkbox.entry.js +2 -2
  116. package/dist/esm/db-custom-button.entry.js +2 -2
  117. package/dist/esm/db-custom-select-dropdown_5.entry.js +9 -9
  118. package/dist/esm/db-custom-select-form-field.entry.js +2 -2
  119. package/dist/esm/db-custom-select.entry.js +5 -5
  120. package/dist/esm/db-divider.entry.js +1 -1
  121. package/dist/esm/db-drawer.entry.js +3 -3
  122. package/dist/esm/db-header.entry.js +2 -2
  123. package/dist/esm/db-icon.entry.js +1 -1
  124. package/dist/esm/db-infotext.entry.js +1 -1
  125. package/dist/esm/db-link.entry.js +1 -1
  126. package/dist/esm/db-navigation-item.entry.js +1 -1
  127. package/dist/esm/db-navigation.entry.js +2 -2
  128. package/dist/esm/db-notification.entry.js +2 -2
  129. package/dist/esm/db-page.entry.js +2 -2
  130. package/dist/esm/db-popover.entry.js +2 -2
  131. package/dist/esm/db-radio.entry.js +1 -1
  132. package/dist/esm/db-section.entry.js +2 -2
  133. package/dist/esm/db-select.entry.js +2 -2
  134. package/dist/esm/db-stack.entry.js +2 -2
  135. package/dist/esm/db-switch.entry.js +2 -2
  136. package/dist/esm/db-tab-item_3.entry.js +68 -134
  137. package/dist/esm/db-tabs.entry.js +123 -373
  138. package/dist/esm/db-textarea.entry.js +2 -2
  139. package/dist/esm/db-tooltip.entry.js +5 -4
  140. package/dist/esm/db-ux.js +1 -1
  141. package/dist/esm/index.js +2 -2
  142. package/dist/esm/loader.js +1 -1
  143. package/dist/types/components/tab-item/model.d.ts +11 -28
  144. package/dist/types/components/tab-item/tab-item.d.ts +20 -22
  145. package/dist/types/components/tab-list/model.d.ts +5 -15
  146. package/dist/types/components/tab-list/tab-list.d.ts +1 -4
  147. package/dist/types/components/tab-panel/model.d.ts +3 -13
  148. package/dist/types/components/tab-panel/tab-panel.d.ts +0 -3
  149. package/dist/types/components/tabs/model.d.ts +17 -51
  150. package/dist/types/components/tabs/tabs.d.ts +16 -35
  151. package/dist/types/components.d.ts +30 -80
  152. package/dist/types/shared/model.d.ts +5 -5
  153. package/dist/vscode.html-custom-data.json +59 -147
  154. package/dist/web-types.json +135 -289
  155. package/package.json +3 -3
  156. package/dist/db-ux/p-10869bfa.entry.js +0 -1
  157. package/dist/db-ux/p-1427bb15.entry.js +0 -1
  158. package/dist/db-ux/p-397bc590.entry.js +0 -1
  159. package/dist/db-ux/p-68835a75.entry.js +0 -1
  160. package/dist/db-ux/p-68a995df.entry.js +0 -1
  161. package/dist/db-ux/p-6e898a58.entry.js +0 -1
  162. package/dist/db-ux/p-71868bb5.entry.js +0 -1
  163. package/dist/db-ux/p-9b4d0c18.entry.js +0 -1
  164. package/dist/db-ux/p-a927fe88.entry.js +0 -1
  165. package/dist/db-ux/p-a93ca690.entry.js +0 -1
  166. package/dist/db-ux/p-d97c0787.entry.js +0 -1
  167. package/dist/db-ux/p-efde1b6e.entry.js +0 -1
  168. package/dist/db-ux/p-f92cbbae.entry.js +0 -1
@@ -82,9 +82,9 @@ const DBHeader = class {
82
82
  }
83
83
  render() {
84
84
  var _a, _b, _c;
85
- return (h("header", { key: '6b7542f09be273019e4a2db38194482a90d7860a', class: cls("db-header", this.className), ref: (el) => {
85
+ return (h("header", { key: 'b5085e769fbc61e94b0ae0e1cca91db441efc1a5', class: cls("db-header", this.className), ref: (el) => {
86
86
  this._ref = el;
87
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-width": this.width, "data-on-forcing-mobile": this.forceMobile && !this.forcedToMobile }, h("db-drawer", { key: '831aaf817b0fa513ec5e5dc4c330c2fa716897af', class: "db-header-drawer", spacing: "small", rounded: true, closeButtonId: this.closeButtonId, closeButtonText: this.closeButtonText, open: getBoolean(this.drawerOpen), onClose: () => this.handleToggle() }, h("div", { key: '271d421742eae32a41d8a7768e29f01f1b9c952f', class: "db-header-drawer-navigation" }, h("div", { key: 'ac6d9af5ff4b2e294760695a776f248d9d5bf756', class: "db-header-navigation", onClick: (event) => this.handleNavigationItemClick(event) }, h("slot", { key: '148922ebf9d852a8c240de740cca790191f8f81e' })), h("div", { key: '482b32d7e04547960ef2478f4b10f304cc246b20', class: "db-header-meta-navigation" }, h("slot", { key: 'a6feae39c0714770d5a9fb9d25260df1fb10effc', name: "metaNavigation" }))), h("div", { key: 'de0e67d3d547e4d0ea82de788e5a253436a67949', class: "db-header-secondary-action" }, h("slot", { key: '989d9cab2d33fc445ab5c7988b3e851f3452c452', name: "secondaryAction" }))), h("div", { key: 'e518b5045d99fa7a171ff330914bf915ca87b7e6', class: "db-header-meta-navigation" }, h("slot", { key: 'aa1077eacd48bef3e16a8b31635c89b9e31addf9', name: "metaNavigation" })), h("div", { key: '028358578a614b11aee56905b791f1fdf0e44c65', class: "db-header-navigation-bar" }, h("div", { key: 'c48f6905f52fe8b387f671802d5d1f4f0598be07', class: "db-header-brand-container" }, h("slot", { key: '37aae0fdf18ee4747bd685a223b1d9b205336042', name: "brand" })), h("div", { key: 'e2155e4f546d91c75733290d0a8c73b507b628aa', class: "db-header-navigation-container" }, h("div", { key: '07e19faa67fa4920872ff1f8426b4fb89118e9de', class: "db-header-navigation" }, h("slot", { key: 'ba4358bc0b459092feb524a02240bd465be5f1be' })), h("div", { key: 'b85a9d1dab7ea4b8e1d8f0bb9156c575511ea88f', class: "db-header-primary-action" }, h("slot", { key: 'f76003fd65f01088b9dfd7e4966895a8b893b675', name: "primaryAction" }))), h("div", { key: '0b9c26a05325fad02c4f1076d67a88de05b1f739', class: "db-header-action-container" }, h("div", { key: '5cd34e7a341e041508134c5cae16448fde09251b', class: "db-header-burger-menu-container" }, h("db-button", { key: '6ac1cf00982f515ee86c978afef7788ad6a7eb81', icon: "menu", variant: "ghost", noText: true, onClick: () => this.handleToggle() }, (_c = this.burgerMenuLabel) !== null && _c !== void 0 ? _c : DEFAULT_BURGER_MENU)), h("div", { key: 'f25c7681051a6b8763c48630f3f23f9946cd68ea', class: "db-header-secondary-action" }, h("slot", { key: '76806c54a2558ffcd3498934e183bcba7fc2ef94', name: "secondaryAction" }))))));
87
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-width": this.width, "data-on-forcing-mobile": this.forceMobile && !this.forcedToMobile }, h("db-drawer", { key: 'a47facce9c8108126495c77d37a487cd34fe0ecb', class: "db-header-drawer", spacing: "small", rounded: true, closeButtonId: this.closeButtonId, closeButtonText: this.closeButtonText, open: getBoolean(this.drawerOpen), onClose: () => this.handleToggle() }, h("div", { key: 'cda6c2d0070ce377af2bd5ca4b77459a94350df5', class: "db-header-drawer-navigation" }, h("div", { key: '15713a6e12680039ca79f27ec4a1000b120af4fd', class: "db-header-navigation", onClick: (event) => this.handleNavigationItemClick(event) }, h("slot", { key: 'e553fe01864f6a23e12edb336ddfabae78ca4f74' })), h("div", { key: '73339268263f22638ce7e7cde00369f58a279d62', class: "db-header-meta-navigation" }, h("slot", { key: 'deffe76713c7ad062821f83a34ad1c0530acff6c', name: "metaNavigation" }))), h("div", { key: '42f61529aa00d9422cac6c8d5ae2588d0eb4760d', class: "db-header-secondary-action" }, h("slot", { key: '3273017c0520401367809b3e39e1d642b92bec50', name: "secondaryAction" }))), h("div", { key: '26b07d2244c291b78daa6dd2bc39ce2ee93d8674', class: "db-header-meta-navigation" }, h("slot", { key: '4adfd5ac044acbb161a26e9e033a1483991842c6', name: "metaNavigation" })), h("div", { key: '6a9709c60965315e7ecffb41ea4aac8caf986086', class: "db-header-navigation-bar" }, h("div", { key: '6eca84e588432ec968d4aed685d0dda4053b08a9', class: "db-header-brand-container" }, h("slot", { key: 'c034633ed87c6c554621e275b6d98d1d1628265c', name: "brand" })), h("div", { key: '04766e92142de2cd49a08711e7ad627b0cef14bd', class: "db-header-navigation-container" }, h("div", { key: 'fa4a5f6deab5edf3e1acf6e67d73ce06e638ae02', class: "db-header-navigation" }, h("slot", { key: '192fbdd2773ab46f2e4800d919a2ace97c9f5ef2' })), h("div", { key: '3bf503b08a862dbca679c198916da4be7228c528', class: "db-header-primary-action" }, h("slot", { key: '2ab7194da0568d92c85d47ecbf4e34aa4a734d00', name: "primaryAction" }))), h("div", { key: 'f45dbbf3346e8bf533a4af7c82e754fe0a679082', class: "db-header-action-container" }, h("div", { key: '7dfcd81988888a0595b94e15ba963abcfb1200ea', class: "db-header-burger-menu-container" }, h("db-button", { key: '52e71ba370d564b8739966643adf2ccce5e48bcb', icon: "menu", variant: "ghost", noText: true, onClick: () => this.handleToggle() }, (_c = this.burgerMenuLabel) !== null && _c !== void 0 ? _c : DEFAULT_BURGER_MENU)), h("div", { key: '54cf3d9d67d7be42f6b06227100abb337deb396d', class: "db-header-secondary-action" }, h("slot", { key: 'fc0a9946c1fd478c57e73f4c3b5b6ae0600101b8', name: "secondaryAction" }))))));
88
88
  }
89
89
  static get watchers() { return {
90
90
  "initialized": [{
@@ -46,7 +46,7 @@ const DBIcon = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b;
49
- return (h("span", { key: 'f0c3320ea041e2c56869d0540d8deaed00fd570a', class: cls("db-icon", this.className), "aria-hidden": "true", ref: (el) => {
49
+ return (h("span", { key: '3bef98de9ca12c66f7cce8e11eaa5d895a8d6750', class: cls("db-icon", this.className), "aria-hidden": "true", ref: (el) => {
50
50
  this._ref = el;
51
51
  }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-icon": this.icon, "data-icon-weight": this.weight, "data-icon-variant": this.variant }, this.text ? this.text : h("slot", null)));
52
52
  }
@@ -46,7 +46,7 @@ const DBInfotext = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b, _c;
49
- return (h("span", { key: '1a8d9f9db5b32a884f90a41cb124d54f32a7f4c0', class: cls("db-infotext", this.className), ref: (el) => {
49
+ return (h("span", { key: '49219bd5f07042ba66ee28e86aed0536e0f776eb', class: cls("db-infotext", this.className), ref: (el) => {
50
50
  this._ref = el;
51
51
  }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-icon": this.icon, "data-semantic": this.semantic, "data-size": this.size, "data-wrap": getBooleanAsString(this.wrap), "data-show-icon-leading": getBooleanAsString((_c = this.showIcon) !== null && _c !== void 0 ? _c : true) }, this.text ? this.text : h("slot", null)));
52
52
  }
@@ -46,7 +46,7 @@ const DBLink = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b, _c, _d;
49
- return (h("a", { key: 'e5663911fcd4d3c7089f915aa842a28f09a4cafa', class: cls("db-link", this.className), ref: (el) => {
49
+ return (h("a", { key: '71c5ab28a592fe182048091df4ed2d34f4cafe96', class: cls("db-link", this.className), ref: (el) => {
50
50
  this._ref = el;
51
51
  }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, href: this.href, target: this.target, rel: this.rel, role: this.role, referrerPolicy: (_c = this.referrerpolicy) !== null && _c !== void 0 ? _c : this.referrerPolicy, hrefLang: this.hreflang, "aria-disabled": getBooleanAsString(this.disabled), tabIndex: this.disabled ? -1 : 0, "data-size": this.size, "data-show-icon-trailing": getBooleanAsString((_d = this.showIcon) !== null && _d !== void 0 ? _d : true), "data-variant": this.variant, "data-content": this.content || "internal", "data-wrap": getBooleanAsString(this.wrap) }, this.text ? this.text : h("slot", null)));
52
52
  }
@@ -115,7 +115,7 @@ const DBNavigationItem = class {
115
115
  }
116
116
  render() {
117
117
  var _a, _b, _c;
118
- return (h("li", { key: '71431f09ac02e0d1093f40403597016a7d1aca53', class: cls("db-navigation-item", this.className), ref: (el) => {
118
+ return (h("li", { key: '58b2c247c8dad65176a6bc037d908c81da83fc58', class: cls("db-navigation-item", this.className), ref: (el) => {
119
119
  this._ref = el;
120
120
  }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, onMouseOver: () => { var _a; return (_a = this.navigationItemSafeTriangle) === null || _a === void 0 ? void 0 : _a.enableFollow(); }, onMouseLeave: () => { var _a; return (_a = this.navigationItemSafeTriangle) === null || _a === void 0 ? void 0 : _a.disableFollow(); }, onMouseMove: (event) => { var _a; return (_a = this.navigationItemSafeTriangle) === null || _a === void 0 ? void 0 : _a.followByMouseEvent(event); }, "data-width": this.width, "data-icon": this.icon, "data-show-icon": getBooleanAsString(this.showIcon), "data-active": this.active, "data-wrap": getBooleanAsString(this.wrap), "aria-disabled": getBooleanAsString(this.disabled) }, !this.hasSubNavigation ? this.text ? this.text : h("slot", null) : null, this.hasSubNavigation ? (h(Fragment, null, h("button", { class: "db-navigation-item-expand-button", id: this.subNavigationToggleId, "aria-haspopup": this.hasAreaPopup ? "true" : undefined, "aria-expanded": this.isSubNavigationExpanded, "aria-controls": this.subNavigationId, disabled: getBoolean(this.disabled, "disabled"), onClick: (event) => this.handleClick(event) }, this.text ? this.text : h("slot", null)), h("menu", { class: "db-sub-navigation", id: this.subNavigationId, "aria-labelledby": this.subNavigationToggleId, "data-force-close": this.autoClose, onClick: (event) => this.handleNavigationItemClick(event) }, this.hasAreaPopup ? (h("div", { class: "db-mobile-navigation-back" }, h("db-button", { icon: "arrow_left", variant: "ghost", id: this.backButtonId, onClick: (event) => this.handleBackClick(event) }, (_c = this.backButtonText) !== null && _c !== void 0 ? _c : DEFAULT_BACK))) : null, h("slot", { name: "subNavigation" })))) : null));
121
121
  }
@@ -46,9 +46,9 @@ const DBNavigation = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b;
49
- return (h("nav", { key: 'ca94fff30f495b5c5e4ff9ac7c7149fb371171d5', class: cls("db-navigation", this.className), ref: (el) => {
49
+ return (h("nav", { key: 'd35a0452fce96ed3fa6d692c8022ea4e36802626', class: cls("db-navigation", this.className), ref: (el) => {
50
50
  this._ref = el;
51
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, h("menu", { key: '73f90a492f154a67253f02ca5b6b6d0ef0845df0' }, h("slot", { key: 'd70091bcc15c09d90086f2e04a0ad990b161f5ae' }))));
51
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, h("menu", { key: '2b1ad0fd739f64003078bbf18535666f83487d1f' }, h("slot", { key: '0c82a0f8e78ca1489efe693ec5ba973ada355c97' }))));
52
52
  }
53
53
  };
54
54
 
@@ -56,13 +56,13 @@ const DBNotification = class {
56
56
  }
57
57
  render() {
58
58
  var _a, _b, _c;
59
- return (h("div", { key: 'c352f22f011516ad6375434f95b689e05d08f354', class: cls("db-notification", this.className), ref: (el) => {
59
+ return (h("div", { key: 'b7789fad4794a93805eeec0cf2740b3f592f32fa', class: cls("db-notification", this.className), ref: (el) => {
60
60
  this._ref = el;
61
61
  }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, role: getNotificationRole({
62
62
  semantic: this.semantic,
63
63
  role: this.role,
64
64
  ariaLive: this.ariaLive,
65
- }), "aria-live": this.ariaLive, "data-semantic": this.semantic, "data-variant": this.variant, "data-icon": getBoolean(this.showIcon) !== false ? this.icon : undefined, "data-show-icon": getBooleanAsString(this.showIcon), "data-link-variant": this.linkVariant }, h("slot", { key: '997c558994530fdd2adb1f2f159ae3990c0f8950', name: "image" }), stringPropVisible(this.headline, this.showHeadline) ? (h("header", null, this.headline)) : null, h("div", { key: 'e2363b4e7d1e7ceb47ac3b992924d3a28099e11a', "data-area": "content" }, this.text ? this.text : h("slot", null)), stringPropVisible(this.timestamp, this.showTimestamp) ? (h("span", null, this.timestamp)) : null, h("slot", { key: '848011c47a131dd734ce241f0fecd0b4e12c85fd', name: "link" }), getBoolean(this.closeable, "closeable") ? (h("db-button", { icon: "cross", variant: "ghost", size: "small", id: this.closeButtonId, noText: true, onClick: (event) => this.handleClose(event) }, (_c = this.closeButtonText) !== null && _c !== void 0 ? _c : DEFAULT_CLOSE_BUTTON)) : null));
65
+ }), "aria-live": this.ariaLive, "data-semantic": this.semantic, "data-variant": this.variant, "data-icon": getBoolean(this.showIcon) !== false ? this.icon : undefined, "data-show-icon": getBooleanAsString(this.showIcon), "data-link-variant": this.linkVariant }, h("slot", { key: 'cdf91c6a6cd8dd519ab235046b9ab260007a370e', name: "image" }), stringPropVisible(this.headline, this.showHeadline) ? (h("header", null, this.headline)) : null, h("div", { key: '97b39e4f03829ea5d1d29b2b1be3066ff4100ac7', "data-area": "content" }, this.text ? this.text : h("slot", null)), stringPropVisible(this.timestamp, this.showTimestamp) ? (h("span", null, this.timestamp)) : null, h("slot", { key: '59856484aeb4d35de524dd4fa5a11f773f6f2a84', name: "link" }), getBoolean(this.closeable, "closeable") ? (h("db-button", { icon: "cross", variant: "ghost", size: "small", id: this.closeButtonId, noText: true, onClick: (event) => this.handleClose(event) }, (_c = this.closeButtonText) !== null && _c !== void 0 ? _c : DEFAULT_CLOSE_BUTTON)) : null));
66
66
  }
67
67
  };
68
68
 
@@ -63,9 +63,9 @@ const DBPage = class {
63
63
  }
64
64
  render() {
65
65
  var _a, _b;
66
- return (h("div", { key: '3f5bc66c9df8cf413d9c2680e7684b0744e3a2c2', class: cls("db-page", this.className), ref: (el) => {
66
+ return (h("div", { key: '3c52f5947a841db0fcfe81b09e37db5a59f04158', class: cls("db-page", this.className), ref: (el) => {
67
67
  this._ref = el;
68
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-variant": this.variant, "data-fade-in": getBooleanAsString(this.fadeIn), "data-fonts-loaded": getBooleanAsString(this.fontsLoaded) }, h("slot", { key: 'e5295cb7977501b139dff99336deff500aae7574', name: "header" }), h("main", { key: 'f97e398d7355f1968fe70274df213e50c86e7ec2', class: cls("db-main", this.mainClass) }, h("slot", { key: '983a96b186d56daeccb13e16b4b0d985e1436178' })), h("slot", { key: 'd081d3a29bb55a627ced239b9d88681698f6425d', name: "footer" })));
68
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-variant": this.variant, "data-fade-in": getBooleanAsString(this.fadeIn), "data-fonts-loaded": getBooleanAsString(this.fontsLoaded) }, h("slot", { key: '9b5d03938d5e60f37d807b3acbeb76a1ecb24aab', name: "header" }), h("main", { key: '49b72ad7dab4cc675c1af0c684bf211affd3fa36', class: cls("db-main", this.mainClass) }, h("slot", { key: '63915bf376296bbfdd9e7f1c3f3e36331543d15c' })), h("slot", { key: 'e94f63187f9347a7377956b040d3c201aa008dd6', name: "footer" })));
69
69
  }
70
70
  };
71
71
 
@@ -168,9 +168,9 @@ const DBPopover = class {
168
168
  }
169
169
  render() {
170
170
  var _a, _b, _c;
171
- return (h("div", { key: '421d455f7991553a839b74e0911286ae9c02cff4', class: cls("db-popover", this.className), ref: (el) => {
171
+ return (h("div", { key: 'a160c72e468d3f98cf94f76193b31dea016821f5', class: cls("db-popover", this.className), ref: (el) => {
172
172
  this._ref = el;
173
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, h("slot", { key: 'f84d068f415c002eda648d07dbbf0d150922693f', name: "trigger" }), h("article", { key: 'd63682e3b821dd2d566ccfec3703b740146d7a7a', class: "db-popover-content", "data-spacing": this.spacing, "data-gap": getBooleanAsString(this.gap), "data-animation": getBooleanAsString((_c = this.animation) !== null && _c !== void 0 ? _c : true), "data-open": getBooleanAsString(this.open), "data-delay": this.delay, "data-width": this.width, "data-placement": this.placement }, h("slot", { key: '74a46121e0a9c5ae62e0d2e35299ff8de0939242' }))));
173
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, h("slot", { key: 'bb80f944827c1a2edb671ce3572546eabdac8fe3', name: "trigger" }), h("article", { key: '5286e4c7e53558e4bdff52ab3742acf0b854cb4a', class: "db-popover-content", "data-spacing": this.spacing, "data-gap": getBooleanAsString(this.gap), "data-animation": getBooleanAsString((_c = this.animation) !== null && _c !== void 0 ? _c : true), "data-open": getBooleanAsString(this.open), "data-delay": this.delay, "data-width": this.width, "data-placement": this.placement }, h("slot", { key: '09822daff7336bfe9541418bcd55a8809cdaab08' }))));
174
174
  }
175
175
  static get watchers() { return {
176
176
  "_ref": [{
@@ -125,7 +125,7 @@ const DBRadio = class {
125
125
  (_a = this.abortController) === null || _a === void 0 ? void 0 : _a.abort();
126
126
  }
127
127
  render() {
128
- return (h("label", { key: '2e30a82188ac83cc3c7bd7a396b1c5b46cc0a79a', class: cls("db-radio", this.className), "data-size": this.size, "data-hide-label": getHideProp(this.showLabel), "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), htmlFor: this._id }, h("input", { key: '74aad9996cffe5ed928bdacb63f82e860a603cb7', type: "radio", "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
128
+ return (h("label", { key: 'b77bbb3335c0b3f3813e11c7ac7228a84a40769a', class: cls("db-radio", this.className), "data-size": this.size, "data-hide-label": getHideProp(this.showLabel), "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), htmlFor: this._id }, h("input", { key: '4fe82a7b57a6dd06e556e26d50df574a541129f9', type: "radio", "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
129
129
  this._ref = el;
130
130
  }, id: this._id, name: this.name, checked: getBoolean(this.checked, "checked"), disabled: getBoolean(this.disabled, "disabled"), value: this.value, required: getBoolean(this.required, "required"), onInput: (event) => this.handleInput(event), onChange: (event) => this.handleChange(event), onBlur: (event) => this.handleBlur(event), onFocus: (event) => this.handleFocus(event) }), this.label ? this.label : h("slot", null)));
131
131
  }
@@ -46,9 +46,9 @@ const DBSection = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b;
49
- return (h("section", { key: 'fcfbe66bb695b60a923d394858d92627bf1f86d5', class: cls("db-section", this.className), ref: (el) => {
49
+ return (h("section", { key: 'd2cb50a43641ef50d901bd488c7d31911e0f5487', class: cls("db-section", this.className), ref: (el) => {
50
50
  this._ref = el;
51
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-spacing": this.spacing || "medium", "data-width": this.width }, h("slot", { key: '626b974f5e58ee2c14a29e6ceff7d312aaef4f1f' })));
51
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, "data-spacing": this.spacing || "medium", "data-width": this.width }, h("slot", { key: '90ce1533ea3392317c7e271ad6d2880d0434321e' })));
52
52
  }
53
53
  };
54
54
 
@@ -236,14 +236,14 @@ const DBSelect = class {
236
236
  }
237
237
  render() {
238
238
  var _a, _b, _c, _d, _e, _f;
239
- return (h("div", { key: 'ceb8838f81622fd92216cfdb965b6221b12ea7a7', class: cls("db-select", this.className), "data-variant": this.variant, "data-hide-label": getHideProp(this.showLabel), "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-icon": this.icon, "data-show-icon": getBooleanAsString(this.showIcon) }, h("label", { key: '8889e667cff25a524532e9e32f61418c14fa0163', htmlFor: this._id }, (_a = this.label) !== null && _a !== void 0 ? _a : DEFAULT_LABEL), h("select", { key: '4ca3dbeeaba0c3bc95b2a8a3945a13060d816d87', "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
239
+ return (h("div", { key: 'e083b3de98c929310348ef084f614b6115cc79cb', class: cls("db-select", this.className), "data-variant": this.variant, "data-hide-label": getHideProp(this.showLabel), "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-icon": this.icon, "data-show-icon": getBooleanAsString(this.showIcon) }, h("label", { key: 'f2dab8efe5a3c299268da1f5c58d09752b6b8ca5', htmlFor: this._id }, (_a = this.label) !== null && _a !== void 0 ? _a : DEFAULT_LABEL), h("select", { key: '610327eb481b3806f99a8d123452bcf8e7e2ca58', "aria-invalid": this.validation === "invalid", "data-custom-validity": this.validation, ref: (el) => {
240
240
  this._ref = el;
241
241
  }, required: getBoolean(this.required, "required"), disabled: getBoolean(this.disabled, "disabled"), id: this._id, name: this.name, size: this.size,
242
242
  /* @ts-ignore */
243
243
  value: (_c = (_b = this.value) !== null && _b !== void 0 ? _b : this._value) !== null && _c !== void 0 ? _c : undefined, 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": (_d = this.ariaDescribedBy) !== null && _d !== void 0 ? _d : this._descByIds }, this.variant === "floating" || !!this.placeholder ? (h("option", { class: "placeholder", value: "", "data-show-empty-option": getBooleanAsString(this.shouldShowEmptyOption()) })) : null, ((_e = this.options) === null || _e === void 0 ? void 0 : _e.length) ? ((_f = this.options) === null || _f === void 0 ? void 0 : _f.map((option) => {
244
244
  var _a;
245
245
  return (h(Fragment, null, option.options ? (h("optgroup", { label: this.getOptionLabel(option), key: undefined }, (_a = option.options) === null || _a === void 0 ? void 0 : _a.map((optgroupOption) => (h("option", { value: optgroupOption.value, selected: optgroupOption.selected, disabled: optgroupOption.disabled, key: undefined }, this.getOptionLabel(optgroupOption)))))) : (h("option", { value: option.value, disabled: option.disabled, selected: option.selected, key: undefined }, this.getOptionLabel(option)))));
246
- })) : (h("slot", null))), this.placeholder ? (h("span", { class: "db-select-placeholder", id: this._placeholderId }, this.placeholder)) : 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: '0ea5b9c2d0ecfe76e15b7ecf1f39721ab80d5e31', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: '1f817d1e72c71d581857ffd06101cd42839c25dc', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
246
+ })) : (h("slot", null))), this.placeholder ? (h("span", { class: "db-select-placeholder", id: this._placeholderId }, this.placeholder)) : 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: '946099b7eaab7da894f46400e1f428de137492ba', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: '723768ffcad5add62979635d354280686145ca31', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
247
247
  }
248
248
  static get watchers() { return {
249
249
  "id": [{
@@ -46,9 +46,9 @@ const DBStack = class {
46
46
  }
47
47
  render() {
48
48
  var _a, _b;
49
- return (h("div", { key: '7b1914f7484d0116dbdcca6c2b8fd62ee5f5361d', class: cls("db-stack", this.className), ref: (el) => {
49
+ return (h("div", { key: 'e8a95918ab5412c03412b92adb3f2a2d5979d492', class: cls("db-stack", this.className), ref: (el) => {
50
50
  this._ref = el;
51
- }, 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": getBooleanAsString(this.wrap) }, h("slot", { key: '8b24b8791579cab2d6e5597f983ee488e860172d' })));
51
+ }, 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": getBooleanAsString(this.wrap) }, h("slot", { key: 'b95b19d6ff1a61f416eadfb14d9e19647e4f6cb4' })));
52
52
  }
53
53
  };
54
54
 
@@ -186,9 +186,9 @@ const DBSwitch = class {
186
186
  }
187
187
  render() {
188
188
  var _a, _b;
189
- return (h("div", { key: 'ef12ecb991d547a453f5a35d6a9502e2b811ea2b', class: cls("db-switch", this.className), "data-visual-aid": getBooleanAsString(this.visualAid), "data-size": this.size, "data-hide-label": getHideProp(this.showLabel), "data-variant": this.variant, "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-custom-validity": this.validation }, h("label", { key: 'a037c403a8204c7093c5a29517235dbee5684c67', htmlFor: this._id }, h("input", { key: '513e08da8efc09d2b8c4b8bc12d6b46019988e63', type: "checkbox", role: "switch", id: this._id, ref: (el) => {
189
+ return (h("div", { key: '66c2badcfc403e68d44d93cd1a79d087b212bbd6', class: cls("db-switch", this.className), "data-visual-aid": getBooleanAsString(this.visualAid), "data-size": this.size, "data-hide-label": getHideProp(this.showLabel), "data-variant": this.variant, "data-hide-asterisk": getHideProp(this.showRequiredAsterisk), "data-custom-validity": this.validation }, h("label", { key: 'c22fc86dd012f6de327f861cca3c1b4ab4f3605d', htmlFor: this._id }, h("input", { key: '3d1532eee9a137f2a1db1ba1574856ecc61833d8', type: "checkbox", role: "switch", id: this._id, ref: (el) => {
190
190
  this._ref = el;
191
- }, checked: getBoolean(this.checked, "checked"), value: this.value, disabled: getBoolean(this.disabled, "disabled"), "aria-invalid": this.validation === "invalid" ? "true" : undefined, "aria-describedby": this._descByIds, name: this.name, required: 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 : h("slot", null)), stringPropVisible(this.message, this.showMessage) ? (h("db-infotext", { size: "small", semantic: "adaptive", id: this._messageId, icon: this.messageIcon }, this.message)) : null, this.hasValidState() ? (h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, (_b = this.validMessage) !== null && _b !== void 0 ? _b : DEFAULT_VALID_MESSAGE)) : null, h("db-infotext", { key: '88bbba78f87645a478e74ddf003303406e333c8f', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: 'd3564c75c3c4a8aefd24b91665345425af9c9071', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
191
+ }, checked: getBoolean(this.checked, "checked"), value: this.value, disabled: getBoolean(this.disabled, "disabled"), "aria-invalid": this.validation === "invalid" ? "true" : undefined, "aria-describedby": this._descByIds, name: this.name, required: 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 : h("slot", null)), stringPropVisible(this.message, this.showMessage) ? (h("db-infotext", { size: "small", semantic: "adaptive", id: this._messageId, icon: this.messageIcon }, this.message)) : null, this.hasValidState() ? (h("db-infotext", { size: "small", semantic: "successful", id: this._validMessageId }, (_b = this.validMessage) !== null && _b !== void 0 ? _b : DEFAULT_VALID_MESSAGE)) : null, h("db-infotext", { key: 'd24f80874212a9a9669d5731d9e5b6f4f3be6001', size: "small", semantic: "critical", id: this._invalidMessageId }, this._invalidMessage), h("span", { key: 'cb3420bd986f1398094fbac151d27a5c2f392d7d', "data-visually-hidden": "true", role: "status" }, this._voiceOverFallback)));
192
192
  }
193
193
  static get watchers() { return {
194
194
  "id": [{
@@ -1,53 +1,34 @@
1
1
  import { r as registerInstance, c as createEvent, h } from './index-K4o-AcjZ.js';
2
- import { e as getBoolean, c as cls, u as uuid } from './index-xkoBSP8R.js';
2
+ import { g as getBooleanAsString, e as getBoolean, c as cls } from './index-xkoBSP8R.js';
3
3
 
4
4
  const DBTabItem = class {
5
5
  constructor(hostRef) {
6
6
  registerInstance(this, hostRef);
7
- this.click = createEvent(this, "click");
7
+ this.change = createEvent(this, "change");
8
+ this._selected = false;
9
+ this._name = undefined;
8
10
  this.initialized = false;
9
- this.internalActive = false;
10
- this.internalTabIndex = -1;
11
- this.isTruncated = false;
12
- this.tooltipText = "";
13
- this._resizeObserver = null;
14
- this._ariaSelectedListener = null;
11
+ this._listenerAdded = false;
12
+ this.boundSetSelectedOnChange = undefined;
15
13
  }
16
- getCurrentTabIndex() {
17
- return this.tabIndex !== undefined
18
- ? Number(this.tabIndex)
19
- : this.internalTabIndex;
14
+ setSelectedOnChange(event) {
15
+ event.stopPropagation();
16
+ this._selected = getBooleanAsString(event.target === this._ref);
20
17
  }
21
- handleClick(event) {
22
- if (event && event.preventDefault) {
23
- event.preventDefault();
24
- }
25
- if (!getBoolean(this.disabled) && this.click) {
26
- this.click.emit(event);
18
+ handleNameAttribute() {
19
+ if (this._ref) {
20
+ const setAttribute = this._ref.setAttribute;
21
+ this._ref.setAttribute = (attribute, value) => {
22
+ setAttribute.call(this._ref, attribute, value);
23
+ if (attribute === "name") {
24
+ this._name = value;
25
+ }
26
+ };
27
27
  }
28
28
  }
29
- checkTruncation() {
30
- if (this._labelRef) {
31
- const scrollWidth = Math.ceil(this._labelRef.scrollWidth);
32
- const clientWidth = Math.ceil(this._labelRef.clientWidth);
33
- const truncated = scrollWidth > clientWidth + 1;
34
- if (this.isTruncated !== truncated) {
35
- this.isTruncated = truncated;
36
- if (!truncated && this._ref) {
37
- if (this._ref.hasAttribute("data-has-tooltip")) {
38
- this._ref.removeAttribute("data-has-tooltip");
39
- }
40
- if (this._ref.hasAttribute("aria-describedby")) {
41
- this._ref.removeAttribute("aria-describedby");
42
- }
43
- }
44
- }
45
- this.tooltipText = truncated
46
- ? this.label ||
47
- this._labelRef.innerText ||
48
- this._labelRef.textContent ||
49
- ""
50
- : "";
29
+ handleChange(event) {
30
+ if (this.change) {
31
+ this.change.emit(event);
51
32
  }
52
33
  }
53
34
  /**
@@ -87,112 +68,66 @@ const DBTabItem = class {
87
68
  }
88
69
  }
89
70
  watch0Fn() {
90
- if (this.active !== undefined) {
91
- this.internalActive = getBoolean(this.active) || false;
71
+ var _a;
72
+ if (this._ref && this.initialized && this.boundSetSelectedOnChange) {
73
+ this.initialized = false;
74
+ // deselect this tab when another tab in tablist is selected
75
+ if (!this._listenerAdded) {
76
+ (_a = this._ref
77
+ .closest("[role=tablist]")) === null || _a === void 0 ? void 0 : _a.addEventListener("change", this.boundSetSelectedOnChange);
78
+ this._listenerAdded = true;
79
+ }
80
+ // Initialize selected state from either active prop (set by parent) or checked attribute
81
+ if (this.active || this._ref.checked) {
82
+ this._selected = getBooleanAsString(true);
83
+ this._ref.click();
84
+ }
92
85
  }
93
86
  }
94
87
  watch0() {
95
88
  this.watch0Fn();
96
89
  }
90
+ watch1Fn() {
91
+ if (this.name) {
92
+ this._name = this.name;
93
+ }
94
+ }
95
+ watch1() {
96
+ this.watch1Fn();
97
+ }
97
98
  componentDidLoad() {
98
- var _a;
99
99
  this.enableAttributePassing(this._ref, "db-tab-item");
100
- this.internalActive = getBoolean(this.active) || false;
101
- this.internalTabIndex = getBoolean(this.active) ? 0 : -1;
102
- if (typeof window !== "undefined") {
103
- const setupObserverAndCheck = () => {
104
- requestAnimationFrame(() => {
105
- this.checkTruncation();
106
- const labelEl = this._labelRef;
107
- if (labelEl && !labelEl.dataset.label) {
108
- labelEl.dataset.label =
109
- this.label || labelEl.innerText || labelEl.textContent || "";
110
- }
111
- if (this._labelRef) {
112
- const resizeObserver = new ResizeObserver(() => {
113
- requestAnimationFrame(() => {
114
- this.checkTruncation();
115
- });
116
- });
117
- resizeObserver.observe(this._labelRef);
118
- this._resizeObserver = resizeObserver;
119
- }
120
- });
121
- };
122
- const hasIcon = this.showIcon && this.icon;
123
- if (hasIcon && ((_a = document.fonts) === null || _a === void 0 ? void 0 : _a.ready)) {
124
- document.fonts.ready.then(setupObserverAndCheck);
125
- }
126
- else {
127
- setupObserverAndCheck();
128
- }
129
- }
130
- if (this._ref) {
131
- const listener = (event) => {
132
- this.internalActive = event.detail.selected;
133
- if (this.tabIndex === undefined) {
134
- if (event.detail.tabIndex !== undefined) {
135
- this.internalTabIndex = event.detail.tabIndex;
136
- }
137
- else {
138
- this.internalTabIndex = event.detail.selected ? 0 : -1;
139
- }
140
- }
141
- };
142
- this._ariaSelectedListener = {
143
- fn: listener,
144
- };
145
- this._ref.addEventListener("aria-selected-changed", listener);
146
- }
100
+ this.boundSetSelectedOnChange = this.setSelectedOnChange.bind(this);
101
+ this.initialized = true;
147
102
  this.watch0Fn();
103
+ this.watch1Fn();
148
104
  }
149
105
  disconnectedCallback() {
150
106
  var _a;
151
- (_a = this._resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
152
- const _listener = this._ariaSelectedListener;
153
- if (this._ref && _listener) {
154
- this._ref.removeEventListener("aria-selected-changed", _listener.fn);
155
- }
156
- }
157
- componentDidUpdate() {
158
- var _a, _b;
159
- if (this._ref) {
160
- const isDisabled = getBoolean(this.disabled);
161
- const disabledStr = isDisabled ? "true" : "false";
162
- if (((_a = this._ref) === null || _a === void 0 ? void 0 : _a.getAttribute("aria-disabled")) !== disabledStr) {
163
- (_b = this._ref) === null || _b === void 0 ? void 0 : _b.setAttribute("aria-disabled", disabledStr);
164
- }
165
- if (!this.isTruncated) {
166
- if (this._ref.hasAttribute("data-has-tooltip")) {
167
- this._ref.removeAttribute("data-has-tooltip");
168
- }
169
- if (this._ref.hasAttribute("aria-describedby")) {
170
- this._ref.removeAttribute("aria-describedby");
171
- }
172
- }
107
+ if (this._listenerAdded && this._ref && this.boundSetSelectedOnChange) {
108
+ (_a = this._ref
109
+ .closest("[role=tablist]")) === null || _a === void 0 ? void 0 : _a.removeEventListener("change", this.boundSetSelectedOnChange);
110
+ this._listenerAdded = false;
173
111
  }
174
112
  }
175
113
  render() {
176
- var _a, _b, _c, _d;
177
- return (h("button", { key: '87666630bffa6918a10d8b2f3539263d4dbcbc32', class: cls("db-tab-item", this.className), type: "button", role: "tab", title: "", ref: (el) => {
114
+ var _a, _b, _c, _d, _e, _f;
115
+ return (h("li", { key: '0b8687c942d18b49bdf25249be3f0ae1ca727256', class: cls("db-tab-item", this.className), role: "none" }, h("label", { key: 'b9eaa4d53de58d78d7f968d18b021c9cfe013502', 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": getBooleanAsString((_d = this.showIconLeading) !== null && _d !== void 0 ? _d : this.showIcon), "data-show-icon-trailing": getBooleanAsString(this.showIconTrailing), "data-no-text": getBooleanAsString(this.noText) }, h("input", { key: '81cf38a1a39e88fc85282e8b82d43768ce6f70a4', type: "radio", role: "tab", disabled: getBoolean(this.disabled, "disabled"), "aria-selected": this._selected, checked: getBoolean(this.checked, "checked"), ref: (el) => {
178
116
  this._ref = el;
179
- }, "aria-label": getBoolean(this.noText) ? this.label : undefined, "aria-selected": (this.active !== undefined
180
- ? getBoolean(this.active)
181
- : this.internalActive)
182
- ? "true"
183
- : "false", "aria-controls": this.ariaControls, disabled: getBoolean(this.disabled) ? true : undefined, tabIndex: this.getCurrentTabIndex(), id: this.id, "data-active": this.active !== undefined
184
- ? getBoolean(this.active)
185
- : this.internalActive, "data-no-text": getBoolean(this.noText) ? "true" : undefined, "data-value": this.value, onClick: (event) => this.handleClick(event) }, !this.noText ? (h("span", { class: "db-tab-label", title: "", ref: (el) => {
186
- this._labelRef = el;
187
- }, "data-icon": getBoolean((_a = this.showIconLeading) !== null && _a !== void 0 ? _a : this.showIcon)
188
- ? (_b = this.iconLeading) !== null && _b !== void 0 ? _b : this.icon
189
- : undefined, "data-icon-trailing": getBoolean(this.showIconTrailing) ? this.iconTrailing : undefined }, this.label ? this.label : null, !this.label ? h("slot", null) : null)) : null, getBoolean(this.noText) ? (h("span", { class: "db-tab-label", "aria-hidden": "true", "data-icon": getBoolean((_c = this.showIconLeading) !== null && _c !== void 0 ? _c : this.showIcon)
190
- ? (_d = this.iconLeading) !== null && _d !== void 0 ? _d : this.icon
191
- : undefined })) : null, this.isTruncated && this.tooltipText ? (h("db-tooltip", { placement: "right" }, this.tooltipText)) : null));
117
+ }, 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, h("slot", { key: '89a4ba46af36e8dcc3bc53f87d17977c5827cd12' }))));
192
118
  }
193
119
  static get watchers() { return {
194
- "active": [{
120
+ "_ref": [{
121
+ "watch0": 0
122
+ }],
123
+ "initialized": [{
195
124
  "watch0": 0
125
+ }],
126
+ "boundSetSelectedOnChange": [{
127
+ "watch0": 0
128
+ }],
129
+ "name": [{
130
+ "watch1": 0
196
131
  }]
197
132
  }; }
198
133
  };
@@ -200,7 +135,6 @@ const DBTabItem = class {
200
135
  const DBTabList = class {
201
136
  constructor(hostRef) {
202
137
  registerInstance(this, hostRef);
203
- this._id = "tab-list-base-id";
204
138
  }
205
139
  /**
206
140
  * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
@@ -240,12 +174,12 @@ const DBTabList = class {
240
174
  }
241
175
  componentDidLoad() {
242
176
  this.enableAttributePassing(this._ref, "db-tab-list");
243
- this._id = this.id || "tab-list-" + uuid();
244
177
  }
245
178
  render() {
246
- return (h("div", { key: 'd6e9d47968f44e65f2c0f400a4141917e2035727', class: cls("db-tab-list", this.className), role: "tablist", ref: (el) => {
179
+ var _a, _b;
180
+ return (h("div", { key: '8f02145864a04b79d94d5d5923b6eff32346a0c3', class: cls("db-tab-list", this.className), ref: (el) => {
247
181
  this._ref = el;
248
- }, id: this._id, "aria-orientation": this.orientation || "horizontal", "aria-label": this.ariaLabelledby ? undefined : this.ariaLabel, "aria-labelledby": this.ariaLabelledby }, h("slot", { key: 'dafa7344fceee4c2cb0fd3d364509c41e4686e6d' })));
182
+ }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id }, h("ul", { key: '759fdba6e69209ca915148c8b190f9311cb6f1ff', role: "tablist" }, h("slot", { key: '96bf4a10d3b422d6eb6be68c46f926b9f55eb0e6' }))));
249
183
  }
250
184
  };
251
185
 
@@ -294,9 +228,9 @@ const DBTabPanel = class {
294
228
  }
295
229
  render() {
296
230
  var _a, _b;
297
- return (h("div", { key: '231689474d2f2b3acfa8e8aed736b3a76559daf9', class: cls("db-tab-panel", this.className), role: "tabpanel", ref: (el) => {
231
+ return (h("section", { key: 'c10873d5857be6ea8653189ab735784939c53474', class: cls("db-tab-panel", this.className), role: "tabpanel", ref: (el) => {
298
232
  this._ref = el;
299
- }, id: (_a = this.id) !== null && _a !== void 0 ? _a : (_b = this.propOverrides) === null || _b === void 0 ? void 0 : _b.id, tabIndex: this.hidden ? -1 : 0, hidden: this.hidden, "aria-label": this.ariaLabel, "aria-labelledby": this.ariaLabel ? undefined : this.ariaLabelledby }, this.content ? this.content : null, h("slot", { key: 'eb72a30d12dcd1bce44b0a2b61d2c486ec779d16' })));
233
+ }, 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, h("slot", { key: '57a98a1b7e26ca61b16397b7615f71d883bfbd28' })));
300
234
  }
301
235
  };
302
236