Merge pull request #2857 from xinnan-tech/build-generator

fix: 修复项目部署二级目录自定义语音盒子主题文件资源异常问题
This commit is contained in:
hrz
2026-01-19 11:45:08 +08:00
committed by GitHub
3 changed files with 31 additions and 28 deletions
+2 -2
View File
@@ -5,8 +5,8 @@
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Xiaozhi AI Customization</title>
<script type="module" crossorigin src="/generator/assets/index-CYcyz9xb.js"></script>
<link rel="stylesheet" crossorigin href="/generator/assets/index-NXxBVrod.css">
<script type="module" crossorigin src="./assets/index-FKVSBRAB.js"></script>
<link rel="stylesheet" crossorigin href="./assets/index-NXxBVrod.css">
</head>
<body>
<div id="app"></div>
@@ -338,8 +338,11 @@ export default {
});
},
handleGenertor() {
const pathname = window.location.pathname;
const basePath = pathname.split('/').slice(0, -1).join('/');
const url = `${window.location.origin}${basePath}/generator/`;
sessionStorage.setItem('devicePath', window.location.href);
window.location.href = `${window.location.origin}/generator/index.html`;
window.location.href = url;
},
goFirst() {
this.currentPage = 1;