Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Guided Tours: Unsafe usage of onTargetDisappear #26706

Closed
sirreal opened this issue Aug 15, 2018 · 0 comments
Closed

Guided Tours: Unsafe usage of onTargetDisappear #26706

sirreal opened this issue Aug 15, 2018 · 0 comments
Assignees
Labels
Guided Tours [Type] Bug When a feature is broken and / or not performing as intended

Comments

@sirreal
Copy link
Member

sirreal commented Aug 15, 2018

This error is sometimes triggered by guided tours:

Uncaught TypeError: e.props.onTargetDisappear is not a function

From #26468 (review)

Observed while testing the mentioned PR, but I had observed this behavior before while implementing #25474

The case mentioned was observed while following the steps of the site icon tour, available at https://wordpress.com/checklist/SIMPLE_SITE_SLUG

The offending call appears to be here:

this.props.onTargetDisappear( {
quit: () => this.context.quit( this.context ),
next: () => this.skipToNext( this.props, this.context ),
} );

And the offending tour Step is likely here or nearby:

<Step
name="click-done"
target="image-editor-button-done"
arrow="bottom-center"
placement="above"
style={ { marginTop: '30px', marginLeft: '90px' } }
>
{ ( { translate } ) => (
<Fragment>
<Continue target="image-editor-button-done" step="finish" click>
{ translate(
'Let’s make sure it looks right before you press {{doneButton/}} to save your changes.',
{ components: { doneButton: <DoneButton /> } }
) }
</Continue>
</Fragment>
) }
</Step>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Guided Tours [Type] Bug When a feature is broken and / or not performing as intended
Projects
None yet
Development

No branches or pull requests

3 participants