From 4163ea23d150319d2c838d9c870a21aee5a81b3a Mon Sep 17 00:00:00 2001 From: Yauheni Pasiukevich Date: Fri, 25 Aug 2023 10:31:53 +0200 Subject: [PATCH] migrate optionRowStyles to ts --- .../optionRowStyles/{index.native.js => index.native.ts} | 3 ++- src/styles/optionRowStyles/{index.js => index.ts} | 3 ++- src/styles/optionRowStyles/types.ts | 6 ++++++ 3 files changed, 10 insertions(+), 2 deletions(-) rename src/styles/optionRowStyles/{index.native.js => index.native.ts} (76%) rename src/styles/optionRowStyles/{index.js => index.ts} (53%) create mode 100644 src/styles/optionRowStyles/types.ts diff --git a/src/styles/optionRowStyles/index.native.js b/src/styles/optionRowStyles/index.native.ts similarity index 76% rename from src/styles/optionRowStyles/index.native.js rename to src/styles/optionRowStyles/index.native.ts index b95382777f7e..11371509ce73 100644 --- a/src/styles/optionRowStyles/index.native.js +++ b/src/styles/optionRowStyles/index.native.ts @@ -1,3 +1,4 @@ +import OptionRowStyles from './types'; import styles from '../styles'; /** @@ -7,7 +8,7 @@ import styles from '../styles'; * https://github.com/Expensify/App/issues/14148 */ -const compactContentContainerStyles = styles.alignItemsCenter; +const compactContentContainerStyles: OptionRowStyles = styles.alignItemsCenter; export { // eslint-disable-next-line import/prefer-default-export diff --git a/src/styles/optionRowStyles/index.js b/src/styles/optionRowStyles/index.ts similarity index 53% rename from src/styles/optionRowStyles/index.js rename to src/styles/optionRowStyles/index.ts index 2bef2a0cd094..fbeca3c702d9 100644 --- a/src/styles/optionRowStyles/index.js +++ b/src/styles/optionRowStyles/index.ts @@ -1,6 +1,7 @@ +import OptionRowStyles from './types'; import styles from '../styles'; -const compactContentContainerStyles = styles.alignItemsBaseline; +const compactContentContainerStyles: OptionRowStyles = styles.alignItemsBaseline; export { // eslint-disable-next-line import/prefer-default-export diff --git a/src/styles/optionRowStyles/types.ts b/src/styles/optionRowStyles/types.ts new file mode 100644 index 000000000000..c08174470701 --- /dev/null +++ b/src/styles/optionRowStyles/types.ts @@ -0,0 +1,6 @@ +import {CSSProperties} from 'react'; +import {ViewStyle} from 'react-native'; + +type OptionRowStyles = CSSProperties | ViewStyle; + +export default OptionRowStyles;