import type { HTMLAttributes, InputHTMLAttributes, ReactNode } from "react";
import { createContext, useContext, useId, useState } from "react";
import { cx } from "../../utils/cx.utils";
import { FormContext } from "../form/form.context";
import { Icon } from "../icons/icon";
import { Label } from "../label/label.component";
import "./checkbox.component.css";
interface CheckboxGroupContextValue {
isChecked: (value: string) => boolean;
toggle: (value: string) => void;
disabled: boolean;
}
const CheckboxGroupContext = createContext(null);
/** Props accepted by {@link Checkbox.Group}. */
export interface CheckboxGroupProps extends Omit, "onChange"> {
/** Label rendered above the group, via {@link Label.Form}. */
label: ReactNode;
/**
* Field name to bind to the enclosing `