mirror of
https://github.com/zadam/trilium.git
synced 2025-11-12 00:05:50 +01:00
chore(client): fix most type errors
This commit is contained in:
@@ -85,7 +85,7 @@ export default class NotePathsWidget extends NoteContextAwareWidget {
|
||||
this.$notePathIntro.text(t("note_paths.intro_not_placed"));
|
||||
}
|
||||
|
||||
const renderedPaths = [];
|
||||
const renderedPaths: JQuery<HTMLElement>[] = [];
|
||||
|
||||
for (const notePathRecord of sortedNotePaths) {
|
||||
const notePath = notePathRecord.notePath;
|
||||
@@ -100,7 +100,7 @@ export default class NotePathsWidget extends NoteContextAwareWidget {
|
||||
const $pathItem = $("<li>");
|
||||
const pathSegments: string[] = [];
|
||||
const lastIndex = notePath.length - 1;
|
||||
|
||||
|
||||
for (let i = 0; i < notePath.length; i++) {
|
||||
const noteId = notePath[i];
|
||||
pathSegments.push(noteId);
|
||||
@@ -109,13 +109,13 @@ export default class NotePathsWidget extends NoteContextAwareWidget {
|
||||
|
||||
$noteLink.find("a").addClass("no-tooltip-preview tn-link");
|
||||
$pathItem.append($noteLink);
|
||||
|
||||
|
||||
if (i != lastIndex) {
|
||||
$pathItem.append(" / ");
|
||||
}
|
||||
}
|
||||
|
||||
const icons = [];
|
||||
const icons: string[] = [];
|
||||
|
||||
if (this.notePath === notePath.join("/")) {
|
||||
$pathItem.addClass("path-current");
|
||||
|
||||
@@ -122,7 +122,7 @@ export default class PromotedAttributesWidget extends NoteContextAwareWidget {
|
||||
return;
|
||||
}
|
||||
|
||||
const $cells = [];
|
||||
const $cells: JQuery<HTMLElement>[] = [];
|
||||
|
||||
for (const definitionAttr of promotedDefAttrs) {
|
||||
const valueType = definitionAttr.name.startsWith("label:") ? "label" : "relation";
|
||||
|
||||
Reference in New Issue
Block a user