@flyingrobots/bijou-tui-app 7.2.0 → 8.0.0-rc.1

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.
Files changed (53) hide show
  1. package/dist/index.d.ts +3 -145
  2. package/dist/index.d.ts.map +1 -1
  3. package/dist/index.js +2 -436
  4. package/dist/index.js.map +1 -1
  5. package/dist/skeleton-chrome.d.ts +8 -0
  6. package/dist/skeleton-chrome.d.ts.map +1 -0
  7. package/dist/skeleton-chrome.js +39 -0
  8. package/dist/skeleton-chrome.js.map +1 -0
  9. package/dist/skeleton-contract.d.ts +6 -0
  10. package/dist/skeleton-contract.d.ts.map +1 -0
  11. package/dist/skeleton-contract.js +2 -0
  12. package/dist/skeleton-contract.js.map +1 -0
  13. package/dist/skeleton-create.d.ts +12 -0
  14. package/dist/skeleton-create.d.ts.map +1 -0
  15. package/dist/skeleton-create.js +84 -0
  16. package/dist/skeleton-create.js.map +1 -0
  17. package/dist/skeleton-drawer.d.ts +6 -0
  18. package/dist/skeleton-drawer.d.ts.map +1 -0
  19. package/dist/skeleton-drawer.js +50 -0
  20. package/dist/skeleton-drawer.js.map +1 -0
  21. package/dist/skeleton-keys.d.ts +4 -0
  22. package/dist/skeleton-keys.d.ts.map +1 -0
  23. package/dist/skeleton-keys.js +35 -0
  24. package/dist/skeleton-keys.js.map +1 -0
  25. package/dist/skeleton-layout.d.ts +6 -0
  26. package/dist/skeleton-layout.d.ts.map +1 -0
  27. package/dist/skeleton-layout.js +54 -0
  28. package/dist/skeleton-layout.js.map +1 -0
  29. package/dist/skeleton-overlays.d.ts +7 -0
  30. package/dist/skeleton-overlays.d.ts.map +1 -0
  31. package/dist/skeleton-overlays.js +78 -0
  32. package/dist/skeleton-overlays.js.map +1 -0
  33. package/dist/skeleton-page-contract.d.ts +28 -0
  34. package/dist/skeleton-page-contract.d.ts.map +1 -0
  35. package/dist/skeleton-page-contract.js +2 -0
  36. package/dist/skeleton-page-contract.js.map +1 -0
  37. package/dist/skeleton-page.d.ts +13 -0
  38. package/dist/skeleton-page.d.ts.map +1 -0
  39. package/dist/skeleton-page.js +73 -0
  40. package/dist/skeleton-page.js.map +1 -0
  41. package/dist/skeleton-state-contract.d.ts +21 -0
  42. package/dist/skeleton-state-contract.d.ts.map +1 -0
  43. package/dist/skeleton-state-contract.js +2 -0
  44. package/dist/skeleton-state-contract.js.map +1 -0
  45. package/dist/skeleton-tab-contract.d.ts +50 -0
  46. package/dist/skeleton-tab-contract.d.ts.map +1 -0
  47. package/dist/skeleton-tab-contract.js +2 -0
  48. package/dist/skeleton-tab-contract.js.map +1 -0
  49. package/dist/skeleton-theme-contract.d.ts +53 -0
  50. package/dist/skeleton-theme-contract.d.ts.map +1 -0
  51. package/dist/skeleton-theme-contract.js +2 -0
  52. package/dist/skeleton-theme-contract.js.map +1 -0
  53. package/package.json +3 -3
@@ -0,0 +1,21 @@
1
+ /** Page model owned by the stock skeleton shell. */
2
+ export interface SkeletonPageModel {
3
+ readonly ready: true;
4
+ readonly drawerOpen: boolean;
5
+ readonly drawerProgress: number;
6
+ readonly quitConfirmOpen: boolean;
7
+ }
8
+ /** Messages used by the skeleton app shell. */
9
+ export type SkeletonMsg = {
10
+ type: 'request-quit';
11
+ } | {
12
+ type: 'confirm-quit';
13
+ } | {
14
+ type: 'cancel-quit';
15
+ } | {
16
+ type: 'toggle-drawer';
17
+ } | {
18
+ type: 'drawer-progress';
19
+ value: number;
20
+ };
21
+ //# sourceMappingURL=skeleton-state-contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-state-contract.d.ts","sourceRoot":"","sources":["../src/skeleton-state-contract.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC;IACrB,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;IAC7B,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,eAAe,EAAE,OAAO,CAAC;CACnC;AAED,+CAA+C;AAC/C,MAAM,MAAM,WAAW,GACnB;IAAE,IAAI,EAAE,cAAc,CAAA;CAAE,GACxB;IAAE,IAAI,EAAE,cAAc,CAAA;CAAE,GACxB;IAAE,IAAI,EAAE,aAAa,CAAA;CAAE,GACvB;IAAE,IAAI,EAAE,eAAe,CAAA;CAAE,GACzB;IAAE,IAAI,EAAE,iBAAiB,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=skeleton-state-contract.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-state-contract.js","sourceRoot":"","sources":["../src/skeleton-state-contract.ts"],"names":[],"mappings":""}
@@ -0,0 +1,50 @@
1
+ import type { BijouContext } from '@flyingrobots/bijou';
2
+ import type { FrameLayoutNode, ViewOutput } from '@flyingrobots/bijou-tui';
3
+ import type { SkeletonPageModel } from './skeleton-state-contract.js';
4
+ /** Context passed to consumer-provided skeleton page renderers. */
5
+ export interface SkeletonRenderContext {
6
+ /** Bijou context used by the skeleton shell. */
7
+ readonly ctx: BijouContext;
8
+ /** Tab being rendered. */
9
+ readonly tab: SkeletonTab;
10
+ /** Current skeleton-owned page model. */
11
+ readonly model: SkeletonPageModel;
12
+ }
13
+ /** Context passed to consumer-provided skeleton layout factories. */
14
+ export interface SkeletonLayoutContext {
15
+ /** Bijou context used by the skeleton shell. */
16
+ readonly ctx: BijouContext;
17
+ /** Tab being rendered. */
18
+ readonly tab: SkeletonTab;
19
+ /** Current skeleton-owned page model. */
20
+ readonly model: SkeletonPageModel;
21
+ }
22
+ /** Single top-level tab in the app skeleton. */
23
+ export interface SkeletonTab {
24
+ /** Stable tab id. */
25
+ readonly id: string;
26
+ /** Visible tab label. */
27
+ readonly title: string;
28
+ /**
29
+ * Optional pane renderer for this tab.
30
+ *
31
+ * Use this when the page body is a single pane. Return a `Surface` or
32
+ * `LayoutNode`; strings are intentionally not accepted by the framed-app
33
+ * render seam.
34
+ */
35
+ readonly render?: (width: number, height: number, context: SkeletonRenderContext) => ViewOutput;
36
+ /**
37
+ * Optional full frame layout factory for this tab.
38
+ *
39
+ * Use this when the page owns splits, grids, or custom pane topology.
40
+ */
41
+ readonly layout?: (context: SkeletonLayoutContext) => FrameLayoutNode;
42
+ }
43
+ /** Resolved active-tab metadata for dynamic status rendering. */
44
+ export interface SkeletonStatusContext {
45
+ /** Active tab id. */
46
+ readonly activeTabId: string;
47
+ /** Active tab title. */
48
+ readonly activeTabTitle: string;
49
+ }
50
+ //# sourceMappingURL=skeleton-tab-contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-tab-contract.d.ts","sourceRoot":"","sources":["../src/skeleton-tab-contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,KAAK,EACV,eAAe,EACf,UAAU,EACX,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAEtE,mEAAmE;AACnE,MAAM,WAAW,qBAAqB;IACpC,gDAAgD;IAChD,QAAQ,CAAC,GAAG,EAAE,YAAY,CAAC;IAC3B,0BAA0B;IAC1B,QAAQ,CAAC,GAAG,EAAE,WAAW,CAAC;IAC1B,yCAAyC;IACzC,QAAQ,CAAC,KAAK,EAAE,iBAAiB,CAAC;CACnC;AAED,qEAAqE;AACrE,MAAM,WAAW,qBAAqB;IACpC,gDAAgD;IAChD,QAAQ,CAAC,GAAG,EAAE,YAAY,CAAC;IAC3B,0BAA0B;IAC1B,QAAQ,CAAC,GAAG,EAAE,WAAW,CAAC;IAC1B,yCAAyC;IACzC,QAAQ,CAAC,KAAK,EAAE,iBAAiB,CAAC;CACnC;AAED,gDAAgD;AAChD,MAAM,WAAW,WAAW;IAC1B,qBAAqB;IACrB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,yBAAyB;IACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB;;;;;;OAMG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,CAChB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,qBAAqB,KAC3B,UAAU,CAAC;IAChB;;;;OAIG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,qBAAqB,KAAK,eAAe,CAAC;CACvE;AAED,iEAAiE;AACjE,MAAM,WAAW,qBAAqB;IACpC,qBAAqB;IACrB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,wBAAwB;IACxB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;CACjC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=skeleton-tab-contract.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-tab-contract.js","sourceRoot":"","sources":["../src/skeleton-tab-contract.ts"],"names":[],"mappings":""}
@@ -0,0 +1,53 @@
1
+ import type { BijouContext, TokenValue } from '@flyingrobots/bijou';
2
+ import type { KeyMap } from '@flyingrobots/bijou-tui';
3
+ import type { SkeletonMsg } from './skeleton-state-contract.js';
4
+ import type { SkeletonStatusContext, SkeletonTab } from './skeleton-tab-contract.js';
5
+ /** Optional token overrides for shell chrome regions. */
6
+ export interface SkeletonThemeTokens {
7
+ /** Header background token for non-tab space. */
8
+ readonly headerBgToken?: TokenValue;
9
+ /** Active tab token. */
10
+ readonly activeTabToken?: TokenValue;
11
+ /** Inactive tab token. */
12
+ readonly inactiveTabToken?: TokenValue;
13
+ /** Footer status-line token. */
14
+ readonly footerStatusToken?: TokenValue;
15
+ /** Footer controls-line token. */
16
+ readonly footerControlsToken?: TokenValue;
17
+ /** Separator row token. */
18
+ readonly separatorToken?: TokenValue;
19
+ /** Drawer border token. */
20
+ readonly drawerBorderToken?: TokenValue;
21
+ /** Drawer background token. */
22
+ readonly drawerBgToken?: TokenValue;
23
+ /** Quit modal border token. */
24
+ readonly modalBorderToken?: TokenValue;
25
+ /** Quit modal background token. */
26
+ readonly modalBgToken?: TokenValue;
27
+ }
28
+ /**
29
+ * Options for creating a batteries-included design-system shell starter.
30
+ *
31
+ * The scaffold is intentionally opinionated: tabs model peer destinations, the
32
+ * drawer models supplemental work, the modal confirms quit, and footer rows
33
+ * carry shell status and shortcut chrome.
34
+ */
35
+ export interface CreateTuiAppSkeletonOptions {
36
+ /** Bijou context for theme and style rendering. */
37
+ readonly ctx: BijouContext;
38
+ /** App title shown in the header line below tabs. */
39
+ readonly title?: string;
40
+ /** Tabs shown on the top row. Defaults to drawer and split pages. */
41
+ readonly tabs?: readonly SkeletonTab[];
42
+ /** Default tab id. Falls back to the first tab. */
43
+ readonly defaultTabId?: string;
44
+ /** Footer key legend for the controls row. */
45
+ readonly keyLegend?: string;
46
+ /** Footer status message, static or derived from the active tab. */
47
+ readonly statusMessage?: string | ((ctx: SkeletonStatusContext) => string);
48
+ /** Optional shell token overrides. */
49
+ readonly themeTokens?: SkeletonThemeTokens;
50
+ /** Extra global key bindings merged into skeleton defaults. */
51
+ readonly globalKeys?: KeyMap<SkeletonMsg>;
52
+ }
53
+ //# sourceMappingURL=skeleton-theme-contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-theme-contract.d.ts","sourceRoot":"","sources":["../src/skeleton-theme-contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,YAAY,EACZ,UAAU,EACX,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,KAAK,EACV,qBAAqB,EACrB,WAAW,EACZ,MAAM,4BAA4B,CAAC;AAEpC,yDAAyD;AACzD,MAAM,WAAW,mBAAmB;IAClC,iDAAiD;IACjD,QAAQ,CAAC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,CAAC,EAAE,MAAM,CAAC,WAAW,CAAC,CAAC;CAC3C"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=skeleton-theme-contract.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skeleton-theme-contract.js","sourceRoot":"","sources":["../src/skeleton-theme-contract.ts"],"names":[],"mappings":""}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flyingrobots/bijou-tui-app",
3
- "version": "7.2.0",
3
+ "version": "8.0.0-rc.1",
4
4
  "description": "Batteries-included TUI app skeleton built on bijou-tui createFramedApp().",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -24,8 +24,8 @@
24
24
  "lint": "tsc --noEmit"
25
25
  },
26
26
  "dependencies": {
27
- "@flyingrobots/bijou": "7.2.0",
28
- "@flyingrobots/bijou-tui": "7.2.0"
27
+ "@flyingrobots/bijou": "8.0.0-rc.1",
28
+ "@flyingrobots/bijou-tui": "8.0.0-rc.1"
29
29
  },
30
30
  "devDependencies": {
31
31
  "@types/node": "^22.0.0",