@fluentui-copilot/react-preview 0.0.0-nightly-20240403-0404-6f5eb4de.1 → 0.0.0-nightly-20240404-0406-2afa9891.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-preview",
3
3
  "entries": [
4
4
  {
5
- "date": "Wed, 03 Apr 2024 04:09:41 GMT",
6
- "tag": "@fluentui-copilot/react-preview_v0.0.0-nightly-20240403-0404-6f5eb4de.1",
7
- "version": "0.0.0-nightly-20240403-0404-6f5eb4de.1",
5
+ "date": "Thu, 04 Apr 2024 04:11:43 GMT",
6
+ "tag": "@fluentui-copilot/react-preview_v0.0.0-nightly-20240404-0406-2afa9891.1",
7
+ "version": "0.0.0-nightly-20240404-0406-2afa9891.1",
8
8
  "comments": {
9
9
  "prerelease": [
10
10
  {
package/CHANGELOG.md CHANGED
@@ -1,13 +1,13 @@
1
1
  # Change Log - @fluentui-copilot/react-preview
2
2
 
3
- This log was last generated on Wed, 03 Apr 2024 04:09:41 GMT and should not be manually modified.
3
+ This log was last generated on Thu, 04 Apr 2024 04:11:43 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
- ## [0.0.0-nightly-20240403-0404-6f5eb4de.1](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-preview_v0.0.0-nightly-20240403-0404-6f5eb4de.1)
7
+ ## [0.0.0-nightly-20240404-0406-2afa9891.1](https://github.com/microsoft/fluentai/tree/@fluentui-copilot/react-preview_v0.0.0-nightly-20240404-0406-2afa9891.1)
8
8
 
9
- Wed, 03 Apr 2024 04:09:41 GMT
10
- [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-preview_v0.3.0..@fluentui-copilot/react-preview_v0.0.0-nightly-20240403-0404-6f5eb4de.1)
9
+ Thu, 04 Apr 2024 04:11:43 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentai/compare/@fluentui-copilot/react-preview_v0.3.0..@fluentui-copilot/react-preview_v0.0.0-nightly-20240404-0406-2afa9891.1)
11
11
 
12
12
  ### Changes
13
13
 
package/dist/index.d.ts CHANGED
@@ -209,7 +209,7 @@ export declare const usePreview_unstable: (props: PreviewProps) => PreviewState;
209
209
  * @param props - props from this instance of PreviewContent
210
210
  * @param ref - reference to root HTMLElement of PreviewContent
211
211
  */
212
- export declare const usePreviewContent_unstable: (props: PreviewContentProps, ref: React_2.Ref<HTMLElement>) => PreviewContentState;
212
+ export declare const usePreviewContent_unstable: (props: PreviewContentProps, ref: React_2.Ref<HTMLDivElement>) => PreviewContentState;
213
213
 
214
214
  /**
215
215
  * Apply styling to the PreviewContent slots based on the state
@@ -227,7 +227,7 @@ export declare const usePreviewContext_unstable: <T>(selector: ContextSelector<P
227
227
  * @param props - props from this instance of PreviewHeader
228
228
  * @param ref - reference to root HTMLElement of PreviewHeader
229
229
  */
230
- export declare const usePreviewHeader_unstable: (props: PreviewHeaderProps, ref: React_2.Ref<HTMLElement>) => PreviewHeaderState;
230
+ export declare const usePreviewHeader_unstable: (props: PreviewHeaderProps, ref: React_2.Ref<HTMLDivElement>) => PreviewHeaderState;
231
231
 
232
232
  /**
233
233
  * Apply styling to the PreviewHeader slots based on the state
@@ -243,7 +243,7 @@ export declare const usePreviewHeaderStyles_unstable: (state: PreviewHeaderState
243
243
  * @param props - props from this instance of PreviewMetadata
244
244
  * @param ref - reference to root HTMLElement of PreviewMetadata
245
245
  */
246
- export declare const usePreviewMetadata_unstable: (props: PreviewMetadataProps, ref: React_2.Ref<HTMLElement>) => PreviewMetadataState;
246
+ export declare const usePreviewMetadata_unstable: (props: PreviewMetadataProps, ref: React_2.Ref<HTMLDivElement>) => PreviewMetadataState;
247
247
 
248
248
  /**
249
249
  * Apply styling to the PreviewMetadata slots based on the state
@@ -1,4 +1,4 @@
1
- import { getNativeElementProps, slot } from '@fluentui/react-components';
1
+ import { getIntrinsicElementProps, slot } from '@fluentui/react-components';
2
2
  /**
3
3
  * Create the state required to render PreviewContent.
4
4
  *
@@ -13,7 +13,7 @@ export const usePreviewContent_unstable = (props, ref) => {
13
13
  components: {
14
14
  root: 'div'
15
15
  },
16
- root: slot.always(getNativeElementProps('div', {
16
+ root: slot.always(getIntrinsicElementProps('div', {
17
17
  ref,
18
18
  ...props
19
19
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewContent.ts"],"sourcesContent":["import type * as React from 'react';\nimport { getNativeElementProps, slot } from '@fluentui/react-components';\nimport type { PreviewContentProps, PreviewContentState } from './PreviewContent.types';\n\n/**\n * Create the state required to render PreviewContent.\n *\n * The returned state can be modified with hooks such as usePreviewContentStyles_unstable,\n * before being passed to renderPreviewContent_unstable.\n *\n * @param props - props from this instance of PreviewContent\n * @param ref - reference to root HTMLElement of PreviewContent\n */\nexport const usePreviewContent_unstable = (\n props: PreviewContentProps,\n ref: React.Ref<HTMLElement>,\n): PreviewContentState => {\n return {\n components: {\n root: 'div',\n },\n root: slot.always(\n getNativeElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n };\n};\n"],"names":["getNativeElementProps","slot","usePreviewContent_unstable","props","ref","components","root","always","elementType"],"mappings":"AACA,SAASA,qBAAqB,EAAEC,IAAI,QAAQ,6BAA6B;AAGzE;;;;;;;;CAQC,GACD,OAAO,MAAMC,6BAA6B,CACxCC,OACAC;IAEA,OAAO;QACLC,YAAY;YACVC,MAAM;QACR;QACAA,MAAML,KAAKM,MAAM,CACfP,sBAAsB,OAAO;YAC3BI;YACA,GAAGD,KAAK;QACV,IACA;YAAEK,aAAa;QAAM;IAEzB;AACF,EAAE"}
1
+ {"version":3,"sources":["usePreviewContent.ts"],"sourcesContent":["import type * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-components';\nimport type { PreviewContentProps, PreviewContentState } from './PreviewContent.types';\n\n/**\n * Create the state required to render PreviewContent.\n *\n * The returned state can be modified with hooks such as usePreviewContentStyles_unstable,\n * before being passed to renderPreviewContent_unstable.\n *\n * @param props - props from this instance of PreviewContent\n * @param ref - reference to root HTMLElement of PreviewContent\n */\nexport const usePreviewContent_unstable = (\n props: PreviewContentProps,\n ref: React.Ref<HTMLDivElement>,\n): PreviewContentState => {\n return {\n components: {\n root: 'div',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n };\n};\n"],"names":["getIntrinsicElementProps","slot","usePreviewContent_unstable","props","ref","components","root","always","elementType"],"mappings":"AACA,SAASA,wBAAwB,EAAEC,IAAI,QAAQ,6BAA6B;AAG5E;;;;;;;;CAQC,GACD,OAAO,MAAMC,6BAA6B,CACxCC,OACAC;IAEA,OAAO;QACLC,YAAY;YACVC,MAAM;QACR;QACAA,MAAML,KAAKM,MAAM,CACfP,yBAAyB,OAAO;YAC9BI;YACA,GAAGD,KAAK;QACV,IACA;YAAEK,aAAa;QAAM;IAEzB;AACF,EAAE"}
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { getNativeElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';
2
+ import { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';
3
3
  import { previewHeaderExtraClassNames } from './usePreviewHeaderStyles';
4
4
  /**
5
5
  * Create the state required to render PreviewHeader.
@@ -28,7 +28,7 @@ export const usePreviewHeader_unstable = (props, ref) => {
28
28
  label: 'span',
29
29
  media: 'div'
30
30
  },
31
- root: slot.always(getNativeElementProps('div', {
31
+ root: slot.always(getIntrinsicElementProps('div', {
32
32
  ref,
33
33
  ...props
34
34
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewHeader.ts"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { previewHeaderExtraClassNames } from './usePreviewHeaderStyles';\nimport type { PreviewHeaderProps, PreviewHeaderState } from './PreviewHeader.types';\n\n/**\n * Create the state required to render PreviewHeader.\n *\n * The returned state can be modified with hooks such as usePreviewHeaderStyles_unstable,\n * before being passed to renderPreviewHeader_unstable.\n *\n * @param props - props from this instance of PreviewHeader\n * @param ref - reference to root HTMLElement of PreviewHeader\n */\nexport const usePreviewHeader_unstable = (\n props: PreviewHeaderProps,\n ref: React.Ref<HTMLElement>,\n): PreviewHeaderState => {\n const { actions, children, citation, label, media } = props;\n\n const mediaId = useId('media');\n\n const state: PreviewHeaderState = {\n components: {\n root: 'div',\n actions: 'div',\n citation: 'span',\n label: 'span',\n media: 'div',\n },\n root: slot.always(\n getNativeElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n actions: slot.optional(actions, { elementType: 'div' }),\n citation: slot.optional(citation, { elementType: 'span' }),\n label: slot.always(label, {\n defaultProps: {\n children,\n },\n elementType: 'span',\n }),\n media: slot.optional(media, {\n defaultProps: {\n id: mediaId,\n },\n elementType: 'div',\n }),\n };\n\n if (state.media?.id) {\n state.label['aria-describedby'] = state.label['aria-describedby']?.concat(state.media.id) ?? state.media.id;\n }\n\n if (state.media && React.isValidElement<HTMLElement>(state.media.children)) {\n state.media.children = React.cloneElement(state.media.children, {\n className: mergeClasses(state.media.children.props.className, previewHeaderExtraClassNames.mediaChild),\n });\n }\n\n return state;\n};\n"],"names":["React","getNativeElementProps","mergeClasses","slot","useId","previewHeaderExtraClassNames","usePreviewHeader_unstable","props","ref","state","actions","children","citation","label","media","mediaId","components","root","always","elementType","optional","defaultProps","id","concat","isValidElement","cloneElement","className","mediaChild"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,qBAAqB,EAAEC,YAAY,EAAEC,IAAI,EAAEC,KAAK,QAAQ,6BAA6B;AAC9F,SAASC,4BAA4B,QAAQ,2BAA2B;AAGxE;;;;;;;;CAQC,GACD,OAAO,MAAMC,4BAA4B,CACvCC,OACAC;QAqCIC;IAnCJ,MAAM,EAAEC,OAAO,EAAEC,QAAQ,EAAEC,QAAQ,EAA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ourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { previewHeaderExtraClassNames } from './usePreviewHeaderStyles';\nimport type { PreviewHeaderProps, PreviewHeaderState } from './PreviewHeader.types';\n\n/**\n * Create the state required to render PreviewHeader.\n *\n * The returned state can be modified with hooks such as usePreviewHeaderStyles_unstable,\n * before being passed to renderPreviewHeader_unstable.\n *\n * @param props - props from this instance of PreviewHeader\n * @param ref - reference to root HTMLElement of PreviewHeader\n */\nexport const usePreviewHeader_unstable = (\n props: PreviewHeaderProps,\n ref: React.Ref<HTMLDivElement>,\n): PreviewHeaderState => {\n const { actions, children, citation, label, media } = props;\n\n const mediaId = useId('media');\n\n const state: PreviewHeaderState = {\n components: {\n root: 'div',\n actions: 'div',\n citation: 'span',\n label: 'span',\n media: 'div',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n actions: slot.optional(actions, { elementType: 'div' }),\n citation: slot.optional(citation, { elementType: 'span' }),\n label: slot.always(label, {\n defaultProps: {\n children,\n },\n elementType: 'span',\n }),\n media: slot.optional(media, {\n defaultProps: {\n id: mediaId,\n },\n elementType: 'div',\n }),\n };\n\n if (state.media?.id) {\n state.label['aria-describedby'] = state.label['aria-describedby']?.concat(state.media.id) ?? state.media.id;\n }\n\n if (state.media && React.isValidElement<HTMLElement>(state.media.children)) {\n state.media.children = React.cloneElement(state.media.children, {\n className: mergeClasses(state.media.children.props.className, previewHeaderExtraClassNames.mediaChild),\n });\n }\n\n return state;\n};\n"],"names":["React","getIntrinsicElementProps","mergeClasses","slot","useId","previewHeaderExtraClassNames","usePreviewHeader_unstable","props","ref","state","actions","children","citation","label","media","mediaId","components","root","always","elementType","optional","defaultProps","id","concat","isValidElement","cloneElement","className","mediaChild"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,wBAAwB,EAAEC,YAAY,EAAEC,IAAI,EAAEC,KAAK,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,EAAE;YAC9De,WAAWxB,aAAaO,MAAMK,KAAK,CAACH,QAAQ,CAACJ,KAAK,CAACmB,SAAS,EAAErB,6BAA6BsB,UAAU;QACvG;IACF;IAEA,OAAOlB;AACT,EAAE"}
@@ -1,4 +1,4 @@
1
- import { getNativeElementProps, slot } from '@fluentui/react-components';
1
+ import { getIntrinsicElementProps, slot } from '@fluentui/react-components';
2
2
  /**
3
3
  * Create the state required to render PreviewMetadata.
4
4
  *
@@ -23,7 +23,7 @@ export const usePreviewMetadata_unstable = (props, ref) => {
23
23
  secondaryText: 'span',
24
24
  tertiaryText: 'span'
25
25
  },
26
- root: slot.always(getNativeElementProps('div', {
26
+ root: slot.always(getIntrinsicElementProps('div', {
27
27
  ref,
28
28
  ...props
29
29
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewMetadata.ts"],"sourcesContent":["import type * as React from 'react';\nimport { getNativeElementProps, slot } from '@fluentui/react-components';\nimport type { PreviewMetadataProps, PreviewMetadataState } from './PreviewMetadata.types';\n\n/**\n * Create the state required to render PreviewMetadata.\n *\n * The returned state can be modified with hooks such as usePreviewMetadataStyles_unstable,\n * before being passed to renderPreviewMetadata_unstable.\n *\n * @param props - props from this instance of PreviewMetadata\n * @param ref - reference to root HTMLElement of PreviewMetadata\n */\nexport const usePreviewMetadata_unstable = (\n props: PreviewMetadataProps,\n ref: React.Ref<HTMLElement>,\n): PreviewMetadataState => {\n const { icon, primaryText, secondaryText, tertiaryText } = props;\n\n return {\n components: {\n root: 'div',\n icon: 'span',\n primaryText: 'span',\n secondaryText: 'span',\n tertiaryText: 'span',\n },\n root: slot.always(\n getNativeElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n icon: slot.optional(icon, { elementType: 'span' }),\n primaryText: slot.optional(primaryText, { elementType: 'span' }),\n secondaryText: slot.optional(secondaryText, { elementType: 'span' }),\n tertiaryText: slot.optional(tertiaryText, { elementType: 'span' }),\n };\n};\n"],"names":["getNativeElementProps","slot","usePreviewMetadata_unstable","props","ref","icon","primaryText","secondaryText","tertiaryText","components","root","always","elementType","optional"],"mappings":"AACA,SAASA,qBAAqB,EAAEC,IAAI,QAAQ,6BAA6B;AAGzE;;;;;;;;CAQC,GACD,OAAO,MAAMC,8BAA8B,CACzCC,OACAC;IAEA,MAAM,EAAEC,IAAI,EAAEC,WAAW,EAAEC,aAAa,EAAEC,YAAY,EAAE,GAAGL;IAE3D,OAAO;QACLM,YAAY;YACVC,MAAM;YACNL,MAAM;YACNC,aAAa;YACbC,eAAe;YACfC,cAAc;QAChB;QACAE,MAAMT,KAAKU,MAAM,CACfX,sBAAsB,OAAO;YAC3BI;YACA,GAAGD,KAAK;QACV,IACA;YAAES,aAAa;QAAM;QAEvBP,MAAMJ,KAAKY,QAAQ,CAACR,MAAM;YAAEO,aAAa;QAAO;QAChDN,aAAaL,KAAKY,QAAQ,CAACP,aAAa;YAAEM,aAAa;QAAO;QAC9DL,eAAeN,KAAKY,QAAQ,CAACN,eAAe;YAAEK,aAAa;QAAO;QAClEJ,cAAcP,KAAKY,QAAQ,CAACL,cAAc;YAAEI,aAAa;QAAO;IAClE;AACF,EAAE"}
1
+ {"version":3,"sources":["usePreviewMetadata.ts"],"sourcesContent":["import type * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-components';\nimport type { PreviewMetadataProps, PreviewMetadataState } from './PreviewMetadata.types';\n\n/**\n * Create the state required to render PreviewMetadata.\n *\n * The returned state can be modified with hooks such as usePreviewMetadataStyles_unstable,\n * before being passed to renderPreviewMetadata_unstable.\n *\n * @param props - props from this instance of PreviewMetadata\n * @param ref - reference to root HTMLElement of PreviewMetadata\n */\nexport const usePreviewMetadata_unstable = (\n props: PreviewMetadataProps,\n ref: React.Ref<HTMLDivElement>,\n): PreviewMetadataState => {\n const { icon, primaryText, secondaryText, tertiaryText } = props;\n\n return {\n components: {\n root: 'div',\n icon: 'span',\n primaryText: 'span',\n secondaryText: 'span',\n tertiaryText: 'span',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n icon: slot.optional(icon, { elementType: 'span' }),\n primaryText: slot.optional(primaryText, { elementType: 'span' }),\n secondaryText: slot.optional(secondaryText, { elementType: 'span' }),\n tertiaryText: slot.optional(tertiaryText, { elementType: 'span' }),\n };\n};\n"],"names":["getIntrinsicElementProps","slot","usePreviewMetadata_unstable","props","ref","icon","primaryText","secondaryText","tertiaryText","components","root","always","elementType","optional"],"mappings":"AACA,SAASA,wBAAwB,EAAEC,IAAI,QAAQ,6BAA6B;AAG5E;;;;;;;;CAQC,GACD,OAAO,MAAMC,8BAA8B,CACzCC,OACAC;IAEA,MAAM,EAAEC,IAAI,EAAEC,WAAW,EAAEC,aAAa,EAAEC,YAAY,EAAE,GAAGL;IAE3D,OAAO;QACLM,YAAY;YACVC,MAAM;YACNL,MAAM;YACNC,aAAa;YACbC,eAAe;YACfC,cAAc;QAChB;QACAE,MAAMT,KAAKU,MAAM,CACfX,yBAAyB,OAAO;YAC9BI;YACA,GAAGD,KAAK;QACV,IACA;YAAES,aAAa;QAAM;QAEvBP,MAAMJ,KAAKY,QAAQ,CAACR,MAAM;YAAEO,aAAa;QAAO;QAChDN,aAAaL,KAAKY,QAAQ,CAACP,aAAa;YAAEM,aAAa;QAAO;QAC9DL,eAAeN,KAAKY,QAAQ,CAACN,eAAe;YAAEK,aAAa;QAAO;QAClEJ,cAAcP,KAAKY,QAAQ,CAACL,cAAc;YAAEI,aAAa;QAAO;IAClE;AACF,EAAE"}
@@ -14,7 +14,7 @@ const usePreviewContent_unstable = (props, ref)=>{
14
14
  components: {
15
15
  root: 'div'
16
16
  },
17
- root: _reactcomponents.slot.always((0, _reactcomponents.getNativeElementProps)('div', {
17
+ root: _reactcomponents.slot.always((0, _reactcomponents.getIntrinsicElementProps)('div', {
18
18
  ref,
19
19
  ...props
20
20
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewContent.js"],"sourcesContent":["import { getNativeElementProps, slot } from '@fluentui/react-components';\n/**\n * Create the state required to render PreviewContent.\n *\n * The returned state can be modified with hooks such as usePreviewContentStyles_unstable,\n * before being passed to renderPreviewContent_unstable.\n *\n * @param props - props from this instance of PreviewContent\n * @param ref - reference to root HTMLElement of PreviewContent\n */\nexport const usePreviewContent_unstable = (props, ref) => {\n return {\n components: {\n root: 'div'\n },\n root: slot.always(getNativeElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n })\n };\n};\n//# sourceMappingURL=usePreviewContent.js.map"],"names":["usePreviewContent_unstable","props","ref","components","root","slot","always","getNativeElementProps","elementType"],"mappings":";;;;+BAUaA;;;eAAAA;;;iCAV+B;AAUrC,MAAMA,6BAA6B,CAACC,OAAOC;IAChD,OAAO;QACLC,YAAY;YACVC,MAAM;QACR;QACAA,MAAMC,qBAAI,CAACC,MAAM,CAACC,IAAAA,sCAAqB,EAAC,OAAO;YAC7CL;YACA,GAAGD,KAAK;QACV,IAAI;YACFO,aAAa;QACf;IACF;AACF,GACA,6CAA6C"}
1
+ {"version":3,"sources":["usePreviewContent.js"],"sourcesContent":["import { getIntrinsicElementProps, slot } from '@fluentui/react-components';\n/**\n * Create the state required to render PreviewContent.\n *\n * The returned state can be modified with hooks such as usePreviewContentStyles_unstable,\n * before being passed to renderPreviewContent_unstable.\n *\n * @param props - props from this instance of PreviewContent\n * @param ref - reference to root HTMLElement of PreviewContent\n */\nexport const usePreviewContent_unstable = (props, ref) => {\n return {\n components: {\n root: 'div'\n },\n root: slot.always(getIntrinsicElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n })\n };\n};\n//# sourceMappingURL=usePreviewContent.js.map"],"names":["usePreviewContent_unstable","props","ref","components","root","slot","always","getIntrinsicElementProps","elementType"],"mappings":";;;;+BAUaA;;;eAAAA;;;iCAVkC;AAUxC,MAAMA,6BAA6B,CAACC,OAAOC;IAChD,OAAO;QACLC,YAAY;YACVC,MAAM;QACR;QACAA,MAAMC,qBAAI,CAACC,MAAM,CAACC,IAAAA,yCAAwB,EAAC,OAAO;YAChDL;YACA,GAAGD,KAAK;QACV,IAAI;YACFO,aAAa;QACf;IACF;AACF,GACA,6CAA6C"}
@@ -24,7 +24,7 @@ const usePreviewHeader_unstable = (props, ref)=>{
24
24
  label: 'span',
25
25
  media: 'div'
26
26
  },
27
- root: _reactcomponents.slot.always((0, _reactcomponents.getNativeElementProps)('div', {
27
+ root: _reactcomponents.slot.always((0, _reactcomponents.getIntrinsicElementProps)('div', {
28
28
  ref,
29
29
  ...props
30
30
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewHeader.js"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { previewHeaderExtraClassNames } from './usePreviewHeaderStyles';\n/**\n * Create the state required to render PreviewHeader.\n *\n * The returned state can be modified with hooks such as usePreviewHeaderStyles_unstable,\n * before being passed to renderPreviewHeader_unstable.\n *\n * @param props - props from this instance of PreviewHeader\n * @param ref - reference to root HTMLElement of PreviewHeader\n */\nexport const usePreviewHeader_unstable = (props, ref) => {\n var _state_media;\n const {\n actions,\n children,\n citation,\n label,\n media\n } = props;\n const mediaId = useId('media');\n const state = {\n components: {\n root: 'div',\n actions: 'div',\n citation: 'span',\n label: 'span',\n media: 'div'\n },\n root: slot.always(getNativeElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n }),\n actions: slot.optional(actions, {\n elementType: 'div'\n }),\n citation: slot.optional(citation, {\n elementType: 'span'\n }),\n label: slot.always(label, {\n defaultProps: {\n children\n },\n elementType: 'span'\n }),\n media: slot.optional(media, {\n defaultProps: {\n id: mediaId\n },\n elementType: 'div'\n })\n };\n if ((_state_media = state.media) === null || _state_media === void 0 ? void 0 : _state_media.id) {\n var _state_label_ariadescribedby;\n var _state_label_ariadescribedby_concat;\n state.label['aria-describedby'] = (_state_label_ariadescribedby_concat = (_state_label_ariadescribedby = state.label['aria-describedby']) === null || _state_label_ariadescribedby === void 0 ? void 0 : _state_label_ariadescribedby.concat(state.media.id)) !== null && _state_label_ariadescribedby_concat !== void 0 ? _state_label_ariadescribedby_concat : state.media.id;\n }\n if (state.media && React.isValidElement(state.media.children)) {\n state.media.children = React.cloneElement(state.media.children, {\n className: mergeClasses(state.media.children.props.className, previewHeaderExtraClassNames.mediaChild)\n });\n }\n return state;\n};\n//# sourceMappingURL=usePreviewHeader.js.map"],"names":["usePreviewHeader_unstable","props","ref","_state_media","actions","children","citation","label","media","mediaId","useId","state","components","root","slot","always","getNativeElementProps","elementType","optional","defaultProps","id","_state_label_ariadescribedby","_state_label_ariadescribedby_concat","concat","React","isValidElement","cloneElement","className","mergeClasses","previewHeaderExtraClassNames","mediaChild"],"mappings":";;;;+BAYaA;;;eAAAA;;;;iEAZU;iCAC0C;wCACpB;AAUtC,MAAMA,4BAA4B,CAACC,OAAOC;IAC/C,IAAIC;IACJ,MAAM,EACJC,OAAO,EACPC,QAAQ,EACRC,QAAQ,EACRC,KAAK,EACLC,KAAK,EACN,GAAGP;IACJ,MAAMQ,UAAUC,IAAAA,sBAAK,EAAC;IACtB,MAAMC,QAAQ;QACZC,YAAY;YACVC,MAAM;YACNT,SAAS;YACTE,UAAU;YACVC,OAAO;YACPC,OAAO;QACT;QACAK,MAAMC,qBAAI,CAACC,MAAM,CAACC,IAAAA,sCAAqB,EAAC,OAAO;YAC7Cd;YACA,GAAGD,KAAK;QACV,IAAI;YACFgB,aAAa;QACf;QACAb,SAASU,qBAAI,CAACI,QAAQ,CAACd,SAAS;YAC9Ba,aAAa;QACf;QACAX,UAAUQ,qBAAI,CAACI,QAAQ,CAACZ,UAAU;YAChCW,aAAa;QACf;QACAV,OAAOO,qBAAI,CAACC,MAAM,CAACR,OAAO;YACxBY,cAAc;gBACZd;YACF;YACAY,aAAa;QACf;QACAT,OAAOM,qBAAI,CAACI,QAAQ,CAACV,OAAO;YAC1BW,cAAc;gBACZC,IAAIX;YACN;YACAQ,aAAa;QACf;IACF;IACA,IAAI,AAACd,CAAAA,eAAeQ,MAAMH,KAAK,AAAD,MAAO,QAAQL,iBAAiB,KAAK,IAAI,KAAK,IAAIA,aAAaiB,EAAE,EAAE;QAC/F,IAAIC;QACJ,IAAIC;QACJX,MAAMJ,KAAK,CAAC,mBAAmB,GAAG,AAACe,CAAAA,sCAAsC,AAACD,CAAAA,+BAA+BV,MAAMJ,KAAK,CAAC,mBAAmB,AAAD,MAAO,QAAQc,iCAAiC,KAAK,IAAI,KAAK,IAAIA,6BAA6BE,MAAM,CAACZ,MAAMH,KAAK,CAACY,EAAE,CAAA,MAAO,QAAQE,wCAAwC,KAAK,IAAIA,sCAAsCX,MAAMH,KAAK,CAACY,EAAE;IACjX;IACA,IAAIT,MAAMH,KAAK,kBAAIgB,OAAMC,cAAc,CAACd,MAAMH,KAAK,CAACH,QAAQ,GAAG;QAC7DM,MAAMH,KAAK,CAACH,QAAQ,iBAAGmB,OAAME,YAAY,CAACf,MAAMH,KAAK,CAACH,QAAQ,EAAE;YAC9DsB,WAAWC,IAAAA,6BAAY,EAACjB,MAAMH,KAAK,CAACH,QAAQ,CAACJ,KAAK,CAAC0B,SAAS,EAAEE,oDAA4B,CAACC,UAAU;QACvG;IACF;IACA,OAAOnB;AACT,GACA,4CAA4C"}
1
+ {"version":3,"sources":["usePreviewHeader.js"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, mergeClasses, slot, useId } from '@fluentui/react-components';\nimport { previewHeaderExtraClassNames } from './usePreviewHeaderStyles';\n/**\n * Create the state required to render PreviewHeader.\n *\n * The returned state can be modified with hooks such as usePreviewHeaderStyles_unstable,\n * before being passed to renderPreviewHeader_unstable.\n *\n * @param props - props from this instance of PreviewHeader\n * @param ref - reference to root HTMLElement of PreviewHeader\n */\nexport const usePreviewHeader_unstable = (props, ref) => {\n var _state_media;\n const {\n actions,\n children,\n citation,\n label,\n media\n } = props;\n const mediaId = useId('media');\n const state = {\n components: {\n root: 'div',\n actions: 'div',\n citation: 'span',\n label: 'span',\n media: 'div'\n },\n root: slot.always(getIntrinsicElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n }),\n actions: slot.optional(actions, {\n elementType: 'div'\n }),\n citation: slot.optional(citation, {\n elementType: 'span'\n }),\n label: slot.always(label, {\n defaultProps: {\n children\n },\n elementType: 'span'\n }),\n media: slot.optional(media, {\n defaultProps: {\n id: mediaId\n },\n elementType: 'div'\n })\n };\n if ((_state_media = state.media) === null || _state_media === void 0 ? void 0 : _state_media.id) {\n var _state_label_ariadescribedby;\n var _state_label_ariadescribedby_concat;\n state.label['aria-describedby'] = (_state_label_ariadescribedby_concat = (_state_label_ariadescribedby = state.label['aria-describedby']) === null || _state_label_ariadescribedby === void 0 ? void 0 : _state_label_ariadescribedby.concat(state.media.id)) !== null && _state_label_ariadescribedby_concat !== void 0 ? _state_label_ariadescribedby_concat : state.media.id;\n }\n if (state.media && React.isValidElement(state.media.children)) {\n state.media.children = React.cloneElement(state.media.children, {\n className: mergeClasses(state.media.children.props.className, previewHeaderExtraClassNames.mediaChild)\n });\n }\n return state;\n};\n//# sourceMappingURL=usePreviewHeader.js.map"],"names":["usePreviewHeader_unstable","props","ref","_state_media","actions","children","citation","label","media","mediaId","useId","state","components","root","slot","always","getIntrinsicElementProps","elementType","optional","defaultProps","id","_state_label_ariadescribedby","_state_label_ariadescribedby_concat","concat","React","isValidElement","cloneElement","className","mergeClasses","previewHeaderExtraClassNames","mediaChild"],"mappings":";;;;+BAYaA;;;eAAAA;;;;iEAZU;iCAC6C;wCACvB;AAUtC,MAAMA,4BAA4B,CAACC,OAAOC;IAC/C,IAAIC;IACJ,MAAM,EACJC,OAAO,EACPC,QAAQ,EACRC,QAAQ,EACRC,KAAK,EACLC,KAAK,EACN,GAAGP;IACJ,MAAMQ,UAAUC,IAAAA,sBAAK,EAAC;IACtB,MAAMC,QAAQ;QACZC,YAAY;YACVC,MAAM;YACNT,SAAS;YACTE,UAAU;YACVC,OAAO;YACPC,OAAO;QACT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@@ -19,7 +19,7 @@ const usePreviewMetadata_unstable = (props, ref)=>{
19
19
  secondaryText: 'span',
20
20
  tertiaryText: 'span'
21
21
  },
22
- root: _reactcomponents.slot.always((0, _reactcomponents.getNativeElementProps)('div', {
22
+ root: _reactcomponents.slot.always((0, _reactcomponents.getIntrinsicElementProps)('div', {
23
23
  ref,
24
24
  ...props
25
25
  }), {
@@ -1 +1 @@
1
- {"version":3,"sources":["usePreviewMetadata.js"],"sourcesContent":["import { getNativeElementProps, slot } from '@fluentui/react-components';\n/**\n * Create the state required to render PreviewMetadata.\n *\n * The returned state can be modified with hooks such as usePreviewMetadataStyles_unstable,\n * before being passed to renderPreviewMetadata_unstable.\n *\n * @param props - props from this instance of PreviewMetadata\n * @param ref - reference to root HTMLElement of PreviewMetadata\n */\nexport const usePreviewMetadata_unstable = (props, ref) => {\n const {\n icon,\n primaryText,\n secondaryText,\n tertiaryText\n } = props;\n return {\n components: {\n root: 'div',\n icon: 'span',\n primaryText: 'span',\n secondaryText: 'span',\n tertiaryText: 'span'\n },\n root: slot.always(getNativeElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n }),\n icon: slot.optional(icon, {\n elementType: 'span'\n }),\n primaryText: slot.optional(primaryText, {\n elementType: 'span'\n }),\n secondaryText: slot.optional(secondaryText, {\n elementType: 'span'\n }),\n tertiaryText: slot.optional(tertiaryText, {\n elementType: 'span'\n })\n };\n};\n//# sourceMappingURL=usePreviewMetadata.js.map"],"names":["usePreviewMetadata_unstable","props","ref","icon","primaryText","secondaryText","tertiaryText","components","root","slot","always","getNativeElementProps","elementType","optional"],"mappings":";;;;+BAUaA;;;eAAAA;;;iCAV+B;AAUrC,MAAMA,8BAA8B,CAACC,OAAOC;IACjD,MAAM,EACJC,IAAI,EACJC,WAAW,EACXC,aAAa,EACbC,YAAY,EACb,GAAGL;IACJ,OAAO;QACLM,YAAY;YACVC,MAAM;YACNL,MAAM;YACNC,aAAa;YACbC,eAAe;YACfC,cAAc;QAChB;QACAE,MAAMC,qBAAI,CAACC,MAAM,CAACC,IAAAA,sCAAqB,EAAC,OAAO;YAC7CT;YACA,GAAGD,KAAK;QACV,IAAI;YACFW,aAAa;QACf;QACAT,MAAMM,qBAAI,CAACI,QAAQ,CAACV,MAAM;YACxBS,aAAa;QACf;QACAR,aAAaK,qBAAI,CAACI,QAAQ,CAACT,aAAa;YACtCQ,aAAa;QACf;QACAP,eAAeI,qBAAI,CAACI,QAAQ,CAACR,eAAe;YAC1CO,aAAa;QACf;QACAN,cAAcG,qBAAI,CAACI,QAAQ,CAACP,cAAc;YACxCM,aAAa;QACf;IACF;AACF,GACA,8CAA8C"}
1
+ {"version":3,"sources":["usePreviewMetadata.js"],"sourcesContent":["import { getIntrinsicElementProps, slot } from '@fluentui/react-components';\n/**\n * Create the state required to render PreviewMetadata.\n *\n * The returned state can be modified with hooks such as usePreviewMetadataStyles_unstable,\n * before being passed to renderPreviewMetadata_unstable.\n *\n * @param props - props from this instance of PreviewMetadata\n * @param ref - reference to root HTMLElement of PreviewMetadata\n */\nexport const usePreviewMetadata_unstable = (props, ref) => {\n const {\n icon,\n primaryText,\n secondaryText,\n tertiaryText\n } = props;\n return {\n components: {\n root: 'div',\n icon: 'span',\n primaryText: 'span',\n secondaryText: 'span',\n tertiaryText: 'span'\n },\n root: slot.always(getIntrinsicElementProps('div', {\n ref,\n ...props\n }), {\n elementType: 'div'\n }),\n icon: slot.optional(icon, {\n elementType: 'span'\n }),\n primaryText: slot.optional(primaryText, {\n elementType: 'span'\n }),\n secondaryText: slot.optional(secondaryText, {\n elementType: 'span'\n }),\n tertiaryText: slot.optional(tertiaryText, {\n elementType: 'span'\n })\n };\n};\n//# sourceMappingURL=usePreviewMetadata.js.map"],"names":["usePreviewMetadata_unstable","props","ref","icon","primaryText","secondaryText","tertiaryText","components","root","slot","always","getIntrinsicElementProps","elementType","optional"],"mappings":";;;;+BAUaA;;;eAAAA;;;iCAVkC;AAUxC,MAAMA,8BAA8B,CAACC,OAAOC;IACjD,MAAM,EACJC,IAAI,EACJC,WAAW,EACXC,aAAa,EACbC,YAAY,EACb,GAAGL;IACJ,OAAO;QACLM,YAAY;YACVC,MAAM;YACNL,MAAM;YACNC,aAAa;YACbC,eAAe;YACfC,cAAc;QAChB;QACAE,MAAMC,qBAAI,CAACC,MAAM,CAACC,IAAAA,yCAAwB,EAAC,OAAO;YAChDT;YACA,GAAGD,KAAK;QACV,IAAI;YACFW,aAAa;QACf;QACAT,MAAMM,qBAAI,CAACI,QAAQ,CAACV,MAAM;YACxBS,aAAa;QACf;QACAR,aAAaK,qBAAI,CAACI,QAAQ,CAACT,aAAa;YACtCQ,aAAa;QACf;QACAP,eAAeI,qBAAI,CAACI,QAAQ,CAACR,eAAe;YAC1CO,aAAa;QACf;QACAN,cAAcG,qBAAI,CAACI,QAAQ,CAACP,cAAc;YACxCM,aAAa;QACf;IACF;AACF,GACA,8CAA8C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui-copilot/react-preview",
3
- "version": "0.0.0-nightly-20240403-0404-6f5eb4de.1",
3
+ "version": "0.0.0-nightly-20240404-0406-2afa9891.1",
4
4
  "description": "Preview components.",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",