Merge pull request #23403 from gentoo90/jquery.colorpicker

jquery.colorpicker: make disable field in options optional
This commit is contained in:
Ron Buckton
2018-02-07 13:53:12 -08:00
committed by GitHub
2 changed files with 4 additions and 1 deletions
+1 -1
View File
@@ -31,7 +31,7 @@ interface JQueryColorpickerOptions {
closeOnOutside?: boolean;
color?: string;
colorFormat?: string;
disabled: boolean;
disabled?: boolean;
draggable?: boolean;
duration?: string;
format?: string;
@@ -70,6 +70,9 @@ colorpicker.colorpicker("destroy");
colorpicker.colorpicker("setColor", "#deadbeef");
colorpicker.colorpicker("option", "disabled", true);
// check if all options are optional
let defaultColorpicker = $("<input type=\"text\"/>").colorpicker({});
// example plugins provided
$.colorpicker.parts["memory"] = function (inst) {