Skip to content

hTuneSys/hexaWebShare

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

96 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

🎨 hexaWebShare

A comprehensive Svelte 5 component library with 100+ production-ready UI components

MIT License Svelte 5 TypeScript DaisyUI Storybook

Documentation β€’ Getting Started β€’ Contributing β€’ Storybook


🌟 Features

  • ✨ 100+ Components - Comprehensive UI components across 6 categories
  • 🎨 DaisyUI + Tailwind - Beautiful, themeable components
  • πŸ”₯ Svelte 5 - Built with the latest Svelte features and runes
  • πŸ“˜ TypeScript - Fully typed with excellent IDE support
  • πŸ“– Storybook - Interactive component documentation
  • β™Ώ Accessible - WCAG-compliant components
  • 🎯 Production-Ready - Optimized and tested
  • πŸŒ“ Dark Mode - Full theme support out of the box

πŸ“¦ Component Categories

Core Components

Essential UI building blocks for any application:

  • Buttons, Forms, Layout, Typography
  • Media, Data Display, Feedback
  • Modals, Dropdowns, Navigation

Admin Components

Admin panel and dashboard components:

  • Dashboards, KPI Cards, Charts
  • CRUD Tables, Data Management
  • User Roles & Permissions

B2B Components

Enterprise workspace features:

  • Workspace & Team Management
  • Projects, Clients, Invoices
  • Kanban Boards, Workflows

E-commerce Components

Online store building blocks:

  • Product Listings & Details
  • Shopping Cart & Checkout
  • Order Management

Marketing Components

Marketing and content sections:

  • Hero Sections, Features
  • Testimonials, Pricing
  • Blog Layouts, CTAs

Utility Components

Cross-cutting utilities:

  • Auth Layouts, Error Boundaries
  • Search Bars, Filters

πŸš€ Quick Start

Prerequisites

  • Node.js 18+ (Download)
  • pnpm 9+ (Install: npm install -g pnpm)
  • Git for version control

Requirements

  • Svelte >= 5.0.0 (uses runes: $props, $derived, $effect, {@render})
  • Client-side only - This library is designed for client-side rendering. SSR/hydration is not currently supported.

Why Svelte 5?

This library uses Svelte 5's new runes syntax throughout all components. Projects using Svelte 4 will encounter build errors.

SSR/Hydration Notice

Components generate unique IDs at runtime using crypto.randomUUID(). This approach works perfectly for client-side rendering but is not compatible with SSR hydration. If you need SSR support, please open an issue to discuss implementation strategies.

Installation for Development

  1. Clone the repository
git clone https://github.com/hTuneSys/hexaWebShare.git
cd hexaWebShare
  1. Install root dependencies and setup Husky
pnpm install

This will:

  • Install Husky for Git hooks
  • Setup pre-commit hooks for REUSE compliance
  • Prepare the development environment
  1. Navigate to the component library
cd hexawebshare
  1. Install component library dependencies
pnpm install
  1. Start Storybook
pnpm storybook

Storybook will open at http://localhost:6006

Alternative: SvelteKit Dev Server

cd hexawebshare
pnpm dev

Opens at http://localhost:5173


πŸ“š Documentation

Comprehensive documentation is available in the docs/ directory:

Essential Guides

Git Workflow

Project Info

πŸ“– Full Documentation Index


πŸ› οΈ Development Workflow

Available Commands

In the hexawebshare/ directory:

Command Description
pnpm install Install dependencies
pnpm dev Start SvelteKit dev server
pnpm storybook Start Storybook dev server
pnpm build Build library package
pnpm build-storybook Build static Storybook
pnpm check TypeScript type checking
pnpm format Format code with Prettier
pnpm lint Check code formatting

Development Flow

# 1. Install root dependencies (Husky)
pnpm install

# 2. Navigate to component library
cd hexawebshare

# 3. Install component dependencies
pnpm install

# 4. Start Storybook
pnpm storybook

# 5. Make your changes
# (Storybook will hot-reload automatically)

# 6. Check types
pnpm check

# 7. Format code
pnpm format

# 8. Commit changes
git add .
git commit -m "feat(Component): add new feature"
# Git hooks will automatically run:
# 1. REUSE compliance check (pre-commit)
# 2. Commit message validation (commit-msg)

πŸ” Git Hooks & Quality Checks

This project uses Git hooks to ensure code quality and compliance. Two hooks are automatically configured:

1. Pre-commit Hook - REUSE Compliance

Checks that all files have proper SPDX license headers.

Required tool: REUSE

# Option 1: Install with pipx (recommended)
pipx install reuse

# Option 2: Install with pip
pip install --user reuse

When it runs: Before each commit

git commit -m "feat: add new component"
# πŸ” Running REUSE compliance check...
# βœ… REUSE compliance check PASSED!

2. Commit-msg Hook - Commit Message Validation

Validates commit messages follow Conventional Commits format.

Required tools: Commitlint (installed in hexawebshare/node_modules)

When it runs: Before each commit (after pre-commit)

Required format:

<type>(<optional-scope>): <description>

Allowed types:

  • feat - New feature
  • fix - Bug fix
  • docs - Documentation changes
  • style - Code formatting (no logic change)
  • refactor - Code restructuring
  • perf - Performance improvement
  • test - Test changes
  • chore - Maintenance tasks
  • ci - CI/CD changes
  • build - Build system changes
  • release - Release preparation
  • hotfix - Critical emergency fix

Examples:

# βœ… Valid commits
git commit -m "feat(Button): add loading state prop"
git commit -m "fix(Modal): resolve focus trap issue"
git commit -m "docs(README): update installation steps"

# ❌ Invalid commits
git commit -m "update button"              # Missing type
git commit -m "added new feature"          # Wrong tense
git commit -m "feat: buton eklendi"        # Non-English

What happens during commit:

git commit -m "feat(Button): add loading state"
# πŸ” Running REUSE compliance check...
# βœ… REUSE compliance check PASSED!
# πŸ” Running Commitlint check...
# βœ… Commit message validation PASSED!

See docs/COMMIT_STRATEGY.md for detailed commit message guidelines.


πŸ§ͺ Quality Checks

Before committing, ensure your code passes all checks:

cd hexawebshare

# Type checking
pnpm check

# Code formatting
pnpm format

# Linting
pnpm lint

# Build verification
pnpm build

# Storybook build
pnpm build-storybook

🎨 Using Components

In Your Svelte App

<script lang="ts">
  import { Button, Card, Modal } from 'hexawebshare';
  
  let showModal = $state(false);
</script>

<Card>
  <h2>Welcome to hexaWebShare</h2>
  <Button 
    label="Open Modal" 
    variant="primary"
    onclick={() => showModal = true}
  />
</Card>

{#if showModal}
  <Modal onclose={() => showModal = false}>
    <h3>Modal Content</h3>
    <p>This is a modal from hexaWebShare!</p>
  </Modal>
{/if}

Creating a New Component

<!-- src/components/core/buttons/MyButton.svelte -->
<script lang="ts">
  interface Props {
    label: string;
    variant?: 'primary' | 'secondary';
    onclick?: () => void;
  }
  
  const { 
    label, 
    variant = 'primary',
    onclick,
  }: Props = $props();
</script>

<button 
  class="btn {variant === 'primary' ? 'btn-primary' : 'btn-secondary'}"
  onclick={onclick}
>
  {label}
</button>

πŸ—οΈ Project Structure

hexaWebShare/
β”œβ”€β”€ .github/              # GitHub configurations
β”‚   β”œβ”€β”€ workflows/        # CI/CD workflows
β”‚   └── ISSUE_TEMPLATE/   # Issue templates
β”œβ”€β”€ .husky/               # Git hooks (pre-commit)
β”œβ”€β”€ docs/                 # Comprehensive documentation
β”œβ”€β”€ hexawebshare/         # Main component library
β”‚   β”œβ”€β”€ .storybook/       # Storybook configuration
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ components/   # Component library
β”‚   β”‚   β”‚   β”œβ”€β”€ core/     # Core components
β”‚   β”‚   β”‚   β”œβ”€β”€ admin/    # Admin components
β”‚   β”‚   β”‚   β”œβ”€β”€ b2b/      # B2B components
β”‚   β”‚   β”‚   β”œβ”€β”€ ecommerce/# E-commerce components
β”‚   β”‚   β”‚   β”œβ”€β”€ marketing/# Marketing components
β”‚   β”‚   β”‚   └── utility/  # Utility components
β”‚   β”‚   β”œβ”€β”€ lib/          # Library exports
β”‚   β”‚   └── routes/       # SvelteKit showcase
β”‚   └── package.json      # Component library dependencies
β”œβ”€β”€ LICENSES/             # License files
β”œβ”€β”€ package.json          # Root package (Husky setup)
└── README.md             # This file

🀝 Contributing

We welcome contributions! Please read our Contributing Guide to get started.

Quick Contribution Checklist

Branch Naming

# Feature
git checkout -b feat/add-tooltip-component

# Bug fix
git checkout -b fix/modal-close-button

# Documentation
git checkout -b docs/update-readme

Commit Messages

# Format: <type>(<scope>): <description>
git commit -m "feat(Button): add loading state prop"
git commit -m "fix(Modal): resolve focus trap issue"
git commit -m "docs(README): update installation steps"

πŸ“‹ Continuous Integration

Pull requests automatically run quality checks via GitHub Actions:

  • βœ… TypeScript type checking
  • βœ… Code formatting validation
  • βœ… Build verification
  • βœ… Storybook build test

See .github/workflows/ci.yml for details.


πŸ“„ License

This project is licensed under the MIT License.

SPDX-FileCopyrightText: 2025 hexaTune LLC
SPDX-License-Identifier: MIT

πŸ™ Acknowledgments

Built with amazing open-source technologies:


πŸ“ž Contact & Support


Built with ❀️ by hexaTune LLC

⭐ Star us on GitHub if you find this project useful!

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Contributors 5