Amélioration de la feuille de personnages #547

Merged
uberwald merged 7 commits from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5 2022-08-28 08:40:51 +02:00
Showing only changes of commit 6e361a5531 - Show all commits

View File

@ -432,14 +432,17 @@ export class RdDActorSheet extends ActorSheet {
} }
}) })
.keyup(async event => { .keyup(async event => {
this.options.recherche = this._optionRecherche(event.currentTarget) const nouvelleRecherche = this._optionRecherche(event.currentTarget);
if (this.timerRecherche) { if (this.options.recherche?.text != nouvelleRecherche?.text){
clearTimeout(this.timerRecherche); this.options.recherche = nouvelleRecherche;
if (this.timerRecherche) {
clearTimeout(this.timerRecherche);
}
this.timerRecherche = setTimeout(() => {
this.timerRecherche = undefined;
this.render(true);
}, 500);
} }
this.timerRecherche = setTimeout(() => {
this.timerRecherche = undefined;
this.render(true);
}, 500);
}) })
.change(async event => .change(async event =>
this.options.recherche = this._optionRecherche(event.currentTarget) this.options.recherche = this._optionRecherche(event.currentTarget)