import type { JSX } from 'solid-js'; import { createComponent, createEffect, mergeProps } from 'solid-js'; import { omitProps } from 'solid-use/props'; import type { CheckStateRenderProps } from '../../states/create-check-state'; import { CheckStateChild, useCheckState } from '../../states/create-check-state'; import type { HeadlessPropsWithRef, ValidConstructor } from '../../utils/dynamic-prop'; import { createForwardRef } from '../../utils/dynamic-prop'; import { createARIACheckedState, createARIADisabledState, createCheckedState, createDisabledState, } from '../../utils/state-props'; import useEventListener from '../../utils/use-event-listener'; import type { ButtonProps } from '../button'; import { Button } from '../button'; import { useCheckboxContext } from './CheckboxContext'; import { CHECKBOX_INDICATOR } from './tags'; export type CheckboxIndicatorProps = HeadlessPropsWithRef< T, CheckStateRenderProps >; /** * The control the user actually clicks. Carries `role="checkbox"` and `aria- * checked`, which is `"mixed"` while the state is indeterminate. * * Renders a `