Removed unused code

This commit is contained in:
keannu125 2023-04-16 19:44:16 +08:00
parent 2559c72cd9
commit cecc63eb7e

View file

@ -1,22 +1,9 @@
import * as React from "react"; import * as React from "react";
import { View, Text, TextInput, ScrollView } from "react-native"; import { View, Text, TextInput, ScrollView } from "react-native";
import styles from "../../styles"; import styles from "../../styles";
import { NoteProps, RootDrawerParamList } from "../../Interfaces/Interfaces"; import { NoteProps } from "../../Interfaces/Interfaces";
import ButtonCentered from "../Buttons/ButtonCentered/ButtonCentered";
import { useQueryClient, useMutation } from "react-query";
import { DeleteNote } from "../Api/Api";
import { useNavigation } from "@react-navigation/native";
export default function PublicNote(props: NoteProps) { export default function PublicNote(props: NoteProps) {
const navigation = useNavigation<RootDrawerParamList>();
const queryClient = useQueryClient();
const mutation = useMutation({
mutationFn: DeleteNote,
onSuccess: () => {
queryClient.invalidateQueries("notes");
queryClient.invalidateQueries("public_notes");
},
});
return ( return (
<View style={styles.addnotecont}> <View style={styles.addnotecont}>
<View style={styles.tle}> <View style={styles.tle}>