givewp icon indicating copy to clipboard operation
givewp copied to clipboard

Fix: prevent Stripe Payment Element from rendering when amount is zero

Open jonwaldstein opened this issue 1 year ago • 0 comments

Resolves GIVE-509

Description

This prevents the Stripe Payment Element from rendering when the donation amount is zero by adding a conditional before loading the fields.

Affects

Stripe payment element gateways

Visuals

Before:

Screenshot 2024-08-23 at 9 29 07 AM

After

Screenshot 2024-08-23 at 10 10 35 AM

Testing Instructions

  • create a v3 form
  • specify 0 for the amount
  • click on stripe payment element

Pre-review Checklist

  • [ ] Acceptance criteria satisfied and marked in related issue
  • [ ] Relevant @unreleased tags included in DocBlocks
  • [ ] Includes unit tests
  • [ ] Reviewed by the designer (if follows a design)
  • [ ] Self Review of code and UX completed

jonwaldstein avatar Aug 23 '24 14:08 jonwaldstein