Initial commit
This commit is contained in:
86
registry/components/FooterMedia.json
Normal file
86
registry/components/FooterMedia.json
Normal file
@@ -0,0 +1,86 @@
|
||||
{
|
||||
"name": "FooterMedia",
|
||||
"description": "Footer with full-width media (image/video) above classic navigation layout.",
|
||||
"constraints": {
|
||||
"textRules": {
|
||||
"logoText": {
|
||||
"required": false,
|
||||
"default": "Webild",
|
||||
"example": "Company Name",
|
||||
"minChars": 2,
|
||||
"maxChars": 30
|
||||
},
|
||||
"copyrightText": {
|
||||
"required": false,
|
||||
"default": "© 2025 | Webild",
|
||||
"example": "© 2025 Company Name",
|
||||
"minChars": 5,
|
||||
"maxChars": 50
|
||||
},
|
||||
"columnTitle": {
|
||||
"required": true,
|
||||
"example": "Product",
|
||||
"minChars": 2,
|
||||
"maxChars": 20
|
||||
},
|
||||
"itemLabel": {
|
||||
"required": true,
|
||||
"example": "Features",
|
||||
"minChars": 2,
|
||||
"maxChars": 30
|
||||
}
|
||||
},
|
||||
"mediaRules": {
|
||||
"note": "Either imageSrc or videoSrc is required (discriminated union)",
|
||||
"imageSrc": {
|
||||
"required": "conditional - required if no videoSrc",
|
||||
"example": "https://images.unsplash.com/photo-1497215728101-856f4ea42174?w=1920"
|
||||
},
|
||||
"videoSrc": {
|
||||
"required": "conditional - required if no imageSrc",
|
||||
"example": "/videos/footer-background.mp4"
|
||||
}
|
||||
},
|
||||
"structureRules": {
|
||||
"columns": {
|
||||
"required": true,
|
||||
"minColumns": 1,
|
||||
"maxColumns": 3,
|
||||
"note": "Each column must have title and items array"
|
||||
},
|
||||
"items": {
|
||||
"required": true,
|
||||
"minItems": 1,
|
||||
"structure": {
|
||||
"label": "string - Link text (required)",
|
||||
"href": "string - Link destination (optional)",
|
||||
"onClick": "() => void - Additional click handler (optional)"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"propsSchema": {
|
||||
"imageSrc": "string (required if no videoSrc)",
|
||||
"imageAlt?": "string (default: '')",
|
||||
"videoSrc": "string (required if no imageSrc)",
|
||||
"videoAriaLabel?": "string (default: 'Footer video')",
|
||||
"columns": "Array<{ title: string, items: Array<{ label: string, href: string }> }> - Footer navigation columns (required)",
|
||||
"logoText?": "string (default: 'Webild')",
|
||||
"copyrightText?": "string (default: '© 2025 | Webild')",
|
||||
"onPrivacyClick?": "() => void",
|
||||
"ariaLabel?": "string (default: 'Site footer')",
|
||||
"className?": "string"
|
||||
},
|
||||
"usageExample": "<FooterMedia imageSrc=\"https://images.unsplash.com/photo-1497215728101-856f4ea42174?w=1920\" columns={[{ title: 'Product', items: [{ label: 'Features', href: 'features' }, { label: 'Pricing', href: 'pricing' }] }]} copyrightText=\"© 2025 | Company\" />",
|
||||
"do": [
|
||||
"Use for feature showcases",
|
||||
"Use for capability displays",
|
||||
"Requires columns[]"
|
||||
],
|
||||
"dont": [],
|
||||
"editRules": {
|
||||
"textOnly": true,
|
||||
"layoutLocked": true,
|
||||
"styleLocked": true
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user