@softov/scena 0.1.2 → 0.1.3

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 (276) hide show
  1. package/dist/core/builtins.d.ts +3 -0
  2. package/dist/{runtime → core}/builtins.js +1 -1
  3. package/dist/core/controls/command.d.ts +18 -0
  4. package/dist/{controls → core/controls}/command.js +2 -2
  5. package/dist/{controls → core/controls}/events.d.ts +1 -1
  6. package/dist/{controls → core/controls}/events.js +1 -1
  7. package/dist/core/controls/keybinding.d.ts +9 -0
  8. package/dist/{controls → core/controls}/keybinding.js +1 -1
  9. package/dist/core/controls/layout.d.ts +31 -0
  10. package/dist/{controls → core/controls}/layout.js +24 -7
  11. package/dist/core/controls/manifest.d.ts +21 -0
  12. package/dist/{controls → core/controls}/manifest.js +2 -2
  13. package/dist/core/controls/session.d.ts +16 -0
  14. package/dist/{controls → core/controls}/session.js +5 -13
  15. package/dist/{controls → core/controls}/shell.d.ts +2 -2
  16. package/dist/{controls → core/controls}/shell.js +1 -1
  17. package/dist/{controls → core/controls}/storage/layout-local.d.ts +1 -1
  18. package/dist/{controls → core/controls}/storage/session-local.d.ts +1 -1
  19. package/dist/{controls → core/controls}/when.d.ts +2 -2
  20. package/dist/{controls → core/controls}/when.js +1 -1
  21. package/dist/{converters → core/converters}/a2ui-v0.10.d.ts +1 -1
  22. package/dist/core/{component-graph.d.ts → graph/component-graph.d.ts} +1 -1
  23. package/dist/core/{component-graph.js → graph/component-graph.js} +1 -1
  24. package/dist/core/{mount-menu.d.ts → graph/mount-menu.d.ts} +1 -1
  25. package/dist/core/{mount-menu.js → graph/mount-menu.js} +1 -1
  26. package/dist/core/graph/mount-surface.d.ts +15 -0
  27. package/dist/core/{mount-surface.js → graph/mount-surface.js} +23 -4
  28. package/dist/core/{surface-presentation.d.ts → graph/surface-presentation.d.ts} +3 -3
  29. package/dist/{i18n → core/i18n}/i18n-backend.d.ts +1 -1
  30. package/dist/core/index.d.ts +34 -43
  31. package/dist/core/index.js +35 -38
  32. package/dist/core/{component-registry.d.ts → registry/component-registry.d.ts} +2 -2
  33. package/dist/core/{component-registry.js → registry/component-registry.js} +1 -1
  34. package/dist/core/registry/converter-registry.d.ts +2 -0
  35. package/dist/core/{converter-registry.js → registry/converter-registry.js} +1 -1
  36. package/dist/core/resolve/binding-resolver.d.ts +7 -0
  37. package/dist/core/{binding-resolver.js → resolve/binding-resolver.js} +2 -2
  38. package/dist/core/{dynamic-resolver.d.ts → resolve/dynamic-resolver.d.ts} +2 -2
  39. package/dist/core/{dynamic-resolver.js → resolve/dynamic-resolver.js} +1 -1
  40. package/dist/core/{path-resolver.d.ts → resolve/path-resolver.d.ts} +2 -2
  41. package/dist/core/{permissions.d.ts → resolve/permissions.d.ts} +1 -1
  42. package/dist/core/scena.d.ts +1 -1
  43. package/dist/core/scena.js +17 -16
  44. package/dist/core/{backends → store/backends}/modus-backend.d.ts +1 -1
  45. package/dist/core/{backends → store/backends}/storage-backend.d.ts +1 -1
  46. package/dist/core/{backends → store/backends}/yjs-backend.d.ts +1 -1
  47. package/dist/core/{reactive-store.d.ts → store/reactive-store.d.ts} +4 -4
  48. package/dist/core/{reactive-store.js → store/reactive-store.js} +2 -2
  49. package/dist/index.d.ts +8 -0
  50. package/dist/index.js +13 -0
  51. package/dist/porta/Limen.d.ts +1 -0
  52. package/dist/porta/Limen.js +1 -0
  53. package/dist/porta/PortaLock.d.ts +1 -0
  54. package/dist/porta/PortaLock.js +6 -2
  55. package/dist/porta/SigillumGate.d.ts +1 -0
  56. package/dist/porta/SigillumGate.js +1 -0
  57. package/dist/porta/commands.d.ts +1 -1
  58. package/dist/porta/login-form.block.d.ts +1 -1
  59. package/dist/porta/provider.d.ts +1 -1
  60. package/dist/porta/register-blocks.d.ts +2 -2
  61. package/dist/porta/register-blocks.js +4 -7
  62. package/dist/porta/register.d.ts +1 -1
  63. package/dist/porta/sigillum.d.ts +2 -2
  64. package/dist/react/DefaultShell.d.ts +47 -1
  65. package/dist/react/DefaultShell.js +81 -12
  66. package/dist/react/Scena.d.ts +2 -2
  67. package/dist/react/ScenaProvider.d.ts +1 -1
  68. package/dist/react/ShellSplitter.d.ts +1 -1
  69. package/dist/react/SurfaceArea.d.ts +5 -3
  70. package/dist/react/SurfaceArea.js +2 -2
  71. package/dist/react/ViewMount.d.ts +1 -1
  72. package/dist/react/ViewMount.js +4 -4
  73. package/dist/react/hooks/useI18n.d.ts +1 -1
  74. package/dist/react/hooks/useI18n.js +1 -1
  75. package/dist/react/hooks/useLabel.d.ts +1 -1
  76. package/dist/react/hooks/useLabel.js +1 -1
  77. package/dist/react/hooks/useLayout.d.ts +1 -1
  78. package/dist/react/hooks/useMounts.d.ts +1 -1
  79. package/dist/react/hooks/useStore.d.ts +1 -1
  80. package/dist/react/hooks/useStore.js +2 -2
  81. package/dist/react/hooks/useStoreLabel.d.ts +2 -2
  82. package/dist/react/hooks/useStoreLabel.js +1 -1
  83. package/dist/react/hooks/useSurfacePresentation.d.ts +3 -3
  84. package/dist/react/hooks/useSurfacePresentation.js +1 -1
  85. package/dist/react/mount-context.d.ts +1 -1
  86. package/dist/react/useSurfaceResize.d.ts +2 -2
  87. package/dist/runtime/client-handlers.d.ts +1 -1
  88. package/dist/runtime/in-memory-socket.d.ts +2 -2
  89. package/dist/runtime/index.d.ts +3 -3
  90. package/dist/runtime/index.js +2 -2
  91. package/dist/runtime/layout-commands.d.ts +3 -3
  92. package/dist/runtime/layout-commands.js +2 -2
  93. package/dist/runtime/opener-commands.d.ts +5 -5
  94. package/dist/runtime/opener-commands.js +3 -3
  95. package/dist/runtime/surface-bridge.d.ts +5 -5
  96. package/dist/runtime/surface-bridge.js +1 -1
  97. package/dist/{runtime → sdk}/args-schema.d.ts +1 -1
  98. package/dist/{core → sdk}/disposable.d.ts +3 -1
  99. package/dist/{types → sdk}/index.d.ts +1 -0
  100. package/dist/{types → sdk}/index.js +1 -0
  101. package/dist/{types → sdk}/label.d.ts +1 -0
  102. package/dist/{core → sdk}/label.js +0 -1
  103. package/dist/{types → sdk}/layout.d.ts +25 -0
  104. package/dist/{types → sdk}/mount-surface.d.ts +19 -1
  105. package/dist/{types → sdk}/scena.d.ts +2 -1
  106. package/dist/styles/bar.css +8 -4
  107. package/dist/styles/base.css +18 -16
  108. package/dist/styles/controller.d.ts +27 -0
  109. package/dist/styles/controller.js +74 -0
  110. package/dist/styles/form.css +10 -0
  111. package/dist/styles/index.d.ts +2 -0
  112. package/dist/styles/index.js +3 -0
  113. package/dist/styles/surface.css +69 -3
  114. package/dist/styles/themes/tokens.css +1 -1
  115. package/dist/ui/_utils.d.ts +1 -1
  116. package/dist/ui/_utils.js +2 -2
  117. package/dist/ui/campus/CampusMappa.js +1 -1
  118. package/dist/ui/chart/catalog.d.ts +1 -1
  119. package/dist/ui/control/ButtonBar.css +61 -0
  120. package/dist/ui/control/ButtonBar.d.ts +36 -0
  121. package/dist/ui/control/ButtonBar.js +42 -0
  122. package/dist/ui/control/ThemeModeToggle.css +22 -0
  123. package/dist/ui/control/ThemeModeToggle.d.ts +20 -0
  124. package/dist/ui/control/ThemeModeToggle.js +34 -0
  125. package/dist/ui/control/ThemePicker.css +24 -0
  126. package/dist/ui/control/ThemePicker.d.ts +27 -0
  127. package/dist/ui/control/ThemePicker.js +33 -0
  128. package/dist/ui/control/catalog.d.ts +1 -1
  129. package/dist/ui/control/catalog.js +5 -1
  130. package/dist/ui/control/index.d.ts +6 -0
  131. package/dist/ui/control/index.js +3 -0
  132. package/dist/ui/data/Filter.d.ts +1 -1
  133. package/dist/ui/data/Listable.d.ts +3 -2
  134. package/dist/ui/data/Listable.js +4 -2
  135. package/dist/ui/data/Pagination.d.ts +4 -1
  136. package/dist/ui/data/Pagination.js +37 -9
  137. package/dist/ui/data/Tree.d.ts +2 -2
  138. package/dist/ui/data/Tree.js +1 -1
  139. package/dist/ui/data/catalog.d.ts +1 -1
  140. package/dist/ui/display/Alert.css +15 -10
  141. package/dist/ui/display/Badge.css +22 -14
  142. package/dist/ui/display/Badge.d.ts +1 -1
  143. package/dist/ui/display/Badge.js +1 -1
  144. package/dist/ui/display/DetailHeader.css +3 -3
  145. package/dist/ui/display/DetailList.js +3 -2
  146. package/dist/ui/display/DetailNotFound.d.ts +1 -1
  147. package/dist/ui/display/DetailNotFound.js +1 -1
  148. package/dist/ui/display/Progress.d.ts +1 -1
  149. package/dist/ui/display/Progress.js +1 -1
  150. package/dist/ui/display/Spinner.d.ts +1 -1
  151. package/dist/ui/display/Spinner.js +1 -1
  152. package/dist/ui/display/StatusDot.css +46 -0
  153. package/dist/ui/display/StatusDot.d.ts +17 -0
  154. package/dist/ui/display/StatusDot.js +16 -0
  155. package/dist/ui/display/Svg.d.ts +1 -1
  156. package/dist/ui/display/Svg.js +1 -1
  157. package/dist/ui/display/catalog.d.ts +1 -1
  158. package/dist/ui/display/catalog.js +1 -0
  159. package/dist/ui/display/index.d.ts +2 -0
  160. package/dist/ui/display/index.js +1 -0
  161. package/dist/ui/forms/LoginForm.d.ts +1 -0
  162. package/dist/ui/forms/LoginForm.js +1 -0
  163. package/dist/ui/forms/SettingsContainer.d.ts +2 -1
  164. package/dist/ui/forms/SettingsContainer.js +2 -2
  165. package/dist/ui/forms/catalog.d.ts +1 -1
  166. package/dist/ui/index.d.ts +6 -1
  167. package/dist/ui/index.js +3 -1
  168. package/dist/ui/layout/BarLayout.d.ts +1 -1
  169. package/dist/ui/layout/FloatingLayout.d.ts +1 -1
  170. package/dist/ui/layout/InlineLayout.d.ts +1 -1
  171. package/dist/ui/layout/MountTitle.d.ts +2 -2
  172. package/dist/ui/layout/MountTitle.js +2 -2
  173. package/dist/ui/layout/RailLayout.d.ts +1 -1
  174. package/dist/ui/layout/SectionHeader.d.ts +2 -2
  175. package/dist/ui/layout/SectionHeader.js +4 -7
  176. package/dist/ui/layout/SingleLayout.d.ts +1 -1
  177. package/dist/ui/layout/SpatialCard.d.ts +2 -2
  178. package/dist/ui/layout/SpatialLayout.d.ts +1 -1
  179. package/dist/ui/layout/SplitLayout.d.ts +1 -1
  180. package/dist/ui/layout/StackHeader.d.ts +1 -1
  181. package/dist/ui/layout/StackLayout.d.ts +1 -1
  182. package/dist/ui/layout/TabLayout.d.ts +1 -1
  183. package/dist/ui/layout/TabPanelLayout.d.ts +2 -2
  184. package/dist/ui/layout/TabPanelLayout.js +1 -1
  185. package/dist/ui/layout/catalog.d.ts +1 -1
  186. package/dist/ui/layout/register.d.ts +2 -2
  187. package/dist/ui/layout/register.js +1 -1
  188. package/dist/ui/media/catalog.d.ts +1 -1
  189. package/dist/ui/menu/ActionList.d.ts +2 -2
  190. package/dist/ui/menu/ActionList.js +1 -1
  191. package/dist/ui/menu/ContainerMenu.d.ts +2 -2
  192. package/dist/ui/menu/ContextMenu.d.ts +2 -2
  193. package/dist/ui/menu/useChatPicker.d.ts +2 -2
  194. package/dist/ui/navigation/ActivityBarItem.css +81 -0
  195. package/dist/ui/navigation/ActivityBarItem.d.ts +61 -0
  196. package/dist/ui/navigation/ActivityBarItem.js +68 -0
  197. package/dist/ui/navigation/catalog.d.ts +1 -1
  198. package/dist/ui/navigation/catalog.js +1 -0
  199. package/dist/ui/navigation/index.d.ts +2 -0
  200. package/dist/ui/navigation/index.js +1 -0
  201. package/dist/ui/overlay/catalog.d.ts +1 -1
  202. package/dist/ui/register.d.ts +3 -3
  203. package/dist/ui/register.js +1 -1
  204. package/package.json +15 -7
  205. package/dist/controls/command.d.ts +0 -18
  206. package/dist/controls/keybinding.d.ts +0 -9
  207. package/dist/controls/layout.d.ts +0 -16
  208. package/dist/controls/manifest.d.ts +0 -21
  209. package/dist/controls/session.d.ts +0 -16
  210. package/dist/core/binding-resolver.d.ts +0 -7
  211. package/dist/core/converter-registry.d.ts +0 -2
  212. package/dist/core/label.d.ts +0 -2
  213. package/dist/core/mount-surface.d.ts +0 -15
  214. package/dist/runtime/builtins.d.ts +0 -3
  215. package/dist/types/disposable.d.ts +0 -3
  216. package/dist/types/disposable.js +0 -1
  217. package/dist/types/label.js +0 -1
  218. /package/dist/{controls → core/controls}/index.d.ts +0 -0
  219. /package/dist/{controls → core/controls}/index.js +0 -0
  220. /package/dist/{controls → core/controls}/storage/layout-local.js +0 -0
  221. /package/dist/{controls → core/controls}/storage/session-local.js +0 -0
  222. /package/dist/{converters → core/converters}/a2ui-v0.10.js +0 -0
  223. /package/dist/{converters → core/converters}/index.d.ts +0 -0
  224. /package/dist/{converters → core/converters}/index.js +0 -0
  225. /package/dist/core/{surface-presentation.js → graph/surface-presentation.js} +0 -0
  226. /package/dist/{i18n → core/i18n}/i18n-backend.js +0 -0
  227. /package/dist/{i18n → core/i18n}/registry.d.ts +0 -0
  228. /package/dist/{i18n → core/i18n}/registry.js +0 -0
  229. /package/dist/core/{path-resolver.js → resolve/path-resolver.js} +0 -0
  230. /package/dist/core/{permissions.js → resolve/permissions.js} +0 -0
  231. /package/dist/core/{backends → store/backends}/modus-backend.js +0 -0
  232. /package/dist/core/{backends → store/backends}/storage-backend.js +0 -0
  233. /package/dist/core/{backends → store/backends}/yjs-backend.js +0 -0
  234. /package/dist/core/{computed-dsl.d.ts → store/computed-dsl.d.ts} +0 -0
  235. /package/dist/core/{computed-dsl.js → store/computed-dsl.js} +0 -0
  236. /package/dist/{runtime → sdk}/args-schema.js +0 -0
  237. /package/dist/{types → sdk}/binding-resolver.d.ts +0 -0
  238. /package/dist/{types → sdk}/binding-resolver.js +0 -0
  239. /package/dist/{types → sdk}/colors.d.ts +0 -0
  240. /package/dist/{types → sdk}/colors.js +0 -0
  241. /package/dist/{types → sdk}/command.d.ts +0 -0
  242. /package/dist/{types → sdk}/command.js +0 -0
  243. /package/dist/{types → sdk}/component-graph.d.ts +0 -0
  244. /package/dist/{types → sdk}/component-graph.js +0 -0
  245. /package/dist/{types → sdk}/component-registry.d.ts +0 -0
  246. /package/dist/{types → sdk}/component-registry.js +0 -0
  247. /package/dist/{types → sdk}/converter-registry.d.ts +0 -0
  248. /package/dist/{types → sdk}/converter-registry.js +0 -0
  249. /package/dist/{core → sdk}/disposable.js +0 -0
  250. /package/dist/{types → sdk}/events.d.ts +0 -0
  251. /package/dist/{types → sdk}/events.js +0 -0
  252. /package/dist/{types → sdk}/host.d.ts +0 -0
  253. /package/dist/{types → sdk}/host.js +0 -0
  254. /package/dist/{types → sdk}/keybinding.d.ts +0 -0
  255. /package/dist/{types → sdk}/keybinding.js +0 -0
  256. /package/dist/{types → sdk}/layout.js +0 -0
  257. /package/dist/{types → sdk}/manifest.d.ts +0 -0
  258. /package/dist/{types → sdk}/manifest.js +0 -0
  259. /package/dist/{types → sdk}/mount-menu.d.ts +0 -0
  260. /package/dist/{types → sdk}/mount-menu.js +0 -0
  261. /package/dist/{types → sdk}/mount-surface.js +0 -0
  262. /package/dist/{types → sdk}/permissions.d.ts +0 -0
  263. /package/dist/{types → sdk}/permissions.js +0 -0
  264. /package/dist/{types → sdk}/query.d.ts +0 -0
  265. /package/dist/{types → sdk}/query.js +0 -0
  266. /package/dist/{types → sdk}/reactive-store.d.ts +0 -0
  267. /package/dist/{types → sdk}/reactive-store.js +0 -0
  268. /package/dist/{types → sdk}/scena.js +0 -0
  269. /package/dist/{types → sdk}/scope-backend.d.ts +0 -0
  270. /package/dist/{types → sdk}/scope-backend.js +0 -0
  271. /package/dist/{types → sdk}/session.d.ts +0 -0
  272. /package/dist/{types → sdk}/session.js +0 -0
  273. /package/dist/{types → sdk}/shell.d.ts +0 -0
  274. /package/dist/{types → sdk}/shell.js +0 -0
  275. /package/dist/{types → sdk}/when.d.ts +0 -0
  276. /package/dist/{types → sdk}/when.js +0 -0
@@ -0,0 +1,3 @@
1
+ import type { Disposable } from '../sdk/disposable.js';
2
+ import type { Scena } from '../sdk/scena.js';
3
+ export declare function registerBuiltinFunctions(scena: Scena): Disposable;
@@ -1,4 +1,4 @@
1
- import { combineDisposables } from '../core/disposable.js';
1
+ import { combineDisposables } from '../sdk/disposable.js';
2
2
  // The 14 a2ui v0.10 basic-catalog functions, registered as commands at
3
3
  // createScena() time. All declare callableFrom: 'clientOnly' semantics
4
4
  // (dispatch: 'client' here — they don't round-trip through the socket).
@@ -0,0 +1,18 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ReactiveStore, SocketBridge } from '../../sdk/reactive-store.js';
3
+ import type { MountSurfaceRegistry } from '../../sdk/mount-surface.js';
4
+ import type { CommandRegistry } from '../../sdk/command.js';
5
+ import type { WhenEngine } from '../../sdk/when.js';
6
+ import type { Scena } from '../../sdk/scena.js';
7
+ import type { KeybindingRegistry } from '../../sdk/keybinding.js';
8
+ interface Deps {
9
+ events: EventBus;
10
+ store: ReactiveStore;
11
+ surfaces: MountSurfaceRegistry;
12
+ when: WhenEngine;
13
+ socket?: SocketBridge;
14
+ keybindings: KeybindingRegistry;
15
+ getScena: () => Scena;
16
+ }
17
+ export declare function createCommandRegistry(deps: Deps): CommandRegistry;
18
+ export {};
@@ -1,5 +1,5 @@
1
- import { disposableFrom } from '../core/disposable.js';
2
- import { validateArgs } from '../runtime/args-schema.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
+ import { validateArgs } from '../../sdk/args-schema.js';
3
3
  export function createCommandRegistry(deps) {
4
4
  const { events, store, surfaces, when, socket, keybindings, getScena } = deps;
5
5
  const commands = new Map();
@@ -1,3 +1,3 @@
1
- import type { EventBus, ScenaEventMap } from '../types/events.js';
1
+ import type { EventBus, ScenaEventMap } from '../../sdk/events.js';
2
2
  export declare function createEventBus(): EventBus;
3
3
  export type { ScenaEventMap };
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from '../core/disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  export function createEventBus() {
3
3
  const subs = new Map();
4
4
  function emit(event, payload) {
@@ -0,0 +1,9 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { KeybindingRegistry } from '../../sdk/keybinding.js';
3
+ import type { WhenEngine } from '../../sdk/when.js';
4
+ interface Deps {
5
+ events: EventBus;
6
+ when: WhenEngine;
7
+ }
8
+ export declare function createKeybindingRegistry(deps: Deps): KeybindingRegistry;
9
+ export {};
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from '../core/disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  function normalizeKey(input) {
3
3
  return input
4
4
  .trim()
@@ -0,0 +1,31 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
3
+ import type { SurfaceName } from '../../sdk/mount-surface.js';
4
+ import type { LayoutAPI, LayoutRegistry, LayoutStorage, ScenaLayout, SurfaceLayoutState } from '../../sdk/layout.js';
5
+ interface LayoutDeps {
6
+ events: EventBus;
7
+ store: ReactiveStore;
8
+ initial?: ScenaLayout;
9
+ storage?: LayoutStorage;
10
+ surfaceDefaults?: Partial<Record<SurfaceName, SurfaceLayoutState>>;
11
+ }
12
+ /**
13
+ * How the nine surfaces scena's own DefaultShell draws start out.
14
+ *
15
+ * These are a convenience, not a claim about what surfaces exist: an app that
16
+ * has its own set passes `surfaceDefaults` to createScena and these are not
17
+ * used at all. Exported so an app that wants scena's nine *plus* its own can
18
+ * spread rather than retype them.
19
+ *
20
+ * They are deliberately the base rather than something `initialLayout` merges
21
+ * into, because the two answer different questions -- which surfaces this app
22
+ * has, versus what state to restore.
23
+ */
24
+ export declare const DEFAULT_SURFACE_LAYOUTS: Partial<Record<SurfaceName, SurfaceLayoutState>>;
25
+ export declare function createLayoutAPI(deps: LayoutDeps): LayoutAPI & {
26
+ setStorage(s: LayoutStorage | null): void;
27
+ };
28
+ export declare function createLayoutRegistry(deps: {
29
+ events: EventBus;
30
+ }): LayoutRegistry;
31
+ export {};
@@ -1,5 +1,17 @@
1
- import { disposableFrom } from '../core/disposable.js';
2
- const DEFAULT_SURFACE_LAYOUTS = {
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
+ /**
3
+ * How the nine surfaces scena's own DefaultShell draws start out.
4
+ *
5
+ * These are a convenience, not a claim about what surfaces exist: an app that
6
+ * has its own set passes `surfaceDefaults` to createScena and these are not
7
+ * used at all. Exported so an app that wants scena's nine *plus* its own can
8
+ * spread rather than retype them.
9
+ *
10
+ * They are deliberately the base rather than something `initialLayout` merges
11
+ * into, because the two answer different questions -- which surfaces this app
12
+ * has, versus what state to restore.
13
+ */
14
+ export const DEFAULT_SURFACE_LAYOUTS = {
3
15
  titlebar: { visible: true, layout: 'bar' },
4
16
  activitybar: { visible: true, layout: 'rail' },
5
17
  'sidebar:left': { visible: true, layout: 'single', size: 240 },
@@ -10,8 +22,12 @@ const DEFAULT_SURFACE_LAYOUTS = {
10
22
  overlay: { visible: true, layout: 'floating' },
11
23
  detached: { visible: false, layout: 'single' },
12
24
  };
13
- function defaultLayout() {
14
- return { surfaces: { ...DEFAULT_SURFACE_LAYOUTS } };
25
+ function defaultLayout(defaults) {
26
+ // `?? DEFAULT_SURFACE_LAYOUTS`, not a merge: an app that passes its own set
27
+ // is saying those ARE its surfaces, and merging would put back the ones it
28
+ // just declined. An empty object is therefore a legitimate answer -- no
29
+ // surfaces until something calls setSurface.
30
+ return { surfaces: { ...(defaults ?? DEFAULT_SURFACE_LAYOUTS) } };
15
31
  }
16
32
  // Long enough to swallow a gesture, short enough that letting go of a splitter
17
33
  // and closing the tab keeps the size.
@@ -35,9 +51,10 @@ function surfaceBase(surface) {
35
51
  export function createLayoutAPI(deps) {
36
52
  const { events, store } = deps;
37
53
  let storage = deps.storage ?? null;
54
+ const base = () => defaultLayout(deps.surfaceDefaults);
38
55
  let state = deps.initial
39
- ? applyDeep(defaultLayout(), deps.initial)
40
- : defaultLayout();
56
+ ? applyDeep(base(), deps.initial)
57
+ : base();
41
58
  const subscribers = new Set();
42
59
  let saveTimer = null;
43
60
  // Only the surfaces that could have changed. `set` and `patch` can touch any
@@ -133,7 +150,7 @@ export function createLayoutAPI(deps) {
133
150
  if (storage) {
134
151
  void storage.load().then((loaded) => {
135
152
  if (loaded) {
136
- state = applyDeep(defaultLayout(), loaded);
153
+ state = applyDeep(base(), loaded);
137
154
  notify();
138
155
  }
139
156
  });
@@ -0,0 +1,21 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
3
+ import type { ComponentRegistry } from '../../sdk/component-registry.js';
4
+ import type { CommandRegistry } from '../../sdk/command.js';
5
+ import type { KeybindingRegistry } from '../../sdk/keybinding.js';
6
+ import type { MountSurfaceRegistry } from '../../sdk/mount-surface.js';
7
+ import type { ConverterRegistry } from '../../sdk/converter-registry.js';
8
+ import type { PermissionEngine } from '../../sdk/permissions.js';
9
+ import type { ManifestAPI } from '../../sdk/manifest.js';
10
+ interface Deps {
11
+ events: EventBus;
12
+ store: ReactiveStore;
13
+ components: ComponentRegistry;
14
+ commands: CommandRegistry;
15
+ keybindings: KeybindingRegistry;
16
+ surfaces: MountSurfaceRegistry;
17
+ converters: ConverterRegistry;
18
+ permissions: PermissionEngine;
19
+ }
20
+ export declare function createManifestAPI(deps: Deps): ManifestAPI;
21
+ export {};
@@ -1,5 +1,5 @@
1
- import { combineDisposables, disposableFrom } from '../core/disposable.js';
2
- import { isPermissionPath } from '../runtime/args-schema.js';
1
+ import { combineDisposables, disposableFrom } from '../../sdk/disposable.js';
2
+ import { isPermissionPath } from '../../sdk/args-schema.js';
3
3
  // Validates an AuthorManifest. Returns a list of errors; empty = ok.
4
4
  // - plugin component names must be `<slug>.<TypeName>`
5
5
  // - plugin command ids must be `<slug>.<...>`
@@ -0,0 +1,16 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
3
+ import type { MountSurfaceRegistry } from '../../sdk/mount-surface.js';
4
+ import type { SessionAPI, SessionStorage } from '../../sdk/session.js';
5
+ import type { ComponentRegistry } from '../../sdk/component-registry.js';
6
+ interface Deps {
7
+ events: EventBus;
8
+ store: ReactiveStore;
9
+ surfaces: MountSurfaceRegistry;
10
+ components: ComponentRegistry;
11
+ storage?: SessionStorage;
12
+ }
13
+ export declare function createSessionAPI(deps: Deps): SessionAPI & {
14
+ setStorage(s: SessionStorage | null): void;
15
+ };
16
+ export {};
@@ -1,15 +1,4 @@
1
- import { disposableFrom } from '../core/disposable.js';
2
- const ALL_SURFACES = [
3
- 'titlebar',
4
- 'activitybar',
5
- 'sidebar:left',
6
- 'sidebar:right',
7
- 'main',
8
- 'panel:bottom',
9
- 'statusbar',
10
- 'overlay',
11
- 'detached',
12
- ];
1
+ import { disposableFrom } from '../../sdk/disposable.js';
13
2
  export function createSessionAPI(deps) {
14
3
  const { events, surfaces, components } = deps;
15
4
  let storage = deps.storage ?? null;
@@ -17,7 +6,10 @@ export function createSessionAPI(deps) {
17
6
  let autoPersistSub = null;
18
7
  function snapshot() {
19
8
  const mounts = [];
20
- for (const surface of ALL_SURFACES) {
9
+ // Whatever is actually occupied, not a list of names this file was
10
+ // written with: an app-defined surface used to be dropped from the
11
+ // snapshot silently, and restore came back missing its mounts.
12
+ for (const surface of surfaces.listSurfaces()) {
21
13
  for (const m of surfaces.listAt(surface)) {
22
14
  mounts.push({
23
15
  key: m.key,
@@ -1,5 +1,5 @@
1
- import type { EventBus } from '../types/events.js';
2
- import type { ShellRegistry } from '../types/shell.js';
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ShellRegistry } from '../../sdk/shell.js';
3
3
  interface Deps {
4
4
  events: EventBus;
5
5
  initialId?: string;
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from '../core/disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  export function createShellRegistry(deps) {
3
3
  const { events } = deps;
4
4
  const shells = new Map();
@@ -1,4 +1,4 @@
1
- import type { LayoutStorage } from '../../types/layout.js';
1
+ import type { LayoutStorage } from '../../../sdk/layout.js';
2
2
  export interface LocalStorageLayoutStorageOptions {
3
3
  key?: string;
4
4
  }
@@ -1,4 +1,4 @@
1
- import type { SessionStorage } from '../../types/session.js';
1
+ import type { SessionStorage } from '../../../sdk/session.js';
2
2
  export interface LocalStorageSessionStorageOptions {
3
3
  key?: string;
4
4
  }
@@ -1,5 +1,5 @@
1
- import type { ReactiveStore } from '../types/reactive-store.js';
2
- import type { WhenEngine } from '../types/when.js';
1
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
2
+ import type { WhenEngine } from '../../sdk/when.js';
3
3
  interface Deps {
4
4
  store: ReactiveStore;
5
5
  }
@@ -1,4 +1,4 @@
1
- import { combineDisposables, disposableFrom } from '../core/disposable.js';
1
+ import { combineDisposables, disposableFrom } from '../../sdk/disposable.js';
2
2
  function tokenize(input) {
3
3
  const tokens = [];
4
4
  let i = 0;
@@ -1,4 +1,4 @@
1
- import type { Converter } from '../types/converter-registry.js';
1
+ import type { Converter } from '../../sdk/converter-registry.js';
2
2
  export interface A2uiComponentSpec {
3
3
  id: string;
4
4
  component: string;
@@ -1,4 +1,4 @@
1
- import type { ComponentNode } from '../types/component-graph.js';
1
+ import type { ComponentNode } from '../../sdk/component-graph.js';
2
2
  export declare function walk(node: ComponentNode, visit: (node: ComponentNode, parent: ComponentNode | null) => void): void;
3
3
  export declare function clone(node: ComponentNode): ComponentNode;
4
4
  export declare function addIds(node: ComponentNode): ComponentNode;
@@ -1,4 +1,4 @@
1
- import { isComponentNode } from '../types/component-graph.js';
1
+ import { isComponentNode } from '../../sdk/component-graph.js';
2
2
  // Recursive tree walk. Visits the root, then every nested ComponentNode found
3
3
  // anywhere in its prop values (single child, child array, or deeper nesting).
4
4
  export function walk(node, visit) {
@@ -1,2 +1,2 @@
1
- import type { MountMenuRegistry } from '../types/mount-menu.js';
1
+ import type { MountMenuRegistry } from '../../sdk/mount-menu.js';
2
2
  export declare function createMountMenuRegistry(): MountMenuRegistry;
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from './disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  export function createMountMenuRegistry() {
3
3
  const bySlot = new Map();
4
4
  function register(slot, contributor) {
@@ -0,0 +1,15 @@
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { MountSurfaceRegistry } from '../../sdk/mount-surface.js';
3
+ import type { ComponentRegistry } from '../../sdk/component-registry.js';
4
+ import type { WhenEngine } from '../../sdk/when.js';
5
+ import type { BindingResolver } from '../../sdk/binding-resolver.js';
6
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
7
+ interface Deps {
8
+ events: EventBus;
9
+ when: WhenEngine;
10
+ bindings: BindingResolver;
11
+ store: ReactiveStore;
12
+ components: ComponentRegistry;
13
+ }
14
+ export declare function createMountSurfaceRegistry(deps: Deps): MountSurfaceRegistry;
15
+ export {};
@@ -1,6 +1,6 @@
1
- import { isDataBinding } from '../types/component-graph.js';
2
- import { combineDisposables, disposableFrom } from './disposable.js';
3
- import { clearMountLocal } from './reactive-store.js';
1
+ import { isDataBinding } from '../../sdk/component-graph.js';
2
+ import { combineDisposables, disposableFrom } from '../../sdk/disposable.js';
3
+ import { clearMountLocal } from '../store/reactive-store.js';
4
4
  const MISSING_NODE = {
5
5
  component: 'MissingComponent',
6
6
  reason: 'unbound',
@@ -179,6 +179,25 @@ export function createMountSurfaceRegistry(deps) {
179
179
  return;
180
180
  events.emit('scena:mount:focused', { key, surface: m.surface });
181
181
  }
182
+ // Which surfaces currently hold a visible mount.
183
+ //
184
+ // Anything that needs to sweep every surface has to ask, rather than iterate
185
+ // a list of names it was compiled with: a surface is whatever an app mounts
186
+ // to, so a hardcoded list silently skips the ones it has not heard of. The
187
+ // session snapshot used to do exactly that.
188
+ //
189
+ // Ordered by first mount, so a caller sweeping surfaces is deterministic.
190
+ function listSurfaces() {
191
+ const seen = new Set();
192
+ const out = [];
193
+ for (const m of [...mountsByKey.values()].sort((a, b) => a.openedAt - b.openedAt)) {
194
+ if (!visibleByKey.has(m.key) || seen.has(m.surface))
195
+ continue;
196
+ seen.add(m.surface);
197
+ out.push(m.surface);
198
+ }
199
+ return out;
200
+ }
182
201
  function listAt(surface) {
183
202
  const out = [];
184
203
  for (const m of mountsByKey.values()) {
@@ -210,5 +229,5 @@ export function createMountSurfaceRegistry(deps) {
210
229
  });
211
230
  }
212
231
  }
213
- return { mount, open, openResource, close, focus, listAt, move };
232
+ return { mount, open, openResource, close, focus, listAt, listSurfaces, move };
214
233
  }
@@ -1,6 +1,6 @@
1
- import type { SurfaceName } from '../types/mount-surface.js';
2
- import type { SurfacePresentation } from '../types/layout.js';
3
- import type { ModusClass } from './backends/modus-backend.js';
1
+ import type { SurfaceName } from '../../sdk/mount-surface.js';
2
+ import type { SurfacePresentation } from '../../sdk/layout.js';
3
+ import type { ModusClass } from '../store/backends/modus-backend.js';
4
4
  export type PresentationPolicy = Partial<Record<SurfaceName, Partial<Record<ModusClass, SurfacePresentation>>>>;
5
5
  export declare function resolveSurfacePresentation(surface: SurfaceName, modus: ModusClass, policy?: PresentationPolicy): SurfacePresentation;
6
6
  export declare function isOverlaid(presentation: SurfacePresentation): boolean;
@@ -1,2 +1,2 @@
1
- import type { ScopeBackend } from '../types/scope-backend.js';
1
+ import type { ScopeBackend } from '../../sdk/scope-backend.js';
2
2
  export declare function createI18nBackend(scope?: string): ScopeBackend;
@@ -1,44 +1,35 @@
1
- export * from '../types/index.js';
2
- export { combineDisposables, disposableFrom } from './disposable.js';
3
- export { walk, clone, addIds, findById, stripMeta } from './component-graph.js';
4
- export { createPermissionEngine } from './permissions.js';
5
- export { createReactiveStore, localPath, rewriteLocal, clearMountLocal, } from './reactive-store.js';
6
- export { createBindingResolver } from './binding-resolver.js';
7
- export { resolveLabel } from './label.js';
8
- export { createStorageBackend, createLocalStorageStorage, } from './backends/storage-backend.js';
9
- export type { BackendStorage } from './backends/storage-backend.js';
10
- export { createModusBackend, DEFAULT_MODUS_BREAKPOINTS, } from './backends/modus-backend.js';
11
- export type { ModusClass, ModusBreakpoints, ModusBackendOptions, } from './backends/modus-backend.js';
12
- export { resolveSurfacePresentation, isOverlaid } from './surface-presentation.js';
13
- export type { PresentationPolicy } from './surface-presentation.js';
14
- export { registerMessages, registerLocale, unregisterMessages, setLocale, getLocale, getLocaleInfo, listLocaleInfo, setFallbackLocale, listLocales, lookup, resolveMessage, translate, allKeys, subscribeI18n, clearMessages, } from '../i18n/registry.js';
15
- export type { TranslateOptions, MessageTree, LocaleInfo, RegisterMessagesExtra, } from '../i18n/registry.js';
16
- export { createI18nBackend } from '../i18n/i18n-backend.js';
17
- export { createComponentRegistry } from './component-registry.js';
18
- export { createConverterRegistry } from './converter-registry.js';
19
- export { createMountSurfaceRegistry } from './mount-surface.js';
1
+ export * from '../sdk/index.js';
2
+ export { combineDisposables, disposableFrom } from '../sdk/disposable.js';
3
+ export { walk, clone, addIds, findById, stripMeta } from './graph/component-graph.js';
4
+ export { createPermissionEngine } from './resolve/permissions.js';
5
+ export { createReactiveStore, localPath, rewriteLocal, clearMountLocal, } from './store/reactive-store.js';
6
+ export { createBindingResolver } from './resolve/binding-resolver.js';
7
+ export { resolveLabel } from '../sdk/label.js';
8
+ export { createStorageBackend, createLocalStorageStorage, } from './store/backends/storage-backend.js';
9
+ export type { BackendStorage } from './store/backends/storage-backend.js';
10
+ export { createModusBackend, DEFAULT_MODUS_BREAKPOINTS, } from './store/backends/modus-backend.js';
11
+ export type { ModusClass, ModusBreakpoints, ModusBackendOptions, } from './store/backends/modus-backend.js';
12
+ export { resolveSurfacePresentation, isOverlaid } from './graph/surface-presentation.js';
13
+ export type { PresentationPolicy } from './graph/surface-presentation.js';
14
+ export { registerMessages, registerLocale, unregisterMessages, setLocale, getLocale, getLocaleInfo, listLocaleInfo, setFallbackLocale, listLocales, lookup, resolveMessage, translate, allKeys, subscribeI18n, clearMessages, } from './i18n/registry.js';
15
+ export type { TranslateOptions, MessageTree, LocaleInfo, RegisterMessagesExtra, } from './i18n/registry.js';
16
+ export { createI18nBackend } from './i18n/i18n-backend.js';
17
+ export { createComponentRegistry } from './registry/component-registry.js';
18
+ export { createConverterRegistry } from './registry/converter-registry.js';
19
+ export { createMountSurfaceRegistry } from './graph/mount-surface.js';
20
20
  export { createScena } from './scena.js';
21
- export { parsePath, joinAbsolute, joinSegments, hasWildcard, interpolatePath, readPath, writePath, scopeOf, } from './path-resolver.js';
22
- export { resolveDynamicValue, resolveDynamicString, resolveDynamicNumber, resolveDynamicBoolean, resolveDynamicStringList, resolveFunctionCall, resolveAction, writeDynamic, isWritableDynamic, } from './dynamic-resolver.js';
23
- export { createEventBus } from '../controls/events.js';
24
- export { createWhenEngine } from '../controls/when.js';
25
- export { createCommandRegistry } from '../controls/command.js';
26
- export { createKeybindingRegistry } from '../controls/keybinding.js';
27
- export { createLayoutAPI, createLayoutRegistry } from '../controls/layout.js';
28
- export { createSessionAPI } from '../controls/session.js';
29
- export { createShellRegistry } from '../controls/shell.js';
30
- export { createManifestAPI } from '../controls/manifest.js';
31
- export { createLocalStorageLayoutStorage, createNoopLayoutStorage, } from '../controls/storage/layout-local.js';
32
- export { createLocalStorageSessionStorage } from '../controls/storage/session-local.js';
33
- export { validateArgs, isPermissionPath } from '../runtime/args-schema.js';
34
- export type { ValidateArgsResult } from '../runtime/args-schema.js';
35
- export { createSurfaceBridge } from '../runtime/surface-bridge.js';
36
- export { registerClientHandler, getClientHandler, } from '../runtime/client-handlers.js';
37
- export { createInMemorySocket } from '../runtime/in-memory-socket.js';
38
- export type { InMemorySocket } from '../runtime/in-memory-socket.js';
39
- export { registerBuiltinFunctions } from '../runtime/builtins.js';
40
- export { registerLayoutCommands } from '../runtime/layout-commands.js';
41
- export { registerOpenerCommands } from '../runtime/opener-commands.js';
42
- export type { RegisterOpenerCommandsOptions } from '../runtime/opener-commands.js';
43
- export { a2uiV010Converter } from '../converters/a2ui-v0.10.js';
44
- export type { A2uiCreateSurface, A2uiComponentSpec, A2uiConverterInput, } from '../converters/a2ui-v0.10.js';
21
+ export { parsePath, joinAbsolute, joinSegments, hasWildcard, interpolatePath, readPath, writePath, scopeOf, } from './resolve/path-resolver.js';
22
+ export { resolveDynamicValue, resolveDynamicString, resolveDynamicNumber, resolveDynamicBoolean, resolveDynamicStringList, resolveFunctionCall, resolveAction, writeDynamic, isWritableDynamic, } from './resolve/dynamic-resolver.js';
23
+ export { createEventBus } from './controls/events.js';
24
+ export { createWhenEngine } from './controls/when.js';
25
+ export { createCommandRegistry } from './controls/command.js';
26
+ export { createKeybindingRegistry } from './controls/keybinding.js';
27
+ export { createLayoutAPI, createLayoutRegistry, DEFAULT_SURFACE_LAYOUTS } from './controls/layout.js';
28
+ export { createSessionAPI } from './controls/session.js';
29
+ export { createShellRegistry } from './controls/shell.js';
30
+ export { createManifestAPI } from './controls/manifest.js';
31
+ export { createLocalStorageLayoutStorage, createNoopLayoutStorage, } from './controls/storage/layout-local.js';
32
+ export { createLocalStorageSessionStorage } from './controls/storage/session-local.js';
33
+ export { registerBuiltinFunctions } from './builtins.js';
34
+ export { a2uiV010Converter } from './converters/a2ui-v0.10.js';
35
+ export type { A2uiCreateSurface, A2uiComponentSpec, A2uiConverterInput, } from './converters/a2ui-v0.10.js';
@@ -1,48 +1,45 @@
1
- // Public runtime entry re-exports the type surface alongside the factory functions.
2
- export * from '../types/index.js';
3
- export { combineDisposables, disposableFrom } from './disposable.js';
4
- export { walk, clone, addIds, findById, stripMeta } from './component-graph.js';
5
- export { createPermissionEngine } from './permissions.js';
6
- export { createReactiveStore, localPath, rewriteLocal, clearMountLocal, } from './reactive-store.js';
7
- export { createBindingResolver } from './binding-resolver.js';
8
- // Pure Label resolver. `types/label.ts` documents this as the intended way to
1
+ // The core barrel: the store, the graph, the resolvers and the registries,
2
+ // re-exported alongside the sdk surface they implement. The runtime layer
3
+ // (surface bridge, sockets, layout/opener commands) is added on top by
4
+ // `src/index.ts`, which is what the package's root export points at.
5
+ export * from '../sdk/index.js';
6
+ export { combineDisposables, disposableFrom } from '../sdk/disposable.js';
7
+ export { walk, clone, addIds, findById, stripMeta } from './graph/component-graph.js';
8
+ export { createPermissionEngine } from './resolve/permissions.js';
9
+ export { createReactiveStore, localPath, rewriteLocal, clearMountLocal, } from './store/reactive-store.js';
10
+ export { createBindingResolver } from './resolve/binding-resolver.js';
11
+ // Pure Label resolver. `sdk/label.ts` documents this as the intended way to
9
12
  // resolve a Label outside React (useLabel is the reactive counterpart), so it
10
13
  // belongs on the public surface.
11
- export { resolveLabel } from './label.js';
14
+ export { resolveLabel } from '../sdk/label.js';
12
15
  // Reference ScopeBackend implementations. The Yjs backend is a deep import
13
- // (`core/backends/yjs-backend.js`) so the barrel never references `yjs`.
14
- export { createStorageBackend, createLocalStorageStorage, } from './backends/storage-backend.js';
16
+ // (`core/store/backends/yjs-backend.js`) so the barrel never references `yjs`.
17
+ export { createStorageBackend, createLocalStorageStorage, } from './store/backends/storage-backend.js';
15
18
  // `$/modus` — display environment (size class, orientation, pointer accuracy)
16
19
  // published as a scope so `when` clauses can gate surfaces on it.
17
- export { createModusBackend, DEFAULT_MODUS_BREAKPOINTS, } from './backends/modus-backend.js';
20
+ export { createModusBackend, DEFAULT_MODUS_BREAKPOINTS, } from './store/backends/modus-backend.js';
18
21
  // Maps a `$/modus` size class to how each surface occupies space. The policy
19
22
  // is supplied by the app — scena ships the mechanism, not the opinion.
20
23
  // `isOverlaid` tells a shell whether to drop the splitter and draw a scrim.
21
- export { resolveSurfacePresentation, isOverlaid } from './surface-presentation.js';
24
+ export { resolveSurfacePresentation, isOverlaid } from './graph/surface-presentation.js';
22
25
  // i18n — registry (source of truth + active locale) + the `$/t` ScopeBackend.
23
- export { registerMessages, registerLocale, unregisterMessages, setLocale, getLocale, getLocaleInfo, listLocaleInfo, setFallbackLocale, listLocales, lookup, resolveMessage, translate, allKeys, subscribeI18n, clearMessages, } from '../i18n/registry.js';
24
- export { createI18nBackend } from '../i18n/i18n-backend.js';
25
- export { createComponentRegistry } from './component-registry.js';
26
- export { createConverterRegistry } from './converter-registry.js';
27
- export { createMountSurfaceRegistry } from './mount-surface.js';
26
+ export { registerMessages, registerLocale, unregisterMessages, setLocale, getLocale, getLocaleInfo, listLocaleInfo, setFallbackLocale, listLocales, lookup, resolveMessage, translate, allKeys, subscribeI18n, clearMessages, } from './i18n/registry.js';
27
+ export { createI18nBackend } from './i18n/i18n-backend.js';
28
+ export { createComponentRegistry } from './registry/component-registry.js';
29
+ export { createConverterRegistry } from './registry/converter-registry.js';
30
+ export { createMountSurfaceRegistry } from './graph/mount-surface.js';
28
31
  export { createScena } from './scena.js';
29
- export { parsePath, joinAbsolute, joinSegments, hasWildcard, interpolatePath, readPath, writePath, scopeOf, } from './path-resolver.js';
30
- export { resolveDynamicValue, resolveDynamicString, resolveDynamicNumber, resolveDynamicBoolean, resolveDynamicStringList, resolveFunctionCall, resolveAction, writeDynamic, isWritableDynamic, } from './dynamic-resolver.js';
31
- export { createEventBus } from '../controls/events.js';
32
- export { createWhenEngine } from '../controls/when.js';
33
- export { createCommandRegistry } from '../controls/command.js';
34
- export { createKeybindingRegistry } from '../controls/keybinding.js';
35
- export { createLayoutAPI, createLayoutRegistry } from '../controls/layout.js';
36
- export { createSessionAPI } from '../controls/session.js';
37
- export { createShellRegistry } from '../controls/shell.js';
38
- export { createManifestAPI } from '../controls/manifest.js';
39
- export { createLocalStorageLayoutStorage, createNoopLayoutStorage, } from '../controls/storage/layout-local.js';
40
- export { createLocalStorageSessionStorage } from '../controls/storage/session-local.js';
41
- export { validateArgs, isPermissionPath } from '../runtime/args-schema.js';
42
- export { createSurfaceBridge } from '../runtime/surface-bridge.js';
43
- export { registerClientHandler, getClientHandler, } from '../runtime/client-handlers.js';
44
- export { createInMemorySocket } from '../runtime/in-memory-socket.js';
45
- export { registerBuiltinFunctions } from '../runtime/builtins.js';
46
- export { registerLayoutCommands } from '../runtime/layout-commands.js';
47
- export { registerOpenerCommands } from '../runtime/opener-commands.js';
48
- export { a2uiV010Converter } from '../converters/a2ui-v0.10.js';
32
+ export { parsePath, joinAbsolute, joinSegments, hasWildcard, interpolatePath, readPath, writePath, scopeOf, } from './resolve/path-resolver.js';
33
+ export { resolveDynamicValue, resolveDynamicString, resolveDynamicNumber, resolveDynamicBoolean, resolveDynamicStringList, resolveFunctionCall, resolveAction, writeDynamic, isWritableDynamic, } from './resolve/dynamic-resolver.js';
34
+ export { createEventBus } from './controls/events.js';
35
+ export { createWhenEngine } from './controls/when.js';
36
+ export { createCommandRegistry } from './controls/command.js';
37
+ export { createKeybindingRegistry } from './controls/keybinding.js';
38
+ export { createLayoutAPI, createLayoutRegistry, DEFAULT_SURFACE_LAYOUTS } from './controls/layout.js';
39
+ export { createSessionAPI } from './controls/session.js';
40
+ export { createShellRegistry } from './controls/shell.js';
41
+ export { createManifestAPI } from './controls/manifest.js';
42
+ export { createLocalStorageLayoutStorage, createNoopLayoutStorage, } from './controls/storage/layout-local.js';
43
+ export { createLocalStorageSessionStorage } from './controls/storage/session-local.js';
44
+ export { registerBuiltinFunctions } from './builtins.js';
45
+ export { a2uiV010Converter } from './converters/a2ui-v0.10.js';
@@ -1,5 +1,5 @@
1
- import type { EventBus } from '../types/events.js';
2
- import type { ComponentRegistry } from '../types/component-registry.js';
1
+ import type { EventBus } from '../../sdk/events.js';
2
+ import type { ComponentRegistry } from '../../sdk/component-registry.js';
3
3
  interface Deps {
4
4
  events: EventBus;
5
5
  }
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from './disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  export function createComponentRegistry(deps) {
3
3
  const { events } = deps;
4
4
  const defs = new Map();
@@ -0,0 +1,2 @@
1
+ import type { ConverterRegistry } from '../../sdk/converter-registry.js';
2
+ export declare function createConverterRegistry(): ConverterRegistry;
@@ -1,4 +1,4 @@
1
- import { disposableFrom } from './disposable.js';
1
+ import { disposableFrom } from '../../sdk/disposable.js';
2
2
  export function createConverterRegistry() {
3
3
  const converters = new Map();
4
4
  function inputMatches(matcher, input) {
@@ -0,0 +1,7 @@
1
+ import type { BindingResolver } from '../../sdk/binding-resolver.js';
2
+ import type { ReactiveStore } from '../../sdk/reactive-store.js';
3
+ interface Deps {
4
+ store: ReactiveStore;
5
+ }
6
+ export declare function createBindingResolver(deps: Deps): BindingResolver;
7
+ export {};