@dxos/shell 0.4.7-next.7a94090 → 0.4.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle/shell.mjs +61697 -61655
- package/dist/bundle/shell.mjs.map +1 -1
- package/dist/bundle/shell.umd.js +70 -69
- package/dist/bundle/shell.umd.js.map +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/react.mjs +103 -78
- package/dist/lib/browser/react.mjs.map +3 -3
- package/dist/types/src/components/Clipboard/CopyButton.d.ts +1 -0
- package/dist/types/src/components/Clipboard/CopyButton.d.ts.map +1 -1
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.d.ts +1 -0
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.d.ts.map +1 -1
- package/dist/types/src/components/EmojiPicker.js.map +1 -1
- package/dist/types/src/components/IdentityList/DeviceList.d.ts +1 -0
- package/dist/types/src/components/IdentityList/DeviceList.d.ts.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.d.ts +1 -0
- package/dist/types/src/components/IdentityList/SpaceMemberList.d.ts.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.d.ts +1 -0
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationList.stories.d.ts +1 -0
- package/dist/types/src/components/InvitationList/InvitationList.stories.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationListContainer.d.ts +1 -0
- package/dist/types/src/components/InvitationList/InvitationListContainer.d.ts.map +1 -1
- package/dist/types/src/components/Panel/CloseButton.d.ts +1 -0
- package/dist/types/src/components/Panel/CloseButton.d.ts.map +1 -1
- package/dist/types/src/components/Panel/Panel.stories.d.ts +1 -0
- package/dist/types/src/components/Panel/Panel.stories.d.ts.map +1 -1
- package/dist/types/src/components/Viewport/Viewport.js.map +1 -1
- package/dist/types/src/components/Viewport/Viewport.stories.d.ts +1 -0
- package/dist/types/src/components/Viewport/Viewport.stories.d.ts.map +1 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.d.ts +1 -0
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.d.ts.map +1 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.js +1 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.js.map +1 -1
- package/dist/types/src/composites/JoinDialog/JoinDialog.d.ts +1 -0
- package/dist/types/src/composites/JoinDialog/JoinDialog.d.ts.map +1 -1
- package/dist/types/src/composites/JoinDialog/JoinDialog.js +2 -2
- package/dist/types/src/composites/JoinDialog/JoinDialog.js.map +1 -1
- package/dist/types/src/composites/Shell/Shell.d.ts +1 -0
- package/dist/types/src/composites/Shell/Shell.d.ts.map +1 -1
- package/dist/types/src/composites/Shell/Shell.js.map +1 -1
- package/dist/types/src/composites/Shell/ShellContext.js.map +1 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.d.ts +1 -0
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.d.ts.map +1 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.js +1 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.js +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/AgentForm.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/steps/AgentForm.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/DeviceManager.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/steps/DeviceManager.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.js +2 -1
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/SignOutChooser.d.ts +1 -0
- package/dist/types/src/panels/IdentityPanel/steps/SignOutChooser.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/SignOutChooser.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/useAgentHandlers.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/useAgentHandlers.js +2 -1
- package/dist/types/src/panels/IdentityPanel/useAgentHandlers.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/JoinPanel.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/joinMachine.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/ResetIdentity.d.ts +1 -0
- package/dist/types/src/panels/JoinPanel/steps/ResetIdentity.d.ts.map +1 -1
- package/dist/types/src/panels/Panels.stories.d.ts.map +1 -1
- package/dist/types/src/panels/Panels.stories.js +1 -3
- package/dist/types/src/panels/Panels.stories.js.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.d.ts +1 -0
- package/dist/types/src/panels/SpacePanel/SpacePanel.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.js.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.d.ts +1 -0
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.js +2 -1
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.js.map +1 -1
- package/dist/types/src/playwright/invitations-manager.js.map +1 -1
- package/dist/types/src/steps/InvitationManager.d.ts +1 -0
- package/dist/types/src/steps/InvitationManager.d.ts.map +1 -1
- package/dist/types/src/steps/InvitationManager.js.map +1 -1
- package/dist/types/src/stories/Invitations.e2e-stories.d.ts +1 -0
- package/dist/types/src/stories/Invitations.e2e-stories.d.ts.map +1 -1
- package/dist/types/src/stories/Invitations.e2e-stories.js +3 -2
- package/dist/types/src/stories/Invitations.e2e-stories.js.map +1 -1
- package/dist/types/src/testing/scoped-shell-manager.js.map +1 -1
- package/dist/types/src/testing/shell-manager.js.map +1 -1
- package/package.json +19 -19
- package/src/panels/IdentityPanel/IdentityPanel.tsx +1 -1
- package/src/panels/IdentityPanel/steps/IdentityActionChooser.tsx +2 -1
- package/src/panels/IdentityPanel/useAgentHandlers.ts +2 -1
- package/src/panels/Panels.stories.tsx +1 -3
- package/src/panels/SpacePanel/steps/SpaceManager.tsx +2 -1
- package/src/stories/Invitations.e2e-stories.tsx +3 -2
|
@@ -908,7 +908,7 @@ import { Dialog, useId as useId9 } from "@dxos/react-ui";
|
|
|
908
908
|
// packages/sdk/shell/src/panels/IdentityPanel/IdentityPanel.tsx
|
|
909
909
|
import React29, { useEffect as useEffect3, useMemo as useMemo3 } from "react";
|
|
910
910
|
import { generateName as generateName3 } from "@dxos/display-name";
|
|
911
|
-
import { log as
|
|
911
|
+
import { log as log5 } from "@dxos/log";
|
|
912
912
|
import { useClient as useClient3 } from "@dxos/react-client";
|
|
913
913
|
import { useIdentity, useDevices, useHaloInvitations as useHaloInvitations2 } from "@dxos/react-client/halo";
|
|
914
914
|
import { useInvitationStatus as useInvitationStatus2 } from "@dxos/react-client/invitations";
|
|
@@ -1098,11 +1098,13 @@ var DeviceManager = ({ devices, active, send }) => {
|
|
|
1098
1098
|
// packages/sdk/shell/src/panels/IdentityPanel/steps/IdentityActionChooser.tsx
|
|
1099
1099
|
import { CaretRight, Devices, Plus, Power, UserGear, HardDrive } from "@phosphor-icons/react";
|
|
1100
1100
|
import React25, { useCallback as useCallback4 } from "react";
|
|
1101
|
+
import { log as log2 } from "@dxos/log";
|
|
1101
1102
|
import { useAgentHostingProviderClient, useClient as useClient2 } from "@dxos/react-client";
|
|
1102
1103
|
import { useHaloInvitations } from "@dxos/react-client/halo";
|
|
1103
1104
|
import { Invitation as Invitation2, InvitationEncoder } from "@dxos/react-client/invitations";
|
|
1104
1105
|
import { DensityProvider, useTranslation as useTranslation11 } from "@dxos/react-ui";
|
|
1105
1106
|
import { getSize as getSize8 } from "@dxos/react-ui-theme";
|
|
1107
|
+
var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/IdentityPanel/steps/IdentityActionChooser.tsx";
|
|
1106
1108
|
var IdentityActionChooser = (props) => {
|
|
1107
1109
|
const { send } = props;
|
|
1108
1110
|
const client = useClient2();
|
|
@@ -1111,10 +1113,15 @@ var IdentityActionChooser = (props) => {
|
|
|
1111
1113
|
const onInvitationEvent = useCallback4((invitation) => {
|
|
1112
1114
|
const invitationCode = InvitationEncoder.encode(invitation);
|
|
1113
1115
|
if (invitation.state === Invitation2.State.CONNECTING) {
|
|
1114
|
-
|
|
1116
|
+
log2.info(JSON.stringify({
|
|
1115
1117
|
invitationCode,
|
|
1116
1118
|
authCode: invitation.authCode
|
|
1117
|
-
})
|
|
1119
|
+
}), void 0, {
|
|
1120
|
+
F: __dxlog_file2,
|
|
1121
|
+
L: 28,
|
|
1122
|
+
S: void 0,
|
|
1123
|
+
C: (f, a) => f(...a)
|
|
1124
|
+
});
|
|
1118
1125
|
}
|
|
1119
1126
|
}, []);
|
|
1120
1127
|
const createInvitation = (e) => {
|
|
@@ -1216,18 +1223,18 @@ var IdentityActionChooserImpl = ({ onCreateInvitationClick, active, send, onDone
|
|
|
1216
1223
|
|
|
1217
1224
|
// packages/sdk/shell/src/panels/IdentityPanel/steps/ProfileForm.tsx
|
|
1218
1225
|
import React26, { useState as useState4 } from "react";
|
|
1219
|
-
import { log as
|
|
1226
|
+
import { log as log3 } from "@dxos/log";
|
|
1220
1227
|
import { useTranslation as useTranslation12 } from "@dxos/react-ui";
|
|
1221
1228
|
import { hexToEmoji as hexToEmoji2, hexToHue } from "@dxos/util";
|
|
1222
|
-
var
|
|
1229
|
+
var __dxlog_file3 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/IdentityPanel/steps/ProfileForm.tsx";
|
|
1223
1230
|
var ProfileForm = (props) => {
|
|
1224
1231
|
const { onUpdateProfile } = props;
|
|
1225
1232
|
const { t } = useTranslation12("os");
|
|
1226
1233
|
const [validationMessage, setValidationMessage] = useState4("");
|
|
1227
1234
|
const handleUpdateProfile = async (profile) => {
|
|
1228
1235
|
await onUpdateProfile?.(profile).catch((error) => {
|
|
1229
|
-
|
|
1230
|
-
F:
|
|
1236
|
+
log3.catch(error, void 0, {
|
|
1237
|
+
F: __dxlog_file3,
|
|
1231
1238
|
L: 33,
|
|
1232
1239
|
S: void 0,
|
|
1233
1240
|
C: (f, a) => f(...a)
|
|
@@ -1363,9 +1370,10 @@ var SignOutChooserImpl = ({ disabled, onResetDevice, onJoinNewIdentity, onBack }
|
|
|
1363
1370
|
// packages/sdk/shell/src/panels/IdentityPanel/useAgentHandlers.ts
|
|
1364
1371
|
import { useCallback as useCallback5, useEffect as useEffect2, useState as useState5 } from "react";
|
|
1365
1372
|
import { invariant } from "@dxos/invariant";
|
|
1373
|
+
import { log as log4 } from "@dxos/log";
|
|
1366
1374
|
import { useAgentHostingProviderClient as useAgentHostingProviderClient2 } from "@dxos/react-client";
|
|
1367
1375
|
import { Invitation as Invitation3, InvitationEncoder as InvitationEncoder2 } from "@dxos/react-client/invitations";
|
|
1368
|
-
var
|
|
1376
|
+
var __dxlog_file4 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/IdentityPanel/useAgentHandlers.ts";
|
|
1369
1377
|
var useAgentHandlers = ({ client, invitations, identity }) => {
|
|
1370
1378
|
const [validationMessage, setValidationMessage] = useState5("");
|
|
1371
1379
|
const [agentStatus, setAgentStatus] = useState5("");
|
|
@@ -1391,14 +1399,19 @@ var useAgentHandlers = ({ client, invitations, identity }) => {
|
|
|
1391
1399
|
const handleAgentCreate = useCallback5(async (invitation) => {
|
|
1392
1400
|
const invitationCode = InvitationEncoder2.encode(invitation);
|
|
1393
1401
|
if (invitation.state === Invitation3.State.CONNECTING) {
|
|
1394
|
-
|
|
1402
|
+
log4.info(JSON.stringify({
|
|
1395
1403
|
invitationCode,
|
|
1396
1404
|
authCode: invitation.authCode
|
|
1397
|
-
})
|
|
1398
|
-
|
|
1399
|
-
F: __dxlog_file3,
|
|
1405
|
+
}), void 0, {
|
|
1406
|
+
F: __dxlog_file4,
|
|
1400
1407
|
L: 50,
|
|
1401
1408
|
S: void 0,
|
|
1409
|
+
C: (f, a) => f(...a)
|
|
1410
|
+
});
|
|
1411
|
+
invariant(identity, "Identity not found", {
|
|
1412
|
+
F: __dxlog_file4,
|
|
1413
|
+
L: 51,
|
|
1414
|
+
S: void 0,
|
|
1402
1415
|
A: [
|
|
1403
1416
|
"identity",
|
|
1404
1417
|
"'Identity not found'"
|
|
@@ -1427,8 +1440,8 @@ var useAgentHandlers = ({ client, invitations, identity }) => {
|
|
|
1427
1440
|
const onAgentDestroy = async () => {
|
|
1428
1441
|
const identity2 = client.halo.identity.get();
|
|
1429
1442
|
invariant(identity2, "Identity not found", {
|
|
1430
|
-
F:
|
|
1431
|
-
L:
|
|
1443
|
+
F: __dxlog_file4,
|
|
1444
|
+
L: 77,
|
|
1432
1445
|
S: void 0,
|
|
1433
1446
|
A: [
|
|
1434
1447
|
"identity",
|
|
@@ -1581,7 +1594,7 @@ var InvitationManager = ({ invitationUrl, active, send, status, type, authCode,
|
|
|
1581
1594
|
};
|
|
1582
1595
|
|
|
1583
1596
|
// packages/sdk/shell/src/panels/IdentityPanel/IdentityPanel.tsx
|
|
1584
|
-
var
|
|
1597
|
+
var __dxlog_file5 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/IdentityPanel/IdentityPanel.tsx";
|
|
1585
1598
|
var viewStyles = "pbs-1 pbe-3 pli-3";
|
|
1586
1599
|
var IdentityHeading = ({ titleId, title, identity, onDone }) => {
|
|
1587
1600
|
const fallbackValue = keyToFallback2(identity.identityKey);
|
|
@@ -1693,14 +1706,19 @@ var IdentityPanel = ({ titleId: propsTitleId, createInvitationUrl = (code) => co
|
|
|
1693
1706
|
invitations
|
|
1694
1707
|
});
|
|
1695
1708
|
if (!identity) {
|
|
1696
|
-
|
|
1709
|
+
log5.error("IdentityPanel rendered with no active identity.", void 0, {
|
|
1710
|
+
F: __dxlog_file5,
|
|
1711
|
+
L: 132,
|
|
1712
|
+
S: void 0,
|
|
1713
|
+
C: (f, a) => f(...a)
|
|
1714
|
+
});
|
|
1697
1715
|
return null;
|
|
1698
1716
|
}
|
|
1699
1717
|
const [identityState, identitySend, identityService] = useIdentityMachine(client);
|
|
1700
1718
|
useEffect3(() => {
|
|
1701
1719
|
const subscription = identityService.subscribe((state) => {
|
|
1702
|
-
|
|
1703
|
-
F:
|
|
1720
|
+
log5("[state]", state, {
|
|
1721
|
+
F: __dxlog_file5,
|
|
1704
1722
|
L: 139,
|
|
1705
1723
|
S: void 0,
|
|
1706
1724
|
C: (f, a) => f(...a)
|
|
@@ -1769,7 +1787,7 @@ var IdentityPanel = ({ titleId: propsTitleId, createInvitationUrl = (code) => co
|
|
|
1769
1787
|
|
|
1770
1788
|
// packages/sdk/shell/src/panels/JoinPanel/JoinPanel.tsx
|
|
1771
1789
|
import React39, { useCallback as useCallback7, useEffect as useEffect5, useMemo as useMemo4 } from "react";
|
|
1772
|
-
import { log as
|
|
1790
|
+
import { log as log10 } from "@dxos/log";
|
|
1773
1791
|
import { useClient as useClient6, useMulticastObservable } from "@dxos/react-client";
|
|
1774
1792
|
import { useIdentity as useIdentity2 } from "@dxos/react-client/halo";
|
|
1775
1793
|
import { DensityProvider as DensityProvider3, useId as useId7, useThemeContext as useThemeContext4 } from "@dxos/react-ui";
|
|
@@ -1811,13 +1829,13 @@ var JoinHeading = /* @__PURE__ */ forwardRef8(({ mode, titleId, onExit, exitActi
|
|
|
1811
1829
|
import { useMachine as useMachine2 } from "@xstate/react";
|
|
1812
1830
|
import { useCallback as useCallback6 } from "react";
|
|
1813
1831
|
import { assign as assign2, createMachine as createMachine2 } from "xstate";
|
|
1814
|
-
import { log as
|
|
1832
|
+
import { log as log6 } from "@dxos/log";
|
|
1815
1833
|
import { AlreadyJoinedError } from "@dxos/react-client";
|
|
1816
1834
|
import { Invitation as Invitation6, InvitationEncoder as InvitationEncoder3 } from "@dxos/react-client/invitations";
|
|
1817
|
-
var
|
|
1835
|
+
var __dxlog_file6 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/JoinPanel/joinMachine.ts";
|
|
1818
1836
|
var getInvitationSubscribable = (Kind, invitation) => {
|
|
1819
|
-
|
|
1820
|
-
F:
|
|
1837
|
+
log6("[subscribing to invitation]", invitation, {
|
|
1838
|
+
F: __dxlog_file6,
|
|
1821
1839
|
L: 88,
|
|
1822
1840
|
S: void 0,
|
|
1823
1841
|
C: (f, a) => f(...a)
|
|
@@ -1826,11 +1844,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1826
1844
|
subscribe: (next, onError, complete) => invitation.subscribe((invitation2) => {
|
|
1827
1845
|
switch (invitation2.state) {
|
|
1828
1846
|
case Invitation6.State.CONNECTING: {
|
|
1829
|
-
|
|
1847
|
+
log6("[invitation connecting]", {
|
|
1830
1848
|
Kind,
|
|
1831
1849
|
invitation: invitation2
|
|
1832
1850
|
}, {
|
|
1833
|
-
F:
|
|
1851
|
+
F: __dxlog_file6,
|
|
1834
1852
|
L: 99,
|
|
1835
1853
|
S: void 0,
|
|
1836
1854
|
C: (f, a) => f(...a)
|
|
@@ -1841,11 +1859,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1841
1859
|
});
|
|
1842
1860
|
}
|
|
1843
1861
|
case Invitation6.State.CONNECTED: {
|
|
1844
|
-
|
|
1862
|
+
log6("[invitation connected]", {
|
|
1845
1863
|
Kind,
|
|
1846
1864
|
invitation: invitation2
|
|
1847
1865
|
}, {
|
|
1848
|
-
F:
|
|
1866
|
+
F: __dxlog_file6,
|
|
1849
1867
|
L: 104,
|
|
1850
1868
|
S: void 0,
|
|
1851
1869
|
C: (f, a) => f(...a)
|
|
@@ -1856,11 +1874,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1856
1874
|
});
|
|
1857
1875
|
}
|
|
1858
1876
|
case Invitation6.State.READY_FOR_AUTHENTICATION: {
|
|
1859
|
-
|
|
1877
|
+
log6("[invitation ready for authentication]", {
|
|
1860
1878
|
Kind,
|
|
1861
1879
|
invitation: invitation2
|
|
1862
1880
|
}, {
|
|
1863
|
-
F:
|
|
1881
|
+
F: __dxlog_file6,
|
|
1864
1882
|
L: 109,
|
|
1865
1883
|
S: void 0,
|
|
1866
1884
|
C: (f, a) => f(...a)
|
|
@@ -1871,11 +1889,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1871
1889
|
});
|
|
1872
1890
|
}
|
|
1873
1891
|
case Invitation6.State.AUTHENTICATING: {
|
|
1874
|
-
|
|
1892
|
+
log6("[invitation authenticating]", {
|
|
1875
1893
|
Kind,
|
|
1876
1894
|
invitation: invitation2
|
|
1877
1895
|
}, {
|
|
1878
|
-
F:
|
|
1896
|
+
F: __dxlog_file6,
|
|
1879
1897
|
L: 114,
|
|
1880
1898
|
S: void 0,
|
|
1881
1899
|
C: (f, a) => f(...a)
|
|
@@ -1886,11 +1904,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1886
1904
|
});
|
|
1887
1905
|
}
|
|
1888
1906
|
case Invitation6.State.SUCCESS: {
|
|
1889
|
-
|
|
1907
|
+
log6("[invitation success]", {
|
|
1890
1908
|
Kind,
|
|
1891
1909
|
invitation: invitation2
|
|
1892
1910
|
}, {
|
|
1893
|
-
F:
|
|
1911
|
+
F: __dxlog_file6,
|
|
1894
1912
|
L: 119,
|
|
1895
1913
|
S: void 0,
|
|
1896
1914
|
C: (f, a) => f(...a)
|
|
@@ -1902,10 +1920,10 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1902
1920
|
return complete?.();
|
|
1903
1921
|
}
|
|
1904
1922
|
case Invitation6.State.CANCELLED: {
|
|
1905
|
-
|
|
1923
|
+
log6.warn("[invitation cancelled]", {
|
|
1906
1924
|
Kind
|
|
1907
1925
|
}, {
|
|
1908
|
-
F:
|
|
1926
|
+
F: __dxlog_file6,
|
|
1909
1927
|
L: 125,
|
|
1910
1928
|
S: void 0,
|
|
1911
1929
|
C: (f, a) => f(...a)
|
|
@@ -1916,10 +1934,10 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1916
1934
|
});
|
|
1917
1935
|
}
|
|
1918
1936
|
case Invitation6.State.TIMEOUT: {
|
|
1919
|
-
|
|
1937
|
+
log6.error("[invitation timeout]", {
|
|
1920
1938
|
Kind
|
|
1921
1939
|
}, {
|
|
1922
|
-
F:
|
|
1940
|
+
F: __dxlog_file6,
|
|
1923
1941
|
L: 130,
|
|
1924
1942
|
S: void 0,
|
|
1925
1943
|
C: (f, a) => f(...a)
|
|
@@ -1932,11 +1950,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1932
1950
|
}
|
|
1933
1951
|
}, (error) => {
|
|
1934
1952
|
if (error instanceof AlreadyJoinedError) {
|
|
1935
|
-
|
|
1953
|
+
log6("[already joined]", {
|
|
1936
1954
|
Kind,
|
|
1937
1955
|
error
|
|
1938
1956
|
}, {
|
|
1939
|
-
F:
|
|
1957
|
+
F: __dxlog_file6,
|
|
1940
1958
|
L: 137,
|
|
1941
1959
|
S: void 0,
|
|
1942
1960
|
C: (f, a) => f(...a)
|
|
@@ -1947,11 +1965,11 @@ var getInvitationSubscribable = (Kind, invitation) => {
|
|
|
1947
1965
|
});
|
|
1948
1966
|
return complete?.();
|
|
1949
1967
|
}
|
|
1950
|
-
|
|
1968
|
+
log6.error("[invitation errored]", {
|
|
1951
1969
|
Kind,
|
|
1952
1970
|
error
|
|
1953
1971
|
}, {
|
|
1954
|
-
F:
|
|
1972
|
+
F: __dxlog_file6,
|
|
1955
1973
|
L: 142,
|
|
1956
1974
|
S: void 0,
|
|
1957
1975
|
C: (f, a) => f(...a)
|
|
@@ -2271,12 +2289,12 @@ var joinMachine = createMachine2({
|
|
|
2271
2289
|
} : context.space
|
|
2272
2290
|
}),
|
|
2273
2291
|
log: (context, event) => {
|
|
2274
|
-
|
|
2292
|
+
log6("[transition]", {
|
|
2275
2293
|
event,
|
|
2276
2294
|
haloInvitation: context.halo.invitation,
|
|
2277
2295
|
spaceInvitation: context.space.invitation
|
|
2278
2296
|
}, {
|
|
2279
|
-
F:
|
|
2297
|
+
F: __dxlog_file6,
|
|
2280
2298
|
L: 406,
|
|
2281
2299
|
S: void 0,
|
|
2282
2300
|
C: (f, a) => f(...a)
|
|
@@ -2289,8 +2307,8 @@ var defaultCodeFromUrl = (invitationType, text) => {
|
|
|
2289
2307
|
const searchParams = new URLSearchParams(text.substring(text.lastIndexOf("?")));
|
|
2290
2308
|
return searchParams.get(`${invitationType}InvitationCode`) ?? searchParams.get(`${invitationType}Invitation`) ?? searchParams.get("invitationCode") ?? searchParams.get("invitation") ?? text;
|
|
2291
2309
|
} catch (err) {
|
|
2292
|
-
|
|
2293
|
-
F:
|
|
2310
|
+
log6.catch(err, void 0, {
|
|
2311
|
+
F: __dxlog_file6,
|
|
2294
2312
|
L: 433,
|
|
2295
2313
|
S: void 0,
|
|
2296
2314
|
C: (f, a) => f(...a)
|
|
@@ -2310,8 +2328,8 @@ var useJoinMachine = (client, options) => {
|
|
|
2310
2328
|
invitationSubscribable: getInvitationSubscribable("Halo", invitationObservable)
|
|
2311
2329
|
};
|
|
2312
2330
|
} catch (err) {
|
|
2313
|
-
|
|
2314
|
-
F:
|
|
2331
|
+
log6.error("Could not redeem device invitation code", err, {
|
|
2332
|
+
F: __dxlog_file6,
|
|
2315
2333
|
L: 454,
|
|
2316
2334
|
S: void 0,
|
|
2317
2335
|
C: (f, a) => f(...a)
|
|
@@ -2335,8 +2353,8 @@ var useJoinMachine = (client, options) => {
|
|
|
2335
2353
|
invitationSubscribable: getInvitationSubscribable("Space", invitationObservable)
|
|
2336
2354
|
};
|
|
2337
2355
|
} catch (err) {
|
|
2338
|
-
|
|
2339
|
-
F:
|
|
2356
|
+
log6.error("Could not redeem space invitation code", err, {
|
|
2357
|
+
F: __dxlog_file6,
|
|
2340
2358
|
L: 476,
|
|
2341
2359
|
S: void 0,
|
|
2342
2360
|
C: (f, a) => f(...a)
|
|
@@ -2501,10 +2519,10 @@ var IdentityAdded = (props) => {
|
|
|
2501
2519
|
|
|
2502
2520
|
// packages/sdk/shell/src/panels/JoinPanel/steps/IdentityInput.tsx
|
|
2503
2521
|
import React33, { useState as useState6 } from "react";
|
|
2504
|
-
import { log as
|
|
2522
|
+
import { log as log7 } from "@dxos/log";
|
|
2505
2523
|
import { useClient as useClient4 } from "@dxos/react-client";
|
|
2506
2524
|
import { useTranslation as useTranslation19 } from "@dxos/react-ui";
|
|
2507
|
-
var
|
|
2525
|
+
var __dxlog_file7 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/JoinPanel/steps/IdentityInput.tsx";
|
|
2508
2526
|
var IdentityInput = (props) => {
|
|
2509
2527
|
const { send, method } = props;
|
|
2510
2528
|
const isRecover = method === "recover identity";
|
|
@@ -2520,8 +2538,8 @@ var IdentityInput = (props) => {
|
|
|
2520
2538
|
identity
|
|
2521
2539
|
});
|
|
2522
2540
|
}, (error) => {
|
|
2523
|
-
|
|
2524
|
-
F:
|
|
2541
|
+
log7.catch(error, void 0, {
|
|
2542
|
+
F: __dxlog_file7,
|
|
2525
2543
|
L: 37,
|
|
2526
2544
|
S: void 0,
|
|
2527
2545
|
C: (f, a) => f(...a)
|
|
@@ -2590,17 +2608,17 @@ var InvitationAccepted = (props) => {
|
|
|
2590
2608
|
|
|
2591
2609
|
// packages/sdk/shell/src/panels/JoinPanel/steps/InvitationInput.tsx
|
|
2592
2610
|
import React35, { useState as useState7, useEffect as useEffect4, cloneElement as cloneElement4 } from "react";
|
|
2593
|
-
import { log as
|
|
2611
|
+
import { log as log8 } from "@dxos/log";
|
|
2594
2612
|
import { useTranslation as useTranslation21 } from "@dxos/react-ui";
|
|
2595
|
-
var
|
|
2613
|
+
var __dxlog_file8 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/JoinPanel/steps/InvitationInput.tsx";
|
|
2596
2614
|
var invitationCodeFromUrl = (text) => {
|
|
2597
2615
|
try {
|
|
2598
2616
|
const searchParams = new URLSearchParams(text.substring(text.lastIndexOf("?")));
|
|
2599
2617
|
const invitation = searchParams.get("spaceInvitationCode") ?? searchParams.get("deviceInvitationCode");
|
|
2600
2618
|
return invitation ?? text;
|
|
2601
2619
|
} catch (err) {
|
|
2602
|
-
|
|
2603
|
-
F:
|
|
2620
|
+
log8.catch(err, void 0, {
|
|
2621
|
+
F: __dxlog_file8,
|
|
2604
2622
|
L: 25,
|
|
2605
2623
|
S: void 0,
|
|
2606
2624
|
C: (f, a) => f(...a)
|
|
@@ -2784,10 +2802,10 @@ var InvitationAuthenticator = ({ failed, Kind, active, pending, invitationId, on
|
|
|
2784
2802
|
|
|
2785
2803
|
// packages/sdk/shell/src/panels/JoinPanel/steps/ResetIdentity.tsx
|
|
2786
2804
|
import React38, { useState as useState9 } from "react";
|
|
2787
|
-
import { log as
|
|
2805
|
+
import { log as log9 } from "@dxos/log";
|
|
2788
2806
|
import { useClient as useClient5 } from "@dxos/react-client";
|
|
2789
2807
|
import { useTranslation as useTranslation24 } from "@dxos/react-ui";
|
|
2790
|
-
var
|
|
2808
|
+
var __dxlog_file9 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/JoinPanel/steps/ResetIdentity.tsx";
|
|
2791
2809
|
var ResetIdentity = ({ send, active }) => {
|
|
2792
2810
|
const client = useClient5();
|
|
2793
2811
|
const { t } = useTranslation24("os");
|
|
@@ -2798,8 +2816,8 @@ var ResetIdentity = ({ send, active }) => {
|
|
|
2798
2816
|
void client.reset().then(() => send?.({
|
|
2799
2817
|
type: "resetIdentity"
|
|
2800
2818
|
}), (error) => {
|
|
2801
|
-
|
|
2802
|
-
F:
|
|
2819
|
+
log9.catch(error, void 0, {
|
|
2820
|
+
F: __dxlog_file9,
|
|
2803
2821
|
L: 35,
|
|
2804
2822
|
S: void 0,
|
|
2805
2823
|
C: (f, a) => f(...a)
|
|
@@ -2865,7 +2883,7 @@ var resolvedBgColor = (status) => status === Invitation7.State.ERROR ? errorBgCo
|
|
|
2865
2883
|
var resolvedTextColor = (status) => status === Invitation7.State.ERROR ? errorTextColor : status === Invitation7.State.CANCELLED || status === Invitation7.State.TIMEOUT ? cancelledTextColor : successTextColor;
|
|
2866
2884
|
|
|
2867
2885
|
// packages/sdk/shell/src/panels/JoinPanel/JoinPanel.tsx
|
|
2868
|
-
var
|
|
2886
|
+
var __dxlog_file10 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/JoinPanel/JoinPanel.tsx";
|
|
2869
2887
|
var JoinPanelImpl = (props) => {
|
|
2870
2888
|
const { titleId, send, activeView, failed, mode, unredeemedCodes, invitationStates, succeededKeys, failReasons, onExit, onHaloDone, onSpaceDone, exitActionParent, doneActionParent, onHaloInvitationCancel, onSpaceInvitationCancel, onHaloInvitationAuthenticate, onSpaceInvitationAuthenticate, IdentityInput: IdentityInputComponent = IdentityInput, ResetIdentity: ResetIdentityComponent = ResetIdentity } = props;
|
|
2871
2889
|
return /* @__PURE__ */ React39.createElement(DensityProvider3, {
|
|
@@ -3024,8 +3042,8 @@ var JoinPanel = ({ titleId: propsTitleId, mode = "default", initialInvitationCod
|
|
|
3024
3042
|
});
|
|
3025
3043
|
useEffect5(() => {
|
|
3026
3044
|
const subscription = joinService.subscribe((state) => {
|
|
3027
|
-
|
|
3028
|
-
F:
|
|
3045
|
+
log10("[state]", state, {
|
|
3046
|
+
F: __dxlog_file10,
|
|
3029
3047
|
L: 198,
|
|
3030
3048
|
S: void 0,
|
|
3031
3049
|
C: (f, a) => f(...a)
|
|
@@ -3278,15 +3296,15 @@ var JoinPanel = ({ titleId: propsTitleId, mode = "default", initialInvitationCod
|
|
|
3278
3296
|
// packages/sdk/shell/src/panels/SpacePanel/SpacePanel.tsx
|
|
3279
3297
|
import { Planet } from "@phosphor-icons/react";
|
|
3280
3298
|
import React41, { useEffect as useEffect6, useMemo as useMemo5 } from "react";
|
|
3281
|
-
import { log as
|
|
3299
|
+
import { log as log13 } from "@dxos/log";
|
|
3282
3300
|
import { useInvitationStatus as useInvitationStatus3 } from "@dxos/react-client/invitations";
|
|
3283
3301
|
import { DensityProvider as DensityProvider4, useId as useId8, useTranslation as useTranslation26 } from "@dxos/react-ui";
|
|
3284
3302
|
|
|
3285
3303
|
// packages/sdk/shell/src/panels/SpacePanel/spaceMachine.ts
|
|
3286
3304
|
import { useMachine as useMachine3 } from "@xstate/react";
|
|
3287
3305
|
import { assign as assign3, createMachine as createMachine3 } from "xstate";
|
|
3288
|
-
import { log as
|
|
3289
|
-
var
|
|
3306
|
+
import { log as log11 } from "@dxos/log";
|
|
3307
|
+
var __dxlog_file11 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/SpacePanel/spaceMachine.ts";
|
|
3290
3308
|
var spaceMachine = createMachine3({
|
|
3291
3309
|
id: "space",
|
|
3292
3310
|
predictableActionArguments: true,
|
|
@@ -3323,11 +3341,11 @@ var spaceMachine = createMachine3({
|
|
|
3323
3341
|
invitation: () => void 0
|
|
3324
3342
|
}),
|
|
3325
3343
|
log: (context, event) => {
|
|
3326
|
-
|
|
3344
|
+
log11("[transition]", {
|
|
3327
3345
|
event,
|
|
3328
3346
|
context
|
|
3329
3347
|
}, {
|
|
3330
|
-
F:
|
|
3348
|
+
F: __dxlog_file11,
|
|
3331
3349
|
L: 53,
|
|
3332
3350
|
S: void 0,
|
|
3333
3351
|
C: (f, a) => f(...a)
|
|
@@ -3347,11 +3365,13 @@ var useSpaceMachine = (options) => {
|
|
|
3347
3365
|
// packages/sdk/shell/src/panels/SpacePanel/steps/SpaceManager.tsx
|
|
3348
3366
|
import { Placeholder as Placeholder2, UserPlus, UsersThree } from "@phosphor-icons/react";
|
|
3349
3367
|
import React40, { useCallback as useCallback8, useState as useState10 } from "react";
|
|
3368
|
+
import { log as log12 } from "@dxos/log";
|
|
3350
3369
|
import { useConfig } from "@dxos/react-client";
|
|
3351
3370
|
import { useSpaceInvitations as useSpaceInvitations2 } from "@dxos/react-client/echo";
|
|
3352
3371
|
import { Invitation as Invitation8, InvitationEncoder as InvitationEncoder4 } from "@dxos/react-client/invitations";
|
|
3353
3372
|
import { ScrollArea, useTranslation as useTranslation25 } from "@dxos/react-ui";
|
|
3354
3373
|
import { descriptionText as descriptionText10, mx as mx22 } from "@dxos/react-ui-theme";
|
|
3374
|
+
var __dxlog_file12 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/SpacePanel/steps/SpaceManager.tsx";
|
|
3355
3375
|
var activeActionKey = "dxos:react-shell/space-manager/active-action";
|
|
3356
3376
|
var SpaceManager = (props) => {
|
|
3357
3377
|
const { space, target } = props;
|
|
@@ -3361,10 +3381,15 @@ var SpaceManager = (props) => {
|
|
|
3361
3381
|
const onInvitationEvent = useCallback8((invitation) => {
|
|
3362
3382
|
const invitationCode = InvitationEncoder4.encode(invitation);
|
|
3363
3383
|
if (invitation.state === Invitation8.State.CONNECTING) {
|
|
3364
|
-
|
|
3384
|
+
log12.info(JSON.stringify({
|
|
3365
3385
|
invitationCode,
|
|
3366
3386
|
authCode: invitation.authCode
|
|
3367
|
-
})
|
|
3387
|
+
}), void 0, {
|
|
3388
|
+
F: __dxlog_file12,
|
|
3389
|
+
L: 49,
|
|
3390
|
+
S: void 0,
|
|
3391
|
+
C: (f, a) => f(...a)
|
|
3392
|
+
});
|
|
3368
3393
|
}
|
|
3369
3394
|
}, []);
|
|
3370
3395
|
const inviteActions = {
|
|
@@ -3459,7 +3484,7 @@ var SpaceManagerImpl = (props) => {
|
|
|
3459
3484
|
};
|
|
3460
3485
|
|
|
3461
3486
|
// packages/sdk/shell/src/panels/SpacePanel/SpacePanel.tsx
|
|
3462
|
-
var
|
|
3487
|
+
var __dxlog_file13 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/panels/SpacePanel/SpacePanel.tsx";
|
|
3463
3488
|
var SpacePanelHeading = ({ titleId, space, onDone }) => {
|
|
3464
3489
|
const { t } = useTranslation26("os");
|
|
3465
3490
|
const name = space.properties.name;
|
|
@@ -3524,8 +3549,8 @@ var SpacePanel = ({ titleId: propsTitleId, createInvitationUrl = (code) => code,
|
|
|
3524
3549
|
});
|
|
3525
3550
|
useEffect6(() => {
|
|
3526
3551
|
const subscription = spaceService.subscribe((state) => {
|
|
3527
|
-
|
|
3528
|
-
F:
|
|
3552
|
+
log13("[state]", state, {
|
|
3553
|
+
F: __dxlog_file13,
|
|
3529
3554
|
L: 94,
|
|
3530
3555
|
S: void 0,
|
|
3531
3556
|
C: (f, a) => f(...a)
|
|
@@ -3623,7 +3648,7 @@ import { createIFramePort } from "@dxos/rpc-tunnel";
|
|
|
3623
3648
|
|
|
3624
3649
|
// packages/sdk/shell/src/composites/Shell/Shell.tsx
|
|
3625
3650
|
import React45, { useEffect as useEffect7, useState as useState11 } from "react";
|
|
3626
|
-
import { log as
|
|
3651
|
+
import { log as log14 } from "@dxos/log";
|
|
3627
3652
|
import { ShellDisplay, ShellLayout, useClient as useClient7 } from "@dxos/react-client";
|
|
3628
3653
|
import { useSpace as useSpace2 } from "@dxos/react-client/echo";
|
|
3629
3654
|
|
|
@@ -3647,7 +3672,7 @@ var SpaceDialog = (spacePanelProps) => {
|
|
|
3647
3672
|
};
|
|
3648
3673
|
|
|
3649
3674
|
// packages/sdk/shell/src/composites/Shell/Shell.tsx
|
|
3650
|
-
var
|
|
3675
|
+
var __dxlog_file14 = "/home/runner/work/dxos/dxos/packages/sdk/shell/src/composites/Shell/Shell.tsx";
|
|
3651
3676
|
var Shell = ({ runtime, origin }) => {
|
|
3652
3677
|
const [{ layout, invitationCode, spaceKey, target }, setLayout] = useState11({
|
|
3653
3678
|
layout: runtime.layout,
|
|
@@ -3664,8 +3689,8 @@ var Shell = ({ runtime, origin }) => {
|
|
|
3664
3689
|
]);
|
|
3665
3690
|
useEffect7(() => {
|
|
3666
3691
|
if (layout === ShellLayout.SPACE && !space) {
|
|
3667
|
-
|
|
3668
|
-
F:
|
|
3692
|
+
log14.warn("No space found for shell space invitations.", void 0, {
|
|
3693
|
+
F: __dxlog_file14,
|
|
3669
3694
|
L: 32,
|
|
3670
3695
|
S: void 0,
|
|
3671
3696
|
C: (f, a) => f(...a)
|