@dxos/plugin-client 0.8.4-main.422d1c7879 → 0.8.4-main.51f1e5ca51

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 (186) hide show
  1. package/dist/lib/browser/{chunk-WNJRYPGG.mjs → chunk-M37DHX5L.mjs} +1 -1
  2. package/dist/lib/browser/{chunk-WNJRYPGG.mjs.map → chunk-M37DHX5L.mjs.map} +2 -2
  3. package/dist/lib/browser/{chunk-M43LJQ5U.mjs → chunk-RPMM5NKJ.mjs} +2 -2
  4. package/dist/lib/browser/chunk-RPMM5NKJ.mjs.map +7 -0
  5. package/dist/lib/browser/{chunk-ELAYKIQU.mjs → chunk-VAIJSQYA.mjs} +1 -1
  6. package/dist/lib/browser/{chunk-ELAYKIQU.mjs.map → chunk-VAIJSQYA.mjs.map} +2 -2
  7. package/dist/lib/browser/cli/index.mjs +5 -37
  8. package/dist/lib/browser/cli/index.mjs.map +2 -2
  9. package/dist/lib/browser/{create-agent-SS5SE35J.mjs → create-agent-JV3EM3TV.mjs} +5 -13
  10. package/dist/lib/browser/create-agent-JV3EM3TV.mjs.map +7 -0
  11. package/dist/lib/browser/{create-identity-PBEUEIPN.mjs → create-identity-ZITQKEVZ.mjs} +4 -4
  12. package/dist/lib/browser/create-identity-ZITQKEVZ.mjs.map +7 -0
  13. package/dist/lib/browser/{create-passkey-JN6I5WMM.mjs → create-passkey-NCP4XA7C.mjs} +7 -31
  14. package/dist/lib/browser/create-passkey-NCP4XA7C.mjs.map +7 -0
  15. package/dist/lib/browser/{create-recovery-code-32I6IWZC.mjs → create-recovery-code-L5LA3GAP.mjs} +6 -14
  16. package/dist/lib/browser/create-recovery-code-L5LA3GAP.mjs.map +7 -0
  17. package/dist/lib/browser/index.mjs +5 -75
  18. package/dist/lib/browser/index.mjs.map +4 -4
  19. package/dist/lib/browser/{join-identity-2BP4G2SD.mjs → join-identity-3W6PJLKN.mjs} +4 -4
  20. package/dist/lib/browser/{join-identity-2BP4G2SD.mjs.map → join-identity-3W6PJLKN.mjs.map} +1 -1
  21. package/dist/lib/browser/meta.json +1 -1
  22. package/dist/lib/browser/operations/index.mjs +3 -3
  23. package/dist/lib/browser/operations/index.mjs.map +3 -3
  24. package/dist/lib/browser/{recover-identity-LS6B5INB.mjs → recover-identity-KL6QY4GI.mjs} +4 -4
  25. package/dist/lib/browser/{recover-identity-LS6B5INB.mjs.map → recover-identity-KL6QY4GI.mjs.map} +1 -1
  26. package/dist/lib/browser/{redeem-passkey-OCIV6VCK.mjs → redeem-passkey-NDEWSJTM.mjs} +6 -22
  27. package/dist/lib/browser/redeem-passkey-NDEWSJTM.mjs.map +7 -0
  28. package/dist/lib/browser/{redeem-token-6BCRGKV6.mjs → redeem-token-YLWAVFXD.mjs} +5 -13
  29. package/dist/lib/browser/redeem-token-YLWAVFXD.mjs.map +7 -0
  30. package/dist/lib/browser/{reset-storage-QJLTL7J3.mjs → reset-storage-OBHEGA6Z.mjs} +4 -4
  31. package/dist/lib/browser/{reset-storage-QJLTL7J3.mjs.map → reset-storage-OBHEGA6Z.mjs.map} +1 -1
  32. package/dist/lib/browser/{share-identity-YJEBJTPA.mjs → share-identity-FTFHFSZQ.mjs} +4 -4
  33. package/dist/lib/browser/{share-identity-YJEBJTPA.mjs.map → share-identity-FTFHFSZQ.mjs.map} +1 -1
  34. package/dist/lib/browser/testing/index.mjs.map +2 -2
  35. package/dist/lib/browser/translations.mjs +74 -0
  36. package/dist/lib/browser/translations.mjs.map +7 -0
  37. package/dist/lib/browser/types/index.mjs +1 -1
  38. package/dist/lib/node-esm/{chunk-SJ6FDER5.mjs → chunk-G77YYPR6.mjs} +2 -2
  39. package/dist/lib/node-esm/chunk-G77YYPR6.mjs.map +7 -0
  40. package/dist/lib/node-esm/{chunk-J5RWSQT6.mjs → chunk-OHKM7GJW.mjs} +1 -1
  41. package/dist/lib/node-esm/{chunk-J5RWSQT6.mjs.map → chunk-OHKM7GJW.mjs.map} +2 -2
  42. package/dist/lib/node-esm/{chunk-IT5LAIV3.mjs → chunk-UBY7FBQ7.mjs} +1 -1
  43. package/dist/lib/node-esm/{chunk-IT5LAIV3.mjs.map → chunk-UBY7FBQ7.mjs.map} +2 -2
  44. package/dist/lib/node-esm/cli/index.mjs +5 -37
  45. package/dist/lib/node-esm/cli/index.mjs.map +2 -2
  46. package/dist/lib/node-esm/{create-agent-QGEHMHBL.mjs → create-agent-Y4BPVDV7.mjs} +5 -13
  47. package/dist/lib/node-esm/create-agent-Y4BPVDV7.mjs.map +7 -0
  48. package/dist/lib/node-esm/{create-identity-EHRJQOO4.mjs → create-identity-367SQSX6.mjs} +4 -4
  49. package/dist/lib/node-esm/create-identity-367SQSX6.mjs.map +7 -0
  50. package/dist/lib/node-esm/{create-passkey-PFBHHBEQ.mjs → create-passkey-WMWK2ETT.mjs} +7 -31
  51. package/dist/lib/node-esm/create-passkey-WMWK2ETT.mjs.map +7 -0
  52. package/dist/lib/node-esm/{create-recovery-code-HBAM2A72.mjs → create-recovery-code-VJGE5HJL.mjs} +6 -14
  53. package/dist/lib/node-esm/create-recovery-code-VJGE5HJL.mjs.map +7 -0
  54. package/dist/lib/node-esm/index.mjs +5 -75
  55. package/dist/lib/node-esm/index.mjs.map +4 -4
  56. package/dist/lib/node-esm/{join-identity-75JCKQHM.mjs → join-identity-IRIRO2VT.mjs} +4 -4
  57. package/dist/lib/node-esm/{join-identity-75JCKQHM.mjs.map → join-identity-IRIRO2VT.mjs.map} +1 -1
  58. package/dist/lib/node-esm/meta.json +1 -1
  59. package/dist/lib/node-esm/operations/index.mjs +3 -3
  60. package/dist/lib/node-esm/operations/index.mjs.map +3 -3
  61. package/dist/lib/node-esm/{recover-identity-AKGNTUJI.mjs → recover-identity-LJCY4BCJ.mjs} +4 -4
  62. package/dist/lib/node-esm/{recover-identity-AKGNTUJI.mjs.map → recover-identity-LJCY4BCJ.mjs.map} +1 -1
  63. package/dist/lib/node-esm/{redeem-passkey-FZO3LZ57.mjs → redeem-passkey-PT7QWFJE.mjs} +6 -22
  64. package/dist/lib/node-esm/redeem-passkey-PT7QWFJE.mjs.map +7 -0
  65. package/dist/lib/node-esm/{redeem-token-IHHIAIQ2.mjs → redeem-token-BHKHEXJM.mjs} +5 -13
  66. package/dist/lib/node-esm/redeem-token-BHKHEXJM.mjs.map +7 -0
  67. package/dist/lib/node-esm/{reset-storage-S5MJITI3.mjs → reset-storage-VPUZJOUV.mjs} +4 -4
  68. package/dist/lib/node-esm/{reset-storage-S5MJITI3.mjs.map → reset-storage-VPUZJOUV.mjs.map} +1 -1
  69. package/dist/lib/node-esm/{share-identity-QZLY3VHE.mjs → share-identity-SZ3REIRC.mjs} +4 -4
  70. package/dist/lib/node-esm/{share-identity-QZLY3VHE.mjs.map → share-identity-SZ3REIRC.mjs.map} +1 -1
  71. package/dist/lib/node-esm/testing/index.mjs.map +2 -2
  72. package/dist/lib/node-esm/translations.mjs +75 -0
  73. package/dist/lib/node-esm/translations.mjs.map +7 -0
  74. package/dist/lib/node-esm/types/index.mjs +1 -1
  75. package/dist/types/src/ClientPlugin.d.ts.map +1 -1
  76. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  77. package/dist/types/src/capabilities/client.d.ts +1 -1
  78. package/dist/types/src/capabilities/client.d.ts.map +1 -1
  79. package/dist/types/src/capabilities/index.d.ts +13 -13
  80. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  81. package/dist/types/src/capabilities/migrations.d.ts.map +1 -1
  82. package/dist/types/src/capabilities/navigation-handler/navigation-handler.d.ts.map +1 -1
  83. package/dist/types/src/capabilities/node.d.ts +13 -13
  84. package/dist/types/src/capabilities/node.d.ts.map +1 -1
  85. package/dist/types/src/capabilities/operation-handler.d.ts +1 -1
  86. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -1
  87. package/dist/types/src/capabilities/react-context.d.ts.map +1 -1
  88. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  89. package/dist/types/src/capabilities/schema-defs.d.ts.map +1 -1
  90. package/dist/types/src/cli/commands/config/index.d.ts +1 -1
  91. package/dist/types/src/cli/commands/config/view.d.ts +1 -1
  92. package/dist/types/src/cli/commands/device/util.d.ts.map +1 -1
  93. package/dist/types/src/cli/commands/halo/create/create.d.ts +2 -2
  94. package/dist/types/src/cli/commands/halo/credential/list/list.d.ts +2 -2
  95. package/dist/types/src/cli/commands/halo/join/join.d.ts +1 -1
  96. package/dist/types/src/cli/commands/halo/util.d.ts.map +1 -1
  97. package/dist/types/src/cli/commands/profile/create.d.ts +1 -1
  98. package/dist/types/src/cli/commands/profile/import.d.ts +2 -2
  99. package/dist/types/src/cli/commands/profile/index.d.ts +6 -6
  100. package/dist/types/src/cli/commands/profile/reset.d.ts +1 -1
  101. package/dist/types/src/cli/commands/profile/util.d.ts.map +1 -1
  102. package/dist/types/src/cli/testing/test-console.d.ts.map +1 -1
  103. package/dist/types/src/containers/DevicesContainer/DevicesContainer.d.ts.map +1 -1
  104. package/dist/types/src/containers/DevicesContainer/DevicesContainer.stories.d.ts +165 -165
  105. package/dist/types/src/containers/DevicesContainer/DevicesContainer.stories.d.ts.map +1 -1
  106. package/dist/types/src/containers/JoinDialog/JoinDialog.d.ts.map +1 -1
  107. package/dist/types/src/containers/JoinDialog/JoinDialog.stories.d.ts.map +1 -1
  108. package/dist/types/src/containers/ProfileContainer/ProfileContainer.stories.d.ts.map +1 -1
  109. package/dist/types/src/containers/RecoveryCodeDialog/RecoveryCodeDialog.d.ts.map +1 -1
  110. package/dist/types/src/containers/RecoveryCodeDialog/RecoveryCodeDialog.stories.d.ts.map +1 -1
  111. package/dist/types/src/containers/RecoveryCodeDialog/index.d.ts.map +1 -1
  112. package/dist/types/src/containers/RecoveryCredentialsContainer/RecoveryCredentialsContainer.stories.d.ts.map +1 -1
  113. package/dist/types/src/containers/ResetDialog/ResetDialog.d.ts.map +1 -1
  114. package/dist/types/src/containers/ResetDialog/ResetDialog.stories.d.ts +1 -1
  115. package/dist/types/src/containers/ResetDialog/ResetDialog.stories.d.ts.map +1 -1
  116. package/dist/types/src/containers/ResetDialog/index.d.ts.map +1 -1
  117. package/dist/types/src/operations/create-agent.d.ts +1 -1
  118. package/dist/types/src/operations/create-agent.d.ts.map +1 -1
  119. package/dist/types/src/operations/create-identity.d.ts +1 -1
  120. package/dist/types/src/operations/create-identity.d.ts.map +1 -1
  121. package/dist/types/src/operations/create-passkey.d.ts +1 -1
  122. package/dist/types/src/operations/create-passkey.d.ts.map +1 -1
  123. package/dist/types/src/operations/create-recovery-code.d.ts +1 -1
  124. package/dist/types/src/operations/create-recovery-code.d.ts.map +1 -1
  125. package/dist/types/src/operations/definitions.d.ts +1 -1
  126. package/dist/types/src/operations/definitions.d.ts.map +1 -1
  127. package/dist/types/src/operations/index.d.ts +1 -1
  128. package/dist/types/src/operations/index.d.ts.map +1 -1
  129. package/dist/types/src/operations/join-identity.d.ts +1 -1
  130. package/dist/types/src/operations/join-identity.d.ts.map +1 -1
  131. package/dist/types/src/operations/recover-identity.d.ts +1 -1
  132. package/dist/types/src/operations/recover-identity.d.ts.map +1 -1
  133. package/dist/types/src/operations/redeem-passkey.d.ts +1 -1
  134. package/dist/types/src/operations/redeem-passkey.d.ts.map +1 -1
  135. package/dist/types/src/operations/redeem-token.d.ts +1 -1
  136. package/dist/types/src/operations/redeem-token.d.ts.map +1 -1
  137. package/dist/types/src/operations/reset-storage.d.ts +1 -1
  138. package/dist/types/src/operations/reset-storage.d.ts.map +1 -1
  139. package/dist/types/src/operations/share-identity.d.ts +1 -1
  140. package/dist/types/src/operations/share-identity.d.ts.map +1 -1
  141. package/dist/types/src/testing/initializeIdentity.d.ts.map +1 -1
  142. package/dist/types/src/translations.d.ts.map +1 -1
  143. package/dist/types/src/types/capabilities.d.ts.map +1 -1
  144. package/dist/types/src/types/events.d.ts.map +1 -1
  145. package/dist/types/src/types/schema.d.ts.map +1 -1
  146. package/dist/types/tsconfig.tsbuildinfo +1 -1
  147. package/package.json +44 -37
  148. package/src/ClientPlugin.ts +1 -2
  149. package/src/capabilities/app-graph-builder.ts +1 -1
  150. package/src/capabilities/index.ts +1 -1
  151. package/src/capabilities/navigation-handler/navigation-handler.ts +1 -1
  152. package/src/capabilities/node.ts +1 -1
  153. package/src/capabilities/operation-handler.ts +1 -1
  154. package/src/containers/DevicesContainer/DevicesContainer.stories.tsx +1 -1
  155. package/src/containers/JoinDialog/JoinDialog.stories.tsx +2 -1
  156. package/src/containers/ProfileContainer/ProfileContainer.stories.tsx +2 -1
  157. package/src/containers/RecoveryCodeDialog/RecoveryCodeDialog.stories.tsx +2 -1
  158. package/src/containers/RecoveryCredentialsContainer/RecoveryCredentialsContainer.stories.tsx +1 -1
  159. package/src/containers/ResetDialog/ResetDialog.stories.tsx +2 -1
  160. package/src/operations/create-agent.ts +1 -1
  161. package/src/operations/create-identity.ts +1 -1
  162. package/src/operations/create-passkey.ts +1 -1
  163. package/src/operations/create-recovery-code.ts +1 -1
  164. package/src/operations/definitions.ts +1 -1
  165. package/src/operations/index.ts +1 -1
  166. package/src/operations/join-identity.ts +1 -1
  167. package/src/operations/recover-identity.ts +1 -1
  168. package/src/operations/redeem-passkey.ts +1 -1
  169. package/src/operations/redeem-token.ts +1 -1
  170. package/src/operations/reset-storage.ts +1 -1
  171. package/src/operations/share-identity.ts +1 -1
  172. package/src/translations.ts +2 -3
  173. package/dist/lib/browser/chunk-M43LJQ5U.mjs.map +0 -7
  174. package/dist/lib/browser/create-agent-SS5SE35J.mjs.map +0 -7
  175. package/dist/lib/browser/create-identity-PBEUEIPN.mjs.map +0 -7
  176. package/dist/lib/browser/create-passkey-JN6I5WMM.mjs.map +0 -7
  177. package/dist/lib/browser/create-recovery-code-32I6IWZC.mjs.map +0 -7
  178. package/dist/lib/browser/redeem-passkey-OCIV6VCK.mjs.map +0 -7
  179. package/dist/lib/browser/redeem-token-6BCRGKV6.mjs.map +0 -7
  180. package/dist/lib/node-esm/chunk-SJ6FDER5.mjs.map +0 -7
  181. package/dist/lib/node-esm/create-agent-QGEHMHBL.mjs.map +0 -7
  182. package/dist/lib/node-esm/create-identity-EHRJQOO4.mjs.map +0 -7
  183. package/dist/lib/node-esm/create-passkey-PFBHHBEQ.mjs.map +0 -7
  184. package/dist/lib/node-esm/create-recovery-code-HBAM2A72.mjs.map +0 -7
  185. package/dist/lib/node-esm/redeem-passkey-FZO3LZ57.mjs.map +0 -7
  186. package/dist/lib/node-esm/redeem-token-IHHIAIQ2.mjs.map +0 -7
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/operations/create-identity.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capabilities, Capability } from '@dxos/app-framework';\nimport { Operation } from '@dxos/compute';\nimport { runAndForwardErrors } from '@dxos/effect';\nimport { ObservabilityOperation } from '@dxos/plugin-observability/operations';\n\nimport { ClientEvents } from '../types';\nimport { ClientCapabilities } from '../types';\nimport { CreateIdentity } from './definitions';\n\nconst handler: Operation.WithHandler<typeof CreateIdentity> = CreateIdentity.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* (profile) {\n const manager = yield* Capability.get(Capabilities.PluginManager);\n const client = yield* Capability.get(ClientCapabilities.Client);\n const data = yield* Effect.promise(() => client.halo.createIdentity(profile));\n yield* Effect.promise(() => runAndForwardErrors(manager.activate(ClientEvents.IdentityCreated)));\n yield* Operation.schedule(ObservabilityOperation.SendEvent, { name: 'identity.create' });\n return data;\n }),\n ),\n);\n\nexport default handler;\n"],
5
+ "mappings": ";;;;;;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,cAAcC,kBAAkB;AACzC,SAASC,iBAAiB;AAC1B,SAASC,2BAA2B;AACpC,SAASC,8BAA8B;AAMvC,IAAMC,UAAwDC,eAAeC,KAC3EC,UAAUC,YACDC,kBAAW,WAAWC,SAAO;AAClC,QAAMC,UAAU,OAAOC,WAAWC,IAAIC,aAAaC,aAAa;AAChE,QAAMC,SAAS,OAAOJ,WAAWC,IAAII,mBAAmBC,MAAM;AAC9D,QAAMC,OAAO,OAAcC,eAAQ,MAAMJ,OAAOK,KAAKC,eAAeZ,OAAAA,CAAAA;AACpE,SAAcU,eAAQ,MAAMG,oBAAoBZ,QAAQa,SAASC,aAAaC,eAAe,CAAA,CAAA;AAC7F,SAAOnB,UAAUoB,SAASC,uBAAuBC,WAAW;IAAEC,MAAM;EAAkB,CAAA;AACtF,SAAOX;AACT,CAAA,CAAA,CAAA;AAIJ,IAAA,0BAAef;",
6
+ "names": ["Effect", "Capabilities", "Capability", "Operation", "runAndForwardErrors", "ObservabilityOperation", "handler", "CreateIdentity", "pipe", "Operation", "withHandler", "fnUntraced", "profile", "manager", "Capability", "get", "Capabilities", "PluginManager", "client", "ClientCapabilities", "Client", "data", "promise", "halo", "createIdentity", "runAndForwardErrors", "activate", "ClientEvents", "IdentityCreated", "schedule", "ObservabilityOperation", "SendEvent", "name"]
7
+ }
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  CreatePasskey
3
- } from "./chunk-M43LJQ5U.mjs";
3
+ } from "./chunk-RPMM5NKJ.mjs";
4
4
  import {
5
5
  ClientCapabilities
6
- } from "./chunk-WNJRYPGG.mjs";
6
+ } from "./chunk-M37DHX5L.mjs";
7
7
  import "./chunk-J5LGTIGS.mjs";
8
8
 
9
9
  // src/operations/create-passkey.ts
@@ -12,21 +12,13 @@ import * as Match from "effect/Match";
12
12
  import { Capability } from "@dxos/app-framework";
13
13
  import { supportsNativePasskeys, createNativePasskey, extractPublicKeyFromAttestation } from "@dxos/app-toolkit";
14
14
  import { PublicKey } from "@dxos/client";
15
+ import { Operation } from "@dxos/compute";
15
16
  import { invariant } from "@dxos/invariant";
16
- import { Operation } from "@dxos/operation";
17
17
  var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-client/src/operations/create-passkey.ts";
18
18
  var handler = CreatePasskey.pipe(Operation.withHandler(Effect.fnUntraced(function* () {
19
19
  const client = yield* Capability.get(ClientCapabilities.Client);
20
20
  const identity = client.halo.identity.get();
21
- invariant(identity, "Identity not available", {
22
- F: __dxlog_file,
23
- L: 22,
24
- S: this,
25
- A: [
26
- "identity",
27
- "'Identity not available'"
28
- ]
29
- });
21
+ invariant(identity, "Identity not available", { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 16, S: this, A: ["identity", "'Identity not available'"] });
30
22
  const lookupKey = PublicKey.random();
31
23
  const { recoveryKey, algorithm } = yield* Match.value(supportsNativePasskeys()).pipe(Match.when(true, () => Effect.gen(function* () {
32
24
  const result = yield* Effect.promise(() => createNativePasskey({
@@ -67,29 +59,13 @@ var handler = CreatePasskey.pipe(Operation.withHandler(Effect.fnUntraced(functio
67
59
  }
68
60
  }
69
61
  }));
70
- invariant(credential, "Credential not available", {
71
- F: __dxlog_file,
72
- L: 65,
73
- S: this,
74
- A: [
75
- "credential",
76
- "'Credential not available'"
77
- ]
78
- });
62
+ invariant(credential, "Credential not available", { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 57, S: this, A: ["credential", "'Credential not available'"] });
79
63
  return {
80
64
  recoveryKey: PublicKey.from(new Uint8Array(credential.response.getPublicKey())),
81
65
  algorithm: credential.response.getPublicKeyAlgorithm() === -7 ? "ES256" : "ED25519"
82
66
  };
83
67
  })));
84
- invariant(client.services.services.IdentityService, "IdentityService not available", {
85
- F: __dxlog_file,
86
- L: 74,
87
- S: this,
88
- A: [
89
- "client.services.services.IdentityService",
90
- "'IdentityService not available'"
91
- ]
92
- });
68
+ invariant(client.services.services.IdentityService, "IdentityService not available", { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 63, S: this, A: ["client.services.services.IdentityService", "'IdentityService not available'"] });
93
69
  yield* Effect.promise(() => client.services.services.IdentityService.createRecoveryCredential({
94
70
  data: {
95
71
  recoveryKey,
@@ -102,4 +78,4 @@ var create_passkey_default = handler;
102
78
  export {
103
79
  create_passkey_default as default
104
80
  };
105
- //# sourceMappingURL=create-passkey-JN6I5WMM.mjs.map
81
+ //# sourceMappingURL=create-passkey-NCP4XA7C.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/operations/create-passkey.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\nimport * as Match from 'effect/Match';\n\nimport { Capability } from '@dxos/app-framework';\nimport { supportsNativePasskeys, createNativePasskey, extractPublicKeyFromAttestation } from '@dxos/app-toolkit';\nimport { PublicKey } from '@dxos/client';\nimport { Operation } from '@dxos/compute';\nimport { invariant } from '@dxos/invariant';\n\nimport { ClientCapabilities } from '../types';\nimport { CreatePasskey } from './definitions';\n\nconst handler: Operation.WithHandler<typeof CreatePasskey> = CreatePasskey.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* () {\n const client = yield* Capability.get(ClientCapabilities.Client);\n const identity = client.halo.identity.get();\n invariant(identity, 'Identity not available');\n\n const lookupKey = PublicKey.random();\n\n const { recoveryKey, algorithm } = yield* Match.value(supportsNativePasskeys()).pipe(\n Match.when(true, () =>\n Effect.gen(function* () {\n const result = yield* Effect.promise(() =>\n createNativePasskey({\n username: identity.did,\n userId: lookupKey.asUint8Array(),\n }),\n );\n const { publicKey, algorithm: alg } = extractPublicKeyFromAttestation(result.attestation_object);\n return {\n recoveryKey: PublicKey.from(publicKey),\n algorithm: alg === -7 ? 'ES256' : 'ED25519',\n };\n }),\n ),\n Match.orElse(() =>\n Effect.gen(function* () {\n const credential = yield* Effect.promise(() =>\n navigator.credentials.create({\n publicKey: {\n challenge: new Uint8Array(),\n rp: { id: location.hostname, name: 'Composer' },\n user: {\n id: lookupKey.asUint8Array() as Uint8Array<ArrayBuffer>,\n name: identity.did,\n displayName: identity.profile?.displayName ?? '',\n },\n pubKeyCredParams: [\n { type: 'public-key', alg: -8 },\n { type: 'public-key', alg: -7 },\n ],\n authenticatorSelection: {\n residentKey: 'required',\n requireResidentKey: true,\n },\n },\n }),\n );\n invariant(credential, 'Credential not available');\n return {\n recoveryKey: PublicKey.from(new Uint8Array((credential as any).response.getPublicKey())),\n algorithm: (credential as any).response.getPublicKeyAlgorithm() === -7 ? 'ES256' : 'ED25519',\n };\n }),\n ),\n );\n\n invariant(client.services.services.IdentityService, 'IdentityService not available');\n yield* Effect.promise(() =>\n client.services.services.IdentityService!.createRecoveryCredential({\n data: {\n recoveryKey,\n algorithm,\n lookupKey,\n },\n }),\n );\n }),\n ),\n);\n\nexport default handler;\n"],
5
+ "mappings": ";;;;;;;;;AAIA,YAAYA,YAAY;AACxB,YAAYC,WAAW;AAEvB,SAASC,kBAAkB;AAC3B,SAASC,wBAAwBC,qBAAqBC,uCAAuC;AAC7F,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAK1B,IAAA,eAA6DC;IAIvD,UAAMC,cAAkBC,KAAKD,UAAY,YAAA,kBAAA,aAAA;AACzCE,QAAAA,SAAUF,OAAU,WAAA,IAAA,mBAAA,MAAA;AAEpB,QAAMG,WAAAA,OAAYC,KAAUC,SAAM,IAAA;AAElC,YAAQC,UAAW,0BAAuBC,EAAAA,YAAYC,YAAAA,GAAAA,cAA0BC,GAC9EF,IAAAA,GAAAA,MAAU,GAAC,CAAA,YACTG,0BAAW,EAAA,CAAA;oBACHC,UAAS,OAAOD;uBAElBE,UAAUZ,IAASa,OAAG,YAAA,uBAAA,CAAA,EAAA,KAAA,WAAA,MAAA,MAAA,WAAA,aAAA;mBACtBC,OAAkBC,eAAAA,MAAY,oBAAA;MAChC,UAAA,SAAA;MAEMC,QAAAA,UAAWC,aAAmBC;IACtC,CAAA,CAAA;UACEZ,EAAAA,WAAaF,WAAUe,IAAKH,IAAAA,gCAAAA,OAAAA,kBAAAA;WAC5BC;MACF,aAAA,UAAA,KAAA,SAAA;MAGJV,WAAa,QACXG,KAAU,UAAC;IACT;oBAEIM,MAAW,WAAA,aAAA;uBACTI,OAAeC,eAAAA,MAAAA,UAAAA,YAAAA,OAAAA;iBACX;mBAAMC,IAAAA,WAAiB;YAAEC;UAAiB,IAAA,SAAA;UAC9CC,MAAM;;cAEJD;UACAE,IAAAA,UAAazB,aAAS0B;UACxB,MAAA,SAAA;UACAC,aAAAA,SAAkB,SAAA,eAAA;;0BACR;;YAAsB,MAAA;YAC9B,KAAA;;;YAA8B,MAAA;YAC/B,KAAA;UACDC;;gCAEsB;UACtB,aAAA;UACF,oBAAA;QACF;MAEF1B;IACA,CAAA,CAAA;cACEI,YAAaF,4BAA+ByB,EAAAA,YAAmBC,YAASC,GAAAA,cAAY,GAAA,IAAA,GAAA,MAAA,GAAA,CAAA,cAAA,4BAAA,EAAA,CAAA;WACpFd;MACF,aAAA,UAAA,KAAA,IAAA,WAAA,WAAA,SAAA,aAAA,CAAA,CAAA;MACF,WAAA,WAAA,SAAA,sBAAA,MAAA,KAAA,UAAA;IAIJf;EACA,CAAA,CAAA,CAAOQ;YAEHsB,OAAM,SAAA,SAAA,iBAAA,iCAAA,EAAA,YAAA,YAAA,GAAA,cAAA,GAAA,IAAA,GAAA,MAAA,GAAA,CAAA,4CAAA,iCAAA,EAAA,CAAA;SACJ1B,eAAAA,MAAAA,OAAAA,SAAAA,SAAAA,gBAAAA,yBAAAA;UACAW;MACAd;MACF;MACF;IAEJ;EAIJ,CAAA,CAAA;;;",
6
+ "names": ["Effect", "Match", "Capability", "supportsNativePasskeys", "createNativePasskey", "extractPublicKeyFromAttestation", "PublicKey", "Operation", "invariant", "CreatePasskey", "identity", "halo", "invariant", "lookupKey", "PublicKey", "random", "recoveryKey", "Match", "supportsNativePasskeys", "pipe", "Effect", "result", "username", "did", "userId", "asUint8Array", "publicKey", "algorithm", "extractPublicKeyFromAttestation", "from", "challenge", "Uint8Array", "location", "name", "user", "displayName", "profile", "pubKeyCredParams", "authenticatorSelection", "credential", "response", "getPublicKey", "data"]
7
+ }
@@ -1,32 +1,24 @@
1
1
  import {
2
2
  RECOVERY_CODE_DIALOG
3
- } from "./chunk-ELAYKIQU.mjs";
3
+ } from "./chunk-VAIJSQYA.mjs";
4
4
  import {
5
5
  CreateRecoveryCode
6
- } from "./chunk-M43LJQ5U.mjs";
6
+ } from "./chunk-RPMM5NKJ.mjs";
7
7
  import {
8
8
  ClientCapabilities
9
- } from "./chunk-WNJRYPGG.mjs";
9
+ } from "./chunk-M37DHX5L.mjs";
10
10
  import "./chunk-J5LGTIGS.mjs";
11
11
 
12
12
  // src/operations/create-recovery-code.ts
13
13
  import * as Effect from "effect/Effect";
14
14
  import { Capability } from "@dxos/app-framework";
15
15
  import { LayoutOperation } from "@dxos/app-toolkit";
16
+ import { Operation } from "@dxos/compute";
16
17
  import { invariant } from "@dxos/invariant";
17
- import { Operation } from "@dxos/operation";
18
18
  var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-client/src/operations/create-recovery-code.ts";
19
19
  var handler = CreateRecoveryCode.pipe(Operation.withHandler(Effect.fnUntraced(function* () {
20
20
  const client = yield* Capability.get(ClientCapabilities.Client);
21
- invariant(client.services.services.IdentityService, "IdentityService not available", {
22
- F: __dxlog_file,
23
- L: 20,
24
- S: this,
25
- A: [
26
- "client.services.services.IdentityService",
27
- "'IdentityService not available'"
28
- ]
29
- });
21
+ invariant(client.services.services.IdentityService, "IdentityService not available", { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 14, S: this, A: ["client.services.services.IdentityService", "'IdentityService not available'"] });
30
22
  const { recoveryCode } = yield* Effect.promise(() => client.services.services.IdentityService.createRecoveryCredential({}));
31
23
  yield* Operation.invoke(LayoutOperation.UpdateDialog, {
32
24
  subject: RECOVERY_CODE_DIALOG,
@@ -41,4 +33,4 @@ var create_recovery_code_default = handler;
41
33
  export {
42
34
  create_recovery_code_default as default
43
35
  };
44
- //# sourceMappingURL=create-recovery-code-32I6IWZC.mjs.map
36
+ //# sourceMappingURL=create-recovery-code-L5LA3GAP.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/operations/create-recovery-code.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capability } from '@dxos/app-framework';\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/compute';\nimport { invariant } from '@dxos/invariant';\n\nimport { RECOVERY_CODE_DIALOG } from '../constants';\nimport { ClientCapabilities } from '../types';\nimport { CreateRecoveryCode } from './definitions';\n\nconst handler: Operation.WithHandler<typeof CreateRecoveryCode> = CreateRecoveryCode.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* () {\n const client = yield* Capability.get(ClientCapabilities.Client);\n invariant(client.services.services.IdentityService, 'IdentityService not available');\n const { recoveryCode } = yield* Effect.promise(() =>\n client.services.services.IdentityService!.createRecoveryCredential({}),\n );\n yield* Operation.invoke(LayoutOperation.UpdateDialog, {\n subject: RECOVERY_CODE_DIALOG,\n blockAlign: 'start',\n type: 'alert',\n props: { code: recoveryCode },\n });\n }),\n ),\n);\n\nexport default handler;\n"],
5
+ "mappings": ";;;;;;;;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,kBAAkB;AAC3B,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAM1B,IAAA,eAAkEC;IAI5DC,UAAUC,mBAAgBC,KAASC,UAAAA,YAAiB,kBAAA,aAAA;AACpD,QAAM,SAAEC,OAAc,WAAUC,IAAAA,mBAC9BJ,MAAOC;AAET,YAAOI,OAAUC,SAAOC,SAAAA,iBAA4B,iCAAE,EAAA,YAAA,YAAA,GAAA,cAAA,GAAA,IAAA,GAAA,MAAA,GAAA,CAAA,4CAAA,iCAAA,EAAA,CAAA;QACpDC,EAAAA,aAASC,IAAAA,OAAAA,eAAAA,MAAAA,OAAAA,SAAAA,SAAAA,gBAAAA,yBAAAA,CAAAA,CAAAA,CAAAA;SACTC,UAAY,OAAA,gBAAA,cAAA;IACZC,SAAM;IACNC,YAAO;UAAEC;IAAmB,OAAA;MAC9B,MAAA;IACF;EAIJ,CAAA;;;",
6
+ "names": ["Effect", "Capability", "LayoutOperation", "Operation", "invariant", "CreateRecoveryCode", "invariant", "client", "services", "IdentityService", "recoveryCode", "Effect", "Operation", "invoke", "LayoutOperation", "subject", "RECOVERY_CODE_DIALOG", "blockAlign", "type", "props", "code"]
7
+ }
@@ -4,80 +4,10 @@ import "./chunk-J5LGTIGS.mjs";
4
4
  import { ActivationEvent, ActivationEvents, Capability, Plugin } from "@dxos/app-framework";
5
5
  import { AppActivationEvents, AppPlugin } from "@dxos/app-toolkit";
6
6
  import { AppGraphBuilder, Client, Migrations, NavigationHandler, OperationHandler, ReactContext, ReactSurface, SchemaDefs } from "#capabilities";
7
- import { meta as meta2 } from "#meta";
8
- import { ClientEvents } from "#types";
9
-
10
- // src/translations.ts
11
- import { translations as shellTranslations } from "@dxos/shell/react";
12
7
  import { meta } from "#meta";
13
- var pluginTranslations = [
14
- {
15
- "en-US": {
16
- [meta.id]: {
17
- "account.label": "User profile",
18
- "profile.label": "Profile",
19
- "profile.description": "You can adjust how your user settings here.",
20
- "devices.label": "Devices",
21
- "add-device.label": "Add device",
22
- "devices-verbose.label": "Manage devices",
23
- "add-device.description": "Authenticating another device is a two-step process. To get started, create a code using the button below.",
24
- "devices.description": "You can add and remove devices, configure your agent in the cloud, reset this device, or log in as a different identity here.",
25
- "create-device-invitation.label": "Create code",
26
- "qr-code.description": "Scan this QR code using the device you want to log in to, or copy the URL and share it with the new device.",
27
- "security.label": "Security",
28
- "reset-device.description": "Log out from this device, erasing all the data on this\xA0device.",
29
- "join-new-identity.description": "Log out from this device, erasing all the data currently on this device, and use a QR code or URL to log\xA0in.",
30
- "recover-identity.description": "Log out from this device, erasing all the data currently on this device, and use a passkey or recovery code to log\xA0in.",
31
- "danger-zone.title": "Log out",
32
- "danger-zone.description": "Because Composer is decentralized, logging out entails erasing all the data on this device. If you have any data on this device that you\u2019d like to keep, you can log in on a separate device using a passkey or complete a peer-to-peer\xA0device invitation above.",
33
- "display-name.label": "Display name",
34
- "display-name.description": "Your name as it appears in the app.",
35
- "display-name-input.placeholder": "Enter a name",
36
- "icon.label": "Avatar",
37
- "icon.description": "The emoji used to represent the user.",
38
- "hue.label": "Color",
39
- "hue.description": "The color used to represent you in the app, including as your avatar\u2019s background, your cursor as it appears to others, and the messages you send in group threads.",
40
- "did.label": "DID",
41
- "did.description": "Your unique ID.",
42
- "open-user-account.label": "Open user account",
43
- "manage-credentials-dialog.title": "Manage Account Recovery",
44
- "credentials-list.label": "Recovery credentials",
45
- "no-credentials.title": "WARNING: There is currently no way to recover your account.",
46
- "no-credentials.message": "Create a recovery credential above to secure your\xA0account.",
47
- "recovery-setup-dialog.title": "Account Security",
48
- "recovery-setup-dialog.description": "In order to maintain access to your account you need to register a recovery credential. Passkeys are the recommended way to do this, they can be stored in your browser or in a password\xA0manager.",
49
- "create-passkey.label": "Create Passkey",
50
- // TODO(wittjosiah): At link to user-focused passkey information.
51
- // Something like https://www.tomsguide.com/news/what-are-passkeys.
52
- "create-passkey.description": "A passkey is a secure and easy to use credential that can be used to recover your\xA0account.",
53
- "create-recovery-code.label": "Create Recovery Code",
54
- "create-recovery-code.description": "A recovery code is 12 word phrase representing a private\xA0key.",
55
- "recovery-code-dialog.title": "Recovery Code",
56
- "recovery-code-dialog.description": "This is your identity recovery code, store it in a safe place. You can use it to recover your identity if you ever lose access to your\xA0devices.",
57
- "recovery-code-dialog-warning-1.message": "NOTE: This code will not be displayed\xA0again.",
58
- "recovery-code-dialog-warning-2.message": "It is your private key for recovering DXOS data. Anyone with this key will be able to gain access to your\xA0account.",
59
- "recovery-code-confirmation.label": "Please confirm you have saved the\xA0code.",
60
- "continue.label": "Continue",
61
- "auth-code.message": "Authorization code",
62
- "auth-other-device-emoji.message": "Authorization icon",
63
- "cancel.label": "Cancel",
64
- "join-new-identity.label": "Join an existing identity",
65
- "qr.label": "QR Code",
66
- "recover-identity.label": "Use a recovery code",
67
- "reset-device.label": "Reset storage",
68
- "reset-dialog.description": "Reset storage",
69
- "reset-dialog.title": "Reset storage"
70
- }
71
- }
72
- }
73
- ];
74
- var translations = [
75
- ...pluginTranslations,
76
- ...shellTranslations
77
- ];
78
-
79
- // src/ClientPlugin.ts
80
- var ClientPlugin = Plugin.define(meta2).pipe(AppPlugin.addAppGraphModule({
8
+ import { translations } from "#translations";
9
+ import { ClientEvents } from "#types";
10
+ var ClientPlugin = Plugin.define(meta).pipe(AppPlugin.addAppGraphModule({
81
11
  activate: AppGraphBuilder
82
12
  }), AppPlugin.addNavigationHandlerModule(({ invitationProp }) => ({
83
13
  activate: () => NavigationHandler({
@@ -128,7 +58,7 @@ var ClientPlugin = Plugin.define(meta2).pipe(AppPlugin.addAppGraphModule({
128
58
 
129
59
  // src/meta.ts
130
60
  import { trim } from "@dxos/util";
131
- var meta3 = {
61
+ var meta2 = {
132
62
  id: "org.dxos.plugin.client",
133
63
  name: "Client",
134
64
  description: trim`
@@ -138,6 +68,6 @@ var meta3 = {
138
68
  };
139
69
  export {
140
70
  ClientPlugin,
141
- meta3 as meta
71
+ meta2 as meta
142
72
  };
143
73
  //# sourceMappingURL=index.mjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/ClientPlugin.ts", "../../../src/translations.ts", "../../../src/meta.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { ActivationEvent, ActivationEvents, Capability, Plugin } from '@dxos/app-framework';\nimport { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';\n\nimport {\n AppGraphBuilder,\n Client,\n Migrations,\n NavigationHandler,\n OperationHandler,\n ReactContext,\n ReactSurface,\n SchemaDefs,\n} from '#capabilities';\nimport { meta } from '#meta';\nimport { ClientEvents } from '#types';\nimport { type ClientPluginOptions } from '#types';\n\nimport { translations } from './translations';\n\nexport const ClientPlugin = Plugin.define<ClientPluginOptions>(meta).pipe(\n AppPlugin.addAppGraphModule({ activate: AppGraphBuilder }),\n AppPlugin.addNavigationHandlerModule(({ invitationProp }) => ({\n activate: () => NavigationHandler({ invitationProp }),\n })),\n AppPlugin.addOperationHandlerModule({ activate: OperationHandler }),\n AppPlugin.addReactContextModule({ activate: ReactContext }),\n AppPlugin.addTranslationsModule({ translations }),\n Plugin.addModule((options) => {\n return {\n id: Capability.getModuleTag(Client),\n activatesOn: ActivationEvent.oneOf(ActivationEvents.Startup, AppActivationEvents.SetupAppGraph),\n firesAfterActivation: [ClientEvents.ClientReady],\n activate: () => Client(options),\n };\n }),\n Plugin.addModule({\n activatesOn: ClientEvents.ClientReady,\n firesBeforeActivation: [AppActivationEvents.SetupSchema],\n activate: SchemaDefs,\n }),\n Plugin.addModule({\n activatesOn: ClientEvents.ClientReady,\n firesBeforeActivation: [ClientEvents.SetupMigration],\n activate: Migrations,\n }),\n Plugin.addModule(\n ({\n shareableLinkOrigin = typeof window !== 'undefined' ? window.location.origin : 'http://localhost',\n invitationPath = '/',\n invitationProp = 'deviceInvitationCode',\n onReset,\n }) => {\n const createInvitationUrl = (invitationCode: string) => {\n const baseUrl = new URL(invitationPath || '/', shareableLinkOrigin);\n baseUrl.searchParams.set(invitationProp, invitationCode);\n return baseUrl.toString();\n };\n\n return {\n id: Capability.getModuleTag(ReactSurface),\n activatesOn: ActivationEvents.SetupReactSurface,\n activate: () => ReactSurface({ createInvitationUrl, onReset }),\n };\n },\n ),\n Plugin.make,\n);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Resource } from '@dxos/react-ui';\nimport { translations as shellTranslations } from '@dxos/shell/react';\n\nimport { meta } from '#meta';\n\n// TODO(burdon): Disambiguate with sdk/shell\nconst pluginTranslations = [\n {\n 'en-US': {\n [meta.id]: {\n 'account.label': 'User profile',\n 'profile.label': 'Profile',\n 'profile.description': 'You can adjust how your user settings here.',\n 'devices.label': 'Devices',\n 'add-device.label': 'Add device',\n 'devices-verbose.label': 'Manage devices',\n 'add-device.description':\n 'Authenticating another device is a two-step process. To get started, create a code using the button below.',\n 'devices.description':\n 'You can add and remove devices, configure your agent in the cloud, reset this device, or log in as a different identity here.',\n 'create-device-invitation.label': 'Create code',\n 'qr-code.description':\n 'Scan this QR code using the device you want to log in to, or copy the URL and share it with the new device.',\n 'security.label': 'Security',\n 'reset-device.description': 'Log out from this device, erasing all the data on this device.',\n 'join-new-identity.description':\n 'Log out from this device, erasing all the data currently on this device, and use a QR code or URL to log in.',\n 'recover-identity.description':\n 'Log out from this device, erasing all the data currently on this device, and use a passkey or recovery code to log in.',\n 'danger-zone.title': 'Log out',\n 'danger-zone.description':\n 'Because Composer is decentralized, logging out entails erasing all the data on this device. If you have any data on this device that you’d like to keep, you can log in on a separate device using a passkey or complete a peer-to-peer device invitation above.',\n 'display-name.label': 'Display name',\n 'display-name.description': 'Your name as it appears in the app.',\n 'display-name-input.placeholder': 'Enter a name',\n 'icon.label': 'Avatar',\n 'icon.description': 'The emoji used to represent the user.',\n 'hue.label': 'Color',\n 'hue.description':\n 'The color used to represent you in the app, including as your avatar’s background, your cursor as it appears to others, and the messages you send in group threads.',\n 'did.label': 'DID',\n 'did.description': 'Your unique ID.',\n 'open-user-account.label': 'Open user account',\n 'manage-credentials-dialog.title': 'Manage Account Recovery',\n 'credentials-list.label': 'Recovery credentials',\n 'no-credentials.title': 'WARNING: There is currently no way to recover your account.',\n 'no-credentials.message': 'Create a recovery credential above to secure your account.',\n 'recovery-setup-dialog.title': 'Account Security',\n 'recovery-setup-dialog.description':\n 'In order to maintain access to your account you need to register a recovery credential. Passkeys are the recommended way to do this, they can be stored in your browser or in a password manager.',\n 'create-passkey.label': 'Create Passkey',\n // TODO(wittjosiah): At link to user-focused passkey information.\n // Something like https://www.tomsguide.com/news/what-are-passkeys.\n 'create-passkey.description':\n 'A passkey is a secure and easy to use credential that can be used to recover your account.',\n 'create-recovery-code.label': 'Create Recovery Code',\n 'create-recovery-code.description': 'A recovery code is 12 word phrase representing a private key.',\n 'recovery-code-dialog.title': 'Recovery Code',\n 'recovery-code-dialog.description':\n 'This is your identity recovery code, store it in a safe place. You can use it to recover your identity if you ever lose access to your devices.',\n 'recovery-code-dialog-warning-1.message': 'NOTE: This code will not be displayed again.',\n 'recovery-code-dialog-warning-2.message':\n 'It is your private key for recovering DXOS data. Anyone with this key will be able to gain access to your account.',\n 'recovery-code-confirmation.label': 'Please confirm you have saved the code.',\n 'continue.label': 'Continue',\n 'auth-code.message': 'Authorization code',\n 'auth-other-device-emoji.message': 'Authorization icon',\n 'cancel.label': 'Cancel',\n 'join-new-identity.label': 'Join an existing identity',\n 'qr.label': 'QR Code',\n 'recover-identity.label': 'Use a recovery code',\n 'reset-device.label': 'Reset storage',\n 'reset-dialog.description': 'Reset storage',\n 'reset-dialog.title': 'Reset storage',\n },\n },\n },\n] as const satisfies Resource[];\n\nexport const translations: Resource[] = [...pluginTranslations, ...shellTranslations];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { trim } from '@dxos/util';\n\nexport const meta: Plugin.Meta = {\n id: 'org.dxos.plugin.client',\n name: 'Client',\n description: trim`\n Core client connectivity and peer-to-peer networking infrastructure.\n Manages identity, authentication, and real-time synchronization across devices.\n `,\n};\n"],
5
- "mappings": "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",
6
- "names": ["ActivationEvent", "ActivationEvents", "Capability", "Plugin", "AppActivationEvents", "AppPlugin", "AppGraphBuilder", "Client", "Migrations", "NavigationHandler", "OperationHandler", "ReactContext", "ReactSurface", "SchemaDefs", "meta", "ClientEvents", "translations", "shellTranslations", "meta", "pluginTranslations", "meta", "id", "translations", "shellTranslations", "ClientPlugin", "Plugin", "define", "meta", "pipe", "AppPlugin", "addAppGraphModule", "activate", "AppGraphBuilder", "addNavigationHandlerModule", "invitationProp", "NavigationHandler", "addOperationHandlerModule", "OperationHandler", "addReactContextModule", "ReactContext", "addTranslationsModule", "translations", "addModule", "options", "id", "Capability", "getModuleTag", "Client", "activatesOn", "ActivationEvent", "oneOf", "ActivationEvents", "Startup", "AppActivationEvents", "SetupAppGraph", "firesAfterActivation", "ClientEvents", "ClientReady", "firesBeforeActivation", "SetupSchema", "SchemaDefs", "SetupMigration", "Migrations", "shareableLinkOrigin", "window", "location", "origin", "invitationPath", "onReset", "createInvitationUrl", "invitationCode", "baseUrl", "URL", "searchParams", "set", "toString", "ReactSurface", "SetupReactSurface", "make", "trim", "meta", "id", "name", "description", "trim"]
3
+ "sources": ["../../../src/ClientPlugin.ts", "../../../src/meta.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { ActivationEvent, ActivationEvents, Capability, Plugin } from '@dxos/app-framework';\nimport { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';\n\nimport {\n AppGraphBuilder,\n Client,\n Migrations,\n NavigationHandler,\n OperationHandler,\n ReactContext,\n ReactSurface,\n SchemaDefs,\n} from '#capabilities';\nimport { meta } from '#meta';\nimport { translations } from '#translations';\nimport { ClientEvents } from '#types';\nimport { type ClientPluginOptions } from '#types';\n\nexport const ClientPlugin = Plugin.define<ClientPluginOptions>(meta).pipe(\n AppPlugin.addAppGraphModule({ activate: AppGraphBuilder }),\n AppPlugin.addNavigationHandlerModule(({ invitationProp }) => ({\n activate: () => NavigationHandler({ invitationProp }),\n })),\n AppPlugin.addOperationHandlerModule({ activate: OperationHandler }),\n AppPlugin.addReactContextModule({ activate: ReactContext }),\n AppPlugin.addTranslationsModule({ translations }),\n Plugin.addModule((options) => {\n return {\n id: Capability.getModuleTag(Client),\n activatesOn: ActivationEvent.oneOf(ActivationEvents.Startup, AppActivationEvents.SetupAppGraph),\n firesAfterActivation: [ClientEvents.ClientReady],\n activate: () => Client(options),\n };\n }),\n Plugin.addModule({\n activatesOn: ClientEvents.ClientReady,\n firesBeforeActivation: [AppActivationEvents.SetupSchema],\n activate: SchemaDefs,\n }),\n Plugin.addModule({\n activatesOn: ClientEvents.ClientReady,\n firesBeforeActivation: [ClientEvents.SetupMigration],\n activate: Migrations,\n }),\n Plugin.addModule(\n ({\n shareableLinkOrigin = typeof window !== 'undefined' ? window.location.origin : 'http://localhost',\n invitationPath = '/',\n invitationProp = 'deviceInvitationCode',\n onReset,\n }) => {\n const createInvitationUrl = (invitationCode: string) => {\n const baseUrl = new URL(invitationPath || '/', shareableLinkOrigin);\n baseUrl.searchParams.set(invitationProp, invitationCode);\n return baseUrl.toString();\n };\n\n return {\n id: Capability.getModuleTag(ReactSurface),\n activatesOn: ActivationEvents.SetupReactSurface,\n activate: () => ReactSurface({ createInvitationUrl, onReset }),\n };\n },\n ),\n Plugin.make,\n);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { trim } from '@dxos/util';\n\nexport const meta: Plugin.Meta = {\n id: 'org.dxos.plugin.client',\n name: 'Client',\n description: trim`\n Core client connectivity and peer-to-peer networking infrastructure.\n Manages identity, authentication, and real-time synchronization across devices.\n `,\n};\n"],
5
+ "mappings": ";;;AAIA,SAASA,iBAAiBC,kBAAkBC,YAAYC,cAAc;AACtE,SAASC,qBAAqBC,iBAAiB;AAE/C,SACEC,iBACAC,QACAC,YACAC,mBACAC,kBACAC,cACAC,cACAC,kBACK;AACP,SAASC,YAAY;AACrB,SAASC,oBAAoB;AAC7B,SAASC,oBAAoB;AAGtB,IAAMC,eAAed,OAAOe,OAA4BJ,IAAAA,EAAMK,KACnEd,UAAUe,kBAAkB;EAAEC,UAAUf;AAAgB,CAAA,GACxDD,UAAUiB,2BAA2B,CAAC,EAAEC,eAAc,OAAQ;EAC5DF,UAAU,MAAMZ,kBAAkB;IAAEc;EAAe,CAAA;AACrD,EAAA,GACAlB,UAAUmB,0BAA0B;EAAEH,UAAUX;AAAiB,CAAA,GACjEL,UAAUoB,sBAAsB;EAAEJ,UAAUV;AAAa,CAAA,GACzDN,UAAUqB,sBAAsB;EAAEX;AAAa,CAAA,GAC/CZ,OAAOwB,UAAU,CAACC,YAAAA;AAChB,SAAO;IACLC,IAAI3B,WAAW4B,aAAavB,MAAAA;IAC5BwB,aAAa/B,gBAAgBgC,MAAM/B,iBAAiBgC,SAAS7B,oBAAoB8B,aAAa;IAC9FC,sBAAsB;MAACnB,aAAaoB;;IACpCf,UAAU,MAAMd,OAAOqB,OAAAA;EACzB;AACF,CAAA,GACAzB,OAAOwB,UAAU;EACfI,aAAaf,aAAaoB;EAC1BC,uBAAuB;IAACjC,oBAAoBkC;;EAC5CjB,UAAUR;AACZ,CAAA,GACAV,OAAOwB,UAAU;EACfI,aAAaf,aAAaoB;EAC1BC,uBAAuB;IAACrB,aAAauB;;EACrClB,UAAUb;AACZ,CAAA,GACAL,OAAOwB,UACL,CAAC,EACCa,sBAAsB,OAAOC,WAAW,cAAcA,OAAOC,SAASC,SAAS,oBAC/EC,iBAAiB,KACjBrB,iBAAiB,wBACjBsB,QAAO,MACR;AACC,QAAMC,sBAAsB,CAACC,mBAAAA;AAC3B,UAAMC,UAAU,IAAIC,IAAIL,kBAAkB,KAAKJ,mBAAAA;AAC/CQ,YAAQE,aAAaC,IAAI5B,gBAAgBwB,cAAAA;AACzC,WAAOC,QAAQI,SAAQ;EACzB;AAEA,SAAO;IACLvB,IAAI3B,WAAW4B,aAAalB,YAAAA;IAC5BmB,aAAa9B,iBAAiBoD;IAC9BhC,UAAU,MAAMT,aAAa;MAAEkC;MAAqBD;IAAQ,CAAA;EAC9D;AACF,CAAA,GAEF1C,OAAOmD,IAAI;;;AC/Db,SAASC,YAAY;AAEd,IAAMC,QAAoB;EAC/BC,IAAI;EACJC,MAAM;EACNC,aAAaJ;;;;AAIf;",
6
+ "names": ["ActivationEvent", "ActivationEvents", "Capability", "Plugin", "AppActivationEvents", "AppPlugin", "AppGraphBuilder", "Client", "Migrations", "NavigationHandler", "OperationHandler", "ReactContext", "ReactSurface", "SchemaDefs", "meta", "translations", "ClientEvents", "ClientPlugin", "define", "pipe", "addAppGraphModule", "activate", "addNavigationHandlerModule", "invitationProp", "addOperationHandlerModule", "addReactContextModule", "addTranslationsModule", "addModule", "options", "id", "getModuleTag", "activatesOn", "oneOf", "Startup", "SetupAppGraph", "firesAfterActivation", "ClientReady", "firesBeforeActivation", "SetupSchema", "SetupMigration", "shareableLinkOrigin", "window", "location", "origin", "invitationPath", "onReset", "createInvitationUrl", "invitationCode", "baseUrl", "URL", "searchParams", "set", "toString", "SetupReactSurface", "make", "trim", "meta", "id", "name", "description"]
7
7
  }
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  JOIN_DIALOG
3
- } from "./chunk-ELAYKIQU.mjs";
3
+ } from "./chunk-VAIJSQYA.mjs";
4
4
  import {
5
5
  JoinIdentity
6
- } from "./chunk-M43LJQ5U.mjs";
6
+ } from "./chunk-RPMM5NKJ.mjs";
7
7
  import "./chunk-J5LGTIGS.mjs";
8
8
 
9
9
  // src/operations/join-identity.ts
10
10
  import * as Effect from "effect/Effect";
11
11
  import { LayoutOperation } from "@dxos/app-toolkit";
12
- import { Operation } from "@dxos/operation";
12
+ import { Operation } from "@dxos/compute";
13
13
  var handler = JoinIdentity.pipe(Operation.withHandler(Effect.fnUntraced(function* (data) {
14
14
  yield* Operation.invoke(LayoutOperation.UpdateDialog, {
15
15
  subject: JOIN_DIALOG,
@@ -24,4 +24,4 @@ var join_identity_default = handler;
24
24
  export {
25
25
  join_identity_default as default
26
26
  };
27
- //# sourceMappingURL=join-identity-2BP4G2SD.mjs.map
27
+ //# sourceMappingURL=join-identity-3W6PJLKN.mjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/operations/join-identity.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nimport { JOIN_DIALOG } from '../constants';\nimport { JoinIdentity } from './definitions';\n\nconst handler: Operation.WithHandler<typeof JoinIdentity> = JoinIdentity.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* (data) {\n yield* Operation.invoke(LayoutOperation.UpdateDialog, {\n subject: JOIN_DIALOG,\n blockAlign: 'start',\n props: {\n initialInvitationCode: data.invitationCode,\n initialDisposition: 'accept-halo-invitation',\n },\n });\n }),\n ),\n);\n\nexport default handler;\n"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/compute';\n\nimport { JOIN_DIALOG } from '../constants';\nimport { JoinIdentity } from './definitions';\n\nconst handler: Operation.WithHandler<typeof JoinIdentity> = JoinIdentity.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* (data) {\n yield* Operation.invoke(LayoutOperation.UpdateDialog, {\n subject: JOIN_DIALOG,\n blockAlign: 'start',\n props: {\n initialInvitationCode: data.invitationCode,\n initialDisposition: 'accept-halo-invitation',\n },\n });\n }),\n ),\n);\n\nexport default handler;\n"],
5
5
  "mappings": ";;;;;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAK1B,IAAMC,UAAsDC,aAAaC,KACvEC,UAAUC,YACDC,kBAAW,WAAWC,MAAI;AAC/B,SAAOH,UAAUI,OAAOC,gBAAgBC,cAAc;IACpDC,SAASC;IACTC,YAAY;IACZC,OAAO;MACLC,uBAAuBR,KAAKS;MAC5BC,oBAAoB;IACtB;EACF,CAAA;AACF,CAAA,CAAA,CAAA;AAIJ,IAAA,wBAAehB;",
6
6
  "names": ["Effect", "LayoutOperation", "Operation", "handler", "JoinIdentity", "pipe", "Operation", "withHandler", "fnUntraced", "data", "invoke", "LayoutOperation", "UpdateDialog", "subject", "JOIN_DIALOG", "blockAlign", "props", "initialInvitationCode", "invitationCode", "initialDisposition"]
7
7
  }