mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-16 05:31:07 +01:00
.
This commit is contained in:
parent
59a4f15680
commit
2f344c90e4
2 changed files with 8 additions and 14 deletions
|
|
@ -13,15 +13,14 @@ export default class CountdownEdit extends HandlebarsApplicationMixin(Applicatio
|
||||||
this.hideNewCountdowns = false;
|
this.hideNewCountdowns = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
get title() {
|
|
||||||
return game.i18n.localize('DAGGERHEART.APPLICATIONS.CountdownEdit.title');
|
|
||||||
}
|
|
||||||
|
|
||||||
static DEFAULT_OPTIONS = {
|
static DEFAULT_OPTIONS = {
|
||||||
classes: ['daggerheart', 'dialog', 'dh-style', 'countdown-edit'],
|
classes: ['daggerheart', 'dialog', 'dh-style', 'countdown-edit'],
|
||||||
tag: 'form',
|
tag: 'form',
|
||||||
position: { width: 600 },
|
position: { width: 600 },
|
||||||
window: { icon: 'fa-solid fa-clock-rotate-left' },
|
window: {
|
||||||
|
title: 'DAGGERHEART.APPLICATIONS.CountdownEdit.title',
|
||||||
|
icon: 'fa-solid fa-clock-rotate-left'
|
||||||
|
},
|
||||||
actions: {
|
actions: {
|
||||||
addCountdown: CountdownEdit.#addCountdown,
|
addCountdown: CountdownEdit.#addCountdown,
|
||||||
toggleCountdownEdit: CountdownEdit.#toggleCountdownEdit,
|
toggleCountdownEdit: CountdownEdit.#toggleCountdownEdit,
|
||||||
|
|
@ -83,8 +82,7 @@ export default class CountdownEdit extends HandlebarsApplicationMixin(Applicatio
|
||||||
canPerformEdit() {
|
canPerformEdit() {
|
||||||
if (game.user.isGM) return true;
|
if (game.user.isGM) return true;
|
||||||
|
|
||||||
const noGM = !game.users.find(x => x.isGM && x.active);
|
if (!game.users.activeGM) {
|
||||||
if (noGM) {
|
|
||||||
ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.gmRequired'));
|
ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.gmRequired'));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ export default class DhCountdowns extends HandlebarsApplicationMixin(Application
|
||||||
window: {
|
window: {
|
||||||
icon: 'fa-solid fa-clock-rotate-left',
|
icon: 'fa-solid fa-clock-rotate-left',
|
||||||
frame: true,
|
frame: true,
|
||||||
title: 'Fear',
|
title: 'DAGGERHEART.UI.Countdowns.title',
|
||||||
positioned: false,
|
positioned: false,
|
||||||
resizable: false,
|
resizable: false,
|
||||||
minimizable: false
|
minimizable: false
|
||||||
|
|
@ -50,10 +50,6 @@ export default class DhCountdowns extends HandlebarsApplicationMixin(Application
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
get title() {
|
|
||||||
return game.i18n.localize('DAGGERHEART.UI.Countdowns.title');
|
|
||||||
}
|
|
||||||
|
|
||||||
get element() {
|
get element() {
|
||||||
return document.body.querySelector('.daggerheart.dh-style.countdowns');
|
return document.body.querySelector('.daggerheart.dh-style.countdowns');
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue