diff --git a/docs/_data/buttons.json b/docs/_data/buttons.json index 2671f20255..dae9a16333 100755 --- a/docs/_data/buttons.json +++ b/docs/_data/buttons.json @@ -187,6 +187,61 @@ ] } ], + "anchor": [ + { + "title": "Anchors", + "classes": [ + { + "title": "Secondary, Clear" + }, + { + "title": "Secondary, Outlined", + "class": "s-btn__outlined" + }, + { + "title": "Secondary, Filled", + "class": "s-btn__filled" + }, + { + "title": "Danger, Clear", + "class": "s-btn__danger" + }, + { + "title": "Danger, Outlined", + "class": "s-btn__danger", + "class2": "s-btn__outlined" + }, + { + "title": "Danger, Filled", + "class": "s-btn__danger", + "class2": "s-btn__filled" + }, + { + "title": "Featured, Clear", + "class": "s-btn__featured" + }, + { + "title": "Featured, Outlined", + "class": "s-btn__featured", + "class2": "s-btn__outlined" + }, + { + "title": "Featured, Filled", + "class": "s-btn__featured", + "class2": "s-btn__filled" + }, + { + "title": "Muted, Clear", + "class": "s-btn__muted" + }, + { + "title": "Muted, Outlined", + "class": "s-btn__muted", + "class2": "s-btn__outlined" + } + ] + } + ], "badges": [ { "title": "Badge", diff --git a/docs/product/components/buttons.html b/docs/product/components/buttons.html index 0d55cda472..c788608fac 100644 --- a/docs/product/components/buttons.html +++ b/docs/product/components/buttons.html @@ -237,6 +237,60 @@ + +
+ {% header "h2", "Anchors" %} +

Anchors can be rendered with the .s-btn to adopt a button-like visual style for a link.

+ +
+{% highlight html %} +Ask question +{% endhighlight %} +
+
+ + + + + + + + + + + + {% for btn in buttons.anchor %} + {% assign types = btn.classes %} + {% for class in types %} + + + + + + + + {% endfor %} + {% endfor %} + +
TypeClassDefault StateSelected StateDisabled State
{{ class.title }} +
+ .s-btn + {% if class.class != nil %} + .{{ class.class }} + {% endif %} + {% if class.class2 != nil %} + .{{ class.class2 }} + {% endif %} + {% if btn.class != nil %} + .{{ btn.class }} + {% endif %} +
+
Ask questionAsk questionAsk question
+
+
+
+
+
{% header "h2", "Loading" %}

Any button can have a loading state applied by adding the .is-loading state class.

diff --git a/lib/components/button/button.less b/lib/components/button/button.less index 5cca3ff20a..e5be59c59d 100644 --- a/lib/components/button/button.less +++ b/lib/components/button/button.less @@ -441,13 +441,13 @@ } &:visited:not(:active):not(:focus) { - &.s-btn__filled { - background-color: var(--_bu-filled-bg); - border-color: var(--_bu-filled-bc); - color: var(--_bu-filled-fc); - } - &:not(.s-btn__outlined) { + &.s-btn__filled { + background-color: var(--_bu-filled-bg-hover); + border-color: var(--_bu-filled-bc-hover); + color: var(--_bu-filled-fc-hover); + } + background-color: var(--_bu-bg); border-color: var(--_bu-bc); color: var(--_bu-fc);