@hunteroi/discord-form
    Preparing search index...

    Interface TextInputFormEntry

    A form entry using a text input component. Supports short (single-line) or paragraph (multi-line) input styles.

    interface TextInputFormEntry {
        answer?: string | number | boolean;
        componentType: "text_input";
        customId: string;
        description?: string;
        label: string;
        parser: (answer: string | string[]) => string | number | boolean;
        raw?: string | string[];
        responseType: "string" | "number" | "boolean";
    }

    Hierarchy (View Summary)

    • FormEntryBase<string | number | boolean>
    • Omit<TextInputComponentData, "label" | "value" | "customId" | "type">
      • TextInputFormEntry
    Index

    Properties

    answer?: string | number | boolean

    The parsed answer with proper typing.

    FormEntryBase

    componentType: "text_input"

    The component type identifier.

    TextInputFormEntry

    customId: string

    The unique identifier for this form entry.

    FormEntryBase

    description?: string

    Optional description to provide additional context. Max 100 characters. Displayed under the label.

    FormEntryBase

    label: string

    The label displayed to the user. For text inputs and file uploads: shown in the label component For select menus: shown in the label component

    FormEntryBase

    parser: (answer: string | string[]) => string | number | boolean

    The parser function to transform the response(s) to the proper type.

    FormEntryBase

    raw?: string | string[]

    The raw value(s) of the entry as returned by Discord.

    FormEntryBase

    responseType: "string" | "number" | "boolean"

    The expected response type after parsing.

    TextInputFormEntry