File tree 1 file changed +4
-5
lines changed
1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 1
1
import React , { useCallback , useEffect } from "react" ;
2
2
import classNames from "classnames" ;
3
3
import { siteSpecific } from "../../services" ;
4
- import { Button } from "reactstrap " ;
4
+ import { IconButton } from "../elements/AffixButton " ;
5
5
6
6
export const ScrollToTop = ( { mainContent} : { mainContent : React . MutableRefObject < HTMLElement | null > } ) => {
7
7
const [ sticky , setSticky ] = React . useState ( false ) ;
@@ -18,16 +18,15 @@ export const ScrollToTop = ({mainContent}: {mainContent: React.MutableRefObject<
18
18
} , [ isSticky ] ) ;
19
19
20
20
return siteSpecific (
21
- < Button
21
+ < IconButton
22
22
color = "keyline"
23
+ icon = "icon-chevron-up"
23
24
className = { classNames ( "scroll-btn d-print-none p-2" , { "is-sticky" : sticky } ) }
24
25
onClick = { ( ) => mainContent . current ?. scrollIntoView ( { behavior : 'smooth' } ) }
25
26
tabIndex = { sticky ? 0 : - 1 }
26
27
aria-label = "Scroll to top of page"
27
28
data-bs-theme = "neutral"
28
- >
29
- < i className = "icon icon-chevron-up" />
30
- </ Button > ,
29
+ /> ,
31
30
32
31
< button
33
32
onClick = { ( ) => mainContent . current ?. scrollIntoView ( { behavior : 'smooth' } ) }
You can’t perform that action at this time.
0 commit comments