You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
WebCAD/src/index.html

43 lines
1.5 KiB

<!DOCTYPE html>
<html lang="zh-cmn-Hans">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<script>
if (location.hostname !== "localhost")
fetch("ver.json").then(res => {
if (!res.ok) return;
res.json().then(v => {
if (res.status)
if (v)
{
let oldVer = sessionStorage.getItem("ver");
sessionStorage.setItem("ver", v);
if (oldVer && oldVer != v)
{
document.body.style.cssText = `
text-align: center;
display: flex;
align-items: center;
justify-content: center;
font-size: 30px;
flex-direction: column;
`;
document.body.textContent = "发现新版本,升级中!";
location.reload();
}
}
});
});
</script>
<title>WebCAD</title>
<meta itemprop="description" content="云端CAD,在线衣柜设计" />
</head>
<body>
</body>
</html>