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: 3 additions & 1 deletion src/pages/settings/Troubleshoot/TroubleshootPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import type {TranslationPaths} from '@src/languages/types';
import ONYXKEYS from '@src/ONYXKEYS';
import ROUTES from '@src/ROUTES';
import SCREENS from '@src/SCREENS';
import getLightbulbIllustrationStyle from './getLightbulbIllustrationStyle';

type BaseMenuItem = {
translationKey: TranslationPaths;
Expand All @@ -50,6 +51,7 @@ function TroubleshootPage({shouldStoreLogs}: TroubleshootPageProps) {
const [isConfirmationModalVisible, setIsConfirmationModalVisible] = useState(false);
const waitForNavigate = useWaitForNavigation();
const {isSmallScreenWidth} = useWindowDimensions();
const illustrationStyle = getLightbulbIllustrationStyle();

const menuItems = useMemo(() => {
const debugConsoleItem: BaseMenuItem = {
Expand Down Expand Up @@ -101,7 +103,7 @@ function TroubleshootPage({shouldStoreLogs}: TroubleshootPageProps) {
isCentralPane
subtitleMuted
illustration={LottieAnimations.Desk}
illustrationStyle={[styles.mt4, styles.mbn4]}
illustrationStyle={illustrationStyle}
titleStyles={styles.accountSettingsSectionTitle}
illustrationBackgroundColor={theme.PAGE_THEMES[SCREENS.SETTINGS.TROUBLESHOOT].backgroundColor}
renderSubtitle={() => (
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import type {ViewStyle} from 'react-native';

// Styling lottie animations for the Lightbulb component requires different margin values depending on the platform.
export default function getLightbulbIllustrationStyle(): ViewStyle {
return {};
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import type {ViewStyle} from 'react-native';

// Styling lottie animations for the Lightbulb component requires different margin values depending on the platform.
export default function getTripIllustrationStyle(): ViewStyle {
return {
marginTop: 16,
marginBottom: -16,
};
}
Comment on lines +4 to +9

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though it worked when introduced, this method was a bit ad-hoc and caused an issue later (see #68592 (comment)). Fixed in PR #68881.