From 2a570d4dcfe9fab46dd2eb2c9248f7baf72fe305 Mon Sep 17 00:00:00 2001 From: hz002 Date: Thu, 21 Nov 2024 21:48:12 +0800 Subject: [PATCH] style(singleAddressHome): android layout --- apps/mobile/src/constant/theme-colors.js | 2 ++ .../src/screens/SingleAddreesHome/AssetContainer.tsx | 2 ++ apps/mobile/src/screens/SingleAddreesHome/Home.tsx | 12 +++--------- .../components/TokenWalletFooter.tsx | 10 ++++------ 4 files changed, 11 insertions(+), 15 deletions(-) diff --git a/apps/mobile/src/constant/theme-colors.js b/apps/mobile/src/constant/theme-colors.js index 9c18522ef..571181df1 100644 --- a/apps/mobile/src/constant/theme-colors.js +++ b/apps/mobile/src/constant/theme-colors.js @@ -121,6 +121,8 @@ const themeColorsNext2024 = { 'neutral-line': 'rgba(224, 229, 236, 1)', 'neutral-title-1': 'rgba(25, 41, 69, 1)', 'neutral-title-2': 'rgba(255, 255, 255, 1)', + // TODO: corresponding dark color + 'netural-card-2': 'rgba(242, 244, 247, 1)', 'neutral-body': 'rgba(62, 73, 94, 1)', 'neutral-foot': 'rgba(106, 117, 135, 1)', 'neutral-secondary': 'rgba(154, 156, 169, 1)', diff --git a/apps/mobile/src/screens/SingleAddreesHome/AssetContainer.tsx b/apps/mobile/src/screens/SingleAddreesHome/AssetContainer.tsx index dc878626e..ac86129ca 100644 --- a/apps/mobile/src/screens/SingleAddreesHome/AssetContainer.tsx +++ b/apps/mobile/src/screens/SingleAddreesHome/AssetContainer.tsx @@ -86,6 +86,7 @@ export const AssetContainer: React.FC = ({ containerStyle={styles.container} renderTabBar={renderTabBar} headerContainerStyle={styles.headerContainer} + minHeaderHeight={10} onTabChange={tab => { setActiveTab(tab.tabName); }} @@ -105,6 +106,7 @@ export const AssetContainer: React.FC = ({ const getStyles = createGetStyles2024(ctx => ({ container: { + marginTop: -10, backgroundColor: ctx.colors2024['neutral-bg-1'], width: '100%', paddingBottom: 18, diff --git a/apps/mobile/src/screens/SingleAddreesHome/Home.tsx b/apps/mobile/src/screens/SingleAddreesHome/Home.tsx index ec2956ed8..4cee6484a 100644 --- a/apps/mobile/src/screens/SingleAddreesHome/Home.tsx +++ b/apps/mobile/src/screens/SingleAddreesHome/Home.tsx @@ -1,7 +1,5 @@ import React, { useCallback } from 'react'; import { SafeAreaView } from 'react-native'; -import RootScreenContainer from '@/components/ScreenContainer/RootScreenContainer'; - import HeaderArea from './HeaderArea'; import { StackActions, useFocusEffect } from '@react-navigation/native'; import { AssetContainer } from './AssetContainer'; @@ -16,6 +14,7 @@ import { ScreenSpecificStatusBar } from '@/components/FocusAwareStatusBar'; import { createGetStyles2024 } from '@/utils/styles'; import { useTheme2024 } from '@/hooks/theme'; import { useSafeSetNavigationOptions } from '@/components/AppStatusBar'; +import NormalScreenContainer from '@/components/ScreenContainer/NormalScreenContainer'; function HomeScreen(): JSX.Element { const { navigation, setNavigationOptions } = useSafeSetNavigationOptions(); @@ -53,11 +52,7 @@ function HomeScreen(): JSX.Element { ); return ( - + {/* */} - + ); } @@ -77,7 +72,6 @@ const getStyles = createGetStyles2024(ctx => ({ }, safeView: { flex: 1, - paddingHorizontal: 16, width: '100%', overflow: 'hidden', }, diff --git a/apps/mobile/src/screens/SingleAddreesHome/components/TokenWalletFooter.tsx b/apps/mobile/src/screens/SingleAddreesHome/components/TokenWalletFooter.tsx index 7a1483657..847a4f299 100644 --- a/apps/mobile/src/screens/SingleAddreesHome/components/TokenWalletFooter.tsx +++ b/apps/mobile/src/screens/SingleAddreesHome/components/TokenWalletFooter.tsx @@ -1,9 +1,8 @@ -import React, { useMemo } from 'react'; -import { StyleSheet, Text, View } from 'react-native'; +import React from 'react'; +import { Text, View } from 'react-native'; import { RcArrowRight2CC } from '@/assets/icons/common'; -import { AppColorsVariants } from '@/constant/theme'; -import { useTheme2024, useThemeColors } from '@/hooks/theme'; +import { useTheme2024 } from '@/hooks/theme'; import { TouchableOpacity } from 'react-native-gesture-handler'; import { createGetStyles2024 } from '@/utils/styles'; @@ -59,8 +58,7 @@ const getStyles = createGetStyles2024(ctx => ({ flexDirection: 'row', alignItems: 'center', borderRadius: 100, - // TODO: card2 - backgroundColor: ctx.colors2024['neutral-bg-2'], + backgroundColor: ctx.colors2024['netural-card-2'], paddingHorizontal: 8, paddingVertical: 10, display: 'flex',