@dxos/plugin-space 0.8.4-main.3c1ae3b → 0.8.4-main.3eb6e50203
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.
- package/dist/lib/browser/CollectionArticle-XXLUNK3F.mjs +127 -0
- package/dist/lib/browser/CollectionArticle-XXLUNK3F.mjs.map +7 -0
- package/dist/lib/browser/ObjectCardStack-CXNBCSMR.mjs +148 -0
- package/dist/lib/browser/ObjectCardStack-CXNBCSMR.mjs.map +7 -0
- package/dist/lib/browser/ObjectDetails-HXV4IQEM.mjs +143 -0
- package/dist/lib/browser/ObjectDetails-HXV4IQEM.mjs.map +7 -0
- package/dist/lib/browser/RecordArticle-36LDKFWF.mjs +108 -0
- package/dist/lib/browser/RecordArticle-36LDKFWF.mjs.map +7 -0
- package/dist/lib/browser/app-graph-builder-GLV46QSI.mjs +530 -0
- package/dist/lib/browser/app-graph-builder-GLV46QSI.mjs.map +7 -0
- package/dist/lib/browser/app-graph-serializer-VOLRDNVE.mjs +85 -0
- package/dist/lib/browser/app-graph-serializer-VOLRDNVE.mjs.map +7 -0
- package/dist/lib/browser/{chunk-POFUXISV.mjs → chunk-7D63MVRS.mjs} +6 -5
- package/dist/lib/browser/chunk-7D63MVRS.mjs.map +7 -0
- package/dist/lib/browser/{chunk-5CSSKOWR.mjs → chunk-A7ZCVQGZ.mjs} +43 -45
- package/dist/lib/browser/chunk-A7ZCVQGZ.mjs.map +7 -0
- package/dist/lib/browser/chunk-ASV6DYFH.mjs +19 -0
- package/dist/lib/browser/chunk-ASV6DYFH.mjs.map +7 -0
- package/dist/lib/browser/chunk-CMLRMQNM.mjs +1889 -0
- package/dist/lib/browser/chunk-CMLRMQNM.mjs.map +7 -0
- package/dist/lib/browser/{chunk-VZBIIYFM.mjs → chunk-HSMQFM57.mjs} +1 -1
- package/dist/lib/browser/chunk-HSMQFM57.mjs.map +7 -0
- package/dist/lib/browser/chunk-KGLWYGIF.mjs +715 -0
- package/dist/lib/browser/chunk-KGLWYGIF.mjs.map +7 -0
- package/dist/lib/browser/chunk-NF3ZFAB4.mjs +13 -0
- package/dist/lib/browser/chunk-NF3ZFAB4.mjs.map +7 -0
- package/dist/lib/browser/{chunk-IJCMB5B5.mjs → chunk-WAOJLA2S.mjs} +195 -196
- package/dist/lib/browser/chunk-WAOJLA2S.mjs.map +7 -0
- package/dist/lib/browser/cli/index.mjs +851 -0
- package/dist/lib/browser/cli/index.mjs.map +7 -0
- package/dist/lib/browser/identity-created-VCFYLSBB.mjs +23 -0
- package/dist/lib/browser/identity-created-VCFYLSBB.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +215 -189
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/operation-resolver-PJJ3PCM7.mjs +830 -0
- package/dist/lib/browser/operation-resolver-PJJ3PCM7.mjs.map +7 -0
- package/dist/lib/browser/react-root-ITWAPZIY.mjs +30 -0
- package/dist/lib/browser/react-root-ITWAPZIY.mjs.map +7 -0
- package/dist/lib/browser/react-surface-6GD6K4I4.mjs +383 -0
- package/dist/lib/browser/react-surface-6GD6K4I4.mjs.map +7 -0
- package/dist/lib/browser/{repair-CNLE35NF.mjs → repair-DKU4TUD2.mjs} +16 -10
- package/dist/lib/browser/repair-DKU4TUD2.mjs.map +7 -0
- package/dist/lib/browser/settings-M2DMD2ZA.mjs +34 -0
- package/dist/lib/browser/settings-M2DMD2ZA.mjs.map +7 -0
- package/dist/lib/browser/spaces-ready-XWJUJ43N.mjs +243 -0
- package/dist/lib/browser/spaces-ready-XWJUJ43N.mjs.map +7 -0
- package/dist/lib/browser/state-V637BLIM.mjs +58 -0
- package/dist/lib/browser/state-V637BLIM.mjs.map +7 -0
- package/dist/lib/browser/types/index.mjs +10 -8
- package/dist/lib/node-esm/CollectionArticle-KFFKKP37.mjs +128 -0
- package/dist/lib/node-esm/CollectionArticle-KFFKKP37.mjs.map +7 -0
- package/dist/lib/node-esm/ObjectCardStack-EHXPNRQW.mjs +149 -0
- package/dist/lib/node-esm/ObjectCardStack-EHXPNRQW.mjs.map +7 -0
- package/dist/lib/node-esm/ObjectDetails-N73UI4ZL.mjs +144 -0
- package/dist/lib/node-esm/ObjectDetails-N73UI4ZL.mjs.map +7 -0
- package/dist/lib/node-esm/RecordArticle-CMEXNNOZ.mjs +109 -0
- package/dist/lib/node-esm/RecordArticle-CMEXNNOZ.mjs.map +7 -0
- package/dist/lib/node-esm/app-graph-builder-KCEHEKVS.mjs +531 -0
- package/dist/lib/node-esm/app-graph-builder-KCEHEKVS.mjs.map +7 -0
- package/dist/lib/node-esm/app-graph-serializer-7C4MV5NB.mjs +86 -0
- package/dist/lib/node-esm/app-graph-serializer-7C4MV5NB.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-2NM62ORP.mjs +1890 -0
- package/dist/lib/node-esm/chunk-2NM62ORP.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-AX3UGL5D.mjs → chunk-5N3YIAXD.mjs} +6 -5
- package/dist/lib/node-esm/chunk-5N3YIAXD.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-UMZ7G6G4.mjs → chunk-A5A7M37T.mjs} +43 -45
- package/dist/lib/node-esm/chunk-A5A7M37T.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-CVXULIYC.mjs +20 -0
- package/dist/lib/node-esm/chunk-CVXULIYC.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-3D4NGZPW.mjs → chunk-FB5YNROS.mjs} +195 -196
- package/dist/lib/node-esm/chunk-FB5YNROS.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-NYSDQPNM.mjs +716 -0
- package/dist/lib/node-esm/chunk-NYSDQPNM.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-PG7DNOEX.mjs +15 -0
- package/dist/lib/node-esm/chunk-PG7DNOEX.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-BDEFTL6K.mjs → chunk-SL4BJSUG.mjs} +1 -1
- package/dist/lib/node-esm/chunk-SL4BJSUG.mjs.map +7 -0
- package/dist/lib/node-esm/cli/index.mjs +852 -0
- package/dist/lib/node-esm/cli/index.mjs.map +7 -0
- package/dist/lib/node-esm/identity-created-2SJABVJD.mjs +25 -0
- package/dist/lib/node-esm/identity-created-2SJABVJD.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +215 -189
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/operation-resolver-2K7N4KYC.mjs +831 -0
- package/dist/lib/node-esm/operation-resolver-2K7N4KYC.mjs.map +7 -0
- package/dist/lib/node-esm/react-root-GIQAKDQ2.mjs +31 -0
- package/dist/lib/node-esm/react-root-GIQAKDQ2.mjs.map +7 -0
- package/dist/lib/node-esm/react-surface-KWP2DNFG.mjs +384 -0
- package/dist/lib/node-esm/react-surface-KWP2DNFG.mjs.map +7 -0
- package/dist/lib/node-esm/{repair-EHZS6MFY.mjs → repair-C2H6JQCL.mjs} +16 -10
- package/dist/lib/node-esm/repair-C2H6JQCL.mjs.map +7 -0
- package/dist/lib/node-esm/settings-VCPCNBOY.mjs +35 -0
- package/dist/lib/node-esm/settings-VCPCNBOY.mjs.map +7 -0
- package/dist/lib/node-esm/spaces-ready-5JOGEWON.mjs +244 -0
- package/dist/lib/node-esm/spaces-ready-5JOGEWON.mjs.map +7 -0
- package/dist/lib/node-esm/state-5MCEPWN3.mjs +59 -0
- package/dist/lib/node-esm/state-5MCEPWN3.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +10 -8
- package/dist/types/src/SpacePlugin.d.ts +3 -15
- package/dist/types/src/SpacePlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts +7 -0
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts +3 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-serializer/app-graph-serializer.d.ts +5 -0
- package/dist/types/src/capabilities/app-graph-serializer/app-graph-serializer.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-serializer/index.d.ts +3 -0
- package/dist/types/src/capabilities/app-graph-serializer/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/identity-created/identity-created.d.ts +5 -0
- package/dist/types/src/capabilities/identity-created/identity-created.d.ts.map +1 -0
- package/dist/types/src/capabilities/identity-created/index.d.ts +3 -0
- package/dist/types/src/capabilities/identity-created/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +10 -20
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-resolver/index.d.ts +6 -0
- package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +9 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-root/index.d.ts +6 -0
- package/dist/types/src/capabilities/react-root/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-root/react-root.d.ts +9 -0
- package/dist/types/src/capabilities/react-root/react-root.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts +5 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts +8 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -0
- package/dist/types/src/capabilities/repair/index.d.ts +3 -0
- package/dist/types/src/capabilities/repair/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/repair/repair.d.ts +6 -0
- package/dist/types/src/capabilities/repair/repair.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/index.d.ts +7 -0
- package/dist/types/src/capabilities/settings/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/settings.d.ts +10 -0
- package/dist/types/src/capabilities/settings/settings.d.ts.map +1 -0
- package/dist/types/src/capabilities/spaces-ready/index.d.ts +3 -0
- package/dist/types/src/capabilities/spaces-ready/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/spaces-ready/spaces-ready.d.ts +5 -0
- package/dist/types/src/capabilities/spaces-ready/spaces-ready.d.ts.map +1 -0
- package/dist/types/src/capabilities/state/index.d.ts +13 -0
- package/dist/types/src/capabilities/state/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/state/state.d.ts +17 -0
- package/dist/types/src/capabilities/state/state.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/add.d.ts +17 -0
- package/dist/types/src/cli/commands/database/add.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/index.d.ts +3 -0
- package/dist/types/src/cli/commands/database/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/query/index.d.ts +2 -0
- package/dist/types/src/cli/commands/database/query/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/query/query.d.ts +13 -0
- package/dist/types/src/cli/commands/database/query/query.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/query/query.test.d.ts +2 -0
- package/dist/types/src/cli/commands/database/query/query.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/remove.d.ts +9 -0
- package/dist/types/src/cli/commands/database/remove.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/stats.d.ts +6 -0
- package/dist/types/src/cli/commands/database/stats.d.ts.map +1 -0
- package/dist/types/src/cli/commands/database/util.d.ts +14 -0
- package/dist/types/src/cli/commands/database/util.d.ts.map +1 -0
- package/dist/types/src/cli/commands/index.d.ts +4 -0
- package/dist/types/src/cli/commands/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/queue/index.d.ts +7 -0
- package/dist/types/src/cli/commands/queue/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/queue/query.d.ts +8 -0
- package/dist/types/src/cli/commands/queue/query.d.ts.map +1 -0
- package/dist/types/src/cli/commands/queue/util.d.ts +6 -0
- package/dist/types/src/cli/commands/queue/util.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/close/close.d.ts +12 -0
- package/dist/types/src/cli/commands/space/close/close.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/close/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/close/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/create/create.d.ts +12 -0
- package/dist/types/src/cli/commands/space/create/create.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/create/create.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/create/create.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/create/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/create/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/index.d.ts +31 -0
- package/dist/types/src/cli/commands/space/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/info/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/info/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/info/info.d.ts +13 -0
- package/dist/types/src/cli/commands/space/info/info.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/info/info.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/info/info.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/join/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/join/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/join/join.d.ts +14 -0
- package/dist/types/src/cli/commands/space/join/join.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/join/util.d.ts +17 -0
- package/dist/types/src/cli/commands/space/join/util.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/list/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/list/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/list/list.d.ts +7 -0
- package/dist/types/src/cli/commands/space/list/list.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/list/list.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/list/list.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/members/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/members/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/members/members.d.ts +13 -0
- package/dist/types/src/cli/commands/space/members/members.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/members/members.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/members/members.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/members/util.d.ts +9 -0
- package/dist/types/src/cli/commands/space/members/util.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/open/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/open/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/open/open.d.ts +12 -0
- package/dist/types/src/cli/commands/space/open/open.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/schema/index.d.ts +8 -0
- package/dist/types/src/cli/commands/space/schema/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/schema/list/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/schema/list/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/schema/list/list.d.ts +15 -0
- package/dist/types/src/cli/commands/space/schema/list/list.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/schema/list/list.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/schema/list/list.test.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/schema/list/util.d.ts +15 -0
- package/dist/types/src/cli/commands/space/schema/list/util.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/share/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/share/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/share/share.d.ts +19 -0
- package/dist/types/src/cli/commands/space/share/share.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/sync/index.d.ts +2 -0
- package/dist/types/src/cli/commands/space/sync/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/sync/sync.d.ts +6 -0
- package/dist/types/src/cli/commands/space/sync/sync.d.ts.map +1 -0
- package/dist/types/src/cli/commands/space/sync/sync.test.d.ts +2 -0
- package/dist/types/src/cli/commands/space/sync/sync.test.d.ts.map +1 -0
- package/dist/types/src/cli/index.d.ts +2 -0
- package/dist/types/src/cli/index.d.ts.map +1 -0
- package/dist/types/src/cli/plugin.d.ts +4 -0
- package/dist/types/src/cli/plugin.d.ts.map +1 -0
- package/dist/types/src/components/AwaitingObject.d.ts.map +1 -1
- package/dist/types/src/components/CollectionArticle.d.ts +6 -3
- package/dist/types/src/components/CollectionArticle.d.ts.map +1 -1
- package/dist/types/src/components/CollectionSection.d.ts +1 -1
- package/dist/types/src/components/CollectionSection.d.ts.map +1 -1
- package/dist/types/src/components/CreateDialog/CreateObjectDialog.d.ts +2 -2
- package/dist/types/src/components/CreateDialog/CreateObjectDialog.d.ts.map +1 -1
- package/dist/types/src/components/CreateDialog/CreateObjectDialog.stories.d.ts +17 -7
- package/dist/types/src/components/CreateDialog/CreateObjectDialog.stories.d.ts.map +1 -1
- package/dist/types/src/components/CreateDialog/CreateObjectPanel.d.ts +9 -5
- package/dist/types/src/components/CreateDialog/CreateObjectPanel.d.ts.map +1 -1
- package/dist/types/src/components/CreateDialog/CreateSpaceDialog.d.ts.map +1 -1
- package/dist/types/src/components/JoinDialog/JoinDialog.d.ts.map +1 -1
- package/dist/types/src/components/MembersContainer/MembersContainer.d.ts.map +1 -1
- package/dist/types/src/components/MembersContainer/MembersContainer.stories.d.ts +11 -2
- package/dist/types/src/components/MembersContainer/MembersContainer.stories.d.ts.map +1 -1
- package/dist/types/src/components/MenuFooter.d.ts +1 -1
- package/dist/types/src/components/MenuFooter.d.ts.map +1 -1
- package/dist/types/src/components/ObjectCardStack/ObjectCardStack.d.ts +1 -1
- package/dist/types/src/components/ObjectCardStack/ObjectCardStack.d.ts.map +1 -1
- package/dist/types/src/components/ObjectCardStack/ObjectForm.d.ts +1 -1
- package/dist/types/src/components/ObjectCardStack/ObjectForm.d.ts.map +1 -1
- package/dist/types/src/components/ObjectDetails/BaseObjectSettings.d.ts +1 -1
- package/dist/types/src/components/ObjectDetails/BaseObjectSettings.d.ts.map +1 -1
- package/dist/types/src/components/ObjectDetails/BaseObjectSettings.stories.d.ts +9 -0
- package/dist/types/src/components/ObjectDetails/BaseObjectSettings.stories.d.ts.map +1 -1
- package/dist/types/src/components/ObjectDetails/ObjectDetails.d.ts +6 -5
- package/dist/types/src/components/ObjectDetails/ObjectDetails.d.ts.map +1 -1
- package/dist/types/src/components/ObjectRenamePopover/ObjectRenamePopover.d.ts +1 -1
- package/dist/types/src/components/ObjectRenamePopover/ObjectRenamePopover.d.ts.map +1 -1
- package/dist/types/src/components/RecordArticle.d.ts +2 -2
- package/dist/types/src/components/RecordArticle.d.ts.map +1 -1
- package/dist/types/src/components/RecordArticle.stories.d.ts +11 -2
- package/dist/types/src/components/RecordArticle.stories.d.ts.map +1 -1
- package/dist/types/src/components/SchemaContainer.d.ts.map +1 -1
- package/dist/types/src/components/SpacePluginSettings.d.ts +4 -2
- package/dist/types/src/components/SpacePluginSettings.d.ts.map +1 -1
- package/dist/types/src/components/SpacePresence/SpacePresence.d.ts +4 -4
- package/dist/types/src/components/SpacePresence/SpacePresence.d.ts.map +1 -1
- package/dist/types/src/components/SpacePresence/SpacePresence.stories.d.ts +9 -0
- package/dist/types/src/components/SpacePresence/SpacePresence.stories.d.ts.map +1 -1
- package/dist/types/src/components/SpaceRenamePopover/SpaceRenamePopover.d.ts.map +1 -1
- package/dist/types/src/components/SpaceSettings/SpaceSettingsContainer.d.ts +4 -1
- package/dist/types/src/components/SpaceSettings/SpaceSettingsContainer.d.ts.map +1 -1
- package/dist/types/src/components/SpaceSettings/SpaceSettingsContainer.stories.d.ts +13 -1
- package/dist/types/src/components/SpaceSettings/SpaceSettingsContainer.stories.d.ts.map +1 -1
- package/dist/types/src/components/SyncStatus/SyncStatus.stories.d.ts +9 -0
- package/dist/types/src/components/SyncStatus/SyncStatus.stories.d.ts.map +1 -1
- package/dist/types/src/components/ViewEditor.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +11 -6
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/constants.d.ts +6 -0
- package/dist/types/src/constants.d.ts.map +1 -0
- package/dist/types/src/helpers/query.d.ts +3 -3
- package/dist/types/src/helpers/query.d.ts.map +1 -1
- package/dist/types/src/hooks/useActiveSpace.d.ts +2 -2
- package/dist/types/src/hooks/useActiveSpace.d.ts.map +1 -1
- package/dist/types/src/hooks/usePath.d.ts +2 -2
- package/dist/types/src/hooks/usePath.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -2
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +2 -2
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +9 -0
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/capabilities.d.ts +71 -0
- package/dist/types/src/types/capabilities.d.ts.map +1 -0
- package/dist/types/src/types/events.d.ts +9 -0
- package/dist/types/src/types/events.d.ts.map +1 -0
- package/dist/types/src/types/index.d.ts +2 -0
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/types/types.d.ts +643 -354
- package/dist/types/src/types/types.d.ts.map +1 -1
- package/dist/types/src/util.d.ts +36 -31
- package/dist/types/src/util.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +83 -69
- package/src/SpacePlugin.ts +174 -194
- package/src/capabilities/app-graph-builder/app-graph-builder.ts +621 -0
- package/src/capabilities/app-graph-builder/index.ts +7 -0
- package/src/capabilities/app-graph-serializer/app-graph-serializer.ts +83 -0
- package/src/capabilities/app-graph-serializer/index.ts +7 -0
- package/src/capabilities/identity-created/identity-created.ts +29 -0
- package/src/capabilities/identity-created/index.ts +7 -0
- package/src/capabilities/index.ts +10 -14
- package/src/capabilities/operation-resolver/index.ts +7 -0
- package/src/capabilities/operation-resolver/operation-resolver.ts +762 -0
- package/src/capabilities/react-root/index.ts +7 -0
- package/src/capabilities/react-root/react-root.tsx +25 -0
- package/src/capabilities/react-surface/index.ts +7 -0
- package/src/capabilities/react-surface/react-surface.tsx +377 -0
- package/src/capabilities/repair/index.ts +7 -0
- package/src/capabilities/{repair.ts → repair/repair.ts} +21 -11
- package/src/capabilities/settings/index.ts +7 -0
- package/src/capabilities/settings/settings.ts +33 -0
- package/src/capabilities/spaces-ready/index.ts +7 -0
- package/src/capabilities/spaces-ready/spaces-ready.ts +290 -0
- package/src/capabilities/state/index.ts +7 -0
- package/src/capabilities/state/state.ts +64 -0
- package/src/cli/commands/database/add.ts +115 -0
- package/src/cli/commands/database/index.ts +16 -0
- package/src/cli/commands/database/query/index.ts +5 -0
- package/src/cli/commands/database/query/query.test.ts +55 -0
- package/src/cli/commands/database/query/query.ts +44 -0
- package/src/cli/commands/database/remove.ts +51 -0
- package/src/cli/commands/database/stats.ts +44 -0
- package/src/cli/commands/database/util.ts +32 -0
- package/src/cli/commands/index.ts +7 -0
- package/src/cli/commands/queue/index.ts +12 -0
- package/src/cli/commands/queue/query.ts +45 -0
- package/src/cli/commands/queue/util.ts +19 -0
- package/src/cli/commands/space/close/close.ts +40 -0
- package/src/cli/commands/space/close/index.ts +5 -0
- package/src/cli/commands/space/create/create.test.ts +67 -0
- package/src/cli/commands/space/create/create.ts +61 -0
- package/src/cli/commands/space/create/index.ts +5 -0
- package/src/cli/commands/space/index.ts +21 -0
- package/src/cli/commands/space/info/index.ts +5 -0
- package/src/cli/commands/space/info/info.test.ts +47 -0
- package/src/cli/commands/space/info/info.ts +37 -0
- package/src/cli/commands/space/join/index.ts +5 -0
- package/src/cli/commands/space/join/join.ts +122 -0
- package/src/cli/commands/space/join/util.ts +82 -0
- package/src/cli/commands/space/list/index.ts +5 -0
- package/src/cli/commands/space/list/list.test.ts +36 -0
- package/src/cli/commands/space/list/list.ts +30 -0
- package/src/cli/commands/space/members/index.ts +5 -0
- package/src/cli/commands/space/members/members.test.ts +46 -0
- package/src/cli/commands/space/members/members.ts +40 -0
- package/src/cli/commands/space/members/util.ts +29 -0
- package/src/cli/commands/space/open/index.ts +5 -0
- package/src/cli/commands/space/open/open.ts +39 -0
- package/src/cli/commands/space/schema/index.ts +12 -0
- package/src/cli/commands/space/schema/list/index.ts +5 -0
- package/src/cli/commands/space/schema/list/list.test.ts +42 -0
- package/src/cli/commands/space/schema/list/list.ts +64 -0
- package/src/cli/commands/space/schema/list/util.ts +39 -0
- package/src/cli/commands/space/share/index.ts +5 -0
- package/src/cli/commands/space/share/share.ts +112 -0
- package/src/cli/commands/space/sync/index.ts +5 -0
- package/src/cli/commands/space/sync/sync.test.ts +12 -0
- package/src/cli/commands/space/sync/sync.ts +33 -0
- package/src/cli/index.ts +5 -0
- package/src/cli/plugin.ts +88 -0
- package/src/components/AwaitingObject.tsx +14 -10
- package/src/components/CollectionArticle.tsx +142 -19
- package/src/components/CollectionSection.tsx +1 -1
- package/src/components/CreateDialog/CreateObjectDialog.stories.tsx +28 -22
- package/src/components/CreateDialog/CreateObjectDialog.tsx +55 -60
- package/src/components/CreateDialog/CreateObjectPanel.tsx +102 -52
- package/src/components/CreateDialog/CreateSpaceDialog.tsx +34 -51
- package/src/components/JoinDialog/JoinDialog.tsx +26 -52
- package/src/components/MembersContainer/MembersContainer.stories.tsx +3 -3
- package/src/components/MembersContainer/MembersContainer.tsx +76 -81
- package/src/components/MenuFooter.tsx +1 -1
- package/src/components/ObjectCardStack/ObjectCardStack.tsx +13 -10
- package/src/components/ObjectCardStack/ObjectForm.tsx +34 -27
- package/src/components/ObjectDetails/BaseObjectSettings.stories.tsx +8 -8
- package/src/components/ObjectDetails/BaseObjectSettings.tsx +35 -31
- package/src/components/ObjectDetails/ObjectDetails.tsx +9 -11
- package/src/components/ObjectRenamePopover/ObjectRenamePopover.tsx +9 -13
- package/src/components/RecordArticle.stories.tsx +14 -13
- package/src/components/RecordArticle.tsx +47 -37
- package/src/components/SchemaContainer.tsx +20 -17
- package/src/components/SpacePluginSettings.tsx +42 -35
- package/src/components/SpacePresence/SpacePresence.stories.tsx +1 -1
- package/src/components/SpacePresence/SpacePresence.tsx +15 -16
- package/src/components/SpaceRenamePopover/SpaceRenamePopover.tsx +11 -12
- package/src/components/SpaceSettings/SpaceSettingsContainer.stories.tsx +5 -5
- package/src/components/SpaceSettings/SpaceSettingsContainer.tsx +165 -182
- package/src/components/SyncStatus/InlineSyncStatus.tsx +1 -1
- package/src/components/SyncStatus/SyncStatus.stories.tsx +1 -1
- package/src/components/SyncStatus/SyncStatus.tsx +1 -1
- package/src/components/SyncStatus/save-tracker.ts +2 -2
- package/src/components/ViewEditor.tsx +16 -12
- package/src/constants.ts +11 -0
- package/src/helpers/query.ts +7 -6
- package/src/hooks/useActiveSpace.ts +8 -5
- package/src/hooks/useInputSurfaceLookup.tsx +3 -3
- package/src/hooks/usePath.ts +4 -4
- package/src/index.ts +1 -2
- package/src/meta.ts +2 -2
- package/src/translations.ts +4 -2
- package/src/types/capabilities.ts +73 -0
- package/src/types/events.ts +16 -0
- package/src/types/index.ts +2 -0
- package/src/types/types.ts +533 -245
- package/src/util.tsx +222 -230
- package/dist/lib/browser/CollectionArticle-WTHWY4YS.mjs +0 -31
- package/dist/lib/browser/CollectionArticle-WTHWY4YS.mjs.map +0 -7
- package/dist/lib/browser/ObjectCardStack-TE7AWPMH.mjs +0 -144
- package/dist/lib/browser/ObjectCardStack-TE7AWPMH.mjs.map +0 -7
- package/dist/lib/browser/ObjectDetails-666IBRHE.mjs +0 -144
- package/dist/lib/browser/ObjectDetails-666IBRHE.mjs.map +0 -7
- package/dist/lib/browser/RecordArticle-2PFEBPXY.mjs +0 -116
- package/dist/lib/browser/RecordArticle-2PFEBPXY.mjs.map +0 -7
- package/dist/lib/browser/app-graph-builder-USKWFIDK.mjs +0 -551
- package/dist/lib/browser/app-graph-builder-USKWFIDK.mjs.map +0 -7
- package/dist/lib/browser/app-graph-serializer-SXIQ425K.mjs +0 -80
- package/dist/lib/browser/app-graph-serializer-SXIQ425K.mjs.map +0 -7
- package/dist/lib/browser/chunk-5CSSKOWR.mjs.map +0 -7
- package/dist/lib/browser/chunk-C6DAPIFF.mjs +0 -20
- package/dist/lib/browser/chunk-C6DAPIFF.mjs.map +0 -7
- package/dist/lib/browser/chunk-E4BEMEZ3.mjs +0 -399
- package/dist/lib/browser/chunk-E4BEMEZ3.mjs.map +0 -7
- package/dist/lib/browser/chunk-IJCMB5B5.mjs.map +0 -7
- package/dist/lib/browser/chunk-POFUXISV.mjs.map +0 -7
- package/dist/lib/browser/chunk-VZBIIYFM.mjs.map +0 -7
- package/dist/lib/browser/chunk-WJXU4GKV.mjs +0 -19
- package/dist/lib/browser/chunk-WJXU4GKV.mjs.map +0 -7
- package/dist/lib/browser/chunk-XKQCDLXX.mjs +0 -2103
- package/dist/lib/browser/chunk-XKQCDLXX.mjs.map +0 -7
- package/dist/lib/browser/identity-created-NAXTPQXE.mjs +0 -23
- package/dist/lib/browser/identity-created-NAXTPQXE.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-QEIM7NQT.mjs +0 -769
- package/dist/lib/browser/intent-resolver-QEIM7NQT.mjs.map +0 -7
- package/dist/lib/browser/react-root-T6ZETLD2.mjs +0 -30
- package/dist/lib/browser/react-root-T6ZETLD2.mjs.map +0 -7
- package/dist/lib/browser/react-surface-MLN5BZ2G.mjs +0 -374
- package/dist/lib/browser/react-surface-MLN5BZ2G.mjs.map +0 -7
- package/dist/lib/browser/repair-CNLE35NF.mjs.map +0 -7
- package/dist/lib/browser/settings-EGTCHS7U.mjs +0 -24
- package/dist/lib/browser/settings-EGTCHS7U.mjs.map +0 -7
- package/dist/lib/browser/spaces-ready-YS4BBZXW.mjs +0 -208
- package/dist/lib/browser/spaces-ready-YS4BBZXW.mjs.map +0 -7
- package/dist/lib/browser/state-C7N6EDDZ.mjs +0 -47
- package/dist/lib/browser/state-C7N6EDDZ.mjs.map +0 -7
- package/dist/lib/node-esm/CollectionArticle-KHXYT3SH.mjs +0 -32
- package/dist/lib/node-esm/CollectionArticle-KHXYT3SH.mjs.map +0 -7
- package/dist/lib/node-esm/ObjectCardStack-AAKMAQ6T.mjs +0 -145
- package/dist/lib/node-esm/ObjectCardStack-AAKMAQ6T.mjs.map +0 -7
- package/dist/lib/node-esm/ObjectDetails-TZ5YKXGN.mjs +0 -145
- package/dist/lib/node-esm/ObjectDetails-TZ5YKXGN.mjs.map +0 -7
- package/dist/lib/node-esm/RecordArticle-SSJ7PULS.mjs +0 -117
- package/dist/lib/node-esm/RecordArticle-SSJ7PULS.mjs.map +0 -7
- package/dist/lib/node-esm/app-graph-builder-QRQ5EQLB.mjs +0 -552
- package/dist/lib/node-esm/app-graph-builder-QRQ5EQLB.mjs.map +0 -7
- package/dist/lib/node-esm/app-graph-serializer-P2X4W7LI.mjs +0 -81
- package/dist/lib/node-esm/app-graph-serializer-P2X4W7LI.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-3D4NGZPW.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-AX3UGL5D.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-BDEFTL6K.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-H4JILUJK.mjs +0 -20
- package/dist/lib/node-esm/chunk-H4JILUJK.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-QQQE2ZCX.mjs +0 -400
- package/dist/lib/node-esm/chunk-QQQE2ZCX.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-UMZ7G6G4.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-WWGV5FJM.mjs +0 -21
- package/dist/lib/node-esm/chunk-WWGV5FJM.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-XD532BVR.mjs +0 -2104
- package/dist/lib/node-esm/chunk-XD532BVR.mjs.map +0 -7
- package/dist/lib/node-esm/identity-created-OXLKCJE3.mjs +0 -25
- package/dist/lib/node-esm/identity-created-OXLKCJE3.mjs.map +0 -7
- package/dist/lib/node-esm/intent-resolver-ZWCBVABN.mjs +0 -770
- package/dist/lib/node-esm/intent-resolver-ZWCBVABN.mjs.map +0 -7
- package/dist/lib/node-esm/react-root-SKB4UJ4K.mjs +0 -31
- package/dist/lib/node-esm/react-root-SKB4UJ4K.mjs.map +0 -7
- package/dist/lib/node-esm/react-surface-BVZGNSBB.mjs +0 -375
- package/dist/lib/node-esm/react-surface-BVZGNSBB.mjs.map +0 -7
- package/dist/lib/node-esm/repair-EHZS6MFY.mjs.map +0 -7
- package/dist/lib/node-esm/settings-N3F6JCIR.mjs +0 -25
- package/dist/lib/node-esm/settings-N3F6JCIR.mjs.map +0 -7
- package/dist/lib/node-esm/spaces-ready-U2K5P4LB.mjs +0 -209
- package/dist/lib/node-esm/spaces-ready-U2K5P4LB.mjs.map +0 -7
- package/dist/lib/node-esm/state-45TXZQJ6.mjs +0 -48
- package/dist/lib/node-esm/state-45TXZQJ6.mjs.map +0 -7
- package/dist/types/src/capabilities/app-graph-builder.d.ts +0 -4
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +0 -1
- package/dist/types/src/capabilities/app-graph-serializer.d.ts +0 -4
- package/dist/types/src/capabilities/app-graph-serializer.d.ts.map +0 -1
- package/dist/types/src/capabilities/capabilities.d.ts +0 -34
- package/dist/types/src/capabilities/capabilities.d.ts.map +0 -1
- package/dist/types/src/capabilities/identity-created.d.ts +0 -4
- package/dist/types/src/capabilities/identity-created.d.ts.map +0 -1
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -9
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-root.d.ts +0 -7
- package/dist/types/src/capabilities/react-root.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-surface.d.ts +0 -7
- package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
- package/dist/types/src/capabilities/repair.d.ts +0 -4
- package/dist/types/src/capabilities/repair.d.ts.map +0 -1
- package/dist/types/src/capabilities/settings.d.ts +0 -4
- package/dist/types/src/capabilities/settings.d.ts.map +0 -1
- package/dist/types/src/capabilities/spaces-ready.d.ts +0 -4
- package/dist/types/src/capabilities/spaces-ready.d.ts.map +0 -1
- package/dist/types/src/capabilities/state.d.ts +0 -5
- package/dist/types/src/capabilities/state.d.ts.map +0 -1
- package/dist/types/src/events.d.ts +0 -8
- package/dist/types/src/events.d.ts.map +0 -1
- package/src/capabilities/app-graph-builder.ts +0 -724
- package/src/capabilities/app-graph-serializer.ts +0 -76
- package/src/capabilities/capabilities.ts +0 -40
- package/src/capabilities/identity-created.ts +0 -25
- package/src/capabilities/intent-resolver.ts +0 -705
- package/src/capabilities/react-root.tsx +0 -22
- package/src/capabilities/react-surface.tsx +0 -358
- package/src/capabilities/settings.ts +0 -21
- package/src/capabilities/spaces-ready.ts +0 -252
- package/src/capabilities/state.ts +0 -46
- package/src/events.ts +0 -15
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { ActivationEvents, Capability, Plugin } from '@dxos/app-framework';
|
|
8
|
+
import { AppPlugin } from '@dxos/app-toolkit';
|
|
9
|
+
import { Tag } from '@dxos/echo';
|
|
10
|
+
import { ClientEvents } from '@dxos/plugin-client/types';
|
|
11
|
+
import { Collection, DataTypes } from '@dxos/schema';
|
|
12
|
+
import {
|
|
13
|
+
AnchoredTo,
|
|
14
|
+
Employer,
|
|
15
|
+
Event,
|
|
16
|
+
HasConnection,
|
|
17
|
+
HasRelationship,
|
|
18
|
+
HasSubject,
|
|
19
|
+
Organization,
|
|
20
|
+
Person,
|
|
21
|
+
Pipeline,
|
|
22
|
+
Task,
|
|
23
|
+
} from '@dxos/types';
|
|
24
|
+
|
|
25
|
+
import { IdentityCreated } from '../capabilities/identity-created';
|
|
26
|
+
import { OperationResolver } from '../capabilities/operation-resolver';
|
|
27
|
+
import { meta } from '../meta';
|
|
28
|
+
import { SpaceEvents } from '../types';
|
|
29
|
+
import { type CreateObject, type SpacePluginOptions } from '../types';
|
|
30
|
+
|
|
31
|
+
import { database, queue, space } from './commands';
|
|
32
|
+
|
|
33
|
+
export const SpacePlugin = Plugin.define<SpacePluginOptions>(meta).pipe(
|
|
34
|
+
// TODO(wittjosiah): Could some of these commands make use of operations?
|
|
35
|
+
AppPlugin.addCommandModule({
|
|
36
|
+
commands: [database, queue, space],
|
|
37
|
+
}),
|
|
38
|
+
AppPlugin.addMetadataModule({
|
|
39
|
+
metadata: {
|
|
40
|
+
id: Collection.Collection.typename,
|
|
41
|
+
metadata: {
|
|
42
|
+
createObject: ((props) => Effect.sync(() => Collection.make(props))) satisfies CreateObject,
|
|
43
|
+
addToCollectionOnCreate: true,
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
}),
|
|
47
|
+
AppPlugin.addSchemaModule({
|
|
48
|
+
schema: [
|
|
49
|
+
...DataTypes,
|
|
50
|
+
AnchoredTo.AnchoredTo,
|
|
51
|
+
Employer.Employer,
|
|
52
|
+
Event.Event,
|
|
53
|
+
HasConnection.HasConnection,
|
|
54
|
+
HasRelationship.HasRelationship,
|
|
55
|
+
HasSubject.HasSubject,
|
|
56
|
+
Organization.Organization,
|
|
57
|
+
Person.Person,
|
|
58
|
+
Pipeline.Pipeline,
|
|
59
|
+
Tag.Tag,
|
|
60
|
+
Task.Task,
|
|
61
|
+
],
|
|
62
|
+
}),
|
|
63
|
+
Plugin.addModule(
|
|
64
|
+
({
|
|
65
|
+
shareableLinkOrigin = 'http://localhost:5173',
|
|
66
|
+
invitationPath = '/',
|
|
67
|
+
invitationProp = 'spaceInvitationCode',
|
|
68
|
+
}) => {
|
|
69
|
+
const createInvitationUrl = (invitationCode: string) => {
|
|
70
|
+
const baseUrl = new URL(invitationPath || '/', shareableLinkOrigin);
|
|
71
|
+
baseUrl.searchParams.set(invitationProp, invitationCode);
|
|
72
|
+
return baseUrl.toString();
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
return {
|
|
76
|
+
id: Capability.getModuleTag(OperationResolver),
|
|
77
|
+
activatesOn: ActivationEvents.SetupOperationResolver,
|
|
78
|
+
activate: () => OperationResolver({ createInvitationUrl, observability: false }),
|
|
79
|
+
};
|
|
80
|
+
},
|
|
81
|
+
),
|
|
82
|
+
Plugin.addModule({
|
|
83
|
+
activatesOn: ClientEvents.IdentityCreated,
|
|
84
|
+
activatesAfter: [SpaceEvents.DefaultSpaceReady],
|
|
85
|
+
activate: IdentityCreated,
|
|
86
|
+
}),
|
|
87
|
+
Plugin.make,
|
|
88
|
+
);
|
|
@@ -4,22 +4,24 @@
|
|
|
4
4
|
|
|
5
5
|
import React, { useCallback, useEffect, useState } from 'react';
|
|
6
6
|
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
7
|
+
import { useOperationInvoker } from '@dxos/app-framework/ui';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { useLayout } from '@dxos/app-toolkit/ui';
|
|
9
10
|
import { Obj } from '@dxos/echo';
|
|
10
11
|
import { useClient } from '@dxos/react-client';
|
|
11
12
|
import { Filter, useQuery } from '@dxos/react-client/echo';
|
|
12
13
|
import { Button, Icon, Toast, useTranslation } from '@dxos/react-ui';
|
|
14
|
+
import { osTranslations } from '@dxos/ui-theme';
|
|
13
15
|
|
|
14
16
|
import { meta } from '../meta';
|
|
15
|
-
import {
|
|
17
|
+
import { SpaceOperation } from '../types';
|
|
16
18
|
|
|
17
19
|
const WAIT_FOR_OBJECT_TIMEOUT = 3 * 60 * 1_000;
|
|
18
20
|
const TOAST_TIMEOUT = 4 * 60 * 1_000;
|
|
19
21
|
|
|
20
22
|
export const AwaitingObject = ({ id }: { id: string }) => {
|
|
21
23
|
const { t } = useTranslation(meta.id);
|
|
22
|
-
const {
|
|
24
|
+
const { invokePromise } = useOperationInvoker();
|
|
23
25
|
const [open, setOpen] = useState(true);
|
|
24
26
|
const [waiting, setWaiting] = useState(true);
|
|
25
27
|
const [found, setFound] = useState(false);
|
|
@@ -47,14 +49,14 @@ export const AwaitingObject = ({ id }: { id: string }) => {
|
|
|
47
49
|
}, [id, objects, layout]);
|
|
48
50
|
|
|
49
51
|
const handleClose = useCallback(
|
|
50
|
-
async () =>
|
|
51
|
-
[
|
|
52
|
+
async () => invokePromise(SpaceOperation.WaitForObject, { id: undefined }),
|
|
53
|
+
[invokePromise],
|
|
52
54
|
);
|
|
53
55
|
|
|
54
56
|
const handleNavigate = useCallback(() => {
|
|
55
|
-
void
|
|
57
|
+
void invokePromise(LayoutOperation.Open, { subject: [id] });
|
|
56
58
|
void handleClose();
|
|
57
|
-
}, [id, handleClose,
|
|
59
|
+
}, [id, handleClose, invokePromise]);
|
|
58
60
|
|
|
59
61
|
return (
|
|
60
62
|
<Toast.Root open={open} duration={TOAST_TIMEOUT} onOpenChange={setOpen}>
|
|
@@ -96,12 +98,14 @@ export const AwaitingObject = ({ id }: { id: string }) => {
|
|
|
96
98
|
</Button>
|
|
97
99
|
</Toast.Action>
|
|
98
100
|
<Toast.Close asChild>
|
|
99
|
-
<Button onClick={handleClose}>{t('close label', { ns:
|
|
101
|
+
<Button onClick={handleClose}>{t('close label', { ns: osTranslations })}</Button>
|
|
100
102
|
</Toast.Close>
|
|
101
103
|
</>
|
|
102
104
|
) : (
|
|
103
105
|
<Toast.Close asChild>
|
|
104
|
-
<Button onClick={handleClose}>
|
|
106
|
+
<Button onClick={handleClose}>
|
|
107
|
+
{t(waiting ? 'close label' : 'confirm label', { ns: osTranslations })}
|
|
108
|
+
</Button>
|
|
105
109
|
</Toast.Close>
|
|
106
110
|
)}
|
|
107
111
|
</Toast.Actions>
|
|
@@ -1,33 +1,156 @@
|
|
|
1
1
|
//
|
|
2
|
-
// Copyright
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import React from 'react';
|
|
5
|
+
import React, { useCallback, useMemo } from 'react';
|
|
6
6
|
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
7
|
+
import { useCapabilities, useOperationInvoker } from '@dxos/app-framework/ui';
|
|
8
|
+
import { AppCapabilities, LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { type SurfaceComponentProps } from '@dxos/app-toolkit/ui';
|
|
10
|
+
import { Filter, Obj } from '@dxos/echo';
|
|
11
|
+
import { useClient } from '@dxos/react-client';
|
|
12
|
+
import { getSpace, useQuery } from '@dxos/react-client/echo';
|
|
13
|
+
import { Layout, ScrollArea, Toolbar, toLocalizedString, useTranslation } from '@dxos/react-ui';
|
|
14
|
+
import { Card, Mosaic, type StackTileComponent } from '@dxos/react-ui-mosaic';
|
|
15
|
+
import { SearchList, useSearchListResults } from '@dxos/react-ui-searchlist';
|
|
16
|
+
import { Collection } from '@dxos/schema';
|
|
17
|
+
import { getStyles } from '@dxos/ui-theme';
|
|
11
18
|
|
|
12
19
|
import { meta } from '../meta';
|
|
13
20
|
|
|
14
|
-
|
|
21
|
+
/**
|
|
22
|
+
* Hook to resolve metadata (icon, iconHue, etc.) for objects based on their typename.
|
|
23
|
+
*/
|
|
24
|
+
const useMetadataResolver = () => {
|
|
25
|
+
const allMetadata = useCapabilities(AppCapabilities.Metadata);
|
|
26
|
+
return useCallback((typename: string) => allMetadata.find((m) => m.id === typename)?.metadata ?? {}, [allMetadata]);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Article view for collections.
|
|
31
|
+
*/
|
|
32
|
+
export const CollectionArticle = ({ subject }: SurfaceComponentProps<Collection.Collection | Collection.Managed>) => {
|
|
15
33
|
const { t } = useTranslation(meta.id);
|
|
34
|
+
const resolveMetadata = useMetadataResolver();
|
|
35
|
+
const { items, handleSearch } = useCollectionItems(subject, resolveMetadata);
|
|
16
36
|
|
|
17
37
|
return (
|
|
18
|
-
<
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
38
|
+
<Layout.Main toolbar>
|
|
39
|
+
<SearchList.Root onSearch={handleSearch}>
|
|
40
|
+
<Toolbar.Root>
|
|
41
|
+
<SearchList.Input placeholder={t('search placeholder')} />
|
|
42
|
+
</Toolbar.Root>
|
|
43
|
+
<SearchList.Content>
|
|
44
|
+
<Mosaic.Container asChild>
|
|
45
|
+
<ScrollArea.Root orientation='vertical'>
|
|
46
|
+
<ScrollArea.Viewport classNames='p-2'>
|
|
47
|
+
<Mosaic.Stack items={items} getId={(item) => item.id} Tile={ObjectTile} />
|
|
48
|
+
</ScrollArea.Viewport>
|
|
49
|
+
</ScrollArea.Root>
|
|
50
|
+
</Mosaic.Container>
|
|
51
|
+
</SearchList.Content>
|
|
52
|
+
</SearchList.Root>
|
|
53
|
+
</Layout.Main>
|
|
54
|
+
);
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
type ObjectItem = {
|
|
58
|
+
id: string;
|
|
59
|
+
object: Obj.Unknown;
|
|
60
|
+
icon: string;
|
|
61
|
+
iconHue?: string;
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
const ObjectTile: StackTileComponent<ObjectItem> = ({ data: item }) => {
|
|
65
|
+
const { t } = useTranslation(meta.id);
|
|
66
|
+
const { invokeSync } = useOperationInvoker();
|
|
67
|
+
|
|
68
|
+
const typename = Obj.getTypename(item.object) ?? '';
|
|
69
|
+
const label =
|
|
70
|
+
Obj.getLabel(item.object) ??
|
|
71
|
+
toLocalizedString(['object name placeholder', { ns: typename, defaultValue: item.id }], t);
|
|
72
|
+
const styles = item.iconHue ? getStyles(item.iconHue) : undefined;
|
|
73
|
+
|
|
74
|
+
const handleClick = () => {
|
|
75
|
+
invokeSync(LayoutOperation.Open, { subject: [item.id] });
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
return (
|
|
79
|
+
<Card.Root fullWidth>
|
|
80
|
+
<Card.Toolbar>
|
|
81
|
+
<Card.ToolbarIconButton variant='ghost' label={label} icon={item.icon} iconOnly iconClassNames={styles?.icon} />
|
|
82
|
+
<Card.Title onClick={handleClick}>{label}</Card.Title>
|
|
83
|
+
<Card.Menu />
|
|
84
|
+
</Card.Toolbar>
|
|
85
|
+
</Card.Root>
|
|
30
86
|
);
|
|
31
87
|
};
|
|
32
88
|
|
|
33
89
|
export default CollectionArticle;
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Hook to get items from a regular collection.
|
|
93
|
+
*/
|
|
94
|
+
const useRegularCollectionItems = (collection: Collection.Collection): Obj.Unknown[] => {
|
|
95
|
+
return useMemo(
|
|
96
|
+
() => (collection.objects ?? []).map((ref) => ref.target).filter((obj): obj is Obj.Unknown => Obj.isObject(obj)),
|
|
97
|
+
[collection.objects],
|
|
98
|
+
);
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Hook to get items from a managed collection by querying the space.
|
|
103
|
+
*/
|
|
104
|
+
const useManagedCollectionItems = (collection: Collection.Managed): Obj.Unknown[] => {
|
|
105
|
+
const client = useClient();
|
|
106
|
+
const space = getSpace(collection);
|
|
107
|
+
|
|
108
|
+
const schema = useMemo(
|
|
109
|
+
() => client.graph.schemaRegistry.query({ typename: collection.key, location: ['runtime'] }).runSync()[0],
|
|
110
|
+
[client, collection],
|
|
111
|
+
);
|
|
112
|
+
|
|
113
|
+
return useQuery(space?.db, schema ? Filter.type(schema) : Filter.nothing());
|
|
114
|
+
};
|
|
115
|
+
|
|
116
|
+
type MetadataResolver = (typename: string) => { icon?: string; iconHue?: string };
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* Combined hook to get collection items with search/filter support.
|
|
120
|
+
*/
|
|
121
|
+
const useCollectionItems = (
|
|
122
|
+
collection: Collection.Collection | Collection.Managed,
|
|
123
|
+
resolveMetadata: MetadataResolver,
|
|
124
|
+
) => {
|
|
125
|
+
const isManaged = Obj.instanceOf(Collection.Managed, collection);
|
|
126
|
+
|
|
127
|
+
// Call both hooks unconditionally to satisfy React's rules of hooks.
|
|
128
|
+
const regularObjects = useRegularCollectionItems(collection as Collection.Collection);
|
|
129
|
+
const managedObjects = useManagedCollectionItems(collection as Collection.Managed);
|
|
130
|
+
|
|
131
|
+
const objects = isManaged ? managedObjects : regularObjects;
|
|
132
|
+
|
|
133
|
+
// Convert objects to items with resolved metadata.
|
|
134
|
+
const items = useMemo(
|
|
135
|
+
() =>
|
|
136
|
+
objects.map((obj) => {
|
|
137
|
+
const typename = Obj.getTypename(obj);
|
|
138
|
+
const metadata = typename ? resolveMetadata(typename) : {};
|
|
139
|
+
return {
|
|
140
|
+
id: Obj.getDXN(obj).toString(),
|
|
141
|
+
object: obj,
|
|
142
|
+
icon: metadata.icon ?? 'ph--placeholder--regular',
|
|
143
|
+
iconHue: metadata.iconHue,
|
|
144
|
+
} satisfies ObjectItem;
|
|
145
|
+
}),
|
|
146
|
+
[objects, resolveMetadata],
|
|
147
|
+
);
|
|
148
|
+
|
|
149
|
+
// Use searchlist results for filtering.
|
|
150
|
+
const { results, handleSearch } = useSearchListResults({
|
|
151
|
+
items,
|
|
152
|
+
extract: (item) => Obj.getLabel(item.object) ?? item.id,
|
|
153
|
+
});
|
|
154
|
+
|
|
155
|
+
return { items: results, handleSearch };
|
|
156
|
+
};
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import React from 'react';
|
|
6
6
|
|
|
7
|
-
import { type SurfaceComponentProps } from '@dxos/app-
|
|
7
|
+
import { type SurfaceComponentProps } from '@dxos/app-toolkit/ui';
|
|
8
8
|
import { useTranslation } from '@dxos/react-ui';
|
|
9
9
|
import { type Collection } from '@dxos/schema';
|
|
10
10
|
|
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
import { type Meta, type StoryObj } from '@storybook/react-vite';
|
|
6
6
|
import React, { useEffect } from 'react';
|
|
7
7
|
|
|
8
|
-
import {
|
|
8
|
+
import { OperationPlugin, RuntimePlugin } from '@dxos/app-framework';
|
|
9
9
|
import { withPluginManager } from '@dxos/app-framework/testing';
|
|
10
10
|
import { Filter, Obj } from '@dxos/echo';
|
|
11
|
-
import {
|
|
11
|
+
import { useDatabase, useQuery } from '@dxos/react-client/echo';
|
|
12
12
|
import { withClientProvider } from '@dxos/react-client/testing';
|
|
13
13
|
import { Dialog } from '@dxos/react-ui';
|
|
14
14
|
import { withTheme } from '@dxos/react-ui/testing';
|
|
@@ -19,7 +19,7 @@ import { translations } from '../../translations';
|
|
|
19
19
|
|
|
20
20
|
import { CreateObjectDialog, type CreateObjectDialogProps } from './CreateObjectDialog';
|
|
21
21
|
|
|
22
|
-
const
|
|
22
|
+
const DefaultStory = (props: CreateObjectDialogProps) => {
|
|
23
23
|
return (
|
|
24
24
|
<Dialog.Root open>
|
|
25
25
|
<Dialog.Overlay blockAlign='start'>
|
|
@@ -33,53 +33,59 @@ const Story = (props: CreateObjectDialogProps) => {
|
|
|
33
33
|
const meta = {
|
|
34
34
|
title: 'plugins/plugin-space/CreateObjectDialog',
|
|
35
35
|
component: CreateObjectDialog,
|
|
36
|
-
render:
|
|
36
|
+
render: DefaultStory,
|
|
37
37
|
decorators: [
|
|
38
|
-
withTheme, // TODO(wittjosiah): Try to write story which does not depend on plugin manager.
|
|
39
|
-
withPluginManager({
|
|
40
|
-
|
|
38
|
+
withTheme(), // TODO(wittjosiah): Try to write story which does not depend on plugin manager.
|
|
39
|
+
withPluginManager({
|
|
40
|
+
plugins: [RuntimePlugin(), OperationPlugin()],
|
|
41
|
+
}),
|
|
42
|
+
withClientProvider({
|
|
43
|
+
createIdentity: true,
|
|
44
|
+
createSpace: true,
|
|
45
|
+
types: [Collection.Collection],
|
|
46
|
+
}),
|
|
41
47
|
],
|
|
42
48
|
parameters: {
|
|
43
49
|
translations: [...translations, ...shellTranslations],
|
|
44
50
|
},
|
|
45
51
|
args: {},
|
|
46
|
-
} satisfies Meta<typeof
|
|
52
|
+
} satisfies Meta<typeof DefaultStory>;
|
|
47
53
|
|
|
48
54
|
export default meta;
|
|
49
55
|
|
|
50
|
-
|
|
56
|
+
type Story = StoryObj<typeof meta>;
|
|
51
57
|
|
|
52
|
-
export const
|
|
58
|
+
export const Default: Story = {};
|
|
59
|
+
|
|
60
|
+
export const Typename: Story = {
|
|
53
61
|
args: { typename: Collection.Collection.typename },
|
|
54
62
|
};
|
|
55
63
|
|
|
56
|
-
export const TargetSpace:
|
|
64
|
+
export const TargetSpace: Story = {
|
|
57
65
|
render: (args) => {
|
|
58
|
-
const
|
|
66
|
+
const db = useDatabase();
|
|
59
67
|
|
|
60
|
-
if (!
|
|
68
|
+
if (!db) {
|
|
61
69
|
return <></>;
|
|
62
70
|
}
|
|
63
71
|
|
|
64
|
-
return <
|
|
72
|
+
return <DefaultStory {...args} target={db} />;
|
|
65
73
|
},
|
|
66
74
|
};
|
|
67
75
|
|
|
68
|
-
export const TargetCollection:
|
|
76
|
+
export const TargetCollection: Story = {
|
|
69
77
|
render: (args) => {
|
|
70
|
-
const
|
|
71
|
-
const [collection] = useQuery(
|
|
78
|
+
const db = useDatabase();
|
|
79
|
+
const [collection] = useQuery(db, Filter.type(Collection.Collection));
|
|
72
80
|
|
|
73
81
|
useEffect(() => {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
}
|
|
77
|
-
}, [space]);
|
|
82
|
+
db?.add(Obj.make(Collection.Collection, { name: 'My Collection', objects: [] }));
|
|
83
|
+
}, [db]);
|
|
78
84
|
|
|
79
85
|
if (!collection) {
|
|
80
86
|
return <></>;
|
|
81
87
|
}
|
|
82
88
|
|
|
83
|
-
return <
|
|
89
|
+
return <DefaultStory {...args} target={collection} />;
|
|
84
90
|
},
|
|
85
91
|
};
|
|
@@ -3,23 +3,23 @@
|
|
|
3
3
|
//
|
|
4
4
|
|
|
5
5
|
import * as Effect from 'effect/Effect';
|
|
6
|
-
import * as Function from 'effect/Function';
|
|
7
|
-
import * as Option from 'effect/Option';
|
|
8
6
|
import React, { useCallback, useMemo, useRef, useState } from 'react';
|
|
9
7
|
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
8
|
+
import { Capability } from '@dxos/app-framework';
|
|
9
|
+
import { useOperationInvoker, usePluginManager } from '@dxos/app-framework/ui';
|
|
10
|
+
import { AppCapabilities, LayoutOperation } from '@dxos/app-toolkit';
|
|
11
|
+
import { Database, Obj, Type } from '@dxos/echo';
|
|
12
|
+
import { EntityKind, getTypeAnnotation } from '@dxos/echo/internal';
|
|
13
|
+
import { runAndForwardErrors } from '@dxos/effect';
|
|
14
14
|
import { invariant } from '@dxos/invariant';
|
|
15
|
+
import { Operation } from '@dxos/operation';
|
|
15
16
|
import { useClient } from '@dxos/react-client';
|
|
16
|
-
import {
|
|
17
|
-
import { Dialog,
|
|
18
|
-
import { cardDialogContent, cardDialogHeader } from '@dxos/react-ui-stack';
|
|
17
|
+
import { useSpaces } from '@dxos/react-client/echo';
|
|
18
|
+
import { Dialog, useTranslation } from '@dxos/react-ui';
|
|
19
19
|
import { type Collection } from '@dxos/schema';
|
|
20
20
|
|
|
21
21
|
import { meta } from '../../meta';
|
|
22
|
-
import {
|
|
22
|
+
import { SpaceOperation } from '../../types';
|
|
23
23
|
|
|
24
24
|
import { CreateObjectPanel, type CreateObjectPanelProps, type Metadata } from './CreateObjectPanel';
|
|
25
25
|
|
|
@@ -29,8 +29,8 @@ export type CreateObjectDialogProps = Pick<
|
|
|
29
29
|
CreateObjectPanelProps,
|
|
30
30
|
'target' | 'views' | 'typename' | 'initialFormValues'
|
|
31
31
|
> & {
|
|
32
|
-
onCreateObject?: (object: Obj.
|
|
33
|
-
shouldNavigate?: (object: Obj.
|
|
32
|
+
onCreateObject?: (object: Obj.Unknown) => void;
|
|
33
|
+
shouldNavigate?: (object: Obj.Unknown) => boolean;
|
|
34
34
|
};
|
|
35
35
|
|
|
36
36
|
export const CreateObjectDialog = ({
|
|
@@ -43,8 +43,8 @@ export const CreateObjectDialog = ({
|
|
|
43
43
|
}: CreateObjectDialogProps) => {
|
|
44
44
|
const manager = usePluginManager();
|
|
45
45
|
const { t } = useTranslation(meta.id);
|
|
46
|
-
const
|
|
47
|
-
const [target, setTarget] = useState<
|
|
46
|
+
const operationInvoker = useOperationInvoker();
|
|
47
|
+
const [target, setTarget] = useState<Database.Database | Collection.Collection | undefined>(initialTarget);
|
|
48
48
|
const [typename, setTypename] = useState<string | undefined>(initialTypename);
|
|
49
49
|
const client = useClient();
|
|
50
50
|
const spaces = useSpaces();
|
|
@@ -52,23 +52,22 @@ export const CreateObjectDialog = ({
|
|
|
52
52
|
|
|
53
53
|
const resolve = useCallback<NonNullable<CreateObjectPanelProps['resolve']>>(
|
|
54
54
|
(typename) => {
|
|
55
|
-
const metadata = manager.
|
|
56
|
-
.
|
|
55
|
+
const metadata = manager.capabilities
|
|
56
|
+
.getAll(AppCapabilities.Metadata)
|
|
57
57
|
.find(({ id }) => id === typename)?.metadata;
|
|
58
|
-
return metadata?.
|
|
58
|
+
return metadata?.createObject ? (metadata as Metadata) : undefined;
|
|
59
59
|
},
|
|
60
60
|
[manager],
|
|
61
61
|
);
|
|
62
62
|
|
|
63
|
-
const
|
|
63
|
+
const db = Database.isDatabase(target) ? target : target && Obj.getDatabase(target);
|
|
64
64
|
// TODO(wittjosiah): Support database schemas.
|
|
65
|
-
const schemas =
|
|
65
|
+
const schemas = db?.schemaRegistry.query({ location: ['runtime'], includeSystem: false }).runSync();
|
|
66
66
|
const userSchemas = useMemo(
|
|
67
67
|
() =>
|
|
68
68
|
schemas
|
|
69
69
|
?.filter((schema) => getTypeAnnotation(schema)?.kind !== EntityKind.Relation)
|
|
70
|
-
.filter((schema) => !!resolve(Type.getTypename(schema)))
|
|
71
|
-
.filter((schema) => !SystemTypeAnnotation.get(schema).pipe(Option.getOrElse(() => false))) ?? [],
|
|
70
|
+
.filter((schema) => !!resolve(Type.getTypename(schema))) ?? [],
|
|
72
71
|
[schemas],
|
|
73
72
|
);
|
|
74
73
|
|
|
@@ -83,35 +82,39 @@ export const CreateObjectDialog = ({
|
|
|
83
82
|
// NOTE: Must close before navigating or attention won't follow object.
|
|
84
83
|
closeRef.current?.click();
|
|
85
84
|
|
|
86
|
-
const
|
|
87
|
-
invariant(
|
|
88
|
-
const
|
|
89
|
-
if (
|
|
85
|
+
const db = Database.isDatabase(target) ? target : target && Obj.getDatabase(target);
|
|
86
|
+
invariant(db, 'Missing database');
|
|
87
|
+
const object = yield* metadata.createObject(data, { db });
|
|
88
|
+
if (Obj.isObject(object) && !Obj.instanceOf(Type.PersistentType, object)) {
|
|
90
89
|
// TODO(wittjosiah): Selection in navtree isn't working as expected when hidden typenames evals to true.
|
|
91
90
|
const hidden = !metadata.addToCollectionOnCreate;
|
|
92
|
-
|
|
91
|
+
yield* operationInvoker.invoke(SpaceOperation.AddObject, {
|
|
93
92
|
target,
|
|
94
93
|
object,
|
|
95
94
|
hidden,
|
|
96
95
|
});
|
|
97
96
|
const shouldNavigate = _shouldNavigate ?? (() => true);
|
|
98
97
|
if (shouldNavigate(object)) {
|
|
99
|
-
yield*
|
|
100
|
-
|
|
101
|
-
|
|
98
|
+
yield* Effect.promise(() =>
|
|
99
|
+
operationInvoker.invokePromise(LayoutOperation.Open, {
|
|
100
|
+
subject: [Obj.getDXN(object).toString()],
|
|
101
|
+
}),
|
|
102
|
+
);
|
|
102
103
|
}
|
|
103
104
|
|
|
104
105
|
onCreateObject?.(object);
|
|
105
106
|
}
|
|
106
|
-
}).pipe(
|
|
107
|
-
|
|
107
|
+
}).pipe(
|
|
108
|
+
Effect.provideService(Capability.Service, manager.capabilities),
|
|
109
|
+
Effect.provideService(Operation.Service, operationInvoker),
|
|
110
|
+
runAndForwardErrors,
|
|
111
|
+
),
|
|
112
|
+
[target, _shouldNavigate, onCreateObject, manager.capabilities, operationInvoker],
|
|
108
113
|
);
|
|
109
114
|
|
|
110
115
|
return (
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
<Dialog.Content classNames={cardDialogContent}>
|
|
114
|
-
<div role='none' className={cardDialogHeader}>
|
|
116
|
+
<Dialog.Content>
|
|
117
|
+
<Dialog.Header>
|
|
115
118
|
<Dialog.Title>
|
|
116
119
|
{t('create object dialog title', {
|
|
117
120
|
object: t('typename label', {
|
|
@@ -121,32 +124,24 @@ export const CreateObjectDialog = ({
|
|
|
121
124
|
})}
|
|
122
125
|
</Dialog.Title>
|
|
123
126
|
<Dialog.Close asChild>
|
|
124
|
-
<
|
|
125
|
-
ref={closeRef}
|
|
126
|
-
icon='ph--x--regular'
|
|
127
|
-
size={4}
|
|
128
|
-
label='Close'
|
|
129
|
-
iconOnly
|
|
130
|
-
density='fine'
|
|
131
|
-
variant='ghost'
|
|
132
|
-
autoFocus
|
|
133
|
-
/>
|
|
127
|
+
<Dialog.CloseIconButton ref={closeRef} />
|
|
134
128
|
</Dialog.Close>
|
|
135
|
-
</
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
129
|
+
</Dialog.Header>
|
|
130
|
+
<Dialog.Body>
|
|
131
|
+
<CreateObjectPanel
|
|
132
|
+
schemas={userSchemas}
|
|
133
|
+
spaces={spaces}
|
|
134
|
+
target={target}
|
|
135
|
+
views={views}
|
|
136
|
+
typename={typename}
|
|
137
|
+
initialFormValues={initialFormValues}
|
|
138
|
+
defaultSpaceId={client.spaces.default.id}
|
|
139
|
+
resolve={resolve}
|
|
140
|
+
onTargetChange={setTarget}
|
|
141
|
+
onTypenameChange={setTypename}
|
|
142
|
+
onCreateObject={handleCreateObject}
|
|
143
|
+
/>
|
|
144
|
+
</Dialog.Body>
|
|
150
145
|
</Dialog.Content>
|
|
151
146
|
);
|
|
152
147
|
};
|