Refactor mobile dashboard layout
This commit is contained in:
@@ -194,6 +194,38 @@ vi.mock('@tamagui/stacks', () => ({
|
||||
XStack: ({ children }: { children: React.ReactNode }) => <div>{children}</div>,
|
||||
}));
|
||||
|
||||
vi.mock('@tamagui/button', () => ({
|
||||
Button: ({ children, onPress }: { children: React.ReactNode; onPress?: () => void }) => (
|
||||
<button type="button" onClick={onPress}>
|
||||
{children}
|
||||
</button>
|
||||
),
|
||||
}));
|
||||
|
||||
vi.mock('@tamagui/list-item', () => ({
|
||||
ListItem: ({
|
||||
title,
|
||||
subTitle,
|
||||
iconAfter,
|
||||
onPress,
|
||||
}: {
|
||||
title?: React.ReactNode;
|
||||
subTitle?: React.ReactNode;
|
||||
iconAfter?: React.ReactNode;
|
||||
onPress?: () => void;
|
||||
}) => (
|
||||
<button type="button" onClick={onPress}>
|
||||
{title}
|
||||
{subTitle}
|
||||
{iconAfter}
|
||||
</button>
|
||||
),
|
||||
}));
|
||||
|
||||
vi.mock('tamagui', () => ({
|
||||
Separator: ({ children }: { children?: React.ReactNode }) => <div>{children}</div>,
|
||||
}));
|
||||
|
||||
vi.mock('@tamagui/text', () => ({
|
||||
SizableText: ({ children }: { children: React.ReactNode }) => <span>{children}</span>,
|
||||
}));
|
||||
@@ -226,6 +258,7 @@ vi.mock('../theme', () => ({
|
||||
},
|
||||
useAdminTheme: () => ({
|
||||
textStrong: '#0f172a',
|
||||
text: '#0f172a',
|
||||
muted: '#64748b',
|
||||
border: '#e2e8f0',
|
||||
surface: '#ffffff',
|
||||
@@ -233,6 +266,13 @@ vi.mock('../theme', () => ({
|
||||
primary: '#ff5a5f',
|
||||
surfaceMuted: '#f8fafc',
|
||||
shadow: 'rgba(15,23,42,0.12)',
|
||||
success: '#16a34a',
|
||||
successText: '#166534',
|
||||
dangerBg: '#fee2e2',
|
||||
dangerText: '#b91c1c',
|
||||
warningBg: '#fef9c3',
|
||||
warningBorder: '#fef08a',
|
||||
warningText: '#92400e',
|
||||
}),
|
||||
}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user