@tamagui/helpers-node 2.0.0-rc.36 → 2.0.0-rc.36-1775243248161
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/getDefaultTamaguiOptions.cjs +12 -10
- package/dist/getDefaultTamaguiOptions.native.js +12 -10
- package/dist/getDefaultTamaguiOptions.native.js.map +1 -1
- package/dist/getTamaguiDefaultPath.cjs +26 -19
- package/dist/getTamaguiDefaultPath.native.js +32 -25
- package/dist/getTamaguiDefaultPath.native.js.map +1 -1
- package/dist/getTamaguiOptions.cjs +12 -10
- package/dist/getTamaguiOptions.native.js +12 -10
- package/dist/getTamaguiOptions.native.js.map +1 -1
- package/dist/index.cjs +7 -5
- package/dist/index.native.js +7 -5
- package/dist/index.native.js.map +1 -1
- package/dist/readTamaguiOptions.cjs +30 -23
- package/dist/readTamaguiOptions.native.js +33 -26
- package/dist/readTamaguiOptions.native.js.map +1 -1
- package/package.json +3 -3
|
@@ -3,20 +3,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var getDefaultTamaguiOptions_exports = {};
|
|
22
24
|
__export(getDefaultTamaguiOptions_exports, {
|
|
@@ -5,20 +5,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
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, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var getDefaultTamaguiOptions_exports = {};
|
|
24
26
|
__export(getDefaultTamaguiOptions_exports, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
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","__toCommonJS","mod","value","getDefaultTamaguiOptions_exports","getDefaultTamaguiOptions","module","exports","import_getTamaguiDefaultPath","require","param","cwd","platform","components","config","getDefaultTamaguiConfigPath"],"sources":["getDefaultTamaguiOptions.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 getDefaultTamaguiOptions_exports = {};\n__export(getDefaultTamaguiOptions_exports, {\n getDefaultTamaguiOptions: () => getDefaultTamaguiOptions\n});\nmodule.exports = __toCommonJS(getDefaultTamaguiOptions_exports);\nvar import_getTamaguiDefaultPath = require(\"./getTamaguiDefaultPath\");\nasync function getDefaultTamaguiOptions(param) {\n var { cwd = \".\" } = param;\n return {\n platform: \"native\",\n components: [\n \"tamagui\"\n ],\n config: await (0, import_getTamaguiDefaultPath.getDefaultTamaguiConfigPath)({\n cwd\n })\n };\n}\n//# sourceMappingURL=getDefaultTamaguiOptions.js.map\n"],"mappings":"AAAA,YAAY;;AACZ,IAAIA,SAAS,GAAGC,MAAM,CAACC,cAAc;AACrC,IAAIC,gBAAgB,GAAGF,MAAM,CAACG,wBAAwB;AACtD,IAAIC,iBAAiB,GAAGJ,MAAM,CAACK,mBAAmB;AAClD,IAAIC,YAAY,GAA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AO,CAAC,mCAAyB,CAAC;AACrE,eAAeJ,wBAAwBA,CAACK,KAAK,EAAE;EAC7C,IAAI;IAAEC,GAAG,GAAG;EAAI,CAAC,GAAGD,KAAK;EACzB,OAAO;IACLE,QAAQ,EAAE,QAAQ;IAClBC,UAAU,EAAE,CACV,SAAS,CACV;IACDC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAEN,4BAA4B,CAACO,2BAA2B,EAAE;MAC1EJ;IACF,CAAC;EACH,CAAC;AACH","ignoreList":[]}
|
|
@@ -3,37 +3,44 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var getTamaguiDefaultPath_exports = {};
|
|
22
24
|
__export(getTamaguiDefaultPath_exports, {
|
|
23
25
|
getDefaultTamaguiConfigPath: () => getDefaultTamaguiConfigPath
|
|
24
26
|
});
|
|
25
27
|
module.exports = __toCommonJS(getTamaguiDefaultPath_exports);
|
|
26
|
-
var import_node_path = require("node:path")
|
|
27
|
-
|
|
28
|
+
var import_node_path = require("node:path");
|
|
29
|
+
var import_fs_extra = require("fs-extra");
|
|
28
30
|
let cachedPath = "";
|
|
29
31
|
async function getDefaultTamaguiConfigPath({
|
|
30
32
|
cwd = ".",
|
|
31
|
-
cache =
|
|
33
|
+
cache = true
|
|
32
34
|
}) {
|
|
33
|
-
if (cache && cachedPath)
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
if (cache && cachedPath) {
|
|
36
|
+
return cachedPath;
|
|
37
|
+
}
|
|
38
|
+
const defaultPaths = ["tamagui.config.ts", (0, import_node_path.join)("src", "tamagui.config.ts")].map(p => (0, import_node_path.join)(cwd, p));
|
|
39
|
+
const existing = (await Promise.all(defaultPaths.map(path => (0, import_fs_extra.pathExists)(path)))).findIndex(x => !!x);
|
|
40
|
+
const found = defaultPaths[existing];
|
|
41
|
+
if (!found) {
|
|
42
|
+
throw new Error(`No found tamagui.config.ts`);
|
|
43
|
+
}
|
|
44
|
+
cachedPath = found;
|
|
45
|
+
return found;
|
|
39
46
|
}
|
|
@@ -5,45 +5,52 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
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, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var getTamaguiDefaultPath_exports = {};
|
|
24
26
|
__export(getTamaguiDefaultPath_exports, {
|
|
25
27
|
getDefaultTamaguiConfigPath: () => getDefaultTamaguiConfigPath
|
|
26
28
|
});
|
|
27
29
|
module.exports = __toCommonJS(getTamaguiDefaultPath_exports);
|
|
28
|
-
var import_path = require("path")
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
var import_path = require("path");
|
|
31
|
+
var import_fs_extra = require("fs-extra");
|
|
32
|
+
var cachedPath = "";
|
|
31
33
|
async function getDefaultTamaguiConfigPath(param) {
|
|
32
34
|
var {
|
|
33
35
|
cwd = ".",
|
|
34
|
-
cache =
|
|
36
|
+
cache = true
|
|
35
37
|
} = param;
|
|
36
|
-
if (cache && cachedPath)
|
|
38
|
+
if (cache && cachedPath) {
|
|
39
|
+
return cachedPath;
|
|
40
|
+
}
|
|
37
41
|
var defaultPaths = ["tamagui.config.ts", (0, import_path.join)("src", "tamagui.config.ts")].map(function (p) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
if (!found)
|
|
47
|
-
|
|
42
|
+
return (0, import_path.join)(cwd, p);
|
|
43
|
+
});
|
|
44
|
+
var existing = (await Promise.all(defaultPaths.map(function (path) {
|
|
45
|
+
return (0, import_fs_extra.pathExists)(path);
|
|
46
|
+
}))).findIndex(function (x) {
|
|
47
|
+
return !!x;
|
|
48
|
+
});
|
|
49
|
+
var found = defaultPaths[existing];
|
|
50
|
+
if (!found) {
|
|
51
|
+
throw new Error(`No found tamagui.config.ts`);
|
|
52
|
+
}
|
|
53
|
+
cachedPath = found;
|
|
54
|
+
return found;
|
|
48
55
|
}
|
|
49
56
|
//# sourceMappingURL=getTamaguiDefaultPath.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
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","__toCommonJS","mod","value","getTamaguiDefaultPath_exports","getDefaultTamaguiConfigPath","module","exports","import_path","require","import_fs_extra","cachedPath","param","cwd","cache","defaultPaths","join","map","p","existing","Promise","path","pathExists","findIndex","x","found","Error"],"sources":["getTamaguiDefaultPath.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 getTamaguiDefaultPath_exports = {};\n__export(getTamaguiDefaultPath_exports, {\n getDefaultTamaguiConfigPath: () => getDefaultTamaguiConfigPath\n});\nmodule.exports = __toCommonJS(getTamaguiDefaultPath_exports);\nvar import_path = require(\"path\");\nvar import_fs_extra = require(\"fs-extra\");\nvar cachedPath = \"\";\nasync function getDefaultTamaguiConfigPath(param) {\n var { cwd = \".\", cache = true } = param;\n if (cache && cachedPath) {\n return cachedPath;\n }\n var defaultPaths = [\n \"tamagui.config.ts\",\n (0, import_path.join)(\"src\", \"tamagui.config.ts\")\n ].map(function(p) {\n return (0, import_path.join)(cwd, p);\n });\n var existing = (await Promise.all(defaultPaths.map(function(path) {\n return (0, import_fs_extra.pathExists)(path);\n }))).findIndex(function(x) {\n return !!x;\n });\n var found = defaultPaths[existing];\n if (!found) {\n throw new Error(`No found tamagui.config.ts`);\n }\n cachedPath = found;\n return found;\n}\n//# sourceMappingURL=getTamaguiDefaultPath.js.map\n"],"mappings":"AAAA,YAAY;;AACZ,IAAIA,SAAS,GAAGC,MAAM,CAACC,cAAc;AACrC,IAAIC,gBAAgB,GAAGF,MAAM,CAACG,wBAAwB;AACtD,IAAIC,iBAAiB,GAAGJ,MAAM,CAACK,mBAAmB;AAClD,IAAIC,YAAY,GAAGN,MAAM,CAACO,SAAS,CAACC,cAAc;AAClD,IAAIC,QAAQ,GAAGA,CAACC,MAAM,EAAEC,GAAG,KAAK;EAC9B,KAAK,IAAIC,IAAI,IAAID,GAAG,EAClBZ,SAAS,CAACW,MAAM,EAAEE,IAAI,EAAE;IAAEC,GAAG,EAAEF,GAAG,CAACC,IAAI,CAAC;IAAEE,UAAU,EAAE;EAAK,CAAC,CAAC;AACjE,CAAC;AACD,IAAIC,WAAW,GAAGA,CAACC,EAAE,EAAEC,IAAI,EAAEC,MAAM,EAAEC,IAAI,KAAK;EAC5C,IAAIF,IAAI,IAAI,OAAOA,IAAI,KAAK,QAAQ,IAAI,OAAOA,IAAI,KAAK,UAAU,EAAE;IAClE,KAAK,IAAIG,GAAG,IAAIhB,iBAAiB,CAACa,IAAI,CAAC,EACrC,IAAI,CAACX,YAAY,CAACe,IAAI,CAACL,EAAE,EAAEI,GAAG,CAAC,IAAIA,GAAG,KAAKF,MAAM,EAC/CnB,S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B,YAAY,CAACE,GAAG,CAAC,UAASI,IAAI,EAAE;IAChE,OAAO,CAAC,CAAC,EAAEX,eAAe,CAACY,UAAU,EAAED,IAAI,CAAC;EAC9C,CAAC,CAAC,CAAC,EAAEE,SAAS,CAAC,UAASC,CAAC,EAAE;IACzB,OAAO,CAAC,CAACA,CAAC;EACZ,CAAC,CAAC;EACF,IAAIC,KAAK,GAAGV,YAAY,CAACI,QAAQ,CAAC;EAClC,IAAI,CAACM,KAAK,EAAE;IACV,MAAM,IAAIC,KAAK,CAAC,4BAA4B,CAAC;EAC/C;EACAf,UAAU,GAAGc,KAAK;EAClB,OAAOA,KAAK;AACd","ignoreList":[]}
|
|
@@ -3,20 +3,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var getTamaguiOptions_exports = {};
|
|
22
24
|
__export(getTamaguiOptions_exports, {
|
|
@@ -5,20 +5,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
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, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var getTamaguiOptions_exports = {};
|
|
24
26
|
__export(getTamaguiOptions_exports, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
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","__toCommonJS","mod","value","getTamaguiOptions_exports","getTamaguiOptions","module","exports","import_readTamaguiOptions","require","param","cwd","readTamaguiOptions","options"],"sources":["getTamaguiOptions.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 getTamaguiOptions_exports = {};\n__export(getTamaguiOptions_exports, {\n getTamaguiOptions: () => getTamaguiOptions\n});\nmodule.exports = __toCommonJS(getTamaguiOptions_exports);\nvar import_readTamaguiOptions = require(\"./readTamaguiOptions\");\nasync function getTamaguiOptions(param) {\n var { cwd = \".\" } = param;\n return (await (0, import_readTamaguiOptions.readTamaguiOptions)({\n cwd\n })).options;\n}\n//# sourceMappingURL=getTamaguiOptions.js.map\n"],"mappings":"AAAA,YAAY;;AACZ,IAAIA,SAAS,GAAGC,MAAM,CAACC,cAAc;AACrC,IAAIC,gBAAgB,GAAGF,MAAM,CAACG,wBAAwB;AACtD,IAAIC,iBAAiB,GAAGJ,MAAM,CAACK,mBAAmB;AAClD,IAAIC,YAAY,GAAGN,MAAM,CAACO,SAAS,CAACC,cAAc;AAClD,IAAIC,QAAQ,GAAGA,CAACC,MAAM,EAAEC,GAAG,KAAK;EAC9B,KAAK,IAAIC,IAAI,IAAID,GAAG,EAClBZ,SAAS,CAACW,MAAM,EAAEE,IAAI,EAAE;IAAEC,GAAG,EAAEF,GAAG,CAACC,IAAI,CAAC;IAAEE,UAAU,EAAE;EAAK,CAAC,CAAC;AACjE,CAAC;AACD,IAAIC,WAAW,GAAGA,CAACC,EAAE,EAAEC,IAAI,EAAEC,MA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
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __copyProps = (to, from, except, desc) => {
|
|
6
|
-
|
|
6
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
7
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
7
8
|
get: () => from[key],
|
|
8
9
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
9
10
|
});
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
13
15
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
14
|
-
value:
|
|
16
|
+
value: true
|
|
15
17
|
}), mod);
|
|
16
18
|
var index_exports = {};
|
|
17
19
|
module.exports = __toCommonJS(index_exports);
|
package/dist/index.native.js
CHANGED
|
@@ -5,15 +5,17 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __copyProps = (to, from, except, desc) => {
|
|
8
|
-
|
|
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, {
|
|
9
10
|
get: () => from[key],
|
|
10
11
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
11
12
|
});
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
}
|
|
14
|
+
return to;
|
|
15
|
+
};
|
|
16
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
17
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
16
|
-
value:
|
|
18
|
+
value: true
|
|
17
19
|
}), mod);
|
|
18
20
|
var index_exports = {};
|
|
19
21
|
module.exports = __toCommonJS(index_exports);
|
package/dist/index.native.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["__defProp","Object","defineProperty","__getOwnPropDesc","getOwnPropertyDescriptor","__getOwnPropNames","getOwnPropertyNames","__hasOwnProp","prototype","hasOwnProperty","__copyProps","to","from","except","desc","key","call","get","enumerable","__reExport","target","mod","secondTarget","__toCommonJS","value","index_exports","module","exports","require"],"sources":["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(\"./readTamaguiOptions\"), module.exports);\n__reExport(index_exports, require(\"./getTamaguiDefaultPath\"), module.exports);\n__reExport(index_exports, require(\"./getTamaguiOptions\"), module.exports);\n//# sourceMappingURL=index.js.map\n"],"mappings":"AAAA,YAAY;;AACZ,IAAIA,SAAS,GAAGC,MAAM,CAACC,cAAc;AACrC,IAAIC,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CAAC,EAAEF,MAAM,CAACC,OAAO,CAAC;AAC1ER,UAAU,CAACM,aAAa,EAAEG,OAAO,CAAC,mCAAyB,CAAC,EAAEF,MAAM,CAACC,OAAO,CAAC;AAC7ER,UAAU,CAACM,aAAa,EAAEG,OAAO,CAAC,+BAAqB,CAAC,EAAEF,MAAM,CAACC,OAAO,CAAC","ignoreList":[]}
|
|
@@ -3,44 +3,50 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var readTamaguiOptions_exports = {};
|
|
22
24
|
__export(readTamaguiOptions_exports, {
|
|
23
25
|
readTamaguiOptions: () => readTamaguiOptions
|
|
24
26
|
});
|
|
25
27
|
module.exports = __toCommonJS(readTamaguiOptions_exports);
|
|
26
|
-
var import_node_path = require("node:path")
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
var import_node_path = require("node:path");
|
|
29
|
+
var import_fs_extra = require("fs-extra");
|
|
30
|
+
var import_getDefaultTamaguiOptions = require("./getDefaultTamaguiOptions.cjs");
|
|
29
31
|
async function readTamaguiOptions({
|
|
30
32
|
cwd = "."
|
|
31
33
|
}) {
|
|
32
34
|
const filePath = (0, import_node_path.join)(cwd, "tamagui.json");
|
|
33
|
-
if (!(await (0, import_fs_extra.pathExists)(filePath)))
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
if (!(await (0, import_fs_extra.pathExists)(filePath))) {
|
|
36
|
+
return {
|
|
37
|
+
exists: false,
|
|
38
|
+
options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
39
|
+
cwd
|
|
40
|
+
})
|
|
41
|
+
};
|
|
42
|
+
}
|
|
39
43
|
try {
|
|
40
44
|
const options = await (0, import_fs_extra.readJSON)(filePath);
|
|
41
|
-
if (!Array.isArray(options.components))
|
|
45
|
+
if (!Array.isArray(options.components)) {
|
|
46
|
+
throw new Error(`Invalid components: not string[]`);
|
|
47
|
+
}
|
|
42
48
|
return {
|
|
43
|
-
exists:
|
|
49
|
+
exists: true,
|
|
44
50
|
options: {
|
|
45
51
|
...(!options.config && (await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
46
52
|
cwd
|
|
@@ -49,8 +55,9 @@ async function readTamaguiOptions({
|
|
|
49
55
|
}
|
|
50
56
|
};
|
|
51
57
|
} catch (err) {
|
|
52
|
-
|
|
53
|
-
|
|
58
|
+
console.error(`Error reading tamagui.json: ${err.message} ${err.stack}`);
|
|
59
|
+
return {
|
|
60
|
+
exists: false,
|
|
54
61
|
options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
55
62
|
cwd
|
|
56
63
|
})
|
|
@@ -5,45 +5,51 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
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, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var readTamaguiOptions_exports = {};
|
|
24
26
|
__export(readTamaguiOptions_exports, {
|
|
25
27
|
readTamaguiOptions: () => readTamaguiOptions
|
|
26
28
|
});
|
|
27
29
|
module.exports = __toCommonJS(readTamaguiOptions_exports);
|
|
28
|
-
var import_path = require("path")
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
var import_path = require("path");
|
|
31
|
+
var import_fs_extra = require("fs-extra");
|
|
32
|
+
var import_getDefaultTamaguiOptions = require("./getDefaultTamaguiOptions.native.js");
|
|
31
33
|
async function readTamaguiOptions(param) {
|
|
32
34
|
var {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
if (!(await (0, import_fs_extra.pathExists)(filePath)))
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
35
|
+
cwd = "."
|
|
36
|
+
} = param;
|
|
37
|
+
var filePath = (0, import_path.join)(cwd, "tamagui.json");
|
|
38
|
+
if (!(await (0, import_fs_extra.pathExists)(filePath))) {
|
|
39
|
+
return {
|
|
40
|
+
exists: false,
|
|
41
|
+
options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
42
|
+
cwd
|
|
43
|
+
})
|
|
44
|
+
};
|
|
45
|
+
}
|
|
42
46
|
try {
|
|
43
47
|
var options = await (0, import_fs_extra.readJSON)(filePath);
|
|
44
|
-
if (!Array.isArray(options.components))
|
|
48
|
+
if (!Array.isArray(options.components)) {
|
|
49
|
+
throw new Error(`Invalid components: not string[]`);
|
|
50
|
+
}
|
|
45
51
|
return {
|
|
46
|
-
exists:
|
|
52
|
+
exists: true,
|
|
47
53
|
options: {
|
|
48
54
|
...(!options.config && (await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
49
55
|
cwd
|
|
@@ -52,8 +58,9 @@ async function readTamaguiOptions(param) {
|
|
|
52
58
|
}
|
|
53
59
|
};
|
|
54
60
|
} catch (err) {
|
|
55
|
-
|
|
56
|
-
|
|
61
|
+
console.error(`Error reading tamagui.json: ${err.message} ${err.stack}`);
|
|
62
|
+
return {
|
|
63
|
+
exists: false,
|
|
57
64
|
options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({
|
|
58
65
|
cwd
|
|
59
66
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
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","__toCommonJS","mod","value","readTamaguiOptions_exports","readTamaguiOptions","module","exports","import_path","require","import_fs_extra","import_getDefaultTamaguiOptions","param","cwd","filePath","join","pathExists","exists","options","getDefaultTamaguiOptions","readJSON","Array","isArray","components","Error","config","err","console","error","message","stack"],"sources":["readTamaguiOptions.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 readTamaguiOptions_exports = {};\n__export(readTamaguiOptions_exports, {\n readTamaguiOptions: () => readTamaguiOptions\n});\nmodule.exports = __toCommonJS(readTamaguiOptions_exports);\nvar import_path = require(\"path\");\nvar import_fs_extra = require(\"fs-extra\");\nvar import_getDefaultTamaguiOptions = require(\"./getDefaultTamaguiOptions\");\nasync function readTamaguiOptions(param) {\n var { cwd = \".\" } = param;\n var filePath = (0, import_path.join)(cwd, \"tamagui.json\");\n if (!await (0, import_fs_extra.pathExists)(filePath)) {\n return {\n exists: false,\n options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({\n cwd\n })\n };\n }\n try {\n var options = await (0, import_fs_extra.readJSON)(filePath);\n if (!Array.isArray(options.components)) {\n throw new Error(`Invalid components: not string[]`);\n }\n return {\n exists: true,\n options: {\n ...!options.config && await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({\n cwd\n }),\n ...options\n }\n };\n } catch (err) {\n console.error(`Error reading tamagui.json: ${err.message} ${err.stack}`);\n return {\n exists: false,\n options: await (0, import_getDefaultTamaguiOptions.getDefaultTamaguiOptions)({\n cwd\n })\n };\n }\n}\n//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AE;IACZC,OAAO,CAACC,KAAK,CAAC,+BAA+BF,GAAG,CAACG,OAAO,IAAIH,GAAG,CAACI,KAAK,EAAE,CAAC;IACxE,OAAO;MACLb,MAAM,EAAE,KAAK;MACbC,OAAO,EAAE,MAAM,CAAC,CAAC,EAAEP,+BAA+B,CAACQ,wBAAwB,EAAE;QAC3EN;MACF,CAAC;IACH,CAAC;EACH;AACF","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/helpers-node",
|
|
3
|
-
"version": "2.0.0-rc.36",
|
|
3
|
+
"version": "2.0.0-rc.36-1775243248161",
|
|
4
4
|
"source": "src/index.ts",
|
|
5
5
|
"files": [
|
|
6
6
|
"src",
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
"clean:build": "tamagui-build clean:build"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@tamagui/types": "2.0.0-rc.36"
|
|
23
|
+
"@tamagui/types": "2.0.0-rc.36-1775243248161"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@tamagui/build": "2.0.0-rc.36",
|
|
26
|
+
"@tamagui/build": "2.0.0-rc.36-1775243248161",
|
|
27
27
|
"fs-extra": "^11.2.0"
|
|
28
28
|
}
|
|
29
29
|
}
|