@descope/flow-components 3.1.0 → 3.1.2

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.
Files changed (58) hide show
  1. package/dist/fm/119.js +1 -1
  2. package/dist/fm/119.js.map +1 -1
  3. package/dist/fm/222.js +1 -1
  4. package/dist/fm/222.js.map +1 -1
  5. package/dist/fm/467.js +1 -1
  6. package/dist/fm/467.js.map +1 -1
  7. package/dist/fm/985.js +1 -1
  8. package/dist/fm/985.js.map +1 -1
  9. package/dist/fm/@mf-types/compiled-types/Avatar/Avatar.d.ts +1 -1
  10. package/dist/fm/@mf-types/compiled-types/Badge/Badge.d.ts +1 -1
  11. package/dist/fm/@mf-types/compiled-types/CodeSnippet/CodeSnippet.d.ts +1 -1
  12. package/dist/fm/@mf-types/compiled-types/CollapsibleContainer/CollapsibleContainer.d.ts +33 -1
  13. package/dist/fm/@mf-types/compiled-types/Container/Container.d.ts +27 -1
  14. package/dist/fm/@mf-types/compiled-types/Divider/Divider.d.ts +1 -1
  15. package/dist/fm/@mf-types/compiled-types/Grid/Columns/gridJsxTypes.d.ts +11 -0
  16. package/dist/fm/@mf-types/compiled-types/Hcaptcha/Hcaptcha.d.ts +1 -1
  17. package/dist/fm/@mf-types/compiled-types/HybridField/HybridField.d.ts +18 -1
  18. package/dist/fm/@mf-types/compiled-types/Image/Image.d.ts +7 -1
  19. package/dist/fm/@mf-types/compiled-types/Recaptcha/Recaptcha.d.ts +1 -1
  20. package/dist/fm/@mf-types/compiled-types/Tooltip/Tooltip.d.ts +2 -2
  21. package/dist/fm/@mf-types/compiled-types/Turnstile/Turnstile.d.ts +12 -1
  22. package/dist/fm/@mf-types/compiled-types/UploadFile/UploadFile.d.ts +1 -1
  23. package/dist/fm/@mf-types/compiled-types/UserAttribute/UserAttribute.d.ts +1 -1
  24. package/dist/fm/@mf-types/compiled-types/UserAuthMethod/UserAuthMethod.d.ts +12 -1
  25. package/dist/fm/@mf-types/componentClasses.d.ts +2 -0
  26. package/dist/fm/@mf-types/components.d.ts +2 -0
  27. package/dist/fm/@mf-types/theme.d.ts +2 -0
  28. package/dist/fm/@mf-types.d.ts +3 -0
  29. package/dist/fm/@mf-types.zip +0 -0
  30. package/dist/fm/__federation_expose_componentClasses.js +1 -1
  31. package/dist/fm/__federation_expose_componentClasses.js.map +1 -1
  32. package/dist/fm/__federation_expose_components.js +1 -1
  33. package/dist/fm/__federation_expose_theme.js +1 -1
  34. package/dist/fm/__federation_expose_theme.js.map +1 -1
  35. package/dist/fm/flowComponents.js +1 -1
  36. package/dist/fm/flowComponents.js.map +1 -1
  37. package/dist/fm/main.js +1 -1
  38. package/dist/fm/main.js.map +1 -1
  39. package/dist/fm/mf-manifest.json +1 -1
  40. package/dist/fm/mf-stats.json +1 -1
  41. package/dist/index.d.ts +223 -122
  42. package/dist/types/Avatar/Avatar.d.ts +1 -1
  43. package/dist/types/Badge/Badge.d.ts +1 -1
  44. package/dist/types/CodeSnippet/CodeSnippet.d.ts +1 -1
  45. package/dist/types/CollapsibleContainer/CollapsibleContainer.d.ts +33 -1
  46. package/dist/types/Container/Container.d.ts +27 -1
  47. package/dist/types/CssVarImage/CssVarImage.d.ts +7 -1
  48. package/dist/types/Divider/Divider.d.ts +1 -1
  49. package/dist/types/Hcaptcha/Hcaptcha.d.ts +1 -1
  50. package/dist/types/HybridField/HybridField.d.ts +18 -1
  51. package/dist/types/Image/Image.d.ts +7 -1
  52. package/dist/types/Recaptcha/Recaptcha.d.ts +1 -1
  53. package/dist/types/Tooltip/Tooltip.d.ts +2 -2
  54. package/dist/types/Turnstile/Turnstile.d.ts +12 -1
  55. package/dist/types/UploadFile/UploadFile.d.ts +1 -1
  56. package/dist/types/UserAttribute/UserAttribute.d.ts +1 -1
  57. package/dist/types/UserAuthMethod/UserAuthMethod.d.ts +12 -1
  58. package/package.json +4 -4
@@ -12,5 +12,5 @@ declare global {
12
12
  }
13
13
  }
14
14
  }
15
- declare const Avatar: React.ForwardRefExoticComponent<any>;
15
+ declare const Avatar: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement, unknown> & Props, "ref"> & React.RefAttributes<HTMLButtonElement>>;
16
16
  export default Avatar;
@@ -12,5 +12,5 @@ declare global {
12
12
  }
13
13
  }
14
14
  }
15
- declare const Badge: React.ForwardRefExoticComponent<any>;
15
+ declare const Badge: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLElement, unknown> & React.RefAttributes<HTMLElement>>;
16
16
  export default Badge;
@@ -10,5 +10,5 @@ declare global {
10
10
  }
11
11
  }
12
12
  }
13
- declare const CodeSnippet: React.ForwardRefExoticComponent<any>;
13
+ declare const CodeSnippet: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLElement, unknown> & React.RefAttributes<HTMLElement>>;
14
14
  export default CodeSnippet;
@@ -1,4 +1,36 @@
1
1
  import React from 'react';
2
+ import { FlexAlignment } from '../types';
3
+ type Never<T extends Record<string, any>> = {
4
+ [K in keyof T]: never;
5
+ };
6
+ type SpaceBetween = '0' | '0.5' | '1' | '1.5' | '2' | '2.5' | '3' | '3.5' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '14' | '16' | '20' | '24' | '28' | '32';
7
+ type Flex = {
8
+ spaceBetween?: SpaceBetween;
9
+ };
10
+ type ContainerAlignment = {
11
+ 'horizontal-alignment'?: FlexAlignment | 'space-between';
12
+ 'vertical-alignment'?: FlexAlignment;
13
+ 'space-between'?: 'sm' | 'md' | 'lg';
14
+ };
15
+ type Props = {
16
+ shadow?: 'md' | 'lg' | 'xl' | '2xl';
17
+ borderRadius?: 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';
18
+ paddingX?: string;
19
+ paddingY?: string;
20
+ background?: string;
21
+ backgroundImageUrl?: string;
22
+ width?: string;
23
+ collapsible?: boolean;
24
+ 'icon-position'?: 'right' | 'left';
25
+ 'fill-title'?: boolean;
26
+ border?: boolean;
27
+ text?: string;
28
+ 'icon-name'?: string;
29
+ collapsed?: boolean;
30
+ 'text-align'?: 'left' | 'right' | 'center';
31
+ 'text-variant'?: 'body1' | 'body2' | 'subtitle1' | 'h1' | 'h2' | 'h3' | 'subtitle2';
32
+ 'text-mode'?: 'primary' | 'secondary' | 'error' | 'success';
33
+ } & ((Flex & Never<ContainerAlignment>) | (ContainerAlignment & Never<Flex>));
2
34
  declare global {
3
35
  namespace React.JSX {
4
36
  interface IntrinsicElements {
@@ -6,5 +38,5 @@ declare global {
6
38
  }
7
39
  }
8
40
  }
9
- declare const Container: React.ForwardRefExoticComponent<any>;
41
+ declare const Container: React.ForwardRefExoticComponent<(Props & React.HTMLAttributes<HTMLDivElement, unknown>) & React.RefAttributes<HTMLDivElement>>;
10
42
  export default Container;
@@ -1,4 +1,30 @@
1
1
  import React from 'react';
2
+ import { FlexAlignment } from '../types';
3
+ type Never<T extends Record<string, any>> = {
4
+ [K in keyof T]: never;
5
+ };
6
+ type SpaceBetween = '0' | '0.5' | '1' | '1.5' | '2' | '2.5' | '3' | '3.5' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '14' | '16' | '20' | '24' | '28' | '32';
7
+ type Flex = {
8
+ align?: 'start' | 'end' | 'center' | 'baseline' | 'stretch';
9
+ justify?: 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly';
10
+ spaceBetween?: SpaceBetween;
11
+ };
12
+ type ContainerAlignment = {
13
+ 'horizontal-alignment'?: FlexAlignment | 'space-between';
14
+ 'vertical-alignment'?: FlexAlignment;
15
+ 'space-between'?: 'sm' | 'md' | 'lg';
16
+ };
17
+ type Props = {
18
+ direction?: 'row' | 'column';
19
+ shadow?: 'md' | 'lg' | 'xl' | '2xl';
20
+ borderRadius?: 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';
21
+ paddingX?: string;
22
+ paddingY?: string;
23
+ background?: string;
24
+ backgroundImageUrl?: string;
25
+ width?: string;
26
+ variant?: string;
27
+ } & ((Flex & Never<ContainerAlignment>) | (ContainerAlignment & Never<Flex>));
2
28
  declare global {
3
29
  namespace React.JSX {
4
30
  interface IntrinsicElements {
@@ -6,5 +32,5 @@ declare global {
6
32
  }
7
33
  }
8
34
  }
9
- declare const Container: React.ForwardRefExoticComponent<any>;
35
+ declare const Container: React.ForwardRefExoticComponent<(Props & React.HTMLAttributes<HTMLDivElement, unknown>) & React.RefAttributes<HTMLDivElement>>;
10
36
  export default Container;
@@ -1,3 +1,9 @@
1
1
  import React from 'react';
2
- declare const CssVarImage: React.ForwardRefExoticComponent<any>;
2
+ type Props = {
3
+ varName: string;
4
+ fallback?: string;
5
+ width?: number;
6
+ height?: number;
7
+ };
8
+ declare const CssVarImage: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLImageElement, unknown> & React.RefAttributes<HTMLDivElement>>;
3
9
  export default CssVarImage;
@@ -14,5 +14,5 @@ declare global {
14
14
  }
15
15
  }
16
16
  }
17
- declare const Divider: React.ForwardRefExoticComponent<Omit<Omit<any, "size"> & Props, "ref"> & React.RefAttributes<HTMLDivElement>>;
17
+ declare const Divider: React.ForwardRefExoticComponent<Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement, unknown>, HTMLDivElement>, "size"> & Props, "ref"> & React.RefAttributes<HTMLDivElement>>;
18
18
  export default Divider;
@@ -10,5 +10,5 @@ type Props = {
10
10
  connector?: string;
11
11
  enabled?: boolean;
12
12
  };
13
- declare const Hcaptcha: React.ForwardRefExoticComponent<any>;
13
+ declare const Hcaptcha: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLDivElement, unknown> & React.RefAttributes<HTMLDivElement>>;
14
14
  export default Hcaptcha;
@@ -25,5 +25,22 @@ declare global {
25
25
  }
26
26
  }
27
27
  }
28
- declare const HybridField: React.ForwardRefExoticComponent<any>;
28
+ declare const HybridField: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement, unknown> & {
29
+ variant?: "countrySelection" | "inputBox";
30
+ 'default-code'?: string;
31
+ 'phone-input-label'?: string;
32
+ 'phone-input-placeholder'?: string;
33
+ 'restrict-countries'?: string;
34
+ 'full-width'?: boolean;
35
+ bordered?: boolean;
36
+ label?: string;
37
+ placeholder?: string;
38
+ size?: ComponentSize;
39
+ 'helper-text'?: string;
40
+ 'data-errormessage-pattern-mismatch-email'?: string;
41
+ 'data-errormessage-value-missing-email'?: string;
42
+ 'data-errormessage-value-missing-phone'?: string;
43
+ 'label-type'?: LabelType;
44
+ 'external-input'?: boolean;
45
+ } & import("../types").HTMLInputAttrs & import("../types").DescopeInputExtraProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
29
46
  export default HybridField;
@@ -14,5 +14,11 @@ declare global {
14
14
  }
15
15
  }
16
16
  }
17
- declare const Image: React.ForwardRefExoticComponent<any>;
17
+ declare const Image: React.ForwardRefExoticComponent<{
18
+ width?: string;
19
+ height?: string;
20
+ alt?: string;
21
+ src: string;
22
+ 'src-dark'?: string;
23
+ } & ITooltip & React.HTMLAttributes<HTMLElement, unknown> & React.RefAttributes<HTMLElement>>;
18
24
  export default Image;
@@ -23,5 +23,5 @@ declare global {
23
23
  }
24
24
  }
25
25
  }
26
- declare const Recaptcha: React.ForwardRefExoticComponent<any>;
26
+ declare const Recaptcha: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLDivElement, unknown> & React.RefAttributes<HTMLDivElement>>;
27
27
  export default Recaptcha;
@@ -11,7 +11,7 @@ type Props = {
11
11
  children?: React.ReactNode;
12
12
  };
13
13
  declare module 'react' {
14
- interface HTMLAttributes<_T> {
14
+ interface HTMLAttributes<T, _T = unknown> {
15
15
  slot?: string;
16
16
  }
17
17
  }
@@ -22,7 +22,7 @@ declare global {
22
22
  }
23
23
  }
24
24
  }
25
- declare const Tooltip: React.ForwardRefExoticComponent<any>;
25
+ declare const Tooltip: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLElement, unknown> & Props & React.RefAttributes<HTMLElement>>;
26
26
  export default Tooltip;
27
27
  export interface ITooltip {
28
28
  hasTooltip?: boolean;
@@ -1,3 +1,14 @@
1
1
  import React from 'react';
2
- declare const Turnstile: React.ForwardRefExoticComponent<any>;
2
+ import { Mode, TextAlign, TypographyVariants } from '../types';
3
+ type Props = {
4
+ connector?: string;
5
+ action?: string;
6
+ textLabel?: string;
7
+ textVariant?: TypographyVariants;
8
+ textMode?: Mode;
9
+ textAlign?: TextAlign;
10
+ readonly?: boolean;
11
+ 'full-width'?: boolean;
12
+ };
13
+ declare const Turnstile: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLDivElement, unknown> & React.RefAttributes<HTMLDivElement>>;
3
14
  export default Turnstile;
@@ -23,5 +23,5 @@ declare global {
23
23
  }
24
24
  }
25
25
  }
26
- declare const UploadFile: React.ForwardRefExoticComponent<any>;
26
+ declare const UploadFile: React.ForwardRefExoticComponent<Props & React.HTMLAttributes<HTMLDivElement, unknown> & React.RefAttributes<HTMLDivElement>>;
27
27
  export default UploadFile;
@@ -19,5 +19,5 @@ declare global {
19
19
  }
20
20
  }
21
21
  }
22
- declare const UserAttribute: React.ForwardRefExoticComponent<any>;
22
+ declare const UserAttribute: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement, unknown> & Props, "ref"> & React.RefAttributes<HTMLButtonElement>>;
23
23
  export default UserAttribute;
@@ -9,5 +9,16 @@ declare global {
9
9
  }
10
10
  }
11
11
  }
12
- declare const UserAuthMethod: React.ForwardRefExoticComponent<any>;
12
+ declare const UserAuthMethod: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement, unknown> & {
13
+ label?: string;
14
+ 'button-label'?: string;
15
+ fulfilled?: boolean;
16
+ 'full-width'?: boolean;
17
+ methodIcon?: string;
18
+ methodIconDark?: string;
19
+ buttonIcon?: string;
20
+ buttonIconDark?: string;
21
+ fulfilledButtonIcon?: string;
22
+ fulfilledButtonIconDark?: string;
23
+ }, "ref"> & React.RefAttributes<HTMLButtonElement>>;
13
24
  export default UserAuthMethod;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@descope/flow-components",
3
- "version": "3.1.0",
3
+ "version": "3.1.2",
4
4
  "description": "",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",
@@ -51,7 +51,7 @@
51
51
  "@typescript-eslint/eslint-plugin": "^8.0.0",
52
52
  "@typescript-eslint/parser": "^8.0.0",
53
53
  "autoprefixer": "^10.4.8",
54
- "babel-jest": "30.2.0",
54
+ "babel-jest": "30.3.0",
55
55
  "eslint": "10.0.3",
56
56
  "eslint-config-airbnb": "^19.0.4",
57
57
  "eslint-config-airbnb-typescript": "18.0.0",
@@ -72,7 +72,7 @@
72
72
  "eslint-plugin-testing-library": "^7.0.0",
73
73
  "husky": "^9.0.0",
74
74
  "jest": "^30.0.0",
75
- "jest-environment-jsdom": "30.2.0",
75
+ "jest-environment-jsdom": "30.3.0",
76
76
  "lint-staged": "^16.0.0",
77
77
  "postcss": "^8.4.14",
78
78
  "prettier": "3.8.1",
@@ -97,7 +97,7 @@
97
97
  "webpack-subresource-integrity": "5.2.0-rc.1"
98
98
  },
99
99
  "dependencies": {
100
- "@descope/web-components-ui": "3.1.0"
100
+ "@descope/web-components-ui": "3.1.2"
101
101
  },
102
102
  "peerDependencies": {
103
103
  "react": ">= 18"