@sekyro/react 0.1.0-rc.3 → 0.1.0-rc.5

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/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode, RefObject } from 'react';
3
- import { CaptureErrorKind, GateHint, ReasonCode, CameraPermissionState, CameraFacing, Verification, CaptureError, CapturedArtifacts, VerificationResult, CaptureState } from '@sekyro/web';
3
+ import { CaptureErrorKind, GateHint, ReasonCode, CameraPermissionState, CameraFacing, Verification, CaptureError, CapturedArtifacts, VerificationResult, CaptureState, HostedBranding } from '@sekyro/web';
4
4
 
5
5
  /** A built-in tip (copy `capture.tips.<id>`, built-in icon). */
6
6
  type BuiltInTipId = "light" | "uncover" | "eyeLevel" | "straight";
@@ -79,10 +79,41 @@ interface Strings {
79
79
  "reasons.expired_document": string;
80
80
  "reasons.authenticity_review": string;
81
81
  "reasons.registry_mismatch": string;
82
+ "reasons.document_nni_mismatch": string;
82
83
  "reasons.otp_mismatch": string;
83
84
  "reasons.otp_expired": string;
84
85
  "reasons.otp_send_failed": string;
85
86
  "reasons.uncalibrated_capture_channel": string;
87
+ "reasons.location_not_allowed": string;
88
+ "reasons.anonymizer_blocked": string;
89
+ "reasons.nationality_not_allowed": string;
90
+ "reasons.document_type_not_accepted": string;
91
+ "reasons.underage": string;
92
+ "reasons.age_unverifiable": string;
93
+ "reasons.name_mismatch": string;
94
+ "reasons.birth_date_mismatch": string;
95
+ "reasons.nationality_mismatch": string;
96
+ "reasons.document_number_mismatch": string;
97
+ "reasons.liveness_inconclusive": string;
98
+ "reasons.match_inconclusive": string;
99
+ "reasons.document_authenticity": string;
100
+ "reasons.mobile_required": string;
101
+ "reasons.capture_tampered": string;
102
+ "reasons.device_velocity_exceeded": string;
103
+ /** `device_cooldown` without a usable `retryAfter`. */
104
+ "reasons.device_cooldown": string;
105
+ /** `device_cooldown`, `{time}` = a relative time ("in 5 minutes"). */
106
+ "cooldown.retryIn": string;
107
+ /** `device_cooldown`, `{time}` = a clock time (with the date when not today). */
108
+ "cooldown.retryAt": string;
109
+ /** The model service is busy and the SDK retries by itself. */
110
+ "capture.busy": string;
111
+ "errors.inference_unavailable": string;
112
+ "method.title": string;
113
+ "method.description": string;
114
+ "method.national_number": string;
115
+ "method.document_photo": string;
116
+ "errors.method_required": string;
86
117
  "errors.attestation_invalid": string;
87
118
  "errors.network_error": string;
88
119
  "errors.session_expired": string;
@@ -92,6 +123,11 @@ interface Strings {
92
123
  "capture.tips.uncover": string;
93
124
  "capture.tips.eyeLevel": string;
94
125
  "capture.tips.straight": string;
126
+ /** Spoken by the pre-capture "Listen" button (voice key `capture.tips.summary`); says what the built-in tips say. */
127
+ "capture.tips.summary": string;
128
+ "capture.tips.listen": string;
129
+ /** The Listen button's label while the summary plays. */
130
+ "capture.tips.stop": string;
95
131
  "capture.permission.granted": string;
96
132
  "capture.permission.prompt": string;
97
133
  "capture.permission.denied": string;
@@ -126,6 +162,18 @@ declare function captureErrorStringKey(kind: CaptureErrorKind): StringKey;
126
162
  * `reasons.*`. Returns `null` for a reason without built-in copy.
127
163
  */
128
164
  declare function reasonStringKey(reason: ReasonCode): StringKey | null;
165
+ /**
166
+ * When a device in cooldown may verify again (`device_cooldown` +
167
+ * `retryAfter`), as the copy key and its `{time}`: within the hour a relative
168
+ * time ("in 5 minutes", minutes rounded up) for `cooldown.retryIn`; later a
169
+ * clock time — with the date when it is not today — for `cooldown.retryAt`.
170
+ * `null` when `retryAfter` is missing, invalid or already past (use
171
+ * `reasons.device_cooldown`). Locale digits and wording come from `Intl`.
172
+ */
173
+ declare function retryAfterTime(locale: SekyroLocale, retryAfter: string | undefined, now?: Date): {
174
+ key: "cooldown.retryIn" | "cooldown.retryAt";
175
+ time: string;
176
+ } | null;
129
177
  /**
130
178
  * The remaining-attempts line for `count`, pluralized with the locale's CLDR
131
179
  * rules (`Intl.PluralRules`) and the locale's digits (`Intl.NumberFormat`) —
@@ -133,8 +181,12 @@ declare function reasonStringKey(reason: ReasonCode): StringKey | null;
133
181
  */
134
182
  declare function attemptsRemainingText(dictionary: Strings, locale: SekyroLocale, count: number): string;
135
183
 
136
- /** Guidance keys that can be spoken (the engine's fcv3.* gate hints). */
137
- type VoiceKey = "fcv3.no_face" | "fcv3.come_closer" | "fcv3.move_back" | "fcv3.center_face" | "fcv3.straighten" | "fcv3.more_light" | "fcv3.too_bright" | "fcv3.hold_still" | "fcv3.steady_camera";
184
+ /**
185
+ * Keys that can be spoken: the engine's `fcv3.*` gate hints, plus
186
+ * `capture.tips.summary` — the pre-capture "Listen to the instructions" summary
187
+ * (played only on an explicit tap, never during capture).
188
+ */
189
+ type VoiceKey = "fcv3.no_face" | "fcv3.come_closer" | "fcv3.move_back" | "fcv3.center_face" | "fcv3.straighten" | "fcv3.more_light" | "fcv3.too_bright" | "fcv3.hold_still" | "fcv3.steady_camera" | "capture.tips.summary";
138
190
  /** Every {@link VoiceKey}, in a stable order (e.g. to build a clip map). */
139
191
  declare const VOICE_KEYS: readonly VoiceKey[];
140
192
 
@@ -151,37 +203,22 @@ type VoiceClipMap = {
151
203
  };
152
204
  /** `voice.clips`: a resolver function or a `{ [locale]: { [voiceKey]: url } }` map. */
153
205
  type VoiceClipSource = VoiceClipResolver | VoiceClipMap;
154
- /**
155
- * A clip-set manifest (the `assets/audio/<set>/manifest.json` shape): per
156
- * locale, one entry per shipped clip, keyed by clip name (`center_face` for
157
- * `fcv3.center_face`). Entry contents (sha256, text, bytes) are not needed to resolve.
158
- */
159
- interface VoiceClipManifest {
160
- readonly set: string;
161
- readonly clips: {
162
- readonly [L in SekyroLocale]?: Readonly<Record<string, unknown>> | undefined;
163
- };
164
- }
165
- /**
166
- * Resolver over a manifest: a listed key resolves to `<baseUrl>/<locale>/<name>.mp3`
167
- * (`baseUrl` = the set's directory, where its manifest.json lives); anything
168
- * else resolves to `null`, so a missing clip costs no 404 round-trip.
169
- */
170
- declare function createManifestResolver(manifest: VoiceClipManifest, baseUrl: string): VoiceClipResolver;
171
206
 
172
207
  /** Voice-guidance options of `<LivenessCapture voice>`. */
173
208
  interface VoiceOptions {
174
209
  /** Initial state when the viewer has no stored preference. Default `true`. */
175
210
  defaultEnabled?: boolean;
176
211
  /**
177
- * Clip source; replaces the bundled set. Either a resolver `(key, locale) → url | null`
178
- * or a map `{ [locale]: { [voiceKey]: url } }` (e.g. delivered by the backend;
212
+ * Clip source; replaces the default. Either a resolver `(key, locale) → url | null`
213
+ * or a map `{ [locale]: { [voiceKey]: url } }` (e.g. delivered by your backend;
179
214
  * pass a new object to change it). A key without a URL — or a resolver that
180
215
  * throws — means "no clip" (speech fallback applies).
216
+ *
217
+ * Default: in verification mode, the Sekyro AI clip set delivered with the
218
+ * session (`https://assets.sekyro.ai` — allow it in your CSP `media-src`);
219
+ * in capture-only mode, none (device voice only).
181
220
  */
182
221
  clips?: VoiceClipSource;
183
- /** Base of the bundled clip set; default `${assetBaseUrl ?? "/models-v3"}/audio/v1`. */
184
- clipBaseUrl?: string;
185
222
  /** Locales where the device voice (speechSynthesis) may speak when no clip plays. Default `true` (all). */
186
223
  speechFallback?: boolean | readonly SekyroLocale[];
187
224
  /** localStorage key of the viewer's preference; `null` = do not persist. Default `"sekyro.voiceGuidance"`. */
@@ -293,13 +330,21 @@ interface LivenessCaptureProps {
293
330
  startDisabled?: boolean;
294
331
  /** Built-in Start label; default `capture.start`. */
295
332
  startLabel?: ReactNode;
296
- /** Tips on the pre-capture screen; default {@link DEFAULT_TIPS}; `false` hides the card. */
333
+ /**
334
+ * Tips on the pre-capture screen; default {@link DEFAULT_TIPS}; `false` hides the card.
335
+ * The "Listen to the instructions" button (spoken `capture.tips.summary`)
336
+ * shows with the built-in tips only — or with any tips when `voice.clips`
337
+ * supplies a `capture.tips.summary` clip for the locale.
338
+ */
297
339
  tips?: false | ReadonlyArray<BuiltInTipId | IntroTip>;
298
340
  /** Camera the attempt opens with; default `"user"` (front). */
299
341
  defaultFacing?: CameraFacing;
300
342
  /**
301
- * Voice guidance (on by default: bundled clips, device-voice fallback).
302
- * `false` = no speech, no voice switch, no stage chip.
343
+ * Voice guidance (on by default). Clips: `voice.clips` when given; else, in
344
+ * verification mode, the Sekyro AI clip set delivered with the session (served
345
+ * from `https://assets.sekyro.ai` — allow it in your CSP `media-src`); else
346
+ * none. The device voice covers any key without a clip.
347
+ * `false` = no speech, no voice switch, no stage chip, no "Listen" button.
303
348
  */
304
349
  voice?: false | VoiceOptions;
305
350
  /** Telemetry: once per change of the displayed, spoken-able (`fcv3.*`) guidance key. */
@@ -368,6 +413,17 @@ declare const DEFAULT_THEME: Required<SekyroTheme> & {
368
413
  };
369
414
  /** The CSS custom properties a theme resolves to (defaults filled in). */
370
415
  declare function themeToCssVars(theme?: SekyroTheme): Record<string, string>;
416
+ /**
417
+ * Map the session's org / app branding (`HostedSessionView.branding`, set in
418
+ * the Sekyro dashboard) onto a {@link SekyroTheme}. Each colour maps to the
419
+ * theme key of the same name and the focus ring follows `brand`. Values that
420
+ * are not `#rrggbb` are ignored. Combine with your own theme through
421
+ * {@link mergeThemes} — pass yours LAST so it wins:
422
+ * `mergeThemes(brandingToTheme(view.branding), myTheme)`.
423
+ */
424
+ declare function brandingToTheme(branding: HostedBranding | undefined): SekyroTheme;
425
+ /** Merge themes left to right: a later theme wins per token (colours merge per key). */
426
+ declare function mergeThemes(...themes: (SekyroTheme | undefined)[]): SekyroTheme;
371
427
  /** Props of {@link SekyroThemeProvider}. */
372
428
  interface SekyroThemeProviderProps {
373
429
  /** Partial theme; unset tokens keep the {@link DEFAULT_THEME} values. */
@@ -386,4 +442,4 @@ declare function SekyroThemeProvider({ theme, children, className }: SekyroTheme
386
442
  /** The complete dictionary for `locale` with `overrides` merged on top. */
387
443
  declare function resolveStrings(locale: SekyroLocale, overrides?: Partial<Strings>): Strings;
388
444
 
389
- export { type BuiltInTipId, DEFAULT_THEME, DEFAULT_TIPS, type IntroContext, type IntroTip, LivenessCapture, type LivenessCaptureProps, type LivenessCaptureSlots, type LivenessNotice, NO_FACE_DEBOUNCE_MS, type SekyroLocale, type SekyroTheme, type SekyroThemeColors, SekyroThemeProvider, type SekyroThemeProviderProps, type StringKey, type Strings, VOICE_KEYS, type VoiceClipManifest, type VoiceClipMap, type VoiceClipResolver, type VoiceClipSource, type VoiceControl, type VoiceKey, type VoiceOptions, ar, attemptsRemainingText, captureErrorStringKey, createManifestResolver, en, fr, hintStringKey, reasonStringKey, resolveStrings, themeToCssVars };
445
+ export { type BuiltInTipId, DEFAULT_THEME, DEFAULT_TIPS, type IntroContext, type IntroTip, LivenessCapture, type LivenessCaptureProps, type LivenessCaptureSlots, type LivenessNotice, NO_FACE_DEBOUNCE_MS, type SekyroLocale, type SekyroTheme, type SekyroThemeColors, SekyroThemeProvider, type SekyroThemeProviderProps, type StringKey, type Strings, VOICE_KEYS, type VoiceClipMap, type VoiceClipResolver, type VoiceClipSource, type VoiceControl, type VoiceKey, type VoiceOptions, ar, attemptsRemainingText, brandingToTheme, captureErrorStringKey, en, fr, hintStringKey, mergeThemes, reasonStringKey, resolveStrings, retryAfterTime, themeToCssVars };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode, RefObject } from 'react';
3
- import { CaptureErrorKind, GateHint, ReasonCode, CameraPermissionState, CameraFacing, Verification, CaptureError, CapturedArtifacts, VerificationResult, CaptureState } from '@sekyro/web';
3
+ import { CaptureErrorKind, GateHint, ReasonCode, CameraPermissionState, CameraFacing, Verification, CaptureError, CapturedArtifacts, VerificationResult, CaptureState, HostedBranding } from '@sekyro/web';
4
4
 
5
5
  /** A built-in tip (copy `capture.tips.<id>`, built-in icon). */
6
6
  type BuiltInTipId = "light" | "uncover" | "eyeLevel" | "straight";
@@ -79,10 +79,41 @@ interface Strings {
79
79
  "reasons.expired_document": string;
80
80
  "reasons.authenticity_review": string;
81
81
  "reasons.registry_mismatch": string;
82
+ "reasons.document_nni_mismatch": string;
82
83
  "reasons.otp_mismatch": string;
83
84
  "reasons.otp_expired": string;
84
85
  "reasons.otp_send_failed": string;
85
86
  "reasons.uncalibrated_capture_channel": string;
87
+ "reasons.location_not_allowed": string;
88
+ "reasons.anonymizer_blocked": string;
89
+ "reasons.nationality_not_allowed": string;
90
+ "reasons.document_type_not_accepted": string;
91
+ "reasons.underage": string;
92
+ "reasons.age_unverifiable": string;
93
+ "reasons.name_mismatch": string;
94
+ "reasons.birth_date_mismatch": string;
95
+ "reasons.nationality_mismatch": string;
96
+ "reasons.document_number_mismatch": string;
97
+ "reasons.liveness_inconclusive": string;
98
+ "reasons.match_inconclusive": string;
99
+ "reasons.document_authenticity": string;
100
+ "reasons.mobile_required": string;
101
+ "reasons.capture_tampered": string;
102
+ "reasons.device_velocity_exceeded": string;
103
+ /** `device_cooldown` without a usable `retryAfter`. */
104
+ "reasons.device_cooldown": string;
105
+ /** `device_cooldown`, `{time}` = a relative time ("in 5 minutes"). */
106
+ "cooldown.retryIn": string;
107
+ /** `device_cooldown`, `{time}` = a clock time (with the date when not today). */
108
+ "cooldown.retryAt": string;
109
+ /** The model service is busy and the SDK retries by itself. */
110
+ "capture.busy": string;
111
+ "errors.inference_unavailable": string;
112
+ "method.title": string;
113
+ "method.description": string;
114
+ "method.national_number": string;
115
+ "method.document_photo": string;
116
+ "errors.method_required": string;
86
117
  "errors.attestation_invalid": string;
87
118
  "errors.network_error": string;
88
119
  "errors.session_expired": string;
@@ -92,6 +123,11 @@ interface Strings {
92
123
  "capture.tips.uncover": string;
93
124
  "capture.tips.eyeLevel": string;
94
125
  "capture.tips.straight": string;
126
+ /** Spoken by the pre-capture "Listen" button (voice key `capture.tips.summary`); says what the built-in tips say. */
127
+ "capture.tips.summary": string;
128
+ "capture.tips.listen": string;
129
+ /** The Listen button's label while the summary plays. */
130
+ "capture.tips.stop": string;
95
131
  "capture.permission.granted": string;
96
132
  "capture.permission.prompt": string;
97
133
  "capture.permission.denied": string;
@@ -126,6 +162,18 @@ declare function captureErrorStringKey(kind: CaptureErrorKind): StringKey;
126
162
  * `reasons.*`. Returns `null` for a reason without built-in copy.
127
163
  */
128
164
  declare function reasonStringKey(reason: ReasonCode): StringKey | null;
165
+ /**
166
+ * When a device in cooldown may verify again (`device_cooldown` +
167
+ * `retryAfter`), as the copy key and its `{time}`: within the hour a relative
168
+ * time ("in 5 minutes", minutes rounded up) for `cooldown.retryIn`; later a
169
+ * clock time — with the date when it is not today — for `cooldown.retryAt`.
170
+ * `null` when `retryAfter` is missing, invalid or already past (use
171
+ * `reasons.device_cooldown`). Locale digits and wording come from `Intl`.
172
+ */
173
+ declare function retryAfterTime(locale: SekyroLocale, retryAfter: string | undefined, now?: Date): {
174
+ key: "cooldown.retryIn" | "cooldown.retryAt";
175
+ time: string;
176
+ } | null;
129
177
  /**
130
178
  * The remaining-attempts line for `count`, pluralized with the locale's CLDR
131
179
  * rules (`Intl.PluralRules`) and the locale's digits (`Intl.NumberFormat`) —
@@ -133,8 +181,12 @@ declare function reasonStringKey(reason: ReasonCode): StringKey | null;
133
181
  */
134
182
  declare function attemptsRemainingText(dictionary: Strings, locale: SekyroLocale, count: number): string;
135
183
 
136
- /** Guidance keys that can be spoken (the engine's fcv3.* gate hints). */
137
- type VoiceKey = "fcv3.no_face" | "fcv3.come_closer" | "fcv3.move_back" | "fcv3.center_face" | "fcv3.straighten" | "fcv3.more_light" | "fcv3.too_bright" | "fcv3.hold_still" | "fcv3.steady_camera";
184
+ /**
185
+ * Keys that can be spoken: the engine's `fcv3.*` gate hints, plus
186
+ * `capture.tips.summary` — the pre-capture "Listen to the instructions" summary
187
+ * (played only on an explicit tap, never during capture).
188
+ */
189
+ type VoiceKey = "fcv3.no_face" | "fcv3.come_closer" | "fcv3.move_back" | "fcv3.center_face" | "fcv3.straighten" | "fcv3.more_light" | "fcv3.too_bright" | "fcv3.hold_still" | "fcv3.steady_camera" | "capture.tips.summary";
138
190
  /** Every {@link VoiceKey}, in a stable order (e.g. to build a clip map). */
139
191
  declare const VOICE_KEYS: readonly VoiceKey[];
140
192
 
@@ -151,37 +203,22 @@ type VoiceClipMap = {
151
203
  };
152
204
  /** `voice.clips`: a resolver function or a `{ [locale]: { [voiceKey]: url } }` map. */
153
205
  type VoiceClipSource = VoiceClipResolver | VoiceClipMap;
154
- /**
155
- * A clip-set manifest (the `assets/audio/<set>/manifest.json` shape): per
156
- * locale, one entry per shipped clip, keyed by clip name (`center_face` for
157
- * `fcv3.center_face`). Entry contents (sha256, text, bytes) are not needed to resolve.
158
- */
159
- interface VoiceClipManifest {
160
- readonly set: string;
161
- readonly clips: {
162
- readonly [L in SekyroLocale]?: Readonly<Record<string, unknown>> | undefined;
163
- };
164
- }
165
- /**
166
- * Resolver over a manifest: a listed key resolves to `<baseUrl>/<locale>/<name>.mp3`
167
- * (`baseUrl` = the set's directory, where its manifest.json lives); anything
168
- * else resolves to `null`, so a missing clip costs no 404 round-trip.
169
- */
170
- declare function createManifestResolver(manifest: VoiceClipManifest, baseUrl: string): VoiceClipResolver;
171
206
 
172
207
  /** Voice-guidance options of `<LivenessCapture voice>`. */
173
208
  interface VoiceOptions {
174
209
  /** Initial state when the viewer has no stored preference. Default `true`. */
175
210
  defaultEnabled?: boolean;
176
211
  /**
177
- * Clip source; replaces the bundled set. Either a resolver `(key, locale) → url | null`
178
- * or a map `{ [locale]: { [voiceKey]: url } }` (e.g. delivered by the backend;
212
+ * Clip source; replaces the default. Either a resolver `(key, locale) → url | null`
213
+ * or a map `{ [locale]: { [voiceKey]: url } }` (e.g. delivered by your backend;
179
214
  * pass a new object to change it). A key without a URL — or a resolver that
180
215
  * throws — means "no clip" (speech fallback applies).
216
+ *
217
+ * Default: in verification mode, the Sekyro AI clip set delivered with the
218
+ * session (`https://assets.sekyro.ai` — allow it in your CSP `media-src`);
219
+ * in capture-only mode, none (device voice only).
181
220
  */
182
221
  clips?: VoiceClipSource;
183
- /** Base of the bundled clip set; default `${assetBaseUrl ?? "/models-v3"}/audio/v1`. */
184
- clipBaseUrl?: string;
185
222
  /** Locales where the device voice (speechSynthesis) may speak when no clip plays. Default `true` (all). */
186
223
  speechFallback?: boolean | readonly SekyroLocale[];
187
224
  /** localStorage key of the viewer's preference; `null` = do not persist. Default `"sekyro.voiceGuidance"`. */
@@ -293,13 +330,21 @@ interface LivenessCaptureProps {
293
330
  startDisabled?: boolean;
294
331
  /** Built-in Start label; default `capture.start`. */
295
332
  startLabel?: ReactNode;
296
- /** Tips on the pre-capture screen; default {@link DEFAULT_TIPS}; `false` hides the card. */
333
+ /**
334
+ * Tips on the pre-capture screen; default {@link DEFAULT_TIPS}; `false` hides the card.
335
+ * The "Listen to the instructions" button (spoken `capture.tips.summary`)
336
+ * shows with the built-in tips only — or with any tips when `voice.clips`
337
+ * supplies a `capture.tips.summary` clip for the locale.
338
+ */
297
339
  tips?: false | ReadonlyArray<BuiltInTipId | IntroTip>;
298
340
  /** Camera the attempt opens with; default `"user"` (front). */
299
341
  defaultFacing?: CameraFacing;
300
342
  /**
301
- * Voice guidance (on by default: bundled clips, device-voice fallback).
302
- * `false` = no speech, no voice switch, no stage chip.
343
+ * Voice guidance (on by default). Clips: `voice.clips` when given; else, in
344
+ * verification mode, the Sekyro AI clip set delivered with the session (served
345
+ * from `https://assets.sekyro.ai` — allow it in your CSP `media-src`); else
346
+ * none. The device voice covers any key without a clip.
347
+ * `false` = no speech, no voice switch, no stage chip, no "Listen" button.
303
348
  */
304
349
  voice?: false | VoiceOptions;
305
350
  /** Telemetry: once per change of the displayed, spoken-able (`fcv3.*`) guidance key. */
@@ -368,6 +413,17 @@ declare const DEFAULT_THEME: Required<SekyroTheme> & {
368
413
  };
369
414
  /** The CSS custom properties a theme resolves to (defaults filled in). */
370
415
  declare function themeToCssVars(theme?: SekyroTheme): Record<string, string>;
416
+ /**
417
+ * Map the session's org / app branding (`HostedSessionView.branding`, set in
418
+ * the Sekyro dashboard) onto a {@link SekyroTheme}. Each colour maps to the
419
+ * theme key of the same name and the focus ring follows `brand`. Values that
420
+ * are not `#rrggbb` are ignored. Combine with your own theme through
421
+ * {@link mergeThemes} — pass yours LAST so it wins:
422
+ * `mergeThemes(brandingToTheme(view.branding), myTheme)`.
423
+ */
424
+ declare function brandingToTheme(branding: HostedBranding | undefined): SekyroTheme;
425
+ /** Merge themes left to right: a later theme wins per token (colours merge per key). */
426
+ declare function mergeThemes(...themes: (SekyroTheme | undefined)[]): SekyroTheme;
371
427
  /** Props of {@link SekyroThemeProvider}. */
372
428
  interface SekyroThemeProviderProps {
373
429
  /** Partial theme; unset tokens keep the {@link DEFAULT_THEME} values. */
@@ -386,4 +442,4 @@ declare function SekyroThemeProvider({ theme, children, className }: SekyroTheme
386
442
  /** The complete dictionary for `locale` with `overrides` merged on top. */
387
443
  declare function resolveStrings(locale: SekyroLocale, overrides?: Partial<Strings>): Strings;
388
444
 
389
- export { type BuiltInTipId, DEFAULT_THEME, DEFAULT_TIPS, type IntroContext, type IntroTip, LivenessCapture, type LivenessCaptureProps, type LivenessCaptureSlots, type LivenessNotice, NO_FACE_DEBOUNCE_MS, type SekyroLocale, type SekyroTheme, type SekyroThemeColors, SekyroThemeProvider, type SekyroThemeProviderProps, type StringKey, type Strings, VOICE_KEYS, type VoiceClipManifest, type VoiceClipMap, type VoiceClipResolver, type VoiceClipSource, type VoiceControl, type VoiceKey, type VoiceOptions, ar, attemptsRemainingText, captureErrorStringKey, createManifestResolver, en, fr, hintStringKey, reasonStringKey, resolveStrings, themeToCssVars };
445
+ export { type BuiltInTipId, DEFAULT_THEME, DEFAULT_TIPS, type IntroContext, type IntroTip, LivenessCapture, type LivenessCaptureProps, type LivenessCaptureSlots, type LivenessNotice, NO_FACE_DEBOUNCE_MS, type SekyroLocale, type SekyroTheme, type SekyroThemeColors, SekyroThemeProvider, type SekyroThemeProviderProps, type StringKey, type Strings, VOICE_KEYS, type VoiceClipMap, type VoiceClipResolver, type VoiceClipSource, type VoiceControl, type VoiceKey, type VoiceOptions, ar, attemptsRemainingText, brandingToTheme, captureErrorStringKey, en, fr, hintStringKey, mergeThemes, reasonStringKey, resolveStrings, retryAfterTime, themeToCssVars };