Class DiscordTextInputComponent
- Namespace
- DisCatSharp.Entities
- Assembly
- DisCatSharp.dll
Represents a text input component that can be submitted. Fires ComponentInteractionCreated event when submitted.
public sealed class DiscordTextInputComponent : DiscordComponent, ILabelComponent
- Inheritance
-
DiscordTextInputComponent
- Implements
- Inherited Members
Constructors
- DiscordTextInputComponent(DiscordTextInputComponent)
Constructs a new text component based on another text component.
- DiscordTextInputComponent(TextComponentStyle, string?, string?, int?, int?, bool, string)
Constructs a new text component field with the specified options.
- DiscordTextInputComponent(TextComponentStyle, string, string?, string?, int?, int?, bool, string)
Constructs a new text component field with the specified options.
Properties
- Label
The text description to apply to the text component.
- MaxLength
The maximal length of text input.
- MinLength
The minimal length of text input. Defaults to 0.
- Placeholder
The placeholder for the text component.
- Required
Whether this text component is required. Defaults to true.
- Style
The style of the text component.
- Value
The pre-filled value for the text component.
Methods
- WithId(int)
Assigns a unique id to the components.