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 CSS class for a product's disabled button #681

Merged
merged 1 commit into from
Jul 7, 2020

Conversation

gabrielmaldi
Copy link
Contributor

Currently, when a product's button is disabled (e.g. no stock), it's rendered with undefined as class:

<button disabled="" class="shopify-buy__btn undefined " data-element="product.button"></button>

This patch fixes this by using the intended default class shopify-buy__btn-disabled:

<button disabled="" class="shopify-buy__btn shopify-buy__btn-disabled " data-element="product.button"></button>

@ghost ghost added the cla-needed label Apr 18, 2020
@gabrielmaldi gabrielmaldi force-pushed the fix-disabled-button-class branch from 025911b to 399594c Compare April 18, 2020 20:27
@ghost ghost removed the cla-needed label Apr 18, 2020
@gabrielmaldi gabrielmaldi force-pushed the fix-disabled-button-class branch from 399594c to 8b0eb79 Compare May 12, 2020 19:08
Copy link
Contributor

@melissaluu melissaluu left a comment

Choose a reason for hiding this comment

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

👋 Hi @gabrielmaldi - thanks so much for fixing this and contributing to the library! This looks great 🎉
I'll merge it into master and it will be part of the next release 😄

@melissaluu melissaluu merged commit 733f080 into Shopify:master Jul 7, 2020
@gabrielmaldi
Copy link
Contributor Author

My pleasure, @melissaluu 😊

@melissaluu melissaluu temporarily deployed to production July 8, 2020 17:13 Inactive
@gabrielmaldi gabrielmaldi deleted the fix-disabled-button-class branch July 8, 2020 22:29
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.

2 participants