element-web/res/css/views/elements/_RichText.scss

123 lines
2.9 KiB
SCSS
Raw Normal View History

// XXX: bleurgh, what is this? These classes totally break the component
// naming scheme; it's completely unclear where or how they're being used
// --Matthew
.mx_UserPill,
.mx_RoomPill,
.mx_GroupPill,
.mx_AtRoomPill {
display: inline-flex;
align-items: center;
vertical-align: middle;
border-radius: $font-16px;
height: $font-16px;
line-height: $font-20px;
padding-left: 0;
2020-04-14 17:35:38 +02:00
padding-right: 0.5rem;
}
a.mx_Pill {
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
vertical-align: text-bottom;
max-width: calc(100% - 1ch);
height: $font-24px;
}
.mx_Pill {
2020-04-14 17:45:21 +02:00
padding: $font-5px;
}
2020-04-14 18:07:59 +02:00
/* More specific to override `.markdown-body a` color */
.mx_EventTile_content .markdown-body a.mx_GroupPill,
.mx_GroupPill {
color: $accent-fg-color;
background-color: $rte-group-pill-color;
}
/* More specific to override `.markdown-body a` text-decoration */
.mx_EventTile_content .markdown-body a.mx_Pill {
text-decoration: none;
}
/* More specific to override `.markdown-body a` color */
.mx_EventTile_content .markdown-body a.mx_UserPill,
.mx_UserPill {
color: $primary-fg-color;
background-color: $other-user-pill-bg-color;
2020-04-07 16:23:19 +02:00
}
.mx_UserPill_selected {
background-color: $accent-color !important;
}
/* More specific to override `.markdown-body a` color */
.mx_EventTile_highlight .mx_EventTile_content .markdown-body a.mx_UserPill_me,
.mx_EventTile_content .markdown-body a.mx_AtRoomPill,
.mx_EventTile_content .mx_AtRoomPill,
.mx_MessageComposer_input .mx_AtRoomPill {
color: $accent-fg-color;
background-color: $mention-user-pill-bg-color;
}
/* More specific to override `.markdown-body a` color */
.mx_EventTile_content .markdown-body a.mx_RoomPill,
.mx_EventTile_content .markdown-body a.mx_GroupPill,
.mx_RoomPill,
.mx_GroupPill {
color: $accent-fg-color;
background-color: $rte-room-pill-color;
}
.mx_EventTile_body .mx_UserPill,
.mx_EventTile_body .mx_RoomPill,
.mx_EventTile_body .mx_GroupPill {
cursor: pointer;
}
.mx_UserPill .mx_BaseAvatar,
.mx_RoomPill .mx_BaseAvatar,
.mx_GroupPill .mx_BaseAvatar,
.mx_AtRoomPill .mx_BaseAvatar {
position: relative;
display: inline-flex;
align-items: center;
border-radius: 10rem;
margin-right: 0.24rem;
}
.mx_Markdown_BOLD {
font-weight: bold;
}
.mx_Markdown_ITALIC {
font-style: italic;
/*
2019-01-31 11:51:26 +01:00
// interestingly, *not* using the explicit italic font
// variant seems yield better results.
// compensate for Nunito italics being terrible
// https://github.com/google/fonts/issues/1726
transform: skewX(-14deg);
display: inline-block;
*/
}
.mx_Markdown_CODE {
padding: .2em 0;
margin: 0;
font-size: 85%;
background-color: $rte-code-bg-color;
border-radius: 3px;
}
.mx_Markdown_HR {
display: block;
background: $rte-bg-color;
}
.mx_Markdown_STRIKETHROUGH {
text-decoration: line-through;
}