File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -33,11 +33,11 @@ class apiPage extends React.Component {
33
33
window . addEventListener ( "scroll" , ( ) => {
34
34
const top = window . scrollY ;
35
35
const scrollButton = document . getElementById ( "back-to-top" ) ;
36
- if ( top >= 50 ) {
36
+ if ( scrollButton && top >= 50 ) {
37
37
scrollButton . classList . add ( "is-visible" ) ;
38
- } else {
38
+ } else if ( scrollButton ) {
39
39
scrollButton . classList . remove ( "is-visible" ) ;
40
- }
40
+ } else ;
41
41
} ) ;
42
42
}
43
43
Original file line number Diff line number Diff line change 73
73
74
74
.api-link {
75
75
position : relative;
76
- line-height : 1.4 ;
76
+ line-height : 1.1 ;
77
77
}
78
78
79
79
.top-menu-anchor {
269
269
}
270
270
271
271
.active-group .list-group li {
272
- @apply py-2 ;
272
+ padding : 5 px 0 ;
273
273
}
274
274
}
275
275
Original file line number Diff line number Diff line change @@ -32,11 +32,11 @@ class APIDocs extends React.Component {
32
32
window . addEventListener ( "scroll" , ( ) => {
33
33
const top = window . scrollY ;
34
34
const scrollButton = document . getElementById ( "back-to-top" ) ;
35
- if ( top >= 50 ) {
35
+ if ( scrollButton && top >= 50 ) {
36
36
scrollButton . classList . add ( "is-visible" ) ;
37
- } else {
37
+ } else if ( scrollButton ) {
38
38
scrollButton . classList . remove ( "is-visible" ) ;
39
- }
39
+ } else ;
40
40
} ) ;
41
41
}
42
42
You can’t perform that action at this time.
0 commit comments