mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 10:02:59 +08:00
chore: get rid of bootstrap related ts-ignore
This commit is contained in:
parent
cdb988ff64
commit
a0442ded58
@ -101,10 +101,8 @@ export default class RevisionsDialog extends BasicWidget {
|
||||
private note: FNote | null;
|
||||
private revisionId: string | null;
|
||||
|
||||
//@ts-ignore
|
||||
private modal: Modal;
|
||||
//@ts-ignore
|
||||
private listDropdown: Dropdown;
|
||||
private modal!: Modal;
|
||||
private listDropdown!: Dropdown;
|
||||
|
||||
private $list!: JQuery<HTMLElement>;
|
||||
private $listDropdown!: JQuery<HTMLElement>;
|
||||
@ -126,13 +124,13 @@ export default class RevisionsDialog extends BasicWidget {
|
||||
|
||||
doRender() {
|
||||
this.$widget = $(TPL);
|
||||
//@ts-ignore
|
||||
this.modal = Modal.getOrCreateInstance(this.$widget);
|
||||
|
||||
this.modal = Modal.getOrCreateInstance(this.$widget[0]);
|
||||
|
||||
this.$list = this.$widget.find(".revision-list");
|
||||
this.$listDropdown = this.$widget.find(".revision-list-dropdown");
|
||||
//@ts-ignore
|
||||
this.listDropdown = Dropdown.getOrCreateInstance(this.$listDropdown, { autoClose: false });
|
||||
|
||||
this.listDropdown = Dropdown.getOrCreateInstance(this.$listDropdown[0], { autoClose: false });
|
||||
this.$content = this.$widget.find(".revision-content");
|
||||
this.$title = this.$widget.find(".revision-title");
|
||||
this.$titleButtons = this.$widget.find(".revision-title-buttons");
|
||||
|
@ -88,8 +88,7 @@ export default class NoteTypeWidget extends NoteContextAwareWidget {
|
||||
doRender() {
|
||||
this.$widget = $(TPL);
|
||||
|
||||
//@ts-ignore
|
||||
this.dropdown = Dropdown.getOrCreateInstance(this.$widget.find("[data-bs-toggle='dropdown']"));
|
||||
this.dropdown = Dropdown.getOrCreateInstance(this.$widget.find("[data-bs-toggle='dropdown']")[0]);
|
||||
|
||||
this.$widget.on("show.bs.dropdown", () => this.renderDropdown());
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user