Check 'useSystemTheme' in quick settings theme switcher (#7809)
* mock Element.scrollIntoView in jest setup Signed-off-by: Kerry Archibald <kerrya@element.io> * extract theme switcher from quick settings, add match system option, test Signed-off-by: Kerry Archibald <kerrya@element.io> * i18n Signed-off-by: Kerry Archibald <kerrya@element.io> * forgotten copyright Signed-off-by: Kerry Archibald <kerrya@element.io> * stylelint Signed-off-by: Kerry Archibald <kerrya@element.io> * remove old class Signed-off-by: Kerry Archibald <kerrya@element.io>
This commit is contained in:
parent
889b0cebb2
commit
f4cd71fd47
8 changed files with 274 additions and 73 deletions
|
@ -4,6 +4,7 @@
|
|||
@import "./_font-sizes.scss";
|
||||
@import "./_font-weights.scss";
|
||||
@import "./_spacing.scss";
|
||||
@import "./components/views/spaces/_QuickThemeSwitcher.scss";
|
||||
@import "./structures/_AutoHideScrollbar.scss";
|
||||
@import "./structures/_BackdropPanel.scss";
|
||||
@import "./structures/_CompatibilityPage.scss";
|
||||
|
|
40
res/css/components/views/spaces/_QuickThemeSwitcher.scss
Normal file
40
res/css/components/views/spaces/_QuickThemeSwitcher.scss
Normal file
|
@ -0,0 +1,40 @@
|
|||
/*
|
||||
Copyright 2022 The Matrix.org Foundation C.I.C.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
.mx_QuickThemeSwitcher {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.mx_Dropdown {
|
||||
min-width: 100px;
|
||||
margin-left: auto;
|
||||
height: min-content;
|
||||
}
|
||||
|
||||
.mx_Dropdown_menu {
|
||||
max-height: 70px;
|
||||
}
|
||||
}
|
||||
|
||||
.mx_QuickThemeSwitcher_heading {
|
||||
font-weight: $font-semi-bold;
|
||||
font-size: $font-12px;
|
||||
line-height: $font-15px;
|
||||
color: $secondary-content;
|
||||
text-transform: uppercase;
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
}
|
|
@ -161,29 +161,4 @@ limitations under the License.
|
|||
mask-image: url('$(res)/img/element-icons/room/ellipsis.svg');
|
||||
}
|
||||
}
|
||||
|
||||
.mx_QuickSettingsButton_themePicker {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
> h4 {
|
||||
font-weight: $font-semi-bold;
|
||||
font-size: $font-12px;
|
||||
line-height: $font-15px;
|
||||
color: $secondary-content;
|
||||
text-transform: uppercase;
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.mx_Dropdown {
|
||||
min-width: 100px;
|
||||
margin-left: auto;
|
||||
height: min-content;
|
||||
}
|
||||
|
||||
.mx_Dropdown_menu {
|
||||
max-height: 70px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue