Struct TextInput
zaun_bot::TextInput · Struct
pub struct TextInput(…)Builds a types::TextInput for a modal.
Methods
Section titled “Methods”pub fn short<impl Into<String>>(custom_id: impl Into<String>) -> SelfA one-line input.
paragraph
Section titled “paragraph”pub fn paragraph<impl Into<String>>(custom_id: impl Into<String>) -> SelfA multi-line input.
length
Section titled “length”pub fn length(self, min: u16, max: u16) -> SelfLength bounds (0–4 000).
required
Section titled “required”pub fn required(self, required: bool) -> SelfWhether it must be filled (default true).
placeholder
Section titled “placeholder”pub fn placeholder<impl Into<String>>(self, text: impl Into<String>) -> SelfPlaceholder (≤ 100).
pub fn value<impl Into<String>>(self, text: impl Into<String>) -> SelfPre-filled value.
Trait implementations
Section titled “Trait implementations”Clone, Debug