Skip to content

Refresh method doesn't do as advertised #53

@jayden2

Description

@jayden2

Docs state:

refresh()
# Returns a promise
Refresh all properties and elements of the tour. This includes re-computing tour steps.

However if I init a tour, go through the tour step(s).
Then remove some of the elements and create new ones. Say I remove table rows, then added the table rows again.
Re-opening the tour and using refresh() (also tried refreshDialog() and updatePositions()) Does not recompute a new element and the tour selector goes to the top left of the page.

This is using js to select, instead of html properties

{
        title: 'title',
        content: 'text​​',
        target: '#table-1 td',
        group: 'guide_1',
        fixed: false,
}

This happens because the target is replaced on init with a selected element, it would be useful to have another function to maybe reselect elements or include that in refresh.
To me it is also strange that the config's target (value) is replaced with the selected element.


It would also be really useful to be able to destroy the tour instance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions