Skip to content

Commit d2c62f6

Browse files
committed
chore: resolve accessibility issues
1 parent d25eb65 commit d2c62f6

File tree

1 file changed

+37
-37
lines changed
  • src/pages/[platform]/build-a-backend/auth/multi-step-sign-in

1 file changed

+37
-37
lines changed

src/pages/[platform]/build-a-backend/auth/multi-step-sign-in/index.mdx

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ Future<void> _handleSignInResult(SignInResult result) async {
8888
}
8989
}
9090
```
91-
### Confirm signin with SMS MFA
91+
## Confirm signin with SMS MFA
9292

9393
If the next step is `confirmSignInWithSmsMfaCode`, Amplify Auth has sent the user a random code over SMS and is waiting for the user to verify that code. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, pass the value to the `confirmSignIn` API.
9494

@@ -130,7 +130,7 @@ Future<void> confirmMfaUser(String mfaCode) async {
130130
}
131131
```
132132

133-
### Confirm signin with TOTP MFA
133+
## Confirm signin with TOTP MFA
134134

135135
If the next step is `confirmSignInWithTOTPCode`, you should prompt the user to enter the TOTP code from their associated authenticator app during set up. The code is a six-digit number that changes every 30 seconds. The user must enter the code before the 30-second window expires.
136136

@@ -161,7 +161,7 @@ Future<void> confirmTotpUser(String totpCode) async {
161161
}
162162
```
163163

164-
### Confirm signin with Email MFA
164+
## Confirm signin with Email MFA
165165

166166
If the next step is `confirmSignInWithEmailMfaCode`, Amplify Auth has sent the user a random code to their email address and is waiting for the user to verify that code. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, pass the value to the `confirmSignIn` API.
167167

@@ -204,7 +204,7 @@ Future<void> confirmMfaUser(String mfaCode) async {
204204
```
205205

206206

207-
### Continue signin with MFA Selection
207+
## Continue signin with MFA Selection
208208

209209
If the next step is `continueSignInWithMFASelection`, the user must select the MFA method to use. Amplify Auth currently supports SMS, TOTP, and email as MFA methods. After the user selects an MFA method, your implementation must pass the selected MFA method to Amplify Auth using `confirmSignIn` API.
210210

@@ -242,7 +242,7 @@ Future<void> _handleMfaSelection(MfaType selection) async {
242242
}
243243
```
244244

245-
### Continue signin with Email Setup
245+
## Continue signin with Email Setup
246246

247247
If the next step is `continueSignInWithEmailMfaSetup`, then the user must provide an email address to complete the sign in process. Once this value has been collected from the user, call the `confirmSignIn` API to continue.
248248

@@ -270,7 +270,7 @@ Future<void> confirmTotpUser(String emailAddress) async {
270270
}
271271
```
272272

273-
### Continue signin with TOTP Setup
273+
## Continue signin with TOTP Setup
274274

275275
If the next step is `continueSignInWithTOTPSetup`, then the user must provide a TOTP code to complete the sign in process. The step returns an associated value of type `TOTPSetupDetails` which would be used for generating TOTP. `TOTPSetupDetails` provides a helper method called `getSetupURI` that can be used to generate a URI, which can be used by native password managers for TOTP association. For example. if the URI is used on Apple platforms, it will trigger the platform's native password manager to associate TOTP with the account. For more advanced use cases, `TOTPSetupDetails` also contains the `sharedSecret` that will be used to either generate a QR code or can be manually entered into an authenticator app.
276276

@@ -303,7 +303,7 @@ Future<void> confirmTotpUser(String totpCode) async {
303303
}
304304
```
305305

306-
### Continue signin with MFA Setup Selection
306+
## Continue signin with MFA Setup Selection
307307
If the next step is `continueSignInWithMfaSetupSelection`, then the user must indicate which of the available MFA methods they would like to setup. After the user selects an MFA method to setup, your implementation must pass the selected MFA method to the `confirmSignIn` API.
308308

309309
The MFA types which are currently supported by Amplify Auth are:
@@ -340,7 +340,7 @@ Future<void> _handleMfaSelection(MfaType selection) async {
340340
}
341341
```
342342

343-
### Confirm signin with custom challenge
343+
## Confirm signin with custom challenge
344344

345345
If the next step is `confirmSignInWithCustomChallenge`, Amplify Auth is awaiting completion of a custom authentication challenge. The challenge is based on the AWS Lambda trigger you configured as part of a [custom sign in flow](/[platform]/build-a-backend/auth/customize-auth-lifecycle/custom-auth-flows/#sign-in-a-user).
346346

@@ -382,7 +382,7 @@ If `failAuthentication=true` is returned by the Lambda, Cognito will invalidate
382382

383383
</Callout>
384384

385-
### Confirm signin with new password
385+
## Confirm signin with new password
386386
If the next step is `confirmSignInWithNewPassword`, Amplify Auth requires the user choose a new password they proceeding with the sign in.
387387

388388
Prompt the user for a new password and pass it to the `confirmSignIn` API.
@@ -411,7 +411,7 @@ Future<void> confirmNewPassword(String newPassword) async {
411411
}
412412
```
413413

414-
### Reset password
414+
## Reset password
415415
If the next step is `resetPassword`, Amplify Auth requires that the user reset their password before proceeding.
416416
Use the `resetPassword` API to guide the user through resetting their password, then call `Amplify.Auth.signIn`
417417
when that's complete to restart the sign-in flow.
@@ -448,7 +448,7 @@ void _handleCodeDelivery(AuthCodeDeliveryDetails codeDeliveryDetails) {
448448
);
449449
}
450450
```
451-
### Confirm Signup
451+
## Confirm Signup
452452
If the next step is `resetPassword`, Amplify Auth requires that the user confirm their email or phone number before proceeding.
453453
Use the `resendSignUpCode` API to send a new sign up code to the registered email or phone number, followed by `confirmSignUp`
454454
to complete the sign up.
@@ -502,7 +502,7 @@ Future<void> confirmSignUp({
502502

503503
Once the sign up is confirmed, call `Amplify.Auth.signIn` again to restart the sign-in flow.
504504

505-
### Done
505+
## Done
506506

507507
The sign-in flow is complete when the next step is `done`, which means the user is successfully authenticated.
508508
As a convenience, the `SignInResult` also provides the `isSignedIn` property, which will be true if the next step is `done`.
@@ -929,7 +929,7 @@ RxAmplify.Auth.signIn("username", "password", options).subscribe(
929929

930930
</BlockSwitcher>
931931

932-
### Confirm signin with SMS MFA
932+
## Confirm signin with SMS MFA
933933

934934
If the next step is `CONFIRM_SIGN_IN_WITH_SMS_MFA_CODE`, Amplify Auth has sent the user a random code over SMS, and is waiting to find out if the user successfully received it. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, your implementation must pass the value to Amplify Auth `confirmSignIn` API.
935935

@@ -1029,38 +1029,38 @@ RxAmplify.Auth.confirmSignIn(
10291029

10301030
</BlockSwitcher>
10311031

1032-
### Confirm signin with TOTP MFA
1032+
## Confirm signin with TOTP MFA
10331033

10341034
If the next step is `CONFIRM_SIGN_IN_WITH_TOTP_CODE`, you should prompt the user to enter the TOTP code from their associated authenticator app during set up. The code is a six-digit number that changes every 30 seconds. The user must enter the code before the 30-second window expires.
10351035

10361036
After the user enters the code, your implementation must pass the value to Amplify Auth `confirmSignIn` API.
10371037

1038-
### Confirm signin with Email MFA
1038+
## Confirm signin with Email MFA
10391039

10401040
If the next step is `CONFIRM_SIGN_IN_WITH_EMAIL_MFA_CODE`, Amplify Auth has sent the user a random code to their email address and is waiting to find out if the user successfully received it. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, your implementation must pass the value to Amplify Auth `confirmSignIn` API.
10411041

10421042
Note: the signIn result also includes an `AuthCodeDeliveryDetails` member. It includes additional information about the code delivery such as the partial email address of the recipient.
10431043

1044-
### Continue signin with MFA Selection
1044+
## Continue signin with MFA Selection
10451045

10461046
If the next step is `CONTINUE_SIGN_IN_WITH_MFA_SELECTION`, the user must select the MFA method to use. Amplify Auth currently supports SMS, TOTP, and email as MFA methods. After the user selects an MFA method, your implementation must pass the selected MFA method to Amplify Auth using `confirmSignIn` API.
10471047

1048-
### Continue signin with Email Setup
1048+
## Continue signin with Email Setup
10491049

10501050
If the next step is `CONTINUE_SIGN_IN_WITH_EMAIL_MFA_SETUP`, then the user must provide an email address to complete the sign in process. Once this value has been collected from the user, call the `confirmSignIn` API to continue.
10511051

1052-
### Continue signin with TOTP Setup
1052+
## Continue signin with TOTP Setup
10531053

10541054
If the next step is `CONTINUE_SIGN_IN_WITH_TOTP_SETUP`, then the user must provide a TOTP code to complete the sign in process. The step returns an associated value of type `TOTPSetupDetails` which would be used for generating TOTP. `TOTPSetupDetails` provides a helper method called `getSetupURI` that can be used to generate a URI, which can be used by native password managers for TOTP association. For example. if the URI is used on Apple platforms, it will trigger the platform's native password manager to associate TOTP with the account. For more advanced use cases, `TOTPSetupDetails` also contains the `sharedSecret` that will be used to either generate a QR code or can be manually entered into an authenticator app.
10551055

10561056
Once the authenticator app is set up, the user can generate a TOTP code and provide it to the library to complete the sign in process.
10571057

1058-
### Continue signin with MFA Setup Selection
1058+
## Continue signin with MFA Setup Selection
10591059

10601060
If the next step is `CONTINUE_SIGN_IN_WITH_MFA_SETUP_SELECTION`, the user must select the MFA method to setup. Amplify Auth currently supports SMS, TOTP, and email as MFA methods. After the user selects an MFA method, your implementation must pass the selected MFA method to Amplify Auth using `confirmSignIn` API.
10611061

10621062

1063-
### Confirm signin with custom challenge
1063+
## Confirm signin with custom challenge
10641064

10651065
If the next step is `CONFIRM_SIGN_IN_WITH_CUSTOM_CHALLENGE`, Amplify Auth is awaiting completion of a custom authentication challenge. The challenge is based on the Lambda trigger you setup when you configured a [custom sign in flow](/[platform]/build-a-backend/auth/customize-auth-lifecycle/custom-auth-flows/#sign-in-a-user). To complete this step, you should prompt the user for the custom challenge answer, and pass the answer to the `confirmSignIn` API.
10661066

@@ -1174,7 +1174,7 @@ NotAuthorizedException{message=Failed since user is not authorized., cause=NotAu
11741174

11751175
</Callout>
11761176

1177-
### Confirm signin with new password
1177+
## Confirm signin with new password
11781178
If you receive a `UserNotConfirmedException` while signing in, Amplify Auth requires a new password for the user before they can proceed. Prompt the user for a new password and pass it to the `confirmSignIn` API.
11791179

11801180
<BlockSwitcher>
@@ -1265,7 +1265,7 @@ RxAmplify.Auth.confirmSignIn(
12651265

12661266
</BlockSwitcher>
12671267

1268-
### Reset password
1268+
## Reset password
12691269
If you receive `PasswordResetRequiredException`, authentication flow could not proceed without resetting the password. The next step is to invoke `resetPassword` api and follow the reset password flow.
12701270
<BlockSwitcher>
12711271

@@ -1327,7 +1327,7 @@ RxAmplify.Auth.resetPassword(
13271327

13281328
</BlockSwitcher>
13291329

1330-
### Confirm Signup
1330+
## Confirm Signup
13311331

13321332
If you receive `CONFIRM_SIGN_UP` as a next step, sign up could not proceed without confirming user information such as email or phone number. The next step is to invoke the `confirmSignUp` API and follow the confirm signup flow.
13331333

@@ -1397,7 +1397,7 @@ RxAmplify.Auth.confirmSignUp(
13971397

13981398
</BlockSwitcher>
13991399

1400-
### Get Current User
1400+
## Get Current User
14011401

14021402
This call fetches the current logged in user and should be used after a user has been successfully signed in.
14031403
If the user is signed in, it will return the current userId and username.
@@ -1453,7 +1453,7 @@ try {
14531453

14541454
</BlockSwitcher>
14551455

1456-
### Done
1456+
## Done
14571457

14581458
Sign In flow is complete when you get `done`. This means the user is successfully authenticated. As a convenience, the SignInResult also provides the `isSignedIn` property, which will be true if the next step is `done`.
14591459

@@ -1571,7 +1571,7 @@ func signIn(username: String, password: String) async {
15711571
15721572
The `nextStep` property is of enum type `AuthSignInStep`. Depending on its value, your code should take one of the following actions:
15731573
1574-
### Confirm signin with SMS MFA
1574+
## Confirm signin with SMS MFA
15751575
If the next step is `confirmSignInWithSMSMFACode`, Amplify Auth has sent the user a random code over SMS, and is waiting to find out if the user successfully received it. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, your implementation must pass the value to Amplify Auth `confirmSignIn` API.
15761576

15771577
Note: the signin result also includes an `AuthCodeDeliveryDetails` member. It includes additional information about the code delivery such as the partial phone number of the SMS recipient.
@@ -1632,7 +1632,7 @@ func confirmSignIn(confirmationCodeFromUser: String) -> AnyCancellable {
16321632

16331633
</BlockSwitcher>
16341634

1635-
### Confirm signin with TOTP MFA
1635+
## Confirm signin with TOTP MFA
16361636

16371637
If the next step is `confirmSignInWithTOTPCode`, you should prompt the user to enter the TOTP code from their associated authenticator app during set up. The code is a six-digit number that changes every 30 seconds. The user must enter the code before the 30-second window expires.
16381638

@@ -1692,7 +1692,7 @@ func confirmSignIn(totpCode: String) -> AnyCancellable {
16921692

16931693
</BlockSwitcher>
16941694

1695-
### Confirm signin with Email MFA
1695+
## Confirm signin with Email MFA
16961696
If the next step is `confirmSignInWithEmailMFACode`, Amplify Auth has sent a random code to the user's email address, and is waiting to find out if the user successfully received it. To handle this step, your app's UI must prompt the user to enter the code. After the user enters the code, your implementation must pass the value to Amplify Auth `confirmSignIn` API.
16971697

16981698
Note: the signin result also includes an `AuthCodeDeliveryDetails` member. It includes additional information about the code delivery such as the partial email address of the recipient.
@@ -1754,7 +1754,7 @@ func confirmSignIn(confirmationCodeFromUser: String) -> AnyCancellable {
17541754
</BlockSwitcher>
17551755

17561756

1757-
### Continue signin with MFA Selection
1757+
## Continue signin with MFA Selection
17581758

17591759
If the next step is `continueSignInWithMFASelection`, the user must select the MFA method to use. Amplify Auth currently supports SMS, TOTP, and email as MFA methods. After the user selects an MFA method, your implementation must pass the selected MFA method to Amplify Auth using `confirmSignIn` API.
17601760

@@ -1804,7 +1804,7 @@ func confirmSignInWithTOTPAsMFASelection() -> AnyCancellable {
18041804

18051805
</BlockSwitcher>
18061806

1807-
### Continue signin with Email Setup
1807+
## Continue signin with Email Setup
18081808
If the next step is `continueSignInWithEmailMFASetup`, then the user must provide an email address to complete the sign in process. Once this value has been collected from the user, call the `confirmSignIn` API to continue.
18091809

18101810
```swift
@@ -1816,7 +1816,7 @@ case .continueSignInWithEmailMFASetup:
18161816
// Then invoke `confirmSignIn` api with the email address
18171817
```
18181818

1819-
### Continue signin with TOTP Setup
1819+
## Continue signin with TOTP Setup
18201820

18211821
If the next step is `continueSignInWithTOTPSetup`, then the user must provide a TOTP code to complete the sign in process. The step returns an associated value of type `TOTPSetupDetails` which would be used for generating TOTP. `TOTPSetupDetails` provides a helper method called `getSetupURI` that can be used to generate a URI, which can be used by native password managers for TOTP association. For example. if the URI is used on Apple platforms, it will trigger the platform's native password manager to associate TOTP with the account. For more advanced use cases, `TOTPSetupDetails` also contains the `sharedSecret` that will be used to either generate a QR code or can be manually entered into an authenticator app.
18221822
@@ -1890,7 +1890,7 @@ func confirmSignInWithTOTPSetup(totpCodeFromAuthenticatorApp: String) -> AnyCanc
18901890
</BlockSwitcher>
18911891
18921892
1893-
### Continue signin with MFA Setup Selection
1893+
## Continue signin with MFA Setup Selection
18941894
18951895
If the next step is `continueSignInWithMFASetupSelection`, the user must indicate which of the available MFA methods they would like to setup. After the user selects an MFA method to setup, your implementation must pass the selected MFA method to the `confirmSignIn` API.
18961896
@@ -1940,7 +1940,7 @@ func continueSignInWithEmailMFASetupSelection() -> AnyCancellable {
19401940
19411941
</BlockSwitcher>
19421942
1943-
### Confirm signin with custom challenge
1943+
## Confirm signin with custom challenge
19441944
19451945
If the next step is `confirmSignInWithCustomChallenge`, Amplify Auth is awaiting completion of a custom authentication challenge. The challenge is based on the Lambda trigger you setup when you configured a [custom sign in flow](/[platform]/build-a-backend/auth/customize-auth-lifecycle/custom-auth-flows/#sign-in-a-user). To complete this step, you should prompt the user for the custom challenge answer, and pass the answer to the `confirmSignIn` API.
19461946
@@ -2011,7 +2011,7 @@ Exception: notAuthorized{message=Failed since user is not authorized., cause=No
20112011
20122012
</Callout>
20132013
2014-
### Confirm signin with new password
2014+
## Confirm signin with new password
20152015
20162016
If the next step is `confirmSignInWithNewPassword`, Amplify Auth requires a new password for the user before they can proceed. Prompt the user for a new password and pass it to the `confirmSignIn` API.
20172017
@@ -2071,7 +2071,7 @@ func confirmSignIn(newPasswordFromUser: String) -> AnyCancellable {
20712071
20722072
</BlockSwitcher>
20732073
2074-
### Reset password
2074+
## Reset password
20752075
20762076
If you receive `resetPassword`, authentication flow could not proceed without resetting the password. The next step is to invoke `resetPassword` api and follow the reset password flow.
20772077
@@ -2117,7 +2117,7 @@ func resetPassword(username: String) -> AnyCancellable {
21172117
21182118
</BlockSwitcher>
21192119
2120-
### Confirm Signup
2120+
## Confirm Signup
21212121
21222122
If you receive `confirmSignUp` as a next step, sign up could not proceed without confirming user information such as email or phone number. The next step is to invoke the `confirmSignUp` API and follow the confirm signup flow.
21232123
@@ -2164,7 +2164,7 @@ func confirmSignUp(for username: String, with confirmationCode: String) -> AnyCa
21642164
21652165
</BlockSwitcher>
21662166
2167-
### Done
2167+
## Done
21682168
21692169
Signin flow is complete when you get `done`. This means the user is successfully authenticated. As a convenience, the SignInResult also provides the `isSignedIn` property, which will be true if the next step is `done`.
21702170
</InlineFilter>

0 commit comments

Comments
 (0)