@bfehub/vuepress-theme-vmi
Version:
Vmi theme of VuePress
36 lines (33 loc) • 952 B
HTML
<html lang="{{ lang }}">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="VuePress {{ version }}">
<style>
:root {
--c-bg: #fff;
}
html.dark {
--c-bg: #22272e;
}
html, body {
background-color: var(--c-bg);
}
</style>
<script>
const userMode = localStorage.getItem('vuepress-color-scheme');
const systemDarkMode = window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches;
if (userMode === 'dark' || (userMode !== 'light' && systemDarkMode)) {
document.documentElement.classList.toggle('dark', true);
}
</script>
<!--vuepress-ssr-head-->
<!--vuepress-ssr-styles-->
<!--vuepress-ssr-resources-->
</head>
<body>
<div id="app"><!--vuepress-ssr-app--></div>
<!--vuepress-ssr-scripts-->
</body>
</html>