Trevixal API
    Preparing search index...

    Interface ViewActions

    interface ViewActions {
        activeKeyPreset?: () => "standard" | "emacs" | "vim";
        activeLanguage?: () => string;
        activeSourceMode?: () => "html" | "markdown" | null;
        activeTheme?: () => string;
        activeToolbarPreset?: () => ToolbarPreset | null;
        activeWidth?: () => "normal" | "full" | "narrow" | "wide";
        addComment?: () => void;
        assist?: (
            action: "rewrite" | "summarise" | "translate" | "continue",
        ) => void;
        assistActions?: readonly (
            "rewrite"
            | "summarise"
            | "translate"
            | "continue"
        )[];
        autocorrectOptions?: () => void;
        checkAccessibility?: () => void;
        copyCode?: (editor: Editor) => void;
        customCSS?: () => void;
        customizeToolbar?: () => void;
        customTheme?: () => void;
        documentFonts?: () => void;
        exportTheme?: () => void;
        findDuplicateText?: () => void;
        formatPainter?: (editor: Editor) => void;
        importTheme?: () => void;
        insertEmoji?: (editor: Editor) => void;
        insertFormField?: (
            kind: "text" | "checkbox" | "date" | "dropdown" | "signature",
        ) => void;
        isSpellcheckEnabled?: () => boolean;
        isViewToggleOn?: (toggle: ViewToggle) => boolean;
        isWritingCheckEnabled?: (kind: WritingCheckKind) => boolean;
        languages?: readonly string[];
        mailMerge?: () => void;
        manageFonts?: () => void;
        openCommandPalette?: (editor: Editor) => void;
        present?: () => void;
        setKeyPreset?: (preset: "standard" | "emacs" | "vim") => void;
        setLanguage?: (code: string) => void;
        setTheme?: (theme: "light" | "dark" | "system") => void;
        setThemePreset?: (preset: string | null) => void;
        setToolbarPreset?: (preset: ToolbarPreset) => void;
        setWidth?: (width: "normal" | "full" | "narrow" | "wide") => void;
        setWritingGoal?: () => void;
        showAbout?: () => void;
        showAuditLog?: () => void;
        showKeyboardShortcuts?: () => void;
        showWritingStats?: () => void;
        toggleAutocorrect?: () => void;
        toggleComments?: () => void;
        toggleDictation?: () => void;
        toggleDocumentTheme?: () => void;
        toggleDyslexiaFont?: () => void;
        toggleFocusMode?: () => void;
        toggleFullscreen?: () => void;
        toggleFullscreenScreenWidth?: () => void;
        toggleHistoryPanel?: () => void;
        toggleOutline?: () => void;
        togglePageMode?: () => void;
        toggleReadAloud?: () => void;
        toggleReadingHeatmap?: () => void;
        toggleReadOnly?: () => void;
        toggleReducedMotion?: () => void;
        toggleSmartTypography?: () => void;
        toggleSourceMode?: (format: "html" | "markdown") => void;
        toggleSpellcheck?: () => void;
        toggleSplitEditor?: () => void;
        toggleSplitPreview?: () => void;
        toggleStylesPane?: () => void;
        toggleTableOfContents?: () => void;
        toggleTrackChanges?: () => void;
        toggleTypewriter?: () => void;
        toggleWorkspace?: () => void;
        toggleWritingAssistant?: () => void;
        toggleWritingCheck?: (kind: WritingCheckKind) => void;
    }
    Index
    activeKeyPreset?: () => "standard" | "emacs" | "vim"

    The key preset in force, so its entry under Tools ▸ Key bindings shows the tick.

    activeLanguage?: () => string

    The language in force, so its entry under View ▸ Language shows the tick.

    activeSourceMode?: () => "html" | "markdown" | null

    The source format on show, or null while the rich surface is up.

    activeTheme?: () => string

    The theme now in force, as the name of its menu entry ('themeDark', 'themeNord'…). The theme entries behave as one radio group, so exactly one of them carries the tick.

    activeToolbarPreset?: () => ToolbarPreset | null

    The preset the toolbar matches, if any, so its entry shows the tick.

    activeWidth?: () => "normal" | "full" | "narrow" | "wide"

    The width now in force, so the four width entries show which is chosen.

    addComment?: () => void

    Comment on the selected text: @trevixal/extension-comments keeps the threads.

    assist?: (action: "rewrite" | "summarise" | "translate" | "continue") => void

    Ask the host's writing assistant to rewrite, summarise or translate the selection, or to continue from the caret. Only the actions named in assistActions get an entry.

    assistActions?: readonly ("rewrite" | "summarise" | "translate" | "continue")[]
    autocorrectOptions?: () => void

    Edit the AutoCorrect list.

    checkAccessibility?: () => void

    List what would trip up a reader with a screen reader or low vision.

    copyCode?: (editor: Editor) => void
    customCSS?: () => void
    customizeToolbar?: () => void
    customTheme?: () => void
    documentFonts?: () => void

    Choose the document's body and heading fonts, saved in its styles.

    exportTheme?: () => void

    Download the theme in force as a JSON file.

    findDuplicateText?: () => void

    List the sentences other documents in the workspace also have.

    formatPainter?: (editor: Editor) => void
    importTheme?: () => void

    Read a theme from a JSON file and apply it.

    insertEmoji?: (editor: Editor) => void
    insertFormField?: (
        kind: "text" | "checkbox" | "date" | "dropdown" | "signature",
    ) => void

    Put a form field in at the caret: @trevixal/extension-forms holds it.

    isSpellcheckEnabled?: () => boolean

    Whether spell checking is on, so its menu entry reports the state it toggles.

    isViewToggleOn?: (toggle: ViewToggle) => boolean

    Whether a piece of chrome is currently on, so its menu entry can show a tick. Without it every one of these entries looks the same whether it is on or off, and the menu stops being a place you can read the editor's state from. You have to toggle something to find out what it was.

    The host owns this chrome, so only the host can answer. Anything left unanswered simply renders as a plain command, exactly as before.

    isWritingCheckEnabled?: (kind: WritingCheckKind) => boolean

    Whether a check is on, so its menu entry shows a check mark.

    languages?: readonly string[]

    The codes setLanguage can switch to; entries for the rest are left out.

    mailMerge?: () => void

    One document per row of a CSV or JSON file, downloaded together.

    manageFonts?: () => void
    openCommandPalette?: (editor: Editor) => void
    present?: () => void

    Show the document as slides, one top-level heading each.

    setKeyPreset?: (preset: "standard" | "emacs" | "vim") => void

    Standard keys, or Emacs's or Vim's for moving and editing.

    setLanguage?: (code: string) => void

    Show the chrome in another language, by its code in UI_LANGUAGES.

    setTheme?: (theme: "light" | "dark" | "system") => void
    setThemePreset?: (preset: string | null) => void

    Apply a named palette from createThemeController, or null for the plain one.

    setToolbarPreset?: (preset: ToolbarPreset) => void

    Show a preset's toolbar groups and hide the rest.

    setWidth?: (width: "normal" | "full" | "narrow" | "wide") => void
    setWritingGoal?: () => void
    showAbout?: () => void
    showAuditLog?: () => void

    Who changed the document, when, and by how much, with a download of it.

    showKeyboardShortcuts?: () => void
    showWritingStats?: () => void
    toggleAutocorrect?: () => void

    Misspellings put right as you type (Word's AutoCorrect), on or off.

    toggleComments?: () => void

    Show or hide the comment threads beside the document.

    toggleDictation?: () => void

    Type what the microphone hears at the caret, or stop.

    toggleDocumentTheme?: () => void

    Keep the theme in force with the document, or stop keeping it.

    toggleDyslexiaFont?: () => void

    A font and spacing easier to read with dyslexia, or the document's own.

    toggleFocusMode?: () => void
    toggleFullscreen?: () => void
    toggleFullscreenScreenWidth?: () => void

    Fullscreen across the whole screen, the document stretching with the window, where toggleFullscreen keeps it at its own width.

    toggleHistoryPanel?: () => void
    toggleOutline?: () => void
    togglePageMode?: () => void
    toggleReadAloud?: () => void

    Read the document aloud from the caret, the caret following the voice, or stop.

    toggleReadingHeatmap?: () => void

    Tint each sentence by how hard it reads, or take the tint off.

    toggleReadOnly?: () => void
    toggleReducedMotion?: () => void

    Transitions, animations and smooth scrolling off, or back on.

    toggleSmartTypography?: () => void

    Curly quotes, dashes and symbols as you type (Word's AutoFormat), on or off.

    toggleSourceMode?: (format: "html" | "markdown") => void

    Swap the rich surface for its Markdown or HTML source.

    toggleSpellcheck?: () => void
    toggleSplitEditor?: () => void

    A second live editor on the same document (the workspace's mirror mode).

    toggleSplitPreview?: () => void
    toggleStylesPane?: () => void

    Show or hide the Styles pane, which the host lays out.

    toggleTableOfContents?: () => void
    toggleTrackChanges?: () => void
    toggleTypewriter?: () => void
    toggleWorkspace?: () => void
    toggleWritingAssistant?: () => void
    toggleWritingCheck?: (kind: WritingCheckKind) => void

    Toggle one writing check; each gets its own entry under Tools ▸ Check writing.