Skip to content

ElectronTouchBarButtonConstructorOptions

Unofficial

Options for creating a ElectronTouchBarButton.

Import:

import type { ElectronTouchBarButtonConstructorOptions } from '@obsidian-typings/obsidian-public-latest';

Signature:

export interface ElectronTouchBarButtonConstructorOptions

Properties

Property Type Description
accessibilityLabel? string A short description of the button for use by screen readers like VoiceOver.
backgroundColor? string Button background color in hex format, i.e #ABCDEF.
enabled? boolean Whether the button is in an enabled state.
icon? ElectronNativeImage | string Button icon.
iconPosition? 'left' | 'overlay' | 'right' Position of the icon.
label? string Button text.

Methods

Method Returns Description
click() void Callback invoked when the button is clicked.