use mui/lab LoadingButton for CreateWallet
This commit is contained in:
parent
72d9bd453f
commit
af9b10341c
@ -1,6 +1,6 @@
|
|||||||
import { View } from 'react-native';
|
import { View } from 'react-native';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { Button } from 'react-native-paper';
|
import { LoadingButton } from '@mui/lab';
|
||||||
|
|
||||||
import { CreateWalletProps } from '../types';
|
import { CreateWalletProps } from '../types';
|
||||||
import styles from '../styles/stylesheet';
|
import styles from '../styles/stylesheet';
|
||||||
@ -11,14 +11,14 @@ const CreateWallet = ({
|
|||||||
}: CreateWalletProps) => {
|
}: CreateWalletProps) => {
|
||||||
return (
|
return (
|
||||||
<View>
|
<View>
|
||||||
<View style={styles.createWalletContainer}>
|
<View>
|
||||||
<Button
|
<LoadingButton
|
||||||
mode="contained"
|
variant="contained"
|
||||||
loading={isWalletCreating}
|
loading={isWalletCreating}
|
||||||
disabled={isWalletCreating}
|
disabled={isWalletCreating}
|
||||||
onPress={createWalletHandler}>
|
onClick={createWalletHandler}>
|
||||||
{isWalletCreating ? 'Creating' : 'Create Wallet'}
|
{isWalletCreating ? 'Creating' : 'CREATE WALLET'}
|
||||||
</Button>
|
</LoadingButton>
|
||||||
</View>
|
</View>
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
|
@ -3,7 +3,6 @@ import { StyleSheet } from 'react-native';
|
|||||||
const styles = StyleSheet.create({
|
const styles = StyleSheet.create({
|
||||||
createWalletContainer: {
|
createWalletContainer: {
|
||||||
marginTop: 20,
|
marginTop: 20,
|
||||||
width: 150,
|
|
||||||
alignSelf: 'center',
|
alignSelf: 'center',
|
||||||
marginBottom: 40
|
marginBottom: 40
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user