@getcoherent/cli 0.6.37 → 0.6.38
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/index.js +12 -7
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -8543,14 +8543,19 @@ async function fixCommand(opts = {}) {
|
|
|
8543
8543
|
console.log(chalk15.green(` \u2714 Replaced "My App" with "${configName}" in (app)/layout.tsx`));
|
|
8544
8544
|
}
|
|
8545
8545
|
}
|
|
8546
|
-
const
|
|
8547
|
-
if (existsSync16(
|
|
8548
|
-
|
|
8546
|
+
const sidebarComponentPath2 = resolve10(projectRoot, "components", "shared", "sidebar.tsx");
|
|
8547
|
+
if (existsSync16(sidebarComponentPath2)) {
|
|
8548
|
+
const sidebarCode = readFileSync12(sidebarComponentPath2, "utf-8");
|
|
8549
8549
|
if (sidebarCode.includes("SidebarTrigger")) {
|
|
8550
|
-
|
|
8551
|
-
|
|
8552
|
-
|
|
8553
|
-
|
|
8550
|
+
if (!dsm) {
|
|
8551
|
+
dsm = new DesignSystemManager9(project.configPath);
|
|
8552
|
+
await dsm.load();
|
|
8553
|
+
}
|
|
8554
|
+
const { PageGenerator } = await import("@getcoherent/core");
|
|
8555
|
+
const gen = new PageGenerator(dsm.getConfig());
|
|
8556
|
+
writeFileSync10(sidebarComponentPath2, gen.generateSharedSidebarCode(), "utf-8");
|
|
8557
|
+
fixes.push("Regenerated sidebar component (removed duplicate SidebarTrigger)");
|
|
8558
|
+
console.log(chalk15.green(" \u2714 Regenerated sidebar component (removed duplicate SidebarTrigger)"));
|
|
8554
8559
|
}
|
|
8555
8560
|
}
|
|
8556
8561
|
const rootPagePath = resolve10(projectRoot, "app", "page.tsx");
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.6.
|
|
6
|
+
"version": "0.6.38",
|
|
7
7
|
"description": "CLI interface for Coherent Design Method",
|
|
8
8
|
"type": "module",
|
|
9
9
|
"main": "./dist/index.js",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"ora": "^7.0.1",
|
|
44
44
|
"prompts": "^2.4.2",
|
|
45
45
|
"zod": "^3.22.4",
|
|
46
|
-
"@getcoherent/core": "0.6.
|
|
46
|
+
"@getcoherent/core": "0.6.38"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@types/node": "^20.11.0",
|