mobile: implement onboarding create flow (backlog #25) - #583
mobile: implement onboarding create flow (backlog #25)#583popdadyrisky wants to merge 8 commits into
Conversation
…mobile create flow
|
@popdadyrisky is attempting to deploy a commit to the miracle656's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@popdadyrisky Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
Thanks! One thing to reconcile before this lands: |
|
Thanks @popdadyrisky — nice onboarding UX. Blocker: this is written for the web runtime and won't run on React Native as-is — it uses #594 just landed the correct native pattern — please rebuild on top of it:
Happy to help scope it. |
|
Apologies for the month this waited — that is on us. Reviewed it against current Nothing routes to this screen. The onboarding folder currently holds only // app/(onboarding)/welcome.tsx:51
const handleCreate = async () => {
await AsyncStorage.setItem(SEEN_WELCOME_KEY, '1');
router.push('/create-wallet');
};
Which is the intent?
Either is fine; what cannot land is a screen with no way in. We have had that pattern bite twice recently — most recently a hook that was added but never mounted, so the feature it described never ran. If you would rather not carry this forward after the delay, that is completely fair. Not closing it either way. If option 1 is the intent and you want me to check the two screens against each other and tell you what |
|
I've been going through every open PR now that the wave has closed, fixing things myself where a PR needed work rather than leaving it to sit. I can't do that here, and I'd rather explain exactly why than leave this quietly open. This is a Next.js page committed into the React Native app.
It does not compile. And fixing the imports would not be enough. The file has 76 web elements — At that point it is not a rebase, it is writing the screen again — and mobile onboarding already exists at I've left this open rather than closing it, so it stays on the record. What would make this mergeable, if you want to take it further: port the flow against For what it's worth, the flow is sensible — the |
|
I've been reworking every open PR myself now that the wave has closed, rather than leaving them to sit. I couldn't land this one, and I want to show you exactly what I hit rather than leave it quietly open. The work itself is careful. The parts I'd single out: the fee payer is derived and shown before deploy, so a user whose Friendbot call fails can fund it by hand instead of being stuck; the secret QR is opt-in behind a confirmation modal rather than rendered by default; and What stopped me: this is the web page, in the mobile app's folderThe file lands at import { useRouter } from 'next/navigation'
import { trackWalletCreated } from '@/lib/supabase'
import { QRCodeCanvas } from 'qrcode.react'
localStorage.getItem('invisible_wallet_key_id')
sessionStorage.setItem('veil_signer_secret', signerSecret)
const out = document.createElement('canvas')
<div className="min-h-screen flex flex-col items-center justify-center p-6">React Native has no It's also unreachable: Why I can't just port itMobile already has this flow — The fee payer comes from the passkey's WebAuthn PRF output, not from the credential ID. That difference decides whether the wallet is recoverable. A credential ID is a public handle — it's returned by the authenticator and stored in the clear, so anyone who reads it can re-derive the fee-payer secret from it. The PRF output is a secret only the authenticator can produce, and only for the right user. Secrets go to the secure store, not to storage the OS can read. So porting this would mean rewriting all 439 lines against React Native APIs, and landing on a screen that does less than the one already shipped. That's not a rework I can do honestly on your behalf. What I'd genuinely like from itOne idea here is better than what's on If you want to take that further as a small mobile-native PR against I've left this open rather than closing it, so it stays on the record. And to be clear about where the mismatch came from: #453 didn't say which app it targeted, and the web onboarding page is the obvious reference implementation to work from. That's on the issue, not on you. |
Implement mobile onboarding create flow that:
Registers a WebAuthn passkey via the Invisible Wallet SDK
Derives a deterministic fee-payer Keypair from the passkey credential ID (HKDF → Ed25519)
Funds the fee-payer via Friendbot (testnet) or verifies mainnet funding
Deploys the wallet contract through the factory using wallet.deploy()
Writes session state (invisible_wallet_address, veil_signer_secret) to sessionStorage and navigates to /dashboard
Files:
frontend/mobile/app/(onboarding)/create.tsx
Acceptance:
WebAuthn credential created → wallet contract deployed → session set → dashboard landing (see QA steps)
Notes:
The mobile flow keeps the signer secret ephemeral until after deploy (opt-in reveal). Web onboarding persists the secret prior to deploy; consider aligning behavior if desired.
closes #453