@hunar.ai/hunar-design-system
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published

Hunar Design System is a React component library used to build accessible and consistent experiences at Hunar.ai.

Docs Blog

NPM Version License

Using the components

Installation

The components library is built on top of Material UI. Material UI needs to be installed in order to use this library. Run the following commands to install the necessary packages

yarn add @hunar.ai/hunar-design-system@latest @mui/material @emotion/react @emotion/styled

Usage

  1. Setup Material UI theme and global styles

    const root = ReactDOM.createRoot(document.getElementById("root")!);
    
    root.render(
      <ThemeProvider theme={theme}>
        <GlobalStyles styles={globalStyles} />
        <CssBaseline />
        <App />
      </ThemeProvider>
    );
  2. Import and use components

    import * as React from "react";
    
    import { CustomSelect } from "@hunar.ai/hunar-design-system";
    
    export const App = () => {
      return <CustomSelect {...props} />;
    };

Development

Setup

Install packages and setup project using the following commands

yarn install
yarn run hook-install

Run the following command to start the development server

yarn start

Publish

Publishing on npm

Build the package using the following command

yarn run build:lib

Publish a new version of the package using the following command

yarn run publish:lib

Publishing storybook

Build storybook using the following command

yarn run build:storybook

In order to publish new version of storybook you should have CHROMATIC_PROJECT_TOKEN env variable present in .env.local file. Run the following command to publish a new version

yarn run publish:storybook

Package Sidebar

Install

npm i @hunar.ai/hunar-design-system

Weekly Downloads

0

Version

0.1.0

License

MIT

Unpacked Size

53.3 kB

Total Files

59

Last publish

Collaborators

  • hunar.ai