The Card component is a versatile content display component that combines images, text content, and call-to-action buttons in various layout configurations. It supports four different display modes for flexible content presentation.
The Card component is ideal for feature highlights, product showcases, service descriptions, or any content that benefits from a visual + textual presentation.
- DisplayAs: Layout configuration (
textOnRight,textOnLeft,textAboveCard,textBelowCard) - Heading: Main title text (displayed as large, bold text)
- SubHeading: Secondary subtitle text
- Body: Rich text content (HTML)
- Asset: Image or media asset
- Links: Collection of call-to-action buttons
No Visual Builder style options are currently configured for the Card component.
[Placeholder for Card component screenshot showing different layout configurations]
Card.astro- Main component that handles layout switchingWrapper.astro- Container component that applies layout-specific CSS classesContent.astro- Text content and call-to-action renderingAsset.astro- Image/media asset renderingcard.graphql- GraphQL fragment for component data
- Responsive design with different layouts for mobile and desktop
- Smart button styling (primary vs secondary based on order)
- Handles missing assets gracefully
- Uses CSS Grid for flexible layouts
- Supports rich text content with HTML rendering
- Fixed image dimensions (1075x700) with lazy loading
- All layouts are contained within max-width containers for readability