@dxos/shell 0.4.10-main.f68a1ca → 0.4.10-main.fd4f2a3
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 +9609 -8881
- package/dist/bundle/shell.mjs.map +1 -1
- package/dist/bundle/shell.umd.js +61 -56
- package/dist/bundle/shell.umd.js.map +1 -1
- package/dist/bundle/style.css +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/react.mjs +4 -3
- package/dist/lib/browser/react.mjs.map +3 -3
- package/dist/lib/browser/testing/index.mjs +5 -7
- package/dist/lib/browser/testing/index.mjs.map +3 -3
- package/dist/types/src/steps/ConfirmReset.d.ts.map +1 -1
- package/dist/types/src/steps/ConfirmReset.js +4 -3
- package/dist/types/src/steps/ConfirmReset.js.map +1 -1
- package/dist/types/src/testing/shell-manager.d.ts.map +1 -1
- package/dist/types/src/testing/shell-manager.js +5 -7
- package/dist/types/src/testing/shell-manager.js.map +1 -1
- package/dist/types/src/types/index.js +1 -0
- package/dist/types/src/types/index.js.map +1 -1
- package/package.json +20 -20
- package/src/steps/ConfirmReset.tsx +4 -3
- package/src/testing/shell-manager.ts +5 -7
- package/src/types/index.ts +2 -0
|
@@ -140,15 +140,13 @@ var ShellManager = class extends ScopedShellManager {
|
|
|
140
140
|
};
|
|
141
141
|
this.page.on("dialog", handleDialog);
|
|
142
142
|
await this.shell.getByTestId("devices-panel.sign-out").click();
|
|
143
|
-
await this.shell.getByTestId("
|
|
144
|
-
this.
|
|
143
|
+
await this.shell.getByTestId("reset-storage.reset-identity-input").fill("CONFIRM");
|
|
144
|
+
await this.shell.getByTestId("reset-storage.reset-identity-confirm").click();
|
|
145
145
|
}
|
|
146
146
|
async joinNewIdentity(invitationCode) {
|
|
147
|
-
await this.shell.getByTestId("devices-panel.
|
|
148
|
-
await this.shell.getByTestId("
|
|
149
|
-
await this.shell.getByTestId("reset-identity-input").
|
|
150
|
-
await this.shell.getByTestId("reset-identity-input-confirm").click();
|
|
151
|
-
await this.shell.getByTestId("identity-chooser.join-identity").click();
|
|
147
|
+
await this.shell.getByTestId("devices-panel.join-new-identity").click();
|
|
148
|
+
await this.shell.getByTestId("join-new-identity.reset-identity-input").fill("CONFIRM");
|
|
149
|
+
await this.shell.getByTestId("join-new-identity.reset-identity-input-confirm").click();
|
|
152
150
|
await this.inputInvitation("device", invitationCode, this.shell);
|
|
153
151
|
}
|
|
154
152
|
async authenticateDevice(authCode, skipDone = true) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/testing/fixtures/identities.ts", "../../../../src/testing/fixtures/invitations.ts", "../../../../src/testing/scoped-shell-manager.ts", "../../../../src/testing/shell-manager.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { PublicKey } from '@dxos/react-client';\nimport { SpaceMember } from '@dxos/react-client/echo';\n\nexport const alice: SpaceMember = {\n identity: {\n identityKey: PublicKey.random(),\n profile: {\n displayName: 'Alice',\n },\n },\n presence: SpaceMember.PresenceState.ONLINE,\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { PublicKey } from '@dxos/react-client';\nimport { Invitation, CancellableInvitationObservable } from '@dxos/react-client/invitations';\n\nexport const inviteWithState = (state: Invitation.State) =>\n new CancellableInvitationObservable({\n initialInvitation: {\n state,\n invitationId: Math.random().toString(16).slice(2),\n kind: Invitation.Kind.SPACE,\n authMethod: Invitation.AuthMethod.NONE,\n swarmKey: PublicKey.random(),\n type: Invitation.Type.INTERACTIVE,\n authCode: [Invitation.State.READY_FOR_AUTHENTICATION, Invitation.State.AUTHENTICATING].includes(state)\n ? '123456'\n : '',\n },\n subscriber: () => {},\n onCancel: async () => {},\n });\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport type { Locator, Page, FrameLocator } from '@playwright/test';\n\ntype Scope = Locator | FrameLocator | Page;\n\nexport class ScopedShellManager {\n page!: Page;\n\n authenticatorIsVisible(type: 'device' | 'space', scope?: Scope) {\n return (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).isVisible();\n }\n\n async invitationFailed(scope?: Scope, timeout = 3000) {\n const peer = scope || this.page;\n try {\n await peer.locator('[data-testid=invitation-rescuer-reset]:not([disabled])').waitFor({ timeout });\n return true;\n } catch {\n return false;\n }\n }\n\n async inputInvitation(type: 'device' | 'space', invitation: string, scope?: Scope) {\n await (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-input`).fill(invitation);\n await this.page.keyboard.press('Enter');\n }\n\n async invitationInputContinue(type: 'device' | 'space', scope?: Scope) {\n await (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-input-continue`).click();\n }\n\n async cancelInvitation(type: 'device' | 'space', kind: 'host' | 'guest', scope?: Scope) {\n if (kind === 'guest') {\n await (scope || this.page)\n .getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-authenticator-cancel`)\n .click();\n } else {\n await (scope || this.page).getByTestId('cancel-invitation').nth(0).click();\n }\n }\n\n async readyToAuthenticate(type: 'device' | 'space', scope?: Scope, timeout = 3000) {\n const peer = scope || this.page;\n try {\n await peer\n .locator(`[data-testid=${type === 'device' ? 'halo' : 'space'}-auth-code-input]:not([disabled])`)\n .waitFor({ timeout });\n return true;\n } catch {\n return false;\n }\n }\n\n async authenticateInvitation(type: 'device' | 'space', authCode: string, scope?: Scope) {\n const peer = scope || this.page;\n // TODO(wittjosiah): Update ids.\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).fill(authCode);\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-authenticator-next`).click();\n }\n\n async clearAuthCode(type: 'device' | 'space', scope?: Scope) {\n const peer = scope || this.page;\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).fill('');\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).focus();\n }\n\n async resetInvitation(scope?: Scope) {\n await (scope || this.page).getByTestId('invitation-rescuer-reset').click();\n }\n\n async doneInvitation(type: 'device' | 'space', scope?: Scope) {\n await (scope || this.page)\n .getByTestId(type === 'device' ? 'halo-invitation-accepted-done' : 'space-invitation-accepted-done')\n .click();\n }\n}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport type { ConsoleMessage, Dialog, Page } from '@playwright/test';\n\nimport { sleep, Trigger } from '@dxos/async';\n\nimport { ScopedShellManager } from './scoped-shell-manager';\n\n// TODO(wittjosiah): Normalize data-testids between snake and camel case.\n\nexport class ShellManager extends ScopedShellManager {\n private _invitationCode = new Trigger<string>();\n private _authCode = new Trigger<string>();\n\n // prettier-ignore\n constructor(\n override readonly page: Page,\n readonly inIFrame = true,\n ) {\n super();\n this.page.on('console', (message) => this._onConsoleMessage(message));\n }\n\n get shell() {\n return this.inIFrame ? this.page.frameLocator('data-testid=dxos-shell') : this.page;\n }\n\n // Getters\n\n async getDisplayName(): Promise<string | null> {\n return this.shell.getByTestId('identityHeading.displayName').textContent();\n }\n\n async isCurrentSpaceViewVisible(): Promise<boolean> {\n return await this.shell.getByTestId('current-space-view').isVisible();\n }\n\n async isSpaceListViewVisible(): Promise<boolean> {\n return await this.shell.getByTestId('space-list-view').isVisible();\n }\n\n // Actions\n\n async createIdentity(name: string) {\n await this.shell.getByTestId('create-identity').click();\n await this.page.keyboard.type(name);\n await this.shell.getByTestId('create-identity-input-continue').click();\n await this.shell.getByTestId('halo-invitation-accepted-done').click();\n }\n\n async createDeviceInvitation(): Promise<string> {\n this._invitationCode = new Trigger<string>();\n this._authCode = new Trigger<string>();\n await this.shell.getByTestId('devices-panel.create-invitation').click();\n return await this._invitationCode.wait();\n }\n\n async resetDevice() {\n const handleDialog = async (dialog: Dialog) => {\n if (dialog.type() === 'confirm') {\n await dialog.accept();\n }\n };\n\n this.page.on('dialog', handleDialog);\n await this.shell.getByTestId('devices-panel.sign-out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B,gBAAgBoB,KAAI;EACxC;EAEA,MAAMC,cAAc;AAClB,UAAMC,eAAe,OAAOC,WAAAA;AAC1B,UAAIA,OAAOL,KAAI,MAAO,WAAW;AAC/B,cAAMK,OAAOC,OAAM;MACrB;IACF;AAEA,SAAK1B,KAAKK,GAAG,UAAUmB,YAAAA;AACvB,UAAM,KAAKhB,MAAMG,YAAY,wBAAA,EAA0BO,MAAK;AAC5D,UAAM,KAAKV,MAAMG,YAAY,
|
|
6
|
-
"names": ["PublicKey", "SpaceMember", "alice", "identity", "identityKey", "PublicKey", "random", "profile", "displayName", "presence", "SpaceMember", "PresenceState", "ONLINE", "PublicKey", "Invitation", "CancellableInvitationObservable", "inviteWithState", "state", "CancellableInvitationObservable", "initialInvitation", "invitationId", "Math", "random", "toString", "slice", "kind", "Invitation", "Kind", "SPACE", "authMethod", "AuthMethod", "NONE", "swarmKey", "PublicKey", "type", "Type", "INTERACTIVE", "authCode", "State", "READY_FOR_AUTHENTICATION", "AUTHENTICATING", "includes", "subscriber", "onCancel", "ScopedShellManager", "authenticatorIsVisible", "type", "scope", "page", "getByTestId", "isVisible", "invitationFailed", "timeout", "peer", "locator", "waitFor", "inputInvitation", "invitation", "fill", "keyboard", "press", "invitationInputContinue", "click", "cancelInvitation", "kind", "nth", "readyToAuthenticate", "authenticateInvitation", "authCode", "clearAuthCode", "focus", "resetInvitation", "doneInvitation", "sleep", "Trigger", "ShellManager", "ScopedShellManager", "constructor", "page", "inIFrame", "_invitationCode", "Trigger", "_authCode", "on", "message", "_onConsoleMessage", "shell", "frameLocator", "getDisplayName", "getByTestId", "textContent", "isCurrentSpaceViewVisible", "isVisible", "isSpaceListViewVisible", "createIdentity", "name", "click", "keyboard", "type", "createDeviceInvitation", "wait", "resetDevice", "handleDialog", "dialog", "accept", "
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { PublicKey } from '@dxos/react-client';\nimport { SpaceMember } from '@dxos/react-client/echo';\n\nexport const alice: SpaceMember = {\n identity: {\n identityKey: PublicKey.random(),\n profile: {\n displayName: 'Alice',\n },\n },\n presence: SpaceMember.PresenceState.ONLINE,\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { PublicKey } from '@dxos/react-client';\nimport { Invitation, CancellableInvitationObservable } from '@dxos/react-client/invitations';\n\nexport const inviteWithState = (state: Invitation.State) =>\n new CancellableInvitationObservable({\n initialInvitation: {\n state,\n invitationId: Math.random().toString(16).slice(2),\n kind: Invitation.Kind.SPACE,\n authMethod: Invitation.AuthMethod.NONE,\n swarmKey: PublicKey.random(),\n type: Invitation.Type.INTERACTIVE,\n authCode: [Invitation.State.READY_FOR_AUTHENTICATION, Invitation.State.AUTHENTICATING].includes(state)\n ? '123456'\n : '',\n },\n subscriber: () => {},\n onCancel: async () => {},\n });\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport type { Locator, Page, FrameLocator } from '@playwright/test';\n\ntype Scope = Locator | FrameLocator | Page;\n\nexport class ScopedShellManager {\n page!: Page;\n\n authenticatorIsVisible(type: 'device' | 'space', scope?: Scope) {\n return (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).isVisible();\n }\n\n async invitationFailed(scope?: Scope, timeout = 3000) {\n const peer = scope || this.page;\n try {\n await peer.locator('[data-testid=invitation-rescuer-reset]:not([disabled])').waitFor({ timeout });\n return true;\n } catch {\n return false;\n }\n }\n\n async inputInvitation(type: 'device' | 'space', invitation: string, scope?: Scope) {\n await (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-input`).fill(invitation);\n await this.page.keyboard.press('Enter');\n }\n\n async invitationInputContinue(type: 'device' | 'space', scope?: Scope) {\n await (scope || this.page).getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-input-continue`).click();\n }\n\n async cancelInvitation(type: 'device' | 'space', kind: 'host' | 'guest', scope?: Scope) {\n if (kind === 'guest') {\n await (scope || this.page)\n .getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-authenticator-cancel`)\n .click();\n } else {\n await (scope || this.page).getByTestId('cancel-invitation').nth(0).click();\n }\n }\n\n async readyToAuthenticate(type: 'device' | 'space', scope?: Scope, timeout = 3000) {\n const peer = scope || this.page;\n try {\n await peer\n .locator(`[data-testid=${type === 'device' ? 'halo' : 'space'}-auth-code-input]:not([disabled])`)\n .waitFor({ timeout });\n return true;\n } catch {\n return false;\n }\n }\n\n async authenticateInvitation(type: 'device' | 'space', authCode: string, scope?: Scope) {\n const peer = scope || this.page;\n // TODO(wittjosiah): Update ids.\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).fill(authCode);\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-invitation-authenticator-next`).click();\n }\n\n async clearAuthCode(type: 'device' | 'space', scope?: Scope) {\n const peer = scope || this.page;\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).fill('');\n await peer.getByTestId(`${type === 'device' ? 'halo' : 'space'}-auth-code-input`).focus();\n }\n\n async resetInvitation(scope?: Scope) {\n await (scope || this.page).getByTestId('invitation-rescuer-reset').click();\n }\n\n async doneInvitation(type: 'device' | 'space', scope?: Scope) {\n await (scope || this.page)\n .getByTestId(type === 'device' ? 'halo-invitation-accepted-done' : 'space-invitation-accepted-done')\n .click();\n }\n}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport type { ConsoleMessage, Dialog, Page } from '@playwright/test';\n\nimport { sleep, Trigger } from '@dxos/async';\n\nimport { ScopedShellManager } from './scoped-shell-manager';\n\n// TODO(wittjosiah): Normalize data-testids between snake and camel case.\n\nexport class ShellManager extends ScopedShellManager {\n private _invitationCode = new Trigger<string>();\n private _authCode = new Trigger<string>();\n\n // prettier-ignore\n constructor(\n override readonly page: Page,\n readonly inIFrame = true,\n ) {\n super();\n this.page.on('console', (message) => this._onConsoleMessage(message));\n }\n\n get shell() {\n return this.inIFrame ? this.page.frameLocator('data-testid=dxos-shell') : this.page;\n }\n\n // Getters\n\n async getDisplayName(): Promise<string | null> {\n return this.shell.getByTestId('identityHeading.displayName').textContent();\n }\n\n async isCurrentSpaceViewVisible(): Promise<boolean> {\n return await this.shell.getByTestId('current-space-view').isVisible();\n }\n\n async isSpaceListViewVisible(): Promise<boolean> {\n return await this.shell.getByTestId('space-list-view').isVisible();\n }\n\n // Actions\n\n async createIdentity(name: string) {\n await this.shell.getByTestId('create-identity').click();\n await this.page.keyboard.type(name);\n await this.shell.getByTestId('create-identity-input-continue').click();\n await this.shell.getByTestId('halo-invitation-accepted-done').click();\n }\n\n async createDeviceInvitation(): Promise<string> {\n this._invitationCode = new Trigger<string>();\n this._authCode = new Trigger<string>();\n await this.shell.getByTestId('devices-panel.create-invitation').click();\n return await this._invitationCode.wait();\n }\n\n async resetDevice() {\n const handleDialog = async (dialog: Dialog) => {\n if (dialog.type() === 'confirm') {\n await dialog.accept();\n }\n };\n\n this.page.on('dialog', handleDialog);\n await this.shell.getByTestId('devices-panel.sign-out').click();\n await this.shell.getByTestId('reset-storage.reset-identity-input').fill('CONFIRM');\n await this.shell.getByTestId('reset-storage.reset-identity-confirm').click();\n }\n\n async joinNewIdentity(invitationCode: string) {\n await this.shell.getByTestId('devices-panel.join-new-identity').click();\n await this.shell.getByTestId('join-new-identity.reset-identity-input').fill('CONFIRM');\n await this.shell.getByTestId('join-new-identity.reset-identity-input-confirm').click();\n await this.inputInvitation('device', invitationCode, this.shell);\n }\n\n async authenticateDevice(authCode: string, skipDone = true) {\n // Wait for focus to shift before typing.\n await sleep(1500);\n await this.authenticateInvitation('device', authCode, this.shell);\n // TODO(wittjosiah): When \"signing out\" and joinging a new identity, the done step seems to be skipped.\n if (!skipDone) {\n await this.doneInvitation('device', this.shell);\n }\n }\n\n async closeShell() {\n await this.page.keyboard.press('Escape');\n }\n\n async createSpaceInvitation(): Promise<string> {\n this._invitationCode = new Trigger<string>();\n this._authCode = new Trigger<string>();\n await this.shell.getByTestId('spaces-panel.create-invitation').click();\n return await this._invitationCode.wait();\n }\n\n async acceptSpaceInvitation(invitationCode: string) {\n await this.inputInvitation('space', invitationCode, this.shell);\n }\n\n async getAuthCode(): Promise<string> {\n return await this._authCode.wait();\n }\n\n async authenticate(authCode: string) {\n // Wait for focus to shift before typing.\n await sleep(1500);\n await this.authenticateInvitation('space', authCode, this.shell);\n await this.doneInvitation('space', this.shell);\n }\n\n private async _onConsoleMessage(message: ConsoleMessage) {\n try {\n const json = JSON.parse(message.text());\n if (json.invitationCode) {\n this._invitationCode.wake(json.invitationCode);\n }\n if (json.authCode) {\n this._authCode.wake(json.authCode);\n }\n } catch {}\n }\n}\n"],
|
|
5
|
+
"mappings": ";;;AAIA,SAASA,iBAAiB;AAC1B,SAASC,mBAAmB;AAErB,IAAMC,QAAqB;EAChCC,UAAU;IACRC,aAAaC,UAAUC,OAAM;IAC7BC,SAAS;MACPC,aAAa;IACf;EACF;EACAC,UAAUC,YAAYC,cAAcC;AACtC;;;ACXA,SAASC,aAAAA,kBAAiB;AAC1B,SAASC,YAAYC,uCAAuC;AAErD,IAAMC,kBAAkB,CAACC,UAC9B,IAAIC,gCAAgC;EAClCC,mBAAmB;IACjBF;IACAG,cAAcC,KAAKC,OAAM,EAAGC,SAAS,EAAA,EAAIC,MAAM,CAAA;IAC/CC,MAAMC,WAAWC,KAAKC;IACtBC,YAAYH,WAAWI,WAAWC;IAClCC,UAAUC,WAAUX,OAAM;IAC1BY,MAAMR,WAAWS,KAAKC;IACtBC,UAAU;MAACX,WAAWY,MAAMC;MAA0Bb,WAAWY,MAAME;MAAgBC,SAASxB,KAAAA,IAC5F,WACA;EACN;EACAyB,YAAY,MAAA;EAAO;EACnBC,UAAU,YAAA;EAAa;AACzB,CAAA;;;ACdK,IAAMC,qBAAN,MAAMA;EAGXC,uBAAuBC,MAA0BC,OAAe;AAC9D,YAAQA,SAAS,KAAKC,MAAMC,YAAY,GAAGH,SAAS,WAAW,SAAS,OAAA,kBAAyB,EAAEI,UAAS;EAC9G;EAEA,MAAMC,iBA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6B,aAAa;AACjB,UAAM,KAAKrC,KAAKmB,SAASmB,MAAM,QAAA;EACjC;EAEA,MAAMC,wBAAyC;AAC7C,SAAKrC,kBAAkB,IAAIC,QAAAA;AAC3B,SAAKC,YAAY,IAAID,QAAAA;AACrB,UAAM,KAAKK,MAAMG,YAAY,gCAAA,EAAkCO,MAAK;AACpE,WAAO,MAAM,KAAKhB,gBAAgBoB,KAAI;EACxC;EAEA,MAAMkB,sBAAsBX,gBAAwB;AAClD,UAAM,KAAKC,gBAAgB,SAASD,gBAAgB,KAAKrB,KAAK;EAChE;EAEA,MAAMiC,cAA+B;AACnC,WAAO,MAAM,KAAKrC,UAAUkB,KAAI;EAClC;EAEA,MAAMoB,aAAaV,UAAkB;AAEnC,UAAME,MAAM,IAAA;AACZ,UAAM,KAAKC,uBAAuB,SAASH,UAAU,KAAKxB,KAAK;AAC/D,UAAM,KAAK4B,eAAe,SAAS,KAAK5B,KAAK;EAC/C;EAEA,MAAcD,kBAAkBD,SAAyB;AACvD,QAAI;AACF,YAAMqC,OAAOC,KAAKC,MAAMvC,QAAQwC,KAAI,CAAA;AACpC,UAAIH,KAAKd,gBAAgB;AACvB,aAAK3B,gBAAgB6C,KAAKJ,KAAKd,cAAc;MAC/C;AACA,UAAIc,KAAKX,UAAU;AACjB,aAAK5B,UAAU2C,KAAKJ,KAAKX,QAAQ;MACnC;IACF,QAAQ;IAAC;EACX;AACF;",
|
|
6
|
+
"names": ["PublicKey", "SpaceMember", "alice", "identity", "identityKey", "PublicKey", "random", "profile", "displayName", "presence", "SpaceMember", "PresenceState", "ONLINE", "PublicKey", "Invitation", "CancellableInvitationObservable", "inviteWithState", "state", "CancellableInvitationObservable", "initialInvitation", "invitationId", "Math", "random", "toString", "slice", "kind", "Invitation", "Kind", "SPACE", "authMethod", "AuthMethod", "NONE", "swarmKey", "PublicKey", "type", "Type", "INTERACTIVE", "authCode", "State", "READY_FOR_AUTHENTICATION", "AUTHENTICATING", "includes", "subscriber", "onCancel", "ScopedShellManager", "authenticatorIsVisible", "type", "scope", "page", "getByTestId", "isVisible", "invitationFailed", "timeout", "peer", "locator", "waitFor", "inputInvitation", "invitation", "fill", "keyboard", "press", "invitationInputContinue", "click", "cancelInvitation", "kind", "nth", "readyToAuthenticate", "authenticateInvitation", "authCode", "clearAuthCode", "focus", "resetInvitation", "doneInvitation", "sleep", "Trigger", "ShellManager", "ScopedShellManager", "constructor", "page", "inIFrame", "_invitationCode", "Trigger", "_authCode", "on", "message", "_onConsoleMessage", "shell", "frameLocator", "getDisplayName", "getByTestId", "textContent", "isCurrentSpaceViewVisible", "isVisible", "isSpaceListViewVisible", "createIdentity", "name", "click", "keyboard", "type", "createDeviceInvitation", "wait", "resetDevice", "handleDialog", "dialog", "accept", "fill", "joinNewIdentity", "invitationCode", "inputInvitation", "authenticateDevice", "authCode", "skipDone", "sleep", "authenticateInvitation", "doneInvitation", "closeShell", "press", "createSpaceInvitation", "acceptSpaceInvitation", "getAuthCode", "authenticate", "json", "JSON", "parse", "text", "wake"]
|
|
7
7
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConfirmReset.d.ts","sourceRoot":"","sources":["../../../../src/steps/ConfirmReset.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,aAAa,CAAC;AAG7C,KAAK,mBAAmB,GAAG,OAAO,CAAC;IACjC,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC/B,IAAI,EAAE,mBAAmB,GAAG,eAAe,CAAC;CAC7C,CAAC,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,SAAS,GAAG,mBAAmB,CAAC;AAEhE,MAAM,MAAM,qBAAqB,GAAG,mBAAmB,GAAG;IACxD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CAAC;AAEF,eAAO,MAAM,YAAY,0CAA2C,iBAAiB,gBAyBpF,CAAC;AAEF,eAAO,MAAM,gBAAgB,yEAO1B,qBAAqB,
|
|
1
|
+
{"version":3,"file":"ConfirmReset.d.ts","sourceRoot":"","sources":["../../../../src/steps/ConfirmReset.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,aAAa,CAAC;AAG7C,KAAK,mBAAmB,GAAG,OAAO,CAAC;IACjC,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC/B,IAAI,EAAE,mBAAmB,GAAG,eAAe,CAAC;CAC7C,CAAC,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,SAAS,GAAG,mBAAmB,CAAC;AAEhE,MAAM,MAAM,qBAAqB,GAAG,mBAAmB,GAAG;IACxD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CAAC;AAEF,eAAO,MAAM,YAAY,0CAA2C,iBAAiB,gBAyBpF,CAAC;AAEF,eAAO,MAAM,gBAAgB,yEAO1B,qBAAqB,gBAiDvB,CAAC"}
|
|
@@ -52,6 +52,7 @@ const ConfirmResetImpl = ({ disabled, pending, validationMessage, onConfirm, onC
|
|
|
52
52
|
const { t } = (0, react_ui_1.useTranslation)('os');
|
|
53
53
|
const confirmationValue = t('confirmation value');
|
|
54
54
|
const [inputValue, setInputValue] = (0, react_2.useState)('');
|
|
55
|
+
const testIdAffix = mode === 'join new identity' ? 'join-new-identity' : 'reset-storage';
|
|
55
56
|
return (react_2.default.createElement(react_2.default.Fragment, null,
|
|
56
57
|
react_2.default.createElement("div", { role: 'none', className: 'grow flex flex-col gap-2 justify-center' },
|
|
57
58
|
react_2.default.createElement(react_ui_1.Message.Root, { valence: 'error' },
|
|
@@ -61,10 +62,10 @@ const ConfirmResetImpl = ({ disabled, pending, validationMessage, onConfirm, onC
|
|
|
61
62
|
react_2.default.createElement(react_ui_1.Message.Body, null, t('sign out chooser message'))),
|
|
62
63
|
react_2.default.createElement(components_1.Input, { validationMessage, label: react_2.default.createElement(components_1.StepHeading, { className: 'text-start mlb-2' }, t(mode === 'join new identity' ? 'join new identity input label' : 'reset storage input label', {
|
|
63
64
|
confirmationValue,
|
|
64
|
-
})), disabled: disabled, "data-testid":
|
|
65
|
+
})), disabled: disabled, "data-testid": `${testIdAffix}.reset-identity-input`, placeholder: confirmationValue, onChange: ({ target: { value } }) => setInputValue(value) })),
|
|
65
66
|
react_2.default.createElement(components_1.Actions, null,
|
|
66
|
-
onCancel && (react_2.default.createElement(components_1.Action, { disabled: disabled, onClick: onCancel, "data-testid":
|
|
67
|
-
onConfirm && (react_2.default.createElement(components_1.Action, { variant: 'destructive', disabled: disabled || pending || inputValue !== confirmationValue, onClick: onConfirm, "data-testid":
|
|
67
|
+
onCancel && (react_2.default.createElement(components_1.Action, { disabled: disabled, onClick: onCancel, "data-testid": `${testIdAffix}.reset-identity-cancel` }, t('cancel label'))),
|
|
68
|
+
onConfirm && (react_2.default.createElement(components_1.Action, { variant: 'destructive', disabled: disabled || pending || inputValue !== confirmationValue, onClick: onConfirm, "data-testid": `${testIdAffix}.reset-identity-confirm` }, pending ? t('reset in progress label') : t('reset device label'))))));
|
|
68
69
|
};
|
|
69
70
|
exports.ConfirmResetImpl = ConfirmResetImpl;
|
|
70
71
|
//# sourceMappingURL=ConfirmReset.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConfirmReset.js","sourceRoot":"","sources":["../../../../src/steps/ConfirmReset.tsx"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;AAEF,iDAAgD;AAChD,+CAAwC;AAExC,mCAAgC;AAChC,6CAAyD;AACzD,yDAAmD;AAGnD,8C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C,CAAC,CAAC,CAAC,CAAC,CAAC,oBAAoB,CAAC,CAC1D,CACV,CACO,CACT,CACJ,CAAC;AACJ,CAAC,CAAC;AAxDW,QAAA,gBAAgB,oBAwD3B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shell-manager.d.ts","sourceRoot":"","sources":["../../../../src/testing/shell-manager.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAA0B,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAIrE,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAI5D,qBAAa,YAAa,SAAQ,kBAAkB;aAM9B,IAAI,EAAE,IAAI;IAC5B,QAAQ,CAAC,QAAQ;IANnB,OAAO,CAAC,eAAe,CAAyB;IAChD,OAAO,CAAC,SAAS,CAAyB;gBAItB,IAAI,EAAE,IAAI,EACnB,QAAQ,UAAO;IAM1B,IAAI,KAAK,mDAER;IAIK,cAAc,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IAIxC,yBAAyB,IAAI,OAAO,CAAC,OAAO,CAAC;IAI7C,sBAAsB,IAAI,OAAO,CAAC,OAAO,CAAC;IAM1C,cAAc,CAAC,IAAI,EAAE,MAAM;IAO3B,sBAAsB,IAAI,OAAO,CAAC,MAAM,CAAC;IAOzC,WAAW;IAaX,eAAe,CAAC,cAAc,EAAE,MAAM;
|
|
1
|
+
{"version":3,"file":"shell-manager.d.ts","sourceRoot":"","sources":["../../../../src/testing/shell-manager.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAA0B,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAIrE,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAI5D,qBAAa,YAAa,SAAQ,kBAAkB;aAM9B,IAAI,EAAE,IAAI;IAC5B,QAAQ,CAAC,QAAQ;IANnB,OAAO,CAAC,eAAe,CAAyB;IAChD,OAAO,CAAC,SAAS,CAAyB;gBAItB,IAAI,EAAE,IAAI,EACnB,QAAQ,UAAO;IAM1B,IAAI,KAAK,mDAER;IAIK,cAAc,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IAIxC,yBAAyB,IAAI,OAAO,CAAC,OAAO,CAAC;IAI7C,sBAAsB,IAAI,OAAO,CAAC,OAAO,CAAC;IAM1C,cAAc,CAAC,IAAI,EAAE,MAAM;IAO3B,sBAAsB,IAAI,OAAO,CAAC,MAAM,CAAC;IAOzC,WAAW;IAaX,eAAe,CAAC,cAAc,EAAE,MAAM;IAOtC,kBAAkB,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,UAAO;IAUpD,UAAU;IAIV,qBAAqB,IAAI,OAAO,CAAC,MAAM,CAAC;IAOxC,qBAAqB,CAAC,cAAc,EAAE,MAAM;IAI5C,WAAW,IAAI,OAAO,CAAC,MAAM,CAAC;IAI9B,YAAY,CAAC,QAAQ,EAAE,MAAM;YAOrB,iBAAiB;CAWhC"}
|
|
@@ -51,15 +51,13 @@ class ShellManager extends scoped_shell_manager_1.ScopedShellManager {
|
|
|
51
51
|
};
|
|
52
52
|
this.page.on('dialog', handleDialog);
|
|
53
53
|
await this.shell.getByTestId('devices-panel.sign-out').click();
|
|
54
|
-
await this.shell.getByTestId('
|
|
55
|
-
this.
|
|
54
|
+
await this.shell.getByTestId('reset-storage.reset-identity-input').fill('CONFIRM');
|
|
55
|
+
await this.shell.getByTestId('reset-storage.reset-identity-confirm').click();
|
|
56
56
|
}
|
|
57
57
|
async joinNewIdentity(invitationCode) {
|
|
58
|
-
await this.shell.getByTestId('devices-panel.
|
|
59
|
-
await this.shell.getByTestId('
|
|
60
|
-
await this.shell.getByTestId('reset-identity-input').
|
|
61
|
-
await this.shell.getByTestId('reset-identity-input-confirm').click();
|
|
62
|
-
await this.shell.getByTestId('identity-chooser.join-identity').click();
|
|
58
|
+
await this.shell.getByTestId('devices-panel.join-new-identity').click();
|
|
59
|
+
await this.shell.getByTestId('join-new-identity.reset-identity-input').fill('CONFIRM');
|
|
60
|
+
await this.shell.getByTestId('join-new-identity.reset-identity-input-confirm').click();
|
|
63
61
|
await this.inputInvitation('device', invitationCode, this.shell);
|
|
64
62
|
}
|
|
65
63
|
async authenticateDevice(authCode, skipDone = true) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shell-manager.js","sourceRoot":"","sources":["../../../../src/testing/shell-manager.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;AAIF,uCAA6C;AAE7C,iEAA4D;AAE5D,yEAAyE;AAEzE,MAAa,YAAa,SAAQ,yCAAkB;IAIlD,kBAAkB;IAClB,YACoB,IAAU,EACnB,WAAW,IAAI;QAExB,KAAK,EAAE,CAAC;QAHU,SAAI,GAAJ,IAAI,CAAM;QACnB,aAAQ,GAAR,QAAQ,CAAO;QANlB,oBAAe,GAAG,IAAI,eAAO,EAAU,CAAC;QACxC,cAAS,GAAG,IAAI,eAAO,EAAU,CAAC;QAQxC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,SAAS,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC,CAAC;IACxE,CAAC;IAED,IAAI,KAAK;QACP,OAAO,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,wBAAwB,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC;IACtF,CAAC;IAED,UAAU;IAEV,KAAK,CAAC,cAAc;QAClB,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,6BAA6B,CAAC,CAAC,WAAW,EAAE,CAAC;IAC7E,CAAC;IAED,KAAK,CAAC,yBAAyB;QAC7B,OAAO,MAAM,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,oBAAoB,CAAC,CAAC,SAAS,EAAE,CAAC;IACxE,CAAC;IAED,KAAK,CAAC,sBAAsB;QAC1B,OAAO,MAAM,IAAI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,WAAW;QACf,OAAO,MAAM,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,CAAC;IACrC,CAAC;IAED,KAAK,CAAC,YAAY,CAAC,QAAgB;QACjC,yCAAyC;QACzC,MAAM,IAAA,aAAK,EAAC,IAAI,CAAC,CAAC;QAClB,MAAM,IAAI,CAAC,sBAAsB,CAAC,OAAO,EAAE,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;QACjE,MAAM,IAAI,CAAC,cAAc,CAAC,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;IACjD,CAAC;IAEO,KAAK,CAAC,iBAAiB,CAAC,OAAuB;QACrD,IAAI;YACF,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;YACxC,IAAI,IAAI,CAAC,cAAc,EAAE;gBACvB,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;aAChD;YACD,IAAI,IAAI,CAAC,QAAQ,EAAE;gBACjB,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;aACpC;SACF;QAAC,WAAM,GAAE;IACZ,CAAC;CACF;AAlHD,oCAkHC"}
|
|
@@ -19,4 +19,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
19
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
20
|
__exportStar(require("./FailReason"), exports);
|
|
21
21
|
__exportStar(require("./IInvitation"), exports);
|
|
22
|
+
// This comment is here to bust NX cache. Remove it after the code changes.
|
|
22
23
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/types/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;;;;;;;;;;;AAEF,+CAA6B;AAC7B,gDAA8B"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/types/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;;;;;;;;;;;AAEF,+CAA6B;AAC7B,gDAA8B;AAE9B,2EAA2E"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/shell",
|
|
3
|
-
"version": "0.4.10-main.
|
|
3
|
+
"version": "0.4.10-main.fd4f2a3",
|
|
4
4
|
"description": "DXOS’s OS experiences",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
@@ -42,19 +42,19 @@
|
|
|
42
42
|
"react-qr-rounded": "^1.0.0",
|
|
43
43
|
"url-join": "^5.0.0",
|
|
44
44
|
"xstate": "^4.37.0",
|
|
45
|
-
"@dxos/
|
|
46
|
-
"@dxos/client-services": "0.4.10-main.
|
|
47
|
-
"@dxos/
|
|
48
|
-
"@dxos/debug": "0.4.10-main.
|
|
49
|
-
"@dxos/display-name": "0.4.10-main.
|
|
50
|
-
"@dxos/invariant": "0.4.10-main.
|
|
51
|
-
"@dxos/
|
|
52
|
-
"@dxos/react-
|
|
53
|
-
"@dxos/
|
|
54
|
-
"@dxos/react-ui": "0.4.10-main.
|
|
55
|
-
"@dxos/
|
|
56
|
-
"@dxos/
|
|
57
|
-
"@dxos/
|
|
45
|
+
"@dxos/client-protocol": "0.4.10-main.fd4f2a3",
|
|
46
|
+
"@dxos/client-services": "0.4.10-main.fd4f2a3",
|
|
47
|
+
"@dxos/async": "0.4.10-main.fd4f2a3",
|
|
48
|
+
"@dxos/debug": "0.4.10-main.fd4f2a3",
|
|
49
|
+
"@dxos/display-name": "0.4.10-main.fd4f2a3",
|
|
50
|
+
"@dxos/invariant": "0.4.10-main.fd4f2a3",
|
|
51
|
+
"@dxos/log": "0.4.10-main.fd4f2a3",
|
|
52
|
+
"@dxos/react-client": "0.4.10-main.fd4f2a3",
|
|
53
|
+
"@dxos/react-ui": "0.4.10-main.fd4f2a3",
|
|
54
|
+
"@dxos/react-ui-theme": "0.4.10-main.fd4f2a3",
|
|
55
|
+
"@dxos/react-ui-types": "0.4.10-main.fd4f2a3",
|
|
56
|
+
"@dxos/rpc-tunnel": "0.4.10-main.fd4f2a3",
|
|
57
|
+
"@dxos/util": "0.4.10-main.fd4f2a3"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"@phosphor-icons/react": "^2.0.5",
|
|
@@ -63,13 +63,13 @@
|
|
|
63
63
|
"@vitejs/plugin-react": "^4.2.1",
|
|
64
64
|
"react": "^18.2.0",
|
|
65
65
|
"react-dom": "^18.2.0",
|
|
66
|
-
"vite": "^5.1.
|
|
66
|
+
"vite": "^5.1.7",
|
|
67
67
|
"vite-plugin-turbosnap": "^1.0.2",
|
|
68
|
-
"@dxos/config": "0.4.10-main.
|
|
69
|
-
"@dxos/
|
|
70
|
-
"@dxos/
|
|
71
|
-
"@dxos/
|
|
72
|
-
"@dxos/
|
|
68
|
+
"@dxos/config": "0.4.10-main.fd4f2a3",
|
|
69
|
+
"@dxos/react-ui-theme": "0.4.10-main.fd4f2a3",
|
|
70
|
+
"@dxos/react-async": "0.4.10-main.fd4f2a3",
|
|
71
|
+
"@dxos/random": "0.4.10-main.fd4f2a3",
|
|
72
|
+
"@dxos/storybook-utils": "0.4.10-main.fd4f2a3"
|
|
73
73
|
},
|
|
74
74
|
"peerDependencies": {
|
|
75
75
|
"@phosphor-icons/react": "^2.0.5",
|
|
@@ -64,6 +64,7 @@ export const ConfirmResetImpl = ({
|
|
|
64
64
|
const { t } = useTranslation('os');
|
|
65
65
|
const confirmationValue = t('confirmation value');
|
|
66
66
|
const [inputValue, setInputValue] = useState('');
|
|
67
|
+
const testIdAffix = mode === 'join new identity' ? 'join-new-identity' : 'reset-storage';
|
|
67
68
|
return (
|
|
68
69
|
<>
|
|
69
70
|
<div role='none' className='grow flex flex-col gap-2 justify-center'>
|
|
@@ -84,14 +85,14 @@ export const ConfirmResetImpl = ({
|
|
|
84
85
|
</StepHeading>
|
|
85
86
|
}
|
|
86
87
|
disabled={disabled}
|
|
87
|
-
data-testid=
|
|
88
|
+
data-testid={`${testIdAffix}.reset-identity-input`}
|
|
88
89
|
placeholder={confirmationValue}
|
|
89
90
|
onChange={({ target: { value } }) => setInputValue(value)}
|
|
90
91
|
/>
|
|
91
92
|
</div>
|
|
92
93
|
<Actions>
|
|
93
94
|
{onCancel && (
|
|
94
|
-
<Action disabled={disabled} onClick={onCancel} data-testid=
|
|
95
|
+
<Action disabled={disabled} onClick={onCancel} data-testid={`${testIdAffix}.reset-identity-cancel`}>
|
|
95
96
|
{t('cancel label')}
|
|
96
97
|
</Action>
|
|
97
98
|
)}
|
|
@@ -100,7 +101,7 @@ export const ConfirmResetImpl = ({
|
|
|
100
101
|
variant='destructive'
|
|
101
102
|
disabled={disabled || pending || inputValue !== confirmationValue}
|
|
102
103
|
onClick={onConfirm}
|
|
103
|
-
data-testid=
|
|
104
|
+
data-testid={`${testIdAffix}.reset-identity-confirm`}
|
|
104
105
|
>
|
|
105
106
|
{pending ? t('reset in progress label') : t('reset device label')}
|
|
106
107
|
</Action>
|
|
@@ -66,16 +66,14 @@ export class ShellManager extends ScopedShellManager {
|
|
|
66
66
|
|
|
67
67
|
this.page.on('dialog', handleDialog);
|
|
68
68
|
await this.shell.getByTestId('devices-panel.sign-out').click();
|
|
69
|
-
await this.shell.getByTestId('
|
|
70
|
-
this.
|
|
69
|
+
await this.shell.getByTestId('reset-storage.reset-identity-input').fill('CONFIRM');
|
|
70
|
+
await this.shell.getByTestId('reset-storage.reset-identity-confirm').click();
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
async joinNewIdentity(invitationCode: string) {
|
|
74
|
-
await this.shell.getByTestId('devices-panel.
|
|
75
|
-
await this.shell.getByTestId('
|
|
76
|
-
await this.shell.getByTestId('reset-identity-input').
|
|
77
|
-
await this.shell.getByTestId('reset-identity-input-confirm').click();
|
|
78
|
-
await this.shell.getByTestId('identity-chooser.join-identity').click();
|
|
74
|
+
await this.shell.getByTestId('devices-panel.join-new-identity').click();
|
|
75
|
+
await this.shell.getByTestId('join-new-identity.reset-identity-input').fill('CONFIRM');
|
|
76
|
+
await this.shell.getByTestId('join-new-identity.reset-identity-input-confirm').click();
|
|
79
77
|
await this.inputInvitation('device', invitationCode, this.shell);
|
|
80
78
|
}
|
|
81
79
|
|