2018-04-11 23:23:35 +00:00
|
|
|
/*
|
|
|
|
Copyright 2015, 2016 OpenMarket Ltd
|
2018-08-21 14:56:56 +00:00
|
|
|
Copyright 2018 New Vector Ltd
|
2018-04-11 23:23:35 +00:00
|
|
|
|
|
|
|
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.
|
|
|
|
*/
|
|
|
|
|
|
|
|
.mx_MessageComposer_wrapper {
|
|
|
|
vertical-align: middle;
|
|
|
|
margin: auto;
|
|
|
|
border-top: 1px solid $primary-hairline-color;
|
|
|
|
position: relative;
|
|
|
|
|
2022-06-07 07:28:29 +00:00
|
|
|
display: grid;
|
|
|
|
grid-template:
|
|
|
|
"reply reply" auto
|
|
|
|
"composer controls" auto
|
|
|
|
/ 1fr auto;
|
2018-08-21 14:56:56 +00:00
|
|
|
|
2022-06-07 07:28:29 +00:00
|
|
|
.mx_ReplyPreview {
|
|
|
|
grid-area: reply;
|
|
|
|
}
|
2018-08-21 14:56:56 +00:00
|
|
|
|
2022-06-07 07:28:29 +00:00
|
|
|
.mx_MessageComposer_row {
|
|
|
|
grid-area: composer;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_controls {
|
|
|
|
grid-area: controls;
|
|
|
|
display: flex;
|
|
|
|
align-items: flex-end;
|
|
|
|
margin-bottom: 2px;
|
|
|
|
}
|
|
|
|
|
|
|
|
>[role=button] {
|
|
|
|
margin-bottom: 7px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_VoiceRecordComposerTile_delete {
|
|
|
|
margin-bottom: 9px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_VoiceRecordComposerTile_stop,
|
|
|
|
.mx_MessageComposer_sendMessage {
|
|
|
|
margin-bottom: $spacing-4;
|
|
|
|
}
|
2018-08-21 14:56:56 +00:00
|
|
|
|
2022-06-07 07:28:29 +00:00
|
|
|
.mx_VoiceMessagePrimaryContainer {
|
|
|
|
margin-right: $spacing-8;
|
|
|
|
}
|
2018-08-21 14:56:56 +00:00
|
|
|
}
|
|
|
|
|
2018-04-11 23:23:35 +00:00
|
|
|
.mx_MessageComposer_autocomplete_wrapper {
|
|
|
|
position: relative;
|
|
|
|
height: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_row {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
align-items: center;
|
2022-06-07 07:28:29 +00:00
|
|
|
border: 1px solid $quaternary-content;
|
|
|
|
border-radius: 12px;
|
|
|
|
padding: $spacing-12 $spacing-8;
|
|
|
|
margin-right: $spacing-16;
|
|
|
|
|
|
|
|
transition: border-color var(--transition-short);
|
|
|
|
|
|
|
|
&[data-notice=true] {
|
|
|
|
border-color: transparent;
|
|
|
|
color: $secondary-content;
|
|
|
|
|
|
|
|
p {
|
|
|
|
margin: 0;
|
|
|
|
line-height: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
svg {
|
|
|
|
vertical-align: middle;
|
|
|
|
position: relative;
|
|
|
|
top: -2px;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&:focus-within {
|
|
|
|
border-color: $tertiary-content;
|
|
|
|
}
|
|
|
|
|
|
|
|
&[aria-disabled=true] {
|
|
|
|
cursor: not-allowed;
|
|
|
|
}
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer .mx_MessageComposer_avatar {
|
2019-01-31 14:13:18 +00:00
|
|
|
position: absolute;
|
2020-07-13 20:15:58 +00:00
|
|
|
left: 26px;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer .mx_MessageComposer_avatar .mx_BaseAvatar {
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_composecontrols {
|
|
|
|
width: 100%;
|
|
|
|
}
|
|
|
|
|
2019-02-01 12:40:42 +00:00
|
|
|
.mx_MessageComposer_e2eIcon.mx_E2EIcon {
|
2022-06-07 07:28:29 +00:00
|
|
|
margin: 0 0 2px;
|
2020-07-13 22:56:25 +00:00
|
|
|
width: 12px;
|
|
|
|
height: 12px;
|
2022-06-07 07:28:29 +00:00
|
|
|
align-self: end;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_noperm_error {
|
|
|
|
font-style: italic;
|
2022-06-07 07:28:29 +00:00
|
|
|
color: $tertiary-content;
|
|
|
|
font-size: $font-12px;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_input_wrapper {
|
|
|
|
flex: 1;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
2018-06-23 15:40:53 +00:00
|
|
|
cursor: text;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_input {
|
|
|
|
flex: 1;
|
|
|
|
vertical-align: middle;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
min-height: 60px;
|
2019-12-23 03:56:19 +00:00
|
|
|
justify-content: flex-start;
|
2018-04-11 23:23:35 +00:00
|
|
|
align-items: flex-start;
|
2020-03-31 14:26:23 +00:00
|
|
|
font-size: $font-14px;
|
2018-04-11 23:23:35 +00:00
|
|
|
margin-right: 6px;
|
|
|
|
}
|
|
|
|
|
2018-05-06 00:18:26 +00:00
|
|
|
.mx_MessageComposer_editor {
|
|
|
|
width: 100%;
|
|
|
|
max-height: 120px;
|
2018-05-08 00:54:06 +00:00
|
|
|
min-height: 19px;
|
2019-01-30 11:53:15 +00:00
|
|
|
overflow-y: auto;
|
|
|
|
overflow-x: hidden;
|
2018-05-23 00:43:03 +00:00
|
|
|
word-break: break-word;
|
2018-05-06 00:18:26 +00:00
|
|
|
}
|
|
|
|
|
2018-05-19 19:28:38 +00:00
|
|
|
// FIXME: rather unpleasant hack to get rid of <p/> margins.
|
|
|
|
// really we should be mixing in markdown-body from gfm.css instead
|
|
|
|
.mx_MessageComposer_editor > :first-child {
|
2019-07-09 17:15:10 +00:00
|
|
|
margin-top: 0 !important;
|
2018-05-19 19:28:38 +00:00
|
|
|
}
|
2022-06-07 07:28:29 +00:00
|
|
|
|
2018-05-19 19:28:38 +00:00
|
|
|
.mx_MessageComposer_editor > :last-child {
|
2019-07-09 17:15:10 +00:00
|
|
|
margin-bottom: 0 !important;
|
2018-05-19 19:28:38 +00:00
|
|
|
}
|
|
|
|
|
2019-07-09 17:15:10 +00:00
|
|
|
@keyframes visualbell {
|
2022-06-07 07:28:29 +00:00
|
|
|
from {
|
|
|
|
background-color: $visual-bell-bg-color;
|
|
|
|
}
|
|
|
|
|
|
|
|
to {
|
|
|
|
background-color: $background;
|
|
|
|
}
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_input_error {
|
|
|
|
animation: 0.2s visualbell;
|
|
|
|
}
|
|
|
|
|
2018-05-23 00:43:03 +00:00
|
|
|
.mx_MessageComposer_input pre {
|
2018-04-11 23:23:35 +00:00
|
|
|
background-color: $rte-code-bg-color;
|
|
|
|
border-radius: 3px;
|
|
|
|
padding: 10px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_input textarea {
|
|
|
|
display: block;
|
|
|
|
width: 100%;
|
|
|
|
padding: 0px;
|
|
|
|
margin-top: 6px;
|
|
|
|
margin-bottom: 6px;
|
|
|
|
border: 0px;
|
|
|
|
resize: none;
|
|
|
|
outline: none;
|
|
|
|
box-shadow: none;
|
2021-08-12 09:27:12 +00:00
|
|
|
color: $primary-content;
|
2021-08-12 09:10:47 +00:00
|
|
|
background-color: $background;
|
2020-03-31 14:26:23 +00:00
|
|
|
font-size: $font-14px;
|
2018-04-11 23:23:35 +00:00
|
|
|
max-height: 120px;
|
|
|
|
overflow: auto;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* hack for FF as vertical alignment of custom placeholder text is broken */
|
|
|
|
.mx_MessageComposer_input textarea::-moz-placeholder {
|
|
|
|
line-height: 100%;
|
2021-11-11 13:37:29 +00:00
|
|
|
color: $accent;
|
2018-04-11 23:23:35 +00:00
|
|
|
opacity: 1.0;
|
|
|
|
}
|
2022-06-07 07:28:29 +00:00
|
|
|
|
2018-04-11 23:23:35 +00:00
|
|
|
.mx_MessageComposer_input textarea::-webkit-input-placeholder {
|
2021-11-11 13:37:29 +00:00
|
|
|
color: $accent;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
2020-07-28 16:13:58 +00:00
|
|
|
.mx_MessageComposer_button_highlight {
|
2021-11-11 13:37:29 +00:00
|
|
|
background: rgba($accent, 0.25);
|
2022-06-07 07:28:29 +00:00
|
|
|
|
2020-07-28 16:13:58 +00:00
|
|
|
// make the icon the accent color too
|
|
|
|
&::before {
|
2021-11-11 13:37:29 +00:00
|
|
|
background-color: $accent !important;
|
2020-07-28 16:13:58 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-02-12 18:05:19 +00:00
|
|
|
.mx_MessageComposer_button {
|
2021-09-07 16:10:09 +00:00
|
|
|
--size: 26px;
|
2019-11-01 14:46:30 +00:00
|
|
|
position: relative;
|
2018-04-11 23:23:35 +00:00
|
|
|
cursor: pointer;
|
2021-09-07 16:10:09 +00:00
|
|
|
height: var(--size);
|
|
|
|
line-height: var(--size);
|
|
|
|
width: auto;
|
2021-09-22 10:55:25 +00:00
|
|
|
padding-left: var(--size);
|
2022-05-04 15:22:09 +00:00
|
|
|
border-radius: 50%;
|
|
|
|
margin-right: 6px;
|
2022-06-07 07:28:29 +00:00
|
|
|
margin-bottom: 7px;
|
2021-09-22 10:55:25 +00:00
|
|
|
|
2022-05-04 15:22:09 +00:00
|
|
|
&:last-child {
|
|
|
|
margin-right: auto;
|
2021-09-22 10:55:25 +00:00
|
|
|
}
|
2019-11-01 14:46:30 +00:00
|
|
|
|
|
|
|
&::before {
|
|
|
|
content: '';
|
|
|
|
position: absolute;
|
2020-07-28 12:19:11 +00:00
|
|
|
top: 3px;
|
|
|
|
left: 3px;
|
2019-11-01 14:46:30 +00:00
|
|
|
height: 20px;
|
|
|
|
width: 20px;
|
2020-07-28 12:19:11 +00:00
|
|
|
background-color: $icon-button-color;
|
2019-11-01 14:46:30 +00:00
|
|
|
mask-repeat: no-repeat;
|
|
|
|
mask-size: contain;
|
|
|
|
mask-position: center;
|
|
|
|
}
|
2020-07-08 15:30:50 +00:00
|
|
|
|
2021-09-07 16:10:09 +00:00
|
|
|
&::after {
|
|
|
|
content: '';
|
|
|
|
position: absolute;
|
|
|
|
left: 0;
|
|
|
|
top: 0;
|
|
|
|
z-index: 0;
|
|
|
|
width: var(--size);
|
|
|
|
height: var(--size);
|
|
|
|
border-radius: 50%;
|
|
|
|
}
|
|
|
|
|
2021-09-09 12:27:25 +00:00
|
|
|
&:hover,
|
|
|
|
&.mx_MessageComposer_closeButtonMenu {
|
2021-09-07 16:10:09 +00:00
|
|
|
&::after {
|
2021-11-11 13:37:29 +00:00
|
|
|
background: rgba($accent, 0.1);
|
2021-09-07 16:10:09 +00:00
|
|
|
}
|
2020-07-28 12:19:11 +00:00
|
|
|
|
|
|
|
&::before {
|
2021-11-11 13:37:29 +00:00
|
|
|
background-color: $accent;
|
2020-07-28 12:19:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-09-16 20:35:50 +00:00
|
|
|
&.mx_MessageComposer_hangup:not(.mx_AccessibleButton_disabled)::before {
|
2021-11-11 13:37:29 +00:00
|
|
|
background-color: $alert;
|
2020-07-08 15:30:50 +00:00
|
|
|
}
|
2019-02-12 18:05:19 +00:00
|
|
|
}
|
|
|
|
|
2019-11-01 14:46:30 +00:00
|
|
|
.mx_MessageComposer_upload::before {
|
2020-07-03 16:03:47 +00:00
|
|
|
mask-image: url('$(res)/img/element-icons/room/composer/attach.svg');
|
2019-02-12 18:05:19 +00:00
|
|
|
}
|
|
|
|
|
2021-10-12 21:13:56 +00:00
|
|
|
.mx_MessageComposer_poll::before {
|
|
|
|
mask-image: url('$(res)/img/element-icons/room/composer/poll.svg');
|
|
|
|
}
|
|
|
|
|
2021-03-16 04:16:58 +00:00
|
|
|
.mx_MessageComposer_voiceMessage::before {
|
|
|
|
mask-image: url('$(res)/img/voip/mic-on-mask.svg');
|
|
|
|
}
|
|
|
|
|
2020-05-29 14:00:27 +00:00
|
|
|
.mx_MessageComposer_emoji::before {
|
2020-07-03 16:03:47 +00:00
|
|
|
mask-image: url('$(res)/img/element-icons/room/composer/emoji.svg');
|
2020-05-29 14:00:27 +00:00
|
|
|
}
|
|
|
|
|
2021-12-06 09:45:12 +00:00
|
|
|
.mx_MessageComposer_location::before {
|
|
|
|
mask-image: url('$(res)/img/element-icons/room/composer/location.svg');
|
|
|
|
}
|
|
|
|
|
2019-11-01 14:46:30 +00:00
|
|
|
.mx_MessageComposer_stickers::before {
|
2020-07-03 16:03:47 +00:00
|
|
|
mask-image: url('$(res)/img/element-icons/room/composer/sticker.svg');
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
2021-09-07 04:11:35 +00:00
|
|
|
.mx_MessageComposer_buttonMenu::before {
|
|
|
|
mask-image: url('$(res)/img/image-view/more.svg');
|
|
|
|
}
|
|
|
|
|
2022-06-07 07:28:29 +00:00
|
|
|
.mx_MessageComposer_sendMessageWrapper {
|
|
|
|
--sendMessageSize: 32px;
|
|
|
|
transition: all var(--transition-short);
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_sendMessageWrapper,
|
|
|
|
.mx_MessageComposer_sendMessageWrapper-enter,
|
|
|
|
.mx_MessageComposer_sendMessageWrapper-exit {
|
|
|
|
width: 0;
|
|
|
|
transform: scale(.6);
|
|
|
|
opacity: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_sendMessageWrapper-enter-active {
|
|
|
|
width: var(--sendMessageSize);
|
|
|
|
transform: scale(1);
|
|
|
|
opacity: 1;
|
|
|
|
}
|
|
|
|
|
2021-02-12 16:06:02 +00:00
|
|
|
.mx_MessageComposer_sendMessage {
|
|
|
|
cursor: pointer;
|
|
|
|
position: relative;
|
2022-06-07 07:28:29 +00:00
|
|
|
width: var(--sendMessageSize);
|
|
|
|
height: var(--sendMessageSize);
|
2021-02-12 16:06:02 +00:00
|
|
|
border-radius: 100%;
|
2021-11-11 13:37:29 +00:00
|
|
|
background-color: $accent;
|
2021-02-12 16:06:02 +00:00
|
|
|
|
2021-02-12 16:11:24 +00:00
|
|
|
&::before {
|
2021-02-12 16:06:02 +00:00
|
|
|
position: absolute;
|
|
|
|
height: 16px;
|
|
|
|
width: 16px;
|
|
|
|
top: 8px;
|
|
|
|
left: 9px;
|
|
|
|
|
|
|
|
mask-image: url('$(res)/img/element-icons/send-message.svg');
|
|
|
|
mask-repeat: no-repeat;
|
|
|
|
mask-size: contain;
|
|
|
|
mask-position: center;
|
|
|
|
|
|
|
|
background-color: $button-fg-color;
|
|
|
|
content: '';
|
|
|
|
}
|
2021-01-09 08:09:14 +00:00
|
|
|
}
|
|
|
|
|
2018-04-11 23:23:35 +00:00
|
|
|
.mx_MessageComposer_formatting {
|
|
|
|
cursor: pointer;
|
|
|
|
margin: 0 11px;
|
|
|
|
width: 24px;
|
|
|
|
height: 18px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar_wrapper {
|
|
|
|
width: 100%;
|
|
|
|
background-color: $menu-bg-color;
|
|
|
|
box-shadow: inset 0 1px 0 0 rgba(0, 0, 0, 0.08);
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar {
|
|
|
|
margin: auto;
|
|
|
|
display: flex;
|
|
|
|
|
|
|
|
height: 30px;
|
|
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
padding-left: 62px;
|
|
|
|
|
|
|
|
flex-direction: row;
|
|
|
|
align-items: center;
|
2020-03-31 14:26:23 +00:00
|
|
|
font-size: $font-10px;
|
2021-11-29 12:52:09 +00:00
|
|
|
color: $info-plinth-fg-color;
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar * {
|
|
|
|
margin-right: 4px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_format_button,
|
|
|
|
.mx_MessageComposer_formatbar_cancel,
|
|
|
|
.mx_MessageComposer_formatbar_markdown {
|
|
|
|
cursor: pointer;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar_cancel {
|
|
|
|
margin-right: 22px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar_markdown {
|
2019-02-18 18:26:40 +00:00
|
|
|
height: 17px;
|
|
|
|
width: 30px;
|
2018-04-11 23:23:35 +00:00
|
|
|
margin-right: 64px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_input_markdownIndicator {
|
|
|
|
height: 10px;
|
2019-02-18 18:26:40 +00:00
|
|
|
width: 12px;
|
2018-04-11 23:23:35 +00:00
|
|
|
padding: 4px 4px 4px 0;
|
2019-02-18 18:26:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MessageComposer_formatbar_markdown,
|
|
|
|
.mx_MessageComposer_input_markdownIndicator {
|
|
|
|
cursor: pointer;
|
|
|
|
mask-image: url('$(res)/img/markdown.svg');
|
|
|
|
mask-size: contain;
|
|
|
|
mask-position: center;
|
|
|
|
mask-repeat: no-repeat;
|
2020-07-28 12:19:11 +00:00
|
|
|
background-color: $icon-button-color;
|
2019-02-18 18:26:40 +00:00
|
|
|
|
|
|
|
&.mx_MessageComposer_markdownDisabled {
|
|
|
|
opacity: 0.2;
|
|
|
|
}
|
2018-04-11 23:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_MatrixChat_useCompactLayout {
|
|
|
|
.mx_MessageComposer_input {
|
|
|
|
min-height: 50px;
|
|
|
|
}
|
|
|
|
}
|
2021-08-20 11:11:04 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Unstable compact mode
|
|
|
|
*/
|
|
|
|
|
|
|
|
.mx_MessageComposer.mx_MessageComposer--compact {
|
|
|
|
margin-right: 0;
|
2021-08-24 08:09:28 +00:00
|
|
|
|
2021-08-20 11:11:04 +00:00
|
|
|
.mx_MessageComposer_button:last-child {
|
|
|
|
margin-right: 0;
|
|
|
|
}
|
|
|
|
}
|