Preview environment

interface APITextInputComponent

export interface APITextInputComponent extends APIBaseComponent<ComponentType.TextInput>

https://discord.com/developers/docs/interactions/message-components#text-inputs-text-input-structure

custom_id : string

The custom id for the text input

label : string

Text that appears on top of the text input field, max 45 characters

optional
max_length? : number

Maximal length of text input

optional
min_length? : number

Minimal length of text input

optional
placeholder? : string

Placeholder for the text input

optional
required? : boolean

Whether or not this text input is required or not

One of text input styles

type : T

The type of the component

Inherited from: APIBaseComponent

optional
value? : string

The pre-filled text in the text input