mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-26 18:58:54 +02:00
Fixes: #3464 - Change color picker to dynamic coloring from static CSS
This commit is contained in:
@@ -91,11 +91,8 @@ $(document).ready(function() {
|
||||
// Assign color picker selection classes
|
||||
function colorPickerClassCopy(data, container) {
|
||||
if (data.element) {
|
||||
// Remove any existing color-selection classes
|
||||
$(container).attr('class', function(i, c) {
|
||||
return c.replace(/(^|\s)color-selection-\S+/g, '');
|
||||
});
|
||||
$(container).addClass($(data.element).attr("class"));
|
||||
// Swap the style
|
||||
$(container).attr('style', $(data.element).attr("style"));
|
||||
}
|
||||
return data.text;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user