@superblocksteam/cli 2.0.0-next.78 → 2.0.0-next.79

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/README.md CHANGED
@@ -14,7 +14,7 @@ $ npm install -g @superblocksteam/cli
14
14
  $ superblocks COMMAND
15
15
  running command...
16
16
  $ superblocks (--version)
17
- @superblocksteam/cli/2.0.0-next.78 linux-x64 node-v20.19.0
17
+ @superblocksteam/cli/2.0.0-next.79 linux-x64 node-v20.19.0
18
18
  $ superblocks --help [COMMAND]
19
19
  USAGE
20
20
  $ superblocks COMMAND
package/dist/index.js CHANGED
@@ -310604,6 +310604,45 @@ var REQUIRED_IMPORTS_BY_PROPERTY_TYPE = {
310604
310604
  }
310605
310605
  ]
310606
310606
  };
310607
+ var EXPRESSION_IMPORTS_BY_IDENTIFIER = {
310608
+ Theme: {
310609
+ importName: "Theme",
310610
+ importPath: "@superblocksteam/library"
310611
+ },
310612
+ Dim: {
310613
+ importName: "Dim",
310614
+ importPath: "@superblocksteam/library"
310615
+ },
310616
+ Global: {
310617
+ importName: "Global",
310618
+ importPath: "@superblocksteam/library"
310619
+ }
310620
+ };
310621
+ var EXPRESSION_IDENTIFIERS = new Set(Object.keys(EXPRESSION_IMPORTS_BY_IDENTIFIER));
310622
+ function getRequiredImportsForProperty(property) {
310623
+ const allImports = /* @__PURE__ */ new Set();
310624
+ function collectImports(prop) {
310625
+ if (isPropertyInfo(prop)) {
310626
+ if (prop.type === "EXPRESSION" && typeof prop.value === "string") {
310627
+ const splitPath = splitJSPath(prop.value);
310628
+ const key2 = splitPath?.[0];
310629
+ if (key2 && EXPRESSION_IDENTIFIERS.has(key2)) {
310630
+ allImports.add(EXPRESSION_IMPORTS_BY_IDENTIFIER[key2]);
310631
+ return;
310632
+ }
310633
+ } else if (prop.type in REQUIRED_IMPORTS_BY_PROPERTY_TYPE) {
310634
+ REQUIRED_IMPORTS_BY_PROPERTY_TYPE[prop.type]?.forEach((imp) => allImports.add(imp));
310635
+ }
310636
+ }
310637
+ if (typeof prop === "object" && prop !== null && !Array.isArray(prop)) {
310638
+ for (const key2 in prop) {
310639
+ collectImports(prop[key2]);
310640
+ }
310641
+ }
310642
+ }
310643
+ collectImports(property);
310644
+ return Array.from(allImports);
310645
+ }
310607
310646
 
310608
310647
  // ../../../vite-plugin-file-sync/dist/parsing/scope.js
310609
310648
  var importsByEntityType = {
@@ -312845,20 +312884,18 @@ var SourceTracker = class {
312845
312884
  }
312846
312885
  for (const [key2, info] of Object.entries(changes)) {
312847
312886
  const jsxAttribute = this.setAttribute(openingTag, key2, info);
312848
- if (info.type in REQUIRED_IMPORTS_BY_PROPERTY_TYPE) {
312849
- const requiredImports = REQUIRED_IMPORTS_BY_PROPERTY_TYPE[info.type];
312850
- if (requiredImports) {
312851
- for (const { importName, importPath } of requiredImports) {
312852
- if (!this.fileToMeta[fileName].imports[importName]) {
312853
- addImport({
312854
- importPath,
312855
- importName,
312856
- path: openingTag,
312857
- onAdd: () => {
312858
- this.fileToMeta[fileName].imports[importName] = true;
312859
- }
312860
- });
312861
- }
312887
+ const imports = getRequiredImportsForProperty(info);
312888
+ if (imports.length > 0) {
312889
+ for (const { importName, importPath } of imports) {
312890
+ if (!this.fileToMeta[fileName].imports[importName]) {
312891
+ addImport({
312892
+ importPath,
312893
+ importName,
312894
+ path: openingTag,
312895
+ onAdd: () => {
312896
+ this.fileToMeta[fileName].imports[importName] = true;
312897
+ }
312898
+ });
312862
312899
  }
312863
312900
  }
312864
312901
  }
@@ -318873,7 +318910,7 @@ var import_util29 = __toESM(require_dist3(), 1);
318873
318910
  // ../sdk/package.json
318874
318911
  var package_default = {
318875
318912
  name: "@superblocksteam/sdk",
318876
- version: "2.0.0-next.78",
318913
+ version: "2.0.0-next.79",
318877
318914
  type: "module",
318878
318915
  description: "Superblocks JS SDK",
318879
318916
  homepage: "https://www.superblocks.com",
@@ -318915,8 +318952,8 @@ var package_default = {
318915
318952
  "@rollup/wasm-node": "^4.35.0",
318916
318953
  "@superblocksteam/bucketeer-sdk": "0.5.0",
318917
318954
  "@superblocksteam/shared": "0.9146.0",
318918
- "@superblocksteam/util": "2.0.0-next.78",
318919
- "@superblocksteam/vite-plugin-file-sync": "2.0.0-next.78",
318955
+ "@superblocksteam/util": "2.0.0-next.79",
318956
+ "@superblocksteam/vite-plugin-file-sync": "2.0.0-next.79",
318920
318957
  "@vitejs/plugin-react": "^4.3.4",
318921
318958
  axios: "^1.4.0",
318922
318959
  chokidar: "^4.0.3",
@@ -325859,7 +325896,7 @@ async function startVite({ app, httpServer: httpServer2, root: root2, mode, port
325859
325896
  };
325860
325897
  const isCustomBuildEnabled2 = await isCustomComponentsEnabled();
325861
325898
  const customFolder = path34.join(root2, "custom");
325862
- const cdnUrl = "https://assets-cdn.superblocks.com/library/2.0.0-next.78";
325899
+ const cdnUrl = "https://assets-cdn.superblocks.com/library/2.0.0-next.79";
325863
325900
  const env3 = loadEnv(mode, root2, "");
325864
325901
  const hmrPort = await getFreePort();
325865
325902
  const hmrOptions = {
@@ -571,5 +571,5 @@
571
571
  "strict": true
572
572
  }
573
573
  },
574
- "version": "2.0.0-next.78"
574
+ "version": "2.0.0-next.79"
575
575
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superblocksteam/cli",
3
- "version": "2.0.0-next.78",
3
+ "version": "2.0.0-next.79",
4
4
  "type": "module",
5
5
  "description": "Official Superblocks CLI",
6
6
  "homepage": "https://www.superblocks.com",
@@ -42,9 +42,9 @@
42
42
  "devDependencies": {
43
43
  "@eslint/js": "^9.16.0",
44
44
  "@oclif/test": "^4.1.11",
45
- "@superblocksteam/sdk": "2.0.0-next.78",
45
+ "@superblocksteam/sdk": "2.0.0-next.79",
46
46
  "@superblocksteam/shared": "0.9146.0",
47
- "@superblocksteam/util": "2.0.0-next.78",
47
+ "@superblocksteam/util": "2.0.0-next.79",
48
48
  "@types/babel__core": "^7.20.0",
49
49
  "@types/chai": "^4",
50
50
  "@types/fs-extra": "^11.0.1",