@@ -35,7 +35,7 @@ type Props = {
35
35
form : FormInstance < any > ;
36
36
showEmbeddingAndModels : boolean ;
37
37
newSelectedSource ?: any ;
38
- botConfig : BotConfig
38
+ botConfig : BotConfig ;
39
39
} ;
40
40
function classNames ( ...classes : string [ ] ) {
41
41
return classes . filter ( Boolean ) . join ( " " ) ;
@@ -47,7 +47,7 @@ export const BotForm = ({
47
47
setSelectedSource,
48
48
form,
49
49
showEmbeddingAndModels,
50
- botConfig
50
+ botConfig,
51
51
} : Props ) => {
52
52
const youtubeMode = Form . useWatch ( [ "options" , "youtube_mode" ] , form ) ;
53
53
const url = Form . useWatch ( [ "content" ] , form ) ;
@@ -117,7 +117,7 @@ export const BotForm = ({
117
117
} }
118
118
>
119
119
< Upload . Dragger
120
- accept = { `.pdf,.docx,.csv,.txt,.mp3,.mp4` }
120
+ accept = { `.pdf,.docx,.csv,.txt,.mp3,.mp4,.zip ` }
121
121
multiple = { true }
122
122
maxCount = { botConfig ?. fileUploadSizeLimit }
123
123
beforeUpload = { ( file ) => {
@@ -130,6 +130,8 @@ export const BotForm = ({
130
130
"audio/mp4" ,
131
131
"video/mp4" ,
132
132
"video/mpeg" ,
133
+ "application/zip" ,
134
+ "application/x-zip-compressed" ,
133
135
]
134
136
. map ( ( type ) => type . toLowerCase ( ) )
135
137
. join ( ", " ) ;
@@ -161,12 +163,13 @@ export const BotForm = ({
161
163
< InboxIcon className = "h-10 w-10 text-gray-400" />
162
164
</ p >
163
165
< p className = "ant-upload-text" >
164
- Click or drag PDF, Docx, CSV , TXT, MP3, MP4 files to this
166
+ Click or drag PDF, Docx, CSV , TXT, MP3, MP4, Zip files to
167
+ this
165
168
</ p >
166
169
< p className = "ant-upload-hint" >
167
- Support is available for a single or bulk upload of up to 10
170
+ { ` Support is available for a single or bulk upload of up to ${ botConfig ?. fileUploadSizeLimit }
168
171
files. Please note that file upload is in beta, so if you
169
- encounter any issues, kindly report them.
172
+ encounter any issues, kindly report them.` }
170
173
</ p >
171
174
</ div >
172
175
</ Upload . Dragger >
0 commit comments