Make the component definitions consistent

This commit is contained in:
IshaVenikar 2024-02-21 11:09:29 +05:30
parent 0bb2785383
commit 5e0d0646b5
4 changed files with 6 additions and 6 deletions

View File

@ -8,13 +8,13 @@ import { addAccount } from '../utils/Accounts';
import styles from '../styles/stylesheet'; import styles from '../styles/stylesheet';
import HDPathDialog from './HDPathDialog'; import HDPathDialog from './HDPathDialog';
const Accounts: React.FC<AccountsProps> = ({ const Accounts = ({
network, network,
accounts, accounts,
updateAccounts, updateAccounts,
currentIndex, currentIndex,
updateIndex: updateId, updateIndex: updateId,
}) => { }: AccountsProps) => {
const navigation = const navigation =
useNavigation<NativeStackNavigationProp<StackParamsList>>(); useNavigation<NativeStackNavigationProp<StackParamsList>>();
const [expanded, setExpanded] = useState(false); const [expanded, setExpanded] = useState(false);

View File

@ -12,11 +12,11 @@ type CustomDialogProps = {
titleText?: string; titleText?: string;
}; };
const DialogComponent: React.FC<CustomDialogProps> = ({ const DialogComponent = ({
visible, visible,
hideDialog, hideDialog,
contentText, contentText,
}) => { }: CustomDialogProps) => {
const words = contentText.split(' '); const words = contentText.split(' ');
return ( return (

View File

@ -5,7 +5,7 @@ import { Text } from 'react-native-paper';
import styles from '../styles/stylesheet'; import styles from '../styles/stylesheet';
import { GridViewProps } from '../types'; import { GridViewProps } from '../types';
const GridView: React.FC<GridViewProps> = ({ words }) => { const GridView = ({ words }: GridViewProps) => {
return ( return (
<View style={styles.gridContainer}> <View style={styles.gridContainer}>
{words.map((word, index) => ( {words.map((word, index) => (

View File

@ -5,7 +5,7 @@ import { List } from 'react-native-paper';
import { NetworkDropdownProps } from '../types'; import { NetworkDropdownProps } from '../types';
import styles from '../styles/stylesheet'; import styles from '../styles/stylesheet';
const NetworkDropdown: React.FC<NetworkDropdownProps> = ({ updateNetwork }) => { const NetworkDropdown = ({ updateNetwork }: NetworkDropdownProps) => {
const [expanded, setExpanded] = useState<boolean>(false); const [expanded, setExpanded] = useState<boolean>(false);
const [selectedNetwork, setSelectedNetwork] = useState<string>('Ethereum'); const [selectedNetwork, setSelectedNetwork] = useState<string>('Ethereum');