@adea-ai/app-framework 0.0.0-stage → 0.24.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 (358) hide show
  1. package/LICENSE +201 -0
  2. package/NOTICE +30 -0
  3. package/README.md +1009 -2
  4. package/dist/app/application.d.ts +47 -0
  5. package/dist/app/application.js +115 -0
  6. package/dist/app/create-application.d.ts +13 -0
  7. package/dist/app/create-application.js +178 -0
  8. package/dist/app/service-registry.d.ts +44 -0
  9. package/dist/app/service-registry.js +116 -0
  10. package/dist/appearance/appearance-host.d.ts +62 -0
  11. package/dist/appearance/appearance-host.js +115 -0
  12. package/dist/appearance/appearance-preferences.d.ts +106 -0
  13. package/dist/appearance/appearance-preferences.js +175 -0
  14. package/dist/appearance/composition.d.ts +11 -0
  15. package/dist/appearance/composition.js +16 -0
  16. package/dist/appearance/custom-theme-import.d.ts +14 -0
  17. package/dist/appearance/custom-theme-import.js +315 -0
  18. package/dist/appearance/custom-theme-library.d.ts +146 -0
  19. package/dist/appearance/custom-theme-library.js +378 -0
  20. package/dist/appearance/editor.d.ts +20 -0
  21. package/dist/appearance/editor.js +47 -0
  22. package/dist/appearance/theme-file-importer.d.ts +23 -0
  23. package/dist/appearance/theme-file-importer.js +66 -0
  24. package/dist/appearance/theme-record-adapter.d.ts +26 -0
  25. package/dist/appearance/theme-record-adapter.js +64 -0
  26. package/dist/appearance/theme-registry.d.ts +10 -0
  27. package/dist/appearance/theme-registry.js +16 -0
  28. package/dist/appearance/window-surface.d.ts +5 -0
  29. package/dist/appearance/window-surface.js +9 -0
  30. package/dist/ci/toolchain-identity.d.ts +39 -0
  31. package/dist/ci/toolchain-identity.js +196 -0
  32. package/dist/cli/cef-helper-cli.d.ts +2 -0
  33. package/dist/cli/cef-helper-cli.js +18 -0
  34. package/dist/cli/cli-runner.d.ts +8 -0
  35. package/dist/cli/cli-runner.js +23 -0
  36. package/dist/cli/create-application-cli.d.ts +2 -0
  37. package/dist/cli/create-application-cli.js +40 -0
  38. package/dist/cli/electrobun-shortcut-patch-cli.d.ts +2 -0
  39. package/dist/cli/electrobun-shortcut-patch-cli.js +17 -0
  40. package/dist/cli/framework-update-cli.d.ts +2 -0
  41. package/dist/cli/framework-update-cli.js +40 -0
  42. package/dist/cli/release-assets-plan-cli.d.ts +2 -0
  43. package/dist/cli/release-assets-plan-cli.js +14 -0
  44. package/dist/cli/release-cut-cli.d.ts +2 -0
  45. package/dist/cli/release-cut-cli.js +27 -0
  46. package/dist/cli/release-descriptor-staging-cli.d.ts +2 -0
  47. package/dist/cli/release-descriptor-staging-cli.js +45 -0
  48. package/dist/cli/release-finalize-cli.d.ts +1 -0
  49. package/dist/cli/release-finalize-cli.js +30 -0
  50. package/dist/cli/release-promote-cli.d.ts +2 -0
  51. package/dist/cli/release-promote-cli.js +32 -0
  52. package/dist/cli/release-publish-cli.d.ts +2 -0
  53. package/dist/cli/release-publish-cli.js +48 -0
  54. package/dist/cli/release-sign-cli.d.ts +2 -0
  55. package/dist/cli/release-sign-cli.js +13 -0
  56. package/dist/cli/release-step-cli.d.ts +2 -0
  57. package/dist/cli/release-step-cli.js +44 -0
  58. package/dist/cli/toolchain-identity-cli.d.ts +2 -0
  59. package/dist/cli/toolchain-identity-cli.js +10 -0
  60. package/dist/cli/update-helper-cli.d.ts +1 -0
  61. package/dist/cli/update-helper-cli.js +10 -0
  62. package/dist/cli/windows-runtime-patch-cli.d.ts +2 -0
  63. package/dist/cli/windows-runtime-patch-cli.js +17 -0
  64. package/dist/desktop/application-command-client.d.ts +15 -0
  65. package/dist/desktop/application-command-client.js +21 -0
  66. package/dist/desktop/channel-handshake.d.ts +32 -0
  67. package/dist/desktop/channel-handshake.js +111 -0
  68. package/dist/desktop/channel-proof.d.ts +43 -0
  69. package/dist/desktop/channel-proof.js +85 -0
  70. package/dist/desktop/client-assets.d.ts +7 -0
  71. package/dist/desktop/client-assets.js +59 -0
  72. package/dist/desktop/desktop-client.d.ts +23 -0
  73. package/dist/desktop/desktop-client.js +231 -0
  74. package/dist/desktop/desktop-gateway.d.ts +18 -0
  75. package/dist/desktop/desktop-gateway.js +146 -0
  76. package/dist/desktop/desktop-host.d.ts +48 -0
  77. package/dist/desktop/desktop-host.js +208 -0
  78. package/dist/desktop/desktop-stream.d.ts +36 -0
  79. package/dist/desktop/desktop-stream.js +231 -0
  80. package/dist/desktop/loopback-policy.d.ts +19 -0
  81. package/dist/desktop/loopback-policy.js +23 -0
  82. package/dist/desktop/open-url-channel.d.ts +15 -0
  83. package/dist/desktop/open-url-channel.js +55 -0
  84. package/dist/desktop/string-policy.d.ts +2 -0
  85. package/dist/desktop/string-policy.js +11 -0
  86. package/dist/framework-source.json +1 -0
  87. package/dist/installer/archive-entry.d.ts +6 -0
  88. package/dist/installer/archive-entry.js +14 -0
  89. package/dist/installer/command-artifact.d.ts +47 -0
  90. package/dist/installer/command-artifact.js +261 -0
  91. package/dist/installer/command-qualification-command.d.ts +12 -0
  92. package/dist/installer/command-qualification-command.js +71 -0
  93. package/dist/installer/hosted-runner.d.ts +4 -0
  94. package/dist/installer/hosted-runner.js +10 -0
  95. package/dist/installer/installed-payload.d.ts +29 -0
  96. package/dist/installer/installed-payload.js +312 -0
  97. package/dist/installer/installer-ci-bootstrap.d.ts +26 -0
  98. package/dist/installer/installer-ci-bootstrap.js +160 -0
  99. package/dist/installer/installer-ci-preflight.d.ts +1 -0
  100. package/dist/installer/installer-ci-preflight.js +49 -0
  101. package/dist/installer/installer-ci-worker.d.ts +1 -0
  102. package/dist/installer/installer-ci-worker.js +105 -0
  103. package/dist/installer/installer-extraction.d.ts +14 -0
  104. package/dist/installer/installer-extraction.js +289 -0
  105. package/dist/installer/installer-fetch-guard.d.ts +15 -0
  106. package/dist/installer/installer-fetch-guard.js +50 -0
  107. package/dist/installer/installer-identity.d.ts +23 -0
  108. package/dist/installer/installer-identity.js +286 -0
  109. package/dist/installer/installer-layout.d.ts +21 -0
  110. package/dist/installer/installer-layout.js +89 -0
  111. package/dist/installer/installer-observation.d.ts +64 -0
  112. package/dist/installer/installer-observation.js +473 -0
  113. package/dist/installer/installer-process-cleanup.d.ts +18 -0
  114. package/dist/installer/installer-process-cleanup.js +158 -0
  115. package/dist/installer/installer-qualification-command.d.ts +11 -0
  116. package/dist/installer/installer-qualification-command.js +71 -0
  117. package/dist/installer/installer-renderer-evidence.d.ts +43 -0
  118. package/dist/installer/installer-renderer-evidence.js +136 -0
  119. package/dist/installer/installer-upgrade-command.d.ts +37 -0
  120. package/dist/installer/installer-upgrade-command.js +172 -0
  121. package/dist/installer/installer-worker-guard.d.ts +21 -0
  122. package/dist/installer/installer-worker-guard.js +72 -0
  123. package/dist/installer/native-executable.d.ts +5 -0
  124. package/dist/installer/native-executable.js +21 -0
  125. package/dist/installer/upgrade-asset-download.d.ts +13 -0
  126. package/dist/installer/upgrade-asset-download.js +41 -0
  127. package/dist/installer/write-all.d.ts +6 -0
  128. package/dist/installer/write-all.js +11 -0
  129. package/dist/native/app-bundle.d.ts +28 -0
  130. package/dist/native/app-bundle.js +60 -0
  131. package/dist/native/cef-helper.d.ts +28 -0
  132. package/dist/native/cef-helper.js +402 -0
  133. package/dist/native/desktop-build-hook.d.ts +7 -0
  134. package/dist/native/desktop-build-hook.js +20 -0
  135. package/dist/native/electrobun-source-patch.d.ts +25 -0
  136. package/dist/native/electrobun-source-patch.js +93 -0
  137. package/dist/native/linux-cef-links.d.ts +2 -0
  138. package/dist/native/linux-cef-links.js +15 -0
  139. package/dist/native/native-secret-store.d.ts +27 -0
  140. package/dist/native/native-secret-store.js +70 -0
  141. package/dist/native/native-utilities.d.ts +24 -0
  142. package/dist/native/native-utilities.js +85 -0
  143. package/dist/native/partitioned-window.d.ts +34 -0
  144. package/dist/native/partitioned-window.js +44 -0
  145. package/dist/native/renderer-profile.d.ts +53 -0
  146. package/dist/native/renderer-profile.js +30 -0
  147. package/dist/native/secure-window.d.ts +38 -0
  148. package/dist/native/secure-window.js +77 -0
  149. package/dist/native/sidecar-services.d.ts +23 -0
  150. package/dist/native/sidecar-services.js +46 -0
  151. package/dist/native/sidecar.d.ts +81 -0
  152. package/dist/native/sidecar.js +250 -0
  153. package/dist/native/window-bootstrap.d.ts +24 -0
  154. package/dist/native/window-bootstrap.js +63 -0
  155. package/dist/native/window-options.d.ts +32 -0
  156. package/dist/native/window-options.js +23 -0
  157. package/dist/native/windows-build-hook-internal.d.ts +2 -0
  158. package/dist/native/windows-build-hook-internal.js +32 -0
  159. package/dist/native/windows-build-hook.d.ts +2 -0
  160. package/dist/native/windows-build-hook.js +12 -0
  161. package/dist/native/windows-runtime-patch-internal.d.ts +3 -0
  162. package/dist/native/windows-runtime-patch-internal.js +20 -0
  163. package/dist/native/windows-runtime-patch.d.ts +4 -0
  164. package/dist/native/windows-runtime-patch.js +12 -0
  165. package/dist/release/feed-release-cut.d.ts +23 -0
  166. package/dist/release/feed-release-cut.js +93 -0
  167. package/dist/release/feed-state.d.ts +25 -0
  168. package/dist/release/feed-state.js +81 -0
  169. package/dist/release/framework-package-publish.d.ts +21 -0
  170. package/dist/release/framework-package-publish.js +127 -0
  171. package/dist/release/framework-update.d.ts +30 -0
  172. package/dist/release/framework-update.js +139 -0
  173. package/dist/release/github-cli.d.ts +6 -0
  174. package/dist/release/github-cli.js +16 -0
  175. package/dist/release/github-release-assets.d.ts +3 -0
  176. package/dist/release/github-release-assets.js +24 -0
  177. package/dist/release/github-release-cut.d.ts +14 -0
  178. package/dist/release/github-release-cut.js +174 -0
  179. package/dist/release/github-release-lookup.d.ts +7 -0
  180. package/dist/release/github-release-lookup.js +29 -0
  181. package/dist/release/github-release-promotion.d.ts +10 -0
  182. package/dist/release/github-release-promotion.js +78 -0
  183. package/dist/release/github-release-provenance.d.ts +9 -0
  184. package/dist/release/github-release-provenance.js +27 -0
  185. package/dist/release/github-release-publisher.d.ts +9 -0
  186. package/dist/release/github-release-publisher.js +63 -0
  187. package/dist/release/github-release-qualification.d.ts +12 -0
  188. package/dist/release/github-release-qualification.js +80 -0
  189. package/dist/release/local-provenance.d.ts +24 -0
  190. package/dist/release/local-provenance.js +72 -0
  191. package/dist/release/local-release.d.ts +133 -0
  192. package/dist/release/local-release.js +387 -0
  193. package/dist/release/macos-dmg.d.ts +22 -0
  194. package/dist/release/macos-dmg.js +91 -0
  195. package/dist/release/release-artifact.d.ts +6 -0
  196. package/dist/release/release-artifact.js +38 -0
  197. package/dist/release/release-assets-plan.d.ts +14 -0
  198. package/dist/release/release-assets-plan.js +65 -0
  199. package/dist/release/release-config.d.ts +76 -0
  200. package/dist/release/release-config.js +180 -0
  201. package/dist/release/release-cut-command.d.ts +13 -0
  202. package/dist/release/release-cut-command.js +39 -0
  203. package/dist/release/release-cut.d.ts +54 -0
  204. package/dist/release/release-cut.js +76 -0
  205. package/dist/release/release-descriptor-staging.d.ts +34 -0
  206. package/dist/release/release-descriptor-staging.js +147 -0
  207. package/dist/release/release-finalize.d.ts +16 -0
  208. package/dist/release/release-finalize.js +104 -0
  209. package/dist/release/release-promotion-command.d.ts +12 -0
  210. package/dist/release/release-promotion-command.js +28 -0
  211. package/dist/release/release-promotion.d.ts +29 -0
  212. package/dist/release/release-promotion.js +57 -0
  213. package/dist/release/release-publication.d.ts +33 -0
  214. package/dist/release/release-publication.js +138 -0
  215. package/dist/release/release-publish-command.d.ts +7 -0
  216. package/dist/release/release-publish-command.js +91 -0
  217. package/dist/release/release-qualification.d.ts +106 -0
  218. package/dist/release/release-qualification.js +135 -0
  219. package/dist/release/release-staging.d.ts +9 -0
  220. package/dist/release/release-staging.js +61 -0
  221. package/dist/release/release-steps.d.ts +38 -0
  222. package/dist/release/release-steps.js +147 -0
  223. package/dist/release/retained-release-build.d.ts +19 -0
  224. package/dist/release/retained-release-build.js +122 -0
  225. package/dist/shell/app-shell.d.ts +61 -0
  226. package/dist/shell/app-shell.js +306 -0
  227. package/dist/shell/app-utilities.d.ts +122 -0
  228. package/dist/shell/app-utilities.js +334 -0
  229. package/dist/shell/application-menu-commands.d.ts +5 -0
  230. package/dist/shell/application-menu-commands.js +11 -0
  231. package/dist/shell/application-menu.d.ts +61 -0
  232. package/dist/shell/application-menu.js +208 -0
  233. package/dist/shell/help-shortcuts.d.ts +12 -0
  234. package/dist/shell/help-shortcuts.js +22 -0
  235. package/dist/shell/navigation-drawer.d.ts +12 -0
  236. package/dist/shell/navigation-drawer.js +42 -0
  237. package/dist/shell/settings-sections.d.ts +31 -0
  238. package/dist/shell/settings-sections.js +50 -0
  239. package/dist/shell/shortcut-platform.d.ts +17 -0
  240. package/dist/shell/shortcut-platform.js +25 -0
  241. package/dist/update-helper.bundle.js +260 -0
  242. package/dist/updates/channel-update-manager.d.ts +46 -0
  243. package/dist/updates/channel-update-manager.js +114 -0
  244. package/dist/updates/desktop-updater.d.ts +104 -0
  245. package/dist/updates/desktop-updater.js +345 -0
  246. package/dist/updates/release-feed.d.ts +61 -0
  247. package/dist/updates/release-feed.js +111 -0
  248. package/dist/updates/release-location.d.ts +9 -0
  249. package/dist/updates/release-location.js +80 -0
  250. package/dist/updates/release-version.d.ts +12 -0
  251. package/dist/updates/release-version.js +43 -0
  252. package/dist/updates/signed-release.d.ts +63 -0
  253. package/dist/updates/signed-release.js +162 -0
  254. package/dist/updates/stable-file.d.ts +10 -0
  255. package/dist/updates/stable-file.js +22 -0
  256. package/dist/updates/update-adapter.d.ts +57 -0
  257. package/dist/updates/update-adapter.js +72 -0
  258. package/dist/updates/update-arm.d.ts +24 -0
  259. package/dist/updates/update-arm.js +95 -0
  260. package/dist/updates/update-channel-store.d.ts +8 -0
  261. package/dist/updates/update-channel-store.js +72 -0
  262. package/dist/updates/update-discovery.d.ts +13 -0
  263. package/dist/updates/update-discovery.js +56 -0
  264. package/dist/updates/update-download.d.ts +14 -0
  265. package/dist/updates/update-download.js +67 -0
  266. package/dist/updates/update-exclusive-rename.d.ts +2 -0
  267. package/dist/updates/update-exclusive-rename.js +52 -0
  268. package/dist/updates/update-extraction.d.ts +18 -0
  269. package/dist/updates/update-extraction.js +183 -0
  270. package/dist/updates/update-handoff-plan.d.ts +22 -0
  271. package/dist/updates/update-handoff-plan.js +28 -0
  272. package/dist/updates/update-helper.d.ts +24 -0
  273. package/dist/updates/update-helper.js +56 -0
  274. package/dist/updates/update-launch.d.ts +5 -0
  275. package/dist/updates/update-launch.js +27 -0
  276. package/dist/updates/update-manager.d.ts +40 -0
  277. package/dist/updates/update-manager.js +83 -0
  278. package/dist/updates/update-process-fence.d.ts +10 -0
  279. package/dist/updates/update-process-fence.js +114 -0
  280. package/dist/updates/update-resume.d.ts +13 -0
  281. package/dist/updates/update-resume.js +34 -0
  282. package/dist/updates/update-shutdown.d.ts +15 -0
  283. package/dist/updates/update-shutdown.js +29 -0
  284. package/dist/updates/update-state.d.ts +30 -0
  285. package/dist/updates/update-state.js +18 -0
  286. package/dist/updates/update-swap-stage.d.ts +27 -0
  287. package/dist/updates/update-swap-stage.js +58 -0
  288. package/dist/updates/update-swap.d.ts +10 -0
  289. package/dist/updates/update-swap.js +30 -0
  290. package/dist/views/app-about.d.ts +22 -0
  291. package/dist/views/app-about.js +43 -0
  292. package/dist/views/app-appearance.d.ts +11 -0
  293. package/dist/views/app-appearance.js +42 -0
  294. package/dist/views/app-help.d.ts +17 -0
  295. package/dist/views/app-help.js +42 -0
  296. package/dist/views/app-settings.d.ts +26 -0
  297. package/dist/views/app-settings.js +97 -0
  298. package/dist/views/appearance-surface.d.ts +9 -0
  299. package/dist/views/appearance-surface.js +334 -0
  300. package/dist/views/update-surface.d.ts +34 -0
  301. package/dist/views/update-surface.js +64 -0
  302. package/package.json +374 -4
  303. package/src/app/application.tsx +138 -0
  304. package/src/appearance/appearance-host.tsx +205 -0
  305. package/src/appearance/appearance-preferences.ts +287 -0
  306. package/src/appearance/composition.ts +29 -0
  307. package/src/appearance/custom-theme-import.ts +424 -0
  308. package/src/appearance/custom-theme-library.ts +600 -0
  309. package/src/appearance/editor.ts +94 -0
  310. package/src/appearance/theme-file-importer.ts +103 -0
  311. package/src/appearance/theme-record-adapter.ts +106 -0
  312. package/src/appearance/theme-registry.ts +20 -0
  313. package/src/appearance/window-surface.ts +18 -0
  314. package/src/desktop/client-assets.ts +75 -0
  315. package/src/native/electrobun-cef-main-frame-bridges.patch +63 -0
  316. package/src/native/electrobun-windows-shortcut-com.patch +923 -0
  317. package/src/native/renderer-profile.ts +27 -0
  318. package/src/native/window-options.ts +24 -0
  319. package/src/shell/app-shell.tsx +294 -0
  320. package/src/shell/app-utilities.tsx +437 -0
  321. package/src/shell/help-shortcuts.ts +24 -0
  322. package/src/shell/navigation-drawer.tsx +36 -0
  323. package/src/shell/settings-sections.ts +74 -0
  324. package/src/shell/shortcut-platform.ts +35 -0
  325. package/src/updates/release-version.ts +57 -0
  326. package/src/updates/update-adapter.ts +129 -0
  327. package/src/updates/update-state.ts +34 -0
  328. package/src/views/app-about.tsx +44 -0
  329. package/src/views/app-appearance.tsx +32 -0
  330. package/src/views/app-help.tsx +43 -0
  331. package/src/views/app-settings.tsx +88 -0
  332. package/src/views/appearance-surface.tsx +427 -0
  333. package/src/views/update-surface.tsx +85 -0
  334. package/templates/application/.gitattributes +1 -0
  335. package/templates/application/.github/workflows/release-assets.yml +29 -0
  336. package/templates/application/.github/workflows/release-finalize.yml +29 -0
  337. package/templates/application/.github/workflows/release-please.yml +19 -0
  338. package/templates/application/.github/workflows/release.yml +29 -0
  339. package/templates/application/.github/workflows/validation.yml +28 -0
  340. package/templates/application/.oxfmtrc.json +6 -0
  341. package/templates/application/.oxlintrc.json +48 -0
  342. package/templates/application/.release-please-manifest.json +3 -0
  343. package/templates/application/README.md +47 -0
  344. package/templates/application/electrobun.config.ts +22 -0
  345. package/templates/application/release-please-config.json +12 -0
  346. package/templates/application/scripts/app-version.ts +9 -0
  347. package/templates/application/scripts/build-desktop.ts +34 -0
  348. package/templates/application/scripts/secure-build.ts +1 -0
  349. package/templates/application/scripts/stage-release.ts +21 -0
  350. package/templates/application/src/bun/index.ts +80 -0
  351. package/templates/application/src/electrobun.d.ts +27 -0
  352. package/templates/application/src/web/index.html +12 -0
  353. package/templates/application/src/web/main.tsx +97 -0
  354. package/templates/application/src/web/public/icon.svg +1 -0
  355. package/templates/application/src/web/style.css +3 -0
  356. package/templates/application/tests/app-config.test.ts +9 -0
  357. package/templates/application/tsconfig.json +15 -0
  358. package/templates/application/vite.config.ts +10 -0
@@ -0,0 +1,334 @@
1
+ import { defineSettingsSections, settingsSectionFromHash } from "./settings-sections.js";
2
+ import { detectShortcutPlatform, resolveShortcutPlatform, settingsShortcutLabel, shortcutModifierKey } from "./shortcut-platform.js";
3
+ import { browserUpdateAdapter } from "../updates/update-adapter.js";
4
+ import { createComponent, memo, mergeProps, template } from "solid-js/web";
5
+ import { Show, Suspense, createEffect, createMemo, createSignal, lazy, on, onCleanup, onMount } from "solid-js";
6
+ import { Palette } from "lucide-solid";
7
+ import { AccountMenu, createAppMenuItems } from "@adea-ai/ui/components/composites/account-menu";
8
+ import { ThemeProvider } from "@adea-ai/ui/components/theme/lazy";
9
+ // src/shell/app-utilities.tsx
10
+ var _tmpl$ = /*#__PURE__*/ template(`<span role=status>Loading…`);
11
+ var AppearancePanel = lazy(() => import("@adea-ai/ui/components/theme").then((module) => ({ default: module.AppearancePanel })));
12
+ var ApplicationAppearance = lazy(() => import("../views/app-appearance.js").then((module) => ({ default: module.ApplicationAppearance })));
13
+ var ApplicationAbout = lazy(() => import("../views/app-about.js").then((module) => ({ default: module.ApplicationAbout })));
14
+ var ApplicationSettings = lazy(() => import("../views/app-settings.js").then((module) => ({ default: module.ApplicationSettings })));
15
+ var ApplicationHelp = lazy(() => import("../views/app-help.js").then((module) => ({ default: module.ApplicationHelp })));
16
+ var UpdateSurface = lazy(() => import("../views/update-surface.js").then((module) => ({ default: module.ApplicationUpdateSurface })));
17
+ /** Theme selection and persistence are supplied by the shared design system. */
18
+ function ApplicationThemeProvider(props) {
19
+ return createComponent(ThemeProvider, mergeProps(props, { get children() {
20
+ return props.children;
21
+ } }));
22
+ }
23
+ var appearanceSectionId = "appearance";
24
+ var settingsKeyshortcuts = "Meta+, Control+,";
25
+ function isSettingsChord(event) {
26
+ return !event.defaultPrevented && (event.metaKey || event.ctrlKey) && !event.altKey && !event.shiftKey && event.key === ",";
27
+ }
28
+ function placeAppearance(sections, appearance, position) {
29
+ const index = position === "end" ? sections.length : typeof position === "number" ? Math.max(0, Math.min(sections.length, Math.trunc(position))) : 0;
30
+ return [
31
+ ...sections.slice(0, index),
32
+ appearance,
33
+ ...sections.slice(index)
34
+ ];
35
+ }
36
+ /** Shared account menu and application dialogs. Mount inside ApplicationThemeProvider. */
37
+ function ApplicationUtilities(props) {
38
+ const [dialog, setDialog] = createSignal();
39
+ const [mounted, setMounted] = createSignal(/* @__PURE__ */ new Set());
40
+ const [localSection, setLocalSection] = createSignal();
41
+ let opener;
42
+ const appearanceOption = () => props.settings?.appearance ?? true;
43
+ const settingsSections = createMemo(() => {
44
+ const settings = props.settings;
45
+ if (!settings) return void 0;
46
+ const option = appearanceOption();
47
+ if (option === false) return defineSettingsSections(settings.sections);
48
+ const placement = option === true ? {} : option;
49
+ return defineSettingsSections(placeAppearance(settings.sections, {
50
+ id: appearanceSectionId,
51
+ label: placement.label ?? "Appearance",
52
+ group: placement.group ?? "Application",
53
+ icon: createComponent(Palette, { "aria-hidden": "true" }),
54
+ render: () => props.appearance ?? createComponent(AppearancePanel, {})
55
+ }, placement.position));
56
+ });
57
+ const hasAppearanceSection = () => Boolean(props.settings) && appearanceOption() !== false;
58
+ const knownSection = (id) => id !== void 0 && Boolean(settingsSections()?.some((item) => item.id === id));
59
+ const defaultSection = () => {
60
+ const preferred = props.settings?.defaultSection;
61
+ return knownSection(preferred) ? preferred : settingsSections()?.[0]?.id;
62
+ };
63
+ const section = () => {
64
+ const controlled = props.settings?.section;
65
+ if (controlled !== void 0) return controlled;
66
+ return localSection() ?? defaultSection() ?? "";
67
+ };
68
+ const selectSection = (id) => {
69
+ const changed = id !== section();
70
+ setLocalSection(id);
71
+ if (changed) props.settings?.onSectionChange?.(id);
72
+ };
73
+ const settingsOpen = () => props.settings?.open !== void 0 ? props.settings.open : dialog() === "settings";
74
+ const updatesAlways = () => props.accountMenu?.updates === "always";
75
+ const updateAdapter = createMemo(() => props.updater ?? browserUpdateAdapter(props.identity.version));
76
+ const markMounted = (value) => {
77
+ if (!mounted().has(value)) setMounted((current) => new Set(current).add(value));
78
+ };
79
+ const show = (value) => {
80
+ const wasOpen = settingsOpen();
81
+ if (value) markMounted(value);
82
+ setDialog(value);
83
+ const isOpen = value === "settings";
84
+ if (wasOpen !== isOpen) props.settings?.onOpenChange?.(isOpen);
85
+ };
86
+ const open = (value, target) => {
87
+ if (value === "updates" && !props.updater && !updatesAlways()) return;
88
+ if (value === "help" && !props.help) return;
89
+ opener = target ?? document.activeElement ?? void 0;
90
+ show(value);
91
+ };
92
+ const openSettings = (id, target) => {
93
+ if (!settingsSections()) {
94
+ open("appearance", target);
95
+ return;
96
+ }
97
+ selectSection(knownSection(id) ? id : defaultSection());
98
+ open("settings", target);
99
+ };
100
+ const openAppearance = (target) => {
101
+ if (hasAppearanceSection()) openSettings(appearanceSectionId, target);
102
+ else open("appearance", target);
103
+ };
104
+ const openUpdates = (target) => {
105
+ if (props.onUpdates) props.onUpdates(target);
106
+ else open("updates", target);
107
+ };
108
+ createEffect(on(() => props.settings?.open, (value) => {
109
+ if (value === false && dialog() === "settings") setDialog(void 0);
110
+ if (!value || !settingsSections()) return;
111
+ if (!opener) opener = document.activeElement ?? void 0;
112
+ markMounted("settings");
113
+ if (dialog() !== "settings") setDialog("settings");
114
+ }));
115
+ props.commands?.(Object.freeze({
116
+ openSettings: (id) => openSettings(id),
117
+ openAppearance: () => openAppearance(),
118
+ openAbout: () => open("about"),
119
+ openHelp: () => open("help"),
120
+ openUpdates: () => openUpdates()
121
+ }));
122
+ const onKeyDown = (event) => {
123
+ if (!props.settings || !isSettingsChord(event)) return;
124
+ event.preventDefault();
125
+ openSettings();
126
+ };
127
+ const onHash = () => {
128
+ const sections = settingsSections();
129
+ if (!sections) return;
130
+ const id = settingsSectionFromHash(window.location.hash, sections, defaultSection());
131
+ if (id) openSettings(id);
132
+ };
133
+ onMount(() => {
134
+ onHash();
135
+ window.addEventListener("keydown", onKeyDown, { capture: true });
136
+ window.addEventListener("hashchange", onHash);
137
+ onCleanup(() => {
138
+ window.removeEventListener("keydown", onKeyDown, { capture: true });
139
+ window.removeEventListener("hashchange", onHash);
140
+ });
141
+ });
142
+ const close = () => show(void 0);
143
+ const items = () => {
144
+ const menu = props.accountMenu;
145
+ const shared = createAppMenuItems({
146
+ primaryItem: props.primaryItem,
147
+ settingsShortcut: menu?.settingsShortcut,
148
+ onAbout: (target) => open("about", target),
149
+ onUpdates: props.updater || props.onUpdates || updatesAlways() ? (target) => openUpdates(target) : void 0,
150
+ onSettings: props.onSettings ?? (props.settings ? (target) => openSettings(void 0, target) : void 0),
151
+ onHelp: props.onHelp ?? (props.help ? (target) => open("help", target) : void 0),
152
+ onFeedback: props.onFeedback
153
+ }).map((item) => {
154
+ if (item.id === "settings" && item.shortcut) return {
155
+ ...item,
156
+ keyshortcuts: menu?.settingsKeyshortcuts ?? settingsKeyshortcuts
157
+ };
158
+ if (item.id === "updates" && updatesAlways()) return {
159
+ ...item,
160
+ platform: void 0
161
+ };
162
+ return item;
163
+ });
164
+ if (menu?.appearance === false) return shared;
165
+ return [{
166
+ id: "appearance",
167
+ label: "Appearance",
168
+ icon: createComponent(Palette, { "aria-hidden": "true" }),
169
+ onSelectAfterClose: (target) => open("appearance", target)
170
+ }, ...shared];
171
+ };
172
+ return [createComponent(AccountMenu, {
173
+ get items() {
174
+ return items();
175
+ },
176
+ get platform() {
177
+ return props.runtime;
178
+ },
179
+ get authenticated() {
180
+ return props.authenticated ?? false;
181
+ },
182
+ get showSession() {
183
+ return props.showSession ?? false;
184
+ },
185
+ get busy() {
186
+ return props.accountMenu?.busy;
187
+ },
188
+ onIntent: () => props.accountMenu?.onIntent?.(),
189
+ get onSignIn() {
190
+ return props.onSignIn;
191
+ },
192
+ get onSignOut() {
193
+ return props.onSignOut;
194
+ },
195
+ get updateAvailable() {
196
+ return props.updateAvailable;
197
+ },
198
+ get label() {
199
+ return props.accountMenu?.label ?? "Application settings";
200
+ },
201
+ railTrigger: true,
202
+ placement: "right-end",
203
+ gutter: 4,
204
+ hideArrow: true
205
+ }), createComponent(Suspense, {
206
+ get fallback() {
207
+ return memo(() => !!dialog())() ? _tmpl$() : null;
208
+ },
209
+ get children() {
210
+ return [
211
+ createComponent(Show, {
212
+ get when() {
213
+ return mounted().has("appearance");
214
+ },
215
+ get children() {
216
+ return createComponent(ApplicationAppearance, {
217
+ get open() {
218
+ return dialog() === "appearance";
219
+ },
220
+ onClose: close,
221
+ get panel() {
222
+ return props.appearance;
223
+ },
224
+ restoreFocusRef: () => opener
225
+ });
226
+ }
227
+ }),
228
+ createComponent(Show, {
229
+ get when() {
230
+ return memo(() => !!mounted().has("settings"))() && settingsSections();
231
+ },
232
+ children: (sections) => createComponent(ApplicationSettings, {
233
+ get open() {
234
+ return settingsOpen();
235
+ },
236
+ onClose: close,
237
+ get sections() {
238
+ return sections();
239
+ },
240
+ get section() {
241
+ return section();
242
+ },
243
+ onSectionChange: selectSection,
244
+ get title() {
245
+ return props.settings?.title;
246
+ },
247
+ restoreFocusRef: () => opener
248
+ })
249
+ }),
250
+ createComponent(Show, {
251
+ get when() {
252
+ return memo(() => !!mounted().has("help"))() && props.help;
253
+ },
254
+ children: (help) => createComponent(ApplicationHelp, {
255
+ get open() {
256
+ return dialog() === "help";
257
+ },
258
+ onClose: close,
259
+ get appName() {
260
+ return props.identity.name;
261
+ },
262
+ get shortcuts() {
263
+ return help().shortcuts ?? [];
264
+ },
265
+ get standard() {
266
+ return {
267
+ search: help().search,
268
+ settings: Boolean(props.settings),
269
+ shortcutPlatform: resolveShortcutPlatform(props.identity)
270
+ };
271
+ },
272
+ get links() {
273
+ return help().links;
274
+ },
275
+ get openExternal() {
276
+ return props.openExternal;
277
+ },
278
+ restoreFocusRef: () => opener
279
+ })
280
+ }),
281
+ createComponent(Show, {
282
+ get when() {
283
+ return mounted().has("about");
284
+ },
285
+ get children() {
286
+ return createComponent(ApplicationAbout, {
287
+ get identity() {
288
+ return props.identity;
289
+ },
290
+ get copyVersionInfo() {
291
+ return props.copyVersionInfo;
292
+ },
293
+ get openExternal() {
294
+ return props.openExternal;
295
+ },
296
+ get open() {
297
+ return dialog() === "about";
298
+ },
299
+ onClose: close,
300
+ restoreFocusRef: () => opener
301
+ });
302
+ }
303
+ }),
304
+ createComponent(Show, {
305
+ get when() {
306
+ return memo(() => !!mounted().has("updates"))() && (props.updater || updatesAlways());
307
+ },
308
+ get children() {
309
+ return createComponent(UpdateSurface, {
310
+ get adapter() {
311
+ return updateAdapter();
312
+ },
313
+ get identity() {
314
+ return props.identity;
315
+ },
316
+ get channel() {
317
+ return memo(() => !!props.updater)() ? props.channel : void 0;
318
+ },
319
+ get onUpdateState() {
320
+ return props.onUpdateState;
321
+ },
322
+ get open() {
323
+ return dialog() === "updates";
324
+ },
325
+ onClose: close,
326
+ restoreFocusRef: () => opener
327
+ });
328
+ }
329
+ })
330
+ ];
331
+ }
332
+ })];
333
+ }
334
+ export { ApplicationThemeProvider, ApplicationUtilities, detectShortcutPlatform, resolveShortcutPlatform, settingsShortcutLabel, shortcutModifierKey };
@@ -0,0 +1,5 @@
1
+ /** Shared surfaces a native menu can open in the window. */
2
+ export declare const applicationMenuCommands: readonly ['about', 'settings', 'help', 'updates'];
3
+ export type ApplicationMenuCommand = (typeof applicationMenuCommands)[number];
4
+ /** The stream the window opens to receive menu commands. */
5
+ export declare const applicationCommandStream = "shell.commands";
@@ -0,0 +1,11 @@
1
+ // src/shell/application-menu-commands.ts
2
+ /** Shared surfaces a native menu can open in the window. */
3
+ var applicationMenuCommands = [
4
+ "about",
5
+ "settings",
6
+ "help",
7
+ "updates"
8
+ ];
9
+ /** The stream the window opens to receive menu commands. */
10
+ var applicationCommandStream = "shell.commands";
11
+ export { applicationCommandStream, applicationMenuCommands };
@@ -0,0 +1,61 @@
1
+ import type { createDesktopStreams } from '../desktop/desktop-stream';
2
+ import { type ApplicationMenuCommand } from './application-menu-commands';
3
+ export * from './application-menu-commands';
4
+ /** The subset of Electrobun's application menu item configuration the framework emits. */
5
+ export type ApplicationMenuItem = {
6
+ type: 'separator';
7
+ } | {
8
+ label?: string;
9
+ role?: string;
10
+ action?: string;
11
+ accelerator?: string;
12
+ enabled?: boolean;
13
+ submenu?: ApplicationMenuItem[];
14
+ };
15
+ export type ApplicationMenuLink = Readonly<{
16
+ label: string;
17
+ url: string;
18
+ }>;
19
+ /** An app-owned top-level menu; its actions are delivered to `onAction`. */
20
+ export type ApplicationMenuSection = Readonly<{
21
+ label: string;
22
+ items: readonly ApplicationMenuItem[];
23
+ }>;
24
+ export type ApplicationMenuOptions = Readonly<{
25
+ name: string;
26
+ platform: string;
27
+ /** Adds Check for Updates to the application menu. */
28
+ updates?: boolean;
29
+ /** Adds Settings… with the platform settings accelerator. */
30
+ settings?: boolean;
31
+ /** Help menu links opened in the system browser. */
32
+ helpLinks?: readonly ApplicationMenuLink[];
33
+ /** App menus placed between View and Window. */
34
+ sections?: readonly ApplicationMenuSection[];
35
+ }>;
36
+ /**
37
+ * Build the standard native menu: application, Edit, View, app sections, Window and Help.
38
+ * Electrobun implements application menus on macOS and Windows; Linux apps keep the same
39
+ * surfaces in the window's account menu.
40
+ */
41
+ export declare function createApplicationMenu(options: ApplicationMenuOptions): ApplicationMenuItem[];
42
+ export type ApplicationMenuDispatch = Readonly<{
43
+ /** Deliver a shared surface command to the window. */
44
+ command(command: ApplicationMenuCommand): void;
45
+ openExternal(url: string): unknown;
46
+ /** App-owned actions from `sections`. */
47
+ action?(action: string): void;
48
+ }>;
49
+ /** Route an `application-menu-clicked` event to shared commands, help links or app actions. */
50
+ export declare function createApplicationMenuHandler(options: Pick<ApplicationMenuOptions, 'helpLinks'> & ApplicationMenuDispatch): (event: unknown) => void;
51
+ /**
52
+ * Broadcast menu commands to authenticated windows over the desktop stream channel.
53
+ * Commands carry no data beyond their name; the window decides how to present them.
54
+ */
55
+ export declare function createApplicationCommandBroadcaster<Principal>(options: {
56
+ authorize(principal: Principal): boolean | Promise<boolean>;
57
+ }): {
58
+ register(streams: ReturnType<typeof createDesktopStreams<Principal>>): void;
59
+ /** Returns whether at least one window received the command. */
60
+ send(command: ApplicationMenuCommand): boolean;
61
+ };
@@ -0,0 +1,208 @@
1
+ import { containsAsciiControl } from "../desktop/string-policy.js";
2
+ import { applicationCommandStream, applicationMenuCommands } from "./application-menu-commands.js";
3
+ // src/shell/application-menu.ts
4
+ var prefix = "app-framework:";
5
+ var linkPrefix = `${prefix}link:`;
6
+ var appAction = /^[a-z][a-z0-9]*(?:[.:-][a-z0-9]+)*$/;
7
+ var separator = { type: "separator" };
8
+ function label(value) {
9
+ return typeof value === "string" && value.trim() && value.length <= 100 && !containsAsciiControl(value);
10
+ }
11
+ function validateItems(items, depth = 0) {
12
+ if (!Array.isArray(items) || items.length > 64 || depth > 2) throw new Error("Invalid menu items");
13
+ return items.map((item) => {
14
+ if ("type" in item) return separator;
15
+ if (item.label !== void 0 && !label(item.label) || item.action !== void 0 && (!appAction.test(item.action) || item.action.startsWith(prefix)) || item.role !== void 0 && !/^[a-zA-Z]+$/.test(item.role) || item.action === void 0 && item.role === void 0 && item.submenu === void 0 || item.label === void 0 && item.role === void 0) throw new Error("Invalid menu item");
16
+ return {
17
+ ...item,
18
+ ...item.submenu ? { submenu: validateItems(item.submenu, depth + 1) } : {}
19
+ };
20
+ });
21
+ }
22
+ function validLink(link) {
23
+ if (!label(link.label)) return false;
24
+ try {
25
+ const url = new URL(link.url);
26
+ return url.protocol === "https:" && url.username === "" && url.password === "";
27
+ } catch {
28
+ return false;
29
+ }
30
+ }
31
+ /**
32
+ * Build the standard native menu: application, Edit, View, app sections, Window and Help.
33
+ * Electrobun implements application menus on macOS and Windows; Linux apps keep the same
34
+ * surfaces in the window's account menu.
35
+ */
36
+ function createApplicationMenu(options) {
37
+ const links = options.helpLinks ?? [];
38
+ if (!label(options.name) || !Array.isArray(links) || links.length > 16 || !links.every(validLink) || (options.sections?.length ?? 0) > 8) throw new Error("Invalid application menu configuration");
39
+ const sections = (options.sections ?? []).map((section) => {
40
+ if (!label(section.label)) throw new Error("Invalid application menu configuration");
41
+ return {
42
+ label: section.label,
43
+ submenu: validateItems(section.items)
44
+ };
45
+ });
46
+ const mac = options.platform === "darwin";
47
+ const about = {
48
+ label: `About ${options.name}`,
49
+ action: `${prefix}about`
50
+ };
51
+ const settings = options.settings ? [{
52
+ label: mac ? "Settings…" : "Settings",
53
+ action: `${prefix}settings`,
54
+ accelerator: ","
55
+ }] : [];
56
+ const updates = options.updates ? [{
57
+ label: "Check for Updates…",
58
+ action: `${prefix}updates`
59
+ }] : [];
60
+ const help = [
61
+ {
62
+ label: `${options.name} Help`,
63
+ action: `${prefix}help`
64
+ },
65
+ ...links.length ? [separator] : [],
66
+ ...links.map((link, index) => ({
67
+ label: link.label,
68
+ action: `${linkPrefix}${index}`
69
+ }))
70
+ ];
71
+ const edit = {
72
+ label: "Edit",
73
+ submenu: [
74
+ { role: "undo" },
75
+ { role: "redo" },
76
+ separator,
77
+ { role: "cut" },
78
+ { role: "copy" },
79
+ { role: "paste" },
80
+ ...mac ? [{ role: "pasteAndMatchStyle" }] : [],
81
+ { role: "delete" },
82
+ { role: "selectAll" }
83
+ ]
84
+ };
85
+ const view = {
86
+ label: "View",
87
+ submenu: [{ role: "toggleFullScreen" }]
88
+ };
89
+ const window = {
90
+ label: "Window",
91
+ submenu: mac ? [
92
+ { role: "minimize" },
93
+ { role: "zoom" },
94
+ separator,
95
+ { role: "bringAllToFront" }
96
+ ] : [{ role: "minimize" }, { role: "close" }]
97
+ };
98
+ if (mac) return [
99
+ {
100
+ label: options.name,
101
+ submenu: [
102
+ about,
103
+ ...updates,
104
+ separator,
105
+ ...settings,
106
+ ...settings.length ? [separator] : [],
107
+ { role: "hide" },
108
+ { role: "hideOthers" },
109
+ { role: "showAll" },
110
+ separator,
111
+ { role: "quit" }
112
+ ]
113
+ },
114
+ edit,
115
+ view,
116
+ ...sections,
117
+ window,
118
+ {
119
+ label: "Help",
120
+ submenu: help
121
+ }
122
+ ];
123
+ return [
124
+ {
125
+ label: "File",
126
+ submenu: [
127
+ ...settings,
128
+ ...settings.length ? [separator] : [],
129
+ { role: "quit" }
130
+ ]
131
+ },
132
+ edit,
133
+ view,
134
+ ...sections,
135
+ window,
136
+ {
137
+ label: "Help",
138
+ submenu: [
139
+ ...help,
140
+ separator,
141
+ ...updates,
142
+ about
143
+ ]
144
+ }
145
+ ];
146
+ }
147
+ function actionOf(event) {
148
+ if (typeof event !== "object" || event === null) return void 0;
149
+ const data = event.data;
150
+ if (typeof data !== "object" || data === null) return void 0;
151
+ const action = data.action;
152
+ return typeof action === "string" && action.length <= 200 ? action : void 0;
153
+ }
154
+ /** Route an `application-menu-clicked` event to shared commands, help links or app actions. */
155
+ function createApplicationMenuHandler(options) {
156
+ const links = [...options.helpLinks ?? []];
157
+ return (event) => {
158
+ const action = actionOf(event);
159
+ if (action === void 0) return;
160
+ if (action.startsWith(linkPrefix)) {
161
+ const index = action.slice(linkPrefix.length);
162
+ const link = /^(?:0|[1-9]\d?)$/.test(index) ? links[Number(index)] : void 0;
163
+ if (link && validLink(link)) options.openExternal(link.url);
164
+ return;
165
+ }
166
+ if (action.startsWith(prefix)) {
167
+ const command = action.slice(14);
168
+ if (applicationMenuCommands.includes(command)) options.command(command);
169
+ return;
170
+ }
171
+ if (appAction.test(action)) options.action?.(action);
172
+ };
173
+ }
174
+ /**
175
+ * Broadcast menu commands to authenticated windows over the desktop stream channel.
176
+ * Commands carry no data beyond their name; the window decides how to present them.
177
+ */
178
+ function createApplicationCommandBroadcaster(options) {
179
+ const subscribers = /* @__PURE__ */ new Set();
180
+ return {
181
+ register(streams) {
182
+ streams.register(applicationCommandStream, {
183
+ parse(value) {
184
+ if (value !== null) throw new Error("Invalid input");
185
+ return null;
186
+ },
187
+ authorize: (principal) => options.authorize(principal),
188
+ open(_principal, _input, context) {
189
+ const send = (payload) => context.current() && context.send(payload);
190
+ subscribers.add(send);
191
+ return {
192
+ receive: () => context.close(),
193
+ close: () => subscribers.delete(send)
194
+ };
195
+ }
196
+ });
197
+ },
198
+ /** Returns whether at least one window received the command. */
199
+ send(command) {
200
+ if (!applicationMenuCommands.includes(command)) return false;
201
+ const payload = JSON.stringify({ command });
202
+ let delivered = false;
203
+ for (const send of subscribers) delivered = send(payload) || delivered;
204
+ return delivered;
205
+ }
206
+ };
207
+ }
208
+ export { applicationCommandStream, applicationMenuCommands, createApplicationCommandBroadcaster, createApplicationMenu, createApplicationMenuHandler };
@@ -0,0 +1,12 @@
1
+ import type { HelpLink, HelpShortcut } from '@adea-ai/ui/components/composites/help-center';
2
+ import { type ShortcutPlatform } from './shortcut-platform';
3
+ export type { HelpLink, HelpShortcut };
4
+ /** Shortcuts the framework binds itself, drawn with the running platform's modifier. */
5
+ export declare function standardShortcuts(options: {
6
+ search?: boolean;
7
+ settings?: boolean;
8
+ /** A navigator-style platform string; ignored when `shortcutPlatform` is supplied. */
9
+ platform?: string;
10
+ shortcutPlatform?: ShortcutPlatform;
11
+ }): HelpShortcut[];
12
+ export * from './shortcut-platform';
@@ -0,0 +1,22 @@
1
+ import { detectShortcutPlatform, resolveShortcutPlatform, settingsShortcutLabel, shortcutModifierKey } from "./shortcut-platform.js";
2
+ import { platformModifierKey } from "@adea-ai/ui/components/ui/kbd";
3
+ // src/shell/help-shortcuts.ts
4
+ /** Shortcuts the framework binds itself, drawn with the running platform's modifier. */
5
+ function standardShortcuts(options) {
6
+ const mod = options.shortcutPlatform ? shortcutModifierKey(options.shortcutPlatform) : platformModifierKey(options.platform);
7
+ return [
8
+ ...options.search ? [{
9
+ label: "Open search",
10
+ keys: [mod, "K"]
11
+ }] : [],
12
+ ...options.settings ? [{
13
+ label: "Open settings",
14
+ keys: [mod, ","]
15
+ }] : [],
16
+ {
17
+ label: "Close panels and dialogs",
18
+ keys: ["Esc"]
19
+ }
20
+ ];
21
+ }
22
+ export { detectShortcutPlatform, resolveShortcutPlatform, settingsShortcutLabel, shortcutModifierKey, standardShortcuts };
@@ -0,0 +1,12 @@
1
+ import type { JSX } from 'solid-js';
2
+ /**
3
+ * The narrow-window navigation drawer. The shell loads it the first time the window is
4
+ * narrow, so wide windows never fetch the dialog primitives behind the sheet.
5
+ */
6
+ export declare function NavigationDrawer(props: {
7
+ name: string;
8
+ open: boolean;
9
+ onOpenChange(open: boolean): void;
10
+ restoreFocus(): HTMLElement | undefined;
11
+ children: JSX.Element;
12
+ }): JSX.Element;