@react-types/tabs
Advanced tools
Comparing version
{ | ||
"name": "@react-types/tabs", | ||
"version": "3.0.0-nightly-74cac946a-250317", | ||
"version": "3.0.0-nightly-77b3442e4-250520", | ||
"description": "Spectrum UI components in React", | ||
@@ -12,3 +12,3 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@react-types/shared": "3.0.0-nightly-74cac946a-250317" | ||
"@react-types/shared": "3.0.0-nightly-77b3442e4-250520" | ||
}, | ||
@@ -15,0 +15,0 @@ "peerDependencies": { |
@@ -33,3 +33,3 @@ /* | ||
export interface TabListProps<T> extends CollectionBase<T>, Omit<SingleSelection, 'disallowEmptySelection'> { | ||
export interface TabListProps<T> extends CollectionBase<T>, Omit<SingleSelection, 'disallowEmptySelection' | 'onSelectionChange'> { | ||
/** | ||
@@ -39,3 +39,5 @@ * Whether the TabList is disabled. | ||
*/ | ||
isDisabled?: boolean | ||
isDisabled?: boolean, | ||
/** Handler that is called when the selection changes. */ | ||
onSelectionChange?: (key: Key) => void | ||
} | ||
@@ -60,3 +62,3 @@ | ||
export interface SpectrumTabsProps<T> extends AriaTabListBase, SingleSelection, DOMProps, StyleProps { | ||
export interface SpectrumTabsProps<T> extends AriaTabListBase, Omit<SingleSelection, 'onSelectionChange'>, DOMProps, StyleProps { | ||
/** The children of the `<Tabs>` element. Should include `<TabList>` and `<TabPanels>` elements. */ | ||
@@ -75,3 +77,5 @@ children: ReactNode, | ||
/** The amount of space between the tabs. */ | ||
density?: 'compact' | 'regular' | ||
density?: 'compact' | 'regular', | ||
/** Handler that is called when the selection changes. */ | ||
onSelectionChange?: (key: Key) => void | ||
} | ||
@@ -78,0 +82,0 @@ |
4030
6.7%78
5.41%+ Added
- Removed