@passflow/react 0.20.0 → 0.20.2
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/CHANGELOG.md +25 -0
- package/README.md +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.es.js +133 -134
- package/dist/index.es.js.map +1 -1
- package/dist/src/components/error/index.d.ts.map +1 -1
- package/dist/src/components/flow/passflow/index.d.ts.map +1 -1
- package/dist/src/components/flow/two-factor-verify/index.d.ts.map +1 -1
- package/dist/src/components/flow/two-factor-verify/screen.d.ts.map +1 -1
- package/dist/src/components/form/forgot-password/forgot-password.d.ts.map +1 -1
- package/dist/src/components/form/invitation-join/index.d.ts.map +1 -1
- package/dist/src/components/form/reset-password/index.d.ts.map +1 -1
- package/dist/src/components/form/signed-in/index.d.cts +9 -0
- package/dist/src/components/form/signed-in/index.d.ts +9 -0
- package/dist/src/components/form/signed-in/index.d.ts.map +1 -0
- package/dist/src/components/form/signin/index.d.ts.map +1 -1
- package/dist/src/components/form/signup/index.d.ts.map +1 -1
- package/dist/src/components/form/verify-challenge/verify-challenge-magic-link.d.ts.map +1 -1
- package/dist/src/components/form/verify-challenge/verify-challenge-otp-manual.d.ts.map +1 -1
- package/dist/src/components/form/verify-challenge/verify-challenge-otp-redirect.d.ts.map +1 -1
- package/dist/src/components/provider/passflow-provider.d.ts.map +1 -1
- package/dist/src/context/navigation-context.d.cts +6 -1
- package/dist/src/context/navigation-context.d.ts +6 -1
- package/dist/src/context/navigation-context.d.ts.map +1 -1
- package/dist/src/hooks/index.d.cts +1 -0
- package/dist/src/hooks/index.d.ts +1 -0
- package/dist/src/hooks/index.d.ts.map +1 -1
- package/dist/src/hooks/use-navigation.d.cts +2 -0
- package/dist/src/hooks/use-navigation.d.ts +2 -0
- package/dist/src/hooks/use-navigation.d.ts.map +1 -1
- package/dist/src/hooks/use-sign-in-ending.d.cts +16 -0
- package/dist/src/hooks/use-sign-in-ending.d.ts +16 -0
- package/dist/src/hooks/use-sign-in-ending.d.ts.map +1 -0
- package/dist/src/utils/index.d.cts +1 -0
- package/dist/src/utils/index.d.ts +1 -0
- package/dist/src/utils/index.d.ts.map +1 -1
- package/dist/src/utils/is-sign-in-page.d.cts +5 -0
- package/dist/src/utils/is-sign-in-page.d.ts +5 -0
- package/dist/src/utils/is-sign-in-page.d.ts.map +1 -0
- package/dist/src/utils/second-factor.d.cts +15 -1
- package/dist/src/utils/second-factor.d.ts +15 -1
- package/dist/src/utils/second-factor.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/dist/src/components/form/verify-challenge/verify-challenge-success.d.cts +0 -3
- package/dist/src/components/form/verify-challenge/verify-challenge-success.d.ts +0 -3
- package/dist/src/components/form/verify-challenge/verify-challenge-success.d.ts.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,31 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@passflow/react` are documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.20.2] - 2026-11-05
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- Email link, OTP and forgot-password no longer fail to start on an app that doesn't list the server's default redirect in its redirect URLs. These calls, along with passkey sign-up and the OTP resend, now name an address only when the request gave one (`successAuthRedirect`, `successResetRedirect`).
|
|
10
|
+
- An opened email link whose answer is the sign-in page now shows "You're signed in". It used to treat that page as another address, which sent the user back to the sign-in form or showed an error.
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- With no target given, an email link, OTP or password reset now ends where the server's answer says: the app's first registered redirect URL, or the server's default if the app has none. Put the URL you want first in the list. This changes the ending for an app that lists the server's default with another URL ahead of it: users now go to that first URL. A tab waiting for its link to be approved ends on the default redirect from the app's settings.
|
|
15
|
+
- A `redirect_url` left on the sign-in, sign-up or forgot-password page URL is no longer carried into the attempt. Pass `successAuthRedirect` or `successResetRedirect` instead.
|
|
16
|
+
|
|
17
|
+
## [0.20.1] - 2026-11-05
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
|
|
21
|
+
- A federated sign-in that owes its second factor no longer ends on a bare 404 on the hosted login. The federated return carries `#tfa_token=` and no `appid`, so the provider ran app-id discovery: that held back the flow, so the landing navigated to the unprefixed `/two-factor-verify`, and it picked the default login app, under which the server refuses the token. On a page served by the API's own origin, with no app id configured, the provider now takes the app from the token's `aud` and skips discovery. It also adds `appid` to the 2FA URL, so a reload keeps the app. An `appId` prop still wins, and any other page behaves as before.
|
|
22
|
+
- A sign-in with nowhere to go now says so. When the target is the sign-in page itself, or there is no target, the user sees "You're signed in" and stays, with no tokens in the address bar, instead of landing back on the sign-in form as if it had failed. This covers sign-in, sign-up, magic link, OTP, 2FA, invitation and password reset endings, and a federated landing on the login page, with or without PKCE. Any other target still gets the redirect.
|
|
23
|
+
|
|
24
|
+
### Changed
|
|
25
|
+
|
|
26
|
+
- Validate the redirect target before completing sign-in. Sign-in now goes through `checkRedirectUrl` before it leaves for a full URL passed in `successAuthRedirect`, and an error screen appears if that fails. Add the URLs you pass to the app's redirect URLs. Requires `@passflow/core` 0.26.0 and a server with `POST /auth/redirect/check`.
|
|
27
|
+
- "Go back" on the error screen now only follows a path on the current origin. Any other target goes to `/`.
|
|
28
|
+
- The 2FA finished screen now reads "You're signed in", and the old "Successful verification! But there is no redirect URL" screen is gone.
|
|
29
|
+
|
|
5
30
|
## [0.20.0] - 2026-11-05
|
|
6
31
|
|
|
7
32
|
### Breaking
|
package/README.md
CHANGED
|
@@ -256,7 +256,7 @@ The whole sign-in experience on its own pages: sign-in, sign-up, one-time codes,
|
|
|
256
256
|
|
|
257
257
|
| Prop | Type | Description |
|
|
258
258
|
|------|------|-------------|
|
|
259
|
-
| successAuthRedirect | string | URL to redirect after successful authentication |
|
|
259
|
+
| successAuthRedirect | string | URL to redirect after successful authentication. A full URL must be in the app's redirect URLs. |
|
|
260
260
|
| federatedDisplayMode | "modal" \| "redirect" | Federated authentication display mode |
|
|
261
261
|
| pathPrefix | string | Where the flow lives, such as `/auth`. Optional: worked out from the first URL |
|
|
262
262
|
| routerType | "browser" \| "hash" \| "memory" | The history the flow keeps. Default `browser` |
|