MenuItem.setWarning method
MenuItem › setWarning
Unofficial
Add warning styling to the menu item.Signature:
setWarning(warning: boolean): thisParameters:
| Parameter | Type | Description |
|---|---|---|
| warning | boolean | Whether the menu item should be styled as a warning. If set to true the {@link obsidian#MenuItem}'s title and icon will become red. Or whatever color is applied to the class 'is-warning' by a theme. |
Returns: this — The menu item instance.
Since: 0.15.0