v56: standardize font sizes to match domain name

This commit is contained in:
primal
2026-01-30 17:06:24 -05:00
parent c5ad66ee81
commit 3147b4e48a
2 changed files with 10 additions and 10 deletions
+9 -9
View File
@@ -137,7 +137,7 @@ function initDashboard() {
let html = '';
items.forEach(item => {
const date = item.pub_date ? new Date(item.pub_date).toLocaleDateString() : '';
html += `<div style="padding: 2px 0; font-size: 11px; border-bottom: 1px solid #1a1a1a;">`;
html += `<div style="padding: 2px 0; border-bottom: 1px solid #1a1a1a;">`;
html += `<span style="color: #666; margin-right: 8px;">${escapeHtml(date)}</span>`;
if (item.link) {
html += `<a href="${escapeHtml(item.link)}" target="_blank" style="color: #0af; text-decoration: none;">${escapeHtml(item.title || item.link)}</a>`;
@@ -236,7 +236,7 @@ function initDashboard() {
// Spacer (clickable to toggle feeds) - uses &nbsp; to ensure clickable area
if (d.last_error) {
html += `<span class="domain-spacer" style="color: #f66; margin-left: 10px; font-size: 11px; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer;" title="${escapeHtml(d.last_error)}">${escapeHtml(d.last_error)}</span>`;
html += `<span class="domain-spacer" style="color: #f66; margin-left: 10px; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer;" title="${escapeHtml(d.last_error)}">${escapeHtml(d.last_error)}</span>`;
} else {
html += '<span class="domain-spacer" style="flex: 1; cursor: pointer;">&nbsp;</span>';
}
@@ -258,24 +258,24 @@ function initDashboard() {
const feedStatus = f.publish_status || 'hold';
html += `<div class="inline-feed-block" data-url="${escapeHtml(f.url)}" data-status="${feedStatus}">`;
html += `<div class="feed-row" style="display: flex; align-items: center; padding: 4px 0; font-size: 12px;">`;
html += `<div class="feed-row" style="display: flex; align-items: center; padding: 4px 0;">`;
// Language indicator (fixed width)
const lang = f.language || '';
html += `<span style="display: inline-block; width: 32px; margin-right: 6px; color: #666; font-size: 10px; font-family: monospace; text-align: center;">${escapeHtml(lang)}</span>`;
html += `<span style="display: inline-block; width: 32px; margin-right: 6px; color: #666; font-family: monospace; text-align: center;">${escapeHtml(lang)}</span>`;
// Feed publish status buttons (pass/hold/skip)
html += renderStatusBtns(feedStatus, 'feed', f.url, f.status);
// Feed crawl status (active/error/dead)
const statusColor = f.status === 'active' ? '#484' : f.status === 'error' ? '#a66' : '#666';
html += `<span style="color: ${statusColor}; font-size: 10px; font-family: monospace; width: 40px; margin-right: 6px;">${escapeHtml(f.status || 'active')}</span>`;
html += `<span style="color: ${statusColor}; font-family: monospace; width: 50px; margin-right: 6px;">${escapeHtml(f.status || 'active')}</span>`;
// Item count if > 0
if (f.item_count > 0) {
html += `<span style="color: #888; font-size: 10px; font-family: monospace; width: 50px; margin-right: 6px; text-align: right;">${commaFormat(f.item_count)}</span>`;
html += `<span style="color: #888; font-family: monospace; width: 55px; margin-right: 6px; text-align: right;">${commaFormat(f.item_count)}</span>`;
} else {
html += `<span style="width: 50px; margin-right: 6px;"></span>`;
html += `<span style="width: 55px; margin-right: 6px;"></span>`;
}
// Feed path (URL without domain) - click to toggle feed info
@@ -284,7 +284,7 @@ function initDashboard() {
const urlObj = new URL(f.url.startsWith('http') ? f.url : 'https://' + f.url);
feedPath = urlObj.pathname + urlObj.search;
} catch (e) {}
html += `<span class="feed-url-toggle" style="color: #0af; font-size: 11px; margin-right: 8px; white-space: nowrap; cursor: pointer;" title="Click to show feed info">${escapeHtml(feedPath)}</span>`;
html += `<span class="feed-url-toggle" style="color: #0af; margin-right: 8px; white-space: nowrap; cursor: pointer;" title="Click to show feed info">${escapeHtml(feedPath)}</span>`;
// Feed title - click to toggle items
if (f.title) {
@@ -296,7 +296,7 @@ function initDashboard() {
html += '</div>';
// Feed info section (hidden by default)
html += '<div class="feed-info" style="display: none; padding: 6px 10px; margin-left: 10px; border-left: 2px solid #444; background: #0a0a0a; font-size: 11px;"></div>';
html += '<div class="feed-info" style="display: none; padding: 6px 10px; margin-left: 10px; border-left: 2px solid #444; background: #0a0a0a;"></div>';
// Feed items section (shown by default)
html += '<div class="feed-items" style="display: block; padding: 4px 10px; margin-left: 10px; border-left: 2px solid #333;"></div>';
+1 -1
View File
@@ -534,7 +534,7 @@ const dashboardHTML = `<!DOCTYPE html>
<div id="output"></div>
</div>
<div style="color: #333; font-size: 11px; margin-top: 10px;">v55</div>
<div style="color: #333; font-size: 11px; margin-top: 10px;">v56</div>
<div class="updated" id="updatedAt">Last updated: {{.UpdatedAt.Format "2006-01-02 15:04:05"}}</div>
</body>