Kaynağa Gözat

Changed: Remove redundant class from highlight button.

Maciej Gołaszewski 7 yıl önce
ebeveyn
işleme
8df687f7aa

+ 1 - 10
packages/ckeditor5-highlight/src/highlightui.js

@@ -26,8 +26,6 @@ import {
 import ToolbarSeparatorView from '@ckeditor/ckeditor5-ui/src/toolbar/toolbarseparatorview';
 
 import './../theme/highlight.css';
-// TODO: dirty hack to make toolbar look nice in dropdown.
-import '@ckeditor/ckeditor5-ui/theme/components/dropdown/buttondropdown.css';
 
 /**
  * The default Highlight UI plugin.
@@ -90,12 +88,6 @@ export default class HighlightUI extends Plugin {
 			button.bind( 'isEnabled' ).to( command, 'isEnabled' );
 			button.bind( 'isOn' ).to( command, 'value', value => value === option.model );
 
-			button.extendTemplate( {
-				attributes: {
-					class: 'ck-highlight_button'
-				}
-			} );
-
 			button.iconView.extendTemplate( {
 				attributes: {
 					style: `color: ${ option.color }`
@@ -203,10 +195,9 @@ export default class HighlightUI extends Plugin {
 
 			bindIconStyleToColor( dropdownView, model );
 
-			// TODO: fix classes in dropdown
 			dropdownView.extendTemplate( {
 				attributes: {
-					class: [ 'ck-highlight_button', 'ck-highlight-dropdown' ]
+					class: [ 'ck-highlight-dropdown' ]
 				}
 			} );
 

+ 1 - 1
packages/ckeditor5-highlight/theme/highlight.css

@@ -3,7 +3,7 @@
  * For licensing, see LICENSE.md.
  */
 
-.ck-highlight_button svg path:not(.ck-icon__fill) {
+.ck-highlight-dropdown svg path:not(.ck-icon__fill) {
 	/* Do not inherit color from parent. */
 	fill: initial;
 }