import BaseMessage, { BaseInput, MessageTypes } from './Base'; /** * TextInput interface represents a structure for text-based input within a messaging context. * It extends from BaseInput to inherit common properties and enriches them with text-specific attributes. * * @Interface * @property {MessageTypes.TEXT} type - Specifies the type of message, constrained to text in this context. * @property {string} text - Contains the main body of the message, which is a textual content to be processed or displayed. * @property {boolean} [preview_url] - Optional property indicating whether URLs within the text should be previewed, enhancing the user experience by displaying a snippet or preview of the linked content. */ export interface TextInput extends BaseInput { type: MessageTypes.TEXT; text: string; preview_url?: boolean; } /** * Represents a text message with a body and a preview URL option. */ declare class Text { preview_url: boolean; body: string; /** * Constructs a new instance with the specified configuration. * * @param {TextInput} config - The configuration object for the text input. * @param {string|boolean} [config.preview_url] - Determines if a preview URL is provided; defaults to false if not specified. * @param {string} config.text - The text content to be processed, limited to 4096 characters. */ constructor(config: TextInput); } /** * Represents a text message, extending the functionality provided by * the BaseMessage class. This class is designed to handle messages * specifically containing textual content. * * The TextMessage class constructs an instance with a given configuration * that includes text-specific properties encapsulated by the Text class. * * @extends BaseMessage */ export declare class TextMessage extends BaseMessage { text: Text; /** * Constructs a new instance of the class, initializing it with the provided configuration. * * @param {TextInput} config - The configuration object containing settings and initial values for text input. */ constructor(config: TextInput); } export {};