Skip to content

Commit bf7d313

Browse files
authored
Fix some styles (#18)
2 parents f694d91 + ef95abb commit bf7d313

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

next/src/components/Footer.jsx

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import { Button } from '@/components/Button'
22
import { navigation } from '@/components/Navigation/config'
33
import { lora } from '@/lib/fonts'
4+
import clsx from 'clsx/lite'
45
import Link from 'next/link'
56
import { useRouter } from 'next/router'
67

7-
function PageLink({ label, page, previous = false }) {
8+
function PageLink({ label, page, previous = false, isRight = false }) {
89
return (
910
<>
1011
<Button
@@ -19,7 +20,17 @@ function PageLink({ label, page, previous = false }) {
1920
href={page.href}
2021
tabIndex={-1}
2122
aria-hidden="true"
22-
className={`text-base font-semibold text-zinc-900 transition hover:text-zinc-600 dark:text-white dark:hover:text-zinc-300 ${lora.className}`}
23+
className={clsx(
24+
'text-base',
25+
'font-semibold',
26+
'text-zinc-900',
27+
'transition',
28+
'hover:text-zinc-600',
29+
'dark:text-white',
30+
'dark:hover:text-zinc-300',
31+
lora.className,
32+
isRight && 'text-right',
33+
)}
2334
>
2435
{page.title}
2536
</Link>
@@ -56,7 +67,7 @@ function PageNavigation() {
5667
)}
5768
{nextPage && (
5869
<div className="ml-auto flex flex-col items-end gap-3">
59-
<PageLink label="Next" page={nextPage} />
70+
<PageLink label="Next" page={nextPage} isRight />
6071
</div>
6172
)}
6273
</div>

next/typography.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,9 @@ module.exports = ({ theme }) => ({
277277
},
278278

279279
// Inline elements
280+
img: {
281+
maxWidth: '100%',
282+
},
280283
a: {
281284
color: 'var(--tw-prose-links)',
282285
textDecoration: 'underline',
@@ -305,6 +308,7 @@ module.exports = ({ theme }) => ({
305308
boxShadow: 'inset 0 0 0 1px var(--tw-prose-code-ring)',
306309
backgroundColor: 'var(--tw-prose-code-bg)',
307310
fontSize: theme('fontSize.2xs'),
311+
overflowWrap: 'break-word',
308312
},
309313
':is(a, h1, h2, h3, blockquote, thead th) code': {
310314
color: 'inherit',

0 commit comments

Comments
 (0)