mirror of
https://github.com/MarekWo/mc-webui.git
synced 2026-03-28 17:42:45 +01:00
fix(ui): move retry counter above Resend button, same line as delivery info
Retry counter now renders as a dm-delivery-meta div above the Resend button instead of inline next to it, matching the position of the post-delivery info. Prevents text from crowding the button on short messages. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -738,10 +738,8 @@ main {
|
|||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dm-retry-info {
|
.dm-retry-info:empty {
|
||||||
font-size: 0.65rem;
|
display: none;
|
||||||
color: var(--text-meta);
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.dm-delivery-meta {
|
.dm-delivery-meta {
|
||||||
@@ -781,7 +779,6 @@ main {
|
|||||||
.dm-actions {
|
.dm-actions {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-end;
|
justify-content: flex-end;
|
||||||
align-items: center;
|
|
||||||
margin-top: 0.25rem;
|
margin-top: 0.25rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1205,10 +1205,12 @@ function displayMessages(messages) {
|
|||||||
deliveryMeta = `<div class="dm-delivery-meta">${parts.join(', ')}</div>`;
|
deliveryMeta = `<div class="dm-delivery-meta">${parts.join(', ')}</div>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Resend button for own messages (with retry counter placeholder)
|
// Retry counter placeholder (same line as delivery meta)
|
||||||
|
const retryInfo = msg.is_own ? `<div class="dm-delivery-meta dm-retry-info" data-dm-id="${msg.id || ''}"></div>` : '';
|
||||||
|
|
||||||
|
// Resend button for own messages
|
||||||
const resendBtn = msg.is_own ? `
|
const resendBtn = msg.is_own ? `
|
||||||
<div class="dm-actions">
|
<div class="dm-actions">
|
||||||
<span class="dm-retry-info" data-dm-id="${msg.id || ''}"></span>
|
|
||||||
<button class="btn btn-outline-secondary btn-sm dm-action-btn" onclick='resendMessage(${JSON.stringify(msg.content)})' title="Resend">
|
<button class="btn btn-outline-secondary btn-sm dm-action-btn" onclick='resendMessage(${JSON.stringify(msg.content)})' title="Resend">
|
||||||
<i class="bi bi-arrow-repeat"></i>
|
<i class="bi bi-arrow-repeat"></i>
|
||||||
</button>
|
</button>
|
||||||
@@ -1222,6 +1224,7 @@ function displayMessages(messages) {
|
|||||||
</div>
|
</div>
|
||||||
<div>${processMessageContent(msg.content)}</div>
|
<div>${processMessageContent(msg.content)}</div>
|
||||||
${deliveryMeta}
|
${deliveryMeta}
|
||||||
|
${retryInfo}
|
||||||
${meta}
|
${meta}
|
||||||
${resendBtn}
|
${resendBtn}
|
||||||
`;
|
`;
|
||||||
|
|||||||
Reference in New Issue
Block a user