diff --git a/.vscode/launch.json b/.vscode/launch.json index 8f9df64..f961904 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -11,7 +11,7 @@ "command": "npm run dev" }, {"name": "Launch Chrome against localhost", - "type": "pwa-chrome", + "type": "chrome", "request": "launch", "url": "http://localhost:3000", "webRoot": "${workspaceFolder}" diff --git a/dynamic-route-healthcheck.sh b/bash-setup-scripts/dynamic-route-healthcheck.sh similarity index 100% rename from dynamic-route-healthcheck.sh rename to bash-setup-scripts/dynamic-route-healthcheck.sh diff --git a/fix-api-dynamic-routes.sh b/bash-setup-scripts/fix-api-dynamic-routes.sh similarity index 100% rename from fix-api-dynamic-routes.sh rename to bash-setup-scripts/fix-api-dynamic-routes.sh diff --git a/patch-dynamic-routes.sh b/bash-setup-scripts/patch-dynamic-routes.sh similarity index 100% rename from patch-dynamic-routes.sh rename to bash-setup-scripts/patch-dynamic-routes.sh diff --git a/patch-scss-imports.sh b/bash-setup-scripts/patch-scss-imports.sh similarity index 100% rename from patch-scss-imports.sh rename to bash-setup-scripts/patch-scss-imports.sh diff --git a/patch-tailwind-reference.sh b/bash-setup-scripts/patch-tailwind-reference.sh similarity index 100% rename from patch-tailwind-reference.sh rename to bash-setup-scripts/patch-tailwind-reference.sh diff --git a/setup-api-layer.sh b/bash-setup-scripts/setup-api-layer.sh similarity index 100% rename from setup-api-layer.sh rename to bash-setup-scripts/setup-api-layer.sh diff --git a/bash-setup-scripts/setup-compatibility-option.sh b/bash-setup-scripts/setup-compatibility-option.sh new file mode 100755 index 0000000..c36fab5 --- /dev/null +++ b/bash-setup-scripts/setup-compatibility-option.sh @@ -0,0 +1,259 @@ +#!/bin/zsh + +echo "🛠 Setting up Compatibility Explorer (Option A)..." + +COMPAT_DIR="src/app/compatibility" +mkdir -p "$COMPAT_DIR" + +cat > "$COMPAT_DIR/page.js" << 'EOF' +"use client"; + +import { useEffect, useState } from "react"; +import Link from "next/link"; +import { useRouter } from "next/navigation"; +import { CATEGORIES } from "@/lib/data/categories"; + +function ModeCard({ title, emoji, description, children }) { + return ( +
{description}
++ Discover cross-compatibility between RC models and parts. Use one of the + tools below to explore fitment, upgrades, and shared components. +
+Loading models and parts…
+ )} + + {/* Mode Selector Grid */} + {!loading && ( +{models?.length ?? 0}
+{parts?.length ?? 0}
+{compat?.length ?? 0}
+List, edit, and link parts here.
++ No models found yet. Click “Add Model” to create your + first one. +
+ )} + +{models?.length ?? 0}
+{parts?.length ?? 0}
+{compat?.length ?? 0}
+Loading part...
; + } + + return ( +{errorMsg}
} + +{errorMsg}
} + ++ No parts found yet. Click “Add Part” to create your first + one. +
+ )} + + {parts && parts.length > 0 && ( +{description}
++ Discover cross-compatibility between RC models and parts. Use one of the + tools below to explore fitment, upgrades, and shared components. +
+Loading models and parts…
+ )} + + {/* Mode Selector Grid */} + {!loading && ( +