-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added: nav menu & github activity page
- Loading branch information
1 parent
b2ea38f
commit 0549c44
Showing
13 changed files
with
732 additions
and
24 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,37 @@ | ||
import Link from "next/link"; | ||
import { getRecentContributions } from "../actions"; | ||
import { format, parseISO } from "date-fns"; | ||
|
||
const GithubActivityPage = async () => { | ||
const contributions = await getRecentContributions(100); | ||
return ( | ||
<main className="space-y-8"> | ||
<header className="font-bold"> | ||
<span>github activity</span> | ||
</header> | ||
<ul className="space-y-8"> | ||
{contributions.map((contribution) => ( | ||
<li key={contribution.abbreviatedOid} className=""> | ||
<Link | ||
href={contribution.repoUrl} | ||
className="text-sm text-zinc-600 dark:text-zinc-400 hover:underline" | ||
> | ||
{contribution.repo} | ||
</Link> | ||
<Link | ||
href={contribution.commitUrl} | ||
className="flex justify-between items-center hover:underline" | ||
> | ||
<p className="w-4/6">{contribution.message}</p> | ||
<p className="text-sm text-zinc-600 dark:text-zinc-400"> | ||
{format(parseISO(contribution.committedDate), "MMM do, yy")} | ||
</p> | ||
</Link> | ||
</li> | ||
))} | ||
</ul> | ||
</main> | ||
); | ||
}; | ||
|
||
export default GithubActivityPage; |
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,16 @@ | ||
import React from "react"; | ||
|
||
interface KbdProps { | ||
letter: string; | ||
} | ||
|
||
const Kbd = ({ letter }: KbdProps) => { | ||
return ( | ||
<kbd className="pointer-events-none inline-flex h-5 select-none items-center justify-center gap-1 font-mono font-medium text-zinc-700 dark:text-zinc-300"> | ||
<span className="text-base">⌘</span> | ||
<span className="text-sm">{letter}</span> | ||
</kbd> | ||
); | ||
}; | ||
|
||
export default Kbd; |
Oops, something went wrong.