chore: code quality improvements, update CHANGELOG.md

This commit is contained in:
tobifroe
2025-09-09 12:50:33 +02:00
committed by Tobias Frölich
parent d0b92774e2
commit 0a34c1159b
3 changed files with 14 additions and 5 deletions
+5
View File
@@ -2,11 +2,16 @@
## Version 1.6.1 - ????-??-??
### **Features:**
- [#255](https://github.com/deltagreen-foundryvtt/delta-green-foundry-vtt-system/issues/255) - Added option to toggle display of tooltips per client
### **Bug Fixes:**
- [#259](https://github.com/deltagreen-foundryvtt/delta-green-foundry-vtt-system/issues/259) - Fixed "Keep Sanity Private" setting in agent sheets.
- [#263](https://github.com/deltagreen-foundryvtt/delta-green-foundry-vtt-system/issues/263) - Fixed inability to edit item descriptions.
- [#253](https://github.com/deltagreen-foundryvtt/delta-green-foundry-vtt-system/issues/253) - Close "Automation Menu" & "Handler Settings" when settings are saved.
- [#252](https://github.com/deltagreen-foundryvtt/delta-green-foundry-vtt-system/issues/252) - Removed redundant lines in tooltip texts
## Version 1.6.0 - 2025-09-04
+8 -1
View File
@@ -1,5 +1,6 @@
/* eslint-disable max-classes-per-file */
import DG, { BASE_TEMPLATE_PATH } from "./config.js";
import DGActorSheet from "./sheets/base-actor-sheet.js";
const { ApplicationV2, HandlebarsApplicationMixin } = foundry.applications.api;
@@ -317,9 +318,15 @@ export default function registerSystemSettings() {
hint: game.i18n.localize("DG.Settings.hideSkillTooltips.hint"),
scope: "client",
config: true,
requiresReload: true,
type: Boolean,
default: false,
onChange: () => {
foundry.applications.instances.forEach((app) => {
if (app instanceof DGActorSheet) {
app.render();
}
});
},
});
// obsolete - will be removed at some point
+1 -4
View File
@@ -399,8 +399,7 @@ export default class DGActorSheet extends DGSheetMixin(ActorSheetV2) {
* @returns {void}
*/
_prepareSkillTooltips() {
const skillsWithTooltips = [];
for (const [_, skill] of Object.entries(this.actor.system.sortedSkills)) {
for (const skill of Object.values(this.actor.system.sortedSkills)) {
skill.tooltip = game.i18n.localize(`DG.Skills.Tooltip.${skill.key}`);
if (!skill.proficiency) {
skill.tooltip = skill.tooltip.concat(
@@ -409,9 +408,7 @@ export default class DGActorSheet extends DGSheetMixin(ActorSheetV2) {
game.i18n.localize("DG.Tooltip.CannotRollSkillLabel"),
);
}
skillsWithTooltips.push(skill);
}
this.actor.system.sortedSkills = skillsWithTooltips;
}
/**