@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.
Files changed (108) hide show
  1. package/dist/cjs/NestingContext.cjs +18 -26
  2. package/dist/cjs/NestingContext.native.cjs +34 -0
  3. package/dist/cjs/NestingContext.native.js +19 -26
  4. package/dist/cjs/NestingContext.native.js.map +1 -1
  5. package/dist/cjs/Stacks.cjs +28 -41
  6. package/dist/cjs/Stacks.native.cjs +51 -0
  7. package/dist/cjs/Stacks.native.js +28 -40
  8. package/dist/cjs/Stacks.native.js.map +1 -1
  9. package/dist/cjs/getElevation.cjs +52 -55
  10. package/dist/cjs/getElevation.native.cjs +71 -0
  11. package/dist/cjs/getElevation.native.js +55 -56
  12. package/dist/cjs/getElevation.native.js.map +1 -1
  13. package/dist/cjs/index.cjs +10 -13
  14. package/dist/cjs/index.native.cjs +23 -0
  15. package/dist/cjs/index.native.js +10 -12
  16. package/dist/cjs/index.native.js.map +1 -1
  17. package/dist/esm/NestingContext.mjs +2 -0
  18. package/dist/esm/NestingContext.mjs.map +1 -1
  19. package/dist/esm/NestingContext.native.js +3 -1
  20. package/dist/esm/NestingContext.native.js.map +1 -1
  21. package/dist/esm/Stacks.mjs +14 -23
  22. package/dist/esm/Stacks.mjs.map +1 -1
  23. package/dist/esm/Stacks.native.js +14 -23
  24. package/dist/esm/Stacks.native.js.map +1 -1
  25. package/dist/esm/getElevation.mjs +39 -39
  26. package/dist/esm/getElevation.mjs.map +1 -1
  27. package/dist/esm/getElevation.native.js +42 -41
  28. package/dist/esm/getElevation.native.js.map +1 -1
  29. package/dist/esm/index.js +5 -6
  30. package/dist/esm/index.mjs +5 -6
  31. package/dist/esm/index.native.js +5 -6
  32. package/dist/jsx/NestingContext.mjs +2 -0
  33. package/dist/jsx/NestingContext.mjs.map +1 -1
  34. package/dist/jsx/NestingContext.native.cjs +34 -0
  35. package/dist/jsx/NestingContext.native.js +19 -26
  36. package/dist/jsx/NestingContext.native.js.map +1 -1
  37. package/dist/jsx/Stacks.mjs +14 -23
  38. package/dist/jsx/Stacks.mjs.map +1 -1
  39. package/dist/jsx/Stacks.native.cjs +51 -0
  40. package/dist/jsx/Stacks.native.js +28 -40
  41. package/dist/jsx/Stacks.native.js.map +1 -1
  42. package/dist/jsx/getElevation.mjs +39 -39
  43. package/dist/jsx/getElevation.mjs.map +1 -1
  44. package/dist/jsx/getElevation.native.cjs +71 -0
  45. package/dist/jsx/getElevation.native.js +55 -56
  46. package/dist/jsx/getElevation.native.js.map +1 -1
  47. package/dist/jsx/index.js +5 -6
  48. package/dist/jsx/index.mjs +5 -6
  49. package/dist/jsx/index.native.cjs +23 -0
  50. package/dist/jsx/index.native.js +10 -12
  51. package/dist/jsx/index.native.js.map +1 -1
  52. package/package.json +4 -5
  53. package/src/Stacks.tsx +2 -16
  54. package/src/getElevation.tsx +16 -9
  55. package/src/index.ts +0 -2
  56. package/types/Stacks.d.ts +39 -20
  57. package/types/Stacks.d.ts.map +1 -1
  58. package/types/getElevation.d.ts +2 -2
  59. package/types/getElevation.d.ts.map +1 -1
  60. package/types/index.d.ts +0 -2
  61. package/types/index.d.ts.map +1 -1
  62. package/dist/cjs/SizableStack.cjs +0 -52
  63. package/dist/cjs/SizableStack.native.js +0 -55
  64. package/dist/cjs/SizableStack.native.js.map +0 -1
  65. package/dist/cjs/ThemeableStack.cjs +0 -63
  66. package/dist/cjs/ThemeableStack.native.js +0 -66
  67. package/dist/cjs/ThemeableStack.native.js.map +0 -1
  68. package/dist/cjs/variants.cjs +0 -68
  69. package/dist/cjs/variants.native.js +0 -73
  70. package/dist/cjs/variants.native.js.map +0 -1
  71. package/dist/esm/SizableStack.mjs +0 -27
  72. package/dist/esm/SizableStack.mjs.map +0 -1
  73. package/dist/esm/SizableStack.native.js +0 -27
  74. package/dist/esm/SizableStack.native.js.map +0 -1
  75. package/dist/esm/ThemeableStack.mjs +0 -37
  76. package/dist/esm/ThemeableStack.mjs.map +0 -1
  77. package/dist/esm/ThemeableStack.native.js +0 -37
  78. package/dist/esm/ThemeableStack.native.js.map +0 -1
  79. package/dist/esm/index.js.map +0 -1
  80. package/dist/esm/index.mjs.map +0 -1
  81. package/dist/esm/index.native.js.map +0 -1
  82. package/dist/esm/variants.mjs +0 -41
  83. package/dist/esm/variants.mjs.map +0 -1
  84. package/dist/esm/variants.native.js +0 -43
  85. package/dist/esm/variants.native.js.map +0 -1
  86. package/dist/jsx/SizableStack.mjs +0 -27
  87. package/dist/jsx/SizableStack.mjs.map +0 -1
  88. package/dist/jsx/SizableStack.native.js +0 -55
  89. package/dist/jsx/SizableStack.native.js.map +0 -1
  90. package/dist/jsx/ThemeableStack.mjs +0 -37
  91. package/dist/jsx/ThemeableStack.mjs.map +0 -1
  92. package/dist/jsx/ThemeableStack.native.js +0 -66
  93. package/dist/jsx/ThemeableStack.native.js.map +0 -1
  94. package/dist/jsx/index.js.map +0 -1
  95. package/dist/jsx/index.mjs.map +0 -1
  96. package/dist/jsx/variants.mjs +0 -41
  97. package/dist/jsx/variants.mjs.map +0 -1
  98. package/dist/jsx/variants.native.js +0 -73
  99. package/dist/jsx/variants.native.js.map +0 -1
  100. package/src/SizableStack.tsx +0 -33
  101. package/src/ThemeableStack.tsx +0 -47
  102. package/src/variants.tsx +0 -38
  103. package/types/SizableStack.d.ts +0 -14
  104. package/types/SizableStack.d.ts.map +0 -1
  105. package/types/ThemeableStack.d.ts +0 -87
  106. package/types/ThemeableStack.d.ts.map +0 -1
  107. package/types/variants.d.ts +0 -28
  108. package/types/variants.d.ts.map +0 -1
@@ -1,74 +1,73 @@
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
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: true
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
- if (from && typeof from === "object" || typeof from === "function") {
15
- for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
16
- get: () => from[key],
17
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
18
- });
19
- }
20
- return to;
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 getElevation_exports = {};
26
25
  __export(getElevation_exports, {
27
- getElevation: () => getElevation,
28
- getSizedElevation: () => getSizedElevation
26
+ getElevation: () => getElevation,
27
+ getSizedElevation: () => getSizedElevation
29
28
  });
30
29
  module.exports = __toCommonJS(getElevation_exports);
31
30
  var import_core = require("@tamagui/core");
32
- var getElevation = function (size, extras) {
33
- if (!size) return;
34
- var {
35
- tokens
36
- } = extras;
37
- var token = tokens.size[size];
38
- var sizeNum = (0, import_core.isVariable)(token) ? +token.val : size;
39
- return getSizedElevation(sizeNum, extras);
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);
40
39
  };
41
- var getSizedElevation = function (val, param) {
42
- var {
43
- theme,
44
- tokens
45
- } = param;
46
- var num = 0;
47
- if (val === true) {
48
- var _$val = (0, import_core.getVariableValue)(tokens.size["true"]);
49
- if (typeof _$val === "number") {
50
- num = _$val;
51
- } else {
52
- num = 10;
53
- }
54
- } else {
55
- num = +val;
56
- }
57
- if (num === 0) {
58
- return;
59
- }
60
- var [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)];
61
- var shadow = {
62
- shadowColor: theme.shadowColor,
63
- shadowRadius,
64
- shadowOffset: {
65
- height,
66
- width: 0
67
- },
68
- ...(import_core.isAndroid ? {
69
- elevationAndroid: 2 * height
70
- } : {})
71
- };
72
- return shadow;
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;
73
71
  };
72
+
74
73
  //# sourceMappingURL=getElevation.native.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["__defProp","Object","defineProperty","__getOwnPropDesc","getOwnPropertyDescriptor","__getOwnPropNames","getOwnPropertyNames","__hasOwnProp","prototype","hasOwnProperty","__export","target","all","name","get","enumerable","__copyProps","to","from","except","desc","key","call","val","__toCommonJS","mod","value","getElevation_exports","getElevation","getSizedElevation","module","exports","import_core","require","size","extras","tokens","token","sizeNum","isVariable","param","theme"],"sources":["../../src/getElevation.tsx"],"sourcesContent":[null],"mappings":"AAMA,YAAS;;AAEF,IAAAA,SAAM,GAAAC,MAAsD,CAAAC,cAAM;AACvE,IAAAC,gBAAW,GAAAF,MAAA,CAAAG,wBAAA;AACX,IAAAC,iBAAmB,GAAAJ,MAAA,CAAAK,mBAAA;AACnB,IAAAC,YAAc,GAAAN,MAAO,CAAAO,SAAS,CAAAC,cAAA;AAC9B,IAAAC,QAAM,GAAAA,CAAAC,MAAW,EAAAC,GAAA,KAAW;EAC5B,SAAOC,IAAA,IAAAD,GAAA,EACTZ,SAAA,CAAAW,MAAA,EAAAE,IAAA;IAAAC,GAAA,EAAAF,GAAA,CAAAC,IAAA;IAAAE,UAAA;EAAA;AAEO;AAIL,IAAAC,WAAU,GAAAA,CAAAC,EAAA,EAAAC,IAAA,EAAAC,MAAA,EAAAC,IAAA;EACV,IAAIF,IAAA,IAAQ,OAAMA,IAAA,wBAAAA,IAAA;IAChB,SAAMG,GAAA,IAAMhB,iBAAiB,CAAAa,IAAO,GACpC,IAAI,CAAAX,YAAO,CAAQe,IAAA,CAAAL,EAAA,EAAAI,GAAU,KAAAA,GAAA,KAAAF,MAAA,EAC3BnB,SAAM,CAAAiB,EAAA,EAAAI,GAAA;MAAAP,GAAA,EAAAS,CAAA,KAAAL,IAAA,CAAAG,GAAA;MAAAN,UAAA,IAAAK,IAAA,GAAAjB,gBAAA,CAAAe,IAAA,EAAAG,GAAA,MAAAD,IAAA,CAAAL;IAAA;EAAA;EAEN,OAAAE,EAAA;AAAM;AACR,IACFO,YAAO,GAAAC,GAAA,IAAAT,WAAA,CAAAhB,SAAA;EAAA0B,KAAA;AAAA,IAAAD,GAAA;AACL,IAAAE,oBAAO;AAAAjB,QACT,CAAAiB,oBAAA;EACAC,YAAY,EAAAA,CAAA,KAAGA,YAAA;EACbC,iBAAA,EAAAA,CAAA,KAAAA;AAAA,EACF;AACAC,MAAA,CAAAC,OAAO,GAAQP,YAAY,CAAAG,oBAAgB,CAAM;AACjD,IAAAK,WAAM,GAASC,OAAA;AAAA,IACbL,YAAA,GAAa,SAAAA,CAAMM,IAAA,EAAAC,MAAA;EAAA,IACnB,CAAAD,IAAA;EAAA,IACA;IAAAE;EAAA,IAAcD,MAAE;EAAiB,IACjCE,KAAI,GAAAD,MACA,CAAAF,IAAA,CAAAA,IAAA;EAAA,IACEI,OAAA,OAAAN,WAAsB,CAAAO,UAAA,EAAAF,KAAA,KAAAA,KAAA,CAAAd,GAAA,GAAAW,IAAA;EAAA,OAEvBL,iBAAA,CAAAS,OAAA,EAAAH,MAAA;AAAA;AAEP,IAAAN,iBAAO,YAAAA,CAAAN,GAAA,EAAAiB,KAAA;EACT;IAAAC,KAAA;IAAAL;EAAA,IAAAI,KAAA","ignoreList":[]}
1
+ {"version":3,"file":"getElevation.native.js","names":[],"sources":["jsx/getElevation.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 getElevation_exports = {};\n__export(getElevation_exports, {\n getElevation: () => getElevation,\n getSizedElevation: () => getSizedElevation\n});\nmodule.exports = __toCommonJS(getElevation_exports);\nvar import_core = require(\"@tamagui/core\");\nvar getElevation = function(size, extras) {\n if (!size) return;\n var { tokens } = extras;\n var sizeToken = (0, import_core.resolveSizeToken)(size, \"size\");\n if (typeof sizeToken === \"number\") return getSizedElevation(sizeToken, extras);\n var token = tokens.size[sizeToken];\n var sizeNum = (0, import_core.isVariable)(token) ? +token.val : size;\n return getSizedElevation(sizeNum, extras);\n};\nvar getSizedElevation = function(val, param) {\n var { theme, tokens } = param;\n var num = 0;\n if (typeof val === \"number\") {\n num = val;\n } else if (val) {\n var sizeToken = (0, import_core.resolveSizeToken)(val, \"size\");\n var token = typeof sizeToken === \"number\" ? sizeToken : tokens.size[sizeToken];\n var tokenValue = (0, import_core.getVariableValue)(token);\n if (typeof tokenValue === \"number\") {\n num = tokenValue;\n } else {\n num = 10;\n }\n }\n if (num === 0) {\n return;\n }\n var [height, shadowRadius] = [\n Math.round(num / 4 + 1),\n Math.round(num / 2 + 2)\n ];\n var _theme_shadowcolor;\n var shadowColor = (_theme_shadowcolor = theme[\"shadow-color\"]) !== null && _theme_shadowcolor !== void 0 ? _theme_shadowcolor : theme.shadowColor;\n var shadow = {\n shadowColor,\n shadowRadius,\n shadowOffset: {\n height,\n width: 0\n },\n ...import_core.isAndroid ? {\n elevationAndroid: 2 * height\n } : {}\n };\n return shadow;\n};\n//# sourceMappingURL=getElevation.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,uBAAuB,CAAC;AAC5B,SAAS,sBAAsB;CAC7B,oBAAoB;CACpB,yBAAyB;AAC3B,CAAC;AACD,OAAO,UAAU,aAAa,oBAAoB;AAClD,IAAI,cAAc,QAAQ,eAAe;AACzC,IAAI,eAAe,SAAS,MAAM,QAAQ;CACxC,IAAI,CAAC,MAAM;CACX,IAAI,EAAE,WAAW;CACjB,IAAI,aAAa,GAAG,YAAY,kBAAkB,MAAM,MAAM;CAC9D,IAAI,OAAO,cAAc,UAAU,OAAO,kBAAkB,WAAW,MAAM;CAC7E,IAAI,QAAQ,OAAO,KAAK;CACxB,IAAI,WAAW,GAAG,YAAY,YAAY,KAAK,IAAI,CAAC,MAAM,MAAM;CAChE,OAAO,kBAAkB,SAAS,MAAM;AAC1C;AACA,IAAI,oBAAoB,SAAS,KAAK,OAAO;CAC3C,IAAI,EAAE,OAAO,WAAW;CACxB,IAAI,MAAM;CACV,IAAI,OAAO,QAAQ,UAAU;EAC3B,MAAM;CACR,OAAO,IAAI,KAAK;EACd,IAAI,aAAa,GAAG,YAAY,kBAAkB,KAAK,MAAM;EAC7D,IAAI,QAAQ,OAAO,cAAc,WAAW,YAAY,OAAO,KAAK;EACpE,IAAI,cAAc,GAAG,YAAY,kBAAkB,KAAK;EACxD,IAAI,OAAO,eAAe,UAAU;GAClC,MAAM;EACR,OAAO;GACL,MAAM;EACR;CACF;CACA,IAAI,QAAQ,GAAG;EACb;CACF;CACA,IAAI,CAAC,QAAQ,gBAAgB,CAC3B,KAAK,MAAM,MAAM,IAAI,CAAC,GACtB,KAAK,MAAM,MAAM,IAAI,CAAC,CACxB;CACA,IAAI;CACJ,IAAI,eAAe,qBAAqB,MAAM,qBAAqB,QAAQ,uBAAuB,KAAK,IAAI,qBAAqB,MAAM;CACtI,IAAI,SAAS;EACX;EACA;EACA,cAAc;GACZ;GACA,OAAO;EACT;EACA,GAAG,YAAY,YAAY,EACzB,kBAAkB,IAAI,OACxB,IAAI,CAAC;CACP;CACA,OAAO;AACT"}
package/dist/jsx/index.js CHANGED
@@ -1,6 +1,5 @@
1
- export * from "./Stacks.mjs";
2
- export * from "./ThemeableStack.mjs";
3
- export * from "./SizableStack.mjs";
4
- export * from "./NestingContext.mjs";
5
- export * from "./getElevation.mjs";
6
- //# sourceMappingURL=index.js.map
1
+ export * from "./Stacks.mjs"
2
+
3
+ export * from "./NestingContext.mjs"
4
+
5
+ export * from "./getElevation.mjs"
@@ -1,6 +1,5 @@
1
- export * from "./Stacks.mjs";
2
- export * from "./ThemeableStack.mjs";
3
- export * from "./SizableStack.mjs";
4
- export * from "./NestingContext.mjs";
5
- export * from "./getElevation.mjs";
6
- //# sourceMappingURL=index.mjs.map
1
+ export * from "./Stacks.mjs"
2
+
3
+ export * from "./NestingContext.mjs"
4
+
5
+ export * from "./getElevation.mjs"
@@ -0,0 +1,23 @@
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 __copyProps = (to, from, except, desc) => {
9
+ if (from && typeof from === "object" || typeof from === "function") {
10
+ for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
11
+ get: () => from[key],
12
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
13
+ });
14
+ }
15
+ return to;
16
+ };
17
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var index_exports = {};
20
+ module.exports = __toCommonJS(index_exports);
21
+ __reExport(index_exports, require("./Stacks.native.js"), module.exports);
22
+ __reExport(index_exports, require("./NestingContext.native.js"), module.exports);
23
+ __reExport(index_exports, require("./getElevation.native.js"), module.exports);
@@ -1,27 +1,25 @@
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 __copyProps = (to, from, except, desc) => {
8
- if (from && typeof from === "object" || typeof from === "function") {
9
- for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
10
- get: () => from[key],
11
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
12
- });
13
- }
14
- return to;
9
+ if (from && typeof from === "object" || typeof from === "function") {
10
+ for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
11
+ get: () => from[key],
12
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
13
+ });
14
+ }
15
+ return to;
15
16
  };
16
17
  var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
17
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
18
- value: true
19
- }), mod);
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
19
  var index_exports = {};
21
20
  module.exports = __toCommonJS(index_exports);
22
21
  __reExport(index_exports, require("./Stacks.native.js"), module.exports);
23
- __reExport(index_exports, require("./ThemeableStack.native.js"), module.exports);
24
- __reExport(index_exports, require("./SizableStack.native.js"), module.exports);
25
22
  __reExport(index_exports, require("./NestingContext.native.js"), module.exports);
26
23
  __reExport(index_exports, require("./getElevation.native.js"), module.exports);
24
+
27
25
  //# sourceMappingURL=index.native.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["__defProp","Object","defineProperty","__getOwnPropDesc","getOwnPropertyDescriptor","__getOwnPropNames","getOwnPropertyNames","__hasOwnProp","prototype","hasOwnProperty"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA;;AACA,IAAAA,SAAA,GAAcC,MAAA,CAAAC,cAAA;AACd,IAAAC,gBAAc,GAAAF,MAAA,CAAAG,wBAAA;AACd,IAAAC,iBAAc,GAAAJ,MAAA,CAAAK,mBAAA;AACd,IAAAC,YAAc,GAAAN,MAAA,CAAAO,SAAA,CAAAC,cAAA","ignoreList":[]}
1
+ {"version":3,"file":"index.native.js","names":[],"sources":["jsx/index.native.js"],"sourcesContent":["\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\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 __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, \"default\"), secondTarget && __copyProps(secondTarget, mod, \"default\"));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar index_exports = {};\nmodule.exports = __toCommonJS(index_exports);\n__reExport(index_exports, require(\"./Stacks\"), module.exports);\n__reExport(index_exports, require(\"./NestingContext\"), module.exports);\n__reExport(index_exports, require(\"./getElevation\"), module.exports);\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;;AACA,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO,UAAU;AACpC,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,cAAc,QAAQ,KAAK,kBAAkB,YAAY,QAAQ,KAAK,SAAS,GAAG,gBAAgB,YAAY,cAAc,KAAK,SAAS;AAC9I,IAAI,gBAAgB,QAAQ,YAAY,UAAU,CAAC,GAAG,cAAc,EAAE,OAAO,KAAK,CAAC,GAAG,GAAG;AACzF,IAAI,gBAAgB,CAAC;AACrB,OAAO,UAAU,aAAa,aAAa;AAC3C,WAAW,eAAe,QAAQ,oBAAU,GAAG,OAAO,OAAO;AAC7D,WAAW,eAAe,QAAQ,4BAAkB,GAAG,OAAO,OAAO;AACrE,WAAW,eAAe,QAAQ,0BAAgB,GAAG,OAAO,OAAO"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/stacks",
3
- "version": "2.7.7",
3
+ "version": "3.0.0-beta.637.1",
4
4
  "gitHead": "a49cc7ea6b93ba384e77a4880ae48ac4a5635c14",
5
5
  "source": "src/index.ts",
6
6
  "files": [
@@ -35,12 +35,11 @@
35
35
  "clean:build": "tamagui-build clean:build"
36
36
  },
37
37
  "dependencies": {
38
- "@tamagui/core": "2.7.7",
39
- "@tamagui/get-button-sized": "2.7.7",
40
- "@tamagui/web": "2.7.7"
38
+ "@tamagui/core": "3.0.0-beta.637.1",
39
+ "@tamagui/web": "3.0.0-beta.637.1"
41
40
  },
42
41
  "devDependencies": {
43
- "@tamagui/build": "2.7.7",
42
+ "@tamagui/build": "3.0.0-beta.637.1",
44
43
  "react": ">=19"
45
44
  },
46
45
  "peerDependencies": {
package/src/Stacks.tsx CHANGED
@@ -4,11 +4,6 @@ import { View, styled } from '@tamagui/core'
4
4
  import { getElevation } from './getElevation'
5
5
 
6
6
  export interface StackVariants {
7
- /**
8
- * @deprecated use `inset: 0, position: 'absolute'` instead
9
- */
10
- fullscreen?: boolean
11
-
12
7
  elevation?: number | SizeTokens
13
8
  }
14
9
 
@@ -18,19 +13,10 @@ export type YStackProps = Omit<GetProps<typeof YStack>, keyof StackVariants> &
18
13
  export type XStackProps = YStackProps
19
14
  export type ZStackProps = YStackProps
20
15
 
21
- export const fullscreenStyle = {
22
- position: 'absolute',
23
- inset: 0,
24
- } as const
25
-
26
16
  const variants = {
27
- fullscreen: {
28
- true: fullscreenStyle,
29
- },
30
-
31
17
  elevation: {
32
- '...size': getElevation,
33
- ':number': getElevation,
18
+ number: getElevation,
19
+ Size: getElevation,
34
20
  },
35
21
  } as const
36
22
 
@@ -4,12 +4,16 @@ import type {
4
4
  ViewProps,
5
5
  VariantSpreadExtras,
6
6
  } from '@tamagui/core'
7
- import { getVariableValue, isAndroid, isVariable } from '@tamagui/core'
7
+ import { getVariableValue, isAndroid, isVariable, resolveSizeToken } from '@tamagui/core'
8
8
 
9
9
  export const getElevation: SizeVariantSpreadFunction<ViewProps> = (size, extras) => {
10
10
  if (!size) return
11
11
  const { tokens } = extras
12
- const token = tokens.size[size]
12
+ const sizeToken = resolveSizeToken(size, 'size')
13
+ // elevation={10} means 10px, not size token '10'. the size scale is keyed by
14
+ // numeric-looking strings, so only a non-numeric token may be looked up.
15
+ if (typeof sizeToken === 'number') return getSizedElevation(sizeToken, extras)
16
+ const token = tokens.size[sizeToken]
13
17
  const sizeNum = (isVariable(token) ? +token.val : size) as number
14
18
  return getSizedElevation(sizeNum, extras)
15
19
  }
@@ -19,22 +23,25 @@ export const getSizedElevation = (
19
23
  { theme, tokens }: VariantSpreadExtras<any>
20
24
  ) => {
21
25
  let num = 0
22
- if (val === true) {
23
- const val = getVariableValue(tokens.size['true'])
24
- if (typeof val === 'number') {
25
- num = val
26
+ if (typeof val === 'number') {
27
+ num = val
28
+ } else if (val) {
29
+ const sizeToken = resolveSizeToken(val, 'size')
30
+ const token = typeof sizeToken === 'number' ? sizeToken : tokens.size[sizeToken]
31
+ const tokenValue = getVariableValue(token)
32
+ if (typeof tokenValue === 'number') {
33
+ num = tokenValue
26
34
  } else {
27
35
  num = 10
28
36
  }
29
- } else {
30
- num = +val
31
37
  }
32
38
  if (num === 0) {
33
39
  return
34
40
  }
35
41
  const [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)]
42
+ const shadowColor = theme['shadow-color'] ?? theme.shadowColor
36
43
  const shadow = {
37
- shadowColor: theme.shadowColor,
44
+ shadowColor,
38
45
  shadowRadius,
39
46
  shadowOffset: { height, width: 0 },
40
47
  ...(isAndroid
package/src/index.ts CHANGED
@@ -1,5 +1,3 @@
1
1
  export * from './Stacks'
2
- export * from './ThemeableStack'
3
- export * from './SizableStack'
4
2
  export * from './NestingContext'
5
3
  export * from './getElevation'
package/types/Stacks.d.ts CHANGED
@@ -1,43 +1,62 @@
1
1
  import type { GetProps, SizeTokens } from '@tamagui/core';
2
2
  export interface StackVariants {
3
- /**
4
- * @deprecated use `inset: 0, position: 'absolute'` instead
5
- */
6
- fullscreen?: boolean;
7
3
  elevation?: number | SizeTokens;
8
4
  }
9
5
  export type YStackProps = Omit<GetProps<typeof YStack>, keyof StackVariants> & StackVariants;
10
6
  export type XStackProps = YStackProps;
11
7
  export type ZStackProps = YStackProps;
12
- export declare const fullscreenStyle: {
13
- readonly position: "absolute";
14
- readonly inset: 0;
15
- };
16
8
  /**
17
9
  * @summary A view that arranges its children in a vertical line.
18
10
  * @see — Docs https://tamagui.dev/ui/stacks#xstack-ystack-zstack
19
11
  */
20
- export declare const YStack: import("@tamagui/core").TamaguiComponent<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
21
- elevation?: number | SizeTokens | undefined;
22
- fullscreen?: boolean | undefined;
23
- }, import("@tamagui/core").StaticConfigPublic>;
12
+ export declare const YStack: import("react").FunctionComponent<Omit<import("@tamagui/core").RNTamaguiViewNonStyleProps, "elevation" | keyof import("@tamagui/core").StackStyleBase> & import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase> & {
13
+ elevation?: number | import("@tamagui/core").Size | undefined;
14
+ } & import("@tamagui/core").WithShorthands<import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase>> & {
15
+ ref?: import("react").Ref<import("@tamagui/core").TamaguiElement> | undefined;
16
+ }> & import("@tamagui/core").StaticComponentObject<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
17
+ elevation?: number | import("@tamagui/core").Size | undefined;
18
+ }, import("@tamagui/core").StaticConfigPublic> & Omit<import("@tamagui/core").StaticConfigPublic, "staticConfig"> & {
19
+ __tama: [import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
20
+ elevation?: number | import("@tamagui/core").Size | undefined;
21
+ }, import("@tamagui/core").StaticConfigPublic];
22
+ };
24
23
  /**
25
24
  * @summary A view that arranges its children in a horizontal line.
26
25
  * @see — Docs https://tamagui.dev/ui/stacks#xstack-ystack-zstack
27
26
  */
28
- export declare const XStack: import("@tamagui/core").TamaguiComponent<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
29
- elevation?: number | SizeTokens | undefined;
30
- fullscreen?: boolean | undefined;
31
- }, import("@tamagui/core").StaticConfigPublic>;
27
+ export declare const XStack: import("react").FunctionComponent<Omit<import("@tamagui/core").RNTamaguiViewNonStyleProps, "elevation" | keyof import("@tamagui/core").StackStyleBase> & import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase> & {
28
+ elevation?: number | import("@tamagui/core").Size | undefined;
29
+ } & import("@tamagui/core").WithShorthands<import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase>> & {
30
+ ref?: import("react").Ref<import("@tamagui/core").TamaguiElement> | undefined;
31
+ }> & import("@tamagui/core").StaticComponentObject<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
32
+ elevation?: number | import("@tamagui/core").Size | undefined;
33
+ }, import("@tamagui/core").StaticConfigPublic> & Omit<import("@tamagui/core").StaticConfigPublic, "staticConfig"> & {
34
+ __tama: [import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
35
+ elevation?: number | import("@tamagui/core").Size | undefined;
36
+ }, import("@tamagui/core").StaticConfigPublic];
37
+ };
32
38
  /**
33
39
  * @summary A view that stacks its children on top of each other.
34
40
  * @see — Docs https://tamagui.dev/ui/stacks#xstack-ystack-zstack
35
41
  */
36
- export declare const ZStack: import("@tamagui/core").TamaguiComponent<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
37
- elevation?: number | SizeTokens | undefined;
38
- fullscreen?: boolean | undefined;
42
+ export declare const ZStack: import("react").FunctionComponent<Omit<import("@tamagui/core").RNTamaguiViewNonStyleProps, "elevation" | keyof import("@tamagui/core").StackStyleBase> & import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase> & {
43
+ elevation?: number | import("@tamagui/core").Size | undefined;
44
+ } & import("@tamagui/core").WithShorthands<import("@tamagui/core").WithThemeValues<import("@tamagui/core").StackStyleBase>> & {
45
+ ref?: import("react").Ref<import("@tamagui/core").TamaguiElement> | undefined;
46
+ }> & import("@tamagui/core").StaticComponentObject<import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
47
+ elevation?: number | import("@tamagui/core").Size | undefined;
39
48
  }, import("@tamagui/core").StaticConfigPublic & {
40
49
  neverFlatten: true;
41
50
  isZStack: true;
42
- }>;
51
+ }> & Omit<import("@tamagui/core").StaticConfigPublic & {
52
+ neverFlatten: true;
53
+ isZStack: true;
54
+ }, "staticConfig"> & {
55
+ __tama: [import("@tamagui/core").TamaDefer, import("@tamagui/core").TamaguiElement, import("@tamagui/core").RNTamaguiViewNonStyleProps, import("@tamagui/core").StackStyleBase, {
56
+ elevation?: number | import("@tamagui/core").Size | undefined;
57
+ }, import("@tamagui/core").StaticConfigPublic & {
58
+ neverFlatten: true;
59
+ isZStack: true;
60
+ }];
61
+ };
43
62
  //# sourceMappingURL=Stacks.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Stacks.d.ts","sourceRoot":"","sources":["../src/Stacks.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAKzD,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAA;IAEpB,SAAS,CAAC,EAAE,MAAM,GAAG,UAAU,CAAA;CAChC;AAED,MAAM,MAAM,WAAW,GAAG,IAAI,CAAC,QAAQ,CAAC,OAAO,MAAM,CAAC,EAAE,MAAM,aAAa,CAAC,GAC1E,aAAa,CAAA;AAEf,MAAM,MAAM,WAAW,GAAG,WAAW,CAAA;AACrC,MAAM,MAAM,WAAW,GAAG,WAAW,CAAA;AAErC,eAAO,MAAM,eAAe;;;CAGlB,CAAA;AAaV;;;GAGG;AACH,eAAO,MAAM,MAAM;;;8CAGjB,CAAA;AAIF;;;GAGG;AACH,eAAO,MAAM,MAAM;;;8CAGjB,CAAA;AAIF;;;GAGG;AACH,eAAO,MAAM,MAAM;;;;;;EASlB,CAAA"}
1
+ {"version":3,"file":"Stacks.d.ts","sourceRoot":"","sources":["../src/Stacks.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAKzD,MAAM,WAAW,aAAa;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,UAAU,CAAA;CAChC;AAED,MAAM,MAAM,WAAW,GAAG,IAAI,CAAC,QAAQ,CAAC,OAAO,MAAM,CAAC,EAAE,MAAM,aAAa,CAAC,GAC1E,aAAa,CAAA;AAEf,MAAM,MAAM,WAAW,GAAG,WAAW,CAAA;AACrC,MAAM,MAAM,WAAW,GAAG,WAAW,CAAA;AASrC;;;GAGG;AACH,eAAO,MAAM,MAAM;;;;;;;;;;CAGjB,CAAA;AAIF;;;GAGG;AACH,eAAO,MAAM,MAAM;;;;;;;;;;CAGjB,CAAA;AAIF;;;GAGG;AACH,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;CASlB,CAAA"}
@@ -1,12 +1,12 @@
1
1
  import type { SizeTokens, SizeVariantSpreadFunction, ViewProps, VariantSpreadExtras } from '@tamagui/core';
2
2
  export declare const getElevation: SizeVariantSpreadFunction<ViewProps>;
3
3
  export declare const getSizedElevation: (val: SizeTokens | number | boolean, { theme, tokens }: VariantSpreadExtras<any>) => {
4
- elevationAndroid?: number | undefined;
5
- shadowColor: import("@tamagui/core").Variable<string> | import("@tamagui/core").Variable<any> | import("@tamagui/core").Variable<undefined> | undefined;
4
+ shadowColor: import("@tamagui/core").Variable<any> | import("@tamagui/core").Variable<string> | import("@tamagui/core").Variable<number> | import("@tamagui/core").Variable<import("@tamagui/core").PxValue> | import("@tamagui/core").Variable<import("@tamagui/core").VariableValGeneric>;
6
5
  shadowRadius: number;
7
6
  shadowOffset: {
8
7
  height: number;
9
8
  width: number;
10
9
  };
10
+ elevationAndroid?: number | undefined;
11
11
  } | undefined;
12
12
  //# sourceMappingURL=getElevation.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getElevation.d.ts","sourceRoot":"","sources":["../src/getElevation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,yBAAyB,EACzB,SAAS,EACT,mBAAmB,EACpB,MAAM,eAAe,CAAA;AAGtB,eAAO,MAAM,YAAY,EAAE,yBAAyB,CAAC,SAAS,CAM7D,CAAA;AAED,eAAO,MAAM,iBAAiB,GAC5B,KAAK,UAAU,GAAG,MAAM,GAAG,OAAO,EAClC,mBAAmB,mBAAmB,CAAC,GAAG,CAAC;;;;;;;;aA4B5C,CAAA"}
1
+ {"version":3,"file":"getElevation.d.ts","sourceRoot":"","sources":["../src/getElevation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,yBAAyB,EACzB,SAAS,EACT,mBAAmB,EACpB,MAAM,eAAe,CAAA;AAGtB,eAAO,MAAM,YAAY,EAAE,yBAAyB,CAAC,SAAS,CAU7D,CAAA;AAED,eAAO,MAAM,iBAAiB,QACvB,UAAU,GAAG,MAAM,GAAG,OAAO,qBACf,mBAAmB,CAAC,GAAG,CAAC;;;;;;;;aA+B5C,CAAA"}
package/types/index.d.ts CHANGED
@@ -1,6 +1,4 @@
1
1
  export * from './Stacks';
2
- export * from './ThemeableStack';
3
- export * from './SizableStack';
4
2
  export * from './NestingContext';
5
3
  export * from './getElevation';
6
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,kBAAkB,CAAA;AAChC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,kBAAkB,CAAA;AAChC,cAAc,gBAAgB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,kBAAkB,CAAA;AAChC,cAAc,gBAAgB,CAAA"}
@@ -1,52 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __export = (target, all) => {
6
- for (var name in all) __defProp(target, name, {
7
- get: all[name],
8
- enumerable: true
9
- });
10
- };
11
- var __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from === "object" || typeof from === "function") {
13
- for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
14
- get: () => from[key],
15
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
16
- });
17
- }
18
- return to;
19
- };
20
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
21
- value: true
22
- }), mod);
23
- var SizableStack_exports = {};
24
- __export(SizableStack_exports, {
25
- SizableStack: () => SizableStack
26
- });
27
- module.exports = __toCommonJS(SizableStack_exports);
28
- var import_core = require("@tamagui/core");
29
- var import_get_button_sized = require("@tamagui/get-button-sized");
30
- var import_ThemeableStack = require("./ThemeableStack.cjs");
31
- var import_variants = require("./variants.cjs");
32
- const SizableStack = (0, import_core.styled)(import_ThemeableStack.ThemeableStack, {
33
- name: "SizableStack",
34
- variants: {
35
- unstyled: {
36
- true: {
37
- elevate: false,
38
- bordered: false
39
- }
40
- },
41
- circular: import_variants.circular,
42
- elevate: import_variants.elevate,
43
- bordered: {
44
- true: import_variants.bordered
45
- },
46
- size: {
47
- "...size": (val, extras) => {
48
- return (0, import_get_button_sized.getButtonSized)(val, extras);
49
- }
50
- }
51
- }
52
- });
@@ -1,55 +0,0 @@
1
- "use strict";
2
-
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: true
11
- });
12
- };
13
- var __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from === "object" || typeof from === "function") {
15
- for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
16
- get: () => from[key],
17
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
18
- });
19
- }
20
- return to;
21
- };
22
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
23
- value: true
24
- }), mod);
25
- var SizableStack_exports = {};
26
- __export(SizableStack_exports, {
27
- SizableStack: () => SizableStack
28
- });
29
- module.exports = __toCommonJS(SizableStack_exports);
30
- var import_core = require("@tamagui/core");
31
- var import_get_button_sized = require("@tamagui/get-button-sized");
32
- var import_ThemeableStack = require("./ThemeableStack.native.js");
33
- var import_variants = require("./variants.native.js");
34
- var SizableStack = (0, import_core.styled)(import_ThemeableStack.ThemeableStack, {
35
- name: "SizableStack",
36
- variants: {
37
- unstyled: {
38
- true: {
39
- elevate: false,
40
- bordered: false
41
- }
42
- },
43
- circular: import_variants.circular,
44
- elevate: import_variants.elevate,
45
- bordered: {
46
- true: import_variants.bordered
47
- },
48
- size: {
49
- "...size": function (val, extras) {
50
- return (0, import_get_button_sized.getButtonSized)(val, extras);
51
- }
52
- }
53
- }
54
- });
55
- //# sourceMappingURL=SizableStack.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","SizableStack_exports","__export","SizableStack","module","exports","import_core","require","import_get_button_sized","import_ThemeableStack","import_variants","styled","ThemeableStack","name","variants","unstyled","true","elevate","bordered","circular","size","...size","val","extras","getButtonSized"],"sources":["../../src/SizableStack.tsx"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,oBAAA;AAAAC,QAAA,CAAAD,oBAAA;EAAAE,YAAA,EAAAA,CAAA,KAAAA;AAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAT,YAAuB,CAAAK,oBAAA;AACvB,IAAAK,WAAA,GAAAC,OAAA,gBAA+B;AAE/B,IAAAC,uBAAA,GAA+BD,OAAA;AAC/B,IAAAE,qBAA4C,GAAAF,OAAA;AAErC,IAAAG,eAAM,GAAAH,OAAe;AAAuB,IACjDJ,YAAM,OAAAG,WAAA,CAAAK,MAAA,EAAAF,qBAAA,CAAAG,cAAA;EAENC,IAAA,gBAAU;EAAAC,QACR;IAAUC,QACF;MAAAC,IACJ;QACAC,OAAA,OAAU;QACZC,QAAA;MACF;IAEA;IACAC,QAAA,EAAAT,eAAA,CAAAS,QAAA;IAEAF,OAAA,EAAAP,eAAU,CAAAO,OAAA;IAAAC,QACF;MACRF,IAAA,EAAAN,eAAA,CAAAQ;IAEA;IAAME,IACJ;MACE,oBAAAC,CAAOC,GAAA,EAAAC,MAAA;QACT,WAAAf,uBAAA,CAAAgB,cAAA,EAAAF,GAAA,EAAAC,MAAA;MACF;IACF;EACD","ignoreList":[]}