import { Event } from "@prisma/client" import { useMemo } from "react" import { KeyedMutator } from "swr" import { ViewContent } from "../../generic/views/content" export type EventsActionViewProps = { data: Event, mutate: KeyedMutator, } export const EventsActionEdit = ({ data, mutate }: EventsActionViewProps) => { return ( ( mutate({ ...data, name: e.target.value }, { revalidate: false })} /> ), [data.name] ) } content={<> {useMemo( () => (