upd: fiksasi

This commit is contained in:
2026-02-26 17:42:33 +08:00
parent 2a0e1f4c1f
commit aee0823cb1
3 changed files with 22 additions and 24 deletions

View File

@@ -1,6 +1,7 @@
import Styles from "@/constants/Styles"; import Styles from "@/constants/Styles";
import { apiGetDataHome } from "@/lib/api"; import { apiGetDataHome } from "@/lib/api";
import { useAuthSession } from "@/providers/AuthProvider"; import { useAuthSession } from "@/providers/AuthProvider";
import { useTheme } from "@/providers/ThemeProvider";
import { router } from "expo-router"; import { router } from "expo-router";
import React, { useEffect, useState } from "react"; import React, { useEffect, useState } from "react";
import { Dimensions, View } from "react-native"; import { Dimensions, View } from "react-native";
@@ -10,7 +11,6 @@ import PaperGridContent from "../paperGridContent";
import ProgressBar from "../progressBar"; import ProgressBar from "../progressBar";
import Skeleton from "../skeleton"; import Skeleton from "../skeleton";
import Text from "../Text"; import Text from "../Text";
import { useTheme } from "@/providers/ThemeProvider";
type Props = { type Props = {
id: string id: string
@@ -52,7 +52,7 @@ export default function ProjectHome({ refreshing }: { refreshing: boolean }) {
}, []); }, []);
return ( return (
<View style={[Styles.mb15]}> <View style={[Styles.mb05]}>
<Text style={[Styles.textDefaultSemiBold, Styles.mb10]}>Kegiatan Terupdate</Text> <Text style={[Styles.textDefaultSemiBold, Styles.mb10]}>Kegiatan Terupdate</Text>
{ {
loading ? (<Skeleton width={100} height={150} borderRadius={10} widthType="percent" />) loading ? (<Skeleton width={100} height={150} borderRadius={10} widthType="percent" />)
@@ -62,7 +62,7 @@ export default function ProjectHome({ refreshing }: { refreshing: boolean }) {
ref={ref} ref={ref}
style={{ width: "100%" }} style={{ width: "100%" }}
width={width * 0.8} width={width * 0.8}
height={235} height={220}
data={data} data={data}
loop={false} loop={false}
autoPlay={false} autoPlay={false}

View File

@@ -22,7 +22,7 @@ export default function PaperGridContent({ content, children, title, headerColor
const bgSource = activeTheme === 'light' ? bgLight : bgDark; const bgSource = activeTheme === 'light' ? bgLight : bgDark;
return ( return (
<Pressable onPress={onPress}> <Pressable onPress={onPress}>
<View style={[content == 'carousel' ? Styles.wrapGridCaraousel : Styles.wrapGridContent]}> <View style={[content == 'carousel' ? Styles.wrapGridCaraousel : Styles.wrapGridContent, { backgroundColor: colors.card }]}>
{ {
headerColor == 'warning' ? ( headerColor == 'warning' ? (
<View style={[Styles.headerPaperGrid, ColorsStatus.warning]}> <View style={[Styles.headerPaperGrid, ColorsStatus.warning]}>
@@ -41,7 +41,6 @@ export default function PaperGridContent({ content, children, title, headerColor
} }
<View style={[ <View style={[
contentPosition && contentPosition == 'top' ? Styles.contentPaperGrid2 : Styles.contentPaperGrid, contentPosition && contentPosition == 'top' ? Styles.contentPaperGrid2 : Styles.contentPaperGrid,
{ backgroundColor: colors.card },
height ? { height: height } : {} height ? { height: height } : {}
]}> ]}>
{children} {children}

View File

@@ -392,10 +392,10 @@ const Styles = StyleSheet.create({
}, },
wrapGridContent: { wrapGridContent: {
shadowColor: '#171717', shadowColor: '#171717',
shadowOffset: { width: 0, height: 4 }, shadowOffset: { width: 0, height: 0 },
shadowOpacity: 0.1, shadowOpacity: 0.1,
shadowRadius: 10, shadowRadius: 5,
elevation: 5, elevation: 2,
borderRadius: 5, borderRadius: 5,
marginBottom: 15 marginBottom: 15
}, },
@@ -403,12 +403,13 @@ const Styles = StyleSheet.create({
width: '95%', width: '95%',
height: 200, height: 200,
shadowColor: '#171717', shadowColor: '#171717',
shadowOffset: { width: 0, height: 4 }, shadowOffset: { width: 0, height: 0 },
shadowOpacity: 0.1, shadowOpacity: 0.1,
shadowRadius: 4, shadowRadius: 5,
elevation: 5, elevation: 2,
borderRadius: 5, borderRadius: 5,
marginLeft: 5 marginLeft: 5,
display: 'flex',
}, },
headerPaperGrid: { headerPaperGrid: {
paddingVertical: 25, paddingVertical: 25,
@@ -418,15 +419,13 @@ const Styles = StyleSheet.create({
borderTopEndRadius: 5 borderTopEndRadius: 5
}, },
contentPaperGrid: { contentPaperGrid: {
backgroundColor: 'white', height: 125,
height: 150,
borderBottomEndRadius: 5, borderBottomEndRadius: 5,
borderBottomStartRadius: 5, borderBottomStartRadius: 5,
paddingHorizontal: 20, paddingHorizontal: 20,
justifyContent: 'space-evenly' justifyContent: 'space-evenly'
}, },
contentPaperGrid2: { contentPaperGrid2: {
backgroundColor: 'white',
height: 100, height: 100,
borderBottomEndRadius: 5, borderBottomEndRadius: 5,
borderBottomStartRadius: 5, borderBottomStartRadius: 5,
@@ -455,8 +454,8 @@ const Styles = StyleSheet.create({
shadowColor: '#171717', shadowColor: '#171717',
shadowOffset: { width: 0, height: 0 }, shadowOffset: { width: 0, height: 0 },
shadowOpacity: 0.1, shadowOpacity: 0.1,
shadowRadius: 4, shadowRadius: 5,
elevation: 5, elevation: 2,
}, },
noShadow: { noShadow: {
shadowColor: 'transparent', shadowColor: 'transparent',
@@ -469,8 +468,8 @@ const Styles = StyleSheet.create({
shadowColor: '#171717', shadowColor: '#171717',
shadowOffset: { width: 0, height: 0 }, shadowOffset: { width: 0, height: 0 },
shadowOpacity: 0.1, shadowOpacity: 0.1,
shadowRadius: 4, shadowRadius: 5,
elevation: 5, elevation: 2,
}, },
contentItemCenter: { contentItemCenter: {
justifyContent: 'center', justifyContent: 'center',
@@ -749,10 +748,10 @@ const Styles = StyleSheet.create({
}, },
wrapHomeCarousel: { wrapHomeCarousel: {
shadowColor: '#171717', shadowColor: '#171717',
shadowOffset: { width: 0, height: 5 }, shadowOffset: { width: 0, height: 4 },
shadowOpacity: 0.2, shadowOpacity: 0.15,
shadowRadius: 5, shadowRadius: 8,
elevation: 50, elevation: 5,
}, },
modalOverlay: { modalOverlay: {
flex: 1, flex: 1,
@@ -764,7 +763,7 @@ const Styles = StyleSheet.create({
width: '80%', width: '80%',
borderRadius: 14, borderRadius: 14,
overflow: 'hidden', overflow: 'hidden',
elevation: 5, elevation: 2,
shadowColor: '#000', shadowColor: '#000',
shadowOffset: { width: 0, height: 2 }, shadowOffset: { width: 0, height: 2 },
shadowOpacity: 0.25, shadowOpacity: 0.25,