diff --git a/resources/skins.vector.styles/layout-default.less b/resources/skins.vector.styles/layout-default.less index 1fb063e..aa601c4 100644 --- a/resources/skins.vector.styles/layout-default.less +++ b/resources/skins.vector.styles/layout-default.less @@ -54,6 +54,7 @@ body { // Vertical centering of header elements (IE>=11), requires flex. // Non-flex fallback for IE<=9: float rule on the child elements. .flex-display(); + flex-wrap: wrap; // https://caniuse.com/#search=align-items align-items: center; z-index: @z-index-header; @@ -153,6 +154,7 @@ body { } #mw-sidebar-button { + float: left; // Browser: IE9 support - button as flex-child fallback. margin-left: -@margin-horizontal-sidebar-button-icon; margin-right: @margin-horizontal-sidebar-button-icon; // Accidentally the same. } diff --git a/resources/skins.vector.styles/layout-search-header.less b/resources/skins.vector.styles/layout-search-header.less index d1d903b..8ced075 100644 --- a/resources/skins.vector.styles/layout-search-header.less +++ b/resources/skins.vector.styles/layout-search-header.less @@ -29,6 +29,9 @@ // Header components #p-search { + flex-grow: 1; + // Support IE9: float will be disabled if display flex is supported + float: left; // Override values to reflect new behaviour. min-width: @min-width-search; max-width: 100%; @@ -40,13 +43,8 @@ } } - // Support IE9: float will be disabled if display flex is supported - #p-search, - #mw-sidebar-button { - float: left; - } - #p-personal { + flex-grow: 1; text-align: right; flex-basis: @min-width-personal-tools; margin-left: @margin-horizontal-search; @@ -55,25 +53,3 @@ float: right; } } - -// If flexbox supported reset the floats that are supporting IE9 -// When IE9 is no longer supported this entire query can be dropped. -@supports ( display: flex ) { - .skin-vector-search-header { - .mw-header { - flex-wrap: wrap; - } - - #p-personal, - #p-search { - flex-grow: 1; - // Disable the float: left rule for IE9 support - float: none; - } - - #mw-sidebar-button { - // Disable the float: left rule for IE9 support - float: none; - } - } -}