@fluentui-copilot/react-reference 0.0.0-nightly-20251106-0406-702b7b06.1 → 0.0.0-nightly-20251107-0407-fc4e98b2.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.
package/CHANGELOG.json CHANGED
@@ -2,9 +2,9 @@
2
2
  "name": "@fluentui-copilot/react-reference",
3
3
  "entries": [
4
4
  {
5
- "date": "Thu, 06 Nov 2025 04:13:05 GMT",
6
- "tag": "@fluentui-copilot/react-reference_v0.0.0-nightly-20251106-0406-702b7b06.1",
7
- "version": "0.0.0-nightly-20251106-0406-702b7b06.1",
5
+ "date": "Fri, 07 Nov 2025 04:14:11 GMT",
6
+ "tag": "@fluentui-copilot/react-reference_v0.0.0-nightly-20251107-0407-fc4e98b2.1",
7
+ "version": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
8
8
  "comments": {
9
9
  "prerelease": [
10
10
  {
package/CHANGELOG.md CHANGED
@@ -1,13 +1,13 @@
1
1
  # Change Log - @fluentui-copilot/react-reference
2
2
 
3
- This log was last generated on Thu, 06 Nov 2025 04:13:05 GMT and should not be manually modified.
3
+ This log was last generated on Fri, 07 Nov 2025 04:14:11 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
- ## [0.0.0-nightly-20251106-0406-702b7b06.1](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-reference_v0.0.0-nightly-20251106-0406-702b7b06.1)
7
+ ## [0.0.0-nightly-20251107-0407-fc4e98b2.1](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-reference_v0.0.0-nightly-20251107-0407-fc4e98b2.1)
8
8
 
9
- Thu, 06 Nov 2025 04:13:05 GMT
10
- [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-reference_v0.16.6..@fluentui-copilot/react-reference_v0.0.0-nightly-20251106-0406-702b7b06.1)
9
+ Fri, 07 Nov 2025 04:14:11 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-reference_v0.16.6..@fluentui-copilot/react-reference_v0.0.0-nightly-20251107-0407-fc4e98b2.1)
11
11
 
12
12
  ### Changes
13
13
 
package/dist/index.d.ts CHANGED
@@ -8,8 +8,7 @@ import type { DesignVersion } from '@fluentui-copilot/react-provider';
8
8
  import { FC } from 'react';
9
9
  import type { ForwardRefComponent } from '@fluentui/react-components';
10
10
  import { ForwardRefComponent as ForwardRefComponent_2 } from '@fluentui/react-utilities';
11
- import type { JSXElement } from '@fluentui/react-components';
12
- import { JSXElement as JSXElement_2 } from '@fluentui/react-utilities';
11
+ import { JSXElement } from '@fluentui/react-utilities';
13
12
  import type { PreviewHeaderProps } from '@fluentui-copilot/react-preview';
14
13
  import type { PreviewMetadataProps } from '@fluentui-copilot/react-preview';
15
14
  import type { PreviewProps } from '@fluentui-copilot/react-preview';
@@ -264,7 +263,7 @@ export declare const renderReference_unstable: (state: ReferenceState) => JSXEle
264
263
  export declare const renderReferenceList_unstable: (state: ReferenceListState, contextValues: ReferenceListContextValues) => JSXElement;
265
264
 
266
265
  /** @deprecated use renderReferenceList_unstable */
267
- export declare const renderReferenceListV2_unstable: (state: ReferenceListState, contextValues: ReferenceListContextValues) => JSXElement_2;
266
+ export declare const renderReferenceListV2_unstable: (state: ReferenceListState, contextValues: ReferenceListContextValues) => JSXElement;
268
267
 
269
268
  /**
270
269
  * Render the final JSX of ReferenceOverflowButton
@@ -272,7 +271,7 @@ export declare const renderReferenceListV2_unstable: (state: ReferenceListState,
272
271
  export declare const renderReferenceOverflowButton_unstable: (state: ReferenceOverflowButtonState) => JSXElement | null;
273
272
 
274
273
  /** @deprecated use renderReference_unstable */
275
- export declare const renderReferenceV2_unstable: (state: ReferenceState) => JSXElement_2;
274
+ export declare const renderReferenceV2_unstable: (state: ReferenceState) => JSXElement;
276
275
 
277
276
  /**
278
277
  * Create the state required to render Citation.
@@ -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';\nimport type { JSXElement } from '@fluentui/react-components';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState): JSXElement => {\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;AAGzD;;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';\nimport type { JSXElement } from '@fluentui/react-utilities';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState): JSXElement => {\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;AAGzD;;CAEC,GACD,OAAO,MAAMC,0BAA0B,CAACC;IACtCF,YAA2BE;IAE3B,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\nimport type { JSXElement } from '@fluentui/react-components';\n\nexport const renderReference_unstable = (state: ReferenceState): JSXElement => {\n assertSlots<ReferenceSlots>(state);\n\n const { id, shouldUseOverflow } = state;\n\n const reference = (\n <state.root>\n {state.citation && <state.citation />}\n {state.divider && <state.divider />}\n {state.content && (\n <state.content>\n {state.graphic && <state.graphic />}\n {state.root.children}\n </state.content>\n )}\n </state.root>\n );\n\n return shouldUseOverflow ? (\n <OverflowItem key={id} id={id}>\n {reference}\n </OverflowItem>\n ) : (\n reference\n );\n};\n"],"names":["OverflowItem","assertSlots","renderReference_unstable","state","id","shouldUseOverflow","reference","root","citation","divider","content","graphic","children"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,YAAY,EAAEC,WAAW,QAAQ,6BAA6B;AAIvE,OAAO,MAAMC,2BAA2B,CAACC;IACvCF,YAA4BE;IAE5B,MAAM,EAAEC,EAAE,EAAEC,iBAAiB,EAAE,GAAGF;IAElC,MAAMG,0BACJ,MAACH,MAAMI,IAAI;;YACRJ,MAAMK,QAAQ,kBAAI,KAACL,MAAMK,QAAQ;YACjCL,MAAMM,OAAO,kBAAI,KAACN,MAAMM,OAAO;YAC/BN,MAAMO,OAAO,kBACZ,MAACP,MAAMO,OAAO;;oBACXP,MAAMQ,OAAO,kBAAI,KAACR,MAAMQ,OAAO;oBAC/BR,MAAMI,IAAI,CAACK,QAAQ;;;;;IAM5B,OAAOP,kCACL,KAACL;QAAsBI,IAAIA;kBACxBE;OADgBF,MAInBE;AAEJ,EAAE"}
1
+ {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\nexport const renderReference_unstable = (state: ReferenceState): JSXElement => {\n assertSlots<ReferenceSlots>(state);\n\n const { id, shouldUseOverflow } = state;\n\n const reference = (\n <state.root>\n {state.citation && <state.citation />}\n {state.divider && <state.divider />}\n {state.content && (\n <state.content>\n {state.graphic && <state.graphic />}\n {state.root.children}\n </state.content>\n )}\n </state.root>\n );\n\n return shouldUseOverflow ? (\n <OverflowItem key={id} id={id}>\n {reference}\n </OverflowItem>\n ) : (\n reference\n );\n};\n"],"names":["OverflowItem","assertSlots","renderReference_unstable","state","id","shouldUseOverflow","reference","root","citation","divider","content","graphic","children"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,YAAY,EAAEC,WAAW,QAAQ,6BAA6B;AAIvE,OAAO,MAAMC,2BAA2B,CAACC;IACvCF,YAA4BE;IAE5B,MAAM,EAAEC,EAAE,EAAEC,iBAAiB,EAAE,GAAGF;IAElC,MAAMG,0BACJ,MAACH,MAAMI,IAAI;;YACRJ,MAAMK,QAAQ,kBAAI,KAACL,MAAMK,QAAQ;YACjCL,MAAMM,OAAO,kBAAI,KAACN,MAAMM,OAAO;YAC/BN,MAAMO,OAAO,kBACZ,MAACP,MAAMO,OAAO;;oBACXP,MAAMQ,OAAO,kBAAI,KAACR,MAAMQ,OAAO;oBAC/BR,MAAMI,IAAI,CAACK,QAAQ;;;;;IAM5B,OAAOP,kCACL,KAACL;QAAsBI,IAAIA;kBACxBE;OADgBF,MAInBE;AAEJ,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useReference.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { useReferenceListContext_unstable } from '../../contexts/referenceListContext';\nimport { referenceExtraClassNames } from './useReferenceStyles.styles';\nimport type { ReferenceProps, ReferenceState, ReferenceSlots } from './Reference.types';\nimport { useDesignVersion } from '@fluentui-copilot/react-provider';\nimport type { JSXIntrinsicElement } from '@fluentui/react-components';\n/**\n * Create the state required to render Reference.\n *\n * The returned state can be modified with hooks such as useReferenceStyles_unstable,\n * before being passed to renderReference_unstable.\n *\n * @param props - props from this instance of Reference\n * @param ref - reference to root HTMLElement of Reference\n */\nexport const useReference_unstable = (\n props: ReferenceProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): ReferenceState => {\n const { as, children, id } = props;\n\n const designVersion = useDesignVersion(props.designVersion);\n\n const shouldUseOverflow = useReferenceListContext_unstable(ctx => ctx.shouldUseOverflow);\n\n const referenceId = useId('reference-', id);\n\n const elementType = as || ((props as JSXIntrinsicElement<'a'>).href ? 'a' : 'button');\n const propsWithAssignedAs = {\n type: elementType === 'button' ? 'button' : undefined,\n ...props,\n as: elementType,\n id: referenceId,\n };\n\n const citation = slot.optional(props.citation, { elementType: 'span' });\n const graphic = slot.optional(props.graphic, { elementType: 'span' });\n const content = slot.optional(props.content as ReferenceSlots['content'], {\n elementType: 'span',\n renderByDefault: graphic !== undefined || !!children,\n });\n const divider = slot.optional(props.divider, {\n elementType: 'span',\n renderByDefault: citation !== undefined && content !== undefined,\n });\n\n const state: ReferenceState = {\n designVersion,\n id: referenceId,\n shouldUseOverflow,\n\n components: {\n root: elementType,\n citation: 'span',\n divider: 'span',\n graphic: 'span',\n content: 'span',\n },\n\n root: slot.always(\n getIntrinsicElementProps(\n elementType,\n {\n ref,\n ...propsWithAssignedAs,\n },\n // `content` is a slot and it's type clashes with the HTMLElement `content` attribute\n ['content'],\n ) as ReferenceSlots['root'],\n { elementType },\n ),\n citation,\n divider,\n content,\n graphic,\n };\n\n if (state.graphic && React.isValidElement<HTMLElement>(state.graphic.children)) {\n state.graphic.children = React.cloneElement(state.graphic.children, {\n className: mergeClasses(state.graphic.children.props.className, referenceExtraClassNames.graphicChild),\n });\n }\n\n return state;\n};\n"],"names":["React","getIntrinsicElementProps","mergeClasses","slot","useId","useReferenceListContext_unstable","referenceExtraClassNames","useDesignVersion","useReference_unstable","props","ref","as","children","id","designVersion","shouldUseOverflow","ctx","referenceId","elementType","href","propsWithAssignedAs","type","undefined","citation","optional","graphic","content","renderByDefault","divider","state","components","root","always","isValidElement","cloneElement","className","graphicChild"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,wBAAwB,EAAEC,YAAY,EAAEC,IAAI,EAAEC,KAAK,QAAQ,6BAA6B;AACjG,SAASC,gCAAgC,QAAQ,sCAAsC;AACvF,SAASC,wBAAwB,QAAQ,8BAA8B;AAEvE,SAASC,gBAAgB,QAAQ,mCAAmC;AAEpE;;;;;;;;CAQC,GACD,OAAO,MAAMC,wBAAwB,CACnCC,OACAC;IAEA,MAAM,EAAEC,EAAE,EAAEC,QAAQ,EAAEC,EAAE,EAAE,GAAGJ;IAE7B,MAAMK,gBAAgBP,iBAAiBE,MAAMK,aAAa;IAE1D,MAAMC,oBAAoBV,iCAAiCW,CAAAA,MAAOA,IAAID,iBAAiB;IAEvF,MAAME,cAAcb,MAAM,cAAcS;IAExC,MAAMK,cAAcP,MAAO,CAAA,AAACF,MAAmCU,IAAI,GAAG,MAAM,QAAO;IACnF,MAAMC,sBAAsB;QAC1BC,MAAMH,gBAAgB,WAAW,WAAWI;QAC5C,GAAGb,KAAK;QACRE,IAAIO;QACJL,IAAII;IACN;IAEA,MAAMM,WAAWpB,KAAKqB,QAAQ,CAACf,MAAMc,QAAQ,EAAE;QAAEL,aAAa;IAAO;IACrE,MAAMO,UAAUtB,KAAKqB,QAAQ,CAACf,MAAMgB,OAAO,EAAE;QAAEP,aAAa;IAAO;IACnE,MAAMQ,UAAUvB,KAAKqB,QAAQ,CAACf,MAAMiB,OAAO,EAA+B;QACxER,aAAa;QACbS,iBAAiBF,YAAYH,aAAa,CAAC,CAACV;IAC9C;IACA,MAAMgB,UAAUzB,KAAKqB,QAAQ,CAACf,MAAMmB,OAAO,EAAE;QAC3CV,aAAa;QACbS,iBAAiBJ,aAAaD,aAAaI,YAAYJ;IACzD;IAEA,MAAMO,QAAwB;QAC5Bf;QACAD,IAAII;QACJF;QAEAe,YAAY;YACVC,MAAMb;YACNK,UAAU;YACVK,SAAS;YACTH,SAAS;YACTC,SAAS;QACX;QAEAK,MAAM5B,KAAK6B,MAAM,CACf/B,yBACEiB,aACA;YACER;YACA,GAAGU,mBAAmB;QACxB,GACA,qFAAqF;QACrF;YAAC;SAAU,GAEb;YAAEF;QAAY;QAEhBK;QACAK;QACAF;QACAD;IACF;IAEA,IAAII,MAAMJ,OAAO,IAAIzB,MAAMiC,cAAc,CAAcJ,MAAMJ,OAAO,CAACb,QAAQ,GAAG;QAC9EiB,MAAMJ,OAAO,CAACb,QAAQ,GAAGZ,MAAMkC,YAAY,CAACL,MAAMJ,OAAO,CAACb,QAAQ,EAAE;YAClEuB,WAAWjC,aAAa2B,MAAMJ,OAAO,CAACb,QAAQ,CAACH,KAAK,CAAC0B,SAAS,EAAE7B,yBAAyB8B,YAAY;QACvG;IACF;IAEA,OAAOP;AACT,EAAE"}
1
+ {"version":3,"sources":["useReference.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { useReferenceListContext_unstable } from '../../contexts/referenceListContext';\nimport { referenceExtraClassNames } from './useReferenceStyles.styles';\nimport type { ReferenceProps, ReferenceState, ReferenceSlots } from './Reference.types';\nimport { useDesignVersion } from '@fluentui-copilot/react-provider';\nimport type { JSXIntrinsicElement } from '@fluentui/react-utilities';\n/**\n * Create the state required to render Reference.\n *\n * The returned state can be modified with hooks such as useReferenceStyles_unstable,\n * before being passed to renderReference_unstable.\n *\n * @param props - props from this instance of Reference\n * @param ref - reference to root HTMLElement of Reference\n */\nexport const useReference_unstable = (\n props: ReferenceProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): ReferenceState => {\n const { as, children, id } = props;\n\n const designVersion = useDesignVersion(props.designVersion);\n\n const shouldUseOverflow = useReferenceListContext_unstable(ctx => ctx.shouldUseOverflow);\n\n const referenceId = useId('reference-', id);\n\n const elementType = as || ((props as JSXIntrinsicElement<'a'>).href ? 'a' : 'button');\n const propsWithAssignedAs = {\n type: elementType === 'button' ? 'button' : undefined,\n ...props,\n as: elementType,\n id: referenceId,\n };\n\n const citation = slot.optional(props.citation, { elementType: 'span' });\n const graphic = slot.optional(props.graphic, { elementType: 'span' });\n const content = slot.optional(props.content as ReferenceSlots['content'], {\n elementType: 'span',\n renderByDefault: graphic !== undefined || !!children,\n });\n const divider = slot.optional(props.divider, {\n elementType: 'span',\n renderByDefault: citation !== undefined && content !== undefined,\n });\n\n const state: ReferenceState = {\n designVersion,\n id: referenceId,\n shouldUseOverflow,\n\n components: {\n root: elementType,\n citation: 'span',\n divider: 'span',\n graphic: 'span',\n content: 'span',\n },\n\n root: slot.always(\n getIntrinsicElementProps(\n elementType,\n {\n ref,\n ...propsWithAssignedAs,\n },\n // `content` is a slot and it's type clashes with the HTMLElement `content` attribute\n ['content'],\n ) as ReferenceSlots['root'],\n { elementType },\n ),\n citation,\n divider,\n content,\n graphic,\n };\n\n if (state.graphic && React.isValidElement<HTMLElement>(state.graphic.children)) {\n state.graphic.children = React.cloneElement(state.graphic.children, {\n className: mergeClasses(state.graphic.children.props.className, referenceExtraClassNames.graphicChild),\n });\n }\n\n return state;\n};\n"],"names":["React","getIntrinsicElementProps","mergeClasses","slot","useId","useReferenceListContext_unstable","referenceExtraClassNames","useDesignVersion","useReference_unstable","props","ref","as","children","id","designVersion","shouldUseOverflow","ctx","referenceId","elementType","href","propsWithAssignedAs","type","undefined","citation","optional","graphic","content","renderByDefault","divider","state","components","root","always","isValidElement","cloneElement","className","graphicChild"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,wBAAwB,EAAEC,YAAY,EAAEC,IAAI,EAAEC,KAAK,QAAQ,6BAA6B;AACjG,SAASC,gCAAgC,QAAQ,sCAAsC;AACvF,SAASC,wBAAwB,QAAQ,8BAA8B;AAEvE,SAASC,gBAAgB,QAAQ,mCAAmC;AAEpE;;;;;;;;CAQC,GACD,OAAO,MAAMC,wBAAwB,CACnCC,OACAC;IAEA,MAAM,EAAEC,EAAE,EAAEC,QAAQ,EAAEC,EAAE,EAAE,GAAGJ;IAE7B,MAAMK,gBAAgBP,iBAAiBE,MAAMK,aAAa;IAE1D,MAAMC,oBAAoBV,iCAAiCW,CAAAA,MAAOA,IAAID,iBAAiB;IAEvF,MAAME,cAAcb,MAAM,cAAcS;IAExC,MAAMK,cAAcP,MAAO,CAAA,AAACF,MAAmCU,IAAI,GAAG,MAAM,QAAO;IACnF,MAAMC,sBAAsB;QAC1BC,MAAMH,gBAAgB,WAAW,WAAWI;QAC5C,GAAGb,KAAK;QACRE,IAAIO;QACJL,IAAII;IACN;IAEA,MAAMM,WAAWpB,KAAKqB,QAAQ,CAACf,MAAMc,QAAQ,EAAE;QAAEL,aAAa;IAAO;IACrE,MAAMO,UAAUtB,KAAKqB,QAAQ,CAACf,MAAMgB,OAAO,EAAE;QAAEP,aAAa;IAAO;IACnE,MAAMQ,UAAUvB,KAAKqB,QAAQ,CAACf,MAAMiB,OAAO,EAA+B;QACxER,aAAa;QACbS,iBAAiBF,YAAYH,aAAa,CAAC,CAACV;IAC9C;IACA,MAAMgB,UAAUzB,KAAKqB,QAAQ,CAACf,MAAMmB,OAAO,EAAE;QAC3CV,aAAa;QACbS,iBAAiBJ,aAAaD,aAAaI,YAAYJ;IACzD;IAEA,MAAMO,QAAwB;QAC5Bf;QACAD,IAAII;QACJF;QAEAe,YAAY;YACVC,MAAMb;YACNK,UAAU;YACVK,SAAS;YACTH,SAAS;YACTC,SAAS;QACX;QAEAK,MAAM5B,KAAK6B,MAAM,CACf/B,yBACEiB,aACA;YACER;YACA,GAAGU,mBAAmB;QACxB,GACA,qFAAqF;QACrF;YAAC;SAAU,GAEb;YAAEF;QAAY;QAEhBK;QACAK;QACAF;QACAD;IACF;IAEA,IAAII,MAAMJ,OAAO,IAAIzB,MAAMiC,cAAc,CAAcJ,MAAMJ,OAAO,CAACb,QAAQ,GAAG;QAC9EiB,MAAMJ,OAAO,CAACb,QAAQ,GAAGZ,MAAMkC,YAAY,CAACL,MAAMJ,OAAO,CAACb,QAAQ,EAAE;YAClEuB,WAAWjC,aAAa2B,MAAMJ,OAAO,CAACb,QAAQ,CAACH,KAAK,CAAC0B,SAAS,EAAE7B,yBAAyB8B,YAAY;QACvG;IACF;IAEA,OAAOP;AACT,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReferenceList.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { Overflow, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceListState, ReferenceListSlots, ReferenceListContextValues } from './ReferenceList.types';\nimport { ReferenceListContextProvider } from '../../contexts/referenceListContext';\nimport type { JSXElement } from '@fluentui/react-components';\n\n/**\n * Render the final JSX of ReferenceList\n */\nexport const renderReferenceList_unstable = (\n state: ReferenceListState,\n contextValues: ReferenceListContextValues,\n): JSXElement => {\n assertSlots<ReferenceListSlots>(state);\n\n const { minVisibleReferences } = state;\n\n return (\n <ReferenceListContextProvider value={contextValues.referenceList}>\n <Overflow minimumVisible={minVisibleReferences}>\n <state.root>\n <state.arrowableRegion />\n {state.showMoreButton && <state.showMoreButton />}\n {state.showLessButton && <state.showLessButton />}\n </state.root>\n </Overflow>\n </ReferenceListContextProvider>\n );\n};\n"],"names":["Overflow","assertSlots","ReferenceListContextProvider","renderReferenceList_unstable","state","contextValues","minVisibleReferences","value","referenceList","minimumVisible","root","arrowableRegion","showMoreButton","showLessButton"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,QAAQ,EAAEC,WAAW,QAAQ,6BAA6B;AAEnE,SAASC,4BAA4B,QAAQ,sCAAsC;AAGnF;;CAEC,GACD,OAAO,MAAMC,+BAA+B,CAC1CC,OACAC;IAEAJ,YAAgCG;IAEhC,MAAM,EAAEE,oBAAoB,EAAE,GAAGF;IAEjC,qBACE,KAACF;QAA6BK,OAAOF,cAAcG,aAAa;kBAC9D,cAAA,KAACR;YAASS,gBAAgBH;sBACxB,cAAA,MAACF,MAAMM,IAAI;;kCACT,KAACN,MAAMO,eAAe;oBACrBP,MAAMQ,cAAc,kBAAI,KAACR,MAAMQ,cAAc;oBAC7CR,MAAMS,cAAc,kBAAI,KAACT,MAAMS,cAAc;;;;;AAKxD,EAAE"}
1
+ {"version":3,"sources":["renderReferenceList.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { Overflow, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceListState, ReferenceListSlots, ReferenceListContextValues } from './ReferenceList.types';\nimport { ReferenceListContextProvider } from '../../contexts/referenceListContext';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of ReferenceList\n */\nexport const renderReferenceList_unstable = (\n state: ReferenceListState,\n contextValues: ReferenceListContextValues,\n): JSXElement => {\n assertSlots<ReferenceListSlots>(state);\n\n const { minVisibleReferences } = state;\n\n return (\n <ReferenceListContextProvider value={contextValues.referenceList}>\n <Overflow minimumVisible={minVisibleReferences}>\n <state.root>\n <state.arrowableRegion />\n {state.showMoreButton && <state.showMoreButton />}\n {state.showLessButton && <state.showLessButton />}\n </state.root>\n </Overflow>\n </ReferenceListContextProvider>\n );\n};\n"],"names":["Overflow","assertSlots","ReferenceListContextProvider","renderReferenceList_unstable","state","contextValues","minVisibleReferences","value","referenceList","minimumVisible","root","arrowableRegion","showMoreButton","showLessButton"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,QAAQ,EAAEC,WAAW,QAAQ,6BAA6B;AAEnE,SAASC,4BAA4B,QAAQ,sCAAsC;AAGnF;;CAEC,GACD,OAAO,MAAMC,+BAA+B,CAC1CC,OACAC;IAEAJ,YAAgCG;IAEhC,MAAM,EAAEE,oBAAoB,EAAE,GAAGF;IAEjC,qBACE,KAACF;QAA6BK,OAAOF,cAAcG,aAAa;kBAC9D,cAAA,KAACR;YAASS,gBAAgBH;sBACxB,cAAA,MAACF,MAAMM,IAAI;;kCACT,KAACN,MAAMO,eAAe;oBACrBP,MAAMQ,cAAc,kBAAI,KAACR,MAAMQ,cAAc;oBAC7CR,MAAMS,cAAc,kBAAI,KAACT,MAAMS,cAAc;;;;;AAKxD,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReferenceOverflowButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceOverflowButtonState, ReferenceOverflowButtonSlots } from './ReferenceOverflowButton.types';\nimport type { JSXElement } from '@fluentui/react-components';\n\n/**\n * Render the final JSX of ReferenceOverflowButton\n */\nexport const renderReferenceOverflowButton_unstable = (state: ReferenceOverflowButtonState): JSXElement | null => {\n assertSlots<ReferenceOverflowButtonSlots>(state);\n const { id, shouldRenderOverflowButton } = state;\n\n return shouldRenderOverflowButton ? (\n <OverflowItem key={id} id={id} priority={1}>\n <state.root />\n </OverflowItem>\n ) : null;\n};\n"],"names":["OverflowItem","assertSlots","renderReferenceOverflowButton_unstable","state","id","shouldRenderOverflowButton","priority","root"],"rangeMappings":";;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,YAAY,EAAEC,WAAW,QAAQ,6BAA6B;AAIvE;;CAEC,GACD,OAAO,MAAMC,yCAAyC,CAACC;IACrDF,YAA0CE;IAC1C,MAAM,EAAEC,EAAE,EAAEC,0BAA0B,EAAE,GAAGF;IAE3C,OAAOE,2CACL,KAACL;QAAsBI,IAAIA;QAAIE,UAAU;kBACvC,cAAA,KAACH,MAAMI,IAAI;OADMH,MAGjB;AACN,EAAE"}
1
+ {"version":3,"sources":["renderReferenceOverflowButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceOverflowButtonState, ReferenceOverflowButtonSlots } from './ReferenceOverflowButton.types';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of ReferenceOverflowButton\n */\nexport const renderReferenceOverflowButton_unstable = (state: ReferenceOverflowButtonState): JSXElement | null => {\n assertSlots<ReferenceOverflowButtonSlots>(state);\n const { id, shouldRenderOverflowButton } = state;\n\n return shouldRenderOverflowButton ? (\n <OverflowItem key={id} id={id} priority={1}>\n <state.root />\n </OverflowItem>\n ) : null;\n};\n"],"names":["OverflowItem","assertSlots","renderReferenceOverflowButton_unstable","state","id","shouldRenderOverflowButton","priority","root"],"rangeMappings":";;;;;;;;;;;;","mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,YAAY,EAAEC,WAAW,QAAQ,6BAA6B;AAIvE;;CAEC,GACD,OAAO,MAAMC,yCAAyC,CAACC;IACrDF,YAA0CE;IAC1C,MAAM,EAAEC,EAAE,EAAEC,0BAA0B,EAAE,GAAGF;IAE3C,OAAOE,2CACL,KAACL;QAAsBI,IAAIA;QAAIE,UAAU;kBACvC,cAAA,KAACH,MAAMI,IAAI;OADMH,MAGjB;AACN,EAAE"}
@@ -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';\nimport type { JSXElement } from '@fluentui/react-components';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState): JSXElement => {\n assertSlots<CitationSlots>(state);\n\n return <state.root />;\n};\n"],"names":["renderCitation_unstable","state","assertSlots","_jsx","root"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;iCAE4B;AAMrB,MAAMA,0BAA0B,CAACC;IACtCC,IAAAA,4BAAAA,EAA2BD;IAE3B,OAAA,WAAA,GAAOE,IAAAA,eAAA,EAACF,MAAMG,IAAI,EAAA,CAAA;AACpB"}
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';\nimport type { JSXElement } from '@fluentui/react-utilities';\n/**\n * Render the final JSX of Citation\n */\nexport const renderCitation_unstable = (state: CitationState): JSXElement => {\n assertSlots<CitationSlots>(state);\n\n return <state.root />;\n};\n"],"names":["renderCitation_unstable","state","assertSlots","_jsx","root"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;iCAE4B;AAMrB,MAAMA,0BAA0B,CAACC;IACtCC,IAAAA,4BAAAA,EAA2BD;IAE3B,OAAA,WAAA,GAAOE,IAAAA,eAAA,EAACF,MAAMG,IAAI,EAAA,CAAA;AACpB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\nimport type { JSXElement } from '@fluentui/react-components';\n\nexport const renderReference_unstable = (state: ReferenceState): JSXElement => {\n assertSlots<ReferenceSlots>(state);\n\n const { id, shouldUseOverflow } = state;\n\n const reference = (\n <state.root>\n {state.citation && <state.citation />}\n {state.divider && <state.divider />}\n {state.content && (\n <state.content>\n {state.graphic && <state.graphic />}\n {state.root.children}\n </state.content>\n )}\n </state.root>\n );\n\n return shouldUseOverflow ? (\n <OverflowItem key={id} id={id}>\n {reference}\n </OverflowItem>\n ) : (\n reference\n );\n};\n"],"names":["renderReference_unstable","state","assertSlots","id","shouldUseOverflow","reference","_jsxs","root","citation","_jsx","divider","content","graphic","children","OverflowItem"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAOaA;;;eAAAA;;;4BANb;iCAE0C;AAInC,MAAMA,2BAA2B,CAACC;IACvCC,IAAAA,4BAAAA,EAA4BD;IAE5B,MAAM,EAAEE,EAAE,EAAEC,iBAAiB,EAAE,GAAGH;IAElC,MAAMI,YAAAA,WAAAA,GACJC,IAAAA,gBAAA,EAACL,MAAMM,IAAI,EAAA;;YACRN,MAAMO,QAAQ,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACR,MAAMO,QAAQ,EAAA,CAAA;YACjCP,MAAMS,OAAO,IAAA,WAAA,GAAID,IAAAA,eAAA,EAACR,MAAMS,OAAO,EAAA,CAAA;YAC/BT,MAAMU,OAAO,IAAA,WAAA,GACZL,IAAAA,gBAAA,EAACL,MAAMU,OAAO,EAAA;;oBACXV,MAAMW,OAAO,IAAA,WAAA,GAAIH,IAAAA,eAAA,EAACR,MAAMW,OAAO,EAAA,CAAA;oBAC/BX,MAAMM,IAAI,CAACM,QAAQ;;;;;IAM5B,OAAOT,oBAAAA,WAAAA,GACLK,IAAAA,eAAA,EAACK,6BAAAA,EAAAA;QAAsBX,IAAIA;kBACxBE;OADgBF,MAInBE;AAEJ"}
1
+ {"version":3,"sources":["renderReference.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceState, ReferenceSlots } from './Reference.types';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\nexport const renderReference_unstable = (state: ReferenceState): JSXElement => {\n assertSlots<ReferenceSlots>(state);\n\n const { id, shouldUseOverflow } = state;\n\n const reference = (\n <state.root>\n {state.citation && <state.citation />}\n {state.divider && <state.divider />}\n {state.content && (\n <state.content>\n {state.graphic && <state.graphic />}\n {state.root.children}\n </state.content>\n )}\n </state.root>\n );\n\n return shouldUseOverflow ? (\n <OverflowItem key={id} id={id}>\n {reference}\n </OverflowItem>\n ) : (\n reference\n );\n};\n"],"names":["renderReference_unstable","state","assertSlots","id","shouldUseOverflow","reference","_jsxs","root","citation","_jsx","divider","content","graphic","children","OverflowItem"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAOaA;;;eAAAA;;;4BANb;iCAE0C;AAInC,MAAMA,2BAA2B,CAACC;IACvCC,IAAAA,4BAAAA,EAA4BD;IAE5B,MAAM,EAAEE,EAAE,EAAEC,iBAAiB,EAAE,GAAGH;IAElC,MAAMI,YAAAA,WAAAA,GACJC,IAAAA,gBAAA,EAACL,MAAMM,IAAI,EAAA;;YACRN,MAAMO,QAAQ,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACR,MAAMO,QAAQ,EAAA,CAAA;YACjCP,MAAMS,OAAO,IAAA,WAAA,GAAID,IAAAA,eAAA,EAACR,MAAMS,OAAO,EAAA,CAAA;YAC/BT,MAAMU,OAAO,IAAA,WAAA,GACZL,IAAAA,gBAAA,EAACL,MAAMU,OAAO,EAAA;;oBACXV,MAAMW,OAAO,IAAA,WAAA,GAAIH,IAAAA,eAAA,EAACR,MAAMW,OAAO,EAAA,CAAA;oBAC/BX,MAAMM,IAAI,CAACM,QAAQ;;;;;IAM5B,OAAOT,oBAAAA,WAAAA,GACLK,IAAAA,eAAA,EAACK,6BAAAA,EAAAA;QAAsBX,IAAIA;kBACxBE;OADgBF,MAInBE;AAEJ"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useReference.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { useReferenceListContext_unstable } from '../../contexts/referenceListContext';\nimport { referenceExtraClassNames } from './useReferenceStyles.styles';\nimport type { ReferenceProps, ReferenceState, ReferenceSlots } from './Reference.types';\nimport { useDesignVersion } from '@fluentui-copilot/react-provider';\nimport type { JSXIntrinsicElement } from '@fluentui/react-components';\n/**\n * Create the state required to render Reference.\n *\n * The returned state can be modified with hooks such as useReferenceStyles_unstable,\n * before being passed to renderReference_unstable.\n *\n * @param props - props from this instance of Reference\n * @param ref - reference to root HTMLElement of Reference\n */\nexport const useReference_unstable = (\n props: ReferenceProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): ReferenceState => {\n const { as, children, id } = props;\n\n const designVersion = useDesignVersion(props.designVersion);\n\n const shouldUseOverflow = useReferenceListContext_unstable(ctx => ctx.shouldUseOverflow);\n\n const referenceId = useId('reference-', id);\n\n const elementType = as || ((props as JSXIntrinsicElement<'a'>).href ? 'a' : 'button');\n const propsWithAssignedAs = {\n type: elementType === 'button' ? 'button' : undefined,\n ...props,\n as: elementType,\n id: referenceId,\n };\n\n const citation = slot.optional(props.citation, { elementType: 'span' });\n const graphic = slot.optional(props.graphic, { elementType: 'span' });\n const content = slot.optional(props.content as ReferenceSlots['content'], {\n elementType: 'span',\n renderByDefault: graphic !== undefined || !!children,\n });\n const divider = slot.optional(props.divider, {\n elementType: 'span',\n renderByDefault: citation !== undefined && content !== undefined,\n });\n\n const state: ReferenceState = {\n designVersion,\n id: referenceId,\n shouldUseOverflow,\n\n components: {\n root: elementType,\n citation: 'span',\n divider: 'span',\n graphic: 'span',\n content: 'span',\n },\n\n root: slot.always(\n getIntrinsicElementProps(\n elementType,\n {\n ref,\n ...propsWithAssignedAs,\n },\n // `content` is a slot and it's type clashes with the HTMLElement `content` attribute\n ['content'],\n ) as ReferenceSlots['root'],\n { elementType },\n ),\n citation,\n divider,\n content,\n graphic,\n };\n\n if (state.graphic && React.isValidElement<HTMLElement>(state.graphic.children)) {\n state.graphic.children = React.cloneElement(state.graphic.children, {\n className: mergeClasses(state.graphic.children.props.className, referenceExtraClassNames.graphicChild),\n });\n }\n\n return state;\n};\n"],"names":["useReference_unstable","props","ref","as","children","id","designVersion","useDesignVersion","shouldUseOverflow","useReferenceListContext_unstable","ctx","referenceId","useId","elementType","href","propsWithAssignedAs","type","undefined","citation","slot","optional","graphic","content","renderByDefault","divider","state","components","root","always","getIntrinsicElementProps","React","isValidElement","cloneElement","className","mergeClasses","referenceExtraClassNames","graphicChild"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAgBaA;;;eAAAA;;;;iEAhBU;iCAC6C;sCACnB;0CACR;+BAER;AAW1B,MAAMA,wBAAwB,CACnCC,OACAC;IAEA,MAAM,EAAEC,EAAE,EAAEC,QAAQ,EAAEC,EAAE,EAAE,GAAGJ;IAE7B,MAAMK,gBAAgBC,IAAAA,+BAAAA,EAAiBN,MAAMK,aAAa;IAE1D,MAAME,oBAAoBC,IAAAA,sDAAAA,EAAiCC,CAAAA,MAAOA,IAAIF,iBAAiB;IAEvF,MAAMG,cAAcC,IAAAA,sBAAAA,EAAM,cAAcP;IAExC,MAAMQ,cAAcV,MAAOF,CAAAA,MAAoCa,IAAI,GAAG,MAAM,QAAA;IAC5E,MAAMC,sBAAsB;QAC1BC,MAAMH,gBAAgB,WAAW,WAAWI;QAC5C,GAAGhB,KAAK;QACRE,IAAIU;QACJR,IAAIM;IACN;IAEA,MAAMO,WAAWC,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMiB,QAAQ,EAAE;QAAEL,aAAa;IAAO;IACrE,MAAMQ,UAAUF,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMoB,OAAO,EAAE;QAAER,aAAa;IAAO;IACnE,MAAMS,UAAUH,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMqB,OAAO,EAA+B;QACxET,aAAa;QACbU,iBAAiBF,YAAYJ,aAAa,CAAC,CAACb;IAC9C;IACA,MAAMoB,UAAUL,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMuB,OAAO,EAAE;QAC3CX,aAAa;QACbU,iBAAiBL,aAAaD,aAAaK,YAAYL;IACzD;IAEA,MAAMQ,QAAwB;QAC5BnB;QACAD,IAAIM;QACJH;QAEAkB,YAAY;YACVC,MAAMd;YACNK,UAAU;YACVM,SAAS;YACTH,SAAS;YACTC,SAAS;QACX;QAEAK,MAAMR,qBAAAA,CAAKS,MAAM,CACfC,IAAAA,yCAAAA,EACEhB,aACA;YACEX;YACA,GAAGa,mBAAmB;QACxB,GAEA;YAAC;SAAU,GAEb;YAAEF;QAAY;QAEhBK;QACAM;QACAF;QACAD;IACF;IAEA,IAAII,MAAMJ,OAAO,kBAAIS,OAAMC,cAAc,CAAcN,MAAMJ,OAAO,CAACjB,QAAQ,GAAG;QAC9EqB,MAAMJ,OAAO,CAACjB,QAAQ,iBAAG0B,OAAME,YAAY,CAACP,MAAMJ,OAAO,CAACjB,QAAQ,EAAE;YAClE6B,WAAWC,IAAAA,6BAAAA,EAAaT,MAAMJ,OAAO,CAACjB,QAAQ,CAACH,KAAK,CAACgC,SAAS,EAAEE,kDAAAA,CAAyBC,YAAY;QACvG;IACF;IAEA,OAAOX;AACT"}
1
+ {"version":3,"sources":["useReference.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { useReferenceListContext_unstable } from '../../contexts/referenceListContext';\nimport { referenceExtraClassNames } from './useReferenceStyles.styles';\nimport type { ReferenceProps, ReferenceState, ReferenceSlots } from './Reference.types';\nimport { useDesignVersion } from '@fluentui-copilot/react-provider';\nimport type { JSXIntrinsicElement } from '@fluentui/react-utilities';\n/**\n * Create the state required to render Reference.\n *\n * The returned state can be modified with hooks such as useReferenceStyles_unstable,\n * before being passed to renderReference_unstable.\n *\n * @param props - props from this instance of Reference\n * @param ref - reference to root HTMLElement of Reference\n */\nexport const useReference_unstable = (\n props: ReferenceProps,\n ref: React.Ref<HTMLButtonElement | HTMLAnchorElement>,\n): ReferenceState => {\n const { as, children, id } = props;\n\n const designVersion = useDesignVersion(props.designVersion);\n\n const shouldUseOverflow = useReferenceListContext_unstable(ctx => ctx.shouldUseOverflow);\n\n const referenceId = useId('reference-', id);\n\n const elementType = as || ((props as JSXIntrinsicElement<'a'>).href ? 'a' : 'button');\n const propsWithAssignedAs = {\n type: elementType === 'button' ? 'button' : undefined,\n ...props,\n as: elementType,\n id: referenceId,\n };\n\n const citation = slot.optional(props.citation, { elementType: 'span' });\n const graphic = slot.optional(props.graphic, { elementType: 'span' });\n const content = slot.optional(props.content as ReferenceSlots['content'], {\n elementType: 'span',\n renderByDefault: graphic !== undefined || !!children,\n });\n const divider = slot.optional(props.divider, {\n elementType: 'span',\n renderByDefault: citation !== undefined && content !== undefined,\n });\n\n const state: ReferenceState = {\n designVersion,\n id: referenceId,\n shouldUseOverflow,\n\n components: {\n root: elementType,\n citation: 'span',\n divider: 'span',\n graphic: 'span',\n content: 'span',\n },\n\n root: slot.always(\n getIntrinsicElementProps(\n elementType,\n {\n ref,\n ...propsWithAssignedAs,\n },\n // `content` is a slot and it's type clashes with the HTMLElement `content` attribute\n ['content'],\n ) as ReferenceSlots['root'],\n { elementType },\n ),\n citation,\n divider,\n content,\n graphic,\n };\n\n if (state.graphic && React.isValidElement<HTMLElement>(state.graphic.children)) {\n state.graphic.children = React.cloneElement(state.graphic.children, {\n className: mergeClasses(state.graphic.children.props.className, referenceExtraClassNames.graphicChild),\n });\n }\n\n return state;\n};\n"],"names":["useReference_unstable","props","ref","as","children","id","designVersion","useDesignVersion","shouldUseOverflow","useReferenceListContext_unstable","ctx","referenceId","useId","elementType","href","propsWithAssignedAs","type","undefined","citation","slot","optional","graphic","content","renderByDefault","divider","state","components","root","always","getIntrinsicElementProps","React","isValidElement","cloneElement","className","mergeClasses","referenceExtraClassNames","graphicChild"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAgBaA;;;eAAAA;;;;iEAhBU;iCAC6C;sCACnB;0CACR;+BAER;AAW1B,MAAMA,wBAAwB,CACnCC,OACAC;IAEA,MAAM,EAAEC,EAAE,EAAEC,QAAQ,EAAEC,EAAE,EAAE,GAAGJ;IAE7B,MAAMK,gBAAgBC,IAAAA,+BAAAA,EAAiBN,MAAMK,aAAa;IAE1D,MAAME,oBAAoBC,IAAAA,sDAAAA,EAAiCC,CAAAA,MAAOA,IAAIF,iBAAiB;IAEvF,MAAMG,cAAcC,IAAAA,sBAAAA,EAAM,cAAcP;IAExC,MAAMQ,cAAcV,MAAOF,CAAAA,MAAoCa,IAAI,GAAG,MAAM,QAAA;IAC5E,MAAMC,sBAAsB;QAC1BC,MAAMH,gBAAgB,WAAW,WAAWI;QAC5C,GAAGhB,KAAK;QACRE,IAAIU;QACJR,IAAIM;IACN;IAEA,MAAMO,WAAWC,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMiB,QAAQ,EAAE;QAAEL,aAAa;IAAO;IACrE,MAAMQ,UAAUF,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMoB,OAAO,EAAE;QAAER,aAAa;IAAO;IACnE,MAAMS,UAAUH,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMqB,OAAO,EAA+B;QACxET,aAAa;QACbU,iBAAiBF,YAAYJ,aAAa,CAAC,CAACb;IAC9C;IACA,MAAMoB,UAAUL,qBAAAA,CAAKC,QAAQ,CAACnB,MAAMuB,OAAO,EAAE;QAC3CX,aAAa;QACbU,iBAAiBL,aAAaD,aAAaK,YAAYL;IACzD;IAEA,MAAMQ,QAAwB;QAC5BnB;QACAD,IAAIM;QACJH;QAEAkB,YAAY;YACVC,MAAMd;YACNK,UAAU;YACVM,SAAS;YACTH,SAAS;YACTC,SAAS;QACX;QAEAK,MAAMR,qBAAAA,CAAKS,MAAM,CACfC,IAAAA,yCAAAA,EACEhB,aACA;YACEX;YACA,GAAGa,mBAAmB;QACxB,GAEA;YAAC;SAAU,GAEb;YAAEF;QAAY;QAEhBK;QACAM;QACAF;QACAD;IACF;IAEA,IAAII,MAAMJ,OAAO,kBAAIS,OAAMC,cAAc,CAAcN,MAAMJ,OAAO,CAACjB,QAAQ,GAAG;QAC9EqB,MAAMJ,OAAO,CAACjB,QAAQ,iBAAG0B,OAAME,YAAY,CAACP,MAAMJ,OAAO,CAACjB,QAAQ,EAAE;YAClE6B,WAAWC,IAAAA,6BAAAA,EAAaT,MAAMJ,OAAO,CAACjB,QAAQ,CAACH,KAAK,CAACgC,SAAS,EAAEE,kDAAAA,CAAyBC,YAAY;QACvG;IACF;IAEA,OAAOX;AACT"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReferenceList.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { Overflow, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceListState, ReferenceListSlots, ReferenceListContextValues } from './ReferenceList.types';\nimport { ReferenceListContextProvider } from '../../contexts/referenceListContext';\nimport type { JSXElement } from '@fluentui/react-components';\n\n/**\n * Render the final JSX of ReferenceList\n */\nexport const renderReferenceList_unstable = (\n state: ReferenceListState,\n contextValues: ReferenceListContextValues,\n): JSXElement => {\n assertSlots<ReferenceListSlots>(state);\n\n const { minVisibleReferences } = state;\n\n return (\n <ReferenceListContextProvider value={contextValues.referenceList}>\n <Overflow minimumVisible={minVisibleReferences}>\n <state.root>\n <state.arrowableRegion />\n {state.showMoreButton && <state.showMoreButton />}\n {state.showLessButton && <state.showLessButton />}\n </state.root>\n </Overflow>\n </ReferenceListContextProvider>\n );\n};\n"],"names":["renderReferenceList_unstable","state","contextValues","assertSlots","minVisibleReferences","_jsx","ReferenceListContextProvider","value","referenceList","Overflow","minimumVisible","_jsxs","root","arrowableRegion","showMoreButton","showLessButton"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAWaA;;;eAAAA;;;4BAVb;iCAEsC;sCAEO;AAMtC,MAAMA,+BAA+B,CAC1CC,OACAC;IAEAC,IAAAA,4BAAAA,EAAgCF;IAEhC,MAAM,EAAEG,oBAAoB,EAAE,GAAGH;IAEjC,OAAA,WAAA,GACEI,IAAAA,eAAA,EAACC,kDAAAA,EAAAA;QAA6BC,OAAOL,cAAcM,aAAa;kBAC9D,WAAA,GAAAH,IAAAA,eAAA,EAACI,yBAAAA,EAAAA;YAASC,gBAAgBN;sBACxB,WAAA,GAAAO,IAAAA,gBAAA,EAACV,MAAMW,IAAI,EAAA;;kCACTP,IAAAA,eAAA,EAACJ,MAAMY,eAAe,EAAA,CAAA;oBACrBZ,MAAMa,cAAc,IAAA,WAAA,GAAIT,IAAAA,eAAA,EAACJ,MAAMa,cAAc,EAAA,CAAA;oBAC7Cb,MAAMc,cAAc,IAAA,WAAA,GAAIV,IAAAA,eAAA,EAACJ,MAAMc,cAAc,EAAA,CAAA;;;;;AAKxD"}
1
+ {"version":3,"sources":["renderReferenceList.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { Overflow, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceListState, ReferenceListSlots, ReferenceListContextValues } from './ReferenceList.types';\nimport { ReferenceListContextProvider } from '../../contexts/referenceListContext';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of ReferenceList\n */\nexport const renderReferenceList_unstable = (\n state: ReferenceListState,\n contextValues: ReferenceListContextValues,\n): JSXElement => {\n assertSlots<ReferenceListSlots>(state);\n\n const { minVisibleReferences } = state;\n\n return (\n <ReferenceListContextProvider value={contextValues.referenceList}>\n <Overflow minimumVisible={minVisibleReferences}>\n <state.root>\n <state.arrowableRegion />\n {state.showMoreButton && <state.showMoreButton />}\n {state.showLessButton && <state.showLessButton />}\n </state.root>\n </Overflow>\n </ReferenceListContextProvider>\n );\n};\n"],"names":["renderReferenceList_unstable","state","contextValues","assertSlots","minVisibleReferences","_jsx","ReferenceListContextProvider","value","referenceList","Overflow","minimumVisible","_jsxs","root","arrowableRegion","showMoreButton","showLessButton"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAWaA;;;eAAAA;;;4BAVb;iCAEsC;sCAEO;AAMtC,MAAMA,+BAA+B,CAC1CC,OACAC;IAEAC,IAAAA,4BAAAA,EAAgCF;IAEhC,MAAM,EAAEG,oBAAoB,EAAE,GAAGH;IAEjC,OAAA,WAAA,GACEI,IAAAA,eAAA,EAACC,kDAAAA,EAAAA;QAA6BC,OAAOL,cAAcM,aAAa;kBAC9D,WAAA,GAAAH,IAAAA,eAAA,EAACI,yBAAAA,EAAAA;YAASC,gBAAgBN;sBACxB,WAAA,GAAAO,IAAAA,gBAAA,EAACV,MAAMW,IAAI,EAAA;;kCACTP,IAAAA,eAAA,EAACJ,MAAMY,eAAe,EAAA,CAAA;oBACrBZ,MAAMa,cAAc,IAAA,WAAA,GAAIT,IAAAA,eAAA,EAACJ,MAAMa,cAAc,EAAA,CAAA;oBAC7Cb,MAAMc,cAAc,IAAA,WAAA,GAAIV,IAAAA,eAAA,EAACJ,MAAMc,cAAc,EAAA,CAAA;;;;;AAKxD"}
@@ -1 +1 @@
1
- {"version":3,"sources":["renderReferenceOverflowButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceOverflowButtonState, ReferenceOverflowButtonSlots } from './ReferenceOverflowButton.types';\nimport type { JSXElement } from '@fluentui/react-components';\n\n/**\n * Render the final JSX of ReferenceOverflowButton\n */\nexport const renderReferenceOverflowButton_unstable = (state: ReferenceOverflowButtonState): JSXElement | null => {\n assertSlots<ReferenceOverflowButtonSlots>(state);\n const { id, shouldRenderOverflowButton } = state;\n\n return shouldRenderOverflowButton ? (\n <OverflowItem key={id} id={id} priority={1}>\n <state.root />\n </OverflowItem>\n ) : null;\n};\n"],"names":["renderReferenceOverflowButton_unstable","state","assertSlots","id","shouldRenderOverflowButton","_jsx","OverflowItem","priority","root"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAUaA;;;eAAAA;;;4BATb;iCAE0C;AAOnC,MAAMA,yCAAyC,CAACC;IACrDC,IAAAA,4BAAAA,EAA0CD;IAC1C,MAAM,EAAEE,EAAE,EAAEC,0BAA0B,EAAE,GAAGH;IAE3C,OAAOG,6BAAAA,WAAAA,GACLC,IAAAA,eAAA,EAACC,6BAAAA,EAAAA;QAAsBH,IAAIA;QAAII,UAAU;kBACvC,WAAA,GAAAF,IAAAA,eAAA,EAACJ,MAAMO,IAAI,EAAA,CAAA;OADML,MAGjB;AACN"}
1
+ {"version":3,"sources":["renderReferenceOverflowButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { OverflowItem, assertSlots } from '@fluentui/react-components';\nimport type { ReferenceOverflowButtonState, ReferenceOverflowButtonSlots } from './ReferenceOverflowButton.types';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of ReferenceOverflowButton\n */\nexport const renderReferenceOverflowButton_unstable = (state: ReferenceOverflowButtonState): JSXElement | null => {\n assertSlots<ReferenceOverflowButtonSlots>(state);\n const { id, shouldRenderOverflowButton } = state;\n\n return shouldRenderOverflowButton ? (\n <OverflowItem key={id} id={id} priority={1}>\n <state.root />\n </OverflowItem>\n ) : null;\n};\n"],"names":["renderReferenceOverflowButton_unstable","state","assertSlots","id","shouldRenderOverflowButton","_jsx","OverflowItem","priority","root"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAUaA;;;eAAAA;;;4BATb;iCAE0C;AAOnC,MAAMA,yCAAyC,CAACC;IACrDC,IAAAA,4BAAAA,EAA0CD;IAC1C,MAAM,EAAEE,EAAE,EAAEC,0BAA0B,EAAE,GAAGH;IAE3C,OAAOG,6BAAAA,WAAAA,GACLC,IAAAA,eAAA,EAACC,6BAAAA,EAAAA;QAAsBH,IAAIA;QAAII,UAAU;kBACvC,WAAA,GAAAF,IAAAA,eAAA,EAACJ,MAAMO,IAAI,EAAA,CAAA;OADML,MAGjB;AACN"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui-copilot/react-reference",
3
- "version": "0.0.0-nightly-20251106-0406-702b7b06.1",
3
+ "version": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
4
4
  "description": "Fluent AI controls for citations and references",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -12,11 +12,11 @@
12
12
  },
13
13
  "license": "MIT",
14
14
  "dependencies": {
15
- "@fluentui-copilot/react-preview": "0.0.0-nightly-20251106-0406-702b7b06.1",
16
- "@fluentui-copilot/react-provider": "0.0.0-nightly-20251106-0406-702b7b06.1",
17
- "@fluentui-copilot/react-sensitivity-label": "0.0.0-nightly-20251106-0406-702b7b06.1",
18
- "@fluentui-copilot/react-utilities": "~0.0.0-nightly-20251106-0406-702b7b06.1",
19
- "@fluentui-copilot/tokens": "0.0.0-nightly-20251106-0406-702b7b06.1",
15
+ "@fluentui-copilot/react-preview": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
16
+ "@fluentui-copilot/react-provider": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
17
+ "@fluentui-copilot/react-sensitivity-label": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
18
+ "@fluentui-copilot/react-utilities": "~0.0.0-nightly-20251107-0407-fc4e98b2.1",
19
+ "@fluentui-copilot/tokens": "0.0.0-nightly-20251107-0407-fc4e98b2.1",
20
20
  "@swc/helpers": "^0.5.1"
21
21
  },
22
22
  "peerDependencies": {