diff --git a/components/create/details.tsx b/components/create/details.tsx index 983f1ae..edebbd4 100644 --- a/components/create/details.tsx +++ b/components/create/details.tsx @@ -1,6 +1,12 @@ import Tag from "@/components/global/tag"; import Beat from "@/components/global/beat"; -import { View, Text, TextInput, Pressable, ImageBackground } from "react-native"; +import { + View, + Text, + TextInput, + Pressable, + ImageBackground, +} from "react-native"; import { useEffect, useState } from "react"; import { beat } from "@/types"; import { Image } from "expo-image"; @@ -88,11 +94,15 @@ const Details = ({ setImages(allImages); }; - const handleRemoveImage = async (selectedImage: ImagePicker.ImagePickerAsset) => { - const newImages = images.filter(function(image, index) { return image.uri !== selectedImage.uri }); + const handleRemoveImage = async ( + selectedImage: ImagePicker.ImagePickerAsset, + ) => { + const newImages = images.filter(function (image, index) { + return image.uri !== selectedImage.uri; + }); setImages(newImages); - } + }; return ( @@ -173,12 +183,20 @@ const Details = ({ - handleRemoveImage(image)} className="absolute top-1 right-1 rounded-full bg-black"> - - + handleRemoveImage(image)} + className="absolute top-1 right-1 rounded-full bg-black" + > + + );