shadcn-glass-ui 1.0.11 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +213 -0
- package/README.md +174 -17
- package/context7.json +58 -0
- package/dist/cli/index.cjs +470 -0
- package/dist/cli/index.cjs.map +1 -0
- package/dist/cli/index.d.ts +18 -0
- package/dist/cli/index.js +469 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/components.cjs +4 -4
- package/dist/components.d.ts +153 -22
- package/dist/components.js +2 -2
- package/dist/hooks.cjs +2 -2
- package/dist/index.cjs +872 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +0 -2390
- package/dist/index.js +844 -3
- package/dist/index.js.map +1 -1
- package/dist/r/ai-card-glass.json +5 -12
- package/dist/r/avatar-glass.json +5 -15
- package/dist/r/circular-metric-glass.json +5 -11
- package/dist/r/circular-progress-glass.json +5 -12
- package/dist/r/combobox-glass.json +5 -13
- package/dist/r/flag-alert-glass.json +5 -11
- package/dist/r/flags-section-glass.json +5 -12
- package/dist/r/insight-card-glass.json +17 -0
- package/dist/r/interactive-card.json +5 -12
- package/dist/r/language-bar-glass.json +5 -11
- package/dist/r/metric-card-glass.json +6 -13
- package/dist/r/metrics-grid-glass.json +5 -11
- package/dist/r/modal-glass.json +5 -15
- package/dist/r/progress-glass.json +5 -13
- package/dist/r/registry.json +20 -2
- package/dist/r/segmented-control-glass.json +5 -11
- package/dist/r/sparkline-glass.json +17 -0
- package/dist/r/stepper-glass.json +33 -0
- package/dist/r/tabs-glass.json +4 -9
- package/dist/r/trust-score-card-glass.json +5 -12
- package/dist/r/year-card-glass.json +5 -13
- package/dist/shadcn-glass-ui.css +1 -1
- package/dist/{theme-context-XtasSxRT.cjs → theme-context-CVW50BKW.cjs} +2 -2
- package/dist/{theme-context-XtasSxRT.cjs.map → theme-context-CVW50BKW.cjs.map} +1 -1
- package/dist/themes.cjs +1 -1
- package/dist/trust-score-card-glass-BcZbul0P.js +26895 -0
- package/dist/trust-score-card-glass-BcZbul0P.js.map +1 -0
- package/dist/trust-score-card-glass-r3qM09Jp.cjs +27689 -0
- package/dist/trust-score-card-glass-r3qM09Jp.cjs.map +1 -0
- package/dist/{use-focus-BbpE2qGq.cjs → use-focus-ZE8ozmZE.cjs} +2 -2
- package/dist/{use-focus-BbpE2qGq.cjs.map → use-focus-ZE8ozmZE.cjs.map} +1 -1
- package/dist/{use-wallpaper-tint-CIqtoETa.cjs → use-wallpaper-tint-BuS80tbN.cjs} +2 -2
- package/dist/{use-wallpaper-tint-CIqtoETa.cjs.map → use-wallpaper-tint-BuS80tbN.cjs.map} +1 -1
- package/dist/{utils-CGCOTvxT.js → utils-CcyeqpKQ.js} +1 -1
- package/dist/{utils-CGCOTvxT.js.map → utils-CcyeqpKQ.js.map} +1 -1
- package/dist/{utils-CriE74ig.cjs → utils-DLXayspX.cjs} +2 -2
- package/dist/{utils-CriE74ig.cjs.map → utils-DLXayspX.cjs.map} +1 -1
- package/dist/utils.cjs +1 -1
- package/dist/utils.js +1 -1
- package/docs/AI_IMPROVEMENTS_COMPLETE.md +574 -0
- package/docs/AI_USAGE.md +1328 -0
- package/docs/API_PATTERNS_COMPARISON.md +418 -0
- package/docs/BEST_PRACTICES.md +800 -0
- package/docs/COMPLIANCE_CHECKLIST.md +307 -0
- package/docs/COMPLIANCE_TESTING.md +436 -0
- package/docs/COMPONENTS_CATALOG.md +1076 -0
- package/docs/CSS_VARIABLES_AUDIT.md +306 -0
- package/docs/CSS_VARIABLES_REFACTORING_PLAN.md +330 -0
- package/docs/EXPORTS_MAP.json +875 -0
- package/docs/EXPORTS_STRUCTURE.md +729 -0
- package/docs/GETTING_STARTED.md +655 -0
- package/docs/METRIC_CARD_API_REDESIGN.md +354 -0
- package/docs/PRIMITIVE_MAPPING.md +404 -0
- package/docs/PUBLISHING.md +593 -0
- package/docs/REGISTRY_SUMMARY.md +96 -0
- package/docs/REGISTRY_USAGE.md +339 -0
- package/docs/SECURITY.md +117 -0
- package/docs/THEME_CREATION_GUIDE.md +455 -0
- package/docs/TOKEN_ARCHITECTURE.md +365 -0
- package/docs/announcements/v1.0.5-devto.md +363 -0
- package/docs/announcements/v1.0.5-reddit.md +115 -0
- package/docs/announcements/v1.0.5-twitter.md +70 -0
- package/docs/api/README.md +725 -0
- package/docs/api/functions/ThemeProvider.md +21 -0
- package/docs/api/functions/cn.md +27 -0
- package/docs/api/functions/getNextTheme.md +21 -0
- package/docs/api/functions/getThemeConfig.md +21 -0
- package/docs/api/functions/useFocus.md +53 -0
- package/docs/api/functions/useHover.md +47 -0
- package/docs/api/functions/useResponsive.md +31 -0
- package/docs/api/functions/useTheme.md +15 -0
- package/docs/api/functions/useWallpaperTint.md +36 -0
- package/docs/api/globals.md +139 -0
- package/docs/api/interfaces/AlertGlassProps.md +131 -0
- package/docs/api/interfaces/AvatarGlassProps.md +114 -0
- package/docs/api/interfaces/BadgeGlassProps.md +118 -0
- package/docs/api/interfaces/ButtonGlassProps.md +179 -0
- package/docs/api/interfaces/CheckboxGlassProps.md +125 -0
- package/docs/api/interfaces/DropdownGlassProps.md +123 -0
- package/docs/api/interfaces/DropdownItem.md +53 -0
- package/docs/api/interfaces/GlassCardProps.md +151 -0
- package/docs/api/interfaces/InputGlassProps.md +169 -0
- package/docs/api/interfaces/NotificationGlassProps.md +67 -0
- package/docs/api/interfaces/ProgressGlassProps.md +49 -0
- package/docs/api/interfaces/SkeletonGlassProps.md +41 -0
- package/docs/api/interfaces/SliderGlassProps.md +107 -0
- package/docs/api/interfaces/TabItem.md +25 -0
- package/docs/api/interfaces/ThemeConfig.md +25 -0
- package/docs/api/interfaces/ThemeContextValue.md +47 -0
- package/docs/api/interfaces/ToggleGlassProps.md +59 -0
- package/docs/api/interfaces/TooltipGlassProps.md +119 -0
- package/docs/api/type-aliases/AlertType.md +11 -0
- package/docs/api/type-aliases/AlertVariant.md +11 -0
- package/docs/api/type-aliases/AvatarSize.md +11 -0
- package/docs/api/type-aliases/AvatarStatus.md +13 -0
- package/docs/api/type-aliases/BadgeSize.md +11 -0
- package/docs/api/type-aliases/BadgeVariant.md +11 -0
- package/docs/api/type-aliases/ButtonGlassSize.md +11 -0
- package/docs/api/type-aliases/ButtonGlassVariant.md +11 -0
- package/docs/api/type-aliases/DropdownAlign.md +11 -0
- package/docs/api/type-aliases/GlowType.md +11 -0
- package/docs/api/type-aliases/InputGlassSize.md +11 -0
- package/docs/api/type-aliases/IntensityType.md +11 -0
- package/docs/api/type-aliases/ModalSize.md +11 -0
- package/docs/api/type-aliases/NotificationType.md +11 -0
- package/docs/api/type-aliases/PaddingType.md +11 -0
- package/docs/api/type-aliases/ProgressGradient.md +11 -0
- package/docs/api/type-aliases/ProgressSize.md +11 -0
- package/docs/api/type-aliases/SkeletonVariant.md +11 -0
- package/docs/api/type-aliases/Theme.md +11 -0
- package/docs/api/type-aliases/ToggleGlassSize.md +11 -0
- package/docs/api/type-aliases/TooltipPosition.md +11 -0
- package/docs/api/variables/AICardGlass.md +11 -0
- package/docs/api/variables/AlertGlass.md +11 -0
- package/docs/api/variables/AvatarGlass.md +11 -0
- package/docs/api/variables/BadgeGlass.md +11 -0
- package/docs/api/variables/BaseProgressGlass.md +11 -0
- package/docs/api/variables/ButtonGlass.md +11 -0
- package/docs/api/variables/CareerStatsGlass.md +11 -0
- package/docs/api/variables/CareerStatsHeaderGlass.md +11 -0
- package/docs/api/variables/CheckboxGlass.md +11 -0
- package/docs/api/variables/CircularMetricGlass.md +22 -0
- package/docs/api/variables/CircularProgressGlass.md +11 -0
- package/docs/api/variables/ComboBoxGlass.md +27 -0
- package/docs/api/variables/ContributionMetricsGlass.md +11 -0
- package/docs/api/variables/DropdownGlass.md +11 -0
- package/docs/api/variables/ExpandableHeaderGlass.md +11 -0
- package/docs/api/variables/FlagAlertGlass.md +11 -0
- package/docs/api/variables/FlagsSectionGlass.md +11 -0
- package/docs/api/variables/FormFieldWrapper.md +44 -0
- package/docs/api/variables/GlassCard.md +11 -0
- package/docs/api/variables/HeaderBrandingGlass.md +11 -0
- package/docs/api/variables/HeaderNavGlass.md +11 -0
- package/docs/api/variables/IconButtonGlass.md +11 -0
- package/docs/api/variables/InputGlass.md +11 -0
- package/docs/api/variables/InteractiveCard.md +45 -0
- package/docs/api/variables/LanguageBarGlass.md +11 -0
- package/docs/api/variables/MetricCardGlass.md +11 -0
- package/docs/api/variables/MetricsGridGlass.md +11 -0
- package/docs/api/variables/ModalGlass.md +72 -0
- package/docs/api/variables/NotificationGlass.md +11 -0
- package/docs/api/variables/PopoverGlass.md +11 -0
- package/docs/api/variables/ProfileAvatarGlass.md +11 -0
- package/docs/api/variables/ProfileHeaderGlass.md +11 -0
- package/docs/api/variables/ProgressGlass.md +11 -0
- package/docs/api/variables/ProjectsListGlass.md +11 -0
- package/docs/api/variables/RainbowProgressGlass.md +11 -0
- package/docs/api/variables/RepositoryCardGlass.md +11 -0
- package/docs/api/variables/RepositoryHeaderGlass.md +11 -0
- package/docs/api/variables/RepositoryMetadataGlass.md +11 -0
- package/docs/api/variables/SearchBoxGlass.md +11 -0
- package/docs/api/variables/SegmentedControlGlass.md +11 -0
- package/docs/api/variables/SkeletonGlass.md +11 -0
- package/docs/api/variables/SliderGlass.md +11 -0
- package/docs/api/variables/SortDropdownGlass.md +11 -0
- package/docs/api/variables/StatItemGlass.md +11 -0
- package/docs/api/variables/StatusIndicatorGlass.md +11 -0
- package/docs/api/variables/THEMES.md +11 -0
- package/docs/api/variables/THEME_CONFIG.md +11 -0
- package/docs/api/variables/TabsGlass.md +52 -0
- package/docs/api/variables/ThemeToggleGlass.md +11 -0
- package/docs/api/variables/ToggleGlass.md +11 -0
- package/docs/api/variables/TooltipGlass.md +11 -0
- package/docs/api/variables/TouchTarget.md +35 -0
- package/docs/api/variables/TrustScoreCardGlass.md +11 -0
- package/docs/api/variables/TrustScoreDisplayGlass.md +11 -0
- package/docs/api/variables/UserInfoGlass.md +11 -0
- package/docs/api/variables/UserStatsLineGlass.md +11 -0
- package/docs/api/variables/YearCardGlass.md +11 -0
- package/docs/api/variables/alertVariants.md +21 -0
- package/docs/api/variables/avatarSizes.md +21 -0
- package/docs/api/variables/badgeVariants.md +21 -0
- package/docs/api/variables/buttonGlassVariants.md +21 -0
- package/docs/api/variables/cardIntensity.md +21 -0
- package/docs/api/variables/dropdownAlign.md +21 -0
- package/docs/api/variables/inputVariants.md +21 -0
- package/docs/api/variables/modalSizes.md +21 -0
- package/docs/api/variables/notificationVariants.md +21 -0
- package/docs/api/variables/progressSizes.md +21 -0
- package/docs/api/variables/shadcnAlertVariants.md +21 -0
- package/docs/api/variables/shadcnBadgeVariants.md +21 -0
- package/docs/api/variables/shadcnButtonVariants.md +21 -0
- package/docs/api/variables/skeletonVariants.md +21 -0
- package/docs/api/variables/statusSizes.md +21 -0
- package/docs/api/variables/toggleSizes.md +21 -0
- package/docs/api/variables/tooltipPositions.md +21 -0
- package/docs/design-system/UI_DESIGN.md +628 -0
- package/docs/migration/CSS_VARIABLES_MIGRATION_2.0.md +325 -0
- package/docs/migration/modal-glass-compound-api.md +458 -0
- package/docs/migration/select-to-combobox.md +386 -0
- package/docs/migration/tabs-glass-compound-api.md +579 -0
- package/docs/technical/DEPENDENCIES.md +291 -0
- package/docs/visual-testing-guide.md +324 -0
- package/package.json +16 -3
- package/dist/trust-score-card-glass-CNcQveNY.cjs +0 -8231
- package/dist/trust-score-card-glass-CNcQveNY.cjs.map +0 -1
- package/dist/trust-score-card-glass-CowcDyxH.js +0 -7795
- package/dist/trust-score-card-glass-CowcDyxH.js.map +0 -1
|
@@ -0,0 +1,729 @@
|
|
|
1
|
+
# Exports Structure
|
|
2
|
+
|
|
3
|
+
> **AI-Friendly Documentation** - Complete guide to library exports for AI assistants
|
|
4
|
+
|
|
5
|
+
This document provides a comprehensive guide to all exports from `shadcn-glass-ui` library,
|
|
6
|
+
organized by category and hierarchy level.
|
|
7
|
+
|
|
8
|
+
## Table of Contents
|
|
9
|
+
|
|
10
|
+
- [Quick Start](#quick-start)
|
|
11
|
+
- [Import Patterns](#import-patterns)
|
|
12
|
+
- [Component Hierarchy](#component-hierarchy)
|
|
13
|
+
- [Complete Export Reference](#complete-export-reference)
|
|
14
|
+
- [Type System](#type-system)
|
|
15
|
+
- [Utilities & Hooks](#utilities--hooks)
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## Quick Start
|
|
20
|
+
|
|
21
|
+
### Essential Imports
|
|
22
|
+
|
|
23
|
+
```tsx
|
|
24
|
+
// Core UI components (most commonly used)
|
|
25
|
+
import { ButtonGlass, InputGlass, ModalGlass, GlassCard } from 'shadcn-glass-ui';
|
|
26
|
+
|
|
27
|
+
// Theme system
|
|
28
|
+
import { ThemeProvider, useTheme } from 'shadcn-glass-ui';
|
|
29
|
+
|
|
30
|
+
// Utility function
|
|
31
|
+
import { cn } from 'shadcn-glass-ui';
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### TypeScript Support
|
|
35
|
+
|
|
36
|
+
```tsx
|
|
37
|
+
import type { ButtonGlassProps, Theme, ThemeConfig } from 'shadcn-glass-ui';
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## Import Patterns
|
|
43
|
+
|
|
44
|
+
### Pattern 1: Named Imports (Recommended)
|
|
45
|
+
|
|
46
|
+
```tsx
|
|
47
|
+
import { ButtonGlass, InputGlass, useTheme } from 'shadcn-glass-ui';
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
**Pros:**
|
|
51
|
+
|
|
52
|
+
- Tree-shakable
|
|
53
|
+
- Clear dependencies
|
|
54
|
+
- Type-safe
|
|
55
|
+
|
|
56
|
+
### Pattern 2: Type-Only Imports
|
|
57
|
+
|
|
58
|
+
```tsx
|
|
59
|
+
import type { ButtonGlassProps, Theme } from 'shadcn-glass-ui';
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
**Pros:**
|
|
63
|
+
|
|
64
|
+
- Zero runtime cost
|
|
65
|
+
- Explicit type usage
|
|
66
|
+
|
|
67
|
+
### Pattern 3: Namespace Import (Not Recommended)
|
|
68
|
+
|
|
69
|
+
```tsx
|
|
70
|
+
import * as GlassUI from 'shadcn-glass-ui';
|
|
71
|
+
|
|
72
|
+
// Usage: <GlassUI.ButtonGlass />
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
**Cons:**
|
|
76
|
+
|
|
77
|
+
- No tree-shaking
|
|
78
|
+
- Larger bundle size
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## Component Hierarchy
|
|
83
|
+
|
|
84
|
+
The library uses a 6-level component hierarchy, from primitives to complete sections:
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
Level 0: Primitives (3) → Foundation building blocks
|
|
88
|
+
Level 1: Core UI (18) → Basic interactive components
|
|
89
|
+
Level 2: Atomic (6) → Small, single-purpose components
|
|
90
|
+
Level 3: Specialized (8) → Domain-specific components
|
|
91
|
+
Level 4: Composite (13) → Multi-component compositions
|
|
92
|
+
Level 5: Sections (7) → Complete page sections
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
### Hierarchy Diagram
|
|
96
|
+
|
|
97
|
+
```
|
|
98
|
+
┌─────────────────────────────────────────────┐
|
|
99
|
+
│ LEVEL 5: SECTIONS (7 components) │
|
|
100
|
+
│ HeaderNavGlass, ProfileHeaderGlass, etc. │
|
|
101
|
+
└──────────────────┬──────────────────────────┘
|
|
102
|
+
│
|
|
103
|
+
┌──────────────────▼──────────────────────────┐
|
|
104
|
+
│ LEVEL 4: COMPOSITE (13 components) │
|
|
105
|
+
│ MetricCardGlass, AICardGlass, etc. │
|
|
106
|
+
└──────────────────┬──────────────────────────┘
|
|
107
|
+
│
|
|
108
|
+
┌──────────────────▼──────────────────────────┐
|
|
109
|
+
│ LEVEL 3: SPECIALIZED (8 components) │
|
|
110
|
+
│ ProgressGlass, LanguageBarGlass, etc. │
|
|
111
|
+
└──────────────────┬──────────────────────────┘
|
|
112
|
+
│
|
|
113
|
+
┌──────────────────▼──────────────────────────┐
|
|
114
|
+
│ LEVEL 2: ATOMIC (6 components) │
|
|
115
|
+
│ ThemeToggleGlass, SearchBoxGlass, etc. │
|
|
116
|
+
└──────────────────┬──────────────────────────┘
|
|
117
|
+
│
|
|
118
|
+
┌──────────────────▼──────────────────────────┐
|
|
119
|
+
│ LEVEL 1: CORE UI (18 components) │
|
|
120
|
+
│ ButtonGlass, InputGlass, ModalGlass, etc. │
|
|
121
|
+
└──────────────────┬──────────────────────────┘
|
|
122
|
+
│
|
|
123
|
+
┌──────────────────▼──────────────────────────┐
|
|
124
|
+
│ LEVEL 0: PRIMITIVES (3 components) │
|
|
125
|
+
│ TouchTarget, FormFieldWrapper, etc. │
|
|
126
|
+
└─────────────────────────────────────────────┘
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
---
|
|
130
|
+
|
|
131
|
+
## Complete Export Reference
|
|
132
|
+
|
|
133
|
+
### Level 0: Primitives (3 components)
|
|
134
|
+
|
|
135
|
+
Foundation components that other components build upon. Rarely used directly in application code.
|
|
136
|
+
|
|
137
|
+
| Export | Type | Description | Use Case |
|
|
138
|
+
| ------------------ | --------- | ---------------------------------------- | ------------------------------- |
|
|
139
|
+
| `TouchTarget` | Component | Touch-friendly wrapper (44/48px minimum) | Wrap small interactive elements |
|
|
140
|
+
| `FormFieldWrapper` | Component | Unified form field structure | Create custom form components |
|
|
141
|
+
| `InteractiveCard` | Component | Hover animations + glass effects | Build custom card components |
|
|
142
|
+
|
|
143
|
+
**Import:**
|
|
144
|
+
|
|
145
|
+
```tsx
|
|
146
|
+
import { TouchTarget, FormFieldWrapper, InteractiveCard } from 'shadcn-glass-ui';
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
**Example:**
|
|
150
|
+
|
|
151
|
+
```tsx
|
|
152
|
+
<TouchTarget>
|
|
153
|
+
<button className="w-8 h-8">×</button>
|
|
154
|
+
</TouchTarget>
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
---
|
|
158
|
+
|
|
159
|
+
### Level 1: Core UI Components (18 components)
|
|
160
|
+
|
|
161
|
+
Primary building blocks for application interfaces. These are the most commonly used components.
|
|
162
|
+
|
|
163
|
+
#### Interactive Controls (7)
|
|
164
|
+
|
|
165
|
+
| Export | Description | Key Props | Variants |
|
|
166
|
+
| --------------- | --------------------- | ------------------------------ | ----------------------------------------------------- |
|
|
167
|
+
| `ButtonGlass` | Primary action button | `variant`, `size`, `asChild` | default, secondary, outline, destructive, ghost, link |
|
|
168
|
+
| `CheckboxGlass` | Checkbox input | `checked`, `onCheckedChange` | - |
|
|
169
|
+
| `ComboBoxGlass` | Searchable dropdown | `options`, `value`, `onChange` | - |
|
|
170
|
+
| `DropdownGlass` | Dropdown menu | `items`, `onSelect`, `trigger` | - |
|
|
171
|
+
| `PopoverGlass` | Popover dialog | `trigger`, `content` | - |
|
|
172
|
+
| `SliderGlass` | Range slider | `value`, `min`, `max`, `step` | - |
|
|
173
|
+
| `ToggleGlass` | Toggle switch | `pressed`, `onPressedChange` | - |
|
|
174
|
+
|
|
175
|
+
#### Form Elements (2)
|
|
176
|
+
|
|
177
|
+
| Export | Description | Key Props | Variants |
|
|
178
|
+
| ------------ | ---------------- | ------------------------------------------------ | -------- |
|
|
179
|
+
| `InputGlass` | Text input field | `type`, `placeholder`, `error` | - |
|
|
180
|
+
| `TabsGlass` | Tab navigation | `defaultValue`, `items` (legacy) OR compound API | - |
|
|
181
|
+
|
|
182
|
+
#### Feedback & Display (9)
|
|
183
|
+
|
|
184
|
+
| Export | Description | Key Props | Variants |
|
|
185
|
+
| ----------------------- | --------------------------- | ------------------------------------------- | ---------------------------------------------------------------- |
|
|
186
|
+
| `AlertGlass` | Alert message | `variant`, `title`, `children` | default, destructive, success, warning |
|
|
187
|
+
| `AvatarGlass` | User avatar | `src`, `alt`, `size`, `status`, `asChild` | - |
|
|
188
|
+
| `BadgeGlass` | Status badge | `variant`, `children` | default, secondary, destructive, outline, success, warning, info |
|
|
189
|
+
| `CircularProgressGlass` | Circular progress indicator | `value`, `size` | - |
|
|
190
|
+
| `GlassCard` | Card container | `glow`, `intensity`, `asChild` | - |
|
|
191
|
+
| `ModalGlass` | Modal dialog | `size`, `children` (legacy) OR compound API | sm, md, lg, xl, full |
|
|
192
|
+
| `NotificationGlass` | Toast notification | `variant`, `title`, `message`, `onClose` | default, destructive, success, warning |
|
|
193
|
+
| `SkeletonGlass` | Loading skeleton | `variant`, `width`, `height` | text, circle, rectangle |
|
|
194
|
+
| `TooltipGlass` | Tooltip overlay | `content`, `position`, `children` | top, bottom, left, right |
|
|
195
|
+
|
|
196
|
+
**Import:**
|
|
197
|
+
|
|
198
|
+
```tsx
|
|
199
|
+
import {
|
|
200
|
+
ButtonGlass,
|
|
201
|
+
InputGlass,
|
|
202
|
+
CheckboxGlass,
|
|
203
|
+
AlertGlass,
|
|
204
|
+
ModalGlass,
|
|
205
|
+
TabsGlass,
|
|
206
|
+
} from 'shadcn-glass-ui';
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
**Example:**
|
|
210
|
+
|
|
211
|
+
```tsx
|
|
212
|
+
// Simple button
|
|
213
|
+
<ButtonGlass variant="default" size="md">Click me</ButtonGlass>
|
|
214
|
+
|
|
215
|
+
// Compound Modal API
|
|
216
|
+
<ModalGlass.Root open={open} onOpenChange={setOpen}>
|
|
217
|
+
<ModalGlass.Trigger asChild>
|
|
218
|
+
<ButtonGlass>Open Modal</ButtonGlass>
|
|
219
|
+
</ModalGlass.Trigger>
|
|
220
|
+
<ModalGlass.Content>
|
|
221
|
+
<ModalGlass.Header>
|
|
222
|
+
<ModalGlass.Title>Modal Title</ModalGlass.Title>
|
|
223
|
+
</ModalGlass.Header>
|
|
224
|
+
<ModalGlass.Body>Content here</ModalGlass.Body>
|
|
225
|
+
</ModalGlass.Content>
|
|
226
|
+
</ModalGlass.Root>
|
|
227
|
+
|
|
228
|
+
// Compound Tabs API
|
|
229
|
+
<TabsGlass.Root defaultValue="tab1">
|
|
230
|
+
<TabsGlass.List>
|
|
231
|
+
<TabsGlass.Trigger value="tab1">Tab 1</TabsGlass.Trigger>
|
|
232
|
+
<TabsGlass.Trigger value="tab2">Tab 2</TabsGlass.Trigger>
|
|
233
|
+
</TabsGlass.List>
|
|
234
|
+
<TabsGlass.Content value="tab1">Content 1</TabsGlass.Content>
|
|
235
|
+
<TabsGlass.Content value="tab2">Content 2</TabsGlass.Content>
|
|
236
|
+
</TabsGlass.Root>
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
### Level 2: Atomic Components (6 components)
|
|
242
|
+
|
|
243
|
+
Small, single-purpose components with focused functionality.
|
|
244
|
+
|
|
245
|
+
| Export | Description | Key Props | Use Case |
|
|
246
|
+
| ----------------------- | -------------------------- | ---------------------------------- | --------------------- |
|
|
247
|
+
| `ExpandableHeaderGlass` | Collapsible section header | `title`, `isExpanded`, `onToggle` | Accordion headers |
|
|
248
|
+
| `IconButtonGlass` | Icon-only button | `icon`, `label`, `onClick` | Toolbars, compact UIs |
|
|
249
|
+
| `SearchBoxGlass` | Search input with icon | `value`, `onChange`, `placeholder` | Search bars |
|
|
250
|
+
| `SortDropdownGlass` | Sort options dropdown | `value`, `options`, `onChange` | Data tables, lists |
|
|
251
|
+
| `StatItemGlass` | Single statistic display | `label`, `value`, `icon` | Dashboard metrics |
|
|
252
|
+
| `ThemeToggleGlass` | Theme switcher button | - | App header |
|
|
253
|
+
|
|
254
|
+
**Import:**
|
|
255
|
+
|
|
256
|
+
```tsx
|
|
257
|
+
import { SearchBoxGlass, ThemeToggleGlass, StatItemGlass } from 'shadcn-glass-ui';
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
**Example:**
|
|
261
|
+
|
|
262
|
+
```tsx
|
|
263
|
+
<SearchBoxGlass
|
|
264
|
+
value={search}
|
|
265
|
+
onChange={setSearch}
|
|
266
|
+
placeholder="Search..."
|
|
267
|
+
/>
|
|
268
|
+
|
|
269
|
+
<ThemeToggleGlass />
|
|
270
|
+
|
|
271
|
+
<StatItemGlass
|
|
272
|
+
label="Total Users"
|
|
273
|
+
value="1,234"
|
|
274
|
+
icon={<Users />}
|
|
275
|
+
/>
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
---
|
|
279
|
+
|
|
280
|
+
### Level 3: Specialized Components (8 components)
|
|
281
|
+
|
|
282
|
+
Domain-specific components with unique styling or functionality.
|
|
283
|
+
|
|
284
|
+
#### Progress Indicators (3)
|
|
285
|
+
|
|
286
|
+
| Export | Description | Key Props | Use Case |
|
|
287
|
+
| ---------------------- | ----------------------------- | -------------------------------- | --------------------------- |
|
|
288
|
+
| `BaseProgressGlass` | Foundation for progress bars | `value`, `className` | Extend for custom progress |
|
|
289
|
+
| `ProgressGlass` | Standard progress bar | `value`, `gradient`, `showValue` | Loading, progress tracking |
|
|
290
|
+
| `RainbowProgressGlass` | Multi-color gradient progress | `value` | Visual appeal, gamification |
|
|
291
|
+
|
|
292
|
+
#### Profile & Status (3)
|
|
293
|
+
|
|
294
|
+
| Export | Description | Key Props | Use Case |
|
|
295
|
+
| ---------------------- | ------------------------ | --------------------------------- | ------------------------- |
|
|
296
|
+
| `ProfileAvatarGlass` | Large avatar with glow | `src`, `alt`, `size` | Profile pages |
|
|
297
|
+
| `StatusIndicatorGlass` | Status dot with glow | `status`, `size` | Online/offline indicators |
|
|
298
|
+
| `LanguageBarGlass` | Language proficiency bar | `language`, `percentage`, `color` | Skills display |
|
|
299
|
+
|
|
300
|
+
#### UI Controls (2)
|
|
301
|
+
|
|
302
|
+
| Export | Description | Key Props | Use Case |
|
|
303
|
+
| ----------------------- | ---------------------- | ------------------------------ | --------------- |
|
|
304
|
+
| `FlagAlertGlass` | Warning/danger flag | `variant`, `title`, `message` | Critical alerts |
|
|
305
|
+
| `SegmentedControlGlass` | Segmented button group | `options`, `value`, `onChange` | View switchers |
|
|
306
|
+
|
|
307
|
+
**Import:**
|
|
308
|
+
|
|
309
|
+
```tsx
|
|
310
|
+
import { ProgressGlass, RainbowProgressGlass, SegmentedControlGlass } from 'shadcn-glass-ui';
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
**Example:**
|
|
314
|
+
|
|
315
|
+
```tsx
|
|
316
|
+
<ProgressGlass value={75} gradient="default" showValue />
|
|
317
|
+
|
|
318
|
+
<RainbowProgressGlass value={60} />
|
|
319
|
+
|
|
320
|
+
<SegmentedControlGlass
|
|
321
|
+
options={['Day', 'Week', 'Month']}
|
|
322
|
+
value="Week"
|
|
323
|
+
onChange={setValue}
|
|
324
|
+
/>
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
---
|
|
328
|
+
|
|
329
|
+
### Level 4: Composite Components (13 components)
|
|
330
|
+
|
|
331
|
+
Multi-component compositions that combine several elements.
|
|
332
|
+
|
|
333
|
+
#### Metrics & Stats (4)
|
|
334
|
+
|
|
335
|
+
| Export | Description | Contains | Use Case |
|
|
336
|
+
| -------------------------- | ------------------------------- | ------------------------ | ---------------------- |
|
|
337
|
+
| `CircularMetricGlass` | Metric with circular progress | CircularProgressGlass | KPI displays |
|
|
338
|
+
| `MetricCardGlass` | Metric display card | GlassCard, ProgressGlass | Dashboard cards |
|
|
339
|
+
| `MetricsGridGlass` | Grid of metrics | Multiple MetricCardGlass | Dashboard layouts |
|
|
340
|
+
| `ContributionMetricsGlass` | GitHub-style contribution chart | Grid, tooltips | Activity visualization |
|
|
341
|
+
|
|
342
|
+
#### User & Profile (3)
|
|
343
|
+
|
|
344
|
+
| Export | Description | Contains | Use Case |
|
|
345
|
+
| -------------------- | ---------------------- | ---------------------------- | -------------------- |
|
|
346
|
+
| `UserInfoGlass` | User info display | AvatarGlass, BadgeGlass | Profile headers |
|
|
347
|
+
| `UserStatsLineGlass` | Single-line user stats | StatItemGlass (multiple) | Compact profiles |
|
|
348
|
+
| `AICardGlass` | AI summary card | GlassCard, BadgeGlass, icons | AI features showcase |
|
|
349
|
+
|
|
350
|
+
#### Repository & Career (6)
|
|
351
|
+
|
|
352
|
+
| Export | Description | Contains | Use Case |
|
|
353
|
+
| ------------------------- | ---------------------------- | ------------------------------ | ------------------ |
|
|
354
|
+
| `RepositoryCardGlass` | Repository card with details | GlassCard, BadgeGlass, buttons | Project listings |
|
|
355
|
+
| `RepositoryHeaderGlass` | Repository header | Breadcrumbs, stats | Repo pages |
|
|
356
|
+
| `RepositoryMetadataGlass` | Repository metadata | Icons, text, links | Repo details |
|
|
357
|
+
| `TrustScoreDisplayGlass` | Trust score indicator | CircularProgressGlass, badges | Reputation systems |
|
|
358
|
+
| `YearCardGlass` | Year timeline card | GlassCard, stats | Career timelines |
|
|
359
|
+
| `CareerStatsHeaderGlass` | Career stats header | Stats, toggle | Profile sections |
|
|
360
|
+
|
|
361
|
+
**Import:**
|
|
362
|
+
|
|
363
|
+
```tsx
|
|
364
|
+
import { MetricCardGlass, CircularMetricGlass, RepositoryCardGlass } from 'shadcn-glass-ui';
|
|
365
|
+
```
|
|
366
|
+
|
|
367
|
+
**Example:**
|
|
368
|
+
|
|
369
|
+
```tsx
|
|
370
|
+
<MetricCardGlass
|
|
371
|
+
title="Total Commits"
|
|
372
|
+
value={1234}
|
|
373
|
+
progress={75}
|
|
374
|
+
icon={<GitCommit />}
|
|
375
|
+
/>
|
|
376
|
+
|
|
377
|
+
<CircularMetricGlass
|
|
378
|
+
value={85}
|
|
379
|
+
label="Score"
|
|
380
|
+
size="lg"
|
|
381
|
+
/>
|
|
382
|
+
```
|
|
383
|
+
|
|
384
|
+
---
|
|
385
|
+
|
|
386
|
+
### Level 5: Section Components (7 components)
|
|
387
|
+
|
|
388
|
+
Complete page sections, ready to use with minimal configuration.
|
|
389
|
+
|
|
390
|
+
| Export | Description | Contains | Use Case |
|
|
391
|
+
| --------------------- | ------------------------- | -------------------------------------------------------- | ----------------- |
|
|
392
|
+
| `HeaderNavGlass` | Navigation header | SearchBoxGlass, ThemeToggleGlass, ButtonGlass | App header |
|
|
393
|
+
| `HeaderBrandingGlass` | Brand header section | Logo, title, links | Landing pages |
|
|
394
|
+
| `ProfileHeaderGlass` | User profile header | ProfileAvatarGlass, UserStatsLineGlass, LanguageBarGlass | Profile pages |
|
|
395
|
+
| `TrustScoreCardGlass` | Trust score card section | TrustScoreDisplayGlass, MetricCardGlass (multiple) | Reputation pages |
|
|
396
|
+
| `CareerStatsGlass` | Career statistics section | CareerStatsHeaderGlass, YearCardGlass (multiple) | Portfolio pages |
|
|
397
|
+
| `FlagsSectionGlass` | Warnings/flags section | ExpandableHeaderGlass, FlagAlertGlass (multiple) | Alert sections |
|
|
398
|
+
| `ProjectsListGlass` | Projects list section | SortDropdownGlass, RepositoryCardGlass (multiple) | Project galleries |
|
|
399
|
+
|
|
400
|
+
**Import:**
|
|
401
|
+
|
|
402
|
+
```tsx
|
|
403
|
+
import { HeaderNavGlass, ProfileHeaderGlass, CareerStatsGlass } from 'shadcn-glass-ui';
|
|
404
|
+
```
|
|
405
|
+
|
|
406
|
+
**Example:**
|
|
407
|
+
|
|
408
|
+
```tsx
|
|
409
|
+
<HeaderNavGlass
|
|
410
|
+
onSearch={handleSearch}
|
|
411
|
+
userName="John Doe"
|
|
412
|
+
/>
|
|
413
|
+
|
|
414
|
+
<ProfileHeaderGlass
|
|
415
|
+
user={{
|
|
416
|
+
name: "John Doe",
|
|
417
|
+
avatar: "/avatar.jpg",
|
|
418
|
+
stats: { repos: 42, followers: 100 },
|
|
419
|
+
languages: [
|
|
420
|
+
{ name: "TypeScript", percentage: 45 },
|
|
421
|
+
{ name: "React", percentage: 35 }
|
|
422
|
+
]
|
|
423
|
+
}}
|
|
424
|
+
/>
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
---
|
|
428
|
+
|
|
429
|
+
## Type System
|
|
430
|
+
|
|
431
|
+
### Component Props Types
|
|
432
|
+
|
|
433
|
+
All component prop types are exported with the `*Props` suffix:
|
|
434
|
+
|
|
435
|
+
```tsx
|
|
436
|
+
import type {
|
|
437
|
+
// Core UI
|
|
438
|
+
ButtonGlassProps,
|
|
439
|
+
InputGlassProps,
|
|
440
|
+
ModalSize,
|
|
441
|
+
|
|
442
|
+
// Atomic
|
|
443
|
+
SearchBoxGlassProps,
|
|
444
|
+
|
|
445
|
+
// Specialized
|
|
446
|
+
ProgressGlassProps,
|
|
447
|
+
ProgressGradient,
|
|
448
|
+
|
|
449
|
+
// Common types
|
|
450
|
+
AvatarSize,
|
|
451
|
+
AvatarStatus,
|
|
452
|
+
BadgeVariant,
|
|
453
|
+
AlertType,
|
|
454
|
+
NotificationType,
|
|
455
|
+
SkeletonVariant,
|
|
456
|
+
TooltipPosition,
|
|
457
|
+
} from 'shadcn-glass-ui';
|
|
458
|
+
```
|
|
459
|
+
|
|
460
|
+
### Variant Types
|
|
461
|
+
|
|
462
|
+
CVA (Class Variance Authority) variant types:
|
|
463
|
+
|
|
464
|
+
```tsx
|
|
465
|
+
import type {
|
|
466
|
+
BadgeVariant, // 'default' | 'secondary' | 'destructive' | 'outline' | 'success' | 'warning' | 'info'
|
|
467
|
+
AlertType, // 'default' | 'destructive' | 'success' | 'warning'
|
|
468
|
+
NotificationType, // 'default' | 'destructive' | 'success' | 'warning'
|
|
469
|
+
SkeletonVariant, // 'text' | 'circle' | 'rectangle'
|
|
470
|
+
TooltipPosition, // 'top' | 'bottom' | 'left' | 'right'
|
|
471
|
+
AvatarSize, // 'xs' | 'sm' | 'md' | 'lg' | 'xl'
|
|
472
|
+
AvatarStatus, // 'online' | 'offline' | 'away' | 'busy'
|
|
473
|
+
ModalSize, // 'sm' | 'md' | 'lg' | 'xl' | 'full'
|
|
474
|
+
ProgressGradient, // 'default' | 'rainbow' | 'blue' | 'green' | 'red'
|
|
475
|
+
GlowType, // 'none' | 'subtle' | 'medium' | 'strong'
|
|
476
|
+
IntensityType, // 'low' | 'medium' | 'high'
|
|
477
|
+
} from 'shadcn-glass-ui';
|
|
478
|
+
```
|
|
479
|
+
|
|
480
|
+
### Theme Types
|
|
481
|
+
|
|
482
|
+
```tsx
|
|
483
|
+
import type {
|
|
484
|
+
Theme, // 'glass' | 'light' | 'aurora'
|
|
485
|
+
ThemeConfig, // { name: Theme; label: string; }
|
|
486
|
+
ThemeContextValue, // { theme: Theme; setTheme: (theme: Theme) => void; cycleTheme: () => void; }
|
|
487
|
+
} from 'shadcn-glass-ui';
|
|
488
|
+
```
|
|
489
|
+
|
|
490
|
+
### Dropdown & Tabs Types
|
|
491
|
+
|
|
492
|
+
```tsx
|
|
493
|
+
import type {
|
|
494
|
+
DropdownItem, // { label: string; value: string; icon?: React.ReactNode; disabled?: boolean; }
|
|
495
|
+
TabItem, // { label: string; value: string; icon?: React.ReactNode; disabled?: boolean; }
|
|
496
|
+
} from 'shadcn-glass-ui';
|
|
497
|
+
```
|
|
498
|
+
|
|
499
|
+
---
|
|
500
|
+
|
|
501
|
+
## Utilities & Hooks
|
|
502
|
+
|
|
503
|
+
### Utility Functions
|
|
504
|
+
|
|
505
|
+
```tsx
|
|
506
|
+
import { cn } from 'shadcn-glass-ui';
|
|
507
|
+
|
|
508
|
+
// Merge Tailwind classes with conflict resolution
|
|
509
|
+
const className = cn('base-class', condition && 'conditional-class', 'override-class');
|
|
510
|
+
```
|
|
511
|
+
|
|
512
|
+
### Theme System
|
|
513
|
+
|
|
514
|
+
```tsx
|
|
515
|
+
import {
|
|
516
|
+
ThemeProvider,
|
|
517
|
+
useTheme,
|
|
518
|
+
THEMES,
|
|
519
|
+
THEME_CONFIG,
|
|
520
|
+
getNextTheme,
|
|
521
|
+
getThemeConfig,
|
|
522
|
+
} from 'shadcn-glass-ui';
|
|
523
|
+
|
|
524
|
+
// Wrap your app
|
|
525
|
+
<ThemeProvider defaultTheme="glass">
|
|
526
|
+
<App />
|
|
527
|
+
</ThemeProvider>;
|
|
528
|
+
|
|
529
|
+
// Use in components
|
|
530
|
+
function MyComponent() {
|
|
531
|
+
const { theme, setTheme, cycleTheme } = useTheme();
|
|
532
|
+
|
|
533
|
+
return (
|
|
534
|
+
<div>
|
|
535
|
+
<p>Current theme: {theme}</p>
|
|
536
|
+
<button onClick={cycleTheme}>Toggle Theme</button>
|
|
537
|
+
</div>
|
|
538
|
+
);
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
// Constants
|
|
542
|
+
console.log(THEMES); // ['glass', 'light', 'aurora']
|
|
543
|
+
console.log(THEME_CONFIG); // [{ name: 'glass', label: 'Glass' }, ...]
|
|
544
|
+
```
|
|
545
|
+
|
|
546
|
+
### React Hooks
|
|
547
|
+
|
|
548
|
+
```tsx
|
|
549
|
+
import { useFocus, useHover, useResponsive, useWallpaperTint } from 'shadcn-glass-ui';
|
|
550
|
+
|
|
551
|
+
// Focus management
|
|
552
|
+
function FocusExample() {
|
|
553
|
+
const { isFocused, focusProps } = useFocus();
|
|
554
|
+
return <input {...focusProps} />;
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
// Hover detection
|
|
558
|
+
function HoverExample() {
|
|
559
|
+
const { isHovered, hoverProps } = useHover();
|
|
560
|
+
return <div {...hoverProps}>Hover me</div>;
|
|
561
|
+
}
|
|
562
|
+
|
|
563
|
+
// Responsive breakpoints
|
|
564
|
+
function ResponsiveExample() {
|
|
565
|
+
const { isMobile, isTablet, isDesktop } = useResponsive();
|
|
566
|
+
return isMobile ? <MobileView /> : <DesktopView />;
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
// Wallpaper tint detection
|
|
570
|
+
function WallpaperExample() {
|
|
571
|
+
const { isDark, tintColor } = useWallpaperTint();
|
|
572
|
+
return <div style={{ color: tintColor }}>Adaptive UI</div>;
|
|
573
|
+
}
|
|
574
|
+
```
|
|
575
|
+
|
|
576
|
+
### CVA Variants (Advanced)
|
|
577
|
+
|
|
578
|
+
For creating custom variants using the same styling system:
|
|
579
|
+
|
|
580
|
+
```tsx
|
|
581
|
+
// Export all CVA variant functions
|
|
582
|
+
export * from './lib/variants';
|
|
583
|
+
|
|
584
|
+
// Usage in custom components
|
|
585
|
+
import { buttonGlassVariants } from 'shadcn-glass-ui';
|
|
586
|
+
|
|
587
|
+
const MyCustomButton = ({ variant, size }) => {
|
|
588
|
+
return <button className={buttonGlassVariants({ variant, size })}>Click me</button>;
|
|
589
|
+
};
|
|
590
|
+
```
|
|
591
|
+
|
|
592
|
+
---
|
|
593
|
+
|
|
594
|
+
## Quick Reference Tables
|
|
595
|
+
|
|
596
|
+
### Most Common Imports (Top 20)
|
|
597
|
+
|
|
598
|
+
```tsx
|
|
599
|
+
import {
|
|
600
|
+
// Theme (always needed)
|
|
601
|
+
ThemeProvider,
|
|
602
|
+
useTheme,
|
|
603
|
+
|
|
604
|
+
// Core UI (80% of use cases)
|
|
605
|
+
ButtonGlass,
|
|
606
|
+
InputGlass,
|
|
607
|
+
GlassCard,
|
|
608
|
+
AlertGlass,
|
|
609
|
+
BadgeGlass,
|
|
610
|
+
ModalGlass,
|
|
611
|
+
TabsGlass,
|
|
612
|
+
CheckboxGlass,
|
|
613
|
+
DropdownGlass,
|
|
614
|
+
|
|
615
|
+
// Atomic (common)
|
|
616
|
+
ThemeToggleGlass,
|
|
617
|
+
SearchBoxGlass,
|
|
618
|
+
|
|
619
|
+
// Specialized (dashboards)
|
|
620
|
+
ProgressGlass,
|
|
621
|
+
|
|
622
|
+
// Composite (dashboards)
|
|
623
|
+
MetricCardGlass,
|
|
624
|
+
|
|
625
|
+
// Sections (app layout)
|
|
626
|
+
HeaderNavGlass,
|
|
627
|
+
|
|
628
|
+
// Utility
|
|
629
|
+
cn,
|
|
630
|
+
} from 'shadcn-glass-ui';
|
|
631
|
+
```
|
|
632
|
+
|
|
633
|
+
### Import by Use Case
|
|
634
|
+
|
|
635
|
+
#### Dashboard Application
|
|
636
|
+
|
|
637
|
+
```tsx
|
|
638
|
+
import {
|
|
639
|
+
ThemeProvider,
|
|
640
|
+
useTheme,
|
|
641
|
+
GlassCard,
|
|
642
|
+
MetricCardGlass,
|
|
643
|
+
CircularMetricGlass,
|
|
644
|
+
MetricsGridGlass,
|
|
645
|
+
ProgressGlass,
|
|
646
|
+
RainbowProgressGlass,
|
|
647
|
+
BadgeGlass,
|
|
648
|
+
HeaderNavGlass,
|
|
649
|
+
} from 'shadcn-glass-ui';
|
|
650
|
+
```
|
|
651
|
+
|
|
652
|
+
#### Form-Heavy Application
|
|
653
|
+
|
|
654
|
+
```tsx
|
|
655
|
+
import {
|
|
656
|
+
ThemeProvider,
|
|
657
|
+
InputGlass,
|
|
658
|
+
ButtonGlass,
|
|
659
|
+
CheckboxGlass,
|
|
660
|
+
ToggleGlass,
|
|
661
|
+
SliderGlass,
|
|
662
|
+
ComboBoxGlass,
|
|
663
|
+
DropdownGlass,
|
|
664
|
+
AlertGlass,
|
|
665
|
+
ModalGlass,
|
|
666
|
+
} from 'shadcn-glass-ui';
|
|
667
|
+
```
|
|
668
|
+
|
|
669
|
+
#### Profile/Portfolio Page
|
|
670
|
+
|
|
671
|
+
```tsx
|
|
672
|
+
import {
|
|
673
|
+
ThemeProvider,
|
|
674
|
+
ProfileHeaderGlass,
|
|
675
|
+
CareerStatsGlass,
|
|
676
|
+
ProjectsListGlass,
|
|
677
|
+
RepositoryCardGlass,
|
|
678
|
+
TrustScoreCardGlass,
|
|
679
|
+
LanguageBarGlass,
|
|
680
|
+
YearCardGlass,
|
|
681
|
+
} from 'shadcn-glass-ui';
|
|
682
|
+
```
|
|
683
|
+
|
|
684
|
+
---
|
|
685
|
+
|
|
686
|
+
## AI Assistant Quick Reference
|
|
687
|
+
|
|
688
|
+
### Component Count by Level
|
|
689
|
+
|
|
690
|
+
- **Level 0 (Primitives):** 3 components
|
|
691
|
+
- **Level 1 (Core UI):** 18 components
|
|
692
|
+
- **Level 2 (Atomic):** 7 components
|
|
693
|
+
- **Level 3 (Specialized):** 10 components
|
|
694
|
+
- **Level 4 (Composite):** 13 components
|
|
695
|
+
- **Level 5 (Sections):** 7 components
|
|
696
|
+
- **Total:** 58 components
|
|
697
|
+
|
|
698
|
+
### Export Categories
|
|
699
|
+
|
|
700
|
+
- **Components:** 58 total
|
|
701
|
+
- **Types:** 25+ prop types, 15+ variant types
|
|
702
|
+
- **Utilities:** 1 function (`cn`)
|
|
703
|
+
- **Hooks:** 4 custom hooks
|
|
704
|
+
- **Theme:** 6 exports (provider, hook, constants, helpers)
|
|
705
|
+
- **CVA Variants:** 15+ variant functions
|
|
706
|
+
|
|
707
|
+
### shadcn/ui Compatibility
|
|
708
|
+
|
|
709
|
+
Components maintain full API compatibility with shadcn/ui:
|
|
710
|
+
|
|
711
|
+
- Standard prop names (`variant`, `size`, `disabled`, etc.)
|
|
712
|
+
- Consistent variant naming (`default`, `secondary`, `destructive`, `outline`)
|
|
713
|
+
- Compatible type definitions
|
|
714
|
+
|
|
715
|
+
### Breaking Changes (v1.0.0)
|
|
716
|
+
|
|
717
|
+
- ❌ `ButtonGlass variant="danger"` → ✅ `variant="destructive"`
|
|
718
|
+
- ❌ `AlertGlass type="error"` → ✅ `variant="destructive"`
|
|
719
|
+
- ❌ `NotificationGlass type="info"` → ✅ `variant="default"`
|
|
720
|
+
- ❌ `SelectGlass` → ✅ `ComboBoxGlass`
|
|
721
|
+
|
|
722
|
+
---
|
|
723
|
+
|
|
724
|
+
## Related Documentation
|
|
725
|
+
|
|
726
|
+
- [Components Catalog](./COMPONENTS_CATALOG.md) - Detailed component reference
|
|
727
|
+
- [Migration Guides](../docs/migration/) - Version upgrade guides
|
|
728
|
+
- [Storybook](https://storybook.example.com) - Live component examples
|
|
729
|
+
- [TypeDoc](https://typedoc.example.com) - Auto-generated API reference
|