mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5509] [GUI] Saved chats: keep a small preview of attached pictures #5480
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#5480
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Astemiir on GitHub (Nov 7, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5509
[GUI] Saved chats: keep a small preview of attached pictures
Area: GUI (web chat) —
serve/web/history.js,serve/web/app.jsVersions: app 0.2.12 / control 0.1.58
Problem
history.jsstores attachments by name only:so a chat reopened after a reload (or after switching to another chat and back) shows a chip with
the file name instead of the picture. The full data URL is intentionally not stored — that part is
right — but the user loses the visual reference.
Proposal
Store a small thumbnail next to the name, never the original:
toDataURL("image/jpeg", 0.72);{name, thumb};cleanMessagespassesthumbthrough;im.url || im.thumb(session keeps the original, history shows the preview);apiMessages()still sends only entries withurl, so a thumbnail is never sent to the model.Measured: a 900×600 PNG → thumbnail 6 131 bytes. A chat with 20 pictures keeps ~120 KB instead of
tens of megabytes.
Test plan
srcstarts withdata:image/jpeg);prompt_tokensincludes image tokens);@github-actions[bot] commented on GitHub (Nov 7, 2026):
Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:
Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment
/reopen.Details: CONTRIBUTING.md