Skip to content

Commit

Permalink
Merge pull request #473 from lifeparticle/addSectionHeader
Browse files Browse the repository at this point in the history
Added section header
  • Loading branch information
lifeparticle committed Jun 27, 2024
2 parents 027a41d + 63bef06 commit f611997
Showing 1 changed file with 56 additions and 51 deletions.
107 changes: 56 additions & 51 deletions ui/src/pages/About/components/Features.tsx
Original file line number Diff line number Diff line change
@@ -1,62 +1,67 @@
import { FC } from "react";
import { Card, Space, Tag } from "antd";
import {List, Card, Space, Tag } from "antd";
import { FEATURE_DATA } from "data/featureData";
import "react-responsive-carousel/lib/styles/carousel.min.css"; // requires a loader
import { Carousel } from "react-responsive-carousel";

const Features: FC = () => {
return (
<Carousel autoPlay={true} infiniteLoop={true}>
{FEATURE_DATA.filter((feature) => !feature.in_progress).map(
(feature, index) => (
<Card
bordered={false}
key={feature.key}
title={
<a
href={feature.link}
target="_blank"
rel="noopener noreferrer"

<List header={<div>Features</div>} bordered>
<List.Item>
<Carousel autoPlay={true} infiniteLoop={true}>
{FEATURE_DATA.filter((feature) => !feature.in_progress).map(
(feature, index) => (
<Card
bordered={false}
key={feature.key}
title={
<a
href={feature.link}
target="_blank"
rel="noopener noreferrer"
>
<h5>
{index} - {feature.name}
</h5>
</a>
}
actions={[
<Space key={feature.key}>
{feature.library.map((lib) => {
return (
<a
key={lib.url}
href={lib.url}
target="_blank"
rel="noopener noreferrer"
>
<Tag
color={
lib.name === "Vanilla JS"
? "green"
: "gold"
}
>
{lib.name}
</Tag>
</a>
);
})}
</Space>,
]}
>
<h5>
{index} - {feature.name}
</h5>
</a>
}
actions={[
<Space key={feature.key}>
{feature.library.map((lib) => {
return (
<a
key={lib.url}
href={lib.url}
target="_blank"
rel="noopener noreferrer"
>
<Tag
color={
lib.name === "Vanilla JS"
? "green"
: "gold"
}
>
{lib.name}
</Tag>
</a>
);
})}
</Space>,
]}
>
{feature.fullDescription.length > 0
? feature.fullDescription
: feature.shortDescription}
<br />
<br />
</Card>
)
)}
</Carousel>
{feature.fullDescription.length > 0
? feature.fullDescription
: feature.shortDescription}
<br />
<br />
</Card>
)
)}
</Carousel>
</List.Item>
</List>
);
};

Expand Down

0 comments on commit f611997

Please sign in to comment.