"use client"; import { MethodType } from "./InputForm"; import { Checkbox } from "@/components/ui/checkbox"; interface ScopeCheckboxProps { scope: string; method: MethodType; field: any; } const ScopeItem: React.FC = ({ scope, method, field }) => { return (
{ return checked ? field.onChange([...field.value, scope]) : field.onChange( field.value?.filter((value: string) => value !== scope) ); }} />
); }; export default ScopeItem;