@tamagui/image 1.0.1-beta.197 → 1.0.1-beta.198

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/dist/cjs/Image.js CHANGED
@@ -32,19 +32,12 @@ var import_core = require("@tamagui/core");
32
32
  var import_react = __toESM(require("react"));
33
33
  var import_react_native = require("react-native");
34
34
  import_react.default["createElement"];
35
- const StyledImage = (0, import_core.styled)(
36
- import_react_native.Image,
37
- {
38
- name: "Image",
39
- position: "relative",
40
- source: { uri: "" },
41
- zIndex: 1
42
- },
43
- {
44
- inlineProps: /* @__PURE__ */ new Set(["src", "width", "height"]),
45
- isReactNative: true
46
- }
47
- );
35
+ const StyledImage = (0, import_core.styled)(import_react_native.Image, {
36
+ name: "Image",
37
+ position: "relative",
38
+ source: { uri: "" },
39
+ zIndex: 1
40
+ });
48
41
  const Image = StyledImage.extractable((inProps) => {
49
42
  const props = (0, import_core.getExpandedShorthands)(inProps);
50
43
  const { src, ...rest } = props;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Image.tsx"],
4
- "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(\n RNImage,\n {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n },\n {\n inlineProps: new Set(['src', 'width', 'height']),\n isReactNative: true,\n }\n)\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAuCS;AAvCT,kBAA2E;AAC3E,mBAAkB;AAClB,0BAAiC;AAEjC,aAAAA,QAAM;AAEN,MAAM,kBAAc;AAAA,EAClB,oBAAAC;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,UAAU;AAAA,IACV,QAAQ,EAAE,KAAK,GAAG;AAAA,IAClB,QAAQ;AAAA,EACV;AAAA,EACA;AAAA,IACE,aAAa,oBAAI,IAAI,CAAC,OAAO,SAAS,QAAQ,CAAC;AAAA,IAC/C,eAAe;AAAA,EACjB;AACF;AAYO,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,YAAQ,mCAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,qBAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,4CAAC;AAAA,IAAY;AAAA,IAAiB,GAAI;AAAA,GAAc;AACzD,CAAC;",
4
+ "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(RNImage, {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n})\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAgCS;AAhCT,kBAA2E;AAC3E,mBAAkB;AAClB,0BAAiC;AAEjC,aAAAA,QAAM;AAEN,MAAM,kBAAc,oBAAO,oBAAAC,OAAS;AAAA,EAClC,MAAM;AAAA,EACN,UAAU;AAAA,EACV,QAAQ,EAAE,KAAK,GAAG;AAAA,EAClB,QAAQ;AACV,CAAC;AAYM,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,YAAQ,mCAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,qBAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,4CAAC;AAAA,IAAY;AAAA,IAAiB,GAAI;AAAA,GAAc;AACzD,CAAC;",
6
6
  "names": ["React", "RNImage"]
7
7
  }
package/dist/esm/Image.js CHANGED
@@ -3,19 +3,12 @@ import { getExpandedShorthands, isWeb, styled } from "@tamagui/core";
3
3
  import React from "react";
4
4
  import { Image as RNImage } from "react-native";
5
5
  React["createElement"];
6
- const StyledImage = styled(
7
- RNImage,
8
- {
9
- name: "Image",
10
- position: "relative",
11
- source: { uri: "" },
12
- zIndex: 1
13
- },
14
- {
15
- inlineProps: /* @__PURE__ */ new Set(["src", "width", "height"]),
16
- isReactNative: true
17
- }
18
- );
6
+ const StyledImage = styled(RNImage, {
7
+ name: "Image",
8
+ position: "relative",
9
+ source: { uri: "" },
10
+ zIndex: 1
11
+ });
19
12
  const Image = StyledImage.extractable((inProps) => {
20
13
  const props = getExpandedShorthands(inProps);
21
14
  const { src, ...rest } = props;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Image.tsx"],
4
- "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(\n RNImage,\n {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n },\n {\n inlineProps: new Set(['src', 'width', 'height']),\n isReactNative: true,\n }\n)\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
- "mappings": "AAuCS;AAvCT,SAA+B,uBAAuB,OAAO,cAAc;AAC3E,OAAO,WAAW;AAClB,SAAS,SAAS,eAAe;AAEjC,MAAM;AAEN,MAAM,cAAc;AAAA,EAClB;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,UAAU;AAAA,IACV,QAAQ,EAAE,KAAK,GAAG;AAAA,IAClB,QAAQ;AAAA,EACV;AAAA,EACA;AAAA,IACE,aAAa,oBAAI,IAAI,CAAC,OAAO,SAAS,QAAQ,CAAC;AAAA,IAC/C,eAAe;AAAA,EACjB;AACF;AAYO,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,QAAQ,sBAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,SAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,oBAAC;AAAA,IAAY;AAAA,IAAiB,GAAI;AAAA,GAAc;AACzD,CAAC;",
4
+ "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(RNImage, {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n})\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
+ "mappings": "AAgCS;AAhCT,SAA+B,uBAAuB,OAAO,cAAc;AAC3E,OAAO,WAAW;AAClB,SAAS,SAAS,eAAe;AAEjC,MAAM;AAEN,MAAM,cAAc,OAAO,SAAS;AAAA,EAClC,MAAM;AAAA,EACN,UAAU;AAAA,EACV,QAAQ,EAAE,KAAK,GAAG;AAAA,EAClB,QAAQ;AACV,CAAC;AAYM,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,QAAQ,sBAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,SAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,oBAAC;AAAA,IAAY;AAAA,IAAiB,GAAI;AAAA,GAAc;AACzD,CAAC;",
6
6
  "names": []
7
7
  }
package/dist/jsx/Image.js CHANGED
@@ -2,19 +2,12 @@ import { getExpandedShorthands, isWeb, styled } from "@tamagui/core";
2
2
  import React from "react";
3
3
  import { Image as RNImage } from "react-native";
4
4
  React["createElement"];
5
- const StyledImage = styled(
6
- RNImage,
7
- {
8
- name: "Image",
9
- position: "relative",
10
- source: { uri: "" },
11
- zIndex: 1
12
- },
13
- {
14
- inlineProps: /* @__PURE__ */ new Set(["src", "width", "height"]),
15
- isReactNative: true
16
- }
17
- );
5
+ const StyledImage = styled(RNImage, {
6
+ name: "Image",
7
+ position: "relative",
8
+ source: { uri: "" },
9
+ zIndex: 1
10
+ });
18
11
  const Image = StyledImage.extractable((inProps) => {
19
12
  const props = getExpandedShorthands(inProps);
20
13
  const { src, ...rest } = props;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Image.tsx"],
4
- "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(\n RNImage,\n {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n },\n {\n inlineProps: new Set(['src', 'width', 'height']),\n isReactNative: true,\n }\n)\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
- "mappings": "AAAA,SAA+B,uBAAuB,OAAO,cAAc;AAC3E,OAAO,WAAW;AAClB,SAAS,SAAS,eAAe;AAEjC,MAAM;AAEN,MAAM,cAAc;AAAA,EAClB;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,UAAU;AAAA,IACV,QAAQ,EAAE,KAAK,GAAG;AAAA,IAClB,QAAQ;AAAA,EACV;AAAA,EACA;AAAA,IACE,aAAa,oBAAI,IAAI,CAAC,OAAO,SAAS,QAAQ,CAAC;AAAA,IAC/C,eAAe;AAAA,EACjB;AACF;AAYO,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,QAAQ,sBAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,SAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,CAAC,YAAY,QAAQ,YAAa,MAAc;AACzD,CAAC;",
4
+ "sourcesContent": ["import { GetProps, StackProps, getExpandedShorthands, isWeb, styled } from '@tamagui/core'\nimport React from 'react'\nimport { Image as RNImage } from 'react-native'\n\nReact['createElement']\n\nconst StyledImage = styled(RNImage, {\n name: 'Image',\n position: 'relative',\n source: { uri: '' },\n zIndex: 1,\n})\n\ntype StyledImageProps = GetProps<typeof StyledImage>\n\ntype BaseProps = Omit<StyledImageProps, 'source' | 'width' | 'height' | 'style' | 'onLayout'> & {\n width: number | string\n height: number | string\n src: string | StyledImageProps['source']\n}\n\nexport type ImageProps = BaseProps & Omit<StackProps, keyof BaseProps>\n\nexport const Image: React.FC<ImageProps> = StyledImage.extractable((inProps) => {\n const props = getExpandedShorthands(inProps)\n const { src, ...rest } = props\n const source =\n typeof src === 'string'\n ? { uri: src, ...(isWeb && { width: props.width, height: props.height }) }\n : src\n\n // must set defaultSource to allow SSR, default it to the same as src\n return <StyledImage source={source} {...(rest as any)} />\n})\n"],
5
+ "mappings": "AAAA,SAA+B,uBAAuB,OAAO,cAAc;AAC3E,OAAO,WAAW;AAClB,SAAS,SAAS,eAAe;AAEjC,MAAM;AAEN,MAAM,cAAc,OAAO,SAAS;AAAA,EAClC,MAAM;AAAA,EACN,UAAU;AAAA,EACV,QAAQ,EAAE,KAAK,GAAG;AAAA,EAClB,QAAQ;AACV,CAAC;AAYM,MAAM,QAA8B,YAAY,YAAY,CAAC,YAAY;AAC9E,QAAM,QAAQ,sBAAsB,OAAO;AAC3C,QAAM,EAAE,QAAQ,KAAK,IAAI;AACzB,QAAM,SACJ,OAAO,QAAQ,WACX,EAAE,KAAK,KAAK,GAAI,SAAS,EAAE,OAAO,MAAM,OAAO,QAAQ,MAAM,OAAO,EAAG,IACvE;AAGN,SAAO,CAAC,YAAY,QAAQ,YAAa,MAAc;AACzD,CAAC;",
6
6
  "names": []
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/image",
3
- "version": "1.0.1-beta.197",
3
+ "version": "1.0.1-beta.198",
4
4
  "sideEffects": [
5
5
  "*.css"
6
6
  ],
@@ -23,14 +23,14 @@
23
23
  "clean:build": "tamagui-build clean:build"
24
24
  },
25
25
  "dependencies": {
26
- "@tamagui/core": "^1.0.1-beta.197"
26
+ "@tamagui/core": "^1.0.1-beta.198"
27
27
  },
28
28
  "peerDependencies": {
29
29
  "react": "*",
30
30
  "react-native": "*"
31
31
  },
32
32
  "devDependencies": {
33
- "@tamagui/build": "^1.0.1-beta.197",
33
+ "@tamagui/build": "^1.0.1-beta.198",
34
34
  "react": "*",
35
35
  "react-native": "*"
36
36
  },
package/src/Image.tsx CHANGED
@@ -4,19 +4,12 @@ import { Image as RNImage } from 'react-native'
4
4
 
5
5
  React['createElement']
6
6
 
7
- const StyledImage = styled(
8
- RNImage,
9
- {
10
- name: 'Image',
11
- position: 'relative',
12
- source: { uri: '' },
13
- zIndex: 1,
14
- },
15
- {
16
- inlineProps: new Set(['src', 'width', 'height']),
17
- isReactNative: true,
18
- }
19
- )
7
+ const StyledImage = styled(RNImage, {
8
+ name: 'Image',
9
+ position: 'relative',
10
+ source: { uri: '' },
11
+ zIndex: 1,
12
+ })
20
13
 
21
14
  type StyledImageProps = GetProps<typeof StyledImage>
22
15