Initial commit
This commit is contained in:
64
registry/components/BlogCardTwo.json
Normal file
64
registry/components/BlogCardTwo.json
Normal file
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"name": "BlogCardTwo",
|
||||
"description": "Blog section with card grid/carousel layout featuring image, author/date, title, excerpt, and multiple tags.",
|
||||
"constraints": {
|
||||
"textRules": {
|
||||
"title": {
|
||||
"required": true,
|
||||
"example": "Latest Articles",
|
||||
"minChars": 2,
|
||||
"maxChars": 50
|
||||
},
|
||||
"description": {
|
||||
"required": true,
|
||||
"example": "Insights and updates from our team",
|
||||
"minChars": 5,
|
||||
"maxChars": 250
|
||||
},
|
||||
"tag": {
|
||||
"required": false,
|
||||
"example": "Blog",
|
||||
"minChars": 2,
|
||||
"maxChars": 30
|
||||
}
|
||||
},
|
||||
"blogRules": {
|
||||
"blogs": {
|
||||
"required": true,
|
||||
"minItems": 1,
|
||||
"example": "[{\"id\": \"1\", \"category\": [\"Design\", \"Research\"], \"title\": \"UX review presentations\", \"excerpt\": \"How to create compelling presentations\", \"imageSrc\": \"/blog-1.jpg\", \"authorName\": \"Olivia Rhye\", \"date\": \"20 Jan 2025\"}]",
|
||||
"note": "Array of blog items. Each item requires id, category (string | string[]), title, excerpt, imageSrc, authorName, and date."
|
||||
}
|
||||
}
|
||||
},
|
||||
"propsSchema": {
|
||||
"blogs": "Array<{ id: string, category: string | string[], title: string, excerpt: string, imageSrc: string, imageAlt?: string, authorName: string, authorAvatar?: string, date: string, onBlogClick?: () => void }> - Blog card items",
|
||||
"carouselMode?": "'auto' | 'buttons' (default: 'buttons')",
|
||||
"uniformGridCustomHeightClasses?": "string",
|
||||
"animationType": "'none' | 'opacity' | 'slide-up' | 'scale-rotate' | 'blur-reveal' (required - controls GSAP scroll animations with stagger effect)",
|
||||
"title": "string",
|
||||
"titleSegments?": "Array<{ type: 'text', content: string } | { type: 'image', src: string, alt?: string }> - For inline images in title",
|
||||
"description": "string",
|
||||
"tag?": "string",
|
||||
"tagIcon?": "LucideIcon",
|
||||
"buttons?": "Array<{text: string, onClick?: () => void, href?: string}>",
|
||||
"textboxLayout": "'default' | 'split' | 'split-actions' | 'split-description' | 'inline-image' (required - 'inline-image' uses titleSegments for rich text with images)",
|
||||
"useInvertedBackground": "'noInvert' | 'invertDefault'",
|
||||
"ariaLabel?": "string (default: 'Blog section')",
|
||||
"className?": "string"
|
||||
},
|
||||
"usageExample": "<BlogCardTwo blogs={[{id: '1', category: ['Design', 'Research', 'Presentation'], title: 'UX review presentations', excerpt: 'How to create compelling presentations that wow your audience', imageSrc: '/blog-1.jpg', authorName: 'Olivia Rhye', date: '20 Jan 2025', onBlogClick: () => console.log('clicked')}]} title=\"Latest Articles\" description=\"Stay updated with our latest insights\" textboxLayout=\"default\" useInvertedBackground={\"noInvert\"} animationType=\"slide-up\" carouselMode=\"buttons\" />",
|
||||
"do": [
|
||||
"Use for blog listings",
|
||||
"Use for article grids",
|
||||
"Requires blogs[]",
|
||||
"Requires titleSegments?[]",
|
||||
"Requires buttons?[]"
|
||||
],
|
||||
"dont": [],
|
||||
"editRules": {
|
||||
"textOnly": true,
|
||||
"layoutLocked": true,
|
||||
"styleLocked": true
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user