@sixbell-telco/sdk 4.2.0 → 4.4.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 (268) hide show
  1. package/CHANGELOG.md +108 -1
  2. package/README.md +98 -66
  3. package/_index.css +2 -1586
  4. package/components/accordion/accordion-item/accordion-item.component.d.ts +1 -1
  5. package/components/alert/README.md +27 -0
  6. package/components/alert/index.d.ts +5 -0
  7. package/components/alert/public-api.d.ts +1 -0
  8. package/components/alert/src/alert.component.d.ts +85 -0
  9. package/components/audio-player/audio-timeline/audio-timeline.component.d.ts +1 -1
  10. package/components/audio-player/button-play/button-play.component.d.ts +7 -7
  11. package/components/audio-player/src/audio-player.component.d.ts +2 -2
  12. package/components/audio-player/volume-control/volume-control.component.d.ts +1 -1
  13. package/components/avatar/README.md +1 -0
  14. package/components/avatar/src/avatar.component.d.ts +2 -2
  15. package/components/badge/src/badge.component.d.ts +4 -4
  16. package/components/button/README.md +5 -4
  17. package/components/button/src/button.component.d.ts +38 -16
  18. package/components/card/README.md +2 -0
  19. package/components/card/card-footer/card-footer.component.d.ts +37 -2
  20. package/components/card/card-section-group/card-section-group.component.d.ts +1 -1
  21. package/components/card/src/card.component.d.ts +6 -6
  22. package/components/countdown/src/countdown.component.d.ts +4 -4
  23. package/components/data-table/README.md +26 -0
  24. package/components/data-table/expandable/expandable.component.d.ts +4 -4
  25. package/components/data-table/sortable-header/sortable-header.component.d.ts +1 -1
  26. package/components/data-table/src/data-table.component.d.ts +15 -8
  27. package/components/data-table/sub-component-toggle/sub-component-toggle.component.d.ts +1 -1
  28. package/components/description-list/README.md +27 -0
  29. package/components/description-list/index.d.ts +5 -0
  30. package/components/description-list/public-api.d.ts +1 -0
  31. package/components/description-list/src/description-list.component.d.ts +90 -0
  32. package/components/dialog/README.md +10 -6
  33. package/components/dialog/dialog-actions/dialog-actions.component.d.ts +4 -0
  34. package/components/dialog/src/dialog.component.d.ts +27 -6
  35. package/components/dialog/src/fullscreen-block-scroll-strategy.d.ts +31 -0
  36. package/components/divider/src/divider.component.d.ts +1 -1
  37. package/components/dropdown/README.md +2 -2
  38. package/components/dropdown/dropdown-chevron/dropdown-chevron.component.d.ts +1 -1
  39. package/components/dropdown/dropdown-content/dropdown-content.component.d.ts +1 -1
  40. package/components/dropdown/dropdown-item/dropdown-item.component.d.ts +4 -4
  41. package/components/dropdown/dropdown-item-checkbox/dropdown-item-checkbox.component.d.ts +5 -5
  42. package/components/dropdown/dropdown-item-radio/dropdown-item-radio.component.d.ts +5 -5
  43. package/components/dropdown/dropdown-trigger/dropdown-trigger.component.d.ts +11 -14
  44. package/components/dropdown-menu/README.md +2 -2
  45. package/components/dropdown-menu/bar/dropdown-menu-bar/dropdown-menu-bar.component.d.ts +1 -1
  46. package/components/dropdown-menu/bar/dropdown-menu-bar-content/dropdown-menu-bar-content.component.d.ts +6 -2
  47. package/components/dropdown-menu/bar/dropdown-menu-bar-item/dropdown-menu-bar-item.component.d.ts +3 -3
  48. package/components/dropdown-menu/bar/dropdown-menu-bar-item-checkbox/dropdown-menu-bar-item-checkbox.component.d.ts +4 -4
  49. package/components/dropdown-menu/bar/dropdown-menu-bar-item-radio/dropdown-menu-bar-item-radio.component.d.ts +4 -4
  50. package/components/dropdown-menu/bar/dropdown-menu-bar-sub-trigger/dropdown-menu-bar-sub-trigger.component.d.ts +3 -1
  51. package/components/dropdown-menu/bar/dropdown-menu-bar-trigger/dropdown-menu-bar-trigger.component.d.ts +3 -1
  52. package/components/dropdown-menu/context/dropdown-context-menu-trigger/dropdown-context-menu-trigger.component.d.ts +2 -1
  53. package/components/dropdown-menu/dropdown-menu-chevron/dropdown-menu-chevron.component.d.ts +1 -1
  54. package/components/dropdown-menu/src/dropdown-menu-content/dropdown-menu-content.component.d.ts +2 -0
  55. package/components/dropdown-menu/src/dropdown-menu-item/dropdown-menu-item.component.d.ts +3 -3
  56. package/components/dropdown-menu/src/dropdown-menu-sub-content/dropdown-menu-sub-content.component.d.ts +2 -0
  57. package/components/dropdown-menu/src/dropdown-menu-sub-trigger/dropdown-menu-sub-trigger.component.d.ts +2 -1
  58. package/components/dropdown-menu/src/dropdown-menu-trigger/dropdown-menu-trigger.component.d.ts +1 -0
  59. package/components/empty-state/README.md +40 -0
  60. package/components/empty-state/index.d.ts +5 -0
  61. package/components/empty-state/public-api.d.ts +1 -0
  62. package/components/empty-state/src/empty-state.component.d.ts +73 -0
  63. package/components/file-upload/file-dropzone/file-dropzone.component.d.ts +4 -4
  64. package/components/file-upload/file-uploader/file-uploader.component.d.ts +2 -2
  65. package/components/forms/checkbox/src/checkbox.component.d.ts +1 -1
  66. package/components/forms/combobox/README.md +2 -1
  67. package/components/forms/combobox/src/combobox.component.d.ts +31 -18
  68. package/components/forms/date-picker/src/date-picker.component.d.ts +16 -9
  69. package/components/forms/form-hint/README.md +29 -0
  70. package/components/forms/form-hint/index.d.ts +5 -0
  71. package/components/forms/form-hint/public-api.d.ts +1 -0
  72. package/components/forms/form-hint/src/form-hint.component.d.ts +38 -0
  73. package/components/forms/form-item/src/form-item.component.d.ts +45 -1
  74. package/components/forms/input/src/input.component.d.ts +15 -8
  75. package/components/forms/radio/src/radio.component.d.ts +1 -1
  76. package/components/forms/range/src/range.component.d.ts +18 -4
  77. package/components/forms/select/README.md +2 -1
  78. package/components/forms/select/src/select.component.d.ts +30 -16
  79. package/components/forms/switch/src/switch.component.d.ts +1 -1
  80. package/components/forms/textarea/src/textarea.component.d.ts +12 -5
  81. package/components/forms/toggle/src/toggle.component.d.ts +1 -1
  82. package/components/notification/src/notification.component.d.ts +1 -1
  83. package/components/overlay/README.md +7 -2
  84. package/components/overlay/overlay-trigger/overlay-trigger.component.d.ts +1 -1
  85. package/components/overlay/src/overlay.component.d.ts +10 -9
  86. package/components/paginator/components/pagination-item/pagination-item.component.d.ts +3 -3
  87. package/components/progress/src/progress.component.d.ts +1 -1
  88. package/components/segmented-button/README.md +57 -0
  89. package/components/segmented-button/index.d.ts +5 -0
  90. package/components/segmented-button/public-api.d.ts +1 -0
  91. package/components/segmented-button/src/segmented-button.component.d.ts +110 -0
  92. package/components/sonner/toaster/src/toaster.component.d.ts +3 -3
  93. package/components/tab/src/tab.component.d.ts +2 -2
  94. package/components/table/README.md +51 -3
  95. package/components/table/public-api.d.ts +1 -0
  96. package/components/table/src/table.component.d.ts +20 -13
  97. package/components/table/table-action/table-action.component.d.ts +14 -3
  98. package/components/table/table-actions/table-actions.component.d.ts +12 -1
  99. package/components/table/tokens/README.md +7 -0
  100. package/components/table/tokens/index.d.ts +5 -0
  101. package/components/table/tokens/public-api.d.ts +1 -0
  102. package/components/table/tokens/table-empty-state.d.ts +6 -0
  103. package/components/tooltip/README.md +25 -7
  104. package/components/tooltip/src/tooltip.component.d.ts +44 -12
  105. package/components/tree/README.md +73 -0
  106. package/components/tree/index.d.ts +5 -0
  107. package/components/tree/public-api.d.ts +1 -0
  108. package/components/tree/src/tree.component.d.ts +180 -0
  109. package/components/wizard/README.md +9 -0
  110. package/components/wizard/wizard-content/wizard-content.component.d.ts +1 -1
  111. package/components/wizard/wizard-wrapper/wizard-wrapper.component.d.ts +15 -6
  112. package/directives/auto-focus/src/auto-focus.directive.d.ts +1 -1
  113. package/directives/only-numbers/src/only-numbers.directive.d.ts +1 -1
  114. package/directives/truncate/README.md +49 -0
  115. package/directives/truncate/index.d.ts +5 -0
  116. package/directives/truncate/public-api.d.ts +1 -0
  117. package/directives/truncate/src/truncate-popover.component.d.ts +11 -0
  118. package/directives/truncate/src/truncate.directive.d.ts +96 -0
  119. package/fesm2022/sixbell-telco-sdk-components-accordion.mjs +2 -2
  120. package/fesm2022/sixbell-telco-sdk-components-accordion.mjs.map +1 -1
  121. package/fesm2022/sixbell-telco-sdk-components-alert.mjs +152 -0
  122. package/fesm2022/sixbell-telco-sdk-components-alert.mjs.map +1 -0
  123. package/fesm2022/sixbell-telco-sdk-components-audio-player.mjs +15 -15
  124. package/fesm2022/sixbell-telco-sdk-components-audio-player.mjs.map +1 -1
  125. package/fesm2022/sixbell-telco-sdk-components-avatar.mjs +4 -4
  126. package/fesm2022/sixbell-telco-sdk-components-avatar.mjs.map +1 -1
  127. package/fesm2022/sixbell-telco-sdk-components-badge.mjs +5 -5
  128. package/fesm2022/sixbell-telco-sdk-components-badge.mjs.map +1 -1
  129. package/fesm2022/sixbell-telco-sdk-components-button.mjs +53 -19
  130. package/fesm2022/sixbell-telco-sdk-components-button.mjs.map +1 -1
  131. package/fesm2022/sixbell-telco-sdk-components-card.mjs +61 -14
  132. package/fesm2022/sixbell-telco-sdk-components-card.mjs.map +1 -1
  133. package/fesm2022/sixbell-telco-sdk-components-countdown.mjs +5 -5
  134. package/fesm2022/sixbell-telco-sdk-components-countdown.mjs.map +1 -1
  135. package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs +3 -3
  136. package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs.map +1 -1
  137. package/fesm2022/sixbell-telco-sdk-components-data-table.mjs +34 -33
  138. package/fesm2022/sixbell-telco-sdk-components-data-table.mjs.map +1 -1
  139. package/fesm2022/sixbell-telco-sdk-components-description-list.mjs +200 -0
  140. package/fesm2022/sixbell-telco-sdk-components-description-list.mjs.map +1 -0
  141. package/fesm2022/sixbell-telco-sdk-components-dialog.mjs +128 -17
  142. package/fesm2022/sixbell-telco-sdk-components-dialog.mjs.map +1 -1
  143. package/fesm2022/sixbell-telco-sdk-components-divider.mjs +2 -2
  144. package/fesm2022/sixbell-telco-sdk-components-divider.mjs.map +1 -1
  145. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs +33 -24
  146. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs.map +1 -1
  147. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-context.mjs +7 -3
  148. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-context.mjs.map +1 -1
  149. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu.mjs +25 -14
  150. package/fesm2022/sixbell-telco-sdk-components-dropdown-menu.mjs.map +1 -1
  151. package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs +43 -72
  152. package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs.map +1 -1
  153. package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs +1 -1
  154. package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs.map +1 -1
  155. package/fesm2022/sixbell-telco-sdk-components-empty-state.mjs +131 -0
  156. package/fesm2022/sixbell-telco-sdk-components-empty-state.mjs.map +1 -0
  157. package/fesm2022/sixbell-telco-sdk-components-file-upload.mjs +9 -9
  158. package/fesm2022/sixbell-telco-sdk-components-file-upload.mjs.map +1 -1
  159. package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs +2 -2
  160. package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs.map +1 -1
  161. package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs +104 -72
  162. package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs.map +1 -1
  163. package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs +23 -12
  164. package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs.map +1 -1
  165. package/fesm2022/sixbell-telco-sdk-components-forms-form-hint.mjs +81 -0
  166. package/fesm2022/sixbell-telco-sdk-components-forms-form-hint.mjs.map +1 -0
  167. package/fesm2022/sixbell-telco-sdk-components-forms-form-item.mjs +45 -3
  168. package/fesm2022/sixbell-telco-sdk-components-forms-form-item.mjs.map +1 -1
  169. package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs +27 -13
  170. package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs.map +1 -1
  171. package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs +2 -2
  172. package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs.map +1 -1
  173. package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs +29 -7
  174. package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs.map +1 -1
  175. package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs +84 -56
  176. package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs.map +1 -1
  177. package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs +2 -2
  178. package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs.map +1 -1
  179. package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs +27 -22
  180. package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs.map +1 -1
  181. package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs +2 -2
  182. package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs.map +1 -1
  183. package/fesm2022/sixbell-telco-sdk-components-notification.mjs +2 -2
  184. package/fesm2022/sixbell-telco-sdk-components-notification.mjs.map +1 -1
  185. package/fesm2022/sixbell-telco-sdk-components-overlay.mjs +41 -79
  186. package/fesm2022/sixbell-telco-sdk-components-overlay.mjs.map +1 -1
  187. package/fesm2022/sixbell-telco-sdk-components-paginator.mjs +4 -4
  188. package/fesm2022/sixbell-telco-sdk-components-paginator.mjs.map +1 -1
  189. package/fesm2022/sixbell-telco-sdk-components-progress.mjs +2 -2
  190. package/fesm2022/sixbell-telco-sdk-components-progress.mjs.map +1 -1
  191. package/fesm2022/sixbell-telco-sdk-components-segmented-button.mjs +329 -0
  192. package/fesm2022/sixbell-telco-sdk-components-segmented-button.mjs.map +1 -0
  193. package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs +4 -4
  194. package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs.map +1 -1
  195. package/fesm2022/sixbell-telco-sdk-components-sonner.mjs +4 -4
  196. package/fesm2022/sixbell-telco-sdk-components-sonner.mjs.map +1 -1
  197. package/fesm2022/sixbell-telco-sdk-components-tab.mjs +3 -3
  198. package/fesm2022/sixbell-telco-sdk-components-tab.mjs.map +1 -1
  199. package/fesm2022/sixbell-telco-sdk-components-table-tokens.mjs +14 -0
  200. package/fesm2022/sixbell-telco-sdk-components-table-tokens.mjs.map +1 -0
  201. package/fesm2022/sixbell-telco-sdk-components-table.mjs +63 -32
  202. package/fesm2022/sixbell-telco-sdk-components-table.mjs.map +1 -1
  203. package/fesm2022/sixbell-telco-sdk-components-tooltip.mjs +187 -75
  204. package/fesm2022/sixbell-telco-sdk-components-tooltip.mjs.map +1 -1
  205. package/fesm2022/sixbell-telco-sdk-components-tree.mjs +478 -0
  206. package/fesm2022/sixbell-telco-sdk-components-tree.mjs.map +1 -0
  207. package/fesm2022/sixbell-telco-sdk-components-wizard.mjs +18 -9
  208. package/fesm2022/sixbell-telco-sdk-components-wizard.mjs.map +1 -1
  209. package/fesm2022/sixbell-telco-sdk-directives-auto-focus.mjs +2 -2
  210. package/fesm2022/sixbell-telco-sdk-directives-auto-focus.mjs.map +1 -1
  211. package/fesm2022/sixbell-telco-sdk-directives-only-numbers.mjs +2 -2
  212. package/fesm2022/sixbell-telco-sdk-directives-only-numbers.mjs.map +1 -1
  213. package/fesm2022/sixbell-telco-sdk-directives-truncate.mjs +339 -0
  214. package/fesm2022/sixbell-telco-sdk-directives-truncate.mjs.map +1 -0
  215. package/fesm2022/sixbell-telco-sdk-layouts.mjs +69 -41
  216. package/fesm2022/sixbell-telco-sdk-layouts.mjs.map +1 -1
  217. package/fesm2022/sixbell-telco-sdk-utils-date.mjs +15 -2
  218. package/fesm2022/sixbell-telco-sdk-utils-date.mjs.map +1 -1
  219. package/fesm2022/sixbell-telco-sdk-utils-mfe.mjs +87 -2
  220. package/fesm2022/sixbell-telco-sdk-utils-mfe.mjs.map +1 -1
  221. package/fesm2022/sixbell-telco-sdk-utils-popover-motion.mjs +186 -0
  222. package/fesm2022/sixbell-telco-sdk-utils-popover-motion.mjs.map +1 -0
  223. package/fesm2022/sixbell-telco-sdk-utils-theme.mjs +234 -4
  224. package/fesm2022/sixbell-telco-sdk-utils-theme.mjs.map +1 -1
  225. package/fesm2022/sixbell-telco-sdk-utils-translation-testing.mjs +203 -0
  226. package/fesm2022/sixbell-telco-sdk-utils-translation-testing.mjs.map +1 -0
  227. package/fesm2022/sixbell-telco-sdk-utils-translation.mjs +129 -14
  228. package/fesm2022/sixbell-telco-sdk-utils-translation.mjs.map +1 -1
  229. package/fesm2022/sixbell-telco-sdk-utils-unsaved-changes.mjs +150 -0
  230. package/fesm2022/sixbell-telco-sdk-utils-unsaved-changes.mjs.map +1 -0
  231. package/i18n/sdk/en.json +224 -0
  232. package/i18n/sdk/es.json +224 -0
  233. package/i18n/sdk/pt.json +224 -0
  234. package/layouts/README.md +18 -11
  235. package/layouts/public-api.d.ts +1 -1
  236. package/layouts/src/app-layout/app-layout.component.d.ts +11 -8
  237. package/layouts/src/layout.config.d.ts +1 -1
  238. package/layouts/src/menu/menu-active.d.ts +2 -1
  239. package/layouts/src/menu/menu-url.d.ts +2 -0
  240. package/layouts/src/navbar/navbar.component.d.ts +5 -5
  241. package/layouts/src/page-banner/page-banner.component.d.ts +19 -2
  242. package/layouts/src/side-menu/side-menu.component.d.ts +2 -2
  243. package/layouts/src/user-menu/user-menu.component.d.ts +5 -5
  244. package/package.json +64 -20
  245. package/src/_index.css +1701 -0
  246. package/utils/mfe/README.md +1 -0
  247. package/utils/mfe/src/hoist-property-rules.d.ts +13 -0
  248. package/utils/mfe/src/mfe-shadow-shell.component.d.ts +3 -0
  249. package/utils/popover-motion/README.md +38 -0
  250. package/utils/popover-motion/index.d.ts +5 -0
  251. package/utils/popover-motion/public-api.d.ts +2 -0
  252. package/utils/popover-motion/src/popover-menu-motion.d.ts +37 -0
  253. package/utils/popover-motion/src/popover-motion.d.ts +31 -0
  254. package/utils/theme/README.md +94 -1
  255. package/utils/theme/public-api.d.ts +2 -1
  256. package/utils/theme/src/models/theme.d.ts +32 -0
  257. package/utils/theme/src/overlay/theme-overlay.d.ts +33 -0
  258. package/utils/theme/src/providers/theme.provider.types.d.ts +7 -0
  259. package/utils/translation/README.md +63 -0
  260. package/utils/translation/src/translation.service.d.ts +24 -0
  261. package/utils/translation/testing/index.d.ts +5 -0
  262. package/utils/translation/testing/public-api.d.ts +2 -0
  263. package/utils/translation/testing/src/translation-testing.d.ts +96 -0
  264. package/utils/unsaved-changes/README.md +33 -0
  265. package/utils/unsaved-changes/index.d.ts +5 -0
  266. package/utils/unsaved-changes/public-api.d.ts +1 -0
  267. package/utils/unsaved-changes/src/unsaved-changes-dialog.component.d.ts +24 -0
  268. package/utils/unsaved-changes/src/unsaved-changes.d.ts +50 -0
@@ -1,6 +1,6 @@
1
1
  import { CommonModule } from '@angular/common';
2
2
  import * as i0 from '@angular/core';
3
- import { inject, ElementRef, NgZone, input, output, computed, isDevMode, afterRenderEffect, DestroyRef, ChangeDetectionStrategy, Component } from '@angular/core';
3
+ import { inject, ElementRef, NgZone, input, booleanAttribute, output, computed, isDevMode, afterRenderEffect, DestroyRef, ChangeDetectionStrategy, Component } from '@angular/core';
4
4
  import { IconComponent } from '@sixbell-telco/sdk/components/icon';
5
5
  import { cn } from '@sixbell-telco/sdk/utils/cn';
6
6
  import { cva } from 'class-variance-authority';
@@ -19,7 +19,7 @@ const hasAccessibleName = (button) => !!(button.getAttribute('aria-label')?.trim
19
19
  const buttonComponent = cva(['btn', 'text-pretty', 'font-body', 'font-medium', 'leading-normal', 'items-center', 'align-middle'], {
20
20
  variants: {
21
21
  variant: {
22
- base: [],
22
+ base: ['btn-base'],
23
23
  primary: ['btn-primary'],
24
24
  secondary: ['btn-secondary'],
25
25
  tertiary: ['btn-tertiary'],
@@ -71,6 +71,7 @@ class ButtonComponent {
71
71
  host = inject(ElementRef);
72
72
  zone = inject(NgZone);
73
73
  unnamedIconWarned = false;
74
+ roleWarned = false;
74
75
  nameWatch = null;
75
76
  /**
76
77
  * Button style variant
@@ -81,57 +82,57 @@ class ButtonComponent {
81
82
  * Ghost button style (transparent background)
82
83
  * @defaultValue false
83
84
  */
84
- ghost = input(false);
85
+ ghost = input(false, { transform: booleanAttribute });
85
86
  /**
86
87
  * Outline button style (border with transparent fill)
87
88
  * @defaultValue false
88
89
  */
89
- outline = input(false);
90
+ outline = input(false, { transform: booleanAttribute });
90
91
  /**
91
92
  * Link button style (appears as a hyperlink)
92
93
  * @defaultValue false
93
94
  */
94
- link = input(false);
95
+ link = input(false, { transform: booleanAttribute });
95
96
  /**
96
97
  * Soft button style (muted/subdued color variant)
97
98
  * @defaultValue false
98
99
  */
99
- soft = input(false);
100
+ soft = input(false, { transform: booleanAttribute });
100
101
  /**
101
102
  * Dash button style (dashed border)
102
103
  * @defaultValue false
103
104
  */
104
- dash = input(false);
105
+ dash = input(false, { transform: booleanAttribute });
105
106
  /**
106
107
  * Wide button style (increased horizontal padding)
107
108
  * @defaultValue false
108
109
  */
109
- wide = input(false);
110
+ wide = input(false, { transform: booleanAttribute });
110
111
  /**
111
112
  * Circular button shape
112
113
  * @defaultValue false
113
114
  */
114
- circle = input(false);
115
+ circle = input(false, { transform: booleanAttribute });
115
116
  /**
116
117
  * Square button shape
117
118
  * @defaultValue false
118
119
  */
119
- square = input(false);
120
+ square = input(false, { transform: booleanAttribute });
120
121
  /**
121
122
  * Glass effect styling
122
123
  * @defaultValue false
123
124
  */
124
- glass = input(false);
125
+ glass = input(false, { transform: booleanAttribute });
125
126
  /**
126
127
  * Full-width button
127
128
  * @defaultValue false
128
129
  */
129
- block = input(false);
130
+ block = input(false, { transform: booleanAttribute });
130
131
  /**
131
132
  * Show loading spinner
132
133
  * @defaultValue false
133
134
  */
134
- loader = input(false);
135
+ loader = input(false, { transform: booleanAttribute });
135
136
  /**
136
137
  * Button size variant
137
138
  * @defaultValue 'md'
@@ -141,12 +142,12 @@ class ButtonComponent {
141
142
  * Add drop shadow
142
143
  * @defaultValue false
143
144
  */
144
- shadow = input(false);
145
+ shadow = input(false, { transform: booleanAttribute });
145
146
  /**
146
147
  * Button is focusable
147
148
  * @defaultValue true
148
149
  */
149
- focusable = input(true);
150
+ focusable = input(true, { transform: booleanAttribute });
150
151
  /**
151
152
  * Icon name (from icon library)
152
153
  */
@@ -165,12 +166,12 @@ class ButtonComponent {
165
166
  * Disabled state
166
167
  * @defaultValue false
167
168
  */
168
- disabled = input(false);
169
+ disabled = input(false, { transform: booleanAttribute });
169
170
  /**
170
171
  * Stop event propagation for activation events
171
172
  * @defaultValue false
172
173
  */
173
- stopPropagation = input(false);
174
+ stopPropagation = input(false, { transform: booleanAttribute });
174
175
  /**
175
176
  * Accessible name forwarded to the inner `<button>` as `aria-label`.
176
177
  * Use it for icon-only buttons. Attributes bound on the `st-button` host are not forwarded.
@@ -186,6 +187,15 @@ class ButtonComponent {
186
187
  * Leave it unset for ordinary buttons.
187
188
  */
188
189
  ariaPressed = input();
190
+ /**
191
+ * Forwarded to the inner `<button>` as `aria-describedby`: the id(s) of elements that describe it,
192
+ * such as a notice that explains why the button is disabled.
193
+ */
194
+ ariaDescribedBy = input();
195
+ /**
196
+ * Forwarded to the inner `<button>` as `aria-controls`: the id(s) of the elements the button shows, hides or resizes.
197
+ */
198
+ ariaControls = input();
189
199
  /**
190
200
  * Event emitted on click
191
201
  */
@@ -227,7 +237,16 @@ class ButtonComponent {
227
237
  'w-full': this.block(),
228
238
  'btn-loading': this.loader(),
229
239
  'shadow-main': this.shadow(),
240
+ 'aria-pressed:inset-ring-base-content aria-pressed:inset-ring': this.isBaseToggleable() && !this.dash(),
241
+ 'aria-pressed:border-[calc(var(--border)*2)] aria-pressed:border-dashed': this.isBaseToggleable() && this.dash(),
242
+ 'aria-pressed:px-[calc(var(--btn-p)-var(--border))]': this.isBaseToggleable() && this.dash() && !this.circle() && !this.square(),
230
243
  }));
244
+ /**
245
+ * @internal A base outline/dash toggle differs from rest only by a light tint when pressed, so
246
+ * `aria-pressed="true"` also doubles its border: an inset `base-content` ring for outline, and twice the
247
+ * dashed border width for dash (the padding shrinks by the same amount, so nothing shifts).
248
+ */
249
+ isBaseToggleable = computed(() => (this.variant() ?? 'base') === 'base' && (this.outline() || this.dash()));
231
250
  linkClass = computed(() => {
232
251
  return cn('link font-body inline-flex items-center gap-1 align-middle leading-normal font-normal no-underline', this.iconPosition(), {
233
252
  'link-primary': this.variant() === 'primary',
@@ -252,6 +271,7 @@ class ButtonComponent {
252
271
  if (this.icon())
253
272
  this.watchAccessibleName();
254
273
  });
274
+ afterRenderEffect(() => this.checkDeclaredRole());
255
275
  inject(DestroyRef).onDestroy(() => this.stopNameWatch());
256
276
  }
257
277
  }
@@ -294,6 +314,20 @@ class ButtonComponent {
294
314
  this.unnamedIconWarned = true;
295
315
  console.warn('[st-button] An icon-only st-button has no accessible name. Set `ariaLabel` or project visually hidden text (`<span class="sr-only">`).', this.host.nativeElement);
296
316
  }
317
+ /**
318
+ * @internal
319
+ * Dev mode only: warns once when a filled or outlined button has no declared role. `base` is meant
320
+ * for `ghost` and `link` buttons; every other button should say what it does with a color variant.
321
+ */
322
+ checkDeclaredRole() {
323
+ if (this.roleWarned)
324
+ return;
325
+ const variant = this.variant();
326
+ if (this.ghost() || this.link() || (variant && variant !== 'base'))
327
+ return;
328
+ this.roleWarned = true;
329
+ console.warn('[st-button] This st-button has no role variant. Set `variant` to `primary`, `secondary`, `tertiary` or a status color; keep `base` (or no variant) for `ghost` and `link` buttons only.', this.host.nativeElement);
330
+ }
297
331
  stopNameWatch() {
298
332
  this.nameWatch?.observer?.disconnect();
299
333
  clearTimeout(this.nameWatch?.timer);
@@ -349,11 +383,11 @@ class ButtonComponent {
349
383
  this.keyDownSpace.emit(event);
350
384
  }
351
385
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.25", ngImport: i0, type: ButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
352
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.25", type: ButtonComponent, isStandalone: true, selector: "st-button", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, ghost: { classPropertyName: "ghost", publicName: "ghost", isSignal: true, isRequired: false, transformFunction: null }, outline: { classPropertyName: "outline", publicName: "outline", isSignal: true, isRequired: false, transformFunction: null }, link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, soft: { classPropertyName: "soft", publicName: "soft", isSignal: true, isRequired: false, transformFunction: null }, dash: { classPropertyName: "dash", publicName: "dash", isSignal: true, isRequired: false, transformFunction: null }, wide: { classPropertyName: "wide", publicName: "wide", isSignal: true, isRequired: false, transformFunction: null }, circle: { classPropertyName: "circle", publicName: "circle", isSignal: true, isRequired: false, transformFunction: null }, square: { classPropertyName: "square", publicName: "square", isSignal: true, isRequired: false, transformFunction: null }, glass: { classPropertyName: "glass", publicName: "glass", isSignal: true, isRequired: false, transformFunction: null }, block: { classPropertyName: "block", publicName: "block", isSignal: true, isRequired: false, transformFunction: null }, loader: { classPropertyName: "loader", publicName: "loader", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, shadow: { classPropertyName: "shadow", publicName: "shadow", isSignal: true, isRequired: false, transformFunction: null }, focusable: { classPropertyName: "focusable", publicName: "focusable", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, stopPropagation: { classPropertyName: "stopPropagation", publicName: "stopPropagation", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaExpanded: { classPropertyName: "ariaExpanded", publicName: "ariaExpanded", isSignal: true, isRequired: false, transformFunction: null }, ariaPressed: { classPropertyName: "ariaPressed", publicName: "ariaPressed", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { clicked: "clicked", pointerDown: "pointerDown", keyDownEnter: "keyDownEnter", keyDownSpace: "keyDownSpace", triggered: "triggered" }, ngImport: i0, template: "@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n", styles: [""], dependencies: [{ kind: "component", type: IconComponent, selector: "st-icon", inputs: ["color", "size", "icon", "ariaLabel"] }, { kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
386
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.25", type: ButtonComponent, isStandalone: true, selector: "st-button", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, ghost: { classPropertyName: "ghost", publicName: "ghost", isSignal: true, isRequired: false, transformFunction: null }, outline: { classPropertyName: "outline", publicName: "outline", isSignal: true, isRequired: false, transformFunction: null }, link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, soft: { classPropertyName: "soft", publicName: "soft", isSignal: true, isRequired: false, transformFunction: null }, dash: { classPropertyName: "dash", publicName: "dash", isSignal: true, isRequired: false, transformFunction: null }, wide: { classPropertyName: "wide", publicName: "wide", isSignal: true, isRequired: false, transformFunction: null }, circle: { classPropertyName: "circle", publicName: "circle", isSignal: true, isRequired: false, transformFunction: null }, square: { classPropertyName: "square", publicName: "square", isSignal: true, isRequired: false, transformFunction: null }, glass: { classPropertyName: "glass", publicName: "glass", isSignal: true, isRequired: false, transformFunction: null }, block: { classPropertyName: "block", publicName: "block", isSignal: true, isRequired: false, transformFunction: null }, loader: { classPropertyName: "loader", publicName: "loader", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, shadow: { classPropertyName: "shadow", publicName: "shadow", isSignal: true, isRequired: false, transformFunction: null }, focusable: { classPropertyName: "focusable", publicName: "focusable", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, stopPropagation: { classPropertyName: "stopPropagation", publicName: "stopPropagation", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaExpanded: { classPropertyName: "ariaExpanded", publicName: "ariaExpanded", isSignal: true, isRequired: false, transformFunction: null }, ariaPressed: { classPropertyName: "ariaPressed", publicName: "ariaPressed", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedBy: { classPropertyName: "ariaDescribedBy", publicName: "ariaDescribedBy", isSignal: true, isRequired: false, transformFunction: null }, ariaControls: { classPropertyName: "ariaControls", publicName: "ariaControls", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { clicked: "clicked", pointerDown: "pointerDown", keyDownEnter: "keyDownEnter", keyDownSpace: "keyDownSpace", triggered: "triggered" }, ngImport: i0, template: "@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t[attr.aria-describedby]=\"ariaDescribedBy() || null\"\n\t[attr.aria-controls]=\"ariaControls() || null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n", styles: [""], dependencies: [{ kind: "component", type: IconComponent, selector: "st-icon", inputs: ["color", "size", "icon", "ariaLabel"] }, { kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
353
387
  }
354
388
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImport: i0, type: ButtonComponent, decorators: [{
355
389
  type: Component,
356
- args: [{ selector: 'st-button', imports: [IconComponent, CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n" }]
390
+ args: [{ selector: 'st-button', imports: [IconComponent, CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t[attr.aria-describedby]=\"ariaDescribedBy() || null\"\n\t[attr.aria-controls]=\"ariaControls() || null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n" }]
357
391
  }], ctorParameters: () => [] });
358
392
 
359
393
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"sixbell-telco-sdk-components-button.mjs","sources":["../../../projects/sdk/components/button/src/button.component.ts","../../../projects/sdk/components/button/src/button.component.html","../../../projects/sdk/components/button/sixbell-telco-sdk-components-button.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport {\n\tafterRenderEffect,\n\tChangeDetectionStrategy,\n\tComponent,\n\tcomputed,\n\tDestroyRef,\n\tElementRef,\n\tinject,\n\tinput,\n\tisDevMode,\n\tNgZone,\n\toutput,\n} from '@angular/core';\nimport { IconComponent } from '@sixbell-telco/sdk/components/icon';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva } from 'class-variance-authority';\n\n/**\n * @internal\n * Generates base button classes with style variants\n */\n/** How long an icon-only button must stay unnamed, after its last DOM change, before the dev-mode warning. */\nconst UNNAMED_ICON_SETTLE_MS = 2000;\n\nconst hasAccessibleName = (button: HTMLButtonElement): boolean =>\n\t!!(\n\t\tbutton.getAttribute('aria-label')?.trim() ||\n\t\tbutton.getAttribute('aria-labelledby')?.trim() ||\n\t\tbutton.getAttribute('title')?.trim() ||\n\t\tbutton.textContent?.trim() ||\n\t\tbutton.querySelector('[role=\"img\"][aria-label]')\n\t);\n\nexport const buttonComponent = cva(['btn', 'text-pretty', 'font-body', 'font-medium', 'leading-normal', 'items-center', 'align-middle'], {\n\tvariants: {\n\t\tvariant: {\n\t\t\tbase: [],\n\t\t\tprimary: ['btn-primary'],\n\t\t\tsecondary: ['btn-secondary'],\n\t\t\ttertiary: ['btn-tertiary'],\n\t\t\taccent: ['btn-accent'],\n\t\t\tinfo: ['btn-info'],\n\t\t\tsuccess: ['btn-success'],\n\t\t\twarning: ['btn-warning'],\n\t\t\terror: ['btn-error'],\n\t\t},\n\t\tsize: {\n\t\t\txs: ['btn-xs'],\n\t\t\tsm: ['btn-sm'],\n\t\t\tmd: ['btn-md'],\n\t\t\tlg: ['btn-lg'],\n\t\t\txl: ['btn-xl'],\n\t\t},\n\t\ticonPosition: {\n\t\t\tleft: [''],\n\t\t\tright: ['flex-row-reverse'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\tvariant: 'base',\n\t\tsize: 'md',\n\t\ticonPosition: 'left',\n\t},\n});\n\n/** Possible button style variants */\nexport type ButtonVariantProps =\n\t'primary' | 'secondary' | 'tertiary' | 'accent' | 'info' | 'success' | 'warning' | 'error' | 'base' | null | undefined;\n\n/** Possible button size variants */\nexport type ButtonSizeProps = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | null | undefined;\n\n/** Possible icon positions relative to button text */\nexport type ButtonIconPositionProps = 'left' | 'right' | null | undefined;\n\n/** Configuration object for button styling variants */\nexport type ButtonProps = {\n\tvariant?: ButtonVariantProps;\n\tsize?: ButtonSizeProps;\n\ticonPosition?: ButtonIconPositionProps;\n};\n\n/** Valid HTML button types */\nexport type HTMLButtonType = 'button' | 'submit' | 'reset';\n\n/**\n * A customizable button component with multiple variants and icon support\n *\n * @remarks\n * Built with Tailwind CSS and class-variance-authority for style management.\n * Supports various styling variants, sizes, icon positions, and state modifiers.\n *\n * @example\n * ```html\n * <st-button\n * variant=\"primary\"\n * size=\"md\"\n * icon=\"check\"\n * iconPosition=\"left\"\n * >\n * Submit\n * </st-button>\n * ```\n */\n@Component({\n\tselector: 'st-button',\n\timports: [IconComponent, CommonModule],\n\ttemplateUrl: './button.component.html',\n\tstyles: '',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ButtonComponent {\n\tprivate readonly host: ElementRef<HTMLElement> = inject(ElementRef);\n\tprivate readonly zone = inject(NgZone);\n\tprivate unnamedIconWarned = false;\n\tprivate nameWatch: { observer?: MutationObserver; timer?: ReturnType<typeof setTimeout> } | null = null;\n\n\t/**\n\t * Button style variant\n\t * @defaultValue 'base'\n\t */\n\tvariant = input<ButtonVariantProps>();\n\n\t/**\n\t * Ghost button style (transparent background)\n\t * @defaultValue false\n\t */\n\tghost = input<boolean>(false);\n\n\t/**\n\t * Outline button style (border with transparent fill)\n\t * @defaultValue false\n\t */\n\toutline = input<boolean>(false);\n\n\t/**\n\t * Link button style (appears as a hyperlink)\n\t * @defaultValue false\n\t */\n\tlink = input<boolean>(false);\n\n\t/**\n\t * Soft button style (muted/subdued color variant)\n\t * @defaultValue false\n\t */\n\tsoft = input<boolean>(false);\n\n\t/**\n\t * Dash button style (dashed border)\n\t * @defaultValue false\n\t */\n\tdash = input<boolean>(false);\n\n\t/**\n\t * Wide button style (increased horizontal padding)\n\t * @defaultValue false\n\t */\n\twide = input<boolean>(false);\n\n\t/**\n\t * Circular button shape\n\t * @defaultValue false\n\t */\n\tcircle = input<boolean>(false);\n\n\t/**\n\t * Square button shape\n\t * @defaultValue false\n\t */\n\tsquare = input<boolean>(false);\n\n\t/**\n\t * Glass effect styling\n\t * @defaultValue false\n\t */\n\tglass = input<boolean>(false);\n\n\t/**\n\t * Full-width button\n\t * @defaultValue false\n\t */\n\tblock = input<boolean>(false);\n\n\t/**\n\t * Show loading spinner\n\t * @defaultValue false\n\t */\n\tloader = input<boolean>(false);\n\n\t/**\n\t * Button size variant\n\t * @defaultValue 'md'\n\t */\n\tsize = input<ButtonSizeProps>();\n\n\t/**\n\t * Add drop shadow\n\t * @defaultValue false\n\t */\n\tshadow = input<boolean>(false);\n\n\t/**\n\t * Button is focusable\n\t * @defaultValue true\n\t */\n\tfocusable = input<boolean>(true);\n\n\t/**\n\t * Icon name (from icon library)\n\t */\n\ticon = input<string | undefined>();\n\n\t/**\n\t * Position of icon relative to text\n\t * @defaultValue 'left'\n\t */\n\ticonPosition = input<ButtonIconPositionProps>();\n\n\t/**\n\t * HTML button type attribute\n\t * @defaultValue 'button'\n\t */\n\ttype = input<HTMLButtonType>('button');\n\n\t/**\n\t * Disabled state\n\t * @defaultValue false\n\t */\n\tdisabled = input<boolean>(false);\n\n\t/**\n\t * Stop event propagation for activation events\n\t * @defaultValue false\n\t */\n\tstopPropagation = input<boolean>(false);\n\n\t/**\n\t * Accessible name forwarded to the inner `<button>` as `aria-label`.\n\t * Use it for icon-only buttons. Attributes bound on the `st-button` host are not forwarded.\n\t */\n\tariaLabel = input<string | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-expanded`.\n\t * Set it only when the button shows or hides another region; leave it unset otherwise.\n\t */\n\tariaExpanded = input<boolean | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-pressed` for toggle buttons.\n\t * Leave it unset for ordinary buttons.\n\t */\n\tariaPressed = input<boolean | 'mixed' | null | undefined>();\n\n\t/**\n\t * Event emitted on click\n\t */\n\tclicked = output<MouseEvent>();\n\n\t/**\n\t * Event emitted on pointer down\n\t */\n\tpointerDown = output<PointerEvent>();\n\n\t/**\n\t * Event emitted on Enter keydown\n\t */\n\tkeyDownEnter = output<KeyboardEvent>();\n\n\t/**\n\t * Event emitted on Space keydown\n\t */\n\tkeyDownSpace = output<KeyboardEvent>();\n\n\t/**\n\t * Event emitted on activation (click or keyboard)\n\t */\n\ttriggered = output<void>();\n\n\t/**\n\t * @internal\n\t * Computed class string for the button container\n\t */\n\tcontainerClass = computed(() =>\n\t\tcn(\n\t\t\tbuttonComponent({\n\t\t\t\tvariant: this.variant(),\n\t\t\t\tsize: this.size(),\n\t\t\t\ticonPosition: this.iconPosition(),\n\t\t\t}),\n\t\t\t{\n\t\t\t\t'btn-ghost': this.ghost(),\n\t\t\t\t'btn-outline': this.outline(),\n\t\t\t\t'btn-link': this.link(),\n\t\t\t\t'btn-soft': this.soft(),\n\t\t\t\t'btn-dash': this.dash(),\n\t\t\t\t'btn-wide': this.wide(),\n\t\t\t\t'btn-circle': this.circle(),\n\t\t\t\t'btn-square': this.square(),\n\t\t\t\tglass: this.glass(),\n\t\t\t\t'w-full': this.block(),\n\t\t\t\t'btn-loading': this.loader(),\n\t\t\t\t'shadow-main': this.shadow(),\n\t\t\t},\n\t\t),\n\t);\n\n\tlinkClass = computed(() => {\n\t\treturn cn('link font-body inline-flex items-center gap-1 align-middle leading-normal font-normal no-underline', this.iconPosition(), {\n\t\t\t'link-primary': this.variant() === 'primary',\n\t\t\t'link-secondary': this.variant() === 'secondary',\n\t\t\t'link-tertiary': this.variant() === 'tertiary',\n\t\t\t'link-accent': this.variant() === 'accent',\n\t\t\t'link-success': this.variant() === 'success',\n\t\t\t'link-info': this.variant() === 'info',\n\t\t\t'link-warning': this.variant() === 'warning',\n\t\t\t'link-error': this.variant() === 'error',\n\t\t\t'text-[12px]': this.size() === 'xs',\n\t\t\t'text-[13px]': this.size() === 'sm',\n\t\t\t'text-[14px]': this.size() === 'md',\n\t\t\t'text-[15px]': this.size() === 'lg',\n\t\t\t'text-[16px]': this.size() === 'xl',\n\t\t\t'text-base-content/10 hover:text-base-content/10 cursor-default hover:cursor-default': this.disabled(),\n\t\t});\n\t});\n\n\tconstructor() {\n\t\tif (isDevMode()) {\n\t\t\tafterRenderEffect(() => {\n\t\t\t\tif (this.icon()) this.watchAccessibleName();\n\t\t\t});\n\t\t\tinject(DestroyRef).onDestroy(() => this.stopNameWatch());\n\t\t}\n\t}\n\n\t/**\n\t * @internal\n\t * Dev mode only: watches the inner button until its accessible name has settled\n\t * (no DOM change for UNNAMED_ICON_SETTLE_MS), then warns once if an icon-only button is still unnamed.\n\t * Names that arrive late, such as translations or projected text, do not warn.\n\t */\n\tprivate watchAccessibleName(): void {\n\t\tif (this.unnamedIconWarned || this.nameWatch) return;\n\t\tconst button = this.host.nativeElement.querySelector('button');\n\t\tif (!button) return;\n\t\tthis.zone.runOutsideAngular(() => {\n\t\t\tconst watch: { observer?: MutationObserver; timer?: ReturnType<typeof setTimeout> } = {};\n\t\t\tthis.nameWatch = watch;\n\t\t\tconst schedule = () => {\n\t\t\t\tclearTimeout(watch.timer);\n\t\t\t\twatch.timer = setTimeout(() => this.checkAccessibleName(button), UNNAMED_ICON_SETTLE_MS);\n\t\t\t};\n\t\t\tif (typeof MutationObserver !== 'undefined') {\n\t\t\t\twatch.observer = new MutationObserver(schedule);\n\t\t\t\twatch.observer.observe(button, {\n\t\t\t\t\tsubtree: true,\n\t\t\t\t\tchildList: true,\n\t\t\t\t\tcharacterData: true,\n\t\t\t\t\tattributes: true,\n\t\t\t\t\tattributeFilter: ['aria-label', 'aria-labelledby', 'title'],\n\t\t\t\t});\n\t\t\t}\n\t\t\tschedule();\n\t\t});\n\t}\n\n\tprivate checkAccessibleName(button: HTMLButtonElement): void {\n\t\tthis.stopNameWatch();\n\t\tif (!this.icon() || hasAccessibleName(button)) return;\n\t\tthis.unnamedIconWarned = true;\n\t\tconsole.warn(\n\t\t\t'[st-button] An icon-only st-button has no accessible name. Set `ariaLabel` or project visually hidden text (`<span class=\"sr-only\">`).',\n\t\t\tthis.host.nativeElement,\n\t\t);\n\t}\n\n\tprivate stopNameWatch(): void {\n\t\tthis.nameWatch?.observer?.disconnect();\n\t\tclearTimeout(this.nameWatch?.timer);\n\t\tthis.nameWatch = null;\n\t}\n\n\t/**\n\t * @internal\n\t * Handle click events\n\t */\n\thandleClick(event: MouseEvent): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.clicked.emit(event);\n\t\tthis.triggered.emit();\n\t}\n\n\t/**\n\t * @internal\n\t * Handle pointer down events\n\t */\n\thandlePointerDown(event: PointerEvent): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.pointerDown.emit(event);\n\t}\n\n\t/**\n\t * @internal\n\t * Handle Enter keydown events\n\t */\n\thandleKeyDownEnter(event: Event): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.keyDownEnter.emit(event as KeyboardEvent);\n\t}\n\n\t/**\n\t * @internal\n\t * Handle Space keydown events\n\t */\n\thandleKeyDownSpace(event: Event): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.keyDownSpace.emit(event as KeyboardEvent);\n\t}\n}\n","@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAkBA;;;AAGG;AACH;AACA,MAAM,sBAAsB,GAAG,IAAI;AAEnC,MAAM,iBAAiB,GAAG,CAAC,MAAyB,KACnD,CAAC,EACA,MAAM,CAAC,YAAY,CAAC,YAAY,CAAC,EAAE,IAAI,EAAE;AACzC,IAAA,MAAM,CAAC,YAAY,CAAC,iBAAiB,CAAC,EAAE,IAAI,EAAE;AAC9C,IAAA,MAAM,CAAC,YAAY,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE;AACpC,IAAA,MAAM,CAAC,WAAW,EAAE,IAAI,EAAE;AAC1B,IAAA,MAAM,CAAC,aAAa,CAAC,0BAA0B,CAAC,CAChD;MAEW,eAAe,GAAG,GAAG,CAAC,CAAC,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,aAAa,EAAE,gBAAgB,EAAE,cAAc,EAAE,cAAc,CAAC,EAAE;AACxI,IAAA,QAAQ,EAAE;AACT,QAAA,OAAO,EAAE;AACR,YAAA,IAAI,EAAE,EAAE;YACR,OAAO,EAAE,CAAC,aAAa,CAAC;YACxB,SAAS,EAAE,CAAC,eAAe,CAAC;YAC5B,QAAQ,EAAE,CAAC,cAAc,CA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YAAY,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAKzB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAP3B,SAAS;+BACC,WAAW,EAAA,OAAA,EACZ,CAAC,aAAa,EAAE,YAAY,CAAC,EAAA,eAAA,EAGrB,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,qzBAAA,EAAA;;;AE/GhD;;AAEG;;;;"}
1
+ {"version":3,"file":"sixbell-telco-sdk-components-button.mjs","sources":["../../../projects/sdk/components/button/src/button.component.ts","../../../projects/sdk/components/button/src/button.component.html","../../../projects/sdk/components/button/sixbell-telco-sdk-components-button.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport {\n\tafterRenderEffect,\n\tbooleanAttribute,\n\tChangeDetectionStrategy,\n\tComponent,\n\tcomputed,\n\tDestroyRef,\n\tElementRef,\n\tinject,\n\tinput,\n\tisDevMode,\n\tNgZone,\n\toutput,\n} from '@angular/core';\nimport { IconComponent } from '@sixbell-telco/sdk/components/icon';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva } from 'class-variance-authority';\n\n/**\n * @internal\n * Generates base button classes with style variants\n */\n/** How long an icon-only button must stay unnamed, after its last DOM change, before the dev-mode warning. */\nconst UNNAMED_ICON_SETTLE_MS = 2000;\n\nconst hasAccessibleName = (button: HTMLButtonElement): boolean =>\n\t!!(\n\t\tbutton.getAttribute('aria-label')?.trim() ||\n\t\tbutton.getAttribute('aria-labelledby')?.trim() ||\n\t\tbutton.getAttribute('title')?.trim() ||\n\t\tbutton.textContent?.trim() ||\n\t\tbutton.querySelector('[role=\"img\"][aria-label]')\n\t);\n\nexport const buttonComponent = cva(['btn', 'text-pretty', 'font-body', 'font-medium', 'leading-normal', 'items-center', 'align-middle'], {\n\tvariants: {\n\t\tvariant: {\n\t\t\tbase: ['btn-base'],\n\t\t\tprimary: ['btn-primary'],\n\t\t\tsecondary: ['btn-secondary'],\n\t\t\ttertiary: ['btn-tertiary'],\n\t\t\taccent: ['btn-accent'],\n\t\t\tinfo: ['btn-info'],\n\t\t\tsuccess: ['btn-success'],\n\t\t\twarning: ['btn-warning'],\n\t\t\terror: ['btn-error'],\n\t\t},\n\t\tsize: {\n\t\t\txs: ['btn-xs'],\n\t\t\tsm: ['btn-sm'],\n\t\t\tmd: ['btn-md'],\n\t\t\tlg: ['btn-lg'],\n\t\t\txl: ['btn-xl'],\n\t\t},\n\t\ticonPosition: {\n\t\t\tleft: [''],\n\t\t\tright: ['flex-row-reverse'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\tvariant: 'base',\n\t\tsize: 'md',\n\t\ticonPosition: 'left',\n\t},\n});\n\n/** Possible button style variants */\nexport type ButtonVariantProps =\n\t'primary' | 'secondary' | 'tertiary' | 'accent' | 'info' | 'success' | 'warning' | 'error' | 'base' | null | undefined;\n\n/** Possible button size variants */\nexport type ButtonSizeProps = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | null | undefined;\n\n/** Possible icon positions relative to button text */\nexport type ButtonIconPositionProps = 'left' | 'right' | null | undefined;\n\n/** Configuration object for button styling variants */\nexport type ButtonProps = {\n\tvariant?: ButtonVariantProps;\n\tsize?: ButtonSizeProps;\n\ticonPosition?: ButtonIconPositionProps;\n};\n\n/** Valid HTML button types */\nexport type HTMLButtonType = 'button' | 'submit' | 'reset';\n\n/**\n * A customizable button component with multiple variants and icon support\n *\n * @remarks\n * Built with Tailwind CSS and class-variance-authority for style management.\n * Supports various styling variants, sizes, icon positions, and state modifiers.\n *\n * @example\n * ```html\n * <st-button\n * variant=\"primary\"\n * size=\"md\"\n * icon=\"check\"\n * iconPosition=\"left\"\n * >\n * Submit\n * </st-button>\n * ```\n */\n@Component({\n\tselector: 'st-button',\n\timports: [IconComponent, CommonModule],\n\ttemplateUrl: './button.component.html',\n\tstyles: '',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ButtonComponent {\n\tprivate readonly host: ElementRef<HTMLElement> = inject(ElementRef);\n\tprivate readonly zone = inject(NgZone);\n\tprivate unnamedIconWarned = false;\n\tprivate roleWarned = false;\n\tprivate nameWatch: { observer?: MutationObserver; timer?: ReturnType<typeof setTimeout> } | null = null;\n\n\t/**\n\t * Button style variant\n\t * @defaultValue 'base'\n\t */\n\tvariant = input<ButtonVariantProps>();\n\n\t/**\n\t * Ghost button style (transparent background)\n\t * @defaultValue false\n\t */\n\tghost = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Outline button style (border with transparent fill)\n\t * @defaultValue false\n\t */\n\toutline = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Link button style (appears as a hyperlink)\n\t * @defaultValue false\n\t */\n\tlink = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Soft button style (muted/subdued color variant)\n\t * @defaultValue false\n\t */\n\tsoft = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Dash button style (dashed border)\n\t * @defaultValue false\n\t */\n\tdash = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Wide button style (increased horizontal padding)\n\t * @defaultValue false\n\t */\n\twide = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Circular button shape\n\t * @defaultValue false\n\t */\n\tcircle = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Square button shape\n\t * @defaultValue false\n\t */\n\tsquare = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Glass effect styling\n\t * @defaultValue false\n\t */\n\tglass = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Full-width button\n\t * @defaultValue false\n\t */\n\tblock = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Show loading spinner\n\t * @defaultValue false\n\t */\n\tloader = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Button size variant\n\t * @defaultValue 'md'\n\t */\n\tsize = input<ButtonSizeProps>();\n\n\t/**\n\t * Add drop shadow\n\t * @defaultValue false\n\t */\n\tshadow = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Button is focusable\n\t * @defaultValue true\n\t */\n\tfocusable = input(true, { transform: booleanAttribute });\n\n\t/**\n\t * Icon name (from icon library)\n\t */\n\ticon = input<string | undefined>();\n\n\t/**\n\t * Position of icon relative to text\n\t * @defaultValue 'left'\n\t */\n\ticonPosition = input<ButtonIconPositionProps>();\n\n\t/**\n\t * HTML button type attribute\n\t * @defaultValue 'button'\n\t */\n\ttype = input<HTMLButtonType>('button');\n\n\t/**\n\t * Disabled state\n\t * @defaultValue false\n\t */\n\tdisabled = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Stop event propagation for activation events\n\t * @defaultValue false\n\t */\n\tstopPropagation = input(false, { transform: booleanAttribute });\n\n\t/**\n\t * Accessible name forwarded to the inner `<button>` as `aria-label`.\n\t * Use it for icon-only buttons. Attributes bound on the `st-button` host are not forwarded.\n\t */\n\tariaLabel = input<string | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-expanded`.\n\t * Set it only when the button shows or hides another region; leave it unset otherwise.\n\t */\n\tariaExpanded = input<boolean | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-pressed` for toggle buttons.\n\t * Leave it unset for ordinary buttons.\n\t */\n\tariaPressed = input<boolean | 'mixed' | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-describedby`: the id(s) of elements that describe it,\n\t * such as a notice that explains why the button is disabled.\n\t */\n\tariaDescribedBy = input<string | null | undefined>();\n\n\t/**\n\t * Forwarded to the inner `<button>` as `aria-controls`: the id(s) of the elements the button shows, hides or resizes.\n\t */\n\tariaControls = input<string | null | undefined>();\n\n\t/**\n\t * Event emitted on click\n\t */\n\tclicked = output<MouseEvent>();\n\n\t/**\n\t * Event emitted on pointer down\n\t */\n\tpointerDown = output<PointerEvent>();\n\n\t/**\n\t * Event emitted on Enter keydown\n\t */\n\tkeyDownEnter = output<KeyboardEvent>();\n\n\t/**\n\t * Event emitted on Space keydown\n\t */\n\tkeyDownSpace = output<KeyboardEvent>();\n\n\t/**\n\t * Event emitted on activation (click or keyboard)\n\t */\n\ttriggered = output<void>();\n\n\t/**\n\t * @internal\n\t * Computed class string for the button container\n\t */\n\tcontainerClass = computed(() =>\n\t\tcn(\n\t\t\tbuttonComponent({\n\t\t\t\tvariant: this.variant(),\n\t\t\t\tsize: this.size(),\n\t\t\t\ticonPosition: this.iconPosition(),\n\t\t\t}),\n\t\t\t{\n\t\t\t\t'btn-ghost': this.ghost(),\n\t\t\t\t'btn-outline': this.outline(),\n\t\t\t\t'btn-link': this.link(),\n\t\t\t\t'btn-soft': this.soft(),\n\t\t\t\t'btn-dash': this.dash(),\n\t\t\t\t'btn-wide': this.wide(),\n\t\t\t\t'btn-circle': this.circle(),\n\t\t\t\t'btn-square': this.square(),\n\t\t\t\tglass: this.glass(),\n\t\t\t\t'w-full': this.block(),\n\t\t\t\t'btn-loading': this.loader(),\n\t\t\t\t'shadow-main': this.shadow(),\n\t\t\t\t'aria-pressed:inset-ring-base-content aria-pressed:inset-ring': this.isBaseToggleable() && !this.dash(),\n\t\t\t\t'aria-pressed:border-[calc(var(--border)*2)] aria-pressed:border-dashed': this.isBaseToggleable() && this.dash(),\n\t\t\t\t'aria-pressed:px-[calc(var(--btn-p)-var(--border))]': this.isBaseToggleable() && this.dash() && !this.circle() && !this.square(),\n\t\t\t},\n\t\t),\n\t);\n\n\t/**\n\t * @internal A base outline/dash toggle differs from rest only by a light tint when pressed, so\n\t * `aria-pressed=\"true\"` also doubles its border: an inset `base-content` ring for outline, and twice the\n\t * dashed border width for dash (the padding shrinks by the same amount, so nothing shifts).\n\t */\n\tprivate readonly isBaseToggleable = computed(() => (this.variant() ?? 'base') === 'base' && (this.outline() || this.dash()));\n\n\tlinkClass = computed(() => {\n\t\treturn cn('link font-body inline-flex items-center gap-1 align-middle leading-normal font-normal no-underline', this.iconPosition(), {\n\t\t\t'link-primary': this.variant() === 'primary',\n\t\t\t'link-secondary': this.variant() === 'secondary',\n\t\t\t'link-tertiary': this.variant() === 'tertiary',\n\t\t\t'link-accent': this.variant() === 'accent',\n\t\t\t'link-success': this.variant() === 'success',\n\t\t\t'link-info': this.variant() === 'info',\n\t\t\t'link-warning': this.variant() === 'warning',\n\t\t\t'link-error': this.variant() === 'error',\n\t\t\t'text-[12px]': this.size() === 'xs',\n\t\t\t'text-[13px]': this.size() === 'sm',\n\t\t\t'text-[14px]': this.size() === 'md',\n\t\t\t'text-[15px]': this.size() === 'lg',\n\t\t\t'text-[16px]': this.size() === 'xl',\n\t\t\t'text-base-content/10 hover:text-base-content/10 cursor-default hover:cursor-default': this.disabled(),\n\t\t});\n\t});\n\n\tconstructor() {\n\t\tif (isDevMode()) {\n\t\t\tafterRenderEffect(() => {\n\t\t\t\tif (this.icon()) this.watchAccessibleName();\n\t\t\t});\n\t\t\tafterRenderEffect(() => this.checkDeclaredRole());\n\t\t\tinject(DestroyRef).onDestroy(() => this.stopNameWatch());\n\t\t}\n\t}\n\n\t/**\n\t * @internal\n\t * Dev mode only: watches the inner button until its accessible name has settled\n\t * (no DOM change for UNNAMED_ICON_SETTLE_MS), then warns once if an icon-only button is still unnamed.\n\t * Names that arrive late, such as translations or projected text, do not warn.\n\t */\n\tprivate watchAccessibleName(): void {\n\t\tif (this.unnamedIconWarned || this.nameWatch) return;\n\t\tconst button = this.host.nativeElement.querySelector('button');\n\t\tif (!button) return;\n\t\tthis.zone.runOutsideAngular(() => {\n\t\t\tconst watch: { observer?: MutationObserver; timer?: ReturnType<typeof setTimeout> } = {};\n\t\t\tthis.nameWatch = watch;\n\t\t\tconst schedule = () => {\n\t\t\t\tclearTimeout(watch.timer);\n\t\t\t\twatch.timer = setTimeout(() => this.checkAccessibleName(button), UNNAMED_ICON_SETTLE_MS);\n\t\t\t};\n\t\t\tif (typeof MutationObserver !== 'undefined') {\n\t\t\t\twatch.observer = new MutationObserver(schedule);\n\t\t\t\twatch.observer.observe(button, {\n\t\t\t\t\tsubtree: true,\n\t\t\t\t\tchildList: true,\n\t\t\t\t\tcharacterData: true,\n\t\t\t\t\tattributes: true,\n\t\t\t\t\tattributeFilter: ['aria-label', 'aria-labelledby', 'title'],\n\t\t\t\t});\n\t\t\t}\n\t\t\tschedule();\n\t\t});\n\t}\n\n\tprivate checkAccessibleName(button: HTMLButtonElement): void {\n\t\tthis.stopNameWatch();\n\t\tif (!this.icon() || hasAccessibleName(button)) return;\n\t\tthis.unnamedIconWarned = true;\n\t\tconsole.warn(\n\t\t\t'[st-button] An icon-only st-button has no accessible name. Set `ariaLabel` or project visually hidden text (`<span class=\"sr-only\">`).',\n\t\t\tthis.host.nativeElement,\n\t\t);\n\t}\n\n\t/**\n\t * @internal\n\t * Dev mode only: warns once when a filled or outlined button has no declared role. `base` is meant\n\t * for `ghost` and `link` buttons; every other button should say what it does with a color variant.\n\t */\n\tprivate checkDeclaredRole(): void {\n\t\tif (this.roleWarned) return;\n\t\tconst variant = this.variant();\n\t\tif (this.ghost() || this.link() || (variant && variant !== 'base')) return;\n\t\tthis.roleWarned = true;\n\t\tconsole.warn(\n\t\t\t'[st-button] This st-button has no role variant. Set `variant` to `primary`, `secondary`, `tertiary` or a status color; keep `base` (or no variant) for `ghost` and `link` buttons only.',\n\t\t\tthis.host.nativeElement,\n\t\t);\n\t}\n\n\tprivate stopNameWatch(): void {\n\t\tthis.nameWatch?.observer?.disconnect();\n\t\tclearTimeout(this.nameWatch?.timer);\n\t\tthis.nameWatch = null;\n\t}\n\n\t/**\n\t * @internal\n\t * Handle click events\n\t */\n\thandleClick(event: MouseEvent): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.clicked.emit(event);\n\t\tthis.triggered.emit();\n\t}\n\n\t/**\n\t * @internal\n\t * Handle pointer down events\n\t */\n\thandlePointerDown(event: PointerEvent): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.pointerDown.emit(event);\n\t}\n\n\t/**\n\t * @internal\n\t * Handle Enter keydown events\n\t */\n\thandleKeyDownEnter(event: Event): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.keyDownEnter.emit(event as KeyboardEvent);\n\t}\n\n\t/**\n\t * @internal\n\t * Handle Space keydown events\n\t */\n\thandleKeyDownSpace(event: Event): void {\n\t\tif (this.disabled()) return;\n\t\tif (this.stopPropagation()) {\n\t\t\tevent.stopPropagation();\n\t\t}\n\t\tthis.keyDownSpace.emit(event as KeyboardEvent);\n\t}\n}\n","@let iconVar = icon();\n@let loaderVar = loader();\n@let focusableVar = focusable();\n<button\n\t[class]=\"link() === false ? containerClass() : linkClass()\"\n\t[type]=\"type()\"\n\t[disabled]=\"disabled()\"\n\t[tabIndex]=\"focusableVar ? 0 : -1\"\n\t[attr.aria-label]=\"ariaLabel() || null\"\n\t[attr.aria-expanded]=\"ariaExpanded() ?? null\"\n\t[attr.aria-pressed]=\"ariaPressed() ?? null\"\n\t[attr.aria-describedby]=\"ariaDescribedBy() || null\"\n\t[attr.aria-controls]=\"ariaControls() || null\"\n\t(pointerdown)=\"handlePointerDown($event)\"\n\t(click)=\"handleClick($event)\"\n\t(keydown.enter)=\"handleKeyDownEnter($event)\"\n\t(keydown.space)=\"handleKeyDownSpace($event)\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"auto\"></st-icon>\n\t}\n\t@if (loaderVar) {\n\t\t<span class=\"loading loading-spinner h-[1.2em] w-[1.2em]\"></span>\n\t}\n\t<ng-content></ng-content>\n</button>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAmBA;;;AAGG;AACH;AACA,MAAM,sBAAsB,GAAG,IAAI;AAEnC,MAAM,iBAAiB,GAAG,CAAC,MAAyB,KACnD,CAAC,EACA,MAAM,CAAC,YAAY,CAAC,YAAY,CA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AA,EAAA,CAAA;;4FAKzB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAP3B,SAAS;+BACC,WAAW,EAAA,OAAA,EACZ,CAAC,aAAa,EAAE,YAAY,CAAC,EAAA,eAAA,EAGrB,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,i6BAAA,EAAA;;;AEhHhD;;AAEG;;;;"}
@@ -1,6 +1,6 @@
1
1
  import { CommonModule, NgTemplateOutlet } from '@angular/common';
2
2
  import * as i0 from '@angular/core';
3
- import { input, computed, ChangeDetectionStrategy, Component, InjectionToken, signal, inject, ElementRef, DestroyRef, EnvironmentInjector, contentChildren, afterRenderEffect, createComponent } from '@angular/core';
3
+ import { input, computed, ChangeDetectionStrategy, Component, InjectionToken, booleanAttribute, inject, ElementRef, signal, effect, DestroyRef, EnvironmentInjector, contentChildren, afterRenderEffect, createComponent } from '@angular/core';
4
4
  import { cn } from '@sixbell-telco/sdk/utils/cn';
5
5
  import { DividerComponent } from '@sixbell-telco/sdk/components/divider';
6
6
  import { cva } from 'class-variance-authority';
@@ -70,12 +70,57 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImpo
70
70
  const CARD_HAS_SECTIONS = new InjectionToken('CARD_HAS_SECTIONS');
71
71
  const CARD_TYPOGRAPHY_CONTEXT = new InjectionToken('CARD_TYPOGRAPHY_CONTEXT');
72
72
 
73
+ /**
74
+ * Footer region of `st-card`, usually holding `st-card-actions`.
75
+ *
76
+ * @example
77
+ * ```html
78
+ * <st-card-footer sticky>
79
+ * <st-card-actions>
80
+ * <st-button variant="primary">Save</st-button>
81
+ * <st-button variant="tertiary" [outline]="true">Cancel</st-button>
82
+ * </st-card-actions>
83
+ * </st-card-footer>
84
+ * ```
85
+ */
73
86
  class CardFooterComponent {
74
- divided = input(false);
75
- contentClass = computed(() => (this.divided() ? 'mt-6' : ''));
87
+ /**
88
+ * Draws a divider above the footer content
89
+ * @defaultValue false
90
+ */
91
+ divided = input(false, { transform: booleanAttribute });
92
+ /**
93
+ * Keeps the footer visible at the bottom of the viewport while a long card scrolls, on the card
94
+ * surface with a top border and a static shadow (no motion). Use it for long create/edit forms.
95
+ * Prefer it over `divided` for long forms; `divided` remains for static footers. With both set, the
96
+ * border separates the actions and no divider is drawn. While it floats over the content (stuck) the
97
+ * bottom corners are square; at rest at the end of the card they follow the card radius.
98
+ * @defaultValue false
99
+ */
100
+ sticky = input(false, { transform: booleanAttribute });
101
+ elementRef = inject(ElementRef);
102
+ /** @internal `true` while the sticky footer floats over the content instead of resting at the card end */
103
+ stuck = signal(false);
104
+ /**
105
+ * @internal The footer sits 1px past the scroll edge, so while stuck its bottom edge is clipped:
106
+ * a visible footer with a ratio below 1, clipped at the bottom, is stuck. Off screen it is not.
107
+ */
108
+ stuckEffect = effect((onCleanup) => {
109
+ if (!this.sticky() || typeof IntersectionObserver === 'undefined') {
110
+ this.stuck.set(false);
111
+ return;
112
+ }
113
+ const observer = new IntersectionObserver(([entry]) => this.stuck.set(entry.isIntersecting && entry.intersectionRatio < 1 && entry.intersectionRect.bottom < entry.boundingClientRect.bottom), { threshold: [1] });
114
+ observer.observe(this.elementRef.nativeElement);
115
+ onCleanup(() => observer.disconnect());
116
+ });
117
+ hostClass = computed(() => cn('flex flex-col', {
118
+ 'border-base-300 rounded-b-box bg-base-200 sticky -bottom-px z-10 -mx-(--card-p,1.5rem) -mb-(--card-p,1.5rem) border-t px-(--card-p,1.5rem) py-4 shadow-[0_-8px_16px_-12px_var(--color-shadow-backdrop)] data-stuck:rounded-b-none': this.sticky(),
119
+ }));
120
+ contentClass = computed(() => (this.divided() && !this.sticky() ? 'mt-6' : ''));
76
121
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.25", ngImport: i0, type: CardFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
77
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.25", type: CardFooterComponent, isStandalone: true, selector: "st-card-footer", inputs: { divided: { classPropertyName: "divided", publicName: "divided", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "flex flex-col" }, ngImport: i0, template: `
78
- @if (divided()) {
122
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.25", type: CardFooterComponent, isStandalone: true, selector: "st-card-footer", inputs: { divided: { classPropertyName: "divided", publicName: "divided", isSignal: true, isRequired: false, transformFunction: null }, sticky: { classPropertyName: "sticky", publicName: "sticky", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "hostClass()", "attr.data-sticky": "sticky() || null", "attr.data-stuck": "stuck() || null" } }, ngImport: i0, template: `
123
+ @if (divided() && !sticky()) {
79
124
  <st-divider variant="neutral" [withMargin]="false"></st-divider>
80
125
  }
81
126
  <div [class]="contentClass()">
@@ -89,10 +134,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImpo
89
134
  selector: 'st-card-footer',
90
135
  imports: [CommonModule, DividerComponent],
91
136
  host: {
92
- class: 'flex flex-col',
137
+ '[class]': 'hostClass()',
138
+ '[attr.data-sticky]': 'sticky() || null',
139
+ '[attr.data-stuck]': 'stuck() || null',
93
140
  },
94
141
  template: `
95
- @if (divided()) {
142
+ @if (divided() && !sticky()) {
96
143
  <st-divider variant="neutral" [withMargin]="false"></st-divider>
97
144
  }
98
145
  <div [class]="contentClass()">
@@ -244,7 +291,7 @@ class CardSectionGroupComponent {
244
291
  envInjector = inject(EnvironmentInjector);
245
292
  dividerClass = 'st-card-section-group-divider';
246
293
  dividerRefs = [];
247
- divided = input(false);
294
+ divided = input(false, { transform: booleanAttribute });
248
295
  sections = contentChildren(CardSectionComponent);
249
296
  constructor() {
250
297
  afterRenderEffect(() => {
@@ -541,7 +588,7 @@ class CardComponent {
541
588
  * Show border around card
542
589
  * @defaultValue false
543
590
  */
544
- border = input(false);
591
+ border = input(false, { transform: booleanAttribute });
545
592
  /**
546
593
  * Image source URL
547
594
  */
@@ -565,27 +612,27 @@ class CardComponent {
565
612
  * Use image as full background
566
613
  * @defaultValue false
567
614
  */
568
- imageAsBackground = input(false);
615
+ imageAsBackground = input(false, { transform: booleanAttribute });
569
616
  /**
570
617
  * Add drop shadow
571
618
  * @defaultValue false
572
619
  */
573
- shadow = input(false);
620
+ shadow = input(false, { transform: booleanAttribute });
574
621
  /**
575
622
  * Glass effect styling
576
623
  * @defaultValue false
577
624
  */
578
- glass = input(false);
625
+ glass = input(false, { transform: booleanAttribute });
579
626
  /**
580
627
  * Dashed border style
581
628
  * @defaultValue false
582
629
  */
583
- dash = input(false);
630
+ dash = input(false, { transform: booleanAttribute });
584
631
  /**
585
632
  * Full-width card
586
633
  * @defaultValue false
587
634
  */
588
- block = input(false);
635
+ block = input(false, { transform: booleanAttribute });
589
636
  /**
590
637
  * @internal
591
638
  * Computed class string for the card container