Skip to content
Sheetwrite

@sheetwrite/core/testing

shownSuggestionfunction

Report a problem

On this page

What the formula bar shows of suggestion after text, or null.

While the function list is open, a suggestion shows only when it starts with what one entry inserts (its name and (): that entry becomes the active one, so the list and the ghost agree. A ghost on screen (previous) stays while the user types its next characters, shortened by them, unless another suggestion shows instead; a mismatch drops it. A shown ghost takes Tab while the list's active entry is the one it showed with.

Declaration

function shownSuggestion(
text: string,
analysis: Pick<FormulaAnalysis, "completion">,
suggestion: FormulaSuggestion | null,
previous?: GhostOnScreen | null,
): ShownSuggestion | null

Parameters

text: stringrequired
analysis: Pick<FormulaAnalysis, "completion">required
suggestion: FormulaSuggestion | nullrequired
previous?: GhostOnScreen | nulloptional

Returns