Merge "On special page do not show empty more menu to low resolutions"

This commit is contained in:
jenkins-bot 2022-05-02 21:25:22 +00:00 committed by Gerrit Code Review
commit 5fc5bb4ad2
2 changed files with 9 additions and 2 deletions

View File

@ -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;
}

View File

@ -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;
}