@incodetech/welcome 1.85.0-20251219175515.0 → 1.85.0-20251219204942.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.
@@ -1,8 +1,10 @@
1
- import { FC, ReactNode } from 'react';
1
+ import { ThemeProvider as DesignSystemThemeProvider } from '../../../incode-design-system/src';
2
+ import { ComponentProps, FC, ReactNode } from 'react';
2
3
  import { UiConfig } from '../ui/types';
3
4
  type IncodeProviderProps = {
4
5
  token: string;
5
6
  uiConfig?: UiConfig;
7
+ closeButton?: ComponentProps<typeof DesignSystemThemeProvider>['closeButton'];
6
8
  children: ReactNode;
7
9
  };
8
10
  declare const IncodeProvider: FC<IncodeProviderProps>;
@@ -0,0 +1,9 @@
1
+ import { UiConfig } from '../ui/types';
2
+ export type UseDashboardThemeResult = {
3
+ uiConfig?: UiConfig;
4
+ isLoading: boolean;
5
+ };
6
+ export declare const useDashboardTheme: ({ token, uiConfig, }: {
7
+ token: string;
8
+ uiConfig?: UiConfig;
9
+ }) => UseDashboardThemeResult;
@@ -1,12 +1,12 @@
1
- import { default as React, FC } from 'react';
2
- interface ErrorModalContentProps {
1
+ import { FC, ReactNode } from 'react';
2
+ type ErrorModalContentProps = {
3
3
  title: string;
4
4
  description: string;
5
5
  attemptsText: string;
6
6
  buttonText: string;
7
- icon: React.ReactNode;
7
+ icon: ReactNode;
8
8
  onButtonClick: () => void;
9
9
  onCloseCancel: () => void;
10
- }
10
+ };
11
11
  declare const ErrorModalContent: FC<ErrorModalContentProps>;
12
12
  export default ErrorModalContent;
@@ -7,7 +7,7 @@ export declare const useFaceFlowState: () => {
7
7
  deepsightVideoRecorder: import('../../mediaRecorder/DeepsightVideoRecorder').DeepsightVideoRecorder;
8
8
  mediaRecorder: import('../../mediaRecorder/MediaRecorder').MediaRecorder;
9
9
  captureConfiguration: import('./FaceFlowManager.types').FaceCaptureConfiguration;
10
- uiConfig: import('../../ui/types').UiConfig;
10
+ uiConfig: import('../..').UiConfig;
11
11
  shouldShowTutorialInCapture: boolean;
12
12
  captureOnly: boolean;
13
13
  onCapture: (response: import('../FaceCapture').FaceCaptureOnlyResponse) => void;
@@ -70,7 +70,7 @@ export declare const useCaptureIdState: () => {
70
70
  showCaptureButtonInAuto: boolean;
71
71
  };
72
72
  attemptsLeft: number;
73
- uiConfig: import('../../../ui/types').UiConfig;
73
+ uiConfig: import('../../..').UiConfig;
74
74
  captureOnly: boolean;
75
75
  onCapture: (response: import('../../CaptureId').CaptureOnlyResponse) => void;
76
76
  storeCapturedImage: (type: 'front' | 'back', imageData: {
@@ -19,7 +19,7 @@ export declare const steps: {
19
19
  readonly component: FC<{
20
20
  onContinue: () => void;
21
21
  emitError: (error: "PERMISSION_REFRESH" | "PERMISSION_DENIED") => void;
22
- uiConfig: import('../../ui/types').UiConfig;
22
+ uiConfig: import('../..').UiConfig;
23
23
  onClose: () => void;
24
24
  isDeepsightEnabled: boolean;
25
25
  }>;
@@ -557,7 +557,7 @@ tokboxApiKey, darkMode, hostingApp, unsafeMode, customHeaders, fingerprintApiKey
557
557
  onError: (err: import('.').FlowRendererError) => void;
558
558
  onEvent?: (event: import('./flow/types').FlowEvent) => void;
559
559
  flow?: import('.').Flow;
560
- uiConfig?: import('./ui/types').UiConfig;
560
+ uiConfig?: import('.').UiConfig;
561
561
  config?: import('./flow/Flow').FlowConfig;
562
562
  authHint?: string;
563
563
  }) => Promise<void>;
@@ -50,6 +50,8 @@ export { default as sendEkyb } from './sendEkyb';
50
50
  export { default as sendEmail } from './sendEmail';
51
51
  export { default as setup } from './setup';
52
52
  export { default as theme } from './theme';
53
+ export type { UiConfig } from './ui/types';
54
+ export { themeToUiConfig } from './ui/utils/themeToUiConfig';
53
55
  export { default as TutorialSelfie } from './tutorials/TutorialSelfie';
54
56
  export { default as update } from './update';
55
57
  export { default as verifyInformation } from './verifyInformation';
@@ -1,9 +1,9 @@
1
- import { CustomPrimitives } from '../../../incode-design-system/src';
1
+ import { CustomPrimitives, SpacingValue } from '../../../incode-design-system/src';
2
2
  export type UiConfig = {
3
3
  branding?: {
4
4
  logo?: {
5
5
  src?: string;
6
- height?: string;
6
+ height?: SpacingValue | string;
7
7
  };
8
8
  hideFooterBranding?: boolean;
9
9
  hideHeaderBranding?: boolean;
@@ -11,7 +11,7 @@ export type UiConfig = {
11
11
  closeButton?: {
12
12
  show?: boolean;
13
13
  position?: 'left' | 'right';
14
- offset?: number | string;
14
+ offset?: SpacingValue | string;
15
15
  };
16
16
  theming?: {
17
17
  designTokens?: Partial<CustomPrimitives>;
@@ -0,0 +1,3 @@
1
+ type PlainObject = Record<string, unknown>;
2
+ export declare const deepMerge: <TLeft extends PlainObject, TRight extends PlainObject>(left: TLeft, right: TRight) => TLeft & TRight;
3
+ export {};
@@ -0,0 +1,3 @@
1
+ import { CustomTheme } from '../../../../types/src';
2
+ import { UiConfig } from '../types';
3
+ export declare const themeToUiConfig: (theme: CustomTheme) => Partial<UiConfig>;