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: Tool Auth Form Button to Prevent Form Bubbling #4666

Merged
merged 1 commit into from
Nov 7, 2024

Conversation

danny-avila
Copy link
Owner

Summary

I modified the PluginAuthForm component to prevent form submission from bubbling up to the parent form by changing the submit button type and implementing manual submission handling.

  • Changed submit button type from "submit" to "button" to prevent automatic form submission
  • Added onClick handler to manually trigger form submission
  • Implemented direct form submission using handleSubmit with auth parameters
  • Maintained existing validation checks (isDirty, isValid, isSubmitting)
  • Preserved plugin installation parameters including pluginKey, action, and isEntityTool flags

Change Type

  • Bug fix (non-breaking change which fixes an issue)

Testing

I tested the changes by:

  1. Verifying the form submission works correctly with the new button type
  2. Ensuring validation states are properly maintained
  3. Confirming the form data is correctly passed to the parent component
  4. Testing that no unwanted form submissions occur

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • My changes do not introduce new warnings
  • I have tested the functionality thoroughly

…ally in PluginAuthForm, to prevent submission from bubbling up to parent form
@danny-avila danny-avila changed the title 🫧 fix: Change Plugin Auth Form Button Type to Prevent Form Bubbling 🫧 fix: Tool Auth Form Button to Prevent Form Bubbling Nov 7, 2024
@danny-avila danny-avila merged commit 81f2936 into main Nov 7, 2024
2 checks passed
@danny-avila danny-avila deleted the fix/tool-auth-submit branch November 7, 2024 16:26
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.

1 participant