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

When an incorrect URL is typed into the Plate.js floating link toolbar, it triggers form submission if Plate is nested within a form. #3082

Open
fufuShih opened this issue Mar 28, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@fufuShih
Copy link

fufuShih commented Mar 28, 2024

Description

When form is the parent component of Plate.js, entering an incorrect URL in the floating link toolbar is expected to maintain focus on the input field. However, it instead triggers the form submission.

Steps to Reproduce

  1. Click Link and goto floating link toolbar
    image

  2. Type wrong url and click "Enter"
    image

  3. It will trigger the form
    image

Sandbox

Code sandbox

Expected Behavior

The expected behavior is that entering a URL into the floating link feature of the Plate.js editor does not trigger form submission. And focus on the input

Environment

  • slate:
  • slate-react:
  • browser: chrome

Bounty

Click here to add a bounty via Algora.

Funding

  • You can sponsor this specific effort via a Polar.sh pledge below
  • We receive the pledge once the issue is completed & verified
Fund with Polar
@fufuShih fufuShih added the bug Something isn't working label Mar 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant