feat: chat — photo attachments
- Migration 073: attachment_url column in chat_messages - upload.ts: add 'chat' folder to ALLOWED_FOLDERS - chat.ts: accept attachment_url in send message, return it in GET messages - api.ts: attachmentUrl in ChatMessage type, uploadImage() with raw FormData fetch - ChatWidget: paperclip button, file preview thumbnail with remove, image display inline in message bubbles (clickable, opens original), send enabled with image only Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1
backend/migrations/073_chat_attachments.sql
Normal file
1
backend/migrations/073_chat_attachments.sql
Normal file
@@ -0,0 +1 @@
|
||||
ALTER TABLE chat_messages ADD COLUMN IF NOT EXISTS attachment_url TEXT;
|
||||
Reference in New Issue
Block a user