2020-04-29 16:07:41 +02:00
|
|
|
/*
|
|
|
|
Copyright 2020 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.
|
|
|
|
*/
|
|
|
|
|
2020-05-08 23:21:26 +02:00
|
|
|
$irc-line-height: $font-18px;
|
2020-04-29 16:07:41 +02:00
|
|
|
|
|
|
|
.mx_IRCLayout {
|
2023-03-07 14:32:38 +01:00
|
|
|
--name-width: 80px; // cf. ircDisplayNameWidth on Settings.tsx
|
2022-07-06 12:44:23 +02:00
|
|
|
--icon-width: 14px;
|
|
|
|
--right-padding: 5px;
|
2023-03-24 13:57:32 +01:00
|
|
|
--line-height: $irc-line-height;
|
2020-04-29 16:07:41 +02:00
|
|
|
|
2023-03-24 13:57:32 +01:00
|
|
|
line-height: var(--line-height) !important;
|
2020-04-29 16:07:41 +02:00
|
|
|
|
2023-03-14 15:32:12 +01:00
|
|
|
.mx_NewRoomIntro {
|
|
|
|
> h2 {
|
|
|
|
line-height: initial; /* Cancel $irc-line-height */
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-04-29 16:07:41 +02:00
|
|
|
.mx_EventTile {
|
2022-07-12 15:40:19 +02:00
|
|
|
--EventTile_irc_line-padding-block: 1px;
|
|
|
|
|
2022-07-27 15:39:29 +02:00
|
|
|
/* timestamps are links which shouldn't be underlined */
|
2020-05-08 23:21:26 +02:00
|
|
|
> a {
|
|
|
|
text-decoration: none;
|
2022-05-07 05:07:51 +02:00
|
|
|
min-width: $MessageTimestamp_width;
|
2020-05-08 23:21:26 +02:00
|
|
|
}
|
|
|
|
|
2020-04-29 16:07:41 +02:00
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
align-items: flex-start;
|
2020-04-29 16:29:25 +02:00
|
|
|
padding-top: 0;
|
2020-04-29 16:07:41 +02:00
|
|
|
|
|
|
|
> * {
|
2022-07-06 12:44:23 +02:00
|
|
|
margin-right: var(--right-padding);
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
|
2022-07-05 09:01:06 +02:00
|
|
|
.mx_EventTile_msgOption {
|
2020-05-26 19:15:06 +02:00
|
|
|
order: 5;
|
2020-04-29 16:07:41 +02:00
|
|
|
flex-shrink: 0;
|
|
|
|
}
|
|
|
|
|
2022-06-29 07:41:52 +02:00
|
|
|
.mx_EventTile_line,
|
|
|
|
.mx_EventTile_reply {
|
2020-05-08 23:21:26 +02:00
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
2020-04-29 16:07:41 +02:00
|
|
|
order: 3;
|
|
|
|
flex-grow: 1;
|
2020-05-26 18:39:39 +02:00
|
|
|
flex-shrink: 1;
|
|
|
|
min-width: 0;
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
|
2022-06-25 19:22:52 +02:00
|
|
|
.mx_EventTile_avatar {
|
2020-04-29 16:07:41 +02:00
|
|
|
order: 1;
|
|
|
|
position: relative;
|
|
|
|
flex-shrink: 0;
|
2020-05-08 23:21:26 +02:00
|
|
|
height: $irc-line-height;
|
2020-04-29 16:07:41 +02:00
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
|
2022-07-27 15:39:29 +02:00
|
|
|
/* Need to use important to override the js provided height and width values. */
|
2022-12-12 12:24:14 +01:00
|
|
|
> .mx_BaseAvatar,
|
|
|
|
> .mx_BaseAvatar > * {
|
2020-05-05 11:54:44 +02:00
|
|
|
height: $font-14px !important;
|
|
|
|
width: $font-14px !important;
|
|
|
|
font-size: $font-10px !important;
|
2020-05-13 15:04:46 +02:00
|
|
|
line-height: $font-15px !important;
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-06-30 00:38:23 +02:00
|
|
|
.mx_DisambiguatedProfile {
|
|
|
|
width: var(--name-width);
|
2022-07-27 15:39:29 +02:00
|
|
|
margin-inline-end: 0; /* override mx_EventTile > * */
|
2022-06-30 00:38:23 +02:00
|
|
|
order: 2;
|
|
|
|
flex-shrink: 0;
|
|
|
|
|
|
|
|
> .mx_DisambiguatedProfile_displayName {
|
|
|
|
width: 100%;
|
|
|
|
text-align: end;
|
|
|
|
overflow: hidden;
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
}
|
|
|
|
|
|
|
|
> .mx_DisambiguatedProfile_mxid {
|
|
|
|
visibility: collapse;
|
2022-07-27 15:39:29 +02:00
|
|
|
/* Override the inherited margin. */
|
2022-06-30 00:38:23 +02:00
|
|
|
margin-left: 0;
|
|
|
|
padding: 0 5px;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
overflow: visible;
|
|
|
|
z-index: 10;
|
|
|
|
|
|
|
|
> .mx_DisambiguatedProfile_displayName {
|
|
|
|
overflow: visible;
|
|
|
|
display: inline;
|
|
|
|
background-color: $event-selected-color;
|
|
|
|
border-radius: 8px 0 0 8px;
|
|
|
|
padding-right: 8px;
|
|
|
|
}
|
|
|
|
|
|
|
|
> .mx_DisambiguatedProfile_mxid {
|
|
|
|
visibility: visible;
|
|
|
|
opacity: 1;
|
|
|
|
background-color: $event-selected-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-06-25 19:49:34 +02:00
|
|
|
.mx_EventTile_e2eIcon {
|
2020-04-29 16:07:41 +02:00
|
|
|
padding: 0;
|
2020-06-11 12:44:11 +02:00
|
|
|
|
2020-05-26 19:15:06 +02:00
|
|
|
flex-shrink: 0;
|
|
|
|
flex-grow: 0;
|
2020-06-11 12:44:11 +02:00
|
|
|
|
|
|
|
height: $font-18px;
|
|
|
|
|
|
|
|
background-position: center;
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
|
2020-05-07 14:55:23 +02:00
|
|
|
.mx_EventTile_line {
|
|
|
|
.mx_EventTile_e2eIcon,
|
|
|
|
.mx_TextualEvent,
|
2022-07-12 15:40:19 +02:00
|
|
|
.mx_ViewSourceEvent,
|
2021-05-20 16:39:25 +02:00
|
|
|
.mx_MTextBody {
|
2022-07-27 15:39:29 +02:00
|
|
|
/* add a 1px padding top and bottom because our larger
|
|
|
|
emoji font otherwise gets cropped by anti-zalgo */
|
2022-07-12 15:40:19 +02:00
|
|
|
padding: var(--EventTile_irc_line-padding-block) 0;
|
2020-05-07 14:55:23 +02:00
|
|
|
}
|
2022-07-01 13:28:57 +02:00
|
|
|
|
2023-03-01 15:41:56 +01:00
|
|
|
.mx_EventTile_e2eIcon,
|
|
|
|
.mx_TextualEvent,
|
|
|
|
.mx_MTextBody {
|
|
|
|
display: inline-block;
|
|
|
|
}
|
|
|
|
|
2022-07-01 13:28:57 +02:00
|
|
|
.mx_ReplyTile {
|
|
|
|
.mx_MTextBody {
|
2022-07-27 15:39:29 +02:00
|
|
|
display: -webkit-box; /* Enable -webkit-line-clamp */
|
2022-07-01 13:28:57 +02:00
|
|
|
}
|
|
|
|
}
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
2020-05-05 11:54:44 +02:00
|
|
|
|
|
|
|
.mx_EventTile_reply {
|
2020-05-26 19:15:06 +02:00
|
|
|
order: 4;
|
2020-05-05 11:54:44 +02:00
|
|
|
}
|
2020-05-07 14:55:23 +02:00
|
|
|
|
|
|
|
.mx_EditMessageComposer_buttons {
|
|
|
|
position: relative;
|
|
|
|
}
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
|
2020-05-08 23:21:26 +02:00
|
|
|
.mx_EventTile_emote {
|
2022-06-25 19:22:52 +02:00
|
|
|
.mx_EventTile_avatar {
|
2023-03-03 10:32:38 +01:00
|
|
|
/* add --right-padding value of MessageTimestamp only */
|
|
|
|
margin-left: calc(var(--name-width) + var(--icon-width) + 1 * var(--right-padding));
|
2020-05-08 23:21:26 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
blockquote {
|
|
|
|
margin: 0;
|
|
|
|
}
|
|
|
|
|
2020-04-29 16:07:41 +02:00
|
|
|
.mx_EventTile.mx_EventTile_info {
|
2022-07-27 15:39:29 +02:00
|
|
|
.mx_ViewSourceEvent, /* For hidden events */
|
2020-04-29 16:07:41 +02:00
|
|
|
.mx_TextualEvent {
|
2020-05-08 23:21:26 +02:00
|
|
|
line-height: $irc-line-height;
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-10-15 18:42:44 +02:00
|
|
|
.mx_ReplyChain {
|
2022-03-22 23:14:55 +01:00
|
|
|
.mx_DisambiguatedProfile {
|
2020-05-08 23:21:26 +02:00
|
|
|
width: unset;
|
2020-12-21 16:58:51 +01:00
|
|
|
background: transparent;
|
2023-03-10 11:47:14 +01:00
|
|
|
order: unset;
|
|
|
|
flex-shrink: unset; /* Unset flex-shrink to prevent long display name blowout */
|
2020-12-21 16:58:51 +01:00
|
|
|
}
|
2021-04-14 09:15:32 +02:00
|
|
|
|
|
|
|
.mx_EventTile_emote {
|
|
|
|
> .mx_EventTile_avatar {
|
|
|
|
margin-left: initial;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageTimestamp {
|
|
|
|
width: initial;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* adding the icon back in the document flow
|
|
|
|
* if it's not present, there's no unwanted wasted space
|
|
|
|
*/
|
|
|
|
.mx_EventTile_e2eIcon {
|
|
|
|
position: relative;
|
|
|
|
order: -1;
|
|
|
|
}
|
2020-05-08 23:21:26 +02:00
|
|
|
}
|
2020-05-13 03:16:43 +02:00
|
|
|
|
|
|
|
.mx_ProfileResizer {
|
2023-03-21 10:10:13 +01:00
|
|
|
--resizer-width: 15px;
|
|
|
|
--resizer-a11y: 3px; /* Magic number, to be replaced with something more proper from the perspective of a11y */
|
|
|
|
|
2020-05-13 03:16:43 +02:00
|
|
|
position: absolute;
|
|
|
|
height: 100%;
|
2023-03-21 10:10:13 +01:00
|
|
|
width: var(--resizer-width);
|
2020-05-13 03:16:43 +02:00
|
|
|
cursor: col-resize;
|
|
|
|
z-index: 100;
|
2023-03-21 10:10:13 +01:00
|
|
|
|
|
|
|
/* Add width of every element rendered before the resizer (including padding for the avatar and the display
|
|
|
|
name), subtracting the resizer width itself to prevent the resizer from overlapping the text and moving
|
|
|
|
the resizer a bit to the left to make it easier to avoid selecting the resizer when highlighting text.
|
|
|
|
Please note that MessageTimestamp does not have inline padding. */
|
|
|
|
inset-inline-start: calc(
|
|
|
|
var(--RoomView_MessageList-padding) + var(--MessageTimestamp-width) + var(--icon-width) +
|
|
|
|
var(--right-padding) + var(--name-width) + var(--right-padding) - var(--resizer-width) -
|
|
|
|
var(--resizer-a11y)
|
|
|
|
);
|
2020-05-13 03:16:43 +02:00
|
|
|
}
|
2020-04-29 16:07:41 +02:00
|
|
|
}
|