mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-03-22 08:58:11 +00:00
code folding
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
|
||||||
|
import './codeEditor.less';
|
||||||
import React, { useEffect, useRef, forwardRef, useImperativeHandle } from "react";
|
import React, { useEffect, useRef, forwardRef, useImperativeHandle } from "react";
|
||||||
|
|
||||||
import { EditorState } from "@codemirror/state";
|
import { EditorState } from "@codemirror/state";
|
||||||
|
|||||||
@@ -18,11 +18,26 @@
|
|||||||
.codeEditor {
|
.codeEditor {
|
||||||
font-family: monospace;
|
font-family: monospace;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
width:100%;
|
||||||
|
|
||||||
@media screen and (pointer: coarse) {
|
@media screen and (pointer: coarse) {
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.cm-scroller {
|
||||||
|
width:100%;
|
||||||
|
|
||||||
|
}
|
||||||
|
.cm-content {
|
||||||
|
width:70%;
|
||||||
|
|
||||||
|
.cm-line {
|
||||||
|
word-wrap: break-word;
|
||||||
|
white-space: pre-wrap;
|
||||||
|
word-break: normal;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Line numbers and gutters */
|
/* Line numbers and gutters */
|
||||||
.cm-gutters {
|
.cm-gutters {
|
||||||
background-color: #f0f0f0;
|
background-color: #f0f0f0;
|
||||||
|
|||||||
Reference in New Issue
Block a user