p5.js-web-editor/client/styles/components/_editor.scss
Yining Shi e86e9a0ae0 Added a star icon for unsaved file name, added 'Saved: xx time ago' (#177)
* added a star icon for unsaved file name, added saved time ago

* changed text

* added timer component

* clean extra styling in _editor.sass

* customize momentjs fromnow function

* clear 10s interval in componentWillUnmount

* use space-between instead of float
2016-11-09 12:52:14 -05:00

108 lines
2.3 KiB
SCSS

.CodeMirror {
@include themify() {
border: 1px solid getThemifyVariable('ide-border-color');
}
font-family: Inconsolata, monospace;
height: 100%;
}
.CodeMirror-linenumbers {
padding-right: #{10 / $base-font-size}rem;
}
.CodeMirror-linenumber {
width: #{35 / $base-font-size}rem;
}
.CodeMirror-lines {
padding-top: #{25 / $base-font-size}rem;
}
.CodeMirror-line {
padding-left: #{5 / $base-font-size}rem;
}
.CodeMirror-gutter-wrapper {
right: 100%;
top: 0;
bottom: 0;
}
.CodeMirror-lint-marker-warning, .CodeMirror-lint-marker-error, .CodeMirror-lint-marker-multiple {
background-image: none;
width: 70px;
position: absolute;
height: 100%;
}
.CodeMirror-lint-message-error, .CodeMirror-lint-message-warning {
background-image: none;
padding-left: inherit;
}
.CodeMirror-lint-marker-warning {
background-color: rgb(255, 190, 5);
}
.CodeMirror-lint-marker-error {
background-color: rgb(255, 95, 82);
}
.CodeMirror-gutter-elt:not(.CodeMirror-linenumber) {
opacity: 0.3;
width: 70px !important;
height: 100%;
// background-color: rgb(255, 95, 82);
}
.CodeMirror-lint-tooltip {
@include themify() {
background-color: getThemifyVariable('modal-background-color');
border: 1px solid getThemifyVariable('modal-border-color');
box-shadow: 0 12px 12px getThemifyVariable('shadow-color');
color: getThemifyVariable('primary-text-color');
}
border-radius: 2px;
font-family: 'Avenir Next', Montserrat, sans-serif;
}
.CodeMirror-gutters {
@include themify() {
background-color: getThemifyVariable('editor-gutter-color');
border-color: getThemifyVariable('ide-border-color');
}
// left: 0 !important;
}
.editor__options-button {
@include themify() {
@extend %icon;
}
position: absolute;
top: 0;
right: #{1.5 / $base-font-size}rem; // move left to avoid vertical scroll bar
z-index: 1;
}
.editor__options {
display: none;
@extend %modal;
position: absolute;
top: #{20 / $base-font-size}rem;
right: #{5 / $base-font-size}rem;
padding: #{10 / $base-font-size}rem;
.editor--options & {
display: block;
}
}
.editor__file-name {
@include themify() {
color: getThemifyVariable('inactive-text-color');
}
padding: 0 0 #{7 / $base-font-size}rem #{76 / $base-font-size}rem;
font-size: #{12 / $base-font-size}rem;
display: flex;
justify-content: space-between;
}