Skip to content

[pull] main from MetaMask:main#386

Merged
pull[bot] merged 5 commits into
Reality2byte:mainfrom
MetaMask:main
Dec 5, 2025
Merged

[pull] main from MetaMask:main#386
pull[bot] merged 5 commits into
Reality2byte:mainfrom
MetaMask:main

Conversation

@pull
Copy link
Copy Markdown

@pull pull Bot commented Dec 5, 2025

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

gambinish and others added 5 commits December 5, 2025 17:53
## **Description**

Temporarily disabling the remove margin feature until we can accurately
calculate the max removable amount. HL uses some discreet safety buffer
to prevent users from removing too much margin.

We were using an estimated hardcoded buffer, but it wasn't accurate, and
was causing confusion as to how much margin could actually be removed.

## **Changelog**

<!--
If this PR is not End-User-Facing and should not show up in the
CHANGELOG, you can choose to either:
1. Write `CHANGELOG entry: null`
2. Label with `no-changelog`

If this PR is End-User-Facing, please write a short User-Facing
description in the past tense like:
`CHANGELOG entry: Added a new tab for users to see their NFTs`
`CHANGELOG entry: Fixed a bug that was causing some NFTs to flicker`

(This helps the Release Engineer do their job more quickly and
accurately)
-->

CHANGELOG entry: disabled remove margin feature

## **Related issues**

Fixes: https://consensyssoftware.atlassian.net/browse/TAT-2205

## **Manual testing steps**

```gherkin
Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]
```

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<!-- [screenshots/recordings] -->

### **After**

<!-- [screenshots/recordings] -->

## **Pre-merge author checklist**

- [x] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> Temporarily disables the Remove Margin option and comments out related
tests in Perps Adjust Margin Action Sheet.
> 
> - **UI (Perps Adjust Margin Action Sheet)**:
> - Remove `reduce_margin` option from `actionOptions` in
`app/components/UI/Perps/components/PerpsAdjustMarginActionSheet/PerpsAdjustMarginActionSheet.tsx`
(left as TODO with reference link).
> - **Tests**:
> - Comment out assertions and handler test for `reduce_margin` in
`app/components/UI/Perps/components/PerpsAdjustMarginActionSheet/PerpsAdjustMarginActionSheet.test.tsx`.
>   - Keep `add_margin` rendering and selection behavior tests intact.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
f2ef03f. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
## **Description**

This PR fixes inconsistent vertical padding in the Add Funds modal
(FundActionMenu) that appears when users tap "Add funds" from the Wallet
screen. The modal was showing tight spacing at the top (~8-10px) and
smaller bottom padding, creating a visually unbalanced and compressed
appearance.

**Improvements:**
- Added consistent 16px top padding above the first list item (Deposit)
- Added consistent 16px bottom padding below the last list item
(Withdraw)
- Aligned padding with MetaMask modal design standards used throughout
the app
- Improved visual consistency and polish for a core wallet funding flow

**Technical Changes:**
- Wrapped `ActionListItem` components in a `Box` component with `pt-4
pb-4` Tailwind classes
- This provides 16px padding on both top and bottom edges, matching the
standard used in other modals like `PerpsModifyActionSheet`

## **Changelog**

CHANGELOG entry: Fixed inconsistent vertical padding in Add Funds modal
to improve visual consistency

## **Related issues**

Fixes: https://consensyssoftware.atlassian.net/browse/TRAM-2673

https://consensyssoftware.atlassian.net/browse/TRAM-2898

## **Manual testing steps**

Feature: Add Funds Modal Padding

  Scenario: user opens Add Funds modal and verifies consistent padding
    Given the user is on the Wallet screen
    When user taps the "Add funds" button
Then the modal should display with 16px padding above the first item
(Deposit)
And the modal should display with 16px padding below the last item
(Withdraw)
    And the top and bottom padding should be visually balanced
    And the modal should not appear compressed or cut off

Scenario: user verifies padding consistency across different action
configurations
    Given the user opens the Add Funds modal
When the modal displays with different combinations of visible actions
(Deposit, Buy, Sell)
Then the padding should remain consistent regardless of which actions
are visible
And the spacing should match other modals in the app (e.g., token
picker, settings sheets)## **Screenshots/Recordings**

### **Before**

<img width="500" alt="Add Funds modal before - showing tight padding"
src="https://github.com/user-attachments/assets/c58eb69d-6b43-4ad2-8ca6-0ec305287dcd"
/>

- Top padding above "Deposit" was ~8-10px (too tight)
- Bottom padding below "Withdraw" was smaller than top padding
- Modal appeared visually compressed and unbalanced

### **After**

<img width="500" alt="Add Funds modal after - showing consistent 16px
padding"
src="https://github.com/user-attachments/assets/ca9d1a65-d6bc-49d2-a7a3-5e133bf52c7e"
/>

- Top padding above first item is now 16px (consistent with design
standards)
- Bottom padding below last item is now 16px (matches top padding)
- Modal has balanced, consistent spacing that matches other modals in
the app
## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I've included tests if applicable (all existing tests pass -
31/31)
- [x] I've documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I've applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> Adds consistent top/bottom padding in `FundActionMenu` by wrapping
action items with a `Box` (`py-4`).
> 
> - **UI**
>   - `app/components/UI/FundActionMenu/FundActionMenu.tsx`:
> - Wraps action items with `Box` using `twClassName="py-4"` to add
consistent top/bottom padding in the bottom sheet.
> - Updates import to include `Box` from
`@metamask/design-system-react-native`.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
2ea9708. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

---------

Co-authored-by: Pedro Pablo Aste Kompen <wachunei@gmail.com>
…ssibility scaling (#23732)

## **Description**

Fixed issue where iOS accessibility font scaling caused the price diff
text to wrap, pushing the trend chart down and causing it to jump up and
down when scanning the chart.

Solution:
- Wrapped text in a flex container with `flexWrap: 'nowrap'` to
constrain layout
- Added `numberOfLines={1}`, `adjustsFontSizeToFit`, and
`minimumFontScale={0.5}` to
prevent text wrapping while maintaining readability by auto-scaling font
size

## **Changelog**

CHANGELOG entry: Fixed chart jumping issues when font accessibility is
turned on

## **Related issues**

Fixes: https://consensyssoftware.atlassian.net/browse/MDP-596

## **Manual testing steps**

```gherkin
Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]
```

## **Screenshots/Recordings**

`~`

### **Before**


https://github.com/user-attachments/assets/b19c37ba-b732-45d6-aa34-99e788e938e3

### **After**


https://github.com/user-attachments/assets/6156229d-546a-4e18-8348-6ef0a25e5387

## **Pre-merge author checklist**

- [x] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [x] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [x] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> Prevents price diff text from wrapping and shifting the chart by
wrapping it in a non-wrapping row container and enabling single-line
autoscaling.
> 
> - **Asset Overview Price UI**:
> - Wrap price diff and date in `priceDiffContainer` (`flexDirection:
'row'`, `flexWrap: 'nowrap'`, `overflow: 'hidden'`).
>   - Add `flexShrink: 1` to `priceDiff` and keep icon styling.
> - Set `numberOfLines={1}`, `adjustsFontSizeToFit`,
`minimumFontScale={0.5}` on the price diff `Text`; nest date `Text`
inside.
> - **Tests**:
>   - Update snapshots to reflect new container and text props.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
936949f. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

## **Description**


1. What is the reason for the change?
- EVM addresses should always be checksummed. Non evm addresses should
not.
- Our addresses were formatted correctly on the list view but not in the
QR modal
- This fix ensures that all the addresses being rendered on that screen
have the proper formatting
2. What is the improvement/solution?
- call toFormattedAddress before passing it as a prop.

## **Changelog**

<!--
If this PR is not End-User-Facing and should not show up in the
CHANGELOG, you can choose to either:
1. Write `CHANGELOG entry: null`
2. Label with `no-changelog`

If this PR is End-User-Facing, please write a short User-Facing
description in the past tense like:
`CHANGELOG entry: Added a new tab for users to see their NFTs`
`CHANGELOG entry: Fixed a bug that was causing some NFTs to flicker`

(This helps the Release Engineer do their job more quickly and
accurately)
-->

CHANGELOG entry: Fixed bug where the EVM addresses were not checksummed

## **Related issues**

Fixes: https://consensyssoftware.atlassian.net/browse/MUL-1327

## **Manual testing steps**
1. create or import a wallet
2. con the home page click the receive button
3. it should open the address list
4. then, look at your EVM addresses and ensure that the shortened
versions are checksummed
5. copy the address and ensure that the address is checksummed
6. click on the QR modal and ensure that the address is checksummed
7. scan the qr code and verify that the address is checksummed
8. look at your Bitcoin address, it should not be checksummed.

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<img width="250" height="600" alt="Simulator Screenshot - iPhone 16 Plus
- 2025-12-04 at 16 42 28"
src="https://github.com/user-attachments/assets/33e47a72-9f11-42a3-9efd-3a3fea271953"
/>

<img width="250" height="600" alt="Simulator Screenshot - iPhone 16 Plus
- 2025-12-04 at 16 42 12"
src="https://github.com/user-attachments/assets/c9162dfe-b619-44e4-9fa4-8dd86f935e70"
/>


### **After**

<img width="250" height="600" alt="Simulator Screenshot - iPhone 16 Plus
- 2025-12-04 at 16 33 52"
src="https://github.com/user-attachments/assets/a2feb119-0a07-4010-a220-95b70bcbaf5c"
/>

<img width="250" height="600" alt="Simulator Screenshot - iPhone 16 Plus
- 2025-12-04 at 16 33 48"
src="https://github.com/user-attachments/assets/4ea253ae-9953-4f77-a623-7ec739aa286d"
/>


## **Pre-merge author checklist**

- [ ] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [ ] I've completed the PR template to the best of my ability
- [ ] I’ve included tests if applicable
- [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.


<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> Checksums EVM addresses (leaves non‑EVM raw) across address list/QR
and selectors, and switches PrivateKeyList to store private keys by
account id; adds tests.
> 
> - **Address formatting**
> - Use `toFormattedAddress` in `MultichainAddressRowsList.utils` when
creating `NetworkAddressItem`.
> - Format addresses in selector
`selectInternalAccountListSpreadByScopesByGroupId` before mapping items.
>   - Pass formatted address to QR navigation in `AddressList.test.tsx`.
> - **Private keys**
> - Store exported private keys by `account.id` instead of
`account.address` in `PrivateKeyList.tsx` and update copy callback
usage.
> - **Tests**
> - Add assertions for checksummed EVM addresses and unmodified non‑EVM
addresses in `MultichainAddressRowsList.utils.test.ts`.
> - Update QR expectation to use formatted address in
`AddressList.test.tsx`.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
c35634f. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

## **Description**

<!--
Write a short description of the changes included in this pull request,
also include relevant motivation and context. Have in mind the following
questions:
1. What is the reason for the change?
2. What is the improvement/solution?
-->

This update adds support for delegating Base assets within the MetaMask
Card feature.

## **Changelog**

<!--
If this PR is not End-User-Facing and should not show up in the
CHANGELOG, you can choose to either:
1. Write `CHANGELOG entry: null`
2. Label with `no-changelog`

If this PR is End-User-Facing, please write a short User-Facing
description in the past tense like:
`CHANGELOG entry: Added a new tab for users to see their NFTs`
`CHANGELOG entry: Fixed a bug that was causing some NFTs to flicker`

(This helps the Release Engineer do their job more quickly and
accurately)
-->

CHANGELOG entry: Added support for delegating Base assets in the
MetaMask Card feature

## **Related issues**

Fixes:

## **Manual testing steps**

```gherkin
Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]
```

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<!-- [screenshots/recordings] -->

### **After**

<!-- [screenshots/recordings] -->


https://github.com/user-attachments/assets/f54fcee4-e30a-40c7-869e-775c24c4e8a1

## **Pre-merge author checklist**

- [x] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.


<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> Enables Base network for MetaMask Card, adding network-aware
SDK/providers, token/feature flag configs, UI mapping/filters, and
balance/allowance handling.
> 
> - **Card SDK/Backend**:
> - Add Base to supported networks and validation (`CardNetwork`,
`SUPPORTED_ASSET_NETWORKS`).
> - Introduce network-aware providers/RPCs (`cardNetworkInfos`,
Base/Linea RPC URLs) and `foxConnect` access per network.
> - Update `getSupportedTokensByChainId()` to default CAIP and use
across callers.
> - Make `getLatestAllowanceFromLogs` network-aware (accepts
`CardNetwork`).
> - Allow `completeEVMDelegation` for `base`; extend delegation settings
validation to `base`.
> - Map external wallet network -> CAIP via `cardNetworkInfos`; remove
unused `totalAllowance` mapping.
> - **UI/Hooks**:
> - Spending Limit: resolve network via `caipChainIdToNetwork` before
delegation.
> - Asset Selection: fetch supported tokens without explicit chain id;
strict network typing for filters.
>   - Balances: include Base chain ID when fetching balances.
> - Latest allowance: skip non-EVM chains; pass network derived from
CAIP when querying logs.
> - Chain name mapping: use `caipChainIdToNetwork` (returns Linea by
default).
> - **Feature Flags**:
> - Add Base (`eip155:8453`) config with tokens and
`foxConnectAddresses`.
> - **Tests**:
> - Update/expand tests for Base support, network-aware log queries, and
new chain name mapping; remove tests for deleted `totalAllowance`
mapping.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
8c5fe0d. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
@pull pull Bot locked and limited conversation to collaborators Dec 5, 2025
@pull pull Bot added the ⤵️ pull label Dec 5, 2025
@pull pull Bot merged commit 6f907f4 into Reality2byte:main Dec 5, 2025
2 of 11 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants