File tree Expand file tree Collapse file tree 2 files changed +12
-3
lines changed Expand file tree Collapse file tree 2 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 1
1
import { useState } from 'react' ;
2
+
3
+ import Section from './Section' ;
2
4
import TabButton from './TabButton' ;
3
5
4
6
import { EXAMPLES } from '../data/examples' ;
@@ -25,8 +27,7 @@ export default function Examples() {
25
27
}
26
28
27
29
return (
28
- < section id = "examples" >
29
- < h2 > Examples</ h2 >
30
+ < Section id = "examples" title = "Examples" >
30
31
< menu >
31
32
< TabButton
32
33
isSelected = { selectedTopic === 'components' }
@@ -54,6 +55,6 @@ export default function Examples() {
54
55
</ TabButton >
55
56
</ menu >
56
57
{ tabContent }
57
- </ section >
58
+ </ Section >
58
59
) ;
59
60
}
Original file line number Diff line number Diff line change
1
+ export default function Section ( { children, title } ) {
2
+ return (
3
+ < section >
4
+ < h2 > { title } </ h2 >
5
+ { children }
6
+ </ section >
7
+ ) ;
8
+ }
You can’t perform that action at this time.
0 commit comments