mirror of
https://github.com/vercel/commerce.git
synced 2025-07-27 04:01:23 +00:00
v1 convert to Agility
This commit is contained in:
29
components/agility-modules/Hero.tsx
Normal file
29
components/agility-modules/Hero.tsx
Normal file
@@ -0,0 +1,29 @@
|
||||
import React, { FC } from 'react'
|
||||
import { Hero } from '@components/ui'
|
||||
import * as AgilityTypes from "@agility/types"
|
||||
|
||||
|
||||
interface Fields {
|
||||
title:string,
|
||||
description:string
|
||||
cTA?:AgilityTypes.URLField
|
||||
}
|
||||
|
||||
interface Props {
|
||||
fields: Fields
|
||||
}
|
||||
|
||||
const HeroModule:FC<Props> = ({fields}) => {
|
||||
|
||||
return (
|
||||
<Hero
|
||||
headline={fields.title}
|
||||
description={fields.description}
|
||||
linkText={fields.cTA?.text}
|
||||
linkUrl={fields.cTA?.href}
|
||||
/>
|
||||
)
|
||||
}
|
||||
|
||||
export default HeroModule
|
||||
|
Reference in New Issue
Block a user