Skip to content

Commit

Permalink
PAYMENTS-4520 Fix incorrect DOM selectors causing the payment method …
Browse files Browse the repository at this point in the history
…form on the account page from working properly in Safari
  • Loading branch information
davidchin committed Jul 19, 2019
1 parent 0a4f58b commit 50e0013
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
- Fix broken conditional statement in share.html [#1533](https://github.com/bigcommerce/cornerstone/pull/1533)
- Enable Facebook like button to be displayed on product page if enabled [#1530](https://github.com/bigcommerce/cornerstone/pull/1530)
- Remove nanobar (loading bar) [#1537](https://github.com/bigcommerce/cornerstone/pull/1537)
- Fix incorrect DOM selectors causing the payment method form on the account page from working properly in Safari [#1540](https://github.com/bigcommerce/cornerstone/pull/1540)

## 3.5.1 (2019-06-24)
- Fix conditional logic in share.html [#1522](https://github.com/bigcommerce/cornerstone/pull/1522)
Expand Down
4 changes: 2 additions & 2 deletions assets/js/theme/account.js
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ export default class Account extends PageManager {
$(`${paymentMethodSelector} input[name="credit_card_number"]`).on('keyup', ({ target }) => {
cardType = creditCardType(target.value);
if (cardType) {
$(`${paymentMethodSelector} img[alt="${cardType}"`).siblings().css('opacity', '.2');
$(`${paymentMethodSelector} img[alt="${cardType}"]`).siblings().css('opacity', '.2');
} else {
$(`${paymentMethodSelector} img`).css('opacity', '1');
}
Expand All @@ -269,7 +269,7 @@ export default class Account extends PageManager {

// Set of credit card format
CCFormatters.setCreditCardNumberFormat(`${paymentMethodSelector} input[name="credit_card_number"]`);
CCFormatters.setExpirationFormat(`${paymentMethodSelector} input[name="expiration"`);
CCFormatters.setExpirationFormat(`${paymentMethodSelector} input[name="expiration"]`);

// Billing address validation
paymentMethodValidator.add(validationModel);
Expand Down

0 comments on commit 50e0013

Please sign in to comment.