react-native-calendar-kit icon indicating copy to clipboard operation
react-native-calendar-kit copied to clipboard

Calendar looks blank in RTL mode

Open fakhergh opened this issue 2 years ago • 9 comments

Hi folks,

I'm working on an application that supports i18n, and I tried to implement calendar-kit. It looks fine on LTR but not on RTL.

Here is screenshot for the issue: Screenshot_1678603907

Current used libraries:

"react-native": "0.70.6" "react": "18.1.0" "@shopify/flash-list": "^1.4.1" "react-native-reanimated": "^2.14.4" "@howljs/calendar-kit": "^1.13.1" ....

Anyone can help or suggest a solution for me? thanks.

fakhergh avatar Mar 12 '23 06:03 fakhergh

@howljs Thank you for this amazing package. I really like it

and could you please help me to solve this issue?

fakhergh avatar Mar 28 '23 03:03 fakhergh

I’m busy with my work at the company right now ☹️ I’ll try to take the time to write this feature later. Sorry

howljs avatar Mar 28 '23 03:03 howljs

Thank you @howljs for your effort.

fakhergh avatar Apr 05 '23 07:04 fakhergh

am facing the same issue @howljs @fakhergh any update on this ?

FadiAboMsalam avatar Apr 17 '23 09:04 FadiAboMsalam

For me what fixed it was using direction: 'ltr' inside the Timeline style for content and container src/components/Timeline/index.tsx

const styles = StyleSheet.create({ container: { flex: 1, direction: 'ltr' }, content: { flexGrow: 1, direction: 'ltr' }, });

Deblancd avatar Apr 27 '23 10:04 Deblancd

@Deblancd i believe that will work on iOS but not android

FadiAboMsalam avatar May 22 '23 08:05 FadiAboMsalam

Yes I am running into this problem as well on android. It seems to work fine on IOS but the schedule does not render properly with RTL on android. Is there any fix to this other than having the user change their system language setting to something that is RTL?

derickdecesare avatar Aug 17 '23 18:08 derickdecesare

adding disableAutoLayout to AnimatedFlashList as props solved the issue.

SwikarBhattarai avatar Feb 20 '24 10:02 SwikarBhattarai

I got around this issue by forcing LTR in my whole application, may not be viable solution for every situation.

In App.js:

import { I18nManager } from 'react-native';

const App = () => { I18nManager.forceRTL(false); I18nManager.allowRTL(false);

derickdecesare avatar Feb 20 '24 17:02 derickdecesare