배터리 센서 섹션 통합
This commit is contained in:
+6
-3
@@ -632,7 +632,7 @@ function ensureFindMyDeviceShell() {
|
||||
<div class="settingRow locateRow" id="updateBtn"><span id="labelForceUpdate"></span></div>
|
||||
</div>
|
||||
<div class="settingTitle"><span id="titleBattery"></span></div>
|
||||
<div class="settingSection">
|
||||
<div class="settingSection" id="batterySection">
|
||||
<div class="settingRow"><span id="labelBatteryState"></span><span id="batteryStatus"></span></div>
|
||||
<div class="settingRow"><span id="labelBatteryLevel"></span><span id="Battery"></span></div>
|
||||
<div class="settingRow"><span id="labelWatchBatteryState"></span><span id="WbatteryStatus"></span></div>
|
||||
@@ -1163,12 +1163,15 @@ function updateSensorSections(sections) {
|
||||
const entries = Object.entries(rows || {}).filter(([, value]) => normalizeDisplayValue(value));
|
||||
if (!entries.length) return;
|
||||
|
||||
activeSectionIds.add(sectionKey);
|
||||
const section = ensureSensorSection(sectionKey);
|
||||
const isBatterySection = sectionKey === 'battery';
|
||||
const section = isBatterySection ? document.getElementById('batterySection') : ensureSensorSection(sectionKey);
|
||||
if (!section) return;
|
||||
|
||||
if (!isBatterySection) {
|
||||
activeSectionIds.add(sectionKey);
|
||||
const title = document.getElementById(`sensorTitleText_${sectionKey}`);
|
||||
if (title) title.textContent = t[sectionKey] || sectionKey;
|
||||
}
|
||||
|
||||
entries.forEach(([key, value]) => {
|
||||
activeRowIds.add(`sensor_${sectionKey}_${key}`);
|
||||
|
||||
Reference in New Issue
Block a user