Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 1 addition & 3 deletions app/src/components/ButtonsContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
import React from 'react';
import { StyleSheet, View } from 'react-native';

import { shouldShowAesopRedesign } from '@/hooks/useAesopRedesign';

interface ButtonsContainerProps {
children: React.ReactNode;
}
Expand All @@ -20,7 +18,7 @@ export default ButtonsContainer;
const styles = StyleSheet.create({
buttonsContainer: {
display: 'flex',
flexDirection: shouldShowAesopRedesign() ? 'row' : 'column',
flexDirection: 'column',
justifyContent: 'center',
alignItems: 'center',
gap: 10,
Expand Down
3 changes: 1 addition & 2 deletions app/src/components/buttons/AbstractButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import type { ViewProps } from 'tamagui';
import { Button, Text } from 'tamagui';

import { pressedStyle } from '@/components/buttons/pressedStyle';
import { shouldShowAesopRedesign } from '@/hooks/useAesopRedesign';
import analytics from '@/utils/analytics';
import { dinot } from '@/utils/fonts';

Expand Down Expand Up @@ -95,7 +94,7 @@ const styles = StyleSheet.create({
flexDirection: 'row',
flexGrow: 0,
flexShrink: 0,
width: shouldShowAesopRedesign() ? '48%' : '100%',
width: '100%',
display: 'flex',
alignItems: 'center',
rowGap: 12,
Expand Down
5 changes: 0 additions & 5 deletions app/src/components/typography/Additional.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import React from 'react';
import type { TextProps } from 'react-native';
import { StyleSheet, Text } from 'react-native';

import { shouldShowAesopRedesign } from '@/hooks/useAesopRedesign';
import { slate400 } from '@/utils/colors';
import { dinot } from '@/utils/fonts';

Expand All @@ -31,9 +30,5 @@ const styles = StyleSheet.create({
marginTop: 10,
fontFamily: dinot,
textTransform: 'none',
...(shouldShowAesopRedesign() && {
fontSize: 11.5,
textTransform: 'uppercase',
}),
},
});
5 changes: 0 additions & 5 deletions app/src/components/typography/Description.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import { StyleSheet } from 'react-native';
import type { TextProps } from 'tamagui';
import { Text } from 'tamagui';

import { shouldShowAesopRedesign } from '@/hooks/useAesopRedesign';
import { slate500 } from '@/utils/colors';
import { dinot } from '@/utils/fonts';

Expand All @@ -34,9 +33,5 @@ const styles = StyleSheet.create({
lineHeight: 23,
textAlign: 'center',
fontFamily: dinot,
...(shouldShowAesopRedesign() && {
textAlign: 'left',
fontSize: 16,
}),
},
});
15 changes: 0 additions & 15 deletions app/src/hooks/useAesopRedesign.ts

This file was deleted.

30 changes: 0 additions & 30 deletions app/src/navigation/aesop.ts

This file was deleted.

3 changes: 0 additions & 3 deletions app/src/navigation/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import { createNativeStackNavigator } from '@react-navigation/native-stack';

import { DefaultNavBar } from '@/components/NavBar';
import AppLayout from '@/layouts/AppLayout';
import { getAesopScreens } from '@/navigation/aesop';
import devScreens from '@/navigation/devTools';
import documentScreens from '@/navigation/document';
import homeScreens from '@/navigation/home';
Expand All @@ -33,8 +32,6 @@ export const navigationScreens = {
...settingsScreens,
...recoveryScreens,
...devScreens, // allow in production for testing
// add last to override other screens
...getAesopScreens(),
};
const AppNavigation = createNativeStackNavigator({
id: undefined,
Expand Down
139 changes: 0 additions & 139 deletions app/src/screens/aesop/DocumentOnboardingScreen.tsx

This file was deleted.

25 changes: 0 additions & 25 deletions app/tests/src/hooks/useAesopRedesign.test.ts

This file was deleted.

22 changes: 0 additions & 22 deletions app/tests/src/navigation.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,26 +51,4 @@ describe('navigation', () => {
'UnsupportedDocument',
]);
});

describe('Aesop design screen overrides', () => {
beforeEach(() => {
jest.resetModules();
});

it('should use regular passport screens when shouldShowAesopRedesign is false', () => {
const navigationScreens = require('@/navigation').navigationScreens;
expect(
navigationScreens.DocumentOnboarding.options.title,
).toBeUndefined();
});

it('should use aesop design passport screens when shouldShowAesopRedesign is true', () => {
jest.mock('@/hooks/useAesopRedesign', () => ({
shouldShowAesopRedesign: jest.fn().mockReturnValue(true),
}));

const navigationScreens = require('@/navigation').navigationScreens;
expect(navigationScreens.DocumentOnboarding.options.title).toBeDefined();
});
});
});
1 change: 0 additions & 1 deletion app/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@ export default defineConfig({
'screens-settings': ['./src/navigation/settings.ts'],
'screens-recovery': ['./src/navigation/recovery.ts'],
'screens-dev': ['./src/navigation/devTools.ts'],
'screens-aesop': ['./src/navigation/aesop.ts'],
},
},
},
Expand Down
2 changes: 0 additions & 2 deletions docs/development-patterns.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ export const navigationScreens = {
...settingsScreens,
...recoveryScreens,
...devScreens,
// Feature screens added last to override others
...getAesopScreens(),
};

// Platform-specific initial routes
Expand Down
Loading