greenole-design-system
v1.1.75
Published
Componentes reutilizáveis grnl
Downloads
689
Readme
Greenole Design System
The Greenole Design System is a React component library designed to create consistent and scalable user interfaces.
The library is constantly evolving, with new components and improvements being added over time.
Table of Contents
Introduction
Greenole Design System gathers reusable components that follow a consistent visual identity.
It helps teams maintain design and usability standards across their React projects.
Note:
This library is in constant evolution. Existing components may be updated and new ones added over time.
Installation
To install the library in your React project, run:
npm install greenole-design-systemNote:
The library declaresreactandreact-domas peer dependencies, so ensure your project already has these installed.
Usage
After installation, you need to import both the CSS styles and the components:
1. Import the CSS styles
First, import the CSS file in your main application file (usually main.jsx, App.jsx, or index.js):
import 'greenole-design-system/dist/greenole.css';2. Import and use components
Then you can import and use the library's components:
import React from 'react';
import { Typography } from 'greenole-design-system';
function App() {
return (
<div>
<Typography variant="h1">
The quick brown fox jumps over the lazy dog.
</Typography>
{/* Additional components will be added in the future */}
</div>
);
}
export default App;Development
To contribute to or test the library locally:
- Clone the repository:
git clone https://github.com/your-username/greenole-design-system.git cd greenole-design-system - Install dependencies:
npm install - Start the development environment using Vite:
npm run dev - To view the documentation and components, we use Storybook:
Storybook serves as the documentation and demo environment for the library's components.npm run storybook
Build & Publication
To generate the library bundle:
Run the build command:
npm run buildThis will create the
distfolder with both CommonJS and ESModule files, as well as type declarations (if configured).To test locally in another project, use
npm link:cd greenole-design-system npm link cd ../your-consumer-project npm link greenole-design-systemWhen ready to publish:
npm login npm publish --access public
Publishing Storybook to GitHub Pages
Build the Storybook:
npm run build-storybookThis generates the static files for your Storybook.
Deploy to GitHub Pages:
npm run deploy-storybookThis will automatically push the built files to the configured branch (
gh-pages).After that, you can access the updated Storybook at: Design System
Contributing
Contributions are welcome! If you would like to help evolve the Greenole Design System, follow these steps:
- Fork the repository.
- Create a branch for your feature (
git checkout -b my-feature). - Commit your changes.
- Open a pull request for review.
