@react-stately/disclosure
Advanced tools
Comparing version 3.0.0-alpha.0 to 3.0.0-nightly-07431f4b1-241030
@@ -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-alpha.0", | ||
"version": "3.0.0-nightly-07431f4b1-241030", | ||
"description": "Spectrum UI components in React", | ||
@@ -25,4 +25,4 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@react-stately/utils": "^3.10.4", | ||
"@react-types/shared": "^3.25.0", | ||
"@react-stately/utils": "^3.0.0-nightly-07431f4b1-241030", | ||
"@react-types/shared": "^3.0.0-nightly-07431f4b1-241030", | ||
"@swc/helpers": "^0.5.0" | ||
@@ -35,3 +35,4 @@ }, | ||
"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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
43391
519