@brightspot/ui 6.8.1 → 6.8.2

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 (170) hide show
  1. package/CHANGELOG.md +661 -0
  2. package/README.md +18 -2
  3. package/dist/storybook/CHANGELOG.md +661 -0
  4. package/dist/storybook/README.md +195 -0
  5. package/dist/storybook/assets/{ActionBar.stories-BOXYJYXy.js → ActionBar.stories-TlhuCumU.js} +1 -1
  6. package/dist/storybook/assets/{ActionItem-WoDvowFu.js → ActionItem-CjtyGLd5.js} +1 -1
  7. package/dist/storybook/assets/{ActionItem.stories-CVFoWP54.js → ActionItem.stories-BVlNQvfP.js} +1 -1
  8. package/dist/storybook/assets/{AiSparkle.stories-Psv9jNpy.js → AiSparkle.stories-DMzc8JUe.js} +2 -2
  9. package/dist/storybook/assets/{Avatar-CIQcHS8b.js → Avatar-C6Li1sPI.js} +1 -1
  10. package/dist/storybook/assets/{Avatar.stories-BE2Xn8fx.js → Avatar.stories-COj6XrPn.js} +1 -1
  11. package/dist/storybook/assets/{AvatarGroup-Chs0VKPg.js → AvatarGroup-DgxRTZBe.js} +1 -1
  12. package/dist/storybook/assets/{AvatarGroup.stories-2ar6gCeX.js → AvatarGroup.stories-Dh3e7iN2.js} +1 -1
  13. package/dist/storybook/assets/{Badge-AV20mCMJ.js → Badge-bWrvpEgX.js} +1 -1
  14. package/dist/storybook/assets/{Badge.stories-w9LqNw0A.js → Badge.stories-KXpmEXpt.js} +1 -1
  15. package/dist/storybook/assets/{Banner.stories-Clhh1bBs.js → Banner.stories-Cnhm3dXK.js} +1 -1
  16. package/dist/storybook/assets/{Button-B7fn_wd5.js → Button-DE0s-gat.js} +1 -1
  17. package/dist/storybook/assets/{Button.stories-5h4M8nd2.js → Button.stories-Cwg1YZEb.js} +1 -1
  18. package/dist/storybook/assets/{ButtonGroup-BmndBsBy.js → ButtonGroup-CoLI5nGO.js} +1 -1
  19. package/dist/storybook/assets/{ButtonGroup.stories-CR1H4H7u.js → ButtonGroup.stories-VhnKPP1n.js} +1 -1
  20. package/dist/storybook/assets/{Card.stories-Bz5vXq5y.js → Card.stories-BgpL90zB.js} +1 -1
  21. package/dist/storybook/assets/{Celebrate.stories-Bu3CNw0k.js → Celebrate.stories-D3NJgYcX.js} +1 -1
  22. package/dist/storybook/assets/{Checkbox-BALsanB1.js → Checkbox-BC1T_KxW.js} +1 -1
  23. package/dist/storybook/assets/{Checkbox.stories-BdvCht5c.js → Checkbox.stories-AFQNz7dQ.js} +1 -1
  24. package/dist/storybook/assets/{CircularProgress-BeE2fWON.js → CircularProgress-eqVb2jUD.js} +1 -1
  25. package/dist/storybook/assets/{CircularProgress.stories-CL8Lc6eU.js → CircularProgress.stories-B6t8VhmJ.js} +1 -1
  26. package/dist/storybook/assets/{ClipboardMixin-C6wcbXIO.js → ClipboardMixin-DcxrOy5B.js} +1 -1
  27. package/dist/storybook/assets/{ClipboardMixin.stories-BsjzC7wd.js → ClipboardMixin.stories-BqtQMjmS.js} +1 -1
  28. package/dist/storybook/assets/{Color-6BZIO3FS-Dsd6EVV9.js → Color-6BZIO3FS-CDluohEc.js} +1 -1
  29. package/dist/storybook/assets/{Colors.stories-CkCdNN9Y.js → Colors.stories-CqTniDIa.js} +1 -1
  30. package/dist/storybook/assets/{CombinedEffects.stories-QG78pIiG.js → CombinedEffects.stories-FwW0chy5.js} +1 -1
  31. package/dist/storybook/assets/{ComponentStatesMixin-CG-Dx_Vk.js → ComponentStatesMixin-hUqOL2aW.js} +1 -1
  32. package/dist/storybook/assets/{ComponentStatesMixin.stories-B1yuAqua.js → ComponentStatesMixin.stories-CwGoq685.js} +1 -1
  33. package/dist/storybook/assets/{CopyToClipboard.stories-CyKcumJ9.js → CopyToClipboard.stories-DUGjgtQx.js} +1 -1
  34. package/dist/storybook/assets/{Debounce.stories-BuNskQ33.js → Debounce.stories-CrWfXhKS.js} +1 -1
  35. package/dist/storybook/assets/{DocsRenderer-LL677BLK-BrPyc8XX.js → DocsRenderer-LL677BLK-9e51z9Xc.js} +3 -3
  36. package/dist/storybook/assets/{Dropdown.stories-DHXeP07z.js → Dropdown.stories-BsBxV0wp.js} +1 -1
  37. package/dist/storybook/assets/{DropdownMenu-WoWnJiQk.js → DropdownMenu-B-LvOIGj.js} +1 -1
  38. package/dist/storybook/assets/{EmptyState.stories-BRoVusey.js → EmptyState.stories-CJ1w8Tp2.js} +1 -1
  39. package/dist/storybook/assets/{EscaAvatar.stories-CWAE-4Uz.js → EscaAvatar.stories-BoLLSj9q.js} +2 -2
  40. package/dist/storybook/assets/{Events.stories-D-npDwlx.js → Events.stories-C3sTBwPJ.js} +1 -1
  41. package/dist/storybook/assets/{Heading.stories-D7hmvFEN.js → Heading.stories-jmXDRBmM.js} +1 -1
  42. package/dist/storybook/assets/{HueRipple.stories-Dx3ozdHi.js → HueRipple.stories-BPx5aSYd.js} +1 -1
  43. package/dist/storybook/assets/{Icon-DPQKiWDz.js → Icon-CWyJRQf7.js} +1 -1
  44. package/dist/storybook/assets/{Icon.stories-CVsQvcwd.js → Icon.stories-iYBxmv2x.js} +1 -1
  45. package/dist/storybook/assets/{IconButton-Dp4Z06bL.js → IconButton-Di5Rgs7F.js} +1 -1
  46. package/dist/storybook/assets/{IconButton.stories-DTbfHfcQ.js → IconButton.stories-DENLoxVk.js} +1 -1
  47. package/dist/storybook/assets/{LinearProgress-DG3tPlGH.js → LinearProgress-D9ngIVlv.js} +1 -1
  48. package/dist/storybook/assets/{LinearProgress.stories-VIU6OqYd.js → LinearProgress.stories-u90B_VJR.js} +1 -1
  49. package/dist/storybook/assets/{Message-BzkpGg8z.js → Message-nFAa55c_.js} +1 -1
  50. package/dist/storybook/assets/{Message.stories-C9bzoQes.js → Message.stories-B4rpz5rI.js} +1 -1
  51. package/dist/storybook/assets/{OnFindMixin-CeeYfx9k.js → OnFindMixin-oL1bvTFj.js} +1 -1
  52. package/dist/storybook/assets/{OnFindMixin.stories-Dq06nuVf.js → OnFindMixin.stories-CdeS5sFA.js} +1 -1
  53. package/dist/storybook/assets/{Pagination-CnWa6AX5.js → Pagination-CSWcjuDU.js} +1 -1
  54. package/dist/storybook/assets/{Pagination.stories-BsH2eN2W.js → Pagination.stories-Da2WzJkv.js} +1 -1
  55. package/dist/storybook/assets/{Popover.stories-CLnzpgEE.js → Popover.stories-CVljlVHc.js} +1 -1
  56. package/dist/storybook/assets/{ProgressMixin-D1atDw3n.js → ProgressMixin-CeSrn0_P.js} +1 -1
  57. package/dist/storybook/assets/{Radio-B6Aq6K0V.js → Radio-rvfGhZwK.js} +1 -1
  58. package/dist/storybook/assets/{Radio.stories-BCVbISmb.js → Radio.stories-B0wHdJuc.js} +1 -1
  59. package/dist/storybook/assets/{RadioGroup.stories-B-TGP_-v.js → RadioGroup.stories-D8krOSlP.js} +1 -1
  60. package/dist/storybook/assets/{ReadyMixin-C8HW2nGE.js → ReadyMixin-CvX_eidU.js} +1 -1
  61. package/dist/storybook/assets/{RovingTabindexMixin-DI5rmyR7.js → RovingTabindexMixin-9z8lwaM9.js} +1 -1
  62. package/dist/storybook/assets/{RovingTabindexMixin.stories-DVKCC_R7.js → RovingTabindexMixin.stories-Y8vBWjJp.js} +1 -1
  63. package/dist/storybook/assets/{Rtc.stories-bBYHOszW.js → Rtc.stories-D3Y-z8y_.js} +1 -1
  64. package/dist/storybook/assets/{ScrollShadow.stories-BIK8YINt.js → ScrollShadow.stories-1KD0lWHX.js} +1 -1
  65. package/dist/storybook/assets/{Switch.stories-COEk74kM.js → Switch.stories-Bsqvm_HE.js} +1 -1
  66. package/dist/storybook/assets/{Tab.stories-Dbt9JvSx.js → Tab.stories-CzcTisNs.js} +1 -1
  67. package/dist/storybook/assets/{Tabs-BIScOPS0.js → Tabs-DdpYNZSW.js} +1 -1
  68. package/dist/storybook/assets/{Tabs.stories-CodKgVf2.js → Tabs.stories-UOS3V0J4.js} +1 -1
  69. package/dist/storybook/assets/{Throttle.stories-BhIqWWrQ.js → Throttle.stories-C8jgzh6e.js} +1 -1
  70. package/dist/storybook/assets/{Tooltip.stories-DKD8nBM1.js → Tooltip.stories-B5BoI0cH.js} +1 -1
  71. package/dist/storybook/assets/{TooltipMixin-CRNNusJ7.js → TooltipMixin-CVKslCDt.js} +1 -1
  72. package/dist/storybook/assets/{Upload.stories-WTO15ST1.js → Upload.stories-BsQDCDqo.js} +1 -1
  73. package/dist/storybook/assets/{UploadItem-DejgZ5A0.js → UploadItem-CYQqNwUF.js} +1 -1
  74. package/dist/storybook/assets/{UploadItem.stories-Pk3ghOcI.js → UploadItem.stories-_le7XBTV.js} +1 -1
  75. package/dist/storybook/assets/{Welcome.stories-DrNnxvt9.js → Welcome.stories-rramKkhd.js} +33 -3
  76. package/dist/storybook/assets/{Widget.stories-CYC5Qdac.js → Widget.stories-DtbAaklk.js} +1 -1
  77. package/dist/storybook/assets/{WithTooltip-65CFNBJE-DK6PZNaa.js → WithTooltip-65CFNBJE-DK6GcBuR.js} +1 -1
  78. package/dist/storybook/assets/{blocks-Dzcxb014.js → blocks-DHnzPh43.js} +5 -5
  79. package/dist/storybook/assets/{formatter-EIJCOSYU-PioIuXjk.js → formatter-EIJCOSYU-qig-qWlG.js} +1 -1
  80. package/dist/storybook/assets/if-defined-DerKRcyC.js +1 -0
  81. package/dist/storybook/assets/{iframe-Byo_x5o2.js → iframe-DlBK9Drk.js} +3 -3
  82. package/dist/storybook/assets/{index-gox-Wle0.js → index-CItQyB37.js} +1 -1
  83. package/dist/storybook/assets/{lottie_svg-3t2UJxjZ.js → lottie_svg-C3v6xdng.js} +1 -1
  84. package/dist/storybook/assets/{onFind-BWiaccUj.js → onFind-Ci35eu2y.js} +1 -1
  85. package/dist/storybook/assets/{onFind.stories-CC_XTN2G.js → onFind.stories-BmbwWWo1.js} +1 -1
  86. package/dist/storybook/assets/{onRemove.stories-CXxpL4ud.js → onRemove.stories-DFWCIgE4.js} +1 -1
  87. package/dist/storybook/assets/{onVisible.stories-DKA9cexx.js → onVisible.stories-B-onpgE-.js} +1 -1
  88. package/dist/storybook/assets/{property-_few0Xe5.js → property-Bmq4RTSP.js} +1 -1
  89. package/dist/storybook/assets/{ref-BaIdO8Sk.js → ref-BhKk4SDh.js} +1 -1
  90. package/dist/storybook/assets/state-DVIUS0Gf.js +1 -0
  91. package/dist/storybook/assets/{style-map-DxZm5Cj7.js → style-map-DE4G47KD.js} +1 -1
  92. package/dist/storybook/assets/{syntaxhighlighter-ED5Y7EFY-B0_bSGZz.js → syntaxhighlighter-ED5Y7EFY-Dfgnal1d.js} +1 -1
  93. package/dist/storybook/custom-elements.json +11835 -0
  94. package/dist/storybook/docs/components/ActionBar.md +55 -0
  95. package/dist/storybook/docs/components/ActionItem.md +50 -0
  96. package/dist/storybook/docs/components/AiSparkle.md +33 -0
  97. package/dist/storybook/docs/components/Avatar.md +45 -0
  98. package/dist/storybook/docs/components/AvatarGroup.md +34 -0
  99. package/dist/storybook/docs/components/Badge.md +47 -0
  100. package/dist/storybook/docs/components/Banner.md +35 -0
  101. package/dist/storybook/docs/components/ButtonGroup.md +65 -0
  102. package/dist/storybook/docs/components/Card.md +67 -0
  103. package/dist/storybook/docs/components/Checkbox.md +49 -0
  104. package/dist/storybook/docs/components/CircularProgress.md +40 -0
  105. package/dist/storybook/docs/components/CopyToClipboard.md +51 -0
  106. package/dist/storybook/docs/components/Dropdown.md +74 -0
  107. package/dist/storybook/docs/components/DropdownItem.md +45 -0
  108. package/dist/storybook/docs/components/DropdownMenu.md +41 -0
  109. package/dist/storybook/docs/components/EmptyState.md +62 -0
  110. package/dist/storybook/docs/components/EscaAvatar.md +40 -0
  111. package/dist/storybook/docs/components/Icon.md +40 -0
  112. package/dist/storybook/docs/components/IconButton.md +36 -0
  113. package/dist/storybook/docs/components/LinearProgress.md +37 -0
  114. package/dist/storybook/docs/components/Message.md +50 -0
  115. package/dist/storybook/docs/components/Pagination.md +70 -0
  116. package/dist/storybook/docs/components/Popover.md +59 -0
  117. package/dist/storybook/docs/components/README.md +48 -0
  118. package/dist/storybook/docs/components/Radio.md +55 -0
  119. package/dist/storybook/docs/components/RadioGroup.md +34 -0
  120. package/dist/storybook/docs/components/Switch.md +48 -0
  121. package/dist/storybook/docs/components/Tab.md +40 -0
  122. package/dist/storybook/docs/components/Tabs.md +49 -0
  123. package/dist/storybook/docs/components/Upload.md +63 -0
  124. package/dist/storybook/docs/components/UploadItem.md +30 -0
  125. package/dist/storybook/docs/components/Widget.md +88 -0
  126. package/dist/storybook/docs/dari-elements.md +55 -0
  127. package/dist/storybook/iframe.html +1 -1
  128. package/dist/storybook/index.html +29 -2
  129. package/dist/storybook/llms-full.txt +1721 -0
  130. package/dist/storybook/llms.txt +65 -0
  131. package/dist/storybook/project.json +1 -1
  132. package/dist/storybook/robots.txt +7 -0
  133. package/dist/storybook/sb-addons/storybook-3/manager-bundle.js +1 -1
  134. package/dist/storybook/sitemap.xml +90 -0
  135. package/docs/components/ActionBar.md +41 -64
  136. package/docs/components/ActionItem.md +50 -96
  137. package/docs/components/AiSparkle.md +23 -60
  138. package/docs/components/Avatar.md +45 -88
  139. package/docs/components/AvatarGroup.md +24 -44
  140. package/docs/components/Badge.md +34 -62
  141. package/docs/components/Banner.md +25 -39
  142. package/docs/components/ButtonGroup.md +65 -99
  143. package/docs/components/Card.md +67 -83
  144. package/docs/components/Checkbox.md +49 -91
  145. package/docs/components/CircularProgress.md +40 -84
  146. package/docs/components/CopyToClipboard.md +35 -40
  147. package/docs/components/Dropdown.md +74 -120
  148. package/docs/components/DropdownItem.md +45 -81
  149. package/docs/components/DropdownMenu.md +30 -70
  150. package/docs/components/EmptyState.md +45 -62
  151. package/docs/components/EscaAvatar.md +30 -61
  152. package/docs/components/Icon.md +29 -62
  153. package/docs/components/IconButton.md +36 -83
  154. package/docs/components/LinearProgress.md +28 -70
  155. package/docs/components/Message.md +38 -63
  156. package/docs/components/Pagination.md +70 -100
  157. package/docs/components/Popover.md +46 -79
  158. package/docs/components/README.md +34 -40
  159. package/docs/components/Radio.md +55 -105
  160. package/docs/components/RadioGroup.md +26 -55
  161. package/docs/components/Switch.md +48 -84
  162. package/docs/components/Tab.md +30 -70
  163. package/docs/components/Tabs.md +49 -86
  164. package/docs/components/Upload.md +63 -112
  165. package/docs/components/UploadItem.md +22 -53
  166. package/docs/components/Widget.md +66 -67
  167. package/llms.txt +63 -0
  168. package/package.json +8 -6
  169. package/dist/storybook/assets/if-defined-DL7cQU7O.js +0 -1
  170. package/dist/storybook/assets/state-BBcPmYaV.js +0 -1
@@ -0,0 +1,1721 @@
1
+ # Brightspot UI
2
+
3
+ > `@brightspot/ui` 6.8.2: Lit web components (`btu-*` tags) and a TailwindCSS v3 preset for building Brightspot CMS screens and plugins.
4
+
5
+ These docs describe 6.8.2. Prefer them over what you remember about this library, because component APIs change between minor versions. For the version a project actually uses, read `node_modules/@brightspot/ui/llms.txt` in that project. Releases without that file still have their manifest at `https://cdn.jsdelivr.net/npm/@brightspot/ui@<version>/dist/custom-elements.json`.
6
+
7
+ Components render in the light DOM, not a shadow root. In HTML, use the attribute names from each component page: many differ from the JavaScript property names, for example `heading-level` for `headingLevel`.
8
+
9
+ The guide and component pages linked below are markdown.
10
+
11
+ ## Getting started
12
+
13
+ - [README](https://ui.brightspot.com/README.md): install, the Tailwind preset and importing components
14
+ - [Using components in a CMS plugin](https://ui.brightspot.com/docs/components/README.md): the CMS defines only `btu-badge`, `btu-copy-to-clipboard`, `btu-icon` and `btu-widget`; import every other element you use
15
+ - [Rendering components from Java](https://ui.brightspot.com/docs/dari-elements.md): the generated `com.brightspot.ui.dari` classes
16
+
17
+ ## Components
18
+
19
+ - [`<btu-action-bar>`](https://ui.brightspot.com/docs/components/ActionBar.md): A persistent container for primary, secondary, tertiary, and destructive actions within an interface, typically anchored to the bottom of a view
20
+ - [`<btu-action-item>`](https://ui.brightspot.com/docs/components/ActionItem.md): An action item button for use within `btu-action-bar`
21
+ - [`<btu-ai-sparkle>`](https://ui.brightspot.com/docs/components/AiSparkle.md): The animated AI-branding sparkle
22
+ - [`<btu-avatar>`](https://ui.brightspot.com/docs/components/Avatar.md): An avatar component for displaying user profile images with fallback support
23
+ - [`<btu-avatar-group>`](https://ui.brightspot.com/docs/components/AvatarGroup.md): A container component for grouping multiple avatars with consistent styling
24
+ - [`<btu-badge>`](https://ui.brightspot.com/docs/components/Badge.md): A badge component for highlighting important information
25
+ - [`<btu-banner>`](https://ui.brightspot.com/docs/components/Banner.md): A full-width container that pins a `<btu-message>` to the top of the CMS or a content edit page
26
+ - [`<btu-button-group>`](https://ui.brightspot.com/docs/components/ButtonGroup.md): A semantic container for grouping related buttons together
27
+ - [`<btu-card>`](https://ui.brightspot.com/docs/components/Card.md): A flexible content container for presenting and organizing information
28
+ - [`<btu-checkbox>`](https://ui.brightspot.com/docs/components/Checkbox.md): A checkbox component for selecting one or more options from a set
29
+ - [`<btu-circular-progress>`](https://ui.brightspot.com/docs/components/CircularProgress.md): A circular progress indicator for showing loading states or progress
30
+ - [`<btu-copy-to-clipboard>`](https://ui.brightspot.com/docs/components/CopyToClipboard.md): A button component that copies text to the system clipboard
31
+ - [`<btu-dropdown>`](https://ui.brightspot.com/docs/components/Dropdown.md): A dropdown component that renders a trigger button and manages a floating panel containing a `btu-dropdown-menu`
32
+ - [`<btu-dropdown-item>`](https://ui.brightspot.com/docs/components/DropdownItem.md): A menu item component for use inside `btu-dropdown-menu`
33
+ - [`<btu-dropdown-menu>`](https://ui.brightspot.com/docs/components/DropdownMenu.md): A menu container component that provides keyboard navigation and ARIA menu semantics
34
+ - [`<btu-empty-state>`](https://ui.brightspot.com/docs/components/EmptyState.md): An empty state component for displaying placeholder content when no data is available
35
+ - [`<btu-esca-avatar>`](https://ui.brightspot.com/docs/components/EscaAvatar.md): The animated avatar for the Esca AI assistant, driven entirely by its `state` attribute so the same element works wherever the assistant appears
36
+ - [`<btu-icon>`](https://ui.brightspot.com/docs/components/Icon.md): An icon component for displaying Lucide icons
37
+ - [`<btu-icon-button>`](https://ui.brightspot.com/docs/components/IconButton.md): Surfaces the different actions someone can perform in an interface where space is limited
38
+ - [`<btu-linear-progress>`](https://ui.brightspot.com/docs/components/LinearProgress.md): A horizontal linear progress bar for showing task completion
39
+ - [`<btu-message>`](https://ui.brightspot.com/docs/components/Message.md): A message for communicating high-visibility content that is not tied to the user's current task — alerts, breaking news, and persistent status
40
+ - [`<btu-pagination>`](https://ui.brightspot.com/docs/components/Pagination.md): A pagination component for navigating through paged content
41
+ - [`<btu-popover>`](https://ui.brightspot.com/docs/components/Popover.md): A popover component for displaying rich interactive content anchored to a trigger element
42
+ - [`<btu-radio>`](https://ui.brightspot.com/docs/components/Radio.md): A single radio option, selectable from a set of mutually exclusive choices
43
+ - [`<btu-radio-group>`](https://ui.brightspot.com/docs/components/RadioGroup.md): A container that groups `btu-radio` options into a single-select control
44
+ - [`<btu-switch>`](https://ui.brightspot.com/docs/components/Switch.md): A toggle switch component for binary on/off states
45
+ - [`<btu-tab>`](https://ui.brightspot.com/docs/components/Tab.md): An individual tab within a tab group
46
+ - [`<btu-tabs>`](https://ui.brightspot.com/docs/components/Tabs.md): A container component for managing a group of tabs
47
+ - [`<btu-upload>`](https://ui.brightspot.com/docs/components/Upload.md): A file upload component with drop zone and file list
48
+ - [`<btu-upload-item>`](https://ui.brightspot.com/docs/components/UploadItem.md): Internal upload item sub-component for displaying individual file upload state
49
+ - [`<btu-widget>`](https://ui.brightspot.com/docs/components/Widget.md): A widget component for displaying content with header, body, and footer sections
50
+
51
+ ## Tailwind classes
52
+
53
+ Each link is a plugin source file; its header comment lists the classes.
54
+
55
+ - [Button](https://cdn.jsdelivr.net/npm/@brightspot/ui@6.8.2/dist/tailwind-plugin-button.ts): Buttons communicate actions that users can take such as submit a form, begin a new task, trigger a new UI element to appear or take a new or next step in some process
56
+ - [Heading](https://cdn.jsdelivr.net/npm/@brightspot/ui@6.8.2/dist/tailwind-plugin-heading.ts): Headings are a combination of font-size, line-height and weight
57
+ - [Scroll Shadow](https://cdn.jsdelivr.net/npm/@brightspot/ui@6.8.2/dist/tailwind-plugin-scroll-shadow.ts): This plugin adds shadows to the edges of a scrollable container when the content of the container overflows
58
+ - [Icon](https://cdn.jsdelivr.net/npm/@brightspot/ui@6.8.2/dist/tailwind-plugin-icon.ts): Lucide icons as classes, for example `before:btu-icon before:btu-icon-heart`, plus size and gradient modifiers
59
+
60
+ ## Optional
61
+
62
+ - [All component pages in one file](https://ui.brightspot.com/llms-full.txt)
63
+ - [Custom Elements Manifest](https://ui.brightspot.com/custom-elements.json): the machine-readable API of every element
64
+ - [Changelog](https://ui.brightspot.com/CHANGELOG.md): what changed in each release
65
+ - [Storybook](https://ui.brightspot.com/): interactive examples; needs JavaScript, so fetching it returns no content
66
+
67
+ ---
68
+
69
+ # `<btu-action-bar>`
70
+ Source: https://ui.brightspot.com/docs/components/ActionBar.md
71
+
72
+ A persistent container for primary, secondary, tertiary, and destructive actions
73
+ within an interface, typically anchored to the bottom of a view.
74
+
75
+ Uses a two-zone layout: destructive actions on the left (start zone),
76
+ main actions on the right (end zone). Both zones maintain their position
77
+ even when the other zone is empty (BSP-18087).
78
+
79
+ **Positioning:** Uses `margin-top: auto` to push to bottom of flex/grid parents.
80
+ In block layout parents, the bar sits after content (a console warning is emitted).
81
+
82
+ **Overflow:** When items don't fit, the least important overflow into a "More" dropdown.
83
+ Items are auto-sorted by variant priority (tertiary → secondary → primary).
84
+ With `compact`, compactable items progressively hide labels one-by-one before overflowing.
85
+
86
+ ```js
87
+ import '@brightspot/ui/components/action-bar/ActionBar.js'
88
+ ```
89
+
90
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-action-bar--docs
91
+
92
+ ## Attributes
93
+
94
+ | Attribute | Property | Type | Default | Description |
95
+ | --- | --- | --- | --- | --- |
96
+ | `position` | `position` | `'top' \| 'bottom'` | `'bottom'` | Bar position: 'top' or 'bottom' (default). |
97
+ | `sticky` | `sticky` | `boolean` | `false` | Enables CSS sticky positioning. When combined with position='top', the bar sticks to the top of the scroll container. With position='bottom' (default), it sticks to the bottom. |
98
+ | `item-alignment` | `alignment` | `'default' \| 'start' \| 'center' \| 'end'` | `'default'` | Content alignment: 'default' (two-zone), 'start', 'center', 'end'. Non-default alignments disable two-zone layout. |
99
+ | `shadow` | `shadow` | `boolean` | `false` | Adds a box-shadow to the bar. |
100
+ | `label` | `label` | `string` | `''` | Accessible label for the toolbar region. |
101
+ | `compact` | `compact` | `boolean` | `false` | Enables progressive label compacting. When space shrinks, items marked `compactable` (with icons) have their labels hidden one-by-one from least to most important before items overflow into "More". |
102
+
103
+ ## Events
104
+
105
+ | Event | Detail | Description |
106
+ | --- | --- | --- |
107
+ | `btu-action-bar-ready` | | Fired after first render and initialization |
108
+ | `btu-action-item-click` | `{label: string}` | Fired when an action item is clicked (bubbles from btu-action-item) |
109
+
110
+ ## Slots
111
+
112
+ | Slot | Description |
113
+ | --- | --- |
114
+ | (default) | One or more `btu-action-item` elements |
115
+
116
+ ## CSS custom properties
117
+
118
+ | Property | Description |
119
+ | --- | --- |
120
+ | `--action-bar-gap` | Gap between items (default: 0.75rem) |
121
+ | `--action-bar-padding` | Bar padding (default: 1.5rem) |
122
+ | `--action-bar-background` | Background color (default: white) |
123
+ | `--action-bar-border-color` | Border color (default: gray-200) |
124
+ | `--action-bar-z-index` | Z-index (default: 100) |
125
+
126
+ ---
127
+
128
+ # `<btu-action-item>`
129
+ Source: https://ui.brightspot.com/docs/components/ActionItem.md
130
+
131
+ An action item button for use within `btu-action-bar`.
132
+
133
+ Renders a styled button using existing `btu-button-*` classes. Supports
134
+ primary, secondary, tertiary, and destructive variants. When `iconOnly`
135
+ is set, the label is hidden and a tooltip is shown instead.
136
+
137
+ **Button styling:** Set `--button-*` CSS custom properties on `<btu-action-item>`
138
+ or a parent element to customize via CSS inheritance. See
139
+ `tailwind-plugin-button.ts` for available props.
140
+
141
+ ```js
142
+ import '@brightspot/ui/components/action-bar/ActionItem.js'
143
+ ```
144
+
145
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-action-bar-action-item--docs
146
+
147
+ ## Attributes
148
+
149
+ | Attribute | Property | Type | Default | Description |
150
+ | --- | --- | --- | --- | --- |
151
+ | `label` | `label` | `string` | `''` | Button label text. |
152
+ | `variant` | `variant` | `'primary' \| 'secondary' \| 'tertiary' \| 'destructive'` | `'secondary'` | Visual variant: 'primary', 'secondary', 'tertiary', 'destructive'. |
153
+ | `symbol` | `symbol` | `string` | `''` | Lucide icon symbol for the leading icon. |
154
+ | `icon-only` | `iconOnly` | `boolean` | `false` | Show icon only, hiding the label. Tooltip activates automatically with the label text. |
155
+ | `disabled` | `disabled` | `boolean` | `false` | Disables the action item. The button remains focusable for accessibility but click events are suppressed. |
156
+ | `loading` | `loading` | `boolean` | `false` | Shows a loading spinner and prevents interaction. |
157
+ | `zone` | `zone` | `'start' \| 'end' \| ''` | `''` | Zone placement: 'start' or 'end'. Used by ActionBar for two-zone layout. If unset, auto-detected from variant (destructive → start, others → end). |
158
+ | `compactable` | `compactable` | `boolean` | `false` | Opt-in for progressive label compacting. When the parent bar has `compact` enabled and space shrinks, compactable items with icons have their labels hidden one-by-one (least important first) before overflowing. Items without an icon ignore this attribute and go directly to overflow. |
159
+ | `tooltip` | `tooltip` | `string` | `''` | Tooltip text content. Set to empty string to remove the tooltip. |
160
+ | `tooltip-position` | `tooltipPosition` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'top'` | Position relative to the host element. Auto-flips when constrained by the viewport. |
161
+ | `tooltip-delay` | `tooltipDelay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
162
+ | `tooltip-offset` | `tooltipOffset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between host and tooltip (sm=4px, md=8px, lg=12px, xl=16px). |
163
+ | `tooltip-no-arrow` | `tooltipNoArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
164
+ | `tooltip-trigger` | `tooltipTrigger` | `string` | `'hover focus'` | Space-separated trigger types: 'hover', 'focus', 'click'. |
165
+
166
+ ## Events
167
+
168
+ | Event | Detail | Description |
169
+ | --- | --- | --- |
170
+ | `btu-action-item-click` | `{label: string}` | Fired when the action item is clicked (not fired when disabled or loading) |
171
+
172
+ ## CSS custom properties
173
+
174
+ | Property | Description |
175
+ | --- | --- |
176
+ | `--button-color` | Override button background color |
177
+ | `--button-text-color` | Override button text color |
178
+ | `--button-border-radius` | Override button border radius |
179
+
180
+ ---
181
+
182
+ # `<btu-ai-sparkle>`
183
+ Source: https://ui.brightspot.com/docs/components/AiSparkle.md
184
+
185
+ The animated AI-branding sparkle. Drive it with the `playing` boolean: `true` loops the clip to
186
+ draw the eye to an AI entry point, `false` freezes the full sparkle so it reads as a static brand
187
+ mark once the surface it advertises is engaged. Reduced-motion users always get the frozen frame.
188
+
189
+ Decorative by default (`aria-hidden="true"`, set only when absent) — the control it sits in owns
190
+ the accessible name.
191
+
192
+ ```js
193
+ import '@brightspot/ui/components/ai-sparkle/AiSparkle.js'
194
+ ```
195
+
196
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-ai-sparkle--docs
197
+
198
+ ## Attributes
199
+
200
+ | Attribute | Property | Type | Default | Description |
201
+ | --- | --- | --- | --- | --- |
202
+ | `playing` | `playing` | `boolean` | `false` | Whether the sparkle animates; otherwise it holds the last (fully-formed) frame. Opt-in (default `false`) like `autoplay`: a boolean defaulting to `true` can't be cleared by attribute absence. The converter also treats `playing="false"` as paused (a plain `type: Boolean` would read any present value, even "false", as `true`). |
203
+ | `size` | `size` | `'xs' \| 'sm' \| 'md' \| 'lg' \| 'xl'` | `'md'` | Size of the sparkle, mirroring `<btu-avatar>`'s scale. `--ai-sparkle-size` overrides it. |
204
+
205
+ ## Events
206
+
207
+ | Event | Detail | Description |
208
+ | --- | --- | --- |
209
+ | `btu-ai-sparkle-ready` | | Fired after the first render |
210
+
211
+ ## CSS custom properties
212
+
213
+ | Property | Description |
214
+ | --- | --- |
215
+ | `--ai-sparkle-size` | Width and height of the sparkle; overrides the `size` attribute (default: 2.5rem) |
216
+
217
+ ---
218
+
219
+ # `<btu-avatar>`
220
+ Source: https://ui.brightspot.com/docs/components/Avatar.md
221
+
222
+ An avatar component for displaying user profile images with fallback support.
223
+
224
+ Avatars display user profile images with automatic fallback to initials when
225
+ the image fails to load or is not provided.
226
+
227
+ ```js
228
+ import '@brightspot/ui/components/avatar/Avatar.js'
229
+ ```
230
+
231
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-avatar--docs
232
+
233
+ ## Attributes
234
+
235
+ | Attribute | Property | Type | Default | Description |
236
+ | --- | --- | --- | --- | --- |
237
+ | `src` | `src` | `string` | `''` | Image source URL |
238
+ | `alt` | `alt` | `string` | `''` | Alt text for the image |
239
+ | `fallback` | `fallback` | `string` | `''` | Fallback text (typically user initials) |
240
+ | `size` | `size` | `'xs' \| 'sm' \| 'md' \| 'lg' \| 'xl' \| 'xxl'` | `'md'` | Size variant. - 'xs': Extra small (1.5rem) - 'sm': Small (2.25rem) - 'md': Medium (2.5rem) - default - 'lg': Large (3rem) - 'xl': Extra large (3.5rem) - 'xxl': Extra extra large (4rem) |
241
+ | `tooltip` | `tooltip` | `string` | `''` | Tooltip text content. Set to empty string to remove the tooltip. |
242
+ | `tooltip-position` | `tooltipPosition` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'top'` | Position relative to the host element. Auto-flips when constrained by the viewport. |
243
+ | `tooltip-delay` | `tooltipDelay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
244
+ | `tooltip-offset` | `tooltipOffset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between host and tooltip (sm=4px, md=8px, lg=12px, xl=16px). |
245
+ | `tooltip-no-arrow` | `tooltipNoArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
246
+ | `tooltip-trigger` | `tooltipTrigger` | `string` | `'hover focus'` | Space-separated trigger types: 'hover', 'focus', 'click'. |
247
+
248
+ ## Events
249
+
250
+ | Event | Detail | Description |
251
+ | --- | --- | --- |
252
+ | `btu-avatar-ready` | | Fired after first render and initialization |
253
+ | `btu-avatar-image-loaded` | `{src: string}` | Fired when image successfully loads |
254
+ | `btu-avatar-image-error` | `{src: string, error: Event}` | Fired when image fails to load |
255
+
256
+ ## CSS custom properties
257
+
258
+ | Property | Description |
259
+ | --- | --- |
260
+ | `--avatar-size` | Custom size (overrides size prop) |
261
+ | `--avatar-bg-color` | Fallback background color (default: purple-600) |
262
+ | `--avatar-corner-rounding` | How rounded is the avatar (default: circle) |
263
+ | `--avatar-ring-color` | Optional ring border color |
264
+ | `--avatar-ring-width` | Ring border width (default: 2px) |
265
+
266
+ ---
267
+
268
+ # `<btu-avatar-group>`
269
+ Source: https://ui.brightspot.com/docs/components/AvatarGroup.md
270
+
271
+ A container component for grouping multiple avatars with consistent styling.
272
+
273
+ AvatarGroup wraps multiple avatar elements and provides:
274
+ - Overflow handling (shows "+N" for excess avatars)
275
+ - Consistent spacing and ring borders
276
+ - Size inheritance for all child avatars
277
+
278
+ ```js
279
+ import '@brightspot/ui/components/avatar/AvatarGroup.js'
280
+ ```
281
+
282
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-avatar-group--docs
283
+
284
+ ## Attributes
285
+
286
+ | Attribute | Property | Type | Default | Description |
287
+ | --- | --- | --- | --- | --- |
288
+ | `max` | `max` | `number \| undefined` | | Maximum number of visible avatars. Remaining avatars shown as "+N" |
289
+ | `size` | `size` | `'xs' \| 'sm' \| 'md'` | `'md'` | Size variant for all child avatars (unless individually overridden) |
290
+
291
+ ## Methods
292
+
293
+ | Method | Description |
294
+ | --- | --- |
295
+ | `processAvatars(): void` | Process all avatar children: apply size, handle overflow Call this method when avatars are dynamically added or removed |
296
+
297
+ ## Events
298
+
299
+ | Event | Detail | Description |
300
+ | --- | --- | --- |
301
+ | `btu-avatar-group-ready` | | Fired after first render and initialization |
302
+ | `btu-avatar-group-overflow` | `{hidden: number}` | Fired when avatars are hidden due to max limit |
303
+
304
+ ---
305
+
306
+ # `<btu-badge>`
307
+ Source: https://ui.brightspot.com/docs/components/Badge.md
308
+
309
+ A badge component for highlighting important information.
310
+
311
+ Badges help highlight notifications, status, or new messages.
312
+ Primarily used for communicating secondary or additional information.
313
+
314
+ ```js
315
+ import '@brightspot/ui/components/badge/Badge.js'
316
+ ```
317
+
318
+ The CMS page defines this element itself, so a plugin can use it there without the import.
319
+
320
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-badge--docs
321
+
322
+ ## Attributes
323
+
324
+ | Attribute | Property | Type | Default | Description |
325
+ | --- | --- | --- | --- | --- |
326
+ | `variant` | `variant` | `'info' \| 'primary' \| 'error' \| 'success' \| 'warning'` | `'info'` | Style of the badge. - 'info': Informational (default) - 'primary': Primary action or emphasis - 'error': Error or danger state - 'success': Success or completion state - 'warning': Warning or caution state |
327
+ | `dot` | `dot` | `boolean` | `false` | Should a dot be displayed before the label? |
328
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'sm'` | Size variant. - 'sm': Small (default) - 'md': Medium - 'lg': Large |
329
+ | `activity` | `activity` | `'busy' \| 'live' \| undefined` | | Attention state that draws the eye to the badge. Names the *intent*; the component owns the visual treatment (so it can change without callers). - 'busy': an in-progress state — a glint shimmers across the label text - 'live': a live/active state — a ring ripples out from the leading dot (implies `dot`) |
330
+ | `fill` | `fill` | `'soft' \| 'solid'` | `'soft'` | Fill style. - 'soft': pale background with strong text (default) - 'solid': swaps the shades for a filled pill |
331
+
332
+ ## Events
333
+
334
+ | Event | Detail | Description |
335
+ | --- | --- | --- |
336
+ | `btu-badge-ready` | | Fired after first render and initialization |
337
+
338
+ ## Slots
339
+
340
+ | Slot | Description |
341
+ | --- | --- |
342
+ | (default) | Label text or child elements (e.g., btu-icon + text) |
343
+
344
+ ## CSS custom properties
345
+
346
+ | Property | Description |
347
+ | --- | --- |
348
+ | `--badge-color-foreground` | Text color (overrides theme color) |
349
+ | `--badge-color-background` | Background color (overrides theme color) |
350
+ | `--badge-radius-size` | Border radius size (overrides shape default, default: 999px) |
351
+ | `--badge-px` | Horizontal padding (overrides size default) |
352
+ | `--badge-py` | Vertical padding (overrides size default) |
353
+ | `--badge-dot-size` | Size of the dot affordance (default: 6px) |
354
+
355
+ ---
356
+
357
+ # `<btu-banner>`
358
+ Source: https://ui.brightspot.com/docs/components/Banner.md
359
+
360
+ A full-width container that pins a `<btu-message>` to the top of the CMS or a
361
+ content edit page. The banner has no content API of its own — compose a
362
+ `<btu-message>` inside it (or several, e.g. for a paginated banner) and the banner
363
+ spans each to 100% of the host, rendering it full-bleed (edge-to-edge, bottom
364
+ border only, no corner rounding).
365
+
366
+ Set the content (variant, label, symbol, dismissible, badge/description/actions
367
+ slots) on the message itself. The full-width treatment lives on this wrapper, so
368
+ the message has no `full-width` attribute — the banner owns that.
369
+
370
+ ```js
371
+ import '@brightspot/ui/components/banner/Banner.js'
372
+ ```
373
+
374
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-banner--docs
375
+
376
+ ## Events
377
+
378
+ | Event | Detail | Description |
379
+ | --- | --- | --- |
380
+ | `btu-banner-ready` | | Fired after the banner is first rendered and initialized |
381
+
382
+ ## Slots
383
+
384
+ | Slot | Description |
385
+ | --- | --- |
386
+ | (default) | One or more `<btu-message>` elements, full-bleed to the host width. With more than one, the banner auto-creates a `<btu-pagination>` and shows one at a time. |
387
+
388
+ ## CSS custom properties
389
+
390
+ | Property | Description |
391
+ | --- | --- |
392
+ | `--banner-z-index` | Stack order for the banner (default: 100). The banner is `position: relative`, so this always applies; set `position: sticky` to also pin it to the viewport. |
393
+
394
+ ---
395
+
396
+ # `<btu-button-group>`
397
+ Source: https://ui.brightspot.com/docs/components/ButtonGroup.md
398
+
399
+ A semantic container for grouping related buttons together.
400
+
401
+ Supports connected (joined) and spaced layouts, horizontal and vertical
402
+ orientation, group-level size and disabled propagation, and optional
403
+ toggle/selection modes (single-select or multi-select).
404
+
405
+ ```js
406
+ import '@brightspot/ui/components/button-group/ButtonGroup.js'
407
+ ```
408
+
409
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-button-group--docs
410
+
411
+ ## Attributes
412
+
413
+ | Attribute | Property | Type | Default | Description |
414
+ | --- | --- | --- | --- | --- |
415
+ | `label` | `label` | `string` | `''` | Accessible name for the group, announced by assistive devices via aria-label. |
416
+ | `orientation` | `orientation` | `'horizontal' \| 'vertical'` | `'horizontal'` | Layout direction of the buttons. |
417
+ | `variant` | `variant` | `'connected' \| 'spaced'` | `'connected'` | `connected` collapses shared borders for a joined appearance. `spaced` renders buttons with a gap. |
418
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'md'` | Propagates a uniform size to all child buttons. |
419
+ | `disabled` | `disabled` | `boolean` | `false` | When true, disables all child buttons as a group. |
420
+ | `selection` | `selection` | `'none' \| 'single' \| 'multiple'` | `'none'` | Enables toggle/selection behavior. `single` allows one active button; `multiple` allows many. |
421
+ | `value` | `value` | `string` | `''` | Reflects the currently selected button value(s). For `single`, the value of the active button. For `multiple`, a comma-delimited list of active values. |
422
+ | `name` | `name` | `string` | `''` | When set, creates hidden input(s) for native form participation. |
423
+
424
+ ## Events
425
+
426
+ | Event | Detail | Description |
427
+ | --- | --- | --- |
428
+ | `btu-button-group-ready` | | Fired after first render and initialization |
429
+ | `btu-button-group-change` | `{value: string}` | Fired when selection changes (single/multiple modes only) |
430
+ | `btu-icon-button-click` | `{name: string \| undefined}` | Bubbles from child btu-icon-button elements when clicked |
431
+
432
+ ## Slots
433
+
434
+ | Slot | Description |
435
+ | --- | --- |
436
+ | (default) | One or more `<button class="btu-button …">` or `<btu-icon-button>` elements to display in the group. The `connected` variant rounds the outer corners on the real `<button>`, so anchors styled as `.btu-button` slotted directly will not get rounded corners. Use `<button>` for grouped controls. |
437
+ | `end` | Pushes the child to the end of the group via auto-margin (vertical: bottom, horizontal: right) |
438
+
439
+ ## CSS custom properties
440
+
441
+ | Property | Description |
442
+ | --- | --- |
443
+ | `--button-group-gap` | Space between buttons when variant="spaced" (default: spacing.sm) |
444
+ | `--button-group-border-radius` | Corner radius of outer edges when variant="connected" (default: 0.5rem) |
445
+ | `--button-group-border-color` | Internal divider color between connected buttons (default: gray-300) |
446
+ | `--button-group-selection-bg` | Background of a toggled/selected child (default: child's --button-tint-subtle) |
447
+ | `--button-group-selection-color` | Text/icon color of a toggled/selected child (default: child's --button-tint-strong) |
448
+ | `--button-group-shimmer-highlight` | Highlight color of the selection shimmer effect (default: child's --button-tint-highlight) Reads the following CSS custom properties from each child button (set by the button plugin per color variant — see tailwind-plugin-button.ts): |
449
+ | `--button-tint-subtle` | Subtle tint of the child button's color family (read-only here) |
450
+ | `--button-tint-strong` | Strong tint of the child button's color family (read-only here) |
451
+ | `--button-tint-highlight` | Highlight tint of the child button's color family (read-only here) |
452
+
453
+ ## CSS states
454
+
455
+ | State | Description |
456
+ | --- | --- |
457
+ | `:state(btu-connected)` | Applied when variant="connected", targetable via :state(btu-connected) |
458
+ | `:state(btu-spaced)` | Applied when variant="spaced", targetable via :state(btu-spaced) |
459
+ | `:state(btu-horizontal)` | Applied when orientation="horizontal", targetable via :state(btu-horizontal) |
460
+ | `:state(btu-vertical)` | Applied when orientation="vertical", targetable via :state(btu-vertical) |
461
+ | `:state(btu-disabled)` | Applied when the group is disabled, targetable via :state(btu-disabled) |
462
+
463
+ ---
464
+
465
+ # `<btu-card>`
466
+ Source: https://ui.brightspot.com/docs/components/Card.md
467
+
468
+ A flexible content container for presenting and organizing information.
469
+
470
+ The layout is driven by composition:
471
+
472
+ - a direct `<img>` or `<btu-icon>` child renders the media layout (image area);
473
+ the icon shows in the image area as the fallback.
474
+ - neither child renders a text-only card.
475
+ - the `compact` attribute renders a quick-start tile; only a
476
+ featured `<btu-icon>` and the `action` slot are used.
477
+
478
+ Composable children, all relocated into the layout automatically:
479
+ - `<img>` — the thumbnail.
480
+ - `<btu-icon>` — the featured icon (compact) or the media image fallback (shown
481
+ when no `<img>` is provided or it fails to load; defaults to `file-text`). The card sizes it.
482
+ - `<btu-badge>` — a status badge.
483
+ - `slot="action"` / `slot="secondary-action"` — a control in the top-right corner
484
+ or next to the title. A `<btu-checkbox>` there stays visible and toggles the
485
+ selected styling (listen for the bubbling `btu-checkbox-change` event); buttons
486
+ reveal on hover/focus.
487
+
488
+ Cards are full-width by default and rely on the parent layout (grid or flex) to
489
+ control their size.
490
+
491
+ ```js
492
+ import '@brightspot/ui/components/card/Card.js'
493
+ ```
494
+
495
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-card--docs
496
+
497
+ ## Attributes
498
+
499
+ | Attribute | Property | Type | Default | Description |
500
+ | --- | --- | --- | --- | --- |
501
+ | `heading` | `heading` | `string` | `''` | Heading text displayed on the card. |
502
+ | `heading-level` | `headingLevel` | `number` | `2` | Heading level (1-6) for the card heading element. Drives the semantic h1–h6 tag. Invalid values log a warning and fall back to the default (2). |
503
+ | `description` | `description` | `string \| undefined` | | Supporting body text. Truncated to 3 lines via CSS. |
504
+ | `compact` | `compact` | `boolean` | `false` | Renders the card as a compact quick-start tile. Badge, image, fields, and secondary-action children are ignored in this case. |
505
+ | `disabled` | `disabled` | `boolean` | `false` | Whether the card is disabled. |
506
+ | `href` | `href` | `string \| undefined` | | Navigation URL for the entire card surface. When set, the card renders as a link. |
507
+
508
+ ## Events
509
+
510
+ | Event | Detail | Description |
511
+ | --- | --- | --- |
512
+ | `btu-card-ready` | | Fired after first render and initialization |
513
+
514
+ ## Slots
515
+
516
+ | Slot | Description |
517
+ | --- | --- |
518
+ | `action` | Intended for a single action in the top-right corner of the card. |
519
+ | `secondary-action` | Intended for a single action next to the title. |
520
+ | `fields` | Intended for additional metadata fields displayed below the title & description |
521
+
522
+ ## CSS custom properties
523
+
524
+ | Property | Description |
525
+ | --- | --- |
526
+ | `--card-min-width` | Minimum width of the card (default: 160px) |
527
+ | `--card-background` | Background color (default: var(--btu-theme-white)) |
528
+ | `--card-border` | Border style (default: 1px solid gray-200) |
529
+ | `--card-radius` | Corner rounding (default: 8px) |
530
+ | `--card-img-ratio` | Fixed aspect ratio for the thumbnail when an `<img>` child is present (default: 16 / 9) |
531
+ | `--card-img-fit` | Object-fit mode for the `<img>` child thumbnail (default: contain) |
532
+ | `--card-icon-background` | Background color behind the composed icon (compact card and media-image fallback) (default: gray-100) |
533
+
534
+ ---
535
+
536
+ # `<btu-checkbox>`
537
+ Source: https://ui.brightspot.com/docs/components/Checkbox.md
538
+
539
+ A checkbox component for selecting one or more options from a set.
540
+
541
+ Uses a hidden native checkbox internally for accessibility and form
542
+ participation. Styled via the `btu-checkbox` Tailwind plugin classes.
543
+ The component manages its own `className` — do not modify it externally
544
+ after initialization (classes present at connection time are preserved).
545
+
546
+ ```js
547
+ import '@brightspot/ui/components/checkbox/Checkbox.js'
548
+ ```
549
+
550
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-checkbox--docs
551
+
552
+ ## Attributes
553
+
554
+ | Attribute | Property | Type | Default | Description |
555
+ | --- | --- | --- | --- | --- |
556
+ | `label` | `label` | `string \| undefined` | | The text label displayed next to the checkbox. |
557
+ | `description` | `description` | `string \| undefined` | | Optional helper text displayed below the label. |
558
+ | `size` | `size` | `'sm' \| 'md'` | `'sm'` | Controls the scale of the checkbox and associated typography. |
559
+ | `checked` | `checked` | `boolean` | `false` | Whether the checkbox is currently selected. |
560
+ | `indeterminate` | `indeterminate` | `boolean` | `false` | Whether the checkbox is in a partially selected state. Sets `aria-checked='mixed'` and activates the native `:indeterminate` pseudo-class. Cleared automatically when the user clicks the checkbox. |
561
+ | `disabled` | `disabled` | `boolean` | `false` | If true, the checkbox is non-interactive and visually muted. |
562
+ | `invalid` | `invalid` | `boolean` | `false` | If true, displays error styling on the checkbox. |
563
+ | `error` | `error` | `string \| undefined` | | Error message text displayed below the checkbox when validation fails. Setting this also activates error styling without needing to set invalid. |
564
+ | `required` | `required` | `boolean` | `false` | Marks the field as mandatory for form submission. |
565
+ | `name` | `name` | `string \| undefined` | | Name of the form control submitted with the form data. |
566
+ | `value` | `value` | `string` | `'on'` | Value associated with the checkbox when submitted. |
567
+
568
+ ## Events
569
+
570
+ | Event | Detail | Description |
571
+ | --- | --- | --- |
572
+ | `btu-checkbox-ready` | | Fired after the checkbox is first rendered and initialized |
573
+ | `btu-checkbox-change` | `{ checked: boolean }` | Fired when the user toggles the checked state |
574
+
575
+ ## CSS custom properties
576
+
577
+ | Property | Description |
578
+ | --- | --- |
579
+ | `--checkbox-color-primary` | Background and border color when checked or indeterminate, and tinted background/border on unchecked hover (default: oklch(var(--btu-theme-primary-700))) |
580
+ | `--checkbox-color-border` | Border color in the unchecked state (default: oklch(var(--btu-theme-gray-300))) |
581
+ | `--checkbox-color-error` | Border and text color in the error state (default: oklch(var(--btu-theme-error-600))) |
582
+ | `--checkbox-border-radius` | Corner rounding of the checkbox square (default: 4px) |
583
+ | `--checkbox-label-spacing` | Distance between the checkbox and the label (default: 0.75rem) |
584
+ | `--checkbox-box-size` | [Internal] Width and height of the checkbox square, set by the size variant (sm: 1rem, md: 1.25rem). Use the `size` attribute instead of overriding directly — the icon must scale in tandem. |
585
+ | `--checkbox-icon-size` | [Internal] Width and height of the icon inside the box, set by the size variant (sm: 0.75rem, md: 0.875rem). Use the `size` attribute instead of overriding directly. |
586
+
587
+ ---
588
+
589
+ # `<btu-circular-progress>`
590
+ Source: https://ui.brightspot.com/docs/components/CircularProgress.md
591
+
592
+ A circular progress indicator for showing loading states or progress.
593
+
594
+ ```js
595
+ import '@brightspot/ui/components/circular-progress/CircularProgress.js'
596
+ ```
597
+
598
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-circular-progress--docs
599
+
600
+ ## Attributes
601
+
602
+ | Attribute | Property | Type | Default | Description |
603
+ | --- | --- | --- | --- | --- |
604
+ | `indeterminate` | `indeterminate` | `boolean` | `true` | Whether the progress indicator is indeterminate (animated spinner). When false, shows determinate progress based on the progress value. |
605
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'sm'` | Size variant. - 'sm': Small (16px) - default - 'md': Medium (32px) - 'lg': Large (48px) |
606
+ | `color` | `color` | `ProgressColors` | `'primary'` | Color theme of the progress indicator. Supports: black, white, primary, teal, gray, purple, rose, error, warning, success |
607
+ | `thickness` | `thickness` | `number \| undefined` | | Stroke width of the progress indicator. |
608
+ | `progress` | `progress` | `number` | | Progress value for determinate variant. Clamped to 0–100. |
609
+ | `label` | `label` | `string \| undefined` | | Optional label text to display with the progress indicator. |
610
+ | `initial-animation` | `initialAnimation` | `boolean` | `true` | Whether to animate progress from 0 to target value when component first becomes visible. |
611
+ | `aria-label` | `ariaLabel` | `string \| null` | `null` | Optional aria-label attribute for screen readers. Describes what the progress indicator represents. |
612
+ | `aria-labelledby` | `ariaLabelledBy` | `string \| null` | `null` | Optional aria-labelledby attribute for screen readers. References the ID of an element that labels the progress indicator. |
613
+ | `aria-valuetext` | `ariaValueText` | `string \| null` | `null` | Optional aria-valuetext attribute for screen readers. Provides human-readable text alternative for progress value. |
614
+ | `completion-announcement` | `completionAnnouncement` | `string \| undefined` | | Optional message to announce to screen readers when progress reaches 100%. If not provided, no announcement will be made on completion. |
615
+
616
+ ## Events
617
+
618
+ | Event | Detail | Description |
619
+ | --- | --- | --- |
620
+ | `btu-circular-progress-ready` | | Fired after first render and initialization |
621
+ | `btu-circular-progress-complete` | | Fired when determinate progress reaches 100 |
622
+
623
+ ## CSS custom properties
624
+
625
+ | Property | Description |
626
+ | --- | --- |
627
+ | `--progress-color` | Custom progress indicator color (overrides theme color) |
628
+ | `--track-color` | Track/background color (overrides default gray-100) |
629
+ | `--progress-size` | Custom size in pixels (overrides size preset) |
630
+
631
+ ---
632
+
633
+ # `<btu-copy-to-clipboard>`
634
+ Source: https://ui.brightspot.com/docs/components/CopyToClipboard.md
635
+
636
+ A button component that copies text to the system clipboard.
637
+
638
+ Provides visual feedback when text is successfully copied by applying
639
+ a temporary state that can be styled with CSS.
640
+
641
+ Button styling is inherited from `btu-button-*` classes. Override appearance
642
+ by passing custom classes via the `buttonclasses` attribute.
643
+
644
+ ```js
645
+ import '@brightspot/ui/components/copy-to-clipboard/CopyToClipboard.js'
646
+ ```
647
+
648
+ The CMS page defines this element itself, so a plugin can use it there without the import.
649
+
650
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-copy-to-clipboard--docs
651
+
652
+ ## Attributes
653
+
654
+ | Attribute | Property | Type | Default | Description |
655
+ | --- | --- | --- | --- | --- |
656
+ | `copydata` | `copydata` | `string \| undefined` | | The text to be copied to the system clipboard. |
657
+ | `buttonclasses` | `buttonClasses` | `string \| undefined` | | Custom CSS classes for the button. If provided, replaces the default classes. |
658
+
659
+ ## Properties
660
+
661
+ These have no attribute; set them from JavaScript.
662
+
663
+ | Property | Type | Default | Description |
664
+ | --- | --- | --- | --- |
665
+ | `copiedStateKey` (read-only) | `'btu-copy-to-clipboard-copied'` | | Custom state applied briefly after a successful copy; also emitted as an event. |
666
+
667
+ ## Methods
668
+
669
+ | Method | Description |
670
+ | --- | --- |
671
+ | `copy(text: string, timeout: unknown)` | Copies the copydata to the system clipboard. Displays a success state for 3 seconds after copying. |
672
+
673
+ ## Events
674
+
675
+ | Event | Detail | Description |
676
+ | --- | --- | --- |
677
+ | `btu-copy-to-clipboard-ready` | | Fired after first render and initialization |
678
+ | `btu-copy-to-clipboard-copied` | | Fired when text is successfully copied to clipboard |
679
+
680
+ ## CSS states
681
+
682
+ | State | Description |
683
+ | --- | --- |
684
+ | `:state(btu-copy-to-clipboard-copied)` | Applied briefly after a successful copy, targetable via :state(btu-copy-to-clipboard-copied) |
685
+
686
+ ---
687
+
688
+ # `<btu-dropdown>`
689
+ Source: https://ui.brightspot.com/docs/components/Dropdown.md
690
+
691
+ A dropdown component that renders a trigger button and manages a floating panel
692
+ containing a `btu-dropdown-menu`.
693
+
694
+ Uses the native Popover API and CSS anchor positioning for panel management.
695
+ The trigger button is built with existing `btu-button-*` classes.
696
+
697
+ **Trigger button styling:** Set `--button-*` CSS custom properties on `<btu-dropdown>`
698
+ or a parent element to customize the trigger via CSS inheritance (e.g.,
699
+ `--button-border-radius`, `--button-color-background`). See
700
+ `tailwind-plugin-button.ts` for available props.
701
+
702
+ ```js
703
+ import '@brightspot/ui/components/dropdown/Dropdown.js'
704
+ ```
705
+
706
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-dropdown--docs
707
+
708
+ ## Attributes
709
+
710
+ | Attribute | Property | Type | Default | Description |
711
+ | --- | --- | --- | --- | --- |
712
+ | `label` | `label` | `string` | `''` | Trigger button text. |
713
+ | `open` | `open` | `boolean` | `false` | Panel visibility state. Can be set programmatically (e.g., for tour UIs) — syncs to `showPopover()`/`hidePopover()` in `updated()`. |
714
+ | `placement` | `placement` | `'bottom-start' \| 'bottom-end' \| 'top-start' \| 'top-end'` | `'bottom-start'` | Panel placement: 'bottom-start', 'bottom-end', 'top-start', 'top-end'. |
715
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'md'` | Button size: 'sm', 'md', 'lg'. |
716
+ | `disabled` | `disabled` | `boolean` | `false` | Prevents opening. |
717
+ | `variant` | `variant` | `'primary' \| 'secondary' \| 'tertiary' \| 'primary-clear' \| 'secondary-clear' \| 'tertiary-clear'` | `'secondary'` | Button variant: 'primary', 'secondary', 'tertiary', 'primary-clear', 'secondary-clear', 'tertiary-clear'. |
718
+ | `symbol` | `symbol` | `string` | `''` | Lucide icon symbol for the trigger. |
719
+ | `icon-position` | `iconPosition` | `'leading' \| 'trailing'` | `'leading'` | Icon position: 'leading' or 'trailing'. |
720
+ | `icon-only` | `iconOnly` | `boolean` | `false` | Hides label, shows icon only. |
721
+ | `stay-open-on-select` | `stayOpenOnSelect` | `boolean` | `false` | Keeps panel open on item click. |
722
+ | `no-chevron` | `noChevron` | `boolean` | `false` | Hides the chevron icon on the trigger button. |
723
+ | `tooltip` | `tooltip` | `string` | `''` | Tooltip text content. Set to empty string to remove the tooltip. |
724
+ | `tooltip-position` | `tooltipPosition` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'top'` | Position relative to the host element. Auto-flips when constrained by the viewport. |
725
+ | `tooltip-delay` | `tooltipDelay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
726
+ | `tooltip-offset` | `tooltipOffset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between host and tooltip (sm=4px, md=8px, lg=12px, xl=16px). |
727
+ | `tooltip-no-arrow` | `tooltipNoArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
728
+ | `tooltip-trigger` | `tooltipTrigger` | `string` | `'hover focus'` | Space-separated trigger types: 'hover', 'focus', 'click'. |
729
+
730
+ ## Events
731
+
732
+ | Event | Detail | Description |
733
+ | --- | --- | --- |
734
+ | `btu-dropdown-ready` | | Fired after first render and initialization |
735
+ | `btu-dropdown-show` | | Fired when the dropdown panel opens |
736
+ | `btu-dropdown-hide` | | Fired when the dropdown panel closes |
737
+ | `btu-dropdown-item-select` | `{label: string, value: string, selected: boolean}` | Fired when a menu item is activated (bubbles from btu-dropdown-item) |
738
+ | `btu-dropdown-item-favorite` | `{label: string, favorited: boolean}` | Fired when a menu item's favorite is toggled (bubbles from btu-dropdown-item) |
739
+
740
+ ## Slots
741
+
742
+ | Slot | Description |
743
+ | --- | --- |
744
+ | (default) | A `btu-dropdown-menu` element containing `btu-dropdown-item` children |
745
+
746
+ ## CSS custom properties
747
+
748
+ | Property | Description |
749
+ | --- | --- |
750
+ | `--dropdown-panel-background` | Panel background color (default: white) |
751
+ | `--dropdown-panel-border-color` | Panel border color (default: gray-200) |
752
+ | `--dropdown-panel-border-radius` | Panel border radius (default: borderRadius.lg) |
753
+ | `--dropdown-panel-min-width` | Panel minimum width (default: max(12rem, anchor-size(width))) |
754
+ | `--dropdown-item-background` | Item background color (default: transparent) |
755
+ | `--dropdown-item-color` | Item text color (default: gray-700) |
756
+ | `--dropdown-item-hover-background` | Item hover background (default: gray-100) |
757
+ | `--dropdown-item-hover-color` | Item hover text color (default: gray-900) |
758
+ | `--dropdown-item-selected-background` | Selected item background (default: primary-50) |
759
+ | `--dropdown-item-selected-color` | Selected item text color (default: primary-700) |
760
+ | `--dropdown-item-font-size` | Item font size (default: fontSize.sm) |
761
+ | `--dropdown-divider-color` | Divider line color (default: gray-200) |
762
+ | `--dropdown-empty-color` | Empty state text color (default: gray-400) |
763
+
764
+ ---
765
+
766
+ # `<btu-dropdown-item>`
767
+ Source: https://ui.brightspot.com/docs/components/DropdownItem.md
768
+
769
+ A menu item component for use inside `btu-dropdown-menu`.
770
+
771
+ Renders as a menu item, divider, or subhead depending on the `type` property.
772
+ Supports checkbox mode (inherited from parent menu), icons, keyboard shortcuts,
773
+ and favorite toggles.
774
+
775
+ ```js
776
+ import '@brightspot/ui/components/dropdown/DropdownItem.js'
777
+ ```
778
+
779
+ ## Attributes
780
+
781
+ | Attribute | Property | Type | Default | Description |
782
+ | --- | --- | --- | --- | --- |
783
+ | `label` | `label` | `string` | `''` | Display text for the item. |
784
+ | `type` | `type` | `'default' \| 'divider' \| 'subhead'` | `'default'` | Item type: 'default', 'divider', or 'subhead'. |
785
+ | `symbol` | `symbol` | `string` | `''` | Lucide icon symbol. |
786
+ | `shortcut` | `shortcut` | `string` | `''` | Keyboard shortcut display text. |
787
+ | `value` | `value` | `string` | `''` | Optional data value associated with the item. |
788
+ | `disabled` | `disabled` | `boolean` | `false` | Whether the item is disabled. |
789
+ | `selected` | `selected` | `boolean` | `false` | Whether the item is selected/checked. |
790
+ | `favorited` | `favorited` | `boolean` | `false` | Whether the item is favorited. |
791
+ | `error` | `error` | `boolean` | `false` | Whether the item has an error. |
792
+
793
+ ## Events
794
+
795
+ | Event | Detail | Description |
796
+ | --- | --- | --- |
797
+ | `btu-dropdown-item-ready` | | Fired after first render |
798
+ | `btu-dropdown-item-select` | `{label: string, value: string, selected: boolean}` | Fired when item is activated |
799
+ | `btu-dropdown-item-favorite` | `{label: string, favorited: boolean}` | Fired when favorite is toggled |
800
+
801
+ ## CSS custom properties
802
+
803
+ | Property | Description |
804
+ | --- | --- |
805
+ | `--dropdown-item-font-size` | Item font size (default: theme fontSize.sm) |
806
+ | `--dropdown-item-color` | Item text color (default: gray-700) |
807
+ | `--dropdown-item-background` | Item background color (default: transparent) |
808
+ | `--dropdown-item-hover-background` | Background on hover (default: gray-100) |
809
+ | `--dropdown-item-hover-color` | Text color on hover (default: gray-900) |
810
+ | `--dropdown-item-selected-background` | Background when selected (default: primary-50) |
811
+ | `--dropdown-item-selected-color` | Text color when selected (default: primary-700) |
812
+
813
+ ---
814
+
815
+ # `<btu-dropdown-menu>`
816
+ Source: https://ui.brightspot.com/docs/components/DropdownMenu.md
817
+
818
+ A menu container component that provides keyboard navigation and ARIA menu semantics.
819
+
820
+ Contains `btu-dropdown-item` children and manages roving tabindex, typeahead search,
821
+ and keyboard navigation following the WAI-ARIA Menu Button Pattern.
822
+
823
+ ```js
824
+ import '@brightspot/ui/components/dropdown/DropdownMenu.js'
825
+ ```
826
+
827
+ ## Attributes
828
+
829
+ | Attribute | Property | Type | Default | Description |
830
+ | --- | --- | --- | --- | --- |
831
+ | `name` | `name` | `string` | `''` | Accessible name for the menu, displayed in header when header is true. |
832
+ | `header` | `header` | `boolean` | `false` | Show header bar with menu name. |
833
+ | `checkbox` | `checkbox` | `boolean` | `false` | Enable checkbox mode for items (menuitemcheckbox role). |
834
+ | `icon` | `icon` | `boolean` | `false` | Show icons before each item. |
835
+ | `symbol` | `symbol` | `string` | `''` | Fallback Lucide icon symbol for items without their own. |
836
+ | `favorites` | `favorites` | `boolean` | `false` | Show favorite toggle on each item. |
837
+ | `shortcuts` | `shortcuts` | `boolean` | `false` | Show keyboard shortcut text on each item. |
838
+ | `empty-message` | `emptyMessage` | `string` | `'No items available'` | Message displayed when the menu has no focusable items. |
839
+
840
+ ## Events
841
+
842
+ | Event | Detail | Description |
843
+ | --- | --- | --- |
844
+ | `btu-dropdown-menu-ready` | | Fired after first render |
845
+
846
+ ## Slots
847
+
848
+ | Slot | Description |
849
+ | --- | --- |
850
+ | (default) | Menu items (`btu-dropdown-item` elements) |
851
+
852
+ ## CSS custom properties
853
+
854
+ | Property | Description |
855
+ | --- | --- |
856
+ | `--dropdown-empty-color` | Empty state text color (default: gray-400) |
857
+
858
+ ---
859
+
860
+ # `<btu-empty-state>`
861
+ Source: https://ui.brightspot.com/docs/components/EmptyState.md
862
+
863
+ An empty state component for displaying placeholder content when no data is available.
864
+
865
+ Supports a graphic slot for icons/images/pictures/SVGs, a heading, a description,
866
+ and an actions slot for buttons or links. Available in three sizes (sm, md, lg)
867
+ with semantic heading levels.
868
+
869
+ ## Architecture: Light DOM + Pseudo-Slots
870
+
871
+ This component uses **Light DOM** (no Shadow Root) with pseudo-slots:
872
+ - User-provided children are physically moved into internal containers
873
+ - Movement is based on `slot` attributes
874
+ - The `onFind` utility detects and redistributes newly-added children (one-time per element)
875
+
876
+ ### Node Redistribution Rules
877
+ - `slot="graphic"` - Moved to graphic container (icon, image, picture, or SVG)
878
+ - `slot="actions"` - Moved to an internal `btu-button-group` (variant="spaced")
879
+
880
+ ### Actions composition
881
+
882
+ The actions container IS a `btu-button-group` with `variant="spaced"`. Its `size`
883
+ is mapped from the empty-state `size` prop (sm→small, md→medium, lg→large) so all
884
+ child `btu-button` / `btu-icon-button` elements get consistent sizing and group
885
+ semantics (`role="group"`, roving tabindex, disabled propagation) for free.
886
+
887
+ ```js
888
+ import '@brightspot/ui/components/empty-state/EmptyState.js'
889
+ ```
890
+
891
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-empty-state--docs
892
+
893
+ ## Attributes
894
+
895
+ | Attribute | Property | Type | Default | Description |
896
+ | --- | --- | --- | --- | --- |
897
+ | `heading` | `heading` | `string` | `''` | Heading text displayed in the empty state. |
898
+ | `description` | `description` | `string \| undefined` | | Description text displayed below the heading. |
899
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'md'` | Size variant of the empty state. Affects spacing, description text, graphic size, and — when `heading-level` is unset — the default heading level (sm→5, md→4, lg→3). |
900
+ | `heading-level` | `headingLevel` | `number \| undefined` | | Heading level (1-6). When set to a valid integer 1-6, overrides the size-based default and drives both the semantic h1-h6 tag and the visual heading size (btu-heading-1 through btu-heading-6). Invalid values log a warning and fall back to the size-based default. |
901
+
902
+ ## Events
903
+
904
+ | Event | Detail | Description |
905
+ | --- | --- | --- |
906
+ | `btu-empty-state-ready` | | Fired after first render and initialization |
907
+ | `btu-button-group-ready` | | Bubbles from the internal actions button-group |
908
+
909
+ ## Slots
910
+
911
+ | Slot | Description |
912
+ | --- | --- |
913
+ | `graphic` | Pseudo-slot for icon, image, picture, or SVG graphic. When the child is a `btu-icon`, the component overrides its `size` attribute based on the empty-state `size` prop (sm→md, md→lg, lg→xl). Use an `img`, `picture`, or inline `svg` for full size control. |
914
+ | `actions` | Pseudo-slot for action buttons. Children are moved into an internal `btu-button-group` (variant="spaced"), so size and disabled state are managed by the group. |
915
+
916
+ ## CSS custom properties
917
+
918
+ | Property | Description |
919
+ | --- | --- |
920
+ | `--empty-state-max-width` | Maximum width of the content block (default: min(75cqw, 360px)) |
921
+ | `--empty-state-color-heading` | Heading text color (default: gray-900) |
922
+ | `--empty-state-color-description` | Description text color (default: gray-500) |
923
+
924
+ ---
925
+
926
+ # `<btu-esca-avatar>`
927
+ Source: https://ui.brightspot.com/docs/components/EscaAvatar.md
928
+
929
+ The animated avatar for the Esca AI assistant, driven entirely by its `state` attribute so the same
930
+ element works wherever the assistant appears.
931
+
932
+ Accessibility: the avatar is a visual indicator, not a status channel. By default it exposes a static
933
+ accessible name (`role="img"`, `aria-label="Esca"`) so it reads like an author/identity avatar; both
934
+ are only set when absent, so consumers can override them.
935
+ - When the assistant is already named in the surrounding UI (the common case in a chat), treat the
936
+ avatar as decorative: set `aria-hidden="true"` to avoid a redundant announcement.
937
+ - Do NOT convey activity (thinking / done) by changing this element's ARIA per `state` — a looping
938
+ `search` would announce repeatedly. Surface status as text in a polite `aria-live` region owned by
939
+ the chat UI, which has the context to word and time announcements. This component intentionally
940
+ does not announce its own state.
941
+
942
+ ```js
943
+ import '@brightspot/ui/components/esca-avatar/EscaAvatar.js'
944
+ ```
945
+
946
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-esca-avatar--docs
947
+
948
+ ## Attributes
949
+
950
+ | Attribute | Property | Type | Default | Description |
951
+ | --- | --- | --- | --- | --- |
952
+ | `state` | `state` | `'idle' \| 'wave' \| 'search' \| 'complete' \| 'glow'` | `'idle'` | Animation to play; changing it swaps the clip. |
953
+ | `size` | `size` | `'xs' \| 'sm' \| 'md' \| 'lg' \| 'xl'` | `'md'` | Size of the avatar, mirroring `<btu-avatar>`'s scale. `--esca-avatar-size` overrides it. |
954
+
955
+ ## Events
956
+
957
+ | Event | Detail | Description |
958
+ | --- | --- | --- |
959
+ | `btu-esca-avatar-ready` | | Fired after the first render |
960
+ | `btu-esca-avatar-complete` | `{state: string}` | Fired when a non-looping animation finishes |
961
+
962
+ ## CSS custom properties
963
+
964
+ | Property | Description |
965
+ | --- | --- |
966
+ | `--esca-avatar-size` | Width and height of the avatar; overrides the `size` attribute (default: 2.5rem) |
967
+
968
+ ---
969
+
970
+ # `<btu-icon>`
971
+ Source: https://ui.brightspot.com/docs/components/Icon.md
972
+
973
+ An icon component for displaying Lucide icons.
974
+
975
+ Icons inherit parent text color by default or can use gradient fills.
976
+ All icons are from the Lucide icon library (https://lucide.dev/icons/).
977
+ Supports both direct SVG rendering and mask-based gradient fills.
978
+
979
+ ```js
980
+ import '@brightspot/ui/components/icon/Icon.js'
981
+ ```
982
+
983
+ The CMS page defines this element itself, so a plugin can use it there without the import.
984
+
985
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-icon--docs
986
+
987
+ ## Attributes
988
+
989
+ | Attribute | Property | Type | Default | Description |
990
+ | --- | --- | --- | --- | --- |
991
+ | `size` | `size` | `'xs' \| 'sm' \| 'md' \| 'lg' \| 'xl'` | `'md'` | Size of the icon. - 'xs': Extra small (0.75rem) - 'sm': Small (1rem) - 'md': Medium (1.25rem, default) - 'lg': Large (1.5rem) - 'xl': Extra large (1.75rem) |
992
+ | `symbol` | `symbol` | `string` | `'circle-dashed'` | Lucide icon name to display. See https://lucide.dev/icons/ for available icons. Lucide v1 removed all brand logos - legacy facebook/instagram/slack/twitter swap to the vendored brand marks at runtime, any other brand name falls back to circle-dashed. |
993
+ | `brand` | `brand` | `string \| undefined` | | Vendored brand mark to display instead of a Lucide icon (names in src/brand-icons.ts); takes precedence over `symbol`. |
994
+ | `gradient` | `gradient` | `IconGradientColor \| undefined` | | Theme color to use for gradient fill. When set, icon displays with gradient. When undefined, icon inherits parent text color. |
995
+ | `emphasize` | `emphasize` | `boolean \| 'pulse' \| undefined` | | Emphasize mode — renders a tonal circle with ring behind the icon. Colors are derived from `currentColor` via oklch relative color syntax. Defaults to primary; override with Tailwind `text-*` classes or `style="color: ..."`. Set as a boolean for the static circle, or `"pulse"` for a one-shot ring animation. Not intended for use with `gradient` — the two features target conflicting rendering modes. |
996
+
997
+ ## Events
998
+
999
+ | Event | Detail | Description |
1000
+ | --- | --- | --- |
1001
+ | `btu-icon-ready` | | Fired after first render and initialization |
1002
+
1003
+ ## CSS custom properties
1004
+
1005
+ | Property | Description |
1006
+ | --- | --- |
1007
+ | `--icon-size` | Icon size (overrides size default) |
1008
+ | `--icon-stroke-width` | SVG stroke width as a unitless number in viewBox units; scales visually with icon size (default: 2) |
1009
+ | `--icon-fill` | Icon fill color for filled icons (e.g., "currentColor") |
1010
+ | `--icon-svg` | SVG data URI for mask-based rendering |
1011
+
1012
+ ---
1013
+
1014
+ # `<btu-icon-button>`
1015
+ Source: https://ui.brightspot.com/docs/components/IconButton.md
1016
+
1017
+ Surfaces the different actions someone can perform in an interface where space is limited.
1018
+
1019
+ Uses an icon to communicate the action and supports multiple visual types and sizes.
1020
+ Tooltip support is built-in for accessibility in compact layouts.
1021
+
1022
+ ```js
1023
+ import '@brightspot/ui/components/icon-button/IconButton.js'
1024
+ ```
1025
+
1026
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-icon-button--docs
1027
+
1028
+ ## Attributes
1029
+
1030
+ | Attribute | Property | Type | Default | Description |
1031
+ | --- | --- | --- | --- | --- |
1032
+ | `name` | `name` | `string \| undefined` | | Optional name for the button which can be used to identify the button in a callback. |
1033
+ | `type` | `type` | `'primary' \| 'primary-clear' \| 'primary-stroke' \| 'secondary' \| 'secondary-clear' \| 'secondary-stroke' \| 'tertiary' \| 'tertiary-clear' \| 'tertiary-stroke'` | `'primary'` | Specifies the type of icon-button, controlling the visual style. |
1034
+ | `symbol` | `symbol` | `string \| undefined` | | Lucide icon symbol. |
1035
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'md'` | Specifies the size of icon-button. |
1036
+ | `destructive` | `destructive` | `boolean` | `false` | Specifies an icon-button will be used to take any destructive action overriding the default color used for the icon-button type with the error color. |
1037
+ | `disabled` | `disabled` | `boolean` | `false` | Disables the button, preventing interaction and indicating an inactive state. |
1038
+ | `tooltip` | `tooltip` | `string` | `''` | Tooltip text content. Set to empty string to remove the tooltip. |
1039
+ | `tooltip-position` | `tooltipPosition` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'top'` | Position relative to the host element. Auto-flips when constrained by the viewport. |
1040
+ | `tooltip-delay` | `tooltipDelay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
1041
+ | `tooltip-offset` | `tooltipOffset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between host and tooltip (sm=4px, md=8px, lg=12px, xl=16px). |
1042
+ | `tooltip-no-arrow` | `tooltipNoArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
1043
+ | `tooltip-trigger` | `tooltipTrigger` | `string` | `'hover focus'` | Space-separated trigger types: 'hover', 'focus', 'click'. |
1044
+
1045
+ ## Events
1046
+
1047
+ | Event | Detail | Description |
1048
+ | --- | --- | --- |
1049
+ | `btu-icon-button-ready` | | Fired after first render and initialization |
1050
+ | `btu-icon-button-click` | `{name: string \| undefined}` | Fired when the button is clicked |
1051
+
1052
+ ---
1053
+
1054
+ # `<btu-linear-progress>`
1055
+ Source: https://ui.brightspot.com/docs/components/LinearProgress.md
1056
+
1057
+ A horizontal linear progress bar for showing task completion.
1058
+
1059
+ ```js
1060
+ import '@brightspot/ui/components/linear-progress/LinearProgress.js'
1061
+ ```
1062
+
1063
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-linear-progress--docs
1064
+
1065
+ ## Attributes
1066
+
1067
+ | Attribute | Property | Type | Default | Description |
1068
+ | --- | --- | --- | --- | --- |
1069
+ | `color` | `color` | `ProgressColors` | `'primary'` | Color theme of the progress indicator. Supports: black, white, primary, teal, gray, purple, rose, error, warning, success |
1070
+ | `thickness` | `thickness` | `number \| undefined` | | Stroke width of the progress indicator. |
1071
+ | `progress` | `progress` | `number` | | Progress value for determinate variant. Clamped to 0–100. |
1072
+ | `label` | `label` | `string \| undefined` | | Optional label text to display with the progress indicator. |
1073
+ | `initial-animation` | `initialAnimation` | `boolean` | `true` | Whether to animate progress from 0 to target value when component first becomes visible. |
1074
+ | `aria-label` | `ariaLabel` | `string \| null` | `null` | Optional aria-label attribute for screen readers. Describes what the progress indicator represents. |
1075
+ | `aria-labelledby` | `ariaLabelledBy` | `string \| null` | `null` | Optional aria-labelledby attribute for screen readers. References the ID of an element that labels the progress indicator. |
1076
+ | `aria-valuetext` | `ariaValueText` | `string \| null` | `null` | Optional aria-valuetext attribute for screen readers. Provides human-readable text alternative for progress value. |
1077
+ | `completion-announcement` | `completionAnnouncement` | `string \| undefined` | | Optional message to announce to screen readers when progress reaches 100%. If not provided, no announcement will be made on completion. |
1078
+
1079
+ ## Events
1080
+
1081
+ | Event | Detail | Description |
1082
+ | --- | --- | --- |
1083
+ | `btu-linear-progress-ready` | | Fired after first render and initialization |
1084
+ | `btu-linear-progress-complete` | | Fired when progress reaches 100 |
1085
+
1086
+ ## CSS custom properties
1087
+
1088
+ | Property | Description |
1089
+ | --- | --- |
1090
+ | `--progress-color` | Custom progress bar color (overrides theme color) |
1091
+ | `--track-color` | Track/background color (overrides default gray-100) |
1092
+
1093
+ ---
1094
+
1095
+ # `<btu-message>`
1096
+ Source: https://ui.brightspot.com/docs/components/Message.md
1097
+
1098
+ A message for communicating high-visibility content that is not tied to the
1099
+ user's current task — alerts, breaking news, and persistent status. Use it on
1100
+ its own as a contained, bordered card, or place it inside a `<btu-banner>` to
1101
+ span the full width of the page (e.g., pinned above the CMS content area).
1102
+
1103
+ Messages render a leading icon, an optional badge, a label, an optional
1104
+ description, and an optional dismiss control. The label and description
1105
+ stack vertically in a text column; everything else sits on the same row.
1106
+
1107
+ ```js
1108
+ import '@brightspot/ui/components/banner/Message.js'
1109
+ ```
1110
+
1111
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-message--docs
1112
+
1113
+ ## Attributes
1114
+
1115
+ | Attribute | Property | Type | Default | Description |
1116
+ | --- | --- | --- | --- | --- |
1117
+ | `variant` | `variant` | `'primary' \| 'info' \| 'warning' \| 'error' \| 'success'` | `'info'` | Visual style and semantic meaning of the message. |
1118
+ | `label` | `label` | `string \| undefined` | | The primary message or title text displayed. |
1119
+ | `symbol` | `symbol` | `string \| undefined` | | Name of the Lucide icon to display. Defaults to a sensible icon per variant. |
1120
+ | `dismissible` | `dismissible` | `boolean` | `false` | If true, a close icon is provided to allow the user to hide the message. |
1121
+
1122
+ ## Events
1123
+
1124
+ | Event | Detail | Description |
1125
+ | --- | --- | --- |
1126
+ | `btu-message-ready` | | Fired after the message is first rendered and initialized |
1127
+ | `btu-message-dismiss` | | Fired when the user clicks the close/dismiss button. Cancelable: the message hides itself (sets `hidden`) unless the listener calls `preventDefault()`. |
1128
+
1129
+ ## Slots
1130
+
1131
+ | Slot | Description |
1132
+ | --- | --- |
1133
+ | `badge` | Pseudo-slot for a leading status/version tag, typically a `<btu-badge>`. The slotted child is moved into the header row, before the label. |
1134
+ | `description` | Pseudo-slot for supporting text rendered directly beneath the label. Slot a single inline element (e.g., `<span slot="description">`) or a block element to enable rich content (links, emphasis). |
1135
+ | `actions` | Pseudo-slot for CTA buttons, links, or a `<btu-pagination>`. Children with `slot="actions"` are moved into an internal container on the trailing edge of the body. `.btu-button` children inherit the message's foreground color across all states. The message does not emit an action-click event — attach handlers to your own elements. |
1136
+
1137
+ ## CSS custom properties
1138
+
1139
+ | Property | Description |
1140
+ | --- | --- |
1141
+ | `--message-color-background` | Overrides the background color for the message |
1142
+ | `--message-color-foreground` | Overrides the text and icon color |
1143
+ | `--message-color-border` | Overrides the border color (defaults to the variant's 300 shade) |
1144
+ | `--message-padding` | Overrides the internal padding (default: 1rem) |
1145
+ | `--message-border-radius` | Overrides the corner rounding (default: 8px) |
1146
+
1147
+ ---
1148
+
1149
+ # `<btu-pagination>`
1150
+ Source: https://ui.brightspot.com/docs/components/Pagination.md
1151
+
1152
+ A pagination component for navigating through paged content.
1153
+
1154
+ Supports multiple layout variants (Search, Widget, Widget Small, Calendar)
1155
+ through configurable props and pseudo-slots.
1156
+
1157
+ **Page size modes:**
1158
+
1159
+ - **Built-in** (default): When no `slot="page-size"` is provided and `page-size-changer`
1160
+ is true, Pagination renders its own `btu-dropdown` from the `page-size-options` attribute.
1161
+ Events, label sync, and page size changes are managed automatically.
1162
+
1163
+ - **Custom slot**: When a child has `slot="page-size"`, the built-in dropdown is suppressed.
1164
+ The consumer owns all behavior — event handling, label sync, etc. Use this for non-standard
1165
+ selectors like a calendar week/month toggle.
1166
+
1167
+ **Page jumper modes:**
1168
+
1169
+ - **Built-in**: When `page-jumper` is true and no `slot="jumper"` is provided, Pagination
1170
+ renders a dropdown with "Page 1" through "Page N" items. Fully reactive — updates
1171
+ automatically when page, page size, or total items change.
1172
+
1173
+ - **Custom slot**: When a child has `slot="jumper"`, the built-in dropdown is suppressed.
1174
+ The consumer owns all behavior. Use this for custom jumper content like a "Today" button.
1175
+
1176
+ ```js
1177
+ import '@brightspot/ui/components/pagination/Pagination.js'
1178
+ ```
1179
+
1180
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-pagination--docs
1181
+
1182
+ ## Attributes
1183
+
1184
+ | Attribute | Property | Type | Default | Description |
1185
+ | --- | --- | --- | --- | --- |
1186
+ | `page` | `page` | `number` | `1` | Current page number (1-based) |
1187
+ | `page-size` | `pageSize` | `number` | `0` | Number of items per page |
1188
+ | `disabled` | `disabled` | `boolean` | `false` | Disables all pagination controls |
1189
+ | `loading` | `loading` | `boolean` | `false` | Shows loading spinner and dims controls |
1190
+ | `hide-on-single-page` | `hideOnSinglePage` | `boolean` | `true` | Hide controls when there is only one page |
1191
+ | `page-size-changer` | `pageSizeChanger` | `boolean` | `true` | Show the page size dropdown |
1192
+ | `page-size-options` | `pageSizeOptions` | `string` | `'10, 20, 50'` | Comma-separated page size options |
1193
+ | `total-items` | `totalItems` | `number` | `0` | Total number of items across all pages |
1194
+ | `boundary-buttons` | `boundaryButtons` | `boolean` | `true` | Show first and last page buttons |
1195
+ | `hide-total-count` | `hideTotalCount` | `boolean` | `false` | Hide the item count display (e.g., "1-10 of 200") |
1196
+ | `page-jumper` | `pageJumper` | `boolean` | `false` | Show the page jumper dropdown. Intended for moderate page counts (under ~100 pages). For large datasets, use a custom `slot="jumper"` with a virtualized or input-based control. |
1197
+ | `label` | `label` | `string \| undefined` | | Accessible label for the pagination nav landmark |
1198
+
1199
+ ## Events
1200
+
1201
+ | Event | Detail | Description |
1202
+ | --- | --- | --- |
1203
+ | `btu-pagination-ready` | | Fired after first render |
1204
+ | `btu-pagination-change` | `{page: number, pageSize: number}` | Fired on page navigation |
1205
+ | `btu-pagination-page-size-change` | `{page: number, pageSize: number}` | Fired on page size change |
1206
+
1207
+ ## Slots
1208
+
1209
+ | Slot | Description |
1210
+ | --- | --- |
1211
+ | `page-size` | Custom page-size selector (replaces built-in dropdown). Consumer manages all behavior. |
1212
+ | `jumper` | Custom jumper content (replaces built-in page jumper dropdown). Consumer manages all behavior. |
1213
+
1214
+ ## CSS custom properties
1215
+
1216
+ | Property | Description |
1217
+ | --- | --- |
1218
+ | `--pagination-color-background` | Background color for dropdowns, buttons, and jumper |
1219
+ | `--pagination-color-foreground` | Text/icon color |
1220
+
1221
+ ---
1222
+
1223
+ # `<btu-popover>`
1224
+ Source: https://ui.brightspot.com/docs/components/Popover.md
1225
+
1226
+ A popover component for displaying rich interactive content anchored to a trigger element.
1227
+
1228
+ Uses the native HTML Popover API for top-layer rendering, light dismiss (click-outside
1229
+ and Escape for click triggers), and focus management. CSS anchor positioning handles
1230
+ viewport-aware placement.
1231
+
1232
+ For click triggers (`popover="auto"`), the browser provides:
1233
+ - Light dismiss (Escape key and click-outside)
1234
+ - Top-layer rendering (no z-index needed)
1235
+ - Focus restoration on close
1236
+ - `autofocus` support — add `autofocus` to an element inside `slot="content"`
1237
+ to have it receive focus when the popover opens
1238
+
1239
+ ```js
1240
+ import '@brightspot/ui/components/popover/Popover.js'
1241
+ ```
1242
+
1243
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-popover--docs
1244
+
1245
+ ## Attributes
1246
+
1247
+ | Attribute | Property | Type | Default | Description |
1248
+ | --- | --- | --- | --- | --- |
1249
+ | `position` | `position` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'bottom'` | Position relative to the trigger element. Auto-flips when constrained by the viewport. |
1250
+ | `trigger` | `trigger` | `'click' \| 'hover' \| 'focus'` | `'click'` | How the popover is activated. - 'click': Toggle on click with light dismiss - 'hover': Show on mouseenter with delay - 'focus': Show on focusin |
1251
+ | `delay` | `delay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
1252
+ | `offset` | `offset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between trigger and popover (sm=4px, md=8px, lg=12px, xl=16px). |
1253
+ | `no-arrow` | `noArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
1254
+ | `inverted` | `inverted` | `boolean` | `false` | Invert the panel surface (dark on light pages, light on dark pages). Opt-in, since the panel holds arbitrary rich content. |
1255
+ | `open` | `open` | `boolean` | `false` | Programmatic open/close state (reflected). |
1256
+ | `panel-label` | `panelLabel` | `string` | `''` | Accessible label for the popover panel (applied as aria-label on the dialog). |
1257
+
1258
+ ## Events
1259
+
1260
+ | Event | Detail | Description |
1261
+ | --- | --- | --- |
1262
+ | `btu-popover-show` | | Fired when the popover opens |
1263
+ | `btu-popover-hide` | | Fired when the popover closes |
1264
+
1265
+ ## Slots
1266
+
1267
+ | Slot | Description |
1268
+ | --- | --- |
1269
+ | `trigger` | The element that activates the popover |
1270
+ | `content` | Rich HTML content displayed inside the popover panel |
1271
+
1272
+ ## CSS custom properties
1273
+
1274
+ | Property | Description |
1275
+ | --- | --- |
1276
+ | `--popover-color-background` | Panel background color (default: var(--btu-theme-white); inverted: var(--btu-theme-black)) |
1277
+ | `--popover-color-content` | Panel text color (default: oklch(var(--btu-theme-gray-900)); inverted: var(--btu-theme-white)) |
1278
+ | `--popover-border-radius` | Panel corner radius (default: theme borderRadius.lg) |
1279
+ | `--popover-border-width` | Edge width, panel and arrow (default: 1px; 0 removes it) |
1280
+ | `--popover-border-color` | Edge color, panel and arrow (default: oklch(var(--btu-theme-gray-200))) |
1281
+ | `--popover-offset` | Gap between trigger and panel (default: 8px; see btu-popover-offset-{sm\|md\|lg\|xl}) |
1282
+ | `--popover-arrow-size` | Width/height of the pointer arrow (default: 8px) |
1283
+
1284
+ ---
1285
+
1286
+ # `<btu-radio>`
1287
+ Source: https://ui.brightspot.com/docs/components/Radio.md
1288
+
1289
+ A single radio option, selectable from a set of mutually exclusive choices.
1290
+
1291
+ Uses a hidden native radio input internally for accessibility and form
1292
+ participation. Styled via the `btu-radio` Tailwind plugin classes. Typically
1293
+ placed inside a `btu-radio-group`, which owns the shared `name`, selection
1294
+ state, and arrow-key navigation; a standalone radio also works but manages
1295
+ only its own checked state. The component manages its own `className` — do not
1296
+ modify it externally after initialization (classes present at connection time
1297
+ are preserved).
1298
+
1299
+ ```js
1300
+ import '@brightspot/ui/components/radio/Radio.js'
1301
+ ```
1302
+
1303
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-radio--docs
1304
+
1305
+ ## Attributes
1306
+
1307
+ | Attribute | Property | Type | Default | Description |
1308
+ | --- | --- | --- | --- | --- |
1309
+ | `label` | `label` | `string \| undefined` | | The text label displayed next to the radio. |
1310
+ | `description` | `description` | `string \| undefined` | | Optional helper text displayed below the label. |
1311
+ | `size` | `size` | `'sm' \| 'md'` | `'sm'` | Controls the scale of the radio and associated typography. |
1312
+ | `checked` | `checked` | `boolean` | `false` | Whether this option is currently selected. |
1313
+ | `disabled` | `disabled` | `boolean` | `false` | If true, the radio is non-interactive and visually muted. |
1314
+ | `invalid` | `invalid` | `boolean` | `false` | If true, displays error styling on the radio. |
1315
+ | `error` | `error` | `string \| undefined` | | Error message text displayed below the radio when validation fails. Setting this also activates error styling without needing to set invalid. |
1316
+ | `value` | `value` | `string \| undefined` | | Value submitted with the form when this option is selected. |
1317
+ | `name` | `name` | `string \| undefined` | | Name of the form control. Usually set by the parent `btu-radio-group` so every option in the group shares one name. |
1318
+ | `tooltip` | `tooltip` | `string` | `''` | Tooltip text content. Set to empty string to remove the tooltip. |
1319
+ | `tooltip-position` | `tooltipPosition` | `'top' \| 'bottom' \| 'left' \| 'right'` | `'top'` | Position relative to the host element. Auto-flips when constrained by the viewport. |
1320
+ | `tooltip-delay` | `tooltipDelay` | `number` | `300` | Show delay in milliseconds (hover trigger only). |
1321
+ | `tooltip-offset` | `tooltipOffset` | `'sm' \| 'md' \| 'lg' \| 'xl' \| null` | `null` | Gap between host and tooltip (sm=4px, md=8px, lg=12px, xl=16px). |
1322
+ | `tooltip-no-arrow` | `tooltipNoArrow` | `boolean` | `false` | Hide the arrow pseudo-element. |
1323
+ | `tooltip-trigger` | `tooltipTrigger` | `string` | `'hover focus'` | Space-separated trigger types: 'hover', 'focus', 'click'. |
1324
+
1325
+ ## Events
1326
+
1327
+ | Event | Detail | Description |
1328
+ | --- | --- | --- |
1329
+ | `btu-radio-ready` | | Fired after the radio is first rendered and initialized |
1330
+ | `btu-radio-change` | `{ checked: boolean; value: string }` | Fired when the user selects this option |
1331
+
1332
+ ## CSS custom properties
1333
+
1334
+ | Property | Description |
1335
+ | --- | --- |
1336
+ | `--radio-color-primary` | Fill and border color when selected (default: oklch(var(--btu-theme-primary-700))) |
1337
+ | `--radio-color-border` | Border color in the unselected state (default: oklch(var(--btu-theme-gray-300))) |
1338
+ | `--radio-color-error` | Border and text color in the error state (default: oklch(var(--btu-theme-error-600))) |
1339
+ | `--radio-label-spacing` | Distance between the radio and the label (default: 0.75rem) |
1340
+ | `--radio-box-size` | [Internal] Diameter of the radio control, set by the size variant (sm: 1rem, md: 1.25rem). Use the `size` attribute instead of overriding directly — the dot must scale in tandem. |
1341
+ | `--radio-dot-size` | [Internal] Diameter of the selected dot, set by the size variant (sm: 0.375rem, md: 0.5rem). Use the `size` attribute instead of overriding directly. |
1342
+
1343
+ ---
1344
+
1345
+ # `<btu-radio-group>`
1346
+ Source: https://ui.brightspot.com/docs/components/RadioGroup.md
1347
+
1348
+ A container that groups `btu-radio` options into a single-select control.
1349
+
1350
+ Owns the shared form `name`, the selected `value`, and keyboard navigation
1351
+ following the WAI-ARIA radio group pattern: a single roving tabstop, and
1352
+ arrow keys that move focus and select in one step. Selection state and the
1353
+ `disabled` / `size` properties are propagated down to child radios.
1354
+
1355
+ ```js
1356
+ import '@brightspot/ui/components/radio/RadioGroup.js'
1357
+ ```
1358
+
1359
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-radio-group--docs
1360
+
1361
+ ## Attributes
1362
+
1363
+ | Attribute | Property | Type | Default | Description |
1364
+ | --- | --- | --- | --- | --- |
1365
+ | `name` | `name` | `string \| undefined` | | Form field name shared by every radio in the group. |
1366
+ | `value` | `value` | `string \| undefined` | | Value of the currently selected option. |
1367
+ | `orientation` | `orientation` | `'vertical' \| 'horizontal'` | `'vertical'` | Layout direction of the options. |
1368
+ | `size` | `size` | `'sm' \| 'md'` | `'sm'` | Controls the scale of every radio in the group. |
1369
+ | `required` | `required` | `boolean` | `false` | Marks a selection as mandatory for form submission. |
1370
+ | `disabled` | `disabled` | `boolean` | `false` | Disables every option in the group. |
1371
+
1372
+ ## Events
1373
+
1374
+ | Event | Detail | Description |
1375
+ | --- | --- | --- |
1376
+ | `btu-radio-group-ready` | | Fired after first render and initialization |
1377
+ | `btu-radio-group-change` | `{ value: string }` | Fired when the selected value changes |
1378
+ | `btu-radio-ready` | | Fired when a child radio finishes initialization (bubbles from btu-radio) |
1379
+ | `btu-radio-change` | `{ checked: boolean; value: string }` | Fired when a child radio is selected (bubbles from btu-radio) |
1380
+
1381
+ ---
1382
+
1383
+ # `<btu-switch>`
1384
+ Source: https://ui.brightspot.com/docs/components/Switch.md
1385
+
1386
+ A toggle switch component for binary on/off states.
1387
+
1388
+ Uses a hidden checkbox internally for accessibility, styled via the
1389
+ `btu-switch` Tailwind plugin classes.
1390
+
1391
+ ```js
1392
+ import '@brightspot/ui/components/switch/Switch.js'
1393
+ ```
1394
+
1395
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-switch--docs
1396
+
1397
+ ## Attributes
1398
+
1399
+ | Attribute | Property | Type | Default | Description |
1400
+ | --- | --- | --- | --- | --- |
1401
+ | `size` | `size` | `'sm' \| 'md' \| 'lg'` | `'sm'` | Controls the physical dimensions of the switch and the associated label typography. |
1402
+ | `label` | `label` | `string \| undefined` | | The primary text displayed next to the toggle. |
1403
+ | `description` | `description` | `string \| undefined` | | Optional helper text or secondary information displayed below the label. |
1404
+ | `checked` | `checked` | `boolean` | `false` | The current state of the switch (on/off). |
1405
+ | `disabled` | `disabled` | `boolean` | `false` | If true, the toggle is non-interactive and visually muted. |
1406
+ | `name` | `name` | `string \| undefined` | | Name of the control for form participation. |
1407
+ | `label-position` | `labelPosition` | `'start' \| 'end'` | `'end'` | Determines if the label appears to the left or right of the switch. |
1408
+ | `on-icon` | `onIcon` | `string \| undefined` | | Lucide icon name shown on the track when the switch is checked (on). |
1409
+ | `off-icon` | `offIcon` | `string \| undefined` | | Lucide icon name shown on the track when the switch is unchecked (off). |
1410
+
1411
+ ## Events
1412
+
1413
+ | Event | Detail | Description |
1414
+ | --- | --- | --- |
1415
+ | `btu-switch-ready` | | Fired after the toggle is first rendered and initialized |
1416
+ | `btu-switch-change` | `{ checked: boolean }` | Fired when the user toggles the switch |
1417
+ | `btu-switch-focus` | | Fired when the component gains focus |
1418
+
1419
+ ## CSS custom properties
1420
+
1421
+ | Property | Description |
1422
+ | --- | --- |
1423
+ | `--switch-color-track-on` | Background color when the toggle is checked (default: var(--btu-theme-primary-700)) |
1424
+ | `--switch-color-track-off` | Background color when the toggle is unchecked (default: var(--btu-theme-gray-300)) |
1425
+ | `--switch-color-knob` | Color of the sliding circular handle (default: var(--btu-theme-white)) |
1426
+ | `--switch-label-spacing` | Distance between the switch and the text label (default: 0.75rem) |
1427
+ | `--switch-track-width` | Track width (default: sm 1.75rem, md 2.25rem, lg 2.75rem) |
1428
+ | `--switch-track-height` | Track height (default: sm 1rem, md 1.25rem, lg 1.5rem) |
1429
+ | `--switch-knob-size` | Knob diameter (default: sm 0.75rem, md 1rem, lg 1.25rem) |
1430
+ | `--switch-knob-padding` | Space between knob and track edges (default: 0.125rem) |
1431
+ | `--switch-track-icon-size` | Size of the track icons (default: sm 0.5rem, md 0.625rem, lg 0.75rem) |
1432
+
1433
+ ---
1434
+
1435
+ # `<btu-tab>`
1436
+ Source: https://ui.brightspot.com/docs/components/Tab.md
1437
+
1438
+ An individual tab within a tab group.
1439
+
1440
+ Renders a button with role="tab" that participates in keyboard navigation
1441
+ and selection state managed by the parent `btu-tabs` container.
1442
+
1443
+ ```js
1444
+ import '@brightspot/ui/components/tabs/Tab.js'
1445
+ ```
1446
+
1447
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-tabs-tab--docs
1448
+
1449
+ ## Attributes
1450
+
1451
+ | Attribute | Property | Type | Default | Description |
1452
+ | --- | --- | --- | --- | --- |
1453
+ | `name` | `name` | `string \| undefined` | | Value that identifies this tab and links it to panel elements that share the same `name` attribute. |
1454
+ | `label` | `label` | `string \| undefined` | | Text displayed in the tab. |
1455
+ | `description` | `description` | `string \| undefined` | | Accessibility description for screen readers. |
1456
+ | `disabled` | `disabled` | `boolean` | `false` | Whether the tab is disabled and non-interactive. |
1457
+ | `symbol` | `symbol` | `string \| undefined` | | Lucide icon symbol to display. |
1458
+ | `icon-position` | `iconPosition` | `'leading' \| 'trailing'` | `'leading'` | Placement of the icon relative to the label. |
1459
+ | `icon-only` | `iconOnly` | `boolean` | `false` | When true, hides the label visually while maintaining accessibility. |
1460
+ | `error` | `error` | `boolean` | `false` | When true, displays an error badge on the tab. |
1461
+ | `badge` | `badge` | `string \| undefined` | | Displays a badge with the given value alongside the label. |
1462
+
1463
+ ## Events
1464
+
1465
+ | Event | Detail | Description |
1466
+ | --- | --- | --- |
1467
+ | `btu-tab-ready` | | Fired after first render |
1468
+ | `btu-tab-change` | `{name: string}` | Fired when a non-disabled tab with a name is clicked |
1469
+
1470
+ ## CSS custom properties
1471
+
1472
+ | Property | Description |
1473
+ | --- | --- |
1474
+ | `--badge-color-background` | Background color of the count indicator badge (default: gray-50) |
1475
+ | `--badge-color-foreground` | Text color of the count indicator badge (default: gray-800) |
1476
+
1477
+ ---
1478
+
1479
+ # `<btu-tabs>`
1480
+ Source: https://ui.brightspot.com/docs/components/Tabs.md
1481
+
1482
+ A container component for managing a group of tabs.
1483
+
1484
+ Provides selection state management, size propagation to child tabs,
1485
+ and keyboard navigation following the WAI-ARIA Tabs pattern.
1486
+
1487
+ When a tab becomes active, direct sibling elements that share the same
1488
+ `name` value are shown; other siblings with a `name` attribute are
1489
+ hidden. Only direct siblings are managed — nested tab groups control their
1490
+ own panels independently.
1491
+
1492
+ ```js
1493
+ import '@brightspot/ui/components/tabs/Tabs.js'
1494
+ ```
1495
+
1496
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-tabs--docs
1497
+
1498
+ ## Attributes
1499
+
1500
+ | Attribute | Property | Type | Default | Description |
1501
+ | --- | --- | --- | --- | --- |
1502
+ | `size` | `size` | `'xs' \| 'sm' \| 'md' \| 'lg'` | `'md'` | Size variant applied to all child tabs. |
1503
+ | `active-tab` | `activeTab` | `string \| undefined` | | The `name` value of the currently active tab. |
1504
+ | `variant` | `variant` | `'full' \| 'menu'` | `'full'` | Layout variant. - 'full': tabs scroll horizontally when they overflow (default) - 'menu': all tabs are hidden; the active tab label and a chevron dropdown are shown instead |
1505
+
1506
+ ## Events
1507
+
1508
+ | Event | Detail | Description |
1509
+ | --- | --- | --- |
1510
+ | `btu-tabs-ready` | | Fired after first render and initialization |
1511
+ | `btu-tabs-show` | `{name: string}` | Fired when a tab becomes active |
1512
+ | `btu-tabs-hide` | `{name: string}` | Fired when a tab is deactivated |
1513
+ | `btu-tab-change` | `{name: string}` | Fired when a tab is selected (bubbles from btu-tab) |
1514
+ | `btu-tab-ready` | | Fired when a child tab finishes initialization (bubbles from btu-tab) |
1515
+
1516
+ ## CSS custom properties
1517
+
1518
+ | Property | Description |
1519
+ | --- | --- |
1520
+ | `--tabs-active-color` | Text and icon color of the active tab (default: gray-700) |
1521
+ | `--tabs-active-indicator-color` | Color of the active tab underline indicator (default: primary-500 → primary-700 → primary-900 gradient) |
1522
+ | `--tabs-border-color` | Color of the bottom border divider (default: gray-200) |
1523
+ | `--tabs-color` | Text and icon color for all tabs (default: gray-500; active/hover tabs use gray-700) |
1524
+ | `--tabs-background` | Background color for all tab buttons (default: transparent) |
1525
+ | `--tabs-container-background` | Background color of the tabs container (default: theme white) |
1526
+ | `--tabs-hover-background` | Background color of a tab on hover (default: gray-100) |
1527
+ | `--tabs-hover-color` | Text and icon color of a tab on hover (default: gray-700) |
1528
+ | `--tabs-gap` | Spacing between tabs (default: 1rem) |
1529
+
1530
+ ---
1531
+
1532
+ # `<btu-upload>`
1533
+ Source: https://ui.brightspot.com/docs/components/Upload.md
1534
+
1535
+ A file upload component with drop zone and file list.
1536
+
1537
+ The component is presentation + file-selection only. It handles file browsing,
1538
+ drag-and-drop reception, client-side validation, and rendering the file list
1539
+ with progress bars. It does not perform network requests — the consumer listens
1540
+ for events, performs their own upload, and drives state back via imperative methods.
1541
+
1542
+ ```js
1543
+ import '@brightspot/ui/components/upload/Upload.js'
1544
+ ```
1545
+
1546
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-upload--docs
1547
+
1548
+ ## Attributes
1549
+
1550
+ | Attribute | Property | Type | Default | Description |
1551
+ | --- | --- | --- | --- | --- |
1552
+ | `accept` | `accept` | `string` | `''` | Accepted file types, matching the HTML `<input accept>` attribute format. Client-side filter only — the browser's file picker uses this as a hint, and drag-drop is enforced by this component. Server-side validation is still required. Supported forms (comma-separated, any combination): - `image/*` — MIME wildcard (any image) - `application/pdf` — exact MIME type - `.pdf`, `.docx` — file extension (case-insensitive) Examples: - `accept="image/*"` — any image - `accept="image/*,application/pdf"` — images and PDFs - `accept=".jpg,.jpeg,.png,.heic"` — specific extensions - `accept=""` (or omitted) — allow all Note: users can bypass the file picker's filter (most browsers offer an "All Files" option), so this attribute is a UX filter, not a security boundary. |
1553
+ | `max-file-size` | `maxFileSize` | `number` | `0` | Maximum file size in bytes. Files exceeding this are rejected. 0 means unlimited. |
1554
+ | `max-files` | `maxFiles` | `number` | `Infinity` | Maximum number of files allowed. When omitted, uploads are unlimited. `max-files="1"` enters single-file mode (selecting a new file replaces the existing one). `max-files="0"` allows zero files. Values above 1 cap the queue at that many files. |
1555
+ | `disabled` | `disabled` | `boolean` | `false` | Disables all interaction — file selection, drag-and-drop, and action buttons. |
1556
+ | `no-drag` | `noDrag` | `boolean` | `false` | Disables drag-and-drop. File selection via click still works. |
1557
+
1558
+ ## Methods
1559
+
1560
+ | Method | Description |
1561
+ | --- | --- |
1562
+ | `setFileProgress(id: string, percent: number): void` | Update the progress of a file upload. Clamps value to 0-100 and coerces non-finite inputs to 0. Announces milestones (25%, 50%, 75%) to screen readers; 100% completion is announced by setFileStatus('complete'). Status transitions: - `pending` → `uploading` (auto — first progress report starts the upload) - `uploading` → `uploading` (progress updates) - `error` → `error` (progress updates only; status is preserved so a stale late callback can't wipe the error UI. To recover from error, call `setFileStatus(id, 'uploading')` first, then report progress.) - `complete` → ignored (terminal state) |
1563
+ | `setFileStatus(id: string, status: FileStatusSettable, message?: string): void` | Set the status of a file. Valid statuses: 'uploading', 'complete', 'error'. For 'error' status, an optional message can be provided. Transitions from 'complete' are rejected (terminal state) — a late-resolving XHR cannot overwrite a prior success. Rejected calls emit `btu-upload-api-error` with reason: 'invalid-transition'. |
1564
+ | `setFileSymbol(id: string, symbol: string): void` | Override the icon symbol for a file. |
1565
+ | `removeFile(id: string): void` | Remove a file programmatically. Fires `btu-upload-file-removed`. |
1566
+ | `getFiles(): readonly FileState[]` | Get a snapshot of all current files and their states. States are readonly; mutations on the returned array's elements are ineffective. |
1567
+
1568
+ ## Events
1569
+
1570
+ | Event | Detail | Description |
1571
+ | --- | --- | --- |
1572
+ | `btu-upload-ready` | `unknown` | Fired when the component has completed first render |
1573
+ | `btu-upload-file-added` | `{id: string, file: File}` | Fired when a file passes validation and is added |
1574
+ | `btu-upload-file-removed` | `{id: string, file: File}` | Fired when a file is removed (user action, programmatic, or on disconnect for in-flight uploads) |
1575
+ | `btu-upload-file-retry` | `{id: string, file: File}` | Fired when user clicks "Try again" on a failed upload |
1576
+ | `btu-upload-file-rejected` | `{file: File, reason: 'type' \| 'size' \| 'count'}` | Fired when a file fails client-side validation or the queue is full |
1577
+ | `btu-upload-file-completed` | `{id: string, file: File}` | Fired when a file's status transitions into 'complete' |
1578
+ | `btu-upload-api-error` | `{method: string, id: string, reason: 'unknown-id' \| 'invalid-transition', message: string}` | Fired when an imperative API call references an unknown id or an illegal status transition |
1579
+
1580
+ ## CSS custom properties
1581
+
1582
+ | Property | Description |
1583
+ | --- | --- |
1584
+ | `--upload-dropzone-bg` | Drop zone background color (default: gray-25) |
1585
+ | `--upload-dropzone-border-color` | Drop zone border color (default: gray-300; gray-200 when disabled, gray-400 in high-contrast) |
1586
+ | `--upload-dropzone-border-radius` | Drop zone border radius (default: borderRadius.lg) |
1587
+ | `--upload-dropzone-hover-bg` | Drop zone hover background (hover default: gray-50; drag-over default: primary-25) |
1588
+ | `--upload-dropzone-hover-border-color` | Drop zone hover/focus border color (default: primary-300; drag-over uses primary-400) |
1589
+ | `--upload-dropzone-focus-ring-color` | Drop zone focus ring color (default: primary-100) |
1590
+ | `--upload-item-bg` | Item background color (default: white) |
1591
+ | `--upload-item-border-color` | Item border color (default: gray-200) |
1592
+ | `--upload-item-active-border-color` | Item active/in-progress border (default: gray-300) |
1593
+ | `--upload-item-complete-border-color` | Item completed border color (default: primary-500) |
1594
+ | `--upload-item-error-bg` | Item error background (default: error-25) |
1595
+ | `--upload-item-error-border-color` | Item error border color (default: error-300) |
1596
+
1597
+ ---
1598
+
1599
+ # `<btu-upload-item>`
1600
+ Source: https://ui.brightspot.com/docs/components/UploadItem.md
1601
+
1602
+ Internal upload item sub-component for displaying individual file upload state.
1603
+
1604
+ This component is not part of the public API — consumers should not create,
1605
+ query, or modify items directly. All interaction goes through `btu-upload` methods.
1606
+
1607
+ ```js
1608
+ import '@brightspot/ui/components/upload/UploadItem.js'
1609
+ ```
1610
+
1611
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-upload-upload-item--docs
1612
+
1613
+ ## Events
1614
+
1615
+ | Event | Detail | Description |
1616
+ | --- | --- | --- |
1617
+ | `btu-upload-item-remove` | `{id: string}` | Fired when remove button is clicked |
1618
+ | `btu-upload-item-retry` | `{id: string}` | Fired when retry link is clicked |
1619
+
1620
+ ## CSS custom properties
1621
+
1622
+ | Property | Description |
1623
+ | --- | --- |
1624
+ | `--upload-item-bg` | Item background color (default: white) |
1625
+ | `--upload-item-border-color` | Item border color (default: gray-200) |
1626
+ | `--upload-item-active-border-color` | Item active/in-progress border (default: gray-300) |
1627
+ | `--upload-item-complete-border-color` | Item completed border color (default: primary-500) |
1628
+ | `--upload-item-error-bg` | Item error background (default: error-25) |
1629
+ | `--upload-item-error-border-color` | Item error border color (default: error-300) |
1630
+
1631
+ ---
1632
+
1633
+ # `<btu-widget>`
1634
+ Source: https://ui.brightspot.com/docs/components/Widget.md
1635
+
1636
+ A widget component for displaying content with header, body, and footer sections.
1637
+
1638
+ ## Architecture: Light DOM + Manager Pattern
1639
+
1640
+ This component uses **Light DOM** (no Shadow Root) with the **Manager Pattern**:
1641
+ - User-provided children are physically moved into internal containers
1642
+ - Movement is based on `slot` attributes (pseudo-slots)
1643
+ - The `onFind` utility automatically redistributes dynamically-added content
1644
+
1645
+ ### Node Redistribution Rules
1646
+ - `slot="controls"` → Moved to header actions area (before system buttons)
1647
+ - `slot="footer"` → Moved to footer container
1648
+ - *(no slot)* → Moved to body container (default)
1649
+
1650
+ ## Features
1651
+
1652
+ - **Collapsible**: Optional chevron toggle to hide/show body and footer
1653
+ - **Fullscreen**: Optional maximize button for fullscreen mode via `:state(fullscreen)` custom state
1654
+ - **Dynamic Content**: `onFind` handles content added after initialization
1655
+ - **Accessible**: Full ARIA support and keyboard navigation
1656
+ - **Themeable**: CSS custom properties for colors and spacing
1657
+
1658
+ ## Accessibility
1659
+
1660
+ - **Collapse toggle**: `aria-expanded`, `aria-controls`, `aria-label`
1661
+ - **Fullscreen toggle**: `aria-pressed`, `aria-label`
1662
+ - **Body region**: `role="region"`, `aria-labelledby` linking to heading
1663
+ - **Tab order**: Natural flow via physical DOM placement
1664
+ - **Collapsed content**: Hidden via `inert` attribute and CSS grid collapse
1665
+
1666
+ ```js
1667
+ import '@brightspot/ui/components/widget/Widget.js'
1668
+ ```
1669
+
1670
+ The CMS page defines this element itself, so a plugin can use it there without the import.
1671
+
1672
+ Interactive examples: https://ui.brightspot.com/?path=/docs/components-widget--docs
1673
+
1674
+ ## Attributes
1675
+
1676
+ | Attribute | Property | Type | Default | Description |
1677
+ | --- | --- | --- | --- | --- |
1678
+ | `heading` | `heading` | `string` | `''` | Heading text displayed in the header. |
1679
+ | `collapsible` | `collapsible` | `boolean` | `false` | Whether the widget can be collapsed/expanded. When true, a chevron toggle button appears in the header. |
1680
+ | `collapsed` | `collapsed` | `boolean` | `false` | Whether the widget is currently collapsed. When true, body and footer are hidden. Implies collapsible. |
1681
+ | `fullscreenable` | `fullscreenable` | `boolean` | `false` | Whether the widget can enter fullscreen mode. When true, a fullscreen toggle button appears in the header. |
1682
+
1683
+ ## Properties
1684
+
1685
+ These have no attribute; set them from JavaScript.
1686
+
1687
+ | Property | Type | Default | Description |
1688
+ | --- | --- | --- | --- |
1689
+ | `isFullscreen` (read-only) | `boolean` | | Whether the widget is currently in fullscreen mode (read-only). Use `btu-widget-fullscreen-changed` event to react to changes. |
1690
+
1691
+ ## Events
1692
+
1693
+ | Event | Detail | Description |
1694
+ | --- | --- | --- |
1695
+ | `btu-widget-ready` | | Fired after first render and redistribution |
1696
+ | `btu-widget-collapse-changed` | `{collapsed: boolean}` | Fired when collapsed state changes |
1697
+ | `btu-widget-fullscreen-changed` | `{fullscreen: boolean}` | Fired when fullscreen state changes |
1698
+
1699
+ ## Slots
1700
+
1701
+ | Slot | Description |
1702
+ | --- | --- |
1703
+ | (default) | Default pseudo-slot: elements without slot attribute are moved to body |
1704
+ | `controls` | Pseudo-slot: buttons/actions moved to header actions area |
1705
+ | `footer` | Pseudo-slot: content moved to footer container |
1706
+
1707
+ ## CSS custom properties
1708
+
1709
+ | Property | Description |
1710
+ | --- | --- |
1711
+ | `--widget-background` | Body and footer background color (default: --btu-theme-white) |
1712
+ | `--widget-border` | Widget border and dividers (default: 1px solid gray-200) |
1713
+ | `--widget-border-color` | Color of header bottom divider (default: gray-200) |
1714
+ | `--header-background` | Header background color (default: transparent) |
1715
+
1716
+ ## CSS states
1717
+
1718
+ | State | Description |
1719
+ | --- | --- |
1720
+ | `:state(collapsed)` | Applied when the widget is collapsed, targetable via :state(collapsed) |
1721
+ | `:state(fullscreen)` | Applied when the widget is in fullscreen mode, targetable via :state(fullscreen) |