fix
deskripsi: - fix page maps - fix ViewWrapper : props styles di tambah # No Issue
This commit is contained in:
@@ -1,9 +1,9 @@
|
|||||||
import { TextCustom, ViewWrapper } from "@/components";
|
import { MapCustom, ViewWrapper } from "@/components";
|
||||||
|
|
||||||
export default function Maps() {
|
export default function Maps() {
|
||||||
return (
|
return (
|
||||||
<ViewWrapper>
|
<ViewWrapper style={{ paddingInline: 0, paddingBlock: 0 }}>
|
||||||
<TextCustom>Maps</TextCustom>
|
<MapCustom height={"100%"} />
|
||||||
</ViewWrapper>
|
</ViewWrapper>
|
||||||
)
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
// components/MapComponent.js
|
// components/MapComponent.js
|
||||||
|
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { StyleSheet, View } from "react-native";
|
import { DimensionValue, StyleSheet, View } from "react-native";
|
||||||
import MapView, { Marker } from "react-native-maps";
|
import MapView, { Marker } from "react-native-maps";
|
||||||
|
|
||||||
interface MapComponentProps {
|
interface MapComponentProps {
|
||||||
@@ -9,7 +9,7 @@ interface MapComponentProps {
|
|||||||
longitude?: number;
|
longitude?: number;
|
||||||
latitudeDelta?: number;
|
latitudeDelta?: number;
|
||||||
longitudeDelta?: number;
|
longitudeDelta?: number;
|
||||||
height?: number;
|
height?: DimensionValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
const MapCustom = ({
|
const MapCustom = ({
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ import {
|
|||||||
ScrollView,
|
ScrollView,
|
||||||
TouchableWithoutFeedback,
|
TouchableWithoutFeedback,
|
||||||
View,
|
View,
|
||||||
|
StyleProp,
|
||||||
|
ViewStyle,
|
||||||
} from "react-native";
|
} from "react-native";
|
||||||
import { SafeAreaView } from "react-native-safe-area-context";
|
import { SafeAreaView } from "react-native-safe-area-context";
|
||||||
|
|
||||||
@@ -15,12 +17,14 @@ interface ViewWrapperProps {
|
|||||||
children: React.ReactNode;
|
children: React.ReactNode;
|
||||||
withBackground?: boolean;
|
withBackground?: boolean;
|
||||||
footerComponent?: React.ReactNode;
|
footerComponent?: React.ReactNode;
|
||||||
|
style?: StyleProp<ViewStyle>;
|
||||||
}
|
}
|
||||||
|
|
||||||
const ViewWrapper = ({
|
const ViewWrapper = ({
|
||||||
children,
|
children,
|
||||||
withBackground = false,
|
withBackground = false,
|
||||||
footerComponent,
|
footerComponent,
|
||||||
|
style,
|
||||||
}: ViewWrapperProps) => {
|
}: ViewWrapperProps) => {
|
||||||
const assetBackground = require("../../assets/images/main-background.png");
|
const assetBackground = require("../../assets/images/main-background.png");
|
||||||
|
|
||||||
@@ -40,14 +44,14 @@ const ViewWrapper = ({
|
|||||||
<ImageBackground
|
<ImageBackground
|
||||||
source={assetBackground}
|
source={assetBackground}
|
||||||
resizeMode="cover"
|
resizeMode="cover"
|
||||||
style={GStyles.imageBackground}
|
style={[GStyles.imageBackground]}
|
||||||
>
|
>
|
||||||
<View style={GStyles.containerWithBackground}>
|
<View style={[GStyles.containerWithBackground, style]}>
|
||||||
{children}
|
{children}
|
||||||
</View>
|
</View>
|
||||||
</ImageBackground>
|
</ImageBackground>
|
||||||
) : (
|
) : (
|
||||||
<View style={GStyles.container}>{children}</View>
|
<View style={[GStyles.container, style]}>{children}</View>
|
||||||
)}
|
)}
|
||||||
</View>
|
</View>
|
||||||
</TouchableWithoutFeedback>
|
</TouchableWithoutFeedback>
|
||||||
|
|||||||
@@ -31,8 +31,8 @@ export default function LoginView() {
|
|||||||
console.log("login user id :", id);
|
console.log("login user id :", id);
|
||||||
|
|
||||||
// router.navigate("/verification");
|
// router.navigate("/verification");
|
||||||
router.navigate(`/(application)/(user)/profile/${id}`);
|
// router.navigate(`/(application)/(user)/profile/${id}`);
|
||||||
// router.navigate("/(application)/(user)/home");
|
router.navigate("/(application)/(user)/home");
|
||||||
// router.navigate(`/(application)/profile/${id}/edit`);
|
// router.navigate(`/(application)/profile/${id}/edit`);
|
||||||
// router.navigate(`/(application)/(user)/portofolio/${id}`)
|
// router.navigate(`/(application)/(user)/portofolio/${id}`)
|
||||||
// router.navigate(`/(application)/(image)/preview-image/${id}`);
|
// router.navigate(`/(application)/(image)/preview-image/${id}`);
|
||||||
|
|||||||
Reference in New Issue
Block a user