478 lines
8.0 KiB
CSS
478 lines
8.0 KiB
CSS
.editor-container {
|
|
margin: 20px auto;
|
|
border-radius: 8px;
|
|
max-width: 1100px;
|
|
color: #000;
|
|
position: relative;
|
|
line-height: 1.7;
|
|
font-weight: 400;
|
|
text-align: left;
|
|
border: 1px solid #e0e0e0;
|
|
background: #fff;
|
|
}
|
|
|
|
.editor-inner {
|
|
background: #fff;
|
|
position: relative;
|
|
border-bottom-left-radius: 8px;
|
|
border-bottom-right-radius: 8px;
|
|
}
|
|
|
|
.editor-input {
|
|
min-height: 300px;
|
|
resize: vertical;
|
|
font-size: 15px;
|
|
caret-color: rgb(5, 5, 5);
|
|
position: relative;
|
|
tab-size: 1;
|
|
outline: 0;
|
|
padding: 15px 20px;
|
|
caret-color: #444;
|
|
}
|
|
|
|
.editor-placeholder {
|
|
color: #999;
|
|
overflow: hidden;
|
|
position: absolute;
|
|
text-overflow: ellipsis;
|
|
top: 15px;
|
|
left: 20px;
|
|
font-size: 15px;
|
|
user-select: none;
|
|
display: inline-block;
|
|
pointer-events: none;
|
|
}
|
|
|
|
.editor-paragraph {
|
|
margin: 0;
|
|
margin-bottom: 8px;
|
|
position: relative;
|
|
}
|
|
|
|
.editor-paragraph:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.editor-heading-h1 {
|
|
font-size: 2em;
|
|
font-weight: 700;
|
|
margin: 0;
|
|
margin-bottom: 12px;
|
|
padding: 0;
|
|
}
|
|
|
|
.editor-heading-h2 {
|
|
font-size: 1.5em;
|
|
font-weight: 700;
|
|
margin: 0;
|
|
margin-bottom: 10px;
|
|
padding: 0;
|
|
}
|
|
|
|
.editor-heading-h3 {
|
|
font-size: 1.25em;
|
|
font-weight: 700;
|
|
margin: 0;
|
|
margin-bottom: 8px;
|
|
padding: 0;
|
|
}
|
|
|
|
.editor-quote {
|
|
margin: 0;
|
|
margin-left: 20px;
|
|
margin-bottom: 10px;
|
|
font-size: 15px;
|
|
color: #666;
|
|
border-left: 4px solid #ccc;
|
|
padding-left: 16px;
|
|
}
|
|
|
|
.editor-code {
|
|
background-color: #f4f4f4;
|
|
font-family: Menlo, Consolas, Monaco, monospace;
|
|
display: block;
|
|
padding: 8px 12px;
|
|
line-height: 1.53;
|
|
font-size: 13px;
|
|
margin: 0;
|
|
margin-top: 8px;
|
|
margin-bottom: 8px;
|
|
overflow-x: auto;
|
|
position: relative;
|
|
tab-size: 2;
|
|
border-radius: 4px;
|
|
}
|
|
|
|
.editor-text-bold {
|
|
font-weight: bold;
|
|
}
|
|
|
|
.editor-text-italic {
|
|
font-style: italic;
|
|
}
|
|
|
|
.editor-text-underline {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.editor-text-strikethrough {
|
|
text-decoration: line-through;
|
|
}
|
|
|
|
.editor-text-code {
|
|
background-color: #f4f4f4;
|
|
padding: 1px 4px;
|
|
font-family: Menlo, Consolas, Monaco, monospace;
|
|
font-size: 90%;
|
|
border-radius: 3px;
|
|
}
|
|
|
|
.editor-list-ol {
|
|
padding: 0;
|
|
margin: 0;
|
|
margin-left: 20px;
|
|
}
|
|
|
|
.editor-list-ul {
|
|
padding: 0;
|
|
margin: 0;
|
|
margin-left: 20px;
|
|
}
|
|
|
|
.editor-listitem {
|
|
margin: 4px 0;
|
|
}
|
|
|
|
.editor-nested-listitem {
|
|
list-style-type: none;
|
|
}
|
|
|
|
/* Horizontal Rule */
|
|
.editor-hr {
|
|
border: none;
|
|
border-top: 2px solid #ccc;
|
|
margin: 15px 0;
|
|
}
|
|
|
|
/* Link */
|
|
.editor-link {
|
|
color: #0066cc;
|
|
text-decoration: none;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.editor-link:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
/* Table */
|
|
.editor-table {
|
|
border-collapse: collapse;
|
|
border-spacing: 0;
|
|
overflow-y: scroll;
|
|
overflow-x: scroll;
|
|
table-layout: fixed;
|
|
width: max-content;
|
|
margin: 15px 0;
|
|
}
|
|
|
|
.editor-table-cell {
|
|
border: 1px solid #ccc;
|
|
min-width: 75px;
|
|
vertical-align: top;
|
|
text-align: start;
|
|
padding: 6px 8px;
|
|
position: relative;
|
|
outline: none;
|
|
}
|
|
|
|
.editor-table-cell-header {
|
|
background-color: #f4f4f4;
|
|
font-weight: bold;
|
|
text-align: left;
|
|
}
|
|
|
|
/* Checklist */
|
|
.editor-listitem-checked,
|
|
.editor-listitem-unchecked {
|
|
position: relative;
|
|
margin-left: 8px;
|
|
margin-right: 8px;
|
|
padding-left: 24px;
|
|
padding-right: 24px;
|
|
list-style-type: none;
|
|
outline: none;
|
|
}
|
|
|
|
.editor-listitem-checked {
|
|
text-decoration: line-through;
|
|
}
|
|
|
|
.editor-listitem-unchecked:before,
|
|
.editor-listitem-checked:before {
|
|
content: '';
|
|
width: 16px;
|
|
height: 16px;
|
|
top: 2px;
|
|
left: 0;
|
|
cursor: pointer;
|
|
display: block;
|
|
background-size: cover;
|
|
position: absolute;
|
|
}
|
|
|
|
.editor-listitem-unchecked:before {
|
|
border: 1px solid #999;
|
|
border-radius: 2px;
|
|
}
|
|
|
|
.editor-listitem-checked:before {
|
|
border: 1px solid #0066cc;
|
|
border-radius: 2px;
|
|
background-color: #0066cc;
|
|
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath fill='white' d='M13.5 2l-7.5 7.5-3.5-3.5-1.5 1.5 5 5 9-9z'/%3E%3C/svg%3E");
|
|
background-repeat: no-repeat;
|
|
background-position: center;
|
|
}
|
|
|
|
.editor-listitem-checked[dir='rtl']:before,
|
|
.editor-listitem-unchecked[dir='rtl']:before {
|
|
left: auto;
|
|
right: 0;
|
|
}
|
|
|
|
.editor-listitem-checked[dir='rtl'],
|
|
.editor-listitem-unchecked[dir='rtl'] {
|
|
padding-left: 24px;
|
|
padding-right: 24px;
|
|
}
|
|
|
|
/* Image */
|
|
.editor-image {
|
|
cursor: default;
|
|
display: inline-block;
|
|
position: relative;
|
|
user-select: none;
|
|
}
|
|
|
|
.editor-image img {
|
|
max-width: 100%;
|
|
cursor: default;
|
|
}
|
|
|
|
.editor-image img.focused {
|
|
outline: 2px solid rgb(60, 132, 244);
|
|
user-select: none;
|
|
}
|
|
|
|
.editor-image img.focused.draggable {
|
|
cursor: grab;
|
|
}
|
|
|
|
.editor-image img.focused.draggable:active {
|
|
cursor: grabbing;
|
|
}
|
|
|
|
.image-control-wrapper--resizing {
|
|
touch-action: none;
|
|
}
|
|
|
|
/* Image Resizer */
|
|
.image-resizer {
|
|
display: block;
|
|
width: 7px;
|
|
height: 7px;
|
|
position: absolute;
|
|
background-color: rgb(60, 132, 244);
|
|
border: 1px solid #fff;
|
|
}
|
|
|
|
.image-resizer.image-resizer-n {
|
|
top: -6px;
|
|
left: 48%;
|
|
cursor: n-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-ne {
|
|
top: -6px;
|
|
right: -6px;
|
|
cursor: ne-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-e {
|
|
bottom: 48%;
|
|
right: -6px;
|
|
cursor: e-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-se {
|
|
bottom: -2px;
|
|
right: -6px;
|
|
cursor: nwse-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-s {
|
|
bottom: -2px;
|
|
left: 48%;
|
|
cursor: s-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-sw {
|
|
bottom: -2px;
|
|
left: -6px;
|
|
cursor: sw-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-w {
|
|
bottom: 48%;
|
|
left: -6px;
|
|
cursor: w-resize;
|
|
}
|
|
|
|
.image-resizer.image-resizer-nw {
|
|
top: -6px;
|
|
left: -6px;
|
|
cursor: nw-resize;
|
|
}
|
|
|
|
/* Text Alignment */
|
|
.editor-text-left {
|
|
text-align: left;
|
|
}
|
|
|
|
.editor-text-center {
|
|
text-align: center;
|
|
}
|
|
|
|
.editor-text-right {
|
|
text-align: right;
|
|
}
|
|
|
|
.editor-text-justify {
|
|
text-align: justify;
|
|
}
|
|
|
|
/* Hashtag styles */
|
|
.editor-hashtag {
|
|
background-color: rgba(88, 144, 255, 0.15);
|
|
border-bottom: 1px solid rgba(88, 144, 255, 0.3);
|
|
font-weight: 500;
|
|
}
|
|
|
|
/* Mention styles */
|
|
.mention {
|
|
background-color: rgba(24, 119, 232, 0.2);
|
|
color: #1877e8;
|
|
border-radius: 4px;
|
|
padding: 1px 3px;
|
|
font-weight: 500;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.mention:focus {
|
|
box-shadow: rgb(180 213 255) 0px 0px 0px 2px;
|
|
outline: none;
|
|
}
|
|
|
|
/* Typeahead popover styles */
|
|
.typeahead-popover {
|
|
background: #fff;
|
|
box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.3);
|
|
border-radius: 8px;
|
|
position: relative;
|
|
z-index: 5;
|
|
}
|
|
|
|
.typeahead-popover ul {
|
|
padding: 0;
|
|
list-style: none;
|
|
margin: 0;
|
|
border-radius: 8px;
|
|
max-height: 200px;
|
|
overflow-y: scroll;
|
|
}
|
|
|
|
.typeahead-popover ul::-webkit-scrollbar {
|
|
display: none;
|
|
}
|
|
|
|
.typeahead-popover ul {
|
|
-ms-overflow-style: none;
|
|
scrollbar-width: none;
|
|
}
|
|
|
|
.typeahead-popover ul li {
|
|
margin: 0;
|
|
min-width: 180px;
|
|
font-size: 14px;
|
|
outline: none;
|
|
cursor: pointer;
|
|
border-radius: 8px;
|
|
}
|
|
|
|
.typeahead-popover ul li.selected {
|
|
background: #eee;
|
|
}
|
|
|
|
.typeahead-popover li {
|
|
margin: 0 8px 0 8px;
|
|
padding: 8px;
|
|
color: #050505;
|
|
cursor: pointer;
|
|
line-height: 16px;
|
|
font-size: 15px;
|
|
display: flex;
|
|
align-content: center;
|
|
flex-direction: row;
|
|
flex-shrink: 0;
|
|
background-color: #fff;
|
|
border-radius: 8px;
|
|
border: 0;
|
|
}
|
|
|
|
.typeahead-popover li.active {
|
|
display: flex;
|
|
width: 20px;
|
|
height: 20px;
|
|
background-size: contain;
|
|
}
|
|
|
|
.typeahead-popover li:first-child {
|
|
border-radius: 8px 8px 0px 0px;
|
|
}
|
|
|
|
.typeahead-popover li:last-child {
|
|
border-radius: 0px 0px 8px 8px;
|
|
}
|
|
|
|
.typeahead-popover li:hover {
|
|
background-color: #eee;
|
|
}
|
|
|
|
.typeahead-popover li .text {
|
|
display: flex;
|
|
line-height: 20px;
|
|
flex-grow: 1;
|
|
min-width: 150px;
|
|
}
|
|
|
|
.typeahead-popover li .icon {
|
|
display: flex;
|
|
width: 20px;
|
|
height: 20px;
|
|
user-select: none;
|
|
margin-right: 8px;
|
|
line-height: 16px;
|
|
background-size: contain;
|
|
background-repeat: no-repeat;
|
|
background-position: center;
|
|
}
|
|
|
|
.mentions-menu {
|
|
width: 250px;
|
|
}
|
|
|
|
.typeahead-popover li .icon.user {
|
|
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23666'%3E%3Cpath d='M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z'/%3E%3C/svg%3E");
|
|
}
|