index.tsx
22 lines
| 1 | import {__} from '@wordpress/i18n'; |
| 2 | import styles from './BlankSlate.module.scss'; |
| 3 | |
| 4 | interface BlankSlateProps { |
| 5 | imagePath: string; |
| 6 | description: string; |
| 7 | href: string; |
| 8 | linkText: string; |
| 9 | } |
| 10 | |
| 11 | export default function BlankSlate({imagePath, description, href, linkText}: BlankSlateProps) { |
| 12 | return ( |
| 13 | <div className={styles.container}> |
| 14 | <img src={imagePath} alt={description} /> |
| 15 | <h3>{description}</h3> |
| 16 | <p className={styles.helpMessage}> |
| 17 | {__('Need help? Learn more about', 'give')} <a href={href}>{linkText}</a> |
| 18 | </p> |
| 19 | </div> |
| 20 | ); |
| 21 | } |
| 22 |