webapp/src/styles/Inbox.scss

273 lines
4.2 KiB
SCSS
Raw Normal View History

2022-09-09 11:53:35 +00:00
main {
display: flex;
2022-11-09 12:20:13 +00:00
height: 100vh;
2022-09-09 11:53:35 +00:00
flex-direction: column;
position: relative;
}
2022-11-15 14:24:50 +00:00
2022-09-09 11:53:35 +00:00
.messages {
2022-11-11 04:34:18 +00:00
top: 74px;
height: calc(100% - 74px);
2022-11-09 12:20:13 +00:00
left: 0;
right: 0;
2022-11-11 04:34:18 +00:00
padding-left: 42px;
padding-right: 26px;
2022-11-09 12:20:13 +00:00
background: #fff;
2022-09-09 11:53:35 +00:00
display: flex;
flex: 1;
flex-direction: column;
2022-11-09 12:20:13 +00:00
position: fixed;
2022-11-14 09:50:27 +00:00
z-index: 9;
2022-09-09 11:53:35 +00:00
2022-11-24 06:52:31 +00:00
.row {
2022-09-09 11:53:35 +00:00
flex: 1;
}
.author__name {
font-weight: 500;
}
.author {
position: relative;
}
}
2022-11-15 14:24:50 +00:00
2022-11-11 04:34:18 +00:00
// список диалогов и юзеров
2022-09-09 11:53:35 +00:00
.chat-list {
display: flex;
flex-direction: column;
2022-11-10 15:58:43 +00:00
padding: 10px;
2022-11-11 04:34:18 +00:00
height: calc(100% - 10px);
2022-09-09 11:53:35 +00:00
2022-11-11 04:34:18 +00:00
$fade-height: 10px;
2022-11-15 14:24:50 +00:00
2022-11-11 04:34:18 +00:00
.holder {
overflow: hidden;
flex: 1;
2022-11-10 15:06:02 +00:00
position: relative;
2022-11-11 04:34:18 +00:00
padding: $fade-height 0;
&::before,
&::after {
content: '';
position: absolute;
width: 100%;
right: 10px;
z-index: 1;
height: $fade-height;
}
&::before {
top: 0;
background: linear-gradient(white, transparent $fade-height);
}
2022-11-15 14:24:50 +00:00
2022-11-11 04:34:18 +00:00
&::after {
bottom: 0;
background: linear-gradient(transparent, white $fade-height);
}
.dialogs {
scroll-behavior: smooth;
display: flex;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
height: 100%;
overflow: auto;
flex-direction: column;
box-sizing: border-box;
}
2022-09-09 11:53:35 +00:00
}
}
.chat-list__search,
.interlocutor {
border-bottom: 3px solid #141414;
padding: 1em 0;
}
2022-11-11 04:34:18 +00:00
// табы выбора списка
2022-09-09 11:53:35 +00:00
.chat-list__types {
@include font-size(1.7rem);
2022-11-15 14:24:50 +00:00
2022-11-11 04:34:18 +00:00
margin: 16px 0;
2022-11-15 14:24:50 +00:00
2022-09-09 11:53:35 +00:00
ul {
display: flex;
flex-wrap: wrap;
list-style: none;
margin: 0;
padding: 0;
}
li {
margin-right: 1em;
}
strong {
border-bottom: 3px solid;
font-weight: normal;
}
}
.interlocutor {
height: 56px;
box-sizing: content-box;
.circlewrap {
height: 56px;
max-width: 56px;
width: 56px;
}
.author {
margin-bottom: 0;
&::before {
left: 40px !important;
height: 8px !important;
width: 8px !important;
}
}
.author__name {
@include font-size(1.7rem);
margin: 0.4em 0 0;
}
.author__details,
.user-status {
margin-left: 6.8rem;
}
.user-status {
@include font-size(1.2rem);
color: #ccc;
}
}
.conversation {
display: flex;
flex-direction: column;
}
.conversation__messages {
flex: 1;
overflow: auto;
position: relative;
}
2022-11-16 04:56:15 +00:00
.message-form {
background: #fff;
padding: 2px 0 12px 0;
2022-09-09 11:53:35 +00:00
2022-11-24 06:52:31 +00:00
.wrapper {
2022-11-16 04:56:15 +00:00
border: 2px solid #cccccc;
border-radius: 16px;
padding: 4px;
display: flex;
flex-direction: row;
align-items: center;
2022-09-09 11:53:35 +00:00
2022-11-24 06:52:31 +00:00
.grow-wrap {
2022-11-16 04:56:15 +00:00
display: grid;
width: 100%;
2022-09-09 11:53:35 +00:00
2022-11-16 04:56:15 +00:00
&::after {
content: attr(data-replicated-value) ' ';
white-space: pre-wrap;
visibility: hidden;
transition: height 1.3s ease-in-out;
}
2022-11-24 06:52:31 +00:00
& textarea {
2022-11-16 04:56:15 +00:00
margin-bottom: 0;
font-family: inherit;
border: none;
resize: none;
overflow: hidden;
&:focus,
&:focus-visible,
&:active {
border: none;
outline: none;
box-shadow: none;
}
}
2022-09-09 11:53:35 +00:00
2022-11-16 04:56:15 +00:00
&::after,
2022-11-24 06:52:31 +00:00
& textarea {
2022-11-16 04:56:15 +00:00
/* Identical styling required!! */
font-weight: 400;
font-size: 14px;
line-height: 20px;
padding: 8px;
grid-area: 1 / 1 / 2 / 2;
width: 100%;
2022-09-09 11:53:35 +00:00
}
}
2022-11-24 06:52:31 +00:00
button {
2022-11-16 04:56:15 +00:00
border: none;
cursor: pointer;
text-align: center;
width: 20px;
height: 20px;
margin: auto 8px 8px 0;
&:hover {
.icon {
opacity: 0.5;
}
}
2022-11-24 06:52:31 +00:00
.icon {
2022-11-16 04:56:15 +00:00
width: 100%;
height: 100%;
opacity: 0.2;
transition: opacity 0.3s;
}
2022-09-09 11:53:35 +00:00
}
}
}
.conversation__messages-container {
left: 0;
height: 100%;
overflow: auto;
position: absolute;
top: 0;
width: 100%;
2022-11-09 12:20:13 +00:00
scroll-behavior: smooth;
2022-09-09 11:53:35 +00:00
}
.conversation__date {
position: relative;
text-align: center;
&::before {
background: #141414;
content: '';
height: 1px;
left: 0;
position: absolute;
top: 0.8em;
width: 100%;
z-index: -1;
}
time {
background: #fff;
@include font-size(1.5rem);
color: #9fa1a7;
padding: 0 0.5em;
}
}