Skip to content

SettingDefinitionAction

Official

A setting definition that renders an action row (clickable button or link).

Import:

import type { SettingDefinitionAction } from 'obsidian';

Signature:

export interface SettingDefinitionAction extends SettingDefinitionBase

Extends: SettingDefinitionBase

Properties

PropertyTypeDescription
action(el: HTMLElement, index: number) => voidCallback invoked when the action setting is clicked. Receives the row element and the row's current index within its parent group or list.
aliases?string[]Additional search terms.
(Inherited from SettingDefinitionBase)
control?neverForbidden discriminant key — set only on SettingDefinitionControl.
desc?DocumentFragment | stringDescription text or fragment. Used for rendering; the textContent of a fragment is used for search.
(Inherited from SettingDefinitionBase)
disabled?(() => boolean) | booleanDisables the row. Evaluated on each render. Call update() on the setting tab to re-evaluate.
namestringDisplay name — used for rendering and search.
(Inherited from SettingDefinitionBase)
render?neverForbidden discriminant key — set only on SettingDefinitionRender.
searchable?(() => boolean) | booleanControls search visibility. false or () => false excludes from search.
(Inherited from SettingDefinitionBase)
visible?(() => boolean) | booleanControls whether the item is rendered. false or () => false hides the item and also excludes it from search for that render cycle. Evaluated on each render; call update() on the setting tab to re-evaluate after the underlying state changes.
(Inherited from SettingDefinitionBase)

Links to this page: