File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -37,14 +37,14 @@ export default async function Page({ params }: Props) {
37
37
38
38
return (
39
39
< >
40
- < div className = { cn ( 'mb-6 mt-8 border-b' , 'border-outline-variant/50' ) } >
40
+ < header className = { cn ( 'mb-6 mt-8 border-b' , 'border-outline-variant/50' ) } >
41
41
< h1 className = "mb-2 text-5xl font-bold tracking-tighter" > { doc . title } </ h1 >
42
42
{ ! ! doc ?. description ?. length && (
43
43
< p className = { cn ( 'my-2 text-base leading-5' , 'text-on-surface-variant/50' ) } >
44
44
{ doc . description }
45
45
</ p >
46
46
) }
47
- </ div >
47
+ </ header >
48
48
{ doc ? < > { doc . content } </ > : 'empty doc' }
49
49
</ >
50
50
)
Original file line number Diff line number Diff line change 1
1
import cn from '@/lib/cn'
2
+ import { VisuallyHidden } from '@radix-ui/react-visually-hidden'
2
3
import { ComponentProps } from 'react'
3
4
4
- export function Intro ( { className, ...props } : ComponentProps < 'div' > ) {
5
- return < div { ...props } className = { cn ( className , 'my-6 text-xl leading-relaxed' ) } />
5
+ export function Intro ( { children, className, ...props } : ComponentProps < 'div' > ) {
6
+ return (
7
+ < section { ...props } className = { cn ( className , 'my-6 text-xl leading-relaxed' ) } >
8
+ < VisuallyHidden >
9
+ < h2 > Summary</ h2 >
10
+ </ VisuallyHidden >
11
+ { children }
12
+ </ section >
13
+ )
6
14
}
You can’t perform that action at this time.
0 commit comments