@sparkvault/sdk-js 13.0.7 → 13.0.9

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.
@@ -41,7 +41,11 @@ export interface AuthContext {
41
41
  export interface VerifyOptions {
42
42
  /** Pre-fill email address (mutually exclusive with phone) */
43
43
  email?: string;
44
- /** Pre-fill phone number in E.164 format, e.g. "+14155551234" (mutually exclusive with email) */
44
+ /**
45
+ * Pre-fill phone number in E.164 format, e.g. "+14155551234" (mutually
46
+ * exclusive with email). The sign-in texts or calls it only once the person
47
+ * picks a text or call method, under the SMS and voice consent.
48
+ */
45
49
  phone?: string;
46
50
  /**
47
51
  * Target element for inline rendering. Can be:
@@ -93,7 +97,7 @@ export interface VerifyOptions {
93
97
  export interface AttachOptions {
94
98
  /** Pre-fill email address */
95
99
  email?: string;
96
- /** Pre-fill phone number in E.164 format */
100
+ /** Pre-fill phone number in E.164 format (see `VerifyOptions.phone`) */
97
101
  phone?: string;
98
102
  /** Auth context for OIDC/simple mode flows */
99
103
  authContext?: AuthContext;
@@ -2,9 +2,10 @@
2
2
  * Backup Verification Input View
3
3
  *
4
4
  * Post-login nudge to add the inverse identifier as a recovery backup:
5
- * collects a new phone (for an email login) or email (for a phone login),
6
- * then hands it off to send a one-time code. Includes a "Not now" skip that
7
- * suppresses this method's prompt for 30 days (handled by the renderer).
5
+ * collects a new phone (for an email login), under the SMS and voice consent,
6
+ * or email (for a phone login), then hands it off to send a one-time code.
7
+ * Includes a "Not now" skip that suppresses this method's prompt for 30 days
8
+ * (handled by the renderer).
8
9
  *
9
10
  * Sibling of PasskeyPromptView — same low-friction, skippable shape.
10
11
  */
@@ -4,7 +4,8 @@
4
4
  * Collects and validates the user's email or phone number: reads the input as
5
5
  * one or the other by the platform's rules (`@sparkvault/app-sdk/phone` and
6
6
  * `@sparkvault/app-sdk/email-address`), and formats a phone-only field as the
7
- * number is typed.
7
+ * number is typed. A field that takes a phone number carries the SMS and voice
8
+ * consent beneath it.
8
9
  */
9
10
  import type { View } from './base';
10
11
  export type IdentityType = 'email' | 'phone';
@@ -1,7 +1,11 @@
1
1
  /**
2
2
  * Method Select View
3
3
  *
4
- * Displays available authentication methods for the user to choose from.
4
+ * Displays available authentication methods for the user to choose from. A
5
+ * list that offers a text or a call carries the SMS and voice consent beneath
6
+ * it: a phone number the sign-in was handed reaches this list without passing
7
+ * the identifier field that carries it, so the tap on a text or call method is
8
+ * what gives it.
5
9
  */
6
10
  import type { View } from './base';
7
11
  import type { IdentityType } from './identity-input';
@@ -0,0 +1,15 @@
1
+ /**
2
+ * SMS and Voice Consent
3
+ *
4
+ * The line the sign-in shows wherever a person gives SparkVault a phone number
5
+ * to text or call, in the platform's one wording
6
+ * (`@sparkvault/app-sdk/consent-lines`): under every field that takes one, and
7
+ * under the method picker wherever it offers a text or a call. It describes
8
+ * the field or the methods above it, so a screen reader reads it with them.
9
+ */
10
+ /**
11
+ * The consent line, its "Terms" opening the terms in a new tab.
12
+ *
13
+ * @param id - The line's id, which the field or each method names in its `aria-describedby`
14
+ */
15
+ export declare function smsConsent(id: string): HTMLParagraphElement;
@@ -311,7 +311,9 @@ export declare class NotifyProductModule {
311
311
  *
312
312
  * Delete a category by storing an explicit `null` TOMBSTONE — that is what keeps
313
313
  * a seeded default from re-appearing on the next merge. The reserved `security`
314
- * category can neither be removed nor made optional.
314
+ * category can neither be removed nor made optional, and the promotional
315
+ * categories `marketing` and `product` can never be made required: their email
316
+ * always carries an unsubscribe link.
315
317
  *
316
318
  * The `events` section configures the outbound event webhook: `webhook_url`
317
319
  * must be https on a public host, and `secret` (16-256 chars) signs every event
@@ -922,7 +922,9 @@ export interface NotifyConfig {
922
922
  * `marketing`) is stored as a tombstone, which keeps the default from
923
923
  * re-appearing on the next merge; any other delete leaves no entry. Storing a
924
924
  * normal object under the same key later re-creates it. The reserved `security`
925
- * category can neither be removed nor made optional.
925
+ * category can neither be removed nor made optional, and the promotional
926
+ * categories `marketing` and `product` can never be made required: their email
927
+ * always carries an unsubscribe link.
926
928
  */
927
929
  export interface NotifyConfigPatch {
928
930
  delivery?: NotifyConfigDeliveryPatch;