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

fix(extension-link): fixes link going to wrong url #4078

Merged
merged 1 commit into from
Jul 7, 2023

Conversation

joenarus
Copy link
Contributor

@joenarus joenarus commented May 25, 2023

Please describe your changes

Fixes links using incorrect url onClick.

How did you accomplish your changes

Casting the type of the target to HTMLLinkElement and removing .closest('a')

How have you tested your changes

Built the package and imported it to our repo. Worked like a charm.

How can we verify your changes

Test on the localhost editor app.

Remarks

This fix is necessary because right now have two links in the same editor results in the second link going to the first link.

closest('a') was returning the wrong href.

Checklist

  • The changes are not breaking the editor
  • Added tests where possible
  • Followed the guidelines
  • Fixed linting issues

Related issues

#4056

@netlify
Copy link

netlify bot commented May 25, 2023

Deploy Preview for tiptap-embed ready!

Name Link
🔨 Latest commit a8bcaa2
🔍 Latest deploy log https://app.netlify.com/sites/tiptap-embed/deploys/646fcf9d971734000795575d
😎 Deploy Preview https://deploy-preview-4078--tiptap-embed.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants