@fluentui-copilot/react-attachments 0.0.0-nightly-20251010-0406-7df7c6d1.1 → 0.0.0-nightly-20251013-0406-7c7739c8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (220) hide show
  1. package/CHANGELOG.json +3 -3
  2. package/CHANGELOG.md +4 -4
  3. package/dist/index.d.ts +379 -0
  4. package/lib/AgentTag.js +1 -0
  5. package/lib/AgentTag.js.map +1 -0
  6. package/lib/Attachment.js +1 -0
  7. package/lib/Attachment.js.map +1 -0
  8. package/lib/AttachmentList.js +1 -0
  9. package/lib/AttachmentList.js.map +1 -0
  10. package/lib/AttachmentOverflowMenu.js +1 -0
  11. package/lib/AttachmentOverflowMenu.js.map +1 -0
  12. package/lib/AttachmentOverflowMenuButton.js +1 -0
  13. package/lib/AttachmentOverflowMenuButton.js.map +1 -0
  14. package/lib/AttachmentOverflowMenuItem.js +1 -0
  15. package/lib/AttachmentOverflowMenuItem.js.map +1 -0
  16. package/lib/components/AgentTag/AgentTag.js +11 -0
  17. package/lib/components/AgentTag/AgentTag.js.map +1 -0
  18. package/lib/components/AgentTag/AgentTag.types.js +3 -0
  19. package/lib/components/AgentTag/AgentTag.types.js.map +1 -0
  20. package/lib/components/AgentTag/index.js +4 -0
  21. package/lib/components/AgentTag/index.js.map +1 -0
  22. package/lib/components/AgentTag/renderAgentTag.js +6 -0
  23. package/lib/components/AgentTag/renderAgentTag.js.map +1 -0
  24. package/lib/components/AgentTag/useAgentTag.js +18 -0
  25. package/lib/components/AgentTag/useAgentTag.js.map +1 -0
  26. package/lib/components/AgentTag/useAgentTagStyles.styles.js +95 -0
  27. package/lib/components/AgentTag/useAgentTagStyles.styles.js.map +1 -0
  28. package/lib/components/AgentTag/useAgentTagStyles.styles.raw.js +66 -0
  29. package/lib/components/AgentTag/useAgentTagStyles.styles.raw.js.map +1 -0
  30. package/lib/components/Attachment/Attachment.js +13 -0
  31. package/lib/components/Attachment/Attachment.js.map +1 -0
  32. package/lib/components/Attachment/Attachment.types.js +3 -0
  33. package/lib/components/Attachment/Attachment.types.js.map +1 -0
  34. package/lib/components/Attachment/index.js +4 -0
  35. package/lib/components/Attachment/index.js.map +1 -0
  36. package/lib/components/Attachment/renderAttachment.js +42 -0
  37. package/lib/components/Attachment/renderAttachment.js.map +1 -0
  38. package/lib/components/Attachment/useAttachment.js +103 -0
  39. package/lib/components/Attachment/useAttachment.js.map +1 -0
  40. package/lib/components/Attachment/useAttachmentStyles.styles.js +348 -0
  41. package/lib/components/Attachment/useAttachmentStyles.styles.js.map +1 -0
  42. package/lib/components/Attachment/useAttachmentStyles.styles.raw.js +328 -0
  43. package/lib/components/Attachment/useAttachmentStyles.styles.raw.js.map +1 -0
  44. package/lib/components/AttachmentList/AttachmentList.js +14 -0
  45. package/lib/components/AttachmentList/AttachmentList.js.map +1 -0
  46. package/lib/components/AttachmentList/AttachmentList.types.js +1 -0
  47. package/lib/components/AttachmentList/AttachmentList.types.js.map +1 -0
  48. package/lib/components/AttachmentList/index.js +4 -0
  49. package/lib/components/AttachmentList/index.js.map +1 -0
  50. package/lib/components/AttachmentList/renderAttachmentList.js +31 -0
  51. package/lib/components/AttachmentList/renderAttachmentList.js.map +1 -0
  52. package/lib/components/AttachmentList/useAttachmentList.js +134 -0
  53. package/lib/components/AttachmentList/useAttachmentList.js.map +1 -0
  54. package/lib/components/AttachmentList/useAttachmentListContextValues.js +12 -0
  55. package/lib/components/AttachmentList/useAttachmentListContextValues.js.map +1 -0
  56. package/lib/components/AttachmentList/useAttachmentListStyles.styles.js +48 -0
  57. package/lib/components/AttachmentList/useAttachmentListStyles.styles.js.map +1 -0
  58. package/lib/components/AttachmentList/useAttachmentListStyles.styles.raw.js +44 -0
  59. package/lib/components/AttachmentList/useAttachmentListStyles.styles.raw.js.map +1 -0
  60. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +14 -0
  61. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js.map +1 -0
  62. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +1 -0
  63. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js.map +1 -0
  64. package/lib/components/AttachmentOverflowMenu/index.js +4 -0
  65. package/lib/components/AttachmentOverflowMenu/index.js.map +1 -0
  66. package/lib/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +13 -0
  67. package/lib/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js.map +1 -0
  68. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +18 -0
  69. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js.map +1 -0
  70. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +12 -0
  71. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js.map +1 -0
  72. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +12 -0
  73. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js.map +1 -0
  74. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +3 -0
  75. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js.map +1 -0
  76. package/lib/components/AttachmentOverflowMenuButton/index.js +4 -0
  77. package/lib/components/AttachmentOverflowMenuButton/index.js.map +1 -0
  78. package/lib/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +15 -0
  79. package/lib/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js.map +1 -0
  80. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +69 -0
  81. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js.map +1 -0
  82. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.js +116 -0
  83. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.js.map +1 -0
  84. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +102 -0
  85. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js.map +1 -0
  86. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +10 -0
  87. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js.map +1 -0
  88. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +3 -0
  89. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js.map +1 -0
  90. package/lib/components/AttachmentOverflowMenuItem/index.js +4 -0
  91. package/lib/components/AttachmentOverflowMenuItem/index.js.map +1 -0
  92. package/lib/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +13 -0
  93. package/lib/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js.map +1 -0
  94. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +56 -0
  95. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js.map +1 -0
  96. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js +84 -0
  97. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js.map +1 -0
  98. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +59 -0
  99. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js.map +1 -0
  100. package/lib/components/index.js +5 -0
  101. package/lib/components/index.js.map +1 -0
  102. package/lib/components/utils/useProgressBarStyles.styles.js +54 -0
  103. package/lib/components/utils/useProgressBarStyles.styles.js.map +1 -0
  104. package/lib/components/utils/useProgressBarStyles.styles.raw.js +42 -0
  105. package/lib/components/utils/useProgressBarStyles.styles.raw.js.map +1 -0
  106. package/lib/contexts/attachmentListContext.js +9 -0
  107. package/lib/contexts/attachmentListContext.js.map +1 -0
  108. package/lib/contexts/attachmentOverflowMenuContext.js +9 -0
  109. package/lib/contexts/attachmentOverflowMenuContext.js.map +1 -0
  110. package/lib/index.js +8 -0
  111. package/lib/index.js.map +1 -0
  112. package/lib-commonjs/AgentTag.js +28 -0
  113. package/lib-commonjs/AgentTag.js.map +1 -0
  114. package/lib-commonjs/Attachment.js +31 -0
  115. package/lib-commonjs/Attachment.js.map +1 -0
  116. package/lib-commonjs/AttachmentList.js +28 -0
  117. package/lib-commonjs/AttachmentList.js.map +1 -0
  118. package/lib-commonjs/AttachmentOverflowMenu.js +25 -0
  119. package/lib-commonjs/AttachmentOverflowMenu.js.map +1 -0
  120. package/lib-commonjs/AttachmentOverflowMenuButton.js +28 -0
  121. package/lib-commonjs/AttachmentOverflowMenuButton.js.map +1 -0
  122. package/lib-commonjs/AttachmentOverflowMenuItem.js +28 -0
  123. package/lib-commonjs/AttachmentOverflowMenuItem.js.map +1 -0
  124. package/lib-commonjs/components/AgentTag/AgentTag.js +21 -0
  125. package/lib-commonjs/components/AgentTag/AgentTag.js.map +1 -0
  126. package/lib-commonjs/components/AgentTag/AgentTag.types.js +6 -0
  127. package/lib-commonjs/components/AgentTag/AgentTag.types.js.map +1 -0
  128. package/lib-commonjs/components/AgentTag/index.js +31 -0
  129. package/lib-commonjs/components/AgentTag/index.js.map +1 -0
  130. package/lib-commonjs/components/AgentTag/renderAgentTag.js +14 -0
  131. package/lib-commonjs/components/AgentTag/renderAgentTag.js.map +1 -0
  132. package/lib-commonjs/components/AgentTag/useAgentTag.js +19 -0
  133. package/lib-commonjs/components/AgentTag/useAgentTag.js.map +1 -0
  134. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.js +145 -0
  135. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.js.map +1 -0
  136. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js +82 -0
  137. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js.map +1 -0
  138. package/lib-commonjs/components/Attachment/Attachment.js +23 -0
  139. package/lib-commonjs/components/Attachment/Attachment.js.map +1 -0
  140. package/lib-commonjs/components/Attachment/Attachment.types.js +6 -0
  141. package/lib-commonjs/components/Attachment/Attachment.types.js.map +1 -0
  142. package/lib-commonjs/components/Attachment/index.js +34 -0
  143. package/lib-commonjs/components/Attachment/index.js.map +1 -0
  144. package/lib-commonjs/components/Attachment/renderAttachment.js +50 -0
  145. package/lib-commonjs/components/Attachment/renderAttachment.js.map +1 -0
  146. package/lib-commonjs/components/Attachment/useAttachment.js +105 -0
  147. package/lib-commonjs/components/Attachment/useAttachment.js.map +1 -0
  148. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.js +550 -0
  149. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.js.map +1 -0
  150. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js +347 -0
  151. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js.map +1 -0
  152. package/lib-commonjs/components/AttachmentList/AttachmentList.js +25 -0
  153. package/lib-commonjs/components/AttachmentList/AttachmentList.js.map +1 -0
  154. package/lib-commonjs/components/AttachmentList/AttachmentList.types.js +4 -0
  155. package/lib-commonjs/components/AttachmentList/AttachmentList.types.js.map +1 -0
  156. package/lib-commonjs/components/AttachmentList/index.js +31 -0
  157. package/lib-commonjs/components/AttachmentList/index.js.map +1 -0
  158. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js +39 -0
  159. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js.map +1 -0
  160. package/lib-commonjs/components/AttachmentList/useAttachmentList.js +137 -0
  161. package/lib-commonjs/components/AttachmentList/useAttachmentList.js.map +1 -0
  162. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js +22 -0
  163. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js.map +1 -0
  164. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.js +67 -0
  165. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.js.map +1 -0
  166. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js +60 -0
  167. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js.map +1 -0
  168. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +24 -0
  169. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js.map +1 -0
  170. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +4 -0
  171. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js.map +1 -0
  172. package/lib-commonjs/components/AttachmentOverflowMenu/index.js +28 -0
  173. package/lib-commonjs/components/AttachmentOverflowMenu/index.js.map +1 -0
  174. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +21 -0
  175. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js.map +1 -0
  176. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +21 -0
  177. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js.map +1 -0
  178. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +22 -0
  179. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js.map +1 -0
  180. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +23 -0
  181. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js.map +1 -0
  182. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +6 -0
  183. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js.map +1 -0
  184. package/lib-commonjs/components/AttachmentOverflowMenuButton/index.js +31 -0
  185. package/lib-commonjs/components/AttachmentOverflowMenuButton/index.js.map +1 -0
  186. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +23 -0
  187. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js.map +1 -0
  188. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +72 -0
  189. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js.map +1 -0
  190. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.js +178 -0
  191. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.js.map +1 -0
  192. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +118 -0
  193. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js.map +1 -0
  194. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +21 -0
  195. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js.map +1 -0
  196. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +6 -0
  197. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js.map +1 -0
  198. package/lib-commonjs/components/AttachmentOverflowMenuItem/index.js +31 -0
  199. package/lib-commonjs/components/AttachmentOverflowMenuItem/index.js.map +1 -0
  200. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +21 -0
  201. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js.map +1 -0
  202. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +59 -0
  203. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js.map +1 -0
  204. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js +109 -0
  205. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js.map +1 -0
  206. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +75 -0
  207. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js.map +1 -0
  208. package/lib-commonjs/components/index.js +92 -0
  209. package/lib-commonjs/components/index.js.map +1 -0
  210. package/lib-commonjs/components/utils/useProgressBarStyles.styles.js +103 -0
  211. package/lib-commonjs/components/utils/useProgressBarStyles.styles.js.map +1 -0
  212. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js +50 -0
  213. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js.map +1 -0
  214. package/lib-commonjs/contexts/attachmentListContext.js +30 -0
  215. package/lib-commonjs/contexts/attachmentListContext.js.map +1 -0
  216. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js +30 -0
  217. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js.map +1 -0
  218. package/lib-commonjs/index.js +122 -0
  219. package/lib-commonjs/index.js.map +1 -0
  220. package/package.json +4 -4
@@ -0,0 +1,347 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: all[name]
9
+ });
10
+ }
11
+ _export(exports, {
12
+ attachmentClassNames: function() {
13
+ return attachmentClassNames;
14
+ },
15
+ useAttachmentStyles_unstable: function() {
16
+ return useAttachmentStyles_unstable;
17
+ },
18
+ useOverflowStyles: function() {
19
+ return useOverflowStyles;
20
+ }
21
+ });
22
+ const _reactcomponents = require("@fluentui/react-components");
23
+ const _tokens = require("@fluentui-copilot/tokens");
24
+ const _useProgressBarStylesstyles = require("../utils/useProgressBarStyles.styles");
25
+ const attachmentClassNames = {
26
+ root: 'fai-Attachment',
27
+ primaryAction: 'fai-Attachment__primaryAction',
28
+ dismissButton: 'fai-Attachment__dismissButton',
29
+ media: 'fai-Attachment__media',
30
+ content: 'fai-Attachment__content',
31
+ dismissIcon: 'fai-Attachment__dismissIcon',
32
+ progress: 'fai-Attachment__progress'
33
+ };
34
+ const ATTACHMENT_MAXWIDTH = '180px';
35
+ const SMALL_ATTACHMENT_SIZE = '16px';
36
+ const ATTACHMENT_SIZE = '20px';
37
+ const useRootBaseClassName = (0, _reactcomponents.makeResetStyles)({
38
+ display: 'inline-flex',
39
+ flexWrap: 'nowrap',
40
+ verticalAlign: 'middle',
41
+ boxSizing: 'border-box',
42
+ width: 'fit-content',
43
+ alignSelf: 'end',
44
+ position: 'relative'
45
+ });
46
+ const buttonBaseStyles = {
47
+ alignItems: 'center',
48
+ backgroundColor: _tokens.tokens.colorSubtleBackground,
49
+ border: `${_tokens.tokens.strokeWidthThin} solid ${_tokens.tokens.colorNeutralStroke1}`,
50
+ borderRadius: _tokens.tokens.borderRadiusMedium,
51
+ boxSizing: 'border-box',
52
+ columnGap: _tokens.tokens.spacingHorizontalSNudge,
53
+ color: _tokens.tokens.colorNeutralForeground1,
54
+ cursor: 'pointer',
55
+ display: 'inline-flex',
56
+ flexWrap: 'nowrap',
57
+ justifyContent: 'center',
58
+ ...(0, _reactcomponents.createCustomFocusIndicatorStyle)({
59
+ outline: `${_tokens.tokens.strokeWidthThick} solid ${_tokens.tokens.colorStrokeFocus2}`,
60
+ outlineOffset: `calc(${_tokens.tokens.strokeWidthThick} * -1)`,
61
+ zIndex: 1
62
+ }),
63
+ verticalAlign: 'middle'
64
+ };
65
+ const usePrimaryActionBaseClassName = (0, _reactcomponents.makeResetStyles)({
66
+ ...buttonBaseStyles,
67
+ borderTopRightRadius: _tokens.tokens.borderRadiusNone,
68
+ borderBottomRightRadius: _tokens.tokens.borderRadiusNone,
69
+ borderRightStyle: 'none',
70
+ maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS} - ${_tokens.tokens.spacingHorizontalXS})`,
71
+ padding: `${_tokens.tokens.spacingVerticalXS} ${_tokens.tokens.spacingHorizontalS} ${_tokens.tokens.spacingVerticalXS} ${_tokens.tokens.spacingHorizontalS}`
72
+ });
73
+ const usePrimaryActionStyles = (0, _reactcomponents.makeStyles)({
74
+ button: {
75
+ ':hover': {
76
+ cursor: 'pointer',
77
+ backgroundColor: _tokens.tokens.colorSubtleBackgroundHover,
78
+ color: _tokens.tokens.colorNeutralForeground2Hover
79
+ },
80
+ ':active': {
81
+ backgroundColor: _tokens.tokens.colorSubtleBackgroundPressed,
82
+ color: _tokens.tokens.colorNeutralForeground2Pressed
83
+ },
84
+ '@media (forced-colors: active)': {
85
+ ':hover': {
86
+ backgroundColor: 'HighlightText'
87
+ },
88
+ ':active': {
89
+ backgroundColor: 'HighlightText'
90
+ }
91
+ }
92
+ }
93
+ });
94
+ const useDismissButtonBaseClassName = (0, _reactcomponents.makeResetStyles)({
95
+ ...buttonBaseStyles,
96
+ padding: `${_tokens.tokens.spacingVerticalXS} ${_tokens.tokens.spacingHorizontalXS} ${_tokens.tokens.spacingVerticalXS} ${_tokens.tokens.spacingHorizontalXS}`,
97
+ maxWidth: `calc(${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS}) + ${_tokens.tokens.spacingHorizontalXS}`,
98
+ minWidth: `calc(${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS}) + ${_tokens.tokens.spacingHorizontalXS}`,
99
+ // divider:
100
+ borderLeftColor: _tokens.tokens.colorNeutralStroke1,
101
+ borderTopLeftRadius: _tokens.tokens.borderRadiusNone,
102
+ borderBottomLeftRadius: _tokens.tokens.borderRadiusNone,
103
+ borderTopRightRadius: _tokens.tokens.borderRadiusMedium,
104
+ borderBottomRightRadius: _tokens.tokens.borderRadiusMedium,
105
+ ':hover': {
106
+ cursor: 'pointer',
107
+ backgroundColor: _tokens.tokens.colorSubtleBackgroundHover,
108
+ color: _tokens.tokens.colorNeutralForeground2BrandHover
109
+ },
110
+ ':active': {
111
+ backgroundColor: _tokens.tokens.colorSubtleBackgroundPressed,
112
+ color: _tokens.tokens.colorNeutralForeground2BrandPressed
113
+ },
114
+ '@media (forced-colors: active)': {
115
+ ':hover': {
116
+ backgroundColor: 'HighlightText'
117
+ },
118
+ ':active': {
119
+ backgroundColor: 'HighlightText'
120
+ }
121
+ }
122
+ });
123
+ const useDismissButtonCurrentStyles = (0, _reactcomponents.makeStyles)({
124
+ root: {
125
+ ':hover': {
126
+ [`& .${attachmentClassNames.dismissIcon}`]: {
127
+ color: _tokens.tokens.colorBrandForegroundLinkHover
128
+ }
129
+ }
130
+ }
131
+ });
132
+ const useMediaBaseClassName = (0, _reactcomponents.makeResetStyles)({
133
+ alignItems: 'center',
134
+ display: 'inline-flex',
135
+ fontSize: ATTACHMENT_SIZE,
136
+ height: ATTACHMENT_SIZE,
137
+ lineHeight: ATTACHMENT_SIZE,
138
+ width: ATTACHMENT_SIZE
139
+ });
140
+ const useContentBaseClassName = (0, _reactcomponents.makeResetStyles)({
141
+ overflowX: 'hidden',
142
+ textOverflow: 'ellipsis',
143
+ whiteSpace: 'nowrap',
144
+ ..._reactcomponents.typographyStyles.body1
145
+ });
146
+ const useDismissIconBaseClassName = (0, _reactcomponents.makeResetStyles)({
147
+ alignItems: 'center',
148
+ borderRadius: _tokens.tokens.borderRadiusCircular,
149
+ border: `${_tokens.tokens.strokeWidthThin} solid ${_tokens.tokens.colorTransparentStroke}`,
150
+ boxSizing: 'border-box',
151
+ color: _tokens.tokens.colorNeutralForeground1,
152
+ display: 'inline-flex',
153
+ fontSize: ATTACHMENT_SIZE,
154
+ height: `calc(${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingVerticalXXS})`,
155
+ justifyContent: 'center',
156
+ maxWidth: `calc(${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS})`,
157
+ minWidth: `calc(${ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS})`,
158
+ padding: `calc(${_tokens.tokens.spacingVerticalXXS} / 2) calc(${_tokens.tokens.spacingHorizontalXXS} / 2)`
159
+ });
160
+ const useDismissIconNextStyles = (0, _reactcomponents.makeStyles)({
161
+ dismissOnly: {
162
+ ':hover': {
163
+ color: _tokens.tokens.colorNeutralForeground2BrandHover
164
+ },
165
+ ':active': {
166
+ color: _tokens.tokens.colorNeutralForeground2BrandPressed
167
+ }
168
+ }
169
+ });
170
+ const useImageOnlyStyles = (0, _reactcomponents.makeStyles)({
171
+ primaryAction: {
172
+ padding: 0
173
+ },
174
+ content: {
175
+ lineHeight: 0
176
+ }
177
+ });
178
+ const useOverflowStyles = (0, _reactcomponents.makeStyles)({
179
+ overflow: {
180
+ maxWidth: '100%',
181
+ width: '100%'
182
+ }
183
+ });
184
+ const useSmallStyles = (0, _reactcomponents.makeStyles)({
185
+ primaryAction: {
186
+ maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS} - ${_tokens.tokens.spacingHorizontalXS})`,
187
+ padding: `${_tokens.tokens.spacingVerticalXXS} ${_tokens.tokens.spacingHorizontalSNudge} ${_tokens.tokens.spacingVerticalXXS} ${_tokens.tokens.spacingHorizontalSNudge}`
188
+ },
189
+ media: {
190
+ fontSize: SMALL_ATTACHMENT_SIZE,
191
+ height: SMALL_ATTACHMENT_SIZE,
192
+ lineHeight: SMALL_ATTACHMENT_SIZE,
193
+ width: SMALL_ATTACHMENT_SIZE
194
+ },
195
+ content: {
196
+ ..._reactcomponents.typographyStyles.caption1
197
+ },
198
+ dismissButton: {
199
+ padding: `${_tokens.tokens.spacingVerticalXXS} ${_tokens.tokens.spacingHorizontalXXS}`,
200
+ maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS}) + ${_tokens.tokens.spacingHorizontalXS}`,
201
+ minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS}) + ${_tokens.tokens.spacingHorizontalXS}`
202
+ },
203
+ dismissIcon: {
204
+ fontSize: SMALL_ATTACHMENT_SIZE,
205
+ height: `calc(${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingVerticalXXS})`,
206
+ maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS})`,
207
+ minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${_tokens.tokens.strokeWidthThin} * 2 + ${_tokens.tokens.spacingHorizontalXXS})`
208
+ }
209
+ });
210
+ const usePrimaryActionNextStyles = (0, _reactcomponents.makeStyles)({
211
+ root: {
212
+ borderTopLeftRadius: _tokens.tokens.borderRadiusXLarge,
213
+ borderBottomLeftRadius: _tokens.tokens.borderRadiusXLarge
214
+ },
215
+ canvas: {
216
+ padding: `${_tokens.tokens.spacingVerticalNone} ${_tokens.tokens.spacingHorizontalS}`,
217
+ minHeight: '40px'
218
+ },
219
+ sidecar: {
220
+ padding: `${_tokens.tokens.spacingVerticalNone} ${_tokens.tokens.spacingHorizontalS}`,
221
+ minHeight: '32px'
222
+ }
223
+ });
224
+ const useDismissButtonNextStyles = (0, _reactcomponents.makeStyles)({
225
+ root: {
226
+ borderTopRightRadius: _tokens.tokens.borderRadiusXLarge,
227
+ borderBottomRightRadius: _tokens.tokens.borderRadiusXLarge,
228
+ ':hover': {
229
+ color: _tokens.tokens.colorNeutralForeground2
230
+ },
231
+ ':active': {
232
+ color: _tokens.tokens.colorNeutralForeground2Pressed
233
+ },
234
+ borderLeftColor: _tokens.tokens.colorNeutralStroke1,
235
+ borderLeftWidth: _tokens.tokens.strokeWidthThin,
236
+ borderLeftStyle: 'solid'
237
+ },
238
+ withPrimary: {
239
+ ':hover': {
240
+ [`& .${attachmentClassNames.dismissIcon}`]: {
241
+ color: _tokens.tokens.colorNeutralForeground2
242
+ }
243
+ },
244
+ ':active': {
245
+ [`& .${attachmentClassNames.dismissIcon}`]: {
246
+ color: _tokens.tokens.colorNeutralForeground2Pressed
247
+ }
248
+ }
249
+ },
250
+ canvas: {
251
+ padding: `${_tokens.tokens.spacingVerticalNone} ${_tokens.tokens.spacingHorizontalS}`,
252
+ minHeight: '40px',
253
+ width: '40px'
254
+ },
255
+ sidecar: {
256
+ padding: `${_tokens.tokens.spacingVerticalNone} ${_tokens.tokens.spacingHorizontalMNudge}`,
257
+ minHeight: '32px',
258
+ width: '32px'
259
+ },
260
+ dismissOnly: {
261
+ borderRadius: _tokens.tokens.borderRadiusXLarge,
262
+ width: 'unset',
263
+ borderLeftColor: _tokens.tokens.colorTransparentStroke,
264
+ backgroundColor: _tokens.tokens.colorNeutralBackground3,
265
+ ':hover': {
266
+ backgroundColor: _tokens.tokens.colorNeutralBackground3
267
+ },
268
+ ':active': {
269
+ backgroundColor: _tokens.tokens.colorNeutralBackground3
270
+ }
271
+ }
272
+ });
273
+ const usePrimaryDismissNextStyles = (0, _reactcomponents.makeStyles)({
274
+ sharedStyles: {
275
+ border: 'none',
276
+ backgroundColor: _tokens.tokens.colorNeutralBackground3
277
+ },
278
+ sharedInteractiveStyles: {
279
+ ':hover': {
280
+ backgroundColor: _tokens.tokens.colorNeutralBackground3Hover
281
+ },
282
+ ':active': {
283
+ backgroundColor: _tokens.tokens.colorNeutralBackground3Pressed
284
+ }
285
+ }
286
+ });
287
+ const useRootNextStyles = (0, _reactcomponents.makeStyles)({
288
+ root: {
289
+ outline: `${_tokens.tokens.strokeWidthThin} solid ${_tokens.tokens.colorTransparentStroke}`,
290
+ borderRadius: _tokens.tokens.borderRadiusXLarge
291
+ }
292
+ });
293
+ const useFocusStyles = (0, _reactcomponents.makeStyles)({
294
+ primaryActionButton: (0, _reactcomponents.createCustomFocusIndicatorStyle)({
295
+ borderTopRightRadius: _tokens.tokens.borderRadiusNone,
296
+ borderBottomRightRadius: _tokens.tokens.borderRadiusNone
297
+ }),
298
+ dismissButton: (0, _reactcomponents.createCustomFocusIndicatorStyle)({
299
+ borderTopLeftRadius: _tokens.tokens.borderRadiusNone,
300
+ borderBottomLeftRadius: _tokens.tokens.borderRadiusNone
301
+ })
302
+ });
303
+ const useAttachmentStyles_unstable = (state)=>{
304
+ 'use no memo';
305
+ const rootBaseClassName = useRootBaseClassName();
306
+ const primaryActionBaseClassName = usePrimaryActionBaseClassName();
307
+ const dismissButtonBaseClassName = useDismissButtonBaseClassName();
308
+ const dismissButtonCurrentStyles = useDismissButtonCurrentStyles();
309
+ const mediaBaseClassName = useMediaBaseClassName();
310
+ const contentBaseClassName = useContentBaseClassName();
311
+ const dismissIconBaseClassName = useDismissIconBaseClassName();
312
+ const dismissIconNextStyles = useDismissIconNextStyles();
313
+ const progressBarStyles = (0, _useProgressBarStylesstyles.useProgressBarStyles)();
314
+ const primaryActionStyles = usePrimaryActionStyles();
315
+ const imageOnlyStyles = useImageOnlyStyles();
316
+ const smallStyles = useSmallStyles();
317
+ const primaryActionNextStyles = usePrimaryActionNextStyles();
318
+ const dismissButtonNextStyles = useDismissButtonNextStyles();
319
+ const primaryDismissNextStyles = usePrimaryDismissNextStyles();
320
+ const rootNextStyles = useRootNextStyles();
321
+ const focusStyles = useFocusStyles();
322
+ const { imageOnly, primaryAction, size, mode, designVersion, dismissOnly } = state;
323
+ state.root.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.root, rootBaseClassName, designVersion === 'next' && rootNextStyles.root, state.root.className);
324
+ state.primaryAction.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.primaryAction, primaryActionBaseClassName, size === 'small' && smallStyles.primaryAction, primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button, imageOnly && imageOnlyStyles.primaryAction, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryAction.as !== 'span' && !state.isLoading && primaryDismissNextStyles.sharedInteractiveStyles, designVersion === 'next' && primaryActionNextStyles.root, designVersion === 'next' && primaryActionNextStyles[mode], focusStyles.primaryActionButton, state.primaryAction.className);
325
+ state.dismissButton.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.dismissButton, dismissButtonBaseClassName, designVersion === 'current' && dismissButtonCurrentStyles.root, size === 'small' && smallStyles.dismissButton, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryDismissNextStyles.sharedInteractiveStyles, designVersion === 'next' && dismissButtonNextStyles.root, designVersion === 'next' && dismissButtonNextStyles[mode], designVersion === 'next' && dismissOnly && dismissButtonNextStyles.dismissOnly, designVersion === 'next' && !dismissOnly && dismissButtonNextStyles.withPrimary, focusStyles.dismissButton, state.dismissButton.className);
326
+ if (state.media) {
327
+ state.media.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.media, mediaBaseClassName, size === 'small' && smallStyles.media, state.media.className);
328
+ }
329
+ state.content.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.content, contentBaseClassName, size === 'small' && smallStyles.content, imageOnly && imageOnlyStyles.content, state.content.className);
330
+ state.dismissIcon.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.dismissIcon, dismissIconBaseClassName, size === 'small' && smallStyles.dismissIcon, designVersion === 'next' && dismissOnly && dismissIconNextStyles.dismissOnly, state.dismissIcon.className);
331
+ if (state.progress) {
332
+ state.progress.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.progress, progressBarStyles.progress, state.progress.className);
333
+ const bar = _reactcomponents.slot.optional(state.progress.bar, {
334
+ elementType: 'div',
335
+ renderByDefault: true
336
+ });
337
+ if (bar) {
338
+ if (state.progress.value === undefined) {
339
+ bar.className = (0, _reactcomponents.mergeClasses)(progressBarStyles.indeterminateProgressBar, bar.className);
340
+ } else {
341
+ bar.className = (0, _reactcomponents.mergeClasses)(progressBarStyles.regularProgressBar, bar.className);
342
+ }
343
+ state.progress.bar = bar;
344
+ }
345
+ }
346
+ return state;
347
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAttachmentStyles.styles.ts"],"sourcesContent":["import {\n createCustomFocusIndicatorStyle,\n makeResetStyles,\n makeStyles,\n mergeClasses,\n slot,\n typographyStyles,\n} from '@fluentui/react-components';\nimport { tokens } from '@fluentui-copilot/tokens';\nimport { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';\nimport type { AttachmentSlots, AttachmentState } from './Attachment.types';\nimport type { GriffelResetStyle, SlotClassNames } from '@fluentui/react-components';\n\nexport const attachmentClassNames: SlotClassNames<AttachmentSlots> = {\n root: 'fai-Attachment',\n primaryAction: 'fai-Attachment__primaryAction',\n dismissButton: 'fai-Attachment__dismissButton',\n media: 'fai-Attachment__media',\n content: 'fai-Attachment__content',\n dismissIcon: 'fai-Attachment__dismissIcon',\n progress: 'fai-Attachment__progress',\n};\n\nconst ATTACHMENT_MAXWIDTH = '180px';\nconst SMALL_ATTACHMENT_SIZE = '16px';\nconst ATTACHMENT_SIZE = '20px';\n\nconst useRootBaseClassName = makeResetStyles({\n display: 'inline-flex',\n flexWrap: 'nowrap',\n verticalAlign: 'middle',\n boxSizing: 'border-box',\n width: 'fit-content',\n alignSelf: 'end',\n position: 'relative',\n});\n\nconst buttonBaseStyles: GriffelResetStyle = {\n alignItems: 'center',\n backgroundColor: tokens.colorSubtleBackground,\n border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke1}`,\n borderRadius: tokens.borderRadiusMedium,\n boxSizing: 'border-box',\n columnGap: tokens.spacingHorizontalSNudge,\n color: tokens.colorNeutralForeground1,\n cursor: 'pointer',\n display: 'inline-flex',\n flexWrap: 'nowrap',\n justifyContent: 'center',\n ...createCustomFocusIndicatorStyle({\n outline: `${tokens.strokeWidthThick} solid ${tokens.colorStrokeFocus2}`,\n outlineOffset: `calc(${tokens.strokeWidthThick} * -1)`,\n zIndex: 1,\n }),\n verticalAlign: 'middle',\n};\n\nconst usePrimaryActionBaseClassName = makeResetStyles({\n ...buttonBaseStyles,\n borderTopRightRadius: tokens.borderRadiusNone,\n borderBottomRightRadius: tokens.borderRadiusNone,\n borderRightStyle: 'none',\n maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,\n padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS}`,\n});\n\nconst usePrimaryActionStyles = makeStyles({\n button: {\n ':hover': {\n cursor: 'pointer',\n backgroundColor: tokens.colorSubtleBackgroundHover,\n color: tokens.colorNeutralForeground2Hover,\n },\n ':active': {\n backgroundColor: tokens.colorSubtleBackgroundPressed,\n color: tokens.colorNeutralForeground2Pressed,\n },\n '@media (forced-colors: active)': {\n ':hover': {\n backgroundColor: 'HighlightText',\n },\n ':active': {\n backgroundColor: 'HighlightText',\n },\n },\n },\n});\n\nconst useDismissButtonBaseClassName = makeResetStyles({\n ...buttonBaseStyles,\n\n padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS}`,\n maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,\n minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,\n\n // divider:\n borderLeftColor: tokens.colorNeutralStroke1,\n borderTopLeftRadius: tokens.borderRadiusNone,\n borderBottomLeftRadius: tokens.borderRadiusNone,\n\n borderTopRightRadius: tokens.borderRadiusMedium,\n borderBottomRightRadius: tokens.borderRadiusMedium,\n\n ':hover': {\n cursor: 'pointer',\n backgroundColor: tokens.colorSubtleBackgroundHover,\n color: tokens.colorNeutralForeground2BrandHover,\n },\n ':active': {\n backgroundColor: tokens.colorSubtleBackgroundPressed,\n color: tokens.colorNeutralForeground2BrandPressed,\n },\n '@media (forced-colors: active)': {\n ':hover': {\n backgroundColor: 'HighlightText',\n },\n ':active': {\n backgroundColor: 'HighlightText',\n },\n },\n});\n\nconst useDismissButtonCurrentStyles = makeStyles({\n root: {\n ':hover': {\n [`& .${attachmentClassNames.dismissIcon}`]: {\n color: tokens.colorBrandForegroundLinkHover,\n },\n },\n },\n});\n\nconst useMediaBaseClassName = makeResetStyles({\n alignItems: 'center',\n display: 'inline-flex',\n fontSize: ATTACHMENT_SIZE,\n height: ATTACHMENT_SIZE,\n lineHeight: ATTACHMENT_SIZE,\n width: ATTACHMENT_SIZE,\n});\n\nconst useContentBaseClassName = makeResetStyles({\n overflowX: 'hidden',\n textOverflow: 'ellipsis',\n whiteSpace: 'nowrap',\n ...typographyStyles.body1,\n});\n\nconst useDismissIconBaseClassName = makeResetStyles({\n alignItems: 'center',\n borderRadius: tokens.borderRadiusCircular,\n border: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,\n boxSizing: 'border-box',\n color: tokens.colorNeutralForeground1,\n display: 'inline-flex',\n fontSize: ATTACHMENT_SIZE,\n height: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,\n justifyContent: 'center',\n maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,\n minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,\n padding: `calc(${tokens.spacingVerticalXXS} / 2) calc(${tokens.spacingHorizontalXXS} / 2)`,\n});\n\nconst useDismissIconNextStyles = makeStyles({\n dismissOnly: {\n ':hover': {\n color: tokens.colorNeutralForeground2BrandHover,\n },\n ':active': {\n color: tokens.colorNeutralForeground2BrandPressed,\n },\n },\n});\n\nconst useImageOnlyStyles = makeStyles({\n primaryAction: {\n padding: 0,\n },\n content: {\n lineHeight: 0,\n },\n});\n\nexport const useOverflowStyles = makeStyles({\n overflow: {\n maxWidth: '100%',\n width: '100%',\n },\n});\n\nconst useSmallStyles = makeStyles({\n primaryAction: {\n maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,\n padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge} ${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge}`,\n },\n media: {\n fontSize: SMALL_ATTACHMENT_SIZE,\n height: SMALL_ATTACHMENT_SIZE,\n lineHeight: SMALL_ATTACHMENT_SIZE,\n width: SMALL_ATTACHMENT_SIZE,\n },\n content: {\n ...typographyStyles.caption1,\n },\n dismissButton: {\n padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalXXS}`,\n maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,\n minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,\n },\n dismissIcon: {\n fontSize: SMALL_ATTACHMENT_SIZE,\n height: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,\n maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,\n minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,\n },\n});\n\nconst usePrimaryActionNextStyles = makeStyles({\n root: {\n borderTopLeftRadius: tokens.borderRadiusXLarge,\n borderBottomLeftRadius: tokens.borderRadiusXLarge,\n },\n canvas: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,\n minHeight: '40px',\n },\n\n sidecar: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,\n minHeight: '32px',\n },\n});\n\nconst useDismissButtonNextStyles = makeStyles({\n root: {\n borderTopRightRadius: tokens.borderRadiusXLarge,\n borderBottomRightRadius: tokens.borderRadiusXLarge,\n ':hover': {\n color: tokens.colorNeutralForeground2,\n },\n ':active': {\n color: tokens.colorNeutralForeground2Pressed,\n },\n\n borderLeftColor: tokens.colorNeutralStroke1,\n borderLeftWidth: tokens.strokeWidthThin,\n borderLeftStyle: 'solid',\n },\n withPrimary: {\n ':hover': {\n [`& .${attachmentClassNames.dismissIcon}`]: {\n color: tokens.colorNeutralForeground2,\n },\n },\n ':active': {\n [`& .${attachmentClassNames.dismissIcon}`]: {\n color: tokens.colorNeutralForeground2Pressed,\n },\n },\n },\n canvas: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,\n minHeight: '40px',\n width: '40px',\n },\n sidecar: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalMNudge}`,\n minHeight: '32px',\n width: '32px',\n },\n dismissOnly: {\n borderRadius: tokens.borderRadiusXLarge,\n width: 'unset',\n borderLeftColor: tokens.colorTransparentStroke,\n backgroundColor: tokens.colorNeutralBackground3,\n ':hover': {\n backgroundColor: tokens.colorNeutralBackground3,\n },\n ':active': {\n backgroundColor: tokens.colorNeutralBackground3,\n },\n },\n});\n\nconst usePrimaryDismissNextStyles = makeStyles({\n sharedStyles: {\n border: 'none',\n backgroundColor: tokens.colorNeutralBackground3,\n },\n sharedInteractiveStyles: {\n ':hover': {\n backgroundColor: tokens.colorNeutralBackground3Hover,\n },\n ':active': {\n backgroundColor: tokens.colorNeutralBackground3Pressed,\n },\n },\n});\n\nconst useRootNextStyles = makeStyles({\n root: {\n outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,\n borderRadius: tokens.borderRadiusXLarge,\n },\n});\n\nconst useFocusStyles = makeStyles({\n primaryActionButton: createCustomFocusIndicatorStyle({\n borderTopRightRadius: tokens.borderRadiusNone,\n borderBottomRightRadius: tokens.borderRadiusNone,\n }),\n\n dismissButton: createCustomFocusIndicatorStyle({\n borderTopLeftRadius: tokens.borderRadiusNone,\n borderBottomLeftRadius: tokens.borderRadiusNone,\n }),\n});\n\n/**\n * Apply styling to the Attachment slots based on the state\n */\nexport const useAttachmentStyles_unstable = (state: AttachmentState): AttachmentState => {\n 'use no memo';\n\n const rootBaseClassName = useRootBaseClassName();\n const primaryActionBaseClassName = usePrimaryActionBaseClassName();\n const dismissButtonBaseClassName = useDismissButtonBaseClassName();\n const dismissButtonCurrentStyles = useDismissButtonCurrentStyles();\n const mediaBaseClassName = useMediaBaseClassName();\n const contentBaseClassName = useContentBaseClassName();\n const dismissIconBaseClassName = useDismissIconBaseClassName();\n const dismissIconNextStyles = useDismissIconNextStyles();\n const progressBarStyles = useProgressBarStyles();\n const primaryActionStyles = usePrimaryActionStyles();\n const imageOnlyStyles = useImageOnlyStyles();\n const smallStyles = useSmallStyles();\n const primaryActionNextStyles = usePrimaryActionNextStyles();\n const dismissButtonNextStyles = useDismissButtonNextStyles();\n const primaryDismissNextStyles = usePrimaryDismissNextStyles();\n const rootNextStyles = useRootNextStyles();\n const focusStyles = useFocusStyles();\n const { imageOnly, primaryAction, size, mode, designVersion, dismissOnly } = state;\n\n state.root.className = mergeClasses(\n attachmentClassNames.root,\n rootBaseClassName,\n designVersion === 'next' && rootNextStyles.root,\n state.root.className,\n );\n state.primaryAction.className = mergeClasses(\n attachmentClassNames.primaryAction,\n primaryActionBaseClassName,\n size === 'small' && smallStyles.primaryAction,\n primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button,\n imageOnly && imageOnlyStyles.primaryAction,\n designVersion === 'next' && primaryDismissNextStyles.sharedStyles,\n designVersion === 'next' &&\n primaryAction.as !== 'span' &&\n !state.isLoading &&\n primaryDismissNextStyles.sharedInteractiveStyles,\n designVersion === 'next' && primaryActionNextStyles.root,\n designVersion === 'next' && primaryActionNextStyles[mode],\n focusStyles.primaryActionButton,\n state.primaryAction.className,\n );\n state.dismissButton.className = mergeClasses(\n attachmentClassNames.dismissButton,\n dismissButtonBaseClassName,\n designVersion === 'current' && dismissButtonCurrentStyles.root,\n size === 'small' && smallStyles.dismissButton,\n designVersion === 'next' && primaryDismissNextStyles.sharedStyles,\n designVersion === 'next' && primaryDismissNextStyles.sharedInteractiveStyles,\n designVersion === 'next' && dismissButtonNextStyles.root,\n designVersion === 'next' && dismissButtonNextStyles[mode],\n designVersion === 'next' && dismissOnly && dismissButtonNextStyles.dismissOnly,\n designVersion === 'next' && !dismissOnly && dismissButtonNextStyles.withPrimary,\n focusStyles.dismissButton,\n state.dismissButton.className,\n );\n if (state.media) {\n state.media.className = mergeClasses(\n attachmentClassNames.media,\n mediaBaseClassName,\n size === 'small' && smallStyles.media,\n state.media.className,\n );\n }\n state.content.className = mergeClasses(\n attachmentClassNames.content,\n contentBaseClassName,\n size === 'small' && smallStyles.content,\n imageOnly && imageOnlyStyles.content,\n state.content.className,\n );\n state.dismissIcon.className = mergeClasses(\n attachmentClassNames.dismissIcon,\n dismissIconBaseClassName,\n size === 'small' && smallStyles.dismissIcon,\n designVersion === 'next' && dismissOnly && dismissIconNextStyles.dismissOnly,\n state.dismissIcon.className,\n );\n\n if (state.progress) {\n state.progress.className = mergeClasses(\n attachmentClassNames.progress,\n progressBarStyles.progress,\n state.progress.className,\n );\n\n const bar = slot.optional(state.progress.bar, { elementType: 'div', renderByDefault: true });\n if (bar) {\n if (state.progress.value === undefined) {\n bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);\n } else {\n bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);\n }\n state.progress.bar = bar;\n }\n }\n\n return state;\n};\n"],"names":["attachmentClassNames","useAttachmentStyles_unstable","useOverflowStyles","root","primaryAction","dismissButton","media","content","dismissIcon","progress","ATTACHMENT_MAXWIDTH","SMALL_ATTACHMENT_SIZE","ATTACHMENT_SIZE","useRootBaseClassName","makeResetStyles","display","flexWrap","verticalAlign","boxSizing","width","alignSelf","position","buttonBaseStyles","alignItems","backgroundColor","tokens","colorSubtleBackground","border","strokeWidthThin","colorNeutralStroke1","borderRadius","borderRadiusMedium","columnGap","spacingHorizontalSNudge","color","colorNeutralForeground1","cursor","justifyContent","createCustomFocusIndicatorStyle","outline","strokeWidthThick","colorStrokeFocus2","outlineOffset","zIndex","usePrimaryActionBaseClassName","borderTopRightRadius","borderRadiusNone","borderBottomRightRadius","borderRightStyle","maxWidth","spacingHorizontalXXS","spacingHorizontalXS","padding","spacingVerticalXS","spacingHorizontalS","usePrimaryActionStyles","makeStyles","button","colorSubtleBackgroundHover","colorNeutralForeground2Hover","colorSubtleBackgroundPressed","colorNeutralForeground2Pressed","useDismissButtonBaseClassName","minWidth","borderLeftColor","borderTopLeftRadius","borderBottomLeftRadius","colorNeutralForeground2BrandHover","colorNeutralForeground2BrandPressed","useDismissButtonCurrentStyles","colorBrandForegroundLinkHover","useMediaBaseClassName","fontSize","height","lineHeight","useContentBaseClassName","overflowX","textOverflow","whiteSpace","typographyStyles","body1","useDismissIconBaseClassName","borderRadiusCircular","colorTransparentStroke","spacingVerticalXXS","useDismissIconNextStyles","dismissOnly","useImageOnlyStyles","overflow","useSmallStyles","caption1","usePrimaryActionNextStyles","borderRadiusXLarge","canvas","spacingVerticalNone","minHeight","sidecar","useDismissButtonNextStyles","colorNeutralForeground2","borderLeftWidth","borderLeftStyle","withPrimary","spacingHorizontalMNudge","colorNeutralBackground3","usePrimaryDismissNextStyles","sharedStyles","sharedInteractiveStyles","colorNeutralBackground3Hover","colorNeutralBackground3Pressed","useRootNextStyles","useFocusStyles","primaryActionButton","state","rootBaseClassName","primaryActionBaseClassName","dismissButtonBaseClassName","dismissButtonCurrentStyles","mediaBaseClassName","contentBaseClassName","dismissIconBaseClassName","dismissIconNextStyles","progressBarStyles","useProgressBarStyles","primaryActionStyles","imageOnlyStyles","smallStyles","primaryActionNextStyles","dismissButtonNextStyles","primaryDismissNextStyles","rootNextStyles","focusStyles","imageOnly","size","mode","designVersion","className","mergeClasses","as","isLoading","bar","slot","optional","elementType","renderByDefault","value","undefined","indeterminateProgressBar","regularProgressBar"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAaaA,oBAAAA;eAAAA;;IAoTAC,4BAAAA;eAAAA;;IA1IAC,iBAAAA;eAAAA;;;iCAhLN;wBACgB;4CACc;AAI9B,MAAMF,uBAAwD;IACnEG,MAAM;IACNC,eAAe;IACfC,eAAe;IACfC,OAAO;IACPC,SAAS;IACTC,aAAa;IACbC,UAAU;AACZ;AAEA,MAAMC,sBAAsB;AAC5B,MAAMC,wBAAwB;AAC9B,MAAMC,kBAAkB;AAExB,MAAMC,uBAAuBC,IAAAA,gCAAAA,EAAgB;IAC3CC,SAAS;IACTC,UAAU;IACVC,eAAe;IACfC,WAAW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CAAC8H,SAAS;QAG1B,MAAMI,MAAMC,qBAAAA,CAAKC,QAAQ,CAAC7B,MAAMvG,QAAQ,CAACkI,GAAG,EAAE;YAAEG,aAAa;YAAOC,iBAAiB;QAAK;QAC1F,IAAIJ,KAAK;YACP,IAAI3B,MAAMvG,QAAQ,CAACuI,KAAK,KAAKC,WAAW;gBACtCN,IAAIJ,SAAS,GAAGC,IAAAA,6BAAAA,EAAaf,kBAAkByB,wBAAwB,EAAEP,IAAIJ,SAAS;YACxF,OAAO;gBACLI,IAAIJ,SAAS,GAAGC,IAAAA,6BAAAA,EAAaf,kBAAkB0B,kBAAkB,EAAER,IAAIJ,SAAS;YAClF;YACAvB,MAAMvG,QAAQ,CAACkI,GAAG,GAAGA;QACvB;IACF;IAEA,OAAO3B;AACT"}
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "AttachmentList", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return AttachmentList;
9
+ }
10
+ });
11
+ const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
12
+ const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
13
+ const _useAttachmentList = require("./useAttachmentList");
14
+ const _renderAttachmentList = require("./renderAttachmentList");
15
+ const _useAttachmentListStylesstyles = require("./useAttachmentListStyles.styles");
16
+ const _useAttachmentListContextValues = require("./useAttachmentListContextValues");
17
+ const _reactprovider = require("@fluentui-copilot/react-provider");
18
+ const AttachmentList = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
19
+ const state = (0, _useAttachmentList.useAttachmentList_unstable)(props, ref);
20
+ const contextValues = (0, _useAttachmentListContextValues.useAttachmentListContextValues_unstable)(state);
21
+ (0, _useAttachmentListStylesstyles.useAttachmentListStyles_unstable)(state);
22
+ (0, _reactprovider.useCustomStyleHook)('useAttachmentListStyles')(state);
23
+ return (0, _renderAttachmentList.renderAttachmentList_unstable)(state, contextValues);
24
+ });
25
+ AttachmentList.displayName = 'AttachmentList';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["AttachmentList.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAttachmentList_unstable } from './useAttachmentList';\nimport { renderAttachmentList_unstable } from './renderAttachmentList';\nimport { useAttachmentListStyles_unstable } from './useAttachmentListStyles.styles';\nimport { useAttachmentListContextValues_unstable } from './useAttachmentListContextValues';\nimport type { AttachmentListProps } from './AttachmentList.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\nexport const AttachmentList: ForwardRefComponent<AttachmentListProps> = React.forwardRef((props, ref) => {\n const state = useAttachmentList_unstable(props, ref);\n const contextValues = useAttachmentListContextValues_unstable(state);\n\n useAttachmentListStyles_unstable(state);\n useCustomStyleHook('useAttachmentListStyles')(state);\n\n return renderAttachmentList_unstable(state, contextValues);\n});\n\nAttachmentList.displayName = 'AttachmentList';\n"],"names":["AttachmentList","React","forwardRef","props","ref","state","useAttachmentList_unstable","contextValues","useAttachmentListContextValues_unstable","useAttachmentListStyles_unstable","useCustomStyleHook","renderAttachmentList_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;;iEATU;mCACoB;sCACG;+CACG;gDACO;+BAGrB;AAE5B,MAAMA,iBAAAA,WAAAA,GAA2DC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IAC/F,MAAMC,QAAQC,IAAAA,6CAAAA,EAA2BH,OAAOC;IAChD,MAAMG,gBAAgBC,IAAAA,uEAAAA,EAAwCH;IAE9DI,IAAAA,+DAAAA,EAAiCJ;IACjCK,IAAAA,iCAAAA,EAAmB,2BAA2BL;IAE9C,OAAOM,IAAAA,mDAAAA,EAA8BN,OAAOE;AAC9C;AAEAP,eAAeY,WAAW,GAAG"}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["AttachmentList.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, MenuList, MenuPopover, Slot } from '@fluentui/react-components';\nimport type { AttachmentListContextValue } from '../../contexts/attachmentListContext';\nimport type { AttachmentProps } from '../Attachment';\nimport type { AttachmentOverflowMenuProps } from '../AttachmentOverflowMenu';\nimport type { DesignVersion } from '@fluentui-copilot/react-provider';\n\nexport type AttachmentListSlots = {\n root: Slot<'div'>;\n menuList?: Slot<typeof MenuList>;\n menuPopover?: Slot<typeof MenuPopover>;\n\n /**\n * An AttachmentList has an overflow menu when `maxVisibleAttachments` is exceeded.\n * Adding a custom button for the overflow menu is supported.\n */\n overflowMenuButton: Slot<'span'>;\n};\n\nexport type AttachmentDismissedData = {\n content?: AttachmentProps['children'];\n media?: AttachmentProps['media'];\n id?: string;\n};\n\n/**\n * AttachmentList Props\n */\nexport type AttachmentListProps = ComponentProps<Partial<AttachmentListSlots>> &\n DesignVersion & {\n /**\n * Callback fired when an attachment is dismissed.\n */\n onAttachmentDismiss?: (\n e: React.MouseEvent<HTMLAnchorElement | HTMLButtonElement | HTMLDivElement>,\n data: AttachmentDismissedData,\n ) => void;\n\n /**\n * Props that will be passed to the overflow menu.\n */\n overflowMenuProps?: Omit<AttachmentOverflowMenuProps, 'children'>;\n\n /**\n * The maximum number of attachments to display before the overflow button is shown even if there is\n * enough space available to show more.\n * If not set, the overflow functionality will be disabled.\n * @default undefined\n */\n maxVisibleAttachments?: number;\n };\n\n/**\n * State used in rendering AttachmentList\n */\nexport type AttachmentListState = ComponentState<AttachmentListSlots> &\n Pick<AttachmentListProps, 'onAttachmentDismiss' | 'overflowMenuProps' | 'designVersion'> & {\n shouldUseOverflow: boolean;\n numberOfAttachments: number;\n };\n\nexport type AttachmentListContextValues = {\n attachmentList: AttachmentListContextValue;\n};\n"],"names":[],"rangeMappings":"","mappings":""}
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: all[name]
9
+ });
10
+ }
11
+ _export(exports, {
12
+ AttachmentList: function() {
13
+ return _AttachmentList.AttachmentList;
14
+ },
15
+ attachmentListClassNames: function() {
16
+ return _useAttachmentListStylesstyles.attachmentListClassNames;
17
+ },
18
+ renderAttachmentList_unstable: function() {
19
+ return _renderAttachmentList.renderAttachmentList_unstable;
20
+ },
21
+ useAttachmentListStyles_unstable: function() {
22
+ return _useAttachmentListStylesstyles.useAttachmentListStyles_unstable;
23
+ },
24
+ useAttachmentList_unstable: function() {
25
+ return _useAttachmentList.useAttachmentList_unstable;
26
+ }
27
+ });
28
+ const _AttachmentList = require("./AttachmentList");
29
+ const _renderAttachmentList = require("./renderAttachmentList");
30
+ const _useAttachmentList = require("./useAttachmentList");
31
+ const _useAttachmentListStylesstyles = require("./useAttachmentListStyles.styles");
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export { AttachmentList } from './AttachmentList';\nexport type { AttachmentDismissedData, AttachmentListContextValues, AttachmentListProps, AttachmentListSlots, AttachmentListState } from './AttachmentList.types';\nexport { renderAttachmentList_unstable } from './renderAttachmentList';\nexport { useAttachmentList_unstable } from './useAttachmentList';\nexport { attachmentListClassNames, useAttachmentListStyles_unstable } from './useAttachmentListStyles.styles';\n"],"names":["AttachmentList","attachmentListClassNames","renderAttachmentList_unstable","useAttachmentListStyles_unstable","useAttachmentList_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,cAAc;eAAdA,8BAAc;;IAIdC,wBAAwB;eAAxBA,uDAAwB;;IAFxBC,6BAA6B;eAA7BA,mDAA6B;;IAEHC,gCAAgC;eAAhCA,+DAAgC;;IAD1DC,0BAA0B;eAA1BA,6CAA0B;;;gCAHJ;sCAEe;mCACH;+CACgC"}
@@ -0,0 +1,39 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "renderAttachmentList_unstable", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return renderAttachmentList_unstable;
9
+ }
10
+ });
11
+ const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
12
+ const _reactcomponents = require("@fluentui/react-components");
13
+ const _attachmentListContext = require("../../contexts/attachmentListContext");
14
+ const _AttachmentOverflowMenu = require("../AttachmentOverflowMenu");
15
+ const renderAttachmentList_unstable = (state, contextValues)=>{
16
+ (0, _reactcomponents.assertSlots)(state);
17
+ const { overflowMenuProps, root, shouldUseOverflow } = state;
18
+ return /*#__PURE__*/ (0, _jsxruntime.jsx)(_attachmentListContext.AttachmentListProvider, {
19
+ value: contextValues.attachmentList,
20
+ children: shouldUseOverflow && state.overflowMenuButton && state.menuList && state.menuPopover ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_reactcomponents.Overflow, {
21
+ ref: root.ref,
22
+ children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(state.root, {
23
+ children: [
24
+ root.children,
25
+ /*#__PURE__*/ (0, _jsxruntime.jsxs)(_AttachmentOverflowMenu.AttachmentOverflowMenu, {
26
+ positioning: 'above',
27
+ ...overflowMenuProps,
28
+ children: [
29
+ /*#__PURE__*/ (0, _jsxruntime.jsx)(state.overflowMenuButton, {}),
30
+ /*#__PURE__*/ (0, _jsxruntime.jsx)(state.menuPopover, {
31
+ children: /*#__PURE__*/ (0, _jsxruntime.jsx)(state.menuList, {})
32
+ })
33
+ ]
34
+ })
35
+ ]
36
+ })
37
+ }) : /*#__PURE__*/ (0, _jsxruntime.jsx)(state.root, {})
38
+ });
39
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["renderAttachmentList.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { Overflow, assertSlots } from '@fluentui/react-components';\nimport type { JSXElement } from '@fluentui/react-components';\nimport { AttachmentListProvider } from '../../contexts/attachmentListContext';\nimport { AttachmentOverflowMenu } from '../AttachmentOverflowMenu';\nimport type { AttachmentListState, AttachmentListSlots, AttachmentListContextValues } from './AttachmentList.types';\n\n/**\n * Render the final JSX of AttachmentList\n */\nexport const renderAttachmentList_unstable = (\n state: AttachmentListState,\n contextValues: AttachmentListContextValues,\n): JSXElement => {\n assertSlots<AttachmentListSlots>(state);\n const { overflowMenuProps, root, shouldUseOverflow } = state;\n\n return (\n <AttachmentListProvider value={contextValues.attachmentList}>\n {shouldUseOverflow && state.overflowMenuButton && state.menuList && state.menuPopover ? (\n <Overflow ref={root.ref}>\n <state.root>\n {root.children}\n <AttachmentOverflowMenu positioning={'above'} {...overflowMenuProps}>\n <state.overflowMenuButton />\n <state.menuPopover>\n <state.menuList />\n </state.menuPopover>\n </AttachmentOverflowMenu>\n </state.root>\n </Overflow>\n ) : (\n <state.root />\n )}\n </AttachmentListProvider>\n );\n};\n"],"names":["renderAttachmentList_unstable","state","contextValues","assertSlots","overflowMenuProps","root","shouldUseOverflow","_jsx","AttachmentListProvider","value","attachmentList","overflowMenuButton","menuList","menuPopover","Overflow","ref","_jsxs","children","AttachmentOverflowMenu","positioning"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAYaA;;;eAAAA;;;4BAXb;iCAEsC;uCAEC;wCACA;AAMhC,MAAMA,gCAAgC,CAC3CC,OACAC;IAEAC,IAAAA,4BAAAA,EAAiCF;IACjC,MAAM,EAAEG,iBAAiB,EAAEC,IAAI,EAAEC,iBAAiB,EAAE,GAAGL;IAEvD,OAAA,WAAA,GACEM,IAAAA,eAAA,EAACC,6CAAAA,EAAAA;QAAuBC,OAAOP,cAAcQ,cAAc;kBACxDJ,qBAAqBL,MAAMU,kBAAkB,IAAIV,MAAMW,QAAQ,IAAIX,MAAMY,WAAW,GAAA,WAAA,GACnFN,IAAAA,eAAA,EAACO,yBAAAA,EAAAA;YAASC,KAAKV,KAAKU,GAAG;sBACrB,WAAA,GAAAC,IAAAA,gBAAA,EAACf,MAAMI,IAAI,EAAA;;oBACRA,KAAKY,QAAQ;kCACdD,IAAAA,gBAAA,EAACE,8CAAAA,EAAAA;wBAAuBC,aAAa;wBAAU,GAAGf,iBAAiB;;0CACjEG,IAAAA,eAAA,EAACN,MAAMU,kBAAkB,EAAA,CAAA;0CACzBJ,IAAAA,eAAA,EAACN,MAAMY,WAAW,EAAA;0CAChB,WAAA,GAAAN,IAAAA,eAAA,EAACN,MAAMW,QAAQ,EAAA,CAAA;;;;;;2BAMvBL,IAAAA,eAAA,EAACN,MAAMI,IAAI,EAAA,CAAA;;AAInB"}