I want to use CodeMirror to edit CSS and allow the user to allow editing styles within classes or identifiers.
Basically, I want the editor to have only one class.
The first line is the name of the class, and the last line is the closure}. All lines between them can be changed by the user.
Example:
.myclass {
}
The reason for this is that the user should not change the class name and that the highlighting does not work if the editor does not have the correct syntax.
I know that he can close it inside class c} and open a new class / id, but that doesn't matter in my case.
Thanks in advance!
source
share