Files
atom/static/editor.less
Kevin Sawicki & Nathan Sobo 807c6878c1 Set width of hidden input to 1 pixel
Previously the width was set to the width of a single character which
caused issues if the char width was currently zero and since the hidden
input no longer has padding or border the width of the input would end
up being zero which would prevent it from gaining focus.
2013-04-16 15:20:16 -07:00

180 lines
2.7 KiB
Plaintext

.editor {
overflow: hidden;
cursor: text;
display: -webkit-flex;
-webkit-user-select: none;
position: relative;
z-index: 0;
font-family: Inconsolata, Monaco, Courier;
line-height: 1.3;
}
.editor.mini {
height: auto;
line-height: 25px;
}
.editor.mini .cursor {
width: 2px;
line-height: 20px;
margin-top: 2px;
}
.editor .gutter .line-number.cursor-line {
opacity: 1;
}
.editor .gutter {
overflow: hidden;
text-align: right;
cursor: default;
min-width: 1em;
box-sizing: border-box;
text-align: right;
}
.editor .gutter .line-number {
padding-right: .5em;
padding-left: .5em;
opacity: 0.6;
}
.editor .gutter .line-numbers {
position: relative;
}
.editor .gutter .line-number.fold.cursor-line {
opacity: 1;
}
.editor .gutter .line-number.fold:after {
visibility: visible;
}
.editor.mini .gutter {
display: none;
}
.editor .gutter .line-number:after {
font-size: 0.8em;
content: '\f078';
font-family: 'Octicons Regular';
-webkit-font-smoothing: antialiased;
opacity: .8;
visibility: hidden;
}
.editor .fold-marker:after {
font-size: .8em;
content: '\f09a';
opacity: .8;
padding-left: .2em;
font-family: 'Octicons Regular';
-webkit-font-smoothing: antialiased;
}
.editor .line.cursor-line .fold-marker:after {
opacity: 1;
}
.editor.is-blurred .line.cursor-line {
background: rgba(0, 0, 0, 0);
}
.editor .invisible {
opacity: 0.2;
font-weight: normal !important;
font-style: normal !important;
}
.editor .indent-guide {
opacity: 0.2;
display: inline-block;
box-shadow: inset 1px 0px;
}
.editor .vertical-scrollbar {
position: absolute;
right: 0;
top: 0;
bottom: 0;
width: 15px;
overflow-y: auto;
z-index: 1;
}
.editor .scroll-view {
overflow-x: auto;
overflow-y: hidden;
-webkit-flex: 1;
min-width: 0;
position: relative;
}
.editor.mini .scroll-view {
overflow: hidden;
}
.editor.soft-wrap .scroll-view {
overflow-x: hidden;
}
.editor .underlayer, .editor .lines, .editor .overlayer {
width: 100%;
height: 100%;
}
.editor .underlayer {
z-index: 0;
position: absolute;
}
.editor .lines {
position: relative;
z-index: 1;
}
.editor .overlayer {
z-index: 2;
position: absolute;
}
.editor .line {
white-space: pre;
}
.editor .line span {
vertical-align: top;
}
.editor .cursor {
position: absolute;
border-left: 1px solid;
}
.editor .cursor,
.editor.is-focused .cursor.blink-off {
visibility: hidden;
}
.editor.is-focused .cursor {
visibility: visible;
}
.editor .hidden-input {
padding: 0;
border: 0;
position: absolute;
z-index: -1;
top: 0;
left: 0;
opacity: 0;
width: 1px;
}
.editor .selection .region {
position: absolute;
pointer-events: none;
z-index: -1;
}