Skip to content

fix(chat): remove the file-type whitelist from chat attachment uploads#27

Merged
Luhaozhu merged 1 commit into
mainfrom
fix/chat-attachment-file-type-filter
Jul 25, 2026
Merged

fix(chat): remove the file-type whitelist from chat attachment uploads#27
Luhaozhu merged 1 commit into
mainfrom
fix/chat-attachment-file-type-filter

Conversation

@Luhaozhu

Copy link
Copy Markdown
Contributor

Problem

The document-upload button in the chat input limited the file picker to .pdf/.docx/.doc/.wps/.txt/.xlsx/.xls/.csv through the hidden input's accept attribute. Other formats such as .pptx could not be selected at all, even though the backend accepts them.

Change

Drop the accept whitelist from the document upload input so any file type can be selected — consistent with the My Space upload flow, which applies no type whitelist (the folder picker alone distinguishes files from folders). The image upload input keeps its image-only accept unchanged.

Testing

Manually verified in the chat input: the attachment picker now offers all file types, and image upload behaviour is unchanged.

The document-upload button in the chat input restricted selection to
.pdf/.docx/.doc/.wps/.txt/.xlsx/.xls/.csv via the input's accept
attribute, so other types (e.g. .pptx) could not be picked. Align with
the My Space upload behaviour, which applies no type whitelist: drop the
accept attribute and allow any file type to be selected.
@Luhaozhu
Luhaozhu merged commit 3dc839d into main Jul 25, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant