diff --git a/includes/SkinVector22.php b/includes/SkinVector22.php index a1d84504..b569e6a7 100644 --- a/includes/SkinVector22.php +++ b/includes/SkinVector22.php @@ -128,6 +128,11 @@ class SkinVector22 extends SkinVector { $portlets = $data['data-portlets']; $actions = $portlets['data-actions']; $overflow = $portlets['data-views-overflow']; + // if the views overflow menu is not empty, then signal that the more menu despite + // being initially empty now has collapsible items. + if ( !$overflow['is-empty'] ) { + $data['data-portlets']['data-actions']['class'] .= ' vector-has-collapsible-items'; + } $data['data-portlets']['data-actions']['html-items'] = $overflow['html-items'] . $actions['html-items']; return $data; } diff --git a/resources/skins.vector.styles/components/ArticleToolbar.less b/resources/skins.vector.styles/components/ArticleToolbar.less index 47da933b..cfc1c083 100644 --- a/resources/skins.vector.styles/components/ArticleToolbar.less +++ b/resources/skins.vector.styles/components/ArticleToolbar.less @@ -5,7 +5,9 @@ display: none; @media ( min-width: @width-breakpoint-tablet ) { - display: block; + &:not( .emptyPortlet ) { + display: block; + } } } @@ -18,7 +20,7 @@ } // Make sure pcactions is displayed (even if .emptyPortlet present) - .mw-portlet-cactions { + .vector-has-collapsible-items { @media ( max-width: @width-breakpoint-tablet ) { display: block; }