-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bdc1092
commit ef1b23a
Showing
6 changed files
with
57 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
"use client"; | ||
import { useState } from "react"; | ||
import Image from "next/image"; | ||
|
||
export default function ScreenshotTabs() { | ||
const [selected, setSelected] = useState(0); | ||
const screenshots = [ | ||
{ | ||
// title: "History & traces", | ||
// title: "Build", | ||
title: "Tracing", | ||
src: "/assets/homepage/hero/2024-12-12-runs.png", | ||
alt: "Inngest function runs and traces", | ||
}, | ||
{ | ||
title: "Observability", | ||
src: "/assets/homepage/hero/2024-12-12-metrics.png", | ||
alt: "Inngest metrics dashboard", | ||
}, | ||
{ | ||
// title: "Function metrics", | ||
title: "Management", | ||
src: "/assets/homepage/hero/2024-12-12-function-list.png", | ||
alt: "Inngest function dashboard", | ||
}, | ||
]; | ||
const screenshot = screenshots[selected]; | ||
|
||
return ( | ||
<div className="flex flex-col gap-2 items-center"> | ||
<div className="p-1 flex flex-row gap-1 rounded-lg text-sm font-semibold bg-carbon-50/10 backdrop-blur"> | ||
{screenshots.map((s, idx) => ( | ||
<button | ||
className={ | ||
"py-1 px-4 rounded-md transition-all hover:bg-carbon-50/10 data-[state=active]:bg-carbon-50 data-[state=active]:text-carbon-800" | ||
} | ||
data-state={idx === selected ? "active" : "inactive"} | ||
aria-selected={idx === selected} | ||
onClick={() => setSelected(idx)} | ||
> | ||
{s.title} | ||
</button> | ||
))} | ||
</div> | ||
<Image | ||
alt={`Screenshot of ${screenshot.alt}`} | ||
className="rounded-t-md mx-auto" | ||
src={screenshot.src} | ||
width={3026 * 0.35} | ||
height={1850 * 0.35} | ||
/> | ||
</div> | ||
); | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.