@tamagui/stacks 2.7.7 → 3.0.0-beta.637.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/dist/cjs/NestingContext.cjs +18 -26
- package/dist/cjs/NestingContext.native.cjs +34 -0
- package/dist/cjs/NestingContext.native.js +19 -26
- package/dist/cjs/NestingContext.native.js.map +1 -1
- package/dist/cjs/Stacks.cjs +28 -41
- package/dist/cjs/Stacks.native.cjs +51 -0
- package/dist/cjs/Stacks.native.js +28 -40
- package/dist/cjs/Stacks.native.js.map +1 -1
- package/dist/cjs/getElevation.cjs +52 -55
- package/dist/cjs/getElevation.native.cjs +71 -0
- package/dist/cjs/getElevation.native.js +55 -56
- package/dist/cjs/getElevation.native.js.map +1 -1
- package/dist/cjs/index.cjs +10 -13
- package/dist/cjs/index.native.cjs +23 -0
- package/dist/cjs/index.native.js +10 -12
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/esm/NestingContext.mjs +2 -0
- package/dist/esm/NestingContext.mjs.map +1 -1
- package/dist/esm/NestingContext.native.js +3 -1
- package/dist/esm/NestingContext.native.js.map +1 -1
- package/dist/esm/Stacks.mjs +14 -23
- package/dist/esm/Stacks.mjs.map +1 -1
- package/dist/esm/Stacks.native.js +14 -23
- package/dist/esm/Stacks.native.js.map +1 -1
- package/dist/esm/getElevation.mjs +39 -39
- package/dist/esm/getElevation.mjs.map +1 -1
- package/dist/esm/getElevation.native.js +42 -41
- package/dist/esm/getElevation.native.js.map +1 -1
- package/dist/esm/index.js +5 -6
- package/dist/esm/index.mjs +5 -6
- package/dist/esm/index.native.js +5 -6
- package/dist/jsx/NestingContext.mjs +2 -0
- package/dist/jsx/NestingContext.mjs.map +1 -1
- package/dist/jsx/NestingContext.native.cjs +34 -0
- package/dist/jsx/NestingContext.native.js +19 -26
- package/dist/jsx/NestingContext.native.js.map +1 -1
- package/dist/jsx/Stacks.mjs +14 -23
- package/dist/jsx/Stacks.mjs.map +1 -1
- package/dist/jsx/Stacks.native.cjs +51 -0
- package/dist/jsx/Stacks.native.js +28 -40
- package/dist/jsx/Stacks.native.js.map +1 -1
- package/dist/jsx/getElevation.mjs +39 -39
- package/dist/jsx/getElevation.mjs.map +1 -1
- package/dist/jsx/getElevation.native.cjs +71 -0
- package/dist/jsx/getElevation.native.js +55 -56
- package/dist/jsx/getElevation.native.js.map +1 -1
- package/dist/jsx/index.js +5 -6
- package/dist/jsx/index.mjs +5 -6
- package/dist/jsx/index.native.cjs +23 -0
- package/dist/jsx/index.native.js +10 -12
- package/dist/jsx/index.native.js.map +1 -1
- package/package.json +4 -5
- package/src/Stacks.tsx +2 -16
- package/src/getElevation.tsx +16 -9
- package/src/index.ts +0 -2
- package/types/Stacks.d.ts +39 -20
- package/types/Stacks.d.ts.map +1 -1
- package/types/getElevation.d.ts +2 -2
- package/types/getElevation.d.ts.map +1 -1
- package/types/index.d.ts +0 -2
- package/types/index.d.ts.map +1 -1
- package/dist/cjs/SizableStack.cjs +0 -52
- package/dist/cjs/SizableStack.native.js +0 -55
- package/dist/cjs/SizableStack.native.js.map +0 -1
- package/dist/cjs/ThemeableStack.cjs +0 -63
- package/dist/cjs/ThemeableStack.native.js +0 -66
- package/dist/cjs/ThemeableStack.native.js.map +0 -1
- package/dist/cjs/variants.cjs +0 -68
- package/dist/cjs/variants.native.js +0 -73
- package/dist/cjs/variants.native.js.map +0 -1
- package/dist/esm/SizableStack.mjs +0 -27
- package/dist/esm/SizableStack.mjs.map +0 -1
- package/dist/esm/SizableStack.native.js +0 -27
- package/dist/esm/SizableStack.native.js.map +0 -1
- package/dist/esm/ThemeableStack.mjs +0 -37
- package/dist/esm/ThemeableStack.mjs.map +0 -1
- package/dist/esm/ThemeableStack.native.js +0 -37
- package/dist/esm/ThemeableStack.native.js.map +0 -1
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/index.mjs.map +0 -1
- package/dist/esm/index.native.js.map +0 -1
- package/dist/esm/variants.mjs +0 -41
- package/dist/esm/variants.mjs.map +0 -1
- package/dist/esm/variants.native.js +0 -43
- package/dist/esm/variants.native.js.map +0 -1
- package/dist/jsx/SizableStack.mjs +0 -27
- package/dist/jsx/SizableStack.mjs.map +0 -1
- package/dist/jsx/SizableStack.native.js +0 -55
- package/dist/jsx/SizableStack.native.js.map +0 -1
- package/dist/jsx/ThemeableStack.mjs +0 -37
- package/dist/jsx/ThemeableStack.mjs.map +0 -1
- package/dist/jsx/ThemeableStack.native.js +0 -66
- package/dist/jsx/ThemeableStack.native.js.map +0 -1
- package/dist/jsx/index.js.map +0 -1
- package/dist/jsx/index.mjs.map +0 -1
- package/dist/jsx/variants.mjs +0 -41
- package/dist/jsx/variants.mjs.map +0 -1
- package/dist/jsx/variants.native.js +0 -73
- package/dist/jsx/variants.native.js.map +0 -1
- package/src/SizableStack.tsx +0 -33
- package/src/ThemeableStack.tsx +0 -47
- package/src/variants.tsx +0 -38
- package/types/SizableStack.d.ts +0 -14
- package/types/SizableStack.d.ts.map +0 -1
- package/types/ThemeableStack.d.ts +0 -87
- package/types/ThemeableStack.d.ts.map +0 -1
- package/types/variants.d.ts +0 -28
- package/types/variants.d.ts.map +0 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
|
|
1
2
|
var __create = Object.create;
|
|
2
3
|
var __defProp = Object.defineProperty;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -5,36 +6,27 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
|
5
6
|
var __getProtoOf = Object.getPrototypeOf;
|
|
6
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
8
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
for (var name in all) __defProp(target, name, {
|
|
10
|
+
get: all[name],
|
|
11
|
+
enumerable: true
|
|
12
|
+
});
|
|
12
13
|
};
|
|
13
14
|
var __copyProps = (to, from, except, desc) => {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
|
+
get: () => from[key],
|
|
18
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
21
22
|
};
|
|
22
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
26
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
27
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
28
|
-
value: mod,
|
|
29
|
-
enumerable: true
|
|
23
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
24
|
+
value: mod,
|
|
25
|
+
enumerable: true
|
|
30
26
|
}) : target, mod));
|
|
31
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
32
|
-
value: true
|
|
33
|
-
}), mod);
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
34
28
|
var NestingContext_exports = {};
|
|
35
|
-
__export(NestingContext_exports, {
|
|
36
|
-
ButtonNestingContext: () => ButtonNestingContext
|
|
37
|
-
});
|
|
29
|
+
__export(NestingContext_exports, { ButtonNestingContext: () => ButtonNestingContext });
|
|
38
30
|
module.exports = __toCommonJS(NestingContext_exports);
|
|
39
31
|
var import_react = __toESM(require("react"), 1);
|
|
40
|
-
const ButtonNestingContext = import_react.default.createContext(false);
|
|
32
|
+
const ButtonNestingContext = import_react.default.createContext(false);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var __create = Object.create;
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
9
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
|
+
var __export = (target, all) => {
|
|
11
|
+
for (var name in all) __defProp(target, name, {
|
|
12
|
+
get: all[name],
|
|
13
|
+
enumerable: true
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
var __copyProps = (to, from, except, desc) => {
|
|
17
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
18
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
19
|
+
get: () => from[key],
|
|
20
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return to;
|
|
24
|
+
};
|
|
25
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
26
|
+
value: mod,
|
|
27
|
+
enumerable: true
|
|
28
|
+
}) : target, mod));
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
|
+
var NestingContext_exports = {};
|
|
31
|
+
__export(NestingContext_exports, { ButtonNestingContext: () => ButtonNestingContext });
|
|
32
|
+
module.exports = __toCommonJS(NestingContext_exports);
|
|
33
|
+
var import_react = __toESM(require("react"), 1);
|
|
34
|
+
var ButtonNestingContext = /* @__PURE__ */ import_react.default.createContext(false);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
|
|
3
4
|
var __create = Object.create;
|
|
4
5
|
var __defProp = Object.defineProperty;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -7,37 +8,29 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
|
7
8
|
var __getProtoOf = Object.getPrototypeOf;
|
|
8
9
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
10
|
var __export = (target, all) => {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
for (var name in all) __defProp(target, name, {
|
|
12
|
+
get: all[name],
|
|
13
|
+
enumerable: true
|
|
14
|
+
});
|
|
14
15
|
};
|
|
15
16
|
var __copyProps = (to, from, except, desc) => {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
18
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
19
|
+
get: () => from[key],
|
|
20
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return to;
|
|
23
24
|
};
|
|
24
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
30
|
-
value: mod,
|
|
31
|
-
enumerable: true
|
|
25
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
26
|
+
value: mod,
|
|
27
|
+
enumerable: true
|
|
32
28
|
}) : target, mod));
|
|
33
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
34
|
-
value: true
|
|
35
|
-
}), mod);
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
36
30
|
var NestingContext_exports = {};
|
|
37
|
-
__export(NestingContext_exports, {
|
|
38
|
-
ButtonNestingContext: () => ButtonNestingContext
|
|
39
|
-
});
|
|
31
|
+
__export(NestingContext_exports, { ButtonNestingContext: () => ButtonNestingContext });
|
|
40
32
|
module.exports = __toCommonJS(NestingContext_exports);
|
|
41
33
|
var import_react = __toESM(require("react"), 1);
|
|
42
|
-
var ButtonNestingContext = /* @__PURE__ */import_react.default.createContext(false);
|
|
34
|
+
var ButtonNestingContext = /* @__PURE__ */ import_react.default.createContext(false);
|
|
35
|
+
|
|
43
36
|
//# sourceMappingURL=NestingContext.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"NestingContext.native.js","names":[],"sources":["cjs/NestingContext.native.js"],"sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n // If the importer is in node compatibility mode or this is not an ESM\n // file that has been converted to a CommonJS file using a Babel-\n // compatible transform (i.e. \"__esModule\" has not been set), then set\n // \"default\" to the CommonJS \"module.exports\" for node compatibility.\n isNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", { value: mod, enumerable: true }) : target,\n mod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar NestingContext_exports = {};\n__export(NestingContext_exports, {\n ButtonNestingContext: () => ButtonNestingContext\n});\nmodule.exports = __toCommonJS(NestingContext_exports);\nvar import_react = __toESM(require(\"react\"), 1);\nvar ButtonNestingContext = /* @__PURE__ */ import_react.default.createContext(false);\n//# sourceMappingURL=NestingContext.js.map\n"],"mappings":";;;;AACA,IAAI,WAAW,OAAO;AACtB,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO;AAC1B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;CAAK,CAAC;AAChE;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC5C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EAClE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GACpC,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QACzC,UAAU,IAAI,KAAK;GAAE,WAAW,KAAK;GAAM,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAAW,CAAC;CACvH;CACA,OAAO;AACT;AACA,IAAI,WAAW,KAAK,YAAY,YAAY,SAAS,OAAO,OAAO,SAAS,aAAa,GAAG,CAAC,IAAI,CAAC,GAAG,YAKnG,cAAc,CAAC,OAAO,CAAC,IAAI,aAAa,UAAU,QAAQ,WAAW;CAAE,OAAO;CAAK,YAAY;AAAK,CAAC,IAAI,QACzG,GACF;AACA,IAAI,gBAAgB,QAAQ,YAAY,UAAU,CAAC,GAAG,cAAc,EAAE,OAAO,KAAK,CAAC,GAAG,GAAG;AACzF,IAAI,yBAAyB,CAAC;AAC9B,SAAS,wBAAwB,EAC/B,4BAA4B,qBAC9B,CAAC;AACD,OAAO,UAAU,aAAa,sBAAsB;AACpD,IAAI,eAAe,QAAQ,QAAQ,OAAO,GAAG,CAAC;AAC9C,IAAI,uBAAuC,6BAAa,QAAQ,cAAc,KAAK"}
|
package/dist/cjs/Stacks.cjs
CHANGED
|
@@ -1,62 +1,49 @@
|
|
|
1
|
+
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
6
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
for (var name in all) __defProp(target, name, {
|
|
8
|
+
get: all[name],
|
|
9
|
+
enumerable: true
|
|
10
|
+
});
|
|
10
11
|
};
|
|
11
12
|
var __copyProps = (to, from, except, desc) => {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
|
+
get: () => from[key],
|
|
16
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
return to;
|
|
19
20
|
};
|
|
20
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value: true
|
|
22
|
-
}), mod);
|
|
21
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
22
|
var Stacks_exports = {};
|
|
24
23
|
__export(Stacks_exports, {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
fullscreenStyle: () => fullscreenStyle
|
|
24
|
+
XStack: () => XStack,
|
|
25
|
+
YStack: () => YStack,
|
|
26
|
+
ZStack: () => ZStack
|
|
29
27
|
});
|
|
30
28
|
module.exports = __toCommonJS(Stacks_exports);
|
|
31
29
|
var import_core = require("@tamagui/core");
|
|
32
30
|
var import_getElevation = require("./getElevation.cjs");
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
};
|
|
37
|
-
const variants = {
|
|
38
|
-
fullscreen: {
|
|
39
|
-
true: fullscreenStyle
|
|
40
|
-
},
|
|
41
|
-
elevation: {
|
|
42
|
-
"...size": import_getElevation.getElevation,
|
|
43
|
-
":number": import_getElevation.getElevation
|
|
44
|
-
}
|
|
45
|
-
};
|
|
31
|
+
const variants = { elevation: {
|
|
32
|
+
number: import_getElevation.getElevation,
|
|
33
|
+
Size: import_getElevation.getElevation
|
|
34
|
+
} };
|
|
46
35
|
const YStack = (0, import_core.styled)(import_core.View, {
|
|
47
|
-
|
|
48
|
-
|
|
36
|
+
flexDirection: "column",
|
|
37
|
+
variants
|
|
49
38
|
});
|
|
50
39
|
YStack["displayName"] = "YStack";
|
|
51
40
|
const XStack = (0, import_core.styled)(import_core.View, {
|
|
52
|
-
|
|
53
|
-
|
|
41
|
+
flexDirection: "row",
|
|
42
|
+
variants
|
|
54
43
|
});
|
|
55
44
|
XStack["displayName"] = "XStack";
|
|
56
|
-
const ZStack = (0, import_core.styled)(YStack, {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
neverFlatten: true,
|
|
60
|
-
isZStack: true
|
|
45
|
+
const ZStack = (0, import_core.styled)(YStack, { position: "relative" }, {
|
|
46
|
+
neverFlatten: true,
|
|
47
|
+
isZStack: true
|
|
61
48
|
});
|
|
62
|
-
ZStack["displayName"] = "ZStack";
|
|
49
|
+
ZStack["displayName"] = "ZStack";
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var __defProp = Object.defineProperty;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all) __defProp(target, name, {
|
|
10
|
+
get: all[name],
|
|
11
|
+
enumerable: true
|
|
12
|
+
});
|
|
13
|
+
};
|
|
14
|
+
var __copyProps = (to, from, except, desc) => {
|
|
15
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
|
+
get: () => from[key],
|
|
18
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
24
|
+
var Stacks_exports = {};
|
|
25
|
+
__export(Stacks_exports, {
|
|
26
|
+
XStack: () => XStack,
|
|
27
|
+
YStack: () => YStack,
|
|
28
|
+
ZStack: () => ZStack
|
|
29
|
+
});
|
|
30
|
+
module.exports = __toCommonJS(Stacks_exports);
|
|
31
|
+
var import_core = require("@tamagui/core");
|
|
32
|
+
var import_getElevation = require("./getElevation.native.js");
|
|
33
|
+
var variants = { elevation: {
|
|
34
|
+
number: import_getElevation.getElevation,
|
|
35
|
+
Size: import_getElevation.getElevation
|
|
36
|
+
} };
|
|
37
|
+
var YStack = (0, import_core.styled)(import_core.View, {
|
|
38
|
+
flexDirection: "column",
|
|
39
|
+
variants
|
|
40
|
+
});
|
|
41
|
+
YStack["displayName"] = "YStack";
|
|
42
|
+
var XStack = (0, import_core.styled)(import_core.View, {
|
|
43
|
+
flexDirection: "row",
|
|
44
|
+
variants
|
|
45
|
+
});
|
|
46
|
+
XStack["displayName"] = "XStack";
|
|
47
|
+
var ZStack = (0, import_core.styled)(YStack, { position: "relative" }, {
|
|
48
|
+
neverFlatten: true,
|
|
49
|
+
isZStack: true
|
|
50
|
+
});
|
|
51
|
+
ZStack["displayName"] = "ZStack";
|
|
@@ -1,65 +1,53 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
|
|
3
4
|
var __defProp = Object.defineProperty;
|
|
4
5
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
6
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
8
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
for (var name in all) __defProp(target, name, {
|
|
10
|
+
get: all[name],
|
|
11
|
+
enumerable: true
|
|
12
|
+
});
|
|
12
13
|
};
|
|
13
14
|
var __copyProps = (to, from, except, desc) => {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
|
+
get: () => from[key],
|
|
18
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
21
22
|
};
|
|
22
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
23
|
-
value: true
|
|
24
|
-
}), mod);
|
|
23
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
24
|
var Stacks_exports = {};
|
|
26
25
|
__export(Stacks_exports, {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
fullscreenStyle: () => fullscreenStyle
|
|
26
|
+
XStack: () => XStack,
|
|
27
|
+
YStack: () => YStack,
|
|
28
|
+
ZStack: () => ZStack
|
|
31
29
|
});
|
|
32
30
|
module.exports = __toCommonJS(Stacks_exports);
|
|
33
31
|
var import_core = require("@tamagui/core");
|
|
34
32
|
var import_getElevation = require("./getElevation.native.js");
|
|
35
|
-
var
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
};
|
|
39
|
-
var variants = {
|
|
40
|
-
fullscreen: {
|
|
41
|
-
true: fullscreenStyle
|
|
42
|
-
},
|
|
43
|
-
elevation: {
|
|
44
|
-
"...size": import_getElevation.getElevation,
|
|
45
|
-
":number": import_getElevation.getElevation
|
|
46
|
-
}
|
|
47
|
-
};
|
|
33
|
+
var variants = { elevation: {
|
|
34
|
+
number: import_getElevation.getElevation,
|
|
35
|
+
Size: import_getElevation.getElevation
|
|
36
|
+
} };
|
|
48
37
|
var YStack = (0, import_core.styled)(import_core.View, {
|
|
49
|
-
|
|
50
|
-
|
|
38
|
+
flexDirection: "column",
|
|
39
|
+
variants
|
|
51
40
|
});
|
|
52
41
|
YStack["displayName"] = "YStack";
|
|
53
42
|
var XStack = (0, import_core.styled)(import_core.View, {
|
|
54
|
-
|
|
55
|
-
|
|
43
|
+
flexDirection: "row",
|
|
44
|
+
variants
|
|
56
45
|
});
|
|
57
46
|
XStack["displayName"] = "XStack";
|
|
58
|
-
var ZStack = (0, import_core.styled)(YStack, {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
neverFlatten: true,
|
|
62
|
-
isZStack: true
|
|
47
|
+
var ZStack = (0, import_core.styled)(YStack, { position: "relative" }, {
|
|
48
|
+
neverFlatten: true,
|
|
49
|
+
isZStack: true
|
|
63
50
|
});
|
|
64
51
|
ZStack["displayName"] = "ZStack";
|
|
52
|
+
|
|
65
53
|
//# sourceMappingURL=Stacks.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"Stacks.native.js","names":[],"sources":["cjs/Stacks.native.js"],"sourcesContent":["\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar Stacks_exports = {};\n__export(Stacks_exports, {\n XStack: () => XStack,\n YStack: () => YStack,\n ZStack: () => ZStack\n});\nmodule.exports = __toCommonJS(Stacks_exports);\nvar import_core = require(\"@tamagui/core\");\nvar import_getElevation = require(\"./getElevation\");\nvar variants = {\n elevation: {\n number: import_getElevation.getElevation,\n Size: import_getElevation.getElevation\n }\n};\nvar YStack = (0, import_core.styled)(import_core.View, {\n flexDirection: \"column\",\n variants\n});\nYStack[\"displayName\"] = \"YStack\";\nvar XStack = (0, import_core.styled)(import_core.View, {\n flexDirection: \"row\",\n variants\n});\nXStack[\"displayName\"] = \"XStack\";\nvar ZStack = (0, import_core.styled)(YStack, {\n position: \"relative\"\n}, {\n neverFlatten: true,\n isZStack: true\n});\nZStack[\"displayName\"] = \"ZStack\";\n//# sourceMappingURL=Stacks.js.map\n"],"mappings":";;;;AACA,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;CAAK,CAAC;AAChE;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC5C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EAClE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GACpC,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QACzC,UAAU,IAAI,KAAK;GAAE,WAAW,KAAK;GAAM,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAAW,CAAC;CACvH;CACA,OAAO;AACT;AACA,IAAI,gBAAgB,QAAQ,YAAY,UAAU,CAAC,GAAG,cAAc,EAAE,OAAO,KAAK,CAAC,GAAG,GAAG;AACzF,IAAI,iBAAiB,CAAC;AACtB,SAAS,gBAAgB;CACvB,cAAc;CACd,cAAc;CACd,cAAc;AAChB,CAAC;AACD,OAAO,UAAU,aAAa,cAAc;AAC5C,IAAI,cAAc,QAAQ,eAAe;AACzC,IAAI,sBAAsB,QAAQ,0BAAgB;AAClD,IAAI,WAAW,EACb,WAAW;CACT,QAAQ,oBAAoB;CAC5B,MAAM,oBAAoB;AAC5B,EACF;AACA,IAAI,UAAU,GAAG,YAAY,QAAQ,YAAY,MAAM;CACrD,eAAe;CACf;AACF,CAAC;AACD,OAAO,iBAAiB;AACxB,IAAI,UAAU,GAAG,YAAY,QAAQ,YAAY,MAAM;CACrD,eAAe;CACf;AACF,CAAC;AACD,OAAO,iBAAiB;AACxB,IAAI,UAAU,GAAG,YAAY,QAAQ,QAAQ,EAC3C,UAAU,WACZ,GAAG;CACD,cAAc;CACd,UAAU;AACZ,CAAC;AACD,OAAO,iBAAiB"}
|
|
@@ -1,70 +1,67 @@
|
|
|
1
|
+
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
6
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
for (var name in all) __defProp(target, name, {
|
|
8
|
+
get: all[name],
|
|
9
|
+
enumerable: true
|
|
10
|
+
});
|
|
10
11
|
};
|
|
11
12
|
var __copyProps = (to, from, except, desc) => {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
|
+
get: () => from[key],
|
|
16
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
return to;
|
|
19
20
|
};
|
|
20
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value: true
|
|
22
|
-
}), mod);
|
|
21
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
22
|
var getElevation_exports = {};
|
|
24
23
|
__export(getElevation_exports, {
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
getElevation: () => getElevation,
|
|
25
|
+
getSizedElevation: () => getSizedElevation
|
|
27
26
|
});
|
|
28
27
|
module.exports = __toCommonJS(getElevation_exports);
|
|
29
28
|
var import_core = require("@tamagui/core");
|
|
30
29
|
const getElevation = (size, extras) => {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
30
|
+
if (!size) return;
|
|
31
|
+
const { tokens } = extras;
|
|
32
|
+
const sizeToken = (0, import_core.resolveSizeToken)(size, "size");
|
|
33
|
+
if (typeof sizeToken === "number") return getSizedElevation(sizeToken, extras);
|
|
34
|
+
const token = tokens.size[sizeToken];
|
|
35
|
+
const sizeNum = (0, import_core.isVariable)(token) ? +token.val : size;
|
|
36
|
+
return getSizedElevation(sizeNum, extras);
|
|
37
|
+
};
|
|
38
|
+
const getSizedElevation = (val, { theme, tokens }) => {
|
|
39
|
+
let num = 0;
|
|
40
|
+
if (typeof val === "number") {
|
|
41
|
+
num = val;
|
|
42
|
+
} else if (val) {
|
|
43
|
+
const sizeToken = (0, import_core.resolveSizeToken)(val, "size");
|
|
44
|
+
const token = typeof sizeToken === "number" ? sizeToken : tokens.size[sizeToken];
|
|
45
|
+
const tokenValue = (0, import_core.getVariableValue)(token);
|
|
46
|
+
if (typeof tokenValue === "number") {
|
|
47
|
+
num = tokenValue;
|
|
48
|
+
} else {
|
|
49
|
+
num = 10;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
if (num === 0) {
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
const [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)];
|
|
56
|
+
const shadowColor = theme["shadow-color"] ?? theme.shadowColor;
|
|
57
|
+
const shadow = {
|
|
58
|
+
shadowColor,
|
|
59
|
+
shadowRadius,
|
|
60
|
+
shadowOffset: {
|
|
61
|
+
height,
|
|
62
|
+
width: 0
|
|
63
|
+
},
|
|
64
|
+
...import_core.isAndroid ? { elevationAndroid: 2 * height } : {}
|
|
65
|
+
};
|
|
66
|
+
return shadow;
|
|
38
67
|
};
|
|
39
|
-
const getSizedElevation = (val, {
|
|
40
|
-
theme,
|
|
41
|
-
tokens
|
|
42
|
-
}) => {
|
|
43
|
-
let num = 0;
|
|
44
|
-
if (val === true) {
|
|
45
|
-
const val2 = (0, import_core.getVariableValue)(tokens.size["true"]);
|
|
46
|
-
if (typeof val2 === "number") {
|
|
47
|
-
num = val2;
|
|
48
|
-
} else {
|
|
49
|
-
num = 10;
|
|
50
|
-
}
|
|
51
|
-
} else {
|
|
52
|
-
num = +val;
|
|
53
|
-
}
|
|
54
|
-
if (num === 0) {
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
const [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)];
|
|
58
|
-
const shadow = {
|
|
59
|
-
shadowColor: theme.shadowColor,
|
|
60
|
-
shadowRadius,
|
|
61
|
-
shadowOffset: {
|
|
62
|
-
height,
|
|
63
|
-
width: 0
|
|
64
|
-
},
|
|
65
|
-
...(import_core.isAndroid ? {
|
|
66
|
-
elevationAndroid: 2 * height
|
|
67
|
-
} : {})
|
|
68
|
-
};
|
|
69
|
-
return shadow;
|
|
70
|
-
};
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var __defProp = Object.defineProperty;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all) __defProp(target, name, {
|
|
10
|
+
get: all[name],
|
|
11
|
+
enumerable: true
|
|
12
|
+
});
|
|
13
|
+
};
|
|
14
|
+
var __copyProps = (to, from, except, desc) => {
|
|
15
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
|
+
get: () => from[key],
|
|
18
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
24
|
+
var getElevation_exports = {};
|
|
25
|
+
__export(getElevation_exports, {
|
|
26
|
+
getElevation: () => getElevation,
|
|
27
|
+
getSizedElevation: () => getSizedElevation
|
|
28
|
+
});
|
|
29
|
+
module.exports = __toCommonJS(getElevation_exports);
|
|
30
|
+
var import_core = require("@tamagui/core");
|
|
31
|
+
var getElevation = function(size, extras) {
|
|
32
|
+
if (!size) return;
|
|
33
|
+
var { tokens } = extras;
|
|
34
|
+
var sizeToken = (0, import_core.resolveSizeToken)(size, "size");
|
|
35
|
+
if (typeof sizeToken === "number") return getSizedElevation(sizeToken, extras);
|
|
36
|
+
var token = tokens.size[sizeToken];
|
|
37
|
+
var sizeNum = (0, import_core.isVariable)(token) ? +token.val : size;
|
|
38
|
+
return getSizedElevation(sizeNum, extras);
|
|
39
|
+
};
|
|
40
|
+
var getSizedElevation = function(val, param) {
|
|
41
|
+
var { theme, tokens } = param;
|
|
42
|
+
var num = 0;
|
|
43
|
+
if (typeof val === "number") {
|
|
44
|
+
num = val;
|
|
45
|
+
} else if (val) {
|
|
46
|
+
var sizeToken = (0, import_core.resolveSizeToken)(val, "size");
|
|
47
|
+
var token = typeof sizeToken === "number" ? sizeToken : tokens.size[sizeToken];
|
|
48
|
+
var tokenValue = (0, import_core.getVariableValue)(token);
|
|
49
|
+
if (typeof tokenValue === "number") {
|
|
50
|
+
num = tokenValue;
|
|
51
|
+
} else {
|
|
52
|
+
num = 10;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
if (num === 0) {
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
var [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)];
|
|
59
|
+
var _theme_shadowcolor;
|
|
60
|
+
var shadowColor = (_theme_shadowcolor = theme["shadow-color"]) !== null && _theme_shadowcolor !== void 0 ? _theme_shadowcolor : theme.shadowColor;
|
|
61
|
+
var shadow = {
|
|
62
|
+
shadowColor,
|
|
63
|
+
shadowRadius,
|
|
64
|
+
shadowOffset: {
|
|
65
|
+
height,
|
|
66
|
+
width: 0
|
|
67
|
+
},
|
|
68
|
+
...import_core.isAndroid ? { elevationAndroid: 2 * height } : {}
|
|
69
|
+
};
|
|
70
|
+
return shadow;
|
|
71
|
+
};
|