@brightspot/ui 5.3.2 → 5.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. package/README.md +113 -150
  2. package/dist/components/banner/Banner.css +32 -0
  3. package/dist/components/banner/Banner.d.ts +56 -0
  4. package/dist/components/banner/Banner.d.ts.map +1 -0
  5. package/dist/components/banner/Banner.js +94 -0
  6. package/dist/components/banner/Banner.js.map +1 -0
  7. package/dist/components/banner/Message.css +4 -0
  8. package/dist/components/banner/Message.d.ts +103 -0
  9. package/dist/components/banner/Message.d.ts.map +1 -0
  10. package/dist/components/banner/Message.js +235 -0
  11. package/dist/components/banner/Message.js.map +1 -0
  12. package/dist/custom-elements.json +319 -0
  13. package/dist/storybook/assets/{ActionBar.stories-1Iqfy4PV.js → ActionBar.stories-BJcrfF0X.js} +1 -1
  14. package/dist/storybook/assets/{ActionItem.stories-DjKyE7m_.js → ActionItem.stories-xLR-VN2Q.js} +1 -1
  15. package/dist/storybook/assets/{Avatar.stories-Dy36fKQN.js → Avatar.stories-Cj5Q2yEp.js} +1 -1
  16. package/dist/storybook/assets/{AvatarGroup.stories-Bh8TY9-P.js → AvatarGroup.stories-DLWAQHFa.js} +1 -1
  17. package/dist/storybook/assets/{Badge.stories-Bn0aBHka.js → Badge.stories-DGSKAf9D.js} +1 -1
  18. package/dist/storybook/assets/Banner.stories-BZ3LLa4I.js +203 -0
  19. package/dist/storybook/assets/{Button-D8Sr8A-v.js → Button-ffu9dnxC.js} +1 -1
  20. package/dist/storybook/assets/{Button.stories-CtRBI4gv.js → Button.stories-DB-uDcVu.js} +1 -1
  21. package/dist/storybook/assets/{ButtonGroup.stories-CVjQWgMD.js → ButtonGroup.stories-eGya8Uts.js} +1 -1
  22. package/dist/storybook/assets/{Card.stories-DXTqqbXb.js → Card.stories-B_hhKmQB.js} +1 -1
  23. package/dist/storybook/assets/{Celebrate.stories-DwQeQ1VN.js → Celebrate.stories-DqKwiwly.js} +1 -1
  24. package/dist/storybook/assets/{Checkbox.stories-D4AyVy-V.js → Checkbox.stories-Bly8OVzf.js} +1 -1
  25. package/dist/storybook/assets/{CircularProgress.stories-D6dHpD70.js → CircularProgress.stories-BZUNNkMK.js} +1 -1
  26. package/dist/storybook/assets/{ClipboardMixin.stories-CvYj7bwY.js → ClipboardMixin.stories-D2XMhwIg.js} +1 -1
  27. package/dist/storybook/assets/{Color-6BZIO3FS-o6fp9dCO.js → Color-6BZIO3FS-BPcC43iH.js} +1 -1
  28. package/dist/storybook/assets/{Colors.stories-Bg-Xuo05.js → Colors.stories-DveV04we.js} +1 -1
  29. package/dist/storybook/assets/{CombinedEffects.stories-C4SNTP9M.js → CombinedEffects.stories-Dl_MhHhl.js} +1 -1
  30. package/dist/storybook/assets/{ComponentStatesMixin-Dj1V-e8c.js → ComponentStatesMixin-CmZnizKN.js} +1 -1
  31. package/dist/storybook/assets/{ComponentStatesMixin.stories-CUoagWLT.js → ComponentStatesMixin.stories-BrAFoGDu.js} +1 -1
  32. package/dist/storybook/assets/{CopyToClipboard.stories-ynkFni9d.js → CopyToClipboard.stories-CiKbtpBJ.js} +1 -1
  33. package/dist/storybook/assets/{Debounce.stories-xAZ6AOUR.js → Debounce.stories-BQ7W_yTX.js} +1 -1
  34. package/dist/storybook/assets/{DocsRenderer-LL677BLK-DeoiTMLA.js → DocsRenderer-LL677BLK-DiDzi0rZ.js} +3 -3
  35. package/dist/storybook/assets/{Dropdown.stories-BQzwsyHE.js → Dropdown.stories-LYd0-ypG.js} +1 -1
  36. package/dist/storybook/assets/{EmptyState.stories-CrckJlBX.js → EmptyState.stories-DjKyE0h3.js} +1 -1
  37. package/dist/storybook/assets/{EscaAvatar.stories-BikckAep.js → EscaAvatar.stories-D3v91UKv.js} +1 -1
  38. package/dist/storybook/assets/{Events.stories-DC0XMBhF.js → Events.stories-CTe5eZa6.js} +1 -1
  39. package/dist/storybook/assets/{Heading.stories-7YtY0gNK.js → Heading.stories-DKt-wgRB.js} +1 -1
  40. package/dist/storybook/assets/{HueRipple.stories-hRstwRnF.js → HueRipple.stories-B3SVSdL8.js} +1 -1
  41. package/dist/storybook/assets/{Icon.stories-4-2N4UlX.js → Icon.stories-B5tDsd--.js} +1 -1
  42. package/dist/storybook/assets/{IconButton.stories-ClpNoAT9.js → IconButton.stories-DOV4zFAP.js} +1 -1
  43. package/dist/storybook/assets/{LinearProgress.stories-BlH24bsJ.js → LinearProgress.stories-ai3UD-xw.js} +1 -1
  44. package/dist/storybook/assets/Message.stories-CzqIe49h.js +432 -0
  45. package/dist/storybook/assets/{OnFindMixin.stories-CKoPIaks.js → OnFindMixin.stories-CUaE6pX1.js} +1 -1
  46. package/dist/storybook/assets/{Pagination.stories-CER9zwKW.js → Pagination.stories-CXCbChNW.js} +1 -1
  47. package/dist/storybook/assets/{Popover.stories-CO7t4Pl8.js → Popover.stories-DyptvVL3.js} +1 -1
  48. package/dist/storybook/assets/{ReadyMixin-C_H-s0cp.js → ReadyMixin-BUpBkgED.js} +1 -1
  49. package/dist/storybook/assets/{RovingTabindexMixin.stories-0Sny7BQc.js → RovingTabindexMixin.stories-DzEH38Tn.js} +1 -1
  50. package/dist/storybook/assets/{Rtc.stories-Ci7CnFM6.js → Rtc.stories-DxQWkudF.js} +1 -1
  51. package/dist/storybook/assets/{ScrollShadow.stories-CSbM9xdE.js → ScrollShadow.stories-DbMdNLKA.js} +1 -1
  52. package/dist/storybook/assets/{Switch.stories-D-SGY0dL.js → Switch.stories-CvSwuR0Z.js} +1 -1
  53. package/dist/storybook/assets/{Tab.stories-DXeloL5R.js → Tab.stories-CI6m8NXD.js} +1 -1
  54. package/dist/storybook/assets/{Tabs.stories-KGjrQHnj.js → Tabs.stories-BMat3ubI.js} +1 -1
  55. package/dist/storybook/assets/{Throttle.stories-SjszmCVX.js → Throttle.stories-PEUZoXfI.js} +1 -1
  56. package/dist/storybook/assets/{Tooltip.stories-DZty4zmq.js → Tooltip.stories-kDJ5PbGO.js} +1 -1
  57. package/dist/storybook/assets/{Upload.stories-CoM7bgt1.js → Upload.stories-Bb5KBlh7.js} +1 -1
  58. package/dist/storybook/assets/{UploadItem.stories-CRrp-ZTV.js → UploadItem.stories-VZVWc52f.js} +1 -1
  59. package/dist/storybook/assets/{Welcome.stories-lQ_IWtd1.js → Welcome.stories-BgzaFbT1.js} +1 -1
  60. package/dist/storybook/assets/{Widget.stories-rY-A2yAZ.js → Widget.stories-Bbczy09Q.js} +1 -1
  61. package/dist/storybook/assets/{WithTooltip-65CFNBJE-asVkTqyz.js → WithTooltip-65CFNBJE-BoKgPPcr.js} +1 -1
  62. package/dist/storybook/assets/{blocks-D-cAwpi5.js → blocks-j0yzxuDk.js} +5 -5
  63. package/dist/storybook/assets/{formatter-EIJCOSYU-CaSK-GPg.js → formatter-EIJCOSYU-B5-4vV2C.js} +1 -1
  64. package/dist/storybook/assets/if-defined-DBQP12ek.js +1 -0
  65. package/dist/storybook/assets/iframe-Ce3XRnL4.css +1 -0
  66. package/dist/storybook/assets/{iframe-DpPeZoRd.js → iframe-DUmd7GbF.js} +86 -86
  67. package/dist/storybook/assets/{index-Eb_LP-gw.js → index-ACSvfrQi.js} +1 -1
  68. package/dist/storybook/assets/{onFind-D8gPkhwL.js → onFind-t_5Bmfio.js} +1 -1
  69. package/dist/storybook/assets/{onFind.stories-C_2tTxBq.js → onFind.stories-CQWcRPFY.js} +1 -1
  70. package/dist/storybook/assets/{onRemove.stories-D-gjr3kA.js → onRemove.stories-B9_DDB2B.js} +1 -1
  71. package/dist/storybook/assets/{onVisible.stories-DGfzNLoX.js → onVisible.stories-G0qjGum_.js} +1 -1
  72. package/dist/storybook/assets/{style-map-WEdc6AkA.js → style-map-D_jXmlQ4.js} +1 -1
  73. package/dist/storybook/assets/{syntaxhighlighter-ED5Y7EFY-CCM2wmJ3.js → syntaxhighlighter-ED5Y7EFY-7_fYNYDB.js} +1 -1
  74. package/dist/storybook/iframe.html +2 -2
  75. package/dist/storybook/index.json +1 -1
  76. package/dist/storybook/project.json +1 -1
  77. package/dist/tailwind-plugin-message.d.ts +2 -0
  78. package/dist/tailwind-plugin-message.d.ts.map +1 -0
  79. package/dist/tailwind-plugin-message.js +168 -0
  80. package/dist/tailwind-plugin-message.js.map +1 -0
  81. package/dist/tailwind-plugin-message.ts +226 -0
  82. package/dist/tailwind.config.d.ts.map +1 -1
  83. package/dist/tailwind.config.js +2 -0
  84. package/dist/tailwind.config.js.map +1 -1
  85. package/dist/tailwind.config.ts +2 -0
  86. package/dist/util/EventEmitterMixin.d.ts +3 -0
  87. package/dist/util/EventEmitterMixin.d.ts.map +1 -1
  88. package/dist/util/EventEmitterMixin.js.map +1 -1
  89. package/docs/components/Banner.md +49 -0
  90. package/docs/components/Message.md +75 -0
  91. package/docs/components/README.md +2 -0
  92. package/package.json +1 -1
  93. package/src/legacy/tool-ui/src/ContentInputGroup.css +4 -0
  94. package/src/legacy/tool-ui/src/Hierarchy.css +4 -11
  95. package/src/legacy/tool-ui/src/MenuView.css +9 -0
  96. package/src/legacy/tool-ui/src/Page.css +1 -1
  97. package/src/legacy/tool-ui/src/PrePublish.ts +0 -24
  98. package/src/legacy/tool-ui/src/ThemeBundleEditor.css +4 -0
  99. package/src/legacy/tool-ui/src/main/webapp/dist/{v4.da15ce3ce45e85b4880a.js → v4.ba601ff96a3370471a41.js} +3 -3
  100. package/src/legacy/tool-ui/src/main/webapp/dist/{v5.8491d982a282935a3058.js → v5.4cdf07db0213a5d2f97e.js} +3 -3
  101. package/src/legacy/tool-ui/src/main/webapp/dist/v5.553c18f29cb4a71c3577.css +5 -0
  102. package/dist/storybook/assets/if-defined-aps73Iby.js +0 -1
  103. package/dist/storybook/assets/iframe-1F7Ef_8q.css +0 -1
  104. package/src/legacy/tool-ui/src/main/webapp/dist/v5.9b40c96064a0f8a10b53.css +0 -5
  105. /package/src/legacy/tool-ui/src/main/webapp/dist/{v4.da15ce3ce45e85b4880a.js.LICENSE.txt → v4.ba601ff96a3370471a41.js.LICENSE.txt} +0 -0
  106. /package/src/legacy/tool-ui/src/main/webapp/dist/{v5.8491d982a282935a3058.js.LICENSE.txt → v5.4cdf07db0213a5d2f97e.js.LICENSE.txt} +0 -0
@@ -0,0 +1,75 @@
1
+ # `src/components/banner/Message.ts`:
2
+
3
+ ## class: `Message`, `btu-message`
4
+
5
+ ### Superclass
6
+
7
+ | Name | Module | Package |
8
+ | ------------ | ------ | ------- |
9
+ | `LitElement` | | lit |
10
+
11
+ ### Mixins
12
+
13
+ | Name | Module | Package |
14
+ | ------------------- | ------------------------------ | ------- |
15
+ | `EventEmitterMixin` | /src/util/EventEmitterMixin.js | |
16
+ | `ReadyMixin` | /src/util/ReadyMixin.js | |
17
+
18
+ ### Fields
19
+
20
+ | Name | Privacy | Type | Default | Description | Inherited From |
21
+ | ------------- | ------- | --------------------- | -------- | ---------------------------------------------------------------------------- | -------------- |
22
+ | `variant` | | `MessageVariant` | `'info'` | Visual style and semantic meaning of the message. | |
23
+ | `label` | | `string \| undefined` | | The primary message or title text displayed. | |
24
+ | `symbol` | | `string \| undefined` | | Name of the Lucide icon to display. Defaults to a sensible icon per variant. | |
25
+ | `dismissible` | | `boolean` | `false` | If true, a close icon is provided to allow the user to hide the message. | |
26
+
27
+ ### Methods
28
+
29
+ | Name | Privacy | Description | Parameters | Return | Inherited From |
30
+ | ---------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------- | --------- | ----------------- |
31
+ | `_handleDismiss` | private | | | `void` | |
32
+ | `emit` | | Dispatches a type-safe CustomEvent with standardized configuration.&#xA;&#xA;All events are configured with:&#xA;- bubbles: true (event propagates up the DOM tree)&#xA;- cancelable: false (event cannot be cancelled)&#xA;- composed: true (event crosses shadow DOM boundaries) | `type: K, detail: UnpackCustomEvent<CustomEventMap[K]>` | `boolean` | EventEmitterMixin |
33
+
34
+ ### Events
35
+
36
+ | Name | Type | Description | Inherited From |
37
+ | --------------------- | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- |
38
+ | `btu-message-ready` | `CustomEvent` | Fired after the message is first rendered and initialized | |
39
+ | `btu-message-dismiss` | `CustomEvent` | Fired when the user clicks the close/dismiss button. Cancelable: the message hides itself (sets \`hidden\`) unless the listener calls \`preventDefault()\`. | |
40
+
41
+ ### Attributes
42
+
43
+ | Name | Field | Inherited From |
44
+ | ------------- | ----------- | -------------- |
45
+ | `variant` | variant | |
46
+ | `label` | label | |
47
+ | `symbol` | symbol | |
48
+ | `dismissible` | dismissible | |
49
+
50
+ ### CSS Properties
51
+
52
+ | Name | Default | Description |
53
+ | ---------------------------- | ------- | ---------------------------------------------------------------- |
54
+ | `--message-color-background` | | Overrides the background color for the message |
55
+ | `--message-color-foreground` | | Overrides the text and icon color |
56
+ | `--message-color-border` | | Overrides the border color (defaults to the variant's 300 shade) |
57
+ | `--message-padding` | | Overrides the internal padding (default: 1rem) |
58
+ | `--message-border-radius` | | Overrides the corner rounding (default: 8px) |
59
+
60
+ ### Slots
61
+
62
+ | Name | Description |
63
+ | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
64
+ | `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. |
65
+ | `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). |
66
+ | `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. |
67
+
68
+ <hr/>
69
+
70
+ ## Exports
71
+
72
+ | Kind | Name | Declaration | Module | Package |
73
+ | --------------------------- | ------------- | ----------- | -------------------------------- | ------- |
74
+ | `js` | `default` | Message | src/components/banner/Message.ts | |
75
+ | `custom-element-definition` | `btu-message` | Message | src/components/banner/Message.ts | |
@@ -9,6 +9,7 @@ This directory contains auto-generated API documentation for all Brightspot UI w
9
9
  - [`<btu-avatar>` - Avatar](Avatar.md)
10
10
  - [`<btu-avatar-group>` - AvatarGroup](AvatarGroup.md)
11
11
  - [`<btu-badge>` - Badge](Badge.md)
12
+ - [`<btu-banner>` - Banner](Banner.md)
12
13
  - [`<btu-button-group>` - ButtonGroup](ButtonGroup.md)
13
14
  - [`<btu-card>` - Card](Card.md)
14
15
  - [`<btu-checkbox>` - Checkbox](Checkbox.md)
@@ -22,6 +23,7 @@ This directory contains auto-generated API documentation for all Brightspot UI w
22
23
  - [`<btu-icon>` - Icon](Icon.md)
23
24
  - [`<btu-icon-button>` - IconButton](IconButton.md)
24
25
  - [`<btu-linear-progress>` - LinearProgress](LinearProgress.md)
26
+ - [`<btu-message>` - Message](Message.md)
25
27
  - [`<btu-pagination>` - Pagination](Pagination.md)
26
28
  - [`<btu-popover>` - Popover](Popover.md)
27
29
  - [`<btu-switch>` - Switch](Switch.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspot/ui",
3
- "version": "5.3.2",
3
+ "version": "5.4.1",
4
4
  "type": "module",
5
5
  "license": "UNLICENSED",
6
6
  "description": "A UI library for building Brightspot CMS components.",
@@ -185,6 +185,10 @@
185
185
  @apply mt-[--CIG-space] basis-full;
186
186
  }
187
187
 
188
+ .CIG > .TemplateField {
189
+ @apply basis-full;
190
+ }
191
+
188
192
  /* -------------- */
189
193
  /* CIG-row */
190
194
  /* -------------- */
@@ -1,6 +1,6 @@
1
1
  /* Hierarchy search result styles */
2
2
  .Hierarchy {
3
- @apply col-span-full grid size-full auto-cols-[minmax(auto,2fr)] grid-flow-col grid-cols-[minmax(262px,1fr)_minmax(262px,1fr)] gap-1 overflow-x-auto overflow-y-hidden px-2.5 [grid-row:2/4];
3
+ @apply col-span-full flex size-full gap-1 overflow-x-auto overflow-y-hidden px-2.5 [grid-row:2/4];
4
4
 
5
5
  .watch-button {
6
6
  @apply hidden;
@@ -8,14 +8,7 @@
8
8
  }
9
9
 
10
10
  .Hierarchy-column {
11
- @apply max-h-full min-w-[262px] overflow-y-auto;
12
-
13
- /* Hacky way to make sure that a single column will span full width */
14
- .Hierarchy > & {
15
- &:has(+ .Hierarchy-children) {
16
- @apply col-span-2;
17
- }
18
- }
11
+ @apply max-h-full min-w-[262px] flex-1 shrink-0 overflow-y-auto;
19
12
 
20
13
  a[data-mismatch-hierarchy-type] {
21
14
  @apply pointer-events-none cursor-none opacity-30;
@@ -51,11 +44,11 @@
51
44
  }
52
45
 
53
46
  .Hierarchy-children {
54
- @apply contents;
47
+ @apply flex shrink-0 gap-1;
55
48
 
56
49
  /* Shows the user that the selected item has no loadable children */
57
50
  :has(li.is-selected) + &.loaded:empty {
58
- @apply blokk h-[42px] min-w-[262px] flex-1 rounded-lg bg-gray-100 shadow-md;
51
+ @apply blokk h-[42px] min-w-[262px] rounded-lg bg-gray-100 shadow-md;
59
52
  }
60
53
  }
61
54
 
@@ -60,6 +60,10 @@
60
60
  @apply btu-button-pressed after:-rotate-180;
61
61
  }
62
62
 
63
+ &.active:not(.is-open):not(.rte-overflow-btn) > button {
64
+ @apply btu-button-pressed;
65
+ }
66
+
63
67
  &.rte-overflow-btn {
64
68
  @apply h-7;
65
69
  }
@@ -316,6 +320,11 @@ button + .rte2-toolbar-submenu-2-items {
316
320
  @apply btu-button-pressed;
317
321
  }
318
322
 
323
+ /* Submenu active items: selector specificity (0-3-1) beats Dropdown-item's background-color:transparent (0-2-3) */
324
+ .rte2-toolbar-submenu-2-items .ProseMirrorToolbar-action.active > a {
325
+ @apply btu-dropdown-item-selected;
326
+ }
327
+
319
328
  .ProseMirrorToolbar-action.disabled > a[data-icon] {
320
329
  @apply btu-button-disabled;
321
330
  }
@@ -780,7 +780,7 @@
780
780
  }
781
781
 
782
782
  .Page-title {
783
- @apply visible absolute bottom-[55dvh] top-auto z-10 order-2 flex w-full transform-none items-center justify-start ps-6 @container-normal md:bottom-[56dvh] md:right-0 md:m-[unset] md:w-[--Page-loginWidth];
783
+ @apply visible absolute bottom-[55dvh] top-auto z-10 order-2 flex w-full transform-none items-center justify-start ps-6 @container-normal md:bottom-[56dvh] md:right-0 md:m-[unset] md:!me-0 md:w-[--Page-loginWidth] md:max-w-none;
784
784
  }
785
785
 
786
786
  .Page-title img {
@@ -18,30 +18,6 @@ onFind('.PrePublish', (popup: HTMLElement) => {
18
18
  }
19
19
 
20
20
  close?.addEventListener('click', () => {
21
- // User closed the popup and chose to continue then submit without interferrence.
22
- if (form) {
23
- const input = form.querySelector<HTMLInputElement>(
24
- 'input[name="prePublish"]',
25
- )
26
- const button = form.querySelector<HTMLButtonElement>(
27
- 'button[name="prePublishDisplay"]',
28
- )
29
-
30
- input?.remove()
31
-
32
- if (button) {
33
- button.addEventListener(
34
- 'click',
35
- () => {
36
- if (input) {
37
- form.appendChild(input)
38
- }
39
- },
40
- { once: true },
41
- )
42
- }
43
- }
44
-
45
21
  popup.classList.remove('is-visible')
46
22
 
47
23
  if (window.BRIGHTSPOT?.ui.cms.enableV5UI) {
@@ -44,6 +44,10 @@
44
44
  }
45
45
  }
46
46
 
47
+ dialog:modal .ThemeBundleEditor-stage.is-open {
48
+ @apply inset-[var(--padding)] rounded-2xl overflow-hidden;
49
+ }
50
+
47
51
  /* Carryover from v4 */
48
52
  .Styleguide .Page.is-inIframe {
49
53
  @apply h-full;