Files
Grav-Admin-Plugin/themes/grav/scss/template/_editor.scss

212 lines
4.3 KiB
SCSS
Raw Normal View History

// Grav Editor
2016-02-26 15:54:06 -08:00
.grav-editor {
[data-grav-editor] {
height: 300px;
}
2015-08-05 18:50:45 -06:00
.CodeMirror-scroll {
margin-right: -36px;
padding-bottom: 36px;
}
.grav-editor-resizer {
height: 6px;
cursor: row-resize;
border-radius: 0 0 3px 3px;
margin-top: -2px;
position: relative;
z-index: 10;
}
}
2016-02-26 15:54:06 -08:00
.grav-editor-fullscreen {
position: fixed;
top: 0;
left: 0;
bottom: 0;
right: 0;
2015-11-24 17:21:32 -08:00
z-index: 99999;
2016-02-26 15:54:06 -08:00
padding: 0 !important;
margin: 0 !important;
2016-02-26 15:54:06 -08:00
.grav-editor-content, .CodeMirror-wrap, .grav-editor-preview {
height: 100% !important;
}
2016-02-26 15:54:06 -08:00
.grav-editor-toolbar, .grav-editor-toolbar ul li:first-child a, .grav-editor-toolbar-flip ul li:last-child a {
border-radius: 0;
}
}
.grav-editor-toolbar {
@include align-items(stretch);
@include display(flex);
@include flex-direction(row);
.grav-editor-actions {
@include flex(1);
}
.grav-editor-modes {
2016-03-01 22:19:13 -08:00
flex-shrink: 0;
ul {
float: right;
}
}
}
2016-02-26 15:54:06 -08:00
.grav-editor-toolbar {
@include clearfix;
ul {
list-style: none;
margin: 0;
padding: 0;
li {
&:first-child a {
border-top-left-radius: 4px;
}
2016-02-26 15:54:06 -08:00
display: inline-block;
}
a {
2016-02-26 15:54:06 -08:00
display: inline-block;
cursor: pointer;
2016-02-26 15:54:06 -08:00
background-color: transparent;
border-radius: 0;
padding: 0.4rem 0.8rem;
margin-top: -1px;
border: 1px solid transparent;
&, &:hover, &:active, &:focus {
outline: 0;
}
}
}
}
2016-03-02 16:39:54 -08:00
.grav-editor-hide-toolbar {
display: none;
}
.grav-editor-toolbar .grav-editor-modes {
li {
&:first-child a {
border-top-left-radius: 0;
}
&:last-child a {
border-top-right-radius: 4px;
}
2016-02-26 15:54:06 -08:00
}
a {
&:hover {
/*border: 1px solid transparent;
border-bottom: 1px solid darken($content-bg, 20%);*/
}
2016-02-26 15:54:06 -08:00
}
}
2016-02-26 15:54:06 -08:00
.grav-editor-toolbar-flip {
float: right;
ul li:last-child a {
border-top-right-radius: 4px;
}
}
.grav-editor-content, .grav-editor-preview {
@include clearfix;
cursor: text;
}
2016-03-03 11:26:13 -08:00
.grav-editor-content {
2016-03-03 11:41:16 -08:00
/* PADDING */
.CodeMirror-lines {
padding: 10px 0; /* Vertical padding around content */
2016-03-03 11:26:13 -08:00
}
2016-03-03 11:41:16 -08:00
.CodeMirror pre {
padding: 0 15px; /* Horizontal padding of content */
}
2016-03-03 11:26:13 -08:00
}
2016-02-26 15:54:06 -08:00
.grav-editor-preview {
padding: 20px;
overflow-y: scroll;
position: relative;
background: #fff;
}
2016-02-26 15:54:06 -08:00
.grav-editor-toolbar {
[data-hint]:after {
white-space: nowrap !important;
max-width: 300px;
width: auto !important;
}
p {
margin-top: 10px;
margin-bottom: 10px;
padding-left: 20px;
}
}
// CodeMirror Theme
.cm-s-paper {
2016-02-25 12:22:22 -07:00
$paper-fg: #666;
$tag: darken($paper-fg, 10%);
&.CodeMirror {
color: $paper-fg;
line-height: 1.4;
}
2016-02-24 21:33:45 -07:00
.cm-link {color: #0082ba;}
.cm-comment {color: lighten($paper-fg,10%);}
2016-02-25 12:22:22 -07:00
.cm-header {color: darken($paper-fg,5%);}
.cm-strong {color: darken($paper-fg,10%);}
.cm-em {color: darken($paper-fg, 10%);}
2016-02-25 12:22:22 -07:00
.cm-string {color: #0082BA;}
.cm-tag {color: $tag}
.cm-bracket {color: lighten($tag, 10%);}
.cm-hr {color: lighten($paper-fg,40%);font-weight: bold;}
2016-02-24 21:33:45 -07:00
.cm-keyword {color: #0082ba;}
.cm-atom {color: #9055af;}
.cm-meta {color: $paper-fg;}
.cm-number {color: #7f8c8d;}
.cm-def {color: #00f;}
.cm-variable {color: black;}
2016-02-25 12:22:22 -07:00
//.cm-variable-2 {color: #555;}
//.cm-variable-3 {color: #085;}
.cm-property {color: black;}
.cm-operator {color: black;}
.cm-string-2 {color: #f50;}
.cm-meta {color: #555;}
.cm-error {color: #f00;}
.cm-qualifier {color: #555;}
.cm-builtin {color: #555;}
.cm-attribute {color: #7f8c8d;}
.cm-quote {color: #888;}
.cm-header-1 {font-size: 140%;}
.cm-header-2 {font-size: 120%;}
.cm-header-3 {font-size: 110%;}
.cm-negative {color: #d44;}
.cm-positive {color: #292;}
.cm-header, .cm-strong {font-weight: bold;}
.cm-em {font-style: italic;}
.cm-link {text-decoration: underline;}
.cm-invalidchar {color: #f00;}
}