ordering-ui-react-native 0.18.99 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ordering-ui-react-native",
3
- "version": "0.18.99",
3
+ "version": "0.19.0",
4
4
  "description": "Reusable components made in react native",
5
5
  "main": "src/index.tsx",
6
6
  "author": "ordering.inc",
@@ -209,11 +209,11 @@ const LoginFormUI = (props: LoginParams) => {
209
209
  props.handleChangeTab(val);
210
210
 
211
211
  if (loginTab === 'email') {
212
- scrollRefTab.current?.scrollToEnd({ animated: true });
212
+ scrollRefTab?.current?.scrollToEnd && scrollRefTab.current?.scrollToEnd({ animated: true });
213
213
  }
214
214
 
215
215
  if (loginTab === 'cellphone') {
216
- scrollRefTab.current?.scrollTo({ animated: true });
216
+ scrollRefTab?.current?.scrollTo && scrollRefTab.current?.scrollTo({ animated: true });
217
217
  }
218
218
  };
219
219
 
@@ -159,7 +159,7 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
159
159
  useEffect(() => {
160
160
  if (scrollref?.current) {
161
161
  Keyboard.addListener('keyboardDidShow', () => {
162
- scrollref?.current && scrollref.current.scrollToEnd()
162
+ scrollref?.current?.scrollToEnd && scrollref.current.scrollToEnd()
163
163
  })
164
164
  }
165
165
  }, [scrollref?.current])
@@ -1,6 +1,5 @@
1
1
  import React, { useEffect, useState } from 'react';
2
- import { View, StyleSheet, Dimensions, Linking } from 'react-native';
3
- import { ScrollView, TouchableOpacity } from 'react-native-gesture-handler';
2
+ import { View, StyleSheet, Dimensions, Linking, ScrollView, TouchableOpacity } from 'react-native';
4
3
  import { Placeholder, PlaceholderLine, Fade } from 'rn-placeholder';
5
4
  import NetInfo from '@react-native-community/netinfo';
6
5
  import { useTheme } from 'styled-components/native';