Recherche plein texte dans le contenu des schémas
- /api/search cherche dans les noms et dans le texte des schémas (textes et libellés, noms de cadres, liens) ; tous les mots requis, casse et accents ignorés, correspondances sur le nom en premier. - Index en mémoire côté serveur : texte extrait à la première recherche, relu seulement si le fichier change (date ou taille), rien d'écrit sur le volume. - L'explorateur affiche l'extrait correspondant sous le nom. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H6J7vKwXx7uopxKhWfFJpm
This commit is contained in:
1 parent
9f9ec3b3a4
commit
c78df092c1
8 files changed
+329
-45
No files matched your search
+6
-1
@@ -8,6 +8,11 @@ export interface Entry {
|
||||
modTime: string;
|
||||
}
|
||||
|
||||
/** Résultat de recherche ; snippet = extrait du contenu qui correspond. */
|
||||
export interface Hit extends Entry {
|
||||
snippet?: string;
|
||||
}
|
||||
|
||||
export interface MoveResult {
|
||||
from: string;
|
||||
to?: string;
|
||||
@@ -72,7 +77,7 @@ export const api = {
|
||||
list: async (dir: string): Promise<Entry[]> =>
|
||||
(await request(`/api/list?path=${q(dir)}`)).json(),
|
||||
|
||||
search: async (text: string): Promise<Entry[]> =>
|
||||
search: async (text: string): Promise<Hit[]> =>
|
||||
(await request(`/api/search?q=${q(text)}`)).json(),
|
||||
|
||||
read: async (path: string): Promise<{ text: string; etag: string }> => {
|
||||
|
||||
Reference in new issue
Block a user