Use semantic headings in user settings Labs (#10773)

* allow testids in settings sections

* use semantic headings in LabsUserSettingsTab

* put back margin var

* explicit cast to boolean

* Update src/components/views/settings/shared/SettingsSubsection.tsx

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>

---------

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
This commit is contained in:
Kerry 2023-05-16 13:22:45 +12:00 committed by GitHub
parent 38c13509fd
commit 9bab356e20
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 164 additions and 156 deletions

View file

@ -344,7 +344,6 @@
@import "./views/settings/tabs/user/_GeneralUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_HelpUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_KeyboardUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_LabsUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_MjolnirUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_PreferencesUserSettingsTab.pcss";
@import "./views/settings/tabs/user/_SecurityUserSettingsTab.pcss";

View file

@ -46,4 +46,8 @@ limitations under the License.
margin-bottom: $spacing-8;
}
}
&.mx_SettingsSubsection_contentStretch {
justify-items: stretch;
}
}

View file

@ -15,7 +15,6 @@ limitations under the License.
*/
.mx_BetaCard {
margin-bottom: $spacing-20;
padding: $spacing-24;
background-color: $system;
border-radius: 8px;
@ -114,10 +113,6 @@ limitations under the License.
}
}
}
&:last-child {
margin-bottom: 0;
}
}
.mx_BetaCard_betaPill {

View file

@ -20,6 +20,7 @@ limitations under the License.
align-items: flex-start;
justify-content: space-between;
margin-bottom: 4px;
width: 100%;
.mx_ToggleSwitch {
flex: 0 0 auto;

View file

@ -1,27 +0,0 @@
/*
Copyright 2021 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_LabsUserSettingsTab {
.mx_SettingsTab_subsectionText,
.mx_SettingsTab_section {
margin-bottom: var(--SettingsTab_section-margin-bottom-preferences-labs);
}
.mx_SettingsFlag {
margin-right: 0; /* remove right margin to align with beta cards */
align-items: center;
}
}