Skip to content

PopoverField<Key>

A single text field of a editFieldsInPopover popover.

Import:

import type { PopoverField } from '@mnaoumov/obsidian-lib/popovers/field-popover';

Signature:

export interface PopoverField<Key extends string>

Properties

PropertyTypeDescription
defaultValue?stringA value to pre-fill the field with.
keyKeyThe key the field's value is returned under.
namestringThe label shown next to the field.
onCreate?(textComponent: TextComponent) => voidCalled with the field's text component once it is built and filled, before the popover is placed. Use it to attach a suggest to the input, such as a LinkPathInputSuggest; a pick in its list does not dismiss the popover.
placeholder?stringA placeholder text for the field.

Links to this page: