cauthy-auth 0.37.0 → 0.38.0
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/README.md +1 -1
- package/dist/client.d.mts +2 -1
- package/dist/client.d.ts +2 -1
- package/dist/client.js.map +1 -1
- package/dist/client.mjs.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -1
- package/dist/index.mjs.map +1 -1
- package/dist/react.d.mts +4 -2
- package/dist/react.d.ts +4 -2
- package/dist/react.js +6 -3
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +6 -3
- package/dist/react.mjs.map +1 -1
- package/dist/styles.css +10 -0
- package/dist/svelte.js.map +1 -1
- package/dist/svelte.mjs.map +1 -1
- package/dist/vue.js.map +1 -1
- package/dist/vue.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -76,7 +76,7 @@ import { Account, AccountPasskeys } from 'cauthy-auth/react'
|
|
|
76
76
|
|
|
77
77
|
`sections` lists the parts shown, in that order: `profile`, `email`, `password`, `linked`, `secondStep`, `phone`, `passkeys`, `agents`, `sessions` (default: all). Each is also its own component: `AccountProfile`, `AccountEmail`, `AccountPassword`, `AccountLinked`, `AccountSecondStep`, `AccountPhone`, `AccountPasskeys`, `AccountAgents`, `AccountSessions`. `onSaved` is called after every change saved, with `{ kind, ... }`: `profile.saved`, `email.change_requested`, `password.changed`, `identity.linked`, `identity.unlinked`, `mfa.enabled`, `mfa.disabled`, `recovery_codes.regenerated`, `phone.added`, `phone.removed`, `passkey.added`, `passkey.removed`, `agent.disconnected`, `sessions.ended`.
|
|
78
78
|
|
|
79
|
-
Each part shows a form only while what it sets up has nothing set yet: no second step, no phone, no passkey, no name. Once something is set, the part shows it (the name and address, "Your account has a password", the second step on, the masked phone and its channel, the passkeys with their kind and date) with its actions: "Change", "Change email", "Change password", "Turn off", "New recovery codes", "Remove phone", "Add a passkey". The form opens only when one is pressed, with a "Cancel" back; an action that weakens the account asks for the current password there, and runs at once for an account without one. Recovery codes, when made, are listed as text to select, with "Copy all" (to the clipboard, one per line) and "Download .txt" (`recovery-codes.txt`). They go nowhere else: no log, no browser storage.
|
|
79
|
+
Each part shows a form only while what it sets up has nothing set yet: no second step, no phone, no passkey, no name. Once something is set, the part shows it (the name and address, "Your account has a password", the second step on, the masked phone and its channel, the passkeys with their kind and date) with its actions: "Change", "Change email", "Change password", "Turn off", "New recovery codes", "Remove phone", "Add a passkey". The form opens only when one is pressed, with a "Cancel" back; an action that weakens the account asks for the current password there, and runs at once for an account without one. Turning the second step on shows the QR code to scan (drawn by Cauthy, a PNG `data:` image; `classNames.qr` styles it), the key to type by hand, and a link that opens an authenticator app on a phone. Recovery codes, when made, are listed as text to select, with "Copy all" (to the clipboard, one per line) and "Download .txt" (`recovery-codes.txt`). They go nowhere else: no log, no browser storage.
|
|
80
80
|
|
|
81
81
|
The legal documents a signed-in person still owes (a new version of the terms), with the action that accepts them. It shows nothing when nothing is owed:
|
|
82
82
|
|
package/dist/client.d.mts
CHANGED
|
@@ -403,12 +403,13 @@ interface AccountClient {
|
|
|
403
403
|
kinds?: string[];
|
|
404
404
|
}): Promise<AuthResult<'accepted'>>;
|
|
405
405
|
mfa: {
|
|
406
|
-
/** Starts turning the second step on: show `
|
|
406
|
+
/** Starts turning the second step on: show `qr` (the `otpauthUri` drawn by Cauthy, a PNG `data:` URI; empty from an older Cauthy) and `secret` to add to an authenticator app, then call `verify`. */
|
|
407
407
|
setup(form: {
|
|
408
408
|
password: string;
|
|
409
409
|
}): Promise<AuthResult<'started', {
|
|
410
410
|
secret: string;
|
|
411
411
|
otpauthUri: string;
|
|
412
|
+
qr: string;
|
|
412
413
|
}>>;
|
|
413
414
|
/** Turns it on with a code from the app. `recoveryCodes` are shown this once. */
|
|
414
415
|
verify(form: {
|
package/dist/client.d.ts
CHANGED
|
@@ -403,12 +403,13 @@ interface AccountClient {
|
|
|
403
403
|
kinds?: string[];
|
|
404
404
|
}): Promise<AuthResult<'accepted'>>;
|
|
405
405
|
mfa: {
|
|
406
|
-
/** Starts turning the second step on: show `
|
|
406
|
+
/** Starts turning the second step on: show `qr` (the `otpauthUri` drawn by Cauthy, a PNG `data:` URI; empty from an older Cauthy) and `secret` to add to an authenticator app, then call `verify`. */
|
|
407
407
|
setup(form: {
|
|
408
408
|
password: string;
|
|
409
409
|
}): Promise<AuthResult<'started', {
|
|
410
410
|
secret: string;
|
|
411
411
|
otpauthUri: string;
|
|
412
|
+
qr: string;
|
|
412
413
|
}>>;
|
|
413
414
|
/** Turns it on with a code from the app. `recoveryCodes` are shown this once. */
|
|
414
415
|
verify(form: {
|