Merge "[search] Fix method call on null value"
[lhc/web/wiklou.git] / resources / src / mediawiki.ui / components / buttons.less
index f88f3ee..600b771 100644 (file)
@@ -12,9 +12,6 @@
 //
 // Styleguide 2.
 
-@transitionDuration: .1s;
-@transitionFunction: ease-in-out;
-
 // Neutral button styling
 //
 // These are the main actions on the page/workflow. The page should have only one of progressive, constructive and desctructive buttons, the rest being quiet.
@@ -47,7 +44,7 @@
        zoom: 1;
 
        // Container styling
-       .button-colors(#FFF);
+       .button-colors(#FFF, #CCC, #777);
        border-radius: @borderRadius;
        min-width: 4em;
 
@@ -66,8 +63,6 @@
                cursor: default;
        }
 
-       .transition(background @transitionDuration @transitionFunction, color @transitionDuration @transitionFunction, box-shadow @transitionDuration @transitionFunction;);
-
        // Styling for specific button types
        // -----------------------------------------
 
        // Styleguide 2.1.1.
        &.mw-ui-progressive,
        &.mw-ui-primary {
-               .button-colors(@colorProgressive);
+               .button-colors(@colorProgressive, @colorProgressiveHighlight, @colorProgressiveActive);
 
                &.mw-ui-quiet {
-                       .button-colors-quiet(@colorProgressive);
+                       .button-colors-quiet(@colorProgressive, @colorProgressiveHighlight, @colorProgressiveActive);
                }
        }
 
        //
        // Styleguide 2.1.2.
        &.mw-ui-constructive {
-               .button-colors(@colorConstructive);
+               .button-colors(@colorConstructive, @colorConstructiveHighlight, @colorConstructiveActive);
 
                &.mw-ui-quiet {
-                       .button-colors-quiet(@colorConstructive);
+                       .button-colors-quiet(@colorConstructive, @colorConstructiveHighlight, @colorConstructiveActive);
                }
        }
 
        //
        // Styleguide 2.1.3.
        &.mw-ui-destructive {
-               .button-colors(@colorDestructive);
+               .button-colors(@colorDestructive, @colorDestructiveHighlight, @colorDestructiveActive);
 
                &.mw-ui-quiet {
-                       .button-colors-quiet(@colorDestructive);
+                       .button-colors-quiet(@colorDestructive, @colorDestructiveHighlight, @colorDestructiveActive);
                }
        }
 
                background: transparent;
                border: none;
                text-shadow: none;
-               .button-colors-quiet(@colorButtonText);
+               .button-colors-quiet(@colorButtonText, @colorButtonTextHighlight, @colorButtonTextActive);
 
                &:hover,
                &:focus {
@@ -243,6 +238,12 @@ a.mw-ui-button {
        &:focus {
                text-decoration: none;
        }
+
+       // a-tags behave different to inputs if the line-height attribute is inherited
+       // from another element (e.g. mw-body-content). They appear bigger as input
+       // tags. See Bug T116427. To fix that, apply the correct line-height (used
+       // for inputs) to a-tags, too.
+       line-height: normal;
 }
 
 // Button groups