@fluentui/react-image 0.0.0-nightly-20230501-0418.1 → 0.0.0-nightly-20230503-0419.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/react-image",
3
3
  "entries": [
4
4
  {
5
- "date": "Mon, 01 May 2023 04:24:17 GMT",
6
- "tag": "@fluentui/react-image_v0.0.0-nightly-20230501-0418.1",
7
- "version": "0.0.0-nightly-20230501-0418.1",
5
+ "date": "Wed, 03 May 2023 04:25:37 GMT",
6
+ "tag": "@fluentui/react-image_v0.0.0-nightly-20230503-0419.1",
7
+ "version": "0.0.0-nightly-20230503-0419.1",
8
8
  "comments": {
9
9
  "prerelease": [
10
10
  {
@@ -16,32 +16,32 @@
16
16
  {
17
17
  "author": "beachball",
18
18
  "package": "@fluentui/react-image",
19
- "comment": "Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230501-0418.1",
20
- "commit": "ec7f7770aa9dd65ad47721639ad0c5d238d9e037"
19
+ "comment": "Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230503-0419.1",
20
+ "commit": "a9a6cef152f4c3885a3697ddf9ded12bfce5a2be"
21
21
  },
22
22
  {
23
23
  "author": "beachball",
24
24
  "package": "@fluentui/react-image",
25
- "comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-20230501-0418.1",
26
- "commit": "ec7f7770aa9dd65ad47721639ad0c5d238d9e037"
25
+ "comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-20230503-0419.1",
26
+ "commit": "a9a6cef152f4c3885a3697ddf9ded12bfce5a2be"
27
27
  },
28
28
  {
29
29
  "author": "beachball",
30
30
  "package": "@fluentui/react-image",
31
- "comment": "Bump @fluentui/react-jsx-runtime to v0.0.0-nightly-20230501-0418.1",
32
- "commit": "ec7f7770aa9dd65ad47721639ad0c5d238d9e037"
31
+ "comment": "Bump @fluentui/react-jsx-runtime to v0.0.0-nightly-20230503-0419.1",
32
+ "commit": "a9a6cef152f4c3885a3697ddf9ded12bfce5a2be"
33
33
  },
34
34
  {
35
35
  "author": "beachball",
36
36
  "package": "@fluentui/react-image",
37
- "comment": "Bump @fluentui/react-theme to v0.0.0-nightly-20230501-0418.1",
38
- "commit": "ec7f7770aa9dd65ad47721639ad0c5d238d9e037"
37
+ "comment": "Bump @fluentui/react-theme to v0.0.0-nightly-20230503-0419.1",
38
+ "commit": "a9a6cef152f4c3885a3697ddf9ded12bfce5a2be"
39
39
  },
40
40
  {
41
41
  "author": "beachball",
42
42
  "package": "@fluentui/react-image",
43
- "comment": "Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20230501-0418.1",
44
- "commit": "ec7f7770aa9dd65ad47721639ad0c5d238d9e037"
43
+ "comment": "Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20230503-0419.1",
44
+ "commit": "a9a6cef152f4c3885a3697ddf9ded12bfce5a2be"
45
45
  }
46
46
  ]
47
47
  }
package/CHANGELOG.md CHANGED
@@ -1,22 +1,22 @@
1
1
  # Change Log - @fluentui/react-image
2
2
 
3
- This log was last generated on Mon, 01 May 2023 04:24:17 GMT and should not be manually modified.
3
+ This log was last generated on Wed, 03 May 2023 04:25:37 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
- ## [0.0.0-nightly-20230501-0418.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-image_v0.0.0-nightly-20230501-0418.1)
7
+ ## [0.0.0-nightly-20230503-0419.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-image_v0.0.0-nightly-20230503-0419.1)
8
8
 
9
- Mon, 01 May 2023 04:24:17 GMT
10
- [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-image_v9.1.7..@fluentui/react-image_v0.0.0-nightly-20230501-0418.1)
9
+ Wed, 03 May 2023 04:25:37 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-image_v9.1.7..@fluentui/react-image_v0.0.0-nightly-20230503-0419.1)
11
11
 
12
12
  ### Changes
13
13
 
14
14
  - Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/not available) by fluentui-internal@service.microsoft.com)
15
- - Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230501-0418.1 ([commit](https://github.com/microsoft/fluentui/commit/ec7f7770aa9dd65ad47721639ad0c5d238d9e037) by beachball)
16
- - Bump @fluentui/react-utilities to v0.0.0-nightly-20230501-0418.1 ([commit](https://github.com/microsoft/fluentui/commit/ec7f7770aa9dd65ad47721639ad0c5d238d9e037) by beachball)
17
- - Bump @fluentui/react-jsx-runtime to v0.0.0-nightly-20230501-0418.1 ([commit](https://github.com/microsoft/fluentui/commit/ec7f7770aa9dd65ad47721639ad0c5d238d9e037) by beachball)
18
- - Bump @fluentui/react-theme to v0.0.0-nightly-20230501-0418.1 ([commit](https://github.com/microsoft/fluentui/commit/ec7f7770aa9dd65ad47721639ad0c5d238d9e037) by beachball)
19
- - Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20230501-0418.1 ([commit](https://github.com/microsoft/fluentui/commit/ec7f7770aa9dd65ad47721639ad0c5d238d9e037) by beachball)
15
+ - Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230503-0419.1 ([commit](https://github.com/microsoft/fluentui/commit/a9a6cef152f4c3885a3697ddf9ded12bfce5a2be) by beachball)
16
+ - Bump @fluentui/react-utilities to v0.0.0-nightly-20230503-0419.1 ([commit](https://github.com/microsoft/fluentui/commit/a9a6cef152f4c3885a3697ddf9ded12bfce5a2be) by beachball)
17
+ - Bump @fluentui/react-jsx-runtime to v0.0.0-nightly-20230503-0419.1 ([commit](https://github.com/microsoft/fluentui/commit/a9a6cef152f4c3885a3697ddf9ded12bfce5a2be) by beachball)
18
+ - Bump @fluentui/react-theme to v0.0.0-nightly-20230503-0419.1 ([commit](https://github.com/microsoft/fluentui/commit/a9a6cef152f4c3885a3697ddf9ded12bfce5a2be) by beachball)
19
+ - Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20230503-0419.1 ([commit](https://github.com/microsoft/fluentui/commit/a9a6cef152f4c3885a3697ddf9ded12bfce5a2be) by beachball)
20
20
 
21
21
  ## [9.1.7](https://github.com/microsoft/fluentui/tree/@fluentui/react-image_v9.1.7)
22
22
 
@@ -0,0 +1,68 @@
1
+ import type { ComponentProps } from '@fluentui/react-utilities';
2
+ import type { ComponentState } from '@fluentui/react-utilities';
3
+ import type { ForwardRefComponent } from '@fluentui/react-utilities';
4
+ import * as React_2 from 'react';
5
+ import type { Slot } from '@fluentui/react-utilities';
6
+ import type { SlotClassNames } from '@fluentui/react-utilities';
7
+
8
+ /**
9
+ * The Image component ensures the consistent styling of images.
10
+ */
11
+ declare const Image_2: ForwardRefComponent<ImageProps>;
12
+ export { Image_2 as Image }
13
+
14
+ export declare const imageClassNames: SlotClassNames<ImageSlots>;
15
+
16
+ export declare type ImageProps = ComponentProps<ImageSlots> & {
17
+ /**
18
+ * An image can take up the width of its container.
19
+ *
20
+ * @default false
21
+ */
22
+ block?: boolean;
23
+ /**
24
+ * An image can appear with a rectangular border.
25
+ *
26
+ * @default false
27
+ */
28
+ bordered?: boolean;
29
+ /**
30
+ * An image can set how it should be resized to fit its container.
31
+ *
32
+ * @default 'default'
33
+ */
34
+ fit?: 'none' | 'center' | 'contain' | 'cover' | 'default';
35
+ /**
36
+ * An image can appear elevated with shadow.
37
+ *
38
+ * @default false
39
+ */
40
+ shadow?: boolean;
41
+ /**
42
+ * An image can appear square, circular, or rounded.
43
+ *
44
+ * @default 'square'
45
+ */
46
+ shape?: 'square' | 'circular' | 'rounded';
47
+ };
48
+
49
+ export declare type ImageSlots = {
50
+ root: Slot<'img'>;
51
+ };
52
+
53
+ export declare type ImageState = ComponentState<ImageSlots> & Required<Pick<ImageProps, 'block' | 'bordered' | 'fit' | 'shadow' | 'shape'>>;
54
+
55
+ /**
56
+ * Define the render function.
57
+ * Given the state of an image, renders it.
58
+ */
59
+ export declare const renderImage_unstable: (state: ImageState) => JSX.Element;
60
+
61
+ /**
62
+ * Given user props, returns state and render function for an Image.
63
+ */
64
+ export declare const useImage_unstable: (props: ImageProps, ref: React_2.Ref<HTMLImageElement>) => ImageState;
65
+
66
+ export declare const useImageStyles_unstable: (state: ImageState) => void;
67
+
68
+ export { }
package/lib/Image.js ADDED
@@ -0,0 +1,2 @@
1
+ export * from './components/Image/index';
2
+ //# sourceMappingURL=Image.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["../src/Image.ts"],"sourcesContent":["export * from './components/Image/index';\n"],"mappings":"AAAA,cAAc"}
@@ -0,0 +1,16 @@
1
+ import * as React from 'react';
2
+ import { renderImage_unstable } from './renderImage';
3
+ import { useImage_unstable } from './useImage';
4
+ import { useImageStyles_unstable } from './useImageStyles.styles';
5
+ import { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';
6
+ /**
7
+ * The Image component ensures the consistent styling of images.
8
+ */
9
+ export const Image = /*#__PURE__*/React.forwardRef((props, ref) => {
10
+ const state = useImage_unstable(props, ref);
11
+ useImageStyles_unstable(state);
12
+ useCustomStyleHook_unstable('useImageStyles_unstable')(state);
13
+ return renderImage_unstable(state);
14
+ });
15
+ Image.displayName = 'Image';
16
+ //# sourceMappingURL=Image.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","renderImage_unstable","useImage_unstable","useImageStyles_unstable","useCustomStyleHook_unstable","Image","forwardRef","props","ref","state","displayName"],"sources":["../../../src/components/Image/Image.tsx"],"sourcesContent":["import * as React from 'react';\nimport { renderImage_unstable } from './renderImage';\nimport { useImage_unstable } from './useImage';\nimport { useImageStyles_unstable } from './useImageStyles.styles';\nimport type { ImageProps } from './Image.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * The Image component ensures the consistent styling of images.\n */\nexport const Image: ForwardRefComponent<ImageProps> = React.forwardRef((props, ref) => {\n const state = useImage_unstable(props, ref);\n\n useImageStyles_unstable(state);\n\n useCustomStyleHook_unstable('useImageStyles_unstable')(state);\n\n return renderImage_unstable(state);\n});\n\nImage.displayName = 'Image';\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,oBAAoB,QAAQ;AACrC,SAASC,iBAAiB,QAAQ;AAClC,SAASC,uBAAuB,QAAQ;AAGxC,SAASC,2BAA2B,QAAQ;AAE5C;;;AAGA,OAAO,MAAMC,KAAA,gBAAyCL,KAAA,CAAMM,UAAU,CAAC,CAACC,KAAA,EAAOC,GAAA,KAAQ;EACrF,MAAMC,KAAA,GAAQP,iBAAA,CAAkBK,KAAA,EAAOC,GAAA;EAEvCL,uBAAA,CAAwBM,KAAA;EAExBL,2BAAA,CAA4B,2BAA2BK,KAAA;EAEvD,OAAOR,oBAAA,CAAqBQ,KAAA;AAC9B;AAEAJ,KAAA,CAAMK,WAAW,GAAG"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=Image.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["../../../src/components/Image/Image.types.ts"],"sourcesContent":["import type { ComponentState, ComponentProps, Slot } from '@fluentui/react-utilities';\n\nexport type ImageSlots = {\n root: Slot<'img'>;\n};\n\nexport type ImageProps = ComponentProps<ImageSlots> & {\n /**\n * An image can take up the width of its container.\n *\n * @default false\n */\n block?: boolean;\n\n /**\n * An image can appear with a rectangular border.\n *\n * @default false\n */\n bordered?: boolean;\n\n /**\n * An image can set how it should be resized to fit its container.\n *\n * @default 'default'\n */\n fit?: 'none' | 'center' | 'contain' | 'cover' | 'default';\n\n /**\n * An image can appear elevated with shadow.\n *\n * @default false\n */\n shadow?: boolean;\n\n /**\n * An image can appear square, circular, or rounded.\n *\n * @default 'square'\n */\n shape?: 'square' | 'circular' | 'rounded';\n};\n\nexport type ImageState = ComponentState<ImageSlots> &\n Required<Pick<ImageProps, 'block' | 'bordered' | 'fit' | 'shadow' | 'shape'>>;\n"],"mappings":"AAAA"}
@@ -0,0 +1,6 @@
1
+ export * from './Image.types';
2
+ export * from './Image';
3
+ export * from './renderImage';
4
+ export * from './useImage';
5
+ export * from './useImageStyles.styles';
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["../../../src/components/Image/index.ts"],"sourcesContent":["export * from './Image.types';\nexport * from './Image';\nexport * from './renderImage';\nexport * from './useImage';\nexport * from './useImageStyles.styles';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc"}
@@ -0,0 +1,14 @@
1
+ /** @jsxRuntime classic */ /** @jsx createElement */import { createElement } from '@fluentui/react-jsx-runtime';
2
+ import { getSlotsNext } from '@fluentui/react-utilities';
3
+ /**
4
+ * Define the render function.
5
+ * Given the state of an image, renders it.
6
+ */
7
+ export const renderImage_unstable = state => {
8
+ const {
9
+ slots,
10
+ slotProps
11
+ } = getSlotsNext(state);
12
+ return /*#__PURE__*/createElement(slots.root, slotProps.root);
13
+ };
14
+ //# sourceMappingURL=renderImage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["createElement","getSlotsNext","renderImage_unstable","state","slots","slotProps","root"],"sources":["../../../src/components/Image/renderImage.tsx"],"sourcesContent":["/** @jsxRuntime classic */\n/** @jsx createElement */\n\nimport { createElement } from '@fluentui/react-jsx-runtime';\n\nimport { getSlotsNext } from '@fluentui/react-utilities';\nimport { ImageSlots, ImageState } from './Image.types';\n\n/**\n * Define the render function.\n * Given the state of an image, renders it.\n */\nexport const renderImage_unstable = (state: ImageState) => {\n const { slots, slotProps } = getSlotsNext<ImageSlots>(state);\n\n return <slots.root {...slotProps.root} />;\n};\n"],"mappings":"AAAA,2BACA,yBAEA,SAASA,aAAa,QAAQ;AAE9B,SAASC,YAAY,QAAQ;AAG7B;;;;AAIA,OAAO,MAAMC,oBAAA,GAAwBC,KAAA,IAAsB;EACzD,MAAM;IAAEC,KAAA;IAAOC;EAAS,CAAE,GAAGJ,YAAA,CAAyBE,KAAA;EAEtD,oBAAOH,aAdT,CAcUI,KAAA,CAAME,IAAI,EAAKD,SAAA,CAAUC,IAAI;AACvC"}
@@ -0,0 +1,30 @@
1
+ import * as React from 'react';
2
+ import { getNativeElementProps } from '@fluentui/react-utilities';
3
+ /**
4
+ * Given user props, returns state and render function for an Image.
5
+ */
6
+ export const useImage_unstable = (props, ref) => {
7
+ const {
8
+ bordered = false,
9
+ fit = 'default',
10
+ block = false,
11
+ shape = 'square',
12
+ shadow = false
13
+ } = props;
14
+ const state = {
15
+ bordered,
16
+ fit,
17
+ block,
18
+ shape,
19
+ shadow,
20
+ components: {
21
+ root: 'img'
22
+ },
23
+ root: getNativeElementProps('img', {
24
+ ref,
25
+ ...props
26
+ })
27
+ };
28
+ return state;
29
+ };
30
+ //# sourceMappingURL=useImage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","getNativeElementProps","useImage_unstable","props","ref","bordered","fit","block","shape","shadow","state","components","root"],"sources":["../../../src/components/Image/useImage.ts"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { ImageProps, ImageState } from './Image.types';\n\n/**\n * Given user props, returns state and render function for an Image.\n */\nexport const useImage_unstable = (props: ImageProps, ref: React.Ref<HTMLImageElement>): ImageState => {\n const { bordered = false, fit = 'default', block = false, shape = 'square', shadow = false } = props;\n\n const state: ImageState = {\n bordered,\n fit,\n block,\n shape,\n shadow,\n components: {\n root: 'img',\n },\n root: getNativeElementProps('img', {\n ref,\n ...props,\n }),\n };\n\n return state;\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,qBAAqB,QAAQ;AAGtC;;;AAGA,OAAO,MAAMC,iBAAA,GAAoBA,CAACC,KAAA,EAAmBC,GAAA,KAAiD;EACpG,MAAM;IAAEC,QAAA,GAAW,KAAK;IAAEC,GAAA,GAAM;IAAWC,KAAA,GAAQ,KAAK;IAAEC,KAAA,GAAQ;IAAUC,MAAA,GAAS;EAAK,CAAE,GAAGN,KAAA;EAE/F,MAAMO,KAAA,GAAoB;IACxBL,QAAA;IACAC,GAAA;IACAC,KAAA;IACAC,KAAA;IACAC,MAAA;IACAE,UAAA,EAAY;MACVC,IAAA,EAAM;IACR;IACAA,IAAA,EAAMX,qBAAA,CAAsB,OAAO;MACjCG,GAAA;MACA,GAAGD;IACL;EACF;EAEA,OAAOO,KAAA;AACT"}
@@ -0,0 +1,80 @@
1
+ import { shorthands, mergeClasses, __styles } from '@griffel/react';
2
+ import { tokens } from '@fluentui/react-theme';
3
+ export const imageClassNames = {
4
+ root: 'fui-Image'
5
+ };
6
+ const useStyles = /*#__PURE__*/__styles({
7
+ base: {
8
+ g2u3we: "fj3muxo",
9
+ h3c5rm: ["f1akhkt", "f1lxtadh"],
10
+ B9xav0g: "f1aperda",
11
+ zhjwy3: ["f1lxtadh", "f1akhkt"],
12
+ Bbmb7ep: ["fzi6hpg", "fyowgf4"],
13
+ Beyfa6y: ["fyowgf4", "fzi6hpg"],
14
+ B7oj6ja: ["f3fg2lr", "f13av6d4"],
15
+ Btl43ni: ["f13av6d4", "f3fg2lr"],
16
+ B7ck84d: "f1ewtqcl",
17
+ mc9l5x: "f14t3ns0"
18
+ },
19
+ bordered: {
20
+ icvyot: "fzkkow9",
21
+ vrafjx: ["fcdblym", "fjik90z"],
22
+ oivjwe: "fg706s2",
23
+ wvpqe5: ["fjik90z", "fcdblym"],
24
+ B4j52fo: "f192inf7",
25
+ Bekrc4i: ["f5tn483", "f1ojsxk5"],
26
+ Bn0qgzm: "f1vxd6vx",
27
+ ibv6hh: ["f1ojsxk5", "f5tn483"]
28
+ },
29
+ circular: {
30
+ Bbmb7ep: ["f8fbkgy", "f1nfllo7"],
31
+ Beyfa6y: ["f1nfllo7", "f8fbkgy"],
32
+ B7oj6ja: ["f1djnp8u", "f1s8kh49"],
33
+ Btl43ni: ["f1s8kh49", "f1djnp8u"]
34
+ },
35
+ rounded: {
36
+ Bbmb7ep: ["f1aa9q02", "f16jpd5f"],
37
+ Beyfa6y: ["f16jpd5f", "f1aa9q02"],
38
+ B7oj6ja: ["f1jar5jt", "fyu767a"],
39
+ Btl43ni: ["fyu767a", "f1jar5jt"]
40
+ },
41
+ square: {},
42
+ shadow: {
43
+ E5pizo: "f1whvlc6"
44
+ },
45
+ center: {
46
+ st4lth: "f1plgu50",
47
+ Ermj5k: "f14xojzb",
48
+ Bqenvij: "f1l02sjl",
49
+ a9b677: "fly5x3f"
50
+ },
51
+ contain: {
52
+ st4lth: "f1kle4es",
53
+ Ermj5k: "f14xojzb",
54
+ Bqenvij: "f1l02sjl",
55
+ a9b677: "fly5x3f"
56
+ },
57
+ "default": {},
58
+ cover: {
59
+ st4lth: "f1ps3kmd",
60
+ Ermj5k: "f14xojzb",
61
+ Bqenvij: "f1l02sjl",
62
+ a9b677: "fly5x3f"
63
+ },
64
+ none: {
65
+ st4lth: "f1plgu50",
66
+ Ermj5k: ["f13uwng7", "fjmyj0p"],
67
+ Bqenvij: "f1l02sjl",
68
+ a9b677: "fly5x3f"
69
+ },
70
+ block: {
71
+ a9b677: "fly5x3f"
72
+ }
73
+ }, {
74
+ d: [".fj3muxo{border-top-color:var(--colorNeutralStroke1);}", ".f1akhkt{border-right-color:var(--colorNeutralStroke1);}", ".f1lxtadh{border-left-color:var(--colorNeutralStroke1);}", ".f1aperda{border-bottom-color:var(--colorNeutralStroke1);}", ".fzi6hpg{border-bottom-right-radius:var(--borderRadiusNone);}", ".fyowgf4{border-bottom-left-radius:var(--borderRadiusNone);}", ".f3fg2lr{border-top-right-radius:var(--borderRadiusNone);}", ".f13av6d4{border-top-left-radius:var(--borderRadiusNone);}", ".f1ewtqcl{box-sizing:border-box;}", ".f14t3ns0{display:inline-block;}", ".fzkkow9{border-top-style:solid;}", ".fcdblym{border-right-style:solid;}", ".fjik90z{border-left-style:solid;}", ".fg706s2{border-bottom-style:solid;}", ".f192inf7{border-top-width:var(--strokeWidthThin);}", ".f5tn483{border-right-width:var(--strokeWidthThin);}", ".f1ojsxk5{border-left-width:var(--strokeWidthThin);}", ".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}", ".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}", ".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}", ".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}", ".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}", ".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}", ".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}", ".f1whvlc6{box-shadow:var(--shadow4);}", ".f1plgu50{object-fit:none;}", ".f14xojzb{object-position:center;}", ".f1l02sjl{height:100%;}", ".fly5x3f{width:100%;}", ".f1kle4es{object-fit:contain;}", ".f1ps3kmd{object-fit:cover;}", ".f13uwng7{object-position:left top;}", ".fjmyj0p{object-position:right top;}"]
75
+ });
76
+ export const useImageStyles_unstable = state => {
77
+ const styles = useStyles();
78
+ state.root.className = mergeClasses(imageClassNames.root, styles.base, state.block && styles.block, state.bordered && styles.bordered, state.shadow && styles.shadow, styles[state.fit], styles[state.shape], state.root.className);
79
+ };
80
+ //# sourceMappingURL=useImageStyles.styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["shorthands","mergeClasses","__styles","tokens","imageClassNames","root","useStyles","base","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bbmb7ep","Beyfa6y","B7oj6ja","Btl43ni","B7ck84d","mc9l5x","bordered","icvyot","vrafjx","oivjwe","wvpqe5","B4j52fo","Bekrc4i","Bn0qgzm","ibv6hh","circular","rounded","square","shadow","E5pizo","center","st4lth","Ermj5k","Bqenvij","a9b677","contain","cover","none","block","d","useImageStyles_unstable","state","styles","className","fit","shape"],"sources":["../../../src/components/Image/useImageStyles.styles.ts"],"sourcesContent":["import { shorthands, mergeClasses, makeStyles } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { ImageSlots, ImageState } from './Image.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const imageClassNames: SlotClassNames<ImageSlots> = {\n root: 'fui-Image',\n};\n\nconst useStyles = makeStyles({\n // Base styles\n base: {\n ...shorthands.borderColor(tokens.colorNeutralStroke1),\n ...shorthands.borderRadius(tokens.borderRadiusNone),\n\n boxSizing: 'border-box',\n display: 'inline-block',\n },\n\n // Bordered styles\n bordered: {\n ...shorthands.borderStyle('solid'),\n ...shorthands.borderWidth(tokens.strokeWidthThin),\n },\n\n // Shape variations\n circular: {\n ...shorthands.borderRadius(tokens.borderRadiusCircular),\n },\n rounded: {\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n },\n square: {\n /* The square styles are exactly the same as the base styles. */\n },\n\n // Shadow styles\n shadow: {\n boxShadow: tokens.shadow4,\n },\n\n // Fit variations\n center: {\n objectFit: 'none',\n objectPosition: 'center',\n height: '100%',\n width: '100%',\n },\n contain: {\n objectFit: 'contain',\n objectPosition: 'center',\n height: '100%',\n width: '100%',\n },\n default: {\n /* The default styles are exactly the same as the base styles. */\n },\n cover: {\n objectFit: 'cover',\n objectPosition: 'center',\n height: '100%',\n width: '100%',\n },\n none: {\n objectFit: 'none',\n objectPosition: 'left top',\n height: '100%',\n width: '100%',\n },\n\n // Block styles\n block: {\n width: '100%',\n },\n});\n\nexport const useImageStyles_unstable = (state: ImageState) => {\n const styles = useStyles();\n state.root.className = mergeClasses(\n imageClassNames.root,\n styles.base,\n state.block && styles.block,\n state.bordered && styles.bordered,\n state.shadow && styles.shadow,\n styles[state.fit],\n styles[state.shape],\n state.root.className,\n );\n};\n"],"mappings":"AAAA,SAASA,UAAU,EAAEC,YAAY,EAAAC,QAAA,QAAoB;AACrD,SAASC,MAAM,QAAQ;AAIvB,OAAO,MAAMC,eAAA,GAA8C;EACzDC,IAAA,EAAM;AACR;AAEA,MAAMC,SAAA,gBAAYJ,QAAA;EAAAK,IAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAC,QAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAC,QAAA;IAAAf,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;EAAAa,OAAA;IAAAhB,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;EAAAc,MAAA;EAAAC,MAAA;IAAAC,MAAA;EAAA;EAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAC,OAAA;IAAAJ,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAA;EAAAE,KAAA;IAAAL,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAG,IAAA;IAAAN,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAI,KAAA;IAAAJ,MAAA;EAAA;AAAA;EAAAK,CAAA;AAAA,EAiElB;AAEA,OAAO,MAAMC,uBAAA,GAA2BC,KAAA,IAAsB;EAC5D,MAAMC,MAAA,GAAStC,SAAA;EACfqC,KAAA,CAAMtC,IAAI,CAACwC,SAAS,GAAG5C,YAAA,CACrBG,eAAA,CAAgBC,IAAI,EACpBuC,MAAA,CAAOrC,IAAI,EACXoC,KAAA,CAAMH,KAAK,IAAII,MAAA,CAAOJ,KAAK,EAC3BG,KAAA,CAAMzB,QAAQ,IAAI0B,MAAA,CAAO1B,QAAQ,EACjCyB,KAAA,CAAMb,MAAM,IAAIc,MAAA,CAAOd,MAAM,EAC7Bc,MAAM,CAACD,KAAA,CAAMG,GAAG,CAAC,EACjBF,MAAM,CAACD,KAAA,CAAMI,KAAK,CAAC,EACnBJ,KAAA,CAAMtC,IAAI,CAACwC,SAAS;AAExB"}
package/lib/index.js ADDED
@@ -0,0 +1,2 @@
1
+ export { Image, imageClassNames, renderImage_unstable, useImageStyles_unstable, useImage_unstable } from './Image';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Image","imageClassNames","renderImage_unstable","useImageStyles_unstable","useImage_unstable"],"sources":["../src/index.ts"],"sourcesContent":["export { Image, imageClassNames, renderImage_unstable, useImageStyles_unstable, useImage_unstable } from './Image';\nexport type { ImageProps, ImageSlots, ImageState } from './Image';\n"],"mappings":"AAAA,SAASA,KAAK,EAAEC,eAAe,EAAEC,oBAAoB,EAAEC,uBAAuB,EAAEC,iBAAiB,QAAQ"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui/react-image",
3
- "version": "0.0.0-nightly-20230501-0418.1",
3
+ "version": "0.0.0-nightly-20230503-0419.1",
4
4
  "description": "Fluent UI React Image component.",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -27,16 +27,16 @@
27
27
  "devDependencies": {
28
28
  "@fluentui/eslint-plugin": "*",
29
29
  "@fluentui/react-conformance": "*",
30
- "@fluentui/react-conformance-griffel": "0.0.0-nightly-20230501-0418.1",
30
+ "@fluentui/react-conformance-griffel": "0.0.0-nightly-20230503-0419.1",
31
31
  "@fluentui/scripts-api-extractor": "*",
32
32
  "@fluentui/scripts-tasks": "*"
33
33
  },
34
34
  "dependencies": {
35
35
  "@griffel/react": "^1.5.2",
36
- "@fluentui/react-shared-contexts": "0.0.0-nightly-20230501-0418.1",
37
- "@fluentui/react-utilities": "0.0.0-nightly-20230501-0418.1",
38
- "@fluentui/react-jsx-runtime": "0.0.0-nightly-20230501-0418.1",
39
- "@fluentui/react-theme": "0.0.0-nightly-20230501-0418.1",
36
+ "@fluentui/react-shared-contexts": "0.0.0-nightly-20230503-0419.1",
37
+ "@fluentui/react-utilities": "0.0.0-nightly-20230503-0419.1",
38
+ "@fluentui/react-jsx-runtime": "0.0.0-nightly-20230503-0419.1",
39
+ "@fluentui/react-theme": "0.0.0-nightly-20230503-0419.1",
40
40
  "@swc/helpers": "^0.4.14"
41
41
  },
42
42
  "peerDependencies": {