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 );
|
2024-04-26 21:41:27 +00:00
|
|
|
align-items: center;
|
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;
|
|
|
|
}
|
|
|
|
|
2024-05-30 06:19:53 +00:00
|
|
|
.citizen-menu {
|
|
|
|
&__card {
|
|
|
|
position: absolute;
|
|
|
|
right: ~'calc( var( --space-xs ) * -1 )'; // counteract margin
|
|
|
|
display: grid;
|
|
|
|
gap: var( --space-xs );
|
|
|
|
max-height: 60vh;
|
|
|
|
padding: var( --space-xs ) 0;
|
|
|
|
transform-origin: var( --transform-origin-offset-end ) var( --transform-origin-offset-end );
|
|
|
|
|
|
|
|
@media ( min-width: @min-width-breakpoint-desktop ) {
|
2024-07-03 20:07:08 +00:00
|
|
|
top: 100%;
|
2024-05-30 06:19:53 +00:00
|
|
|
transform-origin: var( --transform-origin-offset-end ) var( --transform-origin-offset-start );
|
2022-05-16 04:50:00 +00:00
|
|
|
}
|
|
|
|
}
|
2024-07-03 20:07:08 +00:00
|
|
|
}
|
2022-05-16 04:50:00 +00:00
|
|
|
|
2024-07-03 20:07:08 +00:00
|
|
|
.citizen-dropdown {
|
|
|
|
@media ( min-width: @min-width-breakpoint-desktop ) {
|
|
|
|
// Only attach dropdown menu to the button on desktop mode
|
|
|
|
position: relative;
|
|
|
|
}
|
2022-05-16 04:50:00 +00:00
|
|
|
|
2024-07-03 20:07:08 +00:00
|
|
|
&-summary {
|
|
|
|
display: grid;
|
|
|
|
place-items: center;
|
|
|
|
width: 2.5rem; // Same width as other buttons
|
|
|
|
height: 2.25rem; // Same height as other buttons
|
2024-07-05 17:24:31 +00:00
|
|
|
border-radius: var( --border-radius-medium );
|
2022-05-16 04:50:00 +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;
|
2024-07-05 17:24:31 +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 {
|
2024-07-01 00:41:31 +00:00
|
|
|
background-color: var( --background-color-button-quiet--hover );
|
2022-04-24 05:52:41 +00:00
|
|
|
}
|
2019-12-26 10:21:50 +00:00
|
|
|
|
2022-04-24 05:52:41 +00:00
|
|
|
&:active {
|
2024-07-01 00:41:31 +00:00
|
|
|
background-color: var( --background-color-button-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
|
|
|
li {
|
|
|
|
margin: 0;
|
|
|
|
}
|
2022-05-16 04:50:00 +00:00
|
|
|
|
2023-02-22 19:47:32 +00:00
|
|
|
// Hide menu labels
|
|
|
|
> .citizen-menu > .citizen-menu__heading {
|
2024-07-03 18:41:14 +00:00
|
|
|
.sr-only;
|
2023-02-22 19:47:32 +00:00
|
|
|
}
|
2022-04-24 05:52:41 +00:00
|
|
|
}
|
|
|
|
|
2022-05-16 23:31:11 +00:00
|
|
|
// Language counter badge
|
2024-05-30 06:19:53 +00:00
|
|
|
.citizen-page-languages {
|
2024-07-06 00:37:52 +00:00
|
|
|
.citizen-dropdown-summary {
|
2024-05-30 06:19:53 +00:00
|
|
|
position: relative; // So that the badge doesn't take a stroll to the far left
|
|
|
|
|
|
|
|
&::after {
|
|
|
|
position: absolute;
|
|
|
|
top: 0;
|
|
|
|
right: 0;
|
|
|
|
display: block;
|
|
|
|
padding: 0.1em 0.4em;
|
|
|
|
font-size: 0.65rem;
|
|
|
|
content: attr( data-counter-text );
|
2024-06-30 05:11:35 +00:00
|
|
|
background: var( --color-surface-0 );
|
2024-07-05 17:24:31 +00:00
|
|
|
border-radius: var( --border-radius-pill );
|
2022-05-17 13:42:34 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
// Edit button
|
|
|
|
#ca-edit,
|
|
|
|
#ca-ve-edit {
|
|
|
|
> a {
|
2024-06-10 23:47:49 +00:00
|
|
|
color: var( --color-inverted-primary );
|
2024-06-30 05:04:30 +00:00
|
|
|
background-color: var( --color-progressive );
|
2021-01-27 18:59:14 +00:00
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
&:hover {
|
2024-06-30 05:04:30 +00:00
|
|
|
background-color: var( --color-progressive--hover );
|
2022-04-27 17:35:03 +00:00
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
&:active {
|
2024-06-30 05:04:30 +00:00
|
|
|
background-color: var( --color-progressive--active );
|
2021-01-27 18:59:14 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-11-02 03:01:52 +00:00
|
|
|
.citizen-ui-icon {
|
2023-02-28 21:59:36 +00:00
|
|
|
&::before {
|
2024-07-25 01:09:37 +00:00
|
|
|
filter: var( --filter-invert-primary );
|
|
|
|
opacity: 1; // white icon
|
2022-11-02 03:01:52 +00:00
|
|
|
}
|
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
|
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 {
|
2024-08-17 21:40:53 +00:00
|
|
|
// Additional check to check if there are actually source edit button (#929)
|
|
|
|
&#ca-ve-edit:has( + #ca-edit ) {
|
|
|
|
> a {
|
2022-11-07 23:22:15 +00:00
|
|
|
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 )';
|
2024-07-15 06:07:25 +00:00
|
|
|
border-left: var( --border-width-base ) solid var( --color-progressive--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-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 {
|
2024-04-26 21:41:27 +00:00
|
|
|
position: fixed;
|
|
|
|
right: 0;
|
|
|
|
bottom: ~'calc( var( --header-size ) + var( --space-xs ) )';
|
|
|
|
height: var( --toolbar-size );
|
|
|
|
margin: var( --space-xs );
|
|
|
|
background: var( --color-surface-1 );
|
2024-10-05 07:02:12 +00:00
|
|
|
border: 1px solid var( --border-color-base );
|
2024-07-05 17:24:31 +00:00
|
|
|
border-radius: var( --border-radius-medium );
|
2024-07-25 01:53:51 +00:00
|
|
|
box-shadow: var( --box-shadow-drop-xx-large );
|
2024-04-26 21:41:27 +00:00
|
|
|
|
2024-05-28 06:12:50 +00:00
|
|
|
:not( .citizen-menu__card ) .mw-list-item {
|
2024-04-26 21:41:27 +00:00
|
|
|
--size-icon: 1rem;
|
|
|
|
}
|
|
|
|
|
|
|
|
> .mw-portlet li > a {
|
|
|
|
height: var( --toolbar-size );
|
|
|
|
}
|
|
|
|
|
2022-10-01 05:45:55 +00:00
|
|
|
&__item {
|
|
|
|
position: unset;
|
|
|
|
}
|
2023-06-02 18:38:25 +00:00
|
|
|
|
2024-05-28 06:12:50 +00:00
|
|
|
.citizen-menu__card {
|
2024-04-26 21:41:27 +00:00
|
|
|
bottom: 100%;
|
2024-10-05 07:16:57 +00:00
|
|
|
/* Fix card width issue when the page tool bar is narrow */
|
|
|
|
width: max-content;
|
2023-06-02 18:38:25 +00:00
|
|
|
}
|
2022-10-01 05:45:55 +00:00
|
|
|
}
|
2024-07-01 17:44:28 +00:00
|
|
|
|
2024-10-17 06:49:01 +00:00
|
|
|
.citizen-page-languages .citizen-dropdown-summary::after {
|
2024-07-01 17:44:28 +00:00
|
|
|
// Blend with background
|
|
|
|
background: var( --color-surface-1 );
|
|
|
|
}
|
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 );
|
2024-02-26 22:16:07 +00:00
|
|
|
font-size: var( --font-size-small );
|
2021-01-26 19:25:46 +00:00
|
|
|
}
|
|
|
|
}
|
2022-12-07 19:34:22 +00:00
|
|
|
|
2024-05-28 06:12:50 +00:00
|
|
|
.citizen-menu__card {
|
2022-12-07 19:34:22 +00:00
|
|
|
// 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
|
|
|
}
|
|
|
|
}
|