73 lines
1.7 KiB
TypeScript
Raw Normal View History

import clsx from 'clsx';
import React from 'react';
import styles from './styles.module.css';
type FeatureItem = {
title: string;
Svg: React.ComponentType<React.ComponentProps<'svg'>>;
description: JSX.Element;
};
const FeatureList: FeatureItem[] = [
{
title: '增强特性',
description: (
<>
DPI Spine
</>
),
},
{
title: '性能提升',
description: (
<>
Label
</>
),
},
{
title: '开箱即用',
description: (
<>
JavaScript 使
2022-07-05 18:10:58 +08:00
</>
),
},
{
title: '原生体验',
2022-07-05 18:10:58 +08:00
description: (
<>
使
</>
),
},
];
function Feature({ title, Svg, description }: FeatureItem) {
return (
2022-07-05 18:10:58 +08:00
<div className={clsx('col col--3')}>
{/* <div className="text--center">
<Svg className={styles.featureSvg} role="img" />
2022-07-05 18:10:58 +08:00
</div> */}
<div className="text--center padding-horiz--md">
<h3>{title}</h3>
<p>{description}</p>
</div>
</div>
);
}
export default function HomepageFeatures(): JSX.Element {
return (
<section className={styles.features}>
<div className="container">
<div className="row">
{FeatureList.map((props, idx) => (
<Feature key={idx} {...props} />
))}
</div>
</div>
</section>
);
}