Skip to content

Commit 3327e8a

Browse files
Merge pull request #18 from zopdev/fix-readme-storybook
updated the readme file with installation steps
2 parents d2aa6da + d0fc74e commit 3327e8a

File tree

1 file changed

+51
-22
lines changed

1 file changed

+51
-22
lines changed

README.md

Lines changed: 51 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,53 @@
11
# UI Component Library
22

3-
This component library is made for React using tailwindcss.
4-
Goal of this project is to provide ready to use UI components to
5-
develop UI applications faster.
6-
7-
All components are documented in storybook. Use `npm run start`
8-
to start the storybook locally. Latest version of stories can also
9-
be accessed at https://zop.dev/ui-components
10-
11-
## Developer Notes
12-
All components needs to support variety of themes to be used across
13-
multiple projects with different design language. Therefore, we can
14-
not use absolute values for colors, sizes, margin, padding, font family
15-
etc in components. Using arbitary values like `bg-[#bada55] text-[22px]`
16-
are not allowed.
17-
18-
For colors, do not use something like `bg-slate-800`. Only allowed values are: primary, secondary, white, black, gray,
19-
red, yellow, green. In this context, red is used as a variable instead of
20-
an absolute color like #ff0000. One can use `text-red-200` to indicate
21-
error in the component or `text-yellow-500` to indicate warning. A theme can choose
22-
to override this value to something which is more appropriate.
23-
24-
Similarly, we will only use tailwind default classes for font-size.
3+
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
4+
[![React](https://img.shields.io/badge/React-18+-61dafb?logo=react&logoColor=white)](https://react.dev/)
5+
[![TailwindCSS](https://img.shields.io/badge/TailwindCSS-3.x-38bdf8?logo=tailwind-css&logoColor=white)](https://tailwindcss.com/)
6+
[![Storybook](https://img.shields.io/badge/Storybook-7.x-ff4785?logo=storybook&logoColor=white)](https://storybook.js.org/)
7+
8+
A **modern React + TailwindCSS UI component library** designed to help you build beautiful, accessible, and theme-friendly applications faster.
9+
10+
👉 Explore live stories: **[zop.dev/ui-components](https://zop.dev/ui-components)**
11+
12+
---
13+
14+
## ✨ Features
15+
16+
- 📦 **Ready-to-use components** with full Storybook documentation
17+
- 🎨 **Theme-aware** — works across multiple design systems
18+
- 🛠 **TailwindCSS utility classes only** (no arbitrary values)
19+
-**Fast development** — drop in and ship UI quickly
20+
- 🔄 **Composable & flexible** — designed for reuse across projects
21+
22+
---
23+
24+
## 📖 Storybook
25+
26+
Run Storybook locally:
27+
28+
```bash
29+
npm install
30+
npm run start
31+
```
32+
33+
This launches Storybook at [http://localhost:6006](http://localhost:6006).
34+
35+
---
36+
37+
## 📝 Developer Guidelines
38+
39+
To ensure **theme compatibility** and **design consistency**, follow these rules:
40+
41+
1. **No arbitrary values**
42+
43+
-`bg-[#bada55] text-[22px]`
44+
-`bg-primary text-lg`
45+
46+
2. **Allowed color tokens only**
47+
48+
- `primary`, `secondary`, `white`, `black`, `gray`, `red`, `yellow`, `green`
49+
- Use semantic Tailwind classes like `text-red-200` (error) or `text-yellow-500` (warning).
50+
- Actual values may be overridden by project themes.
51+
52+
3. **Font sizes**
53+
- Only use Tailwind’s default typography scale (`text-sm`, `text-lg`, etc).

0 commit comments

Comments
 (0)