Skip to content

Katana bridge flow#1166

Draft
rossgalloway wants to merge 5 commits into
mainfrom
katana-bridge-flow
Draft

Katana bridge flow#1166
rossgalloway wants to merge 5 commits into
mainfrom
katana-bridge-flow

Conversation

@rossgalloway

Copy link
Copy Markdown
Collaborator

⚠️ This is a work in progress and maybe not needed. We probably need to rework it if we want to go this route. I am leaning toward simply re-enabling enso zaps and making the slippage protection tighter. ⚠️

Summary

Add native Katana bridge support to the vault widget flow, including:

  • in-widget bridge entry for Katana vault deposits
  • Katana -> Ethereum bridge support for withdrawals
  • bridge status tracking and persistence
  • bridge recovery UI for lost local state
  • bridge status badges in the vault header

This keeps generic Enso crosschain zaps involving Katana disabled, while adding a dedicated native bridge path for supported Katana assets.

What changed

Deposit bridge flow

  • add a Katana native bridge mode to supported Katana vault deposit widgets
  • route mainnet -> Katana bridging through the native Vault Bridge flow instead of Enso
  • switch the widget title to Bridge when bridge mode is active
  • prefill the local Katana deposit after bridged funds arrive

Withdraw bridge flow

  • add a Katana native bridge mode to supported Katana vault withdraw widgets
  • support Katana -> Ethereum bridge flows for supported assets
  • make the withdraw bridge widget/title/CTA use Withdraw and Bridge
  • keep the multi-step withdraw path explicit:
    • unstake if needed
    • withdraw on Katana
    • approve bridge
    • submit bridge to Ethereum

Bridge tracking and persistence

  • persist bridge notifications in IndexedDB through the existing notifications store
  • poll hosted bridge transaction status through the Katana bridge proxy
  • track source confirmation, pending bridge, ready-to-claim, completed, and failed states
  • add baseline-balance protection for Katana-bound bridge completion so old balances do not create false positives

Recovery UX

  • add a vault-page recovery check for Katana bridge transactions on page load
  • if local notification state is lost, the vault page can still detect active / ready-to-claim bridge transactions from the hosted transactions API
  • surface recovery messaging and direct users to Katana Bridge for claim/track actions

Vault header bridge badge

  • move bridge status out of the widget body and into the Your Deposits area
  • show a compact bridge badge with status and expected duration
  • allow completed badges to be dismissed

Notes

  • Generic Katana Enso crosschain zaps remain blocked.
  • This PR adds recovery and tracking for claimable Katana -> Ethereum withdrawals, but it does not implement native in-app claiming yet.
  • Hosted bridge recovery depends on the server-side POLYGON_API_KEY used by /api/katana-bridge/transactions.

Testing

  • bun run tslint
  • bun run lint:fix
  • bunx vitest run src/components/pages/vaults/components/widget/withdraw/useWithdrawRoute.test.ts
  • bunx vitest run src/components/pages/vaults/components/widget/withdraw/withdrawStepHelpers.test.ts
  • bunx vitest run src/components/pages/vaults/components/detail/katanaBridgeRecovery.test.ts

@vercel

vercel Bot commented Apr 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
yearnfi Error Error May 16, 2026 4:08pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
yearnfi-nextjs Ignored Ignored Preview May 16, 2026 4:08pm

Request Review

@github-actions

github-actions Bot commented Apr 7, 2026

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Snapshot Warnings

⚠️: No snapshots were found for the head SHA c27cb29.
Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice.

Scanned Files

None

Base automatically changed from release/26-04-17 to main May 29, 2026 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant