enhance death roll dialog style (#440)

This commit is contained in:
Murilo Brito 2025-07-28 09:12:42 -03:00 committed by GitHub
parent 6d7401c874
commit 0a944eb3d4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 120 additions and 19 deletions

View file

@ -87,6 +87,26 @@ export default class DhTooltipManager extends foundry.helpers.interaction.Toolti
this.tooltip.innerHTML = html;
}
}
const deathMove = element.dataset.tooltip?.startsWith('#deathMove#');
if (deathMove) {
const name = element.dataset.deathName;
const img = element.dataset.deathImg;
const description = element.dataset.deathDescription;
html = await foundry.applications.handlebars.renderTemplate(
`systems/daggerheart/templates/ui/tooltip/death-move.hbs`,
{
move: { name: name, img: img, description: description }
}
);
this.tooltip.innerHTML = html;
options.direction = this._determineItemTooltipDirection(
element,
this.constructor.TOOLTIP_DIRECTIONS.RIGHT
);
}
}
super.activate(element, { ...options, html: html });