fix: background toggle button dev-only, photo always visible in production
This commit is contained in:
@@ -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}}
|
||||
|
||||
Reference in New Issue
Block a user