Archived
fix: show sending indicator while uploading attachments
Messages with image attachments could take a moment to appear (large base64 upload, server-side resize, first-session open) while the composer cleared instantly, making it look like nothing happened. Await the send for attachment messages and surface a "Sending…" button label plus a "Sending your files…" / "Saving your files…" hint, disabling the composer until the message lands. Plain text messages stay fire-and-forget so the input frees up instantly.
This commit is contained in:
@@ -459,6 +459,7 @@ export const promptEditorStyles = css`
|
||||
.markdown-editor .cm-focused { outline: none; }
|
||||
.shell-mode textarea, .shell-mode .markdown-editor .cm-editor { border-color: var(--pi-success); box-shadow: 0 0 0 1px var(--pi-success-ring); }
|
||||
.mode-hint { position: absolute; right: 8px; bottom: 8px; max-width: calc(100% - 16px); border: 1px solid var(--pi-success-border); border-radius: 999px; background: var(--pi-success-surface); color: var(--pi-success); padding: 2px 8px; font-size: 12px; pointer-events: none; }
|
||||
.sending-hint { border-color: var(--pi-accent-border); background: var(--pi-selection-bg); color: var(--pi-accent); }
|
||||
.attachments { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
|
||||
.attachment-chip { position: relative; width: 56px; height: 56px; border: 1px solid var(--pi-border); border-radius: 8px; overflow: hidden; background: var(--pi-bg); }
|
||||
.attachment-chip img { width: 100%; height: 100%; object-fit: cover; display: block; }
|
||||
|
||||
Reference in New Issue
Block a user