import '@oicl/openbridge-webcomponents/dist/components/textarea-field/textarea-field.js'; import type { VoiceActionDetail, TextareaFieldType, Attachment } from '@oicl/openbridge-webcomponents/dist/components/textarea-field/textarea-field.js'; import type { AudioRecordingStatus } from '@oicl/openbridge-webcomponents/dist/components/audio-recording-item/audio-recording-item.js'; import type { Snippet } from 'svelte'; export interface Props { class?: string; style?: string; /** Field type: 'rich' (no send button) or 'message' (with send button). */ type?: TextareaFieldType; /** The current text value of the input field. */ value?: string; /** If true, the textarea will not update its value from external changes while focused. */ rejectUpdatesOnFocus?: boolean; /** If true, the value will only be initially set from the external model and not updated on subsequent changes. */ rejectUpdates?: boolean; /** If true, the textarea will not update its value if the value is the same as the previous value. Useful to avoid React re-rendering resetting the value. */ rejectDuplicateUpdates?: boolean; /** Placeholder text shown when the input is empty. */ placeholder?: string; /** Label text displayed above the input field. */ label?: string; /** Error text displayed below the field when `error` is true. */ errorText?: string; /** Maximum number of characters allowed in the textarea. */ maxlength?: number | undefined; /** Disables the input field and all actions. */ disabled?: boolean; /** Shows error state with visual highlight. */ error?: boolean; /** Shows a required indicator next to the label. */ required?: boolean; /** Shows the label above the input field. */ showLabel?: boolean; /** Shows the toolbar with action buttons. */ showToolbar?: boolean; /** Shows the voice recording button. */ showVoiceRecording?: boolean; /** Shows a leading icon before the input field. */ hasLeadingIcon?: boolean; /** Whether voice recording is currently active. When true, shows the audio-recording-item instead of textarea. */ recording?: boolean; /** Current recording duration in seconds. */ recordingDuration?: number; /** Array of audio level values (0-1) for waveform visualization. New values should be added to the end (right side) and old values shift left. */ audioLevels?: number[]; /** Recording status passed to audio-recording-item. Use 'recording' during active recording, and 'playback' when paused to allow the user to preview the recorded audio with a slider. Automatically reset to 'recording' when `recording` becomes false. */ recordingStatus?: AudioRecordingStatus; /** Current playback position (0-1) for playback mode. Only relevant when recordingStatus is 'playback'. */ playbackPosition?: number; /** Array of file attachments displayed as removable chips. */ attachments?: Attachment[]; } export interface Events { onChange?: (event: CustomEvent<{ value: string; }>) => void; onInput?: (event: CustomEvent<{ value: string; }>) => void; onBlur?: (event: CustomEvent) => void; onSendClick?: (event: CustomEvent<{ value: string; }>) => void; onAddClick?: (event: CustomEvent) => void; onScreenshotClick?: (event: CustomEvent) => void; onImageClick?: (event: CustomEvent) => void; onAttachmentClick?: (event: CustomEvent) => void; onVoiceAction?: (event: CustomEvent) => void; onAttachmentRemove?: (event: CustomEvent<{ id: string; }>) => void; } export interface Slots { leadingIcon?: Snippet; } type $$ComponentProps = Props & Events & Slots; declare const ObcTextareaField: import("svelte").Component<$$ComponentProps, { VoiceActionDetail: typeof VoiceActionDetail; TextareaFieldType: typeof TextareaFieldType; Attachment: typeof Attachment; AudioRecordingStatus: typeof AudioRecordingStatus; }, "">; type ObcTextareaField = ReturnType; export default ObcTextareaField;