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(storefront): STRF-8599 Drop Jquery: Replaced event's current target to the element passed from utils(on hook) #1821

Merged
merged 1 commit into from
Oct 9, 2020

Conversation

jairo-bc
Copy link
Contributor

@jairo-bc jairo-bc commented Sep 4, 2020

What?

Changed the behaviour of the stencil utils event handlers. Target element is now taken not from event.currentTarget, but passed from the stencil-utils eventemitter.

Tickets / Documentation

https://jira.bigcommerce.com/browse/STRF-8599

Screenshots (if appropriate)

Attach images or add image links here.

Example Image

@bigbot
Copy link

bigbot commented Sep 4, 2020

Autotagging @bigcommerce/storefront-team @davidchin

…et to the element passed from utils(on hook)
@@ -139,8 +139,8 @@ export default class Cart extends PageManager {
this.bindGiftWrappingForm();
});

utils.hooks.on('product-option-change', (event, option) => {
const $changedOption = $(option);
utils.hooks.on('product-option-change', (event, currentTarget) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we need to change places where we do the bind to pass currentTarget for all of them ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@junedkazi junedkazi merged commit e886965 into bigcommerce:master Oct 9, 2020
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.

None yet

3 participants