Skip to content

Commit

Permalink
Merge pull request #131 from neriyaco/patch-1
Browse files Browse the repository at this point in the history
Add RTL Support to `TimeSelector` Component
  • Loading branch information
farhoudshapouran authored Jan 6, 2025
2 parents bd0cea9 + 744a320 commit e6b839e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/TimeSelector.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useCallback } from 'react';
import { Text, View, StyleSheet } from 'react-native';
import { Text, View, StyleSheet, I18nManager } from 'react-native';
import { useCalendarContext } from '../CalendarContext';
import Wheel from './TimePicker/Wheel';
import { CALENDAR_HEIGHT } from '../enums';
Expand Down Expand Up @@ -69,7 +69,7 @@ const styles = StyleSheet.create({
flex: 1,
},
timePickerContainer: {
flexDirection: 'row',
flexDirection: I18nManager.getConstants().isRTL ? 'row-reverse' : 'row',
alignItems: 'center',
justifyContent: 'center',
width: CALENDAR_HEIGHT / 2,
Expand Down

0 comments on commit e6b839e

Please sign in to comment.