@donotdev/cli 0.1.1 → 0.1.44
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/LICENSE.md +1 -1
- package/README.md +0 -0
- package/dependencies-matrix.json +93 -40
- package/dist/bin/commands/agent-setup.js +695 -420
- package/dist/bin/commands/build.js +1181 -832
- package/dist/bin/commands/bump.js +1065 -771
- package/dist/bin/commands/cacheout.js +253 -355
- package/dist/bin/commands/coach.js +275 -375
- package/dist/bin/commands/create-app.js +1085 -790
- package/dist/bin/commands/create-project.js +1117 -819
- package/dist/bin/commands/db.js +17045 -16542
- package/dist/bin/commands/deploy.js +1999 -1367
- package/dist/bin/commands/dev.js +879 -627
- package/dist/bin/commands/doctor.js +696 -425
- package/dist/bin/commands/emu.js +1001 -712
- package/dist/bin/commands/format.js +253 -355
- package/dist/bin/commands/get-demo.js +979 -706
- package/dist/bin/commands/make-admin.js +6279 -5746
- package/dist/bin/commands/preview.js +883 -628
- package/dist/bin/commands/seed.js +17058 -16555
- package/dist/bin/commands/setup-cicd.js +1024 -749
- package/dist/bin/commands/setup.js +1162 -844
- package/dist/bin/commands/staging.js +2000 -1368
- package/dist/bin/commands/sync-secrets.js +1181 -667
- package/dist/bin/commands/type-check.js +735 -461
- package/dist/bin/commands/wai.js +258 -360
- package/dist/bin/dndev.js +31 -16
- package/dist/bin/donotdev.js +31 -16
- package/dist/index.js +2200 -1513
- package/guidelines/DEPENDENCIES.md +155 -0
- package/guidelines/VERSION_CONTROL.md +0 -0
- package/package.json +1 -1
- package/templates/app-demo/.env.example +1 -1
- package/templates/app-demo/entities/Contact.ts.example +0 -0
- package/templates/app-demo/entities/ExampleEntity.ts.example +0 -0
- package/templates/app-demo/entities/demo.ts.example +0 -0
- package/templates/app-demo/index.html.example +0 -0
- package/templates/app-demo/public/apple-touch-icon.png.example +0 -0
- package/templates/app-demo/public/fonts/fonts.css.example +0 -0
- package/templates/app-demo/public/icon-192x192.png.example +0 -0
- package/templates/app-demo/public/icon-512x512.png.example +0 -0
- package/templates/app-demo/src/App.tsx.example +0 -0
- package/templates/app-demo/src/config/app.ts.example +0 -0
- package/templates/app-demo/src/entities/booking.ts.example +0 -0
- package/templates/app-demo/src/entities/onboarding.ts.example +0 -0
- package/templates/app-demo/src/entities/product.ts.example +0 -0
- package/templates/app-demo/src/entities/quote.ts.example +0 -0
- package/templates/app-demo/src/globals.css.example +0 -0
- package/templates/app-demo/src/main.tsx.example +0 -0
- package/templates/app-demo/src/pages/ChangelogPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/ConditionalFormPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/DashboardPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/HomePage.tsx.example +0 -0
- package/templates/app-demo/src/pages/OnboardingPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/PricingPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/ProductsPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/ProfilePage.tsx.example +0 -0
- package/templates/app-demo/src/pages/SettingsPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/ShowcaseDetailPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/ShowcasePage.tsx.example +0 -0
- package/templates/app-demo/src/pages/components/ComponentRenderer.tsx.example +0 -0
- package/templates/app-demo/src/pages/components/ComponentsData.tsx.example +0 -0
- package/templates/app-demo/src/pages/components/componentConfig.ts.example +0 -0
- package/templates/app-demo/src/pages/legal/LegalPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/legal/PrivacyPage.tsx.example +0 -0
- package/templates/app-demo/src/pages/legal/TermsPage.tsx.example +0 -0
- package/templates/app-demo/src/themes.css.example +6 -0
- package/templates/app-demo/tsconfig.json.example +0 -0
- package/templates/app-demo/vite.config.ts.example +0 -0
- package/templates/app-dndev/index.html.example +0 -0
- package/templates/app-dndev/src/App.tsx.example +0 -0
- package/templates/app-dndev/src/components/CockpitLayout.css.example +0 -0
- package/templates/app-dndev/src/components/CockpitLayout.tsx.example +0 -0
- package/templates/app-dndev/src/components/Kanban.css.example +0 -0
- package/templates/app-dndev/src/components/ModeToggle.tsx.example +0 -0
- package/templates/app-dndev/src/components/OverlaySlot.tsx.example +0 -0
- package/templates/app-dndev/src/components/TerminalPanel.css.example +0 -0
- package/templates/app-dndev/src/components/TerminalPanel.tsx.example +0 -0
- package/templates/app-dndev/src/components/markdown-prose.css.example +0 -0
- package/templates/app-dndev/src/components/phases/CaptainLog.tsx.example +0 -0
- package/templates/app-dndev/src/components/phases/ContextTabs.tsx.example +0 -0
- package/templates/app-dndev/src/components/phases/PhaseCard.tsx.example +0 -0
- package/templates/app-dndev/src/components/phases/PhaseDetail.tsx.example +0 -0
- package/templates/app-dndev/src/components/phases/ReviewPanel.tsx.example +0 -0
- package/templates/app-dndev/src/components/phases/phaseData.ts.example +0 -0
- package/templates/app-dndev/src/config/app.ts.example +1 -1
- package/templates/app-dndev/src/config/commands.ts.example +0 -0
- package/templates/app-dndev/src/config/legal.ts.example +0 -0
- package/templates/app-dndev/src/config/providers.ts.example +1 -1
- package/templates/app-dndev/src/globals.css.example +0 -0
- package/templates/app-dndev/src/hooks/useDndevFile.ts.example +0 -0
- package/templates/app-dndev/src/main.tsx.example +0 -0
- package/templates/app-dndev/src/pages/BoardPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/GrillPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/HomePage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/NotFoundPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/PhasesPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/SettingsPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/legal/LegalNoticePage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/legal/PrivacyPage.tsx.example +0 -0
- package/templates/app-dndev/src/pages/legal/TermsPage.tsx.example +0 -0
- package/templates/app-dndev/src/stores/dndevStore.ts.example +0 -0
- package/templates/app-dndev/src/themes.css.example +5 -0
- package/templates/app-dndev/terminal-sidecar.cjs.example +0 -0
- package/templates/app-dndev/vite.config.ts.example +0 -0
- package/templates/app-expo/.env.example +0 -32
- package/templates/app-expo/.expo/README.md.example +0 -0
- package/templates/app-expo/.gitignore.example +0 -0
- package/templates/app-expo/README.md.example +1 -1
- package/templates/app-expo/app/.gitkeep +0 -0
- package/templates/app-expo/app/_layout.tsx.example +0 -0
- package/templates/app-expo/app/form.tsx.example +0 -0
- package/templates/app-expo/app/index.tsx.example +0 -0
- package/templates/app-expo/app/list.tsx.example +0 -0
- package/templates/app-expo/app/profile.tsx.example +0 -0
- package/templates/app-expo/app/signin.tsx.example +0 -0
- package/templates/app-expo/app.json.example +0 -0
- package/templates/app-expo/assets/adaptive-icon.png +0 -0
- package/templates/app-expo/assets/favicon.png +0 -0
- package/templates/app-expo/assets/icon.png +0 -0
- package/templates/app-expo/assets/splash.png +0 -0
- package/templates/app-expo/babel.config.js.example +0 -0
- package/templates/app-expo/eas.json.example +0 -0
- package/templates/app-expo/expo-env.d.ts.example +0 -0
- package/templates/app-expo/metro.config.js.example +0 -0
- package/templates/app-expo/service-account-key.json.example +1 -1
- package/templates/app-expo/src/config/app.ts.example +0 -0
- package/templates/app-expo/src/config/providers.ts.example +1 -1
- package/templates/app-expo/tsconfig.json.example +0 -0
- package/templates/app-next/.env.example +0 -33
- package/templates/app-next/next.config.ts.example +0 -2
- package/templates/app-next/postcss.config.js.example +0 -0
- package/templates/app-next/service-account-key.json.example +0 -0
- package/templates/app-next/src/app/ClientLayout.tsx.example +0 -0
- package/templates/app-next/src/app/not-found.tsx.example +14 -1
- package/templates/app-next/src/config/app.ts.example +1 -1
- package/templates/app-next/src/config/legal.ts.example +0 -0
- package/templates/app-next/src/config/providers.ts.example +1 -1
- package/templates/app-next/src/globals.css.example +0 -0
- package/templates/app-next/src/locales/dndev_en.json.example +0 -0
- package/templates/app-next/src/locales/home_en.json.example +6 -6
- package/templates/app-next/src/pages/HomePage.tsx.example +0 -0
- package/templates/app-next/src/pages/legal/LegalNoticePage.tsx.example +0 -0
- package/templates/app-next/src/pages/legal/PrivacyPage.tsx.example +0 -0
- package/templates/app-next/src/pages/legal/TermsPage.tsx.example +0 -0
- package/templates/app-next/src/pages/locales/example_en.json.example +0 -0
- package/templates/app-next/src/themes.css.example +7 -1
- package/templates/app-vite/.env.example +0 -33
- package/templates/app-vite/csp.example.json +0 -0
- package/templates/app-vite/index.html.example +0 -0
- package/templates/app-vite/service-account-key.json.example +0 -0
- package/templates/app-vite/src/App.tsx.example +0 -0
- package/templates/app-vite/src/config/app.ts.example +1 -1
- package/templates/app-vite/src/config/legal.ts.example +0 -0
- package/templates/app-vite/src/config/providers.ts.example +1 -1
- package/templates/app-vite/src/globals.css.example +0 -0
- package/templates/app-vite/src/locales/dndev_en.json.example +0 -0
- package/templates/app-vite/src/locales/home_en.json.example +6 -6
- package/templates/app-vite/src/main.tsx.example +0 -0
- package/templates/app-vite/src/pages/FormPageExample.tsx.example +0 -0
- package/templates/app-vite/src/pages/HomePage.tsx.example +1 -1
- package/templates/app-vite/src/pages/ListPageExample.tsx.example +0 -0
- package/templates/app-vite/src/pages/NotFoundPage.tsx.example +0 -0
- package/templates/app-vite/src/pages/legal/LegalNoticePage.tsx.example +0 -0
- package/templates/app-vite/src/pages/legal/PrivacyPage.tsx.example +0 -0
- package/templates/app-vite/src/pages/legal/TermsPage.tsx.example +0 -0
- package/templates/app-vite/src/pages/locales/example_en.json.example +0 -0
- package/templates/app-vite/src/themes.css.example +5 -0
- package/templates/deploy-config/.firebaserc.example +0 -0
- package/templates/deploy-config/firestore.indexes.json.example +0 -0
- package/templates/deploy-config/firestore.rules.example +0 -0
- package/templates/deploy-config/storage.rules.example +0 -0
- package/templates/deploy-config/tsconfig.functions.json.example +0 -0
- package/templates/deploy-config/vercel.json.example +2 -2
- package/templates/functions-firebase/.env.example +2 -2
- package/templates/functions-firebase/README.md.example +3 -3
- package/templates/functions-firebase/build.mjs.example +0 -0
- package/templates/functions-firebase/functions.config.js.example +0 -0
- package/templates/functions-firebase/functions.yaml.example +0 -0
- package/templates/functions-firebase/src/auth/getCustomClaims.ts.example +0 -0
- package/templates/functions-firebase/src/auth/getUserAuthStatus.ts.example +0 -0
- package/templates/functions-firebase/src/auth/index.ts.example +0 -0
- package/templates/functions-firebase/src/auth/removeCustomClaims.ts.example +0 -0
- package/templates/functions-firebase/src/auth/setCustomClaims.ts.example +0 -0
- package/templates/functions-firebase/src/billing/handleStripeWebhook.ts.example +0 -0
- package/templates/functions-firebase/src/billing/index.ts.example +0 -0
- package/templates/functions-firebase/src/billing/processPaymentSuccess.ts.example +0 -0
- package/templates/functions-firebase/src/billing/refreshSubscriptionStatus.ts.example +0 -0
- package/templates/functions-firebase/src/crud/createEntity.ts.example +0 -0
- package/templates/functions-firebase/src/crud/deleteEntity.ts.example +0 -0
- package/templates/functions-firebase/src/crud/getEntity.ts.example +0 -0
- package/templates/functions-firebase/src/crud/index.ts.example +0 -0
- package/templates/functions-firebase/src/crud/listEntities.ts.example +0 -0
- package/templates/functions-firebase/src/crud/updateEntity.ts.example +0 -0
- package/templates/functions-firebase/src/index.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/checkGitHubAccess.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/disconnect.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/exchangeToken.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/getConnections.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/grantGitHubAccess.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/index.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/refreshToken.ts.example +0 -0
- package/templates/functions-firebase/src/oauth/revokeGitHubAccess.ts.example +0 -0
- package/templates/functions-firebase/tsconfig.json.example +0 -0
- package/templates/functions-supabase/supabase/config.toml.example +0 -0
- package/templates/functions-supabase/supabase/functions/.env.example +0 -0
- package/templates/functions-supabase/supabase/functions/cancel-subscription/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/change-plan/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/create-checkout-session/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/create-customer-portal/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/crud/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/delete-account/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/deno.json.example +0 -0
- package/templates/functions-supabase/supabase/functions/disconnect-oauth/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/exchange-token/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/get-connections/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/get-custom-claims/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/get-user-auth-status/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/refresh-subscription-status/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/refresh-token/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/remove-custom-claims/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/functions/set-custom-claims/index.ts.example +0 -0
- package/templates/functions-supabase/supabase/migrations/20250101000000_idempotency.sql +0 -0
- package/templates/functions-supabase/supabase/migrations/20250101000001_rate_limits.sql +0 -0
- package/templates/functions-supabase/supabase/migrations/20250101000002_cleanup_jobs.sql +0 -0
- package/templates/functions-supabase/supabase/migrations/20250101000003_operation_metrics.sql +0 -0
- package/templates/functions-supabase/supabase/migrations/20250101000004_crud_bulk.sql +192 -0
- package/templates/functions-vercel/.env.example +3 -3
- package/templates/functions-vercel/README.md.example +2 -2
- package/templates/functions-vercel/build.mjs.example +0 -0
- package/templates/functions-vercel/src/api/auth/getCustomClaims.ts.example +0 -0
- package/templates/functions-vercel/src/api/auth/getUserAuthStatus.ts.example +0 -0
- package/templates/functions-vercel/src/api/auth/removeCustomClaims.ts.example +0 -0
- package/templates/functions-vercel/src/api/auth/setCustomClaims.ts.example +0 -0
- package/templates/functions-vercel/src/api/billing/handleStripeWebhook.ts.example +0 -0
- package/templates/functions-vercel/src/api/billing/processPaymentSuccess.ts.example +0 -0
- package/templates/functions-vercel/src/api/billing/refreshSubscriptionStatus.ts.example +0 -0
- package/templates/functions-vercel/src/api/crud/createEntity.ts.example +0 -0
- package/templates/functions-vercel/src/api/crud/deleteEntity.ts.example +0 -0
- package/templates/functions-vercel/src/api/crud/getEntity.ts.example +0 -0
- package/templates/functions-vercel/src/api/crud/listEntities.ts.example +0 -0
- package/templates/functions-vercel/src/api/crud/updateEntity.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/checkGitHubAccess.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/disconnect.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/exchangeToken.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/getConnections.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/grantGitHubAccess.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/refreshToken.ts.example +0 -0
- package/templates/functions-vercel/src/api/oauth/revokeGitHubAccess.ts.example +0 -0
- package/templates/functions-vercel/tsconfig.json.example +0 -0
- package/templates/functions-vercel/vercel.json.example +0 -0
- package/templates/github-consumer/.github/workflows/ci.yml.example +0 -0
- package/templates/overlay-firebase/env.fragment.example +0 -0
- package/templates/overlay-firebase/env.fragment.expo.example +0 -0
- package/templates/overlay-firebase/env.fragment.nextjs.example +0 -0
- package/templates/overlay-firebase/src/config/providers.expo.ts.example +0 -0
- package/templates/overlay-firebase/src/config/providers.ts.example +0 -0
- package/templates/overlay-supabase/env.fragment.example +0 -0
- package/templates/overlay-supabase/env.fragment.expo.example +0 -0
- package/templates/overlay-supabase/env.fragment.nextjs.example +0 -0
- package/templates/overlay-supabase/src/config/providers.expo.ts.example +1 -1
- package/templates/overlay-supabase/src/config/providers.ts.example +1 -1
- package/templates/overlay-vercel/env.fragment.example +0 -0
- package/templates/overlay-vercel/env.fragment.nextjs.example +0 -0
- package/templates/overlay-vercel/src/config/providers.ts.example +0 -0
- package/templates/preset-admin/src/pages/DashboardPage.tsx.example +0 -0
- package/templates/preset-admin/src/pages/EntityPage.tsx.example +0 -0
- package/templates/preset-admin/src/pages/ReportsPage.tsx.example +0 -0
- package/templates/preset-admin/src/pages/SettingsPage.tsx.example +0 -0
- package/templates/preset-admin/src/pages/UsersPage.tsx.example +0 -0
- package/templates/preset-ecommerce/src/pages/CartPage.tsx.example +0 -0
- package/templates/preset-ecommerce/src/pages/CatalogPage.tsx.example +0 -0
- package/templates/preset-ecommerce/src/pages/CheckoutPage.tsx.example +0 -0
- package/templates/preset-ecommerce/src/pages/HomePage.tsx.example +0 -0
- package/templates/preset-ecommerce/src/pages/ProductPage.tsx.example +0 -0
- package/templates/preset-landing/src/pages/AboutPage.tsx.example +0 -0
- package/templates/preset-landing/src/pages/ContactPage.tsx.example +0 -0
- package/templates/preset-landing/src/pages/HomePage.tsx.example +0 -0
- package/templates/preset-saas/src/pages/DashboardPage.tsx.example +0 -0
- package/templates/preset-saas/src/pages/HomePage.tsx.example +0 -0
- package/templates/preset-saas/src/pages/PricingPage.tsx.example +0 -0
- package/templates/preset-saas/src/pages/ProfilePage.tsx.example +0 -0
- package/templates/preset-saas/src/pages/SettingsPage.tsx.example +0 -0
- package/templates/root-consumer/.claude/agents/architect.md.example +0 -0
- package/templates/root-consumer/.claude/agents/builder.md.example +0 -0
- package/templates/root-consumer/.claude/agents/coder.md.example +0 -0
- package/templates/root-consumer/.claude/agents/extractor.md.example +0 -0
- package/templates/root-consumer/.claude/agents/polisher.md.example +0 -0
- package/templates/root-consumer/.claude/agents/prompt-engineer.md.example +0 -0
- package/templates/root-consumer/.claude/hooks/guard-bash.sh.example +0 -0
- package/templates/root-consumer/.claude/hooks/guard-write.sh.example +2 -35
- package/templates/root-consumer/.claude/hooks/session-start.sh.example +1 -1
- package/templates/root-consumer/.claude/hooks/typecheck-stop.sh.example +0 -0
- package/templates/root-consumer/.claude/rules/consumer-ux.md.example +1 -1
- package/templates/root-consumer/.claude/rules/definition-of-done.md.example +0 -0
- package/templates/root-consumer/.claude/rules/framework.md.example +0 -0
- package/templates/root-consumer/.claude/rules/git.md.example +0 -0
- package/templates/root-consumer/.claude/rules/security.md.example +0 -0
- package/templates/root-consumer/.claude/settings.json.example +1 -27
- package/templates/root-consumer/.claude/skills/brainstorm/SKILL.md.example +0 -0
- package/templates/root-consumer/.claude/skills/build/SKILL.md.example +23 -106
- package/templates/root-consumer/.claude/skills/design/SKILL.md.example +0 -0
- package/templates/root-consumer/.claude/skills/design/output-template.md +0 -0
- package/templates/root-consumer/.claude/skills/grill/SKILL.md.example +0 -0
- package/templates/root-consumer/.claude/skills/polish/SKILL.md.example +0 -0
- package/templates/root-consumer/.claude/skills/techdebt/SKILL.md.example +0 -0
- package/templates/root-consumer/.cursor/mcp.json.example +0 -0
- package/templates/root-consumer/.cursor/rules/no-docs.mdc.example +5 -1
- package/templates/root-consumer/.dndev/args.json.example +0 -0
- package/templates/root-consumer/.dndev.secrets.example +0 -0
- package/templates/root-consumer/.env.example +0 -1
- package/templates/root-consumer/.gemini/settings.json.example +0 -0
- package/templates/root-consumer/.gitignore.example +1 -0
- package/templates/root-consumer/.mcp.json.example +0 -0
- package/templates/root-consumer/.prettierrc.cjs.example +0 -0
- package/templates/root-consumer/AGENTS.md.example +63 -0
- package/templates/root-consumer/CLAUDE.md.example +1 -33
- package/templates/root-consumer/README.md.example +11 -33
- package/templates/root-consumer/entities/index.ts.example +0 -0
- package/templates/root-consumer/eslint.config.js.example +0 -0
- package/templates/root-consumer/tsconfig.json.example +0 -0
- package/templates/root-consumer/.claude/hooks/framework-compliance.sh.example +0 -56
- package/templates/root-consumer/.claude/hooks/guard-files.sh.example +0 -46
- package/templates/root-consumer/.claude/hooks/guard-mcp.sh.example +0 -91
- package/templates/root-consumer/.claude/hooks/guard-secrets.sh.example +0 -67
- package/templates/root-consumer/.claude/hooks/track-mcp-lookup.sh.example +0 -20
- package/templates/root-consumer/.claude/statusline.py.example +0 -79
- package/templates/root-consumer/.clinerules.example +0 -1
- package/templates/root-consumer/.cursorrules.example +0 -1
- package/templates/root-consumer/.github/copilot-instructions.md.example +0 -1
- package/templates/root-consumer/.windsurfrules.example +0 -1
- package/templates/root-consumer/AI.md.example +0 -108
- package/templates/root-consumer/CONVENTIONS.md.example +0 -1
- package/templates/root-consumer/GEMINI.md.example +0 -1
- package/templates/root-consumer/guides/dndev/AGENT_START_HERE.md.example +0 -135
- package/templates/root-consumer/guides/dndev/COMPONENTS_ADV.md.example +0 -276
- package/templates/root-consumer/guides/dndev/INDEX.md.example +0 -56
- package/templates/root-consumer/guides/dndev/SETUP_AUTH.md.example +0 -134
- package/templates/root-consumer/guides/dndev/SETUP_BILLING.md.example +0 -114
- package/templates/root-consumer/guides/dndev/SETUP_FIREBASE.md.example +0 -231
- package/templates/root-consumer/guides/dndev/SETUP_OAUTH.md.example +0 -59
- package/templates/root-consumer/guides/dndev/SETUP_OAUTH_PROVIDERS.md.example +0 -60
- package/templates/root-consumer/guides/dndev/SETUP_SOC2.md.example +0 -234
- package/templates/root-consumer/guides/dndev/SETUP_STRIPE.md.example +0 -62
- package/templates/root-consumer/guides/dndev/SETUP_SUPABASE.md.example +0 -262
- package/templates/root-consumer/guides/dndev/advanced/APP_CHECK.md.example +0 -111
- package/templates/root-consumer/guides/dndev/advanced/COOKIE_REFERENCE.md.example +0 -252
- package/templates/root-consumer/guides/dndev/advanced/EMULATORS.md.example +0 -48
- package/templates/root-consumer/guides/wai-way/WAI_WAY_CLI.md.example +0 -402
- package/templates/root-consumer/guides/wai-way/agents/architect.md.example +0 -78
- package/templates/root-consumer/guides/wai-way/agents/builder.md.example +0 -97
- package/templates/root-consumer/guides/wai-way/agents/extractor.md.example +0 -363
- package/templates/root-consumer/guides/wai-way/agents/polisher.md.example +0 -133
- package/templates/root-consumer/guides/wai-way/blueprints/0_brainstorm.md.example +0 -315
- package/templates/root-consumer/guides/wai-way/blueprints/1_scaffold.md.example +0 -133
- package/templates/root-consumer/guides/wai-way/blueprints/2_entities.md.example +0 -111
- package/templates/root-consumer/guides/wai-way/blueprints/3_compose.md.example +0 -148
- package/templates/root-consumer/guides/wai-way/blueprints/4_configure.md.example +0 -238
- package/templates/root-consumer/guides/wai-way/context_map.json.example +0 -127
- package/templates/root-consumer/guides/wai-way/entity_patterns.md.example +0 -839
- package/templates/root-consumer/guides/wai-way/hld_template.md.example +0 -138
- package/templates/root-consumer/guides/wai-way/lld_template.md.example +0 -103
- package/templates/root-consumer/guides/wai-way/page_patterns.md.example +0 -722
- package/templates/root-consumer/guides/wai-way/prd_template.md.example +0 -140
- package/templates/root-consumer/guides/wai-way/presets_guide.md.example +0 -217
- package/templates/root-consumer/guides/wai-way/spec_template.md.example +0 -313
|
@@ -1,315 +0,0 @@
|
|
|
1
|
-
# BLUEPRINT: 0_BRAINSTORM → PRD + HLD + LLD
|
|
2
|
-
|
|
3
|
-
**Goal:** Deeply understand the app and produce THREE validated specification documents.
|
|
4
|
-
|
|
5
|
-
**MCP:** `start_phase(0)` to begin. `complete_phase()` when done.
|
|
6
|
-
**Done when:** `docs/PRD.md`, `docs/HLD.md`, `docs/LLD.md` are COMPLETE and user has validated them.
|
|
7
|
-
|
|
8
|
-
---
|
|
9
|
-
|
|
10
|
-
## First: Call list_features()
|
|
11
|
-
|
|
12
|
-
**Before probing the user or designing anything**, call `list_features()`.
|
|
13
|
-
|
|
14
|
-
It returns a one-line summary from each framework package README (core, ui, templates, auth, billing, etc.). Use it to avoid designing custom solutions when the framework already provides them (e.g. blog, CRUD, billing pages). If you skip this, you may propose work that already exists in `@donotdev/templates` or other packages.
|
|
15
|
-
|
|
16
|
-
---
|
|
17
|
-
|
|
18
|
-
## CRITICAL: Do NOT Rush This Phase
|
|
19
|
-
|
|
20
|
-
**The #1 cause of wasted work is incomplete requirements.**
|
|
21
|
-
|
|
22
|
-
Before producing documents, you MUST have:
|
|
23
|
-
- [ ] Complete understanding of what users DO (not just what data exists)
|
|
24
|
-
- [ ] All user journeys mapped step-by-step
|
|
25
|
-
- [ ] Business rules and validations documented
|
|
26
|
-
- [ ] Entity relationships and state machines defined
|
|
27
|
-
- [ ] Edge cases and error scenarios considered
|
|
28
|
-
|
|
29
|
-
**If ANY of these are unclear, keep asking questions.**
|
|
30
|
-
|
|
31
|
-
---
|
|
32
|
-
|
|
33
|
-
## The Conversation Flow
|
|
34
|
-
|
|
35
|
-
```
|
|
36
|
-
User provides idea
|
|
37
|
-
↓
|
|
38
|
-
Agent calls list_features() → matches needs to existing framework capabilities
|
|
39
|
-
↓
|
|
40
|
-
Agent asks IDENTITY questions (who, what, why, and **Aesthetic Essence**)
|
|
41
|
-
↓
|
|
42
|
-
Agent asks USER JOURNEY questions (what do users DO step by step?)
|
|
43
|
-
↓
|
|
44
|
-
Agent asks DATA questions (what entities, relationships, states?)
|
|
45
|
-
↓
|
|
46
|
-
Agent asks BUSINESS RULES questions (validations, permissions, constraints)
|
|
47
|
-
↓
|
|
48
|
-
Agent asks EDGE CASE questions (what if X fails? what about Y?)
|
|
49
|
-
↓
|
|
50
|
-
Agent fills spec_template.md FORMAT through conversation
|
|
51
|
-
↓
|
|
52
|
-
Agent presents summary for user validation
|
|
53
|
-
↓
|
|
54
|
-
User confirms → Agent SPLITS into PRD.md + HLD.md + LLD.md
|
|
55
|
-
↓
|
|
56
|
-
Agent calls init_implementation({ from_spec: true }) → creates implementation.md
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
---
|
|
60
|
-
|
|
61
|
-
## Question Categories (In Order)
|
|
62
|
-
|
|
63
|
-
### 1. IDENTITY (The "What")
|
|
64
|
-
|
|
65
|
-
Start broad, then narrow down:
|
|
66
|
-
|
|
67
|
-
- "Describe your app in one paragraph. What problem does it solve?"
|
|
68
|
-
- "Who is the primary user? Secondary users?"
|
|
69
|
-
- "What's the one thing a user MUST be able to do?"
|
|
70
|
-
- "What makes this different from [similar apps]?"
|
|
71
|
-
- **Aesthetic Essence:** "Which visual 'vibe' fits the brand? SaaS (Clean/Modern), Luxury (Gold/Serif), or Brutalist (Orange/High-Contrast)?"
|
|
72
|
-
|
|
73
|
-
**Don't proceed until you can explain the app to someone else.**
|
|
74
|
-
|
|
75
|
-
---
|
|
76
|
-
|
|
77
|
-
### 2. USER JOURNEYS (The "How")
|
|
78
|
-
|
|
79
|
-
**This is the most important section.** Map what users actually DO.
|
|
80
|
-
|
|
81
|
-
For EACH user type, ask:
|
|
82
|
-
- "Walk me through a new user's first session. Step by step."
|
|
83
|
-
- "What's the most common task? Walk me through it."
|
|
84
|
-
- "What's the most complex task? Walk me through it."
|
|
85
|
-
- "What brings users back daily/weekly?"
|
|
86
|
-
|
|
87
|
-
**Document as numbered steps:**
|
|
88
|
-
```
|
|
89
|
-
## User Journey: Create a New Order
|
|
90
|
-
|
|
91
|
-
1. User clicks "New Order" button
|
|
92
|
-
2. User selects customer from dropdown (or creates new)
|
|
93
|
-
3. User adds products (search, quantity, notes)
|
|
94
|
-
4. User sees running total (auto-calculated)
|
|
95
|
-
5. User selects payment method
|
|
96
|
-
6. User clicks "Submit Order"
|
|
97
|
-
7. System validates stock availability
|
|
98
|
-
8. System creates order with status "pending"
|
|
99
|
-
9. User sees confirmation with order number
|
|
100
|
-
10. Customer receives email notification
|
|
101
|
-
```
|
|
102
|
-
|
|
103
|
-
**If you can't write this level of detail, you don't understand the app yet.**
|
|
104
|
-
|
|
105
|
-
---
|
|
106
|
-
|
|
107
|
-
### 3. DATA & ENTITIES (The "What Data")
|
|
108
|
-
|
|
109
|
-
For EACH entity, understand:
|
|
110
|
-
|
|
111
|
-
**Basic:**
|
|
112
|
-
- "What fields does [Entity] have?"
|
|
113
|
-
- "What's required vs optional?"
|
|
114
|
-
- "What are the valid values for [field]?"
|
|
115
|
-
|
|
116
|
-
**Relationships:**
|
|
117
|
-
- "How does [Entity A] relate to [Entity B]?"
|
|
118
|
-
- "Can [Entity] exist without [Related Entity]?"
|
|
119
|
-
- "When [Entity] is deleted, what happens to related data?"
|
|
120
|
-
|
|
121
|
-
**States:**
|
|
122
|
-
- "What statuses can [Entity] have?"
|
|
123
|
-
- "What triggers status changes?"
|
|
124
|
-
- "Can you go back from [status A] to [status B]?"
|
|
125
|
-
|
|
126
|
-
**Example state machine:**
|
|
127
|
-
```
|
|
128
|
-
Order States:
|
|
129
|
-
draft → pending → confirmed → shipped → delivered
|
|
130
|
-
→ cancelled (from pending or confirmed only)
|
|
131
|
-
→ refunded (from delivered only)
|
|
132
|
-
```
|
|
133
|
-
|
|
134
|
-
---
|
|
135
|
-
|
|
136
|
-
### 4. BUSINESS RULES (The "Constraints")
|
|
137
|
-
|
|
138
|
-
Ask about validations and constraints:
|
|
139
|
-
|
|
140
|
-
- "What makes a [Entity] valid/invalid?"
|
|
141
|
-
- "What are the limits? (max items, max size, date ranges)"
|
|
142
|
-
- "What can't happen? What should be prevented?"
|
|
143
|
-
- "What triggers notifications/emails?"
|
|
144
|
-
- "What calculations happen automatically?"
|
|
145
|
-
|
|
146
|
-
**Document as rules:**
|
|
147
|
-
```
|
|
148
|
-
## Business Rules: Orders
|
|
149
|
-
|
|
150
|
-
- Order total = sum(item.price x item.quantity) + shipping - discount
|
|
151
|
-
- Discount cannot exceed 50% of subtotal
|
|
152
|
-
- Order cannot be cancelled after shipping
|
|
153
|
-
- Stock is reserved when order is confirmed, released if cancelled
|
|
154
|
-
- Customer email is sent on: order confirmed, order shipped, order delivered
|
|
155
|
-
```
|
|
156
|
-
|
|
157
|
-
---
|
|
158
|
-
|
|
159
|
-
### 5. PERMISSIONS (The "Who Can")
|
|
160
|
-
|
|
161
|
-
For EACH entity AND action:
|
|
162
|
-
|
|
163
|
-
- "Who can CREATE [Entity]?"
|
|
164
|
-
- "Who can VIEW [Entity]? All of them or only their own?"
|
|
165
|
-
- "Who can EDIT [Entity]? When?"
|
|
166
|
-
- "Who can DELETE [Entity]? Is it soft or hard delete?"
|
|
167
|
-
|
|
168
|
-
**Document as matrix:**
|
|
169
|
-
```
|
|
170
|
-
| Entity | Create | Read | Update | Delete |
|
|
171
|
-
|---------|--------|-----------|-----------|-----------|
|
|
172
|
-
| Product | admin | everyone | admin | admin |
|
|
173
|
-
| Order | user | owner | owner* | admin |
|
|
174
|
-
| Review | user | everyone | owner | owner+admin|
|
|
175
|
-
|
|
176
|
-
* Order update only when status = draft
|
|
177
|
-
```
|
|
178
|
-
|
|
179
|
-
---
|
|
180
|
-
|
|
181
|
-
### 6. EDGE CASES (The "What If")
|
|
182
|
-
|
|
183
|
-
**Don't skip this.** Ask about failure scenarios:
|
|
184
|
-
|
|
185
|
-
- "What if [external service] is down?"
|
|
186
|
-
- "What if user submits invalid data?"
|
|
187
|
-
- "What if two users edit the same thing?"
|
|
188
|
-
- "What if user loses connection mid-action?"
|
|
189
|
-
- "What if [required field] is missing?"
|
|
190
|
-
- "What happens to old data when [schema changes]?"
|
|
191
|
-
|
|
192
|
-
---
|
|
193
|
-
|
|
194
|
-
### 7. UX INTENT (The "Where + Flow")
|
|
195
|
-
|
|
196
|
-
- "Where should the shortcut for the North Star action live? (Goal: < 2 clicks)"
|
|
197
|
-
- "Which features are 'Delighters' (Marketing/Heroes) vs 'Must-Haves' (CRUD)?"
|
|
198
|
-
|
|
199
|
-
---
|
|
200
|
-
|
|
201
|
-
## Producing the Documents
|
|
202
|
-
|
|
203
|
-
Only after ALL questions are answered, use `spec_template.md` as the FORMAT to organize gathered information, then SPLIT into three documents:
|
|
204
|
-
|
|
205
|
-
### What Goes Where
|
|
206
|
-
|
|
207
|
-
**`docs/PRD.md`** (from `prd_template.md`):
|
|
208
|
-
- Identity (name, users, value prop, North Star)
|
|
209
|
-
- User journeys (numbered steps, success/failure criteria)
|
|
210
|
-
- Business rules (validations, calculations, triggers)
|
|
211
|
-
- Permissions matrix (who can CRUD what)
|
|
212
|
-
- Edge cases and error handling
|
|
213
|
-
- Design decision overrides
|
|
214
|
-
|
|
215
|
-
**`docs/HLD.md`** (from `hld_template.md`):
|
|
216
|
-
- Preset selection and rationale
|
|
217
|
-
- Auth model (providers, roles, self-registration)
|
|
218
|
-
- Billing model (if applicable)
|
|
219
|
-
- Aesthetic essence
|
|
220
|
-
- Page map (routes, purpose, which journey they serve)
|
|
221
|
-
- Entity relationship diagram (text-based overview)
|
|
222
|
-
- Feature flags (i18n, PWA, real-time, uploads, etc.)
|
|
223
|
-
- Architecture decisions and trade-offs
|
|
224
|
-
|
|
225
|
-
**`docs/LLD.md`** (from `lld_template.md`):
|
|
226
|
-
- Per-entity detailed spec:
|
|
227
|
-
- Field definitions (name, type, required, validation, visibility)
|
|
228
|
-
- State machine (from/to/trigger/who/side-effects)
|
|
229
|
-
- Relationships (type, target, via field, cascade rule)
|
|
230
|
-
- Access matrix (CRUD per role per condition)
|
|
231
|
-
- Cross-entity validation rules
|
|
232
|
-
|
|
233
|
-
---
|
|
234
|
-
|
|
235
|
-
## Validation: The Completeness Test
|
|
236
|
-
|
|
237
|
-
Before producing the three documents, verify:
|
|
238
|
-
|
|
239
|
-
### Can You Answer These?
|
|
240
|
-
|
|
241
|
-
- [ ] "What does a new user do first?" → Have step-by-step answer
|
|
242
|
-
- [ ] "What's the main thing users do daily?" → Have step-by-step answer
|
|
243
|
-
- [ ] "What happens when [entity] status changes?" → Know all transitions
|
|
244
|
-
- [ ] "What validations exist on [entity]?" → Can list them
|
|
245
|
-
- [ ] "Who can [action] on [entity]?" → Know for every combination
|
|
246
|
-
- [ ] "What if [failure scenario]?" → Have answer for common failures
|
|
247
|
-
|
|
248
|
-
### Is Everything Complete?
|
|
249
|
-
|
|
250
|
-
- [ ] Every user journey has 5+ numbered steps
|
|
251
|
-
- [ ] Every entity has fields, states, and state transitions
|
|
252
|
-
- [ ] Every entity has CRUD permissions for every role
|
|
253
|
-
- [ ] Every business rule is documented explicitly
|
|
254
|
-
- [ ] Every page traces back to a user journey
|
|
255
|
-
- [ ] No "TBD", "TODO", or empty fields
|
|
256
|
-
- [ ] User has said "yes, that's complete"
|
|
257
|
-
|
|
258
|
-
---
|
|
259
|
-
|
|
260
|
-
## Presenting for Validation
|
|
261
|
-
|
|
262
|
-
When ready, present a summary:
|
|
263
|
-
|
|
264
|
-
```markdown
|
|
265
|
-
## Specification Summary
|
|
266
|
-
|
|
267
|
-
### Identity
|
|
268
|
-
**Name:** [App Name]
|
|
269
|
-
**Purpose:** [One sentence]
|
|
270
|
-
**Users:** [Primary], [Secondary]
|
|
271
|
-
|
|
272
|
-
### Core User Journey
|
|
273
|
-
1. [First step]
|
|
274
|
-
2. [Second step]
|
|
275
|
-
...
|
|
276
|
-
|
|
277
|
-
### Entities
|
|
278
|
-
| Entity | States | Key Rules |
|
|
279
|
-
|--------|--------|-----------|
|
|
280
|
-
| [Name] | [States] | [Main validation] |
|
|
281
|
-
|
|
282
|
-
### Pages (derived from journeys)
|
|
283
|
-
- `/` - [Purpose]
|
|
284
|
-
- `/[route]` - [Purpose]
|
|
285
|
-
|
|
286
|
-
### Key Business Rules
|
|
287
|
-
1. [Rule 1]
|
|
288
|
-
2. [Rule 2]
|
|
289
|
-
|
|
290
|
-
### Open Questions (if any)
|
|
291
|
-
- [Question needing user input]
|
|
292
|
-
|
|
293
|
-
---
|
|
294
|
-
Does this capture your requirements completely?
|
|
295
|
-
What's missing or incorrect?
|
|
296
|
-
```
|
|
297
|
-
|
|
298
|
-
---
|
|
299
|
-
|
|
300
|
-
## Output
|
|
301
|
-
|
|
302
|
-
User validates → produce three documents in `docs/`:
|
|
303
|
-
|
|
304
|
-
1. **`docs/PRD.md`** — requirements, journeys, rules, permissions
|
|
305
|
-
2. **`docs/HLD.md`** — architecture, preset, auth, pages, features
|
|
306
|
-
3. **`docs/LLD.md`** — detailed entity specs, state machines, access matrices
|
|
307
|
-
|
|
308
|
-
Then generate the implementation tracker:
|
|
309
|
-
```
|
|
310
|
-
init_implementation({ from_spec: true })
|
|
311
|
-
```
|
|
312
|
-
This creates `.dndev/implementation.md` with checklist items for all phases.
|
|
313
|
-
|
|
314
|
-
**Documents validated AND complete? Move to Phase 1: SCAFFOLD.**
|
|
315
|
-
**Anything unclear? Keep asking questions.**
|
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
# BLUEPRINT: 1_SCAFFOLD + SITEMAP
|
|
2
|
-
|
|
3
|
-
**Goal:** Running app with all routes defined.
|
|
4
|
-
|
|
5
|
-
**MCP:** `start_phase(1)` to begin. `complete_phase()` when done.
|
|
6
|
-
**Done when:** All routes listed, all *Page.tsx files created with correct PageMeta.
|
|
7
|
-
|
|
8
|
-
**Prerequisite:** Phase 0 complete — `docs/PRD.md`, `docs/HLD.md`, `docs/LLD.md` validated.
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
## Step 1: Create App
|
|
13
|
-
|
|
14
|
-
**`dndev` is an installed CLI — run directly, never via `bunx` or `npx`.**
|
|
15
|
-
|
|
16
|
-
```bash
|
|
17
|
-
# Interactive wizard — prompts for builder, backend, features (no --preset flag)
|
|
18
|
-
dndev create-app
|
|
19
|
-
|
|
20
|
-
# Start emulators (if Firebase backend was selected)
|
|
21
|
-
dndev emu start
|
|
22
|
-
|
|
23
|
-
# Start the dev server
|
|
24
|
-
dndev dev
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
---
|
|
28
|
-
|
|
29
|
-
## Step 2: Apply Aesthetic Essence
|
|
30
|
-
|
|
31
|
-
**READ:** `guides/dndev/essences_reference.css`
|
|
32
|
-
|
|
33
|
-
Apply the chosen essence (SaaS, Luxury, Brutalist) to your `src/themes.css`.
|
|
34
|
-
- If **SaaS**: Keep defaults.
|
|
35
|
-
- If **Luxury/Brutalist**: Copy the variables from the reference file into `src/themes.css`.
|
|
36
|
-
- If **Custom**: Adjust primary/secondary colors in `:root`.
|
|
37
|
-
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
## Reference: Demo App
|
|
41
|
-
|
|
42
|
-
**Before creating pages, study the demo app:** `packages/cli/templates/app-demo/src/pages/`
|
|
43
|
-
|
|
44
|
-
It shows the canonical pattern:
|
|
45
|
-
- Thin page wrappers (~5 lines) that import templates
|
|
46
|
-
- `PageMeta.preset` for per-route layout switching (landing → admin → docs)
|
|
47
|
-
- Component showcase with filterable grid
|
|
48
|
-
- Entity definition with `defineEntity()`
|
|
49
|
-
|
|
50
|
-
**Copy from the demo app, customize for your spec.**
|
|
51
|
-
|
|
52
|
-
---
|
|
53
|
-
|
|
54
|
-
## Step 3: Review Pages from HLD
|
|
55
|
-
|
|
56
|
-
From `docs/HLD.md` section 5 (Page Map), you have the list of pages. Now create them.
|
|
57
|
-
|
|
58
|
-
**READ:** `docs/HLD.md` for the page map and `docs/PRD.md` for the user journeys they serve.
|
|
59
|
-
**READ:** `guides/wai-way/page_patterns.md` for page structure patterns.
|
|
60
|
-
|
|
61
|
-
---
|
|
62
|
-
|
|
63
|
-
## Step 4: Create Page Files
|
|
64
|
-
|
|
65
|
-
For each page in HLD page map:
|
|
66
|
-
|
|
67
|
-
```bash
|
|
68
|
-
touch src/pages/AboutPage.tsx
|
|
69
|
-
touch src/pages/DashboardPage.tsx
|
|
70
|
-
touch src/pages/ProductsListPage.tsx
|
|
71
|
-
touch src/pages/ProductPage.tsx
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
---
|
|
75
|
-
|
|
76
|
-
## Step 4: Create Interactive Prototype Stubs
|
|
77
|
-
|
|
78
|
-
**READ:** `src/pages/HomePage.tsx` for PageMeta pattern.
|
|
79
|
-
|
|
80
|
-
For **each page**, create a functional stub that allows the user to validate the flow.
|
|
81
|
-
|
|
82
|
-
```tsx
|
|
83
|
-
import type { PageMeta } from '@donotdev/core';
|
|
84
|
-
import { PageContainer, Link } from '@donotdev/ui';
|
|
85
|
-
import { Section, Stack, Text, Card, Button } from '@donotdev/components';
|
|
86
|
-
import { Info } from 'lucide-react';
|
|
87
|
-
|
|
88
|
-
export const NAMESPACE = 'about';
|
|
89
|
-
|
|
90
|
-
export const meta: PageMeta = {
|
|
91
|
-
namespace: NAMESPACE,
|
|
92
|
-
icon: <Info />,
|
|
93
|
-
// From spec: Set auth: false for the prototype phase so user can click through
|
|
94
|
-
auth: false,
|
|
95
|
-
};
|
|
96
|
-
|
|
97
|
-
export default function AboutPage() {
|
|
98
|
-
return (
|
|
99
|
-
<PageContainer>
|
|
100
|
-
<Section title="About Page (Prototype Stub)">
|
|
101
|
-
<Stack gap="large">
|
|
102
|
-
<Text><strong>Role:</strong> [Describe the purpose of this page from the spec]</Text>
|
|
103
|
-
|
|
104
|
-
<Text level="h3">Navigate Flow:</Text>
|
|
105
|
-
<Stack direction="row" gap="medium">
|
|
106
|
-
<Link path="/dashboard">
|
|
107
|
-
<Button variant="outline">Go to Dashboard</Button>
|
|
108
|
-
</Link>
|
|
109
|
-
<Link path="/contact">
|
|
110
|
-
<Button variant="outline">Go to Contact</Button>
|
|
111
|
-
</Link>
|
|
112
|
-
</Stack>
|
|
113
|
-
|
|
114
|
-
{/* Placeholder for flow validation */}
|
|
115
|
-
<Card variant="outline" content={[`[Placeholder for ${NAMESPACE} core components]`]} />
|
|
116
|
-
</Stack>
|
|
117
|
-
</Section>
|
|
118
|
-
</PageContainer>
|
|
119
|
-
);
|
|
120
|
-
}
|
|
121
|
-
```
|
|
122
|
-
|
|
123
|
-
**Goal:** The user should be able to `bun dev` and click through the entire app flow (the "North Star" path) to validate the architecture before you build any logic.
|
|
124
|
-
|
|
125
|
-
---
|
|
126
|
-
|
|
127
|
-
## Output
|
|
128
|
-
|
|
129
|
-
- [ ] App runs with `bun dev`
|
|
130
|
-
- [ ] All route files created as **Interactive Stubs**
|
|
131
|
-
- [ ] PageMeta set (auth: false for prototype validation)
|
|
132
|
-
- [ ] Navigation links included on each stub to related pages
|
|
133
|
-
- [ ] User has "clicked through" the flow and validated sitemap/friction
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
# BLUEPRINT: 2_ENTITIES
|
|
2
|
-
|
|
3
|
-
**Goal:** Define all data models from `docs/LLD.md` (Single Source of Truth).
|
|
4
|
-
|
|
5
|
-
**MCP:** `start_phase(2)` to begin. Use `lookup_symbol('defineEntity')` for types. `complete_phase()` when done.
|
|
6
|
-
**Done when:** All entities defined with fields, access rules, visibility. Exported from index.ts.
|
|
7
|
-
|
|
8
|
-
**Prerequisite:** Phase 0 (PRD + HLD + LLD) and Phase 1 (scaffold) complete.
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
## Step 1: Review LLD Entities
|
|
13
|
-
|
|
14
|
-
From `docs/LLD.md`, you have the per-entity specs: fields, state machines, relationships, access matrices.
|
|
15
|
-
|
|
16
|
-
**READ:** `guides/wai-way/entity_patterns.md` for common schemas:
|
|
17
|
-
- UserProfile, Post, Product, Order, Review, Comment
|
|
18
|
-
- Category, Settings, Workspace, Invitation, Media, ActivityLog
|
|
19
|
-
|
|
20
|
-
---
|
|
21
|
-
|
|
22
|
-
## Step 2: Create Entity Files
|
|
23
|
-
|
|
24
|
-
For each entity in `docs/LLD.md`:
|
|
25
|
-
|
|
26
|
-
1. Find matching pattern in `entity_patterns.md`
|
|
27
|
-
2. Copy pattern → `entities/[Entity].ts`
|
|
28
|
-
3. Customize fields from LLD field definitions
|
|
29
|
-
4. Set access rules from LLD access matrix
|
|
30
|
-
|
|
31
|
-
**READ:** `entities/ExampleEntity.ts` for the base pattern.
|
|
32
|
-
|
|
33
|
-
```typescript
|
|
34
|
-
// entities/Product.ts
|
|
35
|
-
import { defineEntity } from '@donotdev/core';
|
|
36
|
-
|
|
37
|
-
export const productEntity = defineEntity({
|
|
38
|
-
name: 'Product',
|
|
39
|
-
collection: 'products',
|
|
40
|
-
fields: {
|
|
41
|
-
// Fields from spec...
|
|
42
|
-
},
|
|
43
|
-
access: {
|
|
44
|
-
// Access rules from spec...
|
|
45
|
-
},
|
|
46
|
-
});
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
> **Status field:** Auto-added with locked `type`, `visibility`, `editable`. Don't redefine those. To add custom options:
|
|
50
|
-
> ```typescript
|
|
51
|
-
> status: { validation: { options: [{ value: 'shipped', label: 'Shipped' }] } }
|
|
52
|
-
> // Merged result: [draft, available, deleted, shipped]
|
|
53
|
-
> ```
|
|
54
|
-
|
|
55
|
-
---
|
|
56
|
-
|
|
57
|
-
## Step 3: Export Entities
|
|
58
|
-
|
|
59
|
-
```typescript
|
|
60
|
-
// entities/index.ts
|
|
61
|
-
export { productEntity } from './Product';
|
|
62
|
-
export { customerEntity } from './Customer';
|
|
63
|
-
export { orderEntity } from './Order';
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
---
|
|
67
|
-
|
|
68
|
-
## Field Type Quick Reference
|
|
69
|
-
|
|
70
|
-
| Type | Use for |
|
|
71
|
-
|------|---------|
|
|
72
|
-
| `text` | Single-line text |
|
|
73
|
-
| `textarea` | Multi-line text |
|
|
74
|
-
| `richtext` | Rich text editor |
|
|
75
|
-
| `number` | Numbers |
|
|
76
|
-
| `email` | Email addresses |
|
|
77
|
-
| `tel` | Phone numbers |
|
|
78
|
-
| `url` | URLs |
|
|
79
|
-
| `select` | Dropdown with options |
|
|
80
|
-
| `combobox` | Searchable dropdown |
|
|
81
|
-
| `multiselect` | Multiple selection |
|
|
82
|
-
| `switch` | On/off toggle |
|
|
83
|
-
| `date` | Date picker |
|
|
84
|
-
| `timestamp` | Date + time |
|
|
85
|
-
| `image` | Single image |
|
|
86
|
-
| `images` | Multiple images |
|
|
87
|
-
| `file` | Single file |
|
|
88
|
-
| `files` | Multiple files |
|
|
89
|
-
| `address` | Address autocomplete |
|
|
90
|
-
|
|
91
|
-
---
|
|
92
|
-
|
|
93
|
-
## Access Levels
|
|
94
|
-
|
|
95
|
-
| Level | Who |
|
|
96
|
-
|-------|-----|
|
|
97
|
-
| `guest` | Anyone |
|
|
98
|
-
| `user` | Authenticated |
|
|
99
|
-
| `owner` | Creator only |
|
|
100
|
-
| `admin` | Admins |
|
|
101
|
-
| `super` | Super admins |
|
|
102
|
-
| `never` | No one |
|
|
103
|
-
|
|
104
|
-
---
|
|
105
|
-
|
|
106
|
-
## Output
|
|
107
|
-
|
|
108
|
-
- [ ] All entities from spec defined in `entities/`
|
|
109
|
-
- [ ] Fields match LLD
|
|
110
|
-
- [ ] Access rules match LLD
|
|
111
|
-
- [ ] Exported from `entities/index.ts`
|
|
@@ -1,148 +0,0 @@
|
|
|
1
|
-
# BLUEPRINT: 3_COMPOSE
|
|
2
|
-
|
|
3
|
-
**Goal:** Build pages with components. i18n from day 1 — ALL strings via `t()`.
|
|
4
|
-
|
|
5
|
-
**MCP:** `start_phase(3)` to begin. Use `lookup_symbol(component_name)` for types. `complete_phase()` when done.
|
|
6
|
-
**Done when:** All pages functional with content. CRUD pages use EntityList/EntityFormRenderer. All strings via `t()` with locale files.
|
|
7
|
-
|
|
8
|
-
**Prerequisite:** Phase 0-2 complete. PRD + HLD + LLD validated, entities defined.
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
## Step 1: Apply UX Intent Rules
|
|
13
|
-
|
|
14
|
-
**Every page must follow the Designer Mandate:**
|
|
15
|
-
1. **70/30 Hierarchy:** Only ONE `primary` variant button/card per view. Use `outline` or `muted` for everything else to direct the user's eye to the North Star.
|
|
16
|
-
2. **Benefit-First Copy:** Do not use technical titles for Heros/Cards.
|
|
17
|
-
- No "User Management" -> "Empower Your Team"
|
|
18
|
-
- No "Car List" -> "Explore the Fleet"
|
|
19
|
-
3. **Success Intent:** Ensure framework default toasts are working. Only add a custom celebratory view or Redirect for the **North Star** goal completion.
|
|
20
|
-
|
|
21
|
-
---
|
|
22
|
-
|
|
23
|
-
## Reference: Demo App
|
|
24
|
-
|
|
25
|
-
**Before composing pages, study the demo app:** `packages/cli/templates/app-demo/src/pages/`
|
|
26
|
-
|
|
27
|
-
It shows the canonical pattern:
|
|
28
|
-
- Thin page wrappers (~5 lines) that import templates
|
|
29
|
-
- `PageMeta.preset` for per-route layout switching (landing -> admin -> docs)
|
|
30
|
-
- CRUD with `ProductCardListTemplate` + `defineEntity()`
|
|
31
|
-
- Component showcase with filterable grid
|
|
32
|
-
|
|
33
|
-
**Copy from the demo app, customize for your spec.**
|
|
34
|
-
|
|
35
|
-
---
|
|
36
|
-
|
|
37
|
-
## Step 2: Read Page Patterns
|
|
38
|
-
|
|
39
|
-
**READ:** `guides/wai-way/page_patterns.md` for all patterns:
|
|
40
|
-
- Dashboard, List Page, Form Page
|
|
41
|
-
- Landing/Home, Pricing, Settings
|
|
42
|
-
- Profile, Detail Page, Analytics
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
## Step 3: CRUD Pages
|
|
47
|
-
|
|
48
|
-
For each entity in spec:
|
|
49
|
-
|
|
50
|
-
### List Page
|
|
51
|
-
|
|
52
|
-
**READ:** `src/pages/ListPageExample.tsx`
|
|
53
|
-
|
|
54
|
-
```tsx
|
|
55
|
-
import { EntityList } from '@donotdev/crud';
|
|
56
|
-
import { useAuth } from '@donotdev/auth';
|
|
57
|
-
import { PageContainer } from '@donotdev/ui';
|
|
58
|
-
import { productEntity } from 'entities';
|
|
59
|
-
|
|
60
|
-
export default function ProductsListPage() {
|
|
61
|
-
const user = useAuth('user');
|
|
62
|
-
return (
|
|
63
|
-
<PageContainer>
|
|
64
|
-
<EntityList entity={productEntity} userRole={user?.role} />
|
|
65
|
-
</PageContainer>
|
|
66
|
-
);
|
|
67
|
-
}
|
|
68
|
-
```
|
|
69
|
-
|
|
70
|
-
### Form Page
|
|
71
|
-
|
|
72
|
-
**READ:** `src/pages/FormPageExample.tsx`
|
|
73
|
-
|
|
74
|
-
```tsx
|
|
75
|
-
import { EntityFormRenderer, useCrud } from '@donotdev/crud';
|
|
76
|
-
import { productEntity } from 'entities';
|
|
77
|
-
|
|
78
|
-
export default function ProductPage() {
|
|
79
|
-
const { id } = useParams();
|
|
80
|
-
const { get, add, update } = useCrud(productEntity);
|
|
81
|
-
const isNew = id === 'new';
|
|
82
|
-
// ... see page_patterns.md for full pattern
|
|
83
|
-
}
|
|
84
|
-
```
|
|
85
|
-
|
|
86
|
-
---
|
|
87
|
-
|
|
88
|
-
## Step 4: Dashboard Page
|
|
89
|
-
|
|
90
|
-
Copy Dashboard pattern from `page_patterns.md`:
|
|
91
|
-
- Quick actions (cards with onClick)
|
|
92
|
-
- KPI cards in grid
|
|
93
|
-
- Alert/attention sections
|
|
94
|
-
|
|
95
|
-
---
|
|
96
|
-
|
|
97
|
-
## Step 5: Landing Pages
|
|
98
|
-
|
|
99
|
-
Copy Landing pattern from `page_patterns.md`:
|
|
100
|
-
- HeroSection with CTAs
|
|
101
|
-
- Feature grid with Cards
|
|
102
|
-
- Final CTA section
|
|
103
|
-
|
|
104
|
-
---
|
|
105
|
-
|
|
106
|
-
## Component Quick Reference
|
|
107
|
-
|
|
108
|
-
| Component | Use for |
|
|
109
|
-
|-----------|---------|
|
|
110
|
-
| `PageContainer` | Page wrapper (required) |
|
|
111
|
-
| `HeroSection` | Full-width hero banner |
|
|
112
|
-
| `Section` | Content block with title |
|
|
113
|
-
| `Card` | Content card |
|
|
114
|
-
| `Grid` | Responsive grid ([1,2,3,3] = mobile 1, tablet 2, desktop 3) |
|
|
115
|
-
| `Stack` | Flex container |
|
|
116
|
-
| `Button` | Buttons |
|
|
117
|
-
| `Text` | Typography |
|
|
118
|
-
| `Badge` | Status badges |
|
|
119
|
-
| `Alert` | Notifications |
|
|
120
|
-
| `Loader` | Loading spinner |
|
|
121
|
-
|
|
122
|
-
---
|
|
123
|
-
|
|
124
|
-
## i18n FROM DAY 1
|
|
125
|
-
|
|
126
|
-
```tsx
|
|
127
|
-
// ALWAYS use t() — even with one language
|
|
128
|
-
const { t } = useTranslation('home');
|
|
129
|
-
|
|
130
|
-
<HeroSection
|
|
131
|
-
title={t('hero.title')}
|
|
132
|
-
subtitle={t('hero.subtitle')}
|
|
133
|
-
/>
|
|
134
|
-
```
|
|
135
|
-
|
|
136
|
-
Create locale files alongside pages: `src/locales/{namespace}_{lang}.json`
|
|
137
|
-
|
|
138
|
-
Adding a language later must be zero-cost. No hardcoded user-facing strings, ever.
|
|
139
|
-
|
|
140
|
-
---
|
|
141
|
-
|
|
142
|
-
## Output
|
|
143
|
-
|
|
144
|
-
- [ ] All CRUD pages use EntityList/EntityFormRenderer
|
|
145
|
-
- [ ] Dashboard uses pattern from page_patterns.md
|
|
146
|
-
- [ ] Landing pages use framework components
|
|
147
|
-
- [ ] All strings via t() with locale files created
|
|
148
|
-
- [ ] App is fully functional
|