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: 2 additions & 2 deletions src/components/HeaderE235.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { LinearGradient } from 'expo-linear-gradient';
import React, { useMemo } from 'react';
import { Platform, StyleSheet, View } from 'react-native';
import { StyleSheet, View } from 'react-native';
import { STATION_NAME_FONT_SIZE } from '../constants';
import { useLoopLine } from '../hooks';
import isTablet from '../utils/isTablet';
Expand Down Expand Up @@ -220,7 +220,7 @@ const HeaderE235: React.FC<HeaderE235Props> = (props) => {
threeLetterCode={threeLetterCode}
withDarkTheme
allowScaling
transformOrigin={Platform.OS === 'android' ? 'bottom' : undefined}
transformOrigin="bottom"
/>
) : null}
<Typography
Expand Down
4 changes: 2 additions & 2 deletions src/components/HeaderJL.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { LinearGradient } from 'expo-linear-gradient';
import React, { useMemo } from 'react';
import { Platform, StyleSheet, View } from 'react-native';
import { StyleSheet, View } from 'react-native';
import Svg, { Path } from 'react-native-svg';
import { useLoopLine } from '~/hooks';
import { STATION_NAME_FONT_SIZE } from '../constants';
Expand Down Expand Up @@ -223,7 +223,7 @@ const HeaderJL: React.FC<CommonHeaderProps> = (props) => {
threeLetterCode={threeLetterCode}
withDarkTheme
allowScaling
transformOrigin={Platform.OS === 'android' ? 'bottom' : undefined}
transformOrigin="bottom"
/>
) : null}
<Typography
Expand Down
6 changes: 2 additions & 4 deletions src/components/HeaderJRWest.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { Image } from 'expo-image';
import { LinearGradient } from 'expo-linear-gradient';
import React, { useCallback, useMemo } from 'react';
import { Platform, StyleSheet, View } from 'react-native';
import { StyleSheet, View } from 'react-native';
import { LineType, TrainTypeKind } from '~/@types/graphql';
import { useGetLineMark } from '~/hooks';
import {
Expand Down Expand Up @@ -511,9 +511,7 @@ const HeaderJRWest: React.FC<CommonHeaderProps> = (props) => {
threeLetterCode={threeLetterCode}
withDarkTheme
allowScaling
transformOrigin={
Platform.OS === 'android' ? 'bottom' : undefined
}
transformOrigin="bottom"
/>
</View>
) : null}
Expand Down
2 changes: 1 addition & 1 deletion src/components/HeaderSaikyo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ const HeaderSaikyo: React.FC<CommonHeaderProps> = (props) => {
stationNumber={currentStationNumber.stationNumber || ''}
threeLetterCode={threeLetterCode}
allowScaling
transformOrigin={Platform.OS === 'android' ? 'bottom' : undefined}
transformOrigin="bottom"
/>
) : null}
<View style={styles.stationNameWrapper}>
Expand Down
10 changes: 2 additions & 8 deletions src/components/HeaderTY.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
import { LinearGradient } from 'expo-linear-gradient';
import React from 'react';
import {
Platform,
StyleSheet,
Text,
useWindowDimensions,
View,
} from 'react-native';
import { StyleSheet, Text, useWindowDimensions, View } from 'react-native';
import Animated from 'react-native-reanimated';
import { STATION_NAME_FONT_SIZE } from '../constants';
import { useHeaderAnimation } from '../hooks';
Expand Down Expand Up @@ -225,7 +219,7 @@ const HeaderTY: React.FC<CommonHeaderProps> = (props) => {
stationNumber={currentStationNumber.stationNumber || ''}
threeLetterCode={threeLetterCode}
allowScaling
transformOrigin={Platform.OS === 'android' ? 'bottom' : undefined}
transformOrigin="bottom"
withDarkTheme
/>
) : null}
Expand Down
6 changes: 3 additions & 3 deletions src/components/NumberingIconSquare.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const NumberingIconSquare: React.FC<Props> = ({
threeLetterCode,
allowScaling,
size,
transformOrigin = Platform.OS === 'android' ? 'center' : 'bottom',
transformOrigin = 'center',
withOutline,
}: Props) => {
const [lineSymbol, ...stationNumberRest] = stationNumberRaw.split('-');
Expand All @@ -143,7 +143,7 @@ const NumberingIconSquare: React.FC<Props> = ({
style={[
styles.tlcRoot,
{
transformOrigin: transformOrigin,
transformOrigin,
},
]}
>
Expand Down Expand Up @@ -178,7 +178,7 @@ const NumberingIconSquare: React.FC<Props> = ({
style={
allowScaling && {
transform: [{ scale: 0.8 }],
transformOrigin: 'bottom',
transformOrigin,
paddingVertical: isTablet ? 8 : 4,
paddingHorizontal: isTablet ? 8 : 4,
}
Expand Down