You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
319 B
JavaScript
19 lines
319 B
JavaScript
11 years ago
|
"use strict";
|
||
|
|
||
|
var admin = {};
|
||
|
|
||
|
(function() {
|
||
|
|
||
|
admin.enableColorPicker = function(inputEl, callback) {
|
||
|
inputEl.ColorPicker({
|
||
|
color: inputEl.val() || '#000',
|
||
|
onChange: function(hsb, hex) {
|
||
|
inputEl.val('#' + hex);
|
||
|
if (typeof callback === 'function') {
|
||
|
callback(hsb, hex);
|
||
|
}
|
||
|
}
|
||
|
});
|
||
|
};
|
||
|
|
||
|
}());
|