Skip to content

Commit 5d8cae4

Browse files
committed
Prettier
1 parent 3171863 commit 5d8cae4

13 files changed

Lines changed: 47 additions & 40 deletions

File tree

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ dist
66
.yalc
77
.github
88
.vercel
9+
.next
910

1011
docs
1112

packages/react/TODO-observe-integration.md

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,53 +5,62 @@ All planned phases have been implemented. This document now reflects the final s
55
## What was implemented
66

77
### Flow-level events (ProcessHandler)
8+
89
- [x] `loginVisible` — fires when LoginInitBlock first becomes primary
910
- [x] `loginFinish` — fires in onProcessCompleted when authType === Login
1011
- [x] `signupVisible` — fires when SignupInitBlock first becomes primary
1112
- [x] `signupFinish` — fires in onProcessCompleted when authType === Signup
1213
- [x] `loginReset` — fires when LoginInitBlock becomes primary again (after being away)
1314

1415
### Social login (LoginInitBlock + SignupInitBlock)
16+
1517
- [x] `socialLoginStart` — fires before startSocialVerification API call
1618
- [x] `socialLoginFinish` — fires when finishSocialVerification succeeds
1719
- [x] `socialLoginError` — fires when finishSocialVerification fails
1820

1921
### Identifier tracking (LoginInitBlock + SignupInitBlock + React components)
22+
2023
- [x] `provideIdentifierStartable` — created via tracker in LoginForm.tsx / SignupInit.tsx with DOM ref
2124
- [x] `provideIdentifierSubmitted` — fires in start() / updateUserData() before API call
2225
- [x] `provideIdentifierFinished` — fires on successful API response
2326
- [x] `provideIdentifierError` — fires on failed API response
2427
- [x] Input field instrumentation (auto-detect first character, paste, CUI via PatternDetector)
2528

2629
### Login methods decision (LoginInit + PasskeyError screens)
30+
2731
- [x] `loginMethodsDecisionOffered` — fires in LoginInit.tsx, PasskeyError.tsx, PasskeyErrorLight.tsx
2832

2933
### Email OTP (EmailVerifyBlock)
34+
3035
- [x] `emailOTPStartable` — fires when block is created with verificationMethod === 'email-otp'
3136
- [x] `emailOTPSubmitted` — fires in validateCode() before API call
3237
- [x] `emailOTPFinished` — fires on successful validation
3338
- [x] `emailOTPError` — fires on failed validation
3439
- [x] `emailOTPResent` — fires on successful resend
3540

3641
### Email Link (EmailVerifyBlock)
42+
3743
- [x] `emailLinkStartable` — fires when block is created with verificationMethod === 'email-link'
3844
- [x] `emailLinkSubmitted` — fires in validateEmailLink() before API call
3945
- [x] `emailLinkFinished` — fires on successful link validation
4046
- [x] `emailLinkError` — fires on failed link validation
4147

4248
### web-core changes (B1 fix)
49+
4350
- [x] `loginWithPasskey()` — added `onCeremonyData` callback exposing assertionOptions + assertionResponse
4451
- [x] `loginWithPasskeyChallenge()` — extended `onAuthenticatorCompleted` to pass assertionOptions + assertionResponse
4552
- [x] `appendPasskey()` — added `onCeremonyData` callback exposing attestationOptions + attestationResponse
4653

4754
### Passkey login (PasskeyVerifyBlock + LoginInitBlock conditional UI)
55+
4856
- [x] `passkeyLoginStart` — fires via onCeremonyData callback with assertionOptions
4957
- [x] `passkey.submitted` — fires with assertionResponse
5058
- [x] `passkey.finished` — fires on successful login
5159
- [x] `passkey.clientError` / `passkey.serverErrorUnknown` — fires on failure
5260
- [x] Conditional UI tracking — `conditionalUIStartable`, `conditionalUISubmitted`, `conditionalUIFinished`, `conditionalUIClientError` in LoginInitBlock
5361

5462
### Passkey enrollment (PasskeyAppendBlock)
63+
5564
- [x] `passkeyEnrollmentStartable` — fires when block is initialized
5665
- [x] `passkey_enrollment.started` — fires via onCeremonyData with attestationOptions
5766
- [x] `passkey_enrollment.submitted` — fires with attestationResponse
@@ -71,9 +80,9 @@ All planned phases have been implemented. This document now reflects the final s
7180

7281
## Remaining gaps (future work)
7382

74-
| Gap | Description |
75-
|-----|-------------|
76-
| Phone OTP events | No `phoneOTP*` events in observe SDK |
77-
| Missing fields events | No tracking for the "complete your profile" step |
78-
| Phone identifier instrumentation | `provideIdentifierStartable` assumes text input |
79-
| Password events | No password login events tracked (not present in complete SDK) |
83+
| Gap | Description |
84+
| -------------------------------- | -------------------------------------------------------------- |
85+
| Phone OTP events | No `phoneOTP*` events in observe SDK |
86+
| Missing fields events | No tracking for the "complete your profile" step |
87+
| Phone identifier instrumentation | `provideIdentifierStartable` assumes text input |
88+
| Password events | No password login events tracked (not present in complete SDK) |

packages/react/src/shared-ui/flowHandler/blocks/PasskeyAppendBlock.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ export class PasskeyAppendBlock extends Block<BlockDataPasskeyAppend> {
123123
attestationOptions: '',
124124
} as PasskeyEnrollmentStarted);
125125

126-
const res = await this.app.authProcessService.appendPasskey((data) => {
126+
const res = await this.app.authProcessService.appendPasskey(data => {
127127
this.#enrollmentOp?.submitted({
128128
conditional: false,
129129
auto: this.data.autoSubmit,

packages/react/src/shared-ui/flowHandler/blocks/PasskeyVerifyBlock.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export class PasskeyVerifyBlock extends Block<BlockDataPasskeyVerify> {
9696
assertionOptions: '',
9797
} as PasskeyLoginStart);
9898

99-
const res = await this.app.authProcessService.loginWithPasskey((data) => {
99+
const res = await this.app.authProcessService.loginWithPasskey(data => {
100100
this.#passkeyLoginOp?.submitted({ assertionResponse: data.assertionResponse });
101101
});
102102

packages/tests-e2e/src/complete/scenarios/observe/lists-of-tests.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# Observe integration into complete
22

3-
- [ ] merge shared-ui package into react packge
4-
- [ ] integrate observe login and signup flows
5-
- [ ] manual testing using local react demo
6-
- [ ] validate all login methods locally (manual testing)
3+
- [ ] merge shared-ui package into react packge
4+
- [ ] integrate observe login and signup flows
5+
- [ ] manual testing using local react demo
6+
- [ ] validate all login methods locally (manual testing)
77

88
## 2 Login methods testing
99

1010
| **type** | **scenario** | preconditions | **status** |
11-
|----------------------------------------------------|------------------------------------------------------------------------------------|--------------------------------------------------|------------|
11+
| -------------------------------------------------- | ---------------------------------------------------------------------------------- | ------------------------------------------------ | ---------- |
1212
| passkey-cui | successful | confirmed_user_with_pk | |
1313
| | successful after cancelled | confirmed_user_with_pk | |
1414
| | successful after pk_deleted | confirmed_user_with_server_deleted_pk | |
@@ -43,7 +43,7 @@
4343
## 3 Enrollment testing
4444

4545
| **type** | **scenario** | preconditions | **status** |
46-
|----------|-----------------------------------------------|---------------------------------------|------------|
46+
| -------- | --------------------------------------------- | ------------------------------------- | ---------- |
4747
| passkey | successful (conditional) | - | |
4848
| | successful (auto) | - | |
4949
| | successful (manual) | - | |

packages/tests-e2e/src/complete/scenarios/observe/passkey-button.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ test.describe('observe: passkey-button', () => {
139139
await preparePasskeyButtonState(email, model);
140140

141141
await model.loginInit.removePasskeyButton();
142-
142+
143143
await model.loginInit.fillEmailUsername(email);
144144
await model.loginInit.submitPrimary();
145145
await model.expectScreen(ScreenNames.End);

packages/tests-e2e/src/complete/utils/observe.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,3 @@ export function getObserveProjectId(): string {
55
}
66
return projectId;
77
}
8-

playground/react/app/api/test/users/passkeys/route.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,7 @@ export async function PATCH(req: NextRequest) {
2828
attestationResponse: string;
2929
};
3030
if (!body.userID || !body.processID || !body.trackingID || !body.attestationResponse) {
31-
return Response.json(
32-
{ error: 'userID, processID, trackingID and attestationResponse required' },
33-
{ status: 400 },
34-
);
31+
return Response.json({ error: 'userID, processID, trackingID and attestationResponse required' }, { status: 400 });
3532
}
3633

3734
await finishPasskeyForUser(body.userID, body.processID, body.trackingID, body.attestationResponse);

playground/react/app/api/test/users/route.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
import { NextRequest } from 'next/server';
2-
import { createUserWithPrecondition, listSessionUsers, removeUser } from '../../../../src/server/test-tools/users-service';
2+
import {
3+
createUserWithPrecondition,
4+
listSessionUsers,
5+
removeUser,
6+
} from '../../../../src/server/test-tools/users-service';
37
import type { PreconditionType } from '../../../../src/tools/types';
48

59
export const runtime = 'nodejs';

playground/react/next-env.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3-
import "./.next/types/routes.d.ts";
3+
import './.next/types/routes.d.ts';
44

55
// NOTE: This file should not be edited
66
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

0 commit comments

Comments
 (0)