KSN: add Supabase email/password login#10
Merged
Merged
Conversation
- `bun add @supabase/supabase-js` - `src/api/supabase.ts` creates shared client for project `kasane` - session persisted via `AsyncStorage`, `detectSessionInUrl` off - `AppState` listener pauses token refresh while backgrounded on native
- `src/state/auth.ts` zustand store: `session` + `status` (`loading` | `signedIn` | `signedOut`) - seeded from `getSession`, synced via `onAuthStateChange` - `signIn` / `signUp` / `signOut` wrap SDK, return error message or `null` - `signUp` redirects confirmation email to `/login` on the web app - `useAuthStatus` / `useAuthEmail` selector hooks - jest `moduleNameMapper` for `@/*` alias - cover store transitions and actions in `src/state/auth.test.ts`
- `app/login.tsx`: email + password form with `signIn` / `signUp` mode toggle - check-your-email state after signup, inline errors, busy spinner - signed-in account view shows email + sign out - register `login` in `_layout.tsx` `Stack`
- pill next to JP/EN toggle navigates to `/login` - shows `Sign in` signed out, email initial signed in via `useAuthEmail`
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
✅ Deploy Preview for kasane-guide ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
- 7 arcs covering all 11 chapters of Shirow's original manga - ep 1 of the airing 2026 Science SARU series mapped; chapters-only tail to extend as episodes air - 2 movies (Oshii '95 film + Innocence) - anime `177699` → manga `31023` - register in `src/data/index.ts` `ALL_MAPPINGS`
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
kasane(us-east-2) as auth backend, email+password with confirmation requiredsrc/api/supabase.tsshared client:AsyncStoragesession persistence,AppState-gated token refresh on nativesrc/state/auth.tsuseAuthzustand store synced viaonAuthStateChange;signIn/signUp/signOutreturn error message ornullapp/login.tsxsign-in / create-account form with inline errors, busy state, check-your-email state; account view + sign out when signed inGlobalHeaderaccount pill →/login(Sign insigned out, email initial signed in)moduleNameMapperfor@/*alias; auth store covered insrc/state/auth.test.tsInvalid login credentialsfrom the real projecthttps://kasane.netlify.app+/loginredirect allow-list entry