Merge pull request #394 from netlify/text-editor-scroll
prevent rte scroll, improve code display
This commit is contained in:
commit
d0ee10a681
@ -24,3 +24,8 @@
|
||||
display: block;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.textarea {
|
||||
overflow: hidden;
|
||||
resize: none;
|
||||
}
|
||||
|
@ -339,6 +339,7 @@ export default class RawEditor extends React.Component {
|
||||
</Sticky>
|
||||
<TextareaAutosize
|
||||
inputRef={this.handleRef}
|
||||
className={styles.textarea}
|
||||
value={this.props.value || ''}
|
||||
onKeyDown={this.handleKey}
|
||||
onChange={this.handleChange}
|
||||
|
@ -27,6 +27,7 @@
|
||||
font-size: 1.8rem;
|
||||
}
|
||||
& p {
|
||||
margin-top: 20px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
& hr {
|
||||
@ -69,11 +70,22 @@
|
||||
background-color: var(--controlBGColor);
|
||||
padding: 12px;
|
||||
border-radius: 0 0 var(--borderRadius) var(--borderRadius);
|
||||
overflow-x: auto;
|
||||
overflow: hidden;
|
||||
|
||||
& ul {
|
||||
& ul,
|
||||
& ol {
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
& pre > code {
|
||||
display: block;
|
||||
width: 100%;
|
||||
overflow-y: auto;
|
||||
background-color: #000;
|
||||
color: #ccc;
|
||||
border-radius: var(--borderRadius);
|
||||
padding: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
& .ProseMirror-content {
|
||||
|
Loading…
x
Reference in New Issue
Block a user