103 lines
4.3 KiB
JSON
103 lines
4.3 KiB
JSON
{
|
|
"name": "FeatureCardTwentyFour",
|
|
"description": "Two-column feature card list with title, author, description, tags, and media.",
|
|
"constraints": {
|
|
"textRules": {
|
|
"title": {
|
|
"required": true,
|
|
"example": "Latest Features",
|
|
"minChars": 2,
|
|
"maxChars": 50
|
|
},
|
|
"description": {
|
|
"required": true,
|
|
"example": "Stay updated with our latest announcements",
|
|
"minChars": 5,
|
|
"maxChars": 300
|
|
},
|
|
"tag": {
|
|
"required": false,
|
|
"example": "Features",
|
|
"minChars": 2,
|
|
"maxChars": 30
|
|
}
|
|
},
|
|
"buttonRules": {
|
|
"maxButtons": 2,
|
|
"structure": {
|
|
"text": "string - Button label",
|
|
"href": "string - Link destination (optional)",
|
|
"onClick": "() => void - Additional click handler (optional)",
|
|
"props": "Partial<ButtonPropsForVariant> - Additional button props (optional)"
|
|
},
|
|
"note": "Button variant is controlled by ThemeProvider's defaultButtonVariant."
|
|
},
|
|
"itemRules": {
|
|
"minItems": 1,
|
|
"maxItems": 10,
|
|
"recommendedItems": "2-4",
|
|
"structure": {
|
|
"id": "string",
|
|
"title": "string",
|
|
"author": "string",
|
|
"description": "string",
|
|
"tags": "string[]",
|
|
"media": "Either imageSrc (with optional imageAlt) OR videoSrc (with optional videoAriaLabel)",
|
|
"onFeatureClick": "() => void (optional)"
|
|
},
|
|
"note": "Each feature requires id, title, author, description, tags array. Media uses discriminated union."
|
|
}
|
|
},
|
|
"propsSchema": {
|
|
"features": "FeatureItem[] (required) - Array with id, title, author, description, tags[], imageSrc/videoSrc",
|
|
"animationType": "CardAnimationType",
|
|
"title": "string",
|
|
"titleSegments?": "TitleSegment[]",
|
|
"description": "string",
|
|
"tag?": "string",
|
|
"tagIcon?": "LucideIcon",
|
|
"tagAnimation?": "'none' | 'opacity' | 'slide-up' | 'blur-reveal'",
|
|
"buttons?": "ButtonConfig[]",
|
|
"buttonAnimation?": "'none' | 'opacity' | 'slide-up' | 'blur-reveal'",
|
|
"textboxLayout": "TextboxLayout",
|
|
"useInvertedBackground": "InvertedBackground",
|
|
"ariaLabel?": "string (default: 'Features section')",
|
|
"className?": "string",
|
|
"containerClassName?": "string",
|
|
"cardClassName?": "string",
|
|
"textBoxTitleClassName?": "string",
|
|
"textBoxDescriptionClassName?": "string",
|
|
"textBoxClassName?": "string",
|
|
"textBoxTagClassName?": "string",
|
|
"textBoxButtonContainerClassName?": "string",
|
|
"textBoxButtonClassName?": "string",
|
|
"textBoxButtonTextClassName?": "string",
|
|
"titleImageWrapperClassName?": "string",
|
|
"titleImageClassName?": "string",
|
|
"cardContentClassName?": "string",
|
|
"cardTitleClassName?": "string",
|
|
"authorClassName?": "string",
|
|
"cardDescriptionClassName?": "string",
|
|
"tagsContainerClassName?": "string",
|
|
"tagClassName?": "string",
|
|
"mediaWrapperClassName?": "string",
|
|
"mediaClassName?": "string"
|
|
},
|
|
"usageExample": "<ThemeProvider defaultButtonVariant=\"icon-arrow\" borderRadius=\"rounded\">\n <FeatureCardTwentyFour\n title=\"Latest Features\"\n description=\"Stay updated with our latest announcements.\"\n tag=\"Features\"\n tagIcon={Sparkles}\n textboxLayout=\"default\"\n animationType=\"fade\"\n useInvertedBackground=\"none\"\n features={[\n {\n id: \"1\",\n title: \"Building the Future of Web Development\",\n author: \"John Doe\",\n description: \"A comprehensive guide to modern web technologies.\",\n tags: [\"Development\", \"Tutorial\"],\n imageSrc: \"/feature1.jpg\"\n },\n {\n id: \"2\",\n title: \"Design Systems at Scale\",\n author: \"Jane Smith\",\n description: \"How to build and maintain design systems.\",\n tags: [\"Design\", \"Systems\"],\n imageSrc: \"/feature2.jpg\"\n }\n ]}\n />\n</ThemeProvider>",
|
|
"do": [
|
|
"Use for feature articles, case studies, or content with author attribution",
|
|
"Best for 2-4 featured items",
|
|
"Include relevant tags for each feature",
|
|
"Use high-quality images or videos"
|
|
],
|
|
"dont": [
|
|
"Do not use without author attribution",
|
|
"Do not use for simple feature lists without descriptions"
|
|
],
|
|
"editRules": {
|
|
"textOnly": true,
|
|
"layoutLocked": true,
|
|
"styleLocked": true
|
|
}
|
|
}
|