Fix layaout
This commit is contained in:
parent
84c44d1f6d
commit
1abb757b6b
@ -9,7 +9,7 @@ export class RdDFauneItemSheet extends RdDItemInventaireSheet {
|
|||||||
|
|
||||||
if (!this.options.editable) return;
|
if (!this.options.editable) return;
|
||||||
|
|
||||||
html.find("a.linked-actor-delete").click(async event => await this.onDeleteLinkedActor());
|
$(html).find("a.linked-actor-delete").click(async event => await this.onDeleteLinkedActor());
|
||||||
}
|
}
|
||||||
|
|
||||||
async _onDropActor(event, dragData) {
|
async _onDropActor(event, dragData) {
|
||||||
|
@ -36,9 +36,9 @@ export class RdDSigneDraconiqueItemSheet extends RdDItemSheetV1 {
|
|||||||
|
|
||||||
if (!this.options.editable) return;
|
if (!this.options.editable) return;
|
||||||
|
|
||||||
html.find(".signe-aleatoire").click(async event => await this.setSigneAleatoire());
|
$(html).find(".signe-aleatoire").click(async event => await this.setSigneAleatoire());
|
||||||
html.find("input.select-tmr").change(async event => await this.onSelectTmr(event));
|
$(html).find("input.select-tmr").change(async event => await this.onSelectTmr(event));
|
||||||
html.find(".signe-xp-sort").change(async event => await this.onValeurXpSort(event.currentTarget.attributes['data-typereussite']?.value, Number(event.currentTarget.value)));
|
$(html).find(".signe-xp-sort").change(async event => await this.onValeurXpSort(event.currentTarget.attributes['data-typereussite']?.value, Number(event.currentTarget.value)));
|
||||||
}
|
}
|
||||||
|
|
||||||
async setSigneAleatoire() {
|
async setSigneAleatoire() {
|
||||||
|
@ -14,8 +14,8 @@ export class RdDTokenHud {
|
|||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
static async removeExtensionHud(app, html, tokenId) {
|
static async removeExtensionHud(app, html, tokenId) {
|
||||||
html.find('.control-icon.rdd-combat').remove();
|
$(html).find('.control-icon.rdd-combat').remove();
|
||||||
html.find('.control-icon.rdd-initiative').remove();
|
$(html).find('.control-icon.rdd-initiative').remove();
|
||||||
}
|
}
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
@ -50,7 +50,7 @@ export class RdDTokenHud {
|
|||||||
{ name: 'Initiative +1', command: 'inc', value: 0.01 },
|
{ name: 'Initiative +1', command: 'inc', value: 0.01 },
|
||||||
{ name: 'Initiative -1', command: 'dec', value: -0.01 }]
|
{ name: 'Initiative -1', command: 'dec', value: -0.01 }]
|
||||||
};
|
};
|
||||||
const controlIconCombat = html.find('.control-icon[data-action=combat]');
|
const controlIconCombat = $(html).find('.control-icon[data-action=combat]');
|
||||||
await RdDTokenHud._configureSubMenu(controlIconCombat,
|
await RdDTokenHud._configureSubMenu(controlIconCombat,
|
||||||
'systems/foundryvtt-reve-de-dragon/templates/hud-actor-init.hbs',
|
'systems/foundryvtt-reve-de-dragon/templates/hud-actor-init.hbs',
|
||||||
hudData,
|
hudData,
|
||||||
@ -69,7 +69,7 @@ export class RdDTokenHud {
|
|||||||
|
|
||||||
static async addExtensionHudCombat(html, combatant, token, actions) {
|
static async addExtensionHudCombat(html, combatant, token, actions) {
|
||||||
const hudData = { combatant, token, actions, commandes: [] };
|
const hudData = { combatant, token, actions, commandes: [] };
|
||||||
const controlIconTarget = html.find('.control-icon[data-action=target]');
|
const controlIconTarget = $(html).find('.control-icon[data-action=target]');
|
||||||
await RdDTokenHud._configureSubMenu(controlIconTarget, 'systems/foundryvtt-reve-de-dragon/templates/hud-actor-attaque.hbs', hudData,
|
await RdDTokenHud._configureSubMenu(controlIconTarget, 'systems/foundryvtt-reve-de-dragon/templates/hud-actor-attaque.hbs', hudData,
|
||||||
(event) => {
|
(event) => {
|
||||||
const actionIndex = event.currentTarget.attributes['data-action-index']?.value;
|
const actionIndex = event.currentTarget.attributes['data-action-index']?.value;
|
||||||
|
@ -776,7 +776,7 @@ export class RdDUtility {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
$(html).on("click", '.rdd-world-content-link', async event => {
|
$(html).on("click", '.rdd-world-content-link', async event => {
|
||||||
const htmlElement = html.find(event.currentTarget);
|
const htmlElement = $(html).find(event.currentTarget);
|
||||||
const id = htmlElement?.data("id");
|
const id = htmlElement?.data("id");
|
||||||
const doctype = htmlElement?.data("doctype");
|
const doctype = htmlElement?.data("doctype");
|
||||||
switch (doctype ?? 'Item') {
|
switch (doctype ?? 'Item') {
|
||||||
|
@ -75,7 +75,7 @@ export class OptionsAvancees extends FormApplication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
html.find(".select-option").click((event) => {
|
$(html).find(".select-option").click((event) => {
|
||||||
if (event.currentTarget.attributes.name) {
|
if (event.currentTarget.attributes.name) {
|
||||||
let id = event.currentTarget.attributes.name.value
|
let id = event.currentTarget.attributes.name.value
|
||||||
let isChecked = event.currentTarget.checked
|
let isChecked = event.currentTarget.checked
|
||||||
@ -88,4 +88,3 @@ export class OptionsAvancees extends FormApplication {
|
|||||||
this.close()
|
this.close()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -112,7 +112,7 @@ export class ReglesOptionnelles extends FormApplication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
html.find(".select-option").click((event) => {
|
$(html).find(".select-option").click((event) => {
|
||||||
if (event.currentTarget.attributes.name) {
|
if (event.currentTarget.attributes.name) {
|
||||||
let id = event.currentTarget.attributes.name.value;
|
let id = event.currentTarget.attributes.name.value;
|
||||||
let isChecked = event.currentTarget.checked;
|
let isChecked = event.currentTarget.checked;
|
||||||
@ -125,4 +125,3 @@ export class ReglesOptionnelles extends FormApplication {
|
|||||||
this.close();
|
this.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -131,7 +131,7 @@ export class StatusEffects extends FormApplication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
html.find(".select-effect").click((event) => {
|
$(html).find(".select-effect").click((event) => {
|
||||||
let id = event.currentTarget.attributes.name?.value;
|
let id = event.currentTarget.attributes.name?.value;
|
||||||
if (id) {
|
if (id) {
|
||||||
let selected = StatusEffects._getUseStatusEffects();
|
let selected = StatusEffects._getUseStatusEffects();
|
||||||
@ -151,4 +151,3 @@ export class StatusEffects extends FormApplication {
|
|||||||
this.close();
|
this.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -184,7 +184,7 @@ export class SystemCompendiums extends FormApplication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
html.find("select.system-compendium-setting").change((event) => {
|
$(html).find("select.system-compendium-setting").change((event) => {
|
||||||
const compendium = $(event.currentTarget).data('compendium')
|
const compendium = $(event.currentTarget).data('compendium')
|
||||||
const value = $(event.currentTarget).val();
|
const value = $(event.currentTarget).val();
|
||||||
const systemCompendium = CONFIGURABLE_COMPENDIUMS[compendium];
|
const systemCompendium = CONFIGURABLE_COMPENDIUMS[compendium];
|
||||||
|
@ -36,7 +36,7 @@ export class DialogChateauDormant extends Dialog {
|
|||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
super.activateListeners(html);
|
super.activateListeners(html);
|
||||||
this.html = html;
|
this.html = $(html);
|
||||||
this.html.find('input.sommeil-insomnie').change(event => this.onInsomnie(event));
|
this.html.find('input.sommeil-insomnie').change(event => this.onInsomnie(event));
|
||||||
this._activateListenerOnActorMoral(this.html);
|
this._activateListenerOnActorMoral(this.html);
|
||||||
}
|
}
|
||||||
|
@ -106,9 +106,9 @@ export class DialogFatigueVoyage extends Dialog {
|
|||||||
|
|
||||||
activateListeners(html) {
|
activateListeners(html) {
|
||||||
if (this.html == undefined) {
|
if (this.html == undefined) {
|
||||||
html.find('select[name="code-terrain"]').trigger("focus")
|
$(html).find('select[name="code-terrain"]').trigger("focus")
|
||||||
}
|
}
|
||||||
this.html = html;
|
this.html = $(html);
|
||||||
super.activateListeners(html);
|
super.activateListeners(html);
|
||||||
|
|
||||||
this.html.find('select[name="code-terrain"]').change(event => this.changeParameters())
|
this.html.find('select[name="code-terrain"]').change(event => this.changeParameters())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user