Stacked List 7



<section id="relume" class="border-x border-t border-border-primary">
<div class="grid grid-cols-1 items-end gap-4 p-6 md:grid-cols-[1fr_max-content] md:gap-6">
<div class="max-w-lg">
<h2 class="text-xl font-bold md:text-2xl">Recent Tasks</h2>
<p class="mt-1">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros.
</p>
</div>
<div class="flex items-center justify-between gap-4">
<div class="flex flex-wrap gap-4">
<button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 border border-border-primary text-text-primary bg-background-primary px-5 py-2"
title="Button"
>
Button</button
><button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 border border-border-primary bg-background-alternative text-text-alternative px-5 py-2"
title="Button"
>
Button
</button>
</div>
<button
type="button"
id="radix-:R19:"
aria-haspopup="menu"
aria-expanded="false"
data-state="closed"
class="cursor-pointer border border-border-alternative p-2 focus-visible:outline-none"
>
<svg
stroke="currentColor"
fill="currentColor"
stroke-width="0"
viewBox="0 0 24 24"
class="size-6"
height="1em"
width="1em"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"
></path>
</svg>
</button>
</div>
</div>
<div class="border-t border-border-primary">
<a
href="#"
class="grid max-w-full grid-cols-1 gap-6 border-b border-border-primary px-6 py-4 md:grid-cols-[1fr_max-content]"
><div class="w-full max-w-lg">
<h3 class="font-semibold">Task name</h3>
<p class="text-sm">Created on June 20, 2023</p>
</div>
<div class="flex items-center justify-between gap-4">
<h4
class="flex items-center justify-center bg-background-secondary px-3 py-0.5 text-sm font-medium"
>
Complete
</h4>
<button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 text-text-primary size-10"
>
<svg
stroke="currentColor"
fill="none"
stroke-width="0"
viewBox="0 0 15 15"
class="size-5"
height="1em"
width="1em"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M6.1584 3.13508C6.35985 2.94621 6.67627 2.95642 6.86514 3.15788L10.6151 7.15788C10.7954 7.3502 10.7954 7.64949 10.6151 7.84182L6.86514 11.8418C6.67627 12.0433 6.35985 12.0535 6.1584 11.8646C5.95694 11.6757 5.94673 11.3593 6.1356 11.1579L9.565 7.49985L6.1356 3.84182C5.94673 3.64036 5.95694 3.32394 6.1584 3.13508Z"
fill="currentColor"
></path>
</svg>
</button></div></a
><a
href="#"
class="grid max-w-full grid-cols-1 gap-6 border-b border-border-primary px-6 py-4 md:grid-cols-[1fr_max-content]"
><div class="w-full max-w-lg">
<h3 class="font-semibold">Task name</h3>
<p class="text-sm">Created on June 20, 2023</p>
</div>
<div class="flex items-center justify-between gap-4">
<h4
class="flex items-center justify-center bg-background-secondary px-3 py-0.5 text-sm font-medium"
>
Complete
</h4>
<button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 text-text-primary size-10"
>
<svg
stroke="currentColor"
fill="none"
stroke-width="0"
viewBox="0 0 15 15"
class="size-5"
height="1em"
width="1em"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M6.1584 3.13508C6.35985 2.94621 6.67627 2.95642 6.86514 3.15788L10.6151 7.15788C10.7954 7.3502 10.7954 7.64949 10.6151 7.84182L6.86514 11.8418C6.67627 12.0433 6.35985 12.0535 6.1584 11.8646C5.95694 11.6757 5.94673 11.3593 6.1356 11.1579L9.565 7.49985L6.1356 3.84182C5.94673 3.64036 5.95694 3.32394 6.1584 3.13508Z"
fill="currentColor"
></path>
</svg>
</button></div></a
><a
href="#"
class="grid max-w-full grid-cols-1 gap-6 border-b border-border-primary px-6 py-4 md:grid-cols-[1fr_max-content]"
><div class="w-full max-w-lg">
<h3 class="font-semibold">Task name</h3>
<p class="text-sm">Created on June 20, 2023</p>
</div>
<div class="flex items-center justify-between gap-4">
<h4
class="flex items-center justify-center bg-background-secondary px-3 py-0.5 text-sm font-medium"
>
Complete
</h4>
<button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 text-text-primary size-10"
>
<svg
stroke="currentColor"
fill="none"
stroke-width="0"
viewBox="0 0 15 15"
class="size-5"
height="1em"
width="1em"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M6.1584 3.13508C6.35985 2.94621 6.67627 2.95642 6.86514 3.15788L10.6151 7.15788C10.7954 7.3502 10.7954 7.64949 10.6151 7.84182L6.86514 11.8418C6.67627 12.0433 6.35985 12.0535 6.1584 11.8646C5.95694 11.6757 5.94673 11.3593 6.1356 11.1579L9.565 7.49985L6.1356 3.84182C5.94673 3.64036 5.95694 3.32394 6.1584 3.13508Z"
fill="currentColor"
></path>
</svg>
</button></div></a
><a
href="#"
class="grid max-w-full grid-cols-1 gap-6 border-b border-border-primary px-6 py-4 md:grid-cols-[1fr_max-content]"
><div class="w-full max-w-lg">
<h3 class="font-semibold">Task name</h3>
<p class="text-sm">Created on June 20, 2023</p>
</div>
<div class="flex items-center justify-between gap-4">
<h4
class="flex items-center justify-center bg-background-secondary px-3 py-0.5 text-sm font-medium"
>
Complete
</h4>
<button
class="focus-visible:ring-border-primary inline-flex gap-3 items-center justify-center whitespace-nowrap ring-offset-white transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 text-text-primary size-10"
>
<svg
stroke="currentColor"
fill="none"
stroke-width="0"
viewBox="0 0 15 15"
class="size-5"
height="1em"
width="1em"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M6.1584 3.13508C6.35985 2.94621 6.67627 2.95642 6.86514 3.15788L10.6151 7.15788C10.7954 7.3502 10.7954 7.64949 10.6151 7.84182L6.86514 11.8418C6.67627 12.0433 6.35985 12.0535 6.1584 11.8646C5.95694 11.6757 5.94673 11.3593 6.1356 11.1579L9.565 7.49985L6.1356 3.84182C5.94673 3.64036 5.95694 3.32394 6.1584 3.13508Z"
fill="currentColor"
></path>
</svg>
</button></div
></a>
</div>
</section>
import { Button } from "@relume_io/relume-ui";
import type { ButtonProps } from "@relume_io/relume-ui";
import { BiDotsHorizontalRounded } from "react-icons/bi";
import {
DropdownMenu,
DropdownMenuContent,
DropdownMenuItem,
DropdownMenuTrigger,
} from "@relume_io/relume-ui";
import { RxChevronRight } from "react-icons/rx";
type ListProps = {
url: string;
title: string;
date: string;
badge: string;
button: ButtonProps;
};
type Props = {
heading: string;
description: string;
buttons: ButtonProps[];
options: string[];
lists: ListProps[];
};
export type StackedList7Props = React.ComponentPropsWithoutRef<"section"> & Partial<Props>;
export const StackedList7 = (props: StackedList7Props) => {
const { heading, description, buttons, options, lists } = {
...StackedList7Defaults,
...props,
};
return (
<section id="relume" className="border-x border-t border-border-primary">
<div className="grid grid-cols-1 items-end gap-4 p-6 md:grid-cols-[1fr_max-content] md:gap-6">
<div className="max-w-lg">
<h2 className="text-xl font-bold md:text-2xl">{heading}</h2>
<p className="mt-1">{description}</p>
</div>
<div className="flex items-center justify-between gap-4">
<div className="flex flex-wrap gap-4">
{buttons.map((button, index) => (
<Button key={index} {...button}>
{button.title}
</Button>
))}
</div>
<DropdownMenu>
<DropdownMenuTrigger>
<BiDotsHorizontalRounded className="size-6" />
</DropdownMenuTrigger>
<DropdownMenuContent>
{options.map((option, index) => (
<DropdownMenuItem key={index}>{option}</DropdownMenuItem>
))}
</DropdownMenuContent>
</DropdownMenu>
</div>
</div>
<div className="border-t border-border-primary">
{lists.map((list, index) => (
<a
key={index}
href={list.url}
className="grid max-w-full grid-cols-1 gap-6 border-b border-border-primary px-6 py-4 md:grid-cols-[1fr_max-content]"
>
<div className="w-full max-w-lg">
<h3 className="font-semibold">{list.title}</h3>
<p className="text-sm">{list.date}</p>
</div>
<div className="flex items-center justify-between gap-4">
<h4 className="flex items-center justify-center bg-background-secondary px-3 py-0.5 text-sm font-medium">
{list.badge}
</h4>
<Button {...list.button} />
</div>
</a>
))}
</div>
</section>
);
};
export const StackedList7Defaults: Props = {
heading: "Recent Tasks",
description:
"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros.",
buttons: [
{
title: "Button",
variant: "secondary",
size: "sm",
},
{
title: "Button",
size: "sm",
},
],
options: ["Option One", "Option Two", "Option Three"],
lists: [
{
url: "#",
title: "Task name",
date: "Created on June 20, 2023",
badge: "Complete",
button: {
variant: "tertiary",
size: "icon",
iconRight: <RxChevronRight className="size-5" />,
},
},
{
url: "#",
title: "Task name",
date: "Created on June 20, 2023",
badge: "Complete",
button: {
variant: "tertiary",
size: "icon",
iconRight: <RxChevronRight className="size-5" />,
},
},
{
url: "#",
title: "Task name",
date: "Created on June 20, 2023",
badge: "Complete",
button: {
variant: "tertiary",
size: "icon",
iconRight: <RxChevronRight className="size-5" />,
},
},
{
url: "#",
title: "Task name",
date: "Created on June 20, 2023",
badge: "Complete",
button: {
variant: "tertiary",
size: "icon",
iconRight: <RxChevronRight className="size-5" />,
},
},
],
};
Need help?
For installation guidelines and API information, visit the docs.
Examples
No items found.