diff --git a/CHANGELOG.md b/CHANGELOG.md index 46c63f4..611c682 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,9 @@ - Spanish real translation by Alejabar (thanks !) - Added a GM Dialog Tool for setting global difficulty (TN) value / hidden (with DicePicker live refresh) - Compendium now display Ring and Rank if any in list view -- DicePicker : Fixed the initial display of "use a void point" +- DicePicker : + - Fixed the initial display of "use a void point" + - No free void point anymore - PC/NPC Sheet : - Added a visual indicator for equipped / readied - Now only equipped armor / weapon will show in conflict tab, and all armors/weapons now show in inventory tab diff --git a/system/scripts/actors/base-sheet.js b/system/scripts/actors/base-sheet.js index 8e28108..c93d181 100644 --- a/system/scripts/actors/base-sheet.js +++ b/system/scripts/actors/base-sheet.js @@ -159,7 +159,7 @@ export class BaseSheetL5r5e extends ActorSheet { event.stopPropagation(); const elmt = $(event.currentTarget).data("toggle"); const tgt = html.find("." + elmt); - tgt.hasClass("toggle-active") ? tgt.removeClass("toggle-active") : tgt.addClass("toggle-active"); + tgt.toggleClass("toggle-active"); }); // *** Everything below here is only needed if the sheet is editable *** diff --git a/system/scripts/actors/twenty-questions-dialog.js b/system/scripts/actors/twenty-questions-dialog.js index 4aaa519..4d44285 100644 --- a/system/scripts/actors/twenty-questions-dialog.js +++ b/system/scripts/actors/twenty-questions-dialog.js @@ -165,7 +165,7 @@ export class TwentyQuestionsDialog extends FormApplication { event.stopPropagation(); const elmt = $(event.currentTarget).data("toggle"); const tgt = html.find("." + elmt); - tgt.hasClass("toggle-active") ? tgt.removeClass("toggle-active") : tgt.addClass("toggle-active"); + tgt.toggleClass("toggle-active"); }); // BT Next diff --git a/system/scripts/items/item-sheet.js b/system/scripts/items/item-sheet.js index 4657b8a..fc354c5 100644 --- a/system/scripts/items/item-sheet.js +++ b/system/scripts/items/item-sheet.js @@ -89,7 +89,7 @@ export class ItemSheetL5r5e extends ItemSheet { event.stopPropagation(); const elmt = $(event.currentTarget).data("toggle"); const tgt = html.find("." + elmt); - tgt.hasClass("toggle-active") ? tgt.removeClass("toggle-active") : tgt.addClass("toggle-active"); + tgt.toggleClass("toggle-active"); }); // Everything below here is only needed if the sheet is editable