Skip to content

feat: add file upload support to project evaluation page#100

Open
HuiNeng6 wants to merge 1 commit intoidea2app:mainfrom
HuiNeng6:main
Open

feat: add file upload support to project evaluation page#100
HuiNeng6 wants to merge 1 commit intoidea2app:mainfrom
HuiNeng6:main

Conversation

@HuiNeng6
Copy link
Copy Markdown

@HuiNeng6 HuiNeng6 commented Mar 25, 2026

PR-100 PR-100 PR-100 Powered by Pull Request Badge

Summary

This PR adds file upload support to the project evaluation page as requested in issue #95.

Changes

1. New File Model (\models/File.ts)

  • Created \S3FileModel\ class extending \FileModel\ from \mobx-restful-table\
  • Implements \upload\ method with signed URL support
  • Implements \delete\ method for file removal

2. Updated Project Evaluation Page (\pages/dashboard/project/[id].tsx)

  • Added file input button with multi-select support
  • Added paste event listener to capture images from clipboard
  • Added drag & drop support for file upload
  • Added \uploadFilesAndSendMessages\ method to upload files and send as ConsultMessage

Features

  • File Input Button: Users can click the attachment button to select multiple files
  • Paste Support: Users can paste images directly from clipboard
  • Drag & Drop Support: Users can drag and drop files into the chat area
  • Supported File Types: Images, PDF, DOC, DOCX, TXT, MD

Usage

  1. Click the 📎 button to select files
  2. Or paste images directly (Ctrl+V)
  3. Or drag and drop files into the chat area

Files will be uploaded and sent as messages with the format:
\
📎 filename
[file_url]
\\

Closes #95

- Add File.ts model for S3 file upload
- Add file input button with multi-select support
- Add paste event listener to capture images from clipboard
- Add drag & drop support for file upload
- Upload files and send as ConsultMessage

Closes idea2app#95
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