@astrale-os/shell 0.2.0 → 0.3.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 (166) hide show
  1. package/dist/application/apps.d.ts +3 -3
  2. package/dist/application/apps.d.ts.map +1 -1
  3. package/dist/application/apps.js +2 -2
  4. package/dist/application/namespaces.d.ts +4 -4
  5. package/dist/application/namespaces.d.ts.map +1 -1
  6. package/dist/application/namespaces.js +4 -4
  7. package/dist/application/session/open.d.ts +2 -2
  8. package/dist/application/session/open.d.ts.map +1 -1
  9. package/dist/application/session/open.js +1 -1
  10. package/dist/application/session/session.d.ts +2 -2
  11. package/dist/application/session/session.d.ts.map +1 -1
  12. package/dist/application/session/token.d.ts +1 -1
  13. package/dist/application/session/token.d.ts.map +1 -1
  14. package/dist/application/session/token.js +2 -2
  15. package/dist/application/spaces.d.ts +2 -2
  16. package/dist/application/spaces.d.ts.map +1 -1
  17. package/dist/application/spaces.js +1 -1
  18. package/dist/application/user.d.ts +3 -3
  19. package/dist/application/user.d.ts.map +1 -1
  20. package/dist/application/user.js +1 -1
  21. package/dist/application/view.d.ts +3 -3
  22. package/dist/application/view.d.ts.map +1 -1
  23. package/dist/application/view.js +1 -1
  24. package/dist/channel/children.d.ts +3 -3
  25. package/dist/channel/children.d.ts.map +1 -1
  26. package/dist/channel/listeners.d.ts +1 -1
  27. package/dist/channel/listeners.d.ts.map +1 -1
  28. package/dist/channel/message-port.d.ts +1 -1
  29. package/dist/channel/message-port.d.ts.map +1 -1
  30. package/dist/channel/observer.d.ts +1 -1
  31. package/dist/channel/observer.d.ts.map +1 -1
  32. package/dist/channel/parent.d.ts +3 -3
  33. package/dist/channel/parent.d.ts.map +1 -1
  34. package/dist/channel/parent.js +1 -1
  35. package/dist/channel/transport.d.ts +1 -1
  36. package/dist/channel/transport.d.ts.map +1 -1
  37. package/dist/index.d.ts +56 -56
  38. package/dist/index.d.ts.map +1 -1
  39. package/dist/index.js +20 -20
  40. package/dist/intent/middleware/capabilities.d.ts +3 -3
  41. package/dist/intent/middleware/capabilities.d.ts.map +1 -1
  42. package/dist/intent/middleware/logging.d.ts +1 -1
  43. package/dist/intent/middleware/logging.d.ts.map +1 -1
  44. package/dist/intent/middleware/rate-limit.d.ts +2 -2
  45. package/dist/intent/middleware/rate-limit.d.ts.map +1 -1
  46. package/dist/intent/pipeline.d.ts +1 -1
  47. package/dist/intent/pipeline.d.ts.map +1 -1
  48. package/dist/intent/policy.d.ts +2 -2
  49. package/dist/intent/policy.d.ts.map +1 -1
  50. package/dist/intent/request.d.ts +3 -3
  51. package/dist/intent/request.d.ts.map +1 -1
  52. package/dist/intent/router.d.ts +6 -6
  53. package/dist/intent/router.d.ts.map +1 -1
  54. package/dist/intent/router.js +1 -1
  55. package/dist/kernel/credential.d.ts +2 -2
  56. package/dist/kernel/credential.d.ts.map +1 -1
  57. package/dist/kernel/delegated.d.ts +3 -3
  58. package/dist/kernel/delegated.d.ts.map +1 -1
  59. package/dist/kernel/delegated.js +1 -1
  60. package/dist/kernel/delegation/refresh.d.ts +1 -1
  61. package/dist/kernel/delegation/refresh.d.ts.map +1 -1
  62. package/dist/kernel/delegation/refresh.js +1 -1
  63. package/dist/message/message.d.ts +3 -3
  64. package/dist/message/message.d.ts.map +1 -1
  65. package/dist/shell/access.d.ts +2 -2
  66. package/dist/shell/access.d.ts.map +1 -1
  67. package/dist/shell/access.js +1 -1
  68. package/dist/shell/build.d.ts +11 -11
  69. package/dist/shell/build.d.ts.map +1 -1
  70. package/dist/shell/build.js +1 -1
  71. package/dist/shell/config.d.ts +1 -1
  72. package/dist/shell/config.d.ts.map +1 -1
  73. package/dist/shell/create.d.ts +2 -2
  74. package/dist/shell/create.d.ts.map +1 -1
  75. package/dist/shell/create.js +2 -2
  76. package/dist/shell/sandboxed/boot.d.ts +4 -4
  77. package/dist/shell/sandboxed/boot.d.ts.map +1 -1
  78. package/dist/shell/sandboxed/boot.js +5 -5
  79. package/dist/shell/sandboxed/guarded.d.ts +2 -2
  80. package/dist/shell/sandboxed/guarded.d.ts.map +1 -1
  81. package/dist/shell/sandboxed/pending.d.ts +2 -2
  82. package/dist/shell/sandboxed/pending.d.ts.map +1 -1
  83. package/dist/shell/sandboxed/sandboxed.d.ts +2 -2
  84. package/dist/shell/sandboxed/sandboxed.d.ts.map +1 -1
  85. package/dist/shell/sandboxed/sandboxed.js +10 -10
  86. package/dist/shell/shell.d.ts +12 -12
  87. package/dist/shell/shell.d.ts.map +1 -1
  88. package/dist/shell/standalone.d.ts +2 -2
  89. package/dist/shell/standalone.d.ts.map +1 -1
  90. package/dist/shell/standalone.js +9 -9
  91. package/dist/window/capabilities.d.ts +1 -1
  92. package/dist/window/capabilities.d.ts.map +1 -1
  93. package/dist/window/embed/adapter.d.ts +1 -1
  94. package/dist/window/embed/adapter.d.ts.map +1 -1
  95. package/dist/window/embed/iframe.d.ts +1 -1
  96. package/dist/window/embed/iframe.d.ts.map +1 -1
  97. package/dist/window/lifecycle/states.d.ts +2 -2
  98. package/dist/window/lifecycle/states.d.ts.map +1 -1
  99. package/dist/window/lifecycle/states.js +1 -1
  100. package/dist/window/lifecycle/transition.d.ts +1 -1
  101. package/dist/window/lifecycle/transition.d.ts.map +1 -1
  102. package/dist/window/mount/close.d.ts +6 -6
  103. package/dist/window/mount/close.d.ts.map +1 -1
  104. package/dist/window/mount/credential.d.ts +5 -5
  105. package/dist/window/mount/credential.d.ts.map +1 -1
  106. package/dist/window/mount/credential.js +1 -1
  107. package/dist/window/mount/handshake.js +1 -1
  108. package/dist/window/mount/mount.d.ts +6 -6
  109. package/dist/window/mount/mount.d.ts.map +1 -1
  110. package/dist/window/mount/mount.js +5 -5
  111. package/dist/window/mount/params.d.ts +2 -2
  112. package/dist/window/mount/params.d.ts.map +1 -1
  113. package/dist/window/mount/plain.d.ts +5 -5
  114. package/dist/window/mount/plain.d.ts.map +1 -1
  115. package/dist/window/mount/plain.js +1 -1
  116. package/dist/window/window.d.ts +1 -1
  117. package/dist/window/window.d.ts.map +1 -1
  118. package/package.json +8 -5
  119. package/src/application/apps.ts +5 -5
  120. package/src/application/namespaces.ts +8 -8
  121. package/src/application/session/open.ts +4 -4
  122. package/src/application/session/session.ts +2 -2
  123. package/src/application/session/token.ts +3 -3
  124. package/src/application/spaces.ts +3 -3
  125. package/src/application/user.ts +4 -4
  126. package/src/application/view.ts +3 -3
  127. package/src/channel/children.ts +3 -3
  128. package/src/channel/listeners.ts +1 -1
  129. package/src/channel/message-port.ts +2 -2
  130. package/src/channel/observer.ts +1 -1
  131. package/src/channel/parent.ts +4 -4
  132. package/src/channel/transport.ts +1 -1
  133. package/src/index.ts +56 -56
  134. package/src/intent/middleware/capabilities.ts +3 -3
  135. package/src/intent/middleware/logging.ts +2 -2
  136. package/src/intent/middleware/rate-limit.ts +2 -2
  137. package/src/intent/pipeline.ts +1 -1
  138. package/src/intent/policy.ts +2 -2
  139. package/src/intent/request.ts +3 -3
  140. package/src/intent/router.ts +7 -7
  141. package/src/kernel/credential.ts +2 -2
  142. package/src/kernel/delegated.ts +4 -4
  143. package/src/kernel/delegation/refresh.ts +2 -2
  144. package/src/message/message.ts +3 -3
  145. package/src/shell/access.ts +3 -3
  146. package/src/shell/build.ts +13 -13
  147. package/src/shell/config.ts +1 -1
  148. package/src/shell/create.ts +4 -4
  149. package/src/shell/sandboxed/boot.ts +9 -9
  150. package/src/shell/sandboxed/guarded.ts +2 -2
  151. package/src/shell/sandboxed/pending.ts +2 -2
  152. package/src/shell/sandboxed/sandboxed.ts +18 -18
  153. package/src/shell/shell.ts +12 -12
  154. package/src/shell/standalone.ts +13 -13
  155. package/src/window/capabilities.ts +1 -1
  156. package/src/window/embed/adapter.ts +1 -1
  157. package/src/window/embed/iframe.ts +2 -2
  158. package/src/window/lifecycle/states.ts +2 -2
  159. package/src/window/lifecycle/transition.ts +1 -1
  160. package/src/window/mount/close.ts +6 -6
  161. package/src/window/mount/credential.ts +5 -5
  162. package/src/window/mount/handshake.ts +3 -3
  163. package/src/window/mount/mount.ts +13 -13
  164. package/src/window/mount/params.ts +2 -2
  165. package/src/window/mount/plain.ts +6 -6
  166. package/src/window/window.ts +1 -1
@@ -1,4 +1,4 @@
1
- import { createTokenRefresher } from '../../kernel/delegation/refresh';
1
+ import { createTokenRefresher } from '../../kernel/delegation/refresh.js';
2
2
  /** No-op refresher for windows with no token to refresh (plain mounts, no-refresh credentials). */
3
3
  export const NOOP_REFRESHER = {
4
4
  start: () => { },
@@ -1,4 +1,4 @@
1
- import { INIT_RESPONSE_TYPE, isInitRequest } from '../../message/init';
1
+ import { INIT_RESPONSE_TYPE, isInitRequest } from '../../message/init.js';
2
2
  /** Parent-side handshake: wait for INIT_REQUEST, transfer a MessagePort, complete ctrl:handshake. */
3
3
  export function runParentHandshake(params) {
4
4
  const { iframe, expectedOrigin, timeoutMs } = params;
@@ -1,9 +1,9 @@
1
- import type { ChildrenChannelController } from '../../channel/children';
2
- import type { KernelClient } from '../../kernel/client';
3
- import type { ShellAdapter } from '../embed/adapter';
4
- import type { LifecycleController } from '../lifecycle/states';
5
- import type { Window } from '../window';
6
- import type { CloseResult, MountedWindow, MountParams } from './params';
1
+ import type { ChildrenChannelController } from '../../channel/children.js';
2
+ import type { KernelClient } from '../../kernel/client.js';
3
+ import type { ShellAdapter } from '../embed/adapter.js';
4
+ import type { LifecycleController } from '../lifecycle/states.js';
5
+ import type { Window } from '../window.js';
6
+ import type { CloseResult, MountedWindow, MountParams } from './params.js';
7
7
  export type MountControllerConfig = {
8
8
  adapter: ShellAdapter;
9
9
  kernel: KernelClient;
@@ -1 +1 @@
1
- {"version":3,"file":"mount.d.ts","sourceRoot":"","sources":["../../../src/window/mount/mount.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,wBAAwB,CAAA;AACvE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAA;AACvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AACpD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAEvC,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAWvE,MAAM,MAAM,qBAAqB,GAAG;IAClC,OAAO,EAAE,YAAY,CAAA;IACrB,MAAM,EAAE,YAAY,CAAA;IACpB,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,eAAe,EAAE,yBAAyB,CAAA;IAC1C,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC5B,SAAS,EAAE,mBAAmB,CAAA;CAC/B,CAAA;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,CAAC,MAAM,EAAE,WAAW,GAAG,OAAO,CAAC,aAAa,CAAC,CAAA;IAClD,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAA;IAC7F,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CACzB;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,qBAAqB,GAAG,eAAe,CAuJpF"}
1
+ {"version":3,"file":"mount.d.ts","sourceRoot":"","sources":["../../../src/window/mount/mount.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAA;AAC1E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAA;AACvD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAA;AACjE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAE1C,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAW1E,MAAM,MAAM,qBAAqB,GAAG;IAClC,OAAO,EAAE,YAAY,CAAA;IACrB,MAAM,EAAE,YAAY,CAAA;IACpB,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,eAAe,EAAE,yBAAyB,CAAA;IAC1C,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC5B,SAAS,EAAE,mBAAmB,CAAA;CAC/B,CAAA;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,CAAC,MAAM,EAAE,WAAW,GAAG,OAAO,CAAC,aAAa,CAAC,CAAA;IAClD,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAA;IAC7F,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CACzB;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,qBAAqB,GAAG,eAAe,CAuJpF"}
@@ -1,8 +1,8 @@
1
- import { createMessagePortTransport } from '../../channel/message-port';
2
- import { createCloser } from './close';
3
- import { credentialSource, wireTokenRefresher } from './credential';
4
- import { runParentHandshake } from './handshake';
5
- import { mountPlain } from './plain';
1
+ import { createMessagePortTransport } from '../../channel/message-port.js';
2
+ import { createCloser } from './close.js';
3
+ import { credentialSource, wireTokenRefresher } from './credential.js';
4
+ import { runParentHandshake } from './handshake.js';
5
+ import { mountPlain } from './plain.js';
6
6
  const DEFAULT_HANDSHAKE_TIMEOUT = 5_000;
7
7
  const DEFAULT_DELEGATION_TTL = 3_600;
8
8
  export function createMountController(config) {
@@ -1,5 +1,5 @@
1
- import type { SandboxProfile, WindowCapabilities } from '../capabilities';
2
- import type { Window } from '../window';
1
+ import type { SandboxProfile, WindowCapabilities } from '../capabilities.js';
2
+ import type { Window } from '../window.js';
3
3
  /**
4
4
  * A PRE-MINTED credential to hand the mounted iframe instead of the shell's
5
5
  * own delegation mint — the app-principal path. The caller composes it from
@@ -1 +1 @@
1
- {"version":3,"file":"params.d.ts","sourceRoot":"","sources":["../../../src/window/mount/params.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AACzE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAEvC;;;;;;;;GAQG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B,+CAA+C;IAC/C,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,qDAAqD;IACrD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;IAC1B;;;;OAIG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CACvE,CAAA;AAED,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAA;IAC1B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,YAAY,EAAE,kBAAkB,CAAA;IACzC,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;IAC9B,gFAAgF;IAChF,QAAQ,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,IAAI,CAAA;IACxC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,MAAM,CAAA;IACpC,QAAQ,CAAC,oBAAoB,CAAC,EAAE,MAAM,CAAA;IACtC;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,eAAe,CAAA;IACrC;;;;;;;;OAQG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;CACtC,CAAA;AAED,MAAM,MAAM,WAAW,GACnB;IAAE,IAAI,EAAE,QAAQ,CAAA;CAAE,GAClB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GACpC;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAA;AAEpB,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,iBAAiB,GAAG,WAAW,CAAA;KAAE,CAAA;IAC7D,KAAK,CAAC,IAAI,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAA;CAC5E,CAAA"}
1
+ {"version":3,"file":"params.d.ts","sourceRoot":"","sources":["../../../src/window/mount/params.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AAC5E,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAE1C;;;;;;;;GAQG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B,+CAA+C;IAC/C,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,qDAAqD;IACrD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;IAC1B;;;;OAIG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CACvE,CAAA;AAED,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAA;IAC1B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,YAAY,EAAE,kBAAkB,CAAA;IACzC,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;IAC9B,gFAAgF;IAChF,QAAQ,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,IAAI,CAAA;IACxC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,MAAM,CAAA;IACpC,QAAQ,CAAC,oBAAoB,CAAC,EAAE,MAAM,CAAA;IACtC;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,eAAe,CAAA;IACrC;;;;;;;;OAQG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;CACtC,CAAA;AAED,MAAM,MAAM,WAAW,GACnB;IAAE,IAAI,EAAE,QAAQ,CAAA;CAAE,GAClB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GACpC;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAA;AAEpB,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,iBAAiB,GAAG,WAAW,CAAA;KAAE,CAAA;IAC7D,KAAK,CAAC,IAAI,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAA;CAC5E,CAAA"}
@@ -1,8 +1,8 @@
1
- import type { ShellAdapter } from '../embed/adapter';
2
- import type { LifecycleController } from '../lifecycle/states';
3
- import type { Window } from '../window';
4
- import type { Closer, MountEntry } from './close';
5
- import type { MountedWindow, MountParams } from './params';
1
+ import type { ShellAdapter } from '../embed/adapter.js';
2
+ import type { LifecycleController } from '../lifecycle/states.js';
3
+ import type { Window } from '../window.js';
4
+ import type { Closer, MountEntry } from './close.js';
5
+ import type { MountedWindow, MountParams } from './params.js';
6
6
  export type PlainMountDeps = {
7
7
  adapter: ShellAdapter;
8
8
  windows: Map<string, Window>;
@@ -1 +1 @@
1
- {"version":3,"file":"plain.d.ts","sourceRoot":"","sources":["../../../src/window/mount/plain.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AACpD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AACvC,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AACjD,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAI1D,MAAM,MAAM,cAAc,GAAG;IAC3B,OAAO,EAAE,YAAY,CAAA;IACrB,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC5B,SAAS,EAAE,mBAAmB,CAAA;IAC9B,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,CAAA;IAChC,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED;;;;;GAKG;AACH,wBAAsB,UAAU,CAC9B,IAAI,EAAE,cAAc,EACpB,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,WAAW,GAClB,OAAO,CAAC,aAAa,CAAC,CAyCxB"}
1
+ {"version":3,"file":"plain.d.ts","sourceRoot":"","sources":["../../../src/window/mount/plain.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAA;AACvD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAA;AACjE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAC1C,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AACpD,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAI7D,MAAM,MAAM,cAAc,GAAG;IAC3B,OAAO,EAAE,YAAY,CAAA;IACrB,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC5B,SAAS,EAAE,mBAAmB,CAAA;IAC9B,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,CAAA;IAChC,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED;;;;;GAKG;AACH,wBAAsB,UAAU,CAC9B,IAAI,EAAE,cAAc,EACpB,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,WAAW,GAClB,OAAO,CAAC,aAAa,CAAC,CAyCxB"}
@@ -1,4 +1,4 @@
1
- import { NOOP_REFRESHER } from './credential';
1
+ import { NOOP_REFRESHER } from './credential.js';
2
2
  /**
3
3
  * Plain-iframe mount path — for hosted views that don't speak the shell
4
4
  * protocol. No handshake, no transport, no delegation token, no refresher;
@@ -1,4 +1,4 @@
1
- import type { WindowCapabilities } from './capabilities';
1
+ import type { WindowCapabilities } from './capabilities.js';
2
2
  export type WindowState = 'active' | 'hidden' | 'closing' | 'closed';
3
3
  export interface Window {
4
4
  readonly windowId: string;
@@ -1 +1 @@
1
- {"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../../src/window/window.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAA;AAExD,MAAM,MAAM,WAAW,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAA;AAEpE,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;IAC9B,QAAQ,CAAC,SAAS,EAAE,WAAW,GAAG,QAAQ,CAAA;IAC1C,QAAQ,CAAC,KAAK,EAAE,WAAW,CAAA;IAC3B,QAAQ,CAAC,eAAe,EAAE,MAAM,GAAG,IAAI,CAAA;IACvC,QAAQ,CAAC,YAAY,EAAE,kBAAkB,CAAA;CAC1C"}
1
+ {"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../../src/window/window.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAA;AAE3D,MAAM,MAAM,WAAW,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAA;AAEpE,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;IAC9B,QAAQ,CAAC,SAAS,EAAE,WAAW,GAAG,QAAQ,CAAA;IAC1C,QAAQ,CAAC,KAAK,EAAE,WAAW,CAAA;IAC3B,QAAQ,CAAC,eAAe,EAAE,MAAM,GAAG,IAAI,CAAA;IACvC,QAAQ,CAAC,YAAY,EAAE,kBAAkB,CAAA;CAC1C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@astrale-os/shell",
3
- "version": "0.2.0",
3
+ "version": "0.3.1",
4
4
  "description": "Astrale Shell SDK — parent/child/kernel communication",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -25,9 +25,12 @@
25
25
  "access": "public"
26
26
  },
27
27
  "dependencies": {
28
- "@astrale-domains/workspace-schema": ">=0.2.0 <1.0.0",
29
- "@astrale-os/kernel-client": ">=0.3.0 <1.0.0",
30
- "@astrale-os/kernel-core": ">=0.4.1 <1.0.0"
28
+ "@astrale-domains/shell-schema": ">=0.3.1 <1.0.0",
29
+ "@astrale-os/kernel-client": ">=0.4.0 <1.0.0",
30
+ "@astrale-os/kernel-core": ">=0.7.1 <1.0.0",
31
+ "@astrale-os/kernel-dsl": ">=0.1.3 <1.0.0",
32
+ "jose": "^6.2.3",
33
+ "zod": "^4.3.6"
31
34
  },
32
35
  "devDependencies": {
33
36
  "@typescript/native-preview": "latest",
@@ -41,6 +44,6 @@
41
44
  "typecheck": "tsgo --noEmit && tsgo --noEmit -p tsconfig.test.json",
42
45
  "test": "vitest run",
43
46
  "test:watch": "vitest",
44
- "preinstall": "node .check-workspace.cjs"
47
+ "preinstall": "node -e \"try{require('./.check-workspace.cjs')}catch{}\""
45
48
  }
46
49
  }
@@ -1,13 +1,13 @@
1
1
  import type { BoundNode, DefOf, NodeRefInput } from '@astrale-os/kernel-client'
2
2
 
3
- import { D } from '@astrale-domains/workspace-schema'
3
+ import { D } from '@astrale-domains/shell-schema'
4
4
  import { normalizeRef } from '@astrale-os/kernel-client'
5
5
 
6
- import type { KernelClient } from '../kernel/client'
7
- import type { AppSession } from './session/session'
8
- import type { ShellDomainView, ShellSchema } from './view'
6
+ import type { KernelClient } from '../kernel/client.js'
7
+ import type { AppSession } from './session/session.js'
8
+ import type { ShellDomainView, ShellSchema } from './view.js'
9
9
 
10
- import { openAppSession } from './session/open'
10
+ import { openAppSession } from './session/open.js'
11
11
 
12
12
  /** An installed `Application` node. */
13
13
  export type ApplicationNode = BoundNode<DefOf<ShellSchema, 'Application'>, ShellSchema>
@@ -4,15 +4,15 @@
4
4
  * exactly these. Pure closures over a lazy typed view — constructing this
5
5
  * touches no kernel (safe before a sandboxed shell's `init()`).
6
6
  */
7
- import type { KernelClient } from '../kernel/client'
8
- import type { AppsNamespace } from './apps'
9
- import type { SpacesNamespace } from './spaces'
10
- import type { UserNamespace } from './user'
7
+ import type { KernelClient } from '../kernel/client.js'
8
+ import type { AppsNamespace } from './apps.js'
9
+ import type { SpacesNamespace } from './spaces.js'
10
+ import type { UserNamespace } from './user.js'
11
11
 
12
- import { createAppsNamespace } from './apps'
13
- import { createSpacesNamespace } from './spaces'
14
- import { createUserNamespace } from './user'
15
- import { createShellDomainView } from './view'
12
+ import { createAppsNamespace } from './apps.js'
13
+ import { createSpacesNamespace } from './spaces.js'
14
+ import { createUserNamespace } from './user.js'
15
+ import { createShellDomainView } from './view.js'
16
16
 
17
17
  export interface OsNamespaces {
18
18
  readonly user: UserNamespace
@@ -1,10 +1,10 @@
1
1
  import type { UnresolvedIdentityExpr } from '@astrale-os/kernel-core'
2
2
 
3
- import type { KernelClient } from '../../kernel/client'
4
- import type { MountCredential } from '../../window/mount/params'
5
- import type { AppSession, AppView } from './session'
3
+ import type { KernelClient } from '../../kernel/client.js'
4
+ import type { MountCredential } from '../../window/mount/params.js'
5
+ import type { AppSession, AppView } from './session.js'
6
6
 
7
- import { createTokenCycle } from './token'
7
+ import { createTokenCycle } from './token.js'
8
8
 
9
9
  /** The wire shape of `app::open`. */
10
10
  interface OpenResult {
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * `AppSession` — the client half of the three-call app-opening protocol
3
3
  * (`app::open` → user-signed `auth.delegate` → `app::getAccessToken`). The
4
- * server contract lives in the workspace domain's `Application` methods
4
+ * server contract lives in the shell domain's `Application` methods
5
5
  * (`runtime/application/{open,get-access-token}`).
6
6
  */
7
- import type { MountCredential } from '../../window/mount/params'
7
+ import type { MountCredential } from '../../window/mount/params.js'
8
8
 
9
9
  /** The entry view returned by `app::open`, described for mounting. */
10
10
  export interface AppView {
@@ -1,9 +1,9 @@
1
1
  import type { UnresolvedIdentityExpr } from '@astrale-os/kernel-core'
2
2
 
3
- import type { KernelClient } from '../../kernel/client'
3
+ import type { KernelClient } from '../../kernel/client.js'
4
4
 
5
- import { REFRESH_WINDOW_MS } from '../../kernel/delegation/token'
6
- import { AppSessionRefreshError } from './session'
5
+ import { REFRESH_WINDOW_MS } from '../../kernel/delegation/token.js'
6
+ import { AppSessionRefreshError } from './session.js'
7
7
 
8
8
  /** The wire shape of `app::getAccessToken`. */
9
9
  interface AccessTokenResult {
@@ -2,8 +2,8 @@ import type { BoundNode, DefOf, NodeRefInput } from '@astrale-os/kernel-client'
2
2
 
3
3
  import { normalizeRef } from '@astrale-os/kernel-client'
4
4
 
5
- import type { KernelClient } from '../kernel/client'
6
- import type { ShellDomainView, ShellSchema } from './view'
5
+ import type { KernelClient } from '../kernel/client.js'
6
+ import type { ShellDomainView, ShellSchema } from './view.js'
7
7
 
8
8
  /** A workspace `Space` node. */
9
9
  export type SpaceNode = BoundNode<DefOf<ShellSchema, 'Space'>, ShellSchema>
@@ -17,7 +17,7 @@ export interface SpacesNamespace {
17
17
  create(opts?: { name?: string }): Promise<SpaceNode>
18
18
  }
19
19
 
20
- /** The spaces directory (mirrors the workspace domain's `SPACES_DIR`). */
20
+ /** The spaces directory (mirrors the shell domain's `SPACES_DIR`). */
21
21
  const SPACES_DIR = '/spaces'
22
22
 
23
23
  export function createSpacesNamespace(kernel: KernelClient, v: ShellDomainView): SpacesNamespace {
@@ -2,11 +2,11 @@ import type { BoundNode, DefOf, NodeRefInput } from '@astrale-os/kernel-client'
2
2
 
3
3
  import { normalizeRef } from '@astrale-os/kernel-client'
4
4
 
5
- import type { KernelClient } from '../kernel/client'
6
- import type { SpaceNode } from './spaces'
7
- import type { ShellDomainView, ShellSchema } from './view'
5
+ import type { KernelClient } from '../kernel/client.js'
6
+ import type { SpaceNode } from './spaces.js'
7
+ import type { ShellDomainView, ShellSchema } from './view.js'
8
8
 
9
- import { asArray } from './view'
9
+ import { asArray } from './view.js'
10
10
 
11
11
  /** Self as the shell-domain `User` — typed `firstName`/`lastName`/`email`. */
12
12
  export type UserNode = BoundNode<DefOf<ShellSchema, 'User'>, ShellSchema>
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * The typed plane the OS namespaces speak: `kernel.withSchema(schema)` over the
3
- * workspace domain (`@astrale-domains/workspace-schema`). The bound view is built LAZILY
3
+ * shell domain (`@astrale-domains/shell-schema`). The bound view is built LAZILY
4
4
  * (first call) so the sandboxed shell's "init() first" kernel guard applies
5
5
  * uniformly — constructing namespaces touches no kernel.
6
6
  */
7
7
  import type { BoundNode, DefOf, SchemaBoundView } from '@astrale-os/kernel-client'
8
8
  import type { Node } from '@astrale-os/kernel-core'
9
9
 
10
- import { schema } from '@astrale-domains/workspace-schema'
10
+ import { schema } from '@astrale-domains/shell-schema'
11
11
 
12
- import type { KernelClient } from '../kernel/client'
12
+ import type { KernelClient } from '../kernel/client.js'
13
13
 
14
14
  export type ShellSchema = typeof schema
15
15
 
@@ -1,6 +1,6 @@
1
- import type { MessageOf, MessageType, ShellMessage } from '../message/message'
2
- import type { MessageObserver } from './observer'
3
- import type { Transport } from './transport'
1
+ import type { MessageOf, MessageType, ShellMessage } from '../message/message.js'
2
+ import type { MessageObserver } from './observer.js'
3
+ import type { Transport } from './transport.js'
4
4
 
5
5
  /** Multiplexed channels down to child windows, keyed by windowId. */
6
6
  export interface ChildrenChannel {
@@ -1,4 +1,4 @@
1
- import type { MessageHandler, MessageOf, MessageType, ShellMessage } from '../message/message'
1
+ import type { MessageHandler, MessageOf, MessageType, ShellMessage } from '../message/message.js'
2
2
 
3
3
  /** Per-message-type listener registry — the fan-out primitive channels share. */
4
4
  export interface MessageListeners {
@@ -1,5 +1,5 @@
1
- import type { ShellMessage } from '../message/message'
2
- import type { Transport } from './transport'
1
+ import type { ShellMessage } from '../message/message.js'
2
+ import type { Transport } from './transport.js'
3
3
 
4
4
  export type MessagePortTransportConfig = {
5
5
  port: MessagePort
@@ -1,4 +1,4 @@
1
- import type { ShellMessage } from '../message/message'
1
+ import type { ShellMessage } from '../message/message.js'
2
2
 
3
3
  export type MessageDirection = 'inbound' | 'outbound'
4
4
 
@@ -1,8 +1,8 @@
1
- import type { MessageHandler, MessageOf, MessageType, ShellMessage } from '../message/message'
2
- import type { MessageObserver } from './observer'
3
- import type { Transport } from './transport'
1
+ import type { MessageHandler, MessageOf, MessageType, ShellMessage } from '../message/message.js'
2
+ import type { MessageObserver } from './observer.js'
3
+ import type { Transport } from './transport.js'
4
4
 
5
- import { createMessageListeners } from './listeners'
5
+ import { createMessageListeners } from './listeners.js'
6
6
 
7
7
  /** The child's single channel up to its parent shell. */
8
8
  export interface ParentChannel {
@@ -1,4 +1,4 @@
1
- import type { ShellMessage } from '../message/message'
1
+ import type { ShellMessage } from '../message/message.js'
2
2
 
3
3
  /** The pipe a channel rides: one peer, ordered delivery, no reply semantics. */
4
4
  export interface Transport {
package/src/index.ts CHANGED
@@ -6,90 +6,90 @@ export type {
6
6
  ReplyOf,
7
7
  IntentEnvelope,
8
8
  IntentMessage,
9
- } from './message/intent'
10
- export type { CtrlRegistry, CtrlMessage } from './message/ctrl'
11
- export type { ErrorCode, ErrorMessage } from './message/error'
12
- export type { ShellMessage, MessageHandler } from './message/message'
9
+ } from './message/intent.js'
10
+ export type { CtrlRegistry, CtrlMessage } from './message/ctrl.js'
11
+ export type { ErrorCode, ErrorMessage } from './message/error.js'
12
+ export type { ShellMessage, MessageHandler } from './message/message.js'
13
13
  export {
14
14
  INIT_REQUEST_TYPE,
15
15
  INIT_RESPONSE_TYPE,
16
16
  isInitRequest,
17
17
  isInitResponse,
18
- } from './message/init'
19
- export type { InitRequestMessage, InitResponseMessage } from './message/init'
18
+ } from './message/init.js'
19
+ export type { InitRequestMessage, InitResponseMessage } from './message/init.js'
20
20
 
21
21
  // ─── kernel ─────────────────────────────────────────────────────────────────
22
- export type { KernelClient } from './kernel/client'
23
- export { createKernelClientAdapter } from './kernel/session'
24
- export type { KernelClientAdapter, CreateKernelClientAdapterOpts } from './kernel/session'
25
- export type { DelegationScope, DelegationToken, TokenState } from './kernel/delegation/token'
26
- export { stateOf, isExpired } from './kernel/delegation/token'
27
- export { createTokenRefresher } from './kernel/delegation/refresh'
28
- export type { TokenRefreshConfig, TokenRefresher } from './kernel/delegation/refresh'
22
+ export type { KernelClient } from './kernel/client.js'
23
+ export { createKernelClientAdapter } from './kernel/session.js'
24
+ export type { KernelClientAdapter, CreateKernelClientAdapterOpts } from './kernel/session.js'
25
+ export type { DelegationScope, DelegationToken, TokenState } from './kernel/delegation/token.js'
26
+ export { stateOf, isExpired } from './kernel/delegation/token.js'
27
+ export { createTokenRefresher } from './kernel/delegation/refresh.js'
28
+ export type { TokenRefreshConfig, TokenRefresher } from './kernel/delegation/refresh.js'
29
29
 
30
30
  // ─── channel ────────────────────────────────────────────────────────────────
31
- export type { Transport } from './channel/transport'
32
- export { createMessagePortTransport } from './channel/message-port'
33
- export type { MessagePortTransportConfig } from './channel/message-port'
34
- export type { ParentChannel } from './channel/parent'
35
- export type { ChildrenChannel } from './channel/children'
36
- export type { MessageDirection, ObserverHandler } from './channel/observer'
31
+ export type { Transport } from './channel/transport.js'
32
+ export { createMessagePortTransport } from './channel/message-port.js'
33
+ export type { MessagePortTransportConfig } from './channel/message-port.js'
34
+ export type { ParentChannel } from './channel/parent.js'
35
+ export type { ChildrenChannel } from './channel/children.js'
36
+ export type { MessageDirection, ObserverHandler } from './channel/observer.js'
37
37
 
38
38
  // ─── window ─────────────────────────────────────────────────────────────────
39
- export type { Window, WindowState } from './window/window'
40
- export type { WindowConfig, WindowCapabilities, SandboxProfile } from './window/capabilities'
41
- export { transition as lifecycleTransition } from './window/lifecycle/transition'
42
- export type { LifecycleEvent, TransitionResult } from './window/lifecycle/transition'
43
- export type { ShellAdapter, WindowHandle } from './window/embed/adapter'
44
- export { createIframeShellAdapter } from './window/embed/iframe'
45
- export type { IframeShellAdapterConfig } from './window/embed/iframe'
39
+ export type { Window, WindowState } from './window/window.js'
40
+ export type { WindowConfig, WindowCapabilities, SandboxProfile } from './window/capabilities.js'
41
+ export { transition as lifecycleTransition } from './window/lifecycle/transition.js'
42
+ export type { LifecycleEvent, TransitionResult } from './window/lifecycle/transition.js'
43
+ export type { ShellAdapter, WindowHandle } from './window/embed/adapter.js'
44
+ export { createIframeShellAdapter } from './window/embed/iframe.js'
45
+ export type { IframeShellAdapterConfig } from './window/embed/iframe.js'
46
46
  export type {
47
47
  MountParams,
48
48
  MountCredential,
49
49
  MountedWindow,
50
50
  CloseResult,
51
- } from './window/mount/params'
52
- export { runParentHandshake } from './window/mount/handshake'
53
- export type { HandshakeParams, HandshakeError, HandshakeResult } from './window/mount/handshake'
51
+ } from './window/mount/params.js'
52
+ export { runParentHandshake } from './window/mount/handshake.js'
53
+ export type { HandshakeParams, HandshakeError, HandshakeResult } from './window/mount/handshake.js'
54
54
 
55
55
  // ─── intent ─────────────────────────────────────────────────────────────────
56
- export { createIntentPipeline } from './intent/pipeline'
57
- export type { IntentMiddleware, IntentPipeline } from './intent/pipeline'
58
- export type { IntentDecision, IntentOrigin, IntentPolicy, IntentContext } from './intent/policy'
59
- export { createIntentRouter } from './intent/router'
56
+ export { createIntentPipeline } from './intent/pipeline.js'
57
+ export type { IntentMiddleware, IntentPipeline } from './intent/pipeline.js'
58
+ export type { IntentDecision, IntentOrigin, IntentPolicy, IntentContext } from './intent/policy.js'
59
+ export { createIntentRouter } from './intent/router.js'
60
60
  export type {
61
61
  IntentRouter,
62
62
  IntentRouterController,
63
63
  IntentRouterConfig,
64
64
  LocalIntentHandler,
65
- } from './intent/router'
66
- export { requestIntent, replyToIntent } from './intent/request'
67
- export { loggingMiddleware } from './intent/middleware/logging'
68
- export type { LoggingConfig, LoggingEntry, LoggingSink } from './intent/middleware/logging'
69
- export { capabilitiesMiddleware } from './intent/middleware/capabilities'
65
+ } from './intent/router.js'
66
+ export { requestIntent, replyToIntent } from './intent/request.js'
67
+ export { loggingMiddleware } from './intent/middleware/logging.js'
68
+ export type { LoggingConfig, LoggingEntry, LoggingSink } from './intent/middleware/logging.js'
69
+ export { capabilitiesMiddleware } from './intent/middleware/capabilities.js'
70
70
  export type {
71
71
  CapabilitiesConfig,
72
72
  CapabilityLookup,
73
73
  CapabilityViolation,
74
- } from './intent/middleware/capabilities'
75
- export { rateLimitMiddleware } from './intent/middleware/rate-limit'
76
- export type { RateLimitConfig, RateLimitViolation } from './intent/middleware/rate-limit'
74
+ } from './intent/middleware/capabilities.js'
75
+ export { rateLimitMiddleware } from './intent/middleware/rate-limit.js'
76
+ export type { RateLimitConfig, RateLimitViolation } from './intent/middleware/rate-limit.js'
77
77
 
78
78
  // ─── application (OS plane: shell.user / .spaces / .apps) ───────────────────
79
- export { createOsNamespaces } from './application/namespaces'
80
- export type { OsNamespaces, CreateOsNamespacesDeps } from './application/namespaces'
81
- export type { UserNamespace, UserNode, RoleNode } from './application/user'
82
- export type { SpacesNamespace, SpaceNode } from './application/spaces'
83
- export type { AppsNamespace, ApplicationNode } from './application/apps'
84
- export { openAppSession } from './application/session/open'
85
- export type { OpenAppSessionDeps } from './application/session/open'
86
- export { AppSessionRefreshError } from './application/session/session'
87
- export type { AppSession, AppView, RefreshStep } from './application/session/session'
79
+ export { createOsNamespaces } from './application/namespaces.js'
80
+ export type { OsNamespaces, CreateOsNamespacesDeps } from './application/namespaces.js'
81
+ export type { UserNamespace, UserNode, RoleNode } from './application/user.js'
82
+ export type { SpacesNamespace, SpaceNode } from './application/spaces.js'
83
+ export type { AppsNamespace, ApplicationNode } from './application/apps.js'
84
+ export { openAppSession } from './application/session/open.js'
85
+ export type { OpenAppSessionDeps } from './application/session/open.js'
86
+ export { AppSessionRefreshError } from './application/session/session.js'
87
+ export type { AppSession, AppView, RefreshStep } from './application/session/session.js'
88
88
 
89
89
  // ─── shell ──────────────────────────────────────────────────────────────────
90
- export { createShell } from './shell/create'
91
- export type { Shell } from './shell/shell'
92
- export type { ShellConfig, StandaloneConfig, SandboxedConfig } from './shell/config'
93
- export { requestAccess } from './shell/access'
94
- export { performChildInit } from './shell/sandboxed/boot'
95
- export type { ChildInitParams, ChildInitResult } from './shell/sandboxed/boot'
90
+ export { createShell } from './shell/create.js'
91
+ export type { Shell } from './shell/shell.js'
92
+ export type { ShellConfig, StandaloneConfig, SandboxedConfig } from './shell/config.js'
93
+ export { requestAccess } from './shell/access.js'
94
+ export { performChildInit } from './shell/sandboxed/boot.js'
95
+ export type { ChildInitParams, ChildInitResult } from './shell/sandboxed/boot.js'
@@ -1,6 +1,6 @@
1
- import type { IntentMessage, IntentRegistry } from '../../message/intent'
2
- import type { WindowCapabilities } from '../../window/capabilities'
3
- import type { IntentMiddleware } from '../pipeline'
1
+ import type { IntentMessage, IntentRegistry } from '../../message/intent.js'
2
+ import type { WindowCapabilities } from '../../window/capabilities.js'
3
+ import type { IntentMiddleware } from '../pipeline.js'
4
4
 
5
5
  export type CapabilityLookup = (sender: string) => WindowCapabilities | undefined
6
6
 
@@ -1,5 +1,5 @@
1
- import type { IntentMessage } from '../../message/intent'
2
- import type { IntentMiddleware } from '../pipeline'
1
+ import type { IntentMessage } from '../../message/intent.js'
2
+ import type { IntentMiddleware } from '../pipeline.js'
3
3
 
4
4
  export type LoggingSink = (entry: LoggingEntry) => void
5
5
 
@@ -1,5 +1,5 @@
1
- import type { IntentMessage } from '../../message/intent'
2
- import type { IntentMiddleware } from '../pipeline'
1
+ import type { IntentMessage } from '../../message/intent.js'
2
+ import type { IntentMiddleware } from '../pipeline.js'
3
3
 
4
4
  export type RateLimitKey = (message: IntentMessage) => string
5
5
 
@@ -1,4 +1,4 @@
1
- import type { IntentMessage } from '../message/intent'
1
+ import type { IntentMessage } from '../message/intent.js'
2
2
 
3
3
  export type IntentMiddleware = (message: IntentMessage, next: () => Promise<void>) => Promise<void>
4
4
 
@@ -1,5 +1,5 @@
1
- import type { IntentMessage, IntentRegistry } from '../message/intent'
2
- import type { Window } from '../window/window'
1
+ import type { IntentMessage, IntentRegistry } from '../message/intent.js'
2
+ import type { Window } from '../window/window.js'
3
3
 
4
4
  /**
5
5
  * Decision produced by a routing policy: where an inbound intent should go.
@@ -1,6 +1,6 @@
1
- import type { ChildrenChannel } from '../channel/children'
2
- import type { ParentChannel } from '../channel/parent'
3
- import type { IntentMessage, IntentRegistry, PayloadOf, ReplyOf } from '../message/intent'
1
+ import type { ChildrenChannel } from '../channel/children.js'
2
+ import type { ParentChannel } from '../channel/parent.js'
3
+ import type { IntentMessage, IntentRegistry, PayloadOf, ReplyOf } from '../message/intent.js'
4
4
 
5
5
  /**
6
6
  * Request/reply over the otherwise fire-and-forget intent transport.
@@ -1,11 +1,11 @@
1
- import type { ChildrenChannelController } from '../channel/children'
2
- import type { ParentChannel } from '../channel/parent'
3
- import type { IntentMessage, IntentRegistry } from '../message/intent'
4
- import type { Window } from '../window/window'
5
- import type { IntentPipeline } from './pipeline'
6
- import type { IntentDecision, IntentOrigin, IntentPolicy } from './policy'
1
+ import type { ChildrenChannelController } from '../channel/children.js'
2
+ import type { ParentChannel } from '../channel/parent.js'
3
+ import type { IntentMessage, IntentRegistry } from '../message/intent.js'
4
+ import type { Window } from '../window/window.js'
5
+ import type { IntentPipeline } from './pipeline.js'
6
+ import type { IntentDecision, IntentOrigin, IntentPolicy } from './policy.js'
7
7
 
8
- import { defaultPolicy } from './policy'
8
+ import { defaultPolicy } from './policy.js'
9
9
 
10
10
  /** Minimal dispatch-only router surface (no current in-package implementer). */
11
11
  export interface IntentRouter {
@@ -1,5 +1,5 @@
1
- import type { KernelClient } from './client'
2
- import type { KernelClientAdapter } from './session'
1
+ import type { KernelClient } from './client.js'
2
+ import type { KernelClientAdapter } from './session.js'
3
3
 
4
4
  export type KernelFacadeConfig = {
5
5
  adapter: KernelClientAdapter
@@ -1,8 +1,8 @@
1
- import type { KernelFacadeController } from './credential'
2
- import type { DelegationToken } from './delegation/token'
3
- import type { KernelClientAdapter } from './session'
1
+ import type { KernelFacadeController } from './credential.js'
2
+ import type { DelegationToken } from './delegation/token.js'
3
+ import type { KernelClientAdapter } from './session.js'
4
4
 
5
- import { buildCredentialFacade } from './credential'
5
+ import { buildCredentialFacade } from './credential.js'
6
6
 
7
7
  export type DelegationKernelFacadeConfig = {
8
8
  adapter: KernelClientAdapter