@sparkvault/sdk-js 16.2.0 → 16.3.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.
@@ -6,6 +6,8 @@ export interface SupportViewState {
6
6
  visible: boolean;
7
7
  deskName: string;
8
8
  brandColor?: string | null;
9
+ /** The desk's plain-text note beside the results' ticket button. */
10
+ contactNote?: string;
9
11
  stage: SupportViewStage;
10
12
  issue: string;
11
13
  busy?: boolean;
@@ -87,6 +89,7 @@ export declare class SupportView {
87
89
  private readonly resultStatus;
88
90
  private readonly resultError;
89
91
  private readonly contactResults;
92
+ private readonly contactNote;
90
93
  private readonly resultsFooter;
91
94
  private readonly articleTitle;
92
95
  private readonly articleCategory;
@@ -66,6 +66,8 @@ export interface HelpDeskDesk {
66
66
  customer_can_mark_resolved: boolean;
67
67
  /** Optional plain-text note shown only after a request is confirmed sent. */
68
68
  ticket_confirmation_message?: string | null;
69
+ /** Optional one-line plain-text note shown beside the support view's ticket button. */
70
+ ticket_contact_note?: string | null;
69
71
  /** Independent ticket-portal gate, additional to customer authentication. */
70
72
  ticket_access_control?: {
71
73
  mode: 'public' | 'password' | 'ip_allowlist' | 'identity';
@@ -53,7 +53,10 @@ interface LauncherCallbacks {
53
53
  * The popup's handle was severed (COOP) — postMessage can never deliver, so
54
54
  * a retry popup is futile. The owner should switch this tab to the redirect
55
55
  * flow; resolve `true` when the navigation started (this page is unloading),
56
- * `false` to fall back to the retry alert (e.g. no session storage).
56
+ * `false` when it did not: the return leg could not be armed (e.g. no
57
+ * session storage), and the launcher falls back to the retry alert, or the
58
+ * sign-in ended meanwhile (settled, or this launcher closed), and there is
59
+ * no alert left to show.
57
60
  */
58
61
  onPopupSevered?: () => Promise<boolean>;
59
62
  /**
@@ -190,14 +190,19 @@ export declare class IdentityModule {
190
190
  * 'redirect'`, or a popup whose handle COOP severed. Plain sign-in carries
191
191
  * redirect_uri + state + PKCE challenge and returns via the fragment code;
192
192
  * OIDC/simple modes navigate without them (their server-rendered pages drive
193
- * the server-validated redirect back). Either carries `signinRef`, the
194
- * severed popup's reference; a redirect draws none of its own.
193
+ * the server-validated redirect back). Either carries the severed popup's
194
+ * reference; a redirect draws none of its own.
195
195
  *
196
- * @param signinRef - The reference the pending marker holds for this
197
- * sign-in, or null for a page sent without one
196
+ * The return leg is armed first: the check that the sign-in still runs and
197
+ * the pending marker's removal then share one turn with the navigation, so
198
+ * no sign-in can start or end between them.
199
+ *
200
+ * @param severed - The popup sign-in whose severed popup this continues,
201
+ * with the reference its marker holds for that popup (null for none), or
202
+ * null for an explicit redirect, which carries none
198
203
  * @returns false when the return leg cannot be armed (no session storage or
199
- * WebCrypto) — the caller surfaces an actionable error instead of a
200
- * silent dead-end.
204
+ * WebCrypto), so the caller surfaces an actionable error instead of a
205
+ * silent dead-end, or when the severed popup's sign-in ended meanwhile.
201
206
  */
202
207
  private startRedirectFlow;
203
208
  /**
@@ -46,7 +46,7 @@ export declare function removePendingMarker(): void;
46
46
  export declare class PendingSignIn {
47
47
  private readonly hint;
48
48
  private at;
49
- private live;
49
+ private ended;
50
50
  private opens;
51
51
  private current;
52
52
  private decided;
@@ -58,6 +58,8 @@ export declare class PendingSignIn {
58
58
  * holds.
59
59
  */
60
60
  get reference(): string | null | undefined;
61
+ /** False once the sign-in ended: it settled, was closed, or another replaced it. */
62
+ get live(): boolean;
61
63
  /**
62
64
  * A popup opened, or the current one asked again for the reference it
63
65
  * lacks: arm the marker holding no reference, and draw this open's own.