CSS :indeterminate

The :indeterminate CSS pseudo-class represents any <input> element that is in an indeterminate state. This state typically occurs in checkboxes or radio buttons when the element's checked or selected status is neither true nor false, but in an indeterminate state.

This pseudo-class is commonly used in situations where an indeterminate state needs to be visually represented to the user.

Syntax:

:indeterminate {
  /* CSS properties */
}

Example:

Result:

In this example, the :indeterminate pseudo-class is applied to a checkbox element, which causes it to be displayed in an indeterminate state.