@dxos/plugin-client 0.7.5-labs.e27f9b9 → 0.7.5-main.2567c87

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 (95) hide show
  1. package/dist/lib/browser/{chunk-PDSHZE3P.mjs → chunk-6IF6PREG.mjs} +7 -11
  2. package/dist/lib/browser/chunk-6IF6PREG.mjs.map +7 -0
  3. package/dist/lib/browser/{chunk-RGMLBYIF.mjs → chunk-R4Q6H7RD.mjs} +2 -2
  4. package/dist/lib/browser/{chunk-RGMLBYIF.mjs.map → chunk-R4Q6H7RD.mjs.map} +2 -2
  5. package/dist/lib/browser/{chunk-MSK3TLIH.mjs → chunk-SVBQRT7I.mjs} +1 -1
  6. package/dist/lib/browser/{chunk-MSK3TLIH.mjs.map → chunk-SVBQRT7I.mjs.map} +2 -2
  7. package/dist/lib/browser/{client-BEJK55IM.mjs → client-25GYH6TN.mjs} +7 -3
  8. package/dist/lib/browser/client-25GYH6TN.mjs.map +7 -0
  9. package/dist/lib/browser/index.mjs +12 -18
  10. package/dist/lib/browser/index.mjs.map +3 -3
  11. package/dist/lib/browser/intent-resolver-IWWLWOZD.mjs +132 -0
  12. package/dist/lib/browser/intent-resolver-IWWLWOZD.mjs.map +7 -0
  13. package/dist/lib/browser/meta.json +1 -1
  14. package/dist/lib/browser/{react-context-PHX2CVI7.mjs → react-context-M3RT6SSG.mjs} +2 -2
  15. package/dist/lib/browser/{react-surface-K5NKVCIB.mjs → react-surface-XXONPG5T.mjs} +5 -5
  16. package/dist/lib/browser/react-surface-XXONPG5T.mjs.map +7 -0
  17. package/dist/lib/node/{chunk-ZI7AV5RP.cjs → chunk-3OB25QN2.cjs} +4 -4
  18. package/dist/lib/node/{chunk-ZI7AV5RP.cjs.map → chunk-3OB25QN2.cjs.map} +2 -2
  19. package/dist/lib/node/{chunk-XPC4JOPP.cjs → chunk-IXVWJCYB.cjs} +5 -5
  20. package/dist/lib/node/{chunk-XPC4JOPP.cjs.map → chunk-IXVWJCYB.cjs.map} +2 -2
  21. package/dist/lib/node/{chunk-VUJ3ZPK3.cjs → chunk-N3U7KVO3.cjs} +10 -14
  22. package/dist/lib/node/chunk-N3U7KVO3.cjs.map +7 -0
  23. package/dist/lib/node/{client-AHIW24VM.cjs → client-52L4TUYU.cjs} +12 -8
  24. package/dist/lib/node/client-52L4TUYU.cjs.map +7 -0
  25. package/dist/lib/node/index.cjs +14 -20
  26. package/dist/lib/node/index.cjs.map +3 -3
  27. package/dist/lib/node/intent-resolver-H3Y64MIP.cjs +140 -0
  28. package/dist/lib/node/intent-resolver-H3Y64MIP.cjs.map +7 -0
  29. package/dist/lib/node/meta.json +1 -1
  30. package/dist/lib/node/{react-context-WMOFXPT4.cjs → react-context-B2DNULH4.cjs} +6 -6
  31. package/dist/lib/node/{react-surface-YQ2PKXNV.cjs → react-surface-7USN5NOO.cjs} +15 -15
  32. package/dist/lib/node/react-surface-7USN5NOO.cjs.map +7 -0
  33. package/dist/lib/node-esm/{chunk-QR72BXJK.mjs → chunk-73M5MK5Q.mjs} +2 -2
  34. package/dist/lib/node-esm/{chunk-QR72BXJK.mjs.map → chunk-73M5MK5Q.mjs.map} +2 -2
  35. package/dist/lib/node-esm/{chunk-WS4CKCUR.mjs → chunk-EHGD3UJH.mjs} +7 -11
  36. package/dist/lib/node-esm/chunk-EHGD3UJH.mjs.map +7 -0
  37. package/dist/lib/node-esm/{chunk-B73LKPGU.mjs → chunk-OBGRL3DF.mjs} +1 -1
  38. package/dist/lib/node-esm/{chunk-B73LKPGU.mjs.map → chunk-OBGRL3DF.mjs.map} +2 -2
  39. package/dist/lib/node-esm/{client-FY7IDNRL.mjs → client-K52NWOUN.mjs} +7 -3
  40. package/dist/lib/node-esm/client-K52NWOUN.mjs.map +7 -0
  41. package/dist/lib/node-esm/index.mjs +12 -18
  42. package/dist/lib/node-esm/index.mjs.map +3 -3
  43. package/dist/lib/node-esm/intent-resolver-JCKD6R6L.mjs +133 -0
  44. package/dist/lib/node-esm/intent-resolver-JCKD6R6L.mjs.map +7 -0
  45. package/dist/lib/node-esm/meta.json +1 -1
  46. package/dist/lib/node-esm/{react-context-EEGDXBWA.mjs → react-context-IGEHJQK5.mjs} +2 -2
  47. package/dist/lib/node-esm/{react-surface-H34XQPWC.mjs → react-surface-CXLBCMPN.mjs} +5 -5
  48. package/dist/lib/node-esm/react-surface-CXLBCMPN.mjs.map +7 -0
  49. package/dist/types/src/ClientPlugin.d.ts.map +1 -1
  50. package/dist/types/src/capabilities/app-graph-builder.d.ts +22 -22
  51. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  52. package/dist/types/src/capabilities/capabilities.d.ts.map +1 -1
  53. package/dist/types/src/capabilities/client.d.ts.map +1 -1
  54. package/dist/types/src/capabilities/index.d.ts +29 -30
  55. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  56. package/dist/types/src/capabilities/intent-resolver.d.ts.map +1 -1
  57. package/dist/types/src/events.d.ts +1 -1
  58. package/package.json +16 -17
  59. package/src/ClientPlugin.ts +5 -10
  60. package/src/capabilities/capabilities.ts +0 -1
  61. package/src/capabilities/client.ts +6 -0
  62. package/src/capabilities/index.ts +0 -1
  63. package/src/capabilities/intent-resolver.ts +66 -95
  64. package/src/capabilities/react-surface.tsx +6 -6
  65. package/src/components/IdentityDialog.tsx +3 -3
  66. package/src/components/JoinDialog.tsx +1 -1
  67. package/src/components/RecoveryCodeDialog.stories.tsx +2 -2
  68. package/src/events.ts +1 -1
  69. package/dist/lib/browser/chunk-PDSHZE3P.mjs.map +0 -7
  70. package/dist/lib/browser/client-BEJK55IM.mjs.map +0 -7
  71. package/dist/lib/browser/intent-resolver-E6TL7E24.mjs +0 -159
  72. package/dist/lib/browser/intent-resolver-E6TL7E24.mjs.map +0 -7
  73. package/dist/lib/browser/react-surface-K5NKVCIB.mjs.map +0 -7
  74. package/dist/lib/browser/schema-AL34NY2M.mjs +0 -33
  75. package/dist/lib/browser/schema-AL34NY2M.mjs.map +0 -7
  76. package/dist/lib/node/chunk-VUJ3ZPK3.cjs.map +0 -7
  77. package/dist/lib/node/client-AHIW24VM.cjs.map +0 -7
  78. package/dist/lib/node/intent-resolver-DUPICQ3F.cjs +0 -167
  79. package/dist/lib/node/intent-resolver-DUPICQ3F.cjs.map +0 -7
  80. package/dist/lib/node/react-surface-YQ2PKXNV.cjs.map +0 -7
  81. package/dist/lib/node/schema-HW4W3QYU.cjs +0 -49
  82. package/dist/lib/node/schema-HW4W3QYU.cjs.map +0 -7
  83. package/dist/lib/node-esm/chunk-WS4CKCUR.mjs.map +0 -7
  84. package/dist/lib/node-esm/client-FY7IDNRL.mjs.map +0 -7
  85. package/dist/lib/node-esm/intent-resolver-QUQH2LS2.mjs +0 -160
  86. package/dist/lib/node-esm/intent-resolver-QUQH2LS2.mjs.map +0 -7
  87. package/dist/lib/node-esm/react-surface-H34XQPWC.mjs.map +0 -7
  88. package/dist/lib/node-esm/schema-74LVJ3EU.mjs +0 -34
  89. package/dist/lib/node-esm/schema-74LVJ3EU.mjs.map +0 -7
  90. package/dist/types/src/capabilities/schema.d.ts +0 -4
  91. package/dist/types/src/capabilities/schema.d.ts.map +0 -1
  92. package/src/capabilities/schema.ts +0 -36
  93. /package/dist/lib/browser/{react-context-PHX2CVI7.mjs.map → react-context-M3RT6SSG.mjs.map} +0 -0
  94. /package/dist/lib/node/{react-context-WMOFXPT4.cjs.map → react-context-B2DNULH4.cjs.map} +0 -0
  95. /package/dist/lib/node-esm/{react-context-EEGDXBWA.mjs.map → react-context-IGEHJQK5.mjs.map} +0 -0
package/src/events.ts CHANGED
@@ -7,8 +7,8 @@ import { defineEvent } from '@dxos/app-framework';
7
7
  import { CLIENT_PLUGIN } from './meta';
8
8
 
9
9
  export namespace ClientEvents {
10
+ export const SetupClient = defineEvent(`${CLIENT_PLUGIN}/event/setup-client`);
10
11
  export const ClientReady = defineEvent(`${CLIENT_PLUGIN}/event/client-ready`);
11
- export const SetupSchema = defineEvent(`${CLIENT_PLUGIN}/event/setup-schema`);
12
12
  export const IdentityCreated = defineEvent(`${CLIENT_PLUGIN}/event/identity-created`);
13
13
  export const SpacesReady = defineEvent(`${CLIENT_PLUGIN}/event/spaces-ready`);
14
14
  }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/components/IdentityDialog.tsx", "../../../src/components/JoinDialog.tsx", "../../../src/components/RecoveryCodeDialog.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback } from 'react';\n\nimport { createIntent, LayoutAction, useIntentDispatcher } from '@dxos/app-framework';\nimport { useClient } from '@dxos/react-client';\nimport { Clipboard, Dialog } from '@dxos/react-ui';\nimport { IdentityPanel, type IdentityPanelProps } from '@dxos/shell/react';\n\nimport { CLIENT_PLUGIN } from '../meta';\nimport { ClientAction } from '../types';\n\nexport const IDENTITY_DIALOG = `${CLIENT_PLUGIN}/IdentityDialog`;\n\nexport const IdentityDialog = (props: IdentityPanelProps) => {\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n const client = useClient();\n\n const handleDone = useCallback(\n () =>\n dispatch(\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n options: { state: false },\n }),\n ),\n [dispatch],\n );\n\n const handleResetStorage = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage));\n }, [dispatch]);\n\n const handleRecover = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage, { target: 'recoverIdentity' }));\n }, [dispatch]);\n\n const handleJoinNewIdentity = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage, { target: 'deviceInvitation' }));\n }, [dispatch]);\n\n return (\n <Dialog.Content>\n <Clipboard.Provider>\n <IdentityPanel\n {...props}\n doneActionParent={<Dialog.Close asChild />}\n onDone={handleDone}\n onResetStorage={handleResetStorage}\n onRecover={handleRecover}\n onJoinNewIdentity={handleJoinNewIdentity}\n />\n </Clipboard.Provider>\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback } from 'react';\n\nimport { createIntent, LayoutAction, useIntentDispatcher } from '@dxos/app-framework';\nimport { ObservabilityAction } from '@dxos/plugin-observability/types';\nimport { type InvitationResult } from '@dxos/react-client/invitations';\nimport { Dialog } from '@dxos/react-ui';\nimport { JoinPanel, type JoinPanelProps } from '@dxos/shell/react';\n\nimport { CLIENT_PLUGIN } from '../meta';\nimport { ClientAction } from '../types';\n\nexport const JOIN_DIALOG = `${CLIENT_PLUGIN}/JoinDialog`;\n\nexport const JoinDialog = (props: JoinPanelProps) => {\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n\n const handleCancelResetStorage = useCallback(() => dispatch(createIntent(ClientAction.ShareIdentity)), [dispatch]);\n\n const handleDone = useCallback(\n async (result: InvitationResult | null) => {\n if (result?.identityKey) {\n await Promise.all([\n dispatch(createIntent(LayoutAction.UpdateDialog, { part: 'dialog', options: { state: false } })),\n dispatch(\n createIntent(ObservabilityAction.SendEvent, {\n name: props.initialDisposition === 'recover-identity' ? 'identity.recover' : 'identity.join',\n }),\n ),\n ]);\n }\n },\n [dispatch],\n );\n\n return (\n <Dialog.Content>\n <JoinPanel\n mode='halo-only'\n {...props}\n exitActionParent={<Dialog.Close asChild />}\n doneActionParent={<Dialog.Close asChild />}\n onCancelResetStorage={handleCancelResetStorage}\n onDone={handleDone}\n />\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback, useState } from 'react';\n\nimport { AlertDialog, Button, Clipboard, Input, useTranslation } from '@dxos/react-ui';\n\nimport { CLIENT_PLUGIN } from '../meta';\n\nexport const RECOVER_CODE_DIALOG = `${CLIENT_PLUGIN}/RecoveryCodeDialog`;\n\nexport type RecoveryCodeDialogProps = {\n code: string;\n};\n\nexport const RecoveryCodeDialog = ({ code }: RecoveryCodeDialogProps) => {\n const { t } = useTranslation(CLIENT_PLUGIN);\n const [confirmation, setConfirmation] = useState(false);\n\n const handleConfirmation = useCallback((checked: boolean) => setConfirmation(checked), []);\n\n return (\n <AlertDialog.Content classNames='bs-content min-bs-[15rem] max-bs-full md:max-is-[40rem] overflow-hidden'>\n <AlertDialog.Title>{t('recovery code dialog title')}</AlertDialog.Title>\n <p className='py-4'>{t('recovery code dialog description')}</p>\n <Clipboard.Provider>\n <Code code={code} />\n </Clipboard.Provider>\n <div className='flex flex-col py-4 gap-2'>\n <p>{t('recovery code dialog warning 1')}</p>\n <p>{t('recovery code dialog warning 2')}</p>\n </div>\n <div className='flex items-center gap-2 pbe-4'>\n <Input.Root>\n <Input.Checkbox\n data-testid='recoveryCode.confirm'\n checked={confirmation}\n onCheckedChange={handleConfirmation}\n />\n <Input.Label>{t('recovery code confirmation label')}</Input.Label>\n </Input.Root>\n </div>\n <div className='flex justify-end'>\n <AlertDialog.Action asChild>\n <Button data-testid='recoveryCode.continue' variant='primary' disabled={!confirmation}>\n {t('continue label')}\n </Button>\n </AlertDialog.Action>\n </div>\n </AlertDialog.Content>\n );\n};\n\nconst Code = ({ code }: { code: string }) => {\n const words = code.split(' ');\n return (\n <div className='relative p-2 border border-separator rounded group'>\n <Clipboard.IconButton value={code} classNames='absolute top-2 right-2 invisible group-hover:visible' />\n <div className='grid grid-cols-4'>\n {words.map((word, i) => (\n <div key={i} className='flex items-center p-2 gap-2 items-center'>\n <div className='w-4 text-xs text-center text-subdued'>{i + 1}</div>\n <div className='text-sm'>{word}</div>\n </div>\n ))}\n </div>\n </div>\n );\n};\n"],
5
- "mappings": ";;;;;;;;AAIA,OAAOA,SAASC,mBAAmB;AAEnC,SAASC,cAAcC,cAAcC,2BAA2B;AAChE,SAASC,iBAAiB;AAC1B,SAASC,WAAWC,cAAc;AAClC,SAASC,qBAA8C;AAKhD,IAAMC,kBAAkB,GAAGC,aAAAA;AAE3B,IAAMC,iBAAiB,CAACC,UAAAA;AAC7B,QAAM,EAAEC,iBAAiBC,SAAQ,IAAKC,oBAAAA;AACt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AA;AAMtC;",
6
- "names": ["React", "useCallback", "createIntent", "LayoutAction", "useIntentDispatcher", "useClient", "Clipboard", "Dialog", "IdentityPanel", "IDENTITY_DIALOG", "CLIENT_PLUGIN", "IdentityDialog", "props", "dispatchPromise", "dispatch", "useIntentDispatcher", "client", "useClient", "handleDone", "useCallback", "createIntent", "LayoutAction", "UpdateDialog", "part", "options", "state", "handleResetStorage", "reset", "ClientAction", "ResetStorage", "handleRecover", "target", "handleJoinNewIdentity", "Dialog", "Content", "Clipboard", "Provider", "IdentityPanel", "doneActionParent", "Close", "asChild", "onDone", "onResetStorage", "onRecover", "onJoinNewIdentity", "React", "useCallback", "createIntent", "LayoutAction", "useIntentDispatcher", "ObservabilityAction", "Dialog", "JoinPanel", "JOIN_DIALOG", "CLIENT_PLUGIN", "JoinDialog", "props", "dispatchPromise", "dispatch", "useIntentDispatcher", "handleCancelResetStorage", "useCallback", "createIntent", "ClientAction", "ShareIdentity", "handleDone", "result", "identityKey", "Promise", "all", "LayoutAction", "UpdateDialog", "part", "options", "state", "ObservabilityAction", "SendEvent", "name", "initialDisposition", "React", "Dialog", "Content", "JoinPanel", "mode", "exitActionParent", "Close", "asChild", "doneActionParent", "onCancelResetStorage", "onDone", "React", "useCallback", "useState", "AlertDialog", "Button", "Clipboard", "Input", "useTranslation", "RECOVER_CODE_DIALOG", "CLIENT_PLUGIN", "RecoveryCodeDialog", "code", "t", "useTranslation", "confirmation", "setConfirmation", "useState", "handleConfirmation", "useCallback", "checked", "React", "AlertDialog", "Content", "classNames", "Title", "p", "className", "Clipboard", "Provider", "Code", "div", "Input", "Root", "Checkbox", "data-testid", "onCheckedChange", "Label", "Action", "asChild", "Button", "variant", "disabled", "words", "split", "IconButton", "value", "map", "word", "i", "key"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/client.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { contributes, type PluginsContext } from '@dxos/app-framework';\nimport { Config, Defaults, Envs, Local, Storage } from '@dxos/config';\nimport { Client } from '@dxos/react-client';\n\nimport { ClientCapabilities } from './capabilities';\nimport { ClientEvents } from '../events';\nimport { type ClientPluginOptions } from '../types';\n\ntype ClientCapabilityOptions = Omit<ClientPluginOptions, 'appKey' | 'invitationUrl' | 'invitationParam' | 'onReset'> & {\n context: PluginsContext;\n};\n\nexport default async ({ context, onClientInitialized, ...options }: ClientCapabilityOptions) => {\n const config = new Config(await Storage(), Envs(), Local(), Defaults());\n const client = new Client({ config, ...options });\n await client.initialize();\n await onClientInitialized?.(context, client);\n\n // TODO(wittjosiah): Remove. This is a hack to get the app to boot with the new identity after a reset.\n client.reloaded.on(() => {\n client.halo.identity.subscribe(async (identity) => {\n if (identity) {\n window.location.href = window.location.origin;\n }\n });\n });\n\n const subscription = client.spaces.isReady.subscribe(async (ready) => {\n if (ready) {\n await context.activate(ClientEvents.SpacesReady);\n }\n });\n\n return contributes(ClientCapabilities.Client, client, async () => {\n subscription.unsubscribe();\n await client.destroy();\n });\n};\n"],
5
- "mappings": ";;;;;;;;;AAIA,SAASA,mBAAwC;AACjD,SAASC,QAAQC,UAAUC,MAAMC,OAAOC,eAAe;AACvD,SAASC,cAAc;AAUvB,IAAA,iBAAe,OAAO,EAAEC,SAASC,qBAAqB,GAAGC,QAAAA,MAAkC;AACzF,QAAMC,SAAS,IAAIC,OAAO,MAAMC,QAAAA,GAAWC,KAAAA,GAAQC,MAAAA,GAASC,SAAAA,CAAAA;AAC5D,QAAMC,SAAS,IAAIC,OAAO;IAAEP;IAAQ,GAAGD;EAAQ,CAAA;AAC/C,QAAMO,OAAOE,WAAU;AACvB,QAAMV,sBAAsBD,SAASS,MAAAA;AAGrCA,SAAOG,SAASC,GAAG,MAAA;AACjBJ,WAAOK,KAAKC,SAASC,UAAU,OAAOD,aAAAA;AACpC,UAAIA,UAAU;AACZE,eAAOC,SAASC,OAAOF,OAAOC,SAASE;MACzC;IACF,CAAA;EACF,CAAA;AAEA,QAAMC,eAAeZ,OAAOa,OAAOC,QAAQP,UAAU,OAAOQ,UAAAA;AAC1D,QAAIA,OAAO;AACT,YAAMxB,QAAQyB,SAASC,aAAaC,WAAW;IACjD;EACF,CAAA;AAEA,SAAOC,YAAYC,mBAAmBnB,QAAQD,QAAQ,YAAA;AACpDY,iBAAaS,YAAW;AACxB,UAAMrB,OAAOsB,QAAO;EACtB,CAAA;AACF;",
6
- "names": ["contributes", "Config", "Defaults", "Envs", "Local", "Storage", "Client", "context", "onClientInitialized", "options", "config", "Config", "Storage", "Envs", "Local", "Defaults", "client", "Client", "initialize", "reloaded", "on", "halo", "identity", "subscribe", "window", "location", "href", "origin", "subscription", "spaces", "isReady", "ready", "activate", "ClientEvents", "SpacesReady", "contributes", "ClientCapabilities", "unsubscribe", "destroy"]
7
- }
@@ -1,159 +0,0 @@
1
- import {
2
- ClientEvents
3
- } from "./chunk-RGMLBYIF.mjs";
4
- import {
5
- IDENTITY_DIALOG,
6
- JOIN_DIALOG,
7
- RECOVER_CODE_DIALOG
8
- } from "./chunk-PDSHZE3P.mjs";
9
- import {
10
- ClientAction
11
- } from "./chunk-E3OUNOEL.mjs";
12
- import {
13
- ClientCapabilities
14
- } from "./chunk-MSK3TLIH.mjs";
15
- import "./chunk-NHIL4T3L.mjs";
16
-
17
- // packages/plugins/plugin-client/src/capabilities/intent-resolver.ts
18
- import { Capabilities, contributes, createIntent, createResolver, LayoutAction } from "@dxos/app-framework";
19
- import { invariant } from "@dxos/invariant";
20
- import { ObservabilityAction } from "@dxos/plugin-observability/types";
21
- var __dxlog_file = "/home/runner/work/dxos/dxos/packages/plugins/plugin-client/src/capabilities/intent-resolver.ts";
22
- var intent_resolver_default = ({ context, onReset }) => contributes(Capabilities.IntentResolver, [
23
- createResolver({
24
- intent: ClientAction.CreateIdentity,
25
- resolve: async () => {
26
- const manager = context.requestCapability(Capabilities.PluginManager);
27
- const client = context.requestCapability(ClientCapabilities.Client);
28
- const data = await client.halo.createIdentity();
29
- await manager.activate(ClientEvents.IdentityCreated);
30
- return {
31
- data,
32
- intents: [
33
- createIntent(ObservabilityAction.SendEvent, {
34
- name: "identity.create"
35
- })
36
- ]
37
- };
38
- }
39
- }),
40
- createResolver({
41
- intent: ClientAction.JoinIdentity,
42
- resolve: async (data) => {
43
- return {
44
- intents: [
45
- createIntent(LayoutAction.UpdateDialog, {
46
- part: "dialog",
47
- subject: JOIN_DIALOG,
48
- options: {
49
- blockAlign: "start",
50
- props: {
51
- initialInvitationCode: data.invitationCode,
52
- initialDisposition: "accept-halo-invitation"
53
- }
54
- }
55
- })
56
- ]
57
- };
58
- }
59
- }),
60
- createResolver({
61
- intent: ClientAction.ShareIdentity,
62
- resolve: async () => {
63
- return {
64
- intents: [
65
- createIntent(LayoutAction.UpdateDialog, {
66
- part: "dialog",
67
- subject: IDENTITY_DIALOG,
68
- options: {
69
- blockAlign: "start"
70
- }
71
- }),
72
- createIntent(ObservabilityAction.SendEvent, {
73
- name: "identity.share"
74
- })
75
- ]
76
- };
77
- }
78
- }),
79
- createResolver({
80
- intent: ClientAction.RecoverIdentity,
81
- resolve: async () => {
82
- return {
83
- intents: [
84
- createIntent(LayoutAction.UpdateDialog, {
85
- part: "dialog",
86
- subject: JOIN_DIALOG,
87
- options: {
88
- blockAlign: "start",
89
- props: {
90
- initialDisposition: "recover-identity"
91
- }
92
- }
93
- })
94
- ]
95
- };
96
- }
97
- }),
98
- createResolver({
99
- intent: ClientAction.ResetStorage,
100
- resolve: async (data) => {
101
- await onReset?.({
102
- target: data.target
103
- });
104
- }
105
- }),
106
- createResolver({
107
- intent: ClientAction.CreateAgent,
108
- resolve: async () => {
109
- const client = context.requestCapability(ClientCapabilities.Client);
110
- invariant(client.services.services.EdgeAgentService, "Missing EdgeAgentService", {
111
- F: __dxlog_file,
112
- L: 104,
113
- S: void 0,
114
- A: [
115
- "client.services.services.EdgeAgentService",
116
- "'Missing EdgeAgentService'"
117
- ]
118
- });
119
- await client.services.services.EdgeAgentService.createAgent(null, {
120
- timeout: 1e4
121
- });
122
- }
123
- }),
124
- createResolver({
125
- intent: ClientAction.CreateRecoveryCode,
126
- resolve: async () => {
127
- const client = context.requestCapability(ClientCapabilities.Client);
128
- invariant(client.services.services.IdentityService, "IdentityService not available", {
129
- F: __dxlog_file,
130
- L: 112,
131
- S: void 0,
132
- A: [
133
- "client.services.services.IdentityService",
134
- "'IdentityService not available'"
135
- ]
136
- });
137
- const { recoveryCode } = await client.services.services.IdentityService.createRecoveryCredential({});
138
- return {
139
- intents: [
140
- createIntent(LayoutAction.UpdateDialog, {
141
- part: "dialog",
142
- subject: RECOVER_CODE_DIALOG,
143
- options: {
144
- blockAlign: "start",
145
- type: "alert",
146
- props: {
147
- code: recoveryCode
148
- }
149
- }
150
- })
151
- ]
152
- };
153
- }
154
- })
155
- ]);
156
- export {
157
- intent_resolver_default as default
158
- };
159
- //# sourceMappingURL=intent-resolver-E6TL7E24.mjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/intent-resolver.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport {\n Capabilities,\n contributes,\n createIntent,\n createResolver,\n LayoutAction,\n type PluginsContext,\n} from '@dxos/app-framework';\nimport { invariant } from '@dxos/invariant';\nimport { ObservabilityAction } from '@dxos/plugin-observability/types';\nimport { type JoinPanelProps } from '@dxos/shell/react';\n\nimport { ClientCapabilities } from './capabilities';\nimport { IDENTITY_DIALOG, JOIN_DIALOG, RECOVER_CODE_DIALOG } from '../components';\nimport { ClientEvents } from '../events';\nimport { ClientAction, type ClientPluginOptions } from '../types';\n\ntype IntentResolverOptions = Pick<ClientPluginOptions, 'onReset'> & {\n context: PluginsContext;\n};\n\nexport default ({ context, onReset }: IntentResolverOptions) =>\n contributes(Capabilities.IntentResolver, [\n createResolver({\n intent: ClientAction.CreateIdentity,\n resolve: async () => {\n const manager = context.requestCapability(Capabilities.PluginManager);\n const client = context.requestCapability(ClientCapabilities.Client);\n const data = await client.halo.createIdentity();\n await manager.activate(ClientEvents.IdentityCreated);\n return { data, intents: [createIntent(ObservabilityAction.SendEvent, { name: 'identity.create' })] };\n },\n }),\n createResolver({\n intent: ClientAction.JoinIdentity,\n resolve: async (data) => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: JOIN_DIALOG,\n options: {\n blockAlign: 'start',\n props: {\n initialInvitationCode: data.invitationCode,\n initialDisposition: 'accept-halo-invitation',\n },\n },\n }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.ShareIdentity,\n resolve: async () => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: IDENTITY_DIALOG,\n options: {\n blockAlign: 'start',\n },\n }),\n createIntent(ObservabilityAction.SendEvent, { name: 'identity.share' }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.RecoverIdentity,\n resolve: async () => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: JOIN_DIALOG,\n options: {\n blockAlign: 'start',\n props: {\n initialDisposition: 'recover-identity',\n } satisfies Partial<JoinPanelProps>,\n },\n }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.ResetStorage,\n resolve: async (data) => {\n await onReset?.({ target: data.target });\n },\n }),\n createResolver({\n intent: ClientAction.CreateAgent,\n resolve: async () => {\n const client = context.requestCapability(ClientCapabilities.Client);\n invariant(client.services.services.EdgeAgentService, 'Missing EdgeAgentService');\n await client.services.services.EdgeAgentService.createAgent(null as any, { timeout: 10_000 });\n },\n }),\n createResolver({\n intent: ClientAction.CreateRecoveryCode,\n resolve: async () => {\n const client = context.requestCapability(ClientCapabilities.Client);\n invariant(client.services.services.IdentityService, 'IdentityService not available');\n // TODO(wittjosiah): This needs a proper api.\n const { recoveryCode } = await client.services.services.IdentityService.createRecoveryCredential({});\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: RECOVER_CODE_DIALOG,\n options: {\n blockAlign: 'start',\n type: 'alert',\n props: { code: recoveryCode },\n },\n }),\n ],\n };\n },\n }),\n ]);\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;AAIA,SACEA,cACAC,aACAC,cACAC,gBACAC,oBAEK;AACP,SAASC,iBAAiB;AAC1B,SAASC,2BAA2B;;AAYpC,IAAA,0BAAe,CAAC,EAAEC,SAASC,QAAO,MAChCC,YAAYC,aAAaC,gBAAgB;EACvCC,eAAe;IACbC,QAAQC,aAAaC;IACrBC,SAAS,YAAA;AACP,YAAMC,UAAUV,QAAQW,kBAAkBR,aAAaS,aAAa;AACpE,YAAMC,SAASb,QAAQW,kBAAkBG,mBAAmBC,MAAM;AAClE,YAAMC,OAAO,MAAMH,OAAOI,KAAKC,eAAc;AAC7C,YAAMR,QAAQS,SAASC,aAAaC,eAAe;AACnD,aAAO;QAAEL;QAAMM,SAAS;UAACC,aAAaC,oBAAoBC,WAAW;YAAEC,MAAM;UAAkB,CAAA;;MAAI;IACrG;EACF,CAAA;EACArB,eAAe;IACbC,QAAQC,aAAaoB;IACrBlB,SAAS,OAAOO,SAAAA;AACd,aAAO;QACLM,SAAS;UACPC,aAAaK,aAAaC,cAAc;YACtCC,MAAM;YACNC,SAASC;YACTC,SAAS;cACPC,YAAY;cACZC,OAAO;gBACLC,uBAAuBpB,KAAKqB;gBAC5BC,oBAAoB;cACtB;YACF;UACF,CAAA;;MAEJ;IACF;EACF,CAAA;EACAjC,eAAe;IACbC,QAAQC,aAAagC;IACrB9B,SAAS,YAAA;AACP,aAAO;QACLa,SAAS;UACPC,aAAaK,aAAaC,cAAc;YACtCC,MAAM;YACNC,SAASS;YACTP,SAAS;cACPC,YAAY;YACd;UACF,CAAA;UACAX,aAAaC,oBAAoBC,WAAW;YAAEC,MAAM;UAAiB,CAAA;;MAEzE;IACF;EACF,CAAA;EACArB,eAAe;IACbC,QAAQC,aAAakC;IACrBhC,SAAS,YAAA;AACP,aAAO;QACLa,SAAS;UACPC,aAAaK,aAAaC,cAAc;YACtCC,MAAM;YACNC,SAASC;YACTC,SAAS;cACPC,YAAY;cACZC,OAAO;gBACLG,oBAAoB;cACtB;YACF;UACF,CAAA;;MAEJ;IACF;EACF,CAAA;EACAjC,eAAe;IACbC,QAAQC,aAAamC;IACrBjC,SAAS,OAAOO,SAAAA;AACd,YAAMf,UAAU;QAAE0C,QAAQ3B,KAAK2B;MAAO,CAAA;IACxC;EACF,CAAA;EACAtC,eAAe;IACbC,QAAQC,aAAaqC;IACrBnC,SAAS,YAAA;AACP,YAAMI,SAASb,QAAQW,kBAAkBG,mBAAmBC,MAAM;AAClE8B,gBAAUhC,OAAOiC,SAASA,SAASC,kBAAkB,4BAAA;;;;;;;;;AACrD,YAAMlC,OAAOiC,SAASA,SAASC,iBAAiBC,YAAY,MAAa;QAAEC,SAAS;MAAO,CAAA;IAC7F;EACF,CAAA;EACA5C,eAAe;IACbC,QAAQC,aAAa2C;IACrBzC,SAAS,YAAA;AACP,YAAMI,SAASb,QAAQW,kBAAkBG,mBAAmBC,MAAM;AAClE8B,gBAAUhC,OAAOiC,SAASA,SAASK,iBAAiB,iCAAA;;;;;;;;;AAEpD,YAAM,EAAEC,aAAY,IAAK,MAAMvC,OAAOiC,SAASA,SAASK,gBAAgBE,yBAAyB,CAAC,CAAA;AAClG,aAAO;QACL/B,SAAS;UACPC,aAAaK,aAAaC,cAAc;YACtCC,MAAM;YACNC,SAASuB;YACTrB,SAAS;cACPC,YAAY;cACZqB,MAAM;cACNpB,OAAO;gBAAEqB,MAAMJ;cAAa;YAC9B;UACF,CAAA;;MAEJ;IACF;EACF,CAAA;CACD;",
6
- "names": ["Capabilities", "contributes", "createIntent", "createResolver", "LayoutAction", "invariant", "ObservabilityAction", "context", "onReset", "contributes", "Capabilities", "IntentResolver", "createResolver", "intent", "ClientAction", "CreateIdentity", "resolve", "manager", "requestCapability", "PluginManager", "client", "ClientCapabilities", "Client", "data", "halo", "createIdentity", "activate", "ClientEvents", "IdentityCreated", "intents", "createIntent", "ObservabilityAction", "SendEvent", "name", "JoinIdentity", "LayoutAction", "UpdateDialog", "part", "subject", "JOIN_DIALOG", "options", "blockAlign", "props", "initialInvitationCode", "invitationCode", "initialDisposition", "ShareIdentity", "IDENTITY_DIALOG", "RecoverIdentity", "ResetStorage", "target", "CreateAgent", "invariant", "services", "EdgeAgentService", "createAgent", "timeout", "CreateRecoveryCode", "IdentityService", "recoveryCode", "createRecoveryCredential", "RECOVER_CODE_DIALOG", "type", "code"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/react-surface.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { createSurface, Capabilities, contributes } from '@dxos/app-framework';\nimport { type IdentityPanelProps, type JoinPanelProps } from '@dxos/shell/react';\n\nimport {\n IDENTITY_DIALOG,\n IdentityDialog,\n JOIN_DIALOG,\n JoinDialog,\n RECOVER_CODE_DIALOG,\n RecoveryCodeDialog,\n type RecoveryCodeDialogProps,\n} from '../components';\n\ntype ReactSurfaceOptions = {\n createInvitationUrl: (invitationCode: string) => string;\n};\n\nexport default ({ createInvitationUrl }: ReactSurfaceOptions) =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: IDENTITY_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: IdentityPanelProps } => data.component === IDENTITY_DIALOG,\n component: ({ data }) => <IdentityDialog {...data.props} createInvitationUrl={createInvitationUrl} />,\n }),\n createSurface({\n id: JOIN_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: JoinPanelProps } => data.component === JOIN_DIALOG,\n component: ({ data }) => <JoinDialog {...data.props} />,\n }),\n createSurface({\n id: RECOVER_CODE_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: RecoveryCodeDialogProps } => data.component === RECOVER_CODE_DIALOG,\n component: ({ data }) => <RecoveryCodeDialog {...data.props} />,\n }),\n ]);\n"],
5
- "mappings": ";;;;;;;;;;;;AAIA,OAAOA,WAAW;AAElB,SAASC,eAAeC,cAAcC,mBAAmB;AAiBzD,IAAA,wBAAe,CAAC,EAAEC,oBAAmB,MACnCC,YAAYC,aAAaC,cAAc;EACrCC,cAAc;IACZC,IAAIC;IACJC,MAAM;IACNC,QAAQ,CAACC,SAAgDA,KAAKC,cAAcJ;IAC5EI,WAAW,CAAC,EAAED,KAAI,MAAO,sBAAA,cAACE,gBAAAA;MAAgB,GAAGF,KAAKG;MAAOZ;;EAC3D,CAAA;EACAI,cAAc;IACZC,IAAIQ;IACJN,MAAM;IACNC,QAAQ,CAACC,SAA4CA,KAAKC,cAAcG;IACxEH,WAAW,CAAC,EAAED,KAAI,MAAO,sBAAA,cAACK,YAAeL,KAAKG,KAAK;EACrD,CAAA;EACAR,cAAc;IACZC,IAAIU;IACJR,MAAM;IACNC,QAAQ,CAACC,SAAqDA,KAAKC,cAAcK;IACjFL,WAAW,CAAC,EAAED,KAAI,MAAO,sBAAA,cAACO,oBAAuBP,KAAKG,KAAK;EAC7D,CAAA;CACD;",
6
- "names": ["React", "createSurface", "Capabilities", "contributes", "createInvitationUrl", "contributes", "Capabilities", "ReactSurface", "createSurface", "id", "IDENTITY_DIALOG", "role", "filter", "data", "component", "IdentityDialog", "props", "JOIN_DIALOG", "JoinDialog", "RECOVER_CODE_DIALOG", "RecoveryCodeDialog"]
7
- }
@@ -1,33 +0,0 @@
1
- import {
2
- ClientCapabilities
3
- } from "./chunk-MSK3TLIH.mjs";
4
- import "./chunk-NHIL4T3L.mjs";
5
-
6
- // packages/plugins/plugin-client/src/capabilities/schema.ts
7
- import { effect } from "@preact/signals-core";
8
- import { Capabilities, contributes } from "@dxos/app-framework";
9
- var schema_default = (context) => {
10
- const client = context.requestCapability(ClientCapabilities.Client);
11
- let previousSystem = [];
12
- const unsubscribeSystem = effect(() => {
13
- const systemSchemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.SystemSchema).flat()));
14
- const newSchemas = systemSchemas.filter((schema) => !previousSystem.includes(schema));
15
- previousSystem = systemSchemas;
16
- client.addTypes(newSchemas);
17
- });
18
- let previous = [];
19
- const unsubscribe = effect(() => {
20
- const schemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.Schema).flat()));
21
- const newSchemas = schemas.filter((schema) => !previous.includes(schema));
22
- previous = schemas;
23
- client.addTypes(newSchemas);
24
- });
25
- return contributes(Capabilities.Null, null, () => {
26
- unsubscribeSystem();
27
- unsubscribe();
28
- });
29
- };
30
- export {
31
- schema_default as default
32
- };
33
- //# sourceMappingURL=schema-AL34NY2M.mjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/schema.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { effect } from '@preact/signals-core';\n\nimport { Capabilities, contributes, type PluginsContext } from '@dxos/app-framework';\nimport { type TypedObject } from '@dxos/echo-schema';\n\nimport { ClientCapabilities } from './capabilities';\n\n// TODO(wittjosiah): Remove types?\nexport default (context: PluginsContext) => {\n const client = context.requestCapability(ClientCapabilities.Client);\n\n let previousSystem: TypedObject[] = [];\n const unsubscribeSystem = effect(() => {\n const systemSchemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.SystemSchema).flat()));\n const newSchemas = systemSchemas.filter((schema) => !previousSystem.includes(schema));\n previousSystem = systemSchemas;\n client.addTypes(newSchemas);\n });\n\n let previous: TypedObject[] = [];\n const unsubscribe = effect(() => {\n const schemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.Schema).flat()));\n const newSchemas = schemas.filter((schema) => !previous.includes(schema));\n previous = schemas;\n client.addTypes(newSchemas);\n });\n\n return contributes(Capabilities.Null, null, () => {\n unsubscribeSystem();\n unsubscribe();\n });\n};\n"],
5
- "mappings": ";;;;;;AAIA,SAASA,cAAc;AAEvB,SAASC,cAAcC,mBAAwC;AAM/D,IAAA,iBAAe,CAACC,YAAAA;AACd,QAAMC,SAASD,QAAQE,kBAAkBC,mBAAmBC,MAAM;AAElE,MAAIC,iBAAgC,CAAA;AACpC,QAAMC,oBAAoBC,OAAO,MAAA;AAC/B,UAAMC,gBAAgBC,MAAMC,KAAK,IAAIC,IAAIX,QAAQY,oBAAoBT,mBAAmBU,YAAY,EAAEC,KAAI,CAAA,CAAA;AAC1G,UAAMC,aAAaP,cAAcQ,OAAO,CAACC,WAAW,CAACZ,eAAea,SAASD,MAAAA,CAAAA;AAC7EZ,qBAAiBG;AACjBP,WAAOkB,SAASJ,UAAAA;EAClB,CAAA;AAEA,MAAIK,WAA0B,CAAA;AAC9B,QAAMC,cAAcd,OAAO,MAAA;AACzB,UAAMe,UAAUb,MAAMC,KAAK,IAAIC,IAAIX,QAAQY,oBAAoBT,mBAAmBoB,MAAM,EAAET,KAAI,CAAA,CAAA;AAC9F,UAAMC,aAAaO,QAAQN,OAAO,CAACC,WAAW,CAACG,SAASF,SAASD,MAAAA,CAAAA;AACjEG,eAAWE;AACXrB,WAAOkB,SAASJ,UAAAA;EAClB,CAAA;AAEA,SAAOS,YAAYC,aAAaC,MAAM,MAAM,MAAA;AAC1CpB,sBAAAA;AACAe,gBAAAA;EACF,CAAA;AACF;",
6
- "names": ["effect", "Capabilities", "contributes", "context", "client", "requestCapability", "ClientCapabilities", "Client", "previousSystem", "unsubscribeSystem", "effect", "systemSchemas", "Array", "from", "Set", "requestCapabilities", "SystemSchema", "flat", "newSchemas", "filter", "schema", "includes", "addTypes", "previous", "unsubscribe", "schemas", "Schema", "contributes", "Capabilities", "Null"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/components/IdentityDialog.tsx", "../../../src/components/JoinDialog.tsx", "../../../src/components/RecoveryCodeDialog.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback } from 'react';\n\nimport { createIntent, LayoutAction, useIntentDispatcher } from '@dxos/app-framework';\nimport { useClient } from '@dxos/react-client';\nimport { Clipboard, Dialog } from '@dxos/react-ui';\nimport { IdentityPanel, type IdentityPanelProps } from '@dxos/shell/react';\n\nimport { CLIENT_PLUGIN } from '../meta';\nimport { ClientAction } from '../types';\n\nexport const IDENTITY_DIALOG = `${CLIENT_PLUGIN}/IdentityDialog`;\n\nexport const IdentityDialog = (props: IdentityPanelProps) => {\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n const client = useClient();\n\n const handleDone = useCallback(\n () =>\n dispatch(\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n options: { state: false },\n }),\n ),\n [dispatch],\n );\n\n const handleResetStorage = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage));\n }, [dispatch]);\n\n const handleRecover = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage, { target: 'recoverIdentity' }));\n }, [dispatch]);\n\n const handleJoinNewIdentity = useCallback(async () => {\n await client.reset();\n await dispatch(createIntent(ClientAction.ResetStorage, { target: 'deviceInvitation' }));\n }, [dispatch]);\n\n return (\n <Dialog.Content>\n <Clipboard.Provider>\n <IdentityPanel\n {...props}\n doneActionParent={<Dialog.Close asChild />}\n onDone={handleDone}\n onResetStorage={handleResetStorage}\n onRecover={handleRecover}\n onJoinNewIdentity={handleJoinNewIdentity}\n />\n </Clipboard.Provider>\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback } from 'react';\n\nimport { createIntent, LayoutAction, useIntentDispatcher } from '@dxos/app-framework';\nimport { ObservabilityAction } from '@dxos/plugin-observability/types';\nimport { type InvitationResult } from '@dxos/react-client/invitations';\nimport { Dialog } from '@dxos/react-ui';\nimport { JoinPanel, type JoinPanelProps } from '@dxos/shell/react';\n\nimport { CLIENT_PLUGIN } from '../meta';\nimport { ClientAction } from '../types';\n\nexport const JOIN_DIALOG = `${CLIENT_PLUGIN}/JoinDialog`;\n\nexport const JoinDialog = (props: JoinPanelProps) => {\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n\n const handleCancelResetStorage = useCallback(() => dispatch(createIntent(ClientAction.ShareIdentity)), [dispatch]);\n\n const handleDone = useCallback(\n async (result: InvitationResult | null) => {\n if (result?.identityKey) {\n await Promise.all([\n dispatch(createIntent(LayoutAction.UpdateDialog, { part: 'dialog', options: { state: false } })),\n dispatch(\n createIntent(ObservabilityAction.SendEvent, {\n name: props.initialDisposition === 'recover-identity' ? 'identity.recover' : 'identity.join',\n }),\n ),\n ]);\n }\n },\n [dispatch],\n );\n\n return (\n <Dialog.Content>\n <JoinPanel\n mode='halo-only'\n {...props}\n exitActionParent={<Dialog.Close asChild />}\n doneActionParent={<Dialog.Close asChild />}\n onCancelResetStorage={handleCancelResetStorage}\n onDone={handleDone}\n />\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useCallback, useState } from 'react';\n\nimport { AlertDialog, Button, Clipboard, Input, useTranslation } from '@dxos/react-ui';\n\nimport { CLIENT_PLUGIN } from '../meta';\n\nexport const RECOVER_CODE_DIALOG = `${CLIENT_PLUGIN}/RecoveryCodeDialog`;\n\nexport type RecoveryCodeDialogProps = {\n code: string;\n};\n\nexport const RecoveryCodeDialog = ({ code }: RecoveryCodeDialogProps) => {\n const { t } = useTranslation(CLIENT_PLUGIN);\n const [confirmation, setConfirmation] = useState(false);\n\n const handleConfirmation = useCallback((checked: boolean) => setConfirmation(checked), []);\n\n return (\n <AlertDialog.Content classNames='bs-content min-bs-[15rem] max-bs-full md:max-is-[40rem] overflow-hidden'>\n <AlertDialog.Title>{t('recovery code dialog title')}</AlertDialog.Title>\n <p className='py-4'>{t('recovery code dialog description')}</p>\n <Clipboard.Provider>\n <Code code={code} />\n </Clipboard.Provider>\n <div className='flex flex-col py-4 gap-2'>\n <p>{t('recovery code dialog warning 1')}</p>\n <p>{t('recovery code dialog warning 2')}</p>\n </div>\n <div className='flex items-center gap-2 pbe-4'>\n <Input.Root>\n <Input.Checkbox\n data-testid='recoveryCode.confirm'\n checked={confirmation}\n onCheckedChange={handleConfirmation}\n />\n <Input.Label>{t('recovery code confirmation label')}</Input.Label>\n </Input.Root>\n </div>\n <div className='flex justify-end'>\n <AlertDialog.Action asChild>\n <Button data-testid='recoveryCode.continue' variant='primary' disabled={!confirmation}>\n {t('continue label')}\n </Button>\n </AlertDialog.Action>\n </div>\n </AlertDialog.Content>\n );\n};\n\nconst Code = ({ code }: { code: string }) => {\n const words = code.split(' ');\n return (\n <div className='relative p-2 border border-separator rounded group'>\n <Clipboard.IconButton value={code} classNames='absolute top-2 right-2 invisible group-hover:visible' />\n <div className='grid grid-cols-4'>\n {words.map((word, i) => (\n <div key={i} className='flex items-center p-2 gap-2 items-center'>\n <div className='w-4 text-xs text-center text-subdued'>{i + 1}</div>\n <div className='text-sm'>{word}</div>\n </div>\n ))}\n </div>\n </div>\n );\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAmC;AAEnC,2BAAgE;AAChE,0BAA0B;AAC1B,sBAAkC;AAClC,IAAAA,gBAAuD;ACLvD,IAAAA,gBAAmC;AAEnC,IAAAC,wBAAgE;AAChE,mBAAoC;AAEpC,IAAAC,mBAAuB;AACvB,IAAAF,gBAA+C;ACN/C,IAAAA,gBAA6C;AAE7C,IAAAE,mBAAsE;AFQ/D,IAAMC,kBAAkB,GAAGC,mCAAAA;AAE3B,IAAMC,iBAAiB,CAACC,UAAAA;AAC7B,QAAM,EAAEC,iBAAiBC,SAAQ,QAAKC,0CAAAA;AACtC,QAAMC,aAASC,+BAAAA;AAEf,QAAMC,iBAAaC,0BACjB,MACEL,aACEM,mCAAaC,kCAAaC,cAAc;IACtCC,MAAM;IACNC,SAAS;MAAEC,OAAO;IAAM;EAC1B,CAAA,CAAA,GAEJ;IAACX;GAAS;AAGZ,QAAMY,yBAAqBP,0BAAY,YAAA;AACrC,UAAMH,OAAOW,MAAK;AAClB,UAAMb,aAASM,mCAAaQ,mCAAaC,Y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cAAC8C,uBAAME,UAAQ;IACbC,eAAY;IACZX,SAASJ;IACTgB,iBAAiBb;MAEnBrC,8BAAAA,QAAA,cAAC8C,uBAAMK,OAAK,MAAEnB,EAAE,kCAAA,CAAA,CAAA,CAAA,GAGpBhC,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIF,WAAU;KACb3C,8BAAAA,QAAA,cAACuC,6BAAYa,QAAM;IAAC5C,SAAAA;KAClBR,8BAAAA,QAAA,cAACqD,yBAAAA;IAAOJ,eAAY;IAAwBK,SAAQ;IAAUC,UAAU,CAACrB;KACtEF,EAAE,gBAAA,CAAA,CAAA,CAAA,CAAA;AAMf;AAEA,IAAMY,OAAO,CAAC,EAAEb,KAAI,MAAoB;AACtC,QAAMyB,QAAQzB,KAAK0B,MAAM,GAAA;AACzB,SACEzD,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIF,WAAU;KACb3C,8BAAAA,QAAA,cAACG,iBAAAA,UAAUuD,YAAU;IAACC,OAAO5B;IAAMS,YAAW;MAC9CxC,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIF,WAAU;KACZa,MAAMI,IAAI,CAACC,MAAMC,MAChB9D,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIkB,KAAKD;IAAGnB,WAAU;KACrB3C,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIF,WAAU;KAAwCmB,IAAI,CAAA,GAC3D9D,8BAAAA,QAAA,cAAC6C,OAAAA;IAAIF,WAAU;KAAWkB,IAAAA,CAAAA,CAAAA,CAAAA,CAAAA;AAMtC;",
6
- "names": ["import_react", "import_app_framework", "import_react_ui", "IDENTITY_DIALOG", "CLIENT_PLUGIN", "IdentityDialog", "props", "dispatchPromise", "dispatch", "useIntentDispatcher", "client", "useClient", "handleDone", "useCallback", "createIntent", "LayoutAction", "UpdateDialog", "part", "options", "state", "handleResetStorage", "reset", "ClientAction", "ResetStorage", "handleRecover", "target", "handleJoinNewIdentity", "React", "Dialog", "Content", "Clipboard", "Provider", "IdentityPanel", "doneActionParent", "Close", "asChild", "onDone", "onResetStorage", "onRecover", "onJoinNewIdentity", "JOIN_DIALOG", "JoinDialog", "handleCancelResetStorage", "ShareIdentity", "result", "identityKey", "Promise", "all", "ObservabilityAction", "SendEvent", "name", "initialDisposition", "JoinPanel", "mode", "exitActionParent", "onCancelResetStorage", "RECOVER_CODE_DIALOG", "RecoveryCodeDialog", "code", "t", "useTranslation", "confirmation", "setConfirmation", "useState", "handleConfirmation", "checked", "AlertDialog", "classNames", "Title", "p", "className", "Code", "div", "Input", "Root", "Checkbox", "data-testid", "onCheckedChange", "Label", "Action", "Button", "variant", "disabled", "words", "split", "IconButton", "value", "map", "word", "i", "key"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/client.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { contributes, type PluginsContext } from '@dxos/app-framework';\nimport { Config, Defaults, Envs, Local, Storage } from '@dxos/config';\nimport { Client } from '@dxos/react-client';\n\nimport { ClientCapabilities } from './capabilities';\nimport { ClientEvents } from '../events';\nimport { type ClientPluginOptions } from '../types';\n\ntype ClientCapabilityOptions = Omit<ClientPluginOptions, 'appKey' | 'invitationUrl' | 'invitationParam' | 'onReset'> & {\n context: PluginsContext;\n};\n\nexport default async ({ context, onClientInitialized, ...options }: ClientCapabilityOptions) => {\n const config = new Config(await Storage(), Envs(), Local(), Defaults());\n const client = new Client({ config, ...options });\n await client.initialize();\n await onClientInitialized?.(context, client);\n\n // TODO(wittjosiah): Remove. This is a hack to get the app to boot with the new identity after a reset.\n client.reloaded.on(() => {\n client.halo.identity.subscribe(async (identity) => {\n if (identity) {\n window.location.href = window.location.origin;\n }\n });\n });\n\n const subscription = client.spaces.isReady.subscribe(async (ready) => {\n if (ready) {\n await context.activate(ClientEvents.SpacesReady);\n }\n });\n\n return contributes(ClientCapabilities.Client, client, async () => {\n subscription.unsubscribe();\n await client.destroy();\n });\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAAiD;AACjD,oBAAuD;AACvD,0BAAuB;AAUvB,IAAA,iBAAe,OAAO,EAAEA,SAASC,qBAAqB,GAAGC,QAAAA,MAAkC;AACzF,QAAMC,SAAS,IAAIC,qBAAO,UAAMC,uBAAAA,OAAWC,oBAAAA,OAAQC,qBAAAA,OAASC,wBAAAA,CAAAA;AAC5D,QAAMC,SAAS,IAAIC,2BAAO;IAAEP;IAAQ,GAAGD;EAAQ,CAAA;AAC/C,QAAMO,OAAOE,WAAU;AACvB,QAAMV,sBAAsBD,SAASS,MAAAA;AAGrCA,SAAOG,SAASC,GAAG,MAAA;AACjBJ,WAAOK,KAAKC,SAASC,UAAU,OAAOD,aAAAA;AACpC,UAAIA,UAAU;AACZE,eAAOC,SAASC,OAAOF,OAAOC,SAASE;MACzC;IACF,CAAA;EACF,CAAA;AAEA,QAAMC,eAAeZ,OAAOa,OAAOC,QAAQP,UAAU,OAAOQ,UAAAA;AAC1D,QAAIA,OAAO;AACT,YAAMxB,QAAQyB,SAASC,mCAAaC,WAAW;IACjD;EACF,CAAA;AAEA,aAAOC,kCAAYC,yCAAmBnB,QAAQD,QAAQ,YAAA;AACpDY,iBAAaS,YAAW;AACxB,UAAMrB,OAAOsB,QAAO;EACtB,CAAA;AACF;",
6
- "names": ["context", "onClientInitialized", "options", "config", "Config", "Storage", "Envs", "Local", "Defaults", "client", "Client", "initialize", "reloaded", "on", "halo", "identity", "subscribe", "window", "location", "href", "origin", "subscription", "spaces", "isReady", "ready", "activate", "ClientEvents", "SpacesReady", "contributes", "ClientCapabilities", "unsubscribe", "destroy"]
7
- }
@@ -1,167 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var intent_resolver_DUPICQ3F_exports = {};
20
- __export(intent_resolver_DUPICQ3F_exports, {
21
- default: () => intent_resolver_default
22
- });
23
- module.exports = __toCommonJS(intent_resolver_DUPICQ3F_exports);
24
- var import_chunk_XPC4JOPP = require("./chunk-XPC4JOPP.cjs");
25
- var import_chunk_VUJ3ZPK3 = require("./chunk-VUJ3ZPK3.cjs");
26
- var import_chunk_NVYWMDF3 = require("./chunk-NVYWMDF3.cjs");
27
- var import_chunk_ZI7AV5RP = require("./chunk-ZI7AV5RP.cjs");
28
- var import_chunk_OIFPM5ZW = require("./chunk-OIFPM5ZW.cjs");
29
- var import_app_framework = require("@dxos/app-framework");
30
- var import_invariant = require("@dxos/invariant");
31
- var import_types = require("@dxos/plugin-observability/types");
32
- var __dxlog_file = "/home/runner/work/dxos/dxos/packages/plugins/plugin-client/src/capabilities/intent-resolver.ts";
33
- var intent_resolver_default = ({ context, onReset }) => (0, import_app_framework.contributes)(import_app_framework.Capabilities.IntentResolver, [
34
- (0, import_app_framework.createResolver)({
35
- intent: import_chunk_NVYWMDF3.ClientAction.CreateIdentity,
36
- resolve: async () => {
37
- const manager = context.requestCapability(import_app_framework.Capabilities.PluginManager);
38
- const client = context.requestCapability(import_chunk_ZI7AV5RP.ClientCapabilities.Client);
39
- const data = await client.halo.createIdentity();
40
- await manager.activate(import_chunk_XPC4JOPP.ClientEvents.IdentityCreated);
41
- return {
42
- data,
43
- intents: [
44
- (0, import_app_framework.createIntent)(import_types.ObservabilityAction.SendEvent, {
45
- name: "identity.create"
46
- })
47
- ]
48
- };
49
- }
50
- }),
51
- (0, import_app_framework.createResolver)({
52
- intent: import_chunk_NVYWMDF3.ClientAction.JoinIdentity,
53
- resolve: async (data) => {
54
- return {
55
- intents: [
56
- (0, import_app_framework.createIntent)(import_app_framework.LayoutAction.UpdateDialog, {
57
- part: "dialog",
58
- subject: import_chunk_VUJ3ZPK3.JOIN_DIALOG,
59
- options: {
60
- blockAlign: "start",
61
- props: {
62
- initialInvitationCode: data.invitationCode,
63
- initialDisposition: "accept-halo-invitation"
64
- }
65
- }
66
- })
67
- ]
68
- };
69
- }
70
- }),
71
- (0, import_app_framework.createResolver)({
72
- intent: import_chunk_NVYWMDF3.ClientAction.ShareIdentity,
73
- resolve: async () => {
74
- return {
75
- intents: [
76
- (0, import_app_framework.createIntent)(import_app_framework.LayoutAction.UpdateDialog, {
77
- part: "dialog",
78
- subject: import_chunk_VUJ3ZPK3.IDENTITY_DIALOG,
79
- options: {
80
- blockAlign: "start"
81
- }
82
- }),
83
- (0, import_app_framework.createIntent)(import_types.ObservabilityAction.SendEvent, {
84
- name: "identity.share"
85
- })
86
- ]
87
- };
88
- }
89
- }),
90
- (0, import_app_framework.createResolver)({
91
- intent: import_chunk_NVYWMDF3.ClientAction.RecoverIdentity,
92
- resolve: async () => {
93
- return {
94
- intents: [
95
- (0, import_app_framework.createIntent)(import_app_framework.LayoutAction.UpdateDialog, {
96
- part: "dialog",
97
- subject: import_chunk_VUJ3ZPK3.JOIN_DIALOG,
98
- options: {
99
- blockAlign: "start",
100
- props: {
101
- initialDisposition: "recover-identity"
102
- }
103
- }
104
- })
105
- ]
106
- };
107
- }
108
- }),
109
- (0, import_app_framework.createResolver)({
110
- intent: import_chunk_NVYWMDF3.ClientAction.ResetStorage,
111
- resolve: async (data) => {
112
- await onReset?.({
113
- target: data.target
114
- });
115
- }
116
- }),
117
- (0, import_app_framework.createResolver)({
118
- intent: import_chunk_NVYWMDF3.ClientAction.CreateAgent,
119
- resolve: async () => {
120
- const client = context.requestCapability(import_chunk_ZI7AV5RP.ClientCapabilities.Client);
121
- (0, import_invariant.invariant)(client.services.services.EdgeAgentService, "Missing EdgeAgentService", {
122
- F: __dxlog_file,
123
- L: 104,
124
- S: void 0,
125
- A: [
126
- "client.services.services.EdgeAgentService",
127
- "'Missing EdgeAgentService'"
128
- ]
129
- });
130
- await client.services.services.EdgeAgentService.createAgent(null, {
131
- timeout: 1e4
132
- });
133
- }
134
- }),
135
- (0, import_app_framework.createResolver)({
136
- intent: import_chunk_NVYWMDF3.ClientAction.CreateRecoveryCode,
137
- resolve: async () => {
138
- const client = context.requestCapability(import_chunk_ZI7AV5RP.ClientCapabilities.Client);
139
- (0, import_invariant.invariant)(client.services.services.IdentityService, "IdentityService not available", {
140
- F: __dxlog_file,
141
- L: 112,
142
- S: void 0,
143
- A: [
144
- "client.services.services.IdentityService",
145
- "'IdentityService not available'"
146
- ]
147
- });
148
- const { recoveryCode } = await client.services.services.IdentityService.createRecoveryCredential({});
149
- return {
150
- intents: [
151
- (0, import_app_framework.createIntent)(import_app_framework.LayoutAction.UpdateDialog, {
152
- part: "dialog",
153
- subject: import_chunk_VUJ3ZPK3.RECOVER_CODE_DIALOG,
154
- options: {
155
- blockAlign: "start",
156
- type: "alert",
157
- props: {
158
- code: recoveryCode
159
- }
160
- }
161
- })
162
- ]
163
- };
164
- }
165
- })
166
- ]);
167
- //# sourceMappingURL=intent-resolver-DUPICQ3F.cjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/intent-resolver.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport {\n Capabilities,\n contributes,\n createIntent,\n createResolver,\n LayoutAction,\n type PluginsContext,\n} from '@dxos/app-framework';\nimport { invariant } from '@dxos/invariant';\nimport { ObservabilityAction } from '@dxos/plugin-observability/types';\nimport { type JoinPanelProps } from '@dxos/shell/react';\n\nimport { ClientCapabilities } from './capabilities';\nimport { IDENTITY_DIALOG, JOIN_DIALOG, RECOVER_CODE_DIALOG } from '../components';\nimport { ClientEvents } from '../events';\nimport { ClientAction, type ClientPluginOptions } from '../types';\n\ntype IntentResolverOptions = Pick<ClientPluginOptions, 'onReset'> & {\n context: PluginsContext;\n};\n\nexport default ({ context, onReset }: IntentResolverOptions) =>\n contributes(Capabilities.IntentResolver, [\n createResolver({\n intent: ClientAction.CreateIdentity,\n resolve: async () => {\n const manager = context.requestCapability(Capabilities.PluginManager);\n const client = context.requestCapability(ClientCapabilities.Client);\n const data = await client.halo.createIdentity();\n await manager.activate(ClientEvents.IdentityCreated);\n return { data, intents: [createIntent(ObservabilityAction.SendEvent, { name: 'identity.create' })] };\n },\n }),\n createResolver({\n intent: ClientAction.JoinIdentity,\n resolve: async (data) => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: JOIN_DIALOG,\n options: {\n blockAlign: 'start',\n props: {\n initialInvitationCode: data.invitationCode,\n initialDisposition: 'accept-halo-invitation',\n },\n },\n }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.ShareIdentity,\n resolve: async () => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: IDENTITY_DIALOG,\n options: {\n blockAlign: 'start',\n },\n }),\n createIntent(ObservabilityAction.SendEvent, { name: 'identity.share' }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.RecoverIdentity,\n resolve: async () => {\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: JOIN_DIALOG,\n options: {\n blockAlign: 'start',\n props: {\n initialDisposition: 'recover-identity',\n } satisfies Partial<JoinPanelProps>,\n },\n }),\n ],\n };\n },\n }),\n createResolver({\n intent: ClientAction.ResetStorage,\n resolve: async (data) => {\n await onReset?.({ target: data.target });\n },\n }),\n createResolver({\n intent: ClientAction.CreateAgent,\n resolve: async () => {\n const client = context.requestCapability(ClientCapabilities.Client);\n invariant(client.services.services.EdgeAgentService, 'Missing EdgeAgentService');\n await client.services.services.EdgeAgentService.createAgent(null as any, { timeout: 10_000 });\n },\n }),\n createResolver({\n intent: ClientAction.CreateRecoveryCode,\n resolve: async () => {\n const client = context.requestCapability(ClientCapabilities.Client);\n invariant(client.services.services.IdentityService, 'IdentityService not available');\n // TODO(wittjosiah): This needs a proper api.\n const { recoveryCode } = await client.services.services.IdentityService.createRecoveryCredential({});\n return {\n intents: [\n createIntent(LayoutAction.UpdateDialog, {\n part: 'dialog',\n subject: RECOVER_CODE_DIALOG,\n options: {\n blockAlign: 'start',\n type: 'alert',\n props: { code: recoveryCode },\n },\n }),\n ],\n };\n },\n }),\n ]);\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAOO;AACP,uBAA0B;AAC1B,mBAAoC;;AAYpC,IAAA,0BAAe,CAAC,EAAEA,SAASC,QAAO,UAChCC,kCAAYC,kCAAaC,gBAAgB;MACvCC,qCAAe;IACbC,QAAQC,mCAAaC;IACrBC,SAAS,YAAA;AACP,YAAMC,UAAUV,QAAQW,kBAAkBR,kCAAaS,aAAa;AACpE,YAAMC,SAASb,QAAQW,kBAAkBG,yCAAmBC,MAAM;AAClE,YAAMC,OAAO,MAAMH,OAAOI,KAAKC,eAAc;AAC7C,YAAMR,QAAQS,SAASC,mCAAaC,eAAe;AACnD,aAAO;QAAEL;QAAMM,SAAS;cAACC,mCAAaC,iCAAoBC,WAAW;YAAEC,MAAM;UAAkB,CAAA;;MAAI;IACrG;EACF,CAAA;MACArB,qCAAe;IACbC,QAAQC,mCAAaoB;IACrBlB,SAAS,OAAOO,SAAAA;AACd,aAAO;QACLM,SAAS;cACPC,mCAAaK,kCAAaC,cAAc;YACtCC,MAAM;YACNC,SAASC;YACTC,SAAS;cACPC,YAAY;cACZC,OAAO;gBACLC,uBAAuBpB,KAAKqB;gBAC5BC,oBAAoB;cACtB;YACF;UACF,CAAA;;MAEJ;IACF;EACF,CAAA;MACAjC,qC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rB,SAAS;cACPC,YAAY;cACZqB,MAAM;cACNpB,OAAO;gBAAEqB,MAAMJ;cAAa;YAC9B;UACF,CAAA;;MAEJ;IACF;EACF,CAAA;CACD;",
6
- "names": ["context", "onReset", "contributes", "Capabilities", "IntentResolver", "createResolver", "intent", "ClientAction", "CreateIdentity", "resolve", "manager", "requestCapability", "PluginManager", "client", "ClientCapabilities", "Client", "data", "halo", "createIdentity", "activate", "ClientEvents", "IdentityCreated", "intents", "createIntent", "ObservabilityAction", "SendEvent", "name", "JoinIdentity", "LayoutAction", "UpdateDialog", "part", "subject", "JOIN_DIALOG", "options", "blockAlign", "props", "initialInvitationCode", "invitationCode", "initialDisposition", "ShareIdentity", "IDENTITY_DIALOG", "RecoverIdentity", "ResetStorage", "target", "CreateAgent", "invariant", "services", "EdgeAgentService", "createAgent", "timeout", "CreateRecoveryCode", "IdentityService", "recoveryCode", "createRecoveryCredential", "RECOVER_CODE_DIALOG", "type", "code"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/react-surface.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { createSurface, Capabilities, contributes } from '@dxos/app-framework';\nimport { type IdentityPanelProps, type JoinPanelProps } from '@dxos/shell/react';\n\nimport {\n IDENTITY_DIALOG,\n IdentityDialog,\n JOIN_DIALOG,\n JoinDialog,\n RECOVER_CODE_DIALOG,\n RecoveryCodeDialog,\n type RecoveryCodeDialogProps,\n} from '../components';\n\ntype ReactSurfaceOptions = {\n createInvitationUrl: (invitationCode: string) => string;\n};\n\nexport default ({ createInvitationUrl }: ReactSurfaceOptions) =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: IDENTITY_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: IdentityPanelProps } => data.component === IDENTITY_DIALOG,\n component: ({ data }) => <IdentityDialog {...data.props} createInvitationUrl={createInvitationUrl} />,\n }),\n createSurface({\n id: JOIN_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: JoinPanelProps } => data.component === JOIN_DIALOG,\n component: ({ data }) => <JoinDialog {...data.props} />,\n }),\n createSurface({\n id: RECOVER_CODE_DIALOG,\n role: 'dialog',\n filter: (data): data is { props: RecoveryCodeDialogProps } => data.component === RECOVER_CODE_DIALOG,\n component: ({ data }) => <RecoveryCodeDialog {...data.props} />,\n }),\n ]);\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAkB;AAElB,2BAAyD;AAiBzD,IAAA,wBAAe,CAAC,EAAEA,oBAAmB,UACnCC,kCAAYC,kCAAaC,cAAc;MACrCC,oCAAc;IACZC,IAAIC;IACJC,MAAM;IACNC,QAAQ,CAACC,SAAgDA,KAAKC,cAAcJ;IAC5EI,WAAW,CAAC,EAAED,KAAI,MAAO,6BAAAE,QAAA,cAACC,sCAAAA;MAAgB,GAAGH,KAAKI;MAAOb;;EAC3D,CAAA;MACAI,oCAAc;IACZC,IAAIS;IACJP,MAAM;IACNC,QAAQ,CAACC,SAA4CA,KAAKC,cAAcI;IACxEJ,WAAW,CAAC,EAAED,KAAI,MAAO,6BAAAE,QAAA,cAACI,kCAAeN,KAAKI,KAAK;EACrD,CAAA;MACAT,oCAAc;IACZC,IAAIW;IACJT,MAAM;IACNC,QAAQ,CAACC,SAAqDA,KAAKC,cAAcM;IACjFN,WAAW,CAAC,EAAED,KAAI,MAAO,6BAAAE,QAAA,cAACM,0CAAuBR,KAAKI,KAAK;EAC7D,CAAA;CACD;",
6
- "names": ["createInvitationUrl", "contributes", "Capabilities", "ReactSurface", "createSurface", "id", "IDENTITY_DIALOG", "role", "filter", "data", "component", "React", "IdentityDialog", "props", "JOIN_DIALOG", "JoinDialog", "RECOVER_CODE_DIALOG", "RecoveryCodeDialog"]
7
- }
@@ -1,49 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var schema_HW4W3QYU_exports = {};
20
- __export(schema_HW4W3QYU_exports, {
21
- default: () => schema_default
22
- });
23
- module.exports = __toCommonJS(schema_HW4W3QYU_exports);
24
- var import_chunk_ZI7AV5RP = require("./chunk-ZI7AV5RP.cjs");
25
- var import_chunk_OIFPM5ZW = require("./chunk-OIFPM5ZW.cjs");
26
- var import_signals_core = require("@preact/signals-core");
27
- var import_app_framework = require("@dxos/app-framework");
28
- var schema_default = (context) => {
29
- const client = context.requestCapability(import_chunk_ZI7AV5RP.ClientCapabilities.Client);
30
- let previousSystem = [];
31
- const unsubscribeSystem = (0, import_signals_core.effect)(() => {
32
- const systemSchemas = Array.from(new Set(context.requestCapabilities(import_chunk_ZI7AV5RP.ClientCapabilities.SystemSchema).flat()));
33
- const newSchemas = systemSchemas.filter((schema) => !previousSystem.includes(schema));
34
- previousSystem = systemSchemas;
35
- client.addTypes(newSchemas);
36
- });
37
- let previous = [];
38
- const unsubscribe = (0, import_signals_core.effect)(() => {
39
- const schemas = Array.from(new Set(context.requestCapabilities(import_chunk_ZI7AV5RP.ClientCapabilities.Schema).flat()));
40
- const newSchemas = schemas.filter((schema) => !previous.includes(schema));
41
- previous = schemas;
42
- client.addTypes(newSchemas);
43
- });
44
- return (0, import_app_framework.contributes)(import_app_framework.Capabilities.Null, null, () => {
45
- unsubscribeSystem();
46
- unsubscribe();
47
- });
48
- };
49
- //# sourceMappingURL=schema-HW4W3QYU.cjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/schema.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { effect } from '@preact/signals-core';\n\nimport { Capabilities, contributes, type PluginsContext } from '@dxos/app-framework';\nimport { type TypedObject } from '@dxos/echo-schema';\n\nimport { ClientCapabilities } from './capabilities';\n\n// TODO(wittjosiah): Remove types?\nexport default (context: PluginsContext) => {\n const client = context.requestCapability(ClientCapabilities.Client);\n\n let previousSystem: TypedObject[] = [];\n const unsubscribeSystem = effect(() => {\n const systemSchemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.SystemSchema).flat()));\n const newSchemas = systemSchemas.filter((schema) => !previousSystem.includes(schema));\n previousSystem = systemSchemas;\n client.addTypes(newSchemas);\n });\n\n let previous: TypedObject[] = [];\n const unsubscribe = effect(() => {\n const schemas = Array.from(new Set(context.requestCapabilities(ClientCapabilities.Schema).flat()));\n const newSchemas = schemas.filter((schema) => !previous.includes(schema));\n previous = schemas;\n client.addTypes(newSchemas);\n });\n\n return contributes(Capabilities.Null, null, () => {\n unsubscribeSystem();\n unsubscribe();\n });\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAIA,0BAAuB;AAEvB,2BAA+D;AAM/D,IAAA,iBAAe,CAACA,YAAAA;AACd,QAAMC,SAASD,QAAQE,kBAAkBC,yCAAmBC,MAAM;AAElE,MAAIC,iBAAgC,CAAA;AACpC,QAAMC,wBAAoBC,4BAAO,MAAA;AAC/B,UAAMC,gBAAgBC,MAAMC,KAAK,IAAIC,IAAIX,QAAQY,oBAAoBT,yCAAmBU,YAAY,EAAEC,KAAI,CAAA,CAAA;AAC1G,UAAMC,aAAaP,cAAcQ,OAAO,CAACC,WAAW,CAACZ,eAAea,SAASD,MAAAA,CAAAA;AAC7EZ,qBAAiBG;AACjBP,WAAOkB,SAASJ,UAAAA;EAClB,CAAA;AAEA,MAAIK,WAA0B,CAAA;AAC9B,QAAMC,kBAAcd,4BAAO,MAAA;AACzB,UAAMe,UAAUb,MAAMC,KAAK,IAAIC,IAAIX,QAAQY,oBAAoBT,yCAAmBoB,MAAM,EAAET,KAAI,CAAA,CAAA;AAC9F,UAAMC,aAAaO,QAAQN,OAAO,CAACC,WAAW,CAACG,SAASF,SAASD,MAAAA,CAAAA;AACjEG,eAAWE;AACXrB,WAAOkB,SAASJ,UAAAA;EAClB,CAAA;AAEA,aAAOS,kCAAYC,kCAAaC,MAAM,MAAM,MAAA;AAC1CpB,sBAAAA;AACAe,gBAAAA;EACF,CAAA;AACF;",
6
- "names": ["context", "client", "requestCapability", "ClientCapabilities", "Client", "previousSystem", "unsubscribeSystem", "effect", "systemSchemas", "Array", "from", "Set", "requestCapabilities", "SystemSchema", "flat", "newSchemas", "filter", "schema", "includes", "addTypes", "previous", "unsubscribe", "schemas", "Schema", "contributes", "Capabilities", "Null"]
7
- }