DropDownCommand
A dropdown command shown in a SuggestModal’s instruction bar and bound to a modifier+key shortcut that cycles through its options.
Import:
import type { DropDownCommand } from 'obsidian-dev-utils/obsidian/modals/suggest-modal-command-builder';Signature:
export interface DropDownCommandProperties
| Property | Type | Description |
|---|---|---|
| key | string | The key that cycles the dropdown to its next option. |
| modifiers? | Modifier[] | The modifiers combined with DropDownCommand.key to cycle the dropdown. When omitted, no modifiers are required. |
| purpose | string | The human-readable description shown next to the dropdown in the instruction bar. |
Methods
| Method | Returns | Description |
|---|---|---|
| onChange(value) | void | Called when the dropdown value changes. |
| onInit(dropdownComponent) | void | Called once with the created dropdown component, to initialize its options and state. |