1
1
import * as React from 'react' ;
2
2
import * as Space from 'react-spaces' ;
3
- import { Anchor , Button , Icon } from 'antd' ;
3
+ import { Button , Icon , Menu } from 'antd' ;
4
4
import 'antd/dist/antd.css' ;
5
5
import { GettingStarted } from './GettingStarted' ;
6
6
import { Types } from './Types' ;
@@ -12,6 +12,7 @@ import { Stacked } from './Stacked';
12
12
import { SizingInfo } from './SizingInfo' ;
13
13
import { VersionHistory } from './VersionHistory' ;
14
14
import { Intro } from './Intro' ;
15
+ import { Try } from './Try' ;
15
16
16
17
export const Docs = ( ) => {
17
18
return (
@@ -22,42 +23,46 @@ export const Docs = () => {
22
23
</ Space . CenteredVertically >
23
24
</ Space . Top >
24
25
< Space . Fill className = "all-content" >
25
- < Space . Left className = "sidebar" scrollable = { true } size = { 250 } style = { { padding : 30 , borderRight : '2px solid #ddd' } } >
26
+ < Space . Left className = "sidebar" scrollable = { true } size = { 250 } style = { { paddingTop : 15 , borderRight : '2px solid #ddd' } } >
26
27
27
- < h3 className = "sidebar-header" > GitHub</ h3 >
28
- < div style = { { marginBottom : 15 } } >
29
- < Button type = "primary" onClick = { ( ) => window . location . href = 'https://github.com/aeagle/react-spaces' } > < Icon type = "github" /> View on GitHub</ Button >
30
- </ div >
31
-
32
- < h3 className = "sidebar-header" > NPM < img style = { { position : 'relative' , top : - 2 } } alt = "NPM version" src = "https://img.shields.io/npm/v/react-spaces.svg" /> </ h3 >
28
+ < Menu >
29
+ < Menu . Item > < a href = "#getting-started" > Getting started</ a > </ Menu . Item >
30
+ < Menu . Item > < a href = "#types" > Types</ a > </ Menu . Item >
31
+ < Menu . Item > < a href = "#non-resizable" > Anchored</ a > </ Menu . Item >
32
+ < Menu . Item > < a href = "#resizable" > Resizable</ a > </ Menu . Item >
33
+ < Menu . Item > < a href = "#nested" > Nested</ a > </ Menu . Item >
34
+ < Menu . Item > < a href = "#scrollable" > Scrollable</ a > </ Menu . Item >
35
+ < Menu . Item > < a href = "#stacked" > Stacked</ a > </ Menu . Item >
36
+ < Menu . Item > < a href = "#sizeinfo" > Sizing information</ a > </ Menu . Item >
37
+ < Menu . Item > < a href = "#try" > Try</ a > </ Menu . Item >
38
+ < Menu . Item > < a href = "#changes" > Version history</ a > </ Menu . Item >
39
+ </ Menu >
33
40
34
- < Anchor offsetTop = { 30 } >
35
- < Anchor . Link href = "#getting-started" title = "Getting started" />
36
- < Anchor . Link href = "#types" title = "Types" />
37
- < Anchor . Link href = "#non-resizable" title = "Anchored" />
38
- < Anchor . Link href = "#resizable" title = "Resizable" />
39
- < Anchor . Link href = "#nested" title = "Nested" />
40
- < Anchor . Link href = "#scrollable" title = "Scrollable" />
41
- < Anchor . Link href = "#stacked" title = "Stacked" />
42
- < Anchor . Link href = "#sizeinfo" title = "Sizing information" />
43
- < Anchor . Link href = "#changes" title = "Version history" />
44
- </ Anchor >
41
+ < div style = { { padding : 15 } } >
42
+ < h3 className = "sidebar-header" > GitHub</ h3 >
43
+ < div style = { { marginBottom : 15 } } >
44
+ < Button type = "primary" onClick = { ( ) => window . location . href = 'https://github.com/aeagle/react-spaces' } > < Icon type = "github" /> View on GitHub</ Button >
45
+ </ div >
45
46
46
- < h2 className = "sidebar-header" > < a style = { { color : 'black' , fontSize : 24 } } href = "https://twitter.com/allaneagle" > @allaneagle</ a > </ h2 >
47
+ < h3 className = "sidebar-header" > NPM < img style = { { position : 'relative' , top : - 2 } } alt = "NPM version" src = "https://img.shields.io/npm/v/react-spaces.svg" /> </ h3 >
48
+
49
+ < h2 className = "sidebar-header" > < a style = { { color : 'black' , fontSize : 18 } } href = "https://twitter.com/allaneagle" > @allaneagle</ a > </ h2 >
50
+ </ div >
47
51
48
52
</ Space . Left >
49
53
< Space . Fill className = "main" scrollable = { true } style = { { padding : 30 , paddingTop : 0 } } >
50
54
51
- < Intro />
52
- < GettingStarted />
53
- < Types />
54
- < Anchored />
55
- < Resizable />
56
- < Nested />
57
- < Scrollable />
58
- < Stacked />
59
- < SizingInfo />
60
- < VersionHistory />
55
+ < Intro />
56
+ < GettingStarted />
57
+ < Types />
58
+ < Anchored />
59
+ < Resizable />
60
+ < Nested />
61
+ < Scrollable />
62
+ < Stacked />
63
+ < SizingInfo />
64
+ < Try />
65
+ < VersionHistory />
61
66
62
67
</ Space . Fill >
63
68
0 commit comments