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

@leapwallet/ribbit-react

v0.0.2

Published

Design system for Leap Wallet

Downloads

481

Readme

ribbit-react

A react component library for ribbit design system built by Leap Wallet.

It's built on top of Shadcn UI.

Installation

To install the package, run the following command:

npm install @leapwallet/ribbit-react

Usage

To use the components in your project, import the components from the package:

import { Button } from '@leapwallet/ribbit-react';
import '@leapwallet/ribbit-react/styles.css';

function App() {
  return (
    <div className="leap-ui">
      <Button>Click Me</Button>
    </div>
  );
}

Full Documentation

You can view the documentation online, hosted on Chromatic.

It includes all the components, theming, and design system guidelines.

If you want to view the documentation locally, you can run the storybook server by following the instructions below.

Development

Project Setup

  1. Clone the repository
git clone [email protected]:leapwallet/ribbit-react.git
  1. Install dependencies using pnpm
pnpm install

If you don't have pnpm installed, you can install it using npm by running npm install -g pnpm

Development Server

The project is setup using storybook for development. To start the development server, run the following command:

pnpm storybook

This will start the storybook server on http://localhost:6006/.

If you want to test out components outside of storybook, we also have a vite dev server setup. To start the vite dev server, run the following command:

pnpm dev

This will start the vite dev server on http://localhost:5173/.

Contributing

If you want to contribute to the project, please create a new branch with the following naming convention:

git checkout -b your-name/change-name

Making Changes

The library code lives in the lib directory. Here's the project structure:

.
├── lib
│   ├── components
│   ├── hooks
│   ├── utils.ts
│   ├── index.ts
  1. Any new components should be added to the components directory.
  2. Any new hooks should be added to the hooks directory.
  3. Any utility functions should be added to the utils.ts file.
  4. The index.ts file should export all the components, hooks, and utility functions that need to be exposed.

Adding New Components

Go to the Shadcn UI documentation and see if the component you want to add is already available there.

For example, if you want to add the context-menu component to this library, you can run the following command:

pnpm dlx shadcn-ui@latest add context-menu

If it's not available, you can add the component to this library. Make sure to follow the naming convention and add the component to the components directory.

Testing

Use Storybook dev server to Vite dev server to test the components locally. Make sure to test the components in different scenarios and screen sizes.

Making Pull Requests

Once you have made your changes, push the branch to the repository and create a draft pull request on the staging branch.

git push origin your-name/change-name

Once the pull request is ready for review, mark it as ready for review and a maintainer will review the changes.

Review Steps

  1. Design Review + Testing from the design team
  2. Code Review + API Review + Testing from the maintainer

Once approved, the changes will be merged into the staging branch and will be released in the next release cycle from the main branch.

Making Releases

When a release is to be made, the following steps should be followed:

  1. Create a new release branch from the staging branch
git checkout -b release/vX.Y.Z
  1. Create a Pull Request from the release branch to the main branch

  2. Once the PR is approved, merge the PR into the main branch

  3. Create a new release with tag vX.Y.Z on GitHub and add Release Notes and Changelog.

Once the PR is merged into the main branch, the documentation and storybook will be updated via the chromatic GH action.

When the GitHub release is created, the package will be published to npm and GH package registry via the publish GH action.