Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Jump to specific step with an external link/button #171

Closed
acelsosoares opened this issue Nov 17, 2018 · 4 comments
Closed

Jump to specific step with an external link/button #171

acelsosoares opened this issue Nov 17, 2018 · 4 comments
Labels

Comments

@acelsosoares
Copy link

acelsosoares commented Nov 17, 2018

is there any way to jump to a specific step with a link that is outside of <aw-wizard> element?
I want to build my own navigation menu, and put it in a section located far away from the wizard.

We have this property to do it [awGoToStep]="{stepIndex: 1}". But it only works inside of <aw-wizard> element.

@madoar
Copy link
Owner

madoar commented Nov 18, 2018

You can let the wizard jump to a different step by using the internal API of the wizard.
For this you need to inject the wizard in your code via:

@ViewChild('wizard')
public wizard: WizardComponent;

Afterwards you can navigate the wizard to another step by calling:

wizard.navigation.goToStep(destinationStepIndex);

Please be aware, that this is an internal API call, which may be subject of change in the future.

@unsafecode
Copy link

@madoar Fine, but we definitely need public APIs to handle this, especially when dealing with dynamically created steps.

@madoar
Copy link
Owner

madoar commented Dec 14, 2018

I agree, a public API becomes a requirement when working with dynamically created steps.
The API should become more stable with #166

@madoar
Copy link
Owner

madoar commented Aug 11, 2019

angular-archwizard version 5.0.0 has just been released. It contains #166 with a more stable API to navigate the wizard programmatically. Feel free to give it a try!

If there are any questions or problems feel free to open a new issue!

@madoar madoar closed this as completed Aug 11, 2019
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants