@codeyam/codeyam-cli 0.1.0-staging.2ea44f6 → 0.1.0-staging.3ef993e
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/analyzer-template/.build-info.json +8 -8
- package/analyzer-template/log.txt +3 -3
- package/analyzer-template/package.json +1 -1
- package/analyzer-template/packages/aws/package.json +1 -1
- package/analyzer-template/packages/database/src/lib/kysely/tables/editorScenariosTable.ts +73 -0
- package/analyzer-template/packages/database/src/lib/loadEntities.ts +0 -6
- package/analyzer-template/packages/database/src/lib/updateCommitMetadata.ts +0 -65
- package/analyzer-template/packages/github/dist/database/src/lib/kysely/tables/editorScenariosTable.d.ts +6 -0
- package/analyzer-template/packages/github/dist/database/src/lib/kysely/tables/editorScenariosTable.d.ts.map +1 -1
- package/analyzer-template/packages/github/dist/database/src/lib/kysely/tables/editorScenariosTable.js +73 -0
- package/analyzer-template/packages/github/dist/database/src/lib/kysely/tables/editorScenariosTable.js.map +1 -1
- package/analyzer-template/packages/github/dist/database/src/lib/loadEntities.d.ts.map +1 -1
- package/analyzer-template/packages/github/dist/database/src/lib/loadEntities.js +0 -6
- package/analyzer-template/packages/github/dist/database/src/lib/loadEntities.js.map +1 -1
- package/analyzer-template/packages/github/dist/database/src/lib/updateCommitMetadata.d.ts.map +1 -1
- package/analyzer-template/packages/github/dist/database/src/lib/updateCommitMetadata.js +0 -25
- package/analyzer-template/packages/github/dist/database/src/lib/updateCommitMetadata.js.map +1 -1
- package/analyzer-template/packages/github/dist/types/src/enums/ProjectFramework.d.ts +2 -0
- package/analyzer-template/packages/github/dist/types/src/enums/ProjectFramework.d.ts.map +1 -1
- package/analyzer-template/packages/github/dist/types/src/enums/ProjectFramework.js +2 -0
- package/analyzer-template/packages/github/dist/types/src/enums/ProjectFramework.js.map +1 -1
- package/analyzer-template/packages/types/src/enums/ProjectFramework.ts +2 -0
- package/analyzer-template/packages/ui-components/package.json +1 -1
- package/analyzer-template/packages/utils/dist/types/src/enums/ProjectFramework.d.ts +2 -0
- package/analyzer-template/packages/utils/dist/types/src/enums/ProjectFramework.d.ts.map +1 -1
- package/analyzer-template/packages/utils/dist/types/src/enums/ProjectFramework.js +2 -0
- package/analyzer-template/packages/utils/dist/types/src/enums/ProjectFramework.js.map +1 -1
- package/codeyam-cli/src/commands/__tests__/editor.stepDispatch.test.js +45 -0
- package/codeyam-cli/src/commands/__tests__/editor.stepDispatch.test.js.map +1 -0
- package/codeyam-cli/src/commands/__tests__/init.gitignore.test.js +101 -47
- package/codeyam-cli/src/commands/__tests__/init.gitignore.test.js.map +1 -1
- package/codeyam-cli/src/commands/editor.js +1265 -213
- package/codeyam-cli/src/commands/editor.js.map +1 -1
- package/codeyam-cli/src/commands/init.js +67 -34
- package/codeyam-cli/src/commands/init.js.map +1 -1
- package/codeyam-cli/src/data/techStacks.js +77 -0
- package/codeyam-cli/src/data/techStacks.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/analyzerFinalization.test.js +173 -0
- package/codeyam-cli/src/utils/__tests__/analyzerFinalization.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/backgroundServer.test.js +46 -0
- package/codeyam-cli/src/utils/__tests__/backgroundServer.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/editorAudit.test.js +508 -1
- package/codeyam-cli/src/utils/__tests__/editorAudit.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorDevServer.test.js +152 -3
- package/codeyam-cli/src/utils/__tests__/editorDevServer.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorImageVerifier.test.js +140 -12
- package/codeyam-cli/src/utils/__tests__/editorImageVerifier.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorJournal.test.js +238 -2
- package/codeyam-cli/src/utils/__tests__/editorJournal.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorLoaderHelpers.test.js +128 -1
- package/codeyam-cli/src/utils/__tests__/editorLoaderHelpers.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorPreview.test.js +191 -5
- package/codeyam-cli/src/utils/__tests__/editorPreview.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorProxySession.test.js +153 -0
- package/codeyam-cli/src/utils/__tests__/editorProxySession.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarioLookup.test.js +139 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarioLookup.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarioSwitch.test.js +221 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarioSwitch.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarios.test.js +887 -2
- package/codeyam-cli/src/utils/__tests__/editorScenarios.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorSeedAdapter.test.js +213 -0
- package/codeyam-cli/src/utils/__tests__/editorSeedAdapter.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/entityChangeStatus.test.js +289 -40
- package/codeyam-cli/src/utils/__tests__/entityChangeStatus.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/journalCaptureStabilization.test.js +107 -0
- package/codeyam-cli/src/utils/__tests__/journalCaptureStabilization.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/parseRegisterArg.test.js +129 -0
- package/codeyam-cli/src/utils/__tests__/parseRegisterArg.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/scenarioCoverage.test.js +227 -0
- package/codeyam-cli/src/utils/__tests__/scenarioCoverage.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/scenariosManifest.test.js +426 -218
- package/codeyam-cli/src/utils/__tests__/scenariosManifest.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/setupClaudeCodeSettings.test.js +13 -5
- package/codeyam-cli/src/utils/__tests__/setupClaudeCodeSettings.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/templateConsistency.test.js +51 -0
- package/codeyam-cli/src/utils/__tests__/templateConsistency.test.js.map +1 -0
- package/codeyam-cli/src/utils/__tests__/webappDetection.test.js +142 -0
- package/codeyam-cli/src/utils/__tests__/webappDetection.test.js.map +1 -0
- package/codeyam-cli/src/utils/analyzer.js +9 -0
- package/codeyam-cli/src/utils/analyzer.js.map +1 -1
- package/codeyam-cli/src/utils/analyzerFinalization.js +100 -0
- package/codeyam-cli/src/utils/analyzerFinalization.js.map +1 -0
- package/codeyam-cli/src/utils/backgroundServer.js +92 -16
- package/codeyam-cli/src/utils/backgroundServer.js.map +1 -1
- package/codeyam-cli/src/utils/database.js +37 -2
- package/codeyam-cli/src/utils/database.js.map +1 -1
- package/codeyam-cli/src/utils/editorAudit.js +91 -3
- package/codeyam-cli/src/utils/editorAudit.js.map +1 -1
- package/codeyam-cli/src/utils/editorDevServer.js +89 -1
- package/codeyam-cli/src/utils/editorDevServer.js.map +1 -1
- package/codeyam-cli/src/utils/editorImageVerifier.js +45 -10
- package/codeyam-cli/src/utils/editorImageVerifier.js.map +1 -1
- package/codeyam-cli/src/utils/editorJournal.js +78 -3
- package/codeyam-cli/src/utils/editorJournal.js.map +1 -1
- package/codeyam-cli/src/utils/editorLoaderHelpers.js +32 -0
- package/codeyam-cli/src/utils/editorLoaderHelpers.js.map +1 -1
- package/codeyam-cli/src/utils/editorPreview.js +43 -2
- package/codeyam-cli/src/utils/editorPreview.js.map +1 -1
- package/codeyam-cli/src/utils/editorScenarioSwitch.js +112 -0
- package/codeyam-cli/src/utils/editorScenarioSwitch.js.map +1 -0
- package/codeyam-cli/src/utils/editorScenarios.js +291 -0
- package/codeyam-cli/src/utils/editorScenarios.js.map +1 -1
- package/codeyam-cli/src/utils/editorSeedAdapter.js +173 -0
- package/codeyam-cli/src/utils/editorSeedAdapter.js.map +1 -0
- package/codeyam-cli/src/utils/entityChangeStatus.js +42 -19
- package/codeyam-cli/src/utils/entityChangeStatus.js.map +1 -1
- package/codeyam-cli/src/utils/entityChangeStatus.server.js +56 -5
- package/codeyam-cli/src/utils/entityChangeStatus.server.js.map +1 -1
- package/codeyam-cli/src/utils/parseRegisterArg.js +31 -0
- package/codeyam-cli/src/utils/parseRegisterArg.js.map +1 -0
- package/codeyam-cli/src/utils/progress.js +2 -2
- package/codeyam-cli/src/utils/progress.js.map +1 -1
- package/codeyam-cli/src/utils/scenarioCoverage.js +75 -0
- package/codeyam-cli/src/utils/scenarioCoverage.js.map +1 -0
- package/codeyam-cli/src/utils/scenariosManifest.js +204 -75
- package/codeyam-cli/src/utils/scenariosManifest.js.map +1 -1
- package/codeyam-cli/src/utils/serverState.js +30 -0
- package/codeyam-cli/src/utils/serverState.js.map +1 -1
- package/codeyam-cli/src/utils/setupClaudeCodeSettings.js +13 -5
- package/codeyam-cli/src/utils/setupClaudeCodeSettings.js.map +1 -1
- package/codeyam-cli/src/utils/simulationGateMiddleware.js +8 -1
- package/codeyam-cli/src/utils/simulationGateMiddleware.js.map +1 -1
- package/codeyam-cli/src/utils/slugUtils.js +25 -0
- package/codeyam-cli/src/utils/slugUtils.js.map +1 -0
- package/codeyam-cli/src/utils/syncMocksMiddleware.js +2 -2
- package/codeyam-cli/src/utils/syncMocksMiddleware.js.map +1 -1
- package/codeyam-cli/src/utils/webappDetection.js +21 -0
- package/codeyam-cli/src/utils/webappDetection.js.map +1 -1
- package/codeyam-cli/src/webserver/__tests__/clientErrors.test.js +40 -0
- package/codeyam-cli/src/webserver/__tests__/clientErrors.test.js.map +1 -0
- package/codeyam-cli/src/webserver/__tests__/editorProxy.test.js +567 -0
- package/codeyam-cli/src/webserver/__tests__/editorProxy.test.js.map +1 -0
- package/codeyam-cli/src/webserver/__tests__/idleDetector.test.js +146 -0
- package/codeyam-cli/src/webserver/__tests__/idleDetector.test.js.map +1 -0
- package/codeyam-cli/src/webserver/app/lib/clientErrors.js +65 -0
- package/codeyam-cli/src/webserver/app/lib/clientErrors.js.map +1 -0
- package/codeyam-cli/src/webserver/app/lib/git.js +3 -2
- package/codeyam-cli/src/webserver/app/lib/git.js.map +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{CopyButton-DmJveP3T.js → CopyButton-BPXZwM4t.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{EntityItem-C76mRRiF.js → EntityItem-BcgbViKV.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/{EntityTypeIcon-CobE682z.js → EntityTypeIcon-CQIG2qda.js} +9 -9
- package/codeyam-cli/src/webserver/build/client/assets/{ReportIssueModal-djPLI-WV.js → ReportIssueModal-BzHcG7SE.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/{ScenarioViewer-ZlRKbhrq.js → ScenarioViewer-TSD3C211.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{_index-C96V0n15.js → _index-DLxKhri3.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/{activity.(_tab)-BpKzcsJz.js → activity.(_tab)-BcY3q6nt.js} +6 -6
- package/codeyam-cli/src/webserver/build/client/assets/{agent-transcripts-D9hemwl6.js → agent-transcripts-Bni3iiUj.js} +5 -5
- package/codeyam-cli/src/webserver/build/client/assets/api.editor-project-info-l0sNRNKZ.js +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/api.editor-scenario-coverage-l0sNRNKZ.js +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/{book-open-D_nMCFmP.js → book-open-BYOypzCa.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{chevron-down-BH2h1Ea2.js → chevron-down-C_Pmso5S.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{circle-check-DyIKORY6.js → circle-check-BVMi9VA5.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{copy-NDbZjXao.js → copy-n2FB0_Sw.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/createLucideIcon-CC6AbExI.js +41 -0
- package/codeyam-cli/src/webserver/build/client/assets/{dev.empty-CltMNppm.js → dev.empty-Ii3inc0_.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/editor-COWCNVyV.js +10 -0
- package/codeyam-cli/src/webserver/build/client/assets/editorPreview-CNB06EIa.js +41 -0
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha._-DItJnD8s.js → entity._sha._-DwCV5__E.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha.scenarios._scenarioId.dev-CCa2trIL.js → entity._sha.scenarios._scenarioId.dev-CXSi2aeZ.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/entity._sha.scenarios._scenarioId.fullscreen-CHMiAog3.js +6 -0
- package/codeyam-cli/src/webserver/build/client/assets/{files-DO4CZ16O.js → files-BZrlFE1F.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{git-CdN8sCqs.js → git-DdZcvjGh.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/globals-phvmGvat.css +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/{loader-circle-BAXYRVEO.js → loader-circle-DaAZ_H2w.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/manifest-6134dc40.js +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/memory-9gnxSZlb.js +101 -0
- package/codeyam-cli/src/webserver/build/client/assets/{pause-DTAcYxBt.js → pause-f5-1lKBt.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/root-BWAyuj0r.js +67 -0
- package/codeyam-cli/src/webserver/build/client/assets/{search-fKo7v0Zo.js → search-Di64LWVb.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{settings-DfuTtcJP.js → settings-0OrEMU6J.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{simulations-B3aOzpCZ.js → simulations-DWT-CvLy.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{terminal-BG4heKCG.js → terminal-Br7MOqts.js} +3 -3
- package/codeyam-cli/src/webserver/build/client/assets/{triangle-alert-DtSmdtM4.js → triangle-alert-BLdiCuG-.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/useCustomSizes-C-_hOl_g.js +1 -0
- package/codeyam-cli/src/webserver/build/client/sound-test.html +98 -0
- package/codeyam-cli/src/webserver/build/server/assets/index-ChX0hPcu.js +1 -0
- package/codeyam-cli/src/webserver/build/server/assets/init-kSNsMjj8.js +10 -0
- package/codeyam-cli/src/webserver/build/server/assets/server-build-Bm2xIhmh.js +439 -0
- package/codeyam-cli/src/webserver/build/server/index.js +1 -1
- package/codeyam-cli/src/webserver/build-info.json +5 -5
- package/codeyam-cli/src/webserver/editorProxy.js +487 -17
- package/codeyam-cli/src/webserver/editorProxy.js.map +1 -1
- package/codeyam-cli/src/webserver/idleDetector.js +73 -0
- package/codeyam-cli/src/webserver/idleDetector.js.map +1 -0
- package/codeyam-cli/src/webserver/public/sound-test.html +98 -0
- package/codeyam-cli/src/webserver/scripts/codeyam-preload.mjs +21 -3
- package/codeyam-cli/src/webserver/scripts/journalCapture.ts +94 -4
- package/codeyam-cli/src/webserver/server.js +59 -34
- package/codeyam-cli/src/webserver/server.js.map +1 -1
- package/codeyam-cli/src/webserver/terminalServer.js +64 -32
- package/codeyam-cli/src/webserver/terminalServer.js.map +1 -1
- package/codeyam-cli/templates/chrome-extension-react/EXTENSION_SETUP.md +75 -0
- package/codeyam-cli/templates/chrome-extension-react/README.md +46 -0
- package/codeyam-cli/templates/chrome-extension-react/gitignore +15 -0
- package/codeyam-cli/templates/chrome-extension-react/index.html +12 -0
- package/codeyam-cli/templates/chrome-extension-react/package.json +27 -0
- package/codeyam-cli/templates/chrome-extension-react/popup.html +12 -0
- package/codeyam-cli/templates/chrome-extension-react/public/manifest.json +15 -0
- package/codeyam-cli/templates/chrome-extension-react/src/background/service-worker.ts +7 -0
- package/codeyam-cli/templates/chrome-extension-react/src/globals.css +6 -0
- package/codeyam-cli/templates/chrome-extension-react/src/lib/storage.ts +37 -0
- package/codeyam-cli/templates/chrome-extension-react/src/popup/App.tsx +12 -0
- package/codeyam-cli/templates/chrome-extension-react/src/popup/main.tsx +10 -0
- package/codeyam-cli/templates/chrome-extension-react/tsconfig.json +24 -0
- package/codeyam-cli/templates/chrome-extension-react/vite.config.ts +41 -0
- package/codeyam-cli/templates/codeyam-editor-claude.md +84 -5
- package/codeyam-cli/templates/editor-step-hook.py +37 -8
- package/codeyam-cli/templates/expo-react-native/MOBILE_SETUP.md +89 -0
- package/codeyam-cli/templates/expo-react-native/README.md +41 -0
- package/codeyam-cli/templates/expo-react-native/app/(tabs)/_layout.tsx +33 -0
- package/codeyam-cli/templates/expo-react-native/app/(tabs)/index.tsx +12 -0
- package/codeyam-cli/templates/expo-react-native/app/(tabs)/settings.tsx +12 -0
- package/codeyam-cli/templates/expo-react-native/app/_layout.tsx +12 -0
- package/codeyam-cli/templates/expo-react-native/app.json +18 -0
- package/codeyam-cli/templates/expo-react-native/babel.config.js +9 -0
- package/codeyam-cli/templates/expo-react-native/gitignore +12 -0
- package/codeyam-cli/templates/expo-react-native/global.css +3 -0
- package/codeyam-cli/templates/expo-react-native/lib/storage.ts +32 -0
- package/codeyam-cli/templates/expo-react-native/metro.config.js +6 -0
- package/codeyam-cli/templates/expo-react-native/nativewind-env.d.ts +1 -0
- package/codeyam-cli/templates/expo-react-native/package.json +38 -0
- package/codeyam-cli/templates/expo-react-native/tailwind.config.js +10 -0
- package/codeyam-cli/templates/expo-react-native/tsconfig.json +10 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/AUTH_PATTERNS.md +308 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/AUTH_UPGRADE.md +304 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/DATABASE.md +126 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/FEATURE_PATTERNS.md +37 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/README.md +53 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/app/lib/prisma.ts +9 -4
- package/codeyam-cli/templates/nextjs-prisma-sqlite/env +4 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/gitignore +1 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/package.json +1 -0
- package/codeyam-cli/templates/nextjs-prisma-sqlite/prisma/seed.ts +4 -1
- package/codeyam-cli/templates/nextjs-prisma-sqlite/seed-adapter.ts +92 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/README.md +52 -0
- package/codeyam-cli/templates/{nextjs-prisma-sqlite/PRISMA_SETUP.md → nextjs-prisma-supabase/SUPABASE_SETUP.md} +37 -17
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/api/todos/route.ts +17 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/globals.css +26 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/layout.tsx +34 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/lib/prisma.ts +20 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/lib/supabase.ts +12 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/app/page.tsx +10 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/env +9 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/eslint.config.mjs +11 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/gitignore +40 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/next.config.ts +11 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/package.json +37 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/postcss.config.mjs +7 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/prisma/schema.prisma +27 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/prisma/seed.ts +39 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/prisma.config.ts +12 -0
- package/codeyam-cli/templates/nextjs-prisma-supabase/tsconfig.json +34 -0
- package/codeyam-cli/templates/skills/codeyam-dev-mode/SKILL.md +1 -1
- package/codeyam-cli/templates/skills/codeyam-editor/SKILL.md +28 -9
- package/package.json +1 -1
- package/packages/database/src/lib/kysely/tables/editorScenariosTable.js +73 -0
- package/packages/database/src/lib/kysely/tables/editorScenariosTable.js.map +1 -1
- package/packages/database/src/lib/loadEntities.js +0 -6
- package/packages/database/src/lib/loadEntities.js.map +1 -1
- package/packages/database/src/lib/updateCommitMetadata.js +0 -25
- package/packages/database/src/lib/updateCommitMetadata.js.map +1 -1
- package/packages/types/src/enums/ProjectFramework.js +2 -0
- package/packages/types/src/enums/ProjectFramework.js.map +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/createLucideIcon-CMT1jU2q.js +0 -21
- package/codeyam-cli/src/webserver/build/client/assets/editor-Rfq_y0VR.js +0 -10
- package/codeyam-cli/src/webserver/build/client/assets/editorPreview-GNwaLSmC.js +0 -41
- package/codeyam-cli/src/webserver/build/client/assets/entity._sha.scenarios._scenarioId.fullscreen-CF164ouH.js +0 -6
- package/codeyam-cli/src/webserver/build/client/assets/globals-Bd0cs8vw.css +0 -1
- package/codeyam-cli/src/webserver/build/client/assets/manifest-9ab0aba3.js +0 -1
- package/codeyam-cli/src/webserver/build/client/assets/memory-Dg0mvYrI.js +0 -96
- package/codeyam-cli/src/webserver/build/client/assets/root-3ciuWk-c.js +0 -67
- package/codeyam-cli/src/webserver/build/client/assets/useCustomSizes-CrAK28Bc.js +0 -1
- package/codeyam-cli/src/webserver/build/server/assets/index-DCxIbVvl.js +0 -1
- package/codeyam-cli/src/webserver/build/server/assets/server-build-E-peu3XZ.js +0 -367
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { buildReverseDependencyGraph, classifyDirectChanges, computeEntityChangeStatus, buildChangedFilesMap, pageNameFromUrl, buildEntityInfosFromScenarios, buildEntityInfosFromGlossary, filterGroupsByChangeStatus, filterGlossaryByChangeStatus, filterScenarioScreenshotsByChangeStatus, } from "../entityChangeStatus.js";
|
|
1
|
+
import { buildReverseDependencyGraph, classifyDirectChanges, computeEntityChangeStatus, buildChangedFilesMap, pageNameFromUrl, scenarioEntityName, buildEntityInfosFromScenarios, buildEntityInfosFromGlossary, filterGroupsByChangeStatus, filterGlossaryByChangeStatus, filterScenarioScreenshotsByChangeStatus, } from "../entityChangeStatus.js";
|
|
2
2
|
import { scanPageFilePaths, detectFirstFeature, readFeatureStartedAt, } from "../entityChangeStatus.server.js";
|
|
3
3
|
import * as fsModule from 'fs';
|
|
4
4
|
import * as pathModule from 'path';
|
|
@@ -128,6 +128,11 @@ describe('entityChangeStatus', () => {
|
|
|
128
128
|
// This is an edge case — empty string is falsy so returns Home
|
|
129
129
|
expect(pageNameFromUrl('')).toBe('Home');
|
|
130
130
|
});
|
|
131
|
+
it('should return Home for root path with query string', () => {
|
|
132
|
+
expect(pageNameFromUrl('/?demo=empty')).toBe('Home');
|
|
133
|
+
expect(pageNameFromUrl('/?state=seeded')).toBe('Home');
|
|
134
|
+
expect(pageNameFromUrl('/?tab=overview&sort=date')).toBe('Home');
|
|
135
|
+
});
|
|
131
136
|
it('should handle dynamic route segments', () => {
|
|
132
137
|
expect(pageNameFromUrl('/drinks/[id]')).toBe('Drinks');
|
|
133
138
|
expect(pageNameFromUrl('/users/[userId]/posts')).toBe('Users');
|
|
@@ -1298,81 +1303,274 @@ describe('entityChangeStatus', () => {
|
|
|
1298
1303
|
expect(result).toEqual([]);
|
|
1299
1304
|
});
|
|
1300
1305
|
});
|
|
1306
|
+
// ── scenarioEntityName ──────────────────────────────────────────────
|
|
1307
|
+
describe('scenarioEntityName', () => {
|
|
1308
|
+
it('should return componentName when set', () => {
|
|
1309
|
+
expect(scenarioEntityName({
|
|
1310
|
+
componentName: 'ReviewCard',
|
|
1311
|
+
url: '/isolated-components/ReviewCard?s=Default',
|
|
1312
|
+
})).toBe('ReviewCard');
|
|
1313
|
+
});
|
|
1314
|
+
it('should return page name from URL when componentName is null', () => {
|
|
1315
|
+
expect(scenarioEntityName({ componentName: null, url: '/drinks/1' })).toBe('Drinks');
|
|
1316
|
+
});
|
|
1317
|
+
it('should return Home for root URL when componentName is null', () => {
|
|
1318
|
+
expect(scenarioEntityName({ componentName: null, url: '/' })).toBe('Home');
|
|
1319
|
+
});
|
|
1320
|
+
it('should return Home when both componentName and url are null', () => {
|
|
1321
|
+
expect(scenarioEntityName({ componentName: null, url: null })).toBe('Home');
|
|
1322
|
+
});
|
|
1323
|
+
it('should return page name when componentName is undefined', () => {
|
|
1324
|
+
expect(scenarioEntityName({ url: '/settings' })).toBe('Settings');
|
|
1325
|
+
});
|
|
1326
|
+
it('should return Home when no fields provided', () => {
|
|
1327
|
+
expect(scenarioEntityName({})).toBe('Home');
|
|
1328
|
+
});
|
|
1329
|
+
});
|
|
1301
1330
|
// ── filterScenarioScreenshotsByChangeStatus ───────────────────────────
|
|
1302
1331
|
describe('filterScenarioScreenshotsByChangeStatus', () => {
|
|
1303
|
-
const screenshots = [
|
|
1304
|
-
{ name: 'Busy Month', path: 'busy.png' },
|
|
1305
|
-
{ name: 'Empty Calendar', path: 'empty.png' },
|
|
1306
|
-
{ name: 'EventPill - Default', path: 'pill.png' },
|
|
1307
|
-
{ name: 'ErrorState - Server Error', path: 'error.png' },
|
|
1308
|
-
{ name: 'CalendarGrid - Default', path: 'grid.png' },
|
|
1309
|
-
];
|
|
1310
|
-
const pageNames = new Set(['Home']);
|
|
1311
1332
|
it('should return all screenshots when entityChangeStatus is undefined', () => {
|
|
1312
|
-
|
|
1333
|
+
const screenshots = [
|
|
1334
|
+
{ name: 'Busy Month', path: 'busy.png', componentName: null, url: '/' },
|
|
1335
|
+
{
|
|
1336
|
+
name: 'EventPill - Default',
|
|
1337
|
+
path: 'pill.png',
|
|
1338
|
+
componentName: 'EventPill',
|
|
1339
|
+
url: '/isolated-components/EventPill',
|
|
1340
|
+
},
|
|
1341
|
+
];
|
|
1342
|
+
expect(filterScenarioScreenshotsByChangeStatus(screenshots, undefined)).toEqual(screenshots);
|
|
1313
1343
|
});
|
|
1314
1344
|
it('should return all screenshots when entityChangeStatus is empty', () => {
|
|
1315
|
-
|
|
1345
|
+
const screenshots = [
|
|
1346
|
+
{ name: 'Busy Month', path: 'busy.png', componentName: null, url: '/' },
|
|
1347
|
+
];
|
|
1348
|
+
expect(filterScenarioScreenshotsByChangeStatus(screenshots, {})).toEqual(screenshots);
|
|
1316
1349
|
});
|
|
1317
|
-
it('should
|
|
1350
|
+
it('should include component scenarios whose entity has a change status', () => {
|
|
1351
|
+
const screenshots = [
|
|
1352
|
+
{
|
|
1353
|
+
name: 'EventPill - Default',
|
|
1354
|
+
path: 'pill.png',
|
|
1355
|
+
componentName: 'EventPill',
|
|
1356
|
+
url: '/isolated-components/EventPill',
|
|
1357
|
+
},
|
|
1358
|
+
{
|
|
1359
|
+
name: 'ErrorState - Server Error',
|
|
1360
|
+
path: 'error.png',
|
|
1361
|
+
componentName: 'ErrorState',
|
|
1362
|
+
url: '/isolated-components/ErrorState',
|
|
1363
|
+
},
|
|
1364
|
+
{
|
|
1365
|
+
name: 'CalendarGrid - Default',
|
|
1366
|
+
path: 'grid.png',
|
|
1367
|
+
componentName: 'CalendarGrid',
|
|
1368
|
+
url: '/isolated-components/CalendarGrid',
|
|
1369
|
+
},
|
|
1370
|
+
];
|
|
1318
1371
|
const status = {
|
|
1319
1372
|
ErrorState: { status: 'new' },
|
|
1320
|
-
|
|
1373
|
+
EventPill: { status: 'edited' },
|
|
1321
1374
|
};
|
|
1322
|
-
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status
|
|
1323
|
-
// App-level screenshots (no prefix) match because Home page has status
|
|
1324
|
-
// "ErrorState - *" matches the ErrorState entity
|
|
1375
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1325
1376
|
expect(result.map((s) => s.name)).toEqual([
|
|
1326
|
-
'
|
|
1327
|
-
'Empty Calendar',
|
|
1377
|
+
'EventPill - Default',
|
|
1328
1378
|
'ErrorState - Server Error',
|
|
1329
1379
|
]);
|
|
1330
1380
|
});
|
|
1331
|
-
it('should
|
|
1332
|
-
const
|
|
1333
|
-
{ name: 'Busy Month', path: 'busy.png' },
|
|
1334
|
-
{
|
|
1381
|
+
it('should include page scenarios whose page entity has a change status', () => {
|
|
1382
|
+
const screenshots = [
|
|
1383
|
+
{ name: 'Busy Month', path: 'busy.png', componentName: null, url: '/' },
|
|
1384
|
+
{
|
|
1385
|
+
name: 'Empty Calendar',
|
|
1386
|
+
path: 'empty.png',
|
|
1387
|
+
componentName: null,
|
|
1388
|
+
url: '/',
|
|
1389
|
+
},
|
|
1335
1390
|
];
|
|
1336
1391
|
const status = {
|
|
1337
1392
|
Home: { status: 'edited' },
|
|
1338
1393
|
};
|
|
1339
|
-
const result = filterScenarioScreenshotsByChangeStatus(
|
|
1340
|
-
expect(result).toEqual(
|
|
1394
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1395
|
+
expect(result).toEqual(screenshots);
|
|
1341
1396
|
});
|
|
1342
|
-
it('should exclude
|
|
1397
|
+
it('should exclude page scenarios when their page entity has no status', () => {
|
|
1398
|
+
const screenshots = [
|
|
1399
|
+
{ name: 'Busy Month', path: 'busy.png', componentName: null, url: '/' },
|
|
1400
|
+
{
|
|
1401
|
+
name: 'EventPill - Default',
|
|
1402
|
+
path: 'pill.png',
|
|
1403
|
+
componentName: 'EventPill',
|
|
1404
|
+
url: '/isolated-components/EventPill',
|
|
1405
|
+
},
|
|
1406
|
+
];
|
|
1343
1407
|
const status = {
|
|
1344
1408
|
SomeComponent: { status: 'new' },
|
|
1345
1409
|
};
|
|
1346
|
-
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status
|
|
1347
|
-
//
|
|
1348
|
-
// SomeComponent doesn't match
|
|
1410
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1411
|
+
// Home page has no status, so "Busy Month" is excluded
|
|
1412
|
+
// SomeComponent doesn't match EventPill either
|
|
1349
1413
|
expect(result).toEqual([]);
|
|
1350
1414
|
});
|
|
1351
|
-
it('should include
|
|
1415
|
+
it('should include both page and component scenarios when both entities have status', () => {
|
|
1416
|
+
const screenshots = [
|
|
1417
|
+
{ name: 'Busy Month', path: 'busy.png', componentName: null, url: '/' },
|
|
1418
|
+
{
|
|
1419
|
+
name: 'Empty Calendar',
|
|
1420
|
+
path: 'empty.png',
|
|
1421
|
+
componentName: null,
|
|
1422
|
+
url: '/',
|
|
1423
|
+
},
|
|
1424
|
+
{
|
|
1425
|
+
name: 'EventPill - Default',
|
|
1426
|
+
path: 'pill.png',
|
|
1427
|
+
componentName: 'EventPill',
|
|
1428
|
+
url: '/isolated-components/EventPill',
|
|
1429
|
+
},
|
|
1430
|
+
];
|
|
1352
1431
|
const status = {
|
|
1353
1432
|
Home: { status: 'edited' },
|
|
1354
1433
|
EventPill: { status: 'new' },
|
|
1355
1434
|
};
|
|
1356
|
-
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status
|
|
1435
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1357
1436
|
expect(result.map((s) => s.name)).toEqual([
|
|
1358
1437
|
'Busy Month',
|
|
1359
1438
|
'Empty Calendar',
|
|
1360
1439
|
'EventPill - Default',
|
|
1361
1440
|
]);
|
|
1362
1441
|
});
|
|
1363
|
-
it('should handle
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
{
|
|
1442
|
+
it('should handle page scenarios with dashes in names using URL, not name parsing', () => {
|
|
1443
|
+
// The original bug: "Drink Detail - Earl Grey" was parsed as component "Drink Detail"
|
|
1444
|
+
const screenshots = [
|
|
1445
|
+
{
|
|
1446
|
+
name: 'Drink Detail - Earl Grey',
|
|
1447
|
+
path: 'earl.png',
|
|
1448
|
+
componentName: null,
|
|
1449
|
+
url: '/drinks/1',
|
|
1450
|
+
},
|
|
1451
|
+
{
|
|
1452
|
+
name: 'Drink Detail - No Reviews',
|
|
1453
|
+
path: 'no-reviews.png',
|
|
1454
|
+
componentName: null,
|
|
1455
|
+
url: '/drinks/1',
|
|
1456
|
+
},
|
|
1457
|
+
{
|
|
1458
|
+
name: 'ReviewCard - Default',
|
|
1459
|
+
path: 'review.png',
|
|
1460
|
+
componentName: 'ReviewCard',
|
|
1461
|
+
url: '/isolated-components/ReviewCard',
|
|
1462
|
+
},
|
|
1463
|
+
{
|
|
1464
|
+
name: 'Full Catalog',
|
|
1465
|
+
path: 'catalog.png',
|
|
1466
|
+
componentName: null,
|
|
1467
|
+
url: '/',
|
|
1468
|
+
},
|
|
1469
|
+
];
|
|
1470
|
+
const status = {
|
|
1471
|
+
Drinks: { status: 'new' },
|
|
1472
|
+
ReviewCard: { status: 'new' },
|
|
1473
|
+
Home: { status: 'edited' },
|
|
1474
|
+
};
|
|
1475
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1476
|
+
expect(result.map((s) => s.name)).toEqual([
|
|
1477
|
+
'Drink Detail - Earl Grey',
|
|
1478
|
+
'Drink Detail - No Reviews',
|
|
1479
|
+
'ReviewCard - Default',
|
|
1480
|
+
'Full Catalog',
|
|
1481
|
+
]);
|
|
1482
|
+
});
|
|
1483
|
+
it('should exclude page scenarios for unchanged pages even with dashes in names', () => {
|
|
1484
|
+
const screenshots = [
|
|
1485
|
+
{
|
|
1486
|
+
name: 'Drink Detail - Earl Grey',
|
|
1487
|
+
path: 'earl.png',
|
|
1488
|
+
componentName: null,
|
|
1489
|
+
url: '/drinks/1',
|
|
1490
|
+
},
|
|
1491
|
+
{
|
|
1492
|
+
name: 'ReviewCard - Default',
|
|
1493
|
+
path: 'review.png',
|
|
1494
|
+
componentName: 'ReviewCard',
|
|
1495
|
+
url: '/isolated-components/ReviewCard',
|
|
1496
|
+
},
|
|
1497
|
+
];
|
|
1498
|
+
const status = {
|
|
1499
|
+
ReviewCard: { status: 'edited' },
|
|
1500
|
+
};
|
|
1501
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1502
|
+
// Drinks page has no status, so "Drink Detail" page scenarios are excluded
|
|
1503
|
+
expect(result.map((s) => s.name)).toEqual(['ReviewCard - Default']);
|
|
1504
|
+
});
|
|
1505
|
+
it('should use componentName for matching, not the name prefix', () => {
|
|
1506
|
+
const screenshots = [
|
|
1507
|
+
{
|
|
1508
|
+
name: 'Card Loading State - Spinner',
|
|
1509
|
+
path: 'spinner.png',
|
|
1510
|
+
componentName: 'LoadingCard',
|
|
1511
|
+
url: '/isolated-components/LoadingCard',
|
|
1512
|
+
},
|
|
1513
|
+
];
|
|
1514
|
+
const status = {
|
|
1515
|
+
LoadingCard: { status: 'new' },
|
|
1516
|
+
};
|
|
1517
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1518
|
+
expect(result.map((s) => s.name)).toEqual([
|
|
1519
|
+
'Card Loading State - Spinner',
|
|
1520
|
+
]);
|
|
1521
|
+
});
|
|
1522
|
+
it('should exclude component scenario when its entity has no status', () => {
|
|
1523
|
+
const screenshots = [
|
|
1524
|
+
{
|
|
1525
|
+
name: 'Card Loading State - Spinner',
|
|
1526
|
+
path: 'spinner.png',
|
|
1527
|
+
componentName: 'LoadingCard',
|
|
1528
|
+
url: '/isolated-components/LoadingCard',
|
|
1529
|
+
},
|
|
1530
|
+
];
|
|
1531
|
+
const status = {
|
|
1532
|
+
SomeOtherComponent: { status: 'new' },
|
|
1533
|
+
};
|
|
1534
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1535
|
+
expect(result).toEqual([]);
|
|
1536
|
+
});
|
|
1537
|
+
it('should filter per-page independently (not all-or-nothing for pages)', () => {
|
|
1538
|
+
// Only Drinks page changed, not Home — scenarios for each page should be filtered independently
|
|
1539
|
+
const screenshots = [
|
|
1540
|
+
{
|
|
1541
|
+
name: 'Full Catalog',
|
|
1542
|
+
path: 'catalog.png',
|
|
1543
|
+
componentName: null,
|
|
1544
|
+
url: '/',
|
|
1545
|
+
},
|
|
1546
|
+
{
|
|
1547
|
+
name: 'Drink Detail - Earl Grey',
|
|
1548
|
+
path: 'earl.png',
|
|
1549
|
+
componentName: null,
|
|
1550
|
+
url: '/drinks/1',
|
|
1551
|
+
},
|
|
1552
|
+
];
|
|
1553
|
+
const status = {
|
|
1554
|
+
Drinks: { status: 'new' },
|
|
1555
|
+
};
|
|
1556
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1557
|
+
// Home page has no status, so "Full Catalog" is excluded
|
|
1558
|
+
// Drinks page has status, so "Drink Detail" is included
|
|
1559
|
+
expect(result.map((s) => s.name)).toEqual(['Drink Detail - Earl Grey']);
|
|
1560
|
+
});
|
|
1561
|
+
it('should fall back to name-based parsing when componentName is not present (backward compat)', () => {
|
|
1562
|
+
const screenshots = [
|
|
1367
1563
|
{ name: 'EventPill - Default', path: 'pill.png' },
|
|
1564
|
+
{ name: 'Full Calendar', path: 'cal.png' },
|
|
1368
1565
|
];
|
|
1369
1566
|
const status = {
|
|
1567
|
+
EventPill: { status: 'new' },
|
|
1370
1568
|
Home: { status: 'edited' },
|
|
1371
1569
|
};
|
|
1372
|
-
const result = filterScenarioScreenshotsByChangeStatus(
|
|
1570
|
+
const result = filterScenarioScreenshotsByChangeStatus(screenshots, status);
|
|
1373
1571
|
expect(result.map((s) => s.name)).toEqual([
|
|
1374
|
-
'
|
|
1375
|
-
'
|
|
1572
|
+
'EventPill - Default',
|
|
1573
|
+
'Full Calendar',
|
|
1376
1574
|
]);
|
|
1377
1575
|
});
|
|
1378
1576
|
});
|
|
@@ -1411,12 +1609,12 @@ describe('entityChangeStatus', () => {
|
|
|
1411
1609
|
const result = scanPageFilePaths(tempDir);
|
|
1412
1610
|
expect(result).toEqual({ Home: 'app/page.js' });
|
|
1413
1611
|
});
|
|
1414
|
-
it('should skip
|
|
1612
|
+
it('should skip isolated-components directories', () => {
|
|
1415
1613
|
const appDir = pathModule.join(tempDir, 'app');
|
|
1416
|
-
fsModule.mkdirSync(pathModule.join(appDir, '
|
|
1614
|
+
fsModule.mkdirSync(pathModule.join(appDir, 'isolated-components', 'test'), {
|
|
1417
1615
|
recursive: true,
|
|
1418
1616
|
});
|
|
1419
|
-
fsModule.writeFileSync(pathModule.join(appDir, '
|
|
1617
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'isolated-components', 'test', 'page.tsx'), '');
|
|
1420
1618
|
const result = scanPageFilePaths(tempDir);
|
|
1421
1619
|
expect(result).toEqual({});
|
|
1422
1620
|
});
|
|
@@ -1424,6 +1622,57 @@ describe('entityChangeStatus', () => {
|
|
|
1424
1622
|
const result = scanPageFilePaths(tempDir);
|
|
1425
1623
|
expect(result).toEqual({});
|
|
1426
1624
|
});
|
|
1625
|
+
// ── Expo Router support ──────────────────────────────────────────────
|
|
1626
|
+
it('should find index.tsx as Home page (Expo Router)', () => {
|
|
1627
|
+
const appDir = pathModule.join(tempDir, 'app');
|
|
1628
|
+
fsModule.mkdirSync(appDir, { recursive: true });
|
|
1629
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'index.tsx'), '');
|
|
1630
|
+
const result = scanPageFilePaths(tempDir);
|
|
1631
|
+
expect(result).toEqual({ Home: 'app/index.tsx' });
|
|
1632
|
+
});
|
|
1633
|
+
it('should find named route files as pages (Expo Router)', () => {
|
|
1634
|
+
const appDir = pathModule.join(tempDir, 'app');
|
|
1635
|
+
fsModule.mkdirSync(appDir, { recursive: true });
|
|
1636
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'index.tsx'), '');
|
|
1637
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'add-tea.tsx'), '');
|
|
1638
|
+
fsModule.mkdirSync(pathModule.join(appDir, 'tea'), { recursive: true });
|
|
1639
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'tea', '[id].tsx'), '');
|
|
1640
|
+
const result = scanPageFilePaths(tempDir);
|
|
1641
|
+
expect(result).toEqual({
|
|
1642
|
+
Home: 'app/index.tsx',
|
|
1643
|
+
'Add-tea': 'app/add-tea.tsx',
|
|
1644
|
+
Tea: 'app/tea/[id].tsx',
|
|
1645
|
+
});
|
|
1646
|
+
});
|
|
1647
|
+
it('should skip _layout.tsx files (Expo Router)', () => {
|
|
1648
|
+
const appDir = pathModule.join(tempDir, 'app');
|
|
1649
|
+
fsModule.mkdirSync(appDir, { recursive: true });
|
|
1650
|
+
fsModule.writeFileSync(pathModule.join(appDir, '_layout.tsx'), '');
|
|
1651
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'index.tsx'), '');
|
|
1652
|
+
const result = scanPageFilePaths(tempDir);
|
|
1653
|
+
expect(result).toEqual({ Home: 'app/index.tsx' });
|
|
1654
|
+
});
|
|
1655
|
+
it('should handle route groups like (tabs) transparently (Expo Router)', () => {
|
|
1656
|
+
const appDir = pathModule.join(tempDir, 'app');
|
|
1657
|
+
const tabsDir = pathModule.join(appDir, '(tabs)');
|
|
1658
|
+
fsModule.mkdirSync(tabsDir, { recursive: true });
|
|
1659
|
+
fsModule.writeFileSync(pathModule.join(tabsDir, '_layout.tsx'), '');
|
|
1660
|
+
fsModule.writeFileSync(pathModule.join(tabsDir, 'index.tsx'), '');
|
|
1661
|
+
fsModule.writeFileSync(pathModule.join(tabsDir, 'settings.tsx'), '');
|
|
1662
|
+
const result = scanPageFilePaths(tempDir);
|
|
1663
|
+
expect(result).toEqual({
|
|
1664
|
+
Home: 'app/(tabs)/index.tsx',
|
|
1665
|
+
Settings: 'app/(tabs)/settings.tsx',
|
|
1666
|
+
});
|
|
1667
|
+
});
|
|
1668
|
+
it('should prefer page.tsx over index.tsx when both exist (Next.js priority)', () => {
|
|
1669
|
+
const appDir = pathModule.join(tempDir, 'app');
|
|
1670
|
+
fsModule.mkdirSync(appDir, { recursive: true });
|
|
1671
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'page.tsx'), '');
|
|
1672
|
+
fsModule.writeFileSync(pathModule.join(appDir, 'index.tsx'), '');
|
|
1673
|
+
const result = scanPageFilePaths(tempDir);
|
|
1674
|
+
expect(result).toEqual({ Home: 'app/page.tsx' });
|
|
1675
|
+
});
|
|
1427
1676
|
});
|
|
1428
1677
|
// ── detectFirstFeature ─────────────────────────────────────────────────
|
|
1429
1678
|
describe('detectFirstFeature', () => {
|