@aws-amplify/ui 6.1.0 → 6.3.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/esm/i18n/dictionaries/authenticator/de.mjs +4 -4
- package/dist/esm/i18n/dictionaries/authenticator/th.mjs +101 -0
- package/dist/esm/i18n/dictionaries/index.mjs +3 -1
- package/dist/esm/i18n/translations.mjs +2 -1
- package/dist/esm/index.mjs +1 -0
- package/dist/esm/types/primitives/componentClassName.mjs +19 -0
- package/dist/esm/utils/humanFileSize.mjs +29 -0
- package/dist/esm/utils/setUserAgent/constants.mjs +6 -2
- package/dist/esm/utils/setUserAgent/setUserAgent.mjs +8 -1
- package/dist/index.js +165 -4
- package/dist/styles/breadcrumbs.css +2 -4
- package/dist/styles/breadcrumbs.layer.css +2 -4
- package/dist/styles/button.css +10 -19
- package/dist/styles/button.layer.css +10 -19
- package/dist/styles/input.css +2 -3
- package/dist/styles/input.layer.css +2 -3
- package/dist/styles/link.css +5 -10
- package/dist/styles/link.layer.css +5 -10
- package/dist/styles/reset.css +1 -3
- package/dist/styles/reset.layer.css +1 -3
- package/dist/styles/sliderField.css +2 -3
- package/dist/styles/sliderField.layer.css +2 -3
- package/dist/styles/textArea.css +2 -3
- package/dist/styles/textArea.layer.css +2 -3
- package/dist/styles.css +23 -42
- package/dist/styles.layer.css +23 -42
- package/dist/types/i18n/dictionaries/authenticator/index.d.ts +1 -0
- package/dist/types/i18n/dictionaries/authenticator/th.d.ts +2 -0
- package/dist/types/i18n/dictionaries/index.d.ts +52 -0
- package/dist/types/theme/components/fileUploader.d.ts +20 -0
- package/dist/types/types/primitives/componentClassName.d.ts +19 -0
- package/dist/types/utils/humanFileSize.d.ts +11 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/types/utils/setUserAgent/constants.d.ts +1 -0
- package/dist/types/utils/setUserAgent/setUserAgent.d.ts +1 -1
- package/package.json +1 -1
package/dist/styles.layer.css
CHANGED
|
@@ -1641,9 +1641,8 @@ strong.amplify-text {
|
|
|
1641
1641
|
padding-inline-start: var(--amplify-components-button-padding-inline-start);
|
|
1642
1642
|
padding-inline-end: var(--amplify-components-button-padding-inline-end);
|
|
1643
1643
|
transition: all var(--amplify-components-button-transition-duration);
|
|
1644
|
-
-
|
|
1645
|
-
|
|
1646
|
-
user-select: none;
|
|
1644
|
+
-moz-user-select: none;
|
|
1645
|
+
user-select: none;
|
|
1647
1646
|
--amplify-internal-button-disabled-color: var(
|
|
1648
1647
|
--amplify-components-button-disabled-color
|
|
1649
1648
|
);
|
|
@@ -2664,58 +2663,50 @@ strong.amplify-text {
|
|
|
2664
2663
|
background-color: var(--amplify-internal-button-disabled-background-color);
|
|
2665
2664
|
border-color: var(--amplify-internal-button-disabled-border-color);
|
|
2666
2665
|
color: var(--amplify-internal-button-disabled-color);
|
|
2667
|
-
|
|
2668
|
-
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2666
|
+
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2669
2667
|
cursor: not-allowed;
|
|
2670
2668
|
}
|
|
2671
2669
|
.amplify-button--disabled:hover {
|
|
2672
2670
|
background-color: var(--amplify-internal-button-disabled-background-color);
|
|
2673
2671
|
border-color: var(--amplify-internal-button-disabled-border-color);
|
|
2674
2672
|
color: var(--amplify-internal-button-disabled-color);
|
|
2675
|
-
|
|
2676
|
-
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2673
|
+
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2677
2674
|
}
|
|
2678
2675
|
.amplify-button--disabled :focus {
|
|
2679
2676
|
background-color: var(--amplify-internal-button-disabled-background-color);
|
|
2680
2677
|
border-color: var(--amplify-internal-button-disabled-border-color);
|
|
2681
2678
|
color: var(--amplify-internal-button-disabled-color);
|
|
2682
|
-
|
|
2683
|
-
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2679
|
+
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2684
2680
|
}
|
|
2685
2681
|
.amplify-button--disabled:active {
|
|
2686
2682
|
background-color: var(--amplify-internal-button-disabled-background-color);
|
|
2687
2683
|
border-color: var(--amplify-internal-button-disabled-border-color);
|
|
2688
2684
|
color: var(--amplify-internal-button-disabled-color);
|
|
2689
|
-
|
|
2690
|
-
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2685
|
+
text-decoration: var(--amplify-internal-button-disabled-text-decoration);
|
|
2691
2686
|
}
|
|
2692
2687
|
.amplify-button--loading {
|
|
2693
2688
|
background-color: var(--amplify-internal-button-loading-background-color);
|
|
2694
2689
|
border-color: var(--amplify-internal-button-loading-border-color);
|
|
2695
2690
|
color: var(--amplify-components-button-loading-color);
|
|
2696
|
-
|
|
2697
|
-
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2691
|
+
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2698
2692
|
}
|
|
2699
2693
|
.amplify-button--loading:hover {
|
|
2700
2694
|
background-color: var(--amplify-internal-button-loading-background-color);
|
|
2701
2695
|
border-color: var(--amplify-internal-button-loading-border-color);
|
|
2702
2696
|
color: var(--amplify-components-button-loading-color);
|
|
2703
|
-
|
|
2704
|
-
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2697
|
+
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2705
2698
|
}
|
|
2706
2699
|
.amplify-button--loading:focus {
|
|
2707
2700
|
background-color: var(--amplify-internal-button-loading-background-color);
|
|
2708
2701
|
border-color: var(--amplify-internal-button-loading-border-color);
|
|
2709
2702
|
color: var(--amplify-components-button-loading-color);
|
|
2710
|
-
|
|
2711
|
-
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2703
|
+
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2712
2704
|
}
|
|
2713
2705
|
.amplify-button--loading:active {
|
|
2714
2706
|
background-color: var(--amplify-internal-button-loading-background-color);
|
|
2715
2707
|
border-color: var(--amplify-internal-button-loading-border-color);
|
|
2716
2708
|
color: var(--amplify-components-button-loading-color);
|
|
2717
|
-
|
|
2718
|
-
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2709
|
+
text-decoration: var(--amplify-internal-button-loading-text-decoration);
|
|
2719
2710
|
}
|
|
2720
2711
|
.amplify-button__loader-wrapper {
|
|
2721
2712
|
align-items: var(--amplify-components-button-loader-wrapper-align-items);
|
|
@@ -2863,9 +2854,8 @@ strong.amplify-text {
|
|
|
2863
2854
|
outline-style: var(--amplify-components-fieldcontrol-outline-style);
|
|
2864
2855
|
outline-width: var(--amplify-components-fieldcontrol-outline-width);
|
|
2865
2856
|
outline-offset: var(--amplify-components-fieldcontrol-outline-offset);
|
|
2866
|
-
-
|
|
2867
|
-
|
|
2868
|
-
user-select: text;
|
|
2857
|
+
-moz-user-select: text;
|
|
2858
|
+
user-select: text;
|
|
2869
2859
|
display: inline-block;
|
|
2870
2860
|
--amplify-components-fieldcontrol-color: var(
|
|
2871
2861
|
--amplify-components-input-color
|
|
@@ -2948,9 +2938,8 @@ strong.amplify-text {
|
|
|
2948
2938
|
outline-style: var(--amplify-components-fieldcontrol-outline-style);
|
|
2949
2939
|
outline-width: var(--amplify-components-fieldcontrol-outline-width);
|
|
2950
2940
|
outline-offset: var(--amplify-components-fieldcontrol-outline-offset);
|
|
2951
|
-
-
|
|
2952
|
-
|
|
2953
|
-
user-select: text;
|
|
2941
|
+
-moz-user-select: text;
|
|
2942
|
+
user-select: text;
|
|
2954
2943
|
white-space: pre-wrap;
|
|
2955
2944
|
}
|
|
2956
2945
|
.amplify-textarea:focus {
|
|
@@ -3014,29 +3003,24 @@ strong.amplify-text {
|
|
|
3014
3003
|
|
|
3015
3004
|
.amplify-link {
|
|
3016
3005
|
color: var(--amplify-components-link-color);
|
|
3017
|
-
|
|
3018
|
-
text-decoration: var(--amplify-components-link-text-decoration);
|
|
3006
|
+
text-decoration: var(--amplify-components-link-text-decoration);
|
|
3019
3007
|
cursor: pointer;
|
|
3020
3008
|
}
|
|
3021
3009
|
.amplify-link:visited {
|
|
3022
3010
|
color: var(--amplify-components-link-visited-color);
|
|
3023
|
-
|
|
3024
|
-
text-decoration: var(--amplify-components-link-visited-text-decoration);
|
|
3011
|
+
text-decoration: var(--amplify-components-link-visited-text-decoration);
|
|
3025
3012
|
}
|
|
3026
3013
|
.amplify-link:active {
|
|
3027
3014
|
color: var(--amplify-components-link-active-color);
|
|
3028
|
-
|
|
3029
|
-
text-decoration: var(--amplify-components-link-active-text-decoration);
|
|
3015
|
+
text-decoration: var(--amplify-components-link-active-text-decoration);
|
|
3030
3016
|
}
|
|
3031
3017
|
.amplify-link:focus {
|
|
3032
3018
|
color: var(--amplify-components-link-focus-color);
|
|
3033
|
-
|
|
3034
|
-
text-decoration: var(--amplify-components-link-focus-text-decoration);
|
|
3019
|
+
text-decoration: var(--amplify-components-link-focus-text-decoration);
|
|
3035
3020
|
}
|
|
3036
3021
|
.amplify-link:hover {
|
|
3037
3022
|
color: var(--amplify-components-link-hover-color);
|
|
3038
|
-
|
|
3039
|
-
text-decoration: var(--amplify-components-link-hover-text-decoration);
|
|
3023
|
+
text-decoration: var(--amplify-components-link-hover-text-decoration);
|
|
3040
3024
|
}
|
|
3041
3025
|
|
|
3042
3026
|
.amplify-loader {
|
|
@@ -3467,16 +3451,14 @@ strong.amplify-text {
|
|
|
3467
3451
|
font-weight: var(--amplify-components-breadcrumbs-link-font-weight);
|
|
3468
3452
|
padding-inline: var(--amplify-components-breadcrumbs-link-padding-inline);
|
|
3469
3453
|
padding-block: var(--amplify-components-breadcrumbs-link-padding-block);
|
|
3470
|
-
|
|
3471
|
-
text-decoration: var(--amplify-components-breadcrumbs-link-text-decoration);
|
|
3454
|
+
text-decoration: var(--amplify-components-breadcrumbs-link-text-decoration);
|
|
3472
3455
|
}
|
|
3473
3456
|
|
|
3474
3457
|
.amplify-breadcrumbs__link--current {
|
|
3475
3458
|
color: var(--amplify-components-breadcrumbs-link-current-color);
|
|
3476
3459
|
font-size: var(--amplify-components-breadcrumbs-link-current-font-size);
|
|
3477
3460
|
font-weight: var(--amplify-components-breadcrumbs-link-current-font-weight);
|
|
3478
|
-
|
|
3479
|
-
text-decoration: var(--amplify-components-breadcrumbs-link-current-text-decoration);
|
|
3461
|
+
text-decoration: var(--amplify-components-breadcrumbs-link-current-text-decoration);
|
|
3480
3462
|
}
|
|
3481
3463
|
|
|
3482
3464
|
.amplify-card {
|
|
@@ -5026,9 +5008,8 @@ html[dir=rtl] .amplify-field-group__inner-start {
|
|
|
5026
5008
|
padding-block: var(--amplify-components-sliderfield-padding-block);
|
|
5027
5009
|
position: relative;
|
|
5028
5010
|
touch-action: none;
|
|
5029
|
-
-
|
|
5030
|
-
|
|
5031
|
-
user-select: none;
|
|
5011
|
+
-moz-user-select: none;
|
|
5012
|
+
user-select: none;
|
|
5032
5013
|
--amplify-internal-sliderfield-root-height: var(
|
|
5033
5014
|
--amplify-components-sliderfield-thumb-height
|
|
5034
5015
|
);
|
|
@@ -934,6 +934,58 @@ export declare const uaDict: {
|
|
|
934
934
|
"Verify Contact": string;
|
|
935
935
|
Verify: string;
|
|
936
936
|
};
|
|
937
|
+
export declare const thDict: {
|
|
938
|
+
[x: string]: string;
|
|
939
|
+
Email: string;
|
|
940
|
+
"Phone Number": string;
|
|
941
|
+
"Account recovery requires verified contact information": string;
|
|
942
|
+
"Back to Sign In": string;
|
|
943
|
+
"Change Password": string;
|
|
944
|
+
Changing: string;
|
|
945
|
+
Code: string;
|
|
946
|
+
"Confirm Password": string;
|
|
947
|
+
"Confirm Sign Up": string;
|
|
948
|
+
"Confirm SMS Code": string;
|
|
949
|
+
"Confirm TOTP Code": string;
|
|
950
|
+
Confirm: string;
|
|
951
|
+
"Confirmation Code": string;
|
|
952
|
+
Confirming: string;
|
|
953
|
+
"Create a new account": string;
|
|
954
|
+
"Create Account": string;
|
|
955
|
+
"Creating Account": string;
|
|
956
|
+
"Dismiss alert": string;
|
|
957
|
+
"Enter your code": string;
|
|
958
|
+
"Enter your Email": string;
|
|
959
|
+
"Enter your phone number": string;
|
|
960
|
+
"Enter your username": string;
|
|
961
|
+
"Forgot your password?": string;
|
|
962
|
+
"Hide password": string;
|
|
963
|
+
Loading: string;
|
|
964
|
+
"New password": string;
|
|
965
|
+
Password: string;
|
|
966
|
+
"Resend Code": string;
|
|
967
|
+
"Reset your password": string;
|
|
968
|
+
"Reset your Password": string;
|
|
969
|
+
"Send code": string;
|
|
970
|
+
"Send Code": string;
|
|
971
|
+
Sending: string;
|
|
972
|
+
"Setup TOTP": string;
|
|
973
|
+
"Show password": string;
|
|
974
|
+
"Sign in to your account": string;
|
|
975
|
+
"Sign In with Amazon": string;
|
|
976
|
+
"Sign In with Apple": string;
|
|
977
|
+
"Sign In with Facebook": string;
|
|
978
|
+
"Sign In with Google": string;
|
|
979
|
+
"Sign in": string;
|
|
980
|
+
"Sign In": string;
|
|
981
|
+
"Signing in": string;
|
|
982
|
+
Skip: string;
|
|
983
|
+
Submit: string;
|
|
984
|
+
Submitting: string;
|
|
985
|
+
Username: string;
|
|
986
|
+
"Verify Contact": string;
|
|
987
|
+
Verify: string;
|
|
988
|
+
};
|
|
937
989
|
export declare const defaultTexts: {
|
|
938
990
|
ADD_PROFILE: string;
|
|
939
991
|
ADD_WEBSITE: string;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Modifiers, ComponentStyles, Elements, ColorTheme } from './utils';
|
|
2
|
+
export type FileUploaderTheme<Required extends boolean = false> = ComponentStyles & Modifiers<ColorTheme, Required> & Elements<{
|
|
3
|
+
dropzone?: ComponentStyles & Modifiers<'active' | 'small', Required>;
|
|
4
|
+
dropzone__icon?: ComponentStyles;
|
|
5
|
+
dropzone__text?: ComponentStyles;
|
|
6
|
+
file?: ComponentStyles;
|
|
7
|
+
file__picker?: ComponentStyles;
|
|
8
|
+
file__wrapper?: ComponentStyles;
|
|
9
|
+
file__name?: ComponentStyles;
|
|
10
|
+
file__size?: ComponentStyles;
|
|
11
|
+
file__list?: ComponentStyles;
|
|
12
|
+
file__main?: ComponentStyles;
|
|
13
|
+
file__image?: ComponentStyles;
|
|
14
|
+
file__status?: ComponentStyles & Modifiers<'error' | 'success', Required>;
|
|
15
|
+
loader?: ComponentStyles;
|
|
16
|
+
previewer?: ComponentStyles;
|
|
17
|
+
previewer__text?: ComponentStyles;
|
|
18
|
+
previewer__footer?: ComponentStyles;
|
|
19
|
+
previewer__actions?: ComponentStyles;
|
|
20
|
+
}, Required>;
|
|
@@ -59,6 +59,25 @@ export declare const ComponentClassName: {
|
|
|
59
59
|
readonly FieldGroupFieldWrapper: "amplify-field-group__field-wrapper";
|
|
60
60
|
readonly Fieldset: "amplify-fieldset";
|
|
61
61
|
readonly FieldsetLegend: "amplify-fieldset__legend";
|
|
62
|
+
readonly FileUploader: "amplify-fileuploader";
|
|
63
|
+
readonly FileUploaderDropZone: "amplify-fileuploader__dropzone";
|
|
64
|
+
readonly FileUploaderDropZoneIcon: "amplify-fileuploader__dropzone__icon";
|
|
65
|
+
readonly FileUploaderDropZoneText: "amplify-fileuploader__dropzone__text";
|
|
66
|
+
readonly FileUploaderFilePicker: "amplify-fileuploader__file__picker";
|
|
67
|
+
readonly FileUploaderFile: "amplify-fileuploader__file";
|
|
68
|
+
readonly FileUploaderFileWrapper: "amplify-fileuploader__file__wrapper";
|
|
69
|
+
readonly FileUploaderFileList: "amplify-fileuploader__file__list";
|
|
70
|
+
readonly FileUploaderFileName: "amplify-fileuploader__file__name";
|
|
71
|
+
readonly FileUploaderFileSize: "amplify-fileuploader__file__size";
|
|
72
|
+
readonly FileUploaderFileInfo: "amplify-fileuploader__file__info";
|
|
73
|
+
readonly FileUploaderFileImage: "amplify-fileuploader__file__image";
|
|
74
|
+
readonly FileUploaderFileMain: "amplify-fileuploader__file__main";
|
|
75
|
+
readonly FileUploaderFileStatus: "amplify-fileuploader__file__status";
|
|
76
|
+
readonly FileUploaderLoader: "amplify-fileuploader__loader";
|
|
77
|
+
readonly FileUploaderPreviewer: "amplify-fileuploader__previewer";
|
|
78
|
+
readonly FileUploaderPreviewerText: "amplify-fileuploader__previewer__text";
|
|
79
|
+
readonly FileUploaderPreviewerActions: "amplify-fileuploader__previewer__actions";
|
|
80
|
+
readonly FileUploaderPreviewerFooter: "amplify-fileuploader__previewer__footer";
|
|
62
81
|
readonly Flex: "amplify-flex";
|
|
63
82
|
readonly Grid: "amplify-grid";
|
|
64
83
|
readonly Heading: "amplify-heading";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Format bytes as human-readable text.
|
|
3
|
+
*
|
|
4
|
+
* @param bytes Number of bytes.
|
|
5
|
+
* @param si True to use metric (SI) units, aka powers of 1000. False to use
|
|
6
|
+
* binary (IEC), aka powers of 1024.
|
|
7
|
+
* @param dp Number of decimal places to display.
|
|
8
|
+
*
|
|
9
|
+
* @return Formatted string.
|
|
10
|
+
*/
|
|
11
|
+
export declare function humanFileSize(bytes: number, si?: boolean, dp?: number): string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { AuthUserAgentInput, GeoUserAgentInput, InAppMessagingUserAgentInput, StorageUserAgentInput } from '@aws-amplify/core/internals/utils';
|
|
2
2
|
export declare const ACCOUNT_SETTINGS_INPUT_BASE: Omit<AuthUserAgentInput, 'additionalDetails'>;
|
|
3
3
|
export declare const AUTHENTICATOR_INPUT_BASE: Omit<AuthUserAgentInput, 'additionalDetails'>;
|
|
4
|
+
export declare const FILE_UPLOADER_BASE_INPUT: Omit<StorageUserAgentInput, 'additionalDetails'>;
|
|
4
5
|
export declare const IN_APP_MESSAGING_INPUT_BASE: Omit<InAppMessagingUserAgentInput, 'additionalDetails'>;
|
|
5
6
|
export declare const LOCATION_SEARCH_INPUT_BASE: Omit<GeoUserAgentInput, 'additionalDetails'>;
|
|
6
7
|
export declare const MAP_VIEW_INPUT_BASE: Omit<GeoUserAgentInput, 'additionalDetails'>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type PackageName = 'angular' | 'react' | 'react-auth' | 'react-geo' | 'react-liveness' | 'react-native' | 'react-native-auth' | 'react-notifications' | 'react-storage' | 'vue';
|
|
2
|
-
export type ComponentName = 'Authenticator' | 'ChangePassword' | 'DeleteUser' | 'FaceLivenessDetector' | 'InAppMessaging' | 'LocationSearch' | 'MapView' | 'StorageManager' | 'StorageImage';
|
|
2
|
+
export type ComponentName = 'Authenticator' | 'ChangePassword' | 'DeleteUser' | 'FaceLivenessDetector' | 'FileUploader' | 'InAppMessaging' | 'LocationSearch' | 'MapView' | 'StorageManager' | 'StorageImage';
|
|
3
3
|
export type Version = `${string}.${string}.${string}`;
|
|
4
4
|
export interface SetUserAgentOptions {
|
|
5
5
|
componentName: ComponentName;
|