@tamagui/static-sync 2.0.0-rc.30 → 2.0.0-rc.31

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/static-sync",
3
- "version": "2.0.0-rc.30",
3
+ "version": "2.0.0-rc.31",
4
4
  "license": "MIT",
5
5
  "source": "src/index.ts",
6
6
  "files": [
@@ -32,11 +32,11 @@
32
32
  },
33
33
  "dependencies": {
34
34
  "@babel/core": "^7.25.2",
35
- "@tamagui/static": "2.0.0-rc.30",
36
- "@tamagui/types": "2.0.0-rc.30",
35
+ "@tamagui/static": "2.0.0-rc.31",
36
+ "@tamagui/types": "2.0.0-rc.31",
37
37
  "synckit": "^0.9.2"
38
38
  },
39
39
  "devDependencies": {
40
- "@tamagui/build": "2.0.0-rc.30"
40
+ "@tamagui/build": "2.0.0-rc.31"
41
41
  }
42
42
  }
package/dist/index.js DELETED
@@ -1,95 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: !0 });
9
- }, __copyProps = (to, from, except, desc) => {
10
- if (from && typeof from == "object" || typeof from == "function")
11
- for (let key of __getOwnPropNames(from))
12
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
13
- return to;
14
- };
15
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
16
- // If the importer is in node compatibility mode or this is not an ESM
17
- // file that has been converted to a CommonJS file using a Babel-
18
- // compatible transform (i.e. "__esModule" has not been set), then set
19
- // "default" to the CommonJS "module.exports" for node compatibility.
20
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
21
- mod
22
- )), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
23
-
24
- // src/index.ts
25
- var index_exports = {};
26
- __export(index_exports, {
27
- extractToClassNamesSync: () => extractToClassNamesSync,
28
- extractToNativeSync: () => extractToNativeSync,
29
- getBabelPlugin: () => getBabelPlugin,
30
- getPragmaOptions: () => getPragmaOptions
31
- });
32
- module.exports = __toCommonJS(index_exports);
33
- var import_synckit = require("synckit"), import_node_url = require("node:url"), import_meta = {}, getWorkerPath = () => typeof import_meta < "u" && import_meta.url ? (0, import_node_url.fileURLToPath)(import_meta.resolve("@tamagui/static/worker")).replace(/\.mjs$/, ".js") : require.resolve("@tamagui/static/worker").replace(/\.mjs$/, ".js"), runTaskSync = (0, import_synckit.createSyncFn)(getWorkerPath(), {
34
- timeout: 6e4
35
- // 60s timeout for sync operations
36
- }), getPragmaOptions = (props) => {
37
- let { default: Static } = require("@tamagui/static");
38
- return Static.getPragmaOptions(props);
39
- };
40
- function extractToClassNamesSync(params) {
41
- let { source, sourcePath = "", options, shouldPrintDebug = !1 } = params;
42
- if (typeof source != "string")
43
- throw new Error("`source` must be a string of javascript");
44
- let result = runTaskSync({
45
- type: "extractToClassNames",
46
- source,
47
- sourcePath,
48
- options,
49
- shouldPrintDebug
50
- });
51
- if (!result.success) {
52
- let errorMessage = [
53
- `[tamagui-extract] Error processing file: ${sourcePath || "(unknown)"}`,
54
- "",
55
- result.error,
56
- result.stack ? `
57
- ${result.stack}` : ""
58
- ].filter(Boolean).join(`
59
- `);
60
- throw new Error(errorMessage);
61
- }
62
- return result.data;
63
- }
64
- function extractToNativeSync(sourceFileName, sourceCode, options) {
65
- let result = runTaskSync({
66
- type: "extractToNative",
67
- sourceFileName,
68
- sourceCode,
69
- options
70
- });
71
- if (!result.success) {
72
- let errorMessage = [
73
- `[tamagui-extract] Error processing file: ${sourceFileName || "(unknown)"}`,
74
- "",
75
- result.error,
76
- result.stack ? `
77
- ${result.stack}` : ""
78
- ].filter(Boolean).join(`
79
- `);
80
- throw new Error(errorMessage);
81
- }
82
- return result.data;
83
- }
84
- function getBabelPlugin() {
85
- let { default: Static } = require("@tamagui/static");
86
- return Static.getBabelPlugin();
87
- }
88
- // Annotate the CommonJS export names for ESM import in node:
89
- 0 && (module.exports = {
90
- extractToClassNamesSync,
91
- extractToNativeSync,
92
- getBabelPlugin,
93
- getPragmaOptions
94
- });
95
- //# sourceMappingURL=index.js.map
package/dist/index.js.map DELETED
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../src/index.ts"],
4
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAYA,qBAA6B,oBAC7B,kBAA8B,qBAb9B,kBAmBM,gBAAgB,MAEhB,OAAO,cAAgB,OAAe,YAAY,UACjC,+BAAc,YAAY,QAAQ,wBAAwB,CAAC,EAE5D,QAAQ,UAAU,KAAK,IAIpC,gBAAgB,wBAAwB,EAAE,QAAQ,UAAU,KAAK,GAIpE,kBAAc,6BAAa,cAAc,GAAG;AAAA,EAChD,SAAS;AAAA;AACX,CAAC,GAEY,mBAAmB,CAAC,UAA4C;AAE3E,MAAM,EAAE,SAAS,OAAO,IAAI,QAAQ,iBAAiB;AACrD,SAAO,OAAO,iBAAiB,KAAK;AACtC;AAKO,SAAS,wBAAwB,QAKhC;AACN,MAAM,EAAE,QAAQ,aAAa,IAAI,SAAS,mBAAmB,GAAM,IAAI;AAEvE,MAAI,OAAO,UAAW;AACpB,UAAM,IAAI,MAAM,yCAAyC;AAW3D,MAAM,SAAS,YARF;AAAA,IACX,MAAM;AAAA,IACN;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,CAE+B;AAE/B,MAAI,CAAC,OAAO,SAAS;AACnB,QAAM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