feat: add native clipboard support for screenshot paste #67

Merged
naomi merged 8 commits from feat/keep-workin into main 2026-01-25 13:08:38 -08:00
Owner

Summary

  • Adds Tauri clipboard-manager plugin to read images from native clipboard
  • Falls back to native clipboard when WebView clipboard API returns empty (fixes screenshot paste)
  • Allows sending messages with just attachments (no text required)
  • Logs attached files to output with ๐Ÿ“Ž emoji

Test plan

  • Build and run the app natively on Windows
  • Copy a screenshot (Win+Shift+S) and paste in the chat input
  • Verify the screenshot appears as an attachment preview
  • Send the attachment and verify Claude receives the file path
  • Test sending a message with only an attachment (no text)
  • Verify the ๐Ÿ“Ž log line shows the attached filename

Note: Paste will not work in WSLg dev environment due to clipboard isolation - needs native Windows build to test.

โœจ This PR was created with help from Hikari~ ๐ŸŒธ

## Summary - Adds Tauri clipboard-manager plugin to read images from native clipboard - Falls back to native clipboard when WebView clipboard API returns empty (fixes screenshot paste) - Allows sending messages with just attachments (no text required) - Logs attached files to output with ๐Ÿ“Ž emoji ## Test plan - [ ] Build and run the app natively on Windows - [ ] Copy a screenshot (Win+Shift+S) and paste in the chat input - [ ] Verify the screenshot appears as an attachment preview - [ ] Send the attachment and verify Claude receives the file path - [ ] Test sending a message with only an attachment (no text) - [ ] Verify the ๐Ÿ“Ž log line shows the attached filename **Note:** Paste will not work in WSLg dev environment due to clipboard isolation - needs native Windows build to test. โœจ This PR was created with help from Hikari~ ๐ŸŒธ
naomi added 6 commits 2026-01-24 16:11:27 -08:00
Implements the foundation for file upload support by adding a temp file
management system that tracks files per conversation.

- Add temp_manager.rs module with TempFileManager struct
- Add Tauri commands: save_temp_file, register_temp_file, get_temp_files,
  cleanup_temp_files, cleanup_all_temp_files, cleanup_orphaned_temp_files
- Clean up orphaned files from previous sessions on app startup
- Clean up temp files when conversation is deleted
- Store temp files in /tmp/hikari-uploads/ with unique UUIDs
- Create Attachment interface in messages.ts
- Create AttachmentPreview.svelte component with:
  - Image thumbnails for image attachments
  - File icons for documents
  - File size display
  - Remove button on hover
- Add attachments array to Conversation interface
- Add attachment management methods to conversation store:
  - addAttachment, removeAttachment, clearAttachments, getAttachments
- Integrate AttachmentPreview into InputBar
- Clear attachments on conversation reset
feat: add native clipboard support for screenshot paste
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 59s
CI / Lint & Test (pull_request) Failing after 6m1s
CI / Build Linux (pull_request) Has been skipped
CI / Build Windows (cross-compile) (pull_request) Has been skipped
07f9cf8c30
- Add Tauri clipboard-manager plugin for native clipboard access
- Fall back to native clipboard when WebView clipboard API returns empty
- Convert RGBA image data to PNG via canvas for saving
- Allow sending messages with attachments only (no text required)
- Log attached files to output with ๐Ÿ“Ž emoji
- Update send button to enable when attachments exist

Co-Authored-By: Naomi Carrigan <commits@nhcarrigan.com>
naomi added 1 commit 2026-01-24 16:14:40 -08:00
fix: show actual file size for picked files
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 48s
CI / Lint & Test (pull_request) Failing after 5m42s
CI / Build Linux (pull_request) Has been skipped
CI / Build Windows (cross-compile) (pull_request) Has been skipped
1e5c1c815e
naomi added 1 commit 2026-01-25 11:11:39 -08:00
style: fix prettier formatting issues
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 57s
CI / Lint & Test (pull_request) Successful in 14m34s
CI / Build Linux (pull_request) Successful in 18m24s
CI / Build Windows (cross-compile) (pull_request) Successful in 28m12s
2448521d2e
- Format RELEASE_NOTES_v0.3.0.md
- Format AttachmentPreview.svelte
- Format InputBar.svelte

All checks now passing! โœจ
naomi merged commit 852a4d6661 into main 2026-01-25 13:08:38 -08:00
naomi deleted branch feat/keep-workin 2026-01-25 13:08:38 -08:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: nhcarrigan/hikari-desktop#67