Skip to content

fix(governance): use vault chain for vote-lock logos - #1092

Merged
lcamargof merged 2 commits into
masterfrom
fix/vote-lock-vault-chain
Aug 20, 2026
Merged

fix(governance): use vault chain for vote-lock logos#1092
lcamargof merged 2 commits into
masterfrom
fix/vote-lock-vault-chain

Conversation

@reserve-hermes

@reserve-hermes reserve-hermes commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Summary

  • resolve the vote-lock token logo from the vault's chain instead of the page/global chain
  • use the same vault chain for underlying and reward-token logo resolution

Root cause

The governance sidebar passed the global page chain to TokenLogo. Cross-chain AI DTFs can be displayed on Ethereum while their vlRSR vault is on BNB Chain, so the logo lookup used the wrong chain identity.

Verification

  • pnpm exec oxlint src/views/index-dtf/governance/components/governance-vote-lock.tsx
  • pnpm typecheck
  • prior full branch verification: 896 unit tests passed; 72 E2E helper tests passed; smoke suite 58 passed, 1 skipped
  • independent review: pass, no findings

Engineer review required: this changes the chain identity used by the governance vote-lock UI.

@coderabbitai

coderabbitai Bot commented Aug 19, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: e8ebad55-ca0a-486f-b855-c26a33edd32d

📥 Commits

Reviewing files that changed from the base of the PR and between 4786396 and 232045d.

📒 Files selected for processing (2)
  • src/views/index-dtf/governance/components/governance-vote-lock.tsx
  • src/views/index-dtf/governance/components/tests/governance-vote-lock-chain.test.tsx

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The vote-lock component now uses indexDTF.stToken.chainId for reward-token data and token logos. A new test suite verifies the chain ID passed to vote-lock, underlying, and reward-token logos.

Changes

Governance vote-lock chain identity

Layer / File(s) Summary
Chain identity wiring and validation
src/views/index-dtf/governance/components/governance-vote-lock.tsx, src/views/index-dtf/governance/components/tests/governance-vote-lock-chain.test.tsx
Reward-token data and token logos now use indexDTF.stToken.chainId. Tests verify the chain ID for vlRSR, RSR, ONE, and TWO logos.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: ⚪ Minimal · up to 23204

The governance vote-lock UI now resolves token logos using the vault’s chain, correcting cross-chain displays while preserving same-chain behavior. No actionable merge-blocking risk remains beyond normal checks and review.

Suggested reviewers: lcamargof, wistec-bisrum

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: using the vault chain for governance vote-lock logos.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/vote-lock-vault-chain

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 19, 2026

Copy link
Copy Markdown

Deploying register-app with  Cloudflare Pages  Cloudflare Pages

Latest commit: 7f390c5
Status: ✅  Deploy successful!
Preview URL: https://0144d0b3.register-app.pages.dev
Branch Preview URL: https://fix-vote-lock-vault-chain.register-app.pages.dev

View logs

@lcamargof lcamargof left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@lcamargof
lcamargof merged commit 8111fd8 into master Aug 20, 2026
5 checks passed
@lcamargof
lcamargof deleted the fix/vote-lock-vault-chain branch August 20, 2026 18:06
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.

2 participants