2020-11-19 13:47:56 +08:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="zh">
|
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8" />
|
|
|
|
<title>MobileView</title>
|
|
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
|
|
<link type="image/x-icon" rel="shortcut icon" href="./static/favicon.png" />
|
|
|
|
<meta
|
|
|
|
name="viewport"
|
|
|
|
content="width=device-width, initial-scale=1, maximum-scale=1"
|
|
|
|
/>
|
|
|
|
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
|
2021-04-19 11:30:35 +08:00
|
|
|
<link rel="stylesheet" href="@fortawesome/fontawesome-free/css/all.css" />
|
2021-04-19 13:33:23 +08:00
|
|
|
<link
|
|
|
|
rel="stylesheet"
|
|
|
|
href="@fortawesome/fontawesome-free/css/v4-shims.css"
|
|
|
|
/>
|
2020-11-30 16:53:04 +08:00
|
|
|
<!--DEPENDENCIES_INJECT_PLACEHOLDER-->
|
2021-08-18 16:21:35 +08:00
|
|
|
<link rel="stylesheet" title="ang" href="../scss/themes/ang.scss" />
|
2020-11-19 13:47:56 +08:00
|
|
|
<link
|
|
|
|
rel="stylesheet"
|
|
|
|
title="cxd"
|
|
|
|
disabled
|
|
|
|
href="../scss/themes/cxd.scss"
|
|
|
|
/>
|
|
|
|
<link
|
|
|
|
rel="stylesheet"
|
|
|
|
title="dark"
|
|
|
|
disabled
|
|
|
|
href="../scss/themes/dark.scss"
|
|
|
|
/>
|
2021-01-25 17:22:11 +08:00
|
|
|
<link
|
|
|
|
rel="stylesheet"
|
|
|
|
title="antd"
|
|
|
|
disabled
|
|
|
|
href="../scss/themes/antd.scss"
|
|
|
|
/>
|
2020-12-21 10:08:40 +08:00
|
|
|
<link rel="stylesheet" href="../scss/helper.scss" />
|
2020-11-19 13:47:56 +08:00
|
|
|
<style>
|
|
|
|
.app-wrapper {
|
|
|
|
position: relative;
|
|
|
|
width: 100%;
|
|
|
|
height: 100%;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
|
|
|
<div id="root" class="app-wrapper"></div>
|
|
|
|
<script src="./mod.js"></script>
|
|
|
|
<script type="text/javascript">
|
|
|
|
const themes = [
|
|
|
|
{
|
2021-08-18 16:21:35 +08:00
|
|
|
label: '云舍',
|
|
|
|
value: 'cxd'
|
2020-11-19 13:47:56 +08:00
|
|
|
},
|
|
|
|
{
|
2021-08-18 16:21:35 +08:00
|
|
|
label: 'Ang',
|
|
|
|
value: 'ang'
|
2020-11-19 13:47:56 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
label: 'Dark',
|
|
|
|
value: 'dark'
|
2021-01-25 17:22:11 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
label: 'antd',
|
|
|
|
value: 'antd'
|
2020-11-19 13:47:56 +08:00
|
|
|
}
|
|
|
|
];
|
2020-11-19 19:22:56 +08:00
|
|
|
// mobile 下先禁掉所有外链避免影响
|
2020-11-30 16:53:04 +08:00
|
|
|
document.querySelectorAll('link[title]').forEach(item => {
|
2020-11-19 19:22:56 +08:00
|
|
|
item.disabled = true;
|
|
|
|
});
|
2021-09-09 11:09:32 +08:00
|
|
|
let theme = localStorage.getItem('theme') || 'cxd';
|
|
|
|
if (theme == 'default') {
|
|
|
|
theme = 'cxd';
|
|
|
|
}
|
|
|
|
document.querySelector(`link[title=${theme}]`).disabled = false;
|
|
|
|
if (theme === 'dark') {
|
2020-11-19 19:22:56 +08:00
|
|
|
document.querySelector('body').classList.add('dark');
|
2020-11-19 13:47:56 +08:00
|
|
|
}
|
2020-11-19 19:22:56 +08:00
|
|
|
|
2020-11-19 13:47:56 +08:00
|
|
|
amis.require(['./mobile.tsx'], function (app) {
|
2020-11-19 19:22:56 +08:00
|
|
|
app.bootstrap(document.getElementById('root'), {});
|
2020-11-19 13:47:56 +08:00
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|