Skip to content

move Constants file to commons folder #1718

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Dec 12, 2021
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
38 changes: 38 additions & 0 deletions generatedTypes/src/commons/Constants.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
export declare enum orientations {
PORTRAIT = "portrait",
LANDSCAPE = "landscape"
}
export declare function updateConstants(dimensions: any): void;
declare const constants: {
orientations: typeof orientations;
isAndroid: boolean;
isIOS: boolean;
getAndroidVersion: () => number | undefined;
readonly statusBarHeight: number;
isRTL: boolean;
readonly orientation: orientations;
readonly isLandscape: boolean;
readonly screenWidth: number;
readonly screenHeight: number;
readonly windowWidth: number;
readonly windowHeight: number;
readonly isSmallScreen: boolean;
readonly isShortScreen: boolean;
readonly screenAspectRatio: number;
isTablet: boolean;
getSafeAreaInsets: () => {
left: number;
right: number;
bottom: number;
top: number;
};
readonly isIphoneX: boolean;
addDimensionsEventListener: (callback: any) => void;
removeDimensionsEventListener: (callback: any) => void;
readonly accessibility: {
isScreenReaderEnabled: boolean;
};
backspaceKey: string;
enterKey: string;
};
export default constants;
1 change: 1 addition & 0 deletions generatedTypes/src/commons/new.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ export { default as asBaseComponent, BaseComponentInjectedProps } from './asBase
export { default as forwardRef, ForwardRefInjectedProps } from './forwardRef';
export { default as withScrollEnabler, WithScrollEnablerProps } from './withScrollEnabler';
export { default as withScrollReached, WithScrollReachedProps } from './withScrollReached';
export { default as Constants } from './Constants';
export { ContainerModifiers, MarginModifiers, PaddingModifiers, TypographyModifiers, ColorsModifiers, BackgroundColorModifier } from './modifiers';
1 change: 0 additions & 1 deletion generatedTypes/src/helpers/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
import * as AvatarHelper from './AvatarHelper';
export { default as Constants } from './Constants';
export { AvatarHelper };
2 changes: 1 addition & 1 deletion generatedTypes/src/hooks/useOrientation/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ interface UseOrientationProps {
onOrientationChange?: Function;
}
declare const useOrientation: ({ onOrientationChange }?: UseOrientationProps) => {
orientation: import("../../helpers/Constants").orientations;
orientation: import("../../commons/Constants").orientations;
};
export default useOrientation;
6 changes: 3 additions & 3 deletions generatedTypes/src/incubator/TextField/usePreset.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ export default function usePreset({ preset, ...props }: InternalTextFieldProps):
selectionState?: import("react-native").DocumentSelectionState | undefined;
spellCheck?: boolean | undefined;
textContentType?: "none" | "name" | "password" | "username" | "URL" | "addressCity" | "addressCityAndState" | "addressState" | "countryName" | "creditCardNumber" | "emailAddress" | "familyName" | "fullStreetAddress" | "givenName" | "jobTitle" | "location" | "middleName" | "namePrefix" | "nameSuffix" | "nickname" | "organizationName" | "postalCode" | "streetAddressLine1" | "streetAddressLine2" | "sublocality" | "telephoneNumber" | "newPassword" | "oneTimeCode" | undefined;
autoCompleteType?: "name" | "password" | "username" | "email" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
autoCompleteType?: "name" | "email" | "password" | "username" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
importantForAutofill?: "auto" | "yes" | "no" | "noExcludeDescendants" | "yesExcludeDescendants" | undefined;
disableFullscreenUI?: boolean | undefined;
inlineImageLeft?: string | undefined;
Expand Down Expand Up @@ -457,7 +457,7 @@ export default function usePreset({ preset, ...props }: InternalTextFieldProps):
selectionState?: import("react-native").DocumentSelectionState | undefined;
spellCheck?: boolean | undefined;
textContentType?: "none" | "name" | "password" | "username" | "URL" | "addressCity" | "addressCityAndState" | "addressState" | "countryName" | "creditCardNumber" | "emailAddress" | "familyName" | "fullStreetAddress" | "givenName" | "jobTitle" | "location" | "middleName" | "namePrefix" | "nameSuffix" | "nickname" | "organizationName" | "postalCode" | "streetAddressLine1" | "streetAddressLine2" | "sublocality" | "telephoneNumber" | "newPassword" | "oneTimeCode" | undefined;
autoCompleteType?: "name" | "password" | "username" | "email" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
autoCompleteType?: "name" | "email" | "password" | "username" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
importantForAutofill?: "auto" | "yes" | "no" | "noExcludeDescendants" | "yesExcludeDescendants" | undefined;
disableFullscreenUI?: boolean | undefined;
inlineImageLeft?: string | undefined;
Expand Down Expand Up @@ -899,7 +899,7 @@ export default function usePreset({ preset, ...props }: InternalTextFieldProps):
selectionState?: import("react-native").DocumentSelectionState | undefined;
spellCheck?: boolean | undefined;
textContentType?: "none" | "name" | "password" | "username" | "URL" | "addressCity" | "addressCityAndState" | "addressState" | "countryName" | "creditCardNumber" | "emailAddress" | "familyName" | "fullStreetAddress" | "givenName" | "jobTitle" | "location" | "middleName" | "namePrefix" | "nameSuffix" | "nickname" | "organizationName" | "postalCode" | "streetAddressLine1" | "streetAddressLine2" | "sublocality" | "telephoneNumber" | "newPassword" | "oneTimeCode" | undefined;
autoCompleteType?: "name" | "password" | "username" | "email" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
autoCompleteType?: "name" | "email" | "password" | "username" | "cc-csc" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-number" | "postal-code" | "street-address" | "tel" | "off" | undefined;
importantForAutofill?: "auto" | "yes" | "no" | "noExcludeDescendants" | "yesExcludeDescendants" | undefined;
disableFullscreenUI?: boolean | undefined;
inlineImageLeft?: string | undefined;
Expand Down
2 changes: 1 addition & 1 deletion lib/components/WheelPicker/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React, {Component} from 'react';
import {DeviceEventEmitter, requireNativeComponent, StyleSheet, View, ViewStyle, TextStyle} from 'react-native';

import WheelPickerItem from './WheelPickerItem';
import {Constants} from '../../../src/helpers';
import {Constants} from '../../../src/commons/new';
import {Typography, Colors} from '../../../src/style';

import {PickerPackage, CommunityPickerPackage} from '../../../src/optionalDependencies';
Expand Down
File renamed without changes.
3 changes: 3 additions & 0 deletions src/commons/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ module.exports = {
get UIComponent() {
return require('./UIComponent').default;
},
get Constants() {
return require('./Constants').default;
},
get asBaseComponent() {
return require('./asBaseComponent').default;
},
Expand Down
1 change: 1 addition & 0 deletions src/commons/new.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ export {default as asBaseComponent, BaseComponentInjectedProps} from './asBaseCo
export {default as forwardRef, ForwardRefInjectedProps} from './forwardRef';
export {default as withScrollEnabler, WithScrollEnablerProps} from './withScrollEnabler';
export {default as withScrollReached, WithScrollReachedProps} from './withScrollReached';
export {default as Constants} from './Constants';

export {
ContainerModifiers,
Expand Down
2 changes: 1 addition & 1 deletion src/commons/withScrollReached.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React, {useState, useCallback} from 'react';
import {FlatListProps, ScrollViewProps, NativeSyntheticEvent, NativeScrollEvent} from 'react-native';
import forwardRef, {ForwardRefInjectedProps} from './forwardRef';
import hoistStatics from 'hoist-non-react-statics';
import {Constants} from '../helpers';
import Constants from './Constants';

type ScrollReachedProps = {
onScroll: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
Expand Down
3 changes: 1 addition & 2 deletions src/components/actionSheet/index.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
import _ from 'lodash';
import React, {Component} from 'react';
import {ActionSheetIOS, StyleSheet, StyleProp, ViewStyle, ImageProps, ImageSourcePropType} from 'react-native';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import {asBaseComponent} from '../../commons/new';
import {asBaseComponent, Constants} from '../../commons/new';
import Dialog, {DialogProps} from '../dialog';
import View from '../view';
import Text from '../text';
Expand Down
2 changes: 1 addition & 1 deletion src/components/button/__tests__/index.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import renderer from 'react-test-renderer';
import Button from '../index';
import {Colors, ThemeManager} from '../../../style';
import {Constants} from '../../../helpers';
import {Constants} from '../../../commons';

describe('Button', () => {
beforeEach(() => {
Expand Down
3 changes: 1 addition & 2 deletions src/components/button/index.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import _ from 'lodash';
import React, {PureComponent} from 'react';
import {Platform, StyleSheet, LayoutAnimation, LayoutChangeEvent, ImageStyle} from 'react-native';
import {asBaseComponent, forwardRef} from '../../commons/new';
import {Constants} from 'helpers';
import {asBaseComponent, forwardRef, Constants} from '../../commons/new';
import {Colors, Typography, BorderRadiuses} from 'style';
// @ts-ignore need to migrate to commonsNew
import {modifiers} from 'commons';
Expand Down
3 changes: 1 addition & 2 deletions src/components/card/index.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import _ from 'lodash';
import React, {PureComponent} from 'react';
import {StyleSheet, Animated, ViewStyle} from 'react-native';
import {Constants} from '../../helpers';
import {Colors, BorderRadiuses} from '../../style';
// import {PureBaseComponent} from '../../commons';
import {asBaseComponent, forwardRef, BaseComponentInjectedProps, ForwardRefInjectedProps} from '../../commons/new';
import {Constants, asBaseComponent, forwardRef, BaseComponentInjectedProps, ForwardRefInjectedProps} from '../../commons/new';
import View, {ViewProps} from '../view';
import TouchableOpacity, {TouchableOpacityProps} from '../touchableOpacity';
import Image from '../image';
Expand Down
2 changes: 1 addition & 1 deletion src/components/carousel/__tests__/index.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react';
import {render} from '@testing-library/react-native';
import {Text, View} from 'react-native';
import {fireOnScroll, fireOnMomentumScrollEnd} from '../../../uilib-test-renderer';
import {Constants} from '../../../helpers';
import {Constants} from '../../../commons';
import Carousel from '../index';

const numberOfPagesShown = 5;
Expand Down
3 changes: 1 addition & 2 deletions src/components/carousel/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ import {
NativeSyntheticEvent,
NativeScrollEvent
} from 'react-native';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import {asBaseComponent} from '../../commons/new';
import {asBaseComponent, Constants} from '../../commons/new';
import View from '../view';
import Text from '../text';
import PageControl from '../pageControl';
Expand Down
2 changes: 1 addition & 1 deletion src/components/chipsInput/__tests__/index.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import _ from 'lodash';
import {Constants} from '../../../helpers';
import {Constants} from '../../../commons';
import {ChipsInput} from '../index';

describe('ChipsInput', () => {
Expand Down
3 changes: 1 addition & 2 deletions src/components/chipsInput/index.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import _ from 'lodash';
import React, {Component} from 'react';
import {NativeModules, StyleSheet, ViewStyle, Image, TextInput, NativeSyntheticEvent, TextInputKeyPressEventData, findNodeHandle, ScrollView, ScrollViewProps, TextInputProps as RNTextInputProps} from 'react-native';
import {Constants} from '../../helpers';
import {Colors, BorderRadiuses, ThemeManager, Typography, Spacings} from '../../style';
import Assets from '../../assets';
import {LogService} from '../../services';
import {asBaseComponent, BaseComponentInjectedProps, TypographyModifiers} from '../../commons/new';
import {Constants, asBaseComponent, BaseComponentInjectedProps, TypographyModifiers} from '../../commons/new';
// @ts-expect-error
import {TextField} from '../inputs';
import View from '../view';
Expand Down
3 changes: 1 addition & 2 deletions src/components/colorPalette/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@ import _ from 'lodash';
import memoize from 'memoize-one';
import React, {PureComponent} from 'react';
import {StyleSheet, UIManager, findNodeHandle, StyleProp, ViewStyle} from 'react-native';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import View from '../view';
import Carousel from '../carousel';
import ScrollBar from '../scrollBar';
Expand Down
3 changes: 1 addition & 2 deletions src/components/colorPicker/ColorPickerDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ import {
ViewStyle,
EmitterSubscription
} from 'react-native';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import Assets from '../../assets';
import {Colors, Typography} from '../../style';
import View from '../view';
Expand Down
3 changes: 1 addition & 2 deletions src/components/colorSwatch/index.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
import React, {PureComponent} from 'react';
import {StyleSheet, Animated, Easing, LayoutChangeEvent, StyleProp, ViewStyle} from 'react-native';
import Assets from '../../assets';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import View from '../view';
import TouchableOpacity from '../touchableOpacity';
import Image from '../image';
Expand Down
3 changes: 1 addition & 2 deletions src/components/connectionStatusBar/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@ import React, {PureComponent} from 'react';
import _ from 'lodash';
import {StyleSheet, Text} from 'react-native';
import {NetInfoPackage as NetInfo} from '../../optionalDependencies';
import {Constants} from '../../helpers';
import {Colors, Typography} from '../../style';
import TouchableOpacity from '../touchableOpacity';
import View from '../view';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import {ConnectionStatusBarProps, ConnectionStatusBarState, DEFAULT_PROPS} from './Types';
export {ConnectionStatusBarProps};

Expand Down
3 changes: 1 addition & 2 deletions src/components/dateTimePicker/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,9 @@ import moment from 'moment';
import React, {Component} from 'react';
import {StyleProp, StyleSheet, ViewStyle} from 'react-native';
import {DateTimePickerPackage as RNDateTimePicker} from '../../optionalDependencies';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import Assets from '../../assets';
import {asBaseComponent, BaseComponentInjectedProps} from '../../commons/new';
import {Constants, asBaseComponent, BaseComponentInjectedProps} from '../../commons/new';
import TextField from '../textField';
import Dialog, {DialogProps} from '../dialog';
import View from '../view';
Expand Down
2 changes: 1 addition & 1 deletion src/components/dialog/DialogDismissibleView.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import _ from 'lodash';
import React, {useEffect, useRef, useCallback, useContext} from 'react';
import {Animated, Easing, StyleSheet, StyleProp, ViewStyle, LayoutChangeEvent} from 'react-native';
import {Constants} from '../../helpers';
import {Constants} from '../../commons/new';
import View from '../view';
import PanningContext from '../panningViews/panningContext';
import PanningProvider, {
Expand Down
3 changes: 1 addition & 2 deletions src/components/dialog/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@ import _ from 'lodash';
import React, {Component} from 'react';
import {StyleSheet, StyleProp, ViewStyle, ModalPropsIOS, AccessibilityProps} from 'react-native';
import {Colors} from '../../style';
import Constants from '../../helpers/Constants';
import {AlignmentModifiers, extractAlignmentsValues} from '../../commons/modifiers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import Modal from '../modal';
import View from '../view';
import PanListenerView from '../panningViews/panListenerView';
Expand Down
2 changes: 1 addition & 1 deletion src/components/drawer/Swipeable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import React, {Component} from 'react';
import {Animated, StyleSheet, View, I18nManager} from 'react-native';
import {PanGestureHandler, TapGestureHandler, State} from 'react-native-gesture-handler';
import {Constants} from '../../helpers';
import {Constants} from '../../commons/new';
import {HapticService, HapticType} from '../../services';


Expand Down
3 changes: 1 addition & 2 deletions src/components/drawer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ import React, {PureComponent, ReactNode, RefObject} from 'react';
import memoize from 'memoize-one';
import {Animated, Easing, StyleSheet, ViewStyle, TextStyle, AccessibilityActionEvent} from 'react-native';
import {RectButton} from 'react-native-gesture-handler';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import {extractAccessibilityProps} from '../../commons/modifiers';
import {Constants} from '../../helpers';
import {Colors} from '../../style';
import View from '../view';
import Swipeable, {SwipeableProps} from './Swipeable';
Expand Down
5 changes: 2 additions & 3 deletions src/components/featureHighlight/__tests__/index.spec.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import {updateConstants} from '../../../helpers/Constants';
import {updateConstants} from '../../../commons/Constants';
import {testable as FeatureHighlight} from '../';

describe('FeatureHighlight', () => {

beforeEach(() => {
mockScreenDimentions();
});
Expand Down Expand Up @@ -59,7 +58,7 @@ describe('FeatureHighlight', () => {
expect(FeatureHighlight.findTargetNode).toHaveBeenCalledWith(mockTarget);

jest.runAllTimers();

expect(setTimeout).toHaveBeenCalledTimes(1);
expect(mockTarget.measureInWindow).toBeCalled();
});
Expand Down
3 changes: 1 addition & 2 deletions src/components/featureHighlight/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ import {
LayoutChangeEvent
} from 'react-native';
import {Colors, Typography} from '../../style';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import View from '../view';
import Text from '../text';
import Button, {ButtonProps, ButtonSize} from '../button';
Expand Down
3 changes: 1 addition & 2 deletions src/components/floatingButton/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import React, {PropsWithChildren, PureComponent} from 'react';
import {StyleSheet, Animated} from 'react-native';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import {Colors, Spacings} from '../../style';
import View from '../view';
import Button, {ButtonProps} from '../button';
Expand Down
2 changes: 1 addition & 1 deletion src/components/gridView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {Colors, Spacings} from 'style';
import UIComponent from '../../commons/UIComponent';
import View from '../view';
import Text from '../text';
import {Constants} from 'helpers';
import {Constants} from '../../commons/new';
import GridListItem, {GridListItemProps} from '../gridListItem';
import {formatLastItemLabel} from '../../helpers/FormattingPresenter';

Expand Down
3 changes: 1 addition & 2 deletions src/components/hint/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@ import {
View as RNView
} from 'react-native';
import {Typography, Spacings, Colors, BorderRadiuses, Shadows} from '../../style';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import View from '../view';
import Text from '../text';
import Image from '../image';
Expand Down
3 changes: 1 addition & 2 deletions src/components/image/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ import {
NativeSyntheticEvent,
ImageErrorEventData
} from 'react-native';
import Constants from '../../helpers/Constants';
import {asBaseComponent, ForwardRefInjectedProps, BaseComponentInjectedProps, MarginModifiers} from '../../commons/new';
import {Constants, asBaseComponent, ForwardRefInjectedProps, BaseComponentInjectedProps, MarginModifiers} from '../../commons/new';
// @ts-ignore
import Assets from '../../assets';
import Overlay, {OverlayTypeType, OverlayIntensityType} from '../overlay';
Expand Down
3 changes: 1 addition & 2 deletions src/components/loaderScreen/index.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import React, {Component} from 'react';
import {StyleSheet, ActivityIndicator} from 'react-native';
import {Colors, Typography} from '../../style';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import View from '../../components/view';
import Text from '../../components/text';
import {LoaderScreenProps} from './types';
Expand Down
3 changes: 1 addition & 2 deletions src/components/modal/TopBar.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import React, {Component} from 'react';
import {StyleSheet, StyleProp, TextStyle, ImageSourcePropType} from 'react-native';
import {asBaseComponent} from '../../commons/new';
import {Constants} from '../../helpers';
import {Constants, asBaseComponent} from '../../commons/new';
import Assets from '../../assets';
import {Colors, Typography} from '../../style';
import View, {ViewProps} from '../../components/view';
Expand Down
3 changes: 1 addition & 2 deletions src/components/modal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ import {
GestureResponderEvent
} from 'react-native';
import {BlurViewPackage} from '../../optionalDependencies';
import {Constants} from '../../helpers';
import {asBaseComponent} from '../../commons/new';
import {Constants, asBaseComponent} from '../../commons/new';
import TopBar, {ModalTopBarProps} from './TopBar';
import View from '../../components/view';

Expand Down
Loading