mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-07-08 22:05:16 +02:00
Fix lint: ignore flatpak in biome, fix search cursor iterator usage
This commit is contained in:
+2
-1
@@ -47,7 +47,8 @@
|
|||||||
"!src-web/vite.config.ts",
|
"!src-web/vite.config.ts",
|
||||||
"!src-web/routeTree.gen.ts",
|
"!src-web/routeTree.gen.ts",
|
||||||
"!packages/plugin-runtime-types/lib",
|
"!packages/plugin-runtime-types/lib",
|
||||||
"!**/bindings"
|
"!**/bindings",
|
||||||
|
"!flatpak"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -51,9 +51,10 @@ export function searchMatchCount(): Extension {
|
|||||||
let currentIndex = 0;
|
let currentIndex = 0;
|
||||||
const MAX_COUNT = 9999;
|
const MAX_COUNT = 9999;
|
||||||
const cursor = query.getCursor(state);
|
const cursor = query.getCursor(state);
|
||||||
while (!cursor.next().done) {
|
for (let result = cursor.next(); !result.done; result = cursor.next()) {
|
||||||
count++;
|
count++;
|
||||||
if (cursor.value.from <= selection.from && cursor.value.to >= selection.to) {
|
const match = result.value;
|
||||||
|
if (match.from <= selection.from && match.to >= selection.to) {
|
||||||
currentIndex = count;
|
currentIndex = count;
|
||||||
}
|
}
|
||||||
if (count > MAX_COUNT) break;
|
if (count > MAX_COUNT) break;
|
||||||
|
|||||||
Reference in New Issue
Block a user