@fluentui-copilot/react-attachments 0.12.5-hotfix.1 → 0.12.5-hotfix.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (190) hide show
  1. package/CHANGELOG.json +4 -4
  2. package/CHANGELOG.md +5 -5
  3. package/lib/AgentTag.js +1 -0
  4. package/lib/Attachment.js +1 -0
  5. package/lib/AttachmentList.js +1 -0
  6. package/lib/AttachmentOverflowMenu.js +1 -0
  7. package/lib/AttachmentOverflowMenuButton.js +1 -0
  8. package/lib/AttachmentOverflowMenuItem.js +1 -0
  9. package/lib/AttachmentTag.js +1 -0
  10. package/lib/AttachmentTagItem.js +1 -0
  11. package/lib/AttachmentTagList.js +1 -0
  12. package/lib/components/AgentTag/AgentTag.js +5 -4
  13. package/lib/components/AgentTag/AgentTag.types.js +2 -1
  14. package/lib/components/AgentTag/index.js +1 -0
  15. package/lib/components/AgentTag/renderAgentTag.js +5 -3
  16. package/lib/components/AgentTag/useAgentTag.js +9 -7
  17. package/lib/components/AgentTag/useAgentTagStyles.styles.raw.js +57 -52
  18. package/lib/components/Attachment/Attachment.js +6 -5
  19. package/lib/components/Attachment/Attachment.types.js +2 -1
  20. package/lib/components/Attachment/index.js +1 -0
  21. package/lib/components/Attachment/renderAttachment.js +31 -36
  22. package/lib/components/Attachment/useAttachment.js +95 -85
  23. package/lib/components/Attachment/useAttachmentStyles.styles.raw.js +268 -258
  24. package/lib/components/AttachmentList/AttachmentList.js +7 -6
  25. package/lib/components/AttachmentList/AttachmentList.types.js +2 -1
  26. package/lib/components/AttachmentList/index.js +1 -0
  27. package/lib/components/AttachmentList/renderAttachmentList.js +25 -25
  28. package/lib/components/AttachmentList/useAttachmentList.js +124 -113
  29. package/lib/components/AttachmentList/useAttachmentListContextValues.js +15 -10
  30. package/lib/components/AttachmentList/useAttachmentListStyles.styles.raw.js +36 -31
  31. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +9 -8
  32. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +2 -1
  33. package/lib/components/AttachmentOverflowMenu/index.js +1 -0
  34. package/lib/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +13 -8
  35. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +15 -9
  36. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +15 -10
  37. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +6 -5
  38. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +2 -1
  39. package/lib/components/AttachmentOverflowMenuButton/index.js +1 -0
  40. package/lib/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +10 -11
  41. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +59 -51
  42. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +89 -82
  43. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +5 -4
  44. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +2 -1
  45. package/lib/components/AttachmentOverflowMenuItem/index.js +1 -0
  46. package/lib/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +8 -9
  47. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +49 -41
  48. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +49 -43
  49. package/lib/components/AttachmentTag/AttachmentTag.js +7 -5
  50. package/lib/components/AttachmentTag/AttachmentTag.types.js +2 -1
  51. package/lib/components/AttachmentTag/index.js +1 -0
  52. package/lib/components/AttachmentTag/renderAttachmentTag.js +8 -10
  53. package/lib/components/AttachmentTag/useAttachmentTag.js +11 -9
  54. package/lib/components/AttachmentTag/useAttachmentTagStyles.styles.raw.js +83 -76
  55. package/lib/components/AttachmentTagItem/AttachmentTagItem.js +6 -4
  56. package/lib/components/AttachmentTagItem/AttachmentTagItem.types.js +2 -1
  57. package/lib/components/AttachmentTagItem/index.js +1 -0
  58. package/lib/components/AttachmentTagItem/renderAttachmentTagItem.js +8 -10
  59. package/lib/components/AttachmentTagItem/useAttachmentTagItem.js +11 -9
  60. package/lib/components/AttachmentTagItem/useAttachmentTagItemStyles.styles.raw.js +27 -23
  61. package/lib/components/AttachmentTagList/AttachmentTagList.js +8 -6
  62. package/lib/components/AttachmentTagList/AttachmentTagList.types.js +2 -1
  63. package/lib/components/AttachmentTagList/index.js +1 -0
  64. package/lib/components/AttachmentTagList/renderAttachmentTagList.js +9 -7
  65. package/lib/components/AttachmentTagList/useAttachmentTagList.js +25 -21
  66. package/lib/components/AttachmentTagList/useAttachmentTagListContextValues.js +11 -8
  67. package/lib/components/AttachmentTagList/useAttachmentTagListStyles.styles.raw.js +15 -12
  68. package/lib/components/index.js +1 -0
  69. package/lib/components/utils/useAttachmentTagSlots.js +52 -45
  70. package/lib/components/utils/useProgressBarStyles.styles.raw.js +36 -34
  71. package/lib/contexts/attachmentListContext.js +5 -4
  72. package/lib/contexts/attachmentOverflowMenuContext.js +5 -4
  73. package/lib/contexts/attachmentTagListContext.js +3 -2
  74. package/lib/index.js +1 -0
  75. package/lib-commonjs/AgentTag.js +1 -0
  76. package/lib-commonjs/Attachment.js +1 -0
  77. package/lib-commonjs/AttachmentList.js +1 -0
  78. package/lib-commonjs/AttachmentOverflowMenu.js +1 -0
  79. package/lib-commonjs/AttachmentOverflowMenuButton.js +1 -0
  80. package/lib-commonjs/AttachmentOverflowMenuItem.js +1 -0
  81. package/lib-commonjs/AttachmentTag.js +1 -0
  82. package/lib-commonjs/AttachmentTagItem.js +1 -0
  83. package/lib-commonjs/AttachmentTagList.js +1 -0
  84. package/lib-commonjs/components/AgentTag/AgentTag.js +1 -1
  85. package/lib-commonjs/components/AgentTag/AgentTag.js.map +1 -1
  86. package/lib-commonjs/components/AgentTag/AgentTag.types.js +1 -0
  87. package/lib-commonjs/components/AgentTag/index.js +1 -0
  88. package/lib-commonjs/components/AgentTag/renderAgentTag.js +1 -1
  89. package/lib-commonjs/components/AgentTag/renderAgentTag.js.map +1 -1
  90. package/lib-commonjs/components/AgentTag/useAgentTag.js +1 -1
  91. package/lib-commonjs/components/AgentTag/useAgentTag.js.map +1 -1
  92. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js +1 -1
  93. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js.map +1 -1
  94. package/lib-commonjs/components/Attachment/Attachment.js +1 -1
  95. package/lib-commonjs/components/Attachment/Attachment.js.map +1 -1
  96. package/lib-commonjs/components/Attachment/Attachment.types.js +1 -0
  97. package/lib-commonjs/components/Attachment/index.js +1 -0
  98. package/lib-commonjs/components/Attachment/renderAttachment.js +1 -1
  99. package/lib-commonjs/components/Attachment/renderAttachment.js.map +1 -1
  100. package/lib-commonjs/components/Attachment/useAttachment.js +1 -1
  101. package/lib-commonjs/components/Attachment/useAttachment.js.map +1 -1
  102. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js +1 -1
  103. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js.map +1 -1
  104. package/lib-commonjs/components/AttachmentList/AttachmentList.js +1 -1
  105. package/lib-commonjs/components/AttachmentList/AttachmentList.js.map +1 -1
  106. package/lib-commonjs/components/AttachmentList/AttachmentList.types.js +1 -0
  107. package/lib-commonjs/components/AttachmentList/index.js +1 -0
  108. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js +1 -1
  109. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js.map +1 -1
  110. package/lib-commonjs/components/AttachmentList/useAttachmentList.js +1 -1
  111. package/lib-commonjs/components/AttachmentList/useAttachmentList.js.map +1 -1
  112. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js +1 -1
  113. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js.map +1 -1
  114. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js +1 -1
  115. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js.map +1 -1
  116. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +1 -1
  117. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js.map +1 -1
  118. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +1 -0
  119. package/lib-commonjs/components/AttachmentOverflowMenu/index.js +1 -0
  120. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +1 -1
  121. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js.map +1 -1
  122. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +1 -1
  123. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js.map +1 -1
  124. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +1 -1
  125. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js.map +1 -1
  126. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +1 -1
  127. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js.map +1 -1
  128. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +1 -0
  129. package/lib-commonjs/components/AttachmentOverflowMenuButton/index.js +1 -0
  130. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +1 -1
  131. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js.map +1 -1
  132. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +1 -1
  133. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js.map +1 -1
  134. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +1 -1
  135. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js.map +1 -1
  136. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +1 -1
  137. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js.map +1 -1
  138. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +1 -0
  139. package/lib-commonjs/components/AttachmentOverflowMenuItem/index.js +1 -0
  140. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +1 -1
  141. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js.map +1 -1
  142. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +1 -1
  143. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js.map +1 -1
  144. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +1 -1
  145. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js.map +1 -1
  146. package/lib-commonjs/components/AttachmentTag/AttachmentTag.js +1 -1
  147. package/lib-commonjs/components/AttachmentTag/AttachmentTag.js.map +1 -1
  148. package/lib-commonjs/components/AttachmentTag/AttachmentTag.types.js +1 -0
  149. package/lib-commonjs/components/AttachmentTag/index.js +1 -0
  150. package/lib-commonjs/components/AttachmentTag/renderAttachmentTag.js +1 -1
  151. package/lib-commonjs/components/AttachmentTag/renderAttachmentTag.js.map +1 -1
  152. package/lib-commonjs/components/AttachmentTag/useAttachmentTag.js +1 -1
  153. package/lib-commonjs/components/AttachmentTag/useAttachmentTag.js.map +1 -1
  154. package/lib-commonjs/components/AttachmentTag/useAttachmentTagStyles.styles.raw.js +1 -1
  155. package/lib-commonjs/components/AttachmentTag/useAttachmentTagStyles.styles.raw.js.map +1 -1
  156. package/lib-commonjs/components/AttachmentTagItem/AttachmentTagItem.js +1 -1
  157. package/lib-commonjs/components/AttachmentTagItem/AttachmentTagItem.js.map +1 -1
  158. package/lib-commonjs/components/AttachmentTagItem/AttachmentTagItem.types.js +1 -0
  159. package/lib-commonjs/components/AttachmentTagItem/index.js +1 -0
  160. package/lib-commonjs/components/AttachmentTagItem/renderAttachmentTagItem.js +1 -1
  161. package/lib-commonjs/components/AttachmentTagItem/renderAttachmentTagItem.js.map +1 -1
  162. package/lib-commonjs/components/AttachmentTagItem/useAttachmentTagItem.js +1 -1
  163. package/lib-commonjs/components/AttachmentTagItem/useAttachmentTagItem.js.map +1 -1
  164. package/lib-commonjs/components/AttachmentTagItem/useAttachmentTagItemStyles.styles.raw.js +1 -1
  165. package/lib-commonjs/components/AttachmentTagItem/useAttachmentTagItemStyles.styles.raw.js.map +1 -1
  166. package/lib-commonjs/components/AttachmentTagList/AttachmentTagList.js +1 -1
  167. package/lib-commonjs/components/AttachmentTagList/AttachmentTagList.js.map +1 -1
  168. package/lib-commonjs/components/AttachmentTagList/AttachmentTagList.types.js +1 -0
  169. package/lib-commonjs/components/AttachmentTagList/index.js +1 -0
  170. package/lib-commonjs/components/AttachmentTagList/renderAttachmentTagList.js +1 -1
  171. package/lib-commonjs/components/AttachmentTagList/renderAttachmentTagList.js.map +1 -1
  172. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagList.js +1 -1
  173. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagList.js.map +1 -1
  174. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagListContextValues.js +1 -1
  175. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagListContextValues.js.map +1 -1
  176. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagListStyles.styles.raw.js +1 -1
  177. package/lib-commonjs/components/AttachmentTagList/useAttachmentTagListStyles.styles.raw.js.map +1 -1
  178. package/lib-commonjs/components/index.js +1 -0
  179. package/lib-commonjs/components/utils/useAttachmentTagSlots.js +1 -1
  180. package/lib-commonjs/components/utils/useAttachmentTagSlots.js.map +1 -1
  181. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js +1 -1
  182. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js.map +1 -1
  183. package/lib-commonjs/contexts/attachmentListContext.js +1 -1
  184. package/lib-commonjs/contexts/attachmentListContext.js.map +1 -1
  185. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js +1 -1
  186. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js.map +1 -1
  187. package/lib-commonjs/contexts/attachmentTagListContext.js +1 -1
  188. package/lib-commonjs/contexts/attachmentTagListContext.js.map +1 -1
  189. package/lib-commonjs/index.js +1 -0
  190. package/package.json +4 -4
@@ -2,316 +2,326 @@ import { createCustomFocusIndicatorStyle, makeResetStyles, makeStyles, mergeClas
2
2
  import { tokens } from '@fluentui-copilot/tokens';
3
3
  import { useProgressBarStyles } from '../utils/useProgressBarStyles.styles';
4
4
  export const attachmentClassNames = {
5
- root: 'fai-Attachment',
6
- primaryAction: 'fai-Attachment__primaryAction',
7
- dismissButton: 'fai-Attachment__dismissButton',
8
- media: 'fai-Attachment__media',
9
- content: 'fai-Attachment__content',
10
- dismissIcon: 'fai-Attachment__dismissIcon',
11
- progress: 'fai-Attachment__progress'
5
+ root: 'fai-Attachment',
6
+ primaryAction: 'fai-Attachment__primaryAction',
7
+ dismissButton: 'fai-Attachment__dismissButton',
8
+ media: 'fai-Attachment__media',
9
+ content: 'fai-Attachment__content',
10
+ dismissIcon: 'fai-Attachment__dismissIcon',
11
+ progress: 'fai-Attachment__progress'
12
12
  };
13
13
  const ATTACHMENT_MAXWIDTH = '180px';
14
14
  const SMALL_ATTACHMENT_SIZE = '16px';
15
15
  const ATTACHMENT_SIZE = '20px';
16
16
  const useRootBaseClassName = makeResetStyles({
17
- display: 'inline-flex',
18
- flexWrap: 'nowrap',
19
- verticalAlign: 'middle',
20
- boxSizing: 'border-box',
21
- width: 'fit-content',
22
- alignSelf: 'end',
23
- position: 'relative'
17
+ display: 'inline-flex',
18
+ flexWrap: 'nowrap',
19
+ verticalAlign: 'middle',
20
+ boxSizing: 'border-box',
21
+ width: 'fit-content',
22
+ alignSelf: 'end',
23
+ position: 'relative'
24
24
  });
25
25
  const buttonBaseStyles = {
26
- alignItems: 'center',
27
- backgroundColor: tokens.colorSubtleBackground,
28
- border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke1}`,
29
- borderRadius: tokens.borderRadiusMedium,
30
- boxSizing: 'border-box',
31
- columnGap: tokens.spacingHorizontalSNudge,
32
- color: tokens.colorNeutralForeground1,
33
- cursor: 'pointer',
34
- display: 'inline-flex',
35
- flexWrap: 'nowrap',
36
- justifyContent: 'center',
37
- ...createCustomFocusIndicatorStyle({
38
- outline: `${tokens.strokeWidthThick} solid ${tokens.colorStrokeFocus2}`,
39
- zIndex: 1
40
- }),
41
- verticalAlign: 'middle'
26
+ alignItems: 'center',
27
+ backgroundColor: tokens.colorSubtleBackground,
28
+ border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke1}`,
29
+ borderRadius: tokens.borderRadiusMedium,
30
+ boxSizing: 'border-box',
31
+ columnGap: tokens.spacingHorizontalSNudge,
32
+ color: tokens.colorNeutralForeground1,
33
+ cursor: 'pointer',
34
+ display: 'inline-flex',
35
+ flexWrap: 'nowrap',
36
+ justifyContent: 'center',
37
+ ...createCustomFocusIndicatorStyle({
38
+ outline: `${tokens.strokeWidthThick} solid ${tokens.colorStrokeFocus2}`,
39
+ zIndex: 1
40
+ }),
41
+ verticalAlign: 'middle'
42
42
  };
43
43
  const usePrimaryActionBaseClassName = makeResetStyles({
44
- ...buttonBaseStyles,
45
- borderTopRightRadius: tokens.borderRadiusNone,
46
- borderBottomRightRadius: tokens.borderRadiusNone,
47
- borderRightStyle: 'none',
48
- maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,
49
- padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS}`
44
+ ...buttonBaseStyles,
45
+ borderTopRightRadius: tokens.borderRadiusNone,
46
+ borderBottomRightRadius: tokens.borderRadiusNone,
47
+ borderRightStyle: 'none',
48
+ maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,
49
+ padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalS}`
50
50
  });
51
51
  const usePrimaryActionStyles = makeStyles({
52
- button: {
53
- ':hover': {
54
- cursor: 'pointer',
55
- backgroundColor: tokens.colorSubtleBackgroundHover,
56
- color: tokens.colorNeutralForeground2Hover
57
- },
58
- ':active': {
59
- backgroundColor: tokens.colorSubtleBackgroundPressed,
60
- color: tokens.colorNeutralForeground2Pressed
61
- },
62
- '@media (forced-colors: active)': {
63
- ':hover': {
64
- backgroundColor: 'HighlightText'
65
- },
66
- ':active': {
67
- backgroundColor: 'HighlightText'
68
- }
69
- }
52
+ button: {
53
+ ':hover': {
54
+ cursor: 'pointer',
55
+ backgroundColor: tokens.colorSubtleBackgroundHover,
56
+ color: tokens.colorNeutralForeground2Hover
57
+ },
58
+ ':active': {
59
+ backgroundColor: tokens.colorSubtleBackgroundPressed,
60
+ color: tokens.colorNeutralForeground2Pressed
61
+ },
62
+ '@media (forced-colors: active)': {
63
+ ':hover': {
64
+ backgroundColor: 'HighlightText'
65
+ },
66
+ ':active': {
67
+ backgroundColor: 'HighlightText'
68
+ }
70
69
  }
70
+ }
71
71
  });
72
72
  const useDismissButtonBaseClassName = makeResetStyles({
73
- ...buttonBaseStyles,
74
- padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS}`,
75
- maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
76
- minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
77
- // divider:
78
- borderLeftColor: tokens.colorNeutralStroke1,
79
- borderTopLeftRadius: tokens.borderRadiusNone,
80
- borderBottomLeftRadius: tokens.borderRadiusNone,
81
- borderTopRightRadius: tokens.borderRadiusMedium,
82
- borderBottomRightRadius: tokens.borderRadiusMedium,
73
+ ...buttonBaseStyles,
74
+ padding: `${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS} ${tokens.spacingVerticalXS} ${tokens.spacingHorizontalXS}`,
75
+ maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
76
+ minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
77
+ // divider:
78
+ borderLeftColor: tokens.colorNeutralStroke1,
79
+ borderTopLeftRadius: tokens.borderRadiusNone,
80
+ borderBottomLeftRadius: tokens.borderRadiusNone,
81
+ borderTopRightRadius: tokens.borderRadiusMedium,
82
+ borderBottomRightRadius: tokens.borderRadiusMedium,
83
+ ':hover': {
84
+ cursor: 'pointer',
85
+ backgroundColor: tokens.colorSubtleBackgroundHover,
86
+ color: tokens.colorNeutralForeground2BrandHover
87
+ },
88
+ ':active': {
89
+ backgroundColor: tokens.colorSubtleBackgroundPressed,
90
+ color: tokens.colorNeutralForeground2BrandPressed
91
+ },
92
+ '@media (forced-colors: active)': {
83
93
  ':hover': {
84
- cursor: 'pointer',
85
- backgroundColor: tokens.colorSubtleBackgroundHover,
86
- color: tokens.colorNeutralForeground2BrandHover
94
+ backgroundColor: 'HighlightText'
87
95
  },
88
96
  ':active': {
89
- backgroundColor: tokens.colorSubtleBackgroundPressed,
90
- color: tokens.colorNeutralForeground2BrandPressed
91
- },
92
- '@media (forced-colors: active)': {
93
- ':hover': {
94
- backgroundColor: 'HighlightText'
95
- },
96
- ':active': {
97
- backgroundColor: 'HighlightText'
98
- }
97
+ backgroundColor: 'HighlightText'
99
98
  }
99
+ }
100
100
  });
101
101
  const useDismissButtonCurrentStyles = makeStyles({
102
- root: {
103
- ':hover': {
104
- [`& .${attachmentClassNames.dismissIcon}`]: {
105
- color: tokens.colorBrandForegroundLinkHover
106
- }
107
- }
102
+ root: {
103
+ ':hover': {
104
+ [`& .${attachmentClassNames.dismissIcon}`]: {
105
+ color: tokens.colorBrandForegroundLinkHover
106
+ }
108
107
  }
108
+ }
109
109
  });
110
110
  const useMediaBaseClassName = makeResetStyles({
111
- alignItems: 'center',
112
- display: 'inline-flex',
113
- fontSize: ATTACHMENT_SIZE,
114
- height: ATTACHMENT_SIZE,
115
- lineHeight: ATTACHMENT_SIZE,
116
- width: ATTACHMENT_SIZE
111
+ alignItems: 'center',
112
+ display: 'inline-flex',
113
+ fontSize: ATTACHMENT_SIZE,
114
+ height: ATTACHMENT_SIZE,
115
+ lineHeight: ATTACHMENT_SIZE,
116
+ width: ATTACHMENT_SIZE
117
117
  });
118
118
  const useContentBaseClassName = makeResetStyles({
119
- overflowX: 'hidden',
120
- textOverflow: 'ellipsis',
121
- whiteSpace: 'nowrap',
122
- ...typographyStyles.body1
119
+ overflowX: 'hidden',
120
+ textOverflow: 'ellipsis',
121
+ whiteSpace: 'nowrap',
122
+ ...typographyStyles.body1
123
123
  });
124
124
  const useDismissIconBaseClassName = makeResetStyles({
125
- alignItems: 'center',
126
- borderRadius: tokens.borderRadiusCircular,
127
- border: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,
128
- boxSizing: 'border-box',
129
- color: tokens.colorNeutralForeground1,
130
- display: 'inline-flex',
131
- fontSize: ATTACHMENT_SIZE,
132
- height: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,
133
- justifyContent: 'center',
134
- maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
135
- minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
136
- padding: `calc(${tokens.spacingVerticalXXS} / 2) calc(${tokens.spacingHorizontalXXS} / 2)`
125
+ alignItems: 'center',
126
+ borderRadius: tokens.borderRadiusCircular,
127
+ border: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,
128
+ boxSizing: 'border-box',
129
+ color: tokens.colorNeutralForeground1,
130
+ display: 'inline-flex',
131
+ fontSize: ATTACHMENT_SIZE,
132
+ height: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,
133
+ justifyContent: 'center',
134
+ maxWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
135
+ minWidth: `calc(${ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
136
+ padding: `calc(${tokens.spacingVerticalXXS} / 2) calc(${tokens.spacingHorizontalXXS} / 2)`
137
137
  });
138
138
  const useDismissIconNextStyles = makeStyles({
139
- dismissOnly: {
140
- ':hover': {
141
- color: tokens.colorNeutralForeground2BrandHover
142
- },
143
- ':active': {
144
- color: tokens.colorNeutralForeground2BrandPressed
145
- }
139
+ dismissOnly: {
140
+ ':hover': {
141
+ color: tokens.colorNeutralForeground2BrandHover
142
+ },
143
+ ':active': {
144
+ color: tokens.colorNeutralForeground2BrandPressed
146
145
  }
146
+ }
147
147
  });
148
148
  const useImageOnlyStyles = makeStyles({
149
- primaryAction: {
150
- padding: 0
151
- },
152
- content: {
153
- lineHeight: 0
154
- }
149
+ primaryAction: {
150
+ padding: 0
151
+ },
152
+ content: {
153
+ lineHeight: 0
154
+ }
155
155
  });
156
156
  export const useOverflowStyles = makeStyles({
157
- overflow: {
158
- maxWidth: '100%',
159
- width: '100%'
160
- }
157
+ overflow: {
158
+ maxWidth: '100%',
159
+ width: '100%'
160
+ }
161
161
  });
162
162
  const useSmallStyles = makeStyles({
163
- primaryAction: {
164
- maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,
165
- padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge} ${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge}`
166
- },
167
- media: {
168
- fontSize: SMALL_ATTACHMENT_SIZE,
169
- height: SMALL_ATTACHMENT_SIZE,
170
- lineHeight: SMALL_ATTACHMENT_SIZE,
171
- width: SMALL_ATTACHMENT_SIZE
172
- },
173
- content: {
174
- ...typographyStyles.caption1
175
- },
176
- dismissButton: {
177
- padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalXXS}`,
178
- maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
179
- minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`
180
- },
181
- dismissIcon: {
182
- fontSize: SMALL_ATTACHMENT_SIZE,
183
- height: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,
184
- maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
185
- minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`
186
- }
163
+ primaryAction: {
164
+ maxWidth: `calc(${ATTACHMENT_MAXWIDTH} - ${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS} - ${tokens.spacingHorizontalXS})`,
165
+ padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge} ${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalSNudge}`
166
+ },
167
+ media: {
168
+ fontSize: SMALL_ATTACHMENT_SIZE,
169
+ height: SMALL_ATTACHMENT_SIZE,
170
+ lineHeight: SMALL_ATTACHMENT_SIZE,
171
+ width: SMALL_ATTACHMENT_SIZE
172
+ },
173
+ content: {
174
+ ...typographyStyles.caption1
175
+ },
176
+ dismissButton: {
177
+ padding: `${tokens.spacingVerticalXXS} ${tokens.spacingHorizontalXXS}`,
178
+ maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`,
179
+ minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS}) + ${tokens.spacingHorizontalXS}`
180
+ },
181
+ dismissIcon: {
182
+ fontSize: SMALL_ATTACHMENT_SIZE,
183
+ height: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingVerticalXXS})`,
184
+ maxWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`,
185
+ minWidth: `calc(${SMALL_ATTACHMENT_SIZE} + ${tokens.strokeWidthThin} * 2 + ${tokens.spacingHorizontalXXS})`
186
+ }
187
187
  });
188
188
  const usePrimaryActionNextStyles = makeStyles({
189
- root: {
190
- borderTopLeftRadius: tokens.borderRadiusXLarge,
191
- borderBottomLeftRadius: tokens.borderRadiusXLarge
192
- },
193
- canvas: {
194
- padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
195
- minHeight: '40px'
196
- },
197
- sidecar: {
198
- padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
199
- minHeight: '32px'
200
- }
189
+ root: {
190
+ borderTopLeftRadius: tokens.borderRadiusXLarge,
191
+ borderBottomLeftRadius: tokens.borderRadiusXLarge
192
+ },
193
+ canvas: {
194
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
195
+ minHeight: '40px'
196
+ },
197
+ sidecar: {
198
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
199
+ minHeight: '32px'
200
+ }
201
201
  });
202
202
  const useDismissButtonNextStyles = makeStyles({
203
- root: {
204
- borderTopRightRadius: tokens.borderRadiusXLarge,
205
- borderBottomRightRadius: tokens.borderRadiusXLarge,
206
- ':hover': {
207
- color: tokens.colorNeutralForeground2
208
- },
209
- ':active': {
210
- color: tokens.colorNeutralForeground2Pressed
211
- },
212
- borderLeftColor: tokens.colorNeutralStroke1,
213
- borderLeftWidth: tokens.strokeWidthThin,
214
- borderLeftStyle: 'solid'
203
+ root: {
204
+ borderTopRightRadius: tokens.borderRadiusXLarge,
205
+ borderBottomRightRadius: tokens.borderRadiusXLarge,
206
+ ':hover': {
207
+ color: tokens.colorNeutralForeground2
215
208
  },
216
- withPrimary: {
217
- ':hover': {
218
- [`& .${attachmentClassNames.dismissIcon}`]: {
219
- color: tokens.colorNeutralForeground2
220
- }
221
- },
222
- ':active': {
223
- [`& .${attachmentClassNames.dismissIcon}`]: {
224
- color: tokens.colorNeutralForeground2Pressed
225
- }
226
- }
209
+ ':active': {
210
+ color: tokens.colorNeutralForeground2Pressed
227
211
  },
228
- canvas: {
229
- padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
230
- minHeight: '40px',
231
- width: '40px'
212
+ borderLeftColor: tokens.colorNeutralStroke1,
213
+ borderLeftWidth: tokens.strokeWidthThin,
214
+ borderLeftStyle: 'solid'
215
+ },
216
+ withPrimary: {
217
+ ':hover': {
218
+ [`& .${attachmentClassNames.dismissIcon}`]: {
219
+ color: tokens.colorNeutralForeground2
220
+ }
232
221
  },
233
- sidecar: {
234
- padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalMNudge}`,
235
- minHeight: '32px',
236
- width: '32px'
222
+ ':active': {
223
+ [`& .${attachmentClassNames.dismissIcon}`]: {
224
+ color: tokens.colorNeutralForeground2Pressed
225
+ }
226
+ }
227
+ },
228
+ canvas: {
229
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalS}`,
230
+ minHeight: '40px',
231
+ width: '40px'
232
+ },
233
+ sidecar: {
234
+ padding: `${tokens.spacingVerticalNone} ${tokens.spacingHorizontalMNudge}`,
235
+ minHeight: '32px',
236
+ width: '32px'
237
+ },
238
+ dismissOnly: {
239
+ borderRadius: tokens.borderRadiusXLarge,
240
+ width: 'unset',
241
+ borderLeftColor: tokens.colorTransparentStroke,
242
+ backgroundColor: tokens.colorNeutralBackground3,
243
+ ':hover': {
244
+ backgroundColor: tokens.colorNeutralBackground3
237
245
  },
238
- dismissOnly: {
239
- borderRadius: tokens.borderRadiusXLarge,
240
- width: 'unset',
241
- borderLeftColor: tokens.colorTransparentStroke,
242
- backgroundColor: tokens.colorNeutralBackground3,
243
- ':hover': {
244
- backgroundColor: tokens.colorNeutralBackground3
245
- },
246
- ':active': {
247
- backgroundColor: tokens.colorNeutralBackground3
248
- }
246
+ ':active': {
247
+ backgroundColor: tokens.colorNeutralBackground3
249
248
  }
249
+ }
250
250
  });
251
251
  const usePrimaryDismissNextStyles = makeStyles({
252
- sharedStyles: {
253
- border: 'none',
254
- backgroundColor: tokens.colorNeutralBackground3,
255
- ':hover': {
256
- backgroundColor: tokens.colorNeutralBackground3Hover
257
- },
258
- ':active': {
259
- backgroundColor: tokens.colorNeutralBackground3Pressed
260
- },
261
- ':focus-visible': {
262
- borderRadius: tokens.borderRadiusLarge
263
- }
252
+ sharedStyles: {
253
+ border: 'none',
254
+ backgroundColor: tokens.colorNeutralBackground3,
255
+ ':hover': {
256
+ backgroundColor: tokens.colorNeutralBackground3Hover
257
+ },
258
+ ':active': {
259
+ backgroundColor: tokens.colorNeutralBackground3Pressed
260
+ },
261
+ ':focus-visible': {
262
+ borderRadius: tokens.borderRadiusLarge
264
263
  }
264
+ }
265
265
  });
266
266
  const useRootNextStyles = makeStyles({
267
- root: {
268
- outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,
269
- borderRadius: tokens.borderRadiusXLarge
270
- }
267
+ root: {
268
+ outline: `${tokens.strokeWidthThin} solid ${tokens.colorTransparentStroke}`,
269
+ borderRadius: tokens.borderRadiusXLarge
270
+ }
271
271
  });
272
272
  /**
273
273
  * Apply styling to the Attachment slots based on the state
274
- */ export const useAttachmentStyles_unstable = (state)=>{
275
- 'use no memo';
276
- const rootBaseClassName = useRootBaseClassName();
277
- const primaryActionBaseClassName = usePrimaryActionBaseClassName();
278
- const dismissButtonBaseClassName = useDismissButtonBaseClassName();
279
- const dismissButtonCurrentStyles = useDismissButtonCurrentStyles();
280
- const mediaBaseClassName = useMediaBaseClassName();
281
- const contentBaseClassName = useContentBaseClassName();
282
- const dismissIconBaseClassName = useDismissIconBaseClassName();
283
- const dismissIconNextStyles = useDismissIconNextStyles();
284
- const progressBarStyles = useProgressBarStyles();
285
- const primaryActionStyles = usePrimaryActionStyles();
286
- const imageOnlyStyles = useImageOnlyStyles();
287
- const smallStyles = useSmallStyles();
288
- const primaryActionNextStyles = usePrimaryActionNextStyles();
289
- const dismissButtonNextStyles = useDismissButtonNextStyles();
290
- const primaryDismissNextStyles = usePrimaryDismissNextStyles();
291
- const rootNextStyles = useRootNextStyles();
292
- const { imageOnly, primaryAction, size, mode, designVersion, dismissOnly } = state;
293
- state.root.className = mergeClasses(attachmentClassNames.root, rootBaseClassName, designVersion === 'next' && rootNextStyles.root, state.root.className);
294
- state.primaryAction.className = mergeClasses(attachmentClassNames.primaryAction, primaryActionBaseClassName, size === 'small' && smallStyles.primaryAction, primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button, imageOnly && imageOnlyStyles.primaryAction, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryActionNextStyles.root, designVersion === 'next' && primaryActionNextStyles[mode], state.primaryAction.className);
295
- state.dismissButton.className = mergeClasses(attachmentClassNames.dismissButton, dismissButtonBaseClassName, designVersion === 'current' && dismissButtonCurrentStyles.root, size === 'small' && smallStyles.dismissButton, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && dismissButtonNextStyles.root, designVersion === 'next' && dismissButtonNextStyles[mode], designVersion === 'next' && dismissOnly && dismissButtonNextStyles.dismissOnly, designVersion === 'next' && !dismissOnly && dismissButtonNextStyles.withPrimary, state.dismissButton.className);
296
- if (state.media) {
297
- state.media.className = mergeClasses(attachmentClassNames.media, mediaBaseClassName, size === 'small' && smallStyles.media, state.media.className);
298
- }
299
- state.content.className = mergeClasses(attachmentClassNames.content, contentBaseClassName, size === 'small' && smallStyles.content, imageOnly && imageOnlyStyles.content, state.content.className);
300
- state.dismissIcon.className = mergeClasses(attachmentClassNames.dismissIcon, dismissIconBaseClassName, size === 'small' && smallStyles.dismissIcon, designVersion === 'next' && dismissOnly && dismissIconNextStyles.dismissOnly, state.dismissIcon.className);
301
- if (state.progress) {
302
- state.progress.className = mergeClasses(attachmentClassNames.progress, progressBarStyles.progress, state.progress.className);
303
- const bar = slot.optional(state.progress.bar, {
304
- elementType: 'div',
305
- renderByDefault: true
306
- });
307
- if (bar) {
308
- if (state.progress.value === undefined) {
309
- bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);
310
- } else {
311
- bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);
312
- }
313
- state.progress.bar = bar;
314
- }
274
+ */
275
+ export const useAttachmentStyles_unstable = state => {
276
+ 'use no memo';
277
+
278
+ const rootBaseClassName = useRootBaseClassName();
279
+ const primaryActionBaseClassName = usePrimaryActionBaseClassName();
280
+ const dismissButtonBaseClassName = useDismissButtonBaseClassName();
281
+ const dismissButtonCurrentStyles = useDismissButtonCurrentStyles();
282
+ const mediaBaseClassName = useMediaBaseClassName();
283
+ const contentBaseClassName = useContentBaseClassName();
284
+ const dismissIconBaseClassName = useDismissIconBaseClassName();
285
+ const dismissIconNextStyles = useDismissIconNextStyles();
286
+ const progressBarStyles = useProgressBarStyles();
287
+ const primaryActionStyles = usePrimaryActionStyles();
288
+ const imageOnlyStyles = useImageOnlyStyles();
289
+ const smallStyles = useSmallStyles();
290
+ const primaryActionNextStyles = usePrimaryActionNextStyles();
291
+ const dismissButtonNextStyles = useDismissButtonNextStyles();
292
+ const primaryDismissNextStyles = usePrimaryDismissNextStyles();
293
+ const rootNextStyles = useRootNextStyles();
294
+ const {
295
+ imageOnly,
296
+ primaryAction,
297
+ size,
298
+ mode,
299
+ designVersion,
300
+ dismissOnly
301
+ } = state;
302
+ state.root.className = mergeClasses(attachmentClassNames.root, rootBaseClassName, designVersion === 'next' && rootNextStyles.root, state.root.className);
303
+ state.primaryAction.className = mergeClasses(attachmentClassNames.primaryAction, primaryActionBaseClassName, size === 'small' && smallStyles.primaryAction, primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button, imageOnly && imageOnlyStyles.primaryAction, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryActionNextStyles.root, designVersion === 'next' && primaryActionNextStyles[mode], state.primaryAction.className);
304
+ state.dismissButton.className = mergeClasses(attachmentClassNames.dismissButton, dismissButtonBaseClassName, designVersion === 'current' && dismissButtonCurrentStyles.root, size === 'small' && smallStyles.dismissButton, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && dismissButtonNextStyles.root, designVersion === 'next' && dismissButtonNextStyles[mode], designVersion === 'next' && dismissOnly && dismissButtonNextStyles.dismissOnly, designVersion === 'next' && !dismissOnly && dismissButtonNextStyles.withPrimary, state.dismissButton.className);
305
+ if (state.media) {
306
+ state.media.className = mergeClasses(attachmentClassNames.media, mediaBaseClassName, size === 'small' && smallStyles.media, state.media.className);
307
+ }
308
+ state.content.className = mergeClasses(attachmentClassNames.content, contentBaseClassName, size === 'small' && smallStyles.content, imageOnly && imageOnlyStyles.content, state.content.className);
309
+ state.dismissIcon.className = mergeClasses(attachmentClassNames.dismissIcon, dismissIconBaseClassName, size === 'small' && smallStyles.dismissIcon, designVersion === 'next' && dismissOnly && dismissIconNextStyles.dismissOnly, state.dismissIcon.className);
310
+ if (state.progress) {
311
+ state.progress.className = mergeClasses(attachmentClassNames.progress, progressBarStyles.progress, state.progress.className);
312
+ const bar = slot.optional(state.progress.bar, {
313
+ elementType: 'div',
314
+ renderByDefault: true
315
+ });
316
+ if (bar) {
317
+ if (state.progress.value === undefined) {
318
+ bar.className = mergeClasses(progressBarStyles.indeterminateProgressBar, bar.className);
319
+ } else {
320
+ bar.className = mergeClasses(progressBarStyles.regularProgressBar, bar.className);
321
+ }
322
+ state.progress.bar = bar;
315
323
  }
316
- return state;
324
+ }
325
+ return state;
317
326
  };
327
+ //# sourceMappingURL=useAttachmentStyles.styles.raw.js.map
@@ -4,11 +4,12 @@ import { renderAttachmentList_unstable } from './renderAttachmentList';
4
4
  import { useAttachmentListStyles_unstable } from './useAttachmentListStyles.styles';
5
5
  import { useAttachmentListContextValues_unstable } from './useAttachmentListContextValues';
6
6
  import { useCustomStyleHook } from '@fluentui-copilot/react-provider';
7
- export const AttachmentList = /*#__PURE__*/ React.forwardRef((props, ref)=>{
8
- const state = useAttachmentList_unstable(props, ref);
9
- const contextValues = useAttachmentListContextValues_unstable(state);
10
- useAttachmentListStyles_unstable(state);
11
- useCustomStyleHook('useAttachmentListStyles')(state);
12
- return renderAttachmentList_unstable(state, contextValues);
7
+ export const AttachmentList = /*#__PURE__*/React.forwardRef((props, ref) => {
8
+ const state = useAttachmentList_unstable(props, ref);
9
+ const contextValues = useAttachmentListContextValues_unstable(state);
10
+ useAttachmentListStyles_unstable(state);
11
+ useCustomStyleHook('useAttachmentListStyles')(state);
12
+ return renderAttachmentList_unstable(state, contextValues);
13
13
  });
14
14
  AttachmentList.displayName = 'AttachmentList';
15
+ //# sourceMappingURL=AttachmentList.js.map
@@ -1 +1,2 @@
1
- export { };
1
+ export {};
2
+ //# sourceMappingURL=AttachmentList.types.js.map
@@ -2,3 +2,4 @@ export { AttachmentList } from './AttachmentList';
2
2
  export { renderAttachmentList_unstable } from './renderAttachmentList';
3
3
  export { useAttachmentList_unstable } from './useAttachmentList';
4
4
  export { attachmentListClassNames, useAttachmentListStyles_unstable } from './useAttachmentListStyles.styles';
5
+ //# sourceMappingURL=index.js.map