diff --git a/index.html b/index.html index 0c92948..86ea4b1 100644 --- a/index.html +++ b/index.html @@ -63,6 +63,36 @@ border: 1px solid var(--stone); border-radius: 2px; } + .theme-table { + font-size: 9px; + margin-top: 4px; + } + .theme-table-row { + display: grid; + grid-template-columns: 30px 14px 14px 14px 14px 24px; + gap: 3px; + align-items: center; + padding: 1px 0; + } + .theme-table-header { + color: var(--icon); + font-weight: bold; + border-bottom: 1px solid var(--border); + padding-bottom: 2px; + } + .theme-table-name { + color: var(--bone); + } + .theme-table-mini-swatch { + width: 12px; + height: 12px; + border: 1px solid var(--border); + border-radius: 1px; + } + .theme-table-speed { + color: var(--icon); + font-size: 8px; + } @media (orientation: portrait) and (max-width: 700px) { #debug-panel { display: none; @@ -237,6 +267,8 @@
cloudColor
--
lightColor
--
bgColor
--
+
Theme table
+
@@ -1077,6 +1109,35 @@ var weatherThemes = { document.getElementById('dbg-vh-' + kk).textContent = '#' + ('00000' + vc.toString(16)).slice(-6); } } + + // Theme table + var themeNames = ['sunny', 'cloudy', 'stormy', 'night']; + var themeFields = [ + { key: 'skyColor', label: 'sky' }, + { key: 'cloudColor', label: 'cloud' }, + { key: 'lightColor', label: 'light' }, + { key: 'backgroundColor', label: 'bg' } + ]; + var tableHtml = '
'; + tableHtml += ''; + for (var t = 0; t < themeFields.length; t++) { + tableHtml += '' + themeFields[t].label + ''; + } + tableHtml += 'speed'; + tableHtml += '
'; + for (var n = 0; n < themeNames.length; n++) { + var tn = themeNames[n]; + var th = weatherThemes[tn]; + tableHtml += '
'; + tableHtml += '' + tn + ''; + for (var f = 0; f < themeFields.length; f++) { + var fc = th[themeFields[f].key]; + tableHtml += '
'; + } + tableHtml += '' + th.speed + ''; + tableHtml += '
'; + } + document.getElementById('dbg-theme-table').innerHTML = tableHtml; } function animate() {