Skip to content
Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

34 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

UIverse

⬑ UIverse

A beginner-friendly, open-source React UI component library

Built for learners. Designed for contributors. Ready for GSSoC.

React Vite React Router License: MIT PRs Welcome


πŸ“Œ What is UIverse?

UIverse is a clean, minimal React component library built from scratch β€” no Tailwind, no heavy UI frameworks, just pure React + CSS.

The goal is simple:

Make it easy for beginners to learn React by building and contributing real UI components.

Every component is:

  • πŸ“– Fully commented for learning
  • 🧩 Reusable and prop-driven
  • 🎨 Styled with plain, readable CSS
  • ⚑ Instantly usable β€” drop it in and it works

🎯 Project Goals

Goal Description
πŸ§‘β€πŸ’» Beginner Friendly Every file has comments explaining what and why
🀝 Contributor Ready Clear folder structure, easy to add new components
πŸ† GSSoC Ready Structured for open-source programs like GSSoC
πŸ“¦ Minimal Dependencies Uses React, React Router, and react-icons while keeping the project lightweight
🎨 Plain CSS No Tailwind β€” so contributors learn real CSS

πŸš€ Getting Started

Prerequisites

Make sure you have these installed:

1. Fork the repository

Click the Fork button at the top right of this page to create your own copy.

2. Clone your fork

git clone https://github.com/YOUR_USERNAME/uiverse.git
cd uiverse

3. Install dependencies

npm install

4. Start the dev server

npm run dev

Open http://localhost:5173 in your browser. You're good to go! πŸŽ‰


πŸ“ Project Structure

uiverse/
β”œβ”€β”€ index.html                  # HTML entry point
β”œβ”€β”€ vite.config.js              # Vite configuration
β”œβ”€β”€ package.json
β”‚
└── src/
    β”œβ”€β”€ main.jsx                # App entry β€” sets up BrowserRouter
    β”œβ”€β”€ App.jsx                 # Route definitions
    β”œβ”€β”€ index.css               # Global base styles
    β”‚
    β”œβ”€β”€ components/             # βœ… All reusable UI components live here
    β”‚   β”œβ”€β”€ Button/
    β”‚   β”‚   β”œβ”€β”€ Button.jsx      # Component logic + props
    β”‚   β”‚   └── Button.css      # Component styles
    β”‚   └── Navbar/
    β”‚       β”œβ”€β”€ Navbar.jsx
    β”‚       └── Navbar.css
    β”‚
    β”œβ”€β”€ pages/                  # Route-level page components
    β”‚   β”œβ”€β”€ Home.jsx            # Landing page  β†’  route: "/"
    β”‚   β”œβ”€β”€ Home.css
    β”‚   β”œβ”€β”€ Components.jsx      # Showcase page β†’  route: "/components"
    β”‚   └── Components.css
    β”‚
    └── data/
        └── componentsList.js   # πŸ“‹ Registry of all components (metadata)

Rule of thumb: Each component gets its own folder inside src/components/. One .jsx file + one .css file. That's it.


🧩 Available Components

Component Category Status Description
Button Inputs βœ… Stable Primary, Secondary, Danger variants + sm/md/lg sizes
Navbar Navigation βœ… Stable Sticky navbar with active link highlighting
Input Inputs πŸ”œ Planned Text input with label and validation
Card Layout πŸ”œ Planned Content card with header/body/footer slots
Modal Overlay πŸ”œ Planned Accessible dialog with backdrop
Badge Display πŸ”œ Planned Status indicator with color variants

πŸ› οΈ How to Add a New Component

This is the most important section if you want to contribute. Follow these 3 steps:

Step 1 β€” Create the component files

Create a new folder inside src/components/ with your component name:

src/components/YourComponent/
β”œβ”€β”€ YourComponent.jsx
└── YourComponent.css

YourComponent.jsx β€” minimal template:

// YourComponent.jsx
// Props:
//   propName (type) – description

import React from 'react'
import './YourComponent.css'

function YourComponent({ propName }) {
  return (
    <div className="your-component">
      {/* your JSX here */}
    </div>
  )
}

export default YourComponent

YourComponent.css β€” minimal template:

/* YourComponent.css */

.your-component {
  /* your styles here */
}

Step 2 β€” Register it in componentsList.js

Open src/data/componentsList.js and add your component to the array:

{
  id: 7,                          // next available id
  name: 'YourComponent',
  category: 'Layout',             // Inputs | Layout | Overlay | Display | Navigation
  status: 'Beta',                 // Stable | Beta | Planned
  description: 'One line about what this component does.',
},

Step 3 β€” Add a showcase section in Components.jsx

Open src/pages/Components.jsx and:

  1. Import your component at the top:
import YourComponent from '../components/YourComponent/YourComponent.jsx'
  1. Add it to the sections array (for sidebar navigation):
{ id: 'your-component', label: 'πŸ†• YourComponent' },
  1. Add a <section> block in the JSX (copy the Button section as a template).

That's it. Open a PR and you're a UIverse contributor! πŸŽ‰


🌿 Git Workflow

# 1. Create a new branch for your feature
git checkout -b feat/add-card-component

# 2. Make your changes

# 3. Stage and commit
git add .
git commit -m "feat: add Card component with header/body/footer slots"

# 4. Push to your fork
git push origin feat/add-card-component

# 5. Open a Pull Request on GitHub

Commit Message Format

We follow a simple convention:

Prefix When to use
feat: Adding a new component or feature
fix: Fixing a bug
style: CSS/UI changes only
docs: README or comment updates
refactor: Code cleanup, no behavior change
chore: Config, deps, tooling

Examples:

feat: add Badge component with color variants
fix: button hover state not working on Safari
style: improve Card component spacing
docs: update contributing steps in README

βœ… Contribution Checklist

Before opening a PR, make sure:

  • Component is inside its own folder in src/components/
  • Component has a .jsx and a .css file
  • Props are documented in comments at the top of the .jsx file
  • Component is registered in src/data/componentsList.js
  • A showcase section is added in src/pages/Components.jsx
  • Code runs without errors (npm run dev)
  • CSS class names follow the pattern: uiverse-<componentname>
  • No external libraries added without discussion

πŸ’‘ Component Ideas (Good First Issues)

Looking for something to build? Here are some ideas:

Component Difficulty Notes
Input 🟒 Easy Text input with label + placeholder props
Badge 🟒 Easy Colored pill badge, similar to Button variants
Card 🟑 Medium Header, body, footer slots via props/children
Alert 🟑 Medium Info, success, warning, error variants
Modal πŸ”΄ Hard Needs portal, backdrop, keyboard close (Esc)
Tooltip πŸ”΄ Hard Hover-triggered, position-aware
Toggle 🟑 Medium On/off switch with controlled state
Avatar 🟒 Easy Image or initials fallback, size variants

πŸ—οΈ Tech Stack

Tool Version Purpose
React 18 UI rendering
Vite 5 Dev server + bundler
React Router 6 Client-side routing
Plain CSS β€” Component styling
React Icons 5 Lightweight icon library for React components

πŸ“œ Scripts

npm run dev       # Start development server at localhost:5173
npm run build     # Build for production (outputs to /dist)
npm run preview   # Preview the production build locally

🀝 Code of Conduct

  • Be respectful and welcoming to all contributors
  • Give constructive feedback on PRs
  • Help beginners β€” everyone starts somewhere
  • No spam PRs (e.g. only whitespace changes)

πŸ“„ License

This project is licensed under the MIT License β€” you're free to use, modify, and distribute it.


Made with ❀️ for the open-source community

If this project helped you, consider giving it a ⭐ on GitHub!

About

UIverse is an open-source React UI component library built for developers and contributors. πŸš€ Features Reusable React components Beginner-friendly contributions Clean UI & code Easy copy-paste components

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages