@forgerock/login-widget 1.0.0-beta.9 → 1.0.1

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/package.json CHANGED
@@ -11,14 +11,7 @@
11
11
  "require": "./widget.css"
12
12
  }
13
13
  },
14
- "types": "./index.d.ts",
15
- "typesVersions": {
16
- "*": {
17
- "index": [
18
- "./index.d.ts"
19
- ]
20
- }
21
- },
14
+ "types": "./types.d.ts",
22
15
  "dependencies": {},
23
- "version": "1.0.0-beta.9"
16
+ "version": "1.0.1"
24
17
  }
@@ -1,3 +1,44 @@
1
+ /**
2
+ * An event-handling function.
3
+ */
4
+ declare type Listener = (e: FREvent) => void;
5
+ interface FREvent {
6
+ type: string;
7
+ }
8
+
9
+ /**
10
+ * Event dispatcher for subscribing and publishing categorized events.
11
+ */
12
+ declare class Dispatcher {
13
+ private callbacks;
14
+ /**
15
+ * Subscribes to an event type.
16
+ *
17
+ * @param type The event type
18
+ * @param listener The function to subscribe to events of this type
19
+ */
20
+ addEventListener(type: string, listener: Listener): void;
21
+ /**
22
+ * Unsubscribes from an event type.
23
+ *
24
+ * @param type The event type
25
+ * @param listener The function to unsubscribe from events of this type
26
+ */
27
+ removeEventListener(type: string, listener: Listener): void;
28
+ /**
29
+ * Unsubscribes all listener functions to a single event type or all event types.
30
+ *
31
+ * @param type The event type, or all event types if not specified
32
+ */
33
+ clearEventListeners(type?: string): void;
34
+ /**
35
+ * Publishes an event.
36
+ *
37
+ * @param event The event object to publish
38
+ */
39
+ dispatchEvent<T extends FREvent>(event: T): void;
40
+ }
41
+
1
42
  declare enum ActionTypes {
2
43
  Authenticate = "AUTHENTICATE",
3
44
  Authorize = "AUTHORIZE",
@@ -51,7 +92,7 @@ declare enum CallbackType {
51
92
  /**
52
93
  * Represents the authentication tree API payload schema.
53
94
  */
54
- interface Step {
95
+ interface Step$1 {
55
96
  authId?: string;
56
97
  callbacks?: Callback[];
57
98
  code?: number;
@@ -79,7 +120,7 @@ interface StepDetail {
79
120
  * Represents configuration overrides used when requesting the next
80
121
  * step in an authentication tree.
81
122
  */
82
- interface StepOptions extends ConfigOptions {
123
+ interface StepOptions extends ConfigOptions$1 {
83
124
  query?: StringDict<string>;
84
125
  }
85
126
  /**
@@ -176,7 +217,7 @@ interface Action {
176
217
  /**
177
218
  * Configuration options.
178
219
  */
179
- interface ConfigOptions {
220
+ interface ConfigOptions$1 {
180
221
  callbackFactory?: FRCallbackFactory;
181
222
  clientId?: string;
182
223
  middleware?: RequestMiddleware[];
@@ -224,47 +265,6 @@ interface TokenStoreObject {
224
265
  remove: (clientId: string) => Promise<void>;
225
266
  }
226
267
 
227
- /**
228
- * An event-handling function.
229
- */
230
- declare type Listener = (e: FREvent) => void;
231
- interface FREvent {
232
- type: string;
233
- }
234
-
235
- /**
236
- * Event dispatcher for subscribing and publishing categorized events.
237
- */
238
- declare class Dispatcher {
239
- private callbacks;
240
- /**
241
- * Subscribes to an event type.
242
- *
243
- * @param type The event type
244
- * @param listener The function to subscribe to events of this type
245
- */
246
- addEventListener(type: string, listener: Listener): void;
247
- /**
248
- * Unsubscribes from an event type.
249
- *
250
- * @param type The event type
251
- * @param listener The function to unsubscribe from events of this type
252
- */
253
- removeEventListener(type: string, listener: Listener): void;
254
- /**
255
- * Unsubscribes all listener functions to a single event type or all event types.
256
- *
257
- * @param type The event type, or all event types if not specified
258
- */
259
- clearEventListeners(type?: string): void;
260
- /**
261
- * Publishes an event.
262
- *
263
- * @param event The event object to publish
264
- */
265
- dispatchEvent<T extends FREvent>(event: T): void;
266
- }
267
-
268
268
  /**
269
269
  * Types of steps returned by the authentication tree.
270
270
  */
@@ -291,7 +291,7 @@ interface FailureDetail {
291
291
  * Represents a single step of an authentication tree.
292
292
  */
293
293
  declare class FRStep implements AuthResponse {
294
- payload: Step;
294
+ payload: Step$1;
295
295
  /**
296
296
  * The type of step.
297
297
  */
@@ -304,7 +304,7 @@ declare class FRStep implements AuthResponse {
304
304
  * @param payload The raw payload returned by OpenAM
305
305
  * @param callbackFactory A function that returns am implementation of FRCallback
306
306
  */
307
- constructor(payload: Step, callbackFactory?: FRCallbackFactory);
307
+ constructor(payload: Step$1, callbackFactory?: FRCallbackFactory);
308
308
  /**
309
309
  * Gets the first callback of the specified type in this step.
310
310
  *
@@ -346,7 +346,7 @@ declare type HandleStep = (step: FRStep) => Promise<FRStep>;
346
346
  interface HttpClientRequestOptions {
347
347
  bypassAuthentication?: boolean;
348
348
  authorization?: {
349
- config?: ConfigOptions;
349
+ config?: ConfigOptions$1;
350
350
  handleStep: HandleStep;
351
351
  idToken?: string;
352
352
  txnID?: string;
@@ -490,67 +490,6 @@ declare class SvelteComponentDev$1 extends SvelteComponent {
490
490
  $capture_state(): void;
491
491
  $inject_state(): void;
492
492
  }
493
- interface SvelteComponentTyped<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any> {
494
- $set(props?: Partial<Props>): void;
495
- $on<K extends Extract<keyof Events, string>>(type: K, callback: ((e: Events[K]) => void) | null | undefined): () => void;
496
- $destroy(): void;
497
- [accessor: string]: any;
498
- }
499
- /**
500
- * Base class to create strongly typed Svelte components.
501
- * This only exists for typing purposes and should be used in `.d.ts` files.
502
- *
503
- * ### Example:
504
- *
505
- * You have component library on npm called `component-library`, from which
506
- * you export a component called `MyComponent`. For Svelte+TypeScript users,
507
- * you want to provide typings. Therefore you create a `index.d.ts`:
508
- * ```ts
509
- * import { SvelteComponentTyped } from "svelte";
510
- * export class MyComponent extends SvelteComponentTyped<{foo: string}> {}
511
- * ```
512
- * Typing this makes it possible for IDEs like VS Code with the Svelte extension
513
- * to provide intellisense and to use the component like this in a Svelte file
514
- * with TypeScript:
515
- * ```svelte
516
- * <script lang="ts">
517
- * import { MyComponent } from "component-library";
518
- * </script>
519
- * <MyComponent foo={'bar'} />
520
- * ```
521
- *
522
- * #### Why not make this part of `SvelteComponent(Dev)`?
523
- * Because
524
- * ```ts
525
- * class ASubclassOfSvelteComponent extends SvelteComponent<{foo: string}> {}
526
- * const component: typeof SvelteComponent = ASubclassOfSvelteComponent;
527
- * ```
528
- * will throw a type error, so we need to separate the more strictly typed class.
529
- */
530
- declare class SvelteComponentTyped<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any> extends SvelteComponentDev$1 {
531
- /**
532
- * @private
533
- * For type checking capabilities only.
534
- * Does not exist at runtime.
535
- * ### DO NOT USE!
536
- */
537
- $$prop_def: Props;
538
- /**
539
- * @private
540
- * For type checking capabilities only.
541
- * Does not exist at runtime.
542
- * ### DO NOT USE!
543
- */
544
- $$events_def: Events;
545
- /**
546
- * @private
547
- * For type checking capabilities only.
548
- * Does not exist at runtime.
549
- * ### DO NOT USE!
550
- */
551
- $$slot_def: Slots;
552
- constructor(options: ComponentConstructorOptions<Props>);
553
- }
554
493
 
555
494
  /** Callback to inform of a value updates. */
556
495
  declare type Subscriber<T> = (value: T) => void;
@@ -594,7 +533,7 @@ interface ProcessedPropertyError {
594
533
  }
595
534
 
596
535
  declare class FRLoginFailure implements AuthResponse {
597
- payload: Step;
536
+ payload: Step$1;
598
537
  /**
599
538
  * The type of step.
600
539
  */
@@ -602,7 +541,7 @@ declare class FRLoginFailure implements AuthResponse {
602
541
  /**
603
542
  * @param payload The raw payload returned by OpenAM
604
543
  */
605
- constructor(payload: Step);
544
+ constructor(payload: Step$1);
606
545
  /**
607
546
  * Gets the error code.
608
547
  */
@@ -626,7 +565,7 @@ declare class FRLoginFailure implements AuthResponse {
626
565
  }
627
566
 
628
567
  declare class FRLoginSuccess implements AuthResponse {
629
- payload: Step;
568
+ payload: Step$1;
630
569
  /**
631
570
  * The type of step.
632
571
  */
@@ -634,7 +573,7 @@ declare class FRLoginSuccess implements AuthResponse {
634
573
  /**
635
574
  * @param payload The raw payload returned by OpenAM
636
575
  */
637
- constructor(payload: Step);
576
+ constructor(payload: Step$1);
638
577
  /**
639
578
  * Gets the step's realm.
640
579
  */
@@ -652,14 +591,14 @@ declare class FRLoginSuccess implements AuthResponse {
652
591
  /**
653
592
  * Tokens returned after successful authentication.
654
593
  */
655
- interface OAuth2Tokens {
594
+ interface OAuth2Tokens$1 {
656
595
  accessToken: string;
657
596
  idToken?: string;
658
597
  refreshToken?: string;
659
598
  tokenExpiry?: number;
660
599
  }
661
600
 
662
- interface GetTokensOptions extends ConfigOptions {
601
+ interface GetTokensOptions extends ConfigOptions$1 {
663
602
  forceRenew?: boolean;
664
603
  login?: 'embedded' | 'redirect' | undefined;
665
604
  query?: StringDict<string>;
@@ -667,11 +606,11 @@ interface GetTokensOptions extends ConfigOptions {
667
606
 
668
607
  type Maybe<T> = T | null | undefined;
669
608
 
670
- interface UserStore extends Pick<Writable<UserStoreValue>, 'subscribe'> {
671
- get: (getOptions?: ConfigOptions) => void;
609
+ interface UserStore extends Pick<Writable<UserStoreValue$1>, 'subscribe'> {
610
+ get: (getOptions?: ConfigOptions$1) => void;
672
611
  reset: () => void;
673
612
  }
674
- interface UserStoreValue {
613
+ interface UserStoreValue$1 {
675
614
  completed: boolean;
676
615
  error: Maybe<{
677
616
  code?: Maybe<number>;
@@ -683,11 +622,11 @@ interface UserStoreValue {
683
622
  response: unknown;
684
623
  }
685
624
 
686
- interface OAuthStore extends Pick<Writable<OAuthTokenStoreValue>, 'subscribe'> {
625
+ interface OAuthStore extends Pick<Writable<OAuthTokenStoreValue$1>, 'subscribe'> {
687
626
  get: (getOptions?: GetTokensOptions) => void;
688
627
  reset: () => void;
689
628
  }
690
- interface OAuthTokenStoreValue {
629
+ interface OAuthTokenStoreValue$1 {
691
630
  completed: boolean;
692
631
  error: Maybe<{
693
632
  code?: Maybe<number>;
@@ -696,7 +635,7 @@ interface OAuthTokenStoreValue {
696
635
  }>;
697
636
  loading: boolean;
698
637
  successful: boolean;
699
- response: Maybe<OAuth2Tokens> | void;
638
+ response: Maybe<OAuth2Tokens$1> | void;
700
639
  }
701
640
 
702
641
  interface CallbackMetadata {
@@ -710,7 +649,7 @@ interface CallbackMetadata {
710
649
  idx: number;
711
650
  platform?: Record<string, unknown>;
712
651
  }
713
- interface JourneyStore extends Pick<Writable<JourneyStoreValue>, 'subscribe'> {
652
+ interface JourneyStore extends Pick<Writable<JourneyStoreValue$1>, 'subscribe'> {
714
653
  next: (prevStep?: StepTypes, nextOptions?: StepOptions) => void;
715
654
  pop: () => void;
716
655
  push: (changeOptions: StepOptions) => void;
@@ -718,12 +657,12 @@ interface JourneyStore extends Pick<Writable<JourneyStoreValue>, 'subscribe'> {
718
657
  resume: (url: string, resumeOptions?: StepOptions) => void;
719
658
  start: (startOptions?: StepOptions) => void;
720
659
  }
721
- interface JourneyStoreValue {
660
+ interface JourneyStoreValue$1 {
722
661
  completed: boolean;
723
662
  error: Maybe<{
724
663
  code: Maybe<number>;
725
664
  message: Maybe<string>;
726
- step: Maybe<Step>;
665
+ stage: Maybe<string>;
727
666
  troubleshoot: Maybe<string>;
728
667
  }>;
729
668
  loading: boolean;
@@ -733,7 +672,7 @@ interface JourneyStoreValue {
733
672
  } | null;
734
673
  step: StepTypes;
735
674
  successful: boolean;
736
- response: Maybe<Step>;
675
+ response: Maybe<Step$1>;
737
676
  }
738
677
  interface StepMetadata {
739
678
  derived: {
@@ -747,6 +686,23 @@ interface StepMetadata {
747
686
  }
748
687
  type StepTypes = FRStep | FRLoginSuccess | FRLoginFailure | null;
749
688
 
689
+
690
+ interface ComponentStoreValue {
691
+ lastAction: 'close' | 'open' | 'mount' | null;
692
+ error: {
693
+ code: string;
694
+ message: string;
695
+ } | null;
696
+ modal: {
697
+ component: SvelteComponentDev$1;
698
+ element: HTMLDialogElement;
699
+ } | null;
700
+ mounted: boolean;
701
+ open: boolean | null;
702
+ reason: 'auto' | 'external' | 'user' | null;
703
+ type: 'inline' | 'modal' | null;
704
+ }
705
+
750
706
  declare type Primitive = string | number | symbol | bigint | boolean | null | undefined;
751
707
 
752
708
  declare namespace util {
@@ -2050,6 +2006,8 @@ declare const partialStringsSchema: ZodObject<{
2050
2006
  backToLogin: ZodOptional<ZodString>;
2051
2007
  dontHaveAnAccount: ZodOptional<ZodString>;
2052
2008
  closeModal: ZodOptional<ZodString>;
2009
+ charactersCannotRepeatMoreThan: ZodOptional<ZodString>;
2010
+ charactersCannotRepeatMoreThanCaseInsensitive: ZodOptional<ZodString>;
2053
2011
  chooseDifferentUsername: ZodOptional<ZodString>;
2054
2012
  confirmPassword: ZodOptional<ZodString>;
2055
2013
  constraintViolationForPassword: ZodOptional<ZodString>;
@@ -2082,6 +2040,9 @@ declare const partialStringsSchema: ZodObject<{
2082
2040
  notToExceedMaximumCharacterLength: ZodOptional<ZodString>;
2083
2041
  noLessThanMinimumCharacterLength: ZodOptional<ZodString>;
2084
2042
  passwordCallback: ZodOptional<ZodString>;
2043
+ passwordCannotContainCommonPasswords: ZodOptional<ZodString>;
2044
+ passwordCannotContainCommonPasswordsOrBeReversible: ZodOptional<ZodString>;
2045
+ passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan: ZodOptional<ZodString>;
2085
2046
  passwordRequirements: ZodOptional<ZodString>;
2086
2047
  pleaseCheckValue: ZodOptional<ZodString>;
2087
2048
  pleaseConfirm: ZodOptional<ZodString>;
@@ -2096,6 +2057,10 @@ declare const partialStringsSchema: ZodObject<{
2096
2057
  securityAnswer: ZodOptional<ZodString>;
2097
2058
  securityQuestions: ZodOptional<ZodString>;
2098
2059
  securityQuestionsPrompt: ZodOptional<ZodString>;
2060
+ shouldContainANumber: ZodOptional<ZodString>;
2061
+ shouldContainAnUppercase: ZodOptional<ZodString>;
2062
+ shouldContainALowercase: ZodOptional<ZodString>;
2063
+ shouldContainASymbol: ZodOptional<ZodString>;
2099
2064
  showPassword: ZodOptional<ZodString>;
2100
2065
  sn: ZodOptional<ZodString>;
2101
2066
  submitButton: ZodOptional<ZodString>;
@@ -2106,6 +2071,7 @@ declare const partialStringsSchema: ZodObject<{
2106
2071
  twoFactorAuthentication: ZodOptional<ZodString>;
2107
2072
  useValidEmail: ZodOptional<ZodString>;
2108
2073
  unrecoverableError: ZodOptional<ZodString>;
2074
+ unknownLoginError: ZodOptional<ZodString>;
2109
2075
  unknownNetworkError: ZodOptional<ZodString>;
2110
2076
  userName: ZodOptional<ZodString>;
2111
2077
  usernameRequirements: ZodOptional<ZodString>;
@@ -2119,6 +2085,8 @@ declare const partialStringsSchema: ZodObject<{
2119
2085
  backToLogin?: string | undefined;
2120
2086
  dontHaveAnAccount?: string | undefined;
2121
2087
  closeModal?: string | undefined;
2088
+ charactersCannotRepeatMoreThan?: string | undefined;
2089
+ charactersCannotRepeatMoreThanCaseInsensitive?: string | undefined;
2122
2090
  chooseDifferentUsername?: string | undefined;
2123
2091
  confirmPassword?: string | undefined;
2124
2092
  constraintViolationForPassword?: string | undefined;
@@ -2151,6 +2119,9 @@ declare const partialStringsSchema: ZodObject<{
2151
2119
  notToExceedMaximumCharacterLength?: string | undefined;
2152
2120
  noLessThanMinimumCharacterLength?: string | undefined;
2153
2121
  passwordCallback?: string | undefined;
2122
+ passwordCannotContainCommonPasswords?: string | undefined;
2123
+ passwordCannotContainCommonPasswordsOrBeReversible?: string | undefined;
2124
+ passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan?: string | undefined;
2154
2125
  passwordRequirements?: string | undefined;
2155
2126
  pleaseCheckValue?: string | undefined;
2156
2127
  pleaseConfirm?: string | undefined;
@@ -2165,6 +2136,10 @@ declare const partialStringsSchema: ZodObject<{
2165
2136
  securityAnswer?: string | undefined;
2166
2137
  securityQuestions?: string | undefined;
2167
2138
  securityQuestionsPrompt?: string | undefined;
2139
+ shouldContainANumber?: string | undefined;
2140
+ shouldContainAnUppercase?: string | undefined;
2141
+ shouldContainALowercase?: string | undefined;
2142
+ shouldContainASymbol?: string | undefined;
2168
2143
  showPassword?: string | undefined;
2169
2144
  sn?: string | undefined;
2170
2145
  submitButton?: string | undefined;
@@ -2175,6 +2150,7 @@ declare const partialStringsSchema: ZodObject<{
2175
2150
  twoFactorAuthentication?: string | undefined;
2176
2151
  useValidEmail?: string | undefined;
2177
2152
  unrecoverableError?: string | undefined;
2153
+ unknownLoginError?: string | undefined;
2178
2154
  unknownNetworkError?: string | undefined;
2179
2155
  userName?: string | undefined;
2180
2156
  usernameRequirements?: string | undefined;
@@ -2188,6 +2164,8 @@ declare const partialStringsSchema: ZodObject<{
2188
2164
  backToLogin?: string | undefined;
2189
2165
  dontHaveAnAccount?: string | undefined;
2190
2166
  closeModal?: string | undefined;
2167
+ charactersCannotRepeatMoreThan?: string | undefined;
2168
+ charactersCannotRepeatMoreThanCaseInsensitive?: string | undefined;
2191
2169
  chooseDifferentUsername?: string | undefined;
2192
2170
  confirmPassword?: string | undefined;
2193
2171
  constraintViolationForPassword?: string | undefined;
@@ -2220,6 +2198,9 @@ declare const partialStringsSchema: ZodObject<{
2220
2198
  notToExceedMaximumCharacterLength?: string | undefined;
2221
2199
  noLessThanMinimumCharacterLength?: string | undefined;
2222
2200
  passwordCallback?: string | undefined;
2201
+ passwordCannotContainCommonPasswords?: string | undefined;
2202
+ passwordCannotContainCommonPasswordsOrBeReversible?: string | undefined;
2203
+ passwordCannotContainCommonPasswordsOrBeReversibleStringsLessThan?: string | undefined;
2223
2204
  passwordRequirements?: string | undefined;
2224
2205
  pleaseCheckValue?: string | undefined;
2225
2206
  pleaseConfirm?: string | undefined;
@@ -2234,6 +2215,10 @@ declare const partialStringsSchema: ZodObject<{
2234
2215
  securityAnswer?: string | undefined;
2235
2216
  securityQuestions?: string | undefined;
2236
2217
  securityQuestionsPrompt?: string | undefined;
2218
+ shouldContainANumber?: string | undefined;
2219
+ shouldContainAnUppercase?: string | undefined;
2220
+ shouldContainALowercase?: string | undefined;
2221
+ shouldContainASymbol?: string | undefined;
2237
2222
  showPassword?: string | undefined;
2238
2223
  sn?: string | undefined;
2239
2224
  submitButton?: string | undefined;
@@ -2244,6 +2229,7 @@ declare const partialStringsSchema: ZodObject<{
2244
2229
  twoFactorAuthentication?: string | undefined;
2245
2230
  useValidEmail?: string | undefined;
2246
2231
  unrecoverableError?: string | undefined;
2232
+ unknownLoginError?: string | undefined;
2247
2233
  unknownNetworkError?: string | undefined;
2248
2234
  userName?: string | undefined;
2249
2235
  usernameRequirements?: string | undefined;
@@ -2318,20 +2304,20 @@ declare const partialStyleSchema: ZodObject<{
2318
2304
  } | undefined;
2319
2305
  }>;
2320
2306
 
2321
- interface JourneyOptions {
2307
+ interface JourneyOptions$1 {
2322
2308
  oauth?: boolean;
2323
2309
  user?: boolean;
2324
2310
  }
2325
- interface JourneyOptionsChange {
2311
+ interface JourneyOptionsChange$1 {
2326
2312
  forgerock?: StepOptions;
2327
2313
  journey: string;
2328
2314
  }
2329
- interface JourneyOptionsStart {
2315
+ interface JourneyOptionsStart$1 {
2330
2316
  forgerock?: StepOptions;
2331
2317
  journey?: string;
2332
2318
  resumeUrl?: string;
2333
2319
  }
2334
- interface WidgetConfigOptions {
2320
+ interface WidgetConfigOptions$1 {
2335
2321
  forgerock?: TypeOf<typeof partialConfigSchema>;
2336
2322
  content?: TypeOf<typeof partialStringsSchema>;
2337
2323
  journeys?: TypeOf<typeof journeyConfigSchema>;
@@ -2339,23 +2325,6 @@ interface WidgetConfigOptions {
2339
2325
  style?: TypeOf<typeof partialStyleSchema>;
2340
2326
  }
2341
2327
 
2342
-
2343
- interface ComponentStoreValue {
2344
- lastAction: 'close' | 'open' | 'mount' | null;
2345
- error: {
2346
- code: string;
2347
- message: string;
2348
- } | null;
2349
- modal: {
2350
- component: SvelteComponentDev$1;
2351
- element: HTMLDialogElement;
2352
- } | null;
2353
- mounted: boolean;
2354
- open: boolean | null;
2355
- reason: 'auto' | 'external' | 'user' | null;
2356
- type: 'inline' | 'modal' | null;
2357
- }
2358
-
2359
2328
  declare const api: {
2360
2329
  component: {
2361
2330
  close: (args?: {
@@ -2364,92 +2333,53 @@ declare const api: {
2364
2333
  open: () => void;
2365
2334
  subscribe: (this: void, run: Subscriber<Pick<ComponentStoreValue, "reason" | "error" | "open" | "lastAction" | "mounted">>, invalidate?: ((value?: Pick<ComponentStoreValue, "reason" | "error" | "open" | "lastAction" | "mounted"> | undefined) => void) | undefined) => Unsubscriber;
2366
2335
  };
2367
- configuration: (options?: WidgetConfigOptions | undefined) => {
2368
- set(setOptions?: WidgetConfigOptions | undefined): void;
2336
+ configuration: (options?: WidgetConfigOptions$1 | undefined) => {
2337
+ set(setOptions?: WidgetConfigOptions$1 | undefined): void;
2369
2338
  };
2370
2339
  getStores: () => {
2371
2340
  journeyStore: JourneyStore;
2372
2341
  oauthStore: OAuthStore;
2373
2342
  userStore: UserStore;
2374
2343
  };
2375
- journey: (options?: JourneyOptions | undefined) => {
2376
- change: (changeOptions: JourneyOptionsChange) => Promise<unknown>;
2377
- start: (startOptions?: JourneyOptionsStart | undefined) => Promise<unknown>;
2344
+ journey: (options?: JourneyOptions$1 | undefined) => {
2345
+ change: (changeOptions: JourneyOptionsChange$1) => Promise<unknown>;
2346
+ start: (startOptions?: JourneyOptionsStart$1 | undefined) => Promise<unknown>;
2378
2347
  subscribe: (this: void, run: Subscriber<{
2379
- journey: JourneyStoreValue;
2380
- oauth: OAuthTokenStoreValue;
2381
- user: UserStoreValue;
2348
+ journey: JourneyStoreValue$1;
2349
+ oauth: OAuthTokenStoreValue$1;
2350
+ user: UserStoreValue$1;
2382
2351
  }>, invalidate?: ((value?: {
2383
- journey: JourneyStoreValue;
2384
- oauth: OAuthTokenStoreValue;
2385
- user: UserStoreValue;
2352
+ journey: JourneyStoreValue$1;
2353
+ oauth: OAuthTokenStoreValue$1;
2354
+ user: UserStoreValue$1;
2386
2355
  } | undefined) => void) | undefined) => Unsubscriber;
2387
2356
  };
2388
2357
  request: typeof HttpClient.request;
2389
2358
  user: {
2390
2359
  info(): {
2391
- get: (options?: ConfigOptions | undefined) => Promise<unknown>;
2392
- subscribe: (this: void, run: Subscriber<UserStoreValue>, invalidate?: ((value?: UserStoreValue | undefined) => void) | undefined) => Unsubscriber;
2360
+ get: (options?: ConfigOptions$1 | undefined) => Promise<unknown>;
2361
+ subscribe: (this: void, run: Subscriber<UserStoreValue$1>, invalidate?: ((value?: UserStoreValue$1 | undefined) => void) | undefined) => Unsubscriber;
2393
2362
  };
2394
2363
  logout(): Promise<void>;
2395
2364
  tokens(): {
2396
- get: (options?: ConfigOptions | undefined) => Promise<unknown>;
2397
- subscribe: (this: void, run: Subscriber<OAuthTokenStoreValue>, invalidate?: ((value?: OAuthTokenStoreValue | undefined) => void) | undefined) => Unsubscriber;
2365
+ get: (options?: ConfigOptions$1 | undefined) => Promise<unknown>;
2366
+ subscribe: (this: void, run: Subscriber<OAuthTokenStoreValue$1>, invalidate?: ((value?: OAuthTokenStoreValue$1 | undefined) => void) | undefined) => Unsubscriber;
2398
2367
  };
2399
2368
  };
2400
2369
  };
2401
- declare const configuration: (options?: WidgetConfigOptions | undefined) => {
2402
- set(setOptions?: WidgetConfigOptions | undefined): void;
2403
- };
2404
- declare const journey: (options?: JourneyOptions | undefined) => {
2405
- change: (changeOptions: JourneyOptionsChange) => Promise<unknown>;
2406
- start: (startOptions?: JourneyOptionsStart | undefined) => Promise<unknown>;
2407
- subscribe: (this: void, run: Subscriber<{
2408
- journey: JourneyStoreValue;
2409
- oauth: OAuthTokenStoreValue;
2410
- user: UserStoreValue;
2411
- }>, invalidate?: ((value?: {
2412
- journey: JourneyStoreValue;
2413
- oauth: OAuthTokenStoreValue;
2414
- user: UserStoreValue;
2415
- } | undefined) => void) | undefined) => Unsubscriber;
2416
- };
2417
- declare const component: () => {
2418
- close: (args?: {
2419
- reason: "auto" | "external" | "user";
2420
- } | undefined) => void;
2421
- open: () => void;
2422
- subscribe: (this: void, run: Subscriber<Pick<ComponentStoreValue, "reason" | "error" | "open" | "lastAction" | "mounted">>, invalidate?: ((value?: Pick<ComponentStoreValue, "reason" | "error" | "open" | "lastAction" | "mounted"> | undefined) => void) | undefined) => Unsubscriber;
2423
- };
2424
- declare const request: typeof HttpClient.request;
2425
- declare const user: {
2426
- info(): {
2427
- get: (options?: ConfigOptions | undefined) => Promise<unknown>;
2428
- subscribe: (this: void, run: Subscriber<UserStoreValue>, invalidate?: ((value?: UserStoreValue | undefined) => void) | undefined) => Unsubscriber;
2429
- };
2430
- logout(): Promise<void>;
2431
- tokens(): {
2432
- get: (options?: ConfigOptions | undefined) => Promise<unknown>;
2433
- subscribe: (this: void, run: Subscriber<OAuthTokenStoreValue>, invalidate?: ((value?: OAuthTokenStoreValue | undefined) => void) | undefined) => Unsubscriber;
2434
- };
2435
- };
2436
2370
  type ConfigurationApi = ReturnType<typeof api.configuration>;
2437
2371
  type JourneyApi = ReturnType<typeof api.journey>;
2438
2372
  type UserInfoApi = ReturnType<typeof api.user.info>;
2439
2373
  type UserTokensApi = ReturnType<typeof api.user.tokens>;
2440
- declare const __propDef: {
2441
- props: {
2442
- type?: "inline" | "modal" | undefined;
2443
- };
2444
- events: {
2445
- [evt: string]: CustomEvent<any>;
2446
- };
2447
- slots: {};
2448
- };
2449
- type IndexProps = typeof __propDef.props;
2450
- type IndexEvents = typeof __propDef.events;
2451
- type IndexSlots = typeof __propDef.slots;
2452
- declare class Index extends SvelteComponentTyped<IndexProps, IndexEvents, IndexSlots> {
2453
- }
2374
+ type JourneyOptions = JourneyOptions$1;
2375
+ type JourneyOptionsChange = JourneyOptionsChange$1;
2376
+ type JourneyOptionsStart = JourneyOptionsStart$1;
2377
+ type WidgetConfigOptions = WidgetConfigOptions$1;
2378
+ type JourneyStoreValue = JourneyStoreValue$1;
2379
+ type OAuthTokenStoreValue = OAuthTokenStoreValue$1;
2380
+ type UserStoreValue = UserStoreValue$1;
2381
+ type ConfigOptions = ConfigOptions$1;
2382
+ type OAuth2Tokens = OAuth2Tokens$1;
2383
+ type Step = Step$1;
2454
2384
 
2455
- export { ConfigurationApi, IndexEvents, IndexProps, IndexSlots, JourneyApi, UserInfoApi, UserTokensApi, component, configuration, Index as default, journey, request, user };
2385
+ export { ConfigOptions, ConfigurationApi, JourneyApi, JourneyOptions, JourneyOptionsChange, JourneyOptionsStart, JourneyStoreValue, OAuth2Tokens, OAuthTokenStoreValue, Step, UserInfoApi, UserStoreValue, UserTokensApi, WidgetConfigOptions };