Skip to content

FileSuggestManager

Unofficial

File suggest manager.

Import:

import type { FileSuggestManager } from '@obsidian-typings/obsidian-catalyst-latest';

Signature:

export interface FileSuggestManager

Properties

PropertyTypeDescription
appAppReference to the app.
fileSuggestionsFileSuggestion[] | nullSelection of files and their paths that can be matched to.
globalbooleanWhether search should be vault-wide rather than scoped to current file.
mode'block' | 'display' | 'file' | 'heading' | stringType of suggestions that should be provided.
runnablenull | RunnableExecutor of the search.

Methods

MethodReturnsDescription
getBlockSuggestions(runner, file, text)Promise<SearchResult[]>Get suggestions for block query.
getDisplaySuggestions(runner, linkpath, subpath, alias)Promise<SearchResult[]>Get suggestions for display alias query.
getFileSuggestions(runner, text)Promise<SearchResult[]>Get suggestions for file query.
getGlobalBlockSuggestions(runner, text)Promise<SearchResult[]>Get suggestions for global block query.
getGlobalHeadingSuggestions(runner, text)Promise<SearchResult[]>Get suggestions for global heading query.
getHeadingSuggestions(runner, file, text)Promise<SearchResult[]>Get suggestions for file heading query.
getInstructions()[Instruction]Generate instructions for specific actions in suggestion manager (e.g. accept, select, ...).
getSourcePath()null | stringDetermine the source path of current context.
getSuggestionsAsync(runner, text)Promise<SearchResult[]>Get suggestions for current input text.
matchBlock(path, file, block, sourcePath, content, textParts)null | SearchResultMatch search fragments to a block.

Links to this page: