feat: 新增钢铁厂数字孪生平台基础架构和功能模块
- 添加Three.js基础场景配置和核心功能模块 - 实现模型加载器、动画循环和交互选择器 - 添加温度、压力等仪表盘组件 - 配置Vite构建工具和ESLint规范 - 添加基础UI组件和布局系统 - 实现数据可视化图表组件 - 配置Nginx部署文件 - 添加钢铁厂设备数据模型
This commit is contained in:
21
apps/steelmill/src/main.ts
Normal file
21
apps/steelmill/src/main.ts
Normal file
@@ -0,0 +1,21 @@
|
||||
import { createApp } from 'vue';
|
||||
import './style.css';
|
||||
import App from './App.vue';
|
||||
import route from './router';
|
||||
|
||||
createApp(App).use(route).mount('#app');
|
||||
|
||||
(function (doc, win) {
|
||||
const fn = () => {
|
||||
const docEl = doc.documentElement,
|
||||
clientWidth = docEl.clientWidth;
|
||||
if (!clientWidth) return;
|
||||
docEl.style.fontSize = 100 * (clientWidth / 1920) + 'px';
|
||||
if (clientWidth > 1920) {
|
||||
docEl.style.fontSize = '100px';
|
||||
}
|
||||
};
|
||||
if (!doc.addEventListener) return;
|
||||
win.addEventListener('resize', fn);
|
||||
doc.addEventListener('DOMContentLoaded', fn);
|
||||
})(document, window);
|
||||
Reference in New Issue
Block a user