Update the application with review
This commit is contained in:
committed by
Lei Nelissen
parent
488c817892
commit
7d54f00811
@@ -22,7 +22,7 @@ const Label = styled.Text<{ active?: boolean }>`
|
||||
display: flex;
|
||||
`;
|
||||
|
||||
function generateListButtonStyles() {
|
||||
function useListButtonStyles() {
|
||||
const styles = useDefaultStyles();
|
||||
return StyleSheet.create({
|
||||
...styles,
|
||||
@@ -40,7 +40,7 @@ function generateListButtonStyles() {
|
||||
}
|
||||
|
||||
const ListButton: React.FC<TouchableOpacityProps> = ({ children, ...props }) => {
|
||||
const defaultStyles = generateListButtonStyles();
|
||||
const defaultStyles = useListButtonStyles();
|
||||
const [isPressed, setPressed] = useState(false);
|
||||
const handlePressIn = useCallback(() => setPressed(true), []);
|
||||
const handlePressOut = useCallback(() => setPressed(false), []);
|
||||
|
||||
@@ -4,6 +4,7 @@ import { useNavigation, StackActions } from '@react-navigation/native';
|
||||
import useDefaultStyles from './Colors';
|
||||
|
||||
interface Props {
|
||||
children?: any;
|
||||
fullSize?: boolean;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user