Skip to content

Commit 1279191

Browse files
committed
add direction to onStepProgress callback
1 parent d21baf2 commit 1279191

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ The `onStepProgress` callback receives one argument, an object, with the followi
134134
element, // The DOM node of the step that was triggered
135135
data, // The data supplied to the step
136136
progress, // The percent of completion of the step (0 to 1)
137+
direction, // 'up' or 'down'
137138
}
138139
```
139140

src/Step.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ const Step = props => {
7171
data,
7272
element: scrollProgressEntry.target,
7373
entry: scrollProgressEntry,
74+
direction,
7475
});
7576
}
7677
}, [scrollProgressEntry]);

0 commit comments

Comments
 (0)