@fluentui-copilot/react-reference 0.10.0 → 0.11.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (197) hide show
  1. package/CHANGELOG.json +37 -1
  2. package/CHANGELOG.md +21 -2
  3. package/dist/index.d.ts +222 -3
  4. package/lib/Citation.js.map +1 -1
  5. package/lib/Reference.js.map +1 -1
  6. package/lib/ReferenceGroupToggle.js.map +1 -1
  7. package/lib/ReferenceList.js.map +1 -1
  8. package/lib/ReferenceListV2.js +2 -0
  9. package/lib/ReferenceListV2.js.map +1 -0
  10. package/lib/ReferenceOverflowButton.js +2 -0
  11. package/lib/ReferenceOverflowButton.js.map +1 -0
  12. package/lib/ReferenceV2.js +2 -0
  13. package/lib/ReferenceV2.js.map +1 -0
  14. package/lib/components/Citation/Citation.js.map +1 -1
  15. package/lib/components/Citation/Citation.types.js +3 -1
  16. package/lib/components/Citation/Citation.types.js.map +1 -1
  17. package/lib/components/Citation/index.js.map +1 -1
  18. package/lib/components/Citation/renderCitation.js.map +1 -1
  19. package/lib/components/Citation/useCitation.js +4 -4
  20. package/lib/components/Citation/useCitation.js.map +1 -1
  21. package/lib/components/Citation/useCitationStyles.js.map +1 -1
  22. package/lib/components/Reference/Reference.js.map +1 -1
  23. package/lib/components/Reference/Reference.types.js +3 -1
  24. package/lib/components/Reference/Reference.types.js.map +1 -1
  25. package/lib/components/Reference/index.js.map +1 -1
  26. package/lib/components/Reference/renderReference.js.map +1 -1
  27. package/lib/components/Reference/useReference.js +3 -3
  28. package/lib/components/Reference/useReference.js.map +1 -1
  29. package/lib/components/Reference/useReferenceStyles.js.map +1 -1
  30. package/lib/components/ReferenceGroupToggle/ReferenceGroupToggle.js.map +1 -1
  31. package/lib/components/ReferenceGroupToggle/ReferenceGroupToggle.types.js +3 -1
  32. package/lib/components/ReferenceGroupToggle/ReferenceGroupToggle.types.js.map +1 -1
  33. package/lib/components/ReferenceGroupToggle/index.js.map +1 -1
  34. package/lib/components/ReferenceGroupToggle/renderReferenceGroupToggle.js.map +1 -1
  35. package/lib/components/ReferenceGroupToggle/useReferenceGroupToggle.js.map +1 -1
  36. package/lib/components/ReferenceGroupToggle/useReferenceGroupToggleStyles.js.map +1 -1
  37. package/lib/components/ReferenceList/ReferenceList.js.map +1 -1
  38. package/lib/components/ReferenceList/ReferenceList.types.js +3 -1
  39. package/lib/components/ReferenceList/ReferenceList.types.js.map +1 -1
  40. package/lib/components/ReferenceList/index.js.map +1 -1
  41. package/lib/components/ReferenceList/renderReferenceList.js.map +1 -1
  42. package/lib/components/ReferenceList/useReferenceList.js +2 -2
  43. package/lib/components/ReferenceList/useReferenceList.js.map +1 -1
  44. package/lib/components/ReferenceList/useReferenceListStyles.js.map +1 -1
  45. package/lib/components/reference-v2/Reference/Reference.js +11 -0
  46. package/lib/components/reference-v2/Reference/Reference.js.map +1 -0
  47. package/lib/components/reference-v2/Reference/Reference.types.js +2 -0
  48. package/lib/components/reference-v2/Reference/Reference.types.js.map +1 -0
  49. package/lib/components/reference-v2/Reference/index.js +6 -0
  50. package/lib/components/reference-v2/Reference/index.js.map +1 -0
  51. package/lib/components/reference-v2/Reference/renderReference.js +19 -0
  52. package/lib/components/reference-v2/Reference/renderReference.js.map +1 -0
  53. package/lib/components/reference-v2/Reference/useReference.js +72 -0
  54. package/lib/components/reference-v2/Reference/useReference.js.map +1 -0
  55. package/lib/components/reference-v2/Reference/useReferenceStyles.js +71 -0
  56. package/lib/components/reference-v2/Reference/useReferenceStyles.js.map +1 -0
  57. package/lib/components/reference-v2/ReferenceList/ReferenceList.js +13 -0
  58. package/lib/components/reference-v2/ReferenceList/ReferenceList.js.map +1 -0
  59. package/lib/components/reference-v2/ReferenceList/ReferenceList.types.js +2 -0
  60. package/lib/components/reference-v2/ReferenceList/ReferenceList.types.js.map +1 -0
  61. package/lib/components/reference-v2/ReferenceList/index.js +6 -0
  62. package/lib/components/reference-v2/ReferenceList/index.js.map +1 -0
  63. package/lib/components/reference-v2/ReferenceList/renderReferenceList.js +18 -0
  64. package/lib/components/reference-v2/ReferenceList/renderReferenceList.js.map +1 -0
  65. package/lib/components/reference-v2/ReferenceList/useReferenceList.js +94 -0
  66. package/lib/components/reference-v2/ReferenceList/useReferenceList.js.map +1 -0
  67. package/lib/components/reference-v2/ReferenceList/useReferenceListContextValues.js +21 -0
  68. package/lib/components/reference-v2/ReferenceList/useReferenceListContextValues.js.map +1 -0
  69. package/lib/components/reference-v2/ReferenceList/useReferenceListStyles.js +39 -0
  70. package/lib/components/reference-v2/ReferenceList/useReferenceListStyles.js.map +1 -0
  71. package/lib/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.js +12 -0
  72. package/lib/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.js.map +1 -0
  73. package/lib/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.types.js +4 -0
  74. package/lib/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.types.js.map +1 -0
  75. package/lib/components/reference-v2/ReferenceOverflowButton/index.js +6 -0
  76. package/lib/components/reference-v2/ReferenceOverflowButton/index.js.map +1 -0
  77. package/lib/components/reference-v2/ReferenceOverflowButton/renderReferenceOverflowButton.js +10 -0
  78. package/lib/components/reference-v2/ReferenceOverflowButton/renderReferenceOverflowButton.js.map +1 -0
  79. package/lib/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButton.js +91 -0
  80. package/lib/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButton.js.map +1 -0
  81. package/lib/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButtonStyles.js +35 -0
  82. package/lib/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButtonStyles.js.map +1 -0
  83. package/lib/components/reference-v2/index.js +4 -0
  84. package/lib/components/reference-v2/index.js.map +1 -0
  85. package/lib/{context → contexts}/ReferenceGroupContext.js.map +1 -1
  86. package/lib/contexts/reference-v2/index.js +2 -0
  87. package/lib/contexts/reference-v2/index.js.map +1 -0
  88. package/lib/contexts/reference-v2/referenceListContext.js +16 -0
  89. package/lib/contexts/reference-v2/referenceListContext.js.map +1 -0
  90. package/lib/hooks/index.js.map +1 -1
  91. package/lib/hooks/reference-v2/index.js +2 -0
  92. package/lib/hooks/reference-v2/index.js.map +1 -0
  93. package/lib/hooks/reference-v2/useReferenceCitationPreview.js +120 -0
  94. package/lib/hooks/reference-v2/useReferenceCitationPreview.js.map +1 -0
  95. package/lib/hooks/useReferenceCitationPreview.js.map +1 -1
  96. package/lib/hooks/useReferenceGroup.js.map +1 -1
  97. package/lib/index.js +5 -0
  98. package/lib/index.js.map +1 -1
  99. package/lib-commonjs/Citation.js.map +1 -1
  100. package/lib-commonjs/Reference.js.map +1 -1
  101. package/lib-commonjs/ReferenceGroupToggle.js.map +1 -1
  102. package/lib-commonjs/ReferenceList.js.map +1 -1
  103. package/lib-commonjs/ReferenceListV2.js +7 -0
  104. package/lib-commonjs/ReferenceListV2.js.map +1 -0
  105. package/lib-commonjs/ReferenceOverflowButton.js +7 -0
  106. package/lib-commonjs/ReferenceOverflowButton.js.map +1 -0
  107. package/lib-commonjs/ReferenceV2.js +7 -0
  108. package/lib-commonjs/ReferenceV2.js.map +1 -0
  109. package/lib-commonjs/components/Citation/Citation.js.map +1 -1
  110. package/lib-commonjs/components/Citation/Citation.types.js +3 -1
  111. package/lib-commonjs/components/Citation/Citation.types.js.map +1 -1
  112. package/lib-commonjs/components/Citation/index.js.map +1 -1
  113. package/lib-commonjs/components/Citation/renderCitation.js.map +1 -1
  114. package/lib-commonjs/components/Citation/useCitation.js +3 -3
  115. package/lib-commonjs/components/Citation/useCitation.js.map +1 -1
  116. package/lib-commonjs/components/Citation/useCitationStyles.js.map +1 -1
  117. package/lib-commonjs/components/Reference/Reference.js.map +1 -1
  118. package/lib-commonjs/components/Reference/Reference.types.js +3 -1
  119. package/lib-commonjs/components/Reference/Reference.types.js.map +1 -1
  120. package/lib-commonjs/components/Reference/index.js.map +1 -1
  121. package/lib-commonjs/components/Reference/renderReference.js.map +1 -1
  122. package/lib-commonjs/components/Reference/useReference.js +2 -2
  123. package/lib-commonjs/components/Reference/useReference.js.map +1 -1
  124. package/lib-commonjs/components/Reference/useReferenceStyles.js.map +1 -1
  125. package/lib-commonjs/components/ReferenceGroupToggle/ReferenceGroupToggle.js.map +1 -1
  126. package/lib-commonjs/components/ReferenceGroupToggle/ReferenceGroupToggle.types.js +3 -1
  127. package/lib-commonjs/components/ReferenceGroupToggle/ReferenceGroupToggle.types.js.map +1 -1
  128. package/lib-commonjs/components/ReferenceGroupToggle/index.js.map +1 -1
  129. package/lib-commonjs/components/ReferenceGroupToggle/renderReferenceGroupToggle.js.map +1 -1
  130. package/lib-commonjs/components/ReferenceGroupToggle/useReferenceGroupToggle.js.map +1 -1
  131. package/lib-commonjs/components/ReferenceGroupToggle/useReferenceGroupToggleStyles.js.map +1 -1
  132. package/lib-commonjs/components/ReferenceList/ReferenceList.js.map +1 -1
  133. package/lib-commonjs/components/ReferenceList/ReferenceList.types.js +3 -1
  134. package/lib-commonjs/components/ReferenceList/ReferenceList.types.js.map +1 -1
  135. package/lib-commonjs/components/ReferenceList/index.js.map +1 -1
  136. package/lib-commonjs/components/ReferenceList/renderReferenceList.js.map +1 -1
  137. package/lib-commonjs/components/ReferenceList/useReferenceList.js +1 -1
  138. package/lib-commonjs/components/ReferenceList/useReferenceList.js.map +1 -1
  139. package/lib-commonjs/components/ReferenceList/useReferenceListStyles.js.map +1 -1
  140. package/lib-commonjs/components/reference-v2/Reference/Reference.js +21 -0
  141. package/lib-commonjs/components/reference-v2/Reference/Reference.js.map +1 -0
  142. package/lib-commonjs/components/reference-v2/Reference/Reference.types.js +5 -0
  143. package/lib-commonjs/components/reference-v2/Reference/Reference.types.js.map +1 -0
  144. package/lib-commonjs/components/reference-v2/Reference/index.js +28 -0
  145. package/lib-commonjs/components/reference-v2/Reference/index.js.map +1 -0
  146. package/lib-commonjs/components/reference-v2/Reference/renderReference.js +32 -0
  147. package/lib-commonjs/components/reference-v2/Reference/renderReference.js.map +1 -0
  148. package/lib-commonjs/components/reference-v2/Reference/useReference.js +67 -0
  149. package/lib-commonjs/components/reference-v2/Reference/useReference.js.map +1 -0
  150. package/lib-commonjs/components/reference-v2/Reference/useReferenceStyles.js +122 -0
  151. package/lib-commonjs/components/reference-v2/Reference/useReferenceStyles.js.map +1 -0
  152. package/lib-commonjs/components/reference-v2/ReferenceList/ReferenceList.js +23 -0
  153. package/lib-commonjs/components/reference-v2/ReferenceList/ReferenceList.js.map +1 -0
  154. package/lib-commonjs/components/reference-v2/ReferenceList/ReferenceList.types.js +5 -0
  155. package/lib-commonjs/components/reference-v2/ReferenceList/ReferenceList.types.js.map +1 -0
  156. package/lib-commonjs/components/reference-v2/ReferenceList/index.js +11 -0
  157. package/lib-commonjs/components/reference-v2/ReferenceList/index.js.map +1 -0
  158. package/lib-commonjs/components/reference-v2/ReferenceList/renderReferenceList.js +28 -0
  159. package/lib-commonjs/components/reference-v2/ReferenceList/renderReferenceList.js.map +1 -0
  160. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceList.js +93 -0
  161. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceList.js.map +1 -0
  162. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceListContextValues.js +24 -0
  163. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceListContextValues.js.map +1 -0
  164. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceListStyles.js +55 -0
  165. package/lib-commonjs/components/reference-v2/ReferenceList/useReferenceListStyles.js.map +1 -0
  166. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.js +21 -0
  167. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.js.map +1 -0
  168. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.types.js +7 -0
  169. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/ReferenceOverflowButton.types.js.map +1 -0
  170. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/index.js +11 -0
  171. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/index.js.map +1 -0
  172. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/renderReferenceOverflowButton.js +16 -0
  173. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/renderReferenceOverflowButton.js.map +1 -0
  174. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButton.js +84 -0
  175. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButton.js.map +1 -0
  176. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButtonStyles.js +65 -0
  177. package/lib-commonjs/components/reference-v2/ReferenceOverflowButton/useReferenceOverflowButtonStyles.js.map +1 -0
  178. package/lib-commonjs/components/reference-v2/index.js +9 -0
  179. package/lib-commonjs/components/reference-v2/index.js.map +1 -0
  180. package/lib-commonjs/contexts/ReferenceGroupContext.js.map +1 -0
  181. package/lib-commonjs/contexts/reference-v2/index.js +7 -0
  182. package/lib-commonjs/contexts/reference-v2/index.js.map +1 -0
  183. package/lib-commonjs/contexts/reference-v2/referenceListContext.js +36 -0
  184. package/lib-commonjs/contexts/reference-v2/referenceListContext.js.map +1 -0
  185. package/lib-commonjs/hooks/index.js.map +1 -1
  186. package/lib-commonjs/hooks/reference-v2/index.js +7 -0
  187. package/lib-commonjs/hooks/reference-v2/index.js.map +1 -0
  188. package/lib-commonjs/hooks/reference-v2/useReferenceCitationPreview.js +148 -0
  189. package/lib-commonjs/hooks/reference-v2/useReferenceCitationPreview.js.map +1 -0
  190. package/lib-commonjs/hooks/useReferenceCitationPreview.js.map +1 -1
  191. package/lib-commonjs/hooks/useReferenceGroup.js.map +1 -1
  192. package/lib-commonjs/index.js +95 -30
  193. package/lib-commonjs/index.js.map +1 -1
  194. package/package.json +11 -11
  195. package/lib-commonjs/context/ReferenceGroupContext.js.map +0 -1
  196. /package/lib/{context → contexts}/ReferenceGroupContext.js +0 -0
  197. /package/lib-commonjs/{context → contexts}/ReferenceGroupContext.js +0 -0
package/CHANGELOG.json CHANGED
@@ -2,7 +2,43 @@
2
2
  "name": "@fluentui-copilot/react-reference",
3
3
  "entries": [
4
4
  {
5
- "date": "Wed, 03 Apr 2024 00:23:26 GMT",
5
+ "date": "Tue, 30 Apr 2024 20:54:47 GMT",
6
+ "tag": "@fluentui-copilot/react-reference_v0.11.1",
7
+ "version": "0.11.1",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "author": "Humberto.Morimoto@microsoft.com",
12
+ "package": "@fluentui-copilot/react-reference",
13
+ "commit": "f21ecfc955b4b5d5b3bb146dcedfb7d839170f93",
14
+ "comment": "feat: Implementing Reference, ReferenceList and ReferenceOverflowButton from output-v2 designs."
15
+ },
16
+ {
17
+ "author": "sarah.higley@microsoft.com",
18
+ "package": "@fluentui-copilot/react-reference",
19
+ "commit": "66eba4eb0956384ecc14b2a40c5fa722680f79d8",
20
+ "comment": "chore: bump @fluentui/react-components to latest, 9.49.0 "
21
+ }
22
+ ]
23
+ }
24
+ },
25
+ {
26
+ "date": "Wed, 10 Apr 2024 23:07:50 GMT",
27
+ "tag": "@fluentui-copilot/react-reference_v0.11.0",
28
+ "version": "0.11.0",
29
+ "comments": {
30
+ "minor": [
31
+ {
32
+ "author": "Humberto.Morimoto@microsoft.com",
33
+ "package": "@fluentui-copilot/react-reference",
34
+ "commit": "2afa98912cd99ed6f604c582caee4d49d1ba895d",
35
+ "comment": "fix: Replace usage of deprecated getNativeElementProps with getIntrinsicElementProps."
36
+ }
37
+ ]
38
+ }
39
+ },
40
+ {
41
+ "date": "Wed, 03 Apr 2024 00:23:41 GMT",
6
42
  "tag": "@fluentui-copilot/react-reference_v0.10.0",
7
43
  "version": "0.10.0",
8
44
  "comments": {
package/CHANGELOG.md CHANGED
@@ -1,12 +1,31 @@
1
1
  # Change Log - @fluentui-copilot/react-reference
2
2
 
3
- This log was last generated on Wed, 03 Apr 2024 00:23:26 GMT and should not be manually modified.
3
+ This log was last generated on Tue, 30 Apr 2024 20:54:47 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## [0.11.1](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-reference_v0.11.1)
8
+
9
+ Tue, 30 Apr 2024 20:54:47 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-reference_v0.11.0..@fluentui-copilot/react-reference_v0.11.1)
11
+
12
+ ### Patches
13
+
14
+ - feat: Implementing Reference, ReferenceList and ReferenceOverflowButton from output-v2 designs. ([PR #1586](https://github.com/microsoft/fluentai/pull/1586) by Humberto.Morimoto@microsoft.com)
15
+ - chore: bump @fluentui/react-components to latest, 9.49.0 ([PR #1580](https://github.com/microsoft/fluentai/pull/1580) by sarah.higley@microsoft.com)
16
+
17
+ ## [0.11.0](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-reference_v0.11.0)
18
+
19
+ Wed, 10 Apr 2024 23:07:50 GMT
20
+ [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-reference_v0.10.0..@fluentui-copilot/react-reference_v0.11.0)
21
+
22
+ ### Minor changes
23
+
24
+ - fix: Replace usage of deprecated getNativeElementProps with getIntrinsicElementProps. ([PR #1512](https://github.com/microsoft/fluentai/pull/1512) by Humberto.Morimoto@microsoft.com)
25
+
7
26
  ## [0.10.0](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-reference_v0.10.0)
8
27
 
9
- Wed, 03 Apr 2024 00:23:26 GMT
28
+ Wed, 03 Apr 2024 00:23:41 GMT
10
29
  [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-reference_v0.9.0..@fluentui-copilot/react-reference_v0.10.0)
11
30
 
12
31
  ### Minor changes
package/dist/index.d.ts CHANGED
@@ -1,11 +1,18 @@
1
+ /// <reference types="react" />
2
+
1
3
  import type { Button } from '@fluentui/react-components';
2
4
  import type { ComponentProps } from '@fluentui/react-components';
3
5
  import type { ComponentState } from '@fluentui/react-components';
6
+ import type { Context } from '@fluentui/react-context-selector';
7
+ import type { ContextSelector } from '@fluentui/react-context-selector';
8
+ import { FC } from 'react';
4
9
  import type { ForwardRefComponent } from '@fluentui/react-components';
5
10
  import type { PopoverProps } from '@fluentui/react-components';
6
11
  import type { PopoverSurfaceProps } from '@fluentui/react-components';
7
12
  import type { PopoverSurfaceSlots } from '@fluentui/react-components';
8
13
  import type { PositioningShorthand } from '@fluentui/react-components';
14
+ import { Provider } from 'react';
15
+ import { ProviderProps } from 'react';
9
16
  import * as React_2 from 'react';
10
17
  import type { Slot } from '@fluentui/react-components';
11
18
  import type { SlotClassNames } from '@fluentui/react-components';
@@ -59,6 +66,12 @@ export declare type PackagedCitation = React_2.FC<PackagedCitationProps>;
59
66
  */
60
67
  export declare type PackagedCitationProps = Omit<CitationProps, 'referenceHref'> & Partial<Pick<CitationProps, 'referenceHref'>>;
61
68
 
69
+ export declare type PackagedCitationV2 = React_2.FC<CitationProps>;
70
+
71
+ export declare type PackagedPreviewContentV2Props = Pick<PreviewMetadataProps, 'icon' | 'primaryText' | 'secondaryText' | 'tertiaryText'> & {
72
+ content?: React_2.ReactNode;
73
+ };
74
+
62
75
  /**
63
76
  * A "packaged Reference". A packaged Reference is a `Reference` that is
64
77
  * pre-packaged with props set by the `useReferenceCitation` hook.
@@ -71,8 +84,35 @@ export declare type PackagedReference = React_2.FC<PackagedReferenceProps>;
71
84
  */
72
85
  export declare type PackagedReferenceProps = Omit<ReferenceProps, PartialReferenceProps> & Partial<Pick<ReferenceProps, PartialReferenceProps>>;
73
86
 
87
+ export declare type PackagedReferenceV2 = React_2.FC<ReferenceV2Props>;
88
+
74
89
  declare type PartialReferenceProps = 'citationHref' | 'index' | 'referenceId';
75
90
 
91
+ /**
92
+ * PreviewMetadata Props
93
+ */
94
+ declare type PreviewMetadataProps = ComponentProps<Partial<PreviewMetadataSlots>>;
95
+
96
+ declare type PreviewMetadataSlots = {
97
+ root: Slot<'div'>;
98
+ /**
99
+ * Icon slot in the metadata displayed after all text.
100
+ */
101
+ icon: Slot<'span'>;
102
+ /**
103
+ * First text displayed in the metadata.
104
+ */
105
+ primaryText: Slot<'span'>;
106
+ /**
107
+ * Second text displayed in the metadata.
108
+ */
109
+ secondaryText: Slot<'span'>;
110
+ /**
111
+ * Third text displayed in the metadata.
112
+ */
113
+ tertiaryText: Slot<'span'>;
114
+ };
115
+
76
116
  /**
77
117
  * Preview Props
78
118
  */
@@ -131,6 +171,15 @@ export declare const ReferenceList: ForwardRefComponent<ReferenceListProps>;
131
171
 
132
172
  export declare const referenceListClassNames: SlotClassNames<ReferenceListSlots>;
133
173
 
174
+ export declare const ReferenceListContext: Context<ReferenceListContextValue>;
175
+
176
+ export declare const ReferenceListContextProvider: Provider<ReferenceListContextValue> & FC<ProviderProps<ReferenceListContextValue>>;
177
+
178
+ /**
179
+ * Context shared between ReferenceList and its children components
180
+ */
181
+ export declare type ReferenceListContextValue = Pick<ReferenceListV2State, 'appearance' | 'areReferencesExpanded' | 'overflowButtonTriggeredViaKeyboard' | 'previousOverflowCount' | 'shouldUseOverflow'>;
182
+
134
183
  /**
135
184
  * ReferenceList Props
136
185
  */
@@ -148,6 +197,69 @@ export declare type ReferenceListSlots = {
148
197
  */
149
198
  export declare type ReferenceListState = ComponentState<ReferenceListSlots>;
150
199
 
200
+ export declare const ReferenceListV2: ForwardRefComponent<ReferenceListV2Props>;
201
+
202
+ export declare const referenceListV2ClassNames: SlotClassNames<ReferenceListV2Slots>;
203
+
204
+ export declare type ReferenceListV2ContextValues = {
205
+ referenceList: ReferenceListContextValue;
206
+ };
207
+
208
+ export declare type ReferenceListV2Props = ComponentProps<ReferenceListV2Slots> & {
209
+ /**
210
+ * The appearance of the reference.
211
+ * @default 'lighter'
212
+ */
213
+ appearance?: 'lighter' | 'darker';
214
+ /**
215
+ * The maximum number of references to display before the overflow button is shown even if there is
216
+ * enough space available to show more.
217
+ * If not set, the overflow functionality will be disabled.
218
+ * @default undefined
219
+ */
220
+ maxVisibleReferences?: number;
221
+ };
222
+
223
+ export declare type ReferenceListV2Slots = {
224
+ root: NonNullable<Slot<'div'>>;
225
+ showMoreButton?: Slot<'span'>;
226
+ showLessButton?: Slot<'span'>;
227
+ };
228
+
229
+ export declare type ReferenceListV2State = ComponentState<ReferenceListV2Slots> & Required<Pick<ReferenceListV2Props, 'appearance'>> & {
230
+ areReferencesExpanded: boolean;
231
+ overflowButtonTriggeredViaKeyboard: React.MutableRefObject<boolean>;
232
+ previousOverflowCount: React.MutableRefObject<number>;
233
+ shouldUseOverflow: boolean;
234
+ };
235
+
236
+ export declare const ReferenceOverflowButton: ForwardRefComponent<ReferenceOverflowButtonProps>;
237
+
238
+ export declare const referenceOverflowButtonClassNames: SlotClassNames<ReferenceOverflowButtonSlots>;
239
+
240
+ /**
241
+ * ReferenceOverflowButton Props
242
+ */
243
+ export declare type ReferenceOverflowButtonProps = ComponentProps<ReferenceOverflowButtonSlots> & {
244
+ /**
245
+ * The appearance of the reference.
246
+ * @default 'lighter'
247
+ */
248
+ appearance?: 'lighter' | 'darker';
249
+ text?: string | ((overflowCount: number) => React.ReactNode);
250
+ };
251
+
252
+ export declare type ReferenceOverflowButtonSlots = {
253
+ root: Slot<'button'>;
254
+ };
255
+
256
+ /**
257
+ * State used in rendering ReferenceOverflowButton
258
+ */
259
+ export declare type ReferenceOverflowButtonState = ComponentState<ReferenceOverflowButtonSlots> & Required<Pick<ReferenceOverflowButtonProps, 'appearance'>> & {
260
+ shouldRenderOverflowButton: boolean;
261
+ };
262
+
151
263
  /**
152
264
  * Reference Props
153
265
  */
@@ -239,6 +351,32 @@ export declare type ReferenceState = ComponentState<ReferenceSlots> & Required<P
239
351
  isExpanded: boolean;
240
352
  };
241
353
 
354
+ export declare const ReferenceV2: ForwardRefComponent<ReferenceV2Props>;
355
+
356
+ export declare const referenceV2ClassNames: SlotClassNames<ReferenceV2Slots>;
357
+
358
+ export declare const referenceV2ExtraClassNames: {
359
+ mediaChild: string;
360
+ };
361
+
362
+ export declare type ReferenceV2Props = ComponentProps<Partial<ReferenceV2Slots>> & {
363
+ /**
364
+ * The appearance of the reference.
365
+ * @default 'lighter'
366
+ */
367
+ appearance?: 'lighter' | 'darker';
368
+ };
369
+
370
+ export declare type ReferenceV2Slots = {
371
+ root: NonNullable<Slot<'button'>>;
372
+ citation?: Slot<'span'>;
373
+ divider?: Slot<'span'>;
374
+ content?: Slot<'span'>;
375
+ media?: Slot<'span'>;
376
+ };
377
+
378
+ export declare type ReferenceV2State = ComponentState<ReferenceV2Slots> & Required<Pick<ReferenceV2Props, 'appearance' | 'id'>> & Pick<ReferenceListV2State, 'shouldUseOverflow'>;
379
+
242
380
  /**
243
381
  * Render the final JSX of Citation
244
382
  */
@@ -259,6 +397,18 @@ export declare const renderReferenceGroupToggle_unstable: (state: ReferenceGroup
259
397
  */
260
398
  export declare const renderReferenceList_unstable: (state: ReferenceListState) => JSX.Element;
261
399
 
400
+ /**
401
+ * Render the final JSX of ReferenceList
402
+ */
403
+ export declare const renderReferenceListV2_unstable: (state: ReferenceListV2State, contextValues: ReferenceListV2ContextValues) => JSX.Element;
404
+
405
+ /**
406
+ * Render the final JSX of ReferenceOverflowButton
407
+ */
408
+ export declare const renderReferenceOverflowButton_unstable: (state: ReferenceOverflowButtonState) => JSX.Element | null;
409
+
410
+ export declare const renderReferenceV2_unstable: (state: ReferenceV2State) => JSX.Element;
411
+
262
412
  /**
263
413
  * SensitivityLabel Props
264
414
  */
@@ -298,7 +448,7 @@ declare type SensitivityTooltipSlots = {
298
448
  * @param props - props from this instance of Citation
299
449
  * @param ref - reference to root HTMLElement of Citation
300
450
  */
301
- export declare const useCitation_unstable: (props: CitationProps, ref: React.Ref<HTMLElement>) => CitationState;
451
+ export declare const useCitation_unstable: (props: CitationProps, ref: React.Ref<HTMLAnchorElement>) => CitationState;
302
452
 
303
453
  /**
304
454
  * Apply styling to the Citation slots based on the state
@@ -314,7 +464,7 @@ export declare const useCitationStyles_unstable: (state: CitationState) => Citat
314
464
  * @param props - props from this instance of Reference
315
465
  * @param ref - reference to root HTMLElement of Reference
316
466
  */
317
- export declare const useReference_unstable: (props: ReferenceProps, ref: React_2.Ref<HTMLElement>) => ReferenceState;
467
+ export declare const useReference_unstable: (props: ReferenceProps, ref: React_2.Ref<HTMLDivElement>) => ReferenceState;
318
468
 
319
469
  export declare type UseReferenceCitationPreview = (data: ReferenceCitationData) => {
320
470
  Citation: PackagedCitation;
@@ -330,6 +480,25 @@ export declare type UseReferenceCitationPreview = (data: ReferenceCitationData)
330
480
  */
331
481
  export declare const useReferenceCitationPreview: UseReferenceCitationPreview;
332
482
 
483
+ export declare type UseReferenceCitationPreviewV2 = (props: UseReferenceCitationPreviewV2Props) => {
484
+ Citation: PackagedCitationV2;
485
+ Reference: PackagedReferenceV2;
486
+ };
487
+
488
+ export declare const useReferenceCitationPreviewV2: UseReferenceCitationPreviewV2;
489
+
490
+ export declare type UseReferenceCitationPreviewV2Props = {
491
+ citationPreviewProps?: PreviewProps;
492
+ citationPreviewSurfaceProps?: PreviewSurfaceProps;
493
+ citationProps?: CitationProps;
494
+ index: number;
495
+ previewContentProps?: PackagedPreviewContentV2Props;
496
+ referencePreviewProps?: PreviewProps;
497
+ referencePreviewSurfaceProps?: PreviewSurfaceProps;
498
+ referenceProps?: ReferenceV2Props;
499
+ sensitivityLabelProps?: SensitivityLabelProps;
500
+ };
501
+
333
502
  export declare type UseReferenceGroup = (props: UseReferenceGroupProps) => {
334
503
  referenceGroupToggleProps: ReferenceGroupToggleProps;
335
504
  referenceListProps: ReferenceListProps;
@@ -373,16 +542,66 @@ export declare const useReferenceGroupToggleStyles_unstable: (state: ReferenceGr
373
542
  * @param props - props from this instance of ReferenceList
374
543
  * @param ref - reference to root HTMLElement of ReferenceList
375
544
  */
376
- export declare const useReferenceList_unstable: (props: ReferenceListProps, ref: React_2.Ref<HTMLElement>) => ReferenceListState;
545
+ export declare const useReferenceList_unstable: (props: ReferenceListProps, ref: React_2.Ref<HTMLOListElement>) => ReferenceListState;
546
+
547
+ export declare const useReferenceListContext_unstable: <T>(selector: ContextSelector<ReferenceListContextValue, T>) => T;
377
548
 
378
549
  /**
379
550
  * Apply styling to the ReferenceList slots based on the state
380
551
  */
381
552
  export declare const useReferenceListStyles_unstable: (state: ReferenceListState) => ReferenceListState;
382
553
 
554
+ /**
555
+ * Apply styling to the ReferenceList slots based on the state
556
+ */
557
+ export declare const useReferenceListStylesV2_unstable: (state: ReferenceListV2State) => ReferenceListV2State;
558
+
559
+ /**
560
+ * Create the state required to render ReferenceList.
561
+ *
562
+ * The returned state can be modified with hooks such as useReferenceListStyles_unstable,
563
+ * before being passed to renderReferenceList_unstable.
564
+ *
565
+ * @param props - props from this instance of ReferenceList
566
+ * @param ref - reference to root HTMLElement of ReferenceList
567
+ */
568
+ export declare const useReferenceListV2_unstable: (props: ReferenceListV2Props, ref: React_2.Ref<HTMLDivElement>) => ReferenceListV2State;
569
+
570
+ /**
571
+ * Create the state required to render ReferenceOverflowButton.
572
+ *
573
+ * The returned state can be modified with hooks such as useReferenceOverflowButtonStyles_unstable,
574
+ * before being passed to renderReferenceOverflowButton_unstable.
575
+ *
576
+ * @param props - props from this instance of ReferenceOverflowButton
577
+ * @param ref - reference to root HTMLElement of ReferenceOverflowButton
578
+ */
579
+ export declare const useReferenceOverflowButton_unstable: (props: ReferenceOverflowButtonProps, ref: React_2.Ref<HTMLButtonElement>) => ReferenceOverflowButtonState;
580
+
581
+ /**
582
+ * Apply styling to the ReferenceOverflowButton slots based on the state
583
+ */
584
+ export declare const useReferenceOverflowButtonStyles_unstable: (state: ReferenceOverflowButtonState) => ReferenceOverflowButtonState;
585
+
383
586
  /**
384
587
  * Apply styling to the Reference slots based on the state
385
588
  */
386
589
  export declare const useReferenceStyles_unstable: (state: ReferenceState) => ReferenceState;
387
590
 
591
+ /**
592
+ * Apply styling to the Reference slots based on the state
593
+ */
594
+ export declare const useReferenceStylesV2_unstable: (state: ReferenceV2State) => ReferenceV2State;
595
+
596
+ /**
597
+ * Create the state required to render Reference.
598
+ *
599
+ * The returned state can be modified with hooks such as useReferenceStyles_unstable,
600
+ * before being passed to renderReference_unstable.
601
+ *
602
+ * @param props - props from this instance of Reference
603
+ * @param ref - reference to root HTMLElement of Reference
604
+ */
605
+ export declare const useReferenceV2_unstable: (props: ReferenceV2Props, ref: React_2.Ref<HTMLButtonElement>) => ReferenceV2State;
606
+
388
607
  export { }
@@ -1 +1 @@
1
- {"version":3,"sources":["Citation.ts"],"sourcesContent":["export * from './components/Citation/index';\n"],"names":[],"mappings":"AAAA,cAAc,8BAA8B"}
1
+ {"version":3,"sources":["Citation.ts"],"sourcesContent":["export * from './components/Citation/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,8BAA8B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["Reference.ts"],"sourcesContent":["export * from './components/Reference/index';\n"],"names":[],"mappings":"AAAA,cAAc,+BAA+B"}
1
+ {"version":3,"sources":["Reference.ts"],"sourcesContent":["export * from './components/Reference/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,+BAA+B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["ReferenceGroupToggle.ts"],"sourcesContent":["export * from './components/ReferenceGroupToggle/index';\n"],"names":[],"mappings":"AAAA,cAAc,0CAA0C"}
1
+ {"version":3,"sources":["ReferenceGroupToggle.ts"],"sourcesContent":["export * from './components/ReferenceGroupToggle/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,0CAA0C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["ReferenceList.ts"],"sourcesContent":["export * from './components/ReferenceList/index';\n"],"names":[],"mappings":"AAAA,cAAc,mCAAmC"}
1
+ {"version":3,"sources":["ReferenceList.ts"],"sourcesContent":["export * from './components/ReferenceList/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,mCAAmC"}
@@ -0,0 +1,2 @@
1
+ export * from './components/reference-v2/ReferenceList';
2
+ //# sourceMappingURL=ReferenceListV2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["ReferenceListV2.ts"],"sourcesContent":["export * from './components/reference-v2/ReferenceList';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,0CAA0C"}
@@ -0,0 +1,2 @@
1
+ export * from './components/reference-v2/ReferenceOverflowButton';
2
+ //# sourceMappingURL=ReferenceOverflowButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["ReferenceOverflowButton.ts"],"sourcesContent":["export * from './components/reference-v2/ReferenceOverflowButton';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,oDAAoD"}
@@ -0,0 +1,2 @@
1
+ export * from './components/reference-v2/Reference';
2
+ //# sourceMappingURL=ReferenceV2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["ReferenceV2.ts"],"sourcesContent":["export * from './components/reference-v2/Reference';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,sCAAsC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["Citation.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useCitation_unstable } from './useCitation';\nimport { renderCitation_unstable } from './renderCitation';\nimport { useCitationStyles_unstable } from './useCitationStyles';\nimport type { CitationProps } from './Citation.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Citation component - TODO: add more docs\nexport const Citation: ForwardRefComponent<CitationProps> = React.forwardRef((props, ref) => {\n const state = useCitation_unstable(props, ref);\n\n useCitationStyles_unstable(state);\n useCustomStyleHook('useCitationStyles')(state);\n\n return renderCitation_unstable(state);\n});\n\nCitation.displayName = 'Citation';\n"],"names":["React","useCitation_unstable","renderCitation_unstable","useCitationStyles_unstable","useCustomStyleHook","Citation","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,oBAAoB,QAAQ,gBAAgB;AACrD,SAASC,uBAAuB,QAAQ,mBAAmB;AAC3D,SAASC,0BAA0B,QAAQ,sBAAsB;AAGjE,SAASC,kBAAkB,QAAQ,mCAAmC;AAEtE,2CAA2C;AAC3C,OAAO,MAAMC,yBAA+CL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IACnF,MAAMC,QAAQR,qBAAqBM,OAAOC;IAE1CL,2BAA2BM;IAC3BL,mBAAmB,qBAAqBK;IAExC,OAAOP,wBAAwBO;AACjC,GAAG;AAEHJ,SAASK,WAAW,GAAG"}
1
+ {"version":3,"sources":["Citation.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useCitation_unstable } from './useCitation';\nimport { renderCitation_unstable } from './renderCitation';\nimport { useCitationStyles_unstable } from './useCitationStyles';\nimport type { CitationProps } from './Citation.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Citation component - TODO: add more docs\nexport const Citation: ForwardRefComponent<CitationProps> = React.forwardRef((props, ref) => {\n const state = useCitation_unstable(props, ref);\n\n useCitationStyles_unstable(state);\n useCustomStyleHook('useCitationStyles')(state);\n\n return renderCitation_unstable(state);\n});\n\nCitation.displayName = 'Citation';\n"],"names":["React","useCitation_unstable","renderCitation_unstable","useCitationStyles_unstable","useCustomStyleHook","Citation","forwardRef","props","ref","state","displayName"],"rangeMappings":";;;;;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,oBAAoB,QAAQ,gBAAgB;AACrD,SAASC,uBAAuB,QAAQ,mBAAmB;AAC3D,SAASC,0BAA0B,QAAQ,sBAAsB;AAGjE,SAASC,kBAAkB,QAAQ,mCAAmC;AAEtE,2CAA2C;AAC3C,OAAO,MAAMC,yBAA+CL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IACnF,MAAMC,QAAQR,qBAAqBM,OAAOC;IAE1CL,2BAA2BM;IAC3BL,mBAAmB,qBAAqBK;IAExC,OAAOP,wBAAwBO;AACjC,GAAG;AAEHJ,SAASK,WAAW,GAAG"}
@@ -1,2 +1,4 @@
1
- export {};
1
+ /**
2
+ * State used in rendering Citation
3
+ */export {};
2
4
  //# sourceMappingURL=Citation.types.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["Citation.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-components';\n\nexport type CitationSlots = {\n /**\n * The root slot.\n */\n root: NonNullable<Slot<'a'>>;\n};\n\n/**\n * Citation Props\n */\nexport type CitationProps = ComponentProps<Partial<CitationSlots>> & {\n /**\n * HREF to the associated `Reference`.\n */\n referenceHref?: string;\n\n /**\n * Whether the citation is a block citation and has no built in margins.\n * Citations are inline by default with margins to separate them from inline text.\n */\n block?: boolean;\n};\n\n/**\n * State used in rendering Citation\n */\nexport type CitationState = ComponentState<CitationSlots> &\n Required<Pick<CitationProps, 'block'>> & {\n isPopoverLocked: boolean;\n };\n"],"names":[],"mappings":"AAAA,WA+BI"}
1
+ {"version":3,"sources":["Citation.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-components';\n\nexport type CitationSlots = {\n /**\n * The root slot.\n */\n root: NonNullable<Slot<'a'>>;\n};\n\n/**\n * Citation Props\n */\nexport type CitationProps = ComponentProps<Partial<CitationSlots>> & {\n /**\n * HREF to the associated `Reference`.\n */\n referenceHref?: string;\n\n /**\n * Whether the citation is a block citation and has no built in margins.\n * Citations are inline by default with margins to separate them from inline text.\n */\n block?: boolean;\n};\n\n/**\n * State used in rendering Citation\n */\nexport type CitationState = ComponentState<CitationSlots> &\n Required<Pick<CitationProps, 'block'>> & {\n isPopoverLocked: boolean;\n };\n"],"names":[],"rangeMappings":";;","mappings":"AAyBA;;CAEC,GACD,WAGI"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"sourcesContent":["export * from './Citation';\nexport * from './Citation.types';\nexport * from './renderCitation';\nexport * from './useCitation';\nexport * from './useCitationStyles';\n"],"names":[],"mappings":"AAAA,cAAc,aAAa;AAC3B,cAAc,mBAAmB;AACjC,cAAc,mBAAmB;AACjC,cAAc,gBAAgB;AAC9B,cAAc,sBAAsB"}
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export * from './Citation';\nexport * from './Citation.types';\nexport * from './renderCitation';\nexport * from './useCitation';\nexport * from './useCitationStyles';\n"],"names":[],"rangeMappings":";;;;","mappings":"AAAA,cAAc,aAAa;AAC3B,cAAc,mBAAmB;AACjC,cAAc,mBAAmB;AACjC,cAAc,gBAAgB;AAC9B,cAAc,sBAAsB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderCitation.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-components';\nimport type { CitationState, CitationSlots } from './Citation.types';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState) => {\n assertSlots<CitationSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderCitation_unstable","state","root"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,6BAA6B;AAEzD;;CAEC,GACD,OAAO,MAAMC,0BAA0B,CAACC;IACtCF,YAA2BE;IAE3B,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
1
+ {"version":3,"sources":["renderCitation.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-components';\nimport type { CitationState, CitationSlots } from './Citation.types';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState) => {\n assertSlots<CitationSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderCitation_unstable","state","root"],"rangeMappings":";;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,6BAA6B;AAEzD;;CAEC,GACD,OAAO,MAAMC,0BAA0B,CAACC;IACtCF,YAA2BE;IAE3B,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
@@ -1,4 +1,4 @@
1
- import { getNativeElementProps, slot } from '@fluentui/react-components';
1
+ import { getIntrinsicElementProps, slot } from '@fluentui/react-components';
2
2
  import { usePreviewContext_unstable } from '@fluentui-copilot/react-preview';
3
3
  /**
4
4
  * Create the state required to render Citation.
@@ -22,11 +22,11 @@ export const useCitation_unstable = (props, ref) => {
22
22
  components: {
23
23
  root: 'a'
24
24
  },
25
- root: slot.always(getNativeElementProps('a', {
25
+ root: slot.always(getIntrinsicElementProps('a', {
26
26
  ref,
27
27
  href: referenceHref,
28
- role: null,
29
- 'aria-expanded': null,
28
+ role: undefined,
29
+ 'aria-expanded': undefined,
30
30
  ...otherProps
31
31
  }), {
32
32
  elementType: 'a'
@@ -1 +1 @@
1
- {"version":3,"sources":["useCitation.ts"],"sourcesContent":["import { getNativeElementProps, slot } from '@fluentui/react-components';\nimport { usePreviewContext_unstable } from '@fluentui-copilot/react-preview';\nimport type { CitationProps, CitationState } from './Citation.types';\n/**\n * Create the state required to render Citation.\n *\n * The returned state can be modified with hooks such as useCitationStyles_unstable,\n * before being passed to renderCitation_unstable.\n *\n * @param props - props from this instance of Citation\n * @param ref - reference to root HTMLElement of Citation\n */\nexport const useCitation_unstable = (props: CitationProps, ref: React.Ref<HTMLElement>): CitationState => {\n const { referenceHref, block = false, ...otherProps } = props;\n\n const isPopoverLocked = usePreviewContext_unstable(ctx => ctx.isPreviewLocked) && (props['aria-expanded'] as boolean);\n\n const state: CitationState = {\n block,\n isPopoverLocked,\n components: {\n root: 'a',\n },\n root: slot.always(\n getNativeElementProps('a', {\n ref,\n href: referenceHref,\n role: null,\n 'aria-expanded': null,\n ...otherProps,\n }),\n { elementType: 'a' },\n ),\n };\n\n return state;\n};\n"],"names":["getNativeElementProps","slot","usePreviewContext_unstable","useCitation_unstable","props","ref","referenceHref","block","otherProps","isPopoverLocked","ctx","isPreviewLocked","state","components","root","always","href","role","elementType"],"mappings":"AAAA,SAASA,qBAAqB,EAAEC,IAAI,QAAQ,6BAA6B;AACzE,SAASC,0BAA0B,QAAQ,kCAAkC;AAE7E;;;;;;;;CAQC,GACD,OAAO,MAAMC,uBAAuB,CAACC,OAAsBC;IACzD,MAAM,EAAEC,aAAa,EAAEC,QAAQ,KAAK,EAAE,GAAGC,YAAY,GAAGJ;IAExD,MAAMK,kBAAkBP,2BAA2BQ,CAAAA,MAAOA,IAAIC,eAAe,KAAMP,KAAK,CAAC,gBAAgB;IAEzG,MAAMQ,QAAuB;QAC3BL;QACAE;QACAI,YAAY;YACVC,MAAM;QACR;QACAA,MAAMb,KAAKc,MAAM,CACff,sBAAsB,KAAK;YACzBK;YACAW,MAAMV;YACNW,MAAM;YACN,iBAAiB;YACjB,GAAGT,UAAU;QACf,IACA;YAAEU,aAAa;QAAI;IAEvB;IAEA,OAAON;AACT,EAAE"}
1
+ {"version":3,"sources":["useCitation.ts"],"sourcesContent":["import { getIntrinsicElementProps, slot } from '@fluentui/react-components';\nimport { usePreviewContext_unstable } from '@fluentui-copilot/react-preview';\nimport type { CitationProps, CitationState } from './Citation.types';\n/**\n * Create the state required to render Citation.\n *\n * The returned state can be modified with hooks such as useCitationStyles_unstable,\n * before being passed to renderCitation_unstable.\n *\n * @param props - props from this instance of Citation\n * @param ref - reference to root HTMLElement of Citation\n */\nexport const useCitation_unstable = (props: CitationProps, ref: React.Ref<HTMLAnchorElement>): CitationState => {\n const { referenceHref, block = false, ...otherProps } = props;\n\n const isPopoverLocked = usePreviewContext_unstable(ctx => ctx.isPreviewLocked) && (props['aria-expanded'] as boolean);\n\n const state: CitationState = {\n block,\n isPopoverLocked,\n components: {\n root: 'a',\n },\n root: slot.always(\n getIntrinsicElementProps('a', {\n ref,\n href: referenceHref,\n role: undefined,\n 'aria-expanded': undefined,\n ...otherProps,\n }),\n { elementType: 'a' },\n ),\n };\n\n return state;\n};\n"],"names":["getIntrinsicElementProps","slot","usePreviewContext_unstable","useCitation_unstable","props","ref","referenceHref","block","otherProps","isPopoverLocked","ctx","isPreviewLocked","state","components","root","always","href","role","undefined","elementType"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,wBAAwB,EAAEC,IAAI,QAAQ,6BAA6B;AAC5E,SAASC,0BAA0B,QAAQ,kCAAkC;AAE7E;;;;;;;;CAQC,GACD,OAAO,MAAMC,uBAAuB,CAACC,OAAsBC;IACzD,MAAM,EAAEC,aAAa,EAAEC,QAAQ,KAAK,EAAE,GAAGC,YAAY,GAAGJ;IAExD,MAAMK,kBAAkBP,2BAA2BQ,CAAAA,MAAOA,IAAIC,eAAe,KAAMP,KAAK,CAAC,gBAAgB;IAEzG,MAAMQ,QAAuB;QAC3BL;QACAE;QACAI,YAAY;YACVC,MAAM;QACR;QACAA,MAAMb,KAAKc,MAAM,CACff,yBAAyB,KAAK;YAC5BK;YACAW,MAAMV;YACNW,MAAMC;YACN,iBAAiBA;YACjB,GAAGV,UAAU;QACf,IACA;YAAEW,aAAa;QAAI;IAEvB;IAEA,OAAOP;AACT,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useCitationStyles.ts"],"sourcesContent":["import {\n makeResetStyles,\n makeStyles,\n mergeClasses,\n shorthands,\n tokens,\n typographyStyles,\n} from '@fluentui/react-components';\nimport type { CitationSlots, CitationState } from './Citation.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\n\nexport const citationClassNames: SlotClassNames<CitationSlots> = {\n root: 'fai-Citation',\n};\n\nconst useCitationBaseClassName = makeResetStyles({\n display: 'inline-flex',\n justifyContent: 'center',\n boxSizing: 'border-box',\n alignItems: 'center',\n ...typographyStyles.caption2Strong,\n\n color: tokens.colorNeutralForeground2,\n border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke2}`,\n\n minWidth: '14px',\n height: '14px',\n verticalAlign: `calc((${typographyStyles.caption2Strong.lineHeight} - ${typographyStyles.caption2Strong.fontSize}) / 2)`,\n\n borderRadius: tokens.borderRadiusMedium,\n\n textDecoration: 'none',\n\n marginLeft: tokens.spacingHorizontalXXS,\n marginRight: tokens.spacingHorizontalXXS,\n\n ':hover': {\n cursor: 'pointer',\n color: tokens.colorBrandForeground2Hover,\n borderColor: tokens.colorBrandStroke2Hover,\n backgroundColor: tokens.colorBrandBackground2Hover,\n },\n\n ':hover:active': {\n cursor: 'pointer',\n color: tokens.colorBrandForeground2Pressed,\n borderColor: tokens.colorBrandStroke2Pressed,\n backgroundColor: tokens.colorBrandBackground2Pressed,\n },\n});\n\nconst useCitationRootStyles = makeStyles({\n isBlock: {\n display: 'flex',\n marginLeft: 0,\n marginRight: 0,\n },\n isPopoverLocked: {\n color: tokens.colorBrandForeground2Pressed,\n ...shorthands.borderColor(tokens.colorBrandStroke2Pressed),\n backgroundColor: tokens.colorBrandBackground2,\n ':hover': {\n color: tokens.colorBrandForeground2Pressed,\n ...shorthands.borderColor(tokens.colorBrandStroke2Pressed),\n backgroundColor: tokens.colorBrandBackground2,\n },\n },\n});\n\n/**\n * Apply styling to the Citation slots based on the state\n */\nexport const useCitationStyles_unstable = (state: CitationState): CitationState => {\n const rootBaseClassName = useCitationBaseClassName();\n const rootStyles = useCitationRootStyles();\n\n state.root.className = mergeClasses(\n citationClassNames.root,\n state.isPopoverLocked && rootStyles.isPopoverLocked,\n state.block && rootStyles.isBlock,\n rootBaseClassName,\n state.root.className,\n );\n\n return state;\n};\n"],"names":["makeResetStyles","makeStyles","mergeClasses","shorthands","tokens","typographyStyles","citationClassNames","root","useCitationBaseClassName","display","justifyContent","boxSizing","alignItems","caption2Strong","color","colorNeutralForeground2","border","strokeWidthThin","colorNeutralStroke2","minWidth","height","verticalAlign","lineHeight","fontSize","borderRadius","borderRadiusMedium","textDecoration","marginLeft","spacingHorizontalXXS","marginRight","cursor","colorBrandForeground2Hover","borderColor","colorBrandStroke2Hover","backgroundColor","colorBrandBackground2Hover","colorBrandForeground2Pressed","colorBrandStroke2Pressed","colorBrandBackground2Pressed","useCitationRootStyles","isBlock","isPopoverLocked","colorBrandBackground2","useCitationStyles_unstable","state","rootBaseClassName","rootStyles","className","block"],"mappings":"AAAA,SACEA,eAAe,EACfC,UAAU,EACVC,YAAY,EACZC,UAAU,EACVC,MAAM,EACNC,gBAAgB,QACX,6BAA6B;AAIpC,OAAO,MAAMC,qBAAoD;IAC/DC,MAAM;AACR,EAAE;AAEF,MAAMC,2BAA2BR,gBAAgB;IAC/CS,SAAS;IACTC,gBAAgB;IAChBC,WAAW;IACXC,YAAY;IACZ,GAAGP,iBAAiBQ,cAAc;IAElCC,OAAOV,OAAOW,uBAAuB;IACrCC,QAAQ,CAAC,EAAEZ,OAAOa,eAAe,CAAC,OAAO,EAAEb,OAAOc,mBAAmB,CAAC,CAAC;IAEvEC,UAAU;IACVC,QAAQ;IACRC,eAAe,CAAC,MAAM,EAAEhB,iBAAiBQ,cAAc,CAACS,UAAU,CAAC,GAAG,EAAEjB,iBAAiBQ,cAAc,CAACU,QAAQ,CAAC,MAAM,CAAC;IAExHC,cAAcpB,OAAOqB,kBAAkB;IAEvCC,gBAAgB;IAEhBC,YAAYvB,OAAOwB,oBAAoB;IACvCC,aAAazB,OAAOwB,oBAAoB;IAExC,UAAU;QACRE,QAAQ;QACRhB,OAAOV,OAAO2B,0BAA0B;QACxCC,aAAa5B,OAAO6B,sBAAsB;QAC1CC,iBAAiB9B,OAAO+B,0BAA0B;IACpD;IAEA,iBAAiB;QACfL,QAAQ;QACRhB,OAAOV,OAAOgC,4BAA4B;QAC1CJ,aAAa5B,OAAOiC,wBAAwB;QAC5CH,iBAAiB9B,OAAOkC,4BAA4B;IACtD;AACF;AAEA,MAAMC,wBAAwBtC,WAAW;IACvCuC,SAAS;QACP/B,SAAS;QACTkB,YAAY;QACZE,aAAa;IACf;IACAY,iBAAiB;QACf3B,OAAOV,OAAOgC,4BAA4B;QAC1C,GAAGjC,WAAW6B,WAAW,CAAC5B,OAAOiC,wBAAwB,CAAC;QAC1DH,iBAAiB9B,OAAOsC,qBAAqB;QAC7C,UAAU;YACR5B,OAAOV,OAAOgC,4BAA4B;YAC1C,GAAGjC,WAAW6B,WAAW,CAAC5B,OAAOiC,wBAAwB,CAAC;YAC1DH,iBAAiB9B,OAAOsC,qBAAqB;QAC/C;IACF;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,6BAA6B,CAACC;IACzC,MAAMC,oBAAoBrC;IAC1B,MAAMsC,aAAaP;IAEnBK,MAAMrC,IAAI,CAACwC,SAAS,GAAG7C,aACrBI,mBAAmBC,IAAI,EACvBqC,MAAMH,eAAe,IAAIK,WAAWL,eAAe,EACnDG,MAAMI,KAAK,IAAIF,WAAWN,OAAO,EACjCK,mBACAD,MAAMrC,IAAI,CAACwC,SAAS;IAGtB,OAAOH;AACT,EAAE"}
1
+ {"version":3,"sources":["useCitationStyles.ts"],"sourcesContent":["import {\n makeResetStyles,\n makeStyles,\n mergeClasses,\n shorthands,\n tokens,\n typographyStyles,\n} from '@fluentui/react-components';\nimport type { CitationSlots, CitationState } from './Citation.types';\nimport type { SlotClassNames } from '@fluentui/react-components';\n\nexport const citationClassNames: SlotClassNames<CitationSlots> = {\n root: 'fai-Citation',\n};\n\nconst useCitationBaseClassName = makeResetStyles({\n display: 'inline-flex',\n justifyContent: 'center',\n boxSizing: 'border-box',\n alignItems: 'center',\n ...typographyStyles.caption2Strong,\n\n color: tokens.colorNeutralForeground2,\n border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke2}`,\n\n minWidth: '14px',\n height: '14px',\n verticalAlign: `calc((${typographyStyles.caption2Strong.lineHeight} - ${typographyStyles.caption2Strong.fontSize}) / 2)`,\n\n borderRadius: tokens.borderRadiusMedium,\n\n textDecoration: 'none',\n\n marginLeft: tokens.spacingHorizontalXXS,\n marginRight: tokens.spacingHorizontalXXS,\n\n ':hover': {\n cursor: 'pointer',\n color: tokens.colorBrandForeground2Hover,\n borderColor: tokens.colorBrandStroke2Hover,\n backgroundColor: tokens.colorBrandBackground2Hover,\n },\n\n ':hover:active': {\n cursor: 'pointer',\n color: tokens.colorBrandForeground2Pressed,\n borderColor: tokens.colorBrandStroke2Pressed,\n backgroundColor: tokens.colorBrandBackground2Pressed,\n },\n});\n\nconst useCitationRootStyles = makeStyles({\n isBlock: {\n display: 'flex',\n marginLeft: 0,\n marginRight: 0,\n },\n isPopoverLocked: {\n color: tokens.colorBrandForeground2Pressed,\n ...shorthands.borderColor(tokens.colorBrandStroke2Pressed),\n backgroundColor: tokens.colorBrandBackground2,\n ':hover': {\n color: tokens.colorBrandForeground2Pressed,\n ...shorthands.borderColor(tokens.colorBrandStroke2Pressed),\n backgroundColor: tokens.colorBrandBackground2,\n },\n },\n});\n\n/**\n * Apply styling to the Citation slots based on the state\n */\nexport const useCitationStyles_unstable = (state: CitationState): CitationState => {\n const rootBaseClassName = useCitationBaseClassName();\n const rootStyles = useCitationRootStyles();\n\n state.root.className = mergeClasses(\n citationClassNames.root,\n state.isPopoverLocked && rootStyles.isPopoverLocked,\n state.block && rootStyles.isBlock,\n rootBaseClassName,\n state.root.className,\n );\n\n return state;\n};\n"],"names":["makeResetStyles","makeStyles","mergeClasses","shorthands","tokens","typographyStyles","citationClassNames","root","useCitationBaseClassName","display","justifyContent","boxSizing","alignItems","caption2Strong","color","colorNeutralForeground2","border","strokeWidthThin","colorNeutralStroke2","minWidth","height","verticalAlign","lineHeight","fontSize","borderRadius","borderRadiusMedium","textDecoration","marginLeft","spacingHorizontalXXS","marginRight","cursor","colorBrandForeground2Hover","borderColor","colorBrandStroke2Hover","backgroundColor","colorBrandBackground2Hover","colorBrandForeground2Pressed","colorBrandStroke2Pressed","colorBrandBackground2Pressed","useCitationRootStyles","isBlock","isPopoverLocked","colorBrandBackground2","useCitationStyles_unstable","state","rootBaseClassName","rootStyles","className","block"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SACEA,eAAe,EACfC,UAAU,EACVC,YAAY,EACZC,UAAU,EACVC,MAAM,EACNC,gBAAgB,QACX,6BAA6B;AAIpC,OAAO,MAAMC,qBAAoD;IAC/DC,MAAM;AACR,EAAE;AAEF,MAAMC,2BAA2BR,gBAAgB;IAC/CS,SAAS;IACTC,gBAAgB;IAChBC,WAAW;IACXC,YAAY;IACZ,GAAGP,iBAAiBQ,cAAc;IAElCC,OAAOV,OAAOW,uBAAuB;IACrCC,QAAQ,CAAC,EAAEZ,OAAOa,eAAe,CAAC,OAAO,EAAEb,OAAOc,mBAAmB,CAAC,CAAC;IAEvEC,UAAU;IACVC,QAAQ;IACRC,eAAe,CAAC,MAAM,EAAEhB,iBAAiBQ,cAAc,CAACS,UAAU,CAAC,GAAG,EAAEjB,iBAAiBQ,cAAc,CAACU,QAAQ,CAAC,MAAM,CAAC;IAExHC,cAAcpB,OAAOqB,kBAAkB;IAEvCC,gBAAgB;IAEhBC,YAAYvB,OAAOwB,oBAAoB;IACvCC,aAAazB,OAAOwB,oBAAoB;IAExC,UAAU;QACRE,QAAQ;QACRhB,OAAOV,OAAO2B,0BAA0B;QACxCC,aAAa5B,OAAO6B,sBAAsB;QAC1CC,iBAAiB9B,OAAO+B,0BAA0B;IACpD;IAEA,iBAAiB;QACfL,QAAQ;QACRhB,OAAOV,OAAOgC,4BAA4B;QAC1CJ,aAAa5B,OAAOiC,wBAAwB;QAC5CH,iBAAiB9B,OAAOkC,4BAA4B;IACtD;AACF;AAEA,MAAMC,wBAAwBtC,WAAW;IACvCuC,SAAS;QACP/B,SAAS;QACTkB,YAAY;QACZE,aAAa;IACf;IACAY,iBAAiB;QACf3B,OAAOV,OAAOgC,4BAA4B;QAC1C,GAAGjC,WAAW6B,WAAW,CAAC5B,OAAOiC,wBAAwB,CAAC;QAC1DH,iBAAiB9B,OAAOsC,qBAAqB;QAC7C,UAAU;YACR5B,OAAOV,OAAOgC,4BAA4B;YAC1C,GAAGjC,WAAW6B,WAAW,CAAC5B,OAAOiC,wBAAwB,CAAC;YAC1DH,iBAAiB9B,OAAOsC,qBAAqB;QAC/C;IACF;AACF;AAEA;;CAEC,GACD,OAAO,MAAMC,6BAA6B,CAACC;IACzC,MAAMC,oBAAoBrC;IAC1B,MAAMsC,aAAaP;IAEnBK,MAAMrC,IAAI,CAACwC,SAAS,GAAG7C,aACrBI,mBAAmBC,IAAI,EACvBqC,MAAMH,eAAe,IAAIK,WAAWL,eAAe,EACnDG,MAAMI,KAAK,IAAIF,WAAWN,OAAO,EACjCK,mBACAD,MAAMrC,IAAI,CAACwC,SAAS;IAGtB,OAAOH;AACT,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["Reference.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useReference_unstable } from './useReference';\nimport { renderReference_unstable } from './renderReference';\nimport { useReferenceStyles_unstable } from './useReferenceStyles';\nimport type { ReferenceProps } from './Reference.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Reference component - TODO: add more docs\nexport const Reference: ForwardRefComponent<ReferenceProps> = React.forwardRef((props, ref) => {\n const state = useReference_unstable(props, ref);\n\n useReferenceStyles_unstable(state);\n useCustomStyleHook('useReferenceStyles')(state);\n\n return renderReference_unstable(state);\n});\n\nReference.displayName = 'Reference';\n"],"names":["React","useReference_unstable","renderReference_unstable","useReferenceStyles_unstable","useCustomStyleHook","Reference","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,qBAAqB,QAAQ,iBAAiB;AACvD,SAASC,wBAAwB,QAAQ,oBAAoB;AAC7D,SAASC,2BAA2B,QAAQ,uBAAuB;AAGnE,SAASC,kBAAkB,QAAQ,mCAAmC;AAEtE,4CAA4C;AAC5C,OAAO,MAAMC,0BAAiDL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IACrF,MAAMC,QAAQR,sBAAsBM,OAAOC;IAE3CL,4BAA4BM;IAC5BL,mBAAmB,sBAAsBK;IAEzC,OAAOP,yBAAyBO;AAClC,GAAG;AAEHJ,UAAUK,WAAW,GAAG"}
1
+ {"version":3,"sources":["Reference.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useReference_unstable } from './useReference';\nimport { renderReference_unstable } from './renderReference';\nimport { useReferenceStyles_unstable } from './useReferenceStyles';\nimport type { ReferenceProps } from './Reference.types';\nimport type { ForwardRefComponent } from '@fluentui/react-components';\nimport { useCustomStyleHook } from '@fluentui-copilot/react-provider';\n\n// Reference component - TODO: add more docs\nexport const Reference: ForwardRefComponent<ReferenceProps> = React.forwardRef((props, ref) => {\n const state = useReference_unstable(props, ref);\n\n useReferenceStyles_unstable(state);\n useCustomStyleHook('useReferenceStyles')(state);\n\n return renderReference_unstable(state);\n});\n\nReference.displayName = 'Reference';\n"],"names":["React","useReference_unstable","renderReference_unstable","useReferenceStyles_unstable","useCustomStyleHook","Reference","forwardRef","props","ref","state","displayName"],"rangeMappings":";;;;;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,qBAAqB,QAAQ,iBAAiB;AACvD,SAASC,wBAAwB,QAAQ,oBAAoB;AAC7D,SAASC,2BAA2B,QAAQ,uBAAuB;AAGnE,SAASC,kBAAkB,QAAQ,mCAAmC;AAEtE,4CAA4C;AAC5C,OAAO,MAAMC,0BAAiDL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IACrF,MAAMC,QAAQR,sBAAsBM,OAAOC;IAE3CL,4BAA4BM;IAC5BL,mBAAmB,sBAAsBK;IAEzC,OAAOP,yBAAyBO;AAClC,GAAG;AAEHJ,UAAUK,WAAW,GAAG"}
@@ -1,2 +1,4 @@
1
- export {};
1
+ /**
2
+ * State used in rendering Reference
3
+ */export {};
2
4
  //# sourceMappingURL=Reference.types.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["Reference.types.ts"],"sourcesContent":["import type { CopilotMode } from '@fluentui-copilot/react-provider';\nimport type { Button, ComponentProps, ComponentState, Slot } from '@fluentui/react-components';\n\nexport type ReferenceSlots = {\n /**\n * The root slot.\n */\n root: NonNullable<Slot<'div'>>;\n\n /**\n * Citation slot. Displays a `Citation`. Set the `null` to hide the citation.\n */\n citation: Slot<'div'>;\n\n /**\n * Media slot. Used to display Avatars, Icons, etc.\n */\n media: Slot<'div'>;\n\n /**\n * Actions slot.\n */\n actions: Slot<'div'>;\n\n /**\n * Label slot. Primary description of the reference.\n */\n label: NonNullable<Slot<'div'>>;\n\n /**\n * Sensitivity slot. Used to display a `SensitivityLabel`.\n */\n sensitivity: Slot<'span'>;\n\n /**\n * Metadata slot. Container for `primaryText`, `secondaryText`, `tertiaryText` and `icon`.\n */\n metadata: NonNullable<Slot<'div'>>;\n\n /**\n * Primary text slot. First displayed metadata text.\n */\n primaryText: Slot<'span'>;\n\n /**\n * Secondary text slot. Second displayed metadata text.\n */\n secondaryText: Slot<'span'>;\n\n /**\n * Tertiary text slot. Third displayed metadata text.\n */\n tertiaryText: Slot<'span'>;\n\n /**\n * Icon slot. Icon displayed in metadata area.\n */\n icon: Slot<'span'>;\n\n /**\n * Content slot.\n */\n content: NonNullable<Slot<'div'>>;\n\n /**\n * Details button slot. Used to expand/collapse the reference.\n */\n detailsButton: Slot<typeof Button>;\n};\n\n/**\n * Reference Props\n */\nexport type ReferenceProps = ComponentProps<Partial<ReferenceSlots>> &\n CopilotMode & {\n /**\n * Numeric index associated with `Citation`.\n */\n index: number;\n\n /**\n * HREF back to the `Citation` this `Reference` is associated with.\n */\n citationHref?: string;\n\n /**\n * Unique ID associated with this `Reference`.\n */\n referenceId?: string;\n\n /**\n * Text snippet from the reference source.\n */\n excerpt?: string;\n\n /**\n * @deprecated Inline layout is the only one that is available, use `Preview` component instead for an equivalent to a `Reference` with a popover layout inside of a `Popover`.\n */\n layout?: 'inline' | 'popover';\n };\n\n/**\n * State used in rendering Reference\n */\nexport type ReferenceState = ComponentState<ReferenceSlots> &\n Required<Pick<ReferenceProps, 'mode' | 'layout' | 'index'>> & {\n /**\n * State used to renderer the `Reference` in an expanded state.\n */\n isExpanded: boolean;\n };\n"],"names":[],"mappings":"AAAA,WA8GI"}
1
+ {"version":3,"sources":["Reference.types.ts"],"sourcesContent":["import type { CopilotMode } from '@fluentui-copilot/react-provider';\nimport type { Button, ComponentProps, ComponentState, Slot } from '@fluentui/react-components';\n\nexport type ReferenceSlots = {\n /**\n * The root slot.\n */\n root: NonNullable<Slot<'div'>>;\n\n /**\n * Citation slot. Displays a `Citation`. Set the `null` to hide the citation.\n */\n citation: Slot<'div'>;\n\n /**\n * Media slot. Used to display Avatars, Icons, etc.\n */\n media: Slot<'div'>;\n\n /**\n * Actions slot.\n */\n actions: Slot<'div'>;\n\n /**\n * Label slot. Primary description of the reference.\n */\n label: NonNullable<Slot<'div'>>;\n\n /**\n * Sensitivity slot. Used to display a `SensitivityLabel`.\n */\n sensitivity: Slot<'span'>;\n\n /**\n * Metadata slot. Container for `primaryText`, `secondaryText`, `tertiaryText` and `icon`.\n */\n metadata: NonNullable<Slot<'div'>>;\n\n /**\n * Primary text slot. First displayed metadata text.\n */\n primaryText: Slot<'span'>;\n\n /**\n * Secondary text slot. Second displayed metadata text.\n */\n secondaryText: Slot<'span'>;\n\n /**\n * Tertiary text slot. Third displayed metadata text.\n */\n tertiaryText: Slot<'span'>;\n\n /**\n * Icon slot. Icon displayed in metadata area.\n */\n icon: Slot<'span'>;\n\n /**\n * Content slot.\n */\n content: NonNullable<Slot<'div'>>;\n\n /**\n * Details button slot. Used to expand/collapse the reference.\n */\n detailsButton: Slot<typeof Button>;\n};\n\n/**\n * Reference Props\n */\nexport type ReferenceProps = ComponentProps<Partial<ReferenceSlots>> &\n CopilotMode & {\n /**\n * Numeric index associated with `Citation`.\n */\n index: number;\n\n /**\n * HREF back to the `Citation` this `Reference` is associated with.\n */\n citationHref?: string;\n\n /**\n * Unique ID associated with this `Reference`.\n */\n referenceId?: string;\n\n /**\n * Text snippet from the reference source.\n */\n excerpt?: string;\n\n /**\n * @deprecated Inline layout is the only one that is available, use `Preview` component instead for an equivalent to a `Reference` with a popover layout inside of a `Popover`.\n */\n layout?: 'inline' | 'popover';\n };\n\n/**\n * State used in rendering Reference\n */\nexport type ReferenceState = ComponentState<ReferenceSlots> &\n Required<Pick<ReferenceProps, 'mode' | 'layout' | 'index'>> & {\n /**\n * State used to renderer the `Reference` in an expanded state.\n */\n isExpanded: boolean;\n };\n"],"names":[],"rangeMappings":";;","mappings":"AAqGA;;CAEC,GACD,WAMI"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"sourcesContent":["export * from './Reference';\nexport * from './Reference.types';\nexport * from './renderReference';\nexport * from './useReference';\nexport * from './useReferenceStyles';\n"],"names":[],"mappings":"AAAA,cAAc,cAAc;AAC5B,cAAc,oBAAoB;AAClC,cAAc,oBAAoB;AAClC,cAAc,iBAAiB;AAC/B,cAAc,uBAAuB"}
1
+ {"version":3,"sources":["index.ts"],"sourcesContent":["export * from './Reference';\nexport * from './Reference.types';\nexport * from './renderReference';\nexport * from './useReference';\nexport * from './useReferenceStyles';\n"],"names":[],"rangeMappings":";;;;","mappings":"AAAA,cAAc,cAAc;AAC5B,cAAc,oBAAoB;AAClC,cAAc,oBAAoB;AAClC,cAAc,iBAAiB;AAC/B,cAAc,uBAAuB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-components';\n\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\n\n/**\n * Render the final JSX of Reference\n */\nexport const renderReference_unstable = (state: ReferenceState) => {\n assertSlots<ReferenceSlots>(state);\n\n return (\n <state.root>\n {state.citation && <state.citation />}\n {state.media && <state.media />}\n <state.label />\n {state.actions && (\n <state.actions>\n {state.actions.children}\n {state.detailsButton && <state.detailsButton />}\n </state.actions>\n )}\n {state.sensitivity && <state.sensitivity />}\n <state.metadata>\n {state.primaryText && <state.primaryText />}\n {state.secondaryText && <state.secondaryText />}\n {state.tertiaryText && <state.tertiaryText />}\n {state.icon && <state.icon />}\n {state.metadata.children}\n </state.metadata>\n <state.content />\n </state.root>\n );\n};\n"],"names":["assertSlots","renderReference_unstable","state","root","citation","media","label","actions","children","detailsButton","sensitivity","metadata","primaryText","secondaryText","tertiaryText","icon","content"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,6BAA6B;AAIzD;;CAEC,GACD,OAAO,MAAMC,2BAA2B,CAACC;IACvCF,YAA4BE;IAE5B,qBACE,MAACA,MAAMC,IAAI;;YACRD,MAAME,QAAQ,kBAAI,KAACF,MAAME,QAAQ;YACjCF,MAAMG,KAAK,kBAAI,KAACH,MAAMG,KAAK;0BAC5B,KAACH,MAAMI,KAAK;YACXJ,MAAMK,OAAO,kBACZ,MAACL,MAAMK,OAAO;;oBACXL,MAAMK,OAAO,CAACC,QAAQ;oBACtBN,MAAMO,aAAa,kBAAI,KAACP,MAAMO,aAAa;;;YAG/CP,MAAMQ,WAAW,kBAAI,KAACR,MAAMQ,WAAW;0BACxC,MAACR,MAAMS,QAAQ;;oBACZT,MAAMU,WAAW,kBAAI,KAACV,MAAMU,WAAW;oBACvCV,MAAMW,aAAa,kBAAI,KAACX,MAAMW,aAAa;oBAC3CX,MAAMY,YAAY,kBAAI,KAACZ,MAAMY,YAAY;oBACzCZ,MAAMa,IAAI,kBAAI,KAACb,MAAMa,IAAI;oBACzBb,MAAMS,QAAQ,CAACH,QAAQ;;;0BAE1B,KAACN,MAAMc,OAAO;;;AAGpB,EAAE"}
1
+ {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-components';\n\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\n\n/**\n * Render the final JSX of Reference\n */\nexport const renderReference_unstable = (state: ReferenceState) => {\n assertSlots<ReferenceSlots>(state);\n\n return (\n <state.root>\n {state.citation && <state.citation />}\n {state.media && <state.media />}\n <state.label />\n {state.actions && (\n <state.actions>\n {state.actions.children}\n {state.detailsButton && <state.detailsButton />}\n </state.actions>\n )}\n {state.sensitivity && <state.sensitivity />}\n <state.metadata>\n {state.primaryText && <state.primaryText />}\n {state.secondaryText && <state.secondaryText />}\n {state.tertiaryText && <state.tertiaryText />}\n {state.icon && <state.icon />}\n {state.metadata.children}\n </state.metadata>\n <state.content />\n </state.root>\n );\n};\n"],"names":["assertSlots","renderReference_unstable","state","root","citation","media","label","actions","children","detailsButton","sensitivity","metadata","primaryText","secondaryText","tertiaryText","icon","content"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,6BAA6B;AAIzD;;CAEC,GACD,OAAO,MAAMC,2BAA2B,CAACC;IACvCF,YAA4BE;IAE5B,qBACE,MAACA,MAAMC,IAAI;;YACRD,MAAME,QAAQ,kBAAI,KAACF,MAAME,QAAQ;YACjCF,MAAMG,KAAK,kBAAI,KAACH,MAAMG,KAAK;0BAC5B,KAACH,MAAMI,KAAK;YACXJ,MAAMK,OAAO,kBACZ,MAACL,MAAMK,OAAO;;oBACXL,MAAMK,OAAO,CAACC,QAAQ;oBACtBN,MAAMO,aAAa,kBAAI,KAACP,MAAMO,aAAa;;;YAG/CP,MAAMQ,WAAW,kBAAI,KAACR,MAAMQ,WAAW;0BACxC,MAACR,MAAMS,QAAQ;;oBACZT,MAAMU,WAAW,kBAAI,KAACV,MAAMU,WAAW;oBACvCV,MAAMW,aAAa,kBAAI,KAACX,MAAMW,aAAa;oBAC3CX,MAAMY,YAAY,kBAAI,KAACZ,MAAMY,YAAY;oBACzCZ,MAAMa,IAAI,kBAAI,KAACb,MAAMa,IAAI;oBACzBb,MAAMS,QAAQ,CAACH,QAAQ;;;0BAE1B,KAACN,MAAMc,OAAO;;;AAGpB,EAAE"}
@@ -1,9 +1,9 @@
1
1
  import * as React from 'react';
2
- import { Button, Caption1, getNativeElementProps, mergeCallbacks, mergeClasses, slot, useId, usePopoverContext_unstable as usePopoverContext } from '@fluentui/react-components';
2
+ import { Button, Caption1, getIntrinsicElementProps, mergeCallbacks, mergeClasses, slot, useId, usePopoverContext_unstable as usePopoverContext } from '@fluentui/react-components';
3
3
  import { ChevronDown24Regular, ChevronUp24Regular, ChevronDown16Regular, ChevronUp16Regular } from '@fluentui/react-icons';
4
4
  import { referenceExtraClassNames } from './useReferenceStyles';
5
5
  import { Citation } from '../Citation';
6
- import { useReferenceGroupSetOpen } from '../../context/ReferenceGroupContext';
6
+ import { useReferenceGroupSetOpen } from '../../contexts/ReferenceGroupContext';
7
7
  import { useCopilotMode } from '@fluentui-copilot/react-provider';
8
8
  /**
9
9
  * Create the state required to render Reference.
@@ -96,7 +96,7 @@ export const useReference_unstable = (props, ref) => {
96
96
  icon: 'span',
97
97
  detailsButton: Button
98
98
  },
99
- root: slot.always(getNativeElementProps('div', {
99
+ root: slot.always(getIntrinsicElementProps('div', {
100
100
  ref,
101
101
  id: referenceId,
102
102
  ...groupSemantics,