-
-
Notifications
You must be signed in to change notification settings - Fork 339
Expand file tree
/
Copy pathFeatureGrid.tsx
More file actions
32 lines (30 loc) · 873 Bytes
/
FeatureGrid.tsx
File metadata and controls
32 lines (30 loc) · 873 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import * as React from 'react'
import { CheckCircleIcon } from '~/components/icons/CheckCircleIcon'
type FeatureGridProps = {
title?: string
items: React.ReactNode[]
gridClassName?: string
}
export function FeatureGrid({ title, items, gridClassName }: FeatureGridProps) {
return (
<div className="px-4 sm:px-6 lg:px-8 mx-auto">
{title ? (
<div className="pb-8">
<h3 className="text-3xl font-bold">{title}</h3>
</div>
) : null}
<div
className={
gridClassName ||
'grid grid-flow-row grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-x-10 gap-y-4 mx-auto'
}
>
{items.map((d, i) => (
<span key={i} className="flex gap-2">
<CheckCircleIcon className="text-green-500 h-lh w-4 shrink-0" /> {d}
</span>
))}
</div>
</div>
)
}