PopupBase
Reusable PopupBase component
Example
import {
Button,
createStyles,
PopupBase,
Typography,
usePopups,
useStyles,
View,
} from '@lad-tech/mobydick-core';
export const PopupBaseWidget = () => {
const [styles] = useStyles(styleFn);
const {openPopup} = usePopups();
return (
<View style={styles.container}>
<Typography font={'Regular-Primary-H5'}>Popup</Typography>
<Button
text={'PopupBase'}
onPress={() =>
openPopup({
Content: props => <PopupBase {...props}></PopupBase>,
})
}
/>
</View>
);
};
const styleFn = createStyles(({spaces}) => ({
container: {
gap: spaces.Space8,
},
}));
Props
RequiredonClose
TYPE |
---|
() => void |
Function for close PopupBase
overlayStyle
TYPE |
---|
ViewStyle |
Custom styles for PopupBase