2020-04-22 14:25:43 +00:00
|
|
|
|
@import (reference) "./colortheme-all.less";
|
|
|
|
|
@import (reference) "./variables.less";
|
|
|
|
|
@import (reference) "./avatar.less";
|
|
|
|
|
@import (reference) "./tools.less";
|
|
|
|
|
|
|
|
|
|
.comments_main() {
|
|
|
|
|
@data-color: #888;
|
|
|
|
|
overflow-y: auto;
|
2020-04-29 14:45:42 +00:00
|
|
|
|
color: @cryptpad_text_col;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
|
2020-06-29 15:21:11 +00:00
|
|
|
|
&:empty {
|
|
|
|
|
display: none !important;
|
|
|
|
|
}
|
|
|
|
|
|
2020-05-04 09:59:28 +00:00
|
|
|
|
&.cp-comments-readonly {
|
|
|
|
|
.cp-comment-actions {
|
|
|
|
|
display: none !important;
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-form {
|
|
|
|
|
display: none !important;
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-edit {
|
|
|
|
|
display: none !important;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
2020-04-22 14:25:43 +00:00
|
|
|
|
.cp-comment-reply {
|
2020-04-29 13:27:16 +00:00
|
|
|
|
margin-left: 30px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
2020-04-29 14:45:42 +00:00
|
|
|
|
.cp-comment-deleted {
|
|
|
|
|
background: white;
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
padding: 5px;
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.cp-comment-form {
|
2020-04-23 11:52:21 +00:00
|
|
|
|
&:not(:last-child) {
|
2020-04-29 14:56:16 +00:00
|
|
|
|
padding: 5px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
margin-bottom: 10px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-form-input {
|
|
|
|
|
.avatar_main(40px);
|
2020-04-28 16:11:46 +00:00
|
|
|
|
.cp-avatar {
|
|
|
|
|
border: 1px solid transparent;
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
align-items: flex-start;
|
2020-04-28 14:40:40 +00:00
|
|
|
|
div.cp-textarea {
|
2020-04-22 14:25:43 +00:00
|
|
|
|
flex: 1;
|
2020-04-29 13:24:25 +00:00
|
|
|
|
min-height: 52px; // 22px per line + 8 (padding+border)
|
|
|
|
|
height: unset !important;
|
|
|
|
|
max-height: 140px; // 6 lines
|
|
|
|
|
padding: 3px 5px;
|
2021-01-19 15:03:50 +00:00
|
|
|
|
user-select: text;
|
|
|
|
|
-webkit-user-select: text; // fix for iOS (can't type in contenteditable if user-select none)
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
margin-bottom: 5px;
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-form-actions {
|
|
|
|
|
text-align: right;
|
2020-04-30 12:20:25 +00:00
|
|
|
|
margin-left: -30px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
button:not(:last-child) {
|
2020-04-30 12:20:25 +00:00
|
|
|
|
margin-right: 5px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cp-comment-container {
|
|
|
|
|
outline: none;
|
|
|
|
|
&:not(:focus) {
|
|
|
|
|
cursor: pointer;
|
|
|
|
|
.tools_unselectable();
|
|
|
|
|
}
|
2020-04-23 11:47:03 +00:00
|
|
|
|
//&:not(:last-child) {
|
|
|
|
|
// margin-bottom: 10px;
|
|
|
|
|
//}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
.cp-comment-form {
|
|
|
|
|
margin-top: 5px;
|
|
|
|
|
}
|
2020-04-23 11:47:03 +00:00
|
|
|
|
padding: 5px;
|
2020-04-29 15:41:54 +00:00
|
|
|
|
&:nth-child(2) {
|
|
|
|
|
margin-top: 10px;
|
|
|
|
|
};
|
|
|
|
|
&:last-child {
|
|
|
|
|
margin-bottom: 10px;
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
.cp-comment {
|
|
|
|
|
&:not(:first-child) {
|
2020-04-29 15:41:54 +00:00
|
|
|
|
margin-top: 5px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-header {
|
|
|
|
|
height: 40px;
|
|
|
|
|
align-items: center;
|
|
|
|
|
display: flex;
|
|
|
|
|
background-color: white;
|
2020-04-29 14:45:42 +00:00
|
|
|
|
position: relative;
|
2020-04-28 15:27:11 +00:00
|
|
|
|
padding: 5px;
|
|
|
|
|
box-sizing: content-box;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
.avatar_main(40px);
|
|
|
|
|
.cp-comment-metadata {
|
|
|
|
|
flex: 1;
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-flow: column;
|
|
|
|
|
margin-left: 5px;
|
|
|
|
|
.cp-comment-time {
|
|
|
|
|
font-size: 13px;
|
|
|
|
|
color: @data-color;
|
|
|
|
|
}
|
|
|
|
|
}
|
2020-04-29 14:45:42 +00:00
|
|
|
|
.cp-comment-edit {
|
2020-04-30 10:18:23 +00:00
|
|
|
|
cursor: pointer;
|
|
|
|
|
outline: none;
|
2020-04-29 14:45:42 +00:00
|
|
|
|
position: absolute;
|
|
|
|
|
right: 0;
|
|
|
|
|
top: 0;
|
|
|
|
|
width: 20px;
|
|
|
|
|
height: 20px;
|
|
|
|
|
text-align: center;
|
|
|
|
|
line-height: 20px;
|
|
|
|
|
&:hover {
|
|
|
|
|
color: lighten(@cryptpad_text_col, 10%);
|
|
|
|
|
}
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
.cp-comment-content {
|
|
|
|
|
background-color: white;
|
2020-04-29 13:27:16 +00:00
|
|
|
|
padding: 0px 5px 5px 5px;
|
2020-04-23 11:47:03 +00:00
|
|
|
|
white-space: pre-wrap;
|
2020-04-28 14:40:40 +00:00
|
|
|
|
word-break: break-word;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
2020-04-29 14:45:42 +00:00
|
|
|
|
.cp-comment-edited {
|
|
|
|
|
background-color: white;
|
|
|
|
|
font-size: 13px;
|
|
|
|
|
color: @data-color;
|
|
|
|
|
padding: 0 5px;
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
.cp-comment-actions {
|
|
|
|
|
display: none;
|
|
|
|
|
text-align: right;
|
|
|
|
|
margin-top: 5px;
|
2020-04-23 15:42:28 +00:00
|
|
|
|
button {
|
|
|
|
|
margin-bottom: 0 !important;
|
|
|
|
|
}
|
2020-04-22 14:25:43 +00:00
|
|
|
|
button:not(:last-child) {
|
2020-04-30 12:20:25 +00:00
|
|
|
|
margin-right: 5px;
|
2020-04-22 14:25:43 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.cp-comment-active {
|
2020-04-23 11:47:03 +00:00
|
|
|
|
background-color: rgba(0,0,0,0.2);
|
2020-04-22 14:25:43 +00:00
|
|
|
|
.cp-comment-actions {
|
|
|
|
|
display: block;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|