#232: remove duplicate filename under attachment pill, widen pill #234

Merged
fen merged 2 commits from fix-232 into dev 2026-09-10 22:06:25 +00:00
2 changed files with 5 additions and 11 deletions
Showing only changes of commit ca59c19fa4 - Show all commits
+1 -1
View File
@@ -823,7 +823,7 @@ button[type="submit"]:focus-visible,
} }
.attachment-bar .attachment-chip:hover { border-color: var(--accent); } .attachment-bar .attachment-chip:hover { border-color: var(--accent); }
.attachment-bar .attachment-chip .attachment-name { .attachment-bar .attachment-chip .attachment-name {
max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 720px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
} }
/* #221: images scale to fit the viewer box, aspect ratio preserved. */ /* #221: images scale to fit the viewer box, aspect ratio preserved. */
.attachment-preview { .attachment-preview {
+4 -10
View File
@@ -41,17 +41,11 @@
<div class="attachment-bar"> <div class="attachment-bar">
{{if .AttachmentImage}} {{if .AttachmentImage}}
<div class="attachment-preview"><img src="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" alt="{{.Attachment.Filename}}"></div> <div class="attachment-preview"><img src="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" alt="{{.Attachment.Filename}}"></div>
<a class="attachment-chip" href="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" data-mime="{{.Attachment.Mime}}">
<span class="attachment-name">{{.Attachment.Filename}}</span>
<span class="attachment-size">{{.Attachment.SizeHuman}}</span>
</a>
{{else}}
<a class="attachment-chip" href="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" data-mime="{{.Attachment.Mime}}">
<span class="attachment-name">{{.Attachment.Filename}}</span>
<span class="attachment-size">{{.Attachment.SizeHuman}}</span>
</a>
<div class="attachment-preview"><img src="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" alt="{{.Attachment.Filename}}"></div>
{{end}} {{end}}
<a class="attachment-chip" href="/f/{{.Attachment.ID}}/{{.Attachment.Filename}}" data-mime="{{.Attachment.Mime}}">
<span class="attachment-name">{{.Attachment.Filename}}</span>
<span class="attachment-size">{{.Attachment.SizeHuman}}</span>
</a>
</div> </div>
</div> </div>
{{end}} {{end}}