354 lines
11 KiB
JSON
354 lines
11 KiB
JSON
|
|
{
|
||
|
|
"schemaVersion": "1.0.0",
|
||
|
|
"project": {
|
||
|
|
"name": "blb-throne-of-the-bone-king",
|
||
|
|
"displayName": "Bone Lord Bob — Throne of the Bone King",
|
||
|
|
"purpose": "Cross-platform game shell with shared React Native UI across mobile, web, and desktop.",
|
||
|
|
"root": ".",
|
||
|
|
"model": "single-repo",
|
||
|
|
"repo": {
|
||
|
|
"gitea": "http://100.79.253.19:3000/jacob-mathison/blb-throne-of-the-bone-king",
|
||
|
|
"slug": "jacob-mathison/blb-throne-of-the-bone-king",
|
||
|
|
"defaultBranch": "main"
|
||
|
|
},
|
||
|
|
"universe": "Bone Lord Bob (BLB) — Mathison Projects Inc.",
|
||
|
|
"status": "early-development",
|
||
|
|
"summary": "Menu shell with home navigation, settings (resolution/volume/autosave), policies, toolkit pages, and Zustand-persisted state. Primary iteration targets are web (Vite) and Electron; mobile targets share the same src/ UI layer."
|
||
|
|
},
|
||
|
|
"principles": [
|
||
|
|
"Start with llm.txt for human-readable orientation.",
|
||
|
|
"Use manifest.llm.json for machine-readable routing, commands, targets, and known gaps.",
|
||
|
|
"Shared UI under src/ is React Native — not raw HTML.",
|
||
|
|
"Do not use DOM APIs in shared src/ code; platform shims belong in .web.ts files or src/web/.",
|
||
|
|
"Metro bundles mobile; Vite bundles web/Electron renderer — they are not interchangeable.",
|
||
|
|
"Navigation is Zustand-based; do not add React Navigation unless explicitly requested.",
|
||
|
|
"Persistence is platform-split via persistStorage.ts (mobile) and persistStorage.web.ts (web/Electron).",
|
||
|
|
"Treat knownGaps in this manifest as the canonical repository-wide gap list.",
|
||
|
|
"Commit as Jacob Mathison (jacob@mathisonprojects.com); never commit as an AI identity."
|
||
|
|
],
|
||
|
|
"guideFiles": [
|
||
|
|
{
|
||
|
|
"path": "llm.txt",
|
||
|
|
"type": "root-orientation",
|
||
|
|
"purpose": "First-read guide for project shape, stack, architecture, commands, conventions, and LLM notes.",
|
||
|
|
"alwaysRead": true
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"path": "manifest.llm.json",
|
||
|
|
"type": "machine-manifest",
|
||
|
|
"purpose": "Machine-readable routing manifest: targets, commands, task routes, known gaps, and verification baseline.",
|
||
|
|
"alwaysRead": true
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"path": "AGENTS.md",
|
||
|
|
"type": "agent-instructions",
|
||
|
|
"purpose": "Operational instructions for coding agents: ground rules, structure conventions, and common tasks.",
|
||
|
|
"alwaysRead": true
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"globalReadOrder": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"AGENTS.md"
|
||
|
|
],
|
||
|
|
"globalReadOrderSemantics": "Broad orientation order. Task routers should prefer taskRoutes read arrays to avoid over-reading.",
|
||
|
|
"documentationFiles": [
|
||
|
|
{
|
||
|
|
"path": "llm.txt",
|
||
|
|
"type": "root-orientation",
|
||
|
|
"purpose": "Human-readable first-read guide."
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"path": "manifest.llm.json",
|
||
|
|
"type": "machine-manifest",
|
||
|
|
"purpose": "Machine-readable project manifest."
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"path": "AGENTS.md",
|
||
|
|
"type": "agent-instructions",
|
||
|
|
"purpose": "Agent operating instructions."
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"path": "README.md",
|
||
|
|
"type": "human-overview",
|
||
|
|
"purpose": "Human-facing overview (currently default React Native template; stale relative to web/Electron targets)."
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"targets": [
|
||
|
|
{
|
||
|
|
"id": "web",
|
||
|
|
"label": "Web",
|
||
|
|
"runtime": "react-native-web in browser",
|
||
|
|
"bundler": "Vite",
|
||
|
|
"entry": "index.html → src/web/main.tsx → App.tsx",
|
||
|
|
"devCommand": "npm run web",
|
||
|
|
"devUrl": "http://127.0.0.1:5173",
|
||
|
|
"primary": true
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"id": "electron",
|
||
|
|
"label": "Desktop",
|
||
|
|
"runtime": "Electron (Chromium renderer)",
|
||
|
|
"bundler": "Vite (renderer) + tsc (main)",
|
||
|
|
"entry": "electron/main.ts loads Vite dev server or dist/renderer/",
|
||
|
|
"devCommand": "npm run electron:dev",
|
||
|
|
"primary": true
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"id": "android",
|
||
|
|
"label": "Android",
|
||
|
|
"runtime": "React Native",
|
||
|
|
"bundler": "Metro",
|
||
|
|
"entry": "index.js → App.tsx",
|
||
|
|
"devCommand": "npm run android"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"id": "ios",
|
||
|
|
"label": "iOS",
|
||
|
|
"runtime": "React Native",
|
||
|
|
"bundler": "Metro",
|
||
|
|
"entry": "index.js → App.tsx",
|
||
|
|
"devCommand": "npm run ios"
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"stack": [
|
||
|
|
"React Native 0.85.3",
|
||
|
|
"react-native-web",
|
||
|
|
"React 19.2.3",
|
||
|
|
"TypeScript ^5.8.3",
|
||
|
|
"Zustand ^5.0.14",
|
||
|
|
"Vite ^8",
|
||
|
|
"Electron ^42",
|
||
|
|
"socket.io / socket.io-client ^4.8 (declared, not wired)",
|
||
|
|
"Jest",
|
||
|
|
"ESLint + Prettier",
|
||
|
|
"Node >= 22.12.0"
|
||
|
|
],
|
||
|
|
"architecture": {
|
||
|
|
"rootComponent": "App.tsx",
|
||
|
|
"componentTree": [
|
||
|
|
"SafeAreaProvider",
|
||
|
|
"GameViewport",
|
||
|
|
"AppNavigator"
|
||
|
|
],
|
||
|
|
"navigation": {
|
||
|
|
"type": "zustand-store",
|
||
|
|
"routes": "src/navigation/routes.ts",
|
||
|
|
"navigator": "src/navigation/AppNavigator.tsx",
|
||
|
|
"store": "src/state/navigationStore.ts"
|
||
|
|
},
|
||
|
|
"state": {
|
||
|
|
"library": "zustand",
|
||
|
|
"stores": [
|
||
|
|
{
|
||
|
|
"file": "src/state/navigationStore.ts",
|
||
|
|
"persistKey": "blb-navigation"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"file": "src/state/gameSettingsStore.ts",
|
||
|
|
"persistKey": "blb-game-settings"
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"persistHelper": "src/state/createPersistOptions.ts",
|
||
|
|
"platformStorage": {
|
||
|
|
"mobile": "src/state/persistStorage.ts",
|
||
|
|
"web": "src/state/persistStorage.web.ts"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"settings": "src/settings/gameSettings.ts",
|
||
|
|
"screens": [
|
||
|
|
"src/screens/HomeScreen.tsx",
|
||
|
|
"src/screens/SettingsScreen.tsx",
|
||
|
|
"src/screens/PoliciesScreen.tsx",
|
||
|
|
"src/screens/ToolkitScreen.tsx",
|
||
|
|
"src/screens/PageScreen.tsx"
|
||
|
|
],
|
||
|
|
"components": [
|
||
|
|
"src/components/GameViewport.tsx",
|
||
|
|
"src/components/ScreenLayout.tsx",
|
||
|
|
"src/components/MenuButton.tsx",
|
||
|
|
"src/components/BackHomeButton.tsx"
|
||
|
|
],
|
||
|
|
"webEntry": "src/web/main.tsx",
|
||
|
|
"electronMain": "electron/main.ts",
|
||
|
|
"electronPreload": "electron/preload.ts",
|
||
|
|
"buildOutputs": [
|
||
|
|
"dist/renderer/",
|
||
|
|
"dist/electron/"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"taskRoutes": {
|
||
|
|
"ui-screen": {
|
||
|
|
"description": "Add or modify screens, navigation routes, or shared UI components.",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"AGENTS.md",
|
||
|
|
"src/navigation/routes.ts",
|
||
|
|
"src/navigation/AppNavigator.tsx",
|
||
|
|
"<target screen or component>"
|
||
|
|
],
|
||
|
|
"update": [
|
||
|
|
"src/navigation/routes.ts when adding a route",
|
||
|
|
"src/navigation/AppNavigator.tsx when wiring a route",
|
||
|
|
"manifest.llm.json when screens, routes, or architecture sections change"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"state": {
|
||
|
|
"description": "Zustand stores, persistence, or game settings.",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"src/state/",
|
||
|
|
"src/settings/gameSettings.ts",
|
||
|
|
"src/state/persistStorage.ts",
|
||
|
|
"src/state/persistStorage.web.ts"
|
||
|
|
],
|
||
|
|
"policies": [
|
||
|
|
"Extend persistStorage.ts / persistStorage.web.ts for platform storage changes.",
|
||
|
|
"Do not embed DOM or AsyncStorage calls directly in stores."
|
||
|
|
],
|
||
|
|
"update": [
|
||
|
|
"manifest.llm.json when stores, persist keys, or settings surface change"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"web-electron": {
|
||
|
|
"description": "Vite config, web entry, Electron shell, or platform-specific .web.ts overrides.",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"vite.config.ts",
|
||
|
|
"index.html",
|
||
|
|
"src/web/",
|
||
|
|
"electron/",
|
||
|
|
"tsconfig.electron.json"
|
||
|
|
],
|
||
|
|
"policies": [
|
||
|
|
"DOM APIs are allowed in src/web/ and .web.ts shims only.",
|
||
|
|
"Electron main/preload compile to dist/electron/."
|
||
|
|
],
|
||
|
|
"update": [
|
||
|
|
"manifest.llm.json when targets, build outputs, or dev commands change"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"mobile": {
|
||
|
|
"description": "React Native mobile target changes (Metro, native deps).",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"AGENTS.md",
|
||
|
|
"metro.config.js",
|
||
|
|
"index.js",
|
||
|
|
"App.tsx"
|
||
|
|
],
|
||
|
|
"policies": [
|
||
|
|
"Do not modify android/ or ios/ native files unless explicitly requested.",
|
||
|
|
"Run pod install inside ios/ after native dependency changes."
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"testing": {
|
||
|
|
"description": "Jest tests for logic, stores, routes, or screen scaffolding.",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"<target source>",
|
||
|
|
"<related __tests__ file>"
|
||
|
|
],
|
||
|
|
"verify": [
|
||
|
|
"npm run test"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"realtime": {
|
||
|
|
"description": "Socket.io server/client wiring (planned; not yet implemented).",
|
||
|
|
"read": [
|
||
|
|
"llm.txt",
|
||
|
|
"manifest.llm.json",
|
||
|
|
"socket/",
|
||
|
|
"package.json"
|
||
|
|
],
|
||
|
|
"policies": [
|
||
|
|
"socket/ is currently a stub — confirm scope before implementing."
|
||
|
|
]
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"rootCommands": [
|
||
|
|
{
|
||
|
|
"command": "npm run web",
|
||
|
|
"purpose": "Vite dev server for browser iteration.",
|
||
|
|
"target": "web"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run web:build",
|
||
|
|
"purpose": "Production web build to dist/renderer/.",
|
||
|
|
"target": "web"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run web:preview",
|
||
|
|
"purpose": "Preview production web build.",
|
||
|
|
"target": "web"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run electron:dev",
|
||
|
|
"purpose": "Run Vite dev server and Electron concurrently.",
|
||
|
|
"target": "electron"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run electron:build",
|
||
|
|
"purpose": "Build renderer and compile Electron main process.",
|
||
|
|
"target": "electron"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run electron:package",
|
||
|
|
"purpose": "Build and package desktop installer via electron-builder.",
|
||
|
|
"target": "electron"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run start",
|
||
|
|
"purpose": "Start Metro bundler.",
|
||
|
|
"target": "android"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run android",
|
||
|
|
"purpose": "Run on Android emulator or device.",
|
||
|
|
"target": "android"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run ios",
|
||
|
|
"purpose": "Run on iOS simulator or device.",
|
||
|
|
"target": "ios"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run lint",
|
||
|
|
"purpose": "ESLint."
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"command": "npm run test",
|
||
|
|
"purpose": "Jest test suite."
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"knownGaps": [
|
||
|
|
"socket/ is a stub — socket.io and socket.io-client are installed but no server/client wiring exists.",
|
||
|
|
"docs/ and wiki/ are placeholder README stubs.",
|
||
|
|
"AGENTS.md still describes a mobile-only app and forbids all DOM APIs; it is stale relative to web/Electron targets.",
|
||
|
|
"README.md is the default React Native Community CLI template and does not document web or Electron workflows.",
|
||
|
|
"No JSON Schema validator exists yet for manifest.llm.json."
|
||
|
|
],
|
||
|
|
"verificationBaseline": {
|
||
|
|
"logicOrStoreChanges": [
|
||
|
|
"npm run test"
|
||
|
|
],
|
||
|
|
"uiChanges": [
|
||
|
|
"npm run lint",
|
||
|
|
"npm run test"
|
||
|
|
],
|
||
|
|
"webElectronChanges": [
|
||
|
|
"npm run lint",
|
||
|
|
"npm run test"
|
||
|
|
],
|
||
|
|
"mobileChanges": [
|
||
|
|
"npm run lint",
|
||
|
|
"npm run test"
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|