Skip to content

Commit

Permalink
Update satus.js color picker no longer writes during render
Browse files Browse the repository at this point in the history
  • Loading branch information
raszpl authored Apr 9, 2024
1 parent 8a16511 commit da4132b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions menu/satus.js
Original file line number Diff line number Diff line change
Expand Up @@ -1765,8 +1765,6 @@ satus.components.colorPicker = function(component, skeleton) {
set: function(value) {
array = value;

this.parentNode.storage.value = array;

element.style.backgroundColor = 'rgb(' + value.join(',') + ')';
}
});
Expand Down Expand Up @@ -1894,6 +1892,7 @@ satus.components.colorPicker = function(component, skeleton) {
component = modal.parentElement;

component.color.value = component.skeleton.value || [0, 0, 0];
satus.storage.remove(component.storage.key);

modal.rendered.close();
}
Expand All @@ -1917,6 +1916,7 @@ satus.components.colorPicker = function(component, skeleton) {
component = modal.parentElement;

component.color.value = satus.color.hslToRgb(modal.value);
component.storage.value = component.color.value;

modal.rendered.close();
}
Expand Down

0 comments on commit da4132b

Please sign in to comment.