@arbidocs/sdk 0.4.85 → 0.4.86
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/{browser-BOIk_RaR.d.cts → browser-V51dp6kY.d.cts} +4 -5
- package/dist/{browser-BOIk_RaR.d.ts → browser-V51dp6kY.d.ts} +4 -5
- package/dist/browser.cjs +5 -8
- package/dist/browser.cjs.map +1 -1
- package/dist/browser.d.cts +1 -1
- package/dist/browser.d.ts +1 -1
- package/dist/browser.js +6 -9
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +5 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +6 -9
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as _arbidocs_client from '@arbidocs/client';
|
|
2
1
|
import { SessionStorageProvider, ArbiClient, LoginResult, components, WebSocketServerMessage, WsAuthResultMessage, WsTaskUpdateMessage, KeyPair, LoginProfile } from '@arbidocs/client';
|
|
3
2
|
|
|
4
3
|
/**
|
|
@@ -5450,14 +5449,14 @@ declare class Arbi {
|
|
|
5450
5449
|
email: string;
|
|
5451
5450
|
}>;
|
|
5452
5451
|
/**
|
|
5453
|
-
* Change (or, after recovery, set) the master password
|
|
5454
|
-
*
|
|
5455
|
-
*
|
|
5452
|
+
* Change (or, after recovery, set) the master password. Omit `currentPassword` in recovery
|
|
5453
|
+
* mode. One request: the account identity is re-wrapped under the new password and nothing is
|
|
5454
|
+
* re-encrypted, so the session, the workspace keys and the recovery key all stay as they are.
|
|
5456
5455
|
*/
|
|
5457
5456
|
changePassword: (params: {
|
|
5458
5457
|
newPassword: string;
|
|
5459
5458
|
currentPassword?: string;
|
|
5460
|
-
}) => Promise<
|
|
5459
|
+
}) => Promise<void>;
|
|
5461
5460
|
/** Close the account (soft delete) and sign out. Refused while a subscription is active. */
|
|
5462
5461
|
requestDeletion: () => Promise<{
|
|
5463
5462
|
detail: string;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as _arbidocs_client from '@arbidocs/client';
|
|
2
1
|
import { SessionStorageProvider, ArbiClient, LoginResult, components, WebSocketServerMessage, WsAuthResultMessage, WsTaskUpdateMessage, KeyPair, LoginProfile } from '@arbidocs/client';
|
|
3
2
|
|
|
4
3
|
/**
|
|
@@ -5450,14 +5449,14 @@ declare class Arbi {
|
|
|
5450
5449
|
email: string;
|
|
5451
5450
|
}>;
|
|
5452
5451
|
/**
|
|
5453
|
-
* Change (or, after recovery, set) the master password
|
|
5454
|
-
*
|
|
5455
|
-
*
|
|
5452
|
+
* Change (or, after recovery, set) the master password. Omit `currentPassword` in recovery
|
|
5453
|
+
* mode. One request: the account identity is re-wrapped under the new password and nothing is
|
|
5454
|
+
* re-encrypted, so the session, the workspace keys and the recovery key all stay as they are.
|
|
5456
5455
|
*/
|
|
5457
5456
|
changePassword: (params: {
|
|
5458
5457
|
newPassword: string;
|
|
5459
5458
|
currentPassword?: string;
|
|
5460
|
-
}) => Promise<
|
|
5459
|
+
}) => Promise<void>;
|
|
5461
5460
|
/** Close the account (soft delete) and sign out. Refused while a subscription is active. */
|
|
5462
5461
|
requestDeletion: () => Promise<{
|
|
5463
5462
|
detail: string;
|
package/dist/browser.cjs
CHANGED
|
@@ -7575,25 +7575,22 @@ var Arbi = class {
|
|
|
7575
7575
|
return result;
|
|
7576
7576
|
},
|
|
7577
7577
|
/**
|
|
7578
|
-
* Change (or, after recovery, set) the master password
|
|
7579
|
-
*
|
|
7580
|
-
*
|
|
7578
|
+
* Change (or, after recovery, set) the master password. Omit `currentPassword` in recovery
|
|
7579
|
+
* mode. One request: the account identity is re-wrapped under the new password and nothing is
|
|
7580
|
+
* re-encrypted, so the session, the workspace keys and the recovery key all stay as they are.
|
|
7581
7581
|
*/
|
|
7582
7582
|
changePassword: async (params) => {
|
|
7583
7583
|
const client$1 = this.requireClient();
|
|
7584
7584
|
const lr2 = this.requireLogin();
|
|
7585
7585
|
const email = client$1.session.getState().userEmail ?? this.userProfile?.email;
|
|
7586
7586
|
if (!email) throw new ArbiError("The account email is unknown; sign in again.");
|
|
7587
|
-
|
|
7588
|
-
{ ...params, email,
|
|
7587
|
+
await client.changePassword(
|
|
7588
|
+
{ ...params, email, identitySecretKey: lr2.signingPrivateKey },
|
|
7589
7589
|
{
|
|
7590
7590
|
fetchClient: client$1.fetch,
|
|
7591
7591
|
deploymentDomain: this.getDeploymentDomain()
|
|
7592
7592
|
}
|
|
7593
7593
|
);
|
|
7594
|
-
this.loginResult = { ...lr2, signingPrivateKey: result.newSigningPrivateKey };
|
|
7595
|
-
this.wrappedKeys.clear();
|
|
7596
|
-
return result;
|
|
7597
7594
|
},
|
|
7598
7595
|
/** Close the account (soft delete) and sign out. Refused while a subscription is active. */
|
|
7599
7596
|
requestDeletion: async () => {
|