Skip to content

Commit

Permalink
Remove button variant class when no variant set (#3372)
Browse files Browse the repository at this point in the history
  • Loading branch information
rmccar authored Sep 27, 2024
1 parent 759272a commit 0b669c7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/button/_macro.njk
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
{% else %}
type="{{ buttonType }}"
{% endif %}
class="ons-btn{{ ' ' + params.classes if params.classes else '' }}{% if params.variants and params.variants is not string %}{% for variant in params.variants %}{{ ' ' }}ons-btn--{{ variant }}{% endfor %}{% else %}{{ ' ' }}ons-btn--{{ params.variants }}{% endif %}{{ ' ons-btn--link ons-js-submit-btn' if params.url }}{{ variantClasses }}"
class="ons-btn{{ ' ' + params.classes if params.classes else '' }}{% if params.variants and params.variants is not string %}{% for variant in params.variants %}{{ ' ' }}ons-btn--{{ variant }}{% endfor %}{% elif params.variants %}{{ ' ' }}ons-btn--{{ params.variants }}{% endif %}{{ ' ons-btn--link ons-js-submit-btn' if params.url }}{{ variantClasses }}"
{% if params.id %}id="{{ params.id }}"{% endif %}
{% if params.value and tag != "a" %}value="{{ params.value }}"{% endif %}
{% if params.name and tag != "a" %}name="{{ params.name }}"{% endif %}
Expand Down

0 comments on commit 0b669c7

Please sign in to comment.