mirror of
https://github.com/zen-browser/components.git
synced 2025-07-07 21:09:58 +02:00
Refactor dot removal logic in ZenGradientGenerator
This commit is contained in:
parent
aa13489798
commit
2572fb55f6
1 changed files with 2 additions and 2 deletions
|
@ -280,12 +280,12 @@
|
||||||
|
|
||||||
onDotMouseUp(event) {
|
onDotMouseUp(event) {
|
||||||
if (event.button === 2) {
|
if (event.button === 2) {
|
||||||
if (this.numberOfDots < 2 || !event.target.classList.contains('zen-theme-picker-dot')
|
if (this.numberOfDots < 2 || !event.target.classList.contains('zen-theme-picker-dot')) {
|
||||||
|| this.numberOfDots === 1) {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
event.target.remove();
|
event.target.remove();
|
||||||
this.updateCurrentWorkspace();
|
this.updateCurrentWorkspace();
|
||||||
|
this.numberOfDots--;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.dragging) {
|
if (this.dragging) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue