Table of Contents

Class ModalComponentAttribute

Namespace
Discord.Interactions
Assembly
Discord.Net.Interactions.dll

Mark an IModal property as a modal component field.

[AttributeUsage(AttributeTargets.Property, AllowMultiple = false, Inherited = false)]
public abstract class ModalComponentAttribute : Attribute
Inheritance
ModalComponentAttribute
Derived
Inherited Members

Properties

ComponentType

Gets the type of the component.

public abstract ComponentType ComponentType { get; }

Property Value

ComponentType

Id

Gets the optional identifier for component.

public int Id { get; set; }

Property Value

int

Remarks

Sending components with an id of 0 is allowed but will be treated as empty and replaced by the API.