Skip to content

feat: MUSD-455 bring back claim section on asset details screen#27567

Merged
Matt561 merged 10 commits into
mainfrom
feat/musd-455-bring-back-claim-section-on-asset-details-screen
Mar 19, 2026
Merged

feat: MUSD-455 bring back claim section on asset details screen#27567
Matt561 merged 10 commits into
mainfrom
feat/musd-455-bring-back-claim-section-on-asset-details-screen

Conversation

@Matt561
Copy link
Copy Markdown
Contributor

@Matt561 Matt561 commented Mar 17, 2026

Description

This PR brings back the mUSD bonus claim section displayed on the asset overview screen. It was previously removed as part of this PR.

Changelog

CHANGELOG entry: Restored mUSD claimable bonus claim section on asset overview screen

Related issues

Fixes: MUSD-455: Bring back claim section on asset details screen

Manual testing steps

Feature: mUSD claimable bonus on asset overview

  Scenario: user views and claims their mUSD bonus
    Given user has claimable Merkl rewards above the minimum threshold

    When user navigates to the mUSD asset details screen
    Then a claim bonus section is displayed with the claimable amount

    When user taps "Claim"
    Then the claim confirmation bottom sheet appears
    Then the "Claim" button is guarded against repeated clicks after the first

Screenshots/Recordings

Before

Bonus claim section wasn't rendered on the asset overview screen.

After

Screen.Recording.2026-03-17.at.5.33.54.PM.mov

Notes

  • Fixed an edge case where the Claim button press-guard could get stuck if claimRewards() exits early (e.g. missing selected account or Linea network client id), causing subsequent taps to be ignored.

Note

Medium Risk
Adds a new claim CTA into the token details render path and wires it to rewards-claiming hooks, analytics, and external linking; this could impact performance (hook execution for many assets) and claim UX if gating/chain selection is wrong.

Overview
Restores an mUSD “Claimable bonus” section on the asset details screen, showing the user’s claimable amount and a Claim button that triggers useMerklBonusClaim’s claim flow and disables/rejects repeated presses while a claim is in flight/pending.

Adds an info tooltip with a link to Terms of Use (with new analytics location), plus new i18n strings and test IDs to support UI copy, tracking, and E2E automation.

Written by Cursor Bugbot for commit 0d81e8f. This will update automatically on new commits. Configure here.

Open in Web Open in Cursor 

@Matt561 Matt561 requested review from a team as code owners March 17, 2026 21:50
@Matt561 Matt561 added No QA Needed Apply this label when your PR does not need any QA effort. team-earn labels Mar 17, 2026
@github-actions
Copy link
Copy Markdown
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@Matt561 Matt561 force-pushed the feat/musd-455-bring-back-claim-section-on-asset-details-screen branch from 5c3837a to 0d81e8f Compare March 17, 2026 21:51
@github-actions github-actions Bot added size-M risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 17, 2026
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Comment thread app/components/UI/TokenDetails/components/AssetOverviewContent.tsx Outdated
@github-actions github-actions Bot added risk-medium Moderate testing recommended · Possible bug introduction risk and removed risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 17, 2026
@Matt561 Matt561 force-pushed the feat/musd-455-bring-back-claim-section-on-asset-details-screen branch from 17b2488 to fa7638f Compare March 17, 2026 22:02
@github-actions github-actions Bot added risk-medium Moderate testing recommended · Possible bug introduction risk and removed risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 17, 2026
@metamaskbot metamaskbot added the INVALID-PR-TEMPLATE PR's body doesn't match template label Mar 17, 2026
@github-actions github-actions Bot added size-L risk-medium Moderate testing recommended · Possible bug introduction risk and removed size-M risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 18, 2026
@codecov-commenter
Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 16.12903% with 26 lines in your changes missing coverage. Please review.
✅ Project coverage is 45.21%. Comparing base (bb5bfa8) to head (dec0d8e).
⚠️ Report is 35 commits behind head on main.

Files with missing lines Patch % Lines
...ssetOverviewClaimBonus/AssetOverviewClaimBonus.tsx 7.69% 24 Missing ⚠️
...I/TokenDetails/components/AssetOverviewContent.tsx 50.00% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main   #27567       +/-   ##
===========================================
- Coverage   82.19%   45.21%   -36.98%     
===========================================
  Files        4788     4786        -2     
  Lines      123512   123340      -172     
  Branches    27364    27414       +50     
===========================================
- Hits       101516    55764    -45752     
- Misses      14962    62428    +47466     
+ Partials     7034     5148     -1886     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot added risk-medium Moderate testing recommended · Possible bug introduction risk and removed risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 19, 2026
@Matt561 Matt561 enabled auto-merge March 19, 2026 14:10
@github-actions github-actions Bot added risk-medium Moderate testing recommended · Possible bug introduction risk and removed risk-medium Moderate testing recommended · Possible bug introduction risk labels Mar 19, 2026
@github-actions
Copy link
Copy Markdown
Contributor

🔍 Smart E2E Test Selection

  • Selected E2E tags: SmokeTrade, SmokeWalletPlatform, SmokeConfirmations
  • Selected Performance tags: None (no tests recommended)
  • Risk Level: medium
  • AI Confidence: 72%
click to see 🤖 AI reasoning details

E2E Test Selection:
The PR introduces a new AssetOverviewClaimBonus component for claiming Merkl bonus rewards in the Earn/staking flow. Key findings:

  1. New component (AssetOverviewClaimBonus): Renders a claim bonus UI with a claimable amount, info tooltip, and claim button. Uses useMerklBonusClaim hook to handle the claim transaction flow.

  2. AssetOverviewContent.tsx modification: Integrates the new component into the token details/asset overview screen. The component is gated behind selectMerklCampaignClaimingEnabledFlag feature flag AND isTokenEligibleForMerklRewards check, so it only renders for eligible tokens (mUSD on Linea).

  3. Analytics events: New event location constant added for tooltip tracking.

  4. Localization: New i18n strings added for the claim bonus UI.

Tag selection rationale:

  • SmokeTrade: The staking/earn functionality is covered under SmokeTrade (stake-action-smoke.spec.ts uses SmokeTrade tag). The claim bonus is part of the earn/staking flow on Linea.
  • SmokeConfirmations: Per SmokeTrade tag description, when selecting SmokeTrade for staking flows, also select SmokeConfirmations since claim transactions are on-chain transactions requiring confirmation UI.
  • SmokeWalletPlatform: The AssetOverviewContent.tsx is part of the token details view (a core wallet platform feature). Changes to this component could affect how token details are displayed for all tokens, even though the new component is feature-flag gated.

Risk factors:

  • The changes are additive and feature-flag gated, reducing risk to existing flows
  • The AssetOverviewContent.tsx modification is minimal (3 new imports + conditional render)
  • No changes to controllers, navigation, or shared infrastructure
  • No existing E2E tests specifically for Merkl rewards/claim bonus were found

Performance Test Selection:
The changes are additive UI components gated behind a feature flag. The new AssetOverviewClaimBonus component only renders for eligible tokens (mUSD on Linea) and doesn't affect general asset loading, account lists, or app startup performance. No performance-sensitive code paths (Redux state management, list rendering, app initialization) are modified. Performance tests are not warranted for this change.

View GitHub Actions results

@github-actions
Copy link
Copy Markdown
Contributor

E2E Fixture Validation — Schema is up to date
16 value mismatches detected (expected — fixture represents an existing user).
View details

@sonarqubecloud
Copy link
Copy Markdown

@Matt561 Matt561 added this pull request to the merge queue Mar 19, 2026
Merged via the queue into main with commit 35fb472 Mar 19, 2026
201 of 204 checks passed
@Matt561 Matt561 deleted the feat/musd-455-bring-back-claim-section-on-asset-details-screen branch March 19, 2026 15:53
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 19, 2026
@metamaskbot metamaskbot added the release-7.71.0 Issue or pull request that will be included in release 7.71.0 label Mar 19, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

INVALID-PR-TEMPLATE PR's body doesn't match template No QA Needed Apply this label when your PR does not need any QA effort. release-7.71.0 Issue or pull request that will be included in release 7.71.0 risk-medium Moderate testing recommended · Possible bug introduction risk size-L team-earn

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants