Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 12 additions & 8 deletions src/components/ContentNav/ContentNav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,19 @@ const ContentNav: FC<ContentNavProps> = ({
);
return (
<div className="content-nav">
<button>
{Chevron}
{prevText}
</button>
<div className="nav-item prev">
<a href="">
{Chevron}
<span>{prevText}</span>
</a>
</div>
{current && <div className="current middle">{current}</div>}
<button>
{nextText}
{Chevron}
</button>
<div className="nav-item next">
<a href="">
<span>{nextText}</span>
{Chevron}
</a>
</div>
{current && <div className="current bottom">{current}</div>}
</div>
);
Expand Down
26 changes: 17 additions & 9 deletions src/styles/components/content-nav.css
Original file line number Diff line number Diff line change
@@ -1,17 +1,25 @@
.content-nav {
@apply flex gap-y-2 justify-between border-b border-b-gray-200 pb-4 flex-wrap mt-5 sm:flex-nowrap dark:border-b-gray-700;
button {
@apply flex items-center gap-2 text-gray-500 hover:underline focus-visible:underline px-0 w-2/4 sm:w-auto dark:text-gray-300;
&:first-of-type img {
@apply rotate-90;
@apply flex gap-y-2 justify-between border-b border-b-gray-200 pb-4 flex-wrap mt-5 sm:flex-nowrap dark:border-b-gray-700 sm:grid sm:grid-cols-3;

.nav-item {
a {
@apply flex items-center gap-2 text-gray-500 hover:underline focus-visible:underline px-0 sm:w-auto dark:text-gray-300 w-full;
}
&:last-of-type {
@apply justify-end;
img {
@apply -rotate-90;
&.prev {
a img {
@apply rotate-90;
}
}
&.next {
a {
@apply justify-end;
img {
@apply -rotate-90;
}
}
}
}

.current {
@apply text-2xs text-center sm:text-xs;
&.middle {
Expand Down
9 changes: 9 additions & 0 deletions src/styles/components/not-found.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.not-found {
@apply pt-6 flex-grow justify-center;
.heading {
@apply text-lg min-[420px]:text-xl transition-font-size xs:text-2xl;
}
.button {
@apply mr-auto;
}
}
1 change: 1 addition & 0 deletions src/styles/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
@import "./components/content-nav.css";
@import "./components/card-grid.css";
@import "./components/switchback.css";
@import "./components/not-found.css";