Skip to content

Commit

Permalink
Pixel perfect styles - native and web
Browse files Browse the repository at this point in the history
  • Loading branch information
MaciejSWM committed Mar 4, 2024
1 parent 1297a40 commit 80bafbc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
5 changes: 3 additions & 2 deletions src/components/OnboardingWelcomeVideo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,13 @@ function OnboardingWelcomeVideo() {
isVisible={isModalVisible}
type={shouldUseNarrowLayout ? CONST.MODAL.MODAL_TYPE.CENTERED_SMALL : CONST.MODAL.MODAL_TYPE.BOTTOM_DOCKED}
onClose={closeModal}
innerContainerStyle={shouldUseNarrowLayout ? {} : {paddingTop: MODAL_PADDING, paddingBottom: MODAL_PADDING}}
>
<View
style={styles.WelcomeVideoNavigatorInnerView(shouldUseNarrowLayout)}
style={[shouldUseNarrowLayout ? {width: 500, height: 500} : {}, {maxHeight: '100%'}]}
onLayout={storeContainerDimensions}
>
<View style={{padding: MODAL_PADDING}}>{getWelcomeVideo()}</View>
<View style={shouldUseNarrowLayout ? {padding: MODAL_PADDING} : {paddingHorizontal: MODAL_PADDING}}>{getWelcomeVideo()}</View>
<View style={[shouldUseNarrowLayout ? [styles.mt5, styles.mh8] : [styles.mt3, styles.mh5]]}>
<View style={[shouldUseNarrowLayout ? [styles.gap1, styles.mb8] : [styles.gap2, styles.mb10]]}>
<Text style={styles.textHeroSmall}>{translate('onboarding.welcomeVideo.title')}</Text>
Expand Down
7 changes: 0 additions & 7 deletions src/styles/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1536,13 +1536,6 @@ const styles = (theme: ThemeColors) =>
overflow: 'hidden',
} satisfies ViewStyle),

WelcomeVideoNavigatorInnerView: (shouldUseNarrowLayout: boolean) =>
({
width: shouldUseNarrowLayout ? 500 : '100%',
height: 500,
maxHeight: '100%',
} satisfies ViewStyle),

onlyEmojisText: {
fontSize: variables.fontSizeOnlyEmojis,
lineHeight: variables.fontSizeOnlyEmojisHeight,
Expand Down

0 comments on commit 80bafbc

Please sign in to comment.