tnicola/ngx-joyride

Feature: add support for an optional observable as a step property to be called prior to showing the step

mwamufiya opened this issue · 1 comments

Feature
There is a need in the project I'm working for the side bar on the home page to be included in the onboarding for the user.
however, this sidebar is by default collapsed. and only when the user clicks on the 'hamburger' icon does the side bar expand to show the menu items.

Currently there is no way to configure the step in joyride to 'pause' the joy ride in-between steps so that I can programmatically open the side bar, then resume the step sequence

Feature Details:

  • add an optional property in the step definition that accept an observable.
  • i.e. dependency (or some better name)
  • in the JoyrideStepService service, if an observable has been defined, THEN
  • this observable should first be called
  • upon completion of this observable, the step should then proceed to try and show the step

this would provide a 'hook' in between steps for applications to add custom logic without complicating the internals of joyride.

since the observable might change the scroll and position of the next step, it should likely be initiated prior to initviewPortPosition

Any updates?