discourse/app/assets/stylesheets/common/admin/users.scss
Osama Sayegh 118f7869bb
FEATURE: Add bulk destroy to admin users list (#29744)
This commit introduces a new feature that allows staff to bulk select and delete users directly from the users list at `/admin/users/list`. The main use-case for this feature is make deleting spammers easier when a site is under a large spam attack.

Internal topic: t/140321.
2024-11-25 11:13:35 +03:00

221 lines
3.3 KiB
SCSS

//Styles for /admin/users
.display-row.associations .value {
width: 750px;
@media (max-width: $mobile-breakpoint) {
width: 75%;
float: right;
text-align: left;
margin-left: 0;
}
}
.display-row {
display: flex;
align-items: center;
padding: 10px 5px;
&:nth-of-type(1) {
border-top: 0;
}
&.highlight-danger {
background-color: var(--danger-low);
}
border-top: 1px solid var(--primary-low);
&:before,
&:after {
display: table;
content: "";
}
&:after {
clear: both;
}
&.secondary-emails ul {
margin: 0;
list-style: none;
}
.field {
font-weight: bold;
width: 17.65765%;
min-width: 125px;
margin-left: 12px;
@media (max-width: $mobile-breakpoint) {
margin-left: 0;
line-height: var(--line-height-large);
margin-top: 5px;
}
}
.value {
width: 100%;
max-width: 350px;
min-width: 50px;
margin-left: 12px;
word-break: break-word;
.select-kit {
min-width: 100px;
}
@media (max-width: $mobile-breakpoint) {
text-align: left;
margin-left: 0;
}
.select-kit {
width: inherit;
}
}
.long-value {
margin-left: 12px;
font-size: var(--font-down-1);
button {
margin-left: 10px;
}
}
.controls {
margin-left: 12px;
@media (max-width: $mobile-breakpoint) {
width: 75%;
text-align: left;
margin-left: 0;
}
.btn {
margin-right: 5px;
}
}
&.username,
&.name {
.value {
word-break: break-all;
}
}
}
.admin-users {
input {
margin-bottom: 0;
}
.users-list {
.username .d-icon {
color: var(--primary-medium);
}
}
}
.admin-users-list {
.directory-table__cell {
&.username {
justify-content: start;
}
&.email {
justify-content: start;
span {
display: flex;
min-width: 17em;
word-break: break-all;
}
}
}
.directory-table {
margin-top: 1em;
&__column-header {
&--username,
&---email {
.header-contents {
text-align: left;
}
}
&--username {
flex-grow: 1;
}
}
&__column-header-wrapper {
display: flex;
}
&__cell-bulk-select {
margin-right: 1em;
}
&__cell.username {
align-items: center;
}
&__cell.email {
@include breakpoint("tablet") {
grid-column-start: 1;
grid-column-end: -1;
span {
max-width: 100%;
}
}
}
}
.directory-table__cell {
padding: 0.5em 0.25em;
}
.user-status span {
gap: 0.15em;
}
.avatar {
margin-right: 0.25em;
}
&__controls {
display: flex;
gap: 1em;
}
}
// mobile styles
.mobile-view .admin-users.admin-user {
.display-row {
flex-direction: column;
align-items: flex-start;
.field,
.value {
width: 100%;
}
.select-kit {
width: 100%;
}
}
.long-value {
word-wrap: break-word;
max-width: 100%;
margin: 0;
button {
margin: 5px 0;
display: block;
}
}
h1 {
margin: 15px 0 5px 0;
}
.user-controls {
text-align: inherit;
}
.controls {
width: unset;
margin-top: 5px;
}
.associations button {
margin: 5px 5px 0 0;
}
.ip-lookup {
display: block;
.location-box {
left: 0;
}
}
}