修复LDNET-GA的SEO采集

This commit is contained in:
CN-JS-HuiBai
2026-04-05 17:15:40 +08:00
parent d595397f08
commit dc1a8a1a44
2 changed files with 12 additions and 8 deletions

View File

@@ -4,8 +4,8 @@
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="多源Prometheus服务器监控展示大屏 - 实时CPU、内存、磁盘、网络统计"> <meta name="description" content="LDNET-GA">
<title>数据可视化展示大屏</title> <title>LDNET-GA</title>
<link rel="preconnect" href="https://fonts.googleapis.com"> <link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link <link
@@ -405,9 +405,13 @@
<option value="light">默认白天模式</option> <option value="light">默认白天模式</option>
</select> </select>
</div> </div>
<div class="form-group" style="margin-top: 15px; display: flex; align-items: center; gap: 10px;"> <div class="form-group" style="margin-top: 15px;">
<input type="checkbox" id="show95BandwidthInput" style="width: 18px; height: 18px; cursor: pointer;"> <label for="show95BandwidthInput">24h趋势图默认显示 95计费线</label>
<label for="show95BandwidthInput" style="cursor: pointer; user-select: none;">24h趋势图默认显示 95计费线</label> <select id="show95BandwidthInput"
style="padding: 10px 14px; background: var(--bg-input); border: 1px solid var(--border-color); border-radius: var(--radius-sm); color: var(--text-primary);">
<option value="1">显示</option>
<option value="0">不显示</option>
</select>
</div> </div>
<div class="form-actions" style="margin-top: 25px; display: flex; justify-content: flex-end;"> <div class="form-actions" style="margin-top: 25px; display: flex; justify-content: flex-end;">
<button class="btn btn-add" id="btnSaveSiteSettings">保存设置</button> <button class="btn btn-add" id="btnSaveSiteSettings">保存设置</button>

View File

@@ -263,7 +263,7 @@
dom.siteTitleInput.value = window.SITE_SETTINGS.title || ''; dom.siteTitleInput.value = window.SITE_SETTINGS.title || '';
dom.logoUrlInput.value = window.SITE_SETTINGS.logo_url || ''; dom.logoUrlInput.value = window.SITE_SETTINGS.logo_url || '';
dom.defaultThemeInput.value = window.SITE_SETTINGS.default_theme || 'dark'; dom.defaultThemeInput.value = window.SITE_SETTINGS.default_theme || 'dark';
dom.show95BandwidthInput.checked = !!window.SITE_SETTINGS.show_95_bandwidth; dom.show95BandwidthInput.value = window.SITE_SETTINGS.show_95_bandwidth ? "1" : "0";
} }
loadSiteSettings(); loadSiteSettings();
@@ -1070,7 +1070,7 @@
if (settings.logo_url) dom.logoUrlInput.value = settings.logo_url; if (settings.logo_url) dom.logoUrlInput.value = settings.logo_url;
if (settings.default_theme) dom.defaultThemeInput.value = settings.default_theme; if (settings.default_theme) dom.defaultThemeInput.value = settings.default_theme;
if (settings.show_95_bandwidth !== undefined) { if (settings.show_95_bandwidth !== undefined) {
dom.show95BandwidthInput.checked = !!settings.show_95_bandwidth; dom.show95BandwidthInput.value = settings.show_95_bandwidth ? "1" : "0";
if (networkChart) { if (networkChart) {
networkChart.showP95 = !!settings.show_95_bandwidth; networkChart.showP95 = !!settings.show_95_bandwidth;
if (dom.legendP95) { if (dom.legendP95) {
@@ -1155,7 +1155,7 @@
title: dom.siteTitleInput.value.trim(), title: dom.siteTitleInput.value.trim(),
logo_url: dom.logoUrlInput.value.trim(), logo_url: dom.logoUrlInput.value.trim(),
default_theme: dom.defaultThemeInput.value, default_theme: dom.defaultThemeInput.value,
show_95_bandwidth: dom.show95BandwidthInput.checked ? 1 : 0 show_95_bandwidth: dom.show95BandwidthInput.value === "1" ? 1 : 0
}; };
dom.btnSaveSiteSettings.disabled = true; dom.btnSaveSiteSettings.disabled = true;