Skip to content

Commit

Permalink
feat: add references to /guestbook
Browse files Browse the repository at this point in the history
  • Loading branch information
mateusfg7 committed Jan 23, 2024
1 parent 9e170a6 commit 43ae5e9
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/app/components/header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ export function Header() {
<MenuItem name="Blog" path="/blog" />
<MenuItem name="Projects" path="/projects" />
<MenuItem name="About" path="/about" />
<MenuItem name="Guestbook" path="/guestbook" />
</nav>
<div className="flex w-full items-center gap-8 md:w-auto">
<Search />
Expand Down
4 changes: 3 additions & 1 deletion src/app/components/header/mobile-menu/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ import {
MagnifyingGlass,
Note,
User,
Briefcase
Briefcase,
Book
} from '@phosphor-icons/react/dist/ssr'

import { ToggleTheme } from './toggle-theme'
Expand Down Expand Up @@ -109,6 +110,7 @@ export function MobileMenu() {
<Link title="Blog" icon={Note} href="/blog" />
<Link title="Projects" icon={Briefcase} href="/projects" />
<Link title="About" icon={User} href="/about" />
<Link title="Guestbook" icon={Book} href="/guestbook" />
<Link title="Sitemap" icon={TreeStructure} href="/sitemap" />
<Search />
<OutLink
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/header/mobile-menu/styles.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
.menu-item {
@apply flex items-center gap-7 px-7 py-5 leading-none active:bg-neutral-200 active:dark:bg-neutral-1000;
@apply flex items-center gap-7 px-7 py-4 leading-none active:bg-neutral-200 active:dark:bg-neutral-1000;
}
3 changes: 2 additions & 1 deletion src/app/lib/all-routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ const commonPaths = [
'blog/categories',
'blog/tag',
'blog/feed',
'blog/author'
'blog/author',
'guestbook'
]
const tagPaths = getUniqueTagListFromPosts().map(tag => `blog/tag/${slug(tag)}`)
const categoryPaths = getUniqueCategoryList().map(
Expand Down
11 changes: 10 additions & 1 deletion src/shared/components/kbar/provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ import {
Files,
Books,
ChartPieSlice,
Notebook
Notebook,
Book
} from '@phosphor-icons/react/dist/ssr'
import { getSortedPosts } from '@/shared/lib/get-sorted-posts'
import { KBar } from '@/shared/components/kbar'
Expand Down Expand Up @@ -58,6 +59,14 @@ export function CustomKBarProvider({ children }: { children: ReactNode }) {
icon: <User size="1em" weight="duotone" />,
perform: () => push('/about')
},
{
id: 'guestbook',
name: 'Guestbook',
shortcut: ['n', 'g'],
keywords: 'presence list',
icon: <Book size="1em" weight="duotone" />,
perform: () => push('/guestbook')
},
{
id: 'statistics',
name: 'Statistics',
Expand Down

0 comments on commit 43ae5e9

Please sign in to comment.