@sqlrooms/ai-core / ChatComposerAttachmentsProps
Type Alias: ChatComposerAttachmentsProps
ChatComposerAttachmentsProps =
object
Configuration for the opt-in composer attachment picker.
By default it accepts up to four files, limits images to 1 MiB each and in aggregate, and limits plain-text or Markdown files to 128 KiB each and in aggregate. Unsupported, oversized, or excess files are rejected and reported through onError.
Properties
className?
optionalclassName?:string
imageAccept?
optionalimageAccept?:string
Native file-input accept value for the image choice.
textAccept?
optionaltextAccept?:string
Native file-input accept value for the text or Markdown choice.
maxFiles?
optionalmaxFiles?:number
Maximum number of files waiting in the composer.
maxFileSize?
optionalmaxFileSize?:number
Maximum image size in bytes.
maxTotalImageFileSize?
optionalmaxTotalImageFileSize?:number
Maximum combined size of pending image files in bytes.
maxTextFileSize?
optionalmaxTextFileSize?:number
Maximum text or Markdown size in bytes.
maxTotalTextFileSize?
optionalmaxTotalTextFileSize?:number
Maximum combined size of pending text and Markdown files in bytes.
onError?
optionalonError?: (message) =>void
Called when one or more selected files cannot be attached.
Parameters
| Parameter | Type |
|---|---|
message | string |
Returns
void