@fluentui-copilot/react-attachments 0.0.0-nightly-20251010-0406-7df7c6d1.1 → 0.0.0-nightly-20251014-0405-d8d3e89c.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 +42 -3
  2. package/CHANGELOG.md +17 -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,102 @@
1
+ import { makeResetStyles, makeStyles, mergeClasses, shorthands, slot } from '@fluentui/react-components';
2
+ import { tokens, typographyStyles } from '@fluentui-copilot/tokens';
3
+ import { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';
4
+ export const attachmentOverflowMenuButtonClassNames = {
5
+ root: 'fai-AttachmentOverflowMenuButton',
6
+ progress: 'fai-AttachmentOverflowMenuButton__progress'
7
+ };
8
+ const useRootBaseClassName = makeResetStyles({
9
+ color: tokens.colorNeutralForeground1,
10
+ alignItems: 'center',
11
+ backgroundColor: tokens.colorSubtleBackground,
12
+ border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke1}`,
13
+ borderRadius: tokens.borderRadiusMedium,
14
+ boxSizing: 'border-box',
15
+ columnGap: tokens.spacingHorizontalSNudge,
16
+ cursor: 'pointer',
17
+ display: 'inline-flex',
18
+ flexWrap: 'nowrap',
19
+ fontFamily: typographyStyles.body1.fontFamily,
20
+ fontSize: typographyStyles.body1.fontSize,
21
+ fontWeight: typographyStyles.body1.fontWeight,
22
+ justifyContent: 'center',
23
+ padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS}`,
24
+ verticalAlign: 'middle',
25
+ position: 'relative',
26
+ ':hover': {
27
+ cursor: 'pointer',
28
+ backgroundColor: tokens.colorSubtleBackgroundHover,
29
+ color: tokens.colorNeutralForeground2Hover
30
+ },
31
+ ':active': {
32
+ backgroundColor: tokens.colorSubtleBackgroundPressed,
33
+ color: tokens.colorNeutralForeground2Pressed
34
+ },
35
+ '@media (forced-colors: active)': {
36
+ ':hover': {
37
+ backgroundColor: 'HighlightText'
38
+ },
39
+ ':active': {
40
+ backgroundColor: 'HighlightText'
41
+ }
42
+ }
43
+ });
44
+ const useNextStyles = makeStyles({
45
+ root: {
46
+ borderRadius: tokens.borderRadiusXLarge,
47
+ ...shorthands.borderColor(tokens.colorTransparentStroke),
48
+ color: tokens.colorNeutralForeground2,
49
+ backgroundColor: tokens.colorNeutralBackground3,
50
+ ':hover': {
51
+ cursor: 'pointer',
52
+ color: tokens.colorNeutralForeground2Hover,
53
+ backgroundColor: tokens.colorNeutralBackground3Hover
54
+ },
55
+ ':active': {
56
+ color: tokens.colorNeutralForeground2Pressed,
57
+ backgroundColor: tokens.colorNeutralBackground3Pressed
58
+ }
59
+ },
60
+ canvas: {
61
+ minHeight: '40px',
62
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`
63
+ },
64
+ sidecar: {
65
+ minHeight: '32px',
66
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`
67
+ },
68
+ fullyOverflowed_canvas: {
69
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalL}`,
70
+ ...typographyStyles.subtitle2
71
+ },
72
+ fullyOverflowed_sidecar: {
73
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalM}`,
74
+ ...typographyStyles.body1Strong
75
+ }
76
+ });
77
+ /**
78
+ * Apply styling to the AttachmentOverflowMenuButton slots based on the state
79
+ */ export const useAttachmentOverflowMenuButtonStyles_unstable = (state)=>{
80
+ 'use no memo';
81
+ const { designVersion, mode, fullyOverflowed } = state;
82
+ const rootBaseClassName = useRootBaseClassName();
83
+ const progressBarStyles = useProgressBarStyles();
84
+ const nextStyles = useNextStyles();
85
+ state.root.className = mergeClasses(attachmentOverflowMenuButtonClassNames.root, rootBaseClassName, designVersion === 'next' && nextStyles.root, designVersion === 'next' && nextStyles[mode], designVersion === 'next' && fullyOverflowed && nextStyles[`fullyOverflowed_${mode}`], state.root.className);
86
+ if (state.progress) {
87
+ state.progress.className = mergeClasses(attachmentOverflowMenuButtonClassNames.progress, progressBarStyles.progress, state.progress.className);
88
+ const bar = slot.optional(state.progress.bar, {
89
+ elementType: 'div',
90
+ renderByDefault: true
91
+ });
92
+ if (bar) {
93
+ if (state.progress.value === undefined) {
94
+ bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);
95
+ } else {
96
+ bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);
97
+ }
98
+ state.progress.bar = bar;
99
+ }
100
+ }
101
+ return state;
102
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAttachmentOverflowMenuButtonStyles.styles.ts"],"sourcesContent":["import { makeResetStyles, makeStyles, mergeClasses, shorthands, slot } from '@fluentui/react-components';\nimport { tokens, typographyStyles } from '@fluentui-copilot/tokens';\nimport { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';\nimport type {\n AttachmentOverflowMenuButtonSlots,\n AttachmentOverflowMenuButtonState,\n} from './AttachmentOverflowMenuButton.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\n\nexport const attachmentOverflowMenuButtonClassNames: SlotClassNames<AttachmentOverflowMenuButtonSlots> = {\n root: 'fai-AttachmentOverflowMenuButton',\n progress: 'fai-AttachmentOverflowMenuButton__progress',\n};\n\nconst useRootBaseClassName = makeResetStyles({\n color: tokens.colorNeutralForeground1,\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 cursor: 'pointer',\n display: 'inline-flex',\n flexWrap: 'nowrap',\n fontFamily: typographyStyles.body1.fontFamily,\n fontSize: typographyStyles.body1.fontSize,\n fontWeight: typographyStyles.body1.fontWeight,\n justifyContent: 'center',\n padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS}`,\n verticalAlign: 'middle',\n position: 'relative',\n\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\nconst useNextStyles = makeStyles({\n root: {\n borderRadius: tokens.borderRadiusXLarge,\n ...shorthands.borderColor(tokens.colorTransparentStroke),\n color: tokens.colorNeutralForeground2,\n backgroundColor: tokens.colorNeutralBackground3,\n ':hover': {\n cursor: 'pointer',\n color: tokens.colorNeutralForeground2Hover,\n backgroundColor: tokens.colorNeutralBackground3Hover,\n },\n ':active': {\n color: tokens.colorNeutralForeground2Pressed,\n backgroundColor: tokens.colorNeutralBackground3Pressed,\n },\n },\n canvas: {\n minHeight: '40px',\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,\n },\n sidecar: {\n minHeight: '32px',\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,\n },\n fullyOverflowed_canvas: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalL}`,\n ...typographyStyles.subtitle2,\n },\n fullyOverflowed_sidecar: {\n padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalM}`,\n ...typographyStyles.body1Strong,\n },\n});\n\n/**\n * Apply styling to the AttachmentOverflowMenuButton slots based on the state\n */\nexport const useAttachmentOverflowMenuButtonStyles_unstable = (\n state: AttachmentOverflowMenuButtonState,\n): AttachmentOverflowMenuButtonState => {\n 'use no memo';\n\n const { designVersion, mode, fullyOverflowed } = state;\n\n const rootBaseClassName = useRootBaseClassName();\n const progressBarStyles = useProgressBarStyles();\n const nextStyles = useNextStyles();\n\n state.root.className = mergeClasses(\n attachmentOverflowMenuButtonClassNames.root,\n rootBaseClassName,\n designVersion === 'next' && nextStyles.root,\n designVersion === 'next' && nextStyles[mode],\n designVersion === 'next' && fullyOverflowed && nextStyles[`fullyOverflowed_${mode}`],\n state.root.className,\n );\n\n if (state.progress) {\n state.progress.className = mergeClasses(\n attachmentOverflowMenuButtonClassNames.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":["makeResetStyles","makeStyles","mergeClasses","shorthands","slot","tokens","typographyStyles","useProgressBarStyles","attachmentOverflowMenuButtonClassNames","root","progress","useRootBaseClassName","color","colorNeutralForeground1","alignItems","backgroundColor","colorSubtleBackground","border","strokeWidthThin","colorNeutralStroke1","borderRadius","borderRadiusMedium","boxSizing","columnGap","spacingHorizontalSNudge","cursor","display","flexWrap","fontFamily","body1","fontSize","fontWeight","justifyContent","padding","spacingVerticalXS","spacingHorizontalS","verticalAlign","position","colorSubtleBackgroundHover","colorNeutralForeground2Hover","colorSubtleBackgroundPressed","colorNeutralForeground2Pressed","useNextStyles","borderRadiusXLarge","borderColor","colorTransparentStroke","colorNeutralForeground2","colorNeutralBackground3","colorNeutralBackground3Hover","colorNeutralBackground3Pressed","canvas","minHeight","spacingVerticalNone","sidecar","fullyOverflowed_canvas","spacingHorizontalL","subtitle2","fullyOverflowed_sidecar","spacingHorizontalM","body1Strong","useAttachmentOverflowMenuButtonStyles_unstable","state","designVersion","mode","fullyOverflowed","rootBaseClassName","progressBarStyles","nextStyles","className","bar","optional","elementType","renderByDefault","value","undefined","indeterminateProgressBar","regularProgressBar"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,eAAe,EAAEC,UAAU,EAAEC,YAAY,EAAEC,UAAU,EAAEC,IAAI,QAAQ,6BAA6B;AACzG,SAASC,MAAM,EAAEC,gBAAgB,QAAQ,2BAA2B;AACpE,SAASC,oBAAoB,QAAQ,uCAAuC;AAO5E,OAAO,MAAMC,yCAA4F;IACvGC,MAAM;IACNC,UAAU;AACZ,EAAE;AAEF,MAAMC,uBAAuBX,gBAAgB;IAC3CY,OAAOP,OAAOQ,uBAAuB;IACrCC,YAAY;IACZC,iBAAiBV,OAAOW,qBAAqB;IAC7CC,QAAQ,CAAC,EAAEZ,OAAOa,eAAe,CAAC,OAAO,EAAEb,OAAOc,mBAAmB,CAAC,CAAC;IACvEC,cAAcf,OAAOgB,kBAAkB;IACvCC,WAAW;IACXC,WAAWlB,OAAOmB,uBAAuB;IACzCC,QAAQ;IACRC,SAAS;IACTC,UAAU;IACVC,YAAYtB,iBAAiBuB,KAAK,CAACD,UAAU;IAC7CE,UAAUxB,iBAAiBuB,KAAK,CAACC,QAAQ;IACzCC,YAAYzB,iBAAiBuB,KAAK,CAACE,UAAU;IAC7CC,gBAAgB;IAChBC,SAAS,CAAC,EAAE5B,OAAO6B,iBAAiB,CAAC,CAAC,EAAE7B,OAAO8B,kBAAkB,CAAC,CAAC;IACnEC,eAAe;IACfC,UAAU;IAEV,UAAU;QACRZ,QAAQ;QACRV,iBAAiBV,OAAOiC,0BAA0B;QAClD1B,OAAOP,OAAOkC,4BAA4B;IAC5C;IACA,WAAW;QACTxB,iBAAiBV,OAAOmC,4BAA4B;QACpD5B,OAAOP,OAAOoC,8BAA8B;IAC9C;IACA,kCAAkC;QAChC,UAAU;YACR1B,iBAAiB;QACnB;QACA,WAAW;YACTA,iBAAiB;QACnB;IACF;AACF;AAEA,MAAM2B,gBAAgBzC,WAAW;IAC/BQ,MAAM;QACJW,cAAcf,OAAOsC,kBAAkB;QACvC,GAAGxC,WAAWyC,WAAW,CAACvC,OAAOwC,sBAAsB,CAAC;QACxDjC,OAAOP,OAAOyC,uBAAuB;QACrC/B,iBAAiBV,OAAO0C,uBAAuB;QAC/C,UAAU;YACRtB,QAAQ;YACRb,OAAOP,OAAOkC,4BAA4B;YAC1CxB,iBAAiBV,OAAO2C,4BAA4B;QACtD;QACA,WAAW;YACTpC,OAAOP,OAAOoC,8BAA8B;YAC5C1B,iBAAiBV,OAAO4C,8BAA8B;QACxD;IACF;IACAC,QAAQ;QACNC,WAAW;QACXlB,SAAS,CAAC,EAAE5B,OAAO+C,mBAAmB,CAAC,CAAC,EAAE/C,OAAO8B,kBAAkB,CAAC,CAAC;IACvE;IACAkB,SAAS;QACPF,WAAW;QACXlB,SAAS,CAAC,EAAE5B,OAAO+C,mBAAmB,CAAC,CAAC,EAAE/C,OAAO8B,kBAAkB,CAAC,CAAC;IACvE;IACAmB,wBAAwB;QACtBrB,SAAS,CAAC,EAAE5B,OAAO+C,mBAAmB,CAAC,CAAC,EAAE/C,OAAOkD,kBAAkB,CAAC,CAAC;QACrE,GAAGjD,iBAAiBkD,SAAS;IAC/B;IACAC,yBAAyB;QACvBxB,SAAS,CAAC,EAAE5B,OAAO+C,mBAAmB,CAAC,CAAC,EAAE/C,OAAOqD,kBAAkB,CAAC,CAAC;QACrE,GAAGpD,iBAAiBqD,WAAW;IACjC;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,iDAAiD,CAC5DC;IAEA;IAEA,MAAM,EAAEC,aAAa,EAAEC,IAAI,EAAEC,eAAe,EAAE,GAAGH;IAEjD,MAAMI,oBAAoBtD;IAC1B,MAAMuD,oBAAoB3D;IAC1B,MAAM4D,aAAazB;IAEnBmB,MAAMpD,IAAI,CAAC2D,SAAS,GAAGlE,aACrBM,uCAAuCC,IAAI,EAC3CwD,mBACAH,kBAAkB,UAAUK,WAAW1D,IAAI,EAC3CqD,kBAAkB,UAAUK,UAAU,CAACJ,KAAK,EAC5CD,kBAAkB,UAAUE,mBAAmBG,UAAU,CAAC,CAAC,gBAAgB,EAAEJ,KAAK,CAAC,CAAC,EACpFF,MAAMpD,IAAI,CAAC2D,SAAS;IAGtB,IAAIP,MAAMnD,QAAQ,EAAE;QAClBmD,MAAMnD,QAAQ,CAAC0D,SAAS,GAAGlE,aACzBM,uCAAuCE,QAAQ,EAC/CwD,kBAAkBxD,QAAQ,EAC1BmD,MAAMnD,QAAQ,CAAC0D,SAAS;QAG1B,MAAMC,MAAMjE,KAAKkE,QAAQ,CAACT,MAAMnD,QAAQ,CAAC2D,GAAG,EAAE;YAAEE,aAAa;YAAOC,iBAAiB;QAAK;QAC1F,IAAIH,KAAK;YACP,IAAIR,MAAMnD,QAAQ,CAAC+D,KAAK,KAAKC,WAAW;gBACtCL,IAAID,SAAS,GAAGlE,aAAagE,kBAAkBS,wBAAwB,EAAEN,IAAID,SAAS;YACxF,OAAO;gBACLC,IAAID,SAAS,GAAGlE,aAAagE,kBAAkBU,kBAAkB,EAAEP,IAAID,SAAS;YAClF;YACAP,MAAMnD,QAAQ,CAAC2D,GAAG,GAAGA;QACvB;IACF;IAEA,OAAOR;AACT,EAAE"}
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ import { useAttachmentOverflowMenuItem_unstable } from './useAttachmentOverflowMenuItem';
3
+ import { renderAttachmentOverflowMenuItem_unstable } from './renderAttachmentOverflowMenuItem';
4
+ import { useAttachmentOverflowMenuItemStyles_unstable } from './useAttachmentOverflowMenuItemStyles.styles';
5
+ export const AttachmentOverflowMenuItem = /*#__PURE__*/ React.forwardRef((props, ref)=>{
6
+ const state = useAttachmentOverflowMenuItem_unstable(props, ref);
7
+ useAttachmentOverflowMenuItemStyles_unstable(state);
8
+ return renderAttachmentOverflowMenuItem_unstable(state);
9
+ });
10
+ AttachmentOverflowMenuItem.displayName = 'AttachmentOverflowMenuItem';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["AttachmentOverflowMenuItem.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAttachmentOverflowMenuItem_unstable } from './useAttachmentOverflowMenuItem';\nimport { renderAttachmentOverflowMenuItem_unstable } from './renderAttachmentOverflowMenuItem';\nimport type { AttachmentOverflowMenuItemProps } from './AttachmentOverflowMenuItem.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useAttachmentOverflowMenuItemStyles_unstable } from './useAttachmentOverflowMenuItemStyles.styles';\nexport const AttachmentOverflowMenuItem: ForwardRefComponent<AttachmentOverflowMenuItemProps> = React.forwardRef(\n (props, ref) => {\n const state = useAttachmentOverflowMenuItem_unstable(props, ref);\n useAttachmentOverflowMenuItemStyles_unstable(state);\n\n return renderAttachmentOverflowMenuItem_unstable(state);\n },\n);\n\nAttachmentOverflowMenuItem.displayName = 'AttachmentOverflowMenuItem';\n"],"names":["React","useAttachmentOverflowMenuItem_unstable","renderAttachmentOverflowMenuItem_unstable","useAttachmentOverflowMenuItemStyles_unstable","AttachmentOverflowMenuItem","forwardRef","props","ref","state","displayName"],"rangeMappings":";;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,sCAAsC,QAAQ,kCAAkC;AACzF,SAASC,yCAAyC,QAAQ,qCAAqC;AAG/F,SAASC,4CAA4C,QAAQ,+CAA+C;AAC5G,OAAO,MAAMC,2CAAmFJ,MAAMK,UAAU,CAC9G,CAACC,OAAOC;IACN,MAAMC,QAAQP,uCAAuCK,OAAOC;IAC5DJ,6CAA6CK;IAE7C,OAAON,0CAA0CM;AACnD,GACA;AAEFJ,2BAA2BK,WAAW,GAAG"}
@@ -0,0 +1,3 @@
1
+ /**
2
+ * State used in rendering AttachmentOverflowMenuItem
3
+ */ export { };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["AttachmentOverflowMenuItem.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, MenuItem, ProgressBar, Slot } from '@fluentui/react-components';\nimport type { AttachmentProps } from '../Attachment';\nimport type { DesignVersion } from '@fluentui-copilot/react-provider';\n\nexport type AttachmentOverflowMenuItemSlots = {\n root: NonNullable<Slot<typeof MenuItem>>;\n progress?: Slot<typeof ProgressBar>;\n};\n\n/**\n * AttachmentOverflowMenuItem Props\n */\nexport type AttachmentOverflowMenuItemProps = ComponentProps<Partial<AttachmentOverflowMenuItemSlots>> &\n DesignVersion &\n Pick<AttachmentProps, 'id' | 'media' | 'imageOnly'>;\n\n/**\n * State used in rendering AttachmentOverflowMenuItem\n */\nexport type AttachmentOverflowMenuItemState = ComponentState<AttachmentOverflowMenuItemSlots> &\n Pick<AttachmentOverflowMenuItemProps, 'imageOnly' | 'designVersion'> & {\n isVisible: boolean;\n };\n"],"names":[],"rangeMappings":";;","mappings":"AAgBA;;CAEC,GACD,WAGI"}
@@ -0,0 +1,4 @@
1
+ export { AttachmentOverflowMenuItem } from './AttachmentOverflowMenuItem';
2
+ export { renderAttachmentOverflowMenuItem_unstable } from './renderAttachmentOverflowMenuItem';
3
+ export { useAttachmentOverflowMenuItem_unstable } from './useAttachmentOverflowMenuItem';
4
+ export { attachmentOverflowMenuItemClassNames, useAttachmentOverflowMenuItemStyles_unstable } from './useAttachmentOverflowMenuItemStyles.styles';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export { AttachmentOverflowMenuItem } from './AttachmentOverflowMenuItem';\nexport type { AttachmentOverflowMenuItemProps, AttachmentOverflowMenuItemSlots, AttachmentOverflowMenuItemState } from './AttachmentOverflowMenuItem.types';\nexport { renderAttachmentOverflowMenuItem_unstable } from './renderAttachmentOverflowMenuItem';\nexport { useAttachmentOverflowMenuItem_unstable } from './useAttachmentOverflowMenuItem';\nexport { attachmentOverflowMenuItemClassNames, useAttachmentOverflowMenuItemStyles_unstable } from './useAttachmentOverflowMenuItemStyles.styles';\n"],"names":["AttachmentOverflowMenuItem","renderAttachmentOverflowMenuItem_unstable","useAttachmentOverflowMenuItem_unstable","attachmentOverflowMenuItemClassNames","useAttachmentOverflowMenuItemStyles_unstable"],"rangeMappings":";;;","mappings":"AAAA,SAASA,0BAA0B,QAAQ,+BAA+B;AAE1E,SAASC,yCAAyC,QAAQ,qCAAqC;AAC/F,SAASC,sCAAsC,QAAQ,kCAAkC;AACzF,SAASC,oCAAoC,EAAEC,4CAA4C,QAAQ,+CAA+C"}
@@ -0,0 +1,13 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "@fluentui/react-jsx-runtime/jsx-runtime";
2
+ import { assertSlots } from '@fluentui/react-components';
3
+ /**
4
+ * Render the final JSX of AttachmentOverflowMenuItem
5
+ */ export const renderAttachmentOverflowMenuItem_unstable = (state)=>{
6
+ assertSlots(state);
7
+ return !state.isVisible ? /*#__PURE__*/ _jsxs(state.root, {
8
+ children: [
9
+ state.root.children,
10
+ state.progress && /*#__PURE__*/ _jsx(state.progress, {})
11
+ ]
12
+ }) : null;
13
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["renderAttachmentOverflowMenuItem.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-components';\nimport type { JSXElement } from '@fluentui/react-components';\nimport type {\n AttachmentOverflowMenuItemState,\n AttachmentOverflowMenuItemSlots,\n} from './AttachmentOverflowMenuItem.types';\n\n/**\n * Render the final JSX of AttachmentOverflowMenuItem\n */\nexport const renderAttachmentOverflowMenuItem_unstable = (\n state: AttachmentOverflowMenuItemState,\n): JSXElement | null => {\n assertSlots<AttachmentOverflowMenuItemSlots>(state);\n\n return !state.isVisible ? (\n <state.root>\n {state.root.children}\n {state.progress && <state.progress />}\n </state.root>\n ) : null;\n};\n"],"names":["assertSlots","renderAttachmentOverflowMenuItem_unstable","state","isVisible","root","children","progress"],"rangeMappings":";;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,6BAA6B;AAOzD;;CAEC,GACD,OAAO,MAAMC,4CAA4C,CACvDC;IAEAF,YAA6CE;IAE7C,OAAO,CAACA,MAAMC,SAAS,iBACrB,MAACD,MAAME,IAAI;;YACRF,MAAME,IAAI,CAACC,QAAQ;YACnBH,MAAMI,QAAQ,kBAAI,KAACJ,MAAMI,QAAQ;;SAElC;AACN,EAAE"}
@@ -0,0 +1,56 @@
1
+ import * as React from 'react';
2
+ import { MenuItem, ProgressBar, mergeCallbacks, slot, useId, useIsOverflowItemVisible } from '@fluentui/react-components';
3
+ import { Dismiss20Regular } from '@fluentui/react-icons';
4
+ import { useAttachmentListContext_unstable } from '../../contexts/attachmentListContext';
5
+ import { useDesignVersion } from '@fluentui-copilot/react-provider';
6
+ /**
7
+ * Create the state required to render AttachmentOverflowMenuItem.
8
+ *
9
+ * The returned state can be modified with hooks such as useAttachmentOverflowMenuItemStyles_unstable,
10
+ * before being passed to renderAttachmentOverflowMenuItem_unstable.
11
+ *
12
+ * @param props - props from this instance of AttachmentOverflowMenuItem
13
+ * @param ref - reference to root HTMLElement of AttachmentOverflowMenuItem
14
+ */ export const useAttachmentOverflowMenuItem_unstable = (props, ref)=>{
15
+ 'use no memo';
16
+ const { imageOnly, media } = props;
17
+ const menuItemId = useId('attachment-', props.id);
18
+ const isVisible = useIsOverflowItemVisible(menuItemId);
19
+ const { onAttachmentDismiss } = useAttachmentListContext_unstable((context)=>context);
20
+ const designVersion = useDesignVersion(props.designVersion);
21
+ const root = slot.always({
22
+ ref,
23
+ icon: media,
24
+ secondaryContent: /*#__PURE__*/ React.createElement(Dismiss20Regular, null),
25
+ ...props,
26
+ id: menuItemId
27
+ }, {
28
+ elementType: MenuItem
29
+ });
30
+ root.onClick = mergeCallbacks(root.onClick, (ev)=>{
31
+ onAttachmentDismiss === null || onAttachmentDismiss === void 0 ? void 0 : onAttachmentDismiss(ev, {
32
+ content: props.children,
33
+ media,
34
+ id: menuItemId
35
+ });
36
+ });
37
+ const progress = slot.optional(props.progress, {
38
+ defaultProps: {
39
+ shape: 'square',
40
+ thickness: 'large',
41
+ 'aria-labelledby': props.id
42
+ },
43
+ elementType: ProgressBar
44
+ });
45
+ return {
46
+ components: {
47
+ root: MenuItem,
48
+ progress: ProgressBar
49
+ },
50
+ root,
51
+ progress,
52
+ isVisible,
53
+ imageOnly,
54
+ designVersion
55
+ };
56
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAttachmentOverflowMenuItem.tsx"],"sourcesContent":["import * as React from 'react';\nimport {\n MenuItem,\n ProgressBar,\n mergeCallbacks,\n slot,\n useId,\n useIsOverflowItemVisible,\n} from '@fluentui/react-components';\nimport { Dismiss20Regular } from '@fluentui/react-icons';\nimport { useAttachmentListContext_unstable } from '../../contexts/attachmentListContext';\nimport type {\n AttachmentOverflowMenuItemProps,\n AttachmentOverflowMenuItemState,\n} from './AttachmentOverflowMenuItem.types';\nimport { useDesignVersion } from '@fluentui-copilot/react-provider';\n\n/**\n * Create the state required to render AttachmentOverflowMenuItem.\n *\n * The returned state can be modified with hooks such as useAttachmentOverflowMenuItemStyles_unstable,\n * before being passed to renderAttachmentOverflowMenuItem_unstable.\n *\n * @param props - props from this instance of AttachmentOverflowMenuItem\n * @param ref - reference to root HTMLElement of AttachmentOverflowMenuItem\n */\nexport const useAttachmentOverflowMenuItem_unstable = (\n props: AttachmentOverflowMenuItemProps,\n ref: React.Ref<HTMLDivElement>,\n): AttachmentOverflowMenuItemState => {\n 'use no memo';\n\n const { imageOnly, media } = props;\n const menuItemId = useId('attachment-', props.id);\n const isVisible = useIsOverflowItemVisible(menuItemId);\n const { onAttachmentDismiss } = useAttachmentListContext_unstable(context => context);\n const designVersion = useDesignVersion(props.designVersion);\n\n const root = slot.always(\n { ref, icon: media, secondaryContent: <Dismiss20Regular />, ...props, id: menuItemId },\n { elementType: MenuItem },\n );\n root.onClick = mergeCallbacks(root.onClick, ev => {\n onAttachmentDismiss?.(ev, { content: props.children, media, id: menuItemId });\n });\n\n const progress = slot.optional(props.progress, {\n defaultProps: {\n shape: 'square',\n thickness: 'large',\n 'aria-labelledby': props.id,\n },\n elementType: ProgressBar,\n });\n\n return {\n components: {\n root: MenuItem,\n progress: ProgressBar,\n },\n root,\n progress,\n isVisible,\n imageOnly,\n designVersion,\n };\n};\n"],"names":["React","MenuItem","ProgressBar","mergeCallbacks","slot","useId","useIsOverflowItemVisible","Dismiss20Regular","useAttachmentListContext_unstable","useDesignVersion","useAttachmentOverflowMenuItem_unstable","props","ref","imageOnly","media","menuItemId","id","isVisible","onAttachmentDismiss","context","designVersion","root","always","icon","secondaryContent","elementType","onClick","ev","content","children","progress","optional","defaultProps","shape","thickness","components"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SACEC,QAAQ,EACRC,WAAW,EACXC,cAAc,EACdC,IAAI,EACJC,KAAK,EACLC,wBAAwB,QACnB,6BAA6B;AACpC,SAASC,gBAAgB,QAAQ,wBAAwB;AACzD,SAASC,iCAAiC,QAAQ,uCAAuC;AAKzF,SAASC,gBAAgB,QAAQ,mCAAmC;AAEpE;;;;;;;;CAQC,GACD,OAAO,MAAMC,yCAAyC,CACpDC,OACAC;IAEA;IAEA,MAAM,EAAEC,SAAS,EAAEC,KAAK,EAAE,GAAGH;IAC7B,MAAMI,aAAaV,MAAM,eAAeM,MAAMK,EAAE;IAChD,MAAMC,YAAYX,yBAAyBS;IAC3C,MAAM,EAAEG,mBAAmB,EAAE,GAAGV,kCAAkCW,CAAAA,UAAWA;IAC7E,MAAMC,gBAAgBX,iBAAiBE,MAAMS,aAAa;IAE1D,MAAMC,OAAOjB,KAAKkB,MAAM,CACtB;QAAEV;QAAKW,MAAMT;QAAOU,gCAAkB,oBAACjB;QAAqB,GAAGI,KAAK;QAAEK,IAAID;IAAW,GACrF;QAAEU,aAAaxB;IAAS;IAE1BoB,KAAKK,OAAO,GAAGvB,eAAekB,KAAKK,OAAO,EAAEC,CAAAA;QAC1CT,gCAAAA,0CAAAA,oBAAsBS,IAAI;YAAEC,SAASjB,MAAMkB,QAAQ;YAAEf;YAAOE,IAAID;QAAW;IAC7E;IAEA,MAAMe,WAAW1B,KAAK2B,QAAQ,CAACpB,MAAMmB,QAAQ,EAAE;QAC7CE,cAAc;YACZC,OAAO;YACPC,WAAW;YACX,mBAAmBvB,MAAMK,EAAE;QAC7B;QACAS,aAAavB;IACf;IAEA,OAAO;QACLiC,YAAY;YACVd,MAAMpB;YACN6B,UAAU5B;QACZ;QACAmB;QACAS;QACAb;QACAJ;QACAO;IACF;AACF,EAAE"}
@@ -0,0 +1,84 @@
1
+ import { __styles, mergeClasses, slot } from '@fluentui/react-components';
2
+ import { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';
3
+ import { tokens } from '@fluentui-copilot/tokens';
4
+ export const attachmentOverflowMenuItemClassNames = {
5
+ root: 'fai-AttachmentOverflowMenuItem',
6
+ progress: 'fai-AttachmentOverflowMenuItem__progress'
7
+ };
8
+ const FOCUS_VISIBLE_ATTR = 'data-fui-focus-visible';
9
+ const useStyles = __styles({
10
+ imageOnly: {
11
+ Bt984gj: "f122n59"
12
+ },
13
+ secondaryContent: {
14
+ mc9l5x: "f22iagw",
15
+ Bt984gj: "f122n59"
16
+ }
17
+ }, {
18
+ d: [".f122n59{align-items:center;}", ".f22iagw{display:flex;}"]
19
+ });
20
+ const useNextStyles = __styles({
21
+ nextStyles: {
22
+ Beyfa6y: 0,
23
+ Bbmb7ep: 0,
24
+ Btl43ni: 0,
25
+ B7oj6ja: 0,
26
+ Dimara: "fxe958b",
27
+ Dah5zi: 0,
28
+ B1tsrr9: 0,
29
+ qqdqy8: 0,
30
+ Bkh64rk: 0,
31
+ e3fwne: "f8ydpu5",
32
+ Bw0xxkn: 0,
33
+ oeaueh: 0,
34
+ Bpd4iqm: 0,
35
+ Befb4lg: "f1bars0k"
36
+ }
37
+ }, {
38
+ d: [[".fxe958b{border-radius:20px;}", {
39
+ p: -1
40
+ }], [".f8ydpu5[data-fui-focus-visible]::after{border-radius:20px;}", {
41
+ p: -1
42
+ }], [".f1bars0k{outline:var(--strokeWidthThin) solid var(--colorTransparentStroke);}", {
43
+ p: -1
44
+ }]]
45
+ });
46
+ /**
47
+ * Apply styling to the AttachmentList slots based on the state
48
+ */
49
+ export const useAttachmentOverflowMenuItemStyles_unstable = state => {
50
+ 'use no memo';
51
+
52
+ const {
53
+ imageOnly,
54
+ designVersion
55
+ } = state;
56
+ const styles = useStyles();
57
+ const nextStyles = useNextStyles();
58
+ const progressBarStyles = useProgressBarStyles();
59
+ state.root.className = mergeClasses(attachmentOverflowMenuItemClassNames.root, imageOnly && styles.imageOnly, designVersion === 'next' && nextStyles.nextStyles, state.root.className);
60
+ const secondaryContent = slot.optional(state.root.secondaryContent, {
61
+ elementType: 'span'
62
+ });
63
+ if (secondaryContent) {
64
+ secondaryContent.className = mergeClasses(styles.secondaryContent, secondaryContent.className);
65
+ state.root.secondaryContent = secondaryContent;
66
+ }
67
+ if (state.progress) {
68
+ state.progress.className = mergeClasses(attachmentOverflowMenuItemClassNames.progress, progressBarStyles.progress, state.progress.className);
69
+ const bar = slot.optional(state.progress.bar, {
70
+ elementType: 'div',
71
+ renderByDefault: true
72
+ });
73
+ if (bar) {
74
+ if (state.progress.value === undefined) {
75
+ bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);
76
+ } else {
77
+ bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);
78
+ }
79
+ state.progress.bar = bar;
80
+ }
81
+ }
82
+ return state;
83
+ };
84
+ //# sourceMappingURL=useAttachmentOverflowMenuItemStyles.styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAttachmentOverflowMenuItemStyles.styles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, slot } from '@fluentui/react-components';\nimport { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';\nimport type {\n AttachmentOverflowMenuItemSlots,\n AttachmentOverflowMenuItemState,\n} from './AttachmentOverflowMenuItem.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\nimport { tokens } from '@fluentui-copilot/tokens';\n\nexport const attachmentOverflowMenuItemClassNames: SlotClassNames<AttachmentOverflowMenuItemSlots> = {\n root: 'fai-AttachmentOverflowMenuItem',\n progress: 'fai-AttachmentOverflowMenuItem__progress',\n};\n\nconst FOCUS_VISIBLE_ATTR = 'data-fui-focus-visible';\n\nconst useStyles = makeStyles({\n imageOnly: {\n alignItems: 'center',\n },\n secondaryContent: {\n display: 'flex',\n alignItems: 'center',\n },\n});\n\nconst useNextStyles = makeStyles({\n nextStyles: {\n borderRadius: '20px',\n [`[${FOCUS_VISIBLE_ATTR}]::after`]: {\n borderRadius: '20px',\n },\n outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,\n },\n});\n\n/**\n * Apply styling to the AttachmentList slots based on the state\n */\nexport const useAttachmentOverflowMenuItemStyles_unstable = (\n state: AttachmentOverflowMenuItemState,\n): AttachmentOverflowMenuItemState => {\n 'use no memo';\n\n const { imageOnly, designVersion } = state;\n const styles = useStyles();\n const nextStyles = useNextStyles();\n const progressBarStyles = useProgressBarStyles();\n\n state.root.className = mergeClasses(\n attachmentOverflowMenuItemClassNames.root,\n imageOnly && styles.imageOnly,\n designVersion === 'next' && nextStyles.nextStyles,\n state.root.className,\n );\n\n const secondaryContent = slot.optional(state.root.secondaryContent, {\n elementType: 'span',\n });\n if (secondaryContent) {\n secondaryContent.className = mergeClasses(styles.secondaryContent, secondaryContent.className);\n state.root.secondaryContent = secondaryContent;\n }\n\n if (state.progress) {\n state.progress.className = mergeClasses(\n attachmentOverflowMenuItemClassNames.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":["makeStyles","mergeClasses","slot","useProgressBarStyles","tokens","attachmentOverflowMenuItemClassNames","root","progress","FOCUS_VISIBLE_ATTR","useStyles","imageOnly","alignItems","secondaryContent","display","useNextStyles","nextStyles","borderRadius","outline","strokeWidthThin","colorTransparentStroke","useAttachmentOverflowMenuItemStyles_unstable","state","designVersion","styles","progressBarStyles","className","optional","elementType","bar","renderByDefault","value","undefined","indeterminateProgressBar","regularProgressBar"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,UAAU,EAAEC,YAAY,EAAEC,IAAI,QAAQ,6BAA6B;AAC5E,SAASC,oBAAoB,QAAQ,uCAAuC;AAM5E,SAASC,MAAM,QAAQ,2BAA2B;AAElD,OAAO,MAAMC,uCAAwF;IACnGC,MAAM;IACNC,UAAU;AACZ,EAAE;AAEF,MAAMC,qBAAqB;AAE3B,MAAMC,YAAYT,WAAW;IAC3BU,WAAW;QACTC,YAAY;IACd;IACAC,kBAAkB;QAChBC,SAAS;QACTF,YAAY;IACd;AACF;AAEA,MAAMG,gBAAgBd,WAAW;IAC/Be,YAAY;QACVC,cAAc;QACd,CAAC,CAAC,CAAC,EAAER,mBAAmB,QAAQ,CAAC,CAAC,EAAE;YAClCQ,cAAc;QAChB;QACAC,SAAS,CAAC,EAAEb,OAAOc,eAAe,CAAC,OAAO,EAAEd,OAAOe,sBAAsB,CAAC,CAAC;IAC7E;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,+CAA+C,CAC1DC;IAEA;IAEA,MAAM,EAAEX,SAAS,EAAEY,aAAa,EAAE,GAAGD;IACrC,MAAME,SAASd;IACf,MAAMM,aAAaD;IACnB,MAAMU,oBAAoBrB;IAE1BkB,MAAMf,IAAI,CAACmB,SAAS,GAAGxB,aACrBI,qCAAqCC,IAAI,EACzCI,aAAaa,OAAOb,SAAS,EAC7BY,kBAAkB,UAAUP,WAAWA,UAAU,EACjDM,MAAMf,IAAI,CAACmB,SAAS;IAGtB,MAAMb,mBAAmBV,KAAKwB,QAAQ,CAACL,MAAMf,IAAI,CAACM,gBAAgB,EAAE;QAClEe,aAAa;IACf;IACA,IAAIf,kBAAkB;QACpBA,iBAAiBa,SAAS,GAAGxB,aAAasB,OAAOX,gBAAgB,EAAEA,iBAAiBa,SAAS;QAC7FJ,MAAMf,IAAI,CAACM,gBAAgB,GAAGA;IAChC;IAEA,IAAIS,MAAMd,QAAQ,EAAE;QAClBc,MAAMd,QAAQ,CAACkB,SAAS,GAAGxB,aACzBI,qCAAqCE,QAAQ,EAC7CiB,kBAAkBjB,QAAQ,EAC1Bc,MAAMd,QAAQ,CAACkB,SAAS;QAG1B,MAAMG,MAAM1B,KAAKwB,QAAQ,CAACL,MAAMd,QAAQ,CAACqB,GAAG,EAAE;YAAED,aAAa;YAAOE,iBAAiB;QAAK;QAC1F,IAAID,KAAK;YACP,IAAIP,MAAMd,QAAQ,CAACuB,KAAK,KAAKC,WAAW;gBACtCH,IAAIH,SAAS,GAAGxB,aAAauB,kBAAkBQ,wBAAwB,EAAEJ,IAAIH,SAAS;YACxF,OAAO;gBACLG,IAAIH,SAAS,GAAGxB,aAAauB,kBAAkBS,kBAAkB,EAAEL,IAAIH,SAAS;YAClF;YACAJ,MAAMd,QAAQ,CAACqB,GAAG,GAAGA;QACvB;IACF;IAEA,OAAOP;AACT,EAAE"}
@@ -0,0 +1,59 @@
1
+ import { makeStyles, mergeClasses, slot } from '@fluentui/react-components';
2
+ import { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';
3
+ import { tokens } from '@fluentui-copilot/tokens';
4
+ export const attachmentOverflowMenuItemClassNames = {
5
+ root: 'fai-AttachmentOverflowMenuItem',
6
+ progress: 'fai-AttachmentOverflowMenuItem__progress'
7
+ };
8
+ const FOCUS_VISIBLE_ATTR = 'data-fui-focus-visible';
9
+ const useStyles = makeStyles({
10
+ imageOnly: {
11
+ alignItems: 'center'
12
+ },
13
+ secondaryContent: {
14
+ display: 'flex',
15
+ alignItems: 'center'
16
+ }
17
+ });
18
+ const useNextStyles = makeStyles({
19
+ nextStyles: {
20
+ borderRadius: '20px',
21
+ [`[${FOCUS_VISIBLE_ATTR}]::after`]: {
22
+ borderRadius: '20px'
23
+ },
24
+ outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`
25
+ }
26
+ });
27
+ /**
28
+ * Apply styling to the AttachmentList slots based on the state
29
+ */ export const useAttachmentOverflowMenuItemStyles_unstable = (state)=>{
30
+ 'use no memo';
31
+ const { imageOnly, designVersion } = state;
32
+ const styles = useStyles();
33
+ const nextStyles = useNextStyles();
34
+ const progressBarStyles = useProgressBarStyles();
35
+ state.root.className = mergeClasses(attachmentOverflowMenuItemClassNames.root, imageOnly && styles.imageOnly, designVersion === 'next' && nextStyles.nextStyles, state.root.className);
36
+ const secondaryContent = slot.optional(state.root.secondaryContent, {
37
+ elementType: 'span'
38
+ });
39
+ if (secondaryContent) {
40
+ secondaryContent.className = mergeClasses(styles.secondaryContent, secondaryContent.className);
41
+ state.root.secondaryContent = secondaryContent;
42
+ }
43
+ if (state.progress) {
44
+ state.progress.className = mergeClasses(attachmentOverflowMenuItemClassNames.progress, progressBarStyles.progress, state.progress.className);
45
+ const bar = slot.optional(state.progress.bar, {
46
+ elementType: 'div',
47
+ renderByDefault: true
48
+ });
49
+ if (bar) {
50
+ if (state.progress.value === undefined) {
51
+ bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);
52
+ } else {
53
+ bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);
54
+ }
55
+ state.progress.bar = bar;
56
+ }
57
+ }
58
+ return state;
59
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAttachmentOverflowMenuItemStyles.styles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, slot } from '@fluentui/react-components';\nimport { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';\nimport type {\n AttachmentOverflowMenuItemSlots,\n AttachmentOverflowMenuItemState,\n} from './AttachmentOverflowMenuItem.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\nimport { tokens } from '@fluentui-copilot/tokens';\n\nexport const attachmentOverflowMenuItemClassNames: SlotClassNames<AttachmentOverflowMenuItemSlots> = {\n root: 'fai-AttachmentOverflowMenuItem',\n progress: 'fai-AttachmentOverflowMenuItem__progress',\n};\n\nconst FOCUS_VISIBLE_ATTR = 'data-fui-focus-visible';\n\nconst useStyles = makeStyles({\n imageOnly: {\n alignItems: 'center',\n },\n secondaryContent: {\n display: 'flex',\n alignItems: 'center',\n },\n});\n\nconst useNextStyles = makeStyles({\n nextStyles: {\n borderRadius: '20px',\n [`[${FOCUS_VISIBLE_ATTR}]::after`]: {\n borderRadius: '20px',\n },\n outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,\n },\n});\n\n/**\n * Apply styling to the AttachmentList slots based on the state\n */\nexport const useAttachmentOverflowMenuItemStyles_unstable = (\n state: AttachmentOverflowMenuItemState,\n): AttachmentOverflowMenuItemState => {\n 'use no memo';\n\n const { imageOnly, designVersion } = state;\n const styles = useStyles();\n const nextStyles = useNextStyles();\n const progressBarStyles = useProgressBarStyles();\n\n state.root.className = mergeClasses(\n attachmentOverflowMenuItemClassNames.root,\n imageOnly && styles.imageOnly,\n designVersion === 'next' && nextStyles.nextStyles,\n state.root.className,\n );\n\n const secondaryContent = slot.optional(state.root.secondaryContent, {\n elementType: 'span',\n });\n if (secondaryContent) {\n secondaryContent.className = mergeClasses(styles.secondaryContent, secondaryContent.className);\n state.root.secondaryContent = secondaryContent;\n }\n\n if (state.progress) {\n state.progress.className = mergeClasses(\n attachmentOverflowMenuItemClassNames.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":["makeStyles","mergeClasses","slot","useProgressBarStyles","tokens","attachmentOverflowMenuItemClassNames","root","progress","FOCUS_VISIBLE_ATTR","useStyles","imageOnly","alignItems","secondaryContent","display","useNextStyles","nextStyles","borderRadius","outline","strokeWidthThin","colorTransparentStroke","useAttachmentOverflowMenuItemStyles_unstable","state","designVersion","styles","progressBarStyles","className","optional","elementType","bar","renderByDefault","value","undefined","indeterminateProgressBar","regularProgressBar"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,UAAU,EAAEC,YAAY,EAAEC,IAAI,QAAQ,6BAA6B;AAC5E,SAASC,oBAAoB,QAAQ,uCAAuC;AAM5E,SAASC,MAAM,QAAQ,2BAA2B;AAElD,OAAO,MAAMC,uCAAwF;IACnGC,MAAM;IACNC,UAAU;AACZ,EAAE;AAEF,MAAMC,qBAAqB;AAE3B,MAAMC,YAAYT,WAAW;IAC3BU,WAAW;QACTC,YAAY;IACd;IACAC,kBAAkB;QAChBC,SAAS;QACTF,YAAY;IACd;AACF;AAEA,MAAMG,gBAAgBd,WAAW;IAC/Be,YAAY;QACVC,cAAc;QACd,CAAC,CAAC,CAAC,EAAER,mBAAmB,QAAQ,CAAC,CAAC,EAAE;YAClCQ,cAAc;QAChB;QACAC,SAAS,CAAC,EAAEb,OAAOc,eAAe,CAAC,OAAO,EAAEd,OAAOe,sBAAsB,CAAC,CAAC;IAC7E;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,+CAA+C,CAC1DC;IAEA;IAEA,MAAM,EAAEX,SAAS,EAAEY,aAAa,EAAE,GAAGD;IACrC,MAAME,SAASd;IACf,MAAMM,aAAaD;IACnB,MAAMU,oBAAoBrB;IAE1BkB,MAAMf,IAAI,CAACmB,SAAS,GAAGxB,aACrBI,qCAAqCC,IAAI,EACzCI,aAAaa,OAAOb,SAAS,EAC7BY,kBAAkB,UAAUP,WAAWA,UAAU,EACjDM,MAAMf,IAAI,CAACmB,SAAS;IAGtB,MAAMb,mBAAmBV,KAAKwB,QAAQ,CAACL,MAAMf,IAAI,CAACM,gBAAgB,EAAE;QAClEe,aAAa;IACf;IACA,IAAIf,kBAAkB;QACpBA,iBAAiBa,SAAS,GAAGxB,aAAasB,OAAOX,gBAAgB,EAAEA,iBAAiBa,SAAS;QAC7FJ,MAAMf,IAAI,CAACM,gBAAgB,GAAGA;IAChC;IAEA,IAAIS,MAAMd,QAAQ,EAAE;QAClBc,MAAMd,QAAQ,CAACkB,SAAS,GAAGxB,aACzBI,qCAAqCE,QAAQ,EAC7CiB,kBAAkBjB,QAAQ,EAC1Bc,MAAMd,QAAQ,CAACkB,SAAS;QAG1B,MAAMG,MAAM1B,KAAKwB,QAAQ,CAACL,MAAMd,QAAQ,CAACqB,GAAG,EAAE;YAAED,aAAa;YAAOE,iBAAiB;QAAK;QAC1F,IAAID,KAAK;YACP,IAAIP,MAAMd,QAAQ,CAACuB,KAAK,KAAKC,WAAW;gBACtCH,IAAIH,SAAS,GAAGxB,aAAauB,kBAAkBQ,wBAAwB,EAAEJ,IAAIH,SAAS;YACxF,OAAO;gBACLG,IAAIH,SAAS,GAAGxB,aAAauB,kBAAkBS,kBAAkB,EAAEL,IAAIH,SAAS;YAClF;YACAJ,MAAMd,QAAQ,CAACqB,GAAG,GAAGA;QACvB;IACF;IAEA,OAAOP;AACT,EAAE"}
@@ -0,0 +1,5 @@
1
+ export { Attachment, attachmentClassNames, renderAttachment_unstable, useAttachmentStyles_unstable, useAttachment_unstable, useOverflowStyles } from './Attachment';
2
+ export { AttachmentList, attachmentListClassNames, renderAttachmentList_unstable, useAttachmentListStyles_unstable, useAttachmentList_unstable } from './AttachmentList';
3
+ export { AttachmentOverflowMenu, renderAttachmentOverflowMenu_unstable, useAttachmentOverflowMenuContextValues_unstable, useAttachmentOverflowMenu_unstable } from './AttachmentOverflowMenu';
4
+ export { AttachmentOverflowMenuButton, attachmentOverflowMenuButtonClassNames, renderAttachmentOverflowMenuButton_unstable, useAttachmentOverflowMenuButtonStyles_unstable, useAttachmentOverflowMenuButton_unstable } from './AttachmentOverflowMenuButton';
5
+ export { AttachmentOverflowMenuItem, attachmentOverflowMenuItemClassNames, renderAttachmentOverflowMenuItem_unstable, useAttachmentOverflowMenuItemStyles_unstable, useAttachmentOverflowMenuItem_unstable } from './AttachmentOverflowMenuItem';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export type { AttachmentProps, AttachmentSlots, AttachmentState } from './Attachment';\nexport {\n Attachment,\n attachmentClassNames,\n renderAttachment_unstable,\n useAttachmentStyles_unstable,\n useAttachment_unstable,\n useOverflowStyles,\n} from './Attachment';\nexport type {\n AttachmentDismissedData,\n AttachmentListContextValues,\n AttachmentListProps,\n AttachmentListSlots,\n AttachmentListState,\n} from './AttachmentList';\nexport {\n AttachmentList,\n attachmentListClassNames,\n renderAttachmentList_unstable,\n useAttachmentListStyles_unstable,\n useAttachmentList_unstable,\n} from './AttachmentList';\nexport type {\n AttachmentOverflowMenuContextValues,\n AttachmentOverflowMenuProps,\n AttachmentOverflowMenuSlots,\n AttachmentOverflowMenuState,\n} from './AttachmentOverflowMenu';\nexport {\n AttachmentOverflowMenu,\n renderAttachmentOverflowMenu_unstable,\n useAttachmentOverflowMenuContextValues_unstable,\n useAttachmentOverflowMenu_unstable,\n} from './AttachmentOverflowMenu';\nexport type {\n AttachmentOverflowMenuButtonProps,\n AttachmentOverflowMenuButtonSlots,\n AttachmentOverflowMenuButtonState,\n} from './AttachmentOverflowMenuButton';\nexport {\n AttachmentOverflowMenuButton,\n attachmentOverflowMenuButtonClassNames,\n renderAttachmentOverflowMenuButton_unstable,\n useAttachmentOverflowMenuButtonStyles_unstable,\n useAttachmentOverflowMenuButton_unstable,\n} from './AttachmentOverflowMenuButton';\nexport type {\n AttachmentOverflowMenuItemProps,\n AttachmentOverflowMenuItemSlots,\n AttachmentOverflowMenuItemState,\n} from './AttachmentOverflowMenuItem';\nexport {\n AttachmentOverflowMenuItem,\n attachmentOverflowMenuItemClassNames,\n renderAttachmentOverflowMenuItem_unstable,\n useAttachmentOverflowMenuItemStyles_unstable,\n useAttachmentOverflowMenuItem_unstable,\n} from './AttachmentOverflowMenuItem';\n"],"names":["Attachment","attachmentClassNames","renderAttachment_unstable","useAttachmentStyles_unstable","useAttachment_unstable","useOverflowStyles","AttachmentList","attachmentListClassNames","renderAttachmentList_unstable","useAttachmentListStyles_unstable","useAttachmentList_unstable","AttachmentOverflowMenu","renderAttachmentOverflowMenu_unstable","useAttachmentOverflowMenuContextValues_unstable","useAttachmentOverflowMenu_unstable","AttachmentOverflowMenuButton","attachmentOverflowMenuButtonClassNames","renderAttachmentOverflowMenuButton_unstable","useAttachmentOverflowMenuButtonStyles_unstable","useAttachmentOverflowMenuButton_unstable","AttachmentOverflowMenuItem","attachmentOverflowMenuItemClassNames","renderAttachmentOverflowMenuItem_unstable","useAttachmentOverflowMenuItemStyles_unstable","useAttachmentOverflowMenuItem_unstable"],"rangeMappings":";;;;","mappings":"AACA,SACEA,UAAU,EACVC,oBAAoB,EACpBC,yBAAyB,EACzBC,4BAA4B,EAC5BC,sBAAsB,EACtBC,iBAAiB,QACZ,eAAe;AAQtB,SACEC,cAAc,EACdC,wBAAwB,EACxBC,6BAA6B,EAC7BC,gCAAgC,EAChCC,0BAA0B,QACrB,mBAAmB;AAO1B,SACEC,sBAAsB,EACtBC,qCAAqC,EACrCC,+CAA+C,EAC/CC,kCAAkC,QAC7B,2BAA2B;AAMlC,SACEC,4BAA4B,EAC5BC,sCAAsC,EACtCC,2CAA2C,EAC3CC,8CAA8C,EAC9CC,wCAAwC,QACnC,iCAAiC;AAMxC,SACEC,0BAA0B,EAC1BC,oCAAoC,EACpCC,yCAAyC,EACzCC,4CAA4C,EAC5CC,sCAAsC,QACjC,+BAA+B"}
@@ -0,0 +1,54 @@
1
+ import { __styles } from '@fluentui/react-components';
2
+ import { tokens } from '@fluentui-copilot/tokens';
3
+ const indeterminateProgressBarReducedMotion = {
4
+ '0%': {
5
+ opacity: '.2'
6
+ },
7
+ '50%': {
8
+ opacity: '1'
9
+ },
10
+ '100%': {
11
+ opacity: '.2'
12
+ }
13
+ };
14
+ /**
15
+ * @internal
16
+ */
17
+ export const useProgressBarStyles = __styles({
18
+ progress: {
19
+ a9b677: "fly5x3f",
20
+ qhf8xq: "f1euv43f",
21
+ B5kzvoi: "f1yab3r1",
22
+ oyh7mz: ["f1vgc2s3", "f1e31b4d"],
23
+ j35jbq: ["f1e31b4d", "f1vgc2s3"],
24
+ Bqenvij: "f6ywr7j",
25
+ Beyfa6y: ["f16jpd5f", "f1aa9q02"],
26
+ Bbmb7ep: ["f1aa9q02", "f16jpd5f"]
27
+ },
28
+ regularProgressBar: {
29
+ Bqenvij: "f1l02sjl",
30
+ Bcmaq0h: "ffso0f9"
31
+ },
32
+ indeterminateProgressBar: {
33
+ Bqenvij: "f1l02sjl",
34
+ De3pzq: "f1c21dwh",
35
+ Bcmaq0h: "fc9jjzv",
36
+ jpy9cc: "f3z2g5w",
37
+ Bqo2lbl: "fz5izi4",
38
+ B6plc1d: "fv40pdu",
39
+ I82g5a: "f1uj6jbf"
40
+ }
41
+ }, {
42
+ d: [".fly5x3f{width:100%;}", ".f1euv43f{position:absolute;}", ".f1yab3r1{bottom:0;}", ".f1vgc2s3{left:0;}", ".f1e31b4d{right:0;}", ".f6ywr7j{height:4px;}", ".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f1l02sjl{height:100%;}", ".ffso0f9{background-image:linear-gradient(90deg, var(--colorBrandFlair1) 35%, var(--colorBrandFlair2) 70%, var(--colorBrandFlair3) 92%);}", ".f1c21dwh{background-color:var(--colorTransparentBackground);}", ".fc9jjzv{background-image:linear-gradient(90deg, rgba(0,0,0,0) 0%, var(--colorBrandFlair1) 35%, var(--colorBrandFlair2) 70%, var(--colorBrandFlair3) 92%, rgba(0,0,0,0));}"],
43
+ m: [["@media screen and (prefers-reduced-motion: reduce){.f3z2g5w{max-width:100%;}}", {
44
+ m: "screen and (prefers-reduced-motion: reduce)"
45
+ }], ["@media screen and (prefers-reduced-motion: reduce){.fz5izi4{animation-iteration-count:infinite;}}", {
46
+ m: "screen and (prefers-reduced-motion: reduce)"
47
+ }], ["@media screen and (prefers-reduced-motion: reduce){.fv40pdu{animation-duration:3s;}}", {
48
+ m: "screen and (prefers-reduced-motion: reduce)"
49
+ }], ["@media screen and (prefers-reduced-motion: reduce){.f1uj6jbf{animation-name:ftc26vs;}}", {
50
+ m: "screen and (prefers-reduced-motion: reduce)"
51
+ }]],
52
+ k: ["@keyframes ftc26vs{0%{opacity:.2;}50%{opacity:1;}100%{opacity:.2;}}"]
53
+ });
54
+ //# sourceMappingURL=useProgressBarStyles.styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useProgressBarStyles.styles.ts"],"sourcesContent":["import { makeStyles } from '@fluentui/react-components';\nimport { tokens } from '@fluentui-copilot/tokens';\n\nconst indeterminateProgressBarReducedMotion = {\n '0%': {\n opacity: '.2', // matches indeterminate bar width\n },\n '50%': {\n opacity: '1',\n },\n '100%': {\n opacity: '.2',\n },\n};\n\n/**\n * @internal\n */\nexport const useProgressBarStyles = makeStyles({\n progress: {\n width: '100%',\n position: 'absolute',\n bottom: 0,\n left: 0,\n right: 0,\n height: '4px',\n borderBottomLeftRadius: tokens.borderRadiusMedium,\n borderBottomRightRadius: tokens.borderRadiusMedium,\n },\n regularProgressBar: {\n height: '100%',\n backgroundImage: `linear-gradient(90deg, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%)`,\n },\n indeterminateProgressBar: {\n height: '100%',\n backgroundColor: tokens.colorTransparentBackground,\n backgroundImage: `linear-gradient(90deg, rgba(0,0,0,0) 0%, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%, rgba(0,0,0,0))`,\n '@media screen and (prefers-reduced-motion: reduce)': {\n maxWidth: '100%',\n animationIterationCount: 'infinite',\n animationDuration: '3s',\n animationName: indeterminateProgressBarReducedMotion,\n },\n },\n});\n"],"names":["makeStyles","tokens","indeterminateProgressBarReducedMotion","opacity","useProgressBarStyles","progress","width","position","bottom","left","right","height","borderBottomLeftRadius","borderRadiusMedium","borderBottomRightRadius","regularProgressBar","backgroundImage","colorBrandFlair1","colorBrandFlair2","colorBrandFlair3","indeterminateProgressBar","backgroundColor","colorTransparentBackground","maxWidth","animationIterationCount","animationDuration","animationName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,UAAU,QAAQ,6BAA6B;AACxD,SAASC,MAAM,QAAQ,2BAA2B;AAElD,MAAMC,wCAAwC;IAC5C,MAAM;QACJC,SAAS;IACX;IACA,OAAO;QACLA,SAAS;IACX;IACA,QAAQ;QACNA,SAAS;IACX;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,uBAAuBJ,WAAW;IAC7CK,UAAU;QACRC,OAAO;QACPC,UAAU;QACVC,QAAQ;QACRC,MAAM;QACNC,OAAO;QACPC,QAAQ;QACRC,wBAAwBX,OAAOY,kBAAkB;QACjDC,yBAAyBb,OAAOY,kBAAkB;IACpD;IACAE,oBAAoB;QAClBJ,QAAQ;QACRK,iBAAiB,CAAC,uBAAuB,EAAEf,OAAOgB,gBAAgB,CAAC,MAAM,EAAEhB,OAAOiB,gBAAgB,CAAC,MAAM,EAAEjB,OAAOkB,gBAAgB,CAAC,KAAK,CAAC;IAC3I;IACAC,0BAA0B;QACxBT,QAAQ;QACRU,iBAAiBpB,OAAOqB,0BAA0B;QAClDN,iBAAiB,CAAC,yCAAyC,EAAEf,OAAOgB,gBAAgB,CAAC,MAAM,EAAEhB,OAAOiB,gBAAgB,CAAC,MAAM,EAAEjB,OAAOkB,gBAAgB,CAAC,qBAAqB,CAAC;QAC3K,sDAAsD;YACpDI,UAAU;YACVC,yBAAyB;YACzBC,mBAAmB;YACnBC,eAAexB;QACjB;IACF;AACF,GAAG"}
@@ -0,0 +1,42 @@
1
+ import { makeStyles } from '@fluentui/react-components';
2
+ import { tokens } from '@fluentui-copilot/tokens';
3
+ const indeterminateProgressBarReducedMotion = {
4
+ '0%': {
5
+ opacity: '.2'
6
+ },
7
+ '50%': {
8
+ opacity: '1'
9
+ },
10
+ '100%': {
11
+ opacity: '.2'
12
+ }
13
+ };
14
+ /**
15
+ * @internal
16
+ */ export const useProgressBarStyles = makeStyles({
17
+ progress: {
18
+ width: '100%',
19
+ position: 'absolute',
20
+ bottom: 0,
21
+ left: 0,
22
+ right: 0,
23
+ height: '4px',
24
+ borderBottomLeftRadius: tokens.borderRadiusMedium,
25
+ borderBottomRightRadius: tokens.borderRadiusMedium
26
+ },
27
+ regularProgressBar: {
28
+ height: '100%',
29
+ backgroundImage: `linear-gradient(90deg, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%)`
30
+ },
31
+ indeterminateProgressBar: {
32
+ height: '100%',
33
+ backgroundColor: tokens.colorTransparentBackground,
34
+ backgroundImage: `linear-gradient(90deg, rgba(0,0,0,0) 0%, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%, rgba(0,0,0,0))`,
35
+ '@media screen and (prefers-reduced-motion: reduce)': {
36
+ maxWidth: '100%',
37
+ animationIterationCount: 'infinite',
38
+ animationDuration: '3s',
39
+ animationName: indeterminateProgressBarReducedMotion
40
+ }
41
+ }
42
+ });
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useProgressBarStyles.styles.ts"],"sourcesContent":["import { makeStyles } from '@fluentui/react-components';\nimport { tokens } from '@fluentui-copilot/tokens';\n\nconst indeterminateProgressBarReducedMotion = {\n '0%': {\n opacity: '.2', // matches indeterminate bar width\n },\n '50%': {\n opacity: '1',\n },\n '100%': {\n opacity: '.2',\n },\n};\n\n/**\n * @internal\n */\nexport const useProgressBarStyles = makeStyles({\n progress: {\n width: '100%',\n position: 'absolute',\n bottom: 0,\n left: 0,\n right: 0,\n height: '4px',\n borderBottomLeftRadius: tokens.borderRadiusMedium,\n borderBottomRightRadius: tokens.borderRadiusMedium,\n },\n regularProgressBar: {\n height: '100%',\n backgroundImage: `linear-gradient(90deg, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%)`,\n },\n indeterminateProgressBar: {\n height: '100%',\n backgroundColor: tokens.colorTransparentBackground,\n backgroundImage: `linear-gradient(90deg, rgba(0,0,0,0) 0%, ${tokens.colorBrandFlair1} 35%, ${tokens.colorBrandFlair2} 70%, ${tokens.colorBrandFlair3} 92%, rgba(0,0,0,0))`,\n '@media screen and (prefers-reduced-motion: reduce)': {\n maxWidth: '100%',\n animationIterationCount: 'infinite',\n animationDuration: '3s',\n animationName: indeterminateProgressBarReducedMotion,\n },\n },\n});\n"],"names":["makeStyles","tokens","indeterminateProgressBarReducedMotion","opacity","useProgressBarStyles","progress","width","position","bottom","left","right","height","borderBottomLeftRadius","borderRadiusMedium","borderBottomRightRadius","regularProgressBar","backgroundImage","colorBrandFlair1","colorBrandFlair2","colorBrandFlair3","indeterminateProgressBar","backgroundColor","colorTransparentBackground","maxWidth","animationIterationCount","animationDuration","animationName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,UAAU,QAAQ,6BAA6B;AACxD,SAASC,MAAM,QAAQ,2BAA2B;AAElD,MAAMC,wCAAwC;IAC5C,MAAM;QACJC,SAAS;IACX;IACA,OAAO;QACLA,SAAS;IACX;IACA,QAAQ;QACNA,SAAS;IACX;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,uBAAuBJ,WAAW;IAC7CK,UAAU;QACRC,OAAO;QACPC,UAAU;QACVC,QAAQ;QACRC,MAAM;QACNC,OAAO;QACPC,QAAQ;QACRC,wBAAwBX,OAAOY,kBAAkB;QACjDC,yBAAyBb,OAAOY,kBAAkB;IACpD;IACAE,oBAAoB;QAClBJ,QAAQ;QACRK,iBAAiB,CAAC,uBAAuB,EAAEf,OAAOgB,gBAAgB,CAAC,MAAM,EAAEhB,OAAOiB,gBAAgB,CAAC,MAAM,EAAEjB,OAAOkB,gBAAgB,CAAC,KAAK,CAAC;IAC3I;IACAC,0BAA0B;QACxBT,QAAQ;QACRU,iBAAiBpB,OAAOqB,0BAA0B;QAClDN,iBAAiB,CAAC,yCAAyC,EAAEf,OAAOgB,gBAAgB,CAAC,MAAM,EAAEhB,OAAOiB,gBAAgB,CAAC,MAAM,EAAEjB,OAAOkB,gBAAgB,CAAC,qBAAqB,CAAC;QAC3K,sDAAsD;YACpDI,UAAU;YACVC,yBAAyB;YACzBC,mBAAmB;YACnBC,eAAexB;QACjB;IACF;AACF,GAAG"}
@@ -0,0 +1,9 @@
1
+ import { createContext, useContextSelector } from '@fluentui/react-context-selector';
2
+ export const AttachmentListContext = createContext(undefined);
3
+ const attachmentListContextDefaultValue = {
4
+ onAttachmentDismiss: ()=>null,
5
+ shouldUseOverflow: false,
6
+ numberOfAttachments: 0
7
+ };
8
+ export const AttachmentListProvider = AttachmentListContext.Provider;
9
+ export const useAttachmentListContext_unstable = (selector)=>useContextSelector(AttachmentListContext, (ctx = attachmentListContextDefaultValue)=>selector(ctx));
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["attachmentListContext.ts"],"sourcesContent":["import { createContext, useContextSelector } from '@fluentui/react-context-selector';\nimport type { Context, ContextSelector } from '@fluentui/react-context-selector';\nimport type { AttachmentListState } from '../components/index';\n\nexport const AttachmentListContext: Context<AttachmentListContextValue> = createContext<\n AttachmentListContextValue | undefined\n>(undefined) as Context<AttachmentListContextValue>;\n\nconst attachmentListContextDefaultValue: AttachmentListContextValue = {\n onAttachmentDismiss: () => null,\n shouldUseOverflow: false,\n numberOfAttachments: 0,\n};\n\n/**\n * Context shared between AttachmentList and its children components\n */\nexport type AttachmentListContextValue = Pick<\n AttachmentListState,\n 'onAttachmentDismiss' | 'shouldUseOverflow' | 'numberOfAttachments'\n>;\n\nexport const AttachmentListProvider = AttachmentListContext.Provider;\n\nexport const useAttachmentListContext_unstable = <T>(selector: ContextSelector<AttachmentListContextValue, T>): T =>\n useContextSelector(AttachmentListContext, (ctx = attachmentListContextDefaultValue) => selector(ctx));\n"],"names":["createContext","useContextSelector","AttachmentListContext","undefined","attachmentListContextDefaultValue","onAttachmentDismiss","shouldUseOverflow","numberOfAttachments","AttachmentListProvider","Provider","useAttachmentListContext_unstable","selector","ctx"],"rangeMappings":";;;;;;;;","mappings":"AAAA,SAASA,aAAa,EAAEC,kBAAkB,QAAQ,mCAAmC;AAIrF,OAAO,MAAMC,wBAA6DF,cAExEG,WAAkD;AAEpD,MAAMC,oCAAgE;IACpEC,qBAAqB,IAAM;IAC3BC,mBAAmB;IACnBC,qBAAqB;AACvB;AAUA,OAAO,MAAMC,yBAAyBN,sBAAsBO,QAAQ,CAAC;AAErE,OAAO,MAAMC,oCAAoC,CAAIC,WACnDV,mBAAmBC,uBAAuB,CAACU,MAAMR,iCAAiC,GAAKO,SAASC,MAAM"}
@@ -0,0 +1,9 @@
1
+ import { createContext, useContextSelector } from '@fluentui/react-context-selector';
2
+ export const AttachmentOverflowMenuContext = createContext(undefined);
3
+ const overflowMenuContextDefaultValue = {
4
+ isOverflowing: false,
5
+ overflowButtonRef: undefined,
6
+ overflowCount: 0
7
+ };
8
+ export const AttachmentOverflowMenuProvider = AttachmentOverflowMenuContext.Provider;
9
+ export const useAttachmentOverflowMenuContext_unstable = (selector)=>useContextSelector(AttachmentOverflowMenuContext, (ctx = overflowMenuContextDefaultValue)=>selector(ctx));
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["attachmentOverflowMenuContext.ts"],"sourcesContent":["import { createContext, useContextSelector } from '@fluentui/react-context-selector';\nimport type { Context, ContextSelector } from '@fluentui/react-context-selector';\nimport type { AttachmentOverflowMenuState } from '../components/index';\n\nexport const AttachmentOverflowMenuContext: Context<AttachmentOverflowMenuContextValue> = createContext<\n AttachmentOverflowMenuContextValue | undefined\n>(undefined) as Context<AttachmentOverflowMenuContextValue>;\n\nconst overflowMenuContextDefaultValue: AttachmentOverflowMenuContextValue = {\n isOverflowing: false,\n overflowButtonRef: undefined,\n overflowCount: 0,\n};\n\n/**\n * Context shared between AttachmentOverflowMenu and its children components\n */\nexport type AttachmentOverflowMenuContextValue = Pick<\n AttachmentOverflowMenuState,\n 'isOverflowing' | 'overflowButtonRef' | 'overflowCount'\n>;\nexport const AttachmentOverflowMenuProvider = AttachmentOverflowMenuContext.Provider;\n\nexport const useAttachmentOverflowMenuContext_unstable = <T>(\n selector: ContextSelector<AttachmentOverflowMenuContextValue, T>,\n): T => useContextSelector(AttachmentOverflowMenuContext, (ctx = overflowMenuContextDefaultValue) => selector(ctx));\n"],"names":["createContext","useContextSelector","AttachmentOverflowMenuContext","undefined","overflowMenuContextDefaultValue","isOverflowing","overflowButtonRef","overflowCount","AttachmentOverflowMenuProvider","Provider","useAttachmentOverflowMenuContext_unstable","selector","ctx"],"rangeMappings":";;;;;;;;","mappings":"AAAA,SAASA,aAAa,EAAEC,kBAAkB,QAAQ,mCAAmC;AAIrF,OAAO,MAAMC,gCAA6EF,cAExFG,WAA0D;AAE5D,MAAMC,kCAAsE;IAC1EC,eAAe;IACfC,mBAAmBH;IACnBI,eAAe;AACjB;AASA,OAAO,MAAMC,iCAAiCN,8BAA8BO,QAAQ,CAAC;AAErF,OAAO,MAAMC,4CAA4C,CACvDC,WACMV,mBAAmBC,+BAA+B,CAACU,MAAMR,+BAA+B,GAAKO,SAASC,MAAM"}
package/lib/index.js ADDED
@@ -0,0 +1,8 @@
1
+ export { AttachmentList, attachmentListClassNames, renderAttachmentList_unstable, useAttachmentListStyles_unstable, useAttachmentList_unstable } from './AttachmentList';
2
+ export { AttachmentListContext, AttachmentListProvider, useAttachmentListContext_unstable } from './contexts/attachmentListContext';
3
+ export { Attachment, attachmentClassNames, renderAttachment_unstable, useAttachmentStyles_unstable, useAttachment_unstable } from './Attachment';
4
+ export { AttachmentOverflowMenu, renderAttachmentOverflowMenu_unstable, useAttachmentOverflowMenu_unstable } from './AttachmentOverflowMenu';
5
+ export { AttachmentOverflowMenuContext, AttachmentOverflowMenuProvider, useAttachmentOverflowMenuContext_unstable } from './contexts/attachmentOverflowMenuContext';
6
+ export { AttachmentOverflowMenuButton, attachmentOverflowMenuButtonClassNames, renderAttachmentOverflowMenuButton_unstable, useAttachmentOverflowMenuButtonStyles_unstable, useAttachmentOverflowMenuButton_unstable } from './AttachmentOverflowMenuButton';
7
+ export { AttachmentOverflowMenuItem, attachmentOverflowMenuItemClassNames, renderAttachmentOverflowMenuItem_unstable, useAttachmentOverflowMenuItemStyles_unstable, useAttachmentOverflowMenuItem_unstable } from './AttachmentOverflowMenuItem';
8
+ export { AgentTag, renderAgentTag_unstable, useAgentTag_unstable, agentTagClassNames, useAgentTagStyles_unstable } from './AgentTag';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export type {\n AttachmentListProps,\n AttachmentListSlots,\n AttachmentListState,\n AttachmentDismissedData,\n} from './AttachmentList';\nexport {\n AttachmentList,\n attachmentListClassNames,\n renderAttachmentList_unstable,\n useAttachmentListStyles_unstable,\n useAttachmentList_unstable,\n} from './AttachmentList';\nexport type { AttachmentListContextValue } from './contexts/attachmentListContext';\nexport {\n AttachmentListContext,\n AttachmentListProvider,\n useAttachmentListContext_unstable,\n} from './contexts/attachmentListContext';\nexport type { AttachmentProps, AttachmentSlots, AttachmentState } from './Attachment';\nexport {\n Attachment,\n attachmentClassNames,\n renderAttachment_unstable,\n useAttachmentStyles_unstable,\n useAttachment_unstable,\n} from './Attachment';\n\nexport type {\n AttachmentOverflowMenuProps,\n AttachmentOverflowMenuSlots,\n AttachmentOverflowMenuState,\n} from './AttachmentOverflowMenu';\nexport {\n AttachmentOverflowMenu,\n renderAttachmentOverflowMenu_unstable,\n useAttachmentOverflowMenu_unstable,\n} from './AttachmentOverflowMenu';\n\nexport type { AttachmentOverflowMenuContextValue } from './contexts/attachmentOverflowMenuContext';\nexport {\n AttachmentOverflowMenuContext,\n AttachmentOverflowMenuProvider,\n useAttachmentOverflowMenuContext_unstable,\n} from './contexts/attachmentOverflowMenuContext';\n\nexport type {\n AttachmentOverflowMenuButtonProps,\n AttachmentOverflowMenuButtonSlots,\n AttachmentOverflowMenuButtonState,\n} from './AttachmentOverflowMenuButton';\nexport {\n AttachmentOverflowMenuButton,\n attachmentOverflowMenuButtonClassNames,\n renderAttachmentOverflowMenuButton_unstable,\n useAttachmentOverflowMenuButtonStyles_unstable,\n useAttachmentOverflowMenuButton_unstable,\n} from './AttachmentOverflowMenuButton';\n\nexport type {\n AttachmentOverflowMenuItemProps,\n AttachmentOverflowMenuItemSlots,\n AttachmentOverflowMenuItemState,\n} from './AttachmentOverflowMenuItem';\nexport {\n AttachmentOverflowMenuItem,\n attachmentOverflowMenuItemClassNames,\n renderAttachmentOverflowMenuItem_unstable,\n useAttachmentOverflowMenuItemStyles_unstable,\n useAttachmentOverflowMenuItem_unstable,\n} from './AttachmentOverflowMenuItem';\n\nexport {\n AgentTag,\n renderAgentTag_unstable,\n useAgentTag_unstable,\n agentTagClassNames,\n useAgentTagStyles_unstable,\n} from './AgentTag';\nexport type { AgentTagProps, AgentTagSlots, AgentTagState } from './AgentTag';\n"],"names":["AttachmentList","attachmentListClassNames","renderAttachmentList_unstable","useAttachmentListStyles_unstable","useAttachmentList_unstable","AttachmentListContext","AttachmentListProvider","useAttachmentListContext_unstable","Attachment","attachmentClassNames","renderAttachment_unstable","useAttachmentStyles_unstable","useAttachment_unstable","AttachmentOverflowMenu","renderAttachmentOverflowMenu_unstable","useAttachmentOverflowMenu_unstable","AttachmentOverflowMenuContext","AttachmentOverflowMenuProvider","useAttachmentOverflowMenuContext_unstable","AttachmentOverflowMenuButton","attachmentOverflowMenuButtonClassNames","renderAttachmentOverflowMenuButton_unstable","useAttachmentOverflowMenuButtonStyles_unstable","useAttachmentOverflowMenuButton_unstable","AttachmentOverflowMenuItem","attachmentOverflowMenuItemClassNames","renderAttachmentOverflowMenuItem_unstable","useAttachmentOverflowMenuItemStyles_unstable","useAttachmentOverflowMenuItem_unstable","AgentTag","renderAgentTag_unstable","useAgentTag_unstable","agentTagClassNames","useAgentTagStyles_unstable"],"rangeMappings":";;;;;;;","mappings":"AAMA,SACEA,cAAc,EACdC,wBAAwB,EACxBC,6BAA6B,EAC7BC,gCAAgC,EAChCC,0BAA0B,QACrB,mBAAmB;AAE1B,SACEC,qBAAqB,EACrBC,sBAAsB,EACtBC,iCAAiC,QAC5B,mCAAmC;AAE1C,SACEC,UAAU,EACVC,oBAAoB,EACpBC,yBAAyB,EACzBC,4BAA4B,EAC5BC,sBAAsB,QACjB,eAAe;AAOtB,SACEC,sBAAsB,EACtBC,qCAAqC,EACrCC,kCAAkC,QAC7B,2BAA2B;AAGlC,SACEC,6BAA6B,EAC7BC,8BAA8B,EAC9BC,yCAAyC,QACpC,2CAA2C;AAOlD,SACEC,4BAA4B,EAC5BC,sCAAsC,EACtCC,2CAA2C,EAC3CC,8CAA8C,EAC9CC,wCAAwC,QACnC,iCAAiC;AAOxC,SACEC,0BAA0B,EAC1BC,oCAAoC,EACpCC,yCAAyC,EACzCC,4CAA4C,EAC5CC,sCAAsC,QACjC,+BAA+B;AAEtC,SACEC,QAAQ,EACRC,uBAAuB,EACvBC,oBAAoB,EACpBC,kBAAkB,EAClBC,0BAA0B,QACrB,aAAa"}