npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

dw-neit-rc-drawer

v7.2.0

Published

drawer component for react

Downloads

42

Readme

dw-neit-rc-drawer

NPM version dumi build status codecov node version npm download

Example

https://drawer-react-component.vercel.app/

Usage

import Drawer from 'dw-neit-rc-drawer';
import React from 'react';
import ReactDom from 'react-dom';

ReactDom.render(
  <Drawer>
    {menu children}
  </Drawer>
, mountNode);

Install

dw-neit-rc-drawer

Browser Support

| IE | Chrome | Firefox | Opera | Safari | | ------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | | IE 10+ ✔ | Chrome 31.0+ ✔ | Firefox 31.0+ ✔ | Opera 30.0+ ✔ | Safari 7.0+ ✔ |

API

| props | type | default | description | | ------------------ | --------------------------------------------------------------------------- | -------------------------------------- | ----------------------------------------------------------------------------- | | className | string | null | - | | classNames | { mask?: string; content?: string; wrapper?: string; } | - | pass className to target area | | styles | { mask?: CSSProperties; content?: CSSProperties; wrapper?: CSSProperties; } | - | pass style to target area | | prefixCls | string | 'drawer' | prefix class | | width | string | number | null | drawer content wrapper width, drawer level transition width | | height | string | number | null | drawer content wrapper height, drawer level transition height | | open | boolean | false | open or close menu | | defaultOpen | boolean | false | default open menu | | placement | string | left | left top right bottom | | level | string | array | all | With the drawer level element. all/ null / className / id / tagName / array | | levelMove | number | array | func | null | level move value. default is drawer width | | duration | string | .3s | level animation duration | | ease | string | cubic-bezier(0.78, 0.14, 0.15, 0.86) | level animation timing function | | getContainer | string | func | HTMLElement | body | Return the mount node for Drawer. if is null use React.creactElement | | showMask | boolean | true | mask is show | | maskClosable | boolean | true | Clicking on the mask (area outside the Drawer) to close the Drawer or not. | | maskStyle | CSSProperties | null | mask style | | afterVisibleChange | func | null | transition end callback(open) | | onClose | func | null | close click function | | keyboard | boolean | true | Whether support press esc to close | | autoFocus | boolean | true | Whether focusing on the drawer after it opened | | onMouseEnter | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse enter drawer panel | | onMouseOver | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse over drawer panel | | onMouseLeave | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse leave drawer panel | | onClick | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse click drawer panel | | onKeyDown | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse keydown on drawer panel | | onKeyUp | React.MouseEventHandler<HTMLDivElement> | - | Trigger when mouse keyup on drawer panel |

2.0 Rename onMaskClick -> onClose, add maskClosable.

Development

npm install
npm start