ソースを参照

Fix selectionCssClass not working in defaults (#5847)

There was a bug in the 4.1.0-beta.0 release which resulted in the
`selectionCssClass` not being functional. This was because the
defaults had not been updated to support this option despite the
documentation and the release notes claiming it was supported.
Kevin Brown 5 年 前
コミット
e1f160efcf
1 ファイル変更2 行追加10 行削除
  1. 2 10
      src/js/select2/defaults.js

+ 2 - 10
src/js/select2/defaults.js

@@ -149,11 +149,7 @@ define([
         );
       }
 
-      if (
-        options.dropdownCssClass != null ||
-        options.dropdownCss != null ||
-        options.adaptDropdownCssClass != null
-      ) {
+      if (options.dropdownCssClass != null) {
         options.dropdownAdapter = Utils.Decorate(
           options.dropdownAdapter,
           DropdownCSS
@@ -195,11 +191,7 @@ define([
         );
       }
 
-      if (
-        options.containerCssClass != null ||
-        options.containerCss != null ||
-        options.adaptContainerCssClass != null
-      ) {
+      if (options.selectionCssClass != null) {
         options.selectionAdapter = Utils.Decorate(
           options.selectionAdapter,
           SelectionCSS