|
1 | 1 | import { LabCard } from './index' |
| 2 | +import type { FeaturedLab } from '../../../build/featured' |
2 | 3 |
|
3 | | -const example = { |
| 4 | +const multiProject: FeaturedLab = { |
4 | 5 | title: 'Forms Lab', |
5 | 6 | tagline: 'Digitize forms to create modern, accessible experiences for public outreach.', |
6 | 7 | order: 1, |
7 | 8 | links: [ |
8 | | - { label: 'Demo (Forms Platform)', url: 'https://example.com/demo' }, |
9 | | - { label: 'GitHub repository — Forms Platform', url: 'https://github.com/flexion/forms' }, |
10 | | - { label: 'GitHub repository — Forms Lab (experiment)', url: 'https://github.com/flexion/forms-lab' }, |
| 9 | + { label: 'Live demo', url: 'https://example.com/demo', kind: 'demo', group: 'Forms Platform' }, |
| 10 | + { label: 'Repository', url: 'https://github.com/flexion/forms', kind: 'repo', group: 'Forms Platform' }, |
| 11 | + { label: 'Live demo', url: 'https://example.com/lab', kind: 'demo', group: 'Forms Lab (experiment)' }, |
| 12 | + { label: 'Repository', url: 'https://github.com/flexion/forms-lab', kind: 'repo', group: 'Forms Lab (experiment)' }, |
| 13 | + ], |
| 14 | +} |
| 15 | + |
| 16 | +const singleLink: FeaturedLab = { |
| 17 | + title: 'Messaging Lab', |
| 18 | + tagline: 'Text messaging services to deliver critical updates to the people you serve.', |
| 19 | + order: 2, |
| 20 | + links: [ |
| 21 | + { label: 'Repository', url: 'https://github.com/flexion/flexion-notify', kind: 'repo' }, |
| 22 | + ], |
| 23 | +} |
| 24 | + |
| 25 | +const withCaseStudy: FeaturedLab = { |
| 26 | + title: 'Document Extractor Lab', |
| 27 | + tagline: 'Accurately extract data from PDFs and images for faster application processing.', |
| 28 | + order: 3, |
| 29 | + links: [ |
| 30 | + { label: 'Repository', url: 'https://github.com/flexion/document-extractor', kind: 'repo' }, |
| 31 | + { label: 'Case study', url: 'https://flexion.us/case-study/document-extraction-for-faster-processing/', kind: 'case-study' }, |
11 | 32 | ], |
12 | 33 | } |
13 | 34 |
|
14 | 35 | export function LabCardExamples() { |
15 | 36 | return ( |
16 | 37 | <section id="lab-card"> |
17 | 38 | <h2>Lab card</h2> |
18 | | - <p>Featured-lab card on the home page. Title is not a link; each link inside the card is an external link.</p> |
19 | | - <LabCard lab={example} /> |
| 39 | + <p> |
| 40 | + Featured-lab card on the home page. Cards read as a horizontal band on wide containers |
| 41 | + and stack vertically on narrow ones. Links are grouped by sub-project when a card has |
| 42 | + more than one, and each link is prefixed with an icon that signals its type (demo, |
| 43 | + repository, or case study). |
| 44 | + </p> |
| 45 | + <div class="l-stack" data-space="md"> |
| 46 | + <LabCard lab={multiProject} /> |
| 47 | + <LabCard lab={singleLink} /> |
| 48 | + <LabCard lab={withCaseStudy} /> |
| 49 | + </div> |
20 | 50 | </section> |
21 | 51 | ) |
22 | 52 | } |
0 commit comments