@dxos/plugin-simple-layout 0.8.4-staging.60fe92afc8 → 0.9.1-main.c7dcc2e112

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 (83) hide show
  1. package/dist/lib/neutral/capabilities/index.mjs +3 -3
  2. package/dist/lib/neutral/{chunk-7UDV3JDT.mjs → chunk-5DF656PN.mjs} +2 -2
  3. package/dist/lib/neutral/{chunk-FD2CAY4Q.mjs → chunk-LLTNQSEB.mjs} +2 -2
  4. package/dist/lib/neutral/chunk-LLTNQSEB.mjs.map +7 -0
  5. package/dist/lib/neutral/chunk-NTI42Y3O.mjs +8 -0
  6. package/dist/lib/neutral/chunk-T2JFEPBT.mjs +31 -0
  7. package/dist/lib/neutral/chunk-T2JFEPBT.mjs.map +7 -0
  8. package/dist/lib/neutral/{close-WKMURGUB.mjs → close-5ZAMG3N7.mjs} +3 -3
  9. package/dist/lib/neutral/components/index.mjs +10 -12
  10. package/dist/lib/neutral/components/index.mjs.map +3 -3
  11. package/dist/lib/neutral/hooks/index.mjs +4 -4
  12. package/dist/lib/neutral/hooks/index.mjs.map +3 -3
  13. package/dist/lib/neutral/index.mjs +2 -2
  14. package/dist/lib/neutral/meta.json +1 -1
  15. package/dist/lib/neutral/meta.mjs +1 -1
  16. package/dist/lib/neutral/{open-Y4KNROHW.mjs → open-TI35QPEC.mjs} +6 -6
  17. package/dist/lib/neutral/open-TI35QPEC.mjs.map +7 -0
  18. package/dist/lib/neutral/operations/index.mjs +1 -1
  19. package/dist/lib/neutral/plugin.mjs +2 -2
  20. package/dist/lib/neutral/{react-root-VE265VX4.mjs → react-root-JX7QKKR2.mjs} +2 -2
  21. package/dist/lib/neutral/{react-root-VE265VX4.mjs.map → react-root-JX7QKKR2.mjs.map} +3 -3
  22. package/dist/lib/neutral/{react-surface-N3PGKIYV.mjs → react-surface-GV3O3I25.mjs} +6 -12
  23. package/dist/lib/neutral/react-surface-GV3O3I25.mjs.map +7 -0
  24. package/dist/lib/neutral/{revert-workspace-ST6NZUNG.mjs → revert-workspace-KI6QHPTX.mjs} +3 -3
  25. package/dist/lib/neutral/{set-6ZRLWPJS.mjs → set-C4HII3NF.mjs} +3 -3
  26. package/dist/lib/neutral/{switch-workspace-PYWPTMFO.mjs → switch-workspace-E664GRHY.mjs} +5 -5
  27. package/dist/lib/neutral/switch-workspace-E664GRHY.mjs.map +7 -0
  28. package/dist/lib/neutral/translations.mjs +1 -1
  29. package/dist/lib/neutral/translations.mjs.map +3 -3
  30. package/dist/lib/neutral/types/index.mjs +1 -1
  31. package/dist/lib/neutral/{update-complementary-HKWF5OXT.mjs → update-complementary-BCWHK4SM.mjs} +3 -3
  32. package/dist/lib/neutral/{update-dialog-P4ASXCE7.mjs → update-dialog-TCKGS26T.mjs} +3 -3
  33. package/dist/lib/neutral/{update-popover-REAKC2GN.mjs → update-popover-NRI2OATE.mjs} +3 -3
  34. package/dist/lib/neutral/{url-handler-DGZ4WISE.mjs → url-handler-BJX33VLR.mjs} +5 -5
  35. package/dist/lib/neutral/url-handler-BJX33VLR.mjs.map +7 -0
  36. package/dist/types/dx.config.d.ts +28 -0
  37. package/dist/types/dx.config.d.ts.map +1 -0
  38. package/dist/types/src/capabilities/index.d.ts +6 -18
  39. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  40. package/dist/types/src/capabilities/react-surface.d.ts +2 -2
  41. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  42. package/dist/types/src/components/Popover/Popover.d.ts.map +1 -1
  43. package/dist/types/src/hooks/useAppBarProps.d.ts.map +1 -1
  44. package/dist/types/src/meta.d.ts +28 -2
  45. package/dist/types/src/meta.d.ts.map +1 -1
  46. package/dist/types/src/operations/open.d.ts.map +1 -1
  47. package/dist/types/src/operations/switch-workspace.d.ts.map +1 -1
  48. package/dist/types/src/types/SimpleLayoutCapabilities.d.ts +1 -1
  49. package/dist/types/src/types/SimpleLayoutCapabilities.d.ts.map +1 -1
  50. package/dist/types/tsconfig.tsbuildinfo +1 -1
  51. package/dx.config.ts +20 -0
  52. package/package.json +29 -28
  53. package/src/capabilities/react-root.tsx +1 -1
  54. package/src/capabilities/react-surface.tsx +8 -16
  55. package/src/capabilities/url-handler.ts +4 -4
  56. package/src/components/Home/Home.tsx +3 -3
  57. package/src/components/NavBranch/NavBranch.tsx +2 -2
  58. package/src/components/Popover/Popover.tsx +7 -5
  59. package/src/components/SimpleLayout/AppBar.tsx +2 -2
  60. package/src/hooks/useAppBarProps.ts +3 -2
  61. package/src/hooks/useDrawerActions.ts +1 -1
  62. package/src/hooks/useNavbarActions.ts +1 -1
  63. package/src/meta.ts +3 -13
  64. package/src/operations/open.ts +5 -8
  65. package/src/operations/switch-workspace.ts +2 -2
  66. package/src/translations.ts +1 -1
  67. package/src/types/SimpleLayoutCapabilities.ts +2 -2
  68. package/dist/lib/neutral/chunk-FD2CAY4Q.mjs.map +0 -7
  69. package/dist/lib/neutral/chunk-NKAPURKM.mjs +0 -8
  70. package/dist/lib/neutral/chunk-OK5336TS.mjs +0 -22
  71. package/dist/lib/neutral/chunk-OK5336TS.mjs.map +0 -7
  72. package/dist/lib/neutral/open-Y4KNROHW.mjs.map +0 -7
  73. package/dist/lib/neutral/react-surface-N3PGKIYV.mjs.map +0 -7
  74. package/dist/lib/neutral/switch-workspace-PYWPTMFO.mjs.map +0 -7
  75. package/dist/lib/neutral/url-handler-DGZ4WISE.mjs.map +0 -7
  76. /package/dist/lib/neutral/{chunk-7UDV3JDT.mjs.map → chunk-5DF656PN.mjs.map} +0 -0
  77. /package/dist/lib/neutral/{chunk-NKAPURKM.mjs.map → chunk-NTI42Y3O.mjs.map} +0 -0
  78. /package/dist/lib/neutral/{close-WKMURGUB.mjs.map → close-5ZAMG3N7.mjs.map} +0 -0
  79. /package/dist/lib/neutral/{revert-workspace-ST6NZUNG.mjs.map → revert-workspace-KI6QHPTX.mjs.map} +0 -0
  80. /package/dist/lib/neutral/{set-6ZRLWPJS.mjs.map → set-C4HII3NF.mjs.map} +0 -0
  81. /package/dist/lib/neutral/{update-complementary-HKWF5OXT.mjs.map → update-complementary-BCWHK4SM.mjs.map} +0 -0
  82. /package/dist/lib/neutral/{update-dialog-P4ASXCE7.mjs.map → update-dialog-TCKGS26T.mjs.map} +0 -0
  83. /package/dist/lib/neutral/{update-popover-REAKC2GN.mjs.map → update-popover-NRI2OATE.mjs.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/hooks/useAppBarProps.ts", "../../../../src/hooks/useCompanions.ts", "../../../../src/hooks/actions.ts", "../../../../src/hooks/useDrawerActions.ts", "../../../../src/hooks/useSimpleLayoutState.ts", "../../../../src/hooks/useNavbarActions.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom, useAtomValue } from '@effect-atom/atom-react';\nimport * as Option from 'effect/Option';\nimport { useCallback, useMemo } from 'react';\n\nimport { useCapability, useOperationInvoker } from '@dxos/app-framework/ui';\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Graph, Node, useActionRunner, useNode } from '@dxos/plugin-graph';\nimport { toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { type ActionGraphProps } from '@dxos/react-ui-menu';\n\nimport { type AppBarProps } from '#components';\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\n/**\n * Hook that computes all AppBar props from the app graph.\n * Derives activeId from state atom. Returns props ready to spread into the AppBar component.\n */\nexport const useAppBarProps = (): Omit<AppBarProps, 'classNames'> => {\n const { t } = useTranslation(meta.id);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const state = useAtomValue(stateAtom);\n const { graph } = useAppGraph();\n const { invokePromise } = useOperationInvoker();\n const runAction = useActionRunner();\n\n // Derive activeId from state.\n const activeId = state.active ?? state.workspace;\n const node = useNode(graph, activeId);\n\n // Compute title from node label.\n const title = node ? toLocalizedString(node.properties.label, t) : undefined;\n\n // Build actions atom filtering by disposition.\n // Derive activeId from state atom so we don't need to recreate this atom when it changes.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n const state = get(stateAtom);\n const activeId = state.active ?? state.workspace;\n const allActions = activeId ? get(graph.actions(activeId)) : [];\n const filtered = allActions.filter((action) =>\n ['list-item', 'list-item-primary', 'heading-list-item'].includes(action.properties.disposition),\n );\n const nodes: ActionGraphProps['nodes'] = filtered as ActionGraphProps['nodes'];\n const edges: ActionGraphProps['edges'] = filtered.map((action) => ({\n source: 'root',\n target: action.id,\n relation: 'child',\n }));\n\n return { nodes, edges };\n }),\n [graph, stateAtom],\n );\n\n // Back button logic.\n const showBackButton = activeId !== undefined && activeId !== Node.RootId;\n\n const onBack = useCallback(() => {\n if (state.active) {\n const isWorkspace = Graph.getNode(graph, state.active).pipe(\n Option.map((node) => node.properties.disposition === 'workspace'),\n Option.getOrElse(() => false),\n );\n\n // If history is empty and this is a workspace, go to home.\n if (state.history.length === 0 && isWorkspace) {\n void invokePromise(LayoutOperation.SwitchWorkspace, { subject: Node.RootId });\n } else {\n // Otherwise, close (which will pop from history or clear active).\n void invokePromise(LayoutOperation.Close, { subject: [state.active] });\n }\n } else {\n void invokePromise(LayoutOperation.SwitchWorkspace, { subject: Node.RootId });\n }\n }, [graph, invokePromise, state.active, state.history.length]);\n\n // Compute popover anchor ID.\n const popoverAnchorId = node && state.popoverAnchorId === `${meta.id}:${node.id}` ? state.popoverAnchorId : undefined;\n\n return {\n title,\n actions: actionsAtom,\n showBackButton,\n popoverAnchorId,\n onBack: onBack,\n onAction: runAction,\n };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { useMemo } from 'react';\n\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { useConnections } from '@dxos/plugin-graph';\nimport { byPosition } from '@dxos/util';\n\nimport { PLANK_COMPANION_TYPE } from './actions';\n\n/**\n * @deprecated Adopt the pattern from useNavbarActions (deriving from graph atoms)\n * or merge the Drawer companion display into the NavBar component.\n */\nexport const useCompanions = (nodeId?: string) => {\n const { graph } = useAppGraph();\n const nodes = useConnections(graph, nodeId, 'child');\n const companions = nodes.filter((node) => node.type === PLANK_COMPANION_TYPE);\n return useMemo(() => companions.toSorted((a, b) => byPosition(a.properties, b.properties)), [companions]);\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { type Atom } from '@effect-atom/atom-react';\nimport * as Effect from 'effect/Effect';\n\nimport { type AppCapabilities } from '@dxos/app-toolkit';\nimport { Node } from '@dxos/plugin-graph';\nimport { getLinkedVariant } from '@dxos/react-ui-attention';\nimport { type ActionGraphProps } from '@dxos/react-ui-menu';\nimport { byPosition } from '@dxos/util';\n\nimport { SimpleLayoutCapabilities } from '#types';\n\n// TODO(wittjosiah): Factor out to shared location with plugin-deck.\nexport const PLANK_COMPANION_TYPE = 'org.dxos.plugin.deck.plank-companion';\n\nexport type CompanionActionsConfig = {\n /** Prefix for companion action IDs (e.g. 'navbar' or 'drawer') */\n idPrefix: string;\n /** Optional: highlight companion with this variant */\n selectedVariant?: string;\n /** State updater for toggling the drawer. */\n updateState: (\n fn: (state: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState,\n ) => void;\n};\n\n/**\n * Creates action graph nodes and edges for companion actions.\n * Shared logic between useNavbarActions and useDrawerActions.\n */\n// TODO(burdon): Use builder pattern.\nexport const createCompanionActions = (\n graph: AppCapabilities.AppGraph['graph'],\n stateAtom: Atom.Atom<SimpleLayoutCapabilities.SimpleLayoutState>,\n get: (atom: Atom.Atom<any>) => any,\n config: CompanionActionsConfig,\n): Pick<ActionGraphProps, 'nodes' | 'edges'> => {\n const { idPrefix, selectedVariant, updateState } = config;\n\n // Derive activeId from state atom.\n const state = get(stateAtom);\n const activeId = state.active ?? state.workspace;\n\n // Get companions from graph connections for activeId.\n const activeConnections = activeId ? get(graph.connections(activeId, 'child')) : [];\n const companions = activeConnections\n .filter((node: Node.Node) => node.type === PLANK_COMPANION_TYPE)\n .toSorted((a: Node.Node, b: Node.Node) => byPosition(a.properties, b.properties));\n\n const nodes: ActionGraphProps['nodes'] = [];\n const edges: ActionGraphProps['edges'] = [];\n\n companions.forEach((companion: Node.Node) => {\n const companionVariant = getLinkedVariant(companion.id);\n const companionAction = {\n id: `${idPrefix}-companion-${companion.id}`,\n type: Node.ActionType,\n properties: {\n icon: companion.properties.icon ?? 'ph--circle-dashed--regular',\n label: companion.properties.label,\n iconOnly: true,\n ...(selectedVariant !== undefined && {\n variant: selectedVariant === companionVariant ? 'primary' : 'ghost',\n }),\n },\n data: () =>\n Effect.sync(() =>\n updateState((current) => {\n const closing = current.companionVariant === companionVariant && current.drawerState !== 'closed';\n return {\n ...current,\n companionVariant: closing ? undefined : companionVariant,\n drawerState: closing ? 'closed' : 'open',\n };\n }),\n ),\n };\n nodes.push(companionAction);\n edges.push({ source: 'root', target: companionAction.id, relation: 'child' });\n });\n\n return { nodes, edges };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom } from '@effect-atom/atom-react';\nimport * as Effect from 'effect/Effect';\nimport { useMemo } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Node, useActionRunner } from '@dxos/plugin-graph';\nimport { useTranslation } from '@dxos/react-ui';\nimport { type ActionExecutor, type ActionGraphProps, createGapSeparator } from '@dxos/react-ui-menu';\n\nimport { useMobileLayout } from '#components';\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\nimport { createCompanionActions } from './actions';\nimport { useSimpleLayoutState } from './useSimpleLayoutState';\n\nexport type DrawerActions = {\n /** Action graph atom for the drawer. */\n actions: Atom.Atom<ActionGraphProps>;\n /** Action executor callback. */\n onAction: ActionExecutor;\n};\n\n/**\n * Builds the drawer actions including companion tabs and toolbar buttons.\n */\nexport const useDrawerActions = (consumerName: string): DrawerActions => {\n const { t } = useTranslation(meta.id);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const { graph } = useAppGraph();\n const runAction = useActionRunner();\n const { updateState } = useSimpleLayoutState();\n const { keyboardOpen } = useMobileLayout(consumerName);\n\n // Create a computed atom that derives everything from graph connections and state.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n // Derive drawer state from state atom.\n const state = get(stateAtom);\n\n // Add companion tab actions.\n const { nodes, edges } = createCompanionActions(graph, stateAtom, get, {\n idPrefix: 'drawer',\n selectedVariant: state.drawerState !== 'closed' ? state.companionVariant : undefined,\n updateState,\n });\n\n // Add gap separator before toolbar buttons.\n const gapSeparator = createGapSeparator('drawer-gap');\n nodes.push(...gapSeparator.nodes);\n edges.push(...gapSeparator.edges);\n\n // Add expand/collapse toggle button (hidden when keyboard is open).\n if (!keyboardOpen) {\n const isExpanded = state.drawerState === 'expanded';\n const toggleExpandAction = {\n id: 'drawer-toggle-expand',\n type: Node.ActionType,\n properties: {\n icon: isExpanded ? 'ph--arrow-down--regular' : 'ph--arrow-up--regular',\n label: isExpanded ? t('collapse-drawer.label') : t('expand-drawer.label'),\n iconOnly: true,\n },\n data: () =>\n Effect.sync(() => updateState((state) => ({ ...state, drawerState: isExpanded ? 'open' : 'expanded' }))),\n };\n nodes.push(toggleExpandAction);\n edges.push({ source: 'root', target: toggleExpandAction.id, relation: 'child' });\n }\n\n // Add close button.\n const closeAction = {\n id: 'drawer-close',\n type: Node.ActionType,\n properties: {\n icon: 'ph--x--regular',\n label: t('close-drawer.label'),\n iconOnly: true,\n },\n data: () =>\n Effect.sync(() =>\n updateState((state) => ({ ...state, drawerState: 'closed', companionVariant: undefined })),\n ),\n };\n nodes.push(closeAction);\n edges.push({ source: 'root', target: closeAction.id, relation: 'child' });\n\n return { nodes, edges };\n }),\n [graph, stateAtom, updateState, keyboardOpen, t],\n );\n\n return { actions: actionsAtom, onAction: runAction };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { RegistryContext, useAtomValue } from '@effect-atom/atom-react';\nimport { useCallback, useContext } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\n\nimport { SimpleLayoutCapabilities } from '#types';\n\nexport type UseSimpleLayoutState = {\n state: SimpleLayoutCapabilities.SimpleLayoutState;\n updateState: (\n fn: (current: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState,\n ) => void;\n};\n\nexport const useSimpleLayoutState = (): UseSimpleLayoutState => {\n const registry = useContext(RegistryContext);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const state = useAtomValue(stateAtom);\n\n const updateState = useCallback(\n (fn: (current: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState) => {\n registry.set(stateAtom, fn(registry.get(stateAtom)));\n },\n [registry, stateAtom],\n );\n\n return { state, updateState };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom } from '@effect-atom/atom-react';\nimport { useMemo } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Node, useActionRunner } from '@dxos/plugin-graph';\nimport { useTranslation } from '@dxos/react-ui';\nimport {\n type ActionExecutor,\n type ActionGraphProps,\n createGapSeparator,\n createMenuItemGroup,\n} from '@dxos/react-ui-menu';\n\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\nimport { createCompanionActions } from './actions';\nimport { useSimpleLayoutState } from './useSimpleLayoutState';\n\nconst MAIN_MENU_GROUP_ID = 'navbar-main-menu';\n\nexport type NavbarActions = {\n /** Action graph atom for the navbar. */\n actions: Atom.Atom<ActionGraphProps>;\n /** Action executor callback. */\n onAction: ActionExecutor;\n};\n\n/**\n * Builds the navbar actions including companion icons, separator, and main menu dropdown.\n * Derives everything from graph connection atoms for proper reactivity.\n */\nexport const useNavbarActions = (): NavbarActions => {\n const { t } = useTranslation(meta.id);\n const { graph } = useAppGraph();\n const runAction = useActionRunner();\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const { updateState } = useSimpleLayoutState();\n\n // Create a computed atom that derives everything from graph connections and state.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n // Add companion actions.\n const { nodes, edges } = createCompanionActions(graph, stateAtom, get, {\n idPrefix: 'navbar',\n updateState,\n });\n\n // Add gap separator.\n const gapSeparator = createGapSeparator('navbar-gap');\n nodes.push(...gapSeparator.nodes);\n edges.push(...gapSeparator.edges);\n\n // Add main menu dropdown group.\n const mainMenuGroup = createMenuItemGroup(MAIN_MENU_GROUP_ID, {\n variant: 'dropdownMenu',\n icon: 'ph--list--regular',\n iconOnly: true,\n label: t('main-menu.label'),\n testId: 'simpleLayoutPlugin.addSpace',\n });\n nodes.push(mainMenuGroup);\n edges.push({ source: 'root', target: mainMenuGroup.id, relation: 'child' });\n\n // Get menu actions from root actions (on 'action' edge relation).\n const rootActions = get(graph.actions(Node.RootId));\n const menuActions = rootActions.filter((node) => node.properties.disposition === 'menu');\n\n // Add menu actions as children of the dropdown group.\n menuActions.forEach((menuAction) => {\n nodes.push(menuAction as ActionGraphProps['nodes'][number]);\n edges.push({ source: MAIN_MENU_GROUP_ID, target: menuAction.id, relation: 'child' });\n });\n\n return { nodes, edges };\n }),\n [graph, stateAtom, updateState, t],\n );\n\n return { actions: actionsAtom, onAction: runAction };\n};\n"],
5
- "mappings": ";;;AAIA,SAASA,MAAMC,oBAAoB;AACnC,YAAYC,YAAY;AACxB,SAASC,aAAaC,eAAe;AAErC,SAASC,eAAeC,2BAA2B;AACnD,SAASC,uBAAuB;AAChC,SAASC,mBAAmB;AAC5B,SAASC,OAAOC,MAAMC,iBAAiBC,eAAe;AACtD,SAASC,mBAAmBC,sBAAsB;AAIlD,SAASC,YAAY;AACrB,SAASC,gCAAgC;AAMlC,IAAMC,iBAAiB,MAAA;AAC5B,QAAM,EAAEC,EAAC,IAAKJ,eAAeC,KAAKI,EAAE;AACpC,QAAMC,YAAYf,cAAcW,yB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SAAO;IAAEqC,SAASvB;IAAaiC,UAAUzC;EAAU;AACrD;",
6
- "names": ["Atom", "useAtomValue", "Option", "useCallback", "useMemo", "useCapability", "useOperationInvoker", "LayoutOperation", "useAppGraph", "Graph", "Node", "useActionRunner", "useNode", "toLocalizedString", "useTranslation", "meta", "SimpleLayoutCapabilities", "useAppBarProps", "t", "id", "stateAtom", "State", "state", "graph", "invokePromise", "runAction", "activeId", "active", "workspace", "node", "title", "properties", "label", "undefined", "actionsAtom", "make", "get", "allActions", "actions", "filtered", "filter", "action", "includes", "disposition", "nodes", "edges", "map", "source", "target", "relation", "showBackButton", "RootId", "onBack", "isWorkspace", "getNode", "pipe", "getOrElse", "history", "length", "SwitchWorkspace", "subject", "Close", "popoverAnchorId", "onAction", "useMemo", "useAppGraph", "useConnections", "byPosition", "Effect", "Node", "getLinkedVariant", "byPosition", "PLANK_COMPANION_TYPE", "createCompanionActions", "graph", "stateAtom", "get", "config", "idPrefix", "selectedVariant", "updateState", "state", "activeId", "active", "workspace", "activeConnections", "connections", "companions", "filter", "node", "type", "toSorted", "a", "b", "properties", "nodes", "edges", "forEach", "companion", "companionVariant", "id", "companionAction", "ActionType", "icon", "label", "iconOnly", "undefined", "variant", "data", "sync", "current", "closing", "drawerState", "push", "source", "target", "relation", "useCompanions", "nodeId", "graph", "useAppGraph", "nodes", "useConnections", "companions", "filter", "node", "type", "PLANK_COMPANION_TYPE", "useMemo", "toSorted", "a", "b", "byPosition", "properties", "Atom", "Effect", "useMemo", "useCapability", "useAppGraph", "Node", "useActionRunner", "useTranslation", "createGapSeparator", "useMobileLayout", "meta", "SimpleLayoutCapabilities", "RegistryContext", "useAtomValue", "useCallback", "useContext", "useCapability", "SimpleLayoutCapabilities", "useSimpleLayoutState", "registry", "stateAtom", "State", "state", "updateState", "fn", "set", "get", "useDrawerActions", "consumerName", "t", "useTranslation", "meta", "id", "stateAtom", "useCapability", "SimpleLayoutCapabilities", "State", "graph", "useAppGraph", "runAction", "useActionRunner", "updateState", "useSimpleLayoutState", "keyboardOpen", "useMobileLayout", "actionsAtom", "useMemo", "Atom", "make", "get", "state", "nodes", "edges", "createCompanionActions", "idPrefix", "selectedVariant", "drawerState", "companionVariant", "undefined", "gapSeparator", "createGapSeparator", "push", "isExpanded", "toggleExpandAction", "type", "Node", "ActionType", "properties", "icon", "label", "iconOnly", "data", "sync", "source", "target", "relation", "closeAction", "actions", "onAction", "Atom", "useMemo", "useCapability", "useAppGraph", "Node", "useActionRunner", "useTranslation", "createGapSeparator", "createMenuItemGroup", "meta", "SimpleLayoutCapabilities", "MAIN_MENU_GROUP_ID", "useNavbarActions", "t", "useTranslation", "meta", "id", "graph", "useAppGraph", "runAction", "useActionRunner", "stateAtom", "useCapability", "SimpleLayoutCapabilities", "State", "updateState", "useSimpleLayoutState", "actionsAtom", "useMemo", "Atom", "make", "get", "nodes", "edges", "createCompanionActions", "idPrefix", "gapSeparator", "createGapSeparator", "push", "mainMenuGroup", "createMenuItemGroup", "variant", "icon", "iconOnly", "label", "testId", "source", "target", "relation", "rootActions", "actions", "Node", "RootId", "menuActions", "filter", "node", "properties", "disposition", "forEach", "menuAction", "onAction"]
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom, useAtomValue } from '@effect-atom/atom-react';\nimport * as Option from 'effect/Option';\nimport { useCallback, useMemo } from 'react';\n\nimport { useCapability, useOperationInvoker } from '@dxos/app-framework/ui';\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Graph, Node, useActionRunner, useNode } from '@dxos/plugin-graph';\nimport { toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { type ActionGraphProps } from '@dxos/react-ui-menu';\n\nimport { type AppBarProps } from '#components';\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\n/**\n * Hook that computes all AppBar props from the app graph.\n * Derives activeId from state atom. Returns props ready to spread into the AppBar component.\n */\nexport const useAppBarProps = (): Omit<AppBarProps, 'classNames'> => {\n const { t } = useTranslation(meta.profile.key);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const state = useAtomValue(stateAtom);\n const { graph } = useAppGraph();\n const { invokePromise } = useOperationInvoker();\n const runAction = useActionRunner();\n\n // Derive activeId from state.\n const activeId = state.active ?? state.workspace;\n const node = useNode(graph, activeId);\n\n // Compute title from node label.\n const title = node ? toLocalizedString(node.properties.label, t) : undefined;\n\n // Build actions atom filtering by disposition.\n // Derive activeId from state atom so we don't need to recreate this atom when it changes.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n const state = get(stateAtom);\n const activeId = state.active ?? state.workspace;\n const allActions = activeId ? get(graph.actions(activeId)) : [];\n const filtered = allActions.filter((action) =>\n ['list-item', 'list-item-primary', 'heading-list-item'].includes(action.properties.disposition),\n );\n const nodes: ActionGraphProps['nodes'] = filtered as ActionGraphProps['nodes'];\n const edges: ActionGraphProps['edges'] = filtered.map((action) => ({\n source: 'root',\n target: action.id,\n relation: 'child',\n }));\n\n return { nodes, edges };\n }),\n [graph, stateAtom],\n );\n\n // Back button logic.\n const showBackButton = activeId !== undefined && activeId !== Node.RootId;\n\n const onBack = useCallback(() => {\n if (state.active) {\n const isWorkspace = Graph.getNode(graph, state.active).pipe(\n Option.map((node) => node.properties.disposition === 'workspace'),\n Option.getOrElse(() => false),\n );\n\n // If history is empty and this is a workspace, go to home.\n if (state.history.length === 0 && isWorkspace) {\n void invokePromise(LayoutOperation.SwitchWorkspace, { subject: Node.RootId });\n } else {\n // Otherwise, close (which will pop from history or clear active).\n void invokePromise(LayoutOperation.Close, { subject: [state.active] });\n }\n } else {\n void invokePromise(LayoutOperation.SwitchWorkspace, { subject: Node.RootId });\n }\n }, [graph, invokePromise, state.active, state.history.length]);\n\n // Compute popover anchor ID.\n const popoverAnchorId =\n node && state.popoverAnchorId === `${meta.profile.key}:${node.id}` ? state.popoverAnchorId : undefined;\n\n return {\n title,\n actions: actionsAtom,\n showBackButton,\n popoverAnchorId,\n onBack: onBack,\n onAction: runAction,\n };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { useMemo } from 'react';\n\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { useConnections } from '@dxos/plugin-graph';\nimport { byPosition } from '@dxos/util';\n\nimport { PLANK_COMPANION_TYPE } from './actions';\n\n/**\n * @deprecated Adopt the pattern from useNavbarActions (deriving from graph atoms)\n * or merge the Drawer companion display into the NavBar component.\n */\nexport const useCompanions = (nodeId?: string) => {\n const { graph } = useAppGraph();\n const nodes = useConnections(graph, nodeId, 'child');\n const companions = nodes.filter((node) => node.type === PLANK_COMPANION_TYPE);\n return useMemo(() => companions.toSorted((a, b) => byPosition(a.properties, b.properties)), [companions]);\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { type Atom } from '@effect-atom/atom-react';\nimport * as Effect from 'effect/Effect';\n\nimport { type AppCapabilities } from '@dxos/app-toolkit';\nimport { Node } from '@dxos/plugin-graph';\nimport { getLinkedVariant } from '@dxos/react-ui-attention';\nimport { type ActionGraphProps } from '@dxos/react-ui-menu';\nimport { byPosition } from '@dxos/util';\n\nimport { SimpleLayoutCapabilities } from '#types';\n\n// TODO(wittjosiah): Factor out to shared location with plugin-deck.\nexport const PLANK_COMPANION_TYPE = 'org.dxos.plugin.deck.plank-companion';\n\nexport type CompanionActionsConfig = {\n /** Prefix for companion action IDs (e.g. 'navbar' or 'drawer') */\n idPrefix: string;\n /** Optional: highlight companion with this variant */\n selectedVariant?: string;\n /** State updater for toggling the drawer. */\n updateState: (\n fn: (state: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState,\n ) => void;\n};\n\n/**\n * Creates action graph nodes and edges for companion actions.\n * Shared logic between useNavbarActions and useDrawerActions.\n */\n// TODO(burdon): Use builder pattern.\nexport const createCompanionActions = (\n graph: AppCapabilities.AppGraph['graph'],\n stateAtom: Atom.Atom<SimpleLayoutCapabilities.SimpleLayoutState>,\n get: (atom: Atom.Atom<any>) => any,\n config: CompanionActionsConfig,\n): Pick<ActionGraphProps, 'nodes' | 'edges'> => {\n const { idPrefix, selectedVariant, updateState } = config;\n\n // Derive activeId from state atom.\n const state = get(stateAtom);\n const activeId = state.active ?? state.workspace;\n\n // Get companions from graph connections for activeId.\n const activeConnections = activeId ? get(graph.connections(activeId, 'child')) : [];\n const companions = activeConnections\n .filter((node: Node.Node) => node.type === PLANK_COMPANION_TYPE)\n .toSorted((a: Node.Node, b: Node.Node) => byPosition(a.properties, b.properties));\n\n const nodes: ActionGraphProps['nodes'] = [];\n const edges: ActionGraphProps['edges'] = [];\n\n companions.forEach((companion: Node.Node) => {\n const companionVariant = getLinkedVariant(companion.id);\n const companionAction = {\n id: `${idPrefix}-companion-${companion.id}`,\n type: Node.ActionType,\n properties: {\n icon: companion.properties.icon ?? 'ph--circle-dashed--regular',\n label: companion.properties.label,\n iconOnly: true,\n ...(selectedVariant !== undefined && {\n variant: selectedVariant === companionVariant ? 'primary' : 'ghost',\n }),\n },\n data: () =>\n Effect.sync(() =>\n updateState((current) => {\n const closing = current.companionVariant === companionVariant && current.drawerState !== 'closed';\n return {\n ...current,\n companionVariant: closing ? undefined : companionVariant,\n drawerState: closing ? 'closed' : 'open',\n };\n }),\n ),\n };\n nodes.push(companionAction);\n edges.push({ source: 'root', target: companionAction.id, relation: 'child' });\n });\n\n return { nodes, edges };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom } from '@effect-atom/atom-react';\nimport * as Effect from 'effect/Effect';\nimport { useMemo } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Node, useActionRunner } from '@dxos/plugin-graph';\nimport { useTranslation } from '@dxos/react-ui';\nimport { type ActionExecutor, type ActionGraphProps, createGapSeparator } from '@dxos/react-ui-menu';\n\nimport { useMobileLayout } from '#components';\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\nimport { createCompanionActions } from './actions';\nimport { useSimpleLayoutState } from './useSimpleLayoutState';\n\nexport type DrawerActions = {\n /** Action graph atom for the drawer. */\n actions: Atom.Atom<ActionGraphProps>;\n /** Action executor callback. */\n onAction: ActionExecutor;\n};\n\n/**\n * Builds the drawer actions including companion tabs and toolbar buttons.\n */\nexport const useDrawerActions = (consumerName: string): DrawerActions => {\n const { t } = useTranslation(meta.profile.key);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const { graph } = useAppGraph();\n const runAction = useActionRunner();\n const { updateState } = useSimpleLayoutState();\n const { keyboardOpen } = useMobileLayout(consumerName);\n\n // Create a computed atom that derives everything from graph connections and state.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n // Derive drawer state from state atom.\n const state = get(stateAtom);\n\n // Add companion tab actions.\n const { nodes, edges } = createCompanionActions(graph, stateAtom, get, {\n idPrefix: 'drawer',\n selectedVariant: state.drawerState !== 'closed' ? state.companionVariant : undefined,\n updateState,\n });\n\n // Add gap separator before toolbar buttons.\n const gapSeparator = createGapSeparator('drawer-gap');\n nodes.push(...gapSeparator.nodes);\n edges.push(...gapSeparator.edges);\n\n // Add expand/collapse toggle button (hidden when keyboard is open).\n if (!keyboardOpen) {\n const isExpanded = state.drawerState === 'expanded';\n const toggleExpandAction = {\n id: 'drawer-toggle-expand',\n type: Node.ActionType,\n properties: {\n icon: isExpanded ? 'ph--arrow-down--regular' : 'ph--arrow-up--regular',\n label: isExpanded ? t('collapse-drawer.label') : t('expand-drawer.label'),\n iconOnly: true,\n },\n data: () =>\n Effect.sync(() => updateState((state) => ({ ...state, drawerState: isExpanded ? 'open' : 'expanded' }))),\n };\n nodes.push(toggleExpandAction);\n edges.push({ source: 'root', target: toggleExpandAction.id, relation: 'child' });\n }\n\n // Add close button.\n const closeAction = {\n id: 'drawer-close',\n type: Node.ActionType,\n properties: {\n icon: 'ph--x--regular',\n label: t('close-drawer.label'),\n iconOnly: true,\n },\n data: () =>\n Effect.sync(() =>\n updateState((state) => ({ ...state, drawerState: 'closed', companionVariant: undefined })),\n ),\n };\n nodes.push(closeAction);\n edges.push({ source: 'root', target: closeAction.id, relation: 'child' });\n\n return { nodes, edges };\n }),\n [graph, stateAtom, updateState, keyboardOpen, t],\n );\n\n return { actions: actionsAtom, onAction: runAction };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { RegistryContext, useAtomValue } from '@effect-atom/atom-react';\nimport { useCallback, useContext } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\n\nimport { SimpleLayoutCapabilities } from '#types';\n\nexport type UseSimpleLayoutState = {\n state: SimpleLayoutCapabilities.SimpleLayoutState;\n updateState: (\n fn: (current: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState,\n ) => void;\n};\n\nexport const useSimpleLayoutState = (): UseSimpleLayoutState => {\n const registry = useContext(RegistryContext);\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const state = useAtomValue(stateAtom);\n\n const updateState = useCallback(\n (fn: (current: SimpleLayoutCapabilities.SimpleLayoutState) => SimpleLayoutCapabilities.SimpleLayoutState) => {\n registry.set(stateAtom, fn(registry.get(stateAtom)));\n },\n [registry, stateAtom],\n );\n\n return { state, updateState };\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom } from '@effect-atom/atom-react';\nimport { useMemo } from 'react';\n\nimport { useCapability } from '@dxos/app-framework/ui';\nimport { useAppGraph } from '@dxos/app-toolkit/ui';\nimport { Node, useActionRunner } from '@dxos/plugin-graph';\nimport { useTranslation } from '@dxos/react-ui';\nimport {\n type ActionExecutor,\n type ActionGraphProps,\n createGapSeparator,\n createMenuItemGroup,\n} from '@dxos/react-ui-menu';\n\nimport { meta } from '#meta';\nimport { SimpleLayoutCapabilities } from '#types';\n\nimport { createCompanionActions } from './actions';\nimport { useSimpleLayoutState } from './useSimpleLayoutState';\n\nconst MAIN_MENU_GROUP_ID = 'navbar-main-menu';\n\nexport type NavbarActions = {\n /** Action graph atom for the navbar. */\n actions: Atom.Atom<ActionGraphProps>;\n /** Action executor callback. */\n onAction: ActionExecutor;\n};\n\n/**\n * Builds the navbar actions including companion icons, separator, and main menu dropdown.\n * Derives everything from graph connection atoms for proper reactivity.\n */\nexport const useNavbarActions = (): NavbarActions => {\n const { t } = useTranslation(meta.profile.key);\n const { graph } = useAppGraph();\n const runAction = useActionRunner();\n const stateAtom = useCapability(SimpleLayoutCapabilities.State);\n const { updateState } = useSimpleLayoutState();\n\n // Create a computed atom that derives everything from graph connections and state.\n const actionsAtom = useMemo(\n () =>\n Atom.make((get): ActionGraphProps => {\n // Add companion actions.\n const { nodes, edges } = createCompanionActions(graph, stateAtom, get, {\n idPrefix: 'navbar',\n updateState,\n });\n\n // Add gap separator.\n const gapSeparator = createGapSeparator('navbar-gap');\n nodes.push(...gapSeparator.nodes);\n edges.push(...gapSeparator.edges);\n\n // Add main menu dropdown group.\n const mainMenuGroup = createMenuItemGroup(MAIN_MENU_GROUP_ID, {\n variant: 'dropdownMenu',\n icon: 'ph--list--regular',\n iconOnly: true,\n label: t('main-menu.label'),\n testId: 'simpleLayoutPlugin.addSpace',\n });\n nodes.push(mainMenuGroup);\n edges.push({ source: 'root', target: mainMenuGroup.id, relation: 'child' });\n\n // Get menu actions from root actions (on 'action' edge relation).\n const rootActions = get(graph.actions(Node.RootId));\n const menuActions = rootActions.filter((node) => node.properties.disposition === 'menu');\n\n // Add menu actions as children of the dropdown group.\n menuActions.forEach((menuAction) => {\n nodes.push(menuAction as ActionGraphProps['nodes'][number]);\n edges.push({ source: MAIN_MENU_GROUP_ID, target: menuAction.id, relation: 'child' });\n });\n\n return { nodes, edges };\n }),\n [graph, stateAtom, updateState, t],\n );\n\n return { actions: actionsAtom, onAction: runAction };\n};\n"],
5
+ "mappings": ";;;AAIA,SAASA,MAAMC,oBAAoB;AACnC,YAAYC,YAAY;AACxB,SAASC,aAAaC,eAAe;AAErC,SAASC,eAAeC,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,SAASA,KAAKC,WAAWC,gBAAgB,MAAA;AAGjFJ,gBAAYK,QAAQ,CAACC,eAAAA;AACnB5B,YAAMM,KAAKsB,UAAAA;AACX3B,YAAMK,KAAK;QAAEQ,QAAQpC;QAAoBqC,QAAQa,WAAWZ;QAAIC,UAAU;MAAQ,CAAA;IACpF,CAAA;AAEA,WAAO;MAAEjB;MAAOC;IAAM;EACxB,CAAA,GACF;IAAChB;IAAOI;IAAWI;IAAab;GAAE;AAGpC,SAAO;IAAEuC,SAASxB;IAAakC,UAAU1C;EAAU;AACrD;",
6
+ "names": ["Atom", "useAtomValue", "Option", "useCallback", "useMemo", "useCapability", "useOperationInvoker", "LayoutOperation", "useAppGraph", "Graph", "Node", "useActionRunner", "useNode", "toLocalizedString", "useTranslation", "meta", "SimpleLayoutCapabilities", "useAppBarProps", "t", "profile", "key", "stateAtom", "State", "state", "graph", "invokePromise", "runAction", "activeId", "active", "workspace", "node", "title", "properties", "label", "undefined", "actionsAtom", "make", "get", "allActions", "actions", "filtered", "filter", "action", "includes", "disposition", "nodes", "edges", "map", "source", "target", "id", "relation", "showBackButton", "RootId", "onBack", "isWorkspace", "getNode", "pipe", "getOrElse", "history", "length", "SwitchWorkspace", "subject", "Close", "popoverAnchorId", "onAction", "useMemo", "useAppGraph", "useConnections", "byPosition", "Effect", "Node", "getLinkedVariant", "byPosition", "PLANK_COMPANION_TYPE", "createCompanionActions", "graph", "stateAtom", "get", "config", "idPrefix", "selectedVariant", "updateState", "state", "activeId", "active", "workspace", "activeConnections", "connections", "companions", "filter", "node", "type", "toSorted", "a", "b", "properties", "nodes", "edges", "forEach", "companion", "companionVariant", "id", "companionAction", "ActionType", "icon", "label", "iconOnly", "undefined", "variant", "data", "sync", "current", "closing", "drawerState", "push", "source", "target", "relation", "useCompanions", "nodeId", "graph", "useAppGraph", "nodes", "useConnections", "companions", "filter", "node", "type", "PLANK_COMPANION_TYPE", "useMemo", "toSorted", "a", "b", "byPosition", "properties", "Atom", "Effect", "useMemo", "useCapability", "useAppGraph", "Node", "useActionRunner", "useTranslation", "createGapSeparator", "useMobileLayout", "meta", "SimpleLayoutCapabilities", "RegistryContext", "useAtomValue", "useCallback", "useContext", "useCapability", "SimpleLayoutCapabilities", "useSimpleLayoutState", "registry", "stateAtom", "State", "state", "updateState", "fn", "set", "get", "useDrawerActions", "consumerName", "t", "useTranslation", "meta", "profile", "key", "stateAtom", "useCapability", "SimpleLayoutCapabilities", "State", "graph", "useAppGraph", "runAction", "useActionRunner", "updateState", "useSimpleLayoutState", "keyboardOpen", "useMobileLayout", "actionsAtom", "useMemo", "Atom", "make", "get", "state", "nodes", "edges", "createCompanionActions", "idPrefix", "selectedVariant", "drawerState", "companionVariant", "undefined", "gapSeparator", "createGapSeparator", "push", "isExpanded", "toggleExpandAction", "id", "type", "Node", "ActionType", "properties", "icon", "label", "iconOnly", "data", "sync", "source", "target", "relation", "closeAction", "actions", "onAction", "Atom", "useMemo", "useCapability", "useAppGraph", "Node", "useActionRunner", "useTranslation", "createGapSeparator", "createMenuItemGroup", "meta", "SimpleLayoutCapabilities", "MAIN_MENU_GROUP_ID", "useNavbarActions", "t", "useTranslation", "meta", "profile", "key", "graph", "useAppGraph", "runAction", "useActionRunner", "stateAtom", "useCapability", "SimpleLayoutCapabilities", "State", "updateState", "useSimpleLayoutState", "actionsAtom", "useMemo", "Atom", "make", "get", "nodes", "edges", "createCompanionActions", "idPrefix", "gapSeparator", "createGapSeparator", "push", "mainMenuGroup", "createMenuItemGroup", "variant", "icon", "iconOnly", "label", "testId", "source", "target", "id", "relation", "rootActions", "actions", "Node", "RootId", "menuActions", "filter", "node", "properties", "disposition", "forEach", "menuAction", "onAction"]
7
7
  }
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  SimpleLayoutCapabilities_exports,
3
3
  SimpleLayoutEvents_exports
4
- } from "./chunk-FD2CAY4Q.mjs";
4
+ } from "./chunk-LLTNQSEB.mjs";
5
5
  import {
6
6
  meta
7
- } from "./chunk-OK5336TS.mjs";
7
+ } from "./chunk-T2JFEPBT.mjs";
8
8
  import "./chunk-J5LGTIGS.mjs";
9
9
  export {
10
10
  SimpleLayoutCapabilities_exports as SimpleLayoutCapabilities,