{"_id":"@bottel/cli-app-scaffold","_rev":"4-434a685033f443b8989908387cbe3f48","name":"@bottel/cli-app-scaffold","dist-tags":{"latest":"0.3.0"},"versions":{"0.1.0":{"name":"@bottel/cli-app-scaffold","version":"0.1.0","keywords":["cli","ink","react","terminal","tui","scaffold","bot","bottel"],"author":{"name":"bottel.ai"},"license":"MIT","_id":"@bottel/cli-app-scaffold@0.1.0","maintainers":[{"name":"bottel_ai","email":"cenconq@icloud.com"}],"homepage":"https://github.com/bottel-ai/bottel.ai","bugs":{"url":"https://github.com/bottel-ai/bottel.ai/issues"},"dist":{"shasum":"b43e2d8a65b9364fa41d64e456b63b15cba87efc","tarball":"https://registry.npmjs.org/@bottel/cli-app-scaffold/-/cli-app-scaffold-0.1.0.tgz","fileCount":15,"integrity":"sha512-lbsWT937M/8T58hy4UDHa6a87Oi1jdrPNvw7lLp0Tovxixk09ShHS5Ndu974HQMml3DB4iO1hRabjBHpocqJ9g==","signatures":[{"sig":"MEUCIQCUW542HcNVBxZMrQZ+vpSweMQ89xWY259bTryR7w2++wIgToLI5SiX/4Ady4gWshgOVFdEcZM3tJdsY92oZY2dz4E=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":33388},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./theme":{"types":"./dist/theme.d.ts","import":"./dist/theme.js"},"./engine":{"types":"./dist/engine.d.ts","import":"./dist/engine.js"},"./components":{"types":"./dist/components.d.ts","import":"./dist/components.js"}},"gitHead":"63e7acae82462478fa7b73eaa65ff631f0f312ce","scripts":{"build":"tsc","prepublishOnly":"npm run build"},"_npmUser":{"name":"bottel_ai","email":"cenconq@icloud.com"},"repository":{"url":"git+https://github.com/bottel-ai/bottel.ai.git","type":"git","directory":"packages/cli-app-scaffold"},"_npmVersion":"10.9.7","description":"Generic CLI app scaffold — engine, theme, and components for building bot-native CLI apps with ink (React for terminal)","directories":{},"_nodeVersion":"22.22.2","_hasShrinkwrap":false,"devDependencies":{"ink":"^6.0.0","react":"^19.0.0","typescript":"^5.4.0","@types/react":"^18.3.0","ink-text-input":"^6.0.0"},"peerDependencies":{"ink":">=5.0.0","react":">=18.0.0","ink-text-input":">=6.0.0"},"_npmOperationalInternal":{"tmp":"tmp/cli-app-scaffold_0.1.0_1775633120625_0.6289086782603028","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Deprecated — Ink TUI scaffold, no longer maintained."},"0.2.0":{"name":"@bottel/cli-app-scaffold","version":"0.2.0","keywords":["cli","ink","react","terminal","tui","scaffold","bot","bottel"],"author":{"name":"bottel.ai"},"license":"MIT","_id":"@bottel/cli-app-scaffold@0.2.0","maintainers":[{"name":"bottel_ai","email":"cenconq@icloud.com"}],"homepage":"https://github.com/bottel-ai/bottel.ai","bugs":{"url":"https://github.com/bottel-ai/bottel.ai/issues"},"dist":{"shasum":"af65cd905496bb32d5ed5af05dbae99ba711f3f2","tarball":"https://registry.npmjs.org/@bottel/cli-app-scaffold/-/cli-app-scaffold-0.2.0.tgz","fileCount":18,"integrity":"sha512-dKpqWwVexXi+RBslJZmpj0oezG8LI2bnUZC5I0fCxCcsGpNz3VkXw7HS7/omR+mec7QrLxkLDHixL171GmMbsw==","signatures":[{"sig":"MEUCIQDFd3iovl2yoJI+BR8nsiZ8QmOiFAjRFVmBq2vPHUmpQwIgVRr1vS+b7uDks8/NfMacYGbAMmPaK/KWGKccdx9sdns=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":41738},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./hooks":{"types":"./dist/hooks.d.ts","import":"./dist/hooks.js"},"./theme":{"types":"./dist/theme.d.ts","import":"./dist/theme.js"},"./engine":{"types":"./dist/engine.d.ts","import":"./dist/engine.js"},"./components":{"types":"./dist/components.d.ts","import":"./dist/components.js"}},"gitHead":"8d9af97f3b27be0a90f581af2fc668a8d2d1f76e","scripts":{"build":"tsc","prepublishOnly":"npm run build"},"_npmUser":{"name":"bottel_ai","email":"cenconq@icloud.com"},"repository":{"url":"git+https://github.com/bottel-ai/bottel.ai.git","type":"git","directory":"packages/cli-app-scaffold"},"_npmVersion":"10.9.7","description":"Generic CLI app scaffold — engine, theme, and components for building bot-native CLI apps with ink (React for terminal)","directories":{},"_nodeVersion":"22.22.2","_hasShrinkwrap":false,"devDependencies":{"ink":"^6.0.0","react":"^19.0.0","typescript":"^5.4.0","@types/react":"^18.3.0","ink-text-input":"^6.0.0"},"peerDependencies":{"ink":">=5.0.0","react":">=18.0.0","ink-text-input":">=6.0.0"},"_npmOperationalInternal":{"tmp":"tmp/cli-app-scaffold_0.2.0_1775645978565_0.7945815358791142","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Deprecated — Ink TUI scaffold, no longer maintained."},"0.3.0":{"name":"@bottel/cli-app-scaffold","version":"0.3.0","keywords":["cli","ink","react","terminal","tui","scaffold","bot","bottel"],"author":{"name":"bottel.ai"},"license":"MIT","_id":"@bottel/cli-app-scaffold@0.3.0","maintainers":[{"name":"bottel_ai","email":"cenconq@icloud.com"}],"homepage":"https://github.com/bottel-ai/bottel.ai","bugs":{"url":"https://github.com/bottel-ai/bottel.ai/issues"},"dist":{"shasum":"e84bb79dd15219cb86861b7775d0d019ece26b4f","tarball":"https://registry.npmjs.org/@bottel/cli-app-scaffold/-/cli-app-scaffold-0.3.0.tgz","fileCount":22,"integrity":"sha512-C1vUCJc+S/TSFAwykSAqwVSo5VqRKHWVLWUGDef7i2snp3cBQXLRHZcRBZSXF+IXOU4C7+HU0uHT0tNHx0MSbQ==","signatures":[{"sig":"MEUCIQDYNLk1tYe0Jum2ttDo5hpAqtuLAFIyjbkA6SWcup7GzAIgcR14/XrNqfISJpq/j0lVR81OV16/z3hysQQk7w68Sks=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":65497},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./hooks":{"types":"./dist/hooks.d.ts","import":"./dist/hooks.js"},"./theme":{"types":"./dist/theme.d.ts","import":"./dist/theme.js"},"./engine":{"types":"./dist/engine.d.ts","import":"./dist/engine.js"},"./identity":{"types":"./dist/identity.d.ts","import":"./dist/identity.js"},"./components":{"types":"./dist/components.d.ts","import":"./dist/components.js"}},"gitHead":"e32feed4f53184484204e8a356e1bb88547d4f50","scripts":{"build":"tsc","prepublishOnly":"npm run build"},"_npmUser":{"name":"bottel_ai","email":"cenconq@icloud.com"},"repository":{"url":"git+https://github.com/bottel-ai/bottel.ai.git","type":"git","directory":"packages/cli-app-scaffold"},"_npmVersion":"10.9.7","description":"Generic CLI app scaffold — engine, theme, components, hooks, and shared bot identity for building bot-native CLI apps with ink (React for terminal)","directories":{},"_nodeVersion":"22.22.2","dependencies":{"conf":"^15.1.0"},"_hasShrinkwrap":false,"devDependencies":{"ink":"^6.0.0","react":"^19.0.0","typescript":"^5.4.0","@types/react":"^18.3.0","ink-text-input":"^6.0.0"},"peerDependencies":{"ink":">=5.0.0","react":">=18.0.0","ink-text-input":">=6.0.0"},"_npmOperationalInternal":{"tmp":"tmp/cli-app-scaffold_0.3.0_1775648419691_0.07021326722567589","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Deprecated — Ink TUI scaffold, no longer maintained."}},"time":{"created":"2026-04-08T07:25:20.503Z","modified":"2026-04-15T13:22:06.795Z","0.1.0":"2026-04-08T07:25:20.771Z","0.2.0":"2026-04-08T10:59:38.742Z","0.3.0":"2026-04-08T11:40:19.843Z"},"bugs":{"url":"https://github.com/bottel-ai/bottel.ai/issues"},"author":{"name":"bottel.ai"},"license":"MIT","homepage":"https://github.com/bottel-ai/bottel.ai","keywords":["cli","ink","react","terminal","tui","scaffold","bot","bottel"],"repository":{"url":"git+https://github.com/bottel-ai/bottel.ai.git","type":"git","directory":"packages/cli-app-scaffold"},"description":"Generic CLI app scaffold — engine, theme, components, hooks, and shared bot identity for building bot-native CLI apps with ink (React for terminal)","maintainers":[{"name":"bottel_ai","email":"cenconq@icloud.com"}],"readme":"# @bottel/cli-app-scaffold\n\nGeneric CLI app scaffold — the engine, theme, and components used to build [bottel.ai](https://bottel.ai) and its bundled apps.\n\nA reusable foundation for building bot-native CLI apps with [ink](https://github.com/vadimdemedes/ink) (React for terminal).\n\n## Install\n\n```bash\nnpm install @bottel/cli-app-scaffold ink ink-text-input react\n```\n\n`ink`, `react`, and `ink-text-input` are peer dependencies — install them in your app.\n\n## What's inside\n\n- **Engine** — generic state factory with browser-like history stack\n- **Theme** — colors, box styles, formatters\n- **Components** — Breadcrumb, Cursor, HelpFooter, Autocomplete, Dialog, Separator, ScreenHeader\n\n## Quick start\n\n```typescript\nimport { createStore } from '@bottel/cli-app-scaffold';\nimport { colors, Breadcrumb, HelpFooter } from '@bottel/cli-app-scaffold';\n\n// Define your screens\ntype Screen =\n  | { name: 'home' }\n  | { name: 'detail'; id: string };\n\ninterface ScreenStates {\n  home: { selectedIndex: number };\n  detail: { tab: number };\n  [key: string]: Record<string, unknown>;\n}\n\nconst initialStates: ScreenStates = {\n  home: { selectedIndex: 0 },\n  detail: { tab: 0 },\n};\n\nconst { StoreProvider, useStore } = createStore<Screen, ScreenStates>(\n  { name: 'home' },\n  initialStates,\n);\n```\n\nIn your screens:\n\n```typescript\nfunction Home() {\n  const { screen, screenStates, navigate, goBack, updateScreenState } = useStore();\n  const { selectedIndex } = screenStates.home;\n\n  return (\n    <Box flexDirection=\"column\">\n      <Breadcrumb path={['Home']} />\n      {/* ...your UI... */}\n      <HelpFooter text=\"↑↓ nav · Enter select · Esc back\" />\n    </Box>\n  );\n}\n```\n\n## Subpath imports\n\nPick what you need:\n\n```typescript\nimport { colors, boxStyle } from '@bottel/cli-app-scaffold/theme';\nimport { Breadcrumb, Cursor, Dialog } from '@bottel/cli-app-scaffold/components';\nimport { createStore } from '@bottel/cli-app-scaffold/engine';\n```\n\n## API\n\n### `createStore<Screen, ScreenStates>(initialScreen, initialScreenStates)`\n\nReturns `{ StoreProvider, useStore }`.\n\n`useStore()` returns:\n- `screen` — current screen\n- `screenStates` — all per-screen state\n- `dispatch` — raw reducer dispatch\n- `navigate(screen)` — push to history, reset target screen state\n- `goBack()` — pop history, preserve all state\n- `goHome()` — clear history, return to initial screen\n- `updateScreenState(name, partial)` — merge update into a screen's state\n\n### Components\n\n- `<Breadcrumb path={['Home', 'Section', 'Page']} />`\n- `<Cursor active={true} />`\n- `<HelpFooter text=\"key hints\" />`\n- `<Separator />`\n- `<ScreenHeader title=\"Page Title\" />`\n- `<Autocomplete value onChange onSelect suggestions />`\n- `<Dialog title visible onClose>...children...</Dialog>`\n\n### Theme\n\n- `colors.{primary, secondary, accent, success, warning, error, border, dimBorder}`\n- `boxStyle.{header, section}`\n\n## License\n\nMIT\n","readmeFilename":"README.md"}