File tree Expand file tree Collapse file tree 4 files changed +16
-8
lines changed Expand file tree Collapse file tree 4 files changed +16
-8
lines changed Original file line number Diff line number Diff line change @@ -110,11 +110,11 @@ import ScrollSpy from "react-ui-scrollspy";
110
110
111
111
### 🔧 Customize Attributes
112
112
113
- | Attributes | Type | Description | Default | Required |
114
- | :----------------- | :-------- | :------------------------------------------------------------------------------- | :-------------------- | :------- |
115
- | ` useDataAttribute ` | ` string ` | To customize the string after ` data- ` | ` "to-scrollspy-id" ` | no |
116
- | ` activeClass ` | ` string ` | To customize the ` class ` added when the ` Element ` in view | ` "active-scroll-spy" ` | no |
117
- | ` useBoxMethod ` | ` boolean ` | Set to ` false ` if you want your spy to be active if 50% of that ` div ` is in view | ` true ` | no |
113
+ | Attributes | Type | Description | Default | Required |
114
+ | :----------------- | :-------- | :------------------------------------------------------------------------------------------------------- | :-------------------- | :------- |
115
+ | ` useDataAttribute ` | ` string ` | To customize the string after ` data- ` | ` "to-scrollspy-id" ` | no |
116
+ | ` activeClass ` | ` string ` | To customize the ` class ` added when the ` Element ` in view | ` "active-scroll-spy" ` | no |
117
+ | ` useBoxMethod ` | ` boolean ` | Set to ` false ` if you want your spy to be active only if more than ` 50% ` of that ` div ` is in the viewport | ` true ` | no |
118
118
119
119
## 📝 Authors
120
120
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ const Buttons = (props: Props) => {
9
9
href = "https://github.com/pettiboy/react-ui-scrollspy/"
10
10
target = "_blank"
11
11
>
12
- < div className = { "button button-size" } >
12
+ < div className = { "button button-size text-dark " } >
13
13
< div style = { { marginRight : 10 , marginTop : 5 } } >
14
14
< img
15
15
src = { `${ process . env . PUBLIC_URL } /assets/gh-logo.png` }
Original file line number Diff line number Diff line change 67
67
.ss-active-demo-2 {
68
68
border-radius : 10px ;
69
69
transition : all 0.5s ;
70
- background : blue ;
70
+ background : brown ;
71
71
}
Original file line number Diff line number Diff line change @@ -68,9 +68,17 @@ const Demo2 = (props: Props) => {
68
68
</ div >
69
69
70
70
< div className = "col-md-8 col-sm-8 col-lg-8 flex-column d-flex justify-content-center p-0" >
71
- < div ref = { parentScrollContainerRef } >
71
+ < div
72
+ ref = { parentScrollContainerRef }
73
+ // style={{
74
+ // position: "relative",
75
+ // overflowY: "scroll",
76
+ // height: "50vh",
77
+ // }}
78
+ >
72
79
< ScrollSpy
73
80
useBoxMethod
81
+ // parentScrollContainerRef={parentScrollContainerRef}
74
82
activeClass = "ss-active-demo-2"
75
83
scrollThrottle = { 100 }
76
84
>
You can’t perform that action at this time.
0 commit comments