mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-08-11 02:42:27 +08:00
chore(client/ts): fix build errors
This commit is contained in:
parent
7c805eb427
commit
ffa463f1fc
2
src/public/app/types.d.ts
vendored
2
src/public/app/types.d.ts
vendored
@ -95,7 +95,7 @@ declare global {
|
|||||||
className: string;
|
className: string;
|
||||||
separateWordSearch: boolean;
|
separateWordSearch: boolean;
|
||||||
caseSensitive: boolean;
|
caseSensitive: boolean;
|
||||||
done: () => void;
|
done?: () => void;
|
||||||
});
|
});
|
||||||
unmark(opts?: {
|
unmark(opts?: {
|
||||||
done: () => void;
|
done: () => void;
|
||||||
|
@ -305,7 +305,10 @@ export default class FindWidget extends NoteContextAwareWidget {
|
|||||||
const matchCase = this.$caseSensitiveCheckbox.prop("checked");
|
const matchCase = this.$caseSensitiveCheckbox.prop("checked");
|
||||||
const wholeWord = this.$matchWordsCheckbox.prop("checked");
|
const wholeWord = this.$matchWordsCheckbox.prop("checked");
|
||||||
|
|
||||||
const { totalFound, currentFound } = await this.handler?.performFind(searchTerm, matchCase, wholeWord);
|
if (!this.handler) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const { totalFound, currentFound } = await this.handler.performFind(searchTerm, matchCase, wholeWord);
|
||||||
|
|
||||||
this.$totalFound.text(totalFound);
|
this.$totalFound.text(totalFound);
|
||||||
this.$currentFound.text(currentFound);
|
this.$currentFound.text(currentFound);
|
||||||
|
@ -38,7 +38,7 @@ export default class FindInCode {
|
|||||||
// See https://codemirror.net/addon/search/searchcursor.js for tips
|
// See https://codemirror.net/addon/search/searchcursor.js for tips
|
||||||
const codeEditor = await this.getCodeEditor();
|
const codeEditor = await this.getCodeEditor();
|
||||||
if (!codeEditor) {
|
if (!codeEditor) {
|
||||||
return;
|
return { totalFound: 0, currentFound: 0 };
|
||||||
}
|
}
|
||||||
|
|
||||||
const doc = codeEditor.doc;
|
const doc = codeEditor.doc;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user