Add an option to ignore (block) a user when reporting their events (#8471)
* Add an option to ignore (block) a user when reporting their events This is primarily useful if the content being reported really doesn't belong on your screen, and the room moderators are slow to react. Ideally we'd use the word "block" instead of "ignore", but we call it "ignore user" everywhere else. See https://github.com/vector-im/element-web/issues/19590 for further context on the word choice. This change includes a minor refactor to the styles of labelled toggles (for reusability). * Appease the linter * Use a checkbox instead of toggle in the dialog * Update classnames handling for toggle switch * Appease the linter
This commit is contained in:
parent
c715f72745
commit
e87bda9f37
13 changed files with 350 additions and 27 deletions
|
@ -133,7 +133,6 @@
|
|||
@import "./views/dialogs/_UploadConfirmDialog.scss";
|
||||
@import "./views/dialogs/_UserSettingsDialog.scss";
|
||||
@import "./views/dialogs/_WidgetCapabilitiesPromptDialog.scss";
|
||||
@import "./views/dialogs/_WidgetOpenIDPermissionsDialog.scss";
|
||||
@import "./views/dialogs/security/_AccessSecretStorageDialog.scss";
|
||||
@import "./views/dialogs/security/_CreateCrossSigningDialog.scss";
|
||||
@import "./views/dialogs/security/_CreateKeyBackupDialog.scss";
|
||||
|
@ -161,6 +160,7 @@
|
|||
@import "./views/elements/_InlineSpinner.scss";
|
||||
@import "./views/elements/_InteractiveTooltip.scss";
|
||||
@import "./views/elements/_InviteReason.scss";
|
||||
@import "./views/elements/_LabelledCheckbox.scss";
|
||||
@import "./views/elements/_ManageIntegsButton.scss";
|
||||
@import "./views/elements/_MiniAvatarUploader.scss";
|
||||
@import "./views/elements/_Pill.scss";
|
||||
|
|
|
@ -46,10 +46,6 @@ limitations under the License.
|
|||
font-size: $font-12px;
|
||||
|
||||
.mx_ToggleSwitch {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
margin-right: 8px;
|
||||
|
||||
// downsize the switch + ball
|
||||
width: $font-32px;
|
||||
height: $font-15px;
|
||||
|
@ -64,10 +60,5 @@ limitations under the License.
|
|||
border-radius: $font-15px;
|
||||
}
|
||||
}
|
||||
|
||||
.mx_SettingsFlag_label {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
Copyright 2019 Travis Ralston
|
||||
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.
|
||||
|
@ -14,15 +14,26 @@ See the License for the specific language governing permissions and
|
|||
limitations under the License.
|
||||
*/
|
||||
|
||||
.mx_WidgetOpenIDPermissionsDialog .mx_SettingsFlag {
|
||||
.mx_ToggleSwitch {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
margin-right: 8px;
|
||||
.mx_LabelledCheckbox {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
||||
.mx_Checkbox {
|
||||
margin-top: 3px; // visually align with label text
|
||||
}
|
||||
|
||||
.mx_SettingsFlag_label {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
.mx_LabelledCheckbox_labels {
|
||||
flex: 1;
|
||||
|
||||
.mx_LabelledCheckbox_label {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.mx_LabelledCheckbox_byline {
|
||||
display: block;
|
||||
padding-top: $spacing-4;
|
||||
color: $muted-fg-color;
|
||||
font-size: $font-11px;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -24,6 +24,19 @@ limitations under the License.
|
|||
.mx_ToggleSwitch {
|
||||
flex: 0 0 auto;
|
||||
}
|
||||
|
||||
&.mx_SettingsFlag_toggleInFront {
|
||||
.mx_ToggleSwitch {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
margin-right: 8px;
|
||||
}
|
||||
|
||||
.mx_SettingsFlag_label {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.mx_SettingsFlag_label {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue