Skip to content

FileSuggestManager

Unofficial

File suggest manager.

Import:

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

Signature:

export interface FileSuggestManager

Properties

Property Type Description
app App Reference to the app.
fileSuggestions FileSuggestion[] | null Selection of files and their paths that can be matched to.
global boolean Whether search should be vault-wide rather than scoped to current file.
mode 'block' | 'display' | 'file' | 'heading' | string Type of suggestions that should be provided.
runnable null | Runnable Executor of the search.

Methods

Method Returns Description
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 | string Determine 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 | SearchResult Match search fragments to a block.

Links to this page: