@tamagui/shapes 1.14.0 → 1.14.2
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/Circle.js +33 -1
- package/dist/cjs/Circle.js.map +2 -2
- package/dist/cjs/Square.js +45 -1
- package/dist/cjs/Square.js.map +2 -2
- package/dist/cjs/getShapeSize.js +39 -1
- package/dist/cjs/getShapeSize.js.map +2 -2
- package/dist/cjs/index.js +20 -1
- package/dist/cjs/index.js.map +2 -2
- package/dist/esm/Circle.js +9 -1
- package/dist/esm/Circle.js.map +2 -2
- package/dist/esm/Circle.mjs +9 -1
- package/dist/esm/Circle.mjs.map +2 -2
- package/dist/esm/Square.js +21 -1
- package/dist/esm/Square.js.map +2 -2
- package/dist/esm/Square.mjs +21 -1
- package/dist/esm/Square.mjs.map +2 -2
- package/dist/esm/getShapeSize.js +15 -1
- package/dist/esm/getShapeSize.js.map +2 -2
- package/dist/esm/getShapeSize.mjs +15 -1
- package/dist/esm/getShapeSize.mjs.map +2 -2
- package/dist/esm/index.js +3 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/index.mjs +3 -1
- package/dist/esm/index.mjs.map +1 -1
- package/dist/jsx/Circle.js +9 -1
- package/dist/jsx/Circle.js.map +2 -2
- package/dist/jsx/Circle.mjs +9 -1
- package/dist/jsx/Circle.mjs.map +2 -2
- package/dist/jsx/Square.js +21 -1
- package/dist/jsx/Square.js.map +2 -2
- package/dist/jsx/Square.mjs +21 -1
- package/dist/jsx/Square.mjs.map +2 -2
- package/dist/jsx/getShapeSize.js +15 -1
- package/dist/jsx/getShapeSize.js.map +2 -2
- package/dist/jsx/getShapeSize.mjs +15 -1
- package/dist/jsx/getShapeSize.mjs.map +2 -2
- package/dist/jsx/index.js +3 -1
- package/dist/jsx/index.js.map +1 -1
- package/dist/jsx/index.mjs +3 -1
- package/dist/jsx/index.mjs.map +1 -1
- package/package.json +4 -4
package/dist/cjs/Circle.js
CHANGED
|
@@ -1,2 +1,34 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var Circle_exports = {};
|
|
20
|
+
__export(Circle_exports, {
|
|
21
|
+
Circle: () => Circle
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(Circle_exports);
|
|
24
|
+
var import_web = require("@tamagui/web");
|
|
25
|
+
var import_Square = require("./Square");
|
|
26
|
+
const Circle = (0, import_web.styled)(import_Square.Square, {
|
|
27
|
+
name: "Circle",
|
|
28
|
+
circular: true
|
|
29
|
+
});
|
|
30
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
31
|
+
0 && (module.exports = {
|
|
32
|
+
Circle
|
|
33
|
+
});
|
|
2
34
|
//# sourceMappingURL=Circle.js.map
|
package/dist/cjs/Circle.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Circle.tsx"],
|
|
4
4
|
"sourcesContent": ["import { GetProps, styled } from '@tamagui/web'\n\nimport { Square } from './Square'\n\nexport const Circle = styled(Square, {\n name: 'Circle',\n circular: true,\n})\n\nexport type CircleProps = GetProps<typeof Circle>\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iBAAiC;AAEjC,oBAAuB;AAEhB,MAAM,aAAS,mBAAO,sBAAQ;AAAA,EACnC,MAAM;AAAA,EACN,UAAU;AACZ,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/cjs/Square.js
CHANGED
|
@@ -1,2 +1,46 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var Square_exports = {};
|
|
20
|
+
__export(Square_exports, {
|
|
21
|
+
Square: () => Square
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(Square_exports);
|
|
24
|
+
var import_stacks = require("@tamagui/stacks");
|
|
25
|
+
var import_web = require("@tamagui/web");
|
|
26
|
+
var import_getShapeSize = require("./getShapeSize");
|
|
27
|
+
const Square = (0, import_web.styled)(import_stacks.ThemeableStack, {
|
|
28
|
+
name: "Square",
|
|
29
|
+
alignItems: "center",
|
|
30
|
+
justifyContent: "center",
|
|
31
|
+
variants: {
|
|
32
|
+
circular: {
|
|
33
|
+
true: {
|
|
34
|
+
borderRadius: 1e5
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
size: {
|
|
38
|
+
"...size": import_getShapeSize.getShapeSize
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
43
|
+
0 && (module.exports = {
|
|
44
|
+
Square
|
|
45
|
+
});
|
|
2
46
|
//# sourceMappingURL=Square.js.map
|
package/dist/cjs/Square.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Square.tsx"],
|
|
4
4
|
"sourcesContent": ["import { ThemeableStack } from '@tamagui/stacks'\nimport { GetProps, styled } from '@tamagui/web'\n\nimport { getShapeSize } from './getShapeSize'\n\nexport const Square = styled(ThemeableStack, {\n name: 'Square',\n alignItems: 'center',\n justifyContent: 'center',\n\n variants: {\n circular: {\n true: {\n borderRadius: 100_000,\n },\n },\n\n size: {\n '...size': getShapeSize,\n },\n } as const,\n})\n\nexport type SquareProps = GetProps<typeof Square>\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAA+B;AAC/B,iBAAiC;AAEjC,0BAA6B;AAEtB,MAAM,aAAS,mBAAO,8BAAgB;AAAA,EAC3C,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAEhB,UAAU;AAAA,IACR,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,cAAc;AAAA,MAChB;AAAA,IACF;AAAA,IAEA,MAAM;AAAA,MACJ,WAAW;AAAA,IACb;AAAA,EACF;AACF,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/cjs/getShapeSize.js
CHANGED
|
@@ -1,2 +1,40 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var getShapeSize_exports = {};
|
|
20
|
+
__export(getShapeSize_exports, {
|
|
21
|
+
getShapeSize: () => getShapeSize
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(getShapeSize_exports);
|
|
24
|
+
const getShapeSize = (size, { tokens }) => {
|
|
25
|
+
const width = tokens.size[size] ?? size;
|
|
26
|
+
const height = tokens.size[size] ?? size;
|
|
27
|
+
return {
|
|
28
|
+
width,
|
|
29
|
+
height,
|
|
30
|
+
minWidth: width,
|
|
31
|
+
maxWidth: width,
|
|
32
|
+
maxHeight: height,
|
|
33
|
+
minHeight: height
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
37
|
+
0 && (module.exports = {
|
|
38
|
+
getShapeSize
|
|
39
|
+
});
|
|
2
40
|
//# sourceMappingURL=getShapeSize.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/getShapeSize.tsx"],
|
|
4
4
|
"sourcesContent": ["import { SizableStackProps } from '@tamagui/stacks'\nimport { SizeVariantSpreadFunction } from '@tamagui/web'\n\nexport const getShapeSize: SizeVariantSpreadFunction<SizableStackProps> = (\n size,\n { tokens }\n) => {\n const width = tokens.size[size] ?? size\n const height = tokens.size[size] ?? size\n return {\n width,\n height,\n minWidth: width,\n maxWidth: width,\n maxHeight: height,\n minHeight: height,\n }\n}\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGO,MAAM,eAA6D,CACxE,MACA,EAAE,OAAO,MACN;AACH,QAAM,QAAQ,OAAO,KAAK,IAAI,KAAK;AACnC,QAAM,SAAS,OAAO,KAAK,IAAI,KAAK;AACpC,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,EACb;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
16
|
+
var src_exports = {};
|
|
17
|
+
module.exports = __toCommonJS(src_exports);
|
|
18
|
+
__reExport(src_exports, require("./Square"), module.exports);
|
|
19
|
+
__reExport(src_exports, require("./Circle"), module.exports);
|
|
20
|
+
__reExport(src_exports, require("./getShapeSize"), module.exports);
|
|
2
21
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["export * from './Square'\nexport * from './Circle'\nexport * from './getShapeSize'\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,wBAAc,qBAAd;AACA,wBAAc,qBADd;AAEA,wBAAc,2BAFd;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/Circle.js
CHANGED
|
@@ -1,2 +1,10 @@
|
|
|
1
|
-
import{styled
|
|
1
|
+
import { styled } from "@tamagui/web";
|
|
2
|
+
import { Square } from "./Square";
|
|
3
|
+
const Circle = styled(Square, {
|
|
4
|
+
name: "Circle",
|
|
5
|
+
circular: true
|
|
6
|
+
});
|
|
7
|
+
export {
|
|
8
|
+
Circle
|
|
9
|
+
};
|
|
2
10
|
//# sourceMappingURL=Circle.js.map
|
package/dist/esm/Circle.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Circle.tsx"],
|
|
4
4
|
"sourcesContent": ["import { GetProps, styled } from '@tamagui/web'\n\nimport { Square } from './Square'\n\nexport const Circle = styled(Square, {\n name: 'Circle',\n circular: true,\n})\n\nexport type CircleProps = GetProps<typeof Circle>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAmB,cAAc;AAEjC,SAAS,cAAc;AAEhB,MAAM,SAAS,OAAO,QAAQ;AAAA,EACnC,MAAM;AAAA,EACN,UAAU;AACZ,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/Circle.mjs
CHANGED
|
@@ -1,2 +1,10 @@
|
|
|
1
|
-
import{styled
|
|
1
|
+
import { styled } from "@tamagui/web";
|
|
2
|
+
import { Square } from "./Square";
|
|
3
|
+
const Circle = styled(Square, {
|
|
4
|
+
name: "Circle",
|
|
5
|
+
circular: true
|
|
6
|
+
});
|
|
7
|
+
export {
|
|
8
|
+
Circle
|
|
9
|
+
};
|
|
2
10
|
//# sourceMappingURL=Circle.mjs.map
|
package/dist/esm/Circle.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Circle.tsx"],
|
|
4
4
|
"sourcesContent": ["import { GetProps, styled } from '@tamagui/web'\n\nimport { Square } from './Square'\n\nexport const Circle = styled(Square, {\n name: 'Circle',\n circular: true,\n})\n\nexport type CircleProps = GetProps<typeof Circle>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAmB,cAAc;AAEjC,SAAS,cAAc;AAEhB,MAAM,SAAS,OAAO,QAAQ;AAAA,EACnC,MAAM;AAAA,EACN,UAAU;AACZ,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/Square.js
CHANGED
|
@@ -1,2 +1,22 @@
|
|
|
1
|
-
import{ThemeableStack
|
|
1
|
+
import { ThemeableStack } from "@tamagui/stacks";
|
|
2
|
+
import { styled } from "@tamagui/web";
|
|
3
|
+
import { getShapeSize } from "./getShapeSize";
|
|
4
|
+
const Square = styled(ThemeableStack, {
|
|
5
|
+
name: "Square",
|
|
6
|
+
alignItems: "center",
|
|
7
|
+
justifyContent: "center",
|
|
8
|
+
variants: {
|
|
9
|
+
circular: {
|
|
10
|
+
true: {
|
|
11
|
+
borderRadius: 1e5
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
size: {
|
|
15
|
+
"...size": getShapeSize
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export {
|
|
20
|
+
Square
|
|
21
|
+
};
|
|
2
22
|
//# sourceMappingURL=Square.js.map
|
package/dist/esm/Square.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Square.tsx"],
|
|
4
4
|
"sourcesContent": ["import { ThemeableStack } from '@tamagui/stacks'\nimport { GetProps, styled } from '@tamagui/web'\n\nimport { getShapeSize } from './getShapeSize'\n\nexport const Square = styled(ThemeableStack, {\n name: 'Square',\n alignItems: 'center',\n justifyContent: 'center',\n\n variants: {\n circular: {\n true: {\n borderRadius: 100_000,\n },\n },\n\n size: {\n '...size': getShapeSize,\n },\n } as const,\n})\n\nexport type SquareProps = GetProps<typeof Square>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAS,sBAAsB;AAC/B,SAAmB,cAAc;AAEjC,SAAS,oBAAoB;AAEtB,MAAM,SAAS,OAAO,gBAAgB;AAAA,EAC3C,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAEhB,UAAU;AAAA,IACR,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,cAAc;AAAA,MAChB;AAAA,IACF;AAAA,IAEA,MAAM;AAAA,MACJ,WAAW;AAAA,IACb;AAAA,EACF;AACF,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/Square.mjs
CHANGED
|
@@ -1,2 +1,22 @@
|
|
|
1
|
-
import{ThemeableStack
|
|
1
|
+
import { ThemeableStack } from "@tamagui/stacks";
|
|
2
|
+
import { styled } from "@tamagui/web";
|
|
3
|
+
import { getShapeSize } from "./getShapeSize";
|
|
4
|
+
const Square = styled(ThemeableStack, {
|
|
5
|
+
name: "Square",
|
|
6
|
+
alignItems: "center",
|
|
7
|
+
justifyContent: "center",
|
|
8
|
+
variants: {
|
|
9
|
+
circular: {
|
|
10
|
+
true: {
|
|
11
|
+
borderRadius: 1e5
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
size: {
|
|
15
|
+
"...size": getShapeSize
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export {
|
|
20
|
+
Square
|
|
21
|
+
};
|
|
2
22
|
//# sourceMappingURL=Square.mjs.map
|
package/dist/esm/Square.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Square.tsx"],
|
|
4
4
|
"sourcesContent": ["import { ThemeableStack } from '@tamagui/stacks'\nimport { GetProps, styled } from '@tamagui/web'\n\nimport { getShapeSize } from './getShapeSize'\n\nexport const Square = styled(ThemeableStack, {\n name: 'Square',\n alignItems: 'center',\n justifyContent: 'center',\n\n variants: {\n circular: {\n true: {\n borderRadius: 100_000,\n },\n },\n\n size: {\n '...size': getShapeSize,\n },\n } as const,\n})\n\nexport type SquareProps = GetProps<typeof Square>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAS,sBAAsB;AAC/B,SAAmB,cAAc;AAEjC,SAAS,oBAAoB;AAEtB,MAAM,SAAS,OAAO,gBAAgB;AAAA,EAC3C,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAEhB,UAAU;AAAA,IACR,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,cAAc;AAAA,MAChB;AAAA,IACF;AAAA,IAEA,MAAM;AAAA,MACJ,WAAW;AAAA,IACb;AAAA,EACF;AACF,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/getShapeSize.js
CHANGED
|
@@ -1,2 +1,16 @@
|
|
|
1
|
-
const
|
|
1
|
+
const getShapeSize = (size, { tokens }) => {
|
|
2
|
+
const width = tokens.size[size] ?? size;
|
|
3
|
+
const height = tokens.size[size] ?? size;
|
|
4
|
+
return {
|
|
5
|
+
width,
|
|
6
|
+
height,
|
|
7
|
+
minWidth: width,
|
|
8
|
+
maxWidth: width,
|
|
9
|
+
maxHeight: height,
|
|
10
|
+
minHeight: height
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
getShapeSize
|
|
15
|
+
};
|
|
2
16
|
//# sourceMappingURL=getShapeSize.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/getShapeSize.tsx"],
|
|
4
4
|
"sourcesContent": ["import { SizableStackProps } from '@tamagui/stacks'\nimport { SizeVariantSpreadFunction } from '@tamagui/web'\n\nexport const getShapeSize: SizeVariantSpreadFunction<SizableStackProps> = (\n size,\n { tokens }\n) => {\n const width = tokens.size[size] ?? size\n const height = tokens.size[size] ?? size\n return {\n width,\n height,\n minWidth: width,\n maxWidth: width,\n maxHeight: height,\n minHeight: height,\n }\n}\n"],
|
|
5
|
-
"mappings": "AAGO,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAGO,MAAM,eAA6D,CACxE,MACA,EAAE,OAAO,MACN;AACH,QAAM,QAAQ,OAAO,KAAK,IAAI,KAAK;AACnC,QAAM,SAAS,OAAO,KAAK,IAAI,KAAK;AACpC,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,EACb;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
|
@@ -1,2 +1,16 @@
|
|
|
1
|
-
const
|
|
1
|
+
const getShapeSize = (size, { tokens }) => {
|
|
2
|
+
const width = tokens.size[size] ?? size;
|
|
3
|
+
const height = tokens.size[size] ?? size;
|
|
4
|
+
return {
|
|
5
|
+
width,
|
|
6
|
+
height,
|
|
7
|
+
minWidth: width,
|
|
8
|
+
maxWidth: width,
|
|
9
|
+
maxHeight: height,
|
|
10
|
+
minHeight: height
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
getShapeSize
|
|
15
|
+
};
|
|
2
16
|
//# sourceMappingURL=getShapeSize.mjs.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/getShapeSize.tsx"],
|
|
4
4
|
"sourcesContent": ["import { SizableStackProps } from '@tamagui/stacks'\nimport { SizeVariantSpreadFunction } from '@tamagui/web'\n\nexport const getShapeSize: SizeVariantSpreadFunction<SizableStackProps> = (\n size,\n { tokens }\n) => {\n const width = tokens.size[size] ?? size\n const height = tokens.size[size] ?? size\n return {\n width,\n height,\n minWidth: width,\n maxWidth: width,\n maxHeight: height,\n minHeight: height,\n }\n}\n"],
|
|
5
|
-
"mappings": "AAGO,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAGO,MAAM,eAA6D,CACxE,MACA,EAAE,OAAO,MACN;AACH,QAAM,QAAQ,OAAO,KAAK,IAAI,KAAK;AACnC,QAAM,SAAS,OAAO,KAAK,IAAI,KAAK;AACpC,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,EACb;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/esm/index.js
CHANGED
package/dist/esm/index.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["export * from './Square'\nexport * from './Circle'\nexport * from './getShapeSize'\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,cAAc;AACd,cAAc;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/index.mjs
CHANGED
package/dist/esm/index.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["export * from './Square'\nexport * from './Circle'\nexport * from './getShapeSize'\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,cAAc;AACd,cAAc;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/jsx/Circle.js
CHANGED
|
@@ -1,2 +1,10 @@
|
|
|
1
|
-
import{styled
|
|
1
|
+
import { styled } from "@tamagui/web";
|
|
2
|
+
import { Square } from "./Square";
|
|
3
|
+
const Circle = styled(Square, {
|
|
4
|
+
name: "Circle",
|
|
5
|
+
circular: true
|
|
6
|
+
});
|
|
7
|
+
export {
|
|
8
|
+
Circle
|
|
9
|
+
};
|
|
2
10
|
//# sourceMappingURL=Circle.js.map
|
package/dist/jsx/Circle.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Circle.tsx"],
|
|
4
4
|
"sourcesContent": ["import { GetProps, styled } from '@tamagui/web'\n\nimport { Square } from './Square'\n\nexport const Circle = styled(Square, {\n name: 'Circle',\n circular: true,\n})\n\nexport type CircleProps = GetProps<typeof Circle>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAmB,cAAc;AAEjC,SAAS,cAAc;AAEhB,MAAM,SAAS,OAAO,QAAQ;AAAA,EACnC,MAAM;AAAA,EACN,UAAU;AACZ,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/jsx/Circle.mjs
CHANGED
|
@@ -1,2 +1,10 @@
|
|
|
1
|
-
import{styled
|
|
1
|
+
import { styled } from "@tamagui/web";
|
|
2
|
+
import { Square } from "./Square";
|
|
3
|
+
const Circle = styled(Square, {
|
|
4
|
+
name: "Circle",
|
|
5
|
+
circular: true
|
|
6
|
+
});
|
|
7
|
+
export {
|
|
8
|
+
Circle
|
|
9
|
+
};
|
|
2
10
|
//# sourceMappingURL=Circle.mjs.map
|
package/dist/jsx/Circle.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Circle.tsx"],
|
|
4
4
|
"sourcesContent": ["import { GetProps, styled } from '@tamagui/web'\n\nimport { Square } from './Square'\n\nexport const Circle = styled(Square, {\n name: 'Circle',\n circular: true,\n})\n\nexport type CircleProps = GetProps<typeof Circle>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAmB,cAAc;AAEjC,SAAS,cAAc;AAEhB,MAAM,SAAS,OAAO,QAAQ;AAAA,EACnC,MAAM;AAAA,EACN,UAAU;AACZ,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/jsx/Square.js
CHANGED
|
@@ -1,2 +1,22 @@
|
|
|
1
|
-
import{ThemeableStack
|
|
1
|
+
import { ThemeableStack } from "@tamagui/stacks";
|
|
2
|
+
import { styled } from "@tamagui/web";
|
|
3
|
+
import { getShapeSize } from "./getShapeSize";
|
|
4
|
+
const Square = styled(ThemeableStack, {
|
|
5
|
+
name: "Square",
|
|
6
|
+
alignItems: "center",
|
|
7
|
+
justifyContent: "center",
|
|
8
|
+
variants: {
|
|
9
|
+
circular: {
|
|
10
|
+
true: {
|
|
11
|
+
borderRadius: 1e5
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
size: {
|
|
15
|
+
"...size": getShapeSize
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export {
|
|
20
|
+
Square
|
|
21
|
+
};
|
|
2
22
|
//# sourceMappingURL=Square.js.map
|
package/dist/jsx/Square.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Square.tsx"],
|
|
4
4
|
"sourcesContent": ["import { ThemeableStack } from '@tamagui/stacks'\nimport { GetProps, styled } from '@tamagui/web'\n\nimport { getShapeSize } from './getShapeSize'\n\nexport const Square = styled(ThemeableStack, {\n name: 'Square',\n alignItems: 'center',\n justifyContent: 'center',\n\n variants: {\n circular: {\n true: {\n borderRadius: 100_000,\n },\n },\n\n size: {\n '...size': getShapeSize,\n },\n } as const,\n})\n\nexport type SquareProps = GetProps<typeof Square>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAS,sBAAsB;AAC/B,SAAmB,cAAc;AAEjC,SAAS,oBAAoB;AAEtB,MAAM,SAAS,OAAO,gBAAgB;AAAA,EAC3C,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAEhB,UAAU;AAAA,IACR,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,cAAc;AAAA,MAChB;AAAA,IACF;AAAA,IAEA,MAAM;AAAA,MACJ,WAAW;AAAA,IACb;AAAA,EACF;AACF,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/jsx/Square.mjs
CHANGED
|
@@ -1,2 +1,22 @@
|
|
|
1
|
-
import{ThemeableStack
|
|
1
|
+
import { ThemeableStack } from "@tamagui/stacks";
|
|
2
|
+
import { styled } from "@tamagui/web";
|
|
3
|
+
import { getShapeSize } from "./getShapeSize";
|
|
4
|
+
const Square = styled(ThemeableStack, {
|
|
5
|
+
name: "Square",
|
|
6
|
+
alignItems: "center",
|
|
7
|
+
justifyContent: "center",
|
|
8
|
+
variants: {
|
|
9
|
+
circular: {
|
|
10
|
+
true: {
|
|
11
|
+
borderRadius: 1e5
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
size: {
|
|
15
|
+
"...size": getShapeSize
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export {
|
|
20
|
+
Square
|
|
21
|
+
};
|
|
2
22
|
//# sourceMappingURL=Square.mjs.map
|
package/dist/jsx/Square.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/Square.tsx"],
|
|
4
4
|
"sourcesContent": ["import { ThemeableStack } from '@tamagui/stacks'\nimport { GetProps, styled } from '@tamagui/web'\n\nimport { getShapeSize } from './getShapeSize'\n\nexport const Square = styled(ThemeableStack, {\n name: 'Square',\n alignItems: 'center',\n justifyContent: 'center',\n\n variants: {\n circular: {\n true: {\n borderRadius: 100_000,\n },\n },\n\n size: {\n '...size': getShapeSize,\n },\n } as const,\n})\n\nexport type SquareProps = GetProps<typeof Square>\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAAA,SAAS,sBAAsB;AAC/B,SAAmB,cAAc;AAEjC,SAAS,oBAAoB;AAEtB,MAAM,SAAS,OAAO,gBAAgB;AAAA,EAC3C,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAEhB,UAAU;AAAA,IACR,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,cAAc;AAAA,MAChB;AAAA,IACF;AAAA,IAEA,MAAM;AAAA,MACJ,WAAW;AAAA,IACb;AAAA,EACF;AACF,CAAC;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/jsx/getShapeSize.js
CHANGED
|
@@ -1,2 +1,16 @@
|
|
|
1
|
-
const
|
|
1
|
+
const getShapeSize = (size, { tokens }) => {
|
|
2
|
+
const width = tokens.size[size] ?? size;
|
|
3
|
+
const height = tokens.size[size] ?? size;
|
|
4
|
+
return {
|
|
5
|
+
width,
|
|
6
|
+
height,
|
|
7
|
+
minWidth: width,
|
|
8
|
+
maxWidth: width,
|
|
9
|
+
maxHeight: height,
|
|
10
|
+
minHeight: height
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
getShapeSize
|
|
15
|
+
};
|
|
2
16
|
//# sourceMappingURL=getShapeSize.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/getShapeSize.tsx"],
|
|
4
4
|
"sourcesContent": ["import { SizableStackProps } from '@tamagui/stacks'\nimport { SizeVariantSpreadFunction } from '@tamagui/web'\n\nexport const getShapeSize: SizeVariantSpreadFunction<SizableStackProps> = (\n size,\n { tokens }\n) => {\n const width = tokens.size[size] ?? size\n const height = tokens.size[size] ?? size\n return {\n width,\n height,\n minWidth: width,\n maxWidth: width,\n maxHeight: height,\n minHeight: height,\n }\n}\n"],
|
|
5
|
-
"mappings": "AAGO,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAGO,MAAM,eAA6D,CACxE,MACA,EAAE,OAAO,MACN;AACH,QAAM,QAAQ,OAAO,KAAK,IAAI,KAAK;AACnC,QAAM,SAAS,OAAO,KAAK,IAAI,KAAK;AACpC,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,EACb;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
|
@@ -1,2 +1,16 @@
|
|
|
1
|
-
const
|
|
1
|
+
const getShapeSize = (size, { tokens }) => {
|
|
2
|
+
const width = tokens.size[size] ?? size;
|
|
3
|
+
const height = tokens.size[size] ?? size;
|
|
4
|
+
return {
|
|
5
|
+
width,
|
|
6
|
+
height,
|
|
7
|
+
minWidth: width,
|
|
8
|
+
maxWidth: width,
|
|
9
|
+
maxHeight: height,
|
|
10
|
+
minHeight: height
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
getShapeSize
|
|
15
|
+
};
|
|
2
16
|
//# sourceMappingURL=getShapeSize.mjs.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/getShapeSize.tsx"],
|
|
4
4
|
"sourcesContent": ["import { SizableStackProps } from '@tamagui/stacks'\nimport { SizeVariantSpreadFunction } from '@tamagui/web'\n\nexport const getShapeSize: SizeVariantSpreadFunction<SizableStackProps> = (\n size,\n { tokens }\n) => {\n const width = tokens.size[size] ?? size\n const height = tokens.size[size] ?? size\n return {\n width,\n height,\n minWidth: width,\n maxWidth: width,\n maxHeight: height,\n minHeight: height,\n }\n}\n"],
|
|
5
|
-
"mappings": "AAGO,
|
|
6
|
-
"names": [
|
|
5
|
+
"mappings": "AAGO,MAAM,eAA6D,CACxE,MACA,EAAE,OAAO,MACN;AACH,QAAM,QAAQ,OAAO,KAAK,IAAI,KAAK;AACnC,QAAM,SAAS,OAAO,KAAK,IAAI,KAAK;AACpC,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,EACb;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/dist/jsx/index.js
CHANGED
package/dist/jsx/index.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["export * from './Square'\nexport * from './Circle'\nexport * from './getShapeSize'\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,cAAc;AACd,cAAc;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/jsx/index.mjs
CHANGED
package/dist/jsx/index.mjs.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["export * from './Square'\nexport * from './Circle'\nexport * from './getShapeSize'\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,cAAc;AACd,cAAc;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/shapes",
|
|
3
|
-
"version": "1.14.
|
|
3
|
+
"version": "1.14.2",
|
|
4
4
|
"sideEffects": [
|
|
5
5
|
"*.css"
|
|
6
6
|
],
|
|
@@ -31,14 +31,14 @@
|
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@tamagui/stacks": "1.14.
|
|
35
|
-
"@tamagui/web": "1.14.
|
|
34
|
+
"@tamagui/stacks": "1.14.2",
|
|
35
|
+
"@tamagui/web": "1.14.2"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
38
|
"react": "*"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@tamagui/build": "1.14.
|
|
41
|
+
"@tamagui/build": "1.14.2",
|
|
42
42
|
"react": "^18.2.0"
|
|
43
43
|
},
|
|
44
44
|
"publishConfig": {
|