@dxos/plugin-testing 0.8.4-main.9735255 → 0.8.4-main.bcb3aa67d6

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 (93) hide show
  1. package/dist/lib/browser/index.mjs +30 -172
  2. package/dist/lib/browser/index.mjs.map +4 -4
  3. package/dist/lib/browser/meta.json +1 -1
  4. package/dist/lib/node-esm/index.mjs +30 -171
  5. package/dist/lib/node-esm/index.mjs.map +4 -4
  6. package/dist/lib/node-esm/meta.json +1 -1
  7. package/dist/types/src/StorybookPlugin.d.ts +1 -1
  8. package/dist/types/src/StorybookPlugin.d.ts.map +1 -1
  9. package/dist/types/src/capabilities/index.d.ts +15 -2
  10. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  11. package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
  12. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
  13. package/dist/types/src/capabilities/{state/state.d.ts → state.d.ts} +2 -2
  14. package/dist/types/src/capabilities/state.d.ts.map +1 -0
  15. package/dist/types/src/components/{Layout.d.ts → Layout/Layout.d.ts} +1 -1
  16. package/dist/types/src/components/Layout/Layout.d.ts.map +1 -0
  17. package/dist/types/src/components/Layout/index.d.ts +2 -0
  18. package/dist/types/src/components/Layout/index.d.ts.map +1 -0
  19. package/dist/types/src/core.d.ts +1 -6
  20. package/dist/types/src/core.d.ts.map +1 -1
  21. package/dist/types/src/operations/add-toast.d.ts +5 -0
  22. package/dist/types/src/operations/add-toast.d.ts.map +1 -0
  23. package/dist/types/src/operations/close.d.ts +5 -0
  24. package/dist/types/src/operations/close.d.ts.map +1 -0
  25. package/dist/types/src/operations/index.d.ts +3 -0
  26. package/dist/types/src/operations/index.d.ts.map +1 -0
  27. package/dist/types/src/operations/open.d.ts +5 -0
  28. package/dist/types/src/operations/open.d.ts.map +1 -0
  29. package/dist/types/src/operations/scroll-into-view.d.ts +5 -0
  30. package/dist/types/src/operations/scroll-into-view.d.ts.map +1 -0
  31. package/dist/types/src/operations/set-layout-mode.d.ts +5 -0
  32. package/dist/types/src/operations/set-layout-mode.d.ts.map +1 -0
  33. package/dist/types/src/operations/switch-workspace.d.ts +5 -0
  34. package/dist/types/src/operations/switch-workspace.d.ts.map +1 -0
  35. package/dist/types/src/operations/update-complementary.d.ts +5 -0
  36. package/dist/types/src/operations/update-complementary.d.ts.map +1 -0
  37. package/dist/types/src/operations/update-dialog.d.ts +5 -0
  38. package/dist/types/src/operations/update-dialog.d.ts.map +1 -0
  39. package/dist/types/src/operations/update-popover.d.ts +5 -0
  40. package/dist/types/src/operations/update-popover.d.ts.map +1 -0
  41. package/dist/types/src/operations/update-sidebar.d.ts +5 -0
  42. package/dist/types/src/operations/update-sidebar.d.ts.map +1 -0
  43. package/dist/types/src/operations/update-state.d.ts +5 -0
  44. package/dist/types/src/operations/update-state.d.ts.map +1 -0
  45. package/dist/types/src/types/capabilities.d.ts +2 -0
  46. package/dist/types/src/types/capabilities.d.ts.map +1 -1
  47. package/dist/types/tsconfig.tsbuildinfo +1 -1
  48. package/package.json +26 -18
  49. package/src/StorybookPlugin.ts +18 -16
  50. package/src/capabilities/index.ts +8 -2
  51. package/src/capabilities/operation-handler.ts +16 -0
  52. package/src/capabilities/{state/state.tsx → state.tsx} +6 -7
  53. package/src/components/Layout/Layout.tsx +230 -0
  54. package/src/components/Layout/index.ts +5 -0
  55. package/src/core.ts +2 -6
  56. package/src/meta.ts +1 -1
  57. package/src/operations/add-toast.ts +22 -0
  58. package/src/operations/close.ts +14 -0
  59. package/src/operations/index.ts +18 -0
  60. package/src/operations/open.ts +18 -0
  61. package/src/operations/scroll-into-view.ts +14 -0
  62. package/src/operations/set-layout-mode.ts +14 -0
  63. package/src/operations/switch-workspace.ts +20 -0
  64. package/src/operations/update-complementary.ts +27 -0
  65. package/src/operations/update-dialog.ts +27 -0
  66. package/src/operations/update-popover.ts +37 -0
  67. package/src/operations/update-sidebar.ts +26 -0
  68. package/src/operations/update-state.ts +17 -0
  69. package/src/types/capabilities.ts +5 -2
  70. package/dist/lib/browser/chunk-YHPXIILW.mjs +0 -21
  71. package/dist/lib/browser/chunk-YHPXIILW.mjs.map +0 -7
  72. package/dist/lib/browser/operation-resolver-B2DOYB7C.mjs +0 -111
  73. package/dist/lib/browser/operation-resolver-B2DOYB7C.mjs.map +0 -7
  74. package/dist/lib/browser/state-2M3RMJYA.mjs +0 -42
  75. package/dist/lib/browser/state-2M3RMJYA.mjs.map +0 -7
  76. package/dist/lib/node-esm/chunk-OWK6XE6C.mjs +0 -23
  77. package/dist/lib/node-esm/chunk-OWK6XE6C.mjs.map +0 -7
  78. package/dist/lib/node-esm/operation-resolver-DJI7OPBP.mjs +0 -112
  79. package/dist/lib/node-esm/operation-resolver-DJI7OPBP.mjs.map +0 -7
  80. package/dist/lib/node-esm/state-UF2MWBFU.mjs +0 -43
  81. package/dist/lib/node-esm/state-UF2MWBFU.mjs.map +0 -7
  82. package/dist/types/src/capabilities/operation-resolver/index.d.ts +0 -3
  83. package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +0 -1
  84. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +0 -5
  85. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +0 -1
  86. package/dist/types/src/capabilities/state/index.d.ts +0 -14
  87. package/dist/types/src/capabilities/state/index.d.ts.map +0 -1
  88. package/dist/types/src/capabilities/state/state.d.ts.map +0 -1
  89. package/dist/types/src/components/Layout.d.ts.map +0 -1
  90. package/src/capabilities/operation-resolver/index.ts +0 -7
  91. package/src/capabilities/operation-resolver/operation-resolver.ts +0 -98
  92. package/src/capabilities/state/index.ts +0 -7
  93. package/src/components/Layout.tsx +0 -172
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/core.ts", "../../../src/StorybookPlugin.ts", "../../../src/capabilities/operation-resolver/index.ts", "../../../src/capabilities/state/index.ts", "../../../src/components/Layout.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationPlugin, type Plugin, RuntimePlugin, SettingsPlugin } from '@dxos/app-framework';\nimport { AttentionPlugin } from '@dxos/plugin-attention';\nimport { ClientPlugin } from '@dxos/plugin-client';\nimport { GraphPlugin } from '@dxos/plugin-graph';\nimport { ThemePlugin } from '@dxos/plugin-theme';\nimport { defaultTx } from '@dxos/ui-theme';\n\n// TODO(burdon): Remove this.\n// Re-export common framework plugins.\nexport { AttentionPlugin, ClientPlugin, GraphPlugin, OperationPlugin, RuntimePlugin, SettingsPlugin, ThemePlugin };\n\n/**\n * Core plugins for testing/storybook environments.\n * NOTE: Does not include SpacePlugin to avoid circular dependencies.\n * Import SpacePlugin directly in your stories if needed.\n */\nexport const corePlugins = (): Plugin.Plugin[] => [\n AttentionPlugin(),\n GraphPlugin(),\n OperationPlugin(),\n RuntimePlugin(),\n SettingsPlugin(),\n ThemePlugin({ tx: defaultTx }),\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capability, Common, Plugin } from '@dxos/app-framework';\n\nimport { OperationResolver, State } from './capabilities';\nimport { Layout } from './components';\nimport { meta } from './meta';\nimport { type LayoutStateProps } from './types';\n\nexport type StorybookPluginOptions = {\n initialState?: Partial<LayoutStateProps>;\n};\n\nexport const StorybookPlugin = Plugin.define<StorybookPluginOptions>(meta).pipe(\n Plugin.addModule(({ initialState }) => ({\n id: Capability.getModuleTag(State),\n activatesOn: Common.ActivationEvent.Startup,\n activatesAfter: [Common.ActivationEvent.LayoutReady],\n activate: () => State({ initialState }),\n })),\n Common.Plugin.addReactContextModule({\n activate: () =>\n Effect.succeed(\n Capability.contributes(Common.Capability.ReactContext, {\n id: 'storybook-layout',\n context: Layout,\n }),\n ),\n }),\n Common.Plugin.addOperationResolverModule({\n activate: OperationResolver,\n }),\n Plugin.make,\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nexport const OperationResolver = Capability.lazy('OperationResolver', () => import('./operation-resolver'));\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nexport const State = Capability.lazy('State', () => import('./state'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { RegistryContext, useAtomValue } from '@effect-atom/atom-react';\nimport React, { type PropsWithChildren, useCallback, useContext, useEffect, useRef, useState } from 'react';\n\nimport { Surface, useCapability } from '@dxos/app-framework/react';\nimport {\n AlertDialog,\n Dialog,\n Main,\n Popover,\n type PopoverContentInteractOutsideEvent,\n toLocalizedString,\n useTranslation,\n} from '@dxos/react-ui';\nimport { Card, Mosaic } from '@dxos/react-ui-mosaic';\nimport { descriptionMessage, mx } from '@dxos/ui-theme';\n\nimport { meta } from '../meta';\nimport { LayoutState, type LayoutStateProps } from '../types';\n\nconst debounce_delay = 100;\n\n// TODO(wittjosiah): Support dialogs, tooltips, maybe toast.\nexport const Layout = ({ children }: PropsWithChildren<{}>) => {\n const { t } = useTranslation(meta.id);\n const trigger = useRef<HTMLButtonElement | null>(null);\n const registry = useContext(RegistryContext);\n const stateAtom = useCapability(LayoutState);\n const layout = useAtomValue(stateAtom);\n const [iter, setIter] = useState(0);\n const [open, setOpen] = useState(false);\n const debounceRef = useRef<NodeJS.Timeout | null>(null);\n\n const updateState = useCallback(\n (updates: Partial<LayoutStateProps>) => {\n const current = registry.get(stateAtom);\n registry.set(stateAtom, { ...current, ...updates });\n },\n [registry, stateAtom],\n );\n\n useEffect(() => {\n setOpen(false);\n if (debounceRef.current) {\n clearTimeout(debounceRef.current);\n debounceRef.current = null;\n }\n trigger.current = layout.popoverAnchor ?? null;\n setIter((iter) => iter + 1);\n if (layout.popoverOpen) {\n debounceRef.current = setTimeout(() => setOpen(true), debounce_delay);\n }\n }, [layout.popoverAnchor, layout.popoverContent, layout.popoverOpen]);\n\n const handleClose = useCallback(() => {\n setOpen(false);\n updateState({\n popoverOpen: false,\n popoverAnchor: undefined,\n popoverAnchorId: undefined,\n popoverSide: undefined,\n });\n }, [updateState]);\n\n const handleInteractOutside = useCallback(\n (event: KeyboardEvent | PopoverContentInteractOutsideEvent) => {\n if (\n // TODO(thure): CodeMirror should not focus itself when it updates.\n event.type === 'dismissableLayer.focusOutside' &&\n (event.currentTarget as HTMLElement | undefined)?.classList.contains('cm-content')\n ) {\n event.preventDefault();\n } else {\n handleClose();\n }\n },\n [handleClose],\n );\n\n const DialogRoot = layout.dialogType === 'alert' ? AlertDialog.Root : Dialog.Root;\n const DialogOverlay = layout.dialogType === 'alert' ? AlertDialog.Overlay : Dialog.Overlay;\n\n return (\n <div role='none' className='fixed inset-0 flex overflow-hidden'>\n <Mosaic.Root>\n <Popover.Root open={open}>\n <Main.Root\n navigationSidebarState={layout.sidebarState}\n complementarySidebarState={layout.complementarySidebarState}\n onNavigationSidebarStateChange={(next) => updateState({ sidebarState: next })}\n onComplementarySidebarStateChange={(next) => updateState({ complementarySidebarState: next })}\n >\n {children}\n </Main.Root>\n\n <DialogRoot\n modal={layout.dialogBlockAlign !== 'end'}\n open={layout.dialogOpen}\n onOpenChange={(nextOpen) => updateState({ dialogOpen: nextOpen })}\n >\n {layout.dialogBlockAlign === 'end' ? (\n <Surface\n role='dialog'\n data={layout.dialogContent}\n limit={1}\n fallback={ContentError}\n placeholder={<div />}\n />\n ) : (\n <DialogOverlay\n blockAlign={layout.dialogBlockAlign}\n classNames={layout.dialogOverlayClasses}\n style={layout.dialogOverlayStyle}\n >\n <Surface role='dialog' data={layout.dialogContent} limit={1} fallback={ContentError} />\n </DialogOverlay>\n )}\n </DialogRoot>\n\n <Popover.VirtualTrigger key={iter} virtualRef={trigger} />\n <Popover.Portal>\n <Popover.Content\n side={layout.popoverSide}\n onInteractOutside={handleInteractOutside}\n onEscapeKeyDown={handleInteractOutside}\n sticky='always'\n hideWhenDetached\n >\n <Popover.Viewport>\n {layout.popoverKind === 'card' && (\n <Card.Root>\n <Card.Toolbar>\n {/* TODO(wittjosiah): Cleaner way to handle no drag handle in toolbar? */}\n <span />\n {layout.popoverTitle ? (\n <Card.Title>{toLocalizedString(layout.popoverTitle, t)}</Card.Title>\n ) : (\n <span />\n )}\n <Card.Close onClick={handleClose} />\n </Card.Toolbar>\n <Surface role='card--content' data={layout.popoverContent} limit={1} />\n </Card.Root>\n )}\n {layout.popoverKind === 'base' && <Surface role='popover' data={layout.popoverContent} limit={1} />}\n </Popover.Viewport>\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n </Mosaic.Root>\n </div>\n );\n};\n\nexport const ContentError = ({ error }: { error?: Error }) => {\n const { t } = useTranslation(meta.id);\n const errorString = error?.toString() ?? '';\n return (\n <div role='none' className='overflow-auto p-8 attention-surface grid place-items-center'>\n <p\n role='alert'\n className={mx(descriptionMessage, 'break-words rounded-md p-8', errorString.length < 256 && 'text-lg')}\n >\n {error ? errorString : t('error fallback message')}\n </p>\n </div>\n );\n};\n"],
5
- "mappings": ";;;;;;;AAIA,SAASA,iBAA8BC,eAAeC,sBAAsB;AAC5E,SAASC,uBAAuB;AAChC,SAASC,oBAAoB;AAC7B,SAASC,mBAAmB;AAC5B,SAASC,mBAAmB;AAC5B,SAASC,iBAAiB;AAWnB,IAAMC,cAAc,MAAuB;EAChDC,gBAAAA;EACAC,YAAAA;EACAC,gBAAAA;EACAC,cAAAA;EACAC,eAAAA;EACAC,YAAY;IAAEC,IAAIC;EAAU,CAAA;;;;ACtB9B,YAAYC,YAAY;AAExB,SAASC,cAAAA,aAAYC,QAAQC,cAAc;;;ACF3C,SAASC,kBAAkB;AAEpB,IAAMC,oBAAoBC,WAAWC,KAAK,qBAAqB,MAAM,OAAO,mCAAA,CAAA;;;ACFnF,SAASC,cAAAA,mBAAkB;AAEpB,IAAMC,QAAQC,YAAWC,KAAK,SAAS,MAAM,OAAO,sBAAA,CAAA;;;ACF3D,SAASC,iBAAiBC,oBAAoB;AAC9C,OAAOC,SAAiCC,aAAaC,YAAYC,WAAWC,QAAQC,gBAAgB;AAE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ACzEH,OAAOI,UAAU,CAAC,EAAEC,aAAY,OAAQ;EACtCC,IAAIC,YAAWC,aAAaC,KAAAA;EAC5BC,aAAaC,OAAOC,gBAAgBC;EACpCC,gBAAgB;IAACH,OAAOC,gBAAgBG;;EACxCC,UAAU,MAAMP,MAAM;IAAEJ;EAAa,CAAA;AACvC,EAAA,GACAM,OAAOX,OAAOiB,sBAAsB;EAClCD,UAAU,MACDE,eACLX,YAAWY,YAAYR,OAAOJ,WAAWa,cAAc;IACrDd,IAAI;IACJe,SAASC;EACX,CAAA,CAAA;AAEN,CAAA,GACAX,OAAOX,OAAOuB,2BAA2B;EACvCP,UAAUQ;AACZ,CAAA,GACAxB,OAAOyB,IAAI;",
6
- "names": ["OperationPlugin", "RuntimePlugin", "SettingsPlugin", "AttentionPlugin", "ClientPlugin", "GraphPlugin", "ThemePlugin", "defaultTx", "corePlugins", "AttentionPlugin", "GraphPlugin", "OperationPlugin", "RuntimePlugin", "SettingsPlugin", "ThemePlugin", "tx", "defaultTx", "Effect", "Capability", "Common", "Plugin", "Capability", "OperationResolver", "Capability", "lazy", "Capability", "State", "Capability", "lazy", "RegistryContext", "useAtomValue", "React", "useCallback", "useContext", "useEffect", "useRef", "useState", "Surface", "useCapability", "AlertDialog", "Dialog", "Main", "Popover", "toLocalizedString", "useTranslation", "Card", "Mosaic", "descriptionMessage", "mx", "debounce_delay", "Layout", "children", "t", "useTranslation", "meta", "id", "trigger", "useRef", "registry", "useContext", "RegistryContext", "stateAtom", "useCapability", "LayoutState", "layout", "useAtomValue", "iter", "setIter", "useState", "open", "setOpen", "debounceRef", "updateState", "useCallback", "updates", "current", "get", "set", "useEffect", "clearTimeout", "popoverAnchor", "popoverOpen", "setTimeout", "popoverContent", "handleClose", "undefined", "popoverAnchorId", "popoverSide", "handleInteractOutside", "event", "type", "currentTarget", "classList", "contains", "preventDefault", "DialogRoot", "dialogType", "AlertDialog", "Root", "Dialog", "DialogOverlay", "Overlay", "div", "role", "className", "Mosaic", "Popover", "Main", "navigationSidebarState", "sidebarState", "complementarySidebarState", "onNavigationSidebarStateChange", "next", "onComplementarySidebarStateChange", "modal", "dialogBlockAlign", "dialogOpen", "onOpenChange", "nextOpen", "Surface", "data", "dialogContent", "limit", "fallback", "ContentError", "placeholder", "blockAlign", "classNames", "dialogOverlayClasses", "style", "dialogOverlayStyle", "VirtualTrigger", "key", "virtualRef", "Portal", "Content", "side", "onInteractOutside", "onEscapeKeyDown", "sticky", "hideWhenDetached", "Viewport", "popoverKind", "Card", "Toolbar", "span", "popoverTitle", "Title", "toLocalizedString", "Close", "onClick", "Arrow", "error", "errorString", "toString", "p", "mx", "descriptionMessage", "length", "StorybookPlugin", "Plugin", "define", "meta", "pipe", "addModule", "initialState", "id", "Capability", "getModuleTag", "State", "activatesOn", "Common", "ActivationEvent", "Startup", "activatesAfter", "LayoutReady", "activate", "addReactContextModule", "succeed", "contributes", "ReactContext", "context", "Layout", "addOperationResolverModule", "OperationResolver", "make"]
3
+ "sources": ["../../../src/core.ts", "../../../src/meta.ts", "../../../src/StorybookPlugin.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationPlugin, type Plugin, RuntimePlugin } from '@dxos/app-framework';\nimport { AttentionPlugin } from '@dxos/plugin-attention';\nimport { GraphPlugin } from '@dxos/plugin-graph';\nimport { SettingsPlugin } from '@dxos/plugin-settings';\nimport { ThemePlugin } from '@dxos/plugin-theme';\nimport { defaultTx } from '@dxos/ui-theme';\n\n/**\n * Core plugins for testing/storybook environments.\n * NOTE: Does not include SpacePlugin to avoid circular dependencies.\n * Import SpacePlugin directly in your stories if needed.\n */\nexport const corePlugins = (): Plugin.Plugin[] => [\n AttentionPlugin(),\n GraphPlugin(),\n OperationPlugin(),\n RuntimePlugin(),\n SettingsPlugin(),\n ThemePlugin({ tx: defaultTx }),\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { trim } from '@dxos/util';\n\nexport const meta: Plugin.Meta = {\n id: 'org.dxos.plugin.storybook-layout',\n name: 'Storybook',\n description: trim`\n Development layout optimized for Storybook component testing and documentation.\n Provides specialized views for component development and design system exploration.\n `,\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-testing',\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { ActivationEvents, Capabilities, Capability, Plugin } from '@dxos/app-framework';\nimport { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';\n\nimport { Layout } from '#components';\nimport { meta } from '#meta';\nimport { type LayoutStateProps } from '#types';\n\nimport { OperationHandler, State } from '#capabilities';\n\nexport type StorybookPluginOptions = {\n initialState?: Partial<LayoutStateProps>;\n};\n\nexport const StorybookPlugin = Plugin.define<StorybookPluginOptions>(meta).pipe(\n AppPlugin.addOperationHandlerModule({\n activate: OperationHandler,\n }),\n AppPlugin.addReactContextModule({\n activate: () =>\n Effect.succeed(\n Capability.contributes(Capabilities.ReactContext, {\n id: 'storybook-layout',\n context: Layout,\n }),\n ),\n }),\n Plugin.addModule(({ initialState }) => ({\n id: Capability.getModuleTag(State),\n activatesOn: ActivationEvents.Startup,\n activatesAfter: [AppActivationEvents.LayoutReady],\n activate: () => State({ initialState }),\n })),\n Plugin.make,\n);\n"],
5
+ "mappings": ";;;AAIA,SAASA,iBAA8BC,qBAAqB;AAC5D,SAASC,uBAAuB;AAChC,SAASC,mBAAmB;AAC5B,SAASC,sBAAsB;AAC/B,SAASC,mBAAmB;AAC5B,SAASC,iBAAiB;AAOnB,IAAMC,cAAc,MAAuB;EAChDC,gBAAAA;EACAC,YAAAA;EACAC,gBAAAA;EACAC,cAAAA;EACAC,eAAAA;EACAC,YAAY;IAAEC,IAAIC;EAAU,CAAA;;;;ACjB9B,SAASC,YAAY;AAEd,IAAMC,OAAoB;EAC/BC,IAAI;EACJC,MAAM;EACNC,aAAaC;;;;EAIbC,QAAQ;AACV;;;ACXA,YAAYC,YAAY;AAExB,SAASC,kBAAkBC,cAAcC,YAAYC,cAAc;AACnE,SAASC,qBAAqBC,iBAAiB;AAE/C,SAASC,cAAc;AACvB,SAASC,QAAAA,aAAY;AAGrB,SAASC,kBAAkBC,aAAa;AAMjC,IAAMC,kBAAkBC,OAAOC,OAA+BC,KAAAA,EAAMC,KACzEC,UAAUC,0BAA0B;EAClCC,UAAUC;AACZ,CAAA,GACAH,UAAUI,sBAAsB;EAC9BF,UAAU,MACDG,eACLC,WAAWC,YAAYC,aAAaC,cAAc;IAChDC,IAAI;IACJC,SAASC;EACX,CAAA,CAAA;AAEN,CAAA,GACAhB,OAAOiB,UAAU,CAAC,EAAEC,aAAY,OAAQ;EACtCJ,IAAIJ,WAAWS,aAAaC,KAAAA;EAC5BC,aAAaC,iBAAiBC;EAC9BC,gBAAgB;IAACC,oBAAoBC;;EACrCpB,UAAU,MAAMc,MAAM;IAAEF;EAAa,CAAA;AACvC,EAAA,GACAlB,OAAO2B,IAAI;",
6
+ "names": ["OperationPlugin", "RuntimePlugin", "AttentionPlugin", "GraphPlugin", "SettingsPlugin", "ThemePlugin", "defaultTx", "corePlugins", "AttentionPlugin", "GraphPlugin", "OperationPlugin", "RuntimePlugin", "SettingsPlugin", "ThemePlugin", "tx", "defaultTx", "trim", "meta", "id", "name", "description", "trim", "source", "Effect", "ActivationEvents", "Capabilities", "Capability", "Plugin", "AppActivationEvents", "AppPlugin", "Layout", "meta", "OperationHandler", "State", "StorybookPlugin", "Plugin", "define", "meta", "pipe", "AppPlugin", "addOperationHandlerModule", "activate", "OperationHandler", "addReactContextModule", "succeed", "Capability", "contributes", "Capabilities", "ReactContext", "id", "context", "Layout", "addModule", "initialState", "getModuleTag", "State", "activatesOn", "ActivationEvents", "Startup", "activatesAfter", "AppActivationEvents", "LayoutReady", "make"]
7
7
  }
@@ -1 +1 @@
1
- {"inputs":{"src/core.ts":{"bytes":3313,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/meta.ts":{"bytes":1661,"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/types/capabilities.ts":{"bytes":2133,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/types/index.ts":{"bytes":476,"imports":[{"path":"src/types/capabilities.ts","kind":"import-statement","original":"./capabilities"}],"format":"esm"},"src/capabilities/operation-resolver/operation-resolver.ts":{"bytes":13591,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/capabilities/operation-resolver/index.ts":{"bytes":963,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/operation-resolver/operation-resolver.ts","kind":"dynamic-import","original":"./operation-resolver"}],"format":"esm"},"src/capabilities/state/state.tsx":{"bytes":4683,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/capabilities/state/index.ts":{"bytes":837,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/state/state.tsx","kind":"dynamic-import","original":"./state"}],"format":"esm"},"src/capabilities/index.ts":{"bytes":578,"imports":[{"path":"src/capabilities/operation-resolver/index.ts","kind":"import-statement","original":"./operation-resolver"},{"path":"src/capabilities/state/index.ts","kind":"import-statement","original":"./state"}],"format":"esm"},"src/components/Layout.tsx":{"bytes":20783,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/components/index.ts":{"bytes":467,"imports":[{"path":"src/components/Layout.tsx","kind":"import-statement","original":"./Layout"}],"format":"esm"},"src/StorybookPlugin.ts":{"bytes":4089,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"src/index.ts":{"bytes":637,"imports":[{"path":"src/core.ts","kind":"import-statement","original":"./core"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/StorybookPlugin.ts","kind":"import-statement","original":"./StorybookPlugin"}],"format":"esm"}},"outputs":{"dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":15613},"dist/lib/node-esm/index.mjs":{"imports":[{"path":"dist/lib/node-esm/chunk-OWK6XE6C.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/node-esm/operation-resolver-DJI7OPBP.mjs","kind":"dynamic-import"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/node-esm/state-UF2MWBFU.mjs","kind":"dynamic-import"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"exports":["AttentionPlugin","ClientPlugin","GraphPlugin","OperationPlugin","RuntimePlugin","SettingsPlugin","StorybookPlugin","ThemePlugin","corePlugins","meta"],"entryPoint":"src/index.ts","inputs":{"src/core.ts":{"bytesInOutput":506},"src/index.ts":{"bytesInOutput":0},"src/StorybookPlugin.ts":{"bytesInOutput":692},"src/capabilities/operation-resolver/index.ts":{"bytesInOutput":163},"src/capabilities/index.ts":{"bytesInOutput":0},"src/capabilities/state/index.ts":{"bytesInOutput":142},"src/components/Layout.tsx":{"bytesInOutput":5418},"src/components/index.ts":{"bytesInOutput":0}},"bytes":7467},"dist/lib/node-esm/operation-resolver-DJI7OPBP.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":6683},"dist/lib/node-esm/operation-resolver-DJI7OPBP.mjs":{"imports":[{"path":"dist/lib/node-esm/chunk-OWK6XE6C.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/operation-resolver/operation-resolver.ts","inputs":{"src/capabilities/operation-resolver/operation-resolver.ts":{"bytesInOutput":3403}},"bytes":3720},"dist/lib/node-esm/state-UF2MWBFU.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2491},"dist/lib/node-esm/state-UF2MWBFU.mjs":{"imports":[{"path":"dist/lib/node-esm/chunk-OWK6XE6C.mjs","kind":"import-statement"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/state/state.tsx","inputs":{"src/capabilities/state/state.tsx":{"bytesInOutput":1015}},"bytes":1281},"dist/lib/node-esm/chunk-OWK6XE6C.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2022},"dist/lib/node-esm/chunk-OWK6XE6C.mjs":{"imports":[{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["LayoutState","meta"],"inputs":{"src/meta.ts":{"bytesInOutput":395},"src/types/capabilities.ts":{"bytesInOutput":105},"src/types/index.ts":{"bytesInOutput":0}},"bytes":717}}}
1
+ {"inputs":{"src/core.ts":{"bytes":2660,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/meta.ts":{"bytes":1661,"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/StorybookPlugin.ts":{"bytes":4301,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#components","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"#capabilities","kind":"import-statement","external":true}],"format":"esm"},"src/index.ts":{"bytes":637,"imports":[{"path":"src/core.ts","kind":"import-statement","original":"./core"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/StorybookPlugin.ts","kind":"import-statement","original":"./StorybookPlugin"}],"format":"esm"}},"outputs":{"dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4413},"dist/lib/node-esm/index.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#components","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"#capabilities","kind":"import-statement","external":true}],"exports":["StorybookPlugin","corePlugins","meta"],"entryPoint":"src/index.ts","inputs":{"src/core.ts":{"bytesInOutput":494},"src/index.ts":{"bytesInOutput":0},"src/meta.ts":{"bytesInOutput":395},"src/StorybookPlugin.ts":{"bytesInOutput":878}},"bytes":2006}}}
@@ -1,5 +1,5 @@
1
1
  import { Plugin } from '@dxos/app-framework';
2
- import { type LayoutStateProps } from './types';
2
+ import { type LayoutStateProps } from '#types';
3
3
  export type StorybookPluginOptions = {
4
4
  initialState?: Partial<LayoutStateProps>;
5
5
  };
@@ -1 +1 @@
1
- {"version":3,"file":"StorybookPlugin.d.ts","sourceRoot":"","sources":["../../../src/StorybookPlugin.ts"],"names":[],"mappings":"AAMA,OAAO,EAAsB,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAKjE,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,MAAM,MAAM,sBAAsB,GAAG;IACnC,YAAY,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,CAAC;CAC1C,CAAC;AAEF,eAAO,MAAM,eAAe,8CAoB3B,CAAC"}
1
+ {"version":3,"file":"StorybookPlugin.d.ts","sourceRoot":"","sources":["../../../src/StorybookPlugin.ts"],"names":[],"mappings":"AAMA,OAAO,EAA8C,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAKzF,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAI/C,MAAM,MAAM,sBAAsB,GAAG;IACnC,YAAY,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,CAAC;CAC1C,CAAC;AAEF,eAAO,MAAM,eAAe,8CAoB3B,CAAC"}
@@ -1,3 +1,16 @@
1
- export * from './operation-resolver';
2
- export * from './state';
1
+ import { Capability } from '@dxos/app-framework';
2
+ import { OperationHandlerSet } from '@dxos/operation';
3
+ export declare const OperationHandler: Capability.LazyCapability<OperationHandlerSet.OperationHandlerSet, Capability.ModuleReturn, Error>;
4
+ export declare const State: Capability.LazyCapability<{
5
+ initialState?: Partial<import("../types").LayoutStateProps>;
6
+ } | undefined, [Capability.Capability<Capability.InterfaceDef<import("@effect-atom/atom/Atom").Writable<import("../types").LayoutStateProps, import("../types").LayoutStateProps>>>, Capability.Capability<Capability.InterfaceDef<import("@effect-atom/atom/Atom").Atom<Readonly<{
7
+ mode: string;
8
+ dialogOpen: boolean;
9
+ sidebarOpen: boolean;
10
+ complementarySidebarOpen: boolean;
11
+ workspace: string;
12
+ active: string[];
13
+ inactive: string[];
14
+ scrollIntoView: string | undefined;
15
+ }>>>>], Error>;
3
16
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/index.ts"],"names":[],"mappings":"AAIA,cAAc,sBAAsB,CAAC;AACrC,cAAc,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAEtD,eAAO,MAAM,gBAAgB,oGAG5B,CAAC;AACF,eAAO,MAAM,KAAK;;;;;;;;;;;cAAoD,CAAC"}
@@ -0,0 +1,6 @@
1
+ import * as Effect from 'effect/Effect';
2
+ import { Capability } from '@dxos/app-framework';
3
+ import type { OperationHandlerSet } from '@dxos/operation';
4
+ declare const _default: (props: OperationHandlerSet.OperationHandlerSet) => Effect.Effect<Capability.ModuleReturn, Error, Capability.Service>;
5
+ export default _default;
6
+ //# sourceMappingURL=operation-handler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"operation-handler.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/operation-handler.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAgB,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;;AAI3D,wBAIE"}
@@ -1,8 +1,8 @@
1
1
  import { Atom } from '@effect-atom/atom-react';
2
2
  import * as Effect from 'effect/Effect';
3
3
  import { Capability } from '@dxos/app-framework';
4
- import { type LayoutStateProps } from '../../types';
5
- declare const _default: (props?: {
4
+ import { type LayoutStateProps } from '#types';
5
+ declare const _default: (props: {
6
6
  initialState?: Partial<LayoutStateProps>;
7
7
  } | undefined) => Effect.Effect<[Capability.Capability<Capability.InterfaceDef<Atom.Writable<LayoutStateProps, LayoutStateProps>>>, Capability.Capability<Capability.InterfaceDef<Atom.Atom<Readonly<{
8
8
  mode: string;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/state.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,IAAI,EAAE,MAAM,yBAAyB,CAAC;AAC/C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAGjD,OAAO,EAAe,KAAK,gBAAgB,EAAE,MAAM,QAAQ,CAAC;;mBAWJ,OAAO,CAAC,gBAAgB,CAAC;;;;;;;;;;;AADjF,wBAqBE"}
@@ -1,6 +1,6 @@
1
1
  import React, { type PropsWithChildren } from 'react';
2
2
  export declare const Layout: ({ children }: PropsWithChildren<{}>) => React.JSX.Element;
3
- export declare const ContentError: ({ error }: {
3
+ export declare const ErrorFallback: ({ error }: {
4
4
  error?: Error;
5
5
  }) => React.JSX.Element;
6
6
  //# sourceMappingURL=Layout.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Layout.d.ts","sourceRoot":"","sources":["../../../../../src/components/Layout/Layout.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAwD,MAAM,OAAO,CAAC;AA+D5G,eAAO,MAAM,MAAM,GAAI,cAAc,iBAAiB,CAAC,EAAE,CAAC,sBAiJzD,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,WAAW;IAAE,KAAK,CAAC,EAAE,KAAK,CAAA;CAAE,sBAczD,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from './Layout';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Layout/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC"}
@@ -1,9 +1,4 @@
1
- import { OperationPlugin, type Plugin, RuntimePlugin, SettingsPlugin } from '@dxos/app-framework';
2
- import { AttentionPlugin } from '@dxos/plugin-attention';
3
- import { ClientPlugin } from '@dxos/plugin-client';
4
- import { GraphPlugin } from '@dxos/plugin-graph';
5
- import { ThemePlugin } from '@dxos/plugin-theme';
6
- export { AttentionPlugin, ClientPlugin, GraphPlugin, OperationPlugin, RuntimePlugin, SettingsPlugin, ThemePlugin };
1
+ import { type Plugin } from '@dxos/app-framework';
7
2
  /**
8
3
  * Core plugins for testing/storybook environments.
9
4
  * NOTE: Does not include SpacePlugin to avoid circular dependencies.
@@ -1 +1 @@
1
- {"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../../../src/core.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,KAAK,MAAM,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAClG,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAKjD,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,WAAW,EAAE,eAAe,EAAE,aAAa,EAAE,cAAc,EAAE,WAAW,EAAE,CAAC;AAEnH;;;;GAIG;AACH,eAAO,MAAM,WAAW,QAAO,MAAM,CAAC,MAAM,EAO3C,CAAC"}
1
+ {"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../../../src/core.ts"],"names":[],"mappings":"AAIA,OAAO,EAAmB,KAAK,MAAM,EAAiB,MAAM,qBAAqB,CAAC;AAOlF;;;;GAIG;AACH,eAAO,MAAM,WAAW,QAAO,MAAM,CAAC,MAAM,EAO3C,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.AddToast>;
4
+ export default handler;
5
+ //# sourceMappingURL=add-toast.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"add-toast.d.ts","sourceRoot":"","sources":["../../../../src/operations/add-toast.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,QAAQ,CAQnE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.Close>;
4
+ export default handler;
5
+ //# sourceMappingURL=close.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"close.d.ts","sourceRoot":"","sources":["../../../../src/operations/close.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,KAAK,CAEhE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { OperationHandlerSet } from '@dxos/operation';
2
+ export declare const TestingOperationHandlerSet: OperationHandlerSet.OperationHandlerSet;
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/operations/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAEtD,eAAO,MAAM,0BAA0B,yCAWtC,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.Open>;
4
+ export default handler;
5
+ //# sourceMappingURL=open.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open.d.ts","sourceRoot":"","sources":["../../../../src/operations/open.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,IAAI,CAM/D,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.ScrollIntoView>;
4
+ export default handler;
5
+ //# sourceMappingURL=scroll-into-view.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scroll-into-view.d.ts","sourceRoot":"","sources":["../../../../src/operations/scroll-into-view.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,cAAc,CAEzE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.SetLayoutMode>;
4
+ export default handler;
5
+ //# sourceMappingURL=set-layout-mode.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"set-layout-mode.d.ts","sourceRoot":"","sources":["../../../../src/operations/set-layout-mode.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,aAAa,CAExE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.SwitchWorkspace>;
4
+ export default handler;
5
+ //# sourceMappingURL=switch-workspace.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"switch-workspace.d.ts","sourceRoot":"","sources":["../../../../src/operations/switch-workspace.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,eAAe,CAM1E,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.UpdateComplementary>;
4
+ export default handler;
5
+ //# sourceMappingURL=update-complementary.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-complementary.d.ts","sourceRoot":"","sources":["../../../../src/operations/update-complementary.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,mBAAmB,CAa5E,CAAC;AAEJ,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.UpdateDialog>;
4
+ export default handler;
5
+ //# sourceMappingURL=update-dialog.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-dialog.d.ts","sourceRoot":"","sources":["../../../../src/operations/update-dialog.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,YAAY,CAavE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.UpdatePopover>;
4
+ export default handler;
5
+ //# sourceMappingURL=update-popover.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-popover.d.ts","sourceRoot":"","sources":["../../../../src/operations/update-popover.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAK5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,aAAa,CAsBxE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { LayoutOperation } from '@dxos/app-toolkit';
2
+ import { Operation } from '@dxos/operation';
3
+ declare const handler: Operation.WithHandler<typeof LayoutOperation.UpdateSidebar>;
4
+ export default handler;
5
+ //# sourceMappingURL=update-sidebar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-sidebar.d.ts","sourceRoot":"","sources":["../../../../src/operations/update-sidebar.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,QAAA,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAAC,OAAO,eAAe,CAAC,aAAa,CAYxE,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,5 @@
1
+ import * as Effect from 'effect/Effect';
2
+ import { Capability } from '@dxos/app-framework';
3
+ import { type LayoutStateProps } from '../types';
4
+ export declare const updateState: (fn: (state: LayoutStateProps) => Partial<LayoutStateProps>) => Effect.Effect<void, Error, Capability.Service>;
5
+ //# sourceMappingURL=update-state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-state.d.ts","sourceRoot":"","sources":["../../../../src/operations/update-state.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAgB,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAE/D,OAAO,EAAe,KAAK,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE9D,eAAO,MAAM,WAAW,GAAI,IAAI,CAAC,KAAK,EAAE,gBAAgB,KAAK,OAAO,CAAC,gBAAgB,CAAC,mDAMlF,CAAC"}
@@ -1,5 +1,6 @@
1
1
  import { type Atom } from '@effect-atom/atom-react';
2
2
  import { Capability } from '@dxos/app-framework';
3
+ import { type LayoutOperation } from '@dxos/app-toolkit';
3
4
  import { type Label } from '@dxos/react-ui';
4
5
  export type LayoutStateProps = {
5
6
  sidebarState?: 'expanded' | 'collapsed' | 'closed';
@@ -19,6 +20,7 @@ export type LayoutStateProps = {
19
20
  popoverKind?: 'base' | 'card';
20
21
  popoverTitle?: Label;
21
22
  popoverContent?: any;
23
+ toasts: LayoutOperation.Toast[];
22
24
  workspace: string;
23
25
  };
24
26
  export declare const LayoutState: Capability.InterfaceDef<Atom.Writable<LayoutStateProps, LayoutStateProps>>;
@@ -1 +1 @@
1
- {"version":3,"file":"capabilities.d.ts","sourceRoot":"","sources":["../../../../src/types/capabilities.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,yBAAyB,CAAC;AAEpD,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAI5C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,YAAY,CAAC,EAAE,UAAU,GAAG,WAAW,GAAG,QAAQ,CAAC;IACnD,yBAAyB,CAAC,EAAE,UAAU,GAAG,WAAW,GAAG,QAAQ,CAAC;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