@szhsin/react-accordion
Advanced tools
Comparing version 0.10.0 to 0.10.1
@@ -41,3 +41,3 @@ 'use strict'; | ||
var _excluded$4 = ["allowMultiple", "transition", "transitionTimeout"]; | ||
var _excluded$4 = ["transition", "transitionTimeout"]; | ||
@@ -50,3 +50,2 @@ var getTransition = function getTransition(transition, name) { | ||
var _ref = _temp === void 0 ? {} : _temp, | ||
allowMultiple = _ref.allowMultiple, | ||
transition = _ref.transition, | ||
@@ -57,3 +56,2 @@ transitionTimeout = _ref.transitionTimeout, | ||
var transitionMap = reactTransitionState.useTransitionMap(_extends({ | ||
singleEnter: !allowMultiple, | ||
timeout: transitionTimeout, | ||
@@ -60,0 +58,0 @@ enter: getTransition(transition, 'enter'), |
import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose, extends as _extends } from '../_virtual/_rollupPluginBabelHelpers.js'; | ||
import { useTransitionMap } from 'react-transition-state'; | ||
var _excluded = ["allowMultiple", "transition", "transitionTimeout"]; | ||
var _excluded = ["transition", "transitionTimeout"]; | ||
@@ -12,3 +12,2 @@ var getTransition = function getTransition(transition, name) { | ||
var _ref = _temp === void 0 ? {} : _temp, | ||
allowMultiple = _ref.allowMultiple, | ||
transition = _ref.transition, | ||
@@ -19,3 +18,2 @@ transitionTimeout = _ref.transitionTimeout, | ||
var transitionMap = useTransitionMap(_extends({ | ||
singleEnter: !allowMultiple, | ||
timeout: transitionTimeout, | ||
@@ -22,0 +20,0 @@ enter: getTransition(transition, 'enter'), |
{ | ||
"name": "@szhsin/react-accordion", | ||
"version": "0.10.0", | ||
"description": "An accessible React accordion library", | ||
"version": "0.10.1", | ||
"description": "An unstyled, fully accessible React accordion library.", | ||
"author": "Zheng Song", | ||
@@ -16,5 +16,3 @@ "license": "MIT", | ||
"dist/", | ||
"types/*.d.ts", | ||
"types/components/", | ||
"types/hooks/" | ||
"types/" | ||
], | ||
@@ -26,3 +24,4 @@ "scripts": { | ||
"watch": "rollup -c -w", | ||
"clean": "rm -rf dist types", | ||
"clean": "rm -Rf dist types", | ||
"post-build": "rm -Rf types/__tests__", | ||
"types": "tsc", | ||
@@ -36,3 +35,3 @@ "lint": "eslint .", | ||
"test:cov": "jest --coverage=true", | ||
"build": "run-s clean pret lint types bundle" | ||
"build": "run-s pret clean lint types bundle post-build" | ||
}, | ||
@@ -44,3 +43,3 @@ "peerDependencies": { | ||
"dependencies": { | ||
"react-transition-state": "^2.0.0-alpha.0" | ||
"react-transition-state": "^2.0.0-alpha.1" | ||
}, | ||
@@ -47,0 +46,0 @@ "devDependencies": { |
@@ -5,5 +5,10 @@ /// <reference types="react" /> | ||
itemRef: import("react").RefObject<E>; | ||
state: import("react-transition-state").TransitionState; | ||
state: Readonly<{ | ||
status: import("react-transition-state").TransitionStatus; | ||
isMounted: boolean; | ||
isEnter: boolean; | ||
isResolved: boolean; | ||
}>; | ||
toggle: (toEnter?: boolean) => void; | ||
}; | ||
export { useAccordionItemState }; |
@@ -5,5 +5,10 @@ import { ItemKey } from '../utils/constants'; | ||
initialEntered?: boolean | undefined; | ||
}) => import("react-transition-state").TransitionState; | ||
}) => Readonly<{ | ||
status: import("react-transition-state").TransitionStatus; | ||
isMounted: boolean; | ||
isEnter: boolean; | ||
isResolved: boolean; | ||
}>; | ||
toggle: (key: ItemKey, toEnter?: boolean | undefined) => void; | ||
}; | ||
export { useAccordionState }; |
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
47671
42
1039