vibetunnel/tauri/settings.html
Peter Steinberger 2b611a5797 Work on Tauri
2025-06-23 17:16:29 +02:00

57 lines
No EOL
1.7 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/icon.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>VibeTunnel Settings</title>
<style>
html, body {
margin: 0;
padding: 0;
width: 100%;
height: 100%;
overflow: hidden;
background: transparent;
}
/* Make body transparent for window transparency */
body {
background: transparent !important;
}
/* Theme detection */
@media (prefers-color-scheme: dark) {
html { color-scheme: dark; }
}
@media (prefers-color-scheme: light) {
html { color-scheme: light; }
html.light { color-scheme: light; }
}
</style>
</head>
<body>
<settings-app></settings-app>
<script type="module">
import './src/components/settings-app.ts';
// Apply theme class to html element
const isDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
document.documentElement.classList.toggle('light', !isDark);
// Listen for theme changes
window.matchMedia('(prefers-color-scheme: dark)').addEventListener('change', (e) => {
document.documentElement.classList.toggle('light', !e.matches);
});
// Parse URL parameters to get initial tab
const urlParams = new URLSearchParams(window.location.search);
const tab = urlParams.get('tab');
if (tab) {
// TODO: Pass initial tab to settings-app component
document.querySelector('settings-app')?.setAttribute('initial-tab', tab);
}
</script>
</body>
</html>