@asgardeo/react 0.11.2 → 0.12.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.
- package/dist/AsgardeoReactClient.d.ts +10 -10
- package/dist/__temp__/api.d.ts +6 -6
- package/dist/__temp__/models.d.ts +30 -30
- package/dist/cjs/index.js +6272 -5796
- package/dist/cjs/index.js.map +4 -4
- package/dist/components/adapters/FacebookButton.d.ts +1 -1
- package/dist/components/adapters/GitHubButton.d.ts +1 -1
- package/dist/components/adapters/GoogleButton.d.ts +1 -1
- package/dist/components/adapters/LinkedInButton.d.ts +1 -1
- package/dist/components/adapters/MicrosoftButton.d.ts +1 -1
- package/dist/components/adapters/SignInWithEthereumButton.d.ts +1 -1
- package/dist/components/adapters/SmsOtpButton.d.ts +1 -1
- package/dist/components/auth/Callback/Callback.d.ts +51 -0
- package/dist/components/factories/FieldFactory.d.ts +25 -25
- package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.styles.d.ts +1 -18
- package/dist/components/presentation/CreateOrganization/CreateOrganization.d.ts +1 -1
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.d.ts +26 -26
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.styles.d.ts +1 -31
- package/dist/components/presentation/OrganizationList/OrganizationList.styles.d.ts +1 -6
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.d.ts +3 -3
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.styles.d.ts +1 -27
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.d.ts +6 -6
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.styles.d.ts +1 -25
- package/dist/components/presentation/User/BaseUser.d.ts +4 -4
- package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.d.ts +1 -15
- package/dist/components/presentation/UserProfile/BaseUserProfile.d.ts +3 -3
- package/dist/components/presentation/UserProfile/BaseUserProfile.styles.d.ts +1 -26
- package/dist/components/presentation/auth/AcceptInvite/index.d.ts +1 -1
- package/dist/components/presentation/auth/AcceptInvite/v2/AcceptInvite.d.ts +13 -13
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.d.ts +52 -51
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.styles.d.ts +6 -10
- package/dist/components/presentation/auth/AuthOptionFactory.d.ts +1 -1
- package/dist/components/presentation/auth/InviteUser/index.d.ts +1 -1
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.d.ts +57 -57
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.styles.d.ts +6 -10
- package/dist/components/presentation/auth/InviteUser/v2/InviteUser.d.ts +15 -15
- package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.d.ts +1 -27
- package/dist/components/presentation/auth/SignIn/SignIn.d.ts +1 -1
- package/dist/components/presentation/auth/SignIn/v1/BaseSignIn.d.ts +12 -12
- package/dist/components/presentation/auth/SignIn/v1/options/SignInOptionFactory.d.ts +15 -15
- package/dist/components/presentation/auth/SignIn/v1/types.d.ts +30 -30
- package/dist/components/presentation/auth/SignIn/v2/BaseSignIn.d.ts +47 -47
- package/dist/components/presentation/auth/SignIn/v2/SignIn.d.ts +20 -20
- package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.d.ts +1 -26
- package/dist/components/presentation/auth/SignUp/v1/BaseSignUp.d.ts +40 -40
- package/dist/components/presentation/auth/SignUp/v1/SignUpOptionFactory.d.ts +1 -1
- package/dist/components/presentation/auth/SignUp/v2/BaseSignUp.d.ts +46 -46
- package/dist/components/primitives/Alert/Alert.d.ts +8 -8
- package/dist/components/primitives/Alert/Alert.styles.d.ts +1 -8
- package/dist/components/primitives/Avatar/Avatar.d.ts +4 -4
- package/dist/components/primitives/Avatar/Avatar.styles.d.ts +1 -7
- package/dist/components/primitives/Button/Button.d.ts +14 -14
- package/dist/components/primitives/Button/Button.styles.d.ts +1 -13
- package/dist/components/primitives/Card/Card.d.ts +4 -4
- package/dist/components/primitives/Card/Card.styles.d.ts +1 -11
- package/dist/components/primitives/Checkbox/Checkbox.d.ts +8 -8
- package/dist/components/primitives/Checkbox/Checkbox.styles.d.ts +1 -8
- package/dist/components/primitives/DatePicker/DatePicker.d.ts +12 -12
- package/dist/components/primitives/DatePicker/DatePicker.styles.d.ts +1 -6
- package/dist/components/primitives/Dialog/Dialog.d.ts +17 -17
- package/dist/components/primitives/Dialog/Dialog.styles.d.ts +1 -9
- package/dist/components/primitives/Divider/Divider.d.ts +2 -2
- package/dist/components/primitives/Divider/Divider.styles.d.ts +1 -7
- package/dist/components/primitives/FormControl/FormControl.d.ts +4 -4
- package/dist/components/primitives/FormControl/FormControl.styles.d.ts +1 -5
- package/dist/components/primitives/InputLabel/InputLabel.d.ts +10 -10
- package/dist/components/primitives/InputLabel/InputLabel.styles.d.ts +1 -7
- package/dist/components/primitives/KeyValueInput/KeyValueInput.d.ts +4 -4
- package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.d.ts +1 -17
- package/dist/components/primitives/Logo/Logo.d.ts +8 -8
- package/dist/components/primitives/Logo/Logo.styles.d.ts +1 -7
- package/dist/components/primitives/MultiInput/MultiInput.d.ts +28 -28
- package/dist/components/primitives/MultiInput/MultiInput.styles.d.ts +1 -11
- package/dist/components/primitives/OtpField/OtpField.d.ts +20 -20
- package/dist/components/primitives/OtpField/OtpField.styles.d.ts +1 -6
- package/dist/components/primitives/PasswordField/PasswordField.styles.d.ts +1 -5
- package/dist/components/primitives/Select/Select.d.ts +18 -18
- package/dist/components/primitives/Select/Select.styles.d.ts +1 -6
- package/dist/components/primitives/Spinner/Spinner.d.ts +4 -4
- package/dist/components/primitives/Spinner/Spinner.styles.d.ts +1 -6
- package/dist/components/primitives/TextField/TextField.d.ts +18 -18
- package/dist/components/primitives/TextField/TextField.styles.d.ts +1 -9
- package/dist/components/primitives/Typography/Typography.d.ts +24 -24
- package/dist/components/primitives/Typography/Typography.styles.d.ts +1 -19
- package/dist/contexts/Asgardeo/AsgardeoContext.d.ts +62 -62
- package/dist/contexts/Branding/BrandingContext.d.ts +12 -11
- package/dist/contexts/Branding/BrandingProvider.d.ts +10 -10
- package/dist/contexts/Flow/FlowContext.d.ts +25 -24
- package/dist/contexts/Flow/FlowProvider.d.ts +4 -4
- package/dist/contexts/I18n/I18nContext.d.ts +6 -5
- package/dist/contexts/I18n/I18nProvider.d.ts +1 -1
- package/dist/contexts/Theme/ThemeContext.d.ts +12 -11
- package/dist/contexts/Theme/ThemeProvider.d.ts +10 -10
- package/dist/contexts/Theme/types.d.ts +30 -30
- package/dist/contexts/User/UserContext.d.ts +2 -2
- package/dist/contexts/User/UserProvider.d.ts +2 -2
- package/dist/hooks/useBranding.d.ts +17 -17
- package/dist/hooks/useBrowserUrl.d.ts +8 -0
- package/dist/hooks/useForm.d.ts +10 -9
- package/dist/hooks/useTranslation.d.ts +4 -4
- package/dist/hooks/v2/useOAuthCallback.d.ts +82 -0
- package/dist/index.d.ts +7 -26
- package/dist/index.js +6330 -5824
- package/dist/index.js.map +4 -4
- package/dist/utils/oauth.d.ts +24 -0
- package/dist/utils/v2/flowTransformer.d.ts +7 -7
- package/dist/utils/v2/getAuthComponentHeadings.d.ts +2 -2
- package/package.json +2 -2
|
@@ -23,29 +23,29 @@ export interface InputLabelProps extends Omit<LabelHTMLAttributes<HTMLLabelEleme
|
|
|
23
23
|
*/
|
|
24
24
|
children: ReactNode;
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
26
|
+
* Additional CSS class names
|
|
27
27
|
*/
|
|
28
|
-
|
|
28
|
+
className?: string;
|
|
29
29
|
/**
|
|
30
30
|
* Whether there's an error state
|
|
31
31
|
*/
|
|
32
32
|
error?: boolean;
|
|
33
33
|
/**
|
|
34
|
-
* Custom
|
|
34
|
+
* Custom margin bottom (useful for different form layouts)
|
|
35
35
|
*/
|
|
36
|
-
|
|
36
|
+
marginBottom?: string;
|
|
37
37
|
/**
|
|
38
|
-
*
|
|
38
|
+
* Whether the field is required
|
|
39
39
|
*/
|
|
40
|
-
|
|
40
|
+
required?: boolean;
|
|
41
41
|
/**
|
|
42
|
-
* Custom
|
|
42
|
+
* Custom style overrides
|
|
43
43
|
*/
|
|
44
|
-
|
|
44
|
+
style?: CSSProperties;
|
|
45
45
|
/**
|
|
46
|
-
*
|
|
46
|
+
* Display type for label positioning
|
|
47
47
|
*/
|
|
48
|
-
|
|
48
|
+
variant?: InputLabelVariant;
|
|
49
49
|
}
|
|
50
50
|
declare const InputLabel: FC<InputLabelProps>;
|
|
51
51
|
export default InputLabel;
|
|
@@ -26,11 +26,5 @@ export type InputLabelVariant = 'block' | 'inline';
|
|
|
26
26
|
* @param marginBottom - Custom margin bottom value
|
|
27
27
|
* @returns Object containing CSS class names for component styling
|
|
28
28
|
*/
|
|
29
|
-
declare const useStyles: (theme: Theme, colorScheme: string, variant: InputLabelVariant, error: boolean, marginBottom?: string) =>
|
|
30
|
-
label: string;
|
|
31
|
-
error: string;
|
|
32
|
-
requiredIndicator: string;
|
|
33
|
-
block: string;
|
|
34
|
-
inline: string;
|
|
35
|
-
};
|
|
29
|
+
declare const useStyles: (theme: Theme, colorScheme: string, variant: InputLabelVariant, error: boolean, marginBottom?: string) => Record<string, string>;
|
|
36
30
|
export default useStyles;
|
|
@@ -53,14 +53,14 @@ export interface KeyValueInputProps {
|
|
|
53
53
|
* Maximum number of key-value pairs allowed.
|
|
54
54
|
*/
|
|
55
55
|
maxPairs?: number;
|
|
56
|
-
/**
|
|
57
|
-
* Callback fired when the key-value pairs change.
|
|
58
|
-
*/
|
|
59
|
-
onChange?: (pairs: KeyValuePair[]) => void;
|
|
60
56
|
/**
|
|
61
57
|
* Callback fired when a pair is added.
|
|
62
58
|
*/
|
|
63
59
|
onAdd?: (pair: KeyValuePair) => void;
|
|
60
|
+
/**
|
|
61
|
+
* Callback fired when the key-value pairs change.
|
|
62
|
+
*/
|
|
63
|
+
onChange?: (pairs: KeyValuePair[]) => void;
|
|
64
64
|
/**
|
|
65
65
|
* Callback fired when a pair is removed.
|
|
66
66
|
*/
|
|
@@ -25,21 +25,5 @@ import { Theme } from '@asgardeo/browser';
|
|
|
25
25
|
* @param hasError - Whether the component has an error
|
|
26
26
|
* @returns Object containing CSS class names for component styling
|
|
27
27
|
*/
|
|
28
|
-
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, readOnly: boolean, hasError: boolean) =>
|
|
29
|
-
container: string;
|
|
30
|
-
label: string;
|
|
31
|
-
requiredIndicator: string;
|
|
32
|
-
pairsList: string;
|
|
33
|
-
pairRow: string;
|
|
34
|
-
pairInput: string;
|
|
35
|
-
addRow: string;
|
|
36
|
-
removeButton: string;
|
|
37
|
-
addButton: string;
|
|
38
|
-
helperText: string;
|
|
39
|
-
emptyState: string;
|
|
40
|
-
readOnlyPair: string;
|
|
41
|
-
readOnlyKey: string;
|
|
42
|
-
readOnlyValue: string;
|
|
43
|
-
counterText: string;
|
|
44
|
-
};
|
|
28
|
+
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, readOnly: boolean, hasError: boolean) => Record<string, string>;
|
|
45
29
|
export default useStyles;
|
|
@@ -21,26 +21,26 @@ export type LogoSize = 'small' | 'medium' | 'large';
|
|
|
21
21
|
* Props for the Logo component.
|
|
22
22
|
*/
|
|
23
23
|
export interface LogoProps {
|
|
24
|
+
/**
|
|
25
|
+
* Custom alt text for the logo.
|
|
26
|
+
*/
|
|
27
|
+
alt?: string;
|
|
24
28
|
/**
|
|
25
29
|
* Custom CSS class name for the logo.
|
|
26
30
|
*/
|
|
27
31
|
className?: string;
|
|
28
32
|
/**
|
|
29
|
-
*
|
|
33
|
+
* Size of the logo.
|
|
30
34
|
*/
|
|
31
|
-
|
|
35
|
+
size?: LogoSize;
|
|
32
36
|
/**
|
|
33
|
-
* Custom
|
|
37
|
+
* Custom logo URL to override theme logo.
|
|
34
38
|
*/
|
|
35
|
-
|
|
39
|
+
src?: string;
|
|
36
40
|
/**
|
|
37
41
|
* Custom title for the logo.
|
|
38
42
|
*/
|
|
39
43
|
title?: string;
|
|
40
|
-
/**
|
|
41
|
-
* Size of the logo.
|
|
42
|
-
*/
|
|
43
|
-
size?: LogoSize;
|
|
44
44
|
}
|
|
45
45
|
/**
|
|
46
46
|
* Logo component that displays the brand logo from theme or custom source.
|
|
@@ -24,11 +24,5 @@ export type LogoSize = 'small' | 'medium' | 'large';
|
|
|
24
24
|
* @param size - The size of the logo
|
|
25
25
|
* @returns Object containing CSS class names for component styling
|
|
26
26
|
*/
|
|
27
|
-
declare const useStyles: (theme: Theme, colorScheme: string, size: LogoSize) =>
|
|
28
|
-
logo: string;
|
|
29
|
-
size: string;
|
|
30
|
-
small: string;
|
|
31
|
-
medium: string;
|
|
32
|
-
large: string;
|
|
33
|
-
};
|
|
27
|
+
declare const useStyles: (theme: Theme, colorScheme: string, size: LogoSize) => Record<string, string>;
|
|
34
28
|
export default useStyles;
|
|
@@ -20,69 +20,69 @@ export type MultiInputType = 'text' | 'email' | 'tel' | 'url' | 'password' | 'da
|
|
|
20
20
|
export type MultiInputFieldType = 'STRING' | 'DATE_TIME' | 'BOOLEAN';
|
|
21
21
|
export interface MultiInputProps {
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* Additional CSS class names
|
|
24
24
|
*/
|
|
25
|
-
|
|
25
|
+
className?: string;
|
|
26
26
|
/**
|
|
27
|
-
*
|
|
27
|
+
* Whether the field is disabled
|
|
28
28
|
*/
|
|
29
|
-
|
|
29
|
+
disabled?: boolean;
|
|
30
30
|
/**
|
|
31
|
-
*
|
|
31
|
+
* Icon to display at the end (right) of each input (in addition to add/remove buttons)
|
|
32
32
|
*/
|
|
33
|
-
|
|
33
|
+
endIcon?: ReactNode;
|
|
34
34
|
/**
|
|
35
|
-
*
|
|
35
|
+
* Error message to display below the inputs
|
|
36
36
|
*/
|
|
37
|
-
|
|
37
|
+
error?: string;
|
|
38
38
|
/**
|
|
39
|
-
*
|
|
39
|
+
* Field type for different input components
|
|
40
40
|
*/
|
|
41
|
-
|
|
41
|
+
fieldType?: MultiInputFieldType;
|
|
42
42
|
/**
|
|
43
43
|
* Helper text to display below the inputs
|
|
44
44
|
*/
|
|
45
45
|
helperText?: string;
|
|
46
46
|
/**
|
|
47
|
-
*
|
|
47
|
+
* Label text to display above the inputs
|
|
48
48
|
*/
|
|
49
|
-
|
|
49
|
+
label?: string;
|
|
50
50
|
/**
|
|
51
|
-
*
|
|
51
|
+
* Maximum number of fields to allow (default: unlimited)
|
|
52
52
|
*/
|
|
53
|
-
|
|
53
|
+
maxFields?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Minimum number of fields to show (default: 1)
|
|
56
|
+
*/
|
|
57
|
+
minFields?: number;
|
|
54
58
|
/**
|
|
55
59
|
* Callback when values change
|
|
56
60
|
*/
|
|
57
61
|
onChange: (values: string[]) => void;
|
|
58
62
|
/**
|
|
59
|
-
*
|
|
63
|
+
* Placeholder text for input fields
|
|
60
64
|
*/
|
|
61
|
-
|
|
65
|
+
placeholder?: string;
|
|
62
66
|
/**
|
|
63
|
-
*
|
|
67
|
+
* Whether the field is required
|
|
64
68
|
*/
|
|
65
|
-
|
|
69
|
+
required?: boolean;
|
|
66
70
|
/**
|
|
67
71
|
* Icon to display at the start (left) of each input
|
|
68
72
|
*/
|
|
69
73
|
startIcon?: ReactNode;
|
|
70
74
|
/**
|
|
71
|
-
*
|
|
72
|
-
*/
|
|
73
|
-
endIcon?: ReactNode;
|
|
74
|
-
/**
|
|
75
|
-
* Minimum number of fields to show (default: 1)
|
|
75
|
+
* Custom style object
|
|
76
76
|
*/
|
|
77
|
-
|
|
77
|
+
style?: CSSProperties;
|
|
78
78
|
/**
|
|
79
|
-
*
|
|
79
|
+
* Input type
|
|
80
80
|
*/
|
|
81
|
-
|
|
81
|
+
type?: MultiInputType;
|
|
82
82
|
/**
|
|
83
|
-
*
|
|
83
|
+
* Array of values
|
|
84
84
|
*/
|
|
85
|
-
|
|
85
|
+
values: string[];
|
|
86
86
|
}
|
|
87
87
|
declare const MultiInput: FC<MultiInputProps>;
|
|
88
88
|
export default MultiInput;
|
|
@@ -28,15 +28,5 @@ export type MultiInputFieldType = 'STRING' | 'DATE_TIME' | 'BOOLEAN';
|
|
|
28
28
|
* @param canRemove - Whether items can be removed
|
|
29
29
|
* @returns Object containing CSS class names for component styling
|
|
30
30
|
*/
|
|
31
|
-
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, canAddMore: boolean, canRemove: boolean) =>
|
|
32
|
-
container: string;
|
|
33
|
-
inputRow: string;
|
|
34
|
-
inputWrapper: string;
|
|
35
|
-
plusIcon: string;
|
|
36
|
-
listContainer: string;
|
|
37
|
-
listItem: string;
|
|
38
|
-
listItemText: string;
|
|
39
|
-
removeButton: string;
|
|
40
|
-
icon: string;
|
|
41
|
-
};
|
|
31
|
+
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, canAddMore: boolean, canRemove: boolean) => Record<string, string>;
|
|
42
32
|
export default useStyles;
|
|
@@ -19,37 +19,33 @@ import { FC, CSSProperties } from 'react';
|
|
|
19
19
|
export type OtpFieldType = 'text' | 'number' | 'password';
|
|
20
20
|
export interface OtpInputProps {
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
23
|
-
*/
|
|
24
|
-
label?: string;
|
|
25
|
-
/**
|
|
26
|
-
* Error message to display below the OTP input
|
|
22
|
+
* Auto focus the first input on mount
|
|
27
23
|
*/
|
|
28
|
-
|
|
24
|
+
autoFocus?: boolean;
|
|
29
25
|
/**
|
|
30
26
|
* Additional CSS class names
|
|
31
27
|
*/
|
|
32
28
|
className?: string;
|
|
33
|
-
/**
|
|
34
|
-
* Whether the field is required
|
|
35
|
-
*/
|
|
36
|
-
required?: boolean;
|
|
37
29
|
/**
|
|
38
30
|
* Whether the field is disabled
|
|
39
31
|
*/
|
|
40
32
|
disabled?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* Error message to display below the OTP input
|
|
35
|
+
*/
|
|
36
|
+
error?: string;
|
|
41
37
|
/**
|
|
42
38
|
* Helper text to display below the OTP input
|
|
43
39
|
*/
|
|
44
40
|
helperText?: string;
|
|
45
41
|
/**
|
|
46
|
-
*
|
|
42
|
+
* Label text to display above the OTP input
|
|
47
43
|
*/
|
|
48
|
-
|
|
44
|
+
label?: string;
|
|
49
45
|
/**
|
|
50
|
-
*
|
|
46
|
+
* Number of OTP input fields
|
|
51
47
|
*/
|
|
52
|
-
|
|
48
|
+
length?: number;
|
|
53
49
|
/**
|
|
54
50
|
* Callback function called when OTP value changes
|
|
55
51
|
*/
|
|
@@ -63,25 +59,29 @@ export interface OtpInputProps {
|
|
|
63
59
|
*/
|
|
64
60
|
onComplete?: (value: string) => void;
|
|
65
61
|
/**
|
|
66
|
-
*
|
|
62
|
+
* Pattern for numeric input validation
|
|
67
63
|
*/
|
|
68
|
-
|
|
64
|
+
pattern?: string;
|
|
69
65
|
/**
|
|
70
66
|
* Placeholder character for each input field
|
|
71
67
|
*/
|
|
72
68
|
placeholder?: string;
|
|
69
|
+
/**
|
|
70
|
+
* Whether the field is required
|
|
71
|
+
*/
|
|
72
|
+
required?: boolean;
|
|
73
73
|
/**
|
|
74
74
|
* Custom container style
|
|
75
75
|
*/
|
|
76
76
|
style?: CSSProperties;
|
|
77
77
|
/**
|
|
78
|
-
*
|
|
78
|
+
* Type of input (text, number, password)
|
|
79
79
|
*/
|
|
80
|
-
|
|
80
|
+
type?: OtpFieldType;
|
|
81
81
|
/**
|
|
82
|
-
*
|
|
82
|
+
* Current OTP value
|
|
83
83
|
*/
|
|
84
|
-
|
|
84
|
+
value?: string;
|
|
85
85
|
}
|
|
86
86
|
declare const OtpField: FC<OtpInputProps>;
|
|
87
87
|
export default OtpField;
|
|
@@ -26,10 +26,5 @@ export type OtpFieldType = 'text' | 'number' | 'password';
|
|
|
26
26
|
* @param length - Number of OTP input fields
|
|
27
27
|
* @returns Object containing CSS class names for component styling
|
|
28
28
|
*/
|
|
29
|
-
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, length: number) =>
|
|
30
|
-
inputContainer: string;
|
|
31
|
-
input: string;
|
|
32
|
-
inputError: string;
|
|
33
|
-
inputDisabled: string;
|
|
34
|
-
};
|
|
29
|
+
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, length: number) => Record<string, string>;
|
|
35
30
|
export default useStyles;
|
|
@@ -25,9 +25,5 @@ import { Theme } from '@asgardeo/browser';
|
|
|
25
25
|
* @param hasError - Whether the component has an error
|
|
26
26
|
* @returns Object containing CSS class names for component styling
|
|
27
27
|
*/
|
|
28
|
-
declare const useStyles: (theme: Theme, colorScheme: string, showPassword: boolean, disabled: boolean, hasError: boolean) =>
|
|
29
|
-
toggleIcon: string;
|
|
30
|
-
visibleIcon: string;
|
|
31
|
-
hiddenIcon: string;
|
|
32
|
-
};
|
|
28
|
+
declare const useStyles: (theme: Theme, colorScheme: string, showPassword: boolean, disabled: boolean, hasError: boolean) => Record<string, string>;
|
|
33
29
|
export default useStyles;
|
|
@@ -17,48 +17,48 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import { FC, SelectHTMLAttributes } from 'react';
|
|
19
19
|
export interface SelectOption {
|
|
20
|
-
/**
|
|
21
|
-
* The value that will be submitted with the form
|
|
22
|
-
*/
|
|
23
|
-
value: string;
|
|
24
20
|
/**
|
|
25
21
|
* The text that will be displayed in the select
|
|
26
22
|
*/
|
|
27
23
|
label: string;
|
|
28
|
-
}
|
|
29
|
-
export interface SelectProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'className'> {
|
|
30
|
-
/**
|
|
31
|
-
* Label text to display above the select
|
|
32
|
-
*/
|
|
33
|
-
label?: string;
|
|
34
24
|
/**
|
|
35
|
-
*
|
|
25
|
+
* The value that will be submitted with the form
|
|
36
26
|
*/
|
|
37
|
-
|
|
27
|
+
value: string;
|
|
28
|
+
}
|
|
29
|
+
export interface SelectProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'className'> {
|
|
38
30
|
/**
|
|
39
31
|
* Additional CSS class names
|
|
40
32
|
*/
|
|
41
33
|
className?: string;
|
|
42
|
-
/**
|
|
43
|
-
* Whether the field is required
|
|
44
|
-
*/
|
|
45
|
-
required?: boolean;
|
|
46
34
|
/**
|
|
47
35
|
* Whether the field is disabled
|
|
48
36
|
*/
|
|
49
37
|
disabled?: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* Error message to display below the select
|
|
40
|
+
*/
|
|
41
|
+
error?: string;
|
|
50
42
|
/**
|
|
51
43
|
* Helper text to display below the select
|
|
52
44
|
*/
|
|
53
45
|
helperText?: string;
|
|
54
46
|
/**
|
|
55
|
-
*
|
|
47
|
+
* Label text to display above the select
|
|
56
48
|
*/
|
|
57
|
-
|
|
49
|
+
label?: string;
|
|
58
50
|
/**
|
|
59
51
|
* The options to display in the select
|
|
60
52
|
*/
|
|
61
53
|
options: SelectOption[];
|
|
54
|
+
/**
|
|
55
|
+
* Placeholder text for the default/empty option
|
|
56
|
+
*/
|
|
57
|
+
placeholder?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Whether the field is required
|
|
60
|
+
*/
|
|
61
|
+
required?: boolean;
|
|
62
62
|
}
|
|
63
63
|
declare const Select: FC<SelectProps>;
|
|
64
64
|
export default Select;
|
|
@@ -24,10 +24,5 @@ import { Theme } from '@asgardeo/browser';
|
|
|
24
24
|
* @param hasError - Whether the component has an error
|
|
25
25
|
* @returns Object containing CSS class names for component styling
|
|
26
26
|
*/
|
|
27
|
-
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean) =>
|
|
28
|
-
select: string;
|
|
29
|
-
selectError: string;
|
|
30
|
-
selectDisabled: string;
|
|
31
|
-
option: string;
|
|
32
|
-
};
|
|
27
|
+
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean) => Record<string, string>;
|
|
33
28
|
export default useStyles;
|
|
@@ -19,17 +19,17 @@ import { FC, CSSProperties } from 'react';
|
|
|
19
19
|
export type SpinnerSize = 'small' | 'medium' | 'large';
|
|
20
20
|
export interface SpinnerProps {
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
22
|
+
* Additional CSS class names
|
|
23
23
|
*/
|
|
24
|
-
|
|
24
|
+
className?: string;
|
|
25
25
|
/**
|
|
26
26
|
* Custom color for the spinner
|
|
27
27
|
*/
|
|
28
28
|
color?: string;
|
|
29
29
|
/**
|
|
30
|
-
*
|
|
30
|
+
* Size of the spinner
|
|
31
31
|
*/
|
|
32
|
-
|
|
32
|
+
size?: SpinnerSize;
|
|
33
33
|
/**
|
|
34
34
|
* Custom styles
|
|
35
35
|
*/
|
|
@@ -25,10 +25,5 @@ export type SpinnerSize = 'small' | 'medium' | 'large';
|
|
|
25
25
|
* @param color - The color of the spinner
|
|
26
26
|
* @returns Object containing CSS class names for component styling
|
|
27
27
|
*/
|
|
28
|
-
declare const useStyles: (theme: Theme, colorScheme: string, size: SpinnerSize, color?: string) =>
|
|
29
|
-
spinner: string;
|
|
30
|
-
spinnerSmall: string;
|
|
31
|
-
spinnerMedium: string;
|
|
32
|
-
spinnerLarge: string;
|
|
33
|
-
};
|
|
28
|
+
declare const useStyles: (theme: Theme, colorScheme: string, size: SpinnerSize, color?: string) => Record<string, string>;
|
|
34
29
|
export default useStyles;
|
|
@@ -17,46 +17,46 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import { FC, InputHTMLAttributes, ReactNode } from 'react';
|
|
19
19
|
export interface TextFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className'> {
|
|
20
|
-
/**
|
|
21
|
-
* Label text to display above the input
|
|
22
|
-
*/
|
|
23
|
-
label?: string;
|
|
24
|
-
/**
|
|
25
|
-
* Error message to display below the input
|
|
26
|
-
*/
|
|
27
|
-
error?: string;
|
|
28
20
|
/**
|
|
29
21
|
* Additional CSS class names
|
|
30
22
|
*/
|
|
31
23
|
className?: string;
|
|
32
|
-
/**
|
|
33
|
-
* Whether the field is required
|
|
34
|
-
*/
|
|
35
|
-
required?: boolean;
|
|
36
24
|
/**
|
|
37
25
|
* Whether the field is disabled
|
|
38
26
|
*/
|
|
39
27
|
disabled?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* Icon to display at the end (right) of the input
|
|
30
|
+
*/
|
|
31
|
+
endIcon?: ReactNode;
|
|
32
|
+
/**
|
|
33
|
+
* Error message to display below the input
|
|
34
|
+
*/
|
|
35
|
+
error?: string;
|
|
40
36
|
/**
|
|
41
37
|
* Helper text to display below the input
|
|
42
38
|
*/
|
|
43
39
|
helperText?: string;
|
|
44
40
|
/**
|
|
45
|
-
*
|
|
41
|
+
* Label text to display above the input
|
|
46
42
|
*/
|
|
47
|
-
|
|
43
|
+
label?: string;
|
|
48
44
|
/**
|
|
49
|
-
*
|
|
45
|
+
* Click handler for the end icon
|
|
50
46
|
*/
|
|
51
|
-
|
|
47
|
+
onEndIconClick?: () => void;
|
|
52
48
|
/**
|
|
53
49
|
* Click handler for the start icon
|
|
54
50
|
*/
|
|
55
51
|
onStartIconClick?: () => void;
|
|
56
52
|
/**
|
|
57
|
-
*
|
|
53
|
+
* Whether the field is required
|
|
58
54
|
*/
|
|
59
|
-
|
|
55
|
+
required?: boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Icon to display at the start (left) of the input
|
|
58
|
+
*/
|
|
59
|
+
startIcon?: ReactNode;
|
|
60
60
|
}
|
|
61
61
|
declare const TextField: FC<TextFieldProps>;
|
|
62
62
|
export default TextField;
|
|
@@ -26,13 +26,5 @@ import { Theme } from '@asgardeo/browser';
|
|
|
26
26
|
* @param hasEndIcon - Whether the component has an end icon
|
|
27
27
|
* @returns Object containing CSS class names for component styling
|
|
28
28
|
*/
|
|
29
|
-
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, hasStartIcon: boolean, hasEndIcon: boolean) =>
|
|
30
|
-
inputContainer: string;
|
|
31
|
-
input: string;
|
|
32
|
-
inputError: string;
|
|
33
|
-
inputDisabled: string;
|
|
34
|
-
icon: string;
|
|
35
|
-
startIcon: string;
|
|
36
|
-
endIcon: string;
|
|
37
|
-
};
|
|
29
|
+
declare const useStyles: (theme: Theme, colorScheme: string, disabled: boolean, hasError: boolean, hasStartIcon: boolean, hasEndIcon: boolean) => Record<string, string>;
|
|
38
30
|
export default useStyles;
|
|
@@ -19,57 +19,57 @@ import { CSSProperties, FC, ReactNode, ElementType } from 'react';
|
|
|
19
19
|
import { TypographyVariant, TypographyAlign, TypographyColor } from './Typography.styles';
|
|
20
20
|
export interface TypographyProps {
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
23
|
-
*/
|
|
24
|
-
children: ReactNode;
|
|
25
|
-
/**
|
|
26
|
-
* The typography variant to apply
|
|
22
|
+
* Text alignment
|
|
27
23
|
*/
|
|
28
|
-
|
|
24
|
+
align?: TypographyAlign;
|
|
29
25
|
/**
|
|
30
|
-
* The
|
|
26
|
+
* The content to be rendered
|
|
31
27
|
*/
|
|
32
|
-
|
|
28
|
+
children: ReactNode;
|
|
33
29
|
/**
|
|
34
|
-
*
|
|
30
|
+
* Additional CSS class names
|
|
35
31
|
*/
|
|
36
|
-
|
|
32
|
+
className?: string;
|
|
37
33
|
/**
|
|
38
34
|
* Color variant
|
|
39
35
|
*/
|
|
40
36
|
color?: TypographyColor;
|
|
41
37
|
/**
|
|
42
|
-
*
|
|
38
|
+
* The HTML element or React component to render
|
|
43
39
|
*/
|
|
44
|
-
|
|
40
|
+
component?: ElementType;
|
|
45
41
|
/**
|
|
46
|
-
*
|
|
42
|
+
* Custom font size (overrides variant sizing)
|
|
47
43
|
*/
|
|
48
|
-
|
|
44
|
+
fontSize?: string | number;
|
|
49
45
|
/**
|
|
50
|
-
* Custom
|
|
46
|
+
* Custom font weight
|
|
51
47
|
*/
|
|
52
|
-
|
|
48
|
+
fontWeight?: 'normal' | 'medium' | 'semibold' | 'bold' | number;
|
|
49
|
+
/**
|
|
50
|
+
* Whether to disable gutters (margin bottom)
|
|
51
|
+
*/
|
|
52
|
+
gutterBottom?: boolean;
|
|
53
53
|
/**
|
|
54
54
|
* Whether the text should be displayed inline
|
|
55
55
|
*/
|
|
56
56
|
inline?: boolean;
|
|
57
57
|
/**
|
|
58
|
-
*
|
|
58
|
+
* Line height
|
|
59
59
|
*/
|
|
60
|
-
|
|
60
|
+
lineHeight?: string | number;
|
|
61
61
|
/**
|
|
62
|
-
*
|
|
62
|
+
* Whether the text should be clipped with ellipsis when it overflows
|
|
63
63
|
*/
|
|
64
|
-
|
|
64
|
+
noWrap?: boolean;
|
|
65
65
|
/**
|
|
66
|
-
*
|
|
66
|
+
* Custom styles
|
|
67
67
|
*/
|
|
68
|
-
|
|
68
|
+
style?: CSSProperties;
|
|
69
69
|
/**
|
|
70
|
-
*
|
|
70
|
+
* The typography variant to apply
|
|
71
71
|
*/
|
|
72
|
-
|
|
72
|
+
variant?: TypographyVariant;
|
|
73
73
|
}
|
|
74
74
|
/**
|
|
75
75
|
* Typography component for consistent text rendering throughout the application.
|