@ttoss/react-auth 2.1.1 → 2.2.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/index.js +7 -1
- package/package.json +5 -5
package/dist/esm/index.js
CHANGED
|
@@ -928,10 +928,16 @@ var AuthLogic = () => {
|
|
|
928
928
|
}) => {
|
|
929
929
|
try {
|
|
930
930
|
setLoading(true);
|
|
931
|
-
await signIn({
|
|
931
|
+
const result = await signIn({
|
|
932
932
|
username: email,
|
|
933
933
|
password
|
|
934
934
|
});
|
|
935
|
+
if (result.nextStep.signInStep === "RESET_PASSWORD") {
|
|
936
|
+
setNotifications({
|
|
937
|
+
type: "error",
|
|
938
|
+
message: `For your security, we have updated our system and you need to reset your password in 'forgot your password?' to proceed`
|
|
939
|
+
});
|
|
940
|
+
}
|
|
935
941
|
} catch (error) {
|
|
936
942
|
switch (error.code) {
|
|
937
943
|
case "UserNotConfirmedException":
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ttoss/react-auth",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "ttoss authentication module for React apps.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "ttoss",
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"aws-amplify": "^6.0.0",
|
|
34
34
|
"react": ">=16.8.0",
|
|
35
|
+
"@ttoss/react-notifications": "^1.24.58",
|
|
35
36
|
"@ttoss/react-i18n": "^2.0.4",
|
|
36
|
-
"@ttoss/ui": "^5.0.8"
|
|
37
|
-
"@ttoss/react-notifications": "^1.24.58"
|
|
37
|
+
"@ttoss/ui": "^5.0.8"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@jest/globals": "^29.7.0",
|
|
@@ -43,11 +43,11 @@
|
|
|
43
43
|
"jest": "^29.7.0",
|
|
44
44
|
"react": "^18.3.1",
|
|
45
45
|
"tsup": "^8.3.0",
|
|
46
|
+
"@ttoss/i18n-cli": "^0.7.22",
|
|
46
47
|
"@ttoss/cloud-auth": "^0.12.22",
|
|
48
|
+
"@ttoss/react-i18n": "^2.0.4",
|
|
47
49
|
"@ttoss/config": "^1.34.1",
|
|
48
|
-
"@ttoss/i18n-cli": "^0.7.22",
|
|
49
50
|
"@ttoss/react-notifications": "^1.24.58",
|
|
50
|
-
"@ttoss/react-i18n": "^2.0.4",
|
|
51
51
|
"@ttoss/test-utils": "^2.1.17",
|
|
52
52
|
"@ttoss/ui": "^5.0.8"
|
|
53
53
|
},
|