Velocity X Components

Cards & Expandables

Image Overlay Gradient Card

Full-bleed photo card with title and copy sat over a bottom scrim, tuned so white text stays readable against a bright sky shot exactly as reliably as a dark one — no manual contrast tweaking per image.

Subscription Included with the Velocity Components subscription.
bash
$ velocityx add image-overlay-gradient-card

Built for react. Needs react already installed as a peer dependency. An Astro-only project needs @astrojs/react wired up first — this won't run on its own in plain Astro.

Full docs for Image Overlay Gradient Card →

Needs a licence key — subscribe here, then velocityx loginonce.

react v1.0.1 react

Props

NameTypeRequiredDefaultDescription
srcstringYesrequired
altstringYesrequired
ratio'16/9' | '4/3' | '1/1' | '3/4' | '21/9'No'4/3'
eyebrowstringYessmall label above the title
titlestringYes
descriptionstringYes
hrefstringYeswraps the whole card in a link
classNamestringNo''

File this creates

The CLI writes this path into your project, relative to its root — nothing else moves.

text
components/velocity/image-overlay-gradient-card/ImageOverlayGradientCard.jsx

Using the Image Overlay Gradient Card component

Install it with velocityx add image-overlay-gradient-card. The CLI writes the source straight into your project — no runtime dependency, no registry lock-in, and it themes itself from the same primary-*/accent-* scale as the rest of the library.

More from Cards & Expandables.