docs: add type description of hero image (#1691)

Co-authored-by: Divyansh Singh <40380293+brc-dd@users.noreply.github.com>
pull/1747/head
Mazel 2 years ago committed by GitHub
parent c4870ba665
commit 655bca1d70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -48,10 +48,18 @@ interface Hero {
// Tagline displayed below `text`. // Tagline displayed below `text`.
tagline?: string tagline?: string
// The image is displayed next to the text and tagline area.
image?: ThemeableImage
// Action buttons to display in home hero section. // Action buttons to display in home hero section.
actions?: HeroAction[] actions?: HeroAction[]
} }
type ThemeableImage =
| string
| { src: string; alt?: string }
| { light: string; dark: string; alt?: string }
interface HeroAction { interface HeroAction {
// Color theme of the button. Defaults to `brand`. // Color theme of the button. Defaults to `brand`.
theme?: 'brand' | 'alt' theme?: 'brand' | 'alt'

Loading…
Cancel
Save