session-desktop/stylesheets/_session_conversation.scss

589 lines
11 KiB
SCSS
Raw Normal View History

2020-02-28 01:48:21 +01:00
@keyframes toShadow {
from {
opacity: 1;
}
to {
opacity: 0.25;
}
}
@keyframes fromShadow {
from {
opacity: 0.25;
}
to {
opacity: 1;
}
}
2020-03-05 07:03:22 +01:00
@keyframes pulseLight {
0% {
box-shadow: 0px 0px 0px 0px $session-color-danger-alt;
}
50% {
box-shadow: 0px 0px 12px 0px rgba($session-color-danger-alt, 1);
}
100% {
box-shadow: 0px 0px 0px 0px rgba($session-color-danger-alt, 1);
}
}
.conversation-item__options-pane {
position: absolute;
2020-02-19 02:05:48 +01:00
height: 100%;
right: 0vw;
2020-03-12 07:15:02 +01:00
2021-07-14 05:48:59 +02:00
transition: transform 0.3s ease-in-out;
transform: translateX(100%);
will-change: transform;
width: 25vw;
2021-07-14 05:48:59 +02:00
z-index: 1;
2020-02-28 01:48:21 +01:00
&.show {
transform: none;
2021-07-14 05:48:59 +02:00
transition: transform 0.3s ease-in-out;
z-index: 2;
2020-03-17 08:29:17 +01:00
}
2020-02-28 01:48:21 +01:00
}
.conversation-header {
2020-03-12 07:15:02 +01:00
&--items-wrapper {
2020-02-28 01:48:21 +01:00
display: flex;
flex-grow: 1;
align-items: center;
justify-content: center;
width: 100%;
2020-02-28 01:48:21 +01:00
}
.message-selection-overlay {
position: absolute;
display: flex;
left: 0px;
right: 0px;
2020-07-21 06:43:46 +02:00
padding: 0px $session-margin-md;
2020-02-28 01:48:21 +01:00
align-items: center;
justify-content: space-between;
height: $main-view-header-height;
@include themify($themes) {
background: themed('cellBackground');
}
2020-03-12 07:15:02 +01:00
2020-02-28 01:48:21 +01:00
.close-button {
float: left;
}
2020-03-12 07:15:02 +01:00
2020-02-28 01:48:21 +01:00
.session-button.default.danger {
display: flex;
}
}
.message-selection-overlay div[role='button'] {
display: inline-block;
}
2020-03-12 07:15:02 +01:00
2020-02-28 01:48:21 +01:00
.message-selection-overlay .button-group {
float: right;
}
}
2020-11-13 04:29:59 +01:00
.session-conversation {
flex-grow: 1;
display: flex;
flex-direction: column;
max-width: calc(100vw - 380px);
.selection-mode {
.messages-container > *:not(.message-selected) {
animation: toShadow $session-transition-duration;
opacity: 0.25;
}
}
}
2020-07-20 09:30:26 +02:00
.conversation-content {
display: flex;
flex-grow: 1;
flex-direction: column;
position: relative;
2020-07-21 06:43:46 +02:00
outline: none;
2020-07-20 09:30:26 +02:00
.conversation-messages {
display: flex;
flex-direction: column;
flex-grow: 1;
width: 100%;
2020-07-21 06:43:46 +02:00
height: 0;
2020-07-20 09:30:26 +02:00
background-color: inherit;
2020-07-21 06:43:46 +02:00
outline: none;
2020-07-21 08:40:17 +02:00
position: relative;
2020-07-21 06:43:46 +02:00
2020-10-09 04:30:10 +02:00
@include themify($themes) {
border-left: themed('sessionBorder');
border-top: themed('sessionBorder');
}
2020-07-21 06:43:46 +02:00
&__blocking-overlay {
background-color: rgba(0, 0, 0, 0.8);
position: absolute;
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
}
2020-07-20 09:30:26 +02:00
}
.conversation-info-panel {
position: absolute;
justify-content: flex-start;
flex-direction: column;
align-items: center;
height: 100%;
width: 100%;
z-index: 5; // to be sure to hide the borders of images in messages
2020-07-20 09:30:26 +02:00
background-color: inherit;
display: none;
padding: 20px;
&.show {
display: flex;
@include themify($themes) {
background: themed('inboxBackground');
}
2020-07-20 09:30:26 +02:00
}
}
}
2020-02-19 02:05:48 +01:00
.messages-container {
display: flex;
flex-grow: 1;
flex-direction: column-reverse;
2020-02-25 01:29:44 +01:00
position: relative;
2020-07-17 08:38:51 +02:00
overflow-x: hidden;
min-width: 370px;
2020-02-19 03:54:59 +01:00
scrollbar-width: 4px;
2020-07-21 09:37:34 +02:00
padding: $session-margin-sm $session-margin-lg $session-margin-lg;
}
2020-07-16 08:39:35 +02:00
.session-message-wrapper {
letter-spacing: 0.03em;
margin-top: 3px;
margin-bottom: 3px;
display: flex;
2020-07-16 08:39:35 +02:00
}
.composition-container {
2020-02-19 02:05:48 +01:00
display: flex;
justify-content: center;
align-items: center;
padding: 0px $session-margin-md;
2020-02-27 02:01:08 +01:00
min-height: min-content;
2020-10-09 04:30:10 +02:00
@include themify($themes) {
background: themed('composeViewBackground');
2020-10-15 02:18:37 +02:00
border-top: themed('sessionBorder');
2020-10-09 04:30:10 +02:00
}
2020-02-19 02:05:48 +01:00
& > .session-icon-button {
margin-right: $session-margin-sm;
}
.session-icon-button {
2020-02-27 06:29:01 +01:00
display: flex;
justify-content: center;
align-items: center;
2020-02-19 02:05:48 +01:00
opacity: 0.8;
.send {
padding: $session-margin-xs;
border-radius: 50%;
height: 30px;
width: 30px;
}
}
.send-message-input {
2020-07-20 09:30:26 +02:00
cursor: text;
display: flex;
2020-07-17 05:46:46 +02:00
align-items: center;
2020-02-19 02:05:48 +01:00
flex-grow: 1;
min-height: $composition-container-height;
2020-07-20 09:30:26 +02:00
padding: $session-margin-md 0;
2020-02-19 02:05:48 +01:00
textarea {
2020-04-27 04:41:02 +02:00
font-family: $session-font-default;
2020-02-19 02:05:48 +01:00
min-height: $composition-container-height / 3;
2020-07-17 05:46:46 +02:00
max-height: 3 * $composition-container-height;
2020-02-19 02:05:48 +01:00
margin-right: $session-margin-md;
2020-10-09 04:30:10 +02:00
@include themify($themes) {
color: themed('textColor');
}
background: transparent;
2020-02-19 02:05:48 +01:00
resize: none;
display: flex;
flex-grow: 1;
2020-02-19 02:05:48 +01:00
outline: none;
border: none;
2020-07-17 03:05:27 +02:00
font-size: 14px;
2020-02-19 02:05:48 +01:00
line-height: $session-font-h2;
letter-spacing: 0.5px;
}
2020-07-22 06:03:24 +02:00
&__emoji-overlay {
// Should have identical properties to the textarea above to line up perfectly.
position: absolute;
font-size: 14px;
font-family: $session-font-default;
margin-left: 2px;
line-height: $session-font-h2;
letter-spacing: 0.5px;
2020-07-24 03:16:40 +02:00
color: rgba(0, 0, 0, 0);
2020-07-22 06:03:24 +02:00
}
2020-02-19 02:05:48 +01:00
}
}
.session-emoji-panel {
position: absolute;
2020-02-27 00:01:18 +01:00
bottom: 68px;
right: 0px;
padding: $session-margin-lg;
2020-03-12 07:15:02 +01:00
z-index: 5;
opacity: 0;
visibility: hidden;
transition: $session-transition-duration;
button:focus {
outline: none;
}
&.show {
opacity: 1;
visibility: visible;
}
2020-03-13 01:10:27 +01:00
& > section.emoji-mart {
2020-07-17 04:07:06 +02:00
font-family: $session-font-default;
font-size: $session-font-sm;
2020-03-12 07:15:02 +01:00
background-color: $session-shade-4;
border: 1px solid $session-shade-6-alt;
2020-03-13 01:10:27 +01:00
border-radius: 8px;
2020-03-13 04:28:52 +01:00
padding-bottom: $session-margin-sm;
2020-03-13 01:10:27 +01:00
2020-03-12 07:15:02 +01:00
.emoji-mart-category-label {
top: -2px;
2020-03-13 01:10:27 +01:00
2020-03-12 07:15:02 +01:00
span {
2020-04-27 04:41:02 +02:00
font-family: $session-font-default;
2020-03-12 07:15:02 +01:00
padding-top: $session-margin-sm;
background-color: $session-shade-4;
}
}
2020-03-13 01:10:27 +01:00
2020-07-17 04:07:06 +02:00
.emoji-mart-scroll {
height: 340px;
}
.emoji-mart-category .emoji-mart-emoji span {
cursor: pointer;
}
2020-03-13 01:10:27 +01:00
.emoji-mart-bar:last-child {
border: none;
2020-07-08 09:12:34 +02:00
.emoji-mart-preview {
2020-03-13 01:10:27 +01:00
display: none;
}
}
2020-07-08 09:12:34 +02:00
&:after {
2020-03-13 01:10:27 +01:00
content: '';
position: absolute;
top: calc(100% - 40px);
left: calc(100% - 79px);
width: 22px;
height: 22px;
background-color: $session-shade-4;
transform: rotate(45deg);
border-radius: 3px;
transform: scaleY(1.4) rotate(45deg);
border: 0.7px solid $session-shade-6-alt;
clip-path: polygon(100% 100%, 7.2px 100%, 100% 7.2px);
}
2020-03-12 07:15:02 +01:00
}
}
2020-02-19 02:05:48 +01:00
.session-progress {
position: relative;
2020-03-18 07:40:36 +01:00
z-index: 100;
2020-02-19 02:05:48 +01:00
&__progress {
2020-03-18 07:40:36 +01:00
will-change: transform;
2020-07-08 09:12:34 +02:00
2020-03-18 07:40:36 +01:00
width: 100%;
2020-02-19 02:05:48 +01:00
position: absolute;
left: 0px;
font-size: 0px;
2020-03-25 00:01:36 +01:00
height: 1px;
2020-02-19 02:05:48 +01:00
background-color: $session-color-green;
2020-03-18 07:40:36 +01:00
&.fade {
opacity: 0;
}
2020-02-19 02:05:48 +01:00
}
2020-02-27 00:01:18 +01:00
}
2020-02-27 06:29:01 +01:00
.session-recording {
height: $composition-container-height;
display: flex;
justify-content: space-between;
align-items: center;
flex-grow: 1;
2020-03-12 04:11:15 +01:00
outline: none;
2020-02-27 06:29:01 +01:00
$actions-element-size: 45px;
&--actions {
display: flex;
align-items: center;
justify-content: center;
width: $actions-element-size;
height: $actions-element-size;
border-radius: 50%;
.session-icon-button {
animation: fadein $session-transition-duration;
opacity: 1;
border-radius: 50%;
width: $actions-element-size;
height: $actions-element-size;
.play {
margin-left: 4px;
}
}
}
2020-02-28 03:15:00 +01:00
&--visualisation {
z-index: 2;
2020-02-28 03:15:00 +01:00
width: 100%;
2020-03-03 05:07:48 +01:00
display: flex;
align-items: center;
justify-content: center;
2020-03-06 05:03:07 +01:00
position: relative;
2020-03-03 05:34:02 +01:00
canvas {
2020-03-06 05:03:07 +01:00
position: absolute;
2020-03-03 06:00:54 +01:00
width: 100%;
padding: 0px $session-margin-lg;
2020-03-03 05:34:02 +01:00
}
2020-02-28 03:15:00 +01:00
}
2020-03-05 00:43:48 +01:00
&--status {
2020-02-27 06:29:01 +01:00
display: flex;
justify-content: center;
position: absolute;
left: 0;
2020-12-08 01:42:40 +01:00
z-index: 2;
2020-02-27 06:29:01 +01:00
right: 0;
bottom: $composition-container-height + $session-margin-md;
2020-03-12 07:15:02 +01:00
.session-button {
2020-02-27 06:29:01 +01:00
display: flex;
justify-content: center;
align-items: center;
width: 173px;
font-weight: 300;
2020-04-27 04:41:02 +02:00
font-family: $session-font-default;
2020-03-12 07:15:02 +01:00
2020-03-05 00:43:48 +01:00
&.primary {
cursor: default;
user-select: none;
2020-03-12 07:15:02 +01:00
&:hover {
2020-03-05 00:43:48 +01:00
filter: brightness(100%);
2020-03-05 07:03:22 +01:00
border: 2px solid #161819;
2020-03-05 00:43:48 +01:00
}
2020-03-05 07:03:22 +01:00
background-color: $session-shade-1-alt;
border: 2px solid #161819;
2020-03-05 00:43:48 +01:00
}
}
}
&--timer {
display: inline-flex;
align-items: center;
2020-04-27 04:41:02 +02:00
font-family: $session-font-default;
2020-03-05 00:43:48 +01:00
font-weight: bold;
font-size: 14px;
flex-shrink: 0;
2020-03-05 00:43:48 +01:00
2020-03-12 04:11:15 +01:00
&.playback-timer {
margin-right: $session-margin-sm;
}
2020-03-12 07:15:02 +01:00
&-light {
2020-03-05 00:43:48 +01:00
height: $session-margin-sm;
width: $session-margin-sm;
border-radius: 50%;
background-color: $session-color-danger-alt;
margin-left: $session-margin-sm;
2020-03-05 07:03:22 +01:00
animation: pulseLight 4s infinite;
2020-02-27 06:29:01 +01:00
}
}
2020-03-12 04:11:15 +01:00
}
2020-07-16 08:39:35 +02:00
2020-07-16 10:14:08 +02:00
// box-sizing: border-box;
// position: absolute;
// z-index: 3;
// width: 4px;
// height: 5px;
// margin-left: 0px;
// top: 0px;
// background: #00f782;
// border-radius: 50px;
2020-07-16 08:39:35 +02:00
/* ************ */
/* AUDIO PLAYER */
/* ************ */
$rhap_theme-color: #212121 !default;
2020-07-16 10:14:08 +02:00
$rhap_background-color: rgba(0, 0, 0, 0) !default;
2020-07-16 08:39:35 +02:00
$rhap_font-family: inherit !default;
2020-07-16 10:14:08 +02:00
.rhap_container,
.rhap_container button,
.rhap_progress-container {
2020-07-16 08:39:35 +02:00
outline: none;
}
2020-07-16 10:14:08 +02:00
.rhap_progress-container {
margin: 0 0 0 calc(10px + 1%);
}
2020-07-16 08:39:35 +02:00
.rhap_container {
min-width: 220px;
2020-07-16 10:14:08 +02:00
padding: 0px;
background-color: transparent;
box-shadow: none;
2020-07-17 03:05:27 +02:00
svg {
transition: fill $session-transition-duration;
&:hover path {
2020-07-20 09:30:26 +02:00
fill: #ffffff;
2020-07-17 03:05:27 +02:00
}
}
2020-07-16 08:39:35 +02:00
}
2020-07-16 10:14:08 +02:00
.rhap_total-time {
2020-07-16 08:39:35 +02:00
display: none;
}
2020-07-16 10:14:08 +02:00
.rhap_current-time {
2020-07-17 03:05:27 +02:00
margin: 0 5px 0 4px;
flex-shrink: 0;
2020-07-16 08:39:35 +02:00
}
.rhap_play-pause-button {
display: flex;
justify-content: center;
align-items: center;
}
.rhap_volume-bar {
display: none;
}
.rhap_volume-button {
@include themify($themes) {
color: subtle(themed('textColor'));
}
}
2020-07-16 10:14:08 +02:00
.rhap_volume-container div[role='progressbar'] {
display: none;
2020-07-16 08:39:35 +02:00
}
.rhap_time {
@include themify($themes) {
color: subtle(themed('textColor'));
}
2020-07-16 08:39:35 +02:00
font-size: 12px;
}
.rhap_progress-bar {
box-sizing: border-box;
position: relative;
z-index: 0;
width: 100%;
height: 5px;
@include themify($themes) {
background-color: rgba(themed('textColor'), 0.3);
}
2020-07-16 08:39:35 +02:00
border-radius: 2px;
}
.rhap_progress-filled {
@include themify($themes) {
background-color: rgba(themed('accent'), 0.6);
}
2020-07-17 03:05:27 +02:00
padding-left: 5px;
}
// special case for light theme, outgoing message (accent color on accent color background is not readable)
.light-theme .module-message--outgoing {
.rhap_progress-filled {
@include themify($themes) {
background-color: rgba(themed('textColor'), 0.6);
}
}
2020-07-16 08:39:35 +02:00
}
.rhap_download-progress {
height: 100%;
position: absolute;
z-index: 1;
@include themify($themes) {
background-color: subtle(themed('textColor'));
}
2020-07-16 08:39:35 +02:00
border-radius: 2px;
}
.rhap_progress-indicator {
2020-07-17 03:05:27 +02:00
z-index: 3;
width: 15px;
height: 15px;
top: -5px;
margin-left: -10px;
background: $session-color-green;
box-shadow: none;
2020-07-20 09:30:26 +02:00
box-shadow: rgba($rhap_theme-color, 0.5) 0 0 5px;
2020-07-16 08:39:35 +02:00
}
.rhap_controls-section {
display: flex;
justify-content: space-between;
align-items: center;
}
.rhap_additional-controls {
display: none;
}
2020-07-16 10:14:08 +02:00
.rhap_play-pause-button {
width: unset;
height: unset;
2020-07-16 08:39:35 +02:00
}
2020-07-16 10:14:08 +02:00
.rhap_controls-section {
flex: unset;
justify-content: flex-start;
2020-07-16 08:39:35 +02:00
}
.rhap_volume-button {
font-size: 20px;
2020-07-16 10:14:08 +02:00
width: 20px;
height: 20px;
margin-right: 0px;
2020-07-16 08:39:35 +02:00
}
/* **************** */
/* END AUDIO PLAYER */
2020-07-16 10:14:08 +02:00
/* **************** */