codemirror / codemirror5

In-browser code editor (version 5, legacy)
http://codemirror.net/5/
MIT License
26.77k stars 4.96k forks source link

Use of `rgb` with four arguments breaks use of CM in Rails/Sass #5951

Closed blerner closed 5 years ago

blerner commented 5 years ago

https://github.com/codemirror/CodeMirror/blob/85482b0377911befe59c90fc7d714f30b59c98e7/theme/yonce.css#L27-L28 uses rgb with a fourth argument. This is legal CSS syntax, but not yet legal in Sass. This recently broke a rails app I was writing, when I updated my npm packages and that updated CM.

https://github.com/sass/sass/issues/2564 tracks adding support for four-argument rgb to sass, but it hasn't made its way into libsass and sassc yet...

ReasorA commented 5 years ago

Ran into this same issue using dynamic imports with Webpack. It errors when run through Webpack's sass-loader. Currently, we need to either edit this file or delete it with each npm i.

import(`codemirror/theme/${editorTheme}.css`)