resolved an issue with the button not working
This commit is contained in:
parent
088ea79995
commit
64e3cc4f05
2 changed files with 10 additions and 3 deletions
|
|
@ -2,7 +2,7 @@
|
|||
"id": "duality-roller",
|
||||
"title": "Duality Dice Roller",
|
||||
"description": "Adds a button next to the chat dice/controls that triggers the /dr command for the Foundryborne Daggerheart system.",
|
||||
"version": "0.1.2",
|
||||
"version": "0.1.3",
|
||||
"compatibility": {
|
||||
"minimum": "13",
|
||||
"verified": "13"
|
||||
|
|
@ -16,5 +16,5 @@
|
|||
"languages": [],
|
||||
"url": "https://github.com/cptn-cosmo/DualityDiceRoller",
|
||||
"manifest": "https://github.com/cptn-cosmo/DualityDiceRoller/releases/latest/download/module.json",
|
||||
"download": "https://github.com/cptn-cosmo/DualityDiceRoller/releases/download/0.1.2/duality-roller.zip"
|
||||
"download": "https://github.com/cptn-cosmo/DualityDiceRoller/releases/download/0.1.3/duality-roller.zip"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,7 +61,14 @@ function addDRButton(html) {
|
|||
await runDRCommand();
|
||||
});
|
||||
|
||||
container.appendChild(btn); // fallback if fewer than 4 buttons
|
||||
// Append the button at the end of the roll-privacy div
|
||||
const rollPrivacyDiv = container.querySelector("#roll-privacy");
|
||||
if (rollPrivacyDiv) {
|
||||
rollPrivacyDiv.appendChild(btn);
|
||||
} else {
|
||||
container.appendChild(btn); // fallback if the div doesn't exist
|
||||
}
|
||||
|
||||
} catch (err) {
|
||||
console.error("DR Quick Button | addDRButton error:", err);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue