From c9becf25e7741eba2ebe864869163622fd8c3ea9 Mon Sep 17 00:00:00 2001 From: WBHarry Date: Thu, 17 Oct 2024 18:56:07 +0200 Subject: [PATCH] Added Icon Color classes to npcview --- BestiaryTracking.js | 36 ++++++++++++++++++----- templates/partials/hazardView.hbs | 2 +- templates/partials/monsterView.hbs | 2 +- templates/partials/npcView.hbs | 24 +++++++-------- templates/partials/pcPersonality.hbs | 2 +- templates/partials/toggleInputSection.hbs | 2 +- templates/partials/toggleTextSection.hbs | 2 +- 7 files changed, 46 insertions(+), 24 deletions(-) diff --git a/BestiaryTracking.js b/BestiaryTracking.js index 00466f6..cfe107b 100644 --- a/BestiaryTracking.js +++ b/BestiaryTracking.js @@ -8910,7 +8910,10 @@ class BestiaryDisplayMenu extends HandlebarsApplicationMixin$7( this.settings = { hideWelcome: game.settings.get("pf2e-bestiary-tracking", "hide-welcome"), hideTips: game.settings.get("pf2e-bestiary-tracking", "hide-tips"), - sectionsPosition: game.settings.get("pf2e-bestiary-tracking", "sections-position"), + sectionsPosition: game.settings.get( + "pf2e-bestiary-tracking", + "sections-position", + ), hideAbilityDescriptions: game.settings.get( "pf2e-bestiary-tracking", "hide-ability-descriptions", @@ -9013,7 +9016,20 @@ class BestiaryDisplayMenu extends HandlebarsApplicationMixin$7( ).length; context.toBestiaryOptions = toBestiaryOptions; - context.positionOptions = [{ value: 'top', name: 'PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Top' }, { value: 'center', name: 'PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Center'}, { value: 'bottom', name: 'PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Bottom' }]; + context.positionOptions = [ + { + value: "top", + name: "PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Top", + }, + { + value: "center", + name: "PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Center", + }, + { + value: "bottom", + name: "PF2EBestiary.Menus.BestiaryDisplay.PositionOptions.Bottom", + }, + ]; return context; } @@ -9115,9 +9131,9 @@ class BestiaryDisplayMenu extends HandlebarsApplicationMixin$7( this.settings.hideTips, ); await game.settings.set( - "pf2e-bestiary-tracking", + "pf2e-bestiary-tracking", "sections-position", - this.settings.sectionsPosition + this.settings.sectionsPosition, ); await game.settings.set( "pf2e-bestiary-tracking", @@ -10065,7 +10081,7 @@ const bestiaryDisplay = () => { scope: "world", config: false, type: String, - default: 'top', + default: "top", }); game.settings.register( @@ -14999,8 +15015,14 @@ class PF2EBestiary extends HandlebarsApplicationMixin( "use-token-art", ); context.hideTips = game.settings.get("pf2e-bestiary-tracking", "hide-tips"); - context.hideWelcome = game.settings.get("pf2e-bestiary-tracking", "hide-welcome"); - context.sectionsPositioning = game.settings.get("pf2e-bestiary-tracking", 'sections-position'); + context.hideWelcome = game.settings.get( + "pf2e-bestiary-tracking", + "hide-welcome", + ); + context.sectionsPositioning = game.settings.get( + "pf2e-bestiary-tracking", + "sections-position", + ); context.hideAbilityDescriptions = game.settings.get( "pf2e-bestiary-tracking", "hide-ability-descriptions", diff --git a/templates/partials/hazardView.hbs b/templates/partials/hazardView.hbs index e0140d7..bce8c28 100644 --- a/templates/partials/hazardView.hbs +++ b/templates/partials/hazardView.hbs @@ -304,7 +304,7 @@
- +
{{localize "PF2EBestiary.Bestiary.Miscellaneous.RecallKnowledgeAttempts"}}
diff --git a/templates/partials/monsterView.hbs b/templates/partials/monsterView.hbs index 68befec..13d205a 100644 --- a/templates/partials/monsterView.hbs +++ b/templates/partials/monsterView.hbs @@ -305,7 +305,7 @@
- +
{{localize "PF2EBestiary.Bestiary.Miscellaneous.RecallKnowledgeAttempts"}}
diff --git a/templates/partials/npcView.hbs b/templates/partials/npcView.hbs index f2cb9b6..479ed07 100644 --- a/templates/partials/npcView.hbs +++ b/templates/partials/npcView.hbs @@ -12,9 +12,9 @@ {{> "modules/pf2e-bestiary-tracking/templates/partials/toggleInputSection.hbs" icon="fa-solid fa-left-right" title="PF2EBestiary.Bestiary.NPC.Weight" editMode=this.npcState.editMode path="system.npcData.general.weight" data=this.general.weight }} {{/if}}
-
+
- +
{{localize "PF2EBestiary.Bestiary.NPC.Dispositions"}}
@@ -40,7 +40,7 @@
- +
{{localize "PF2EBestiary.Bestiary.Miscellaneous.RecallKnowledgeAttempts"}}
@@ -78,7 +78,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.GMPlayersContainerTitle"}}
@@ -101,7 +101,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.PremiseLabel"}}
@@ -188,7 +188,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Background"}}
@@ -216,7 +216,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Discovery"}}
{{#if this.npcState.editMode}}{{/if}} @@ -256,7 +256,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.InfluenceSkills"}}
{{#if this.npcState.editMode}}{{/if}} @@ -319,7 +319,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Influence"}}
@@ -368,7 +368,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Weaknesses"}}
{{#if this.npcState.editMode}}{{/if}} @@ -412,7 +412,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Resistances"}}
{{#if this.npcState.editMode}}{{/if}} @@ -456,7 +456,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Penalties"}}
{{#if this.npcState.editMode}}{{/if}} diff --git a/templates/partials/pcPersonality.hbs b/templates/partials/pcPersonality.hbs index 669512b..a1900e9 100644 --- a/templates/partials/pcPersonality.hbs +++ b/templates/partials/pcPersonality.hbs @@ -1,7 +1,7 @@
- +
{{localize "PF2EBestiary.Bestiary.NPC.Personality"}}
diff --git a/templates/partials/toggleInputSection.hbs b/templates/partials/toggleInputSection.hbs index 6264612..36f8096 100644 --- a/templates/partials/toggleInputSection.hbs +++ b/templates/partials/toggleInputSection.hbs @@ -2,7 +2,7 @@
- +
{{localize title}}
{{#if (and (not this.noEdit) (and this.user.isGM editMode))}} diff --git a/templates/partials/toggleTextSection.hbs b/templates/partials/toggleTextSection.hbs index 165cc78..18b41e9 100644 --- a/templates/partials/toggleTextSection.hbs +++ b/templates/partials/toggleTextSection.hbs @@ -1,7 +1,7 @@
- +
{{localize title}}