2021-01-26 19:25:46 +00:00
|
|
|
.page-actions {
|
2019-12-26 10:21:50 +00:00
|
|
|
display: flex;
|
2023-07-28 01:19:27 +00:00
|
|
|
gap: var( --space-xxs );
|
2022-11-23 19:47:38 +00:00
|
|
|
margin-left: -0.75rem; // Align to the margin
|
2022-05-11 02:17:12 +00:00
|
|
|
font-size: 0.875rem;
|
2022-10-23 23:40:19 +00:00
|
|
|
font-weight: var( --font-weight-medium );
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-05-16 04:50:00 +00:00
|
|
|
// TODO: Merge this with header__item
|
|
|
|
&__item {
|
|
|
|
display: flex;
|
|
|
|
}
|
|
|
|
|
|
|
|
// TODO: Merge this with header__button
|
|
|
|
&__button {
|
|
|
|
display: grid;
|
2023-07-28 01:19:27 +00:00
|
|
|
place-items: center;
|
2022-11-23 19:47:38 +00:00
|
|
|
width: 2.75rem; // Same width as other buttons
|
2022-11-25 02:19:14 +00:00
|
|
|
height: 2.25rem; // Same height as other buttons
|
2022-05-16 22:12:37 +00:00
|
|
|
border-radius: var( --border-radius--medium );
|
2022-05-16 04:50:00 +00:00
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background-color: var( --background-color-quiet--hover );
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
.citizen-ui-icon::before {
|
2022-05-16 04:50:00 +00:00
|
|
|
opacity: var( --opacity-icon-base--hover );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active {
|
|
|
|
background-color: var( --background-color-quiet--active );
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
.citizen-ui-icon::before {
|
2022-05-16 04:50:00 +00:00
|
|
|
opacity: var( --opacity-icon-base--active );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-05-16 22:12:37 +00:00
|
|
|
&__card {
|
|
|
|
position: absolute;
|
2022-11-23 19:47:38 +00:00
|
|
|
top: 100%;
|
|
|
|
right: ~'calc( var( --space-xs ) * -1 )'; // counteract margin
|
2023-07-28 01:19:27 +00:00
|
|
|
z-index: @z-index-page-header; // So the popups inside will be higher than content
|
2023-08-22 21:02:50 +00:00
|
|
|
display: grid;
|
|
|
|
gap: var( --space-xs );
|
2022-05-16 22:12:37 +00:00
|
|
|
max-height: 60vh;
|
2023-08-22 21:02:50 +00:00
|
|
|
padding: var( --space-xs ) 0;
|
2022-11-23 19:47:38 +00:00
|
|
|
margin: var( --space-xs );
|
2023-07-28 01:19:27 +00:00
|
|
|
overflow: auto;
|
2022-05-16 22:12:37 +00:00
|
|
|
font-size: 0.875rem;
|
|
|
|
.citizen-card;
|
2022-05-20 20:07:44 +00:00
|
|
|
.citizen-card-hide( top right );
|
2023-07-07 21:02:27 +00:00
|
|
|
.citizen-card-transition();
|
2021-01-27 19:52:49 +00:00
|
|
|
}
|
|
|
|
|
2022-05-16 22:12:37 +00:00
|
|
|
// Visible page tools styles
|
2022-04-24 05:52:41 +00:00
|
|
|
> .mw-portlet {
|
|
|
|
ul {
|
|
|
|
display: flex;
|
2022-11-02 03:01:52 +00:00
|
|
|
gap: var( --space-xxs );
|
2022-04-24 05:52:41 +00:00
|
|
|
}
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
li > a {
|
2023-07-28 01:19:27 +00:00
|
|
|
gap: 0;
|
2023-07-07 19:26:31 +00:00
|
|
|
padding-right: var( --space-sm );
|
|
|
|
padding-left: var( --space-sm );
|
2022-04-24 05:52:41 +00:00
|
|
|
font-size: 0;
|
2023-07-28 01:19:27 +00:00
|
|
|
border-radius: var( --border-radius--medium );
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
&:hover {
|
|
|
|
background-color: var( --background-color-quiet--hover );
|
|
|
|
}
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
&:active {
|
|
|
|
background-color: var( --background-color-quiet--active );
|
2021-01-26 19:25:46 +00:00
|
|
|
}
|
2020-06-12 05:56:42 +00:00
|
|
|
}
|
2022-04-24 05:52:41 +00:00
|
|
|
}
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
ul {
|
|
|
|
margin: 0;
|
|
|
|
list-style: none;
|
2019-12-26 10:21:50 +00:00
|
|
|
}
|
2021-01-26 19:25:46 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
li {
|
|
|
|
margin: 0;
|
|
|
|
}
|
2022-05-16 04:50:00 +00:00
|
|
|
|
|
|
|
// TODO: Merge this with header styles
|
2023-01-26 01:25:40 +00:00
|
|
|
.citizen-menu-checkbox-checkbox:checked ~ .page-actions__button {
|
2022-05-16 04:50:00 +00:00
|
|
|
background-color: var( --background-color-primary--active );
|
|
|
|
}
|
2023-02-22 19:47:32 +00:00
|
|
|
|
|
|
|
// Hide menu labels
|
|
|
|
> .citizen-menu > .citizen-menu__heading {
|
|
|
|
.mixin-screen-reader-text;
|
|
|
|
}
|
2022-04-24 05:52:41 +00:00
|
|
|
}
|
|
|
|
|
2022-05-16 23:31:11 +00:00
|
|
|
// Language counter badge
|
|
|
|
// TODO: Maybe this should be in a mixin
|
|
|
|
#citizen-languages__buttonCheckbox {
|
|
|
|
position: relative; // So that the badge doesn't take a stroll to the far left
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
&::after {
|
2022-05-16 23:31:11 +00:00
|
|
|
position: absolute;
|
|
|
|
top: 0;
|
2022-11-23 23:38:31 +00:00
|
|
|
right: 0;
|
2022-05-16 23:31:11 +00:00
|
|
|
display: block;
|
|
|
|
padding: 0.1em 0.4em;
|
2023-07-28 01:19:27 +00:00
|
|
|
font-size: 0.65rem;
|
2022-05-16 23:31:11 +00:00
|
|
|
color: #fff;
|
|
|
|
content: attr( data-counter-text );
|
2023-07-28 01:19:27 +00:00
|
|
|
background: var( --color-primary );
|
|
|
|
border-radius: var( --border-radius--pill );
|
2022-05-16 23:31:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-05-17 13:42:34 +00:00
|
|
|
.citizen-languages {
|
|
|
|
// Special handling for ULS
|
|
|
|
// ULS won't be triggered by the label button
|
|
|
|
// so we need to overlay the checkbox on top of it
|
|
|
|
.mw-interlanguage-selector {
|
|
|
|
position: absolute;
|
|
|
|
z-index: 1;
|
|
|
|
display: block;
|
2022-05-19 01:26:43 +00:00
|
|
|
width: var( --size-button--page );
|
|
|
|
height: var( --size-button--page );
|
2022-05-17 13:42:34 +00:00
|
|
|
padding: 0;
|
|
|
|
margin: 0;
|
|
|
|
cursor: pointer;
|
|
|
|
opacity: 0;
|
|
|
|
|
|
|
|
// Hover state needs to be define because the checkbox now overlays the label
|
|
|
|
&:hover {
|
|
|
|
~ .page-actions__button {
|
|
|
|
background-color: var( --background-color-quiet--hover );
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
.citizen-ui-icon::before {
|
2022-05-17 13:42:34 +00:00
|
|
|
opacity: var( --opacity-icon-base--hover );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active {
|
|
|
|
~ .page-actions__button {
|
|
|
|
background-color: var( --background-color-quiet--active );
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
.citizen-ui-icon::before {
|
2022-05-17 13:42:34 +00:00
|
|
|
opacity: var( --opacity-icon-base--active );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-05-16 22:12:37 +00:00
|
|
|
.page-actions-more,
|
|
|
|
.citizen-languages {
|
|
|
|
position: relative;
|
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
// Edit button
|
|
|
|
#ca-edit,
|
|
|
|
#ca-ve-edit {
|
|
|
|
> a {
|
|
|
|
color: #fff;
|
2023-07-28 01:19:27 +00:00
|
|
|
background-color: var( --color-primary );
|
2021-01-27 18:59:14 +00:00
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
&:hover {
|
|
|
|
background-color: var( --color-primary--hover );
|
2022-04-27 17:35:03 +00:00
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
&:active {
|
|
|
|
background-color: var( --color-primary--active );
|
2021-01-27 18:59:14 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
> a,
|
|
|
|
.citizen-ui-icon {
|
2023-02-28 21:59:36 +00:00
|
|
|
&::before {
|
2022-11-02 03:01:52 +00:00
|
|
|
filter: invert( 1 );
|
|
|
|
// white icon
|
|
|
|
opacity: 1;
|
|
|
|
}
|
2021-01-27 18:59:14 +00:00
|
|
|
}
|
2022-11-02 03:01:52 +00:00
|
|
|
}
|
2021-01-26 19:25:46 +00:00
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
// VE styles shouldn't be core but it is just a few lines :/
|
2022-11-07 23:22:15 +00:00
|
|
|
#ca-ve-edit {
|
2022-11-02 03:01:52 +00:00
|
|
|
order: 98; // Before source edit
|
2021-01-26 19:25:46 +00:00
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
> a {
|
2022-11-07 22:28:39 +00:00
|
|
|
// See SkinHooks.php for why VE is here
|
2023-02-28 21:59:36 +00:00
|
|
|
&::before {
|
2022-11-07 22:28:39 +00:00
|
|
|
width: var( --size-icon );
|
|
|
|
height: var( --size-icon );
|
2023-07-28 01:19:27 +00:00
|
|
|
content: '';
|
2022-11-07 22:28:39 +00:00
|
|
|
background-repeat: no-repeat;
|
2023-07-28 01:19:27 +00:00
|
|
|
background-position: center;
|
2022-11-07 22:28:39 +00:00
|
|
|
background-size: var( --size-icon );
|
|
|
|
}
|
2022-11-02 03:01:52 +00:00
|
|
|
}
|
2022-11-07 23:22:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
#ca-edit {
|
|
|
|
order: 99; // Align to last
|
|
|
|
}
|
2021-01-26 19:25:46 +00:00
|
|
|
|
2022-11-07 23:22:15 +00:00
|
|
|
// Merge two buttons together
|
2023-07-23 07:12:30 +00:00
|
|
|
.client-js .citizen-ve-edit-merged {
|
2022-11-07 23:22:15 +00:00
|
|
|
&#ca-ve-edit {
|
|
|
|
> a {
|
|
|
|
border-top-right-radius: 0;
|
2023-07-28 01:19:27 +00:00
|
|
|
border-bottom-right-radius: 0;
|
2022-11-07 23:22:15 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&#ca-edit {
|
2022-11-02 03:01:52 +00:00
|
|
|
margin-left: ~'calc( var( --space-xxs ) * -1 )';
|
2023-07-28 01:19:27 +00:00
|
|
|
border-left: 1px solid var( --color-primary--hover );
|
2021-01-26 19:25:46 +00:00
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
> a {
|
|
|
|
gap: 0;
|
2023-07-28 01:19:27 +00:00
|
|
|
font-size: 0; // hide edit source text
|
|
|
|
border-top-left-radius: 0;
|
|
|
|
border-bottom-left-radius: 0;
|
2021-01-26 19:25:46 +00:00
|
|
|
}
|
|
|
|
}
|
2020-06-12 05:56:42 +00:00
|
|
|
}
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-05-16 22:12:37 +00:00
|
|
|
// Checkbox hack
|
|
|
|
#page-actions-more,
|
|
|
|
#citizen-languages {
|
|
|
|
&__checkbox:checked {
|
|
|
|
~ .page-actions__card {
|
|
|
|
.citizen-card-show();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-11-23 19:47:38 +00:00
|
|
|
// To avoid more menu from overflow in narrow screen
|
2023-11-16 22:55:23 +00:00
|
|
|
@media ( max-width: @max-width-breakpoint-tablet ) {
|
2022-10-01 05:45:55 +00:00
|
|
|
.page-actions {
|
|
|
|
&__item {
|
|
|
|
position: unset;
|
|
|
|
}
|
2023-06-02 18:38:25 +00:00
|
|
|
|
|
|
|
&__card {
|
|
|
|
right: 0;
|
|
|
|
left: 0;
|
|
|
|
}
|
2022-10-01 05:45:55 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-11-16 22:55:23 +00:00
|
|
|
@media ( min-width: @min-width-breakpoint-desktop ) {
|
2022-04-24 05:52:41 +00:00
|
|
|
.page-actions {
|
|
|
|
> .mw-portlet {
|
|
|
|
li > a {
|
2022-11-02 03:01:52 +00:00
|
|
|
gap: var( --space-xs );
|
2023-07-28 01:19:27 +00:00
|
|
|
font-size: 0.875rem;
|
2021-01-26 19:25:46 +00:00
|
|
|
}
|
|
|
|
}
|
2022-12-07 19:34:22 +00:00
|
|
|
|
|
|
|
&__card {
|
|
|
|
// Expand the width on narrow screens might overflow the page
|
2022-12-11 23:33:12 +00:00
|
|
|
white-space: nowrap;
|
2022-12-07 19:34:22 +00:00
|
|
|
}
|
2021-01-26 19:25:46 +00:00
|
|
|
}
|
|
|
|
}
|
2021-05-04 17:33:43 +00:00
|
|
|
|
2022-05-16 22:12:37 +00:00
|
|
|
// Reset hover styles if it is a touch device
|
|
|
|
// This is dumb but hover:hover overrides active states
|
|
|
|
@media ( hover: none ) {
|
|
|
|
.page-actions {
|
|
|
|
&__button {
|
|
|
|
&:hover {
|
|
|
|
background-color: none;
|
|
|
|
|
2023-02-28 21:59:36 +00:00
|
|
|
.citizen-ui-icon::before {
|
2022-05-16 22:12:37 +00:00
|
|
|
opacity: var( --opacity-icon-base );
|
|
|
|
}
|
|
|
|
}
|
2021-05-04 17:33:43 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|