diff --git a/app/static/js/dm.js b/app/static/js/dm.js index 765db85..9fc0114 100644 --- a/app/static/js/dm.js +++ b/app/static/js/dm.js @@ -1208,8 +1208,13 @@ function displayMessages(messages) { deliveryMeta = `
${parts.join(', ')}
`; } - // Retry counter placeholder (same line as delivery meta) - const retryInfo = msg.is_own ? `
` : ''; + // Retry counter placeholder — pre-populate for in-progress sends + let retryInfo = ''; + if (msg.is_own) { + const isPending = !msg.status || (msg.status !== 'delivered' && msg.status !== 'failed'); + const initialText = isPending && msg.expected_ack ? 'Attempt 1/...' : ''; + retryInfo = `
${initialText}
`; + } // Resend button for own messages const resendBtn = msg.is_own ? `