| name | groww-ui-toolkit |
| description | Comprehensive React UI component library by Groww. Use for building consistent, accessible web applications with pre-built components. Contains atoms (Button, Input, CheckBox, etc.) and molecules (Calendar, Carousel, etc.). |
Groww UI Toolkit
A comprehensive React component library providing building blocks for modern web applications.
Import All Components
import { Button, TextInput, Select, CheckBox, Table, Tabs, Popup, Toast } from '@groww-tech/ui-toolkit';
Package Structure
@groww-tech/ui-toolkit
├── components/
│ ├── atoms/ # Primitive components
│ └── molecules/ # Composite components
Component Categories
Form Components
Layout Components
Overlay Components
Display Components
Navigation Components
Interactive Components
Common Props Pattern
Most components follow these common patterns:
Default Props
className?: string - Custom CSS class
dataTestId?: string - Test ID for automation
disabled?: boolean - Disabled state
Event Handlers
onChange?: (value: T) => void - Value change callback
onClick?: () => void - Click callback
Display Options
size?: 'small' | 'medium' | 'large' - Size variants
variant?: string - Visual variant
Theme Integration
The toolkit uses CSS variables from @groww-tech/mint-css. Ensure it's imported:
import '@groww-tech/mint-css/dist/index.min.css';
Or in HTML:
<link href="https://cdn.jsdelivr.net/npm/@groww-tech/mint-css/dist/index.min.css" rel="stylesheet">
Accessibility
All components follow WCAG guidelines:
- Keyboard navigation
- Screen reader support
- Focus indicators
- Proper ARIA attributes
Best Practices
- Use semantic components: Button for actions, Link for navigation
- Follow size conventions: Small (32px), Medium (40px), Large (48px)
- Provide labels: Always label form inputs
- Handle loading states: Show feedback during async operations
- Use variants appropriately: Primary for main CTA, negative for destructive actions
Anti-Patterns
- Don't override component internals: Use documented props
- Don't skip error handling: Always provide error states
- Don't forget validation: Validate before submission
- Don't ignore accessibility: Test with screen readers
- Don't use incorrect types: Check component prop types