Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
2cfeb08
feat: migrate Button (web3auth scope) (#27810)
kirillzyusko Mar 26, 2026
d0b494f
fix(perps): Can't create a TP/SL with 6 decimals for PUMP (#27901)
abretonc7s Mar 26, 2026
0978f3f
fix(perps): Adjust incorrect market categories (#27910)
abretonc7s Mar 26, 2026
5e7b624
refactor(analytics): C4 migrate useMetrics to useAnalytics: Simulatio…
NicolasMassart Mar 26, 2026
048febe
refactor(analytics): C5 migrate to useAnalytics in PredictGTMModal (#…
NicolasMassart Mar 26, 2026
5bc0539
fix(perps): Incorrect PnL and order size displayed in perp market pag…
abretonc7s Mar 26, 2026
3a6aaf3
chore: upgrade design-system-react-native to 0.11.0 and deprecate rep…
georgewrmarshall Mar 26, 2026
d0ed881
fix: fix charting url (#27972)
sahar-fehri Mar 26, 2026
241087f
feat: added 'View all' button in explore search (#26569)
juanmigdr Mar 26, 2026
65c4658
test(swap): add gasless swap e2e tests for ETH/USDC to MUSD with 7702…
davibroc Mar 26, 2026
31ebc2b
feat(rewards): Ondo GM portfolio position and leaderboard section (#2…
VGR-GIT Mar 26, 2026
ae5b5bb
feat(card): add balance properties on SpendingLimit Card Viewed scree…
Brunonascdev Mar 26, 2026
d9cc49e
feat: Add WCv2 session amount limit (#27988)
jiexi Mar 26, 2026
31b09da
chore: Downgrade `@tanstack/react-query` to `^4.43.0` (#27964)
FrederikBolding Mar 26, 2026
49c3ca0
fix(predict): invalidate EthQuery cache before Claim/Withdraw Safe TX…
matallui Mar 26, 2026
3e1b3d4
fix: revoke permissions for each session in WC2Manager.removeAll() (#…
adonesky1 Mar 26, 2026
dee9a46
fix(perps): Missing 1 decimal on price input when using preset on lim…
abretonc7s Mar 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ import { useTailwind } from '@metamask/design-system-twrnc-preset';

import { ButtonFilterProps } from './ButtonFilter.types';

/**
* @deprecated Please update your code to use `ButtonFilter` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/ButtonFilter/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const ButtonFilter = ({
children,
isActive = false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ import { useAnimatedPressable, useStyles } from '../../hooks';
import { MainActionButtonProps } from './MainActionButton.types';
import styleSheet from './MainActionButton.styles';

/**
* @deprecated Please update your code to use `MainActionButton` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/MainActionButton/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const MainActionButton = ({
iconName,
label,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ import {

import type { TabEmptyStateProps } from './TabEmptyState.types';

/**
* @deprecated Please update your code to use `TabEmptyState` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/TabEmptyState/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
export const TabEmptyState: React.FC<TabEmptyStateProps> = ({
icon,
description,
Expand Down
8 changes: 8 additions & 0 deletions app/component-library/components/Banners/Banner/Banner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@ import BannerTip from './variants/BannerTip';
// Internal dependencies.
import { BannerProps, BannerVariant } from './Banner.types';

/**
* @deprecated Please update your code to use `BannerAlert` from `@metamask/design-system-react-native`.
* The `BannerVariant.Tip` variant is unused and will be removed.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BannerAlert/README.md}
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/MIGRATION.md Migration docs}
* @since @metamask/design-system-react-native@0.11.0
*/
const Banner = (bannerProps: BannerProps) => {
switch (bannerProps.variant) {
case BannerVariant.Alert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ import {
TESTID_BANNER_CLOSE_BUTTON_ICON,
} from './BannerBase.constants';

/**
* @deprecated Please update your code to use `BannerBase` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BannerBase/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const BannerBase: React.FC<BannerBaseProps> = ({
style,
startAccessory,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ import {
BANNERALERT_TEST_ID,
} from './BannerAlert.constants';

/**
* @deprecated Please update your code to use `BannerAlert` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BannerAlert/README.md}
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/MIGRATION.md Migration docs}
* @since @metamask/design-system-react-native@0.11.0
*/
const BannerAlert: React.FC<BannerAlertProps> = ({
style,
severity = DEFAULT_BANNERALERT_SEVERITY,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ import {
BANNERTIP_TEST_ID,
} from './BannerTip.constants';

/**
* @deprecated This component is unused and will be removed.
* Please use `BannerBase` from `@metamask/design-system-react-native` instead.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BannerBase/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const BannerTip: React.FC<BannerTipProps> = ({
style,
logoType = DEFAULT_BANNERTIP_LOGOTYPE,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ import BottomSheetDialog, {
BottomSheetDialogRef,
} from './foundation/BottomSheetDialog';

/**
* @deprecated Please update your code to use `BottomSheet` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BottomSheet/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const BottomSheet = forwardRef<BottomSheetRef, BottomSheetProps>(
(
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ import {
BottomSheetDialogProps,
} from './BottomSheetDialog.types';

/**
* @deprecated Please update your code to use `BottomSheetDialog` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/BottomSheetDialog/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const BottomSheetDialog = forwardRef<
BottomSheetDialogRef,
BottomSheetDialogProps
Expand Down
1 change: 1 addition & 0 deletions app/component-library/components/Icons/Icon/Icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { DEFAULT_ICON_SIZE, DEFAULT_ICON_COLOR } from './Icon.constants';
* @deprecated Please update your code to use `Icon` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/Icon/README.md}
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/MIGRATION.md Migration docs}
*/
const Icon = ({
size = DEFAULT_ICON_SIZE,
Expand Down
6 changes: 6 additions & 0 deletions app/component-library/components/List/ListItem/ListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ import {
TESTID_LISTITEM_GAP,
} from './ListItem.constants';

/**
* @deprecated Please update your code to use `ListItem` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/ListItem/README.md}
* @since @metamask/design-system-react-native@0.11.0
*/
const ListItem: React.FC<ListItemProps> = ({
style,
children,
Expand Down
1 change: 1 addition & 0 deletions app/component-library/components/Texts/Text/Text.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { DEFAULT_TEXT_COLOR, DEFAULT_TEXT_VARIANT } from './Text.constants';
* @deprecated Please update your code to use `Text` from `@metamask/design-system-react-native`.
* The API may have changed — compare props before migrating.
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/Text/README.md}
* @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/MIGRATION.md Migration docs}
*/
const Text: React.FC<TextProps> = ({
variant = DEFAULT_TEXT_VARIANT,
Expand Down
6 changes: 6 additions & 0 deletions app/components/Nav/Main/MainNavigator.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ import ActivityView from '../../Views/ActivityView';
import RewardsNavigator from '../../UI/Rewards/RewardsNavigator';
import { ExploreFeed } from '../../Views/TrendingView/TrendingView';
import ExploreSearchScreen from '../../Views/TrendingView/Views/ExploreSearchScreen/ExploreSearchScreen';
import ExploreSectionResultsFullView from '../../Views/TrendingView/Views/ExploreSectionResultsFullView/ExploreSectionResultsFullView';
import TrendingFeedSessionManager from '../../UI/Trending/services/TrendingFeedSessionManager';
import CollectiblesDetails from '../../UI/CollectibleModal';
import OptinMetrics from '../../UI/OptinMetrics';
Expand Down Expand Up @@ -1181,6 +1182,11 @@ const MainNavigator = () => {
component={SitesFullView}
options={{ headerShown: false, ...slideFromRightAnimation }}
/>
<Stack.Screen
name={Routes.EXPLORE_SECTION_RESULTS_FULL_VIEW}
component={ExploreSectionResultsFullView}
options={{ headerShown: false, ...slideFromRightAnimation }}
/>
<Stack.Screen
name={Routes.BROWSER.HOME}
component={BrowserFlow}
Expand Down
33 changes: 33 additions & 0 deletions app/components/Nav/Main/__snapshots__/MainNavigator.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,17 @@ exports[`MainNavigator Tab Bar Visibility hides tab bar when browser is active 1
}
}
/>
<Screen
component={[Function]}
name="ExploreSectionResultsFullView"
options={
{
"animationEnabled": true,
"cardStyleInterpolator": [Function],
"headerShown": false,
}
}
/>
<Screen
component={[Function]}
name="BrowserTabHome"
Expand Down Expand Up @@ -716,6 +727,17 @@ exports[`MainNavigator Tab Bar Visibility shows tab bar when not in browser 1`]
}
}
/>
<Screen
component={[Function]}
name="ExploreSectionResultsFullView"
options={
{
"animationEnabled": true,
"cardStyleInterpolator": [Function],
"headerShown": false,
}
}
/>
<Screen
component={[Function]}
name="BrowserTabHome"
Expand Down Expand Up @@ -1117,6 +1139,17 @@ exports[`MainNavigator matches rendered snapshot 1`] = `
}
}
/>
<Screen
component={[Function]}
name="ExploreSectionResultsFullView"
options={
{
"animationEnabled": true,
"cardStyleInterpolator": [Function],
"headerShown": false,
}
}
/>
<Screen
component={[Function]}
name="BrowserTabHome"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import Routes from '../../../../constants/navigation/Routes';
import NotificationsService from '../../../../util/notifications/services/NotificationService';
import { MetaMetricsEvents } from '../../../../core/Analytics';
import { useEnableNotifications } from '../../../../util/notifications/hooks/useNotifications';
import { useMetrics } from '../../../hooks/useMetrics';
import { useAnalytics } from '../../../hooks/useAnalytics/useAnalytics';
import { selectIsMetamaskNotificationsEnabled } from '../../../../selectors/notifications';
import { selectIsBackupAndSyncEnabled } from '../../../../selectors/identity';
import useThunkDispatch from '../../../hooks/useThunkDispatch';
Expand All @@ -43,7 +43,7 @@ interface Props {
}

const BasicFunctionalityModal = ({ route }: Props) => {
const { trackEvent, createEventBuilder } = useMetrics();
const { trackEvent, createEventBuilder } = useAnalytics();
const { colors } = useTheme();
const styles = createStyles(colors);
const bottomSheetRef = useRef<BottomSheetRef>(null);
Expand Down
5 changes: 3 additions & 2 deletions app/components/UI/Bridge/components/InputStepper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import Input from '../../../../../component-library/components/Form/TextField/fo
import {
ButtonIcon,
ButtonIconSize,
ButtonIconVariant,
IconColor,
IconName,
Text,
Expand Down Expand Up @@ -42,7 +43,7 @@ export const InputStepper = ({
<ButtonIcon
size={ButtonIconSize.Lg}
iconName={IconName.Minus}
isFloating
variant={ButtonIconVariant.Floating}
style={tw.style(minusPressed ? 'bg-muted-pressed' : 'bg-muted')}
iconProps={{ color: IconColor.IconDefault }}
onPressIn={() => setMinusPressed(true)}
Expand Down Expand Up @@ -72,7 +73,7 @@ export const InputStepper = ({
<ButtonIcon
size={ButtonIconSize.Lg}
iconName={IconName.Add}
isFloating
variant={ButtonIconVariant.Floating}
style={tw.style(plusPressed ? 'bg-muted-pressed' : 'bg-muted')}
iconProps={{ color: IconColor.IconDefault }}
onPressIn={() => setPlusPressed(true)}
Expand Down
6 changes: 3 additions & 3 deletions app/components/UI/Card/Views/SpendingLimit/SpendingLimit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ const SpendingLimit: React.FC<SpendingLimitProps> = ({ route }) => {
{accountGroupName ?? selectedAccount.metadata.name}
</Text>
<Icon
name={IconName.ArrowRight}
name={IconName.ArrowDown}
size={IconSize.Md}
color={IconColor.IconDefault}
style={tw.style('self-center shrink-0')}
Expand Down Expand Up @@ -355,7 +355,7 @@ const SpendingLimit: React.FC<SpendingLimitProps> = ({ route }) => {
{tokenLabel}
</Text>
<Icon
name={IconName.ArrowRight}
name={IconName.ArrowDown}
size={IconSize.Md}
color={IconColor.IconDefault}
style={tw.style('self-center shrink-0')}
Expand Down Expand Up @@ -386,7 +386,7 @@ const SpendingLimit: React.FC<SpendingLimitProps> = ({ route }) => {
{spendingLimitLabel}
</Text>
<Icon
name={IconName.ArrowRight}
name={IconName.ArrowDown}
size={IconSize.Md}
color={IconColor.IconDefault}
style={tw.style('self-center shrink-0')}
Expand Down
5 changes: 5 additions & 0 deletions app/components/UI/Card/hooks/useCardDetails.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const mockRefetch = jest.fn();
jest.mock('@tanstack/react-query', () => ({
useQuery: jest.fn().mockReturnValue({
data: undefined,
isFetching: false,
isLoading: false,
error: null,
refetch: jest.fn(),
Expand Down Expand Up @@ -63,6 +64,7 @@ describe('useCardDetails', () => {

(useQuery as jest.Mock).mockReturnValue({
data: undefined,
isFetching: false,
isLoading: false,
error: null,
refetch: mockRefetch,
Expand Down Expand Up @@ -90,6 +92,7 @@ describe('useCardDetails', () => {
};
(useQuery as jest.Mock).mockReturnValue({
data: cardDetailsResult,
isFetching: false,
isLoading: false,
error: null,
refetch: mockRefetch,
Expand All @@ -106,6 +109,7 @@ describe('useCardDetails', () => {
it('returns loading state from useQuery', () => {
(useQuery as jest.Mock).mockReturnValue({
data: undefined,
isFetching: true,
isLoading: true,
error: null,
refetch: mockRefetch,
Expand Down Expand Up @@ -141,6 +145,7 @@ describe('useCardDetails', () => {
const mockError = new Error('Test error');
(useQuery as jest.Mock).mockReturnValue({
data: undefined,
isFetching: false,
isLoading: false,
error: mockError,
refetch: mockRefetch,
Expand Down
3 changes: 2 additions & 1 deletion app/components/UI/Card/hooks/useCardDetails.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ const useCardDetails = () => {
const {
data: cardDetailsData,
isLoading,
isFetching,
error,
refetch,
} = useQuery<CardDetailsResult | null>({
Expand Down Expand Up @@ -69,7 +70,7 @@ const useCardDetails = () => {
return {
cardDetails: cardDetailsData?.cardDetails ?? null,
warning: cardDetailsData?.warning ?? null,
isLoading,
isLoading: isLoading && isFetching,
error: error as Error | null,
fetchCardDetails,
};
Expand Down
6 changes: 5 additions & 1 deletion app/components/UI/Card/hooks/useCardPinToken.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ const useCardPinToken = (): UseCardPinTokenResult => {
[theme.themeAppearance],
);

const { mutateAsync, isPending, error, data, reset } = useMutation({
const { mutateAsync, isPending, error, data, reset } = useMutation<
CardPinTokenResponse,
Error,
{ customCss: typeof customCss }
>({
mutationKey: cardQueries.pin.keys.token(),
mutationFn: cardQueries.pin.tokenMutationFn(sdk),
});
Expand Down
2 changes: 1 addition & 1 deletion app/components/UI/Card/hooks/useCashbackWallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ const useCashbackWallet = () => {

return {
cashbackWallet: walletQuery.data ?? null,
isLoading: walletQuery.isLoading,
isLoading: walletQuery.isLoading && walletQuery.isFetching,
error: walletQuery.error,
fetchCashbackWallet: walletQuery.refetch,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const useGetCardExternalWalletDetails = (
const sdkRef = useRef(sdk);
sdkRef.current = sdk;

const { data, isLoading, error, refetch } = useQuery({
const { data, isLoading, isFetching, error, refetch } = useQuery({
queryKey: cardQueries.dashboard.keys.externalWalletDetails(),
queryFn: async () => {
const currentDelegationSettings =
Expand Down Expand Up @@ -155,7 +155,7 @@ const useGetCardExternalWalletDetails = (

return {
data: data ?? null,
isLoading,
isLoading: isLoading && isFetching,
error: error as Error | null,
fetchData,
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,7 @@ describe('useGetDelegationSettings', () => {
it('returns loading state from useQuery', () => {
(useQuery as jest.Mock).mockReturnValue({
data: undefined,
isFetching: true,
isLoading: true,
error: null,
});
Expand Down
Loading
Loading