mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-11 19:25:21 +01:00
Feature: add methods for generate tags and labels for documents and actions (#499)
* FEAT: getTags and getLabels for weapons items * FEAT: add _gettags and _getLabels to armor, domainCard, weapons and ActiveEffect * define tags for actions --------- Co-authored-by: Joaquin Pereyra <joaquinpereyra98@users.noreply.github.com>
This commit is contained in:
parent
9d025bf105
commit
a27ee1578e
8 changed files with 237 additions and 165 deletions
|
|
@ -240,7 +240,7 @@ export const updateActorTokens = async (actor, update) => {
|
|||
* Retrieves a Foundry document associated with the nearest ancestor element
|
||||
* that has a `data-item-uuid` attribute.
|
||||
* @param {HTMLElement} element - The DOM element to start the search from.
|
||||
* @returns {foundry.abstract.Document|null} The resolved document, or null if not found or invalid.
|
||||
* @returns {Promise<foundry.abstract.Document|null>} The resolved document, or null if not found or invalid.
|
||||
*/
|
||||
export async function getDocFromElement(element) {
|
||||
const target = element.closest('[data-item-uuid]');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue