@gravity-ui/navigation 0.18.0 → 0.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.js +3 -2
- package/build/cjs/index.js.map +1 -1
- package/build/esm/index.js +3 -2
- package/build/esm/index.js.map +1 -1
- package/package.json +1 -1
package/build/esm/index.js
CHANGED
|
@@ -4773,8 +4773,9 @@ const b$i = block('drawer');
|
|
|
4773
4773
|
const TIMEOUT = 300;
|
|
4774
4774
|
const DrawerItem = ({ visible, content, direction, className }) => {
|
|
4775
4775
|
const itemRef = React__default.useRef(null);
|
|
4776
|
-
|
|
4777
|
-
|
|
4776
|
+
const cssDirection = direction === 'left' ? undefined : direction;
|
|
4777
|
+
return (React__default.createElement(CSSTransition, { in: visible, timeout: TIMEOUT, unmountOnExit: true, classNames: b$i('item-transition', { direction: cssDirection }), nodeRef: itemRef },
|
|
4778
|
+
React__default.createElement("div", { ref: itemRef, className: b$i('item', { direction: cssDirection }, className) }, content)));
|
|
4778
4779
|
};
|
|
4779
4780
|
const Drawer = ({ className, children, style, onVeilClick, onEscape, preventScrollBody = true, }) => {
|
|
4780
4781
|
let someItemVisible = false;
|