mirror of
https://github.com/atom/atom.git
synced 2026-02-19 02:44:29 -05:00
Remove .editor class to force themes to style background via :host
The goal is to allow the editor’s styling to be overridden as follows:
atom-text-editor {
background: black;
color: white;
}
If we retain these classes, themes will continue to style the root
element of the editor and destroy the ability to style the editor in
this way. You would instead have to do the following:
atom-text-editor::shadow .editor {
background: black;
color: white;
}
This is way less intuitive and confusing for people.
This commit is contained in:
@@ -90,7 +90,10 @@ TextEditorComponent = React.createClass
|
||||
|
||||
style.height = scrollViewHeight if @autoHeight
|
||||
|
||||
className = 'editor-contents'
|
||||
if useShadowDOM
|
||||
className = 'editor-contents--private'
|
||||
else
|
||||
className = 'editor-contents'
|
||||
className += ' is-focused' if focused
|
||||
className += ' has-selection' if hasSelection
|
||||
|
||||
|
||||
Reference in New Issue
Block a user