-
Notifications
You must be signed in to change notification settings - Fork 219
Fix address block invalidations in the editor and address card display in Firefox #11714
Conversation
The release ZIP for this PR is accessible via:
Script Dependencies ReportThere is no changed script dependency between this branch and trunk. This comment was automatically generated by the TypeScript Errors Report
packages/checkout/components/text-input/test/validated-text-input.tsx
|
Size Change: +338 B (0%) Total Size: 1.54 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this, @mikejolley. Both, the test cases you mentioned as well as edge cases I executed, worked as expected. Code-wise I could not spot anything strange. Nice work. 👏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
working well, thanks Mike
Great work on debuggin this and fixing it on such a short time. @mikejolley I recommend creating a separate ticket with some tests for this case and working on it next, to make sure we are safe from having a regression happening again. |
…y in Firefox (#11714) * Add checks to see if getCartData finished before rendering address * Prevent block error due to excessive updates of customValidation * Do not condense address in admin and handle phone field * Add missing showPhoneField for billing --------- Co-authored-by: Thomas Roberts <[email protected]>
Hey @mikejolley , Curious if this is going to fix the issue I am having. On the checkout page, I use autofill for everything (email, address, and CC). IF i auto populate email address, it clear the CC fields. If I auto populate the CC fields, it clears the email address field. |
Credit card fields? I don't think thats related to this fix. Perhaps the autocomplete entry in your browser for CC details lacks the name/email/address? If you have steps to reproduce this you could create a new ticket. I've not seen it reported anywhere else. |
* Empty commit for release pull request * Empty commit for release pull request * Empty commit for release pull request * Empty commit for release pull request * Update Jetpack WooCommerce Analytics module integration to check for changed template names (#11707) * Bump versions to 11.4.6 * Add testing notes * Update testing zip * Skip template related E2E tests (#11700) * Empty commit for release pull request * Fix address block invalidations in the editor and address card display in Firefox (#11714) * Add checks to see if getCartData finished before rendering address * Prevent block error due to excessive updates of customValidation * Do not condense address in admin and handle phone field * Add missing showPhoneField for billing --------- Co-authored-by: Thomas Roberts <[email protected]> * Add changelog in "readme.txt" * Run change version npm script * Add testing notes * Empty commit for release pull request * Add changelog in "readme.txt" * Add version numbers * Ensure that incompatible notices are displayed in Safari. (#11736) * Add the testing docs * Update testing notes title of 11.4.8 --------- Co-authored-by: github-actions <[email protected]> Co-authored-by: Thomas Roberts <[email protected]> Co-authored-by: Thomas Roberts <[email protected]> Co-authored-by: Saad Tarhi <[email protected]> Co-authored-by: Mike Jolley <[email protected]> Co-authored-by: Niels Lange <[email protected]>
What
This PR fixes some issues with the address card and address form components.
The first issue caused block invalidation due to the custom validation function changing on every render. I fixed this by implementing a ref.
Fixes #11583
The second issue only affected firefox and would cause the collapsed address component to never render. This was fixed by waiting for cart data to load before mounting.
Fixes #11650
This change also negated the need for #11062 so we should test for regressions.
The final change was to ensure the address is never collapsed in admin so form changes are visible, and to correctly hide the phone value on the frontend if that field is toggled off.
Testing Instructions
Please consider any edge cases this change may have, and also other areas of the product this may impact.
Firefox testing
WooCommerce Visibility
Required:
Checklist
Required:
[type]
label or a[skip-changelog]
label.Conditional:
[skip-changelog]
label is not present).Changelog