fix toggle logic and cursors
This commit is contained in:
parent
704058ac36
commit
0dce445375
|
@ -120,6 +120,14 @@
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.world_entry .inline-drawer-header {
|
||||||
|
cursor: initial;
|
||||||
|
}
|
||||||
|
|
||||||
|
.world_entry .killSwitch {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.world_entry_form_control input[type=button] {
|
.world_entry_form_control input[type=button] {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
|
@ -5302,7 +5302,7 @@
|
||||||
<span class="drag-handle">☰</span>
|
<span class="drag-handle">☰</span>
|
||||||
<div class="gap5px world_entry_thin_controls wide100p alignitemscenter">
|
<div class="gap5px world_entry_thin_controls wide100p alignitemscenter">
|
||||||
<div class="inline-drawer-toggle fa-fw fa-solid fa-circle-chevron-down inline-drawer-icon down"></div>
|
<div class="inline-drawer-toggle fa-fw fa-solid fa-circle-chevron-down inline-drawer-icon down"></div>
|
||||||
<div class="fa-solid fa-toggle-on" name="entryKillSwitch"></div>
|
<div class="fa-solid fa-toggle-on killSwitch" name="entryKillSwitch"></div>
|
||||||
<div class="flex-container alignitemscenter wide100p">
|
<div class="flex-container alignitemscenter wide100p">
|
||||||
|
|
||||||
<div class="WIEntryTitleAndStatus flex-container flex1 alignitemscenter">
|
<div class="WIEntryTitleAndStatus flex-container flex1 alignitemscenter">
|
||||||
|
|
|
@ -2916,10 +2916,9 @@ async function getWorldEntry(name, data, entry) {
|
||||||
const entryKillSwitch = template.find('div[name="entryKillSwitch"]');
|
const entryKillSwitch = template.find('div[name="entryKillSwitch"]');
|
||||||
entryKillSwitch.data('uid', entry.uid);
|
entryKillSwitch.data('uid', entry.uid);
|
||||||
entryKillSwitch.on('click', async function (event) {
|
entryKillSwitch.on('click', async function (event) {
|
||||||
event.stopPropagation();
|
|
||||||
const uid = entry.uid;
|
const uid = entry.uid;
|
||||||
data.entries[uid].disable = !data.entries[uid].disable;
|
data.entries[uid].disable = !data.entries[uid].disable;
|
||||||
let isActive = data.entries[uid].disable;
|
let isActive = !data.entries[uid].disable;
|
||||||
setWIOriginalDataValue(data, uid, 'enabled', isActive);
|
setWIOriginalDataValue(data, uid, 'enabled', isActive);
|
||||||
if (isActive) {
|
if (isActive) {
|
||||||
template.removeClass('disabledWIEntry');
|
template.removeClass('disabledWIEntry');
|
||||||
|
|
Loading…
Reference in New Issue