diff --git a/builder.go b/builder.go index 7e729c9..a22bfbf 100644 --- a/builder.go +++ b/builder.go @@ -241,3 +241,56 @@ func (c *ComponentEmoji) SetAnimated(animated bool) *ComponentEmoji { c.Animated = animated return c } + +// TextInputBuilder creates a new TextInput struct. +func TextInputBuilder() *TextInput { + return &TextInput{} +} + +// SetCustomID sets customID for TextInput. +func (t *TextInput) SetCustomID(customID string) *TextInput { + t.CustomID = customID + return t +} + +// SetStyle sets style for TextInput. +func (t *TextInput) SetStyle(style TextInputStyle) *TextInput { + t.Style = style + return t +} + +// SetLabel sets label for TextInput. +func (t *TextInput) SetLabel(label string) *TextInput { + t.Label = label + return t +} + +// SetMinLength sets min length for TextInput. +func (t *TextInput) SetMinLength(minLength int) *TextInput { + t.MinLength = minLength + return t +} + +// SetMaxLength sets max length for TextInput. +func (t *TextInput) SetMaxLength(maxLength int) *TextInput { + t.MaxLength = maxLength + return t +} + +// SetRequired sets required for TextInput. +func (t *TextInput) SetRequired(required bool) *TextInput { + t.Required = required + return t +} + +// SetValue sets value for TextInput. +func (t *TextInput) SetValue(value string) *TextInput { + t.Value = value + return t +} + +// SetPlaceholder sets placeholder for TextInput. +func (t *TextInput) SetPlaceholder(placeholder string) *TextInput { + t.Placeholder = placeholder + return t +}