1.0.1 • Published 10 months ago
@mtzgpepe/react-ui-hero v1.0.1
React UI Hero Component
A flexible and customizable Hero component for React applications.
Installation
npm install @your-org/react-ui-heroUsage
import { Hero } from '@your-org/react-ui-hero';
function App() {
  return (
    <Hero
      title="Welcome to Our Platform"
      subtitle="Discover amazing features and start building today"
      primaryAction={{
        label: 'Get Started',
        onClick: () => console.log('Get Started clicked')
      }}
      secondaryAction={{
        label: 'Learn More',
        onClick: () => console.log('Learn More clicked')
      }}
    />
  );
}Props
title(string, required): Main title textsubtitle(string, optional): Subtitle textchildren(ReactNode, optional): Additional contentprimaryAction(object, optional): Primary call-to-action button configurationlabel(string): Button textonClick(function): Click handler
secondaryAction(object, optional): Secondary call-to-action button configurationlabel(string): Button textonClick(function): Click handler
backgroundClass(string, optional): Custom background CSS classes (default: 'bg-gradient-to-r from-blue-600 to-blue-500')imageUrl(string, optional): Background image URL
Development
Setup
- Clone the repository
 - Install dependencies:
npm install 
Building
npm run buildPublishing
- Update version in package.json
 - Build the package:
npm run build - Login to npm:
npm login - Publish the package:
npm publish --access public 
License
MIT