@fluentui-copilot/react-attachments 0.13.2 → 0.13.4

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 (141) hide show
  1. package/CHANGELOG.json +31 -1
  2. package/CHANGELOG.md +20 -2
  3. package/lib/AgentTag.js +0 -1
  4. package/lib/Attachment.js +0 -1
  5. package/lib/AttachmentList.js +0 -1
  6. package/lib/AttachmentOverflowMenu.js +0 -1
  7. package/lib/AttachmentOverflowMenuButton.js +0 -1
  8. package/lib/AttachmentOverflowMenuItem.js +0 -1
  9. package/lib/components/AgentTag/AgentTag.js +4 -5
  10. package/lib/components/AgentTag/AgentTag.types.js +1 -2
  11. package/lib/components/AgentTag/index.js +0 -1
  12. package/lib/components/AgentTag/renderAgentTag.js +3 -5
  13. package/lib/components/AgentTag/useAgentTag.js +7 -9
  14. package/lib/components/AgentTag/useAgentTagStyles.styles.raw.js +66 -0
  15. package/lib/components/AgentTag/useAgentTagStyles.styles.raw.js.map +1 -0
  16. package/lib/components/Attachment/Attachment.js +5 -6
  17. package/lib/components/Attachment/Attachment.types.js +1 -2
  18. package/lib/components/Attachment/index.js +0 -1
  19. package/lib/components/Attachment/renderAttachment.js +36 -31
  20. package/lib/components/Attachment/useAttachment.js +85 -95
  21. package/lib/components/Attachment/useAttachmentStyles.styles.js +25 -17
  22. package/lib/components/Attachment/useAttachmentStyles.styles.js.map +1 -1
  23. package/lib/components/Attachment/useAttachmentStyles.styles.raw.js +328 -0
  24. package/lib/components/Attachment/useAttachmentStyles.styles.raw.js.map +1 -0
  25. package/lib/components/AttachmentList/AttachmentList.js +6 -7
  26. package/lib/components/AttachmentList/AttachmentList.types.js +1 -2
  27. package/lib/components/AttachmentList/index.js +0 -1
  28. package/lib/components/AttachmentList/renderAttachmentList.js +25 -25
  29. package/lib/components/AttachmentList/useAttachmentList.js +113 -124
  30. package/lib/components/AttachmentList/useAttachmentListContextValues.js +10 -15
  31. package/lib/components/AttachmentList/useAttachmentListStyles.styles.raw.js +44 -0
  32. package/lib/components/AttachmentList/useAttachmentListStyles.styles.raw.js.map +1 -0
  33. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +8 -9
  34. package/lib/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +1 -2
  35. package/lib/components/AttachmentOverflowMenu/index.js +0 -1
  36. package/lib/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +8 -13
  37. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +9 -15
  38. package/lib/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +10 -15
  39. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +5 -6
  40. package/lib/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +1 -2
  41. package/lib/components/AttachmentOverflowMenuButton/index.js +0 -1
  42. package/lib/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +11 -10
  43. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +51 -59
  44. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +102 -0
  45. package/lib/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js.map +1 -0
  46. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +4 -5
  47. package/lib/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +1 -2
  48. package/lib/components/AttachmentOverflowMenuItem/index.js +0 -1
  49. package/lib/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +9 -8
  50. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +41 -49
  51. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js +11 -3
  52. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js.map +1 -1
  53. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +59 -0
  54. package/lib/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js.map +1 -0
  55. package/lib/components/index.js +0 -1
  56. package/lib/components/utils/useProgressBarStyles.styles.raw.js +42 -0
  57. package/lib/components/utils/useProgressBarStyles.styles.raw.js.map +1 -0
  58. package/lib/contexts/attachmentListContext.js +4 -5
  59. package/lib/contexts/attachmentOverflowMenuContext.js +4 -5
  60. package/lib/index.js +0 -1
  61. package/lib-commonjs/AgentTag.js +0 -1
  62. package/lib-commonjs/Attachment.js +0 -1
  63. package/lib-commonjs/AttachmentList.js +0 -1
  64. package/lib-commonjs/AttachmentOverflowMenu.js +0 -1
  65. package/lib-commonjs/AttachmentOverflowMenuButton.js +0 -1
  66. package/lib-commonjs/AttachmentOverflowMenuItem.js +0 -1
  67. package/lib-commonjs/components/AgentTag/AgentTag.js +1 -1
  68. package/lib-commonjs/components/AgentTag/AgentTag.js.map +1 -1
  69. package/lib-commonjs/components/AgentTag/AgentTag.types.js +0 -1
  70. package/lib-commonjs/components/AgentTag/index.js +0 -1
  71. package/lib-commonjs/components/AgentTag/renderAgentTag.js +1 -1
  72. package/lib-commonjs/components/AgentTag/renderAgentTag.js.map +1 -1
  73. package/lib-commonjs/components/AgentTag/useAgentTag.js +1 -1
  74. package/lib-commonjs/components/AgentTag/useAgentTag.js.map +1 -1
  75. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js +82 -0
  76. package/lib-commonjs/components/AgentTag/useAgentTagStyles.styles.raw.js.map +1 -0
  77. package/lib-commonjs/components/Attachment/Attachment.js +1 -1
  78. package/lib-commonjs/components/Attachment/Attachment.js.map +1 -1
  79. package/lib-commonjs/components/Attachment/Attachment.types.js +0 -1
  80. package/lib-commonjs/components/Attachment/index.js +0 -1
  81. package/lib-commonjs/components/Attachment/renderAttachment.js +1 -1
  82. package/lib-commonjs/components/Attachment/renderAttachment.js.map +1 -1
  83. package/lib-commonjs/components/Attachment/useAttachment.js +1 -1
  84. package/lib-commonjs/components/Attachment/useAttachment.js.map +1 -1
  85. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.js +53 -33
  86. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.js.map +1 -1
  87. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js +347 -0
  88. package/lib-commonjs/components/Attachment/useAttachmentStyles.styles.raw.js.map +1 -0
  89. package/lib-commonjs/components/AttachmentList/AttachmentList.js +1 -1
  90. package/lib-commonjs/components/AttachmentList/AttachmentList.js.map +1 -1
  91. package/lib-commonjs/components/AttachmentList/AttachmentList.types.js +0 -1
  92. package/lib-commonjs/components/AttachmentList/index.js +0 -1
  93. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js +1 -1
  94. package/lib-commonjs/components/AttachmentList/renderAttachmentList.js.map +1 -1
  95. package/lib-commonjs/components/AttachmentList/useAttachmentList.js +1 -1
  96. package/lib-commonjs/components/AttachmentList/useAttachmentList.js.map +1 -1
  97. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js +1 -1
  98. package/lib-commonjs/components/AttachmentList/useAttachmentListContextValues.js.map +1 -1
  99. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js +60 -0
  100. package/lib-commonjs/components/AttachmentList/useAttachmentListStyles.styles.raw.js.map +1 -0
  101. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js +1 -1
  102. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.js.map +1 -1
  103. package/lib-commonjs/components/AttachmentOverflowMenu/AttachmentOverflowMenu.types.js +0 -1
  104. package/lib-commonjs/components/AttachmentOverflowMenu/index.js +0 -1
  105. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js +1 -1
  106. package/lib-commonjs/components/AttachmentOverflowMenu/renderAttachmentOverflowMenu.js.map +1 -1
  107. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js +1 -1
  108. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenu.js.map +1 -1
  109. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js +1 -1
  110. package/lib-commonjs/components/AttachmentOverflowMenu/useAttachmentOverflowMenuContextValues.js.map +1 -1
  111. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js +1 -1
  112. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.js.map +1 -1
  113. package/lib-commonjs/components/AttachmentOverflowMenuButton/AttachmentOverflowMenuButton.types.js +0 -1
  114. package/lib-commonjs/components/AttachmentOverflowMenuButton/index.js +0 -1
  115. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js +1 -1
  116. package/lib-commonjs/components/AttachmentOverflowMenuButton/renderAttachmentOverflowMenuButton.js.map +1 -1
  117. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js +1 -1
  118. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButton.js.map +1 -1
  119. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js +118 -0
  120. package/lib-commonjs/components/AttachmentOverflowMenuButton/useAttachmentOverflowMenuButtonStyles.styles.raw.js.map +1 -0
  121. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js +1 -1
  122. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.js.map +1 -1
  123. package/lib-commonjs/components/AttachmentOverflowMenuItem/AttachmentOverflowMenuItem.types.js +0 -1
  124. package/lib-commonjs/components/AttachmentOverflowMenuItem/index.js +0 -1
  125. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js +1 -1
  126. package/lib-commonjs/components/AttachmentOverflowMenuItem/renderAttachmentOverflowMenuItem.js.map +1 -1
  127. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js +1 -1
  128. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItem.js.map +1 -1
  129. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js +13 -2
  130. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.js.map +1 -1
  131. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js +75 -0
  132. package/lib-commonjs/components/AttachmentOverflowMenuItem/useAttachmentOverflowMenuItemStyles.styles.raw.js.map +1 -0
  133. package/lib-commonjs/components/index.js +0 -1
  134. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js +50 -0
  135. package/lib-commonjs/components/utils/useProgressBarStyles.styles.raw.js.map +1 -0
  136. package/lib-commonjs/contexts/attachmentListContext.js +1 -1
  137. package/lib-commonjs/contexts/attachmentListContext.js.map +1 -1
  138. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js +1 -1
  139. package/lib-commonjs/contexts/attachmentOverflowMenuContext.js.map +1 -1
  140. package/lib-commonjs/index.js +0 -1
  141. package/package.json +4 -4
@@ -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"}
@@ -1,10 +1,9 @@
1
1
  import { createContext, useContextSelector } from '@fluentui/react-context-selector';
2
2
  export const AttachmentListContext = createContext(undefined);
3
3
  const attachmentListContextDefaultValue = {
4
- onAttachmentDismiss: () => null,
5
- shouldUseOverflow: false,
6
- numberOfAttachments: 0
4
+ onAttachmentDismiss: ()=>null,
5
+ shouldUseOverflow: false,
6
+ numberOfAttachments: 0
7
7
  };
8
8
  export const AttachmentListProvider = AttachmentListContext.Provider;
9
- export const useAttachmentListContext_unstable = selector => useContextSelector(AttachmentListContext, (ctx = attachmentListContextDefaultValue) => selector(ctx));
10
- //# sourceMappingURL=attachmentListContext.js.map
9
+ export const useAttachmentListContext_unstable = (selector)=>useContextSelector(AttachmentListContext, (ctx = attachmentListContextDefaultValue)=>selector(ctx));
@@ -1,10 +1,9 @@
1
1
  import { createContext, useContextSelector } from '@fluentui/react-context-selector';
2
2
  export const AttachmentOverflowMenuContext = createContext(undefined);
3
3
  const overflowMenuContextDefaultValue = {
4
- isOverflowing: false,
5
- overflowButtonRef: undefined,
6
- overflowCount: 0
4
+ isOverflowing: false,
5
+ overflowButtonRef: undefined,
6
+ overflowCount: 0
7
7
  };
8
8
  export const AttachmentOverflowMenuProvider = AttachmentOverflowMenuContext.Provider;
9
- export const useAttachmentOverflowMenuContext_unstable = selector => useContextSelector(AttachmentOverflowMenuContext, (ctx = overflowMenuContextDefaultValue) => selector(ctx));
10
- //# sourceMappingURL=attachmentOverflowMenuContext.js.map
9
+ export const useAttachmentOverflowMenuContext_unstable = (selector)=>useContextSelector(AttachmentOverflowMenuContext, (ctx = overflowMenuContextDefaultValue)=>selector(ctx));
package/lib/index.js CHANGED
@@ -6,4 +6,3 @@ export { AttachmentOverflowMenuContext, AttachmentOverflowMenuProvider, useAttac
6
6
  export { AttachmentOverflowMenuButton, attachmentOverflowMenuButtonClassNames, renderAttachmentOverflowMenuButton_unstable, useAttachmentOverflowMenuButtonStyles_unstable, useAttachmentOverflowMenuButton_unstable } from './AttachmentOverflowMenuButton';
7
7
  export { AttachmentOverflowMenuItem, attachmentOverflowMenuItemClassNames, renderAttachmentOverflowMenuItem_unstable, useAttachmentOverflowMenuItemStyles_unstable, useAttachmentOverflowMenuItem_unstable } from './AttachmentOverflowMenuItem';
8
8
  export { AgentTag, renderAgentTag_unstable, useAgentTag_unstable, agentTagClassNames, useAgentTagStyles_unstable } from './AgentTag';
9
- //# sourceMappingURL=index.js.map
@@ -26,4 +26,3 @@ _export(exports, {
26
26
  }
27
27
  });
28
28
  const _index = require("./components/AgentTag/index");
29
- //# sourceMappingURL=AgentTag.js.map
@@ -29,4 +29,3 @@ _export(exports, {
29
29
  }
30
30
  });
31
31
  const _index = require("./components/Attachment/index");
32
- //# sourceMappingURL=Attachment.js.map
@@ -26,4 +26,3 @@ _export(exports, {
26
26
  }
27
27
  });
28
28
  const _index = require("./components/AttachmentList/index");
29
- //# sourceMappingURL=AttachmentList.js.map
@@ -23,4 +23,3 @@ _export(exports, {
23
23
  }
24
24
  });
25
25
  const _index = require("./components/AttachmentOverflowMenu/index");
26
- //# sourceMappingURL=AttachmentOverflowMenu.js.map
@@ -26,4 +26,3 @@ _export(exports, {
26
26
  }
27
27
  });
28
28
  const _index = require("./components/AttachmentOverflowMenuButton/index");
29
- //# sourceMappingURL=AttachmentOverflowMenuButton.js.map
@@ -26,4 +26,3 @@ _export(exports, {
26
26
  }
27
27
  });
28
28
  const _index = require("./components/AttachmentOverflowMenuItem/index");
29
- //# sourceMappingURL=AttachmentOverflowMenuItem.js.map
@@ -18,4 +18,4 @@ const AgentTag = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
18
18
  (0, _useAgentTagStylesstyles.useAgentTagStyles_unstable)(state);
19
19
  return (0, _renderAgentTag.renderAgentTag_unstable)(state);
20
20
  });
21
- AgentTag.displayName = 'AgentTag'; //# sourceMappingURL=AgentTag.js.map
21
+ AgentTag.displayName = 'AgentTag';
@@ -1 +1 @@
1
- {"version":3,"sources":["AgentTag.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAgentTag_unstable } from './useAgentTag';\nimport { renderAgentTag_unstable } from './renderAgentTag';\nimport { useAgentTagStyles_unstable } from './useAgentTagStyles.styles';\nimport type { AgentTagProps } from './AgentTag.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\n\n// AgentTag component - TODO: add more docs\nexport const AgentTag: ForwardRefComponent<AgentTagProps> = React.forwardRef((props, ref) => {\n const state = useAgentTag_unstable(props, ref);\n\n useAgentTagStyles_unstable(state);\n return renderAgentTag_unstable(state);\n});\n\nAgentTag.displayName = 'AgentTag';\n"],"names":["AgentTag","React","forwardRef","props","state","useAgentTag_unstable","useAgentTagStyles_unstable","renderAgentTag_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAQaA;;;eAAAA;;;;iEARU;6BACc;gCACG;yCACG;AAKpC,MAAMA,WAAAA,WAAAA,GAAAA,OAA+CC,UAAMC,CAAU,CAACC,OAACA;UAC5EC,QAAMA,IAAAA,iCAAQC,EAAAA,OAAqBF;2DAEnCG,EAAAA;WACAC,IAAAA,uCAAOA,EAAAA;AACT;AAEAP,SAASQ,WAAW,GAAG"}
1
+ {"version":3,"sources":["AgentTag.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAgentTag_unstable } from './useAgentTag';\nimport { renderAgentTag_unstable } from './renderAgentTag';\nimport { useAgentTagStyles_unstable } from './useAgentTagStyles.styles';\nimport type { AgentTagProps } from './AgentTag.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\n\n// AgentTag component - TODO: add more docs\nexport const AgentTag: ForwardRefComponent<AgentTagProps> = React.forwardRef((props, ref) => {\n const state = useAgentTag_unstable(props, ref);\n\n useAgentTagStyles_unstable(state);\n return renderAgentTag_unstable(state);\n});\n\nAgentTag.displayName = 'AgentTag';\n"],"names":["AgentTag","React","forwardRef","props","ref","state","useAgentTag_unstable","useAgentTagStyles_unstable","renderAgentTag_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAQaA;;;eAAAA;;;;iEARU;6BACc;gCACG;yCACG;AAKpC,MAAMA,WAAAA,WAAAA,GAA+CC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IACnF,MAAMC,QAAQC,IAAAA,iCAAAA,EAAqBH,OAAOC;IAE1CG,IAAAA,mDAAAA,EAA2BF;IAC3B,OAAOG,IAAAA,uCAAAA,EAAwBH;AACjC;AAEAL,SAASS,WAAW,GAAG"}
@@ -4,4 +4,3 @@
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- //# sourceMappingURL=AgentTag.types.js.map
@@ -29,4 +29,3 @@ const _AgentTag = require("./AgentTag");
29
29
  const _renderAgentTag = require("./renderAgentTag");
30
30
  const _useAgentTag = require("./useAgentTag");
31
31
  const _useAgentTagStylesstyles = require("./useAgentTagStyles.styles");
32
- //# sourceMappingURL=index.js.map
@@ -11,4 +11,4 @@ Object.defineProperty(exports, "renderAgentTag_unstable", {
11
11
  const _Attachment = require("../Attachment");
12
12
  const renderAgentTag_unstable = (state)=>{
13
13
  return (0, _Attachment.renderAttachment_unstable)(state);
14
- }; //# sourceMappingURL=renderAgentTag.js.map
14
+ };
@@ -1 +1 @@
1
- {"version":3,"sources":["renderAgentTag.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { renderAttachment_unstable } from '../Attachment';\nimport type { AgentTagState } from './AgentTag.types';\n\n/**\n * Render the final JSX of AgentTag\n */\nexport const renderAgentTag_unstable = (state: AgentTagState) => {\n return renderAttachment_unstable(state);\n};\n"],"names":["renderAttachment_unstable","state"],"rangeMappings":";;;;;;;;;;;;","mappings":";;;;+BAUSA;;;eAAAA;;;4BATT;AASE,MAAOA,0BAA0BC,CAAAA;IACjC,OAAAD,IAAAA,qCAAA,EAAAC"}
1
+ {"version":3,"sources":["renderAgentTag.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { renderAttachment_unstable } from '../Attachment';\nimport type { AgentTagState } from './AgentTag.types';\n\n/**\n * Render the final JSX of AgentTag\n */\nexport const renderAgentTag_unstable = (state: AgentTagState) => {\n return renderAttachment_unstable(state);\n};\n"],"names":["renderAgentTag_unstable","state","renderAttachment_unstable"],"rangeMappings":";;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;AAQO,MAAMA,0BAA0B,CAACC;IACtC,OAAOC,IAAAA,qCAAAA,EAA0BD;AACnC"}
@@ -16,4 +16,4 @@ const useAgentTag_unstable = (props, ref)=>{
16
16
  designVersion: 'next'
17
17
  }, ref);
18
18
  return state;
19
- }; //# sourceMappingURL=useAgentTag.js.map
19
+ };
@@ -1 +1 @@
1
- {"version":3,"sources":["useAgentTag.ts"],"sourcesContent":["import type * as React from 'react';\nimport type { AgentTagProps, AgentTagState } from './AgentTag.types';\nimport { useAttachment_unstable } from '..';\n\n// If you add JSX to this file, be sure to change the file type to .tsx\n\n/**\n * Create the state required to render AgentTag.\n *\n * The returned state can be modified with hooks such as useAgentTagStyles_unstable,\n * before being passed to renderAgentTag_unstable.\n *\n * @param props - props from this instance of AgentTag\n * @param ref - reference to root HTMLElement of AgentTag\n */\nexport const useAgentTag_unstable = (props: AgentTagProps, ref: React.Ref<HTMLDivElement>): AgentTagState => {\n const state = useAttachment_unstable({ ...props, dismissOnly: true, designVersion: 'next' }, ref);\n\n return state;\n};\n"],"names":["state","useAttachment_unstable","ref","dismissOnly","designVersion"],"rangeMappings":";;;;;;;;;;;;;;;;;","mappings":";;;;+BAgBQA;;;eAAAA;;;kBAd+B;AAcrC,MAAMA,uBAAQC,CAAAA,OAAuBC;UAAEF,QAAQC,IAAAA,wBAAA,EAAA;gBAAEE;qBAAmBC;QAAsBA,eAAGF;OAE7FA;IACA,OAAAF"}
1
+ {"version":3,"sources":["useAgentTag.ts"],"sourcesContent":["import type * as React from 'react';\nimport type { AgentTagProps, AgentTagState } from './AgentTag.types';\nimport { useAttachment_unstable } from '..';\n\n// If you add JSX to this file, be sure to change the file type to .tsx\n\n/**\n * Create the state required to render AgentTag.\n *\n * The returned state can be modified with hooks such as useAgentTagStyles_unstable,\n * before being passed to renderAgentTag_unstable.\n *\n * @param props - props from this instance of AgentTag\n * @param ref - reference to root HTMLElement of AgentTag\n */\nexport const useAgentTag_unstable = (props: AgentTagProps, ref: React.Ref<HTMLDivElement>): AgentTagState => {\n const state = useAttachment_unstable({ ...props, dismissOnly: true, designVersion: 'next' }, ref);\n\n return state;\n};\n"],"names":["useAgentTag_unstable","props","ref","state","useAttachment_unstable","dismissOnly","designVersion"],"rangeMappings":";;;;;;;;;;;;;;;;;;","mappings":";;;;+BAeaA;;;eAAAA;;;kBAb0B;AAahC,MAAMA,uBAAuB,CAACC,OAAsBC;IACzD,MAAMC,QAAQC,IAAAA,wBAAAA,EAAuB;QAAE,GAAGH,KAAK;QAAEI,aAAa;QAAMC,eAAe;IAAO,GAAGJ;IAE7F,OAAOC;AACT"}
@@ -0,0 +1,82 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: all[name]
9
+ });
10
+ }
11
+ _export(exports, {
12
+ agentTagClassNames: function() {
13
+ return agentTagClassNames;
14
+ },
15
+ useAgentTagStyles_unstable: function() {
16
+ return useAgentTagStyles_unstable;
17
+ }
18
+ });
19
+ const _reactcomponents = require("@fluentui/react-components");
20
+ const _ = require("..");
21
+ const _tokens = require("@fluentui-copilot/tokens");
22
+ const agentTagClassNames = {
23
+ root: 'fai-AgentTag',
24
+ primaryAction: 'fai-AgentTag__primaryAction',
25
+ dismissIcon: 'fai-AgentTag__dismissIcon',
26
+ dismissButton: 'fai-AgentTag__dismissButton',
27
+ media: 'fai-AgentTag__media',
28
+ content: 'fai-AgentTag__content',
29
+ progress: 'fai-AgentTag__progress'
30
+ };
31
+ const useMediaStyles = (0, _reactcomponents.makeStyles)({
32
+ canvas: {
33
+ width: '24px',
34
+ height: '24px'
35
+ },
36
+ sidecar: {
37
+ width: '20px',
38
+ height: '20px'
39
+ }
40
+ });
41
+ const useContentStyles = (0, _reactcomponents.makeStyles)({
42
+ canvas: {
43
+ ..._tokens.typographyStyles.subtitle2,
44
+ color: _tokens.tokens.colorNeutralForeground2
45
+ },
46
+ sidecar: {
47
+ ..._tokens.typographyStyles.body1Strong,
48
+ color: _tokens.tokens.colorNeutralForeground2
49
+ }
50
+ });
51
+ const useDismissButtonStyles = (0, _reactcomponents.makeStyles)({
52
+ canvas: {
53
+ borderRadius: _tokens.tokens.borderRadius2XL,
54
+ paddingLeft: _tokens.tokens.spacingHorizontalL,
55
+ paddingRight: _tokens.tokens.spacingHorizontalM
56
+ },
57
+ sidecar: {
58
+ paddingLeft: _tokens.tokens.spacingHorizontalM,
59
+ paddingRight: _tokens.tokens.spacingHorizontalS,
60
+ borderRadius: _tokens.tokens.borderRadiusXLarge
61
+ }
62
+ });
63
+ const useAgentTagStyles_unstable = (state)=>{
64
+ 'use no memo';
65
+ const { mode } = state;
66
+ const contentStyles = useContentStyles();
67
+ const dismissButtonStyles = useDismissButtonStyles();
68
+ const mediaStyles = useMediaStyles();
69
+ state.root.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.root, state.root.className);
70
+ state.primaryAction.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.primaryAction, state.primaryAction.className);
71
+ state.dismissIcon.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.dismissIcon, state.dismissIcon.className);
72
+ state.dismissButton.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.dismissButton, dismissButtonStyles[mode], state.dismissButton.className);
73
+ if (state.media) {
74
+ state.media.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.media, mediaStyles[mode], state.media.className);
75
+ }
76
+ state.content.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.content, contentStyles[mode], state.content.className);
77
+ if (state.progress) {
78
+ state.progress.className = (0, _reactcomponents.mergeClasses)(agentTagClassNames.progress, state.progress.className);
79
+ }
80
+ (0, _.useAttachmentStyles_unstable)(state);
81
+ return state;
82
+ };
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["useAgentTagStyles.styles.ts"],"sourcesContent":["import { makeStyles, mergeClasses } from '@fluentui/react-components';\nimport type { AgentTagSlots, AgentTagState } from './AgentTag.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\nimport { useAttachmentStyles_unstable } from '..';\nimport { tokens, typographyStyles } from '@fluentui-copilot/tokens';\n\nexport const agentTagClassNames: SlotClassNames<AgentTagSlots> = {\n root: 'fai-AgentTag',\n primaryAction: 'fai-AgentTag__primaryAction',\n dismissIcon: 'fai-AgentTag__dismissIcon',\n dismissButton: 'fai-AgentTag__dismissButton',\n media: 'fai-AgentTag__media',\n content: 'fai-AgentTag__content',\n progress: 'fai-AgentTag__progress',\n};\n\nconst useMediaStyles = makeStyles({\n canvas: {\n width: '24px',\n height: '24px',\n },\n sidecar: { width: '20px', height: '20px' },\n});\n\nconst useContentStyles = makeStyles({\n canvas: {\n ...typographyStyles.subtitle2,\n color: tokens.colorNeutralForeground2,\n },\n sidecar: {\n ...typographyStyles.body1Strong,\n color: tokens.colorNeutralForeground2,\n },\n});\n\nconst useDismissButtonStyles = makeStyles({\n canvas: {\n borderRadius: tokens.borderRadius2XL,\n paddingLeft: tokens.spacingHorizontalL,\n paddingRight: tokens.spacingHorizontalM,\n },\n sidecar: {\n paddingLeft: tokens.spacingHorizontalM,\n paddingRight: tokens.spacingHorizontalS,\n borderRadius: tokens.borderRadiusXLarge,\n },\n});\n\n/**\n * Apply styling to the AgentTag slots based on the state\n */\nexport const useAgentTagStyles_unstable = (state: AgentTagState): AgentTagState => {\n 'use no memo';\n\n const { mode } = state;\n\n const contentStyles = useContentStyles();\n const dismissButtonStyles = useDismissButtonStyles();\n const mediaStyles = useMediaStyles();\n\n state.root.className = mergeClasses(agentTagClassNames.root, state.root.className);\n\n state.primaryAction.className = mergeClasses(agentTagClassNames.primaryAction, state.primaryAction.className);\n\n state.dismissIcon.className = mergeClasses(agentTagClassNames.dismissIcon, state.dismissIcon.className);\n\n state.dismissButton.className = mergeClasses(\n agentTagClassNames.dismissButton,\n dismissButtonStyles[mode],\n state.dismissButton.className,\n );\n\n if (state.media) {\n state.media.className = mergeClasses(agentTagClassNames.media, mediaStyles[mode], state.media.className);\n }\n\n state.content.className = mergeClasses(agentTagClassNames.content, contentStyles[mode], state.content.className);\n\n if (state.progress) {\n state.progress.className = mergeClasses(agentTagClassNames.progress, state.progress.className);\n }\n\n useAttachmentStyles_unstable(state);\n\n return state;\n};\n"],"names":["agentTagClassNames","useAgentTagStyles_unstable","root","primaryAction","dismissIcon","dismissButton","media","content","progress","useMediaStyles","makeStyles","canvas","width","height","sidecar","useContentStyles","typographyStyles","subtitle2","color","tokens","colorNeutralForeground2","body1Strong","useDismissButtonStyles","borderRadius","borderRadius2XL","paddingLeft","spacingHorizontalL","paddingRight","spacingHorizontalM","spacingHorizontalS","borderRadiusXLarge","state","mode","contentStyles","dismissButtonStyles","mediaStyles","className","mergeClasses","useAttachmentStyles_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAMaA,kBAAAA;eAAAA;;IA6CAC,0BAAAA;eAAAA;;;iCAnD4B;kBAGI;wBACJ;AAElC,MAAMD,qBAAoD;IAC/DE,MAAM;IACNC,eAAe;IACfC,aAAa;IACbC,eAAe;IACfC,OAAO;IACPC,SAAS;IACTC,UAAU;AACZ;AAEA,MAAMC,iBAAiBC,IAAAA,2BAAAA,EAAW;IAChCC,QAAQ;QACNC,OAAO;QACPC,QAAQ;IACV;IACAC,SAAS;QAAEF,OAAO;QAAQC,QA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MzB,KAAK,EAAE;QACfyB,MAAMzB,KAAK,CAAC8B,SAAS,GAAGC,IAAAA,6BAAAA,EAAarC,mBAAmBM,KAAK,EAAE6B,WAAW,CAACH,KAAK,EAAED,MAAMzB,KAAK,CAAC8B,SAAS;IACzG;IAEAL,MAAMxB,OAAO,CAAC6B,SAAS,GAAGC,IAAAA,6BAAAA,EAAarC,mBAAmBO,OAAO,EAAE0B,aAAa,CAACD,KAAK,EAAED,MAAMxB,OAAO,CAAC6B,SAAS;IAE/G,IAAIL,MAAMvB,QAAQ,EAAE;QAClBuB,MAAMvB,QAAQ,CAAC4B,SAAS,GAAGC,IAAAA,6BAAAA,EAAarC,mBAAmBQ,QAAQ,EAAEuB,MAAMvB,QAAQ,CAAC4B,SAAS;IAC/F;IAEAE,IAAAA,8BAAAA,EAA6BP;IAE7B,OAAOA;AACT"}
@@ -20,4 +20,4 @@ const Attachment = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
20
20
  (0, _reactprovider.useCustomStyleHook)('useAttachmentStyles')(state);
21
21
  return (0, _renderAttachment.renderAttachment_unstable)(state);
22
22
  });
23
- Attachment.displayName = 'Attachment'; //# sourceMappingURL=Attachment.js.map
23
+ Attachment.displayName = 'Attachment';
@@ -1 +1 @@
1
- {"version":3,"sources":["Attachment.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAttachment_unstable } from './useAttachment';\nimport { renderAttachment_unstable } from './renderAttachment';\nimport { useAttachmentStyles_unstable } from './useAttachmentStyles.styles';\nimport type { AttachmentProps } from './Attachment.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Attachment component - TODO: add more docs\nexport const Attachment: ForwardRefComponent<AttachmentProps> = React.forwardRef((props, ref) => {\n const state = useAttachment_unstable(props, ref);\n\n useAttachmentStyles_unstable(state);\n useCustomStyleHook('useAttachmentStyles')(state);\n\n return renderAttachment_unstable(state);\n});\n\nAttachment.displayName = 'Attachment';\n"],"names":["Attachment","React","forwardRef","props","state","useAttachment_unstable","useAttachmentStyles_unstable","useCustomStyleHook","renderAttachment_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;;iEATU;+BACgB;kCACG;2CACG;+BAGV;AAG5B,MAAMA,aAAAA,WAAAA,GAAAA,OAAmDC,UAAMC,CAAU,CAACC,OAACA;UAChFC,QAAMA,IAAAA,qCAAQC,EAAAA,OAAuBF;+DAErCG,EAAAA;yCACAC,EAAAA,uBAAmBH;WAEnBI,IAAAA,2CAAOA,EAAAA;AACT;AAEAR,WAAWS,WAAW,GAAG"}
1
+ {"version":3,"sources":["Attachment.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useAttachment_unstable } from './useAttachment';\nimport { renderAttachment_unstable } from './renderAttachment';\nimport { useAttachmentStyles_unstable } from './useAttachmentStyles.styles';\nimport type { AttachmentProps } from './Attachment.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Attachment component - TODO: add more docs\nexport const Attachment: ForwardRefComponent<AttachmentProps> = React.forwardRef((props, ref) => {\n const state = useAttachment_unstable(props, ref);\n\n useAttachmentStyles_unstable(state);\n useCustomStyleHook('useAttachmentStyles')(state);\n\n return renderAttachment_unstable(state);\n});\n\nAttachment.displayName = 'Attachment';\n"],"names":["Attachment","React","forwardRef","props","ref","state","useAttachment_unstable","useAttachmentStyles_unstable","useCustomStyleHook","renderAttachment_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;;iEATU;+BACgB;kCACG;2CACG;+BAGV;AAG5B,MAAMA,aAAAA,WAAAA,GAAmDC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IACvF,MAAMC,QAAQC,IAAAA,qCAAAA,EAAuBH,OAAOC;IAE5CG,IAAAA,uDAAAA,EAA6BF;IAC7BG,IAAAA,iCAAAA,EAAmB,uBAAuBH;IAE1C,OAAOI,IAAAA,2CAAAA,EAA0BJ;AACnC;AAEAL,WAAWU,WAAW,GAAG"}
@@ -4,4 +4,3 @@
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- //# sourceMappingURL=Attachment.types.js.map
@@ -32,4 +32,3 @@ const _Attachment = require("./Attachment");
32
32
  const _renderAttachment = require("./renderAttachment");
33
33
  const _useAttachment = require("./useAttachment");
34
34
  const _useAttachmentStylesstyles = require("./useAttachmentStyles.styles");
35
- //# sourceMappingURL=index.js.map
@@ -47,4 +47,4 @@ const renderDismissOnly = (state)=>{
47
47
  ]
48
48
  })
49
49
  });
50
- }; //# sourceMappingURL=renderAttachment.js.map
50
+ };
@@ -1 +1 @@
1
- {"version":3,"sources":["renderAttachment.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { AttachmentState, AttachmentSlots } from './Attachment.types';\n\n/**\n * Render the final JSX of Attachment\n */\nexport const renderAttachment_unstable = (state: AttachmentState) => {\n const { id, shouldUseOverflow, designVersion, dismissOnly } = state;\n\n const attachment = designVersion === 'next' && dismissOnly ? renderDismissOnly(state) : renderAttachment(state);\n\n return shouldUseOverflow ? (\n <OverflowItem id={id} key={id}>\n {attachment}\n </OverflowItem>\n ) : (\n attachment\n );\n};\n\nconst renderAttachment = (state: AttachmentState) => {\n assertSlots<AttachmentSlots>(state);\n\n return (\n <state.root>\n <state.primaryAction>\n {state.media && !state.imageOnly && <state.media />}\n <state.content />\n {state.progress && <state.progress />}\n </state.primaryAction>\n <state.dismissButton>\n <state.dismissIcon />\n </state.dismissButton>\n </state.root>\n );\n};\n\nconst renderDismissOnly = (state: AttachmentState) => {\n assertSlots<AttachmentSlots>(state);\n\n return (\n <state.root>\n <state.dismissButton>\n {state.media && !state.imageOnly && <state.media />}\n <state.content />\n {state.progress && <state.progress />}\n <state.dismissIcon />\n </state.dismissButton>\n </state.root>\n );\n};\n"],"names":["id","designVersion","attachment","state","renderAttachment","assertSlots","progress","root","dismissButton","_jsx","dismissIcon","renderDismissOnly","children","_jsxs","media","content"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAUUA;;;eAAAA;;;4BATV;iCAE0C;AAOxC,MAAQA,4BAAuBC,CAAAA;UAE/B,EAEAD,EAAA,mBACoBA,4BAIlBE,EAEF,GAAAC;IAEF,MAAMC,aAAAA,kBAAoBD,UAAAA,cAAAA,kBAAAA,SAAAA,iBAAAA;WACxBE,oBAA6BF,WAAAA,GAAAA,IAAAA,eAAAA,EAAAA,6BAAAA,EAAAA;QAE7BH,IAAAA;;;;yBAGOG,CAAAA;;sBAEAA,GAAAA,IAAAA,gBAAMG,EAAAA,MAAQC,IAAA,EAAA;;;;;;;;;+CAEjBJ,MAACA,aAAMK,EAAAA;qCACL,GAAAC,IAAAA,eAAA,EAAAN,MAAAO,WAAOA,EAAAA,CAAAA;;;;;AAIf,MAAAC,oBAAAR,CAAAA;IAEAE,IAAAA,4BAAMM,EAAAA;WACJN,WAA6BF,GAAAA,IAAAA,eAAAA,EAAAA,MAAAA,IAAAA,EAAAA;QAE7BS,UAAA,WACE,GAAAC,IAAAA,gBAACV,EAAAA,MAAMI,aAAI,EAAA;;sBACTO,KAAA,IAAA,CAAAX,MAACA,SAAMK,IAAAA,WAAa,GAAAC,IAAAA,eAAA,EAAAN,MAAAW,KAAA,EAAA,CAAA;gBAAA,WAAA,GAAAL,IAAAA,eAAA,EAAAN,MAAAY,OAAA,EAAA,CAAA;gBAAAZ,MAAAG,QAAA,IAAA,WAAA,GAAAG,IAAAA,eAAA,EAAAN,MAAAG,QAAA,EAAA,CAAA;gBAAA,WAAA,GAAAG,IAAAA,eAAA,EAAAN,MAAAO,WAAA,EAAA,CAAA;aAAA;;;+CAGH"}
1
+ {"version":3,"sources":["renderAttachment.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { AttachmentState, AttachmentSlots } from './Attachment.types';\n\n/**\n * Render the final JSX of Attachment\n */\nexport const renderAttachment_unstable = (state: AttachmentState) => {\n const { id, shouldUseOverflow, designVersion, dismissOnly } = state;\n\n const attachment = designVersion === 'next' && dismissOnly ? renderDismissOnly(state) : renderAttachment(state);\n\n return shouldUseOverflow ? (\n <OverflowItem id={id} key={id}>\n {attachment}\n </OverflowItem>\n ) : (\n attachment\n );\n};\n\nconst renderAttachment = (state: AttachmentState) => {\n assertSlots<AttachmentSlots>(state);\n\n return (\n <state.root>\n <state.primaryAction>\n {state.media && !state.imageOnly && <state.media />}\n <state.content />\n {state.progress && <state.progress />}\n </state.primaryAction>\n <state.dismissButton>\n <state.dismissIcon />\n </state.dismissButton>\n </state.root>\n );\n};\n\nconst renderDismissOnly = (state: AttachmentState) => {\n assertSlots<AttachmentSlots>(state);\n\n return (\n <state.root>\n <state.dismissButton>\n {state.media && !state.imageOnly && <state.media />}\n <state.content />\n {state.progress && <state.progress />}\n <state.dismissIcon />\n </state.dismissButton>\n </state.root>\n );\n};\n"],"names":["renderAttachment_unstable","state","id","shouldUseOverflow","designVersion","dismissOnly","attachment","renderDismissOnly","renderAttachment","_jsx","OverflowItem","assertSlots","_jsxs","root","primaryAction","media","imageOnly","content","progress","dismissButton","dismissIcon"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;iCAE0C;AAMnC,MAAMA,4BAA4B,CAACC;IACxC,MAAM,EAAEC,EAAE,EAAEC,iBAAiB,EAAEC,aAAa,EAAEC,WAAW,EAAE,GAAGJ;IAE9D,MAAMK,aAAaF,kBAAkB,UAAUC,cAAcE,kBAAkBN,SAASO,iBAAiBP;IAEzG,OAAOE,oB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
101
101
  }
102
102
  return state;
103
- }; //# sourceMappingURL=useAttachment.js.map
103
+ };
@@ -1 +1 @@
1
- {"version":3,"sources":["useAttachment.tsx"],"sourcesContent":["import * as React from 'react';\nimport { ProgressBar, getIntrinsicElementProps, mergeCallbacks, slot, useId } from '@fluentui/react-components';\nimport { Dismiss12Regular, Dismiss20Regular } from '@fluentui/react-icons';\nimport { useAttachmentListContext_unstable } from '../../contexts/attachmentListContext';\nimport type { AttachmentProps, AttachmentState } from './Attachment.types';\nimport { useCopilotMode, useDesignVersion } from '@fluentui-copilot/react-provider';\n\n/**\n * Create the state required to render Attachment.\n *\n * The returned state can be modified with hooks such as useAttachmentStyles_unstable,\n * before being passed to renderAttachment_unstable.\n *\n * @param props - props from this instance of Attachment\n * @param ref - reference to root HTMLElement of Attachment\n */\nexport const useAttachment_unstable = (props: AttachmentProps, ref: React.Ref<HTMLDivElement>): AttachmentState => {\n const { children, imageOnly, size = 'medium', dismissOnly = false } = props;\n const { onAttachmentDismiss, shouldUseOverflow } = useAttachmentListContext_unstable(context => context);\n const attachmentId = useId('attachment-', props.id);\n const isLoading = !!props.progress;\n\n const mode = useCopilotMode(props.mode);\n const designVersion = useDesignVersion(props.designVersion);\n\n const root = slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n id: attachmentId,\n }),\n { elementType: 'div' },\n );\n\n const primaryAction = slot.always(props.primaryAction, {\n defaultProps: { as: dismissOnly ? 'span' : undefined },\n elementType: 'button',\n });\n\n const dismissButton = slot.always(props.dismissButton, {\n defaultProps: { 'aria-label': 'Remove attachment' },\n elementType: 'button',\n });\n\n dismissButton.onClick = mergeCallbacks(\n dismissButton.onClick as React.MouseEventHandler<HTMLAnchorElement | HTMLButtonElement>,\n (ev: React.MouseEvent<HTMLAnchorElement | HTMLButtonElement>) => {\n onAttachmentDismiss?.(ev, { content: children, media, id: attachmentId });\n },\n );\n\n const media = slot.optional(props.media, { elementType: 'span' });\n\n const content = slot.always(props.content, {\n defaultProps: {\n children: props.children,\n },\n elementType: 'span',\n });\n\n const dismissIcon = slot.always(props.dismissIcon, {\n defaultProps: {\n children: size === 'small' ? <Dismiss12Regular /> : <Dismiss20Regular />,\n },\n elementType: 'span',\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 const state: AttachmentState = {\n id: attachmentId,\n size,\n components: {\n root: 'div',\n primaryAction: 'button',\n dismissButton: 'button',\n media: 'span',\n content: 'span',\n dismissIcon: 'span',\n progress: ProgressBar,\n },\n\n root,\n primaryAction,\n dismissButton,\n media,\n content,\n dismissIcon,\n progress,\n imageOnly,\n isLoading,\n shouldUseOverflow,\n mode,\n designVersion,\n dismissOnly,\n };\n\n if (state.primaryAction.as === 'span') {\n state.components.primaryAction = 'span';\n }\n\n return state;\n};\n"],"names":["children","size","ref","attachmentId","imageOnly","isLoading","mode","useCopilotMode","dismissOnly","designVersion","props","useAttachmentListContext_unstable","context","elementType","useId","id","progress","primaryAction","slot","always","defaultProps","useDesignVersion","as","undefined","dismissButton","onAttachmentDismiss","media","onClick","mergeCallbacks","ev","dismissIcon","content","thickness","React","createElement","Dismiss12Regular","Dismiss20Regular","components","root","shouldUseOverflow"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAiBUA;;;eAAAA;;;;iEAjBa;iCAC4D;4BAChC;uCACD;+BAED;AAY/C,MAAQA,yBAAqBC,CAAAA,OAAOC;UACpC,EACAF,QAAMG,EACNC,SAAMC,EAENJ,OAAMK,QAAOC,EACbC,cAAMC,KAAAA,KAENC;UAEIR,qBACQ,mBACJC,KACNQ,IAAAA,wDACA,EAAAC,CAAAA,UAAAA;UAAEC,eAAaC,IAAAA,sBAAA,EAAA,eAAAJ,MAAAK,EAAA;UAAMV,YAAA,C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;QAMF2B;QAEAD;;QAEA1B;QAEAC;QACAkC"}
1
+ {"version":3,"sources":["useAttachment.tsx"],"sourcesContent":["import * as React from 'react';\nimport { ProgressBar, getIntrinsicElementProps, mergeCallbacks, slot, useId } from '@fluentui/react-components';\nimport { Dismiss12Regular, Dismiss20Regular } from '@fluentui/react-icons';\nimport { useAttachmentListContext_unstable } from '../../contexts/attachmentListContext';\nimport type { AttachmentProps, AttachmentState } from './Attachment.types';\nimport { useCopilotMode, useDesignVersion } from '@fluentui-copilot/react-provider';\n\n/**\n * Create the state required to render Attachment.\n *\n * The returned state can be modified with hooks such as useAttachmentStyles_unstable,\n * before being passed to renderAttachment_unstable.\n *\n * @param props - props from this instance of Attachment\n * @param ref - reference to root HTMLElement of Attachment\n */\nexport const useAttachment_unstable = (props: AttachmentProps, ref: React.Ref<HTMLDivElement>): AttachmentState => {\n const { children, imageOnly, size = 'medium', dismissOnly = false } = props;\n const { onAttachmentDismiss, shouldUseOverflow } = useAttachmentListContext_unstable(context => context);\n const attachmentId = useId('attachment-', props.id);\n const isLoading = !!props.progress;\n\n const mode = useCopilotMode(props.mode);\n const designVersion = useDesignVersion(props.designVersion);\n\n const root = slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n id: attachmentId,\n }),\n { elementType: 'div' },\n );\n\n const primaryAction = slot.always(props.primaryAction, {\n defaultProps: { as: dismissOnly ? 'span' : undefined },\n elementType: 'button',\n });\n\n const dismissButton = slot.always(props.dismissButton, {\n defaultProps: { 'aria-label': 'Remove attachment' },\n elementType: 'button',\n });\n\n dismissButton.onClick = mergeCallbacks(\n dismissButton.onClick as React.MouseEventHandler<HTMLAnchorElement | HTMLButtonElement>,\n (ev: React.MouseEvent<HTMLAnchorElement | HTMLButtonElement>) => {\n onAttachmentDismiss?.(ev, { content: children, media, id: attachmentId });\n },\n );\n\n const media = slot.optional(props.media, { elementType: 'span' });\n\n const content = slot.always(props.content, {\n defaultProps: {\n children: props.children,\n },\n elementType: 'span',\n });\n\n const dismissIcon = slot.always(props.dismissIcon, {\n defaultProps: {\n children: size === 'small' ? <Dismiss12Regular /> : <Dismiss20Regular />,\n },\n elementType: 'span',\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 const state: AttachmentState = {\n id: attachmentId,\n size,\n components: {\n root: 'div',\n primaryAction: 'button',\n dismissButton: 'button',\n media: 'span',\n content: 'span',\n dismissIcon: 'span',\n progress: ProgressBar,\n },\n\n root,\n primaryAction,\n dismissButton,\n media,\n content,\n dismissIcon,\n progress,\n imageOnly,\n isLoading,\n shouldUseOverflow,\n mode,\n designVersion,\n dismissOnly,\n };\n\n if (state.primaryAction.as === 'span') {\n state.components.primaryAction = 'span';\n }\n\n return state;\n};\n"],"names":["useAttachment_unstable","props","ref","children","imageOnly","size","dismissOnly","onAttachmentDismiss","shouldUseOverflow","useAttachmentListContext_unstable","context","attachmentId","useId","id","isLoading","progress","mode","useCopilotMode","designVersion","useDesignVersion","root","slot","always","getIntrinsicElementProps","elementType","primaryAction","defaultProps","as","undefined","dismissButton","onClick","mergeCallbacks","ev","content","media","optional","dismissIcon","React","createElement","Dismiss12Regular","Dismiss20Regular","shape","thickness","ProgressBar","state","components"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAgBaA;;;eAAAA;;;;iEAhBU;iCAC4D;4BAChC;uCACD;+BAED;AAW1C,MAAMA,yBAAyB,CAACC,OAAwBC;IAC7D,MAAM,EAAEC,QAAQ,EAAEC,SAAS,EAAEC,OAAO,QAAQ,EAAEC,cAAc,KAAK,EAAE,GAAGL;IACtE,MAAM,EAAEM,mBAAmB,EAAEC,iBAAiB,EAAE,GAAGC,IAAAA,wDAAAA,EAAkCC,CAAAA,UAAWA;I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AAA,WAAAA,GAAsBF,OAAAC,aAAA,CAACE,4BAAAA,EAAAA;QACvD;QACAhB,aAAa;IACf;IAEA,MAAMT,WAAWM,qBAAAA,CAAKc,QAAQ,CAAClC,MAAMc,QAAQ,EAAE;QAC7CW,cAAc;YACZe,OAAO;YACPC,WAAW;YACX,mBAAmBzC,MAAMY,EAAE;QAC7B;QACAW,aAAamB,4BAAAA;IACf;IAEA,MAAMC,QAAyB;QAC7B/B,IAAIF;QACJN;QACAwC,YAAY;YACVzB,MAAM;YACNK,eAAe;YACfI,eAAe;YACfK,OAAO;YACPD,SAAS;YACTG,aAAa;YACbrB,UAAU4B,4BAAAA;QACZ;QAEAvB;QACAK;QACAI;QACAK;QACAD;QACAG;QACArB;QACAX;QACAU;QACAN;QACAQ;QACAE;QACAZ;IACF;IAEA,IAAIsC,MAAMnB,aAAa,CAACE,EAAE,KAAK,QAAQ;QACrCiB,MAAMC,UAAU,CAACpB,aAAa,GAAG;IACnC;IAEA,OAAOmB;AACT"}
@@ -51,15 +51,16 @@ const buttonBaseStyles = {
51
51
  justifyContent: 'center',
52
52
  ...(0, _reactcomponents.createCustomFocusIndicatorStyle)({
53
53
  outline: `${_tokens.tokens.strokeWidthThick} solid ${_tokens.tokens.colorStrokeFocus2}`,
54
+ outlineOffset: `calc(${_tokens.tokens.strokeWidthThick} * -1)`,
54
55
  zIndex: 1
55
56
  }),
56
57
  verticalAlign: 'middle'
57
58
  };
58
- const usePrimaryActionBaseClassName = (0, _reactcomponents.__resetStyles)("rjo71rc", "rsix9pn", [
59
- ".rjo71rc{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;border-top-right-radius:var(--borderRadiusNone);border-bottom-right-radius:var(--borderRadiusNone);border-right-style:none;max-width:calc(180px - 20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS) - var(--spacingHorizontalXS));padding:var(--spacingVerticalXS) var(--spacingHorizontalS) var(--spacingVerticalXS) var(--spacingHorizontalS);}",
60
- ".rjo71rc[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);z-index:1;}",
61
- ".rsix9pn{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;border-top-left-radius:var(--borderRadiusNone);border-bottom-left-radius:var(--borderRadiusNone);border-left-style:none;max-width:calc(180px - 20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS) - var(--spacingHorizontalXS));padding:var(--spacingVerticalXS) var(--spacingHorizontalS) var(--spacingVerticalXS) var(--spacingHorizontalS);}",
62
- ".rsix9pn[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);z-index:1;}"
59
+ const usePrimaryActionBaseClassName = (0, _reactcomponents.__resetStyles)("r1cypics", "r1zmptn", [
60
+ ".r1cypics{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;border-top-right-radius:var(--borderRadiusNone);border-bottom-right-radius:var(--borderRadiusNone);border-right-style:none;max-width:calc(180px - 20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS) - var(--spacingHorizontalXS));padding:var(--spacingVerticalXS) var(--spacingHorizontalS) var(--spacingVerticalXS) var(--spacingHorizontalS);}",
61
+ ".r1cypics[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);outline-offset:calc(var(--strokeWidthThick) * -1);z-index:1;}",
62
+ ".r1zmptn{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;border-top-left-radius:var(--borderRadiusNone);border-bottom-left-radius:var(--borderRadiusNone);border-left-style:none;max-width:calc(180px - 20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS) - var(--spacingHorizontalXS));padding:var(--spacingVerticalXS) var(--spacingHorizontalS) var(--spacingVerticalXS) var(--spacingHorizontalS);}",
63
+ ".r1zmptn[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);outline-offset:calc(var(--strokeWidthThick) * -1);z-index:1;}"
63
64
  ]);
64
65
  const usePrimaryActionStyles = (0, _reactcomponents.__styles)({
65
66
  button: {
@@ -96,20 +97,20 @@ const usePrimaryActionStyles = (0, _reactcomponents.__styles)({
96
97
  ]
97
98
  ]
98
99
  });
99
- const useDismissButtonBaseClassName = (0, _reactcomponents.__resetStyles)("r1v8xxbh", "ruebrp4", {
100
+ const useDismissButtonBaseClassName = (0, _reactcomponents.__resetStyles)("r10lynrk", "r2f20ug", {
100
101
  r: [
101
- ".r1v8xxbh{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;padding:var(--spacingVerticalXS) var(--spacingHorizontalXS) var(--spacingVerticalXS) var(--spacingHorizontalXS);max-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);min-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);border-left-color:var(--colorNeutralStroke1);border-top-left-radius:var(--borderRadiusNone);border-bottom-left-radius:var(--borderRadiusNone);border-top-right-radius:var(--borderRadiusMedium);border-bottom-right-radius:var(--borderRadiusMedium);}",
102
- ".r1v8xxbh[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);z-index:1;}",
103
- ".r1v8xxbh:hover{cursor:pointer;background-color:var(--colorSubtleBackgroundHover);color:var(--colorNeutralForeground2BrandHover);}",
104
- ".r1v8xxbh:active{background-color:var(--colorSubtleBackgroundPressed);color:var(--colorNeutralForeground2BrandPressed);}",
105
- ".ruebrp4{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;padding:var(--spacingVerticalXS) var(--spacingHorizontalXS) var(--spacingVerticalXS) var(--spacingHorizontalXS);max-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);min-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);border-right-color:var(--colorNeutralStroke1);border-top-right-radius:var(--borderRadiusNone);border-bottom-right-radius:var(--borderRadiusNone);border-top-left-radius:var(--borderRadiusMedium);border-bottom-left-radius:var(--borderRadiusMedium);}",
106
- ".ruebrp4[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);z-index:1;}",
107
- ".ruebrp4:hover{cursor:pointer;background-color:var(--colorSubtleBackgroundHover);color:var(--colorNeutralForeground2BrandHover);}",
108
- ".ruebrp4:active{background-color:var(--colorSubtleBackgroundPressed);color:var(--colorNeutralForeground2BrandPressed);}"
102
+ ".r10lynrk{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;padding:var(--spacingVerticalXS) var(--spacingHorizontalXS) var(--spacingVerticalXS) var(--spacingHorizontalXS);max-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);min-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);border-left-color:var(--colorNeutralStroke1);border-top-left-radius:var(--borderRadiusNone);border-bottom-left-radius:var(--borderRadiusNone);border-top-right-radius:var(--borderRadiusMedium);border-bottom-right-radius:var(--borderRadiusMedium);}",
103
+ ".r10lynrk[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);outline-offset:calc(var(--strokeWidthThick) * -1);z-index:1;}",
104
+ ".r10lynrk:hover{cursor:pointer;background-color:var(--colorSubtleBackgroundHover);color:var(--colorNeutralForeground2BrandHover);}",
105
+ ".r10lynrk:active{background-color:var(--colorSubtleBackgroundPressed);color:var(--colorNeutralForeground2BrandPressed);}",
106
+ ".r2f20ug{align-items:center;background-color:var(--colorSubtleBackground);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);border-radius:var(--borderRadiusMedium);box-sizing:border-box;column-gap:var(--spacingHorizontalSNudge);color:var(--colorNeutralForeground1);cursor:pointer;display:inline-flex;flex-wrap:nowrap;justify-content:center;vertical-align:middle;padding:var(--spacingVerticalXS) var(--spacingHorizontalXS) var(--spacingVerticalXS) var(--spacingHorizontalXS);max-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);min-width:calc(20px + var(--strokeWidthThin) * 2 + var(--spacingHorizontalXXS))+var(--spacingHorizontalXS);border-right-color:var(--colorNeutralStroke1);border-top-right-radius:var(--borderRadiusNone);border-bottom-right-radius:var(--borderRadiusNone);border-top-left-radius:var(--borderRadiusMedium);border-bottom-left-radius:var(--borderRadiusMedium);}",
107
+ ".r2f20ug[data-fui-focus-visible]{outline:var(--strokeWidthThick) solid var(--colorStrokeFocus2);outline-offset:calc(var(--strokeWidthThick) * -1);z-index:1;}",
108
+ ".r2f20ug:hover{cursor:pointer;background-color:var(--colorSubtleBackgroundHover);color:var(--colorNeutralForeground2BrandHover);}",
109
+ ".r2f20ug:active{background-color:var(--colorSubtleBackgroundPressed);color:var(--colorNeutralForeground2BrandPressed);}"
109
110
  ],
110
111
  s: [
111
- "@media (forced-colors: active){.r1v8xxbh:hover{background-color:HighlightText;}.r1v8xxbh:active{background-color:HighlightText;}}",
112
- "@media (forced-colors: active){.ruebrp4:hover{background-color:HighlightText;}.ruebrp4:active{background-color:HighlightText;}}"
112
+ "@media (forced-colors: active){.r10lynrk:hover{background-color:HighlightText;}.r10lynrk:active{background-color:HighlightText;}}",
113
+ "@media (forced-colors: active){.r2f20ug:hover{background-color:HighlightText;}.r2f20ug:active{background-color:HighlightText;}}"
113
114
  ]
114
115
  });
115
116
  const useDismissButtonCurrentStyles = (0, _reactcomponents.__styles)({
@@ -422,14 +423,11 @@ const usePrimaryDismissNextStyles = (0, _reactcomponents.__styles)({
422
423
  icvyot: 0,
423
424
  B4j52fo: 0,
424
425
  irswps: "f3bhgqh",
425
- De3pzq: "f16xq7d1",
426
+ De3pzq: "f16xq7d1"
427
+ },
428
+ sharedInteractiveStyles: {
426
429
  Jwef8y: "f1h648pw",
427
- ecr2s2: "fwdzr64",
428
- Bpw7sjs: 0,
429
- zppij7: 0,
430
- ajd3u1: 0,
431
- iqhfy: 0,
432
- B7b6voy: "f1c9fnza"
430
+ ecr2s2: "fwdzr64"
433
431
  }
434
432
  }, {
435
433
  d: [
@@ -446,14 +444,6 @@ const usePrimaryDismissNextStyles = (0, _reactcomponents.__styles)({
446
444
  ],
447
445
  a: [
448
446
  ".fwdzr64:active{background-color:var(--colorNeutralBackground3Pressed);}"
449
- ],
450
- i: [
451
- [
452
- ".f1c9fnza:focus-visible{border-radius:var(--borderRadiusLarge);}",
453
- {
454
- p: -1
455
- }
456
- ]
457
447
  ]
458
448
  });
459
449
  const useRootNextStyles = (0, _reactcomponents.__styles)({
@@ -484,6 +474,35 @@ const useRootNextStyles = (0, _reactcomponents.__styles)({
484
474
  ]
485
475
  ]
486
476
  });
477
+ const useFocusStyles = (0, _reactcomponents.__styles)({
478
+ primaryActionButton: {
479
+ B6xbmo0: [
480
+ "f146y5a9",
481
+ "f1k2ftg"
482
+ ],
483
+ kdpuga: [
484
+ "f1ndz5i7",
485
+ "f1co4qro"
486
+ ]
487
+ },
488
+ dismissButton: {
489
+ dm238s: [
490
+ "f1k2ftg",
491
+ "f146y5a9"
492
+ ],
493
+ Bw81rd7: [
494
+ "f1co4qro",
495
+ "f1ndz5i7"
496
+ ]
497
+ }
498
+ }, {
499
+ d: [
500
+ ".f146y5a9[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusNone);}",
501
+ ".f1k2ftg[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusNone);}",
502
+ ".f1ndz5i7[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusNone);}",
503
+ ".f1co4qro[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusNone);}"
504
+ ]
505
+ });
487
506
  const useAttachmentStyles_unstable = (state)=>{
488
507
  'use no memo';
489
508
  const rootBaseClassName = useRootBaseClassName();
@@ -502,10 +521,11 @@ const useAttachmentStyles_unstable = (state)=>{
502
521
  const dismissButtonNextStyles = useDismissButtonNextStyles();
503
522
  const primaryDismissNextStyles = usePrimaryDismissNextStyles();
504
523
  const rootNextStyles = useRootNextStyles();
524
+ const focusStyles = useFocusStyles();
505
525
  const { imageOnly, primaryAction, size, mode, designVersion, dismissOnly } = state;
506
526
  state.root.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.root, rootBaseClassName, designVersion === 'next' && rootNextStyles.root, state.root.className);
507
- state.primaryAction.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.primaryAction, primaryActionBaseClassName, size === 'small' && smallStyles.primaryAction, primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button, imageOnly && imageOnlyStyles.primaryAction, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryActionNextStyles.root, designVersion === 'next' && primaryActionNextStyles[mode], state.primaryAction.className);
508
- state.dismissButton.className = (0, _reactcomponents.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);
527
+ state.primaryAction.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.primaryAction, primaryActionBaseClassName, size === 'small' && smallStyles.primaryAction, primaryAction.as !== 'span' && !state.isLoading && primaryActionStyles.button, imageOnly && imageOnlyStyles.primaryAction, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryAction.as !== 'span' && !state.isLoading && primaryDismissNextStyles.sharedInteractiveStyles, designVersion === 'next' && primaryActionNextStyles.root, designVersion === 'next' && primaryActionNextStyles[mode], focusStyles.primaryActionButton, state.primaryAction.className);
528
+ state.dismissButton.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.dismissButton, dismissButtonBaseClassName, designVersion === 'current' && dismissButtonCurrentStyles.root, size === 'small' && smallStyles.dismissButton, designVersion === 'next' && primaryDismissNextStyles.sharedStyles, designVersion === 'next' && primaryDismissNextStyles.sharedInteractiveStyles, designVersion === 'next' && dismissButtonNextStyles.root, designVersion === 'next' && dismissButtonNextStyles[mode], designVersion === 'next' && dismissOnly && dismissButtonNextStyles.dismissOnly, designVersion === 'next' && !dismissOnly && dismissButtonNextStyles.withPrimary, focusStyles.dismissButton, state.dismissButton.className);
509
529
  if (state.media) {
510
530
  state.media.className = (0, _reactcomponents.mergeClasses)(attachmentClassNames.media, mediaBaseClassName, size === 'small' && smallStyles.media, state.media.className);
511
531
  }