@dxos/plugin-deck 0.6.8-main.046e6cf

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 (106) hide show
  1. package/LICENSE +8 -0
  2. package/README.md +15 -0
  3. package/dist/lib/browser/chunk-YVHGFQQR.mjs +12 -0
  4. package/dist/lib/browser/chunk-YVHGFQQR.mjs.map +7 -0
  5. package/dist/lib/browser/index.mjs +1657 -0
  6. package/dist/lib/browser/index.mjs.map +7 -0
  7. package/dist/lib/browser/meta.json +1 -0
  8. package/dist/lib/browser/meta.mjs +9 -0
  9. package/dist/lib/browser/meta.mjs.map +7 -0
  10. package/dist/types/src/DeckPlugin.d.ts +15 -0
  11. package/dist/types/src/DeckPlugin.d.ts.map +1 -0
  12. package/dist/types/src/components/DeckContext.d.ts +8 -0
  13. package/dist/types/src/components/DeckContext.d.ts.map +1 -0
  14. package/dist/types/src/components/DeckLayout/ActiveNode.d.ts +5 -0
  15. package/dist/types/src/components/DeckLayout/ActiveNode.d.ts.map +1 -0
  16. package/dist/types/src/components/DeckLayout/ComplementarySidebar.d.ts +9 -0
  17. package/dist/types/src/components/DeckLayout/ComplementarySidebar.d.ts.map +1 -0
  18. package/dist/types/src/components/DeckLayout/ContentEmpty.d.ts +3 -0
  19. package/dist/types/src/components/DeckLayout/ContentEmpty.d.ts.map +1 -0
  20. package/dist/types/src/components/DeckLayout/DeckLayout.d.ts +25 -0
  21. package/dist/types/src/components/DeckLayout/DeckLayout.d.ts.map +1 -0
  22. package/dist/types/src/components/DeckLayout/Fallback.d.ts +3 -0
  23. package/dist/types/src/components/DeckLayout/Fallback.d.ts.map +1 -0
  24. package/dist/types/src/components/DeckLayout/Fullscreen.d.ts +5 -0
  25. package/dist/types/src/components/DeckLayout/Fullscreen.d.ts.map +1 -0
  26. package/dist/types/src/components/DeckLayout/NodePlankHeading.d.ts +14 -0
  27. package/dist/types/src/components/DeckLayout/NodePlankHeading.d.ts.map +1 -0
  28. package/dist/types/src/components/DeckLayout/Plank.d.ts +14 -0
  29. package/dist/types/src/components/DeckLayout/Plank.d.ts.map +1 -0
  30. package/dist/types/src/components/DeckLayout/PlankError.d.ts +14 -0
  31. package/dist/types/src/components/DeckLayout/PlankError.d.ts.map +1 -0
  32. package/dist/types/src/components/DeckLayout/PlankLoading.d.ts +3 -0
  33. package/dist/types/src/components/DeckLayout/PlankLoading.d.ts.map +1 -0
  34. package/dist/types/src/components/DeckLayout/Sidebar.d.ts +8 -0
  35. package/dist/types/src/components/DeckLayout/Sidebar.d.ts.map +1 -0
  36. package/dist/types/src/components/DeckLayout/Toast.d.ts +5 -0
  37. package/dist/types/src/components/DeckLayout/Toast.d.ts.map +1 -0
  38. package/dist/types/src/components/DeckLayout/constants.d.ts +3 -0
  39. package/dist/types/src/components/DeckLayout/constants.d.ts.map +1 -0
  40. package/dist/types/src/components/DeckLayout/index.d.ts +3 -0
  41. package/dist/types/src/components/DeckLayout/index.d.ts.map +1 -0
  42. package/dist/types/src/components/LayoutContext.d.ts +5 -0
  43. package/dist/types/src/components/LayoutContext.d.ts.map +1 -0
  44. package/dist/types/src/components/LayoutSettings.d.ts +6 -0
  45. package/dist/types/src/components/LayoutSettings.d.ts.map +1 -0
  46. package/dist/types/src/components/index.d.ts +5 -0
  47. package/dist/types/src/components/index.d.ts.map +1 -0
  48. package/dist/types/src/hooks/index.d.ts +3 -0
  49. package/dist/types/src/hooks/index.d.ts.map +1 -0
  50. package/dist/types/src/hooks/useNode.d.ts +11 -0
  51. package/dist/types/src/hooks/useNode.d.ts.map +1 -0
  52. package/dist/types/src/hooks/useNodeActionExpander.d.ts +3 -0
  53. package/dist/types/src/hooks/useNodeActionExpander.d.ts.map +1 -0
  54. package/dist/types/src/index.d.ts +4 -0
  55. package/dist/types/src/index.d.ts.map +1 -0
  56. package/dist/types/src/layout.d.ts +25 -0
  57. package/dist/types/src/layout.d.ts.map +1 -0
  58. package/dist/types/src/layout.test.d.ts +2 -0
  59. package/dist/types/src/layout.test.d.ts.map +1 -0
  60. package/dist/types/src/meta.d.ts +7 -0
  61. package/dist/types/src/meta.d.ts.map +1 -0
  62. package/dist/types/src/translations.d.ts +41 -0
  63. package/dist/types/src/translations.d.ts.map +1 -0
  64. package/dist/types/src/types.d.ts +16 -0
  65. package/dist/types/src/types.d.ts.map +1 -0
  66. package/dist/types/src/util/check-app-scheme.d.ts +2 -0
  67. package/dist/types/src/util/check-app-scheme.d.ts.map +1 -0
  68. package/dist/types/src/util/index.d.ts +4 -0
  69. package/dist/types/src/util/index.d.ts.map +1 -0
  70. package/dist/types/src/util/layout-parts.d.ts +7 -0
  71. package/dist/types/src/util/layout-parts.d.ts.map +1 -0
  72. package/dist/types/src/util/overscroll.d.ts +7 -0
  73. package/dist/types/src/util/overscroll.d.ts.map +1 -0
  74. package/package.json +76 -0
  75. package/src/DeckPlugin.tsx +629 -0
  76. package/src/components/DeckContext.ts +14 -0
  77. package/src/components/DeckLayout/ActiveNode.tsx +24 -0
  78. package/src/components/DeckLayout/ComplementarySidebar.tsx +58 -0
  79. package/src/components/DeckLayout/ContentEmpty.tsx +21 -0
  80. package/src/components/DeckLayout/DeckLayout.tsx +270 -0
  81. package/src/components/DeckLayout/Fallback.tsx +28 -0
  82. package/src/components/DeckLayout/Fullscreen.tsx +32 -0
  83. package/src/components/DeckLayout/NodePlankHeading.tsx +160 -0
  84. package/src/components/DeckLayout/Plank.tsx +142 -0
  85. package/src/components/DeckLayout/PlankError.tsx +64 -0
  86. package/src/components/DeckLayout/PlankLoading.tsx +15 -0
  87. package/src/components/DeckLayout/Sidebar.tsx +43 -0
  88. package/src/components/DeckLayout/Toast.tsx +48 -0
  89. package/src/components/DeckLayout/constants.ts +6 -0
  90. package/src/components/DeckLayout/index.ts +6 -0
  91. package/src/components/LayoutContext.ts +12 -0
  92. package/src/components/LayoutSettings.tsx +86 -0
  93. package/src/components/index.ts +8 -0
  94. package/src/hooks/index.ts +6 -0
  95. package/src/hooks/useNode.ts +40 -0
  96. package/src/hooks/useNodeActionExpander.ts +24 -0
  97. package/src/index.ts +9 -0
  98. package/src/layout.test.ts +380 -0
  99. package/src/layout.ts +245 -0
  100. package/src/meta.ts +10 -0
  101. package/src/translations.ts +47 -0
  102. package/src/types.ts +38 -0
  103. package/src/util/check-app-scheme.ts +21 -0
  104. package/src/util/index.ts +7 -0
  105. package/src/util/layout-parts.ts +12 -0
  106. package/src/util/overscroll.ts +97 -0
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import { type LayoutParts, type LayoutPart, type LayoutEntry } from '@dxos/app-framework';
3
+ import { type Node } from '@dxos/plugin-graph';
4
+ export declare const NodePlankHeading: ({ node, id, layoutParts, layoutPart, layoutEntry, popoverAnchorId, pending, flatDeck, }: {
5
+ node?: Node;
6
+ id?: string;
7
+ layoutParts?: LayoutParts;
8
+ layoutPart?: LayoutPart;
9
+ layoutEntry?: LayoutEntry;
10
+ popoverAnchorId?: string;
11
+ pending?: boolean;
12
+ flatDeck?: boolean;
13
+ }) => React.JSX.Element;
14
+ //# sourceMappingURL=NodePlankHeading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NodePlankHeading.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/NodePlankHeading.tsx"],"names":[],"mappings":"AAKA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAEnD,OAAO,EASL,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,WAAW,EACjB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,IAAI,EAAY,MAAM,oBAAoB,CAAC;AAOzD,eAAO,MAAM,gBAAgB,4FAU1B;IACD,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,sBAiHA,CAAC"}
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import { type LayoutEntry, type LayoutPart, type LayoutParts } from '@dxos/app-framework';
3
+ import { type ClassNameValue } from '@dxos/react-ui';
4
+ export type PlankProps = {
5
+ entry: LayoutEntry;
6
+ layoutParts: LayoutParts;
7
+ part: LayoutPart;
8
+ resizeable?: boolean;
9
+ flatDeck?: boolean;
10
+ searchEnabled?: boolean;
11
+ classNames?: ClassNameValue;
12
+ };
13
+ export declare const Plank: ({ entry, layoutParts, part, resizeable, flatDeck, searchEnabled, classNames }: PlankProps) => React.JSX.Element;
14
+ //# sourceMappingURL=Plank.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Plank.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/Plank.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAE3C,OAAO,EAGL,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,WAAW,EAIjB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EAAmC,KAAK,cAAc,EAAE,MAAM,gBAAgB,CAAC;AActF,MAAM,MAAM,UAAU,GAAG;IACvB,KAAK,EAAE,WAAW,CAAC;IACnB,WAAW,EAAE,WAAW,CAAC;IAEzB,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,UAAU,CAAC,EAAE,cAAc,CAAC;CAC7B,CAAC;AAEF,eAAO,MAAM,KAAK,kFAAmF,UAAU,sBAiG9G,CAAC"}
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import { type LayoutCoordinate } from '@dxos/app-framework';
3
+ import { type Node } from '@dxos/plugin-graph';
4
+ export declare const PlankContentError: ({ error }: {
5
+ error?: Error;
6
+ }) => React.JSX.Element;
7
+ export declare const PlankError: ({ layoutCoordinate, id, node, error, flatDeck, }: {
8
+ layoutCoordinate: LayoutCoordinate;
9
+ id: string;
10
+ node?: Node;
11
+ error?: Error;
12
+ flatDeck?: boolean;
13
+ }) => React.JSX.Element;
14
+ //# sourceMappingURL=PlankError.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlankError.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/PlankError.tsx"],"names":[],"mappings":"AAIA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAEnD,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAQ/C,eAAO,MAAM,iBAAiB,cAAe;IAAE,KAAK,CAAC,EAAE,KAAK,CAAA;CAAE,sBAiB7D,CAAC;AAEF,eAAO,MAAM,UAAU,qDAMpB;IACD,gBAAgB,EAAE,gBAAgB,CAAC;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,sBAiBA,CAAC"}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ export declare const PlankLoading: () => React.JSX.Element;
3
+ //# sourceMappingURL=PlankLoading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlankLoading.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/PlankLoading.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,eAAO,MAAM,YAAY,yBAMxB,CAAC"}
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import { type Attention, type LayoutParts } from '@dxos/app-framework';
3
+ export type SidebarProps = {
4
+ attention: Attention;
5
+ layoutParts: LayoutParts;
6
+ };
7
+ export declare const Sidebar: ({ attention, layoutParts }: SidebarProps) => React.JSX.Element;
8
+ //# sourceMappingURL=Sidebar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Sidebar.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/Sidebar.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAEvC,OAAO,EAAE,KAAK,SAAS,EAAE,KAAK,WAAW,EAAoB,MAAM,qBAAqB,CAAC;AAKzF,MAAM,MAAM,YAAY,GAAG;IACzB,SAAS,EAAE,SAAS,CAAC;IACrB,WAAW,EAAE,WAAW,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,OAAO,+BAAgC,YAAY,sBA0B/D,CAAC"}
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import type { Toast as ToastProps } from '@dxos/app-framework';
3
+ import { type ToastRootProps } from '@dxos/react-ui';
4
+ export declare const Toast: ({ id, title, description, icon, duration, actionLabel, actionAlt, closeLabel, onAction, onOpenChange, }: ToastProps & Pick<ToastRootProps, "onOpenChange">) => React.JSX.Element;
5
+ //# sourceMappingURL=Toast.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/Toast.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,KAAK,IAAI,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,EAAiC,KAAK,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGpF,eAAO,MAAM,KAAK,4GAWf,UAAU,GAAG,IAAI,CAAC,cAAc,EAAE,cAAc,CAAC,sBA0BnD,CAAC"}
@@ -0,0 +1,3 @@
1
+ export declare const NAV_ID = "NavTree";
2
+ export declare const SURFACE_PREFIX = "surface:";
3
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/constants.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,MAAM,YAAY,CAAC;AAChC,eAAO,MAAM,cAAc,aAAa,CAAC"}
@@ -0,0 +1,3 @@
1
+ export { NAV_ID } from './constants';
2
+ export * from './DeckLayout';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/DeckLayout/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,cAAc,cAAc,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { type Context } from 'react';
2
+ import type { Layout } from '@dxos/app-framework';
3
+ export declare const LayoutContext: Context<Layout | null>;
4
+ export declare const useLayout: () => Layout;
5
+ //# sourceMappingURL=LayoutContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LayoutContext.d.ts","sourceRoot":"","sources":["../../../../src/components/LayoutContext.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,OAAO,EAA6B,MAAM,OAAO,CAAC;AAEhE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAGlD,eAAO,MAAM,aAAa,EAAE,OAAO,CAAC,MAAM,GAAG,IAAI,CAAsC,CAAC;AAExF,eAAO,MAAM,SAAS,QAAO,MAAgF,CAAC"}
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { type DeckSettingsProps } from '../types';
3
+ export declare const LayoutSettings: ({ settings }: {
4
+ settings: DeckSettingsProps;
5
+ }) => React.JSX.Element;
6
+ //# sourceMappingURL=LayoutSettings.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LayoutSettings.d.ts","sourceRoot":"","sources":["../../../../src/components/LayoutSettings.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,EAGL,KAAK,iBAAiB,EAGvB,MAAM,UAAU,CAAC;AAIlB,eAAO,MAAM,cAAc,iBAAkB;IAAE,QAAQ,EAAE,iBAAiB,CAAA;CAAE,sBAiE3E,CAAC"}
@@ -0,0 +1,5 @@
1
+ export * from './DeckLayout';
2
+ export * from './DeckContext';
3
+ export * from './LayoutContext';
4
+ export * from './LayoutSettings';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/index.ts"],"names":[],"mappings":"AAIA,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './useNode';
2
+ export * from './useNodeActionExpander';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/hooks/index.ts"],"names":[],"mappings":"AAIA,cAAc,WAAW,CAAC;AAC1B,cAAc,yBAAyB,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { type Graph, type Node } from '@dxos/plugin-graph';
2
+ /**
3
+ * React hook to get a node from the graph.
4
+ *
5
+ * @param graph Graph to find the node in.
6
+ * @param id Id of the node to find.
7
+ * @param timeout Optional timeout in milliseconds to wait for the node to be found.
8
+ * @returns Node if found, undefined otherwise.
9
+ */
10
+ export declare const useNode: <T = any>(graph: Graph, id?: string, timeout?: number) => Node<T> | undefined;
11
+ //# sourceMappingURL=useNode.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useNode.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useNode.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAE3D;;;;;;;GAOG;AAEH,eAAO,MAAM,OAAO,GAAI,CAAC,eAAe,KAAK,OAAO,MAAM,YAAY,MAAM,KAAG,IAAI,CAAC,CAAC,CAAC,GAAG,SAsBxF,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { type Node } from '@dxos/plugin-graph';
2
+ export declare const useNodeActionExpander: (node?: Node) => void;
3
+ //# sourceMappingURL=useNodeActionExpander.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useNodeActionExpander.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useNodeActionExpander.ts"],"names":[],"mappings":"AAMA,OAAO,EAA4C,KAAK,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAQzF,eAAO,MAAM,qBAAqB,UAAW,IAAI,SAShD,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { DeckPlugin } from './DeckPlugin';
2
+ export default DeckPlugin;
3
+ export * from './DeckPlugin';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,eAAe,UAAU,CAAC;AAE1B,cAAc,cAAc,CAAC"}
@@ -0,0 +1,25 @@
1
+ import { type LayoutAdjustment, type LayoutCoordinate, type LayoutEntry, type LayoutParts, type LayoutPart } from '@dxos/app-framework';
2
+ import { type NewPlankPositioning } from './types';
3
+ type OpenLayoutEntryOptions = {
4
+ positioning?: NewPlankPositioning;
5
+ pivotId?: string;
6
+ };
7
+ export declare const openEntry: (layout: LayoutParts, part: LayoutPart, entry: LayoutEntry, options?: OpenLayoutEntryOptions) => LayoutParts;
8
+ export declare const closeEntry: (layout: LayoutParts, layoutCoordinate: LayoutCoordinate) => LayoutParts;
9
+ export declare const incrementPlank: (layout: LayoutParts, adjustment: LayoutAdjustment) => LayoutParts;
10
+ export declare const removePart: (layout: LayoutParts, part: LayoutPart) => LayoutParts;
11
+ export declare const mergeLayoutParts: (...layoutParts: LayoutParts[]) => LayoutParts;
12
+ export declare const uriToSoloPart: (uri: string) => LayoutParts | undefined;
13
+ export declare const soloPartToUri: (layout: LayoutParts) => string;
14
+ /**
15
+ * Converts a URI string into a LayoutParts object.
16
+ * @deprecated Keeping these as a reference for now. We should remove these once we're sure we don't need them.
17
+ */
18
+ export declare const uriToActiveParts: (uri: string) => LayoutParts;
19
+ /**
20
+ * Converts a LayoutParts object into a URI string.
21
+ * @deprecated Keeping these as a reference for now. We should remove these once we're sure we don't need them.
22
+ */
23
+ export declare const activePartsToUri: (activeParts: LayoutParts) => string;
24
+ export {};
25
+ //# sourceMappingURL=layout.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../../src/layout.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,WAAW,EAKhB,KAAK,UAAU,EAChB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAQnD,KAAK,sBAAsB,GAAG;IAAE,WAAW,CAAC,EAAE,mBAAmB,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEtF,eAAO,MAAM,SAAS,WACZ,WAAW,QACb,UAAU,SACT,WAAW,YACR,sBAAsB,KAC/B,WAwCF,CAAC;AAEF,eAAO,MAAM,UAAU,WAAY,WAAW,oBAAoB,gBAAgB,KAAG,WAoBpF,CAAC;AAEF,eAAO,MAAM,cAAc,WAAY,WAAW,cAAc,gBAAgB,KAAG,WA+BlF,CAAC;AAEF,eAAO,MAAM,UAAU,WAAY,WAAW,QAAQ,UAAU,KAAG,WAIlE,CAAC;AAEF,eAAO,MAAM,gBAAgB,mBAAoB,WAAW,EAAE,KAAG,WAyBhE,CAAC;AAcF,eAAO,MAAM,aAAa,QAAS,MAAM,KAAG,WAAW,GAAG,SAYzD,CAAC;AAEF,eAAO,MAAM,aAAa,WAAY,WAAW,KAAG,MAQnD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,QAAS,MAAM,KAAG,WAgB9C,CAAC;AAiBF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,gBAAiB,WAAW,KAAG,MAK3D,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=layout.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"layout.test.d.ts","sourceRoot":"","sources":["../../../src/layout.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,7 @@
1
+ export declare const DECK_PLUGIN = "dxos.org/plugin/deck";
2
+ declare const _default: {
3
+ id: string;
4
+ name: string;
5
+ };
6
+ export default _default;
7
+ //# sourceMappingURL=meta.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.d.ts","sourceRoot":"","sources":["../../../src/meta.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,WAAW,yBAAyB,CAAC;;;;;AAElD,wBAGE"}
@@ -0,0 +1,41 @@
1
+ declare const _default: {
2
+ 'en-US': {
3
+ "dxos.org/plugin/deck": {
4
+ 'main header label': string;
5
+ 'open navigation sidebar label': string;
6
+ 'open complementary sidebar label': string;
7
+ 'open settings label': string;
8
+ 'plugin error message': string;
9
+ 'content fallback message': string;
10
+ 'content fallback description': string;
11
+ 'toggle fullscreen label': string;
12
+ 'settings show footer label': string;
13
+ 'settings native redirect label': string;
14
+ 'settings custom slots': string;
15
+ 'settings new plank position start label': string;
16
+ 'settings new plank position end label': string;
17
+ 'select new plank positioning placeholder': string;
18
+ 'select new plank positioning label': string;
19
+ 'undo available label': string;
20
+ 'undo action label': string;
21
+ 'undo action alt': string;
22
+ 'undo close label': string;
23
+ 'open comments label': string;
24
+ 'error fallback message': string;
25
+ 'plank heading fallback label': string;
26
+ 'actions menu label': string;
27
+ 'settings deck label': string;
28
+ 'reload required message': string;
29
+ 'pending heading': string;
30
+ 'insert plank label': string;
31
+ 'solo plank label': string;
32
+ 'settings overscroll label': string;
33
+ 'select overscroll placeholder': string;
34
+ 'settings overscroll centering label': string;
35
+ 'settings overscroll none label': string;
36
+ 'settings flat deck': string;
37
+ };
38
+ };
39
+ }[];
40
+ export default _default;
41
+ //# sourceMappingURL=translations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"translations.d.ts","sourceRoot":"","sources":["../../../src/translations.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,wBAyCE"}
@@ -0,0 +1,16 @@
1
+ import type { GraphBuilderProvides, IntentResolverProvides, LayoutProvides, LocationProvides, SettingsProvides, SurfaceProvides, TranslationsProvides } from '@dxos/app-framework';
2
+ export declare const NewPlankPositions: readonly ["start", "end"];
3
+ export type NewPlankPositioning = (typeof NewPlankPositions)[number];
4
+ export declare const OverscrollOptions: readonly ["none", "centering"];
5
+ export type Overscroll = (typeof OverscrollOptions)[number];
6
+ export type DeckSettingsProps = {
7
+ showFooter: boolean;
8
+ customSlots: boolean;
9
+ flatDeck: boolean;
10
+ enableNativeRedirect: boolean;
11
+ disableDeck: boolean;
12
+ newPlankPositioning: NewPlankPositioning;
13
+ overscroll: Overscroll;
14
+ };
15
+ export type DeckPluginProvides = SurfaceProvides & IntentResolverProvides & GraphBuilderProvides & TranslationsProvides & SettingsProvides<DeckSettingsProps> & LayoutProvides & LocationProvides;
16
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,oBAAoB,EACpB,sBAAsB,EACtB,cAAc,EACd,gBAAgB,EAChB,gBAAgB,EAChB,eAAe,EACf,oBAAoB,EACrB,MAAM,qBAAqB,CAAC;AAG7B,eAAO,MAAM,iBAAiB,2BAA4B,CAAC;AAC3D,MAAM,MAAM,mBAAmB,GAAG,CAAC,OAAO,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAC;AAErE,eAAO,MAAM,iBAAiB,gCAAiC,CAAC;AAChE,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE5D,MAAM,MAAM,iBAAiB,GAAG;IAC9B,UAAU,EAAE,OAAO,CAAC;IACpB,WAAW,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,WAAW,EAAE,OAAO,CAAC;IACrB,mBAAmB,EAAE,mBAAmB,CAAC;IACzC,UAAU,EAAE,UAAU,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG,eAAe,GAC9C,sBAAsB,GACtB,oBAAoB,GACpB,oBAAoB,GACpB,gBAAgB,CAAC,iBAAiB,CAAC,GACnC,cAAc,GACd,gBAAgB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const checkAppScheme: (url: string) => void;
2
+ //# sourceMappingURL=check-app-scheme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"check-app-scheme.d.ts","sourceRoot":"","sources":["../../../../src/util/check-app-scheme.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,cAAc,QAAS,MAAM,SAezC,CAAC"}
@@ -0,0 +1,4 @@
1
+ export * from './check-app-scheme';
2
+ export * from './layout-parts';
3
+ export * from './overscroll';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/util/index.ts"],"names":[],"mappings":"AAIA,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { type LayoutMode, type LayoutPart } from '@dxos/app-framework';
2
+ /**
3
+ * If in solo mode and the part is the main part, open it in solo mode.
4
+ * From the dispatch POV we refer to both 'solo' and 'main' as 'main'.
5
+ */
6
+ export declare const getEffectivePart: (partName: LayoutPart, layoutMode: LayoutMode) => LayoutPart;
7
+ //# sourceMappingURL=layout-parts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"layout-parts.d.ts","sourceRoot":"","sources":["../../../../src/util/layout-parts.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEvE;;;GAGG;AACH,eAAO,MAAM,gBAAgB,aAAc,UAAU,cAAc,UAAU,KAAG,UACd,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { type LayoutMode, type LayoutParts } from '@dxos/app-framework';
2
+ import { type Overscroll } from '../types';
3
+ export declare const calculateOverscroll: (layoutMode: LayoutMode, sidebarOpen: boolean, complementarySidebarOpen: boolean, layoutParts: LayoutParts, plankSizing: Record<string, number>, overscroll: Overscroll) => {
4
+ paddingLeft: string;
5
+ paddingRight: string;
6
+ } | undefined;
7
+ //# sourceMappingURL=overscroll.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"overscroll.d.ts","sourceRoot":"","sources":["../../../../src/util/overscroll.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAGxE,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,UAAU,CAAC;AAE3C,eAAO,MAAM,mBAAmB,eAClB,UAAU,eACT,OAAO,4BACM,OAAO,eACpB,WAAW,eACX,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,cACvB,UAAU;;;aAiFvB,CAAC"}
package/package.json ADDED
@@ -0,0 +1,76 @@
1
+ {
2
+ "name": "@dxos/plugin-deck",
3
+ "version": "0.6.8-main.046e6cf",
4
+ "description": "DXOS Surface plugin for the main application layout.",
5
+ "homepage": "https://dxos.org",
6
+ "bugs": "https://github.com/dxos/dxos/issues",
7
+ "license": "MIT",
8
+ "author": "DXOS.org",
9
+ "exports": {
10
+ ".": {
11
+ "browser": "./dist/lib/browser/index.mjs",
12
+ "types": "./dist/types/src/index.d.ts"
13
+ },
14
+ "./meta": {
15
+ "browser": "./dist/lib/browser/meta.mjs",
16
+ "types": "./dist/types/src/meta.d.ts"
17
+ }
18
+ },
19
+ "types": "dist/types/src/index.d.ts",
20
+ "typesVersions": {
21
+ "*": {
22
+ "meta": [
23
+ "dist/types/src/meta.d.ts"
24
+ ]
25
+ }
26
+ },
27
+ "files": [
28
+ "dist",
29
+ "src"
30
+ ],
31
+ "dependencies": {
32
+ "@preact/signals-core": "^1.6.0",
33
+ "immer": "^10.1.1",
34
+ "@dxos/app-framework": "0.6.8-main.046e6cf",
35
+ "@dxos/async": "0.6.8-main.046e6cf",
36
+ "@dxos/echo-schema": "0.6.8-main.046e6cf",
37
+ "@dxos/debug": "0.6.8-main.046e6cf",
38
+ "@dxos/invariant": "0.6.8-main.046e6cf",
39
+ "@dxos/keyboard": "0.6.8-main.046e6cf",
40
+ "@dxos/log": "0.6.8-main.046e6cf",
41
+ "@dxos/plugin-attention": "0.6.8-main.046e6cf",
42
+ "@dxos/local-storage": "0.6.8-main.046e6cf",
43
+ "@dxos/plugin-client": "0.6.8-main.046e6cf",
44
+ "@dxos/plugin-graph": "0.6.8-main.046e6cf",
45
+ "@dxos/plugin-observability": "0.6.8-main.046e6cf",
46
+ "@dxos/plugin-theme": "0.6.8-main.046e6cf",
47
+ "@dxos/react-client": "0.6.8-main.046e6cf",
48
+ "@dxos/plugin-settings": "0.6.8-main.046e6cf",
49
+ "@dxos/react-ui-attention": "0.6.8-main.046e6cf",
50
+ "@dxos/react-ui-deck": "0.6.8-main.046e6cf",
51
+ "@dxos/react-ui-mosaic": "0.6.8-main.046e6cf",
52
+ "@dxos/react-ui-text-tooltip": "0.6.8-main.046e6cf",
53
+ "@dxos/util": "0.6.8-main.046e6cf"
54
+ },
55
+ "devDependencies": {
56
+ "@phosphor-icons/react": "^2.1.5",
57
+ "@types/react": "~18.2.0",
58
+ "@types/react-dom": "~18.2.0",
59
+ "react": "~18.2.0",
60
+ "react-dom": "~18.2.0",
61
+ "vite": "^5.3.4",
62
+ "@dxos/react-ui": "0.6.8-main.046e6cf",
63
+ "@dxos/react-ui-theme": "0.6.8-main.046e6cf",
64
+ "@dxos/storybook-utils": "0.6.8-main.046e6cf"
65
+ },
66
+ "peerDependencies": {
67
+ "@phosphor-icons/react": "^2.0.5",
68
+ "react": "^18.0.0",
69
+ "react-dom": "^18.0.0",
70
+ "@dxos/react-ui": "0.6.8-main.046e6cf",
71
+ "@dxos/react-ui-theme": "0.6.8-main.046e6cf"
72
+ },
73
+ "publishConfig": {
74
+ "access": "public"
75
+ }
76
+ }