@react-stately/disclosure
Advanced tools
Comparing version 3.0.0-nightly-bebc9764a-241010 to 3.0.0-nightly-c53ab48ec-250115
@@ -1,2 +0,2 @@ | ||
import { Expandable, Key } from "@react-types/shared"; | ||
import { Key } from "@react-types/shared"; | ||
export interface DisclosureProps { | ||
@@ -27,3 +27,3 @@ /** Whether the disclosure is expanded (controlled). */ | ||
export function useDisclosureState(props: DisclosureProps): DisclosureState; | ||
export interface DisclosureGroupProps extends Expandable { | ||
export interface DisclosureGroupProps { | ||
/** Whether multiple items can be expanded at the same time. */ | ||
@@ -33,2 +33,8 @@ allowsMultipleExpanded?: boolean; | ||
isDisabled?: boolean; | ||
/** The currently expanded keys in the group (controlled). */ | ||
expandedKeys?: Iterable<Key>; | ||
/** The initial expanded keys in the group (uncontrolled). */ | ||
defaultExpandedKeys?: Iterable<Key>; | ||
/** Handler that is called when items are expanded or collapsed. */ | ||
onExpandedChange?: (keys: Set<Key>) => any; | ||
} | ||
@@ -35,0 +41,0 @@ export interface DisclosureGroupState { |
{ | ||
"name": "@react-stately/disclosure", | ||
"version": "3.0.0-nightly-bebc9764a-241010", | ||
"version": "3.0.0-nightly-c53ab48ec-250115", | ||
"description": "Spectrum UI components in React", | ||
@@ -25,13 +25,12 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@react-stately/utils": "^3.0.0-nightly-bebc9764a-241010", | ||
"@react-types/shared": "^3.0.0-nightly-bebc9764a-241010", | ||
"@react-stately/utils": "3.0.0-nightly-c53ab48ec-250115", | ||
"@react-types/shared": "3.0.0-nightly-c53ab48ec-250115", | ||
"@swc/helpers": "^0.5.0" | ||
}, | ||
"peerDependencies": { | ||
"react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0" | ||
"react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" | ||
}, | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"stableVersion": "3.0.0-alpha.0" | ||
} | ||
} |
@@ -13,11 +13,17 @@ /* | ||
import {Expandable, Key} from '@react-types/shared'; | ||
import {Key} from '@react-types/shared'; | ||
import {useControlledState} from '@react-stately/utils'; | ||
import {useEffect, useMemo} from 'react'; | ||
export interface DisclosureGroupProps extends Expandable { | ||
export interface DisclosureGroupProps { | ||
/** Whether multiple items can be expanded at the same time. */ | ||
allowsMultipleExpanded?: boolean, | ||
/** Whether all items are disabled. */ | ||
isDisabled?: boolean | ||
isDisabled?: boolean, | ||
/** The currently expanded keys in the group (controlled). */ | ||
expandedKeys?: Iterable<Key>, | ||
/** The initial expanded keys in the group (uncontrolled). */ | ||
defaultExpandedKeys?: Iterable<Key>, | ||
/** Handler that is called when items are expanded or collapsed. */ | ||
onExpandedChange?: (keys: Set<Key>) => any | ||
} | ||
@@ -24,0 +30,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
43358
519
+ Added@react-stately/utils@3.0.0-nightly-c53ab48ec-250115(transitive)
+ Added@react-types/shared@3.0.0-nightly-c53ab48ec-250115(transitive)
- Removed@react-stately/utils@3.10.5(transitive)
- Removed@react-types/shared@3.27.0(transitive)