@dxos/plugin-space 0.6.12-main.5cc132e → 0.6.12-main.78ddbdf

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 (65) hide show
  1. package/dist/lib/browser/{chunk-DTVUOG2C.mjs → chunk-WBMH5WIP.mjs} +14 -2
  2. package/dist/lib/browser/chunk-WBMH5WIP.mjs.map +7 -0
  3. package/dist/lib/browser/index.mjs +400 -177
  4. package/dist/lib/browser/index.mjs.map +4 -4
  5. package/dist/lib/browser/meta.json +1 -1
  6. package/dist/lib/browser/types/index.mjs +7 -3
  7. package/dist/lib/node/{chunk-CVZPI2P3.cjs → chunk-GF3SRAQM.cjs} +20 -6
  8. package/dist/lib/node/chunk-GF3SRAQM.cjs.map +7 -0
  9. package/dist/lib/node/index.cjs +509 -289
  10. package/dist/lib/node/index.cjs.map +4 -4
  11. package/dist/lib/node/meta.json +1 -1
  12. package/dist/lib/node/types/index.cjs +14 -10
  13. package/dist/lib/node/types/index.cjs.map +2 -2
  14. package/dist/lib/node-esm/{chunk-LZEGRS7H.mjs → chunk-GM2YUC77.mjs} +3 -1
  15. package/dist/lib/node-esm/{chunk-LZEGRS7H.mjs.map → chunk-GM2YUC77.mjs.map} +1 -1
  16. package/dist/lib/node-esm/{chunk-DTVUOG2C.mjs → chunk-N5VC55UM.mjs} +16 -2
  17. package/dist/lib/node-esm/chunk-N5VC55UM.mjs.map +7 -0
  18. package/dist/lib/node-esm/index.mjs +402 -178
  19. package/dist/lib/node-esm/index.mjs.map +4 -4
  20. package/dist/lib/node-esm/meta.json +1 -1
  21. package/dist/lib/node-esm/meta.mjs +2 -1
  22. package/dist/lib/node-esm/types/index.mjs +8 -3
  23. package/dist/types/src/SpacePlugin.d.ts.map +1 -1
  24. package/dist/types/src/components/SaveStatus.d.ts.map +1 -1
  25. package/dist/types/src/components/ShareSpaceButton.stories.d.ts +2 -0
  26. package/dist/types/src/components/ShareSpaceButton.stories.d.ts.map +1 -1
  27. package/dist/types/src/components/SpaceMain/SpaceMain.d.ts.map +1 -1
  28. package/dist/types/src/components/SpacePresence.stories.d.ts +2 -0
  29. package/dist/types/src/components/SpacePresence.stories.d.ts.map +1 -1
  30. package/dist/types/src/components/SpaceSettings.d.ts.map +1 -1
  31. package/dist/types/src/components/SyncStatus/SyncStatus.d.ts +13 -0
  32. package/dist/types/src/components/SyncStatus/SyncStatus.d.ts.map +1 -0
  33. package/dist/types/src/components/SyncStatus/SyncStatus.stories.d.ts +115 -0
  34. package/dist/types/src/components/SyncStatus/SyncStatus.stories.d.ts.map +1 -0
  35. package/dist/types/src/components/SyncStatus/index.d.ts +2 -0
  36. package/dist/types/src/components/SyncStatus/index.d.ts.map +1 -0
  37. package/dist/types/src/components/SyncStatus/types.d.ts +14 -0
  38. package/dist/types/src/components/SyncStatus/types.d.ts.map +1 -0
  39. package/dist/types/src/components/index.d.ts +1 -0
  40. package/dist/types/src/components/index.d.ts.map +1 -1
  41. package/dist/types/src/translations.d.ts +2 -0
  42. package/dist/types/src/translations.d.ts.map +1 -1
  43. package/dist/types/src/types/thread.d.ts +13 -0
  44. package/dist/types/src/types/thread.d.ts.map +1 -1
  45. package/dist/types/src/types/types.d.ts +18 -1
  46. package/dist/types/src/types/types.d.ts.map +1 -1
  47. package/dist/types/src/util.d.ts +1 -4
  48. package/dist/types/src/util.d.ts.map +1 -1
  49. package/package.json +34 -32
  50. package/src/SpacePlugin.tsx +24 -13
  51. package/src/components/SaveStatus.tsx +6 -9
  52. package/src/components/SpaceMain/SpaceMain.tsx +1 -22
  53. package/src/components/SpaceSettings.tsx +32 -3
  54. package/src/components/SyncStatus/SyncStatus.stories.tsx +62 -0
  55. package/src/components/SyncStatus/SyncStatus.tsx +188 -0
  56. package/src/components/SyncStatus/index.ts +5 -0
  57. package/src/components/SyncStatus/types.ts +77 -0
  58. package/src/components/index.ts +1 -0
  59. package/src/translations.ts +2 -0
  60. package/src/types/thread.ts +9 -0
  61. package/src/types/types.ts +25 -1
  62. package/src/util.tsx +15 -50
  63. package/dist/lib/browser/chunk-DTVUOG2C.mjs.map +0 -7
  64. package/dist/lib/node/chunk-CVZPI2P3.cjs.map +0 -7
  65. package/dist/lib/node-esm/chunk-DTVUOG2C.mjs.map +0 -7
@@ -1,22 +1,24 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
1
2
  import {
2
3
  SPACE_PLUGIN,
3
4
  SPACE_PLUGIN_SHORT_ID,
4
5
  SpaceAction,
5
6
  meta_default
6
- } from "./chunk-LZEGRS7H.mjs";
7
+ } from "./chunk-GM2YUC77.mjs";
7
8
  import {
8
9
  ActorSchema,
9
10
  ChannelType,
10
11
  CollectionType,
11
12
  ContactType,
13
+ MessageState,
12
14
  MessageType,
13
15
  SPACE_DIRECTORY_HANDLE,
14
16
  ThreadStatus,
15
- ThreadType
16
- } from "./chunk-DTVUOG2C.mjs";
17
+ ThreadType,
18
+ parseSpaceInitPlugin
19
+ } from "./chunk-N5VC55UM.mjs";
17
20
 
18
21
  // packages/plugins/plugin-space/src/SpacePlugin.tsx
19
- import { CardsThree as CardsThree2, Plus as Plus2, SignIn, Warning as Warning2 } from "@phosphor-icons/react";
20
22
  import { effect, signal } from "@preact/signals-core";
21
23
  import React18 from "react";
22
24
  import { LayoutAction as LayoutAction2, NavigationAction as NavigationAction3, Surface as Surface2, firstIdInPart, openIds, parseGraphPlugin, parseIntentPlugin as parseIntentPlugin3, parseMetadataResolverPlugin, parseNavigationPlugin as parseNavigationPlugin2, resolvePlugin } from "@dxos/app-framework";
@@ -183,15 +185,13 @@ var EmptyTree = () => {
183
185
  };
184
186
 
185
187
  // packages/plugins/plugin-space/src/components/MenuFooter.tsx
186
- import { Planet as Planet2 } from "@phosphor-icons/react";
187
- import React7 from "react";
188
+ import { Planet } from "@phosphor-icons/react";
189
+ import React6 from "react";
188
190
  import { getSpace as getSpace2 } from "@dxos/client/echo";
189
191
  import { useClient as useClient2 } from "@dxos/react-client";
190
192
  import { DropdownMenu, toLocalizedString, useTranslation as useTranslation6 } from "@dxos/react-ui";
191
193
 
192
194
  // packages/plugins/plugin-space/src/util.tsx
193
- import { CardsThree, Database, PencilSimpleLine, Planet, Plus, Trash, Users, X, ClockCounterClockwise, LockSimpleOpen, LockSimple, Placeholder, Link } from "@phosphor-icons/react";
194
- import React6 from "react";
195
195
  import { NavigationAction as NavigationAction2 } from "@dxos/app-framework";
196
196
  import { create, isReactiveObject, getTypename, getSchema, getEchoObjectAnnotation, EXPANDO_TYPENAME } from "@dxos/echo-schema";
197
197
  import { invariant } from "@dxos/invariant";
@@ -284,8 +284,7 @@ var constructSpaceNode = ({ space, personal, namesCache, resolve }) => {
284
284
  namesCache
285
285
  }),
286
286
  description: space.state.get() === SpaceState.SPACE_READY && space.properties.description,
287
- icon: (props) => /* @__PURE__ */ React6.createElement(Planet, props),
288
- iconSymbol: "ph--planet--regular",
287
+ icon: "ph--planet--regular",
289
288
  disabled: space.state.get() !== SpaceState.SPACE_READY || hasPendingMigration,
290
289
  testId: "spacePlugin.space"
291
290
  }
@@ -311,8 +310,7 @@ var constructSpaceActionGroups = ({ space, dispatch }) => {
311
310
  ns: SPACE_PLUGIN
312
311
  }
313
312
  ],
314
- icon: (props) => /* @__PURE__ */ React6.createElement(Plus, props),
315
- iconSymbol: "ph--plus--regular",
313
+ icon: "ph--plus--regular",
316
314
  disposition: "toolbar",
317
315
  // TODO(wittjosiah): This is currently a navtree feature. Address this with cmd+k integration.
318
316
  // mainAreaDisposition: 'in-flow',
@@ -346,8 +344,7 @@ var constructSpaceActionGroups = ({ space, dispatch }) => {
346
344
  ns: SPACE_PLUGIN
347
345
  }
348
346
  ],
349
- icon: (props) => /* @__PURE__ */ React6.createElement(CardsThree, props),
350
- iconSymbol: "ph--cards-three--regular",
347
+ icon: "ph--cards-three--regular",
351
348
  testId: "spacePlugin.createCollection"
352
349
  }
353
350
  }
@@ -381,8 +378,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
381
378
  ns: SPACE_PLUGIN
382
379
  }
383
380
  ],
384
- icon: (props) => /* @__PURE__ */ React6.createElement(Database, props),
385
- iconSymbol: "ph--database--regular",
381
+ icon: "ph--database--regular",
386
382
  disposition: "toolbar",
387
383
  mainAreaDisposition: "in-flow",
388
384
  disabled: migrating || Migrations.running(space)
@@ -413,8 +409,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
413
409
  ns: SPACE_PLUGIN
414
410
  }
415
411
  ],
416
- icon: (props) => /* @__PURE__ */ React6.createElement(Users, props),
417
- iconSymbol: "ph--users--regular",
412
+ icon: "ph--users--regular",
418
413
  disabled: locked,
419
414
  keyBinding: {
420
415
  macos: "meta+.",
@@ -441,8 +436,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
441
436
  ns: SPACE_PLUGIN
442
437
  }
443
438
  ],
444
- icon: locked ? (props) => /* @__PURE__ */ React6.createElement(LockSimpleOpen, props) : (props) => /* @__PURE__ */ React6.createElement(LockSimple, props),
445
- iconSymbol: locked ? "ph--lock-simple-open--regular" : "ph--lock-simple--regular"
439
+ icon: locked ? "ph--lock-simple-open--regular" : "ph--lock-simple--regular"
446
440
  }
447
441
  }, {
448
442
  id: getId(SpaceAction.RENAME),
@@ -464,8 +458,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
464
458
  ns: SPACE_PLUGIN
465
459
  }
466
460
  ],
467
- icon: (props) => /* @__PURE__ */ React6.createElement(PencilSimpleLine, props),
468
- iconSymbol: "ph--pencil-simple-line--regular",
461
+ icon: "ph--pencil-simple-line--regular",
469
462
  keyBinding: {
470
463
  macos: "shift+F6",
471
464
  windows: "shift+F6"
@@ -494,8 +487,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
494
487
  ns: SPACE_PLUGIN
495
488
  }
496
489
  ],
497
- icon: (props) => /* @__PURE__ */ React6.createElement(X, props),
498
- iconSymbol: "ph--x--regular",
490
+ icon: "ph--x--regular",
499
491
  mainAreaDisposition: "menu",
500
492
  disabled: personal
501
493
  }
@@ -521,8 +513,7 @@ var constructSpaceActions = ({ space, dispatch, personal, migrating }) => {
521
513
  ns: SPACE_PLUGIN
522
514
  }
523
515
  ],
524
- icon: (props) => /* @__PURE__ */ React6.createElement(ClockCounterClockwise, props),
525
- iconSymbol: "ph--clock-counter-clockwise--regular",
516
+ icon: "ph--clock-counter-clockwise--regular",
526
517
  disposition: "toolbar",
527
518
  mainAreaDisposition: "in-flow"
528
519
  }
@@ -556,8 +547,7 @@ var createObjectNode = ({ object, space, resolve }) => {
556
547
  ns: SPACE_PLUGIN
557
548
  }
558
549
  ],
559
- icon: metadata.icon ?? (() => /* @__PURE__ */ React6.createElement(Placeholder, null)),
560
- iconSymbol: metadata.iconSymbol ?? "ph--placeholder--regular",
550
+ icon: metadata.icon ?? "ph--placeholder--regular",
561
551
  testId: "spacePlugin.object",
562
552
  persistenceClass: "echo",
563
553
  persistenceKey: space?.id
@@ -582,8 +572,7 @@ var constructObjectActionGroups = ({ object, dispatch }) => {
582
572
  ns: SPACE_PLUGIN
583
573
  }
584
574
  ],
585
- icon: (props) => /* @__PURE__ */ React6.createElement(Plus, props),
586
- iconSymbol: "ph--plus--regular",
575
+ icon: "ph--plus--regular",
587
576
  disposition: "toolbar",
588
577
  // TODO(wittjosiah): This is currently a navtree feature. Address this with cmd+k integration.
589
578
  // mainAreaDisposition: 'in-flow',
@@ -617,8 +606,7 @@ var constructObjectActionGroups = ({ object, dispatch }) => {
617
606
  ns: SPACE_PLUGIN
618
607
  }
619
608
  ],
620
- icon: (props) => /* @__PURE__ */ React6.createElement(CardsThree, props),
621
- iconSymbol: "ph--cards-three--regular",
609
+ icon: "ph--cards-three--regular",
622
610
  testId: "spacePlugin.createCollection"
623
611
  }
624
612
  }
@@ -650,8 +638,7 @@ var constructObjectActions = ({ node, dispatch }) => {
650
638
  ns: SPACE_PLUGIN
651
639
  }
652
640
  ],
653
- icon: (props) => /* @__PURE__ */ React6.createElement(PencilSimpleLine, props),
654
- iconSymbol: "ph--pencil-simple-line--regular",
641
+ icon: "ph--pencil-simple-line--regular",
655
642
  // TODO(wittjosiah): Doesn't work.
656
643
  // keyBinding: 'shift+F6',
657
644
  testId: "spacePlugin.renameObject"
@@ -682,8 +669,7 @@ var constructObjectActions = ({ node, dispatch }) => {
682
669
  ns: SPACE_PLUGIN
683
670
  }
684
671
  ],
685
- icon: (props) => /* @__PURE__ */ React6.createElement(Trash, props),
686
- iconSymbol: "ph--trash--regular",
672
+ icon: "ph--trash--regular",
687
673
  keyBinding: object instanceof CollectionType ? void 0 : "shift+meta+Backspace",
688
674
  testId: "spacePlugin.deleteObject"
689
675
  }
@@ -702,8 +688,7 @@ var constructObjectActions = ({ node, dispatch }) => {
702
688
  ns: SPACE_PLUGIN
703
689
  }
704
690
  ],
705
- icon: (props) => /* @__PURE__ */ React6.createElement(Link, props),
706
- iconSymbol: "ph--link--regular",
691
+ icon: "ph--link--regular",
707
692
  testId: "spacePlugin.copyLink"
708
693
  }
709
694
  }
@@ -744,7 +729,7 @@ var cloneObject = async (object, resolve) => {
744
729
  const serializer = metadata.serializer;
745
730
  invariant(serializer, `No serializer for type: ${typename}`, {
746
731
  F: __dxlog_file,
747
- L: 639,
732
+ L: 604,
748
733
  S: void 0,
749
734
  A: [
750
735
  "serializer",
@@ -768,19 +753,19 @@ var MenuFooter = ({ object }) => {
768
753
  const spaceName = space ? getSpaceDisplayName(space, {
769
754
  personal: client.spaces.default === space
770
755
  }) : "";
771
- return space ? /* @__PURE__ */ React7.createElement(React7.Fragment, null, /* @__PURE__ */ React7.createElement(DropdownMenu.Separator, null), /* @__PURE__ */ React7.createElement(DropdownMenu.GroupLabel, null, t("menu footer label")), /* @__PURE__ */ React7.createElement("dl", {
756
+ return space ? /* @__PURE__ */ React6.createElement(React6.Fragment, null, /* @__PURE__ */ React6.createElement(DropdownMenu.Separator, null), /* @__PURE__ */ React6.createElement(DropdownMenu.GroupLabel, null, t("menu footer label")), /* @__PURE__ */ React6.createElement("dl", {
772
757
  className: "pis-2 mbe-2 text-xs grid grid-cols-[max-content_1fr] gap-2"
773
- }, /* @__PURE__ */ React7.createElement("dt", {
758
+ }, /* @__PURE__ */ React6.createElement("dt", {
774
759
  className: "uppercase text-[.75em] tracking-wide font-medium mbs-px self-start"
775
- }, t("location label")), /* @__PURE__ */ React7.createElement("dd", {
760
+ }, t("location label")), /* @__PURE__ */ React6.createElement("dd", {
776
761
  className: "line-clamp-3"
777
- }, /* @__PURE__ */ React7.createElement(Planet2, {
762
+ }, /* @__PURE__ */ React6.createElement(Planet, {
778
763
  className: "inline-block mie-1"
779
764
  }), toLocalizedString(spaceName, t)))) : null;
780
765
  };
781
766
 
782
767
  // packages/plugins/plugin-space/src/components/MissingObject.tsx
783
- import React8, { useEffect as useEffect2, useState as useState2 } from "react";
768
+ import React7, { useEffect as useEffect2, useState as useState2 } from "react";
784
769
  import { parseIntentPlugin as parseIntentPlugin2, useResolvePlugin as useResolvePlugin2 } from "@dxos/app-framework";
785
770
  import { Status, useTranslation as useTranslation7 } from "@dxos/react-ui";
786
771
  import { baseSurface as baseSurface2, descriptionText as descriptionText4, mx as mx5 } from "@dxos/react-ui-theme";
@@ -808,13 +793,13 @@ var MissingObject = ({ id }) => {
808
793
  intentPlugin,
809
794
  id
810
795
  ]);
811
- return /* @__PURE__ */ React8.createElement("div", {
796
+ return /* @__PURE__ */ React7.createElement("div", {
812
797
  role: "none",
813
798
  className: mx5(baseSurface2, "min-bs-screen is-full flex items-center justify-center p-8")
814
- }, waiting ? /* @__PURE__ */ React8.createElement("p", {
799
+ }, waiting ? /* @__PURE__ */ React7.createElement("p", {
815
800
  role: "alert",
816
801
  className: mx5(descriptionText4, "border border-dashed border-neutral-400/50 rounded-lg flex items-center justify-center p-8 font-normal text-lg")
817
- }, t("missing object message")) : /* @__PURE__ */ React8.createElement(Status, {
802
+ }, t("missing object message")) : /* @__PURE__ */ React7.createElement(Status, {
818
803
  indeterminate: true,
819
804
  "aria-label": "Initializing"
820
805
  }));
@@ -822,7 +807,7 @@ var MissingObject = ({ id }) => {
822
807
 
823
808
  // packages/plugins/plugin-space/src/components/PersistenceStatus.tsx
824
809
  import { ArrowsCounterClockwise, CheckCircle as CheckCircle2, Warning } from "@phosphor-icons/react";
825
- import React9, { useEffect as useEffect3, useState as useState3 } from "react";
810
+ import React8, { useEffect as useEffect3, useState as useState3 } from "react";
826
811
  import { debounce } from "@dxos/async";
827
812
  import { Tooltip, useTranslation as useTranslation8 } from "@dxos/react-ui";
828
813
  import { getSize as getSize2, mx as mx6, staticPlaceholderText, warningText } from "@dxos/react-ui-theme";
@@ -850,40 +835,40 @@ var PersistenceStatus = ({ db }) => {
850
835
  ]);
851
836
  switch (status) {
852
837
  case 2:
853
- return /* @__PURE__ */ React9.createElement("div", {
838
+ return /* @__PURE__ */ React8.createElement("div", {
854
839
  className: "flex items-center"
855
- }, /* @__PURE__ */ React9.createElement(Warning, {
840
+ }, /* @__PURE__ */ React8.createElement(Warning, {
856
841
  className: mx6(getSize2(4), "me-1")
857
- }), /* @__PURE__ */ React9.createElement("span", {
842
+ }), /* @__PURE__ */ React8.createElement("span", {
858
843
  className: mx6("text-sm", warningText)
859
844
  }, t("persistence error label")));
860
845
  case 1:
861
- return /* @__PURE__ */ React9.createElement("div", {
846
+ return /* @__PURE__ */ React8.createElement("div", {
862
847
  className: "flex items-center"
863
- }, /* @__PURE__ */ React9.createElement(ArrowsCounterClockwise, {
848
+ }, /* @__PURE__ */ React8.createElement(ArrowsCounterClockwise, {
864
849
  className: mx6(getSize2(4), "me-1")
865
- }), /* @__PURE__ */ React9.createElement("span", {
850
+ }), /* @__PURE__ */ React8.createElement("span", {
866
851
  className: mx6("text-sm", staticPlaceholderText)
867
852
  }, t("persistence pending label")));
868
853
  case 0:
869
854
  default:
870
- return /* @__PURE__ */ React9.createElement(Tooltip.Root, {
855
+ return /* @__PURE__ */ React8.createElement(Tooltip.Root, {
871
856
  delayDuration: 400
872
- }, /* @__PURE__ */ React9.createElement(Tooltip.Trigger, {
857
+ }, /* @__PURE__ */ React8.createElement(Tooltip.Trigger, {
873
858
  role: "status",
874
859
  className: "flex items-center"
875
- }, /* @__PURE__ */ React9.createElement(CheckCircle2, {
860
+ }, /* @__PURE__ */ React8.createElement(CheckCircle2, {
876
861
  className: mx6(getSize2(4), "me-1")
877
- }), displayMessage && /* @__PURE__ */ React9.createElement("span", {
862
+ }), displayMessage && /* @__PURE__ */ React8.createElement("span", {
878
863
  className: mx6("text-sm", staticPlaceholderText)
879
- }, t("persisted locally label"))), /* @__PURE__ */ React9.createElement(Tooltip.Portal, null, /* @__PURE__ */ React9.createElement(Tooltip.Content, {
864
+ }, t("persisted locally label"))), /* @__PURE__ */ React8.createElement(Tooltip.Portal, null, /* @__PURE__ */ React8.createElement(Tooltip.Content, {
880
865
  classNames: "z-10"
881
- }, t("persisted locally message"), /* @__PURE__ */ React9.createElement(Tooltip.Arrow, null))));
866
+ }, t("persisted locally message"), /* @__PURE__ */ React8.createElement(Tooltip.Arrow, null))));
882
867
  }
883
868
  };
884
869
 
885
870
  // packages/plugins/plugin-space/src/components/PopoverRenameObject.tsx
886
- import React10, { useCallback, useRef, useState as useState4 } from "react";
871
+ import React9, { useCallback, useRef, useState as useState4 } from "react";
887
872
  import { log } from "@dxos/log";
888
873
  import { Button as Button2, Input, Popover, useTranslation as useTranslation9 } from "@dxos/react-ui";
889
874
  var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-space/src/components/PopoverRenameObject.tsx";
@@ -913,23 +898,23 @@ var PopoverRenameObject = ({ object: obj }) => {
913
898
  object,
914
899
  name
915
900
  ]);
916
- return /* @__PURE__ */ React10.createElement("div", {
901
+ return /* @__PURE__ */ React9.createElement("div", {
917
902
  role: "none",
918
903
  className: "p-1 flex gap-2"
919
- }, /* @__PURE__ */ React10.createElement("div", {
904
+ }, /* @__PURE__ */ React9.createElement("div", {
920
905
  role: "none",
921
906
  className: "flex-1"
922
- }, /* @__PURE__ */ React10.createElement(Input.Root, null, /* @__PURE__ */ React10.createElement(Input.Label, {
907
+ }, /* @__PURE__ */ React9.createElement(Input.Root, null, /* @__PURE__ */ React9.createElement(Input.Label, {
923
908
  srOnly: true
924
- }, t("object name label")), /* @__PURE__ */ React10.createElement(Input.TextInput, {
909
+ }, t("object name label")), /* @__PURE__ */ React9.createElement(Input.TextInput, {
925
910
  placeholder: t("object title placeholder"),
926
911
  value: name,
927
912
  "data-testid": "spacePlugin.renameObject.input",
928
913
  onChange: ({ target: { value } }) => setName(value),
929
914
  onKeyDown: ({ key }) => key === "Enter" && doneButton.current?.click()
930
- }))), /* @__PURE__ */ React10.createElement(Popover.Close, {
915
+ }))), /* @__PURE__ */ React9.createElement(Popover.Close, {
931
916
  asChild: true
932
- }, /* @__PURE__ */ React10.createElement(Button2, {
917
+ }, /* @__PURE__ */ React9.createElement(Button2, {
933
918
  ref: doneButton,
934
919
  classNames: "self-stretch",
935
920
  onClick: handleDone
@@ -939,7 +924,7 @@ var PopoverRenameObject = ({ object: obj }) => {
939
924
  };
940
925
 
941
926
  // packages/plugins/plugin-space/src/components/PopoverRenameSpace.tsx
942
- import React11, { useCallback as useCallback2, useRef as useRef2, useState as useState5 } from "react";
927
+ import React10, { useCallback as useCallback2, useRef as useRef2, useState as useState5 } from "react";
943
928
  import { Button as Button3, Input as Input2, Popover as Popover2, useTranslation as useTranslation10 } from "@dxos/react-ui";
944
929
  var PopoverRenameSpace = ({ space }) => {
945
930
  const { t } = useTranslation10(SPACE_PLUGIN);
@@ -951,24 +936,24 @@ var PopoverRenameSpace = ({ space }) => {
951
936
  space,
952
937
  name
953
938
  ]);
954
- return /* @__PURE__ */ React11.createElement("div", {
939
+ return /* @__PURE__ */ React10.createElement("div", {
955
940
  role: "none",
956
941
  className: "p-1 flex gap-2"
957
- }, /* @__PURE__ */ React11.createElement("div", {
942
+ }, /* @__PURE__ */ React10.createElement("div", {
958
943
  role: "none",
959
944
  className: "flex-1"
960
- }, /* @__PURE__ */ React11.createElement(Input2.Root, null, /* @__PURE__ */ React11.createElement(Input2.Label, {
945
+ }, /* @__PURE__ */ React10.createElement(Input2.Root, null, /* @__PURE__ */ React10.createElement(Input2.Label, {
961
946
  srOnly: true
962
- }, t("space name label")), /* @__PURE__ */ React11.createElement(Input2.TextInput, {
947
+ }, t("space name label")), /* @__PURE__ */ React10.createElement(Input2.TextInput, {
963
948
  defaultValue: space.properties.name ?? "",
964
949
  placeholder: t("unnamed space label"),
965
950
  onChange: ({ target: { value } }) => setName(value),
966
951
  // TODO(wittjosiah): Ideally this should access the popover context to close the popover.
967
952
  // Currently this is not possible because Radix does not expose the popover context.
968
953
  onKeyDown: ({ key }) => key === "Enter" && doneButton.current?.click()
969
- }))), /* @__PURE__ */ React11.createElement(Popover2.Close, {
954
+ }))), /* @__PURE__ */ React10.createElement(Popover2.Close, {
970
955
  asChild: true
971
- }, /* @__PURE__ */ React11.createElement(Button3, {
956
+ }, /* @__PURE__ */ React10.createElement(Button3, {
972
957
  ref: doneButton,
973
958
  classNames: "self-stretch",
974
959
  onClick: handleDone
@@ -978,12 +963,12 @@ var PopoverRenameSpace = ({ space }) => {
978
963
  };
979
964
 
980
965
  // packages/plugins/plugin-space/src/components/ShareSpaceButton.tsx
981
- import React12 from "react";
966
+ import React11 from "react";
982
967
  import { useIntentDispatcher } from "@dxos/app-framework";
983
968
  import { Button as Button4, useTranslation as useTranslation11 } from "@dxos/react-ui";
984
969
  var ShareSpaceButton = ({ spaceId }) => {
985
970
  const dispatch = useIntentDispatcher();
986
- return /* @__PURE__ */ React12.createElement(ShareSpaceButtonImpl, {
971
+ return /* @__PURE__ */ React11.createElement(ShareSpaceButtonImpl, {
987
972
  onClick: () => dispatch({
988
973
  action: SpaceAction.SHARE,
989
974
  data: {
@@ -994,7 +979,7 @@ var ShareSpaceButton = ({ spaceId }) => {
994
979
  };
995
980
  var ShareSpaceButtonImpl = ({ onClick }) => {
996
981
  const { t } = useTranslation11(SPACE_PLUGIN);
997
- return /* @__PURE__ */ React12.createElement(Button4, {
982
+ return /* @__PURE__ */ React11.createElement(Button4, {
998
983
  "data-testid": "spacePlugin.shareSpaceButton",
999
984
  onClick,
1000
985
  classNames: "mli-1"
@@ -1003,16 +988,16 @@ var ShareSpaceButtonImpl = ({ onClick }) => {
1003
988
 
1004
989
  // packages/plugins/plugin-space/src/components/SpaceMain/SpaceMain.tsx
1005
990
  import { Command } from "@phosphor-icons/react";
1006
- import React14 from "react";
991
+ import React13 from "react";
1007
992
  import { Surface } from "@dxos/app-framework";
1008
993
  import { SpaceState as SpaceState2 } from "@dxos/react-client/echo";
1009
- import { Button as Button6, Main, useTranslation as useTranslation13, toLocalizedString as toLocalizedString2 } from "@dxos/react-ui";
994
+ import { Main, useTranslation as useTranslation13 } from "@dxos/react-ui";
1010
995
  import { getSize as getSize4, mx as mx8, topbarBlockPaddingStart } from "@dxos/react-ui-theme";
1011
996
  import { ClipboardProvider } from "@dxos/shell/react";
1012
997
 
1013
998
  // packages/plugins/plugin-space/src/components/SpaceMain/SpaceMembersSection.tsx
1014
999
  import { CaretDown, Check, UserPlus, UsersThree } from "@phosphor-icons/react";
1015
- import React13, { useCallback as useCallback3, useState as useState6 } from "react";
1000
+ import React12, { useCallback as useCallback3, useState as useState6 } from "react";
1016
1001
  import { LayoutAction, useIntent } from "@dxos/app-framework";
1017
1002
  import { useMembers, SpaceMember, useSpaceInvitations } from "@dxos/react-client/echo";
1018
1003
  import { InvitationEncoder } from "@dxos/react-client/invitations";
@@ -1024,9 +1009,9 @@ var activeActionKeyStorageKey = "dxos:react-shell/space-manager/active-action";
1024
1009
  var Presence = SpaceMember.PresenceState;
1025
1010
  var handleCreateInvitationUrl = (invitationCode) => `${origin}?spaceInvitationCode=${invitationCode}`;
1026
1011
  var SpaceMemberList = ({ members }) => {
1027
- return members.length > 0 ? /* @__PURE__ */ React13.createElement(List, {
1012
+ return members.length > 0 ? /* @__PURE__ */ React12.createElement(List, {
1028
1013
  classNames: "col-start-2 col-end-5 gap-y-1 grid grid-cols-subgrid items-center"
1029
- }, members.map((member) => /* @__PURE__ */ React13.createElement(IdentityListItem, {
1014
+ }, members.map((member) => /* @__PURE__ */ React12.createElement(IdentityListItem, {
1030
1015
  classNames: "contents",
1031
1016
  key: member.identity.identityKey.toHex(),
1032
1017
  identity: member.identity,
@@ -1112,83 +1097,83 @@ var SpaceMembersSection = ({ space }) => {
1112
1097
  [Presence.ONLINE]: [],
1113
1098
  [Presence.OFFLINE]: []
1114
1099
  });
1115
- return /* @__PURE__ */ React13.createElement("section", {
1100
+ return /* @__PURE__ */ React12.createElement("section", {
1116
1101
  className: "mbe-4 col-span-3 grid gap-y-2 grid-cols-subgrid auto-rows-min"
1117
- }, /* @__PURE__ */ React13.createElement("h2", {
1102
+ }, /* @__PURE__ */ React12.createElement("h2", {
1118
1103
  className: "contents"
1119
- }, /* @__PURE__ */ React13.createElement(UsersThree, {
1104
+ }, /* @__PURE__ */ React12.createElement(UsersThree, {
1120
1105
  weight: "duotone",
1121
1106
  className: mx7(getSize3(5), "place-self-center")
1122
- }), /* @__PURE__ */ React13.createElement("span", {
1107
+ }), /* @__PURE__ */ React12.createElement("span", {
1123
1108
  className: "text-lg col-span-2"
1124
- }, t("space members label"))), /* @__PURE__ */ React13.createElement("h3", {
1109
+ }, t("space members label"))), /* @__PURE__ */ React12.createElement("h3", {
1125
1110
  className: "col-start-2 col-span-3 text-sm italic text-description"
1126
- }, t("invitations heading")), invitations.length > 0 && /* @__PURE__ */ React13.createElement(List, {
1111
+ }, t("invitations heading")), invitations.length > 0 && /* @__PURE__ */ React12.createElement(List, {
1127
1112
  classNames: "col-start-2 col-span-2 gap-y-2 grid grid-cols-[var(--rail-size)_1fr_var(--rail-action)_var(--rail-action)]"
1128
- }, invitations.map((invitation) => /* @__PURE__ */ React13.createElement(InvitationListItem, {
1113
+ }, invitations.map((invitation) => /* @__PURE__ */ React12.createElement(InvitationListItem, {
1129
1114
  reverseEffects: true,
1130
1115
  classNames: "pis-0 pie-0 gap-0 col-span-4 grid grid-cols-subgrid",
1131
1116
  key: invitation.get().invitationId,
1132
1117
  invitation,
1133
1118
  send: handleInvitationSelect,
1134
1119
  createInvitationUrl: handleCreateInvitationUrl
1135
- }))), /* @__PURE__ */ React13.createElement(ButtonGroup, {
1120
+ }))), /* @__PURE__ */ React12.createElement(ButtonGroup, {
1136
1121
  classNames: "col-start-2 col-end-4 grid grid-cols-[1fr_var(--rail-action)] place-self-grow gap-px"
1137
- }, /* @__PURE__ */ React13.createElement(Button5, {
1122
+ }, /* @__PURE__ */ React12.createElement(Button5, {
1138
1123
  classNames: "gap-2",
1139
1124
  onClick: activeAction.onClick
1140
- }, /* @__PURE__ */ React13.createElement(activeAction.icon, {
1125
+ }, /* @__PURE__ */ React12.createElement(activeAction.icon, {
1141
1126
  className: getSize3(5)
1142
- }), /* @__PURE__ */ React13.createElement("span", null, t(activeAction.label, {
1127
+ }), /* @__PURE__ */ React12.createElement("span", null, t(activeAction.label, {
1143
1128
  ns: "os"
1144
- }))), /* @__PURE__ */ React13.createElement(DropdownMenu2.Root, null, /* @__PURE__ */ React13.createElement(DropdownMenu2.Trigger, {
1129
+ }))), /* @__PURE__ */ React12.createElement(DropdownMenu2.Root, null, /* @__PURE__ */ React12.createElement(DropdownMenu2.Trigger, {
1145
1130
  asChild: true
1146
- }, /* @__PURE__ */ React13.createElement(Button5, {
1131
+ }, /* @__PURE__ */ React12.createElement(Button5, {
1147
1132
  classNames: "pli-0"
1148
- }, /* @__PURE__ */ React13.createElement(CaretDown, {
1133
+ }, /* @__PURE__ */ React12.createElement(CaretDown, {
1149
1134
  className: getSize3(4)
1150
- }))), /* @__PURE__ */ React13.createElement(DropdownMenu2.Content, null, /* @__PURE__ */ React13.createElement(DropdownMenu2.Viewport, null, Object.entries(inviteActions).map(([id, action]) => {
1151
- return /* @__PURE__ */ React13.createElement(DropdownMenu2.CheckboxItem, {
1135
+ }))), /* @__PURE__ */ React12.createElement(DropdownMenu2.Content, null, /* @__PURE__ */ React12.createElement(DropdownMenu2.Viewport, null, Object.entries(inviteActions).map(([id, action]) => {
1136
+ return /* @__PURE__ */ React12.createElement(DropdownMenu2.CheckboxItem, {
1152
1137
  key: id,
1153
1138
  "aria-labelledby": `${id}__label`,
1154
1139
  "aria-describedby": `${id}__description`,
1155
1140
  checked: activeActionKey === id,
1156
1141
  onCheckedChange: (checked) => checked && setActiveActionKey(id),
1157
1142
  classNames: "gap-2"
1158
- }, action.icon && /* @__PURE__ */ React13.createElement(action.icon, {
1143
+ }, action.icon && /* @__PURE__ */ React12.createElement(action.icon, {
1159
1144
  className: getSize3(5)
1160
- }), /* @__PURE__ */ React13.createElement("div", {
1145
+ }), /* @__PURE__ */ React12.createElement("div", {
1161
1146
  role: "none",
1162
1147
  className: "flex-1 min-is-0 space-b-1"
1163
- }, /* @__PURE__ */ React13.createElement("p", {
1148
+ }, /* @__PURE__ */ React12.createElement("p", {
1164
1149
  id: `${id}__label`
1165
1150
  }, t(action.label, {
1166
1151
  ns: "os"
1167
- })), action.description && /* @__PURE__ */ React13.createElement("p", {
1152
+ })), action.description && /* @__PURE__ */ React12.createElement("p", {
1168
1153
  id: `${id}__description`,
1169
1154
  className: descriptionText5
1170
1155
  }, t(action.description, {
1171
1156
  ns: "os"
1172
- }))), /* @__PURE__ */ React13.createElement(DropdownMenu2.ItemIndicator, {
1157
+ }))), /* @__PURE__ */ React12.createElement(DropdownMenu2.ItemIndicator, {
1173
1158
  asChild: true
1174
- }, /* @__PURE__ */ React13.createElement(Check, {
1159
+ }, /* @__PURE__ */ React12.createElement(Check, {
1175
1160
  className: getSize3(4)
1176
1161
  })));
1177
- })), /* @__PURE__ */ React13.createElement(DropdownMenu2.Arrow, null)))), members[Presence.ONLINE].length + members[Presence.OFFLINE].length < 1 ? /* @__PURE__ */ React13.createElement("p", {
1162
+ })), /* @__PURE__ */ React12.createElement(DropdownMenu2.Arrow, null)))), members[Presence.ONLINE].length + members[Presence.OFFLINE].length < 1 ? /* @__PURE__ */ React12.createElement("p", {
1178
1163
  className: mx7(descriptionText5, "text-center is-full mlb-2")
1179
1164
  }, t("empty space members message", {
1180
1165
  ns: "os"
1181
- })) : /* @__PURE__ */ React13.createElement(React13.Fragment, null, /* @__PURE__ */ React13.createElement("h3", {
1166
+ })) : /* @__PURE__ */ React12.createElement(React12.Fragment, null, /* @__PURE__ */ React12.createElement("h3", {
1182
1167
  className: "col-start-2 col-end-5 text-sm italic text-description"
1183
1168
  }, t("active space members heading", {
1184
1169
  count: members[Presence.ONLINE].length
1185
- })), /* @__PURE__ */ React13.createElement(SpaceMemberList, {
1170
+ })), /* @__PURE__ */ React12.createElement(SpaceMemberList, {
1186
1171
  members: members[Presence.ONLINE]
1187
- }), /* @__PURE__ */ React13.createElement("h3", {
1172
+ }), /* @__PURE__ */ React12.createElement("h3", {
1188
1173
  className: "col-start-2 col-end-5 text-sm italic text-description"
1189
1174
  }, t("inactive space members heading", {
1190
1175
  count: members[Presence.OFFLINE].length
1191
- })), /* @__PURE__ */ React13.createElement(SpaceMemberList, {
1176
+ })), /* @__PURE__ */ React12.createElement(SpaceMemberList, {
1192
1177
  members: members[Presence.OFFLINE]
1193
1178
  })));
1194
1179
  };
@@ -1196,19 +1181,19 @@ var SpaceMembersSection = ({ space }) => {
1196
1181
  // packages/plugins/plugin-space/src/components/SpaceMain/SpaceMain.tsx
1197
1182
  var KeyShortcuts = () => {
1198
1183
  const { t } = useTranslation13(SPACE_PLUGIN);
1199
- return /* @__PURE__ */ React14.createElement("section", {
1184
+ return /* @__PURE__ */ React13.createElement("section", {
1200
1185
  className: "mbe-4 col-span-4 md:col-start-5 md:col-end-7 grid grid-cols-subgrid gap-y-2 auto-rows-min"
1201
- }, /* @__PURE__ */ React14.createElement("h2", {
1186
+ }, /* @__PURE__ */ React13.createElement("h2", {
1202
1187
  className: "contents"
1203
- }, /* @__PURE__ */ React14.createElement(Command, {
1188
+ }, /* @__PURE__ */ React13.createElement(Command, {
1204
1189
  weight: "duotone",
1205
1190
  className: mx8(getSize4(5), "place-self-center")
1206
- }), /* @__PURE__ */ React14.createElement("span", {
1191
+ }), /* @__PURE__ */ React13.createElement("span", {
1207
1192
  className: "text-lg col-span-2 md:col-span-1"
1208
- }, t("keyshortcuts label"))), /* @__PURE__ */ React14.createElement("div", {
1193
+ }, t("keyshortcuts label"))), /* @__PURE__ */ React13.createElement("div", {
1209
1194
  role: "none",
1210
1195
  className: "col-start-2 col-end-4 md:col-end-5 pie-2"
1211
- }, /* @__PURE__ */ React14.createElement(Surface, {
1196
+ }, /* @__PURE__ */ React13.createElement(Surface, {
1212
1197
  role: "keyshortcuts"
1213
1198
  })));
1214
1199
  };
@@ -1217,7 +1202,7 @@ var SpaceMain = ({ space, role }) => {
1217
1202
  const state = space.state.get();
1218
1203
  const ready = state === SpaceState2.SPACE_READY;
1219
1204
  const Root = role === "main" ? Main.Content : "div";
1220
- return /* @__PURE__ */ React14.createElement(ClipboardProvider, null, /* @__PURE__ */ React14.createElement(Root, {
1205
+ return /* @__PURE__ */ React13.createElement(ClipboardProvider, null, /* @__PURE__ */ React13.createElement(Root, {
1221
1206
  ...role === "main" ? {
1222
1207
  classNames: [
1223
1208
  topbarBlockPaddingStart,
@@ -1230,13 +1215,13 @@ var SpaceMain = ({ space, role }) => {
1230
1215
  },
1231
1216
  "data-testid": `spacePlugin.${role}`,
1232
1217
  "data-isready": ready ? "true" : "false"
1233
- }, ready && /* @__PURE__ */ React14.createElement(SpaceMembersSection, {
1218
+ }, ready && /* @__PURE__ */ React13.createElement(SpaceMembersSection, {
1234
1219
  space
1235
- }), /* @__PURE__ */ React14.createElement(KeyShortcuts, null)));
1220
+ }), /* @__PURE__ */ React13.createElement(KeyShortcuts, null)));
1236
1221
  };
1237
1222
 
1238
1223
  // packages/plugins/plugin-space/src/components/SpacePresence.tsx
1239
- import React15, { useCallback as useCallback4, useEffect as useEffect4, useState as useState7 } from "react";
1224
+ import React14, { useCallback as useCallback4, useEffect as useEffect4, useState as useState7 } from "react";
1240
1225
  import { usePlugin } from "@dxos/app-framework";
1241
1226
  import { generateName } from "@dxos/display-name";
1242
1227
  import { PublicKey, useClient as useClient3 } from "@dxos/react-client";
@@ -1280,9 +1265,9 @@ var SpacePresence = ({ object, spaceKey }) => {
1280
1265
  lastSeen
1281
1266
  };
1282
1267
  }).toSorted((a, b) => a.lastSeen - b.lastSeen);
1283
- return density === "fine" ? /* @__PURE__ */ React15.createElement(SmallPresence, {
1268
+ return density === "fine" ? /* @__PURE__ */ React14.createElement(SmallPresence, {
1284
1269
  count: membersForObject.length
1285
- }) : /* @__PURE__ */ React15.createElement(FullPresence, {
1270
+ }) : /* @__PURE__ */ React14.createElement(FullPresence, {
1286
1271
  members: membersForObject
1287
1272
  });
1288
1273
  };
@@ -1292,38 +1277,38 @@ var FullPresence = (props) => {
1292
1277
  if (members.length === 0) {
1293
1278
  return null;
1294
1279
  }
1295
- return /* @__PURE__ */ React15.createElement(AvatarGroup.Root, {
1280
+ return /* @__PURE__ */ React14.createElement(AvatarGroup.Root, {
1296
1281
  size,
1297
1282
  classNames: "mbs-2 mie-4",
1298
1283
  "data-testid": "spacePlugin.presence"
1299
- }, members.slice(0, 3).map((member, i) => /* @__PURE__ */ React15.createElement(Tooltip2.Root, {
1284
+ }, members.slice(0, 3).map((member, i) => /* @__PURE__ */ React14.createElement(Tooltip2.Root, {
1300
1285
  key: member.identity.identityKey.toHex()
1301
- }, /* @__PURE__ */ React15.createElement(Tooltip2.Trigger, null, /* @__PURE__ */ React15.createElement(PrensenceAvatar, {
1286
+ }, /* @__PURE__ */ React14.createElement(Tooltip2.Trigger, null, /* @__PURE__ */ React14.createElement(PrensenceAvatar, {
1302
1287
  identity: member.identity,
1303
1288
  group: true,
1304
1289
  match: member.currentlyAttended,
1305
1290
  index: members.length - i,
1306
1291
  onClick: () => onMemberClick?.(member)
1307
- })), /* @__PURE__ */ React15.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React15.createElement(Tooltip2.Content, {
1292
+ })), /* @__PURE__ */ React14.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React14.createElement(Tooltip2.Content, {
1308
1293
  side: "bottom"
1309
- }, /* @__PURE__ */ React15.createElement("span", null, getName(member.identity)), /* @__PURE__ */ React15.createElement(Tooltip2.Arrow, null))))), members.length > 3 && /* @__PURE__ */ React15.createElement(Tooltip2.Root, null, /* @__PURE__ */ React15.createElement(Tooltip2.Trigger, null, /* @__PURE__ */ React15.createElement(AvatarGroupItem.Root, {
1294
+ }, /* @__PURE__ */ React14.createElement("span", null, getName(member.identity)), /* @__PURE__ */ React14.createElement(Tooltip2.Arrow, null))))), members.length > 3 && /* @__PURE__ */ React14.createElement(Tooltip2.Root, null, /* @__PURE__ */ React14.createElement(Tooltip2.Trigger, null, /* @__PURE__ */ React14.createElement(AvatarGroupItem.Root, {
1310
1295
  status: "inactive"
1311
- }, /* @__PURE__ */ React15.createElement(Avatar.Frame, {
1296
+ }, /* @__PURE__ */ React14.createElement(Avatar.Frame, {
1312
1297
  style: {
1313
1298
  zIndex: members.length - 4
1314
1299
  }
1315
- }, /* @__PURE__ */ React15.createElement(Avatar.Fallback, {
1300
+ }, /* @__PURE__ */ React14.createElement(Avatar.Fallback, {
1316
1301
  text: `+${members.length - 3}`
1317
- })))), /* @__PURE__ */ React15.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React15.createElement(Tooltip2.Content, {
1302
+ })))), /* @__PURE__ */ React14.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React14.createElement(Tooltip2.Content, {
1318
1303
  side: "bottom"
1319
- }, /* @__PURE__ */ React15.createElement(Tooltip2.Arrow, null), /* @__PURE__ */ React15.createElement(List2, {
1304
+ }, /* @__PURE__ */ React14.createElement(Tooltip2.Arrow, null), /* @__PURE__ */ React14.createElement(List2, {
1320
1305
  classNames: "max-h-56 overflow-y-auto"
1321
- }, members.map((member) => /* @__PURE__ */ React15.createElement(ListItem.Root, {
1306
+ }, members.map((member) => /* @__PURE__ */ React14.createElement(ListItem.Root, {
1322
1307
  key: member.identity.identityKey.toHex(),
1323
1308
  classNames: "flex gap-2 items-center cursor-pointer mbe-2",
1324
1309
  onClick: () => onMemberClick?.(member),
1325
1310
  "data-testid": "identity-list-item"
1326
- }, /* @__PURE__ */ React15.createElement(PrensenceAvatar, {
1311
+ }, /* @__PURE__ */ React14.createElement(PrensenceAvatar, {
1327
1312
  identity: member.identity,
1328
1313
  showName: true,
1329
1314
  match: member.currentlyAttended
@@ -1333,10 +1318,10 @@ var PrensenceAvatar = ({ identity, showName, match, group, index, onClick }) =>
1333
1318
  const Root = group ? AvatarGroupItem.Root : Avatar.Root;
1334
1319
  const status = match ? "current" : "active";
1335
1320
  const fallbackValue = keyToFallback(identity.identityKey);
1336
- return /* @__PURE__ */ React15.createElement(Root, {
1321
+ return /* @__PURE__ */ React14.createElement(Root, {
1337
1322
  status,
1338
1323
  hue: identity.profile?.data?.hue || fallbackValue.hue
1339
- }, /* @__PURE__ */ React15.createElement(Avatar.Frame, {
1324
+ }, /* @__PURE__ */ React14.createElement(Avatar.Frame, {
1340
1325
  "data-testid": "spacePlugin.presence.member",
1341
1326
  "data-status": status,
1342
1327
  ...index ? {
@@ -1345,9 +1330,9 @@ var PrensenceAvatar = ({ identity, showName, match, group, index, onClick }) =>
1345
1330
  }
1346
1331
  } : {},
1347
1332
  onClick: () => onClick?.()
1348
- }, /* @__PURE__ */ React15.createElement(Avatar.Fallback, {
1333
+ }, /* @__PURE__ */ React14.createElement(Avatar.Fallback, {
1349
1334
  text: identity.profile?.data?.emoji || fallbackValue.emoji
1350
- })), showName && /* @__PURE__ */ React15.createElement(Avatar.Label, {
1335
+ })), showName && /* @__PURE__ */ React14.createElement(Avatar.Label, {
1351
1336
  classNames: "text-sm truncate pli-2"
1352
1337
  }, getName(identity)));
1353
1338
  };
@@ -1358,36 +1343,37 @@ var SmallPresenceLive = ({ viewers }) => {
1358
1343
  return () => clearInterval(interval);
1359
1344
  }, []);
1360
1345
  const activeViewers = viewers ? Array.from(viewers.values()).filter(({ lastSeen }) => moment - lastSeen < ACTIVITY_DURATION) : [];
1361
- return /* @__PURE__ */ React15.createElement(SmallPresence, {
1346
+ return /* @__PURE__ */ React14.createElement(SmallPresence, {
1362
1347
  count: activeViewers.length
1363
1348
  });
1364
1349
  };
1365
1350
  var SmallPresence = ({ count }) => {
1366
1351
  const { t } = useTranslation14(SPACE_PLUGIN);
1367
- return /* @__PURE__ */ React15.createElement(Tooltip2.Root, null, /* @__PURE__ */ React15.createElement(Tooltip2.Trigger, {
1352
+ return /* @__PURE__ */ React14.createElement(Tooltip2.Root, null, /* @__PURE__ */ React14.createElement(Tooltip2.Trigger, {
1368
1353
  asChild: true
1369
- }, /* @__PURE__ */ React15.createElement(AttentionGlyph, {
1354
+ }, /* @__PURE__ */ React14.createElement(AttentionGlyph, {
1370
1355
  presence: count > 1 ? "many" : count === 1 ? "one" : "none",
1371
1356
  classNames: "self-center mie-1"
1372
- })), /* @__PURE__ */ React15.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React15.createElement(Tooltip2.Content, {
1357
+ })), /* @__PURE__ */ React14.createElement(Tooltip2.Portal, null, /* @__PURE__ */ React14.createElement(Tooltip2.Content, {
1373
1358
  side: "bottom",
1374
1359
  classNames: "z-[70]"
1375
- }, /* @__PURE__ */ React15.createElement("span", null, t("presence label", {
1360
+ }, /* @__PURE__ */ React14.createElement("span", null, t("presence label", {
1376
1361
  count
1377
- })), /* @__PURE__ */ React15.createElement(Tooltip2.Arrow, null))));
1362
+ })), /* @__PURE__ */ React14.createElement(Tooltip2.Arrow, null))));
1378
1363
  };
1379
1364
 
1380
1365
  // packages/plugins/plugin-space/src/components/SpaceSettings.tsx
1381
- import React16 from "react";
1382
- import { useIntentDispatcher as useIntentDispatcher2 } from "@dxos/app-framework";
1366
+ import React15 from "react";
1367
+ import { useIntentDispatcher as useIntentDispatcher2, useResolvePlugins } from "@dxos/app-framework";
1383
1368
  import { SettingsValue } from "@dxos/plugin-settings";
1384
- import { Input as Input3, useTranslation as useTranslation15 } from "@dxos/react-ui";
1369
+ import { Input as Input3, Select, toLocalizedString as toLocalizedString2, useTranslation as useTranslation15 } from "@dxos/react-ui";
1385
1370
  var SpaceSettings = ({ settings }) => {
1386
1371
  const { t } = useTranslation15(SPACE_PLUGIN);
1387
1372
  const dispatch = useIntentDispatcher2();
1388
- return /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(SettingsValue, {
1373
+ const plugins = useResolvePlugins(parseSpaceInitPlugin);
1374
+ return /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(SettingsValue, {
1389
1375
  label: t("show hidden spaces label")
1390
- }, /* @__PURE__ */ React16.createElement(Input3.Switch, {
1376
+ }, /* @__PURE__ */ React15.createElement(Input3.Switch, {
1391
1377
  checked: settings.showHidden,
1392
1378
  onCheckedChange: (checked) => dispatch({
1393
1379
  plugin: SPACE_PLUGIN,
@@ -1396,33 +1382,40 @@ var SpaceSettings = ({ settings }) => {
1396
1382
  state: !!checked
1397
1383
  }
1398
1384
  })
1399
- })));
1385
+ })), /* @__PURE__ */ React15.createElement(SettingsValue, {
1386
+ label: t("default on space create label")
1387
+ }, /* @__PURE__ */ React15.createElement(Select.Root, {
1388
+ value: settings.onSpaceCreate,
1389
+ onValueChange: (value) => {
1390
+ settings.onSpaceCreate = value;
1391
+ }
1392
+ }, /* @__PURE__ */ React15.createElement(Select.TriggerButton, null), /* @__PURE__ */ React15.createElement(Select.Portal, null, /* @__PURE__ */ React15.createElement(Select.Content, null, /* @__PURE__ */ React15.createElement(Select.Viewport, null, plugins.map(({ provides: { space: { onSpaceCreate } } }) => /* @__PURE__ */ React15.createElement(Select.Option, {
1393
+ key: onSpaceCreate.action,
1394
+ value: onSpaceCreate.action
1395
+ }, toLocalizedString2(onSpaceCreate.label, t)))))))));
1400
1396
  };
1401
1397
 
1402
1398
  // packages/plugins/plugin-space/src/components/SaveStatus.tsx
1403
- import { ArrowsClockwise, CheckCircle as CheckCircle3 } from "@phosphor-icons/react";
1404
- import React17, { useEffect as useEffect5 } from "react";
1399
+ import React16, { useEffect as useEffect5, useState as useState8 } from "react";
1405
1400
  import { Context } from "@dxos/context";
1406
1401
  import { StatusBar } from "@dxos/plugin-status-bar";
1407
1402
  import { useClient as useClient4 } from "@dxos/react-client";
1408
- import { useTranslation as useTranslation16 } from "@dxos/react-ui";
1409
- import { getSize as getSize5 } from "@dxos/react-ui-theme";
1403
+ import { Icon, useTranslation as useTranslation16 } from "@dxos/react-ui";
1410
1404
  var __dxlog_file3 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-space/src/components/SaveStatus.tsx";
1411
1405
  var SaveStatus = () => {
1412
1406
  const { t } = useTranslation16(SPACE_PLUGIN);
1413
1407
  const client = useClient4();
1414
- const [state, setState] = React17.useState("saved");
1408
+ const [state, setState] = useState8("saved");
1415
1409
  useEffect5(() => {
1416
1410
  return createClientSaveTracker(client, (state2) => {
1417
1411
  setState(state2);
1418
1412
  });
1419
1413
  }, []);
1420
- return /* @__PURE__ */ React17.createElement(StatusBar.Item, {
1414
+ return /* @__PURE__ */ React16.createElement(StatusBar.Item, {
1421
1415
  title: state === "saving" ? t("saving label") : t("saved label")
1422
- }, state === "saving" ? /* @__PURE__ */ React17.createElement(ArrowsClockwise, {
1423
- className: getSize5(3)
1424
- }) : /* @__PURE__ */ React17.createElement(CheckCircle3, {
1425
- className: getSize5(3)
1416
+ }, /* @__PURE__ */ React16.createElement(Icon, {
1417
+ icon: state === "saving" ? "ph--arrows-clockwise--regular" : "ph--check-circle--regular",
1418
+ size: 4
1426
1419
  }));
1427
1420
  };
1428
1421
  var createClientSaveTracker = (client, cb) => {
@@ -1453,7 +1446,7 @@ var createClientSaveTracker = (client, cb) => {
1453
1446
  var createSpaceSaveTracker = (space, cb) => {
1454
1447
  const ctx = new Context(void 0, {
1455
1448
  F: __dxlog_file3,
1456
- L: 67
1449
+ L: 64
1457
1450
  });
1458
1451
  void space.waitUntilReady().then(() => {
1459
1452
  if (ctx.disposed) {
@@ -1484,6 +1477,214 @@ var createSpaceSaveTracker = (space, cb) => {
1484
1477
  };
1485
1478
  };
1486
1479
 
1480
+ // packages/plugins/plugin-space/src/components/SyncStatus/SyncStatus.tsx
1481
+ import React17, { useEffect as useEffect7, useState as useState10 } from "react";
1482
+ import { StatusBar as StatusBar2 } from "@dxos/plugin-status-bar";
1483
+ import { Icon as Icon2, Popover as Popover3, useTranslation as useTranslation17 } from "@dxos/react-ui";
1484
+ import { SyntaxHighlighter } from "@dxos/react-ui-syntax-highlighter";
1485
+ import { mx as mx9 } from "@dxos/react-ui-theme";
1486
+
1487
+ // packages/plugins/plugin-space/src/components/SyncStatus/types.ts
1488
+ import { useEffect as useEffect6, useState as useState9 } from "react";
1489
+ import { Context as Context2 } from "@dxos/context";
1490
+ import { EdgeService } from "@dxos/protocols";
1491
+ import { useClient as useClient5 } from "@dxos/react-client";
1492
+ var __dxlog_file4 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-space/src/components/SyncStatus/types.ts";
1493
+ var createEmptyEdgeSyncState = () => ({
1494
+ missingOnLocal: 0,
1495
+ missingOnRemote: 0,
1496
+ localDocumentCount: 0,
1497
+ remoteDocumentCount: 0,
1498
+ differentDocuments: 0
1499
+ });
1500
+ var getSyncSummary = (syncMap) => {
1501
+ return Object.entries(syncMap).reduce((summary, [_spaceId, peerState]) => {
1502
+ summary.missingOnLocal += peerState.missingOnLocal;
1503
+ summary.missingOnRemote += peerState.missingOnRemote;
1504
+ summary.localDocumentCount += peerState.localDocumentCount;
1505
+ summary.remoteDocumentCount += peerState.remoteDocumentCount;
1506
+ summary.differentDocuments += peerState.differentDocuments;
1507
+ return summary;
1508
+ }, createEmptyEdgeSyncState());
1509
+ };
1510
+ var isEdgePeerId = (peerId, spaceId) => peerId.startsWith(`${EdgeService.AUTOMERGE_REPLICATOR}:${spaceId}`);
1511
+ var useSyncState = () => {
1512
+ const client = useClient5();
1513
+ const [spaceState, setSpaceState] = useState9({});
1514
+ useEffect6(() => {
1515
+ const ctx = new Context2(void 0, {
1516
+ F: __dxlog_file4,
1517
+ L: 48
1518
+ });
1519
+ const createSubscriptions = (spaces) => {
1520
+ for (const space of spaces) {
1521
+ if (spaceState[space.id]) {
1522
+ continue;
1523
+ }
1524
+ ctx.onDispose(space.crud.subscribeToSyncState(ctx, ({ peers = [] }) => {
1525
+ const syncState = peers.find((state) => isEdgePeerId(state.peerId, space.id));
1526
+ if (syncState) {
1527
+ setSpaceState((spaceState2) => ({
1528
+ ...spaceState2,
1529
+ [space.id]: syncState
1530
+ }));
1531
+ }
1532
+ }));
1533
+ }
1534
+ };
1535
+ createSubscriptions(client.spaces.get());
1536
+ client.spaces.subscribe((spaces) => {
1537
+ createSubscriptions(spaces);
1538
+ });
1539
+ return () => {
1540
+ void ctx.dispose();
1541
+ };
1542
+ }, [
1543
+ client
1544
+ ]);
1545
+ return spaceState;
1546
+ };
1547
+
1548
+ // packages/plugins/plugin-space/src/components/SyncStatus/SyncStatus.tsx
1549
+ var SYNC_STALLED_TIMEOUT = 5e3;
1550
+ var styles = {
1551
+ barBg: "bg-neutral-50 dark:bg-green-900 text-black",
1552
+ barFg: "bg-neutral-100 bg-green-500",
1553
+ barHover: "dark:hover:bg-green-500"
1554
+ };
1555
+ var SyncStatus = () => {
1556
+ const state = useSyncState();
1557
+ return /* @__PURE__ */ React17.createElement(SyncStatusIndicator, {
1558
+ state
1559
+ });
1560
+ };
1561
+ var SyncStatusIndicator = ({ state }) => {
1562
+ const summary = getSyncSummary(state);
1563
+ const offline = false;
1564
+ const needsToUpload = summary.differentDocuments > 0 || summary.missingOnRemote > 0;
1565
+ const needsToDownload = summary.differentDocuments > 0 || summary.missingOnLocal > 0;
1566
+ const [classNames, setClassNames] = useState10();
1567
+ useEffect7(() => {
1568
+ setClassNames(void 0);
1569
+ if (!needsToUpload && !needsToDownload) {
1570
+ return;
1571
+ }
1572
+ const t = setTimeout(() => {
1573
+ setClassNames("text-orange-500");
1574
+ }, SYNC_STALLED_TIMEOUT);
1575
+ return () => clearTimeout(t);
1576
+ }, [
1577
+ needsToUpload,
1578
+ needsToDownload
1579
+ ]);
1580
+ return /* @__PURE__ */ React17.createElement(StatusBar2.Item, null, /* @__PURE__ */ React17.createElement(Popover3.Root, null, /* @__PURE__ */ React17.createElement(Popover3.Trigger, null, /* @__PURE__ */ React17.createElement(Icon2, {
1581
+ icon: offline ? "ph--cloud-x--regular" : needsToUpload ? "ph--cloud-arrow-up--regular" : needsToDownload ? "ph--cloud-arrow-down--regular" : "ph--cloud-check--regular",
1582
+ size: 4,
1583
+ classNames
1584
+ })), /* @__PURE__ */ React17.createElement(Popover3.Content, null, /* @__PURE__ */ React17.createElement(SyncStatusDetail, {
1585
+ state,
1586
+ summary,
1587
+ debug: false
1588
+ }))));
1589
+ };
1590
+ var SyncStatusDetail = ({ classNames, state, summary, debug }) => {
1591
+ const { t } = useTranslation17(SPACE_PLUGIN);
1592
+ const entries = Object.entries(state).sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0);
1593
+ return /* @__PURE__ */ React17.createElement("div", {
1594
+ className: mx9("flex flex-col text-xs min-w-[16rem]", classNames)
1595
+ }, /* @__PURE__ */ React17.createElement("h1", {
1596
+ className: "p-2"
1597
+ }, t("sync status title")), /* @__PURE__ */ React17.createElement("div", {
1598
+ className: "flex flex-col gap-[2px] my-[2px]"
1599
+ }, entries.map(([spaceId, state2]) => /* @__PURE__ */ React17.createElement(SpaceRow, {
1600
+ key: spaceId,
1601
+ spaceId,
1602
+ state: state2
1603
+ }))), debug && /* @__PURE__ */ React17.createElement(SyntaxHighlighter, {
1604
+ language: "json"
1605
+ }, JSON.stringify(summary, null, 2)));
1606
+ };
1607
+ var useActive = (count) => {
1608
+ const [current, setCurrent] = useState10(count);
1609
+ const [active, setActive] = useState10(false);
1610
+ useEffect7(() => {
1611
+ let t;
1612
+ if (count !== current) {
1613
+ setActive(true);
1614
+ setCurrent(count);
1615
+ t && clearTimeout(t);
1616
+ t = setTimeout(() => {
1617
+ setActive(false);
1618
+ }, SYNC_STALLED_TIMEOUT);
1619
+ }
1620
+ return () => {
1621
+ setActive(false);
1622
+ clearTimeout(t);
1623
+ };
1624
+ }, [
1625
+ count,
1626
+ current
1627
+ ]);
1628
+ return active;
1629
+ };
1630
+ var SpaceRow = ({ spaceId, state: { localDocumentCount, remoteDocumentCount, missingOnLocal, missingOnRemote } }) => {
1631
+ const downActive = useActive(localDocumentCount);
1632
+ const upActive = useActive(remoteDocumentCount);
1633
+ return /* @__PURE__ */ React17.createElement("div", {
1634
+ className: mx9("flex items-center mx-[2px] gap-[2px] cursor-pointer", styles.barHover),
1635
+ title: spaceId,
1636
+ onClick: () => {
1637
+ void navigator.clipboard.writeText(spaceId);
1638
+ }
1639
+ }, /* @__PURE__ */ React17.createElement(Icon2, {
1640
+ icon: "ph--arrow-fat-line-left--regular",
1641
+ size: 3,
1642
+ classNames: mx9(downActive && "animate-[pulse_1s_infinite]")
1643
+ }), /* @__PURE__ */ React17.createElement(Candle, {
1644
+ up: {
1645
+ count: remoteDocumentCount,
1646
+ total: remoteDocumentCount + missingOnRemote
1647
+ },
1648
+ down: {
1649
+ count: localDocumentCount,
1650
+ total: localDocumentCount + missingOnLocal
1651
+ },
1652
+ title: spaceId
1653
+ }), /* @__PURE__ */ React17.createElement(Icon2, {
1654
+ icon: "ph--arrow-fat-line-right--regular",
1655
+ size: 3,
1656
+ classNames: mx9(upActive && "animate-[pulse_1s_step-start_infinite]")
1657
+ }));
1658
+ };
1659
+ var Candle = ({ classNames, up, down }) => {
1660
+ return /* @__PURE__ */ React17.createElement("div", {
1661
+ className: mx9("grid grid-cols-[1fr_2rem_1fr] w-full h-3", classNames)
1662
+ }, /* @__PURE__ */ React17.createElement(Bar, {
1663
+ classNames: "justify-end",
1664
+ ...up
1665
+ }), /* @__PURE__ */ React17.createElement("div", {
1666
+ className: "relative"
1667
+ }, /* @__PURE__ */ React17.createElement("div", {
1668
+ className: mx9("absolute inset-0 flex items-center justify-center text-xs", styles.barBg)
1669
+ }, up.total)), /* @__PURE__ */ React17.createElement(Bar, down));
1670
+ };
1671
+ var Bar = ({ classNames, count, total }) => {
1672
+ let p = count / total * 100;
1673
+ if (count < total) {
1674
+ p = Math.min(p, 95);
1675
+ }
1676
+ return /* @__PURE__ */ React17.createElement("div", {
1677
+ className: mx9("relative flex w-full", styles.barBg, classNames)
1678
+ }, /* @__PURE__ */ React17.createElement("div", {
1679
+ className: mx9("shrink-0", styles.barFg),
1680
+ style: {
1681
+ width: `${p}%`
1682
+ }
1683
+ }), count !== total && /* @__PURE__ */ React17.createElement("div", {
1684
+ className: "absolute top-0 bottom-0 flex items-center mx-0.5 text-black text-xs"
1685
+ }, count));
1686
+ };
1687
+
1487
1688
  // packages/plugins/plugin-space/src/translations.ts
1488
1689
  var translations_default = [
1489
1690
  {
@@ -1563,21 +1764,25 @@ var translations_default = [
1563
1764
  "space limit close label": "Close",
1564
1765
  "remove deleted objects label": "Cleanup",
1565
1766
  "remove deleted objects alt": "Permanently remove deleted objects to free up space.",
1566
- "copy link label": "Copy link"
1767
+ "copy link label": "Copy link",
1768
+ "default on space create label": "On space create",
1769
+ "sync status title": "Sync status"
1567
1770
  }
1568
1771
  }
1569
1772
  }
1570
1773
  ];
1571
1774
 
1572
1775
  // packages/plugins/plugin-space/src/SpacePlugin.tsx
1573
- var __dxlog_file4 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-space/src/SpacePlugin.tsx";
1776
+ var __dxlog_file5 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-space/src/SpacePlugin.tsx";
1574
1777
  var ACTIVE_NODE_BROADCAST_INTERVAL = 3e4;
1575
1778
  var OBJECT_ID_LENGTH = 60;
1576
1779
  var SPACE_MAX_OBJECTS = 500;
1577
1780
  var DIRECTORY_TYPE = "text/directory";
1578
1781
  var parseSpacePlugin = (plugin) => Array.isArray(plugin?.provides.space?.enabled) ? plugin : void 0;
1579
1782
  var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1580
- const settings = new LocalStorageStore(SPACE_PLUGIN);
1783
+ const settings = new LocalStorageStore(SPACE_PLUGIN, {
1784
+ onSpaceCreate: "dxos.org/plugin/markdown/action/create"
1785
+ });
1581
1786
  const state = new LocalStorageStore(SPACE_PLUGIN, {
1582
1787
  awaiting: void 0,
1583
1788
  spaceNames: {},
@@ -1657,8 +1862,8 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1657
1862
  log2.warn("Failed to broadcast active node for presence.", {
1658
1863
  err: err.message
1659
1864
  }, {
1660
- F: __dxlog_file4,
1661
- L: 223,
1865
+ F: __dxlog_file5,
1866
+ L: 225,
1662
1867
  S: void 0,
1663
1868
  C: (f, a) => f(...a)
1664
1869
  });
@@ -1779,8 +1984,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1779
1984
  ns: SPACE_PLUGIN
1780
1985
  }
1781
1986
  ],
1782
- icon: (props) => /* @__PURE__ */ React18.createElement(CardsThree2, props),
1783
- iconSymbol: "ph--cards-three--regular",
1987
+ icon: "ph--cards-three--regular",
1784
1988
  // TODO(wittjosiah): Move out of metadata.
1785
1989
  loadReferences: (collection) => loadObjectReferences(collection, (collection2) => [
1786
1990
  ...collection2.objects,
@@ -1887,7 +2091,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1887
2091
  });
1888
2092
  }
1889
2093
  case "status": {
1890
- return /* @__PURE__ */ React18.createElement(SaveStatus, null);
2094
+ return /* @__PURE__ */ React18.createElement(React18.Fragment, null, /* @__PURE__ */ React18.createElement(SyncStatus, null), /* @__PURE__ */ React18.createElement(SaveStatus, null));
1891
2095
  }
1892
2096
  default:
1893
2097
  return null;
@@ -1948,8 +2152,8 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1948
2152
  spacesOrder.order = nextOrder.map(({ id }) => id);
1949
2153
  } else {
1950
2154
  log2.warn("spaces order object not found", void 0, {
1951
- F: __dxlog_file4,
1952
- L: 518,
2155
+ F: __dxlog_file5,
2156
+ L: 524,
1953
2157
  S: void 0,
1954
2158
  C: (f, a) => f(...a)
1955
2159
  });
@@ -1985,8 +2189,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
1985
2189
  ns: SPACE_PLUGIN
1986
2190
  }
1987
2191
  ],
1988
- icon: (props) => /* @__PURE__ */ React18.createElement(Plus2, props),
1989
- iconSymbol: "ph--plus--regular",
2192
+ icon: "ph--plus--regular",
1990
2193
  disposition: "toolbar",
1991
2194
  testId: "spacePlugin.createSpace"
1992
2195
  }
@@ -2011,8 +2214,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
2011
2214
  ns: SPACE_PLUGIN
2012
2215
  }
2013
2216
  ],
2014
- icon: (props) => /* @__PURE__ */ React18.createElement(SignIn, props),
2015
- iconSymbol: "ph--sign-in--regular",
2217
+ icon: "ph--sign-in--regular",
2016
2218
  testId: "spacePlugin.joinSpace"
2017
2219
  }
2018
2220
  }
@@ -2247,6 +2449,25 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
2247
2449
  }
2248
2450
  },
2249
2451
  intents: [
2452
+ ...settings.values.onSpaceCreate ? [
2453
+ [
2454
+ {
2455
+ action: settings.values.onSpaceCreate,
2456
+ data: {
2457
+ space
2458
+ }
2459
+ },
2460
+ {
2461
+ action: SpaceAction.ADD_OBJECT,
2462
+ data: {
2463
+ target: space
2464
+ }
2465
+ },
2466
+ {
2467
+ action: NavigationAction3.EXPOSE
2468
+ }
2469
+ ]
2470
+ ] : [],
2250
2471
  [
2251
2472
  {
2252
2473
  action: ObservabilityAction.SEND_EVENT,
@@ -2467,8 +2688,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
2467
2688
  title: translations_default[0]["en-US"][SPACE_PLUGIN]["space limit label"],
2468
2689
  description: translations_default[0]["en-US"][SPACE_PLUGIN]["space limit description"],
2469
2690
  duration: 5e3,
2470
- icon: (props) => /* @__PURE__ */ React18.createElement(Warning2, props),
2471
- iconSymbol: "ph--warning--regular",
2691
+ icon: "ph--warning--regular",
2472
2692
  actionLabel: translations_default[0]["en-US"][SPACE_PLUGIN]["remove deleted objects label"],
2473
2693
  actionAlt: translations_default[0]["en-US"][SPACE_PLUGIN]["remove deleted objects alt"],
2474
2694
  // TODO(wittjosiah): Use OS namespace.
@@ -2510,7 +2730,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
2510
2730
  }
2511
2731
  return {
2512
2732
  data: {
2513
- id: object.id,
2733
+ id: fullyQualifiedId4(object),
2514
2734
  object,
2515
2735
  activeParts: {
2516
2736
  main: [
@@ -2563,8 +2783,7 @@ var SpacePlugin = ({ firstRun, onFirstRun } = {}) => {
2563
2783
  data: {
2564
2784
  activeParts: {
2565
2785
  main: deletionData.wasActive,
2566
- sidebar: deletionData.wasActive,
2567
- complementary: deletionData.wasActive
2786
+ sidebar: deletionData.wasActive
2568
2787
  }
2569
2788
  }
2570
2789
  });
@@ -2688,6 +2907,7 @@ export {
2688
2907
  EmptyTree,
2689
2908
  FullPresence,
2690
2909
  MenuFooter,
2910
+ MessageState,
2691
2911
  MessageType,
2692
2912
  MissingObject,
2693
2913
  PersistenceStatus,
@@ -2709,6 +2929,9 @@ export {
2709
2929
  SpacePlugin,
2710
2930
  SpacePresence,
2711
2931
  SpaceSettings,
2932
+ SyncStatus,
2933
+ SyncStatusDetail,
2934
+ SyncStatusIndicator,
2712
2935
  ThreadStatus,
2713
2936
  ThreadType,
2714
2937
  cloneObject,
@@ -2723,6 +2946,7 @@ export {
2723
2946
  getNestedObjects,
2724
2947
  getSpaceDisplayName,
2725
2948
  memoizeQuery,
2949
+ parseSpaceInitPlugin,
2726
2950
  parseSpacePlugin,
2727
2951
  translations_default as translations
2728
2952
  };