@react-types/checkbox
Advanced tools
+3
-3
| { | ||
| "name": "@react-types/checkbox", | ||
| "version": "3.0.0-rc.2", | ||
| "version": "3.0.0-rc.3", | ||
| "description": "Spectrum UI components in React", | ||
@@ -12,3 +12,3 @@ "license": "Apache-2.0", | ||
| "dependencies": { | ||
| "@react-types/shared": "^3.0.0-rc.2" | ||
| "@react-types/shared": "3.0.0-rc.3" | ||
| }, | ||
@@ -21,3 +21,3 @@ "peerDependencies": { | ||
| }, | ||
| "gitHead": "207e6ee9076905c96638a7f81a367758872e1410" | ||
| "gitHead": "461d6321126ae9b4f1508aa912f7b36bf8a603f8" | ||
| } |
+24
-8
@@ -13,6 +13,14 @@ /* | ||
| import {DOMProps, InputBase, StyleProps} from '@react-types/shared'; | ||
| import { | ||
| AriaLabelingProps, | ||
| AriaValidationProps, | ||
| FocusableDOMProps, | ||
| FocusableProps, | ||
| InputBase, | ||
| StyleProps, | ||
| Validation | ||
| } from '@react-types/shared'; | ||
| import {ReactNode} from 'react'; | ||
| export interface CheckboxBase extends InputBase { | ||
| export interface ToggleProps extends InputBase, Validation, FocusableProps { | ||
| children?: ReactNode, // pass in children to render label | ||
@@ -26,16 +34,24 @@ defaultSelected?: boolean, | ||
| export interface CheckboxProps extends CheckboxBase { | ||
| export interface AriaToggleProps extends ToggleProps, FocusableDOMProps, AriaLabelingProps, AriaValidationProps { | ||
| /** | ||
| * Indeterminism is presentational, when a checkbox is indeterminate, it overrides the selection state. | ||
| * The indeterminate visual representation remains even after subsequent clicks. | ||
| * Identifies the element (or elements) whose contents or presence are controlled by the current element. | ||
| */ | ||
| 'aria-controls'?: string | ||
| } | ||
| export interface CheckboxProps extends ToggleProps { | ||
| /** | ||
| * Indeterminism is presentational only. | ||
| * The indeterminate visual representation remains regardless of user interaction. | ||
| */ | ||
| isIndeterminate?: boolean | ||
| } | ||
| export interface SpectrumCheckboxProps extends CheckboxProps, DOMProps, StyleProps { | ||
| export interface AriaCheckboxProps extends CheckboxProps, AriaToggleProps {} | ||
| export interface SpectrumCheckboxProps extends AriaCheckboxProps, StyleProps { | ||
| /** | ||
| * By default, checkboxes are not emphasized (gray). | ||
| * This prop sets the emphasized style (blue) which provides visual prominence. | ||
| * This prop sets the emphasized style which provides visual prominence. | ||
| */ | ||
| isEmphasized?: boolean | ||
| } |
13864
2.45%49
40%+ Added
- Removed