feature & fix
deskripsi: - new component Clickable - new folder (image) untuk take picture dan imaga preview - fix klik gambar # No Issue
This commit is contained in:
36
components/Clickable/ClickableCustom.tsx
Normal file
36
components/Clickable/ClickableCustom.tsx
Normal file
@@ -0,0 +1,36 @@
|
||||
import { StyleSheet, TouchableOpacity } from "react-native";
|
||||
|
||||
export default function ClickableCustom({
|
||||
children,
|
||||
onPress,
|
||||
disabled,
|
||||
style,
|
||||
...props
|
||||
}: {
|
||||
children: React.ReactNode;
|
||||
onPress: () => void;
|
||||
disabled?: boolean;
|
||||
style?: any;
|
||||
[key: string]: any;
|
||||
}) {
|
||||
return (
|
||||
<>
|
||||
<TouchableOpacity
|
||||
activeOpacity={0.7}
|
||||
onPress={onPress}
|
||||
disabled={disabled}
|
||||
style={[styles.container, style]}
|
||||
{...props}
|
||||
>
|
||||
{children}
|
||||
</TouchableOpacity>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
const styles = StyleSheet.create({
|
||||
container: {
|
||||
width: "100%",
|
||||
height: "auto",
|
||||
},
|
||||
});
|
||||
@@ -33,16 +33,22 @@ import LandscapeFrameUploaded from "./Image/LandscapeFrameUploaded";
|
||||
import DividerCustom from "./Divider/DividerCustom";
|
||||
// Map
|
||||
import MapCustom from "./Map/MapCustom";
|
||||
// Center
|
||||
import CenterCustom from "./Center/CenterCustom";
|
||||
// Clickable
|
||||
import ClickableCustom from "./Clickable/ClickableCustom";
|
||||
|
||||
export {
|
||||
AlertCustom,
|
||||
// Image
|
||||
AvatarCustom,
|
||||
LeftButtonCustom as BackButton,
|
||||
LandscapeFrameUploaded,
|
||||
// Box
|
||||
BaseBox,
|
||||
BoxButtonOnFooter,
|
||||
ButtonCenteredOnly,
|
||||
InformationBox,
|
||||
LeftButtonCustom as BackButton,
|
||||
// Button
|
||||
ButtonCustom,
|
||||
// Drawer
|
||||
@@ -50,8 +56,6 @@ export {
|
||||
MenuDrawerDynamicGrid,
|
||||
// Grid
|
||||
Grid,
|
||||
InformationBox,
|
||||
LandscapeFrameUploaded,
|
||||
// Map
|
||||
MapCustom,
|
||||
// Select
|
||||
@@ -70,4 +74,8 @@ export {
|
||||
ViewWrapper,
|
||||
// Divider
|
||||
DividerCustom,
|
||||
// Center
|
||||
CenterCustom,
|
||||
// Clickable
|
||||
ClickableCustom,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user