fix: background toggle button dev-only, photo always visible in production

This commit is contained in:
juanatsap
2026-05-02 15:00:02 +01:00
parent 65eadcada7
commit 3aebc82068
@@ -9,6 +9,7 @@
document.body.style.setProperty('--bg-photo-url', 'url("' + url + '")');
document.body.classList.add('bg-photo');
{{if not .IsProduction}}
window.toggleBgPhoto = function() {
var isOn = document.body.classList.contains('bg-photo');
if (isOn) {
@@ -22,10 +23,12 @@
if (icon) icon.setAttribute('icon', isOn ? 'mdi:image-outline' : 'mdi:image');
}
};
{{end}}
})();
</script>
<!-- Background Photo Toggle -->
{{if not .IsProduction}}
<!-- Background Photo Toggle (Dev Only) -->
<button
id="bg-photo-toggle"
class="fixed-btn bg-photo-btn no-print has-tooltip"
@@ -36,3 +39,4 @@
</button>
{{end}}
{{end}}
{{end}}