Skip to content

Commit b37f0e8

Browse files
author
AZhurav1ev
committed
Added possibility to hide Previous button
1 parent 6abcf22 commit b37f0e8

File tree

4 files changed

+11
-4
lines changed

4 files changed

+11
-4
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ var enjoyhint_script_steps = [
8484

8585
#### Properties of the step configuration
8686
* `"event selector" : "description"` - to describe a step you should set an event type, selecte element and add description for this element (hint)
87-
* `markerColor` - the color of a marker that accepts all CSS colors.
87+
* `arrowColor` - the color of a marker that accepts all CSS colors.
8888
* `keyCode` - the code of a button, which triggers the next EnjoyHint step upon a click. Defined by the “key” event. (“key #block” : “hello”).
8989
* `event_selector` - if you need to attach an event (that was set in "event" property) to other selector, you can use this one
9090
* `timeout` - delay before the moment, when an element is highlighted
@@ -108,6 +108,7 @@ var enjoyhint_script_steps = [
108108
```
109109
* `showSkip` - shows or hides the Skip button (true|false)
110110
* `showNext` - shows or hides the Next button (true|false)
111+
* `showPrev` - shows or hides the Previous button (true|false)
111112

112113

113114

enjoyhint.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,10 @@
190190
if(current_step !== 0) {
191191
$body.enjoyhint("show_prev");
192192
}
193-
193+
194+
if (step_data.showPrev == false) {
195+
$body.enjoyhint("hide_prev");
196+
}
194197

195198
if (step_data.showSkip == false) {
196199
$body.enjoyhint("hide_skip");

0 commit comments

Comments
 (0)