@mattermost/compass-ui 0.1.0-alpha.6 → 0.1.0-alpha.7

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 (247) hide show
  1. package/dist/components/action-button/ActionButton.cjs.map +1 -1
  2. package/dist/components/action-button/ActionButton.d.ts +1 -0
  3. package/dist/components/action-button/ActionButton.d.ts.map +1 -1
  4. package/dist/components/action-button/ActionButton.js.map +1 -1
  5. package/dist/components/admin-panel/AdminPanel.cjs.map +1 -1
  6. package/dist/components/admin-panel/AdminPanel.d.ts +1 -0
  7. package/dist/components/admin-panel/AdminPanel.d.ts.map +1 -1
  8. package/dist/components/admin-panel/AdminPanel.js.map +1 -1
  9. package/dist/components/admin-panel-header/AdminPanelHeader.cjs.map +1 -1
  10. package/dist/components/admin-panel-header/AdminPanelHeader.d.ts +1 -0
  11. package/dist/components/admin-panel-header/AdminPanelHeader.d.ts.map +1 -1
  12. package/dist/components/admin-panel-header/AdminPanelHeader.js.map +1 -1
  13. package/dist/components/button/Button.cjs +1 -1
  14. package/dist/components/button/Button.cjs.map +1 -1
  15. package/dist/components/button/Button.d.ts +2 -2
  16. package/dist/components/button/Button.d.ts.map +1 -1
  17. package/dist/components/button/Button.js +24 -24
  18. package/dist/components/button/Button.js.map +1 -1
  19. package/dist/components/button/Button.module.css +1 -1
  20. package/dist/components/button/Button.module.scss.cjs +1 -1
  21. package/dist/components/button/Button.module.scss.js +13 -12
  22. package/dist/components/button/Button.module.scss.js.map +1 -1
  23. package/dist/components/card-button/CardButton.cjs +2 -0
  24. package/dist/components/card-button/CardButton.cjs.map +1 -0
  25. package/dist/components/card-button/CardButton.d.ts +20 -0
  26. package/dist/components/card-button/CardButton.d.ts.map +1 -0
  27. package/dist/components/card-button/CardButton.js +45 -0
  28. package/dist/components/card-button/CardButton.js.map +1 -0
  29. package/dist/components/card-button/CardButton.module.css +1 -0
  30. package/dist/components/card-button/CardButton.module.scss.cjs +2 -0
  31. package/dist/components/card-button/CardButton.module.scss.cjs.map +1 -0
  32. package/dist/components/card-button/CardButton.module.scss.js +13 -0
  33. package/dist/components/card-button/CardButton.module.scss.js.map +1 -0
  34. package/dist/components/card-button/CardButtonGroup.cjs +2 -0
  35. package/dist/components/card-button/CardButtonGroup.cjs.map +1 -0
  36. package/dist/components/card-button/CardButtonGroup.d.ts +13 -0
  37. package/dist/components/card-button/CardButtonGroup.d.ts.map +1 -0
  38. package/dist/components/card-button/CardButtonGroup.js +85 -0
  39. package/dist/components/card-button/CardButtonGroup.js.map +1 -0
  40. package/dist/components/card-button/CardButtonGroup.module.css +1 -0
  41. package/dist/components/card-button/CardButtonGroup.module.scss.cjs +2 -0
  42. package/dist/components/card-button/CardButtonGroup.module.scss.cjs.map +1 -0
  43. package/dist/components/card-button/CardButtonGroup.module.scss.js +7 -0
  44. package/dist/components/card-button/CardButtonGroup.module.scss.js.map +1 -0
  45. package/dist/components/card-button/index.cjs +2 -0
  46. package/dist/components/card-button/index.d.ts +5 -0
  47. package/dist/components/card-button/index.d.ts.map +1 -0
  48. package/dist/components/card-button/index.js +7 -0
  49. package/dist/components/card-button/index.js.map +1 -0
  50. package/dist/components/emoji-button/EmojiButton.cjs +2 -0
  51. package/dist/components/emoji-button/EmojiButton.cjs.map +1 -0
  52. package/dist/components/emoji-button/EmojiButton.d.ts +30 -0
  53. package/dist/components/emoji-button/EmojiButton.d.ts.map +1 -0
  54. package/dist/components/emoji-button/EmojiButton.js +35 -0
  55. package/dist/components/emoji-button/EmojiButton.js.map +1 -0
  56. package/dist/components/emoji-button/EmojiButton.module.css +1 -0
  57. package/dist/components/emoji-button/EmojiButton.module.scss.cjs +2 -0
  58. package/dist/components/emoji-button/EmojiButton.module.scss.cjs.map +1 -0
  59. package/dist/components/emoji-button/EmojiButton.module.scss.js +15 -0
  60. package/dist/components/emoji-button/EmojiButton.module.scss.js.map +1 -0
  61. package/dist/components/emoji-button/index.cjs +2 -0
  62. package/dist/components/emoji-button/index.cjs.map +1 -0
  63. package/dist/components/emoji-button/index.d.ts +3 -0
  64. package/dist/components/emoji-button/index.d.ts.map +1 -0
  65. package/dist/components/emoji-button/index.js +6 -0
  66. package/dist/components/emoji-popover/EmojiPopover.cjs +2 -0
  67. package/dist/components/emoji-popover/EmojiPopover.cjs.map +1 -0
  68. package/dist/components/emoji-popover/EmojiPopover.d.ts +34 -0
  69. package/dist/components/emoji-popover/EmojiPopover.d.ts.map +1 -0
  70. package/dist/components/emoji-popover/EmojiPopover.js +244 -0
  71. package/dist/components/emoji-popover/EmojiPopover.js.map +1 -0
  72. package/dist/components/emoji-popover/EmojiPopover.module.css +1 -0
  73. package/dist/components/emoji-popover/EmojiPopover.module.scss.cjs +2 -0
  74. package/dist/components/emoji-popover/EmojiPopover.module.scss.cjs.map +1 -0
  75. package/dist/components/emoji-popover/EmojiPopover.module.scss.js +27 -0
  76. package/dist/components/emoji-popover/EmojiPopover.module.scss.js.map +1 -0
  77. package/dist/components/{message-reactions → emoji-popover}/index.cjs +1 -1
  78. package/dist/components/emoji-popover/index.cjs.map +1 -0
  79. package/dist/components/emoji-popover/index.d.ts +3 -0
  80. package/dist/components/emoji-popover/index.d.ts.map +1 -0
  81. package/dist/components/emoji-popover/index.js +5 -0
  82. package/dist/components/emoji-popover/index.js.map +1 -0
  83. package/dist/components/global-banner/GlobalBanner.cjs.map +1 -1
  84. package/dist/components/global-banner/GlobalBanner.d.ts +1 -1
  85. package/dist/components/global-banner/GlobalBanner.d.ts.map +1 -1
  86. package/dist/components/global-banner/GlobalBanner.js.map +1 -1
  87. package/dist/components/global-header/GlobalHeader.module.css +1 -1
  88. package/dist/components/global-header/GlobalHeader.module.scss.cjs +1 -1
  89. package/dist/components/global-header/GlobalHeader.module.scss.js +16 -16
  90. package/dist/components/menu-group-heading/MenuGroupHeading.cjs +2 -0
  91. package/dist/components/menu-group-heading/MenuGroupHeading.cjs.map +1 -0
  92. package/dist/components/menu-group-heading/MenuGroupHeading.d.ts +11 -0
  93. package/dist/components/menu-group-heading/MenuGroupHeading.d.ts.map +1 -0
  94. package/dist/components/menu-group-heading/MenuGroupHeading.js +20 -0
  95. package/dist/components/menu-group-heading/MenuGroupHeading.js.map +1 -0
  96. package/dist/components/menu-group-heading/MenuGroupHeading.module.css +1 -0
  97. package/dist/components/menu-group-heading/MenuGroupHeading.module.scss.cjs +2 -0
  98. package/dist/components/menu-group-heading/MenuGroupHeading.module.scss.cjs.map +1 -0
  99. package/dist/components/menu-group-heading/MenuGroupHeading.module.scss.js +8 -0
  100. package/dist/components/menu-group-heading/MenuGroupHeading.module.scss.js.map +1 -0
  101. package/dist/components/menu-group-heading/index.cjs +2 -0
  102. package/dist/components/menu-group-heading/index.cjs.map +1 -0
  103. package/dist/components/menu-group-heading/index.d.ts +3 -0
  104. package/dist/components/menu-group-heading/index.d.ts.map +1 -0
  105. package/dist/components/menu-group-heading/index.js +5 -0
  106. package/dist/components/menu-group-heading/index.js.map +1 -0
  107. package/dist/components/menu-item/MenuItem.cjs.map +1 -1
  108. package/dist/components/menu-item/MenuItem.d.ts +2 -2
  109. package/dist/components/menu-item/MenuItem.d.ts.map +1 -1
  110. package/dist/components/menu-item/MenuItem.js.map +1 -1
  111. package/dist/components/message-separator/MessageSeparator.cjs +1 -1
  112. package/dist/components/message-separator/MessageSeparator.cjs.map +1 -1
  113. package/dist/components/message-separator/MessageSeparator.d.ts +1 -1
  114. package/dist/components/message-separator/MessageSeparator.js +1 -1
  115. package/dist/components/message-separator/MessageSeparator.js.map +1 -1
  116. package/dist/components/modal/Modal.cjs +1 -1
  117. package/dist/components/modal/Modal.cjs.map +1 -1
  118. package/dist/components/modal/Modal.d.ts +43 -11
  119. package/dist/components/modal/Modal.d.ts.map +1 -1
  120. package/dist/components/modal/Modal.js +56 -74
  121. package/dist/components/modal/Modal.js.map +1 -1
  122. package/dist/components/modal/Modal.module.css +1 -1
  123. package/dist/components/modal/Modal.module.scss.cjs +1 -1
  124. package/dist/components/modal/Modal.module.scss.js +12 -25
  125. package/dist/components/modal/Modal.module.scss.js.map +1 -1
  126. package/dist/components/modal/index.d.ts +1 -1
  127. package/dist/components/modal/index.d.ts.map +1 -1
  128. package/dist/components/modal-footer/ModalFooter.cjs +2 -0
  129. package/dist/components/modal-footer/ModalFooter.cjs.map +1 -0
  130. package/dist/components/modal-footer/ModalFooter.d.ts +29 -0
  131. package/dist/components/modal-footer/ModalFooter.d.ts.map +1 -0
  132. package/dist/components/modal-footer/ModalFooter.js +31 -0
  133. package/dist/components/modal-footer/ModalFooter.js.map +1 -0
  134. package/dist/components/modal-footer/ModalFooter.module.css +1 -0
  135. package/dist/components/modal-footer/ModalFooter.module.scss.cjs +2 -0
  136. package/dist/components/modal-footer/ModalFooter.module.scss.cjs.map +1 -0
  137. package/dist/components/modal-footer/ModalFooter.module.scss.js +17 -0
  138. package/dist/components/modal-footer/ModalFooter.module.scss.js.map +1 -0
  139. package/dist/components/modal-footer/index.cjs +2 -0
  140. package/dist/components/modal-footer/index.cjs.map +1 -0
  141. package/dist/components/modal-footer/index.d.ts +3 -0
  142. package/dist/components/modal-footer/index.d.ts.map +1 -0
  143. package/dist/components/modal-footer/index.js +5 -0
  144. package/dist/components/modal-footer/index.js.map +1 -0
  145. package/dist/components/modal-header/ModalHeader.cjs +2 -0
  146. package/dist/components/modal-header/ModalHeader.cjs.map +1 -0
  147. package/dist/components/modal-header/ModalHeader.d.ts +38 -0
  148. package/dist/components/modal-header/ModalHeader.d.ts.map +1 -0
  149. package/dist/components/modal-header/ModalHeader.js +74 -0
  150. package/dist/components/modal-header/ModalHeader.js.map +1 -0
  151. package/dist/components/modal-header/ModalHeader.module.css +1 -0
  152. package/dist/components/modal-header/ModalHeader.module.scss.cjs +2 -0
  153. package/dist/components/modal-header/ModalHeader.module.scss.cjs.map +1 -0
  154. package/dist/components/modal-header/ModalHeader.module.scss.js +19 -0
  155. package/dist/components/modal-header/ModalHeader.module.scss.js.map +1 -0
  156. package/dist/components/modal-header/index.cjs +2 -0
  157. package/dist/components/modal-header/index.cjs.map +1 -0
  158. package/dist/components/modal-header/index.d.ts +3 -0
  159. package/dist/components/modal-header/index.d.ts.map +1 -0
  160. package/dist/components/modal-header/index.js +5 -0
  161. package/dist/components/modal-header/index.js.map +1 -0
  162. package/dist/components/popover-notice/PopoverNotice.cjs.map +1 -1
  163. package/dist/components/popover-notice/PopoverNotice.d.ts +1 -1
  164. package/dist/components/popover-notice/PopoverNotice.d.ts.map +1 -1
  165. package/dist/components/popover-notice/PopoverNotice.js.map +1 -1
  166. package/dist/components/reaction-button/ReactionButton.cjs +2 -0
  167. package/dist/components/reaction-button/ReactionButton.cjs.map +1 -0
  168. package/dist/components/reaction-button/ReactionButton.d.ts +17 -0
  169. package/dist/components/reaction-button/ReactionButton.d.ts.map +1 -0
  170. package/dist/components/reaction-button/ReactionButton.js +42 -0
  171. package/dist/components/reaction-button/ReactionButton.js.map +1 -0
  172. package/dist/components/reaction-button/ReactionButton.module.css +1 -0
  173. package/dist/components/reaction-button/ReactionButton.module.scss.cjs +2 -0
  174. package/dist/components/reaction-button/ReactionButton.module.scss.cjs.map +1 -0
  175. package/dist/components/reaction-button/ReactionButton.module.scss.js +12 -0
  176. package/dist/components/reaction-button/ReactionButton.module.scss.js.map +1 -0
  177. package/dist/components/reaction-button/index.cjs +2 -0
  178. package/dist/components/reaction-button/index.cjs.map +1 -0
  179. package/dist/components/reaction-button/index.d.ts +3 -0
  180. package/dist/components/reaction-button/index.d.ts.map +1 -0
  181. package/dist/components/reaction-button/index.js +5 -0
  182. package/dist/components/reaction-button/index.js.map +1 -0
  183. package/dist/components/reactions-row/ReactionsRow.cjs +2 -0
  184. package/dist/components/reactions-row/ReactionsRow.cjs.map +1 -0
  185. package/dist/components/{message-reactions/MessageReactions.d.ts → reactions-row/ReactionsRow.d.ts} +5 -5
  186. package/dist/components/reactions-row/ReactionsRow.d.ts.map +1 -0
  187. package/dist/components/reactions-row/ReactionsRow.js +71 -0
  188. package/dist/components/reactions-row/ReactionsRow.js.map +1 -0
  189. package/dist/components/reactions-row/ReactionsRow.module.css +1 -0
  190. package/dist/components/reactions-row/ReactionsRow.module.scss.cjs +2 -0
  191. package/dist/components/reactions-row/ReactionsRow.module.scss.cjs.map +1 -0
  192. package/dist/components/reactions-row/ReactionsRow.module.scss.js +14 -0
  193. package/dist/components/reactions-row/ReactionsRow.module.scss.js.map +1 -0
  194. package/dist/components/reactions-row/index.cjs +2 -0
  195. package/dist/components/reactions-row/index.cjs.map +1 -0
  196. package/dist/components/reactions-row/index.d.ts +3 -0
  197. package/dist/components/reactions-row/index.d.ts.map +1 -0
  198. package/dist/components/reactions-row/index.js +5 -0
  199. package/dist/components/reactions-row/index.js.map +1 -0
  200. package/dist/components/right-sidebar-header/RightSidebarHeader.cjs.map +1 -1
  201. package/dist/components/right-sidebar-header/RightSidebarHeader.d.ts +1 -1
  202. package/dist/components/right-sidebar-header/RightSidebarHeader.d.ts.map +1 -1
  203. package/dist/components/right-sidebar-header/RightSidebarHeader.js.map +1 -1
  204. package/dist/components/section-notice/SectionNotice.cjs.map +1 -1
  205. package/dist/components/section-notice/SectionNotice.d.ts +1 -1
  206. package/dist/components/section-notice/SectionNotice.d.ts.map +1 -1
  207. package/dist/components/section-notice/SectionNotice.js.map +1 -1
  208. package/dist/components/tag/Tag.cjs.map +1 -1
  209. package/dist/components/tag/Tag.d.ts +1 -1
  210. package/dist/components/tag/Tag.d.ts.map +1 -1
  211. package/dist/components/tag/Tag.js.map +1 -1
  212. package/dist/components/text-input/TextInput.cjs.map +1 -1
  213. package/dist/components/text-input/TextInput.d.ts +1 -1
  214. package/dist/components/text-input/TextInput.d.ts.map +1 -1
  215. package/dist/components/text-input/TextInput.js.map +1 -1
  216. package/dist/components/thread-footer/ThreadFooter.module.css +1 -1
  217. package/dist/components/thread-footer/ThreadFooter.module.scss.cjs +1 -1
  218. package/dist/components/thread-footer/ThreadFooter.module.scss.js +19 -19
  219. package/dist/components/tooltip/Tooltip.cjs.map +1 -1
  220. package/dist/components/tooltip/Tooltip.d.ts +1 -1
  221. package/dist/components/tooltip/Tooltip.d.ts.map +1 -1
  222. package/dist/components/tooltip/Tooltip.js.map +1 -1
  223. package/dist/components/tour-point/TourPoint.module.css +1 -1
  224. package/dist/components/tour-point/TourPoint.module.scss.cjs +1 -1
  225. package/dist/components/tour-point/TourPoint.module.scss.js +28 -28
  226. package/dist/index.cjs +1 -1
  227. package/dist/index.css +23 -7
  228. package/dist/index.d.ts +8 -1
  229. package/dist/index.d.ts.map +1 -1
  230. package/dist/index.js +192 -175
  231. package/dist/index.js.map +1 -1
  232. package/package.json +25 -4
  233. package/dist/components/message-reactions/MessageReactions.cjs +0 -2
  234. package/dist/components/message-reactions/MessageReactions.cjs.map +0 -1
  235. package/dist/components/message-reactions/MessageReactions.d.ts.map +0 -1
  236. package/dist/components/message-reactions/MessageReactions.js +0 -85
  237. package/dist/components/message-reactions/MessageReactions.js.map +0 -1
  238. package/dist/components/message-reactions/MessageReactions.module.css +0 -1
  239. package/dist/components/message-reactions/MessageReactions.module.scss.cjs +0 -2
  240. package/dist/components/message-reactions/MessageReactions.module.scss.cjs.map +0 -1
  241. package/dist/components/message-reactions/MessageReactions.module.scss.js +0 -18
  242. package/dist/components/message-reactions/MessageReactions.module.scss.js.map +0 -1
  243. package/dist/components/message-reactions/index.d.ts +0 -3
  244. package/dist/components/message-reactions/index.d.ts.map +0 -1
  245. package/dist/components/message-reactions/index.js +0 -5
  246. /package/dist/components/{message-reactions → card-button}/index.cjs.map +0 -0
  247. /package/dist/components/{message-reactions → emoji-button}/index.js.map +0 -0
@@ -1,29 +1,16 @@
1
- import './Modal.module.css';const _ = "_modal_1wwq4_2", o = "_modal__header_1wwq4_20", d = "_modal__title_1wwq4_40", l = "_modal__subtitle_1wwq4_54", e = "_modal__close_1wwq4_61", a = "_modal__body_1wwq4_66", m = "_modal__footer_1wwq4_76", t = {
2
- modal: _,
3
- "modal--size-small": "_modal--size-small_1wwq4_11",
4
- "modal--size-medium": "_modal--size-medium_1wwq4_14",
5
- "modal--size-large": "_modal--size-large_1wwq4_17",
6
- modal__header: o,
7
- "modal__header--no-divider": "_modal__header--no-divider_1wwq4_28",
8
- "modal__header-inner": "_modal__header-inner_1wwq4_32",
9
- "modal__title-group": "_modal__title-group_1wwq4_40",
10
- modal__title: d,
11
- modal__subtitle: l,
12
- modal__close: e,
13
- modal__body: a,
14
- "modal__body-inner": "_modal__body-inner_1wwq4_70",
15
- "modal__body-inner--menu": "_modal__body-inner--menu_1wwq4_73",
16
- modal__footer: m,
17
- "modal__footer--no-divider": "_modal__footer--no-divider_1wwq4_85"
1
+ import './Modal.module.css';const m = "_modal_18mtm_2", _ = "_modal__body_18mtm_20", o = {
2
+ modal: m,
3
+ "modal--size-small": "_modal--size-small_18mtm_11",
4
+ "modal--size-medium": "_modal--size-medium_18mtm_14",
5
+ "modal--size-large": "_modal--size-large_18mtm_17",
6
+ modal__body: _,
7
+ "modal__body-inner": "_modal__body-inner_18mtm_24",
8
+ "modal__body-inner--menu": "_modal__body-inner--menu_18mtm_27",
9
+ "modal__body-inner--none": "_modal__body-inner--none_18mtm_30"
18
10
  };
19
11
  export {
20
- t as default,
21
- _ as modal,
22
- a as modal__body,
23
- e as modal__close,
24
- m as modal__footer,
25
- o as modal__header,
26
- l as modal__subtitle,
27
- d as modal__title
12
+ o as default,
13
+ m as modal,
14
+ _ as modal__body
28
15
  };
29
16
  //# sourceMappingURL=Modal.module.scss.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Modal.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"Modal.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;"}
@@ -1,3 +1,3 @@
1
1
  export { default as Modal } from './Modal';
2
- export type { ModalBodyPadding, ModalProps, ModalSize } from './Modal';
2
+ export type { ModalBodyPadding, ModalFooterType, ModalProps, ModalSize, ModalSubtitlePlacement, } from './Modal';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/modal/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,SAAS,CAAC;AAC3C,YAAY,EAAE,gBAAgB,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/modal/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,SAAS,CAAC;AAC3C,YAAY,EACV,gBAAgB,EAChB,eAAe,EACf,UAAU,EACV,SAAS,EACT,sBAAsB,GACvB,MAAM,SAAS,CAAC"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("react/jsx-runtime"),e=require("./ModalFooter.module.scss.cjs");function n({className:r="",type:l="2-actions",divider:i=!0,leading:a,children:d}){const t=l==="spacer-small"||l==="spacer-large",s=i&&!t,u=e.default[`modal-footer--type-${l}`];return o.jsx("div",{className:[e.default["modal-footer"],u,s&&e.default["modal-footer--divider"],!s&&!t&&e.default["modal-footer--no-divider"],r].filter(Boolean).join(" "),children:!t&&o.jsxs("div",{className:e.default["modal-footer__content"],children:[a!=null&&o.jsx("div",{className:e.default["modal-footer__leading"],children:a}),d!=null&&o.jsx("div",{className:e.default["modal-footer__actions"],children:d})]})})}exports.default=n;
2
+ //# sourceMappingURL=ModalFooter.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalFooter.cjs","sources":["../../../src/components/modal-footer/ModalFooter.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport styles from './ModalFooter.module.scss';\n\n/**\n * Figma Modal Footer Type (kebab-case).\n * - `2-actions` / `1-action` — children end-aligned\n * - `2-actions-separated` — space-between (first child start, rest end… or use `leading`)\n * - `pagination` / `stepped-progress` — `leading` on the left, `children` on the right\n * - `spacer-small` / `spacer-large` — empty padding only\n */\nexport type ModalFooterType =\n | '2-actions'\n | '2-actions-separated'\n | '1-action'\n | 'pagination'\n | 'stepped-progress'\n | 'spacer-small'\n | 'spacer-large';\n\nexport interface ModalFooterProps {\n className?: string;\n /** Layout variant. Figma: Type. Default: `2-actions`. */\n type?: ModalFooterType;\n /** Top border. Figma: Divider = On. Default: true (ignored for spacers). */\n divider?: boolean;\n /** Left slot — pagination status text, PaginationDots, etc. */\n leading?: ReactNode;\n /** Action buttons (or empty for spacers). */\n children?: ReactNode;\n}\n\n/**\n * Modal Footer chrome — padding, optional divider, and layout for actions /\n * pagination / stepped progress / spacers. Pass Buttons (or other controls) as\n * children; host owns labels and handlers.\n *\n * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=797-8156\n */\nexport default function ModalFooter({\n className = '',\n type = '2-actions',\n divider = true,\n leading,\n children,\n}: ModalFooterProps) {\n const isSpacer = type === 'spacer-small' || type === 'spacer-large';\n const showDivider = divider && !isSpacer;\n const typeClass = styles[`modal-footer--type-${type}`];\n\n return (\n <div\n className={[\n styles['modal-footer'],\n typeClass,\n showDivider && styles['modal-footer--divider'],\n !showDivider && !isSpacer && styles['modal-footer--no-divider'],\n className,\n ]\n .filter(Boolean)\n .join(' ')}\n >\n {!isSpacer && (\n <div className={styles['modal-footer__content']}>\n {leading != null && (\n <div className={styles['modal-footer__leading']}>{leading}</div>\n )}\n {children != null && (\n <div className={styles['modal-footer__actions']}>{children}</div>\n )}\n </div>\n )}\n </div>\n );\n}\n"],"names":["ModalFooter","className","type","divider","leading","children","isSpacer","showDivider","typeClass","styles","jsx","jsxs"],"mappings":"4LAsCA,SAAwBA,EAAY,CAClC,UAAAC,EAAY,GACZ,KAAAC,EAAO,YACP,QAAAC,EAAU,GACV,QAAAC,EACA,SAAAC,CACF,EAAqB,CACnB,MAAMC,EAAWJ,IAAS,gBAAkBA,IAAS,eAC/CK,EAAcJ,GAAW,CAACG,EAC1BE,EAAYC,EAAAA,QAAO,sBAAsBP,CAAI,EAAE,EAErD,OACEQ,EAAAA,IAAC,MAAA,CACC,UAAW,CACTD,EAAAA,QAAO,cAAc,EACrBD,EACAD,GAAeE,EAAAA,QAAO,uBAAuB,EAC7C,CAACF,GAAe,CAACD,GAAYG,EAAAA,QAAO,0BAA0B,EAC9DR,CAAA,EAEC,OAAO,OAAO,EACd,KAAK,GAAG,EAEV,UAACK,GACAK,EAAAA,KAAC,OAAI,UAAWF,EAAAA,QAAO,uBAAuB,EAC3C,SAAA,CAAAL,GAAW,MACVM,MAAC,MAAA,CAAI,UAAWD,EAAAA,QAAO,uBAAuB,EAAI,SAAAL,EAAQ,EAE3DC,GAAY,MACXK,EAAAA,IAAC,MAAA,CAAI,UAAWD,EAAAA,QAAO,uBAAuB,EAAI,SAAAJ,CAAA,CAAS,CAAA,CAAA,CAE/D,CAAA,CAAA,CAIR"}
@@ -0,0 +1,29 @@
1
+ import { ReactNode } from 'react';
2
+ /**
3
+ * Figma Modal Footer Type (kebab-case).
4
+ * - `2-actions` / `1-action` — children end-aligned
5
+ * - `2-actions-separated` — space-between (first child start, rest end… or use `leading`)
6
+ * - `pagination` / `stepped-progress` — `leading` on the left, `children` on the right
7
+ * - `spacer-small` / `spacer-large` — empty padding only
8
+ */
9
+ export type ModalFooterType = '2-actions' | '2-actions-separated' | '1-action' | 'pagination' | 'stepped-progress' | 'spacer-small' | 'spacer-large';
10
+ export interface ModalFooterProps {
11
+ className?: string;
12
+ /** Layout variant. Figma: Type. Default: `2-actions`. */
13
+ type?: ModalFooterType;
14
+ /** Top border. Figma: Divider = On. Default: true (ignored for spacers). */
15
+ divider?: boolean;
16
+ /** Left slot — pagination status text, PaginationDots, etc. */
17
+ leading?: ReactNode;
18
+ /** Action buttons (or empty for spacers). */
19
+ children?: ReactNode;
20
+ }
21
+ /**
22
+ * Modal Footer chrome — padding, optional divider, and layout for actions /
23
+ * pagination / stepped progress / spacers. Pass Buttons (or other controls) as
24
+ * children; host owns labels and handlers.
25
+ *
26
+ * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=797-8156
27
+ */
28
+ export default function ModalFooter({ className, type, divider, leading, children, }: ModalFooterProps): import("react/jsx-runtime").JSX.Element;
29
+ //# sourceMappingURL=ModalFooter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalFooter.d.ts","sourceRoot":"","sources":["../../../src/components/modal-footer/ModalFooter.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC;;;;;;GAMG;AACH,MAAM,MAAM,eAAe,GACvB,WAAW,GACX,qBAAqB,GACrB,UAAU,GACV,YAAY,GACZ,kBAAkB,GAClB,cAAc,GACd,cAAc,CAAC;AAEnB,MAAM,WAAW,gBAAgB;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,yDAAyD;IACzD,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,4EAA4E;IAC5E,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,+DAA+D;IAC/D,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,6CAA6C;IAC7C,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB;AAED;;;;;;GAMG;AACH,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,SAAc,EACd,IAAkB,EAClB,OAAc,EACd,OAAO,EACP,QAAQ,GACT,EAAE,gBAAgB,2CA6BlB"}
@@ -0,0 +1,31 @@
1
+ import { jsx as l, jsxs as c } from "react/jsx-runtime";
2
+ import o from "./ModalFooter.module.scss.js";
3
+ function v({
4
+ className: d = "",
5
+ type: e = "2-actions",
6
+ divider: i = !0,
7
+ leading: r,
8
+ children: s
9
+ }) {
10
+ const a = e === "spacer-small" || e === "spacer-large", t = i && !a, n = o[`modal-footer--type-${e}`];
11
+ return /* @__PURE__ */ l(
12
+ "div",
13
+ {
14
+ className: [
15
+ o["modal-footer"],
16
+ n,
17
+ t && o["modal-footer--divider"],
18
+ !t && !a && o["modal-footer--no-divider"],
19
+ d
20
+ ].filter(Boolean).join(" "),
21
+ children: !a && /* @__PURE__ */ c("div", { className: o["modal-footer__content"], children: [
22
+ r != null && /* @__PURE__ */ l("div", { className: o["modal-footer__leading"], children: r }),
23
+ s != null && /* @__PURE__ */ l("div", { className: o["modal-footer__actions"], children: s })
24
+ ] })
25
+ }
26
+ );
27
+ }
28
+ export {
29
+ v as default
30
+ };
31
+ //# sourceMappingURL=ModalFooter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalFooter.js","sources":["../../../src/components/modal-footer/ModalFooter.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport styles from './ModalFooter.module.scss';\n\n/**\n * Figma Modal Footer Type (kebab-case).\n * - `2-actions` / `1-action` — children end-aligned\n * - `2-actions-separated` — space-between (first child start, rest end… or use `leading`)\n * - `pagination` / `stepped-progress` — `leading` on the left, `children` on the right\n * - `spacer-small` / `spacer-large` — empty padding only\n */\nexport type ModalFooterType =\n | '2-actions'\n | '2-actions-separated'\n | '1-action'\n | 'pagination'\n | 'stepped-progress'\n | 'spacer-small'\n | 'spacer-large';\n\nexport interface ModalFooterProps {\n className?: string;\n /** Layout variant. Figma: Type. Default: `2-actions`. */\n type?: ModalFooterType;\n /** Top border. Figma: Divider = On. Default: true (ignored for spacers). */\n divider?: boolean;\n /** Left slot — pagination status text, PaginationDots, etc. */\n leading?: ReactNode;\n /** Action buttons (or empty for spacers). */\n children?: ReactNode;\n}\n\n/**\n * Modal Footer chrome — padding, optional divider, and layout for actions /\n * pagination / stepped progress / spacers. Pass Buttons (or other controls) as\n * children; host owns labels and handlers.\n *\n * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=797-8156\n */\nexport default function ModalFooter({\n className = '',\n type = '2-actions',\n divider = true,\n leading,\n children,\n}: ModalFooterProps) {\n const isSpacer = type === 'spacer-small' || type === 'spacer-large';\n const showDivider = divider && !isSpacer;\n const typeClass = styles[`modal-footer--type-${type}`];\n\n return (\n <div\n className={[\n styles['modal-footer'],\n typeClass,\n showDivider && styles['modal-footer--divider'],\n !showDivider && !isSpacer && styles['modal-footer--no-divider'],\n className,\n ]\n .filter(Boolean)\n .join(' ')}\n >\n {!isSpacer && (\n <div className={styles['modal-footer__content']}>\n {leading != null && (\n <div className={styles['modal-footer__leading']}>{leading}</div>\n )}\n {children != null && (\n <div className={styles['modal-footer__actions']}>{children}</div>\n )}\n </div>\n )}\n </div>\n );\n}\n"],"names":["ModalFooter","className","type","divider","leading","children","isSpacer","showDivider","typeClass","styles","jsx","jsxs"],"mappings":";;AAsCA,SAAwBA,EAAY;AAAA,EAClC,WAAAC,IAAY;AAAA,EACZ,MAAAC,IAAO;AAAA,EACP,SAAAC,IAAU;AAAA,EACV,SAAAC;AAAA,EACA,UAAAC;AACF,GAAqB;AACnB,QAAMC,IAAWJ,MAAS,kBAAkBA,MAAS,gBAC/CK,IAAcJ,KAAW,CAACG,GAC1BE,IAAYC,EAAO,sBAAsBP,CAAI,EAAE;AAErD,SACE,gBAAAQ;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW;AAAA,QACTD,EAAO,cAAc;AAAA,QACrBD;AAAA,QACAD,KAAeE,EAAO,uBAAuB;AAAA,QAC7C,CAACF,KAAe,CAACD,KAAYG,EAAO,0BAA0B;AAAA,QAC9DR;AAAA,MAAA,EAEC,OAAO,OAAO,EACd,KAAK,GAAG;AAAA,MAEV,WAACK,KACA,gBAAAK,EAAC,SAAI,WAAWF,EAAO,uBAAuB,GAC3C,UAAA;AAAA,QAAAL,KAAW,QACV,gBAAAM,EAAC,OAAA,EAAI,WAAWD,EAAO,uBAAuB,GAAI,UAAAL,GAAQ;AAAA,QAE3DC,KAAY,QACX,gBAAAK,EAAC,OAAA,EAAI,WAAWD,EAAO,uBAAuB,GAAI,UAAAJ,EAAA,CAAS;AAAA,MAAA,EAAA,CAE/D;AAAA,IAAA;AAAA,EAAA;AAIR;"}
@@ -0,0 +1 @@
1
+ ._modal-footer_1yi4a_2{display:flex;flex-direction:column;flex-shrink:0;align-items:stretch}._modal-footer--divider_1yi4a_8{border-top:1px solid rgba(var(--center-channel-color-rgb),.12)}._modal-footer--no-divider_1yi4a_11 ._modal-footer__content_1yi4a_11{padding-top:0}._modal-footer__content_1yi4a_11{display:flex;align-items:center;justify-content:flex-end;gap:var(--spacing-xs);width:100%;padding:var(--spacing-xxl) var(--spacing-xxxl)}._modal-footer__leading_1yi4a_22{flex:1 1 auto;min-width:0;display:flex;align-items:center;font-family:var(--font-family-body);font-size:var(--font-size-75);font-weight:var(--font-weight-semibold);line-height:var(--line-height-75);color:rgba(var(--center-channel-color-rgb),.64)}._modal-footer__actions_1yi4a_33{display:flex;flex-shrink:0;align-items:center;justify-content:flex-end;gap:var(--spacing-xs)}._modal-footer--type-2-actions-separated_1yi4a_40 ._modal-footer__content_1yi4a_11{justify-content:space-between}._modal-footer--type-2-actions-separated_1yi4a_40 ._modal-footer__actions_1yi4a_33:only-child{flex:1 1 auto;justify-content:space-between}._modal-footer--type-pagination_1yi4a_47 ._modal-footer__content_1yi4a_11,._modal-footer--type-stepped-progress_1yi4a_47 ._modal-footer__content_1yi4a_11{justify-content:space-between}._modal-footer--type-spacer-small_1yi4a_50{padding:var(--spacing-l);min-height:calc(var(--spacing-l) * 2)}._modal-footer--type-spacer-large_1yi4a_54{padding:var(--spacing-xxl);min-height:calc(var(--spacing-xxl) * 2)}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./ModalFooter.module.css');const o={"modal-footer":"_modal-footer_1yi4a_2","modal-footer--divider":"_modal-footer--divider_1yi4a_8","modal-footer--no-divider":"_modal-footer--no-divider_1yi4a_11","modal-footer__content":"_modal-footer__content_1yi4a_11","modal-footer__leading":"_modal-footer__leading_1yi4a_22","modal-footer__actions":"_modal-footer__actions_1yi4a_33","modal-footer--type-2-actions-separated":"_modal-footer--type-2-actions-separated_1yi4a_40","modal-footer--type-pagination":"_modal-footer--type-pagination_1yi4a_47","modal-footer--type-stepped-progress":"_modal-footer--type-stepped-progress_1yi4a_47","modal-footer--type-spacer-small":"_modal-footer--type-spacer-small_1yi4a_50","modal-footer--type-spacer-large":"_modal-footer--type-spacer-large_1yi4a_54"};exports.default=o;
2
+ //# sourceMappingURL=ModalFooter.module.scss.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalFooter.module.scss.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,17 @@
1
+ import './ModalFooter.module.css';const o = {
2
+ "modal-footer": "_modal-footer_1yi4a_2",
3
+ "modal-footer--divider": "_modal-footer--divider_1yi4a_8",
4
+ "modal-footer--no-divider": "_modal-footer--no-divider_1yi4a_11",
5
+ "modal-footer__content": "_modal-footer__content_1yi4a_11",
6
+ "modal-footer__leading": "_modal-footer__leading_1yi4a_22",
7
+ "modal-footer__actions": "_modal-footer__actions_1yi4a_33",
8
+ "modal-footer--type-2-actions-separated": "_modal-footer--type-2-actions-separated_1yi4a_40",
9
+ "modal-footer--type-pagination": "_modal-footer--type-pagination_1yi4a_47",
10
+ "modal-footer--type-stepped-progress": "_modal-footer--type-stepped-progress_1yi4a_47",
11
+ "modal-footer--type-spacer-small": "_modal-footer--type-spacer-small_1yi4a_50",
12
+ "modal-footer--type-spacer-large": "_modal-footer--type-spacer-large_1yi4a_54"
13
+ };
14
+ export {
15
+ o as default
16
+ };
17
+ //# sourceMappingURL=ModalFooter.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalFooter.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./ModalFooter.cjs");exports.ModalFooter=e.default;
2
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ export { default as ModalFooter } from './ModalFooter';
2
+ export type { ModalFooterProps, ModalFooterType } from './ModalFooter';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/modal-footer/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,eAAe,CAAC;AACvD,YAAY,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { default as e } from "./ModalFooter.js";
2
+ export {
3
+ e as ModalFooter
4
+ };
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react/jsx-runtime"),__b=require("@mattermost/compass-icons/components/close.js"),b=__b?.default??__b,__N=require("@mattermost/compass-icons/components/arrow-left.js"),N=__N?.default??__N,c=require("../icon/Icon.cjs"),n=require("../icon-button/IconButton.cjs"),a=require("./ModalHeader.module.scss.cjs");function v({className:u="",title:l,subtitle:d,subtitlePlacement:h="below",hideTitle:o=!1,titleId:s,showBackButton:m=!1,onBack:f,onClose:_,divider:j=!0,headerAction:x}){const r=!o&&l!=null,i=r&&d!=null,t=h==="beside"&&i;return e.jsx("div",{className:[a.default["modal-header"],!j&&a.default["modal-header--no-divider"],o&&a.default["modal-header--close-only"],u].filter(Boolean).join(" "),children:e.jsxs("div",{className:a.default["modal-header__content"],children:[r?e.jsxs("div",{className:a.default["modal-header__titles"],children:[e.jsxs("div",{className:a.default["modal-header__primary"],children:[m&&e.jsx(n.default,{"aria-label":"Go back",icon:e.jsx(c.default,{glyph:e.jsx(N,{}),size:"20"}),onClick:f}),e.jsx("h2",{id:s,className:a.default["modal-header__title"],children:l}),t&&e.jsxs("div",{className:a.default["modal-header__subtitle-beside"],children:[e.jsx("span",{className:a.default["modal-header__subtitle-divider"],"aria-hidden":!0}),e.jsx("p",{className:a.default["modal-header__subtitle"],children:d})]})]}),i&&!t&&e.jsx("p",{className:a.default["modal-header__subtitle"],children:d})]}):s!=null&&l!=null?e.jsx("h2",{id:s,className:a.default["modal-header__title-sr"],children:l}):null,e.jsxs("div",{className:a.default["modal-header__actions"],children:[x,e.jsx(n.default,{"aria-label":"Close",className:a.default["modal-header__close"],icon:e.jsx(c.default,{glyph:e.jsx(b,{}),size:"20"}),onClick:_})]})]})})}exports.default=v;
2
+ //# sourceMappingURL=ModalHeader.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalHeader.cjs","sources":["../../../src/components/modal-header/ModalHeader.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport ArrowLeftIcon from '@mattermost/compass-icons/components/arrow-left';\nimport Icon from '@/components/icon/Icon';\nimport IconButton from '@/components/icon-button/IconButton';\nimport styles from './ModalHeader.module.scss';\n\nexport type ModalSubtitlePlacement = 'below' | 'beside';\n\nexport interface ModalHeaderProps {\n className?: string;\n /** Heading text. Omit (with `hideTitle`) for close-only headers. */\n title?: ReactNode;\n /** Optional secondary text — placement controlled by `subtitlePlacement`. */\n subtitle?: ReactNode;\n /**\n * Where the subtitle sits relative to the title.\n * Figma: Subtitle = Below | Beside. Default: `below`.\n */\n subtitlePlacement?: ModalSubtitlePlacement;\n /** When true, title is visually hidden (close-only chrome; keep `title`/`titleId` for a11y). */\n hideTitle?: boolean;\n /** id for the title element — pair with dialog `aria-labelledby`. */\n titleId?: string;\n /** Back arrow before the title. */\n showBackButton?: boolean;\n onBack?: () => void;\n /** Called when the × is clicked. */\n onClose?: () => void;\n /** Show bottom border. Figma: Divider = On. Default: true. */\n divider?: boolean;\n /**\n * Optional control before close (Figma Controls = Button / Small Input / …).\n * Host owns the Button, TextInput, etc.\n */\n headerAction?: ReactNode;\n}\n\n/**\n * Modal Header — title row, optional subtitle (below or beside), optional back,\n * optional header action, and close. Compose into `Modal` or use standalone.\n *\n * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=789-15921\n */\nexport default function ModalHeader({\n className = '',\n title,\n subtitle,\n subtitlePlacement = 'below',\n hideTitle = false,\n titleId,\n showBackButton = false,\n onBack,\n onClose,\n divider = true,\n headerAction,\n}: ModalHeaderProps) {\n const showTitleBlock = !hideTitle && title != null;\n const showSubtitle = showTitleBlock && subtitle != null;\n const beside = subtitlePlacement === 'beside' && showSubtitle;\n\n return (\n <div\n className={[\n styles['modal-header'],\n !divider && styles['modal-header--no-divider'],\n hideTitle && styles['modal-header--close-only'],\n className,\n ]\n .filter(Boolean)\n .join(' ')}\n >\n <div className={styles['modal-header__content']}>\n {showTitleBlock ? (\n <div className={styles['modal-header__titles']}>\n <div className={styles['modal-header__primary']}>\n {showBackButton && (\n <IconButton\n aria-label=\"Go back\"\n icon={<Icon glyph={<ArrowLeftIcon />} size=\"20\" />}\n onClick={onBack}\n />\n )}\n <h2 id={titleId} className={styles['modal-header__title']}>\n {title}\n </h2>\n {beside && (\n <div className={styles['modal-header__subtitle-beside']}>\n <span\n className={styles['modal-header__subtitle-divider']}\n aria-hidden\n />\n <p className={styles['modal-header__subtitle']}>{subtitle}</p>\n </div>\n )}\n </div>\n {showSubtitle && !beside && (\n <p className={styles['modal-header__subtitle']}>{subtitle}</p>\n )}\n </div>\n ) : titleId != null && title != null ? (\n <h2 id={titleId} className={styles['modal-header__title-sr']}>\n {title}\n </h2>\n ) : null}\n\n <div className={styles['modal-header__actions']}>\n {headerAction}\n <IconButton\n aria-label=\"Close\"\n className={styles['modal-header__close']}\n icon={<Icon glyph={<CloseIcon />} size=\"20\" />}\n onClick={onClose}\n />\n </div>\n </div>\n </div>\n );\n}\n"],"names":["ModalHeader","className","title","subtitle","subtitlePlacement","hideTitle","titleId","showBackButton","onBack","onClose","divider","headerAction","showTitleBlock","showSubtitle","beside","jsx","styles","jsxs","IconButton","Icon","ArrowLeftIcon","CloseIcon"],"mappings":"yXA4CA,SAAwBA,EAAY,CAClC,UAAAC,EAAY,GACZ,MAAAC,EACA,SAAAC,EACA,kBAAAC,EAAoB,QACpB,UAAAC,EAAY,GACZ,QAAAC,EACA,eAAAC,EAAiB,GACjB,OAAAC,EACA,QAAAC,EACA,QAAAC,EAAU,GACV,aAAAC,CACF,EAAqB,CACnB,MAAMC,EAAiB,CAACP,GAAaH,GAAS,KACxCW,EAAeD,GAAkBT,GAAY,KAC7CW,EAASV,IAAsB,UAAYS,EAEjD,OACEE,EAAAA,IAAC,MAAA,CACC,UAAW,CACTC,EAAAA,QAAO,cAAc,EACrB,CAACN,GAAWM,EAAAA,QAAO,0BAA0B,EAC7CX,GAAaW,EAAAA,QAAO,0BAA0B,EAC9Cf,CAAA,EAEC,OAAO,OAAO,EACd,KAAK,GAAG,EAEX,SAAAgB,EAAAA,KAAC,MAAA,CAAI,UAAWD,UAAO,uBAAuB,EAC3C,SAAA,CAAAJ,EACCK,EAAAA,KAAC,MAAA,CAAI,UAAWD,UAAO,sBAAsB,EAC3C,SAAA,CAAAC,EAAAA,KAAC,MAAA,CAAI,UAAWD,EAAAA,QAAO,uBAAuB,EAC3C,SAAA,CAAAT,GACCQ,EAAAA,IAACG,EAAAA,QAAA,CACC,aAAW,UACX,WAAOC,UAAA,CAAK,YAAQC,EAAA,EAAc,EAAI,KAAK,KAAK,EAChD,QAASZ,CAAA,CAAA,EAGbO,EAAAA,IAAC,MAAG,GAAIT,EAAS,UAAWU,EAAAA,QAAO,qBAAqB,EACrD,SAAAd,EACH,EACCY,GACCG,EAAAA,KAAC,MAAA,CAAI,UAAWD,UAAO,+BAA+B,EACpD,SAAA,CAAAD,EAAAA,IAAC,OAAA,CACC,UAAWC,EAAAA,QAAO,gCAAgC,EAClD,cAAW,EAAA,CAAA,QAEZ,IAAA,CAAE,UAAWA,EAAAA,QAAO,wBAAwB,EAAI,SAAAb,CAAA,CAAS,CAAA,CAAA,CAC5D,CAAA,EAEJ,EACCU,GAAgB,CAACC,GAChBC,EAAAA,IAAC,KAAE,UAAWC,EAAAA,QAAO,wBAAwB,EAAI,SAAAb,CAAA,CAAS,CAAA,CAAA,CAE9D,EACEG,GAAW,MAAQJ,GAAS,KAC9Ba,EAAAA,IAAC,KAAA,CAAG,GAAIT,EAAS,UAAWU,UAAO,wBAAwB,EACxD,WACH,EACE,KAEJC,EAAAA,KAAC,MAAA,CAAI,UAAWD,EAAAA,QAAO,uBAAuB,EAC3C,SAAA,CAAAL,EACDI,EAAAA,IAACG,EAAAA,QAAA,CACC,aAAW,QACX,UAAWF,EAAAA,QAAO,qBAAqB,EACvC,WAAOG,UAAA,CAAK,YAAQE,EAAA,EAAU,EAAI,KAAK,KAAK,EAC5C,QAASZ,CAAA,CAAA,CACX,CAAA,CACF,CAAA,CAAA,CACF,CAAA,CAAA,CAGN"}
@@ -0,0 +1,38 @@
1
+ import { ReactNode } from 'react';
2
+ export type ModalSubtitlePlacement = 'below' | 'beside';
3
+ export interface ModalHeaderProps {
4
+ className?: string;
5
+ /** Heading text. Omit (with `hideTitle`) for close-only headers. */
6
+ title?: ReactNode;
7
+ /** Optional secondary text — placement controlled by `subtitlePlacement`. */
8
+ subtitle?: ReactNode;
9
+ /**
10
+ * Where the subtitle sits relative to the title.
11
+ * Figma: Subtitle = Below | Beside. Default: `below`.
12
+ */
13
+ subtitlePlacement?: ModalSubtitlePlacement;
14
+ /** When true, title is visually hidden (close-only chrome; keep `title`/`titleId` for a11y). */
15
+ hideTitle?: boolean;
16
+ /** id for the title element — pair with dialog `aria-labelledby`. */
17
+ titleId?: string;
18
+ /** Back arrow before the title. */
19
+ showBackButton?: boolean;
20
+ onBack?: () => void;
21
+ /** Called when the × is clicked. */
22
+ onClose?: () => void;
23
+ /** Show bottom border. Figma: Divider = On. Default: true. */
24
+ divider?: boolean;
25
+ /**
26
+ * Optional control before close (Figma Controls = Button / Small Input / …).
27
+ * Host owns the Button, TextInput, etc.
28
+ */
29
+ headerAction?: ReactNode;
30
+ }
31
+ /**
32
+ * Modal Header — title row, optional subtitle (below or beside), optional back,
33
+ * optional header action, and close. Compose into `Modal` or use standalone.
34
+ *
35
+ * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=789-15921
36
+ */
37
+ export default function ModalHeader({ className, title, subtitle, subtitlePlacement, hideTitle, titleId, showBackButton, onBack, onClose, divider, headerAction, }: ModalHeaderProps): import("react/jsx-runtime").JSX.Element;
38
+ //# sourceMappingURL=ModalHeader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalHeader.d.ts","sourceRoot":"","sources":["../../../src/components/modal-header/ModalHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOvC,MAAM,MAAM,sBAAsB,GAAG,OAAO,GAAG,QAAQ,CAAC;AAExD,MAAM,WAAW,gBAAgB;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oEAAoE;IACpE,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,6EAA6E;IAC7E,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,sBAAsB,CAAC;IAC3C,gGAAgG;IAChG,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,qEAAqE;IACrE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,mCAAmC;IACnC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,oCAAoC;IACpC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,8DAA8D;IAC9D,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,YAAY,CAAC,EAAE,SAAS,CAAC;CAC1B;AAED;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,SAAc,EACd,KAAK,EACL,QAAQ,EACR,iBAA2B,EAC3B,SAAiB,EACjB,OAAO,EACP,cAAsB,EACtB,MAAM,EACN,OAAO,EACP,OAAc,EACd,YAAY,GACb,EAAE,gBAAgB,2CA8DlB"}
@@ -0,0 +1,74 @@
1
+ import { jsx as a, jsxs as l } from "react/jsx-runtime";
2
+ import __v from "@mattermost/compass-icons/components/close.js";const v=__v&&__v.default?__v.default:__v;
3
+ import __y from "@mattermost/compass-icons/components/arrow-left.js";const y=__y&&__y.default?__y.default:__y;
4
+ import n from "../icon/Icon.js";
5
+ import h from "../icon-button/IconButton.js";
6
+ import e from "./ModalHeader.module.scss.js";
7
+ function g({
8
+ className: t = "",
9
+ title: o,
10
+ subtitle: d,
11
+ subtitlePlacement: _ = "below",
12
+ hideTitle: s = !1,
13
+ titleId: r,
14
+ showBackButton: u = !1,
15
+ onBack: p,
16
+ onClose: f,
17
+ divider: N = !0,
18
+ headerAction: b
19
+ }) {
20
+ const i = !s && o != null, c = i && d != null, m = _ === "beside" && c;
21
+ return /* @__PURE__ */ a(
22
+ "div",
23
+ {
24
+ className: [
25
+ e["modal-header"],
26
+ !N && e["modal-header--no-divider"],
27
+ s && e["modal-header--close-only"],
28
+ t
29
+ ].filter(Boolean).join(" "),
30
+ children: /* @__PURE__ */ l("div", { className: e["modal-header__content"], children: [
31
+ i ? /* @__PURE__ */ l("div", { className: e["modal-header__titles"], children: [
32
+ /* @__PURE__ */ l("div", { className: e["modal-header__primary"], children: [
33
+ u && /* @__PURE__ */ a(
34
+ h,
35
+ {
36
+ "aria-label": "Go back",
37
+ icon: /* @__PURE__ */ a(n, { glyph: /* @__PURE__ */ a(y, {}), size: "20" }),
38
+ onClick: p
39
+ }
40
+ ),
41
+ /* @__PURE__ */ a("h2", { id: r, className: e["modal-header__title"], children: o }),
42
+ m && /* @__PURE__ */ l("div", { className: e["modal-header__subtitle-beside"], children: [
43
+ /* @__PURE__ */ a(
44
+ "span",
45
+ {
46
+ className: e["modal-header__subtitle-divider"],
47
+ "aria-hidden": !0
48
+ }
49
+ ),
50
+ /* @__PURE__ */ a("p", { className: e["modal-header__subtitle"], children: d })
51
+ ] })
52
+ ] }),
53
+ c && !m && /* @__PURE__ */ a("p", { className: e["modal-header__subtitle"], children: d })
54
+ ] }) : r != null && o != null ? /* @__PURE__ */ a("h2", { id: r, className: e["modal-header__title-sr"], children: o }) : null,
55
+ /* @__PURE__ */ l("div", { className: e["modal-header__actions"], children: [
56
+ b,
57
+ /* @__PURE__ */ a(
58
+ h,
59
+ {
60
+ "aria-label": "Close",
61
+ className: e["modal-header__close"],
62
+ icon: /* @__PURE__ */ a(n, { glyph: /* @__PURE__ */ a(v, {}), size: "20" }),
63
+ onClick: f
64
+ }
65
+ )
66
+ ] })
67
+ ] })
68
+ }
69
+ );
70
+ }
71
+ export {
72
+ g as default
73
+ };
74
+ //# sourceMappingURL=ModalHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalHeader.js","sources":["../../../src/components/modal-header/ModalHeader.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport ArrowLeftIcon from '@mattermost/compass-icons/components/arrow-left';\nimport Icon from '@/components/icon/Icon';\nimport IconButton from '@/components/icon-button/IconButton';\nimport styles from './ModalHeader.module.scss';\n\nexport type ModalSubtitlePlacement = 'below' | 'beside';\n\nexport interface ModalHeaderProps {\n className?: string;\n /** Heading text. Omit (with `hideTitle`) for close-only headers. */\n title?: ReactNode;\n /** Optional secondary text — placement controlled by `subtitlePlacement`. */\n subtitle?: ReactNode;\n /**\n * Where the subtitle sits relative to the title.\n * Figma: Subtitle = Below | Beside. Default: `below`.\n */\n subtitlePlacement?: ModalSubtitlePlacement;\n /** When true, title is visually hidden (close-only chrome; keep `title`/`titleId` for a11y). */\n hideTitle?: boolean;\n /** id for the title element — pair with dialog `aria-labelledby`. */\n titleId?: string;\n /** Back arrow before the title. */\n showBackButton?: boolean;\n onBack?: () => void;\n /** Called when the × is clicked. */\n onClose?: () => void;\n /** Show bottom border. Figma: Divider = On. Default: true. */\n divider?: boolean;\n /**\n * Optional control before close (Figma Controls = Button / Small Input / …).\n * Host owns the Button, TextInput, etc.\n */\n headerAction?: ReactNode;\n}\n\n/**\n * Modal Header — title row, optional subtitle (below or beside), optional back,\n * optional header action, and close. Compose into `Modal` or use standalone.\n *\n * @see https://www.figma.com/design/qdm5tKododENqnTvjLovDT/Patterns---Modals?node-id=789-15921\n */\nexport default function ModalHeader({\n className = '',\n title,\n subtitle,\n subtitlePlacement = 'below',\n hideTitle = false,\n titleId,\n showBackButton = false,\n onBack,\n onClose,\n divider = true,\n headerAction,\n}: ModalHeaderProps) {\n const showTitleBlock = !hideTitle && title != null;\n const showSubtitle = showTitleBlock && subtitle != null;\n const beside = subtitlePlacement === 'beside' && showSubtitle;\n\n return (\n <div\n className={[\n styles['modal-header'],\n !divider && styles['modal-header--no-divider'],\n hideTitle && styles['modal-header--close-only'],\n className,\n ]\n .filter(Boolean)\n .join(' ')}\n >\n <div className={styles['modal-header__content']}>\n {showTitleBlock ? (\n <div className={styles['modal-header__titles']}>\n <div className={styles['modal-header__primary']}>\n {showBackButton && (\n <IconButton\n aria-label=\"Go back\"\n icon={<Icon glyph={<ArrowLeftIcon />} size=\"20\" />}\n onClick={onBack}\n />\n )}\n <h2 id={titleId} className={styles['modal-header__title']}>\n {title}\n </h2>\n {beside && (\n <div className={styles['modal-header__subtitle-beside']}>\n <span\n className={styles['modal-header__subtitle-divider']}\n aria-hidden\n />\n <p className={styles['modal-header__subtitle']}>{subtitle}</p>\n </div>\n )}\n </div>\n {showSubtitle && !beside && (\n <p className={styles['modal-header__subtitle']}>{subtitle}</p>\n )}\n </div>\n ) : titleId != null && title != null ? (\n <h2 id={titleId} className={styles['modal-header__title-sr']}>\n {title}\n </h2>\n ) : null}\n\n <div className={styles['modal-header__actions']}>\n {headerAction}\n <IconButton\n aria-label=\"Close\"\n className={styles['modal-header__close']}\n icon={<Icon glyph={<CloseIcon />} size=\"20\" />}\n onClick={onClose}\n />\n </div>\n </div>\n </div>\n );\n}\n"],"names":["ModalHeader","className","title","subtitle","subtitlePlacement","hideTitle","titleId","showBackButton","onBack","onClose","divider","headerAction","showTitleBlock","showSubtitle","beside","jsx","styles","jsxs","IconButton","Icon","ArrowLeftIcon","CloseIcon"],"mappings":";;;;;;AA4CA,SAAwBA,EAAY;AAAA,EAClC,WAAAC,IAAY;AAAA,EACZ,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,mBAAAC,IAAoB;AAAA,EACpB,WAAAC,IAAY;AAAA,EACZ,SAAAC;AAAA,EACA,gBAAAC,IAAiB;AAAA,EACjB,QAAAC;AAAA,EACA,SAAAC;AAAA,EACA,SAAAC,IAAU;AAAA,EACV,cAAAC;AACF,GAAqB;AACnB,QAAMC,IAAiB,CAACP,KAAaH,KAAS,MACxCW,IAAeD,KAAkBT,KAAY,MAC7CW,IAASV,MAAsB,YAAYS;AAEjD,SACE,gBAAAE;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW;AAAA,QACTC,EAAO,cAAc;AAAA,QACrB,CAACN,KAAWM,EAAO,0BAA0B;AAAA,QAC7CX,KAAaW,EAAO,0BAA0B;AAAA,QAC9Cf;AAAA,MAAA,EAEC,OAAO,OAAO,EACd,KAAK,GAAG;AAAA,MAEX,UAAA,gBAAAgB,EAAC,OAAA,EAAI,WAAWD,EAAO,uBAAuB,GAC3C,UAAA;AAAA,QAAAJ,IACC,gBAAAK,EAAC,OAAA,EAAI,WAAWD,EAAO,sBAAsB,GAC3C,UAAA;AAAA,UAAA,gBAAAC,EAAC,OAAA,EAAI,WAAWD,EAAO,uBAAuB,GAC3C,UAAA;AAAA,YAAAT,KACC,gBAAAQ;AAAA,cAACG;AAAA,cAAA;AAAA,gBACC,cAAW;AAAA,gBACX,wBAAOC,GAAA,EAAK,yBAAQC,GAAA,EAAc,GAAI,MAAK,MAAK;AAAA,gBAChD,SAASZ;AAAA,cAAA;AAAA,YAAA;AAAA,YAGb,gBAAAO,EAAC,QAAG,IAAIT,GAAS,WAAWU,EAAO,qBAAqB,GACrD,UAAAd,GACH;AAAA,YACCY,KACC,gBAAAG,EAAC,OAAA,EAAI,WAAWD,EAAO,+BAA+B,GACpD,UAAA;AAAA,cAAA,gBAAAD;AAAA,gBAAC;AAAA,gBAAA;AAAA,kBACC,WAAWC,EAAO,gCAAgC;AAAA,kBAClD,eAAW;AAAA,gBAAA;AAAA,cAAA;AAAA,gCAEZ,KAAA,EAAE,WAAWA,EAAO,wBAAwB,GAAI,UAAAb,EAAA,CAAS;AAAA,YAAA,EAAA,CAC5D;AAAA,UAAA,GAEJ;AAAA,UACCU,KAAgB,CAACC,KAChB,gBAAAC,EAAC,OAAE,WAAWC,EAAO,wBAAwB,GAAI,UAAAb,EAAA,CAAS;AAAA,QAAA,EAAA,CAE9D,IACEG,KAAW,QAAQJ,KAAS,OAC9B,gBAAAa,EAAC,MAAA,EAAG,IAAIT,GAAS,WAAWU,EAAO,wBAAwB,GACxD,aACH,IACE;AAAA,QAEJ,gBAAAC,EAAC,OAAA,EAAI,WAAWD,EAAO,uBAAuB,GAC3C,UAAA;AAAA,UAAAL;AAAA,UACD,gBAAAI;AAAA,YAACG;AAAA,YAAA;AAAA,cACC,cAAW;AAAA,cACX,WAAWF,EAAO,qBAAqB;AAAA,cACvC,wBAAOG,GAAA,EAAK,yBAAQE,GAAA,EAAU,GAAI,MAAK,MAAK;AAAA,cAC5C,SAASZ;AAAA,YAAA;AAAA,UAAA;AAAA,QACX,EAAA,CACF;AAAA,MAAA,EAAA,CACF;AAAA,IAAA;AAAA,EAAA;AAGN;"}
@@ -0,0 +1 @@
1
+ ._modal-header_1aii1_2{display:flex;flex-direction:column;flex-shrink:0;border-bottom:1px solid rgba(var(--center-channel-color-rgb),.12)}._modal-header--no-divider_1aii1_8{border-bottom:none}._modal-header--no-divider_1aii1_8 ._modal-header__content_1aii1_11{padding-bottom:0}._modal-header--close-only_1aii1_14 ._modal-header__content_1aii1_11{justify-content:flex-end}._modal-header__content_1aii1_11{display:flex;align-items:flex-start;gap:10px;width:100%;padding:var(--spacing-xxl) var(--spacing-xxxl)}._modal-header__titles_1aii1_24{display:flex;flex:1 1 auto;flex-direction:column;align-items:flex-start;gap:var(--spacing-m);min-width:0;padding:var(--spacing-xxxxs) 0}._modal-header__primary_1aii1_33{display:flex;align-items:center;gap:var(--spacing-m);width:100%;min-height:var(--line-height-500)}._modal-header__title_1aii1_24{flex:1 1 auto;min-width:0;margin:0;font-family:var(--font-family-heading);font-size:var(--font-size-500);font-weight:var(--font-weight-semibold);line-height:var(--line-height-500);color:var(--center-channel-color)}._modal-header__title-sr_1aii1_50{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}._modal-header__subtitle_1aii1_61{margin:0;font-family:var(--font-family-body);font-size:var(--font-size-75);font-weight:var(--font-weight-regular);line-height:var(--line-height-75);color:rgba(var(--center-channel-color-rgb),.72)}._modal-header__subtitle-beside_1aii1_69{display:flex;flex-shrink:0;align-items:center;gap:var(--spacing-xs)}._modal-header__subtitle-beside_1aii1_69 ._modal-header__subtitle_1aii1_61{line-height:var(--line-height-200);white-space:nowrap}._modal-header__subtitle-divider_1aii1_79{display:block;width:1px;height:var(--line-height-500);background-color:rgba(var(--center-channel-color-rgb),.16)}._modal-header__actions_1aii1_85{display:flex;flex-shrink:0;align-items:center;justify-content:flex-end;gap:7px;height:28px}._modal-header__close_1aii1_93{margin-right:-12px;margin-top:-6px;margin-bottom:-6px}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./ModalHeader.module.css');const e={"modal-header":"_modal-header_1aii1_2","modal-header--no-divider":"_modal-header--no-divider_1aii1_8","modal-header__content":"_modal-header__content_1aii1_11","modal-header--close-only":"_modal-header--close-only_1aii1_14","modal-header__titles":"_modal-header__titles_1aii1_24","modal-header__primary":"_modal-header__primary_1aii1_33","modal-header__title":"_modal-header__title_1aii1_24","modal-header__title-sr":"_modal-header__title-sr_1aii1_50","modal-header__subtitle":"_modal-header__subtitle_1aii1_61","modal-header__subtitle-beside":"_modal-header__subtitle-beside_1aii1_69","modal-header__subtitle-divider":"_modal-header__subtitle-divider_1aii1_79","modal-header__actions":"_modal-header__actions_1aii1_85","modal-header__close":"_modal-header__close_1aii1_93"};exports.default=e;
2
+ //# sourceMappingURL=ModalHeader.module.scss.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalHeader.module.scss.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,19 @@
1
+ import './ModalHeader.module.css';const e = {
2
+ "modal-header": "_modal-header_1aii1_2",
3
+ "modal-header--no-divider": "_modal-header--no-divider_1aii1_8",
4
+ "modal-header__content": "_modal-header__content_1aii1_11",
5
+ "modal-header--close-only": "_modal-header--close-only_1aii1_14",
6
+ "modal-header__titles": "_modal-header__titles_1aii1_24",
7
+ "modal-header__primary": "_modal-header__primary_1aii1_33",
8
+ "modal-header__title": "_modal-header__title_1aii1_24",
9
+ "modal-header__title-sr": "_modal-header__title-sr_1aii1_50",
10
+ "modal-header__subtitle": "_modal-header__subtitle_1aii1_61",
11
+ "modal-header__subtitle-beside": "_modal-header__subtitle-beside_1aii1_69",
12
+ "modal-header__subtitle-divider": "_modal-header__subtitle-divider_1aii1_79",
13
+ "modal-header__actions": "_modal-header__actions_1aii1_85",
14
+ "modal-header__close": "_modal-header__close_1aii1_93"
15
+ };
16
+ export {
17
+ e as default
18
+ };
19
+ //# sourceMappingURL=ModalHeader.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ModalHeader.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./ModalHeader.cjs");exports.ModalHeader=e.default;
2
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ export { default as ModalHeader } from './ModalHeader';
2
+ export type { ModalHeaderProps, ModalSubtitlePlacement } from './ModalHeader';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/modal-header/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,eAAe,CAAC;AACvD,YAAY,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { default as d } from "./ModalHeader.js";
2
+ export {
3
+ d as ModalHeader
4
+ };
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1 +1 @@
1
- {"version":3,"file":"PopoverNotice.cjs","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport InformationOutlineIcon from '@mattermost/compass-icons/components/information-outline';\nimport CheckCircleOutlineIcon from '@mattermost/compass-icons/components/check-circle-outline';\nimport AlertCircleOutlineIcon from '@mattermost/compass-icons/components/alert-circle-outline';\nimport AlertOutlineIcon from '@mattermost/compass-icons/components/alert-outline';\nimport Button from '@/components/button/Button';\nimport Checkbox from '@/components/checkbox/Checkbox';\nimport IconButton from '@/components/icon-button/IconButton';\nimport Icon from '@/components/icon/Icon';\nimport styles from './PopoverNotice.module.scss';\n\nexport type PopoverNoticeVariant = 'info' | 'success' | 'warning' | 'danger';\n\nexport interface PopoverNoticeAction {\n label: string;\n onClick?: () => void;\n emphasis?: 'primary' | 'tertiary';\n}\n\nexport interface PopoverNoticeProps {\n /** Popover title text. */\n title: string;\n /** Body content. */\n children: ReactNode;\n /**\n * Semantic variant — sets the icon and its color automatically.\n * Ignored if `icon` is also provided.\n */\n variant?: PopoverNoticeVariant;\n /** Optional icon shown to the left of the title. Overrides variant icon. */\n icon?: ReactNode;\n /** Action buttons rendered below the body. */\n actions?: PopoverNoticeAction[];\n /** When true, shows a \"Don't show this again\" checkbox. */\n showCheckbox?: boolean;\n /** Checkbox label override. */\n checkboxLabel?: string;\n /** Callback when close button is clicked. */\n onClose?: () => void;\n /** Optional CSS class name. */\n className?: string;\n}\n\nconst VARIANT_ICONS: Record<PopoverNoticeVariant, ReactNode> = {\n info: <Icon size=\"20\" glyph={<InformationOutlineIcon />} />,\n success: <Icon size=\"20\" glyph={<CheckCircleOutlineIcon />} />,\n warning: <Icon size=\"20\" glyph={<AlertCircleOutlineIcon />} />,\n danger: <Icon size=\"20\" glyph={<AlertOutlineIcon />} />,\n};\n\nconst VARIANT_ICON_CLASS: Record<PopoverNoticeVariant, string> = {\n info: styles['popover-notice__icon--info'],\n success: styles['popover-notice__icon--success'],\n warning: styles['popover-notice__icon--warning'],\n danger: styles['popover-notice__icon--danger'],\n};\n\n/**\n * Popover Notice is a small overlay card that surfaces a transient message — a tip, a\n * confirmation, a warning — without taking over the screen. Think of it as a [Section\n * Notice](/components/section-notice) that floats: shorter, dismissable, and gone in five\n * seconds unless the user engages.\n */\nexport default function PopoverNotice({\n title,\n children,\n variant,\n icon,\n actions,\n showCheckbox = false,\n checkboxLabel = \"Don't show this confirmation again\",\n onClose,\n className = '',\n}: PopoverNoticeProps) {\n const rootClass = [styles['popover-notice'], className]\n .filter(Boolean)\n .join(' ');\n\n const resolvedIcon = icon ?? (variant ? VARIANT_ICONS[variant] : null);\n const iconColorClass = !icon && variant ? VARIANT_ICON_CLASS[variant] : '';\n\n return (\n <div className={rootClass}>\n <div className={styles['popover-notice__content']}>\n {resolvedIcon != null && (\n <div\n className={[styles['popover-notice__icon'], iconColorClass]\n .filter(Boolean)\n .join(' ')}\n aria-hidden\n >\n {resolvedIcon}\n </div>\n )}\n\n <div className={styles['popover-notice__body']}>\n <div className={styles['popover-notice__title-row']}>\n <span className={styles['popover-notice__title']}>{title}</span>\n </div>\n\n <div className={styles['popover-notice__description']}>\n {children}\n </div>\n\n {actions && actions.length > 0 && (\n <div className={styles['popover-notice__actions']}>\n {actions.map((action, i) => (\n <Button\n key={i}\n emphasis={action.emphasis ?? 'primary'}\n size=\"small\"\n onClick={action.onClick}\n >\n {action.label}\n </Button>\n ))}\n </div>\n )}\n\n {showCheckbox && <Checkbox size=\"medium\">{checkboxLabel}</Checkbox>}\n </div>\n </div>\n\n {onClose && (\n <IconButton\n className={styles['popover-notice__close']}\n aria-label=\"Close\"\n size=\"small\"\n icon={<Icon size=\"16\" glyph={<CloseIcon />} />}\n onClick={onClose}\n />\n )}\n </div>\n );\n}\n"],"names":["VARIANT_ICONS","Icon","jsx","InformationOutlineIcon","CheckCircleOutlineIcon","AlertCircleOutlineIcon","AlertOutlineIcon","VARIANT_ICON_CLASS","styles","PopoverNotice","title","children","variant","icon","actions","showCheckbox","checkboxLabel","onClose","className","rootClass","resolvedIcon","iconColorClass","jsxs","action","i","Button","Checkbox","IconButton","CloseIcon"],"mappings":"0pBA4CMA,EAAyD,CAC7D,WAAOC,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACC,IAAuB,EAAI,EACzD,cAAUF,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACE,IAAuB,EAAI,EAC5D,cAAUH,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACG,IAAuB,EAAI,EAC5D,aAASJ,EAAAA,QAAA,CAAK,KAAK,KAAK,MAAOC,EAAAA,IAACI,IAAiB,CAAA,CAAI,CACvD,EAEMC,EAA2D,CAC/D,KAAMC,EAAAA,QAAO,4BAA4B,EACzC,QAASA,EAAAA,QAAO,+BAA+B,EAC/C,QAASA,EAAAA,QAAO,+BAA+B,EAC/C,OAAQA,EAAAA,QAAO,8BAA8B,CAC/C,EAQA,SAAwBC,EAAc,CACpC,MAAAC,EACA,SAAAC,EACA,QAAAC,EACA,KAAAC,EACA,QAAAC,EACA,aAAAC,EAAe,GACf,cAAAC,EAAgB,qCAChB,QAAAC,EACA,UAAAC,EAAY,EACd,EAAuB,CACrB,MAAMC,EAAY,CAACX,UAAO,gBAAgB,EAAGU,CAAS,EACnD,OAAO,OAAO,EACd,KAAK,GAAG,EAELE,EAAeP,IAASD,EAAUZ,EAAcY,CAAO,EAAI,MAC3DS,EAAiB,CAACR,GAAQD,EAAUL,EAAmBK,CAAO,EAAI,GAExE,OACEU,EAAAA,KAAC,MAAA,CAAI,UAAWH,EACd,SAAA,CAAAG,EAAAA,KAAC,MAAA,CAAI,UAAWd,EAAAA,QAAO,yBAAyB,EAC7C,SAAA,CAAAY,GAAgB,MACflB,EAAAA,IAAC,MAAA,CACC,UAAW,CAACM,UAAO,sBAAsB,EAAGa,CAAc,EACvD,OAAO,OAAO,EACd,KAAK,GAAG,EACX,cAAW,GAEV,SAAAD,CAAA,CAAA,EAILE,EAAAA,KAAC,MAAA,CAAI,UAAWd,EAAAA,QAAO,sBAAsB,EAC3C,SAAA,CAAAN,EAAAA,IAAC,MAAA,CAAI,UAAWM,EAAAA,QAAO,2BAA2B,EAChD,SAAAN,EAAAA,IAAC,OAAA,CAAK,UAAWM,EAAAA,QAAO,uBAAuB,EAAI,SAAAE,CAAA,CAAM,EAC3D,QAEC,MAAA,CAAI,UAAWF,EAAAA,QAAO,6BAA6B,EACjD,SAAAG,EACH,EAECG,GAAWA,EAAQ,OAAS,SAC1B,MAAA,CAAI,UAAWN,EAAAA,QAAO,yBAAyB,EAC7C,SAAAM,EAAQ,IAAI,CAACS,EAAQC,IACpBtB,EAAAA,IAACuB,EAAAA,QAAA,CAEC,SAAUF,EAAO,UAAY,UAC7B,KAAK,QACL,QAASA,EAAO,QAEf,SAAAA,EAAO,KAAA,EALHC,CAAA,CAOR,EACH,EAGDT,GAAgBb,EAAAA,IAACwB,UAAA,CAAS,KAAK,SAAU,SAAAV,CAAA,CAAc,CAAA,CAAA,CAC1D,CAAA,EACF,EAECC,GACCf,EAAAA,IAACyB,EAAAA,QAAA,CACC,UAAWnB,EAAAA,QAAO,uBAAuB,EACzC,aAAW,QACX,KAAK,QACL,WAAOP,UAAA,CAAK,KAAK,KAAK,MAAOC,MAAC0B,IAAU,EAAI,EAC5C,QAASX,CAAA,CAAA,CACX,EAEJ,CAEJ"}
1
+ {"version":3,"file":"PopoverNotice.cjs","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport InformationOutlineIcon from '@mattermost/compass-icons/components/information-outline';\nimport CheckCircleOutlineIcon from '@mattermost/compass-icons/components/check-circle-outline';\nimport AlertCircleOutlineIcon from '@mattermost/compass-icons/components/alert-circle-outline';\nimport AlertOutlineIcon from '@mattermost/compass-icons/components/alert-outline';\nimport Button from '@/components/button/Button';\nimport Checkbox from '@/components/checkbox/Checkbox';\nimport IconButton from '@/components/icon-button/IconButton';\nimport Icon from '@/components/icon/Icon';\nimport styles from './PopoverNotice.module.scss';\n\nexport type PopoverNoticeVariant = 'info' | 'success' | 'warning' | 'danger';\n\nexport interface PopoverNoticeAction {\n label: string;\n onClick?: () => void;\n emphasis?: 'primary' | 'tertiary';\n}\n\nexport interface PopoverNoticeProps {\n /** Popover title text. */\n title: string;\n /** Body content. */\n children: ReactNode;\n /**\n * Semantic variant — sets the icon and its color automatically.\n * Ignored if `icon` is also provided.\n */\n variant?: PopoverNoticeVariant;\n /** Optional icon shown to the left of the title. Overrides the variant icon. Pass `<Icon glyph={<SomeIcon />} size=\"20\" />` — the slot does not resize raw SVG children. */\n icon?: ReactNode;\n /** Action buttons rendered below the body. */\n actions?: PopoverNoticeAction[];\n /** When true, shows a \"Don't show this again\" checkbox. */\n showCheckbox?: boolean;\n /** Checkbox label override. */\n checkboxLabel?: string;\n /** Callback when close button is clicked. */\n onClose?: () => void;\n /** Optional CSS class name. */\n className?: string;\n}\n\nconst VARIANT_ICONS: Record<PopoverNoticeVariant, ReactNode> = {\n info: <Icon size=\"20\" glyph={<InformationOutlineIcon />} />,\n success: <Icon size=\"20\" glyph={<CheckCircleOutlineIcon />} />,\n warning: <Icon size=\"20\" glyph={<AlertCircleOutlineIcon />} />,\n danger: <Icon size=\"20\" glyph={<AlertOutlineIcon />} />,\n};\n\nconst VARIANT_ICON_CLASS: Record<PopoverNoticeVariant, string> = {\n info: styles['popover-notice__icon--info'],\n success: styles['popover-notice__icon--success'],\n warning: styles['popover-notice__icon--warning'],\n danger: styles['popover-notice__icon--danger'],\n};\n\n/**\n * Popover Notice is a small overlay card that surfaces a transient message — a tip, a\n * confirmation, a warning — without taking over the screen. Think of it as a [Section\n * Notice](/components/section-notice) that floats: shorter, dismissable, and gone in five\n * seconds unless the user engages.\n */\nexport default function PopoverNotice({\n title,\n children,\n variant,\n icon,\n actions,\n showCheckbox = false,\n checkboxLabel = \"Don't show this confirmation again\",\n onClose,\n className = '',\n}: PopoverNoticeProps) {\n const rootClass = [styles['popover-notice'], className]\n .filter(Boolean)\n .join(' ');\n\n const resolvedIcon = icon ?? (variant ? VARIANT_ICONS[variant] : null);\n const iconColorClass = !icon && variant ? VARIANT_ICON_CLASS[variant] : '';\n\n return (\n <div className={rootClass}>\n <div className={styles['popover-notice__content']}>\n {resolvedIcon != null && (\n <div\n className={[styles['popover-notice__icon'], iconColorClass]\n .filter(Boolean)\n .join(' ')}\n aria-hidden\n >\n {resolvedIcon}\n </div>\n )}\n\n <div className={styles['popover-notice__body']}>\n <div className={styles['popover-notice__title-row']}>\n <span className={styles['popover-notice__title']}>{title}</span>\n </div>\n\n <div className={styles['popover-notice__description']}>\n {children}\n </div>\n\n {actions && actions.length > 0 && (\n <div className={styles['popover-notice__actions']}>\n {actions.map((action, i) => (\n <Button\n key={i}\n emphasis={action.emphasis ?? 'primary'}\n size=\"small\"\n onClick={action.onClick}\n >\n {action.label}\n </Button>\n ))}\n </div>\n )}\n\n {showCheckbox && <Checkbox size=\"medium\">{checkboxLabel}</Checkbox>}\n </div>\n </div>\n\n {onClose && (\n <IconButton\n className={styles['popover-notice__close']}\n aria-label=\"Close\"\n size=\"small\"\n icon={<Icon size=\"16\" glyph={<CloseIcon />} />}\n onClick={onClose}\n />\n )}\n </div>\n );\n}\n"],"names":["VARIANT_ICONS","Icon","jsx","InformationOutlineIcon","CheckCircleOutlineIcon","AlertCircleOutlineIcon","AlertOutlineIcon","VARIANT_ICON_CLASS","styles","PopoverNotice","title","children","variant","icon","actions","showCheckbox","checkboxLabel","onClose","className","rootClass","resolvedIcon","iconColorClass","jsxs","action","i","Button","Checkbox","IconButton","CloseIcon"],"mappings":"0pBA4CMA,EAAyD,CAC7D,WAAOC,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACC,IAAuB,EAAI,EACzD,cAAUF,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACE,IAAuB,EAAI,EAC5D,cAAUH,UAAA,CAAK,KAAK,KAAK,MAAOC,MAACG,IAAuB,EAAI,EAC5D,aAASJ,EAAAA,QAAA,CAAK,KAAK,KAAK,MAAOC,EAAAA,IAACI,IAAiB,CAAA,CAAI,CACvD,EAEMC,EAA2D,CAC/D,KAAMC,EAAAA,QAAO,4BAA4B,EACzC,QAASA,EAAAA,QAAO,+BAA+B,EAC/C,QAASA,EAAAA,QAAO,+BAA+B,EAC/C,OAAQA,EAAAA,QAAO,8BAA8B,CAC/C,EAQA,SAAwBC,EAAc,CACpC,MAAAC,EACA,SAAAC,EACA,QAAAC,EACA,KAAAC,EACA,QAAAC,EACA,aAAAC,EAAe,GACf,cAAAC,EAAgB,qCAChB,QAAAC,EACA,UAAAC,EAAY,EACd,EAAuB,CACrB,MAAMC,EAAY,CAACX,UAAO,gBAAgB,EAAGU,CAAS,EACnD,OAAO,OAAO,EACd,KAAK,GAAG,EAELE,EAAeP,IAASD,EAAUZ,EAAcY,CAAO,EAAI,MAC3DS,EAAiB,CAACR,GAAQD,EAAUL,EAAmBK,CAAO,EAAI,GAExE,OACEU,EAAAA,KAAC,MAAA,CAAI,UAAWH,EACd,SAAA,CAAAG,EAAAA,KAAC,MAAA,CAAI,UAAWd,EAAAA,QAAO,yBAAyB,EAC7C,SAAA,CAAAY,GAAgB,MACflB,EAAAA,IAAC,MAAA,CACC,UAAW,CAACM,UAAO,sBAAsB,EAAGa,CAAc,EACvD,OAAO,OAAO,EACd,KAAK,GAAG,EACX,cAAW,GAEV,SAAAD,CAAA,CAAA,EAILE,EAAAA,KAAC,MAAA,CAAI,UAAWd,EAAAA,QAAO,sBAAsB,EAC3C,SAAA,CAAAN,EAAAA,IAAC,MAAA,CAAI,UAAWM,EAAAA,QAAO,2BAA2B,EAChD,SAAAN,EAAAA,IAAC,OAAA,CAAK,UAAWM,EAAAA,QAAO,uBAAuB,EAAI,SAAAE,CAAA,CAAM,EAC3D,QAEC,MAAA,CAAI,UAAWF,EAAAA,QAAO,6BAA6B,EACjD,SAAAG,EACH,EAECG,GAAWA,EAAQ,OAAS,SAC1B,MAAA,CAAI,UAAWN,EAAAA,QAAO,yBAAyB,EAC7C,SAAAM,EAAQ,IAAI,CAACS,EAAQC,IACpBtB,EAAAA,IAACuB,EAAAA,QAAA,CAEC,SAAUF,EAAO,UAAY,UAC7B,KAAK,QACL,QAASA,EAAO,QAEf,SAAAA,EAAO,KAAA,EALHC,CAAA,CAOR,EACH,EAGDT,GAAgBb,EAAAA,IAACwB,UAAA,CAAS,KAAK,SAAU,SAAAV,CAAA,CAAc,CAAA,CAAA,CAC1D,CAAA,EACF,EAECC,GACCf,EAAAA,IAACyB,EAAAA,QAAA,CACC,UAAWnB,EAAAA,QAAO,uBAAuB,EACzC,aAAW,QACX,KAAK,QACL,WAAOP,UAAA,CAAK,KAAK,KAAK,MAAOC,MAAC0B,IAAU,EAAI,EAC5C,QAASX,CAAA,CAAA,CACX,EAEJ,CAEJ"}
@@ -15,7 +15,7 @@ export interface PopoverNoticeProps {
15
15
  * Ignored if `icon` is also provided.
16
16
  */
17
17
  variant?: PopoverNoticeVariant;
18
- /** Optional icon shown to the left of the title. Overrides variant icon. */
18
+ /** Optional icon shown to the left of the title. Overrides the variant icon. Pass `<Icon glyph={<SomeIcon />} size="20" />` — the slot does not resize raw SVG children. */
19
19
  icon?: ReactNode;
20
20
  /** Action buttons rendered below the body. */
21
21
  actions?: PopoverNoticeAction[];
@@ -1 +1 @@
1
- {"version":3,"file":"PopoverNotice.d.ts","sourceRoot":"","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAYvC,MAAM,MAAM,oBAAoB,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,CAAC;AAE7E,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,CAAC,EAAE,SAAS,GAAG,UAAU,CAAC;CACnC;AAED,MAAM,WAAW,kBAAkB;IACjC,0BAA0B;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,oBAAoB;IACpB,QAAQ,EAAE,SAAS,CAAC;IACpB;;;OAGG;IACH,OAAO,CAAC,EAAE,oBAAoB,CAAC;IAC/B,4EAA4E;IAC5E,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,8CAA8C;IAC9C,OAAO,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAChC,2DAA2D;IAC3D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,+BAA+B;IAC/B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,6CAA6C;IAC7C,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAgBD;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,EACpC,KAAK,EACL,QAAQ,EACR,OAAO,EACP,IAAI,EACJ,OAAO,EACP,YAAoB,EACpB,aAAoD,EACpD,OAAO,EACP,SAAc,GACf,EAAE,kBAAkB,2CA6DpB"}
1
+ {"version":3,"file":"PopoverNotice.d.ts","sourceRoot":"","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAYvC,MAAM,MAAM,oBAAoB,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,CAAC;AAE7E,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,CAAC,EAAE,SAAS,GAAG,UAAU,CAAC;CACnC;AAED,MAAM,WAAW,kBAAkB;IACjC,0BAA0B;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,oBAAoB;IACpB,QAAQ,EAAE,SAAS,CAAC;IACpB;;;OAGG;IACH,OAAO,CAAC,EAAE,oBAAoB,CAAC;IAC/B,4KAA4K;IAC5K,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,8CAA8C;IAC9C,OAAO,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAChC,2DAA2D;IAC3D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,+BAA+B;IAC/B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,6CAA6C;IAC7C,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAgBD;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,EACpC,KAAK,EACL,QAAQ,EACR,OAAO,EACP,IAAI,EACJ,OAAO,EACP,YAAoB,EACpB,aAAoD,EACpD,OAAO,EACP,SAAc,GACf,EAAE,kBAAkB,2CA6DpB"}
@@ -1 +1 @@
1
- {"version":3,"file":"PopoverNotice.js","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport InformationOutlineIcon from '@mattermost/compass-icons/components/information-outline';\nimport CheckCircleOutlineIcon from '@mattermost/compass-icons/components/check-circle-outline';\nimport AlertCircleOutlineIcon from '@mattermost/compass-icons/components/alert-circle-outline';\nimport AlertOutlineIcon from '@mattermost/compass-icons/components/alert-outline';\nimport Button from '@/components/button/Button';\nimport Checkbox from '@/components/checkbox/Checkbox';\nimport IconButton from '@/components/icon-button/IconButton';\nimport Icon from '@/components/icon/Icon';\nimport styles from './PopoverNotice.module.scss';\n\nexport type PopoverNoticeVariant = 'info' | 'success' | 'warning' | 'danger';\n\nexport interface PopoverNoticeAction {\n label: string;\n onClick?: () => void;\n emphasis?: 'primary' | 'tertiary';\n}\n\nexport interface PopoverNoticeProps {\n /** Popover title text. */\n title: string;\n /** Body content. */\n children: ReactNode;\n /**\n * Semantic variant — sets the icon and its color automatically.\n * Ignored if `icon` is also provided.\n */\n variant?: PopoverNoticeVariant;\n /** Optional icon shown to the left of the title. Overrides variant icon. */\n icon?: ReactNode;\n /** Action buttons rendered below the body. */\n actions?: PopoverNoticeAction[];\n /** When true, shows a \"Don't show this again\" checkbox. */\n showCheckbox?: boolean;\n /** Checkbox label override. */\n checkboxLabel?: string;\n /** Callback when close button is clicked. */\n onClose?: () => void;\n /** Optional CSS class name. */\n className?: string;\n}\n\nconst VARIANT_ICONS: Record<PopoverNoticeVariant, ReactNode> = {\n info: <Icon size=\"20\" glyph={<InformationOutlineIcon />} />,\n success: <Icon size=\"20\" glyph={<CheckCircleOutlineIcon />} />,\n warning: <Icon size=\"20\" glyph={<AlertCircleOutlineIcon />} />,\n danger: <Icon size=\"20\" glyph={<AlertOutlineIcon />} />,\n};\n\nconst VARIANT_ICON_CLASS: Record<PopoverNoticeVariant, string> = {\n info: styles['popover-notice__icon--info'],\n success: styles['popover-notice__icon--success'],\n warning: styles['popover-notice__icon--warning'],\n danger: styles['popover-notice__icon--danger'],\n};\n\n/**\n * Popover Notice is a small overlay card that surfaces a transient message — a tip, a\n * confirmation, a warning — without taking over the screen. Think of it as a [Section\n * Notice](/components/section-notice) that floats: shorter, dismissable, and gone in five\n * seconds unless the user engages.\n */\nexport default function PopoverNotice({\n title,\n children,\n variant,\n icon,\n actions,\n showCheckbox = false,\n checkboxLabel = \"Don't show this confirmation again\",\n onClose,\n className = '',\n}: PopoverNoticeProps) {\n const rootClass = [styles['popover-notice'], className]\n .filter(Boolean)\n .join(' ');\n\n const resolvedIcon = icon ?? (variant ? VARIANT_ICONS[variant] : null);\n const iconColorClass = !icon && variant ? VARIANT_ICON_CLASS[variant] : '';\n\n return (\n <div className={rootClass}>\n <div className={styles['popover-notice__content']}>\n {resolvedIcon != null && (\n <div\n className={[styles['popover-notice__icon'], iconColorClass]\n .filter(Boolean)\n .join(' ')}\n aria-hidden\n >\n {resolvedIcon}\n </div>\n )}\n\n <div className={styles['popover-notice__body']}>\n <div className={styles['popover-notice__title-row']}>\n <span className={styles['popover-notice__title']}>{title}</span>\n </div>\n\n <div className={styles['popover-notice__description']}>\n {children}\n </div>\n\n {actions && actions.length > 0 && (\n <div className={styles['popover-notice__actions']}>\n {actions.map((action, i) => (\n <Button\n key={i}\n emphasis={action.emphasis ?? 'primary'}\n size=\"small\"\n onClick={action.onClick}\n >\n {action.label}\n </Button>\n ))}\n </div>\n )}\n\n {showCheckbox && <Checkbox size=\"medium\">{checkboxLabel}</Checkbox>}\n </div>\n </div>\n\n {onClose && (\n <IconButton\n className={styles['popover-notice__close']}\n aria-label=\"Close\"\n size=\"small\"\n icon={<Icon size=\"16\" glyph={<CloseIcon />} />}\n onClick={onClose}\n />\n )}\n </div>\n );\n}\n"],"names":["VARIANT_ICONS","Icon","jsx","InformationOutlineIcon","CheckCircleOutlineIcon","AlertCircleOutlineIcon","AlertOutlineIcon","VARIANT_ICON_CLASS","styles","PopoverNotice","title","children","variant","icon","actions","showCheckbox","checkboxLabel","onClose","className","rootClass","resolvedIcon","iconColorClass","jsxs","action","i","Button","Checkbox","IconButton","CloseIcon"],"mappings":";;;;;;;;;;;AA4CA,MAAMA,IAAyD;AAAA,EAC7D,wBAAOC,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACC,KAAuB,GAAI;AAAA,EACzD,2BAAUF,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACE,KAAuB,GAAI;AAAA,EAC5D,2BAAUH,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACG,KAAuB,GAAI;AAAA,EAC5D,0BAASJ,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACI,KAAiB,EAAA,CAAI;AACvD,GAEMC,IAA2D;AAAA,EAC/D,MAAMC,EAAO,4BAA4B;AAAA,EACzC,SAASA,EAAO,+BAA+B;AAAA,EAC/C,SAASA,EAAO,+BAA+B;AAAA,EAC/C,QAAQA,EAAO,8BAA8B;AAC/C;AAQA,SAAwBC,EAAc;AAAA,EACpC,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,SAAAC;AAAA,EACA,MAAAC;AAAA,EACA,SAAAC;AAAA,EACA,cAAAC,IAAe;AAAA,EACf,eAAAC,IAAgB;AAAA,EAChB,SAAAC;AAAA,EACA,WAAAC,IAAY;AACd,GAAuB;AACrB,QAAMC,IAAY,CAACX,EAAO,gBAAgB,GAAGU,CAAS,EACnD,OAAO,OAAO,EACd,KAAK,GAAG,GAELE,IAAeP,MAASD,IAAUZ,EAAcY,CAAO,IAAI,OAC3DS,IAAiB,CAACR,KAAQD,IAAUL,EAAmBK,CAAO,IAAI;AAExE,SACE,gBAAAU,EAAC,OAAA,EAAI,WAAWH,GACd,UAAA;AAAA,IAAA,gBAAAG,EAAC,OAAA,EAAI,WAAWd,EAAO,yBAAyB,GAC7C,UAAA;AAAA,MAAAY,KAAgB,QACf,gBAAAlB;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,WAAW,CAACM,EAAO,sBAAsB,GAAGa,CAAc,EACvD,OAAO,OAAO,EACd,KAAK,GAAG;AAAA,UACX,eAAW;AAAA,UAEV,UAAAD;AAAA,QAAA;AAAA,MAAA;AAAA,MAIL,gBAAAE,EAAC,OAAA,EAAI,WAAWd,EAAO,sBAAsB,GAC3C,UAAA;AAAA,QAAA,gBAAAN,EAAC,OAAA,EAAI,WAAWM,EAAO,2BAA2B,GAChD,UAAA,gBAAAN,EAAC,QAAA,EAAK,WAAWM,EAAO,uBAAuB,GAAI,UAAAE,EAAA,CAAM,GAC3D;AAAA,0BAEC,OAAA,EAAI,WAAWF,EAAO,6BAA6B,GACjD,UAAAG,GACH;AAAA,QAECG,KAAWA,EAAQ,SAAS,uBAC1B,OAAA,EAAI,WAAWN,EAAO,yBAAyB,GAC7C,UAAAM,EAAQ,IAAI,CAACS,GAAQC,MACpB,gBAAAtB;AAAA,UAACuB;AAAA,UAAA;AAAA,YAEC,UAAUF,EAAO,YAAY;AAAA,YAC7B,MAAK;AAAA,YACL,SAASA,EAAO;AAAA,YAEf,UAAAA,EAAO;AAAA,UAAA;AAAA,UALHC;AAAA,QAAA,CAOR,GACH;AAAA,QAGDT,KAAgB,gBAAAb,EAACwB,GAAA,EAAS,MAAK,UAAU,UAAAV,EAAA,CAAc;AAAA,MAAA,EAAA,CAC1D;AAAA,IAAA,GACF;AAAA,IAECC,KACC,gBAAAf;AAAA,MAACyB;AAAA,MAAA;AAAA,QACC,WAAWnB,EAAO,uBAAuB;AAAA,QACzC,cAAW;AAAA,QACX,MAAK;AAAA,QACL,wBAAOP,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAAC0B,KAAU,GAAI;AAAA,QAC5C,SAASX;AAAA,MAAA;AAAA,IAAA;AAAA,EACX,GAEJ;AAEJ;"}
1
+ {"version":3,"file":"PopoverNotice.js","sources":["../../../src/components/popover-notice/PopoverNotice.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport CloseIcon from '@mattermost/compass-icons/components/close';\nimport InformationOutlineIcon from '@mattermost/compass-icons/components/information-outline';\nimport CheckCircleOutlineIcon from '@mattermost/compass-icons/components/check-circle-outline';\nimport AlertCircleOutlineIcon from '@mattermost/compass-icons/components/alert-circle-outline';\nimport AlertOutlineIcon from '@mattermost/compass-icons/components/alert-outline';\nimport Button from '@/components/button/Button';\nimport Checkbox from '@/components/checkbox/Checkbox';\nimport IconButton from '@/components/icon-button/IconButton';\nimport Icon from '@/components/icon/Icon';\nimport styles from './PopoverNotice.module.scss';\n\nexport type PopoverNoticeVariant = 'info' | 'success' | 'warning' | 'danger';\n\nexport interface PopoverNoticeAction {\n label: string;\n onClick?: () => void;\n emphasis?: 'primary' | 'tertiary';\n}\n\nexport interface PopoverNoticeProps {\n /** Popover title text. */\n title: string;\n /** Body content. */\n children: ReactNode;\n /**\n * Semantic variant — sets the icon and its color automatically.\n * Ignored if `icon` is also provided.\n */\n variant?: PopoverNoticeVariant;\n /** Optional icon shown to the left of the title. Overrides the variant icon. Pass `<Icon glyph={<SomeIcon />} size=\"20\" />` — the slot does not resize raw SVG children. */\n icon?: ReactNode;\n /** Action buttons rendered below the body. */\n actions?: PopoverNoticeAction[];\n /** When true, shows a \"Don't show this again\" checkbox. */\n showCheckbox?: boolean;\n /** Checkbox label override. */\n checkboxLabel?: string;\n /** Callback when close button is clicked. */\n onClose?: () => void;\n /** Optional CSS class name. */\n className?: string;\n}\n\nconst VARIANT_ICONS: Record<PopoverNoticeVariant, ReactNode> = {\n info: <Icon size=\"20\" glyph={<InformationOutlineIcon />} />,\n success: <Icon size=\"20\" glyph={<CheckCircleOutlineIcon />} />,\n warning: <Icon size=\"20\" glyph={<AlertCircleOutlineIcon />} />,\n danger: <Icon size=\"20\" glyph={<AlertOutlineIcon />} />,\n};\n\nconst VARIANT_ICON_CLASS: Record<PopoverNoticeVariant, string> = {\n info: styles['popover-notice__icon--info'],\n success: styles['popover-notice__icon--success'],\n warning: styles['popover-notice__icon--warning'],\n danger: styles['popover-notice__icon--danger'],\n};\n\n/**\n * Popover Notice is a small overlay card that surfaces a transient message — a tip, a\n * confirmation, a warning — without taking over the screen. Think of it as a [Section\n * Notice](/components/section-notice) that floats: shorter, dismissable, and gone in five\n * seconds unless the user engages.\n */\nexport default function PopoverNotice({\n title,\n children,\n variant,\n icon,\n actions,\n showCheckbox = false,\n checkboxLabel = \"Don't show this confirmation again\",\n onClose,\n className = '',\n}: PopoverNoticeProps) {\n const rootClass = [styles['popover-notice'], className]\n .filter(Boolean)\n .join(' ');\n\n const resolvedIcon = icon ?? (variant ? VARIANT_ICONS[variant] : null);\n const iconColorClass = !icon && variant ? VARIANT_ICON_CLASS[variant] : '';\n\n return (\n <div className={rootClass}>\n <div className={styles['popover-notice__content']}>\n {resolvedIcon != null && (\n <div\n className={[styles['popover-notice__icon'], iconColorClass]\n .filter(Boolean)\n .join(' ')}\n aria-hidden\n >\n {resolvedIcon}\n </div>\n )}\n\n <div className={styles['popover-notice__body']}>\n <div className={styles['popover-notice__title-row']}>\n <span className={styles['popover-notice__title']}>{title}</span>\n </div>\n\n <div className={styles['popover-notice__description']}>\n {children}\n </div>\n\n {actions && actions.length > 0 && (\n <div className={styles['popover-notice__actions']}>\n {actions.map((action, i) => (\n <Button\n key={i}\n emphasis={action.emphasis ?? 'primary'}\n size=\"small\"\n onClick={action.onClick}\n >\n {action.label}\n </Button>\n ))}\n </div>\n )}\n\n {showCheckbox && <Checkbox size=\"medium\">{checkboxLabel}</Checkbox>}\n </div>\n </div>\n\n {onClose && (\n <IconButton\n className={styles['popover-notice__close']}\n aria-label=\"Close\"\n size=\"small\"\n icon={<Icon size=\"16\" glyph={<CloseIcon />} />}\n onClick={onClose}\n />\n )}\n </div>\n );\n}\n"],"names":["VARIANT_ICONS","Icon","jsx","InformationOutlineIcon","CheckCircleOutlineIcon","AlertCircleOutlineIcon","AlertOutlineIcon","VARIANT_ICON_CLASS","styles","PopoverNotice","title","children","variant","icon","actions","showCheckbox","checkboxLabel","onClose","className","rootClass","resolvedIcon","iconColorClass","jsxs","action","i","Button","Checkbox","IconButton","CloseIcon"],"mappings":";;;;;;;;;;;AA4CA,MAAMA,IAAyD;AAAA,EAC7D,wBAAOC,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACC,KAAuB,GAAI;AAAA,EACzD,2BAAUF,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACE,KAAuB,GAAI;AAAA,EAC5D,2BAAUH,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACG,KAAuB,GAAI;AAAA,EAC5D,0BAASJ,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAACI,KAAiB,EAAA,CAAI;AACvD,GAEMC,IAA2D;AAAA,EAC/D,MAAMC,EAAO,4BAA4B;AAAA,EACzC,SAASA,EAAO,+BAA+B;AAAA,EAC/C,SAASA,EAAO,+BAA+B;AAAA,EAC/C,QAAQA,EAAO,8BAA8B;AAC/C;AAQA,SAAwBC,EAAc;AAAA,EACpC,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,SAAAC;AAAA,EACA,MAAAC;AAAA,EACA,SAAAC;AAAA,EACA,cAAAC,IAAe;AAAA,EACf,eAAAC,IAAgB;AAAA,EAChB,SAAAC;AAAA,EACA,WAAAC,IAAY;AACd,GAAuB;AACrB,QAAMC,IAAY,CAACX,EAAO,gBAAgB,GAAGU,CAAS,EACnD,OAAO,OAAO,EACd,KAAK,GAAG,GAELE,IAAeP,MAASD,IAAUZ,EAAcY,CAAO,IAAI,OAC3DS,IAAiB,CAACR,KAAQD,IAAUL,EAAmBK,CAAO,IAAI;AAExE,SACE,gBAAAU,EAAC,OAAA,EAAI,WAAWH,GACd,UAAA;AAAA,IAAA,gBAAAG,EAAC,OAAA,EAAI,WAAWd,EAAO,yBAAyB,GAC7C,UAAA;AAAA,MAAAY,KAAgB,QACf,gBAAAlB;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,WAAW,CAACM,EAAO,sBAAsB,GAAGa,CAAc,EACvD,OAAO,OAAO,EACd,KAAK,GAAG;AAAA,UACX,eAAW;AAAA,UAEV,UAAAD;AAAA,QAAA;AAAA,MAAA;AAAA,MAIL,gBAAAE,EAAC,OAAA,EAAI,WAAWd,EAAO,sBAAsB,GAC3C,UAAA;AAAA,QAAA,gBAAAN,EAAC,OAAA,EAAI,WAAWM,EAAO,2BAA2B,GAChD,UAAA,gBAAAN,EAAC,QAAA,EAAK,WAAWM,EAAO,uBAAuB,GAAI,UAAAE,EAAA,CAAM,GAC3D;AAAA,0BAEC,OAAA,EAAI,WAAWF,EAAO,6BAA6B,GACjD,UAAAG,GACH;AAAA,QAECG,KAAWA,EAAQ,SAAS,uBAC1B,OAAA,EAAI,WAAWN,EAAO,yBAAyB,GAC7C,UAAAM,EAAQ,IAAI,CAACS,GAAQC,MACpB,gBAAAtB;AAAA,UAACuB;AAAA,UAAA;AAAA,YAEC,UAAUF,EAAO,YAAY;AAAA,YAC7B,MAAK;AAAA,YACL,SAASA,EAAO;AAAA,YAEf,UAAAA,EAAO;AAAA,UAAA;AAAA,UALHC;AAAA,QAAA,CAOR,GACH;AAAA,QAGDT,KAAgB,gBAAAb,EAACwB,GAAA,EAAS,MAAK,UAAU,UAAAV,EAAA,CAAc;AAAA,MAAA,EAAA,CAC1D;AAAA,IAAA,GACF;AAAA,IAECC,KACC,gBAAAf;AAAA,MAACyB;AAAA,MAAA;AAAA,QACC,WAAWnB,EAAO,uBAAuB;AAAA,QACzC,cAAW;AAAA,QACX,MAAK;AAAA,QACL,wBAAOP,GAAA,EAAK,MAAK,MAAK,OAAO,gBAAAC,EAAC0B,KAAU,GAAI;AAAA,QAC5C,SAASX;AAAA,MAAA;AAAA,IAAA;AAAA,EACX,GAEJ;AAEJ;"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("react/jsx-runtime"),n=require("react"),t=require("./ReactionButton.module.scss.cjs");function b({emoji:a,count:e,byCurrentUser:i=!1,className:l="",onClick:d,...f}){const o=n.useRef(e),u=n.useRef(void 0),[s,c]=n.useState(null);n.useEffect(()=>(e!==o.current&&(clearTimeout(u.current),c(e>o.current?"up":"down"),o.current=e,u.current=setTimeout(()=>c(null),300)),()=>clearTimeout(u.current)),[e]);const m=[t.default["reaction-button"],i?t.default["reaction-button--mine"]:"",l].filter(Boolean).join(" "),_=[t.default["reaction-button__count"],s==="up"?t.default["reaction-button__count--anim-up"]:"",s==="down"?t.default["reaction-button__count--anim-down"]:""].filter(Boolean).join(" ");return r.jsxs("button",{type:"button",className:m,onClick:d,"aria-label":`${a} ${e} reaction${e!==1?"s":""}`,"aria-pressed":i,...f,children:[r.jsx("span",{className:t.default["reaction-button__emoji"],"aria-hidden":!0,children:a}),r.jsx("span",{className:_,children:e})]})}exports.default=b;
2
+ //# sourceMappingURL=ReactionButton.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReactionButton.cjs","sources":["../../../src/components/reaction-button/ReactionButton.tsx"],"sourcesContent":["import { useEffect, useRef, useState } from 'react';\nimport type { ButtonHTMLAttributes } from 'react';\nimport styles from './ReactionButton.module.scss';\n\nexport interface ReactionButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {\n /** The emoji character to display. */\n emoji: string;\n /** Number of users who reacted with this emoji. */\n count: number;\n /** Whether the current user has reacted with this emoji. */\n byCurrentUser?: boolean;\n}\n\n/**\n * A single emoji reaction button — shows the emoji, count, and highlights when the current user\n * has reacted. Fires onClick when clicked; the host owns toggle logic.\n *\n * The count animates up or down when the `count` prop changes.\n */\nexport default function ReactionButton({\n emoji,\n count,\n byCurrentUser = false,\n className = '',\n onClick,\n ...rest\n}: ReactionButtonProps) {\n const prevCountRef = useRef(count);\n const timerRef = useRef<ReturnType<typeof setTimeout>>(undefined);\n const [countAnim, setCountAnim] = useState<'up' | 'down' | null>(null);\n\n useEffect(() => {\n if (count !== prevCountRef.current) {\n clearTimeout(timerRef.current);\n setCountAnim(count > prevCountRef.current ? 'up' : 'down');\n prevCountRef.current = count;\n timerRef.current = setTimeout(() => setCountAnim(null), 300);\n }\n return () => clearTimeout(timerRef.current);\n }, [count]);\n\n const rootClass = [\n styles['reaction-button'],\n byCurrentUser ? styles['reaction-button--mine'] : '',\n className,\n ]\n .filter(Boolean)\n .join(' ');\n\n const countClass = [\n styles['reaction-button__count'],\n countAnim === 'up' ? styles['reaction-button__count--anim-up'] : '',\n countAnim === 'down' ? styles['reaction-button__count--anim-down'] : '',\n ]\n .filter(Boolean)\n .join(' ');\n\n return (\n <button\n type=\"button\"\n className={rootClass}\n onClick={onClick}\n aria-label={`${emoji} ${count} reaction${count !== 1 ? 's' : ''}`}\n aria-pressed={byCurrentUser}\n {...rest}\n >\n <span className={styles['reaction-button__emoji']} aria-hidden>\n {emoji}\n </span>\n <span className={countClass}>{count}</span>\n </button>\n );\n}\n"],"names":["ReactionButton","emoji","count","byCurrentUser","className","onClick","rest","prevCountRef","useRef","timerRef","countAnim","setCountAnim","useState","useEffect","rootClass","styles","countClass","jsxs","jsx"],"mappings":"kNAmBA,SAAwBA,EAAe,CACrC,MAAAC,EACA,MAAAC,EACA,cAAAC,EAAgB,GAChB,UAAAC,EAAY,GACZ,QAAAC,EACA,GAAGC,CACL,EAAwB,CACtB,MAAMC,EAAeC,EAAAA,OAAON,CAAK,EAC3BO,EAAWD,EAAAA,OAAsC,MAAS,EAC1D,CAACE,EAAWC,CAAY,EAAIC,EAAAA,SAA+B,IAAI,EAErEC,EAAAA,UAAU,KACJX,IAAUK,EAAa,UACzB,aAAaE,EAAS,OAAO,EAC7BE,EAAaT,EAAQK,EAAa,QAAU,KAAO,MAAM,EACzDA,EAAa,QAAUL,EACvBO,EAAS,QAAU,WAAW,IAAME,EAAa,IAAI,EAAG,GAAG,GAEtD,IAAM,aAAaF,EAAS,OAAO,GACzC,CAACP,CAAK,CAAC,EAEV,MAAMY,EAAY,CAChBC,EAAAA,QAAO,iBAAiB,EACxBZ,EAAgBY,EAAAA,QAAO,uBAAuB,EAAI,GAClDX,CAAA,EAEC,OAAO,OAAO,EACd,KAAK,GAAG,EAELY,EAAa,CACjBD,EAAAA,QAAO,wBAAwB,EAC/BL,IAAc,KAAOK,UAAO,iCAAiC,EAAI,GACjEL,IAAc,OAASK,UAAO,mCAAmC,EAAI,EAAA,EAEpE,OAAO,OAAO,EACd,KAAK,GAAG,EAEX,OACEE,EAAAA,KAAC,SAAA,CACC,KAAK,SACL,UAAWH,EACX,QAAAT,EACA,aAAY,GAAGJ,CAAK,IAAIC,CAAK,YAAYA,IAAU,EAAI,IAAM,EAAE,GAC/D,eAAcC,EACb,GAAGG,EAEJ,SAAA,CAAAY,EAAAA,IAAC,QAAK,UAAWH,UAAO,wBAAwB,EAAG,cAAW,GAC3D,SAAAd,EACH,EACAiB,EAAAA,IAAC,OAAA,CAAK,UAAWF,EAAa,SAAAd,CAAA,CAAM,CAAA,CAAA,CAAA,CAG1C"}
@@ -0,0 +1,17 @@
1
+ import { ButtonHTMLAttributes } from 'react';
2
+ export interface ReactionButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
3
+ /** The emoji character to display. */
4
+ emoji: string;
5
+ /** Number of users who reacted with this emoji. */
6
+ count: number;
7
+ /** Whether the current user has reacted with this emoji. */
8
+ byCurrentUser?: boolean;
9
+ }
10
+ /**
11
+ * A single emoji reaction button — shows the emoji, count, and highlights when the current user
12
+ * has reacted. Fires onClick when clicked; the host owns toggle logic.
13
+ *
14
+ * The count animates up or down when the `count` prop changes.
15
+ */
16
+ export default function ReactionButton({ emoji, count, byCurrentUser, className, onClick, ...rest }: ReactionButtonProps): import("react/jsx-runtime").JSX.Element;
17
+ //# sourceMappingURL=ReactionButton.d.ts.map