Files
wekan/client/components/users/userAvatar.css
T
Lauri Ojansivu a6b10e3592 Dark themes: the quiet greys, Card Settings, popups and sidebars are readable again.
The accessibility audit made the quiet text greys dark for every theme, and
old rules never followed the dark themes: Card Settings drew white text on
light grey blocks, popup items, the sidebar's shortcuts row, quiet buttons and
sidebar labels were black on dark, and an !important list header beat each
theme's own. The quiet text is a variable with a light value on the dark
surfaces; Card Settings' sections, popup items and the other rules follow the
theme. axe-core finds no colour contrast failure in cleandark, moderndark, dark
and exodark on the board, sidebar, Card Settings, an opened card and the custom
fields popup.

Thanks to Samunosuke and xet7 !

Fixes #6863,
2026-11-03 11:41:58 +02:00

225 lines
5.5 KiB
CSS

.member {
border-radius: 3px;
display: block;
position: relative;
float: inline-start;
height: 24px;
width: 24px;
margin: 3px;
cursor: pointer;
user-select: none;
z-index: 1;
text-decoration: none;
border-radius: 50%;
}
.member .avatar {
overflow: hidden;
border-radius: 50%;
}
.member .avatar.avatar-initials {
/* The grey is only a fallback: each person has a colour of their own (#2110,
set inline from models/lib/avatarColor.js). The initials take its text colour. */
height: 70%;
width: 70%;
padding: 15%;
background-color: #dbdbdb;
color: #444;
position: absolute;
display: flex;
align-items: center;
justify-content: center;
}
/* SVG text is drawn with `fill`, not `color`: the initials follow the
person's text colour (#2110). */
.member .avatar.avatar-initials text {
fill: currentColor;
}
.member .avatar.avatar-image {
object-fit: cover;
object-position: center;
height: 100%;
width: 100%;
}
.member .member-presence-status {
background-color: #b3b3b3;
border: 1px solid #fff;
border-radius: 50%;
height: 7px;
width: 7px;
position: absolute;
inset-inline-end: -1px;
bottom: -1px;
border: 1px solid #fff;
z-index: 15;
}
.member .member-presence-status.active {
background: #64c464;
border-color: #daf1da;
}
.member .member-presence-status.idle {
background: #e4e467;
border-color: #f7f7d4;
}
.member .member-presence-status.disconnected {
background: #bdbdbd;
border-color: #ededed;
}
.member .member-presence-status.pending {
background: #e44242;
border-color: #f1dada;
}
.member .edit-avatar {
position: absolute;
top: 0;
height: 100%;
width: 100%;
border-radius: 50%;
background: #000;
display: flex;
align-items: center;
justify-content: center;
opacity: 0;
}
.member .edit-avatar:hover {
opacity: 0.6;
}
.member .edit-avatar i.fa-pencil {
color: #fff;
}
.member.add-member {
display: flex;
align-items: center;
justify-content: center;
box-shadow: 0 0 0 2px #bfbfbf inset;
}
.member.add-member:hover,
.member.add-member.is-active {
box-shadow: 0 0 0 2px #666 inset;
}
/* Change profile image popup (changeAvatarPopup / adminChangeAvatarPopup).
One row per avatar: thumbnail, file name, a check when it is the one in use,
and a delete button. The delete button is a SIBLING of the select link (see
userAvatar.jade), so it needs its own row-level flex layout here. */
.avatar-list .avatar-list-item {
display: flex;
align-items: stretch;
}
.avatar-list .avatar-list-select {
flex: 1 1 auto;
min-width: 0;
display: flex;
align-items: center;
gap: 8px;
}
.avatar-list .avatar-list-select > .member {
align-self: center;
margin: 0;
}
.avatar-list .avatar-list-info {
flex: 1 1 auto;
min-width: 0;
line-height: calc(18px * var(--wekan-ui-font-scale, 1));
padding: 4px 0;
}
.avatar-list .avatar-list-name {
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.avatar-list .avatar-list-check {
flex: 0 0 auto;
color: #3cb500;
}
/* Marks the avatar in use; :not(:hover) so the popup's own hover colour still wins. */
.avatar-list .avatar-list-item.selected .avatar-list-select:not(:hover) {
background-color: #e2e6e9;
}
.avatar-list .avatar-list-delete {
flex: 0 0 auto;
display: flex;
align-items: center;
padding: 0 12px;
color: var(--wekan-quiet-text, #595959) !important;
}
/* Outweighs .pop-over-list li > a:not(.disabled):hover, which would otherwise
paint the delete button with the generic blue row-hover colour. */
.avatar-list.pop-over-list li > a.avatar-list-delete:hover {
color: #fff !important;
background-color: #b04632;
}
.avatar-upload-hints {
color: var(--wekan-quiet-text, #595959);
font-size: calc(12px * var(--wekan-ui-font-scale, 1));
line-height: calc(16px * var(--wekan-ui-font-scale, 1));
margin: 6px 0;
}
.atMention {
background: #dbdbdb;
border-radius: 3px;
padding: 1px 4px;
margin: -1px 0;
display: inline-block;
}
.atMention.me {
background: #cfdfe8;
}
.mini-profile-info {
margin-top: 10px;
}
.mini-profile-info .info {
padding-top: 5px;
}
.mini-profile-info .info h3,
.mini-profile-info .info p {
margin-bottom: 0;
padding-inline-start: 0;
}
.mini-profile-info .info p {
padding-top: 0;
}
.mini-profile-info .member {
width: 40px;
height: 40px;
margin-inline-end: 10px;
}
/* Account-status distinction on the avatar itself (see userAvatar.js
memberAccountClass / isImportedMember / isInactiveMember):
- imported-member: an un-reconciled board-import placeholder that is not yet mapped
to a real account — dashed ring + amber "?" corner badge.
- inactive-member: deactivated on this board (e.g. a person not in LDAP after
reconciliation) — greyscale + dimmed, grey corner badge.
A placeholder is usually both; a real, active account gets neither. */
.member.imported-member .avatar {
border: 2px dashed #7f8c9a;
box-sizing: border-box;
opacity: 0.9;
}
.member.inactive-member .avatar {
filter: grayscale(1);
opacity: 0.55;
}
.member .member-account-badge {
position: absolute;
bottom: -2px;
inset-inline-end: -2px;
min-width: 14px;
height: 14px;
line-height: calc(13px * var(--wekan-ui-font-scale, 1));
padding: 0 1px;
border-radius: 7px;
font-size: calc(10px * var(--wekan-ui-font-scale, 1));
font-weight: bold;
text-align: center;
color: #fff;
box-shadow: 0 0 0 1.5px #fff;
pointer-events: none;
}
.member .member-account-badge.imported {
background: #f39c12;
}
.member .member-account-badge.inactive {
background: #95a5a6;
}