From b6a123fe726a339f87cbdc90c7521337c0fb848d Mon Sep 17 00:00:00 2001 From: Utkarsh patrikar <137105846+utkarsh232005@users.noreply.github.com> Date: Tue, 26 May 2026 12:58:28 +0530 Subject: [PATCH] Revert "Ui responsive for mobile" --- package.json | 3 +- scripts/patch-lovable-config.cjs | 37 -------------------- src/components/Commands.tsx | 4 +-- src/components/Hero.tsx | 8 ++--- src/components/Navbar.tsx | 60 ++------------------------------ src/components/Terminal.tsx | 2 +- vite.config.ts | 2 +- 7 files changed, 11 insertions(+), 105 deletions(-) delete mode 100644 scripts/patch-lovable-config.cjs diff --git a/package.json b/package.json index 8bf24d4..9b51765 100644 --- a/package.json +++ b/package.json @@ -9,8 +9,7 @@ "build:dev": "vite build --mode development", "preview": "vite preview", "lint": "eslint .", - "format": "prettier --write .", - "postinstall": "node scripts/patch-lovable-config.cjs" + "format": "prettier --write ." }, "dependencies": { "@cloudflare/vite-plugin": "^1.25.5", diff --git a/scripts/patch-lovable-config.cjs b/scripts/patch-lovable-config.cjs deleted file mode 100644 index 47a6d89..0000000 --- a/scripts/patch-lovable-config.cjs +++ /dev/null @@ -1,37 +0,0 @@ -// Patches @lovable.dev/vite-tanstack-config to prefer the ESM entrypoint -// (dist/index.js) over the CJS one (dist/index.cjs) for import contexts. -// Required for Node.js >=22.12 compat — the CJS file does require("vite"), -// which is ESM-only, causing ERR_REQUIRE_CYCLE_MODULE. -const fs = require("fs"); -const path = require("path"); - -const pkgPath = path.resolve( - __dirname, - "..", - "node_modules", - "@lovable.dev", - "vite-tanstack-config", - "package.json" -); - -if (!fs.existsSync(pkgPath)) { - console.warn("[patch-lovable-config] package not found — skipping"); - process.exit(0); -} - -const pkg = JSON.parse(fs.readFileSync(pkgPath, "utf8")); - -if (pkg.exports) { - console.log("[patch-lovable-config] exports already present — nothing to do"); - process.exit(0); -} - -pkg.exports = { - ".": { - import: "./dist/index.js", - require: "./dist/index.cjs", - }, -}; - -fs.writeFileSync(pkgPath, JSON.stringify(pkg, null, 2) + "\n"); -console.log("[patch-lovable-config] added exports field to prefer ESM entrypoint"); diff --git a/src/components/Commands.tsx b/src/components/Commands.tsx index 083fea2..93266cd 100644 --- a/src/components/Commands.tsx +++ b/src/components/Commands.tsx @@ -63,12 +63,12 @@ export const Commands = () => {