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

react-sidebar-ui

v1.3.3

Published

Sidebar component for React projects with customizable design

Downloads

503

Readme

react-sidebar-ui

⚛️ Sidebar component for React projects with customizable design

NPM NPM Downloads React Sidebar UI Black React Sidebar UI Light React Sidebar UI Light

Install

npm install react-sidebar-ui
or
yarn add react-sidebar-ui

Usage

  1. Import https://unpkg.com/[email protected]/dist/index.css into your index.html file
  2. In order to use icons, you should import Font-Awesome
  3. Start using the component
import React from 'react'
import {Sidebar, InputItem, DropdownItem, Icon, Item, Logo, LogoText} from 'react-sidebar-ui'

const App = () => {
  return (
    <div>
      <Sidebar bgColor='black' isCollapsed={false}>
        <Logo
          image='https://media2.giphy.com/media/eNAsjO55tPbgaor7ma/source.gif'
          imageName='react logo'/>
        <LogoText>React Sidebar UI</LogoText>
        <DropdownItem
          values={['First', 'Second', 'Third']}
          bgColor={'black'}>
          Menu
        </DropdownItem>

        <Item bgColor='black'>
          <Icon><i className="fas fa-home"/></Icon>
          Home
        </Item>
        <Item bgColor='black'>
          <Icon><i className="fas fa-info"/></Icon>
          About
        </Item>
        <Item bgColor='black'>
          <Icon><i className="fas fa-sitemap"/></Icon>
          My Website
        </Item>
        <Item bgColor='black'>
          <Icon><i className="far fa-address-book"/></Icon>
          Contacts
        </Item>
        <Item bgColor='black'>
          <Icon><i className="fas fa-rss-square"/></Icon>
          Blog
        </Item>
        <InputItem type='text' placeholder={'Search...'}/>
      </Sidebar>
    </div>
  )
};

Props

Common props you may want to specify include:

Sidebar

  • bgColor - change the color of the sidebar, it can be black, light, blue, purple, aqua, peach
  • isCollapsed - add start position of the sidebar if it will be collapsed or not
  • classes - add your custom classes if you want to add custom style to the component
  • position - add where the sidebar will be positioned on the screen, it can be left and right. If you don't specify it will be left.

DropdownItem

  • bgColor - change the color of the sidebar it can be black, light, blue, purple, aqua, peach
  • values - items that will be displayed
  • classes - add your custom classes if you want to add custom style to the component

Item

  • bgColor - change the color of the sidebar it can be black, light, blue, purple, aqua, peach
  • classes - add your custom classes if you want to add custom style to the component

Logo

  • image - url to the image
  • imageText - alt tag of the image
  • classes - add your custom classes if you want to add custom style to the component

InputItem

  • type - type of the input field
  • placeholder - placeholder of the input field
  • classes - add your custom classes if you want to add custom style to the component

Icon

  • classes - you should add font-awesome class here add your custom classes if you want to add custom style to the component

Customization

If you want to change the style of a component, you can do it by adding your own classes to the component.

Contribute

Contributions are always welcome! Please read the contribution guidelines first.

⭐ If you liked the component, please consider giving me a star. Thank you!

License

Copyright © Svetloslav Novoselski