Skip to content

Commit

Permalink
Add missing disabled property to SegmentedControlOwnProps interface (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
David Kiss committed Sep 1, 2020
1 parent ecdf5d3 commit 0900ef0
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1407,12 +1407,40 @@ export type SearchTableHeaderCellProps = PolymorphicBoxProps<'div', SearchTableH
export declare const SearchTableHeaderCell: BoxComponent<SearchTableHeaderCellOwnProps, 'div'>

export interface SegmentedControlOwnProps {
/**
* The options (elements) displayed by the segmented control
*/
options: Array<{ label: string, value: NonNullable<SegmentedControlOwnProps['value']> }>

/**
* The value of the segmented control
*/
value?: number | string | boolean

/**
* The initial value of an uncontrolled segmented control
*/
defaultValue?: number | string | boolean

/**
* Function called when value changes.
*/
onChange: (value: NonNullable<SegmentedControlOwnProps['value']>) => void

/**
* The name attribute of the segmented control
*/
name?: string

/**
* The height of the segmented control
*/
height?: number

/**
* Whether or not the component is disabled
*/
disabled?: boolean
}

export type SegmentedControlProps = PolymorphicBoxProps<'div', SegmentedControlOwnProps>
Expand Down

0 comments on commit 0900ef0

Please sign in to comment.