naive-ui/index.html

49 lines
1.2 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html lang="en">
2021-04-19 23:05:20 +08:00
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=1"
/>
<title>Naive UI</title>
<meta name="naive-ui-style" />
2021-12-29 02:59:14 +08:00
<meta name="vueuc-style" />
2021-04-19 23:05:20 +08:00
<link
rel="icon"
type="image/svg+xml"
href="/demo/assets/images/naivelogo.svg"
/>
2021-11-25 03:21:54 +08:00
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/@docsearch/css@alpha"
/>
<style>
:root {
--docsearch-primary-color: #18a058;
}
</style>
2021-04-19 23:05:20 +08:00
</head>
<body>
<script>
const path = window.location.pathname
const pathLocale = path.startsWith('/en-US')
? 'en-US'
: path.startsWith('/zh-CN')
? 'zh-CN'
: undefined
2021-04-19 23:05:20 +08:00
function deriveTitleFromLocale(locale = navigator.language) {
if (locale === 'zh-CN') {
2021-05-25 13:21:43 +08:00
document.title = 'Naive UI: 一个 Vue 3 组件库'
2021-04-19 23:05:20 +08:00
} else {
2021-05-25 13:21:43 +08:00
document.title = 'Naive UI: A Vue 3 Component Library'
2021-04-19 23:05:20 +08:00
}
}
deriveTitleFromLocale(pathLocale)
2021-04-19 23:05:20 +08:00
</script>
<div id="app"></div>
2021-11-25 03:21:54 +08:00
<div id="search" style="display: none"></div>
2021-04-19 23:05:20 +08:00
<script type="module" src="__INDEX__"></script>
</body>
</html>