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

@kenshooui/react-menu

v4.0.5

Published

React Menu

Downloads

1,984

Readme

React Menu

Build Status npm version

Kenshoo menu component

react-menu demo

React menu is a simple menu container component that helps a user create a simple menu bar

Installation

Installation using npm:

 npm install @kenshooui/react-menu --save

Installation using Yarn:

 yarn add @kenshooui/react-menu

How to use

import React, { Component } from "react";
import Menu, {
    Button, 
    Dropdown, 
    Seperator, 
    DropdownItem, 
} from ""@kenshooui/react-menu";

class Menu extends Component {
  render() {
     <Menu>
            <Button>Analysis</Button>
            <Dropdown label="options">
                <DropdownItem>option 1</DropdownItem>
                <DropdownItem>Option 2/DropdownItem>
            </Dropdown>
            <Separator />
            <Button>Help</Button>
            <Dropdown label="more options">
                <DropdownItem>option 1</DropdownItem>
                <DropdownItem>Option 2</DropdownItem>
            </Dropdown>
            <div>I'm a div</div>
        </Menu>
  }
}

Properties

Menu

| Name | Type | Default | Description
|:----- |:----- |:----- |:-----
| className | String | '' | Used for customizing the style. | children | Elements/Components | '' | List of elements to place in the menu

Button

| Name | Type | Default | Description
|:----- |:----- |:----- |:-----
| className | String | '' | Used for customizing the style. | disabledClassName | String | '' | Used for customizing the disabled style. | children | Elements/Components | '' | List of elements to place in the menu | isDisabled | boolean | '' | Toggle to disable/enable the component. | onClick | function | '' | The click callback function.

Dropdown

| Name | Type | Default | Description
|:----- |:----- |:----- |:-----
| className | String | '' | Used for customizing the style. | disabledClassName | String | '' | Used for customizing the disabled style. | itemsClassName | String | '' | Used for customizing the items container style. | iconClassName | String | '' | Used for customizing the chevron icon. | label | String | '' | The dropdown label | children | Elements/Components | '' | List of elements to place in the menu | isDisabled | boolean | '' | Toggle to disable/enable the component. | withIcon | boolean | 'true' | Toggle to display/hide arrow icon next to the dropdown title. | onClick | function | '' | The click callback function. | direction | String | '' | bottom, right, right_to_top, left, left_to_top, bottom_left - default uses bottom style.

Seperator

Use this component to divide the menu to left and right sections

| Name | Type | Default | Description
|:----- |:----- |:----- |:-----
| className | String | '' | class name - Used for customizing the style.

How to Contribute

Setting up development environment

  1. Fork the repository and create your branch from master.
  2. Install the project: yarn install
  3. Run tests: yarn test or yarn test:watch
  4. Run dev environment: yarn storybook and head to https://localhost:6006

Issuing a change

  1. Push to github.

  2. If you’ve fixed a bug or added code that should be tested, add tests.

  3. Open a Pull Request with the following guidelines:

    • Set title prefix to feature/bug and supply a descriptive PR title.
    • Add description to your Pull Request describing your change.
  4. Once your Pull Request is issued, the test suite and build processes will run and your change will be reviewed.

Compatibility

  • React 16 or newer