显示1080样式

This commit is contained in:
2023-12-28 09:59:32 +08:00
parent 7a6b0b8da6
commit fd4187118d
4 changed files with 16 additions and 16 deletions

View File

@@ -23,12 +23,12 @@ export default {
...mapGetters(['showToast', 'showAlert'])
},
mounted () {
// const htmlStyle = document.getElementsByTagName('html')[0].style
// if (window.screen.height <= 1080) {
// htmlStyle.height = 1080
// } else {
// htmlStyle.height = 1200
// }
const htmlStyle = document.getElementsByTagName('html')[0].style
if (window.screen.height <= 1080) {
htmlStyle.height = 1080
} else {
htmlStyle.height = 1200
}
}
}
</script>

View File

@@ -82,9 +82,9 @@ li {
/* 顺安大屏尺寸1920*1200 */
html, body {
width: 1920px;
height: 1200px;
/* height: 1200px; */
/* height: 1080px; */
/* height: 100%; */
height: 100%;
}
body {

View File

@@ -283,11 +283,11 @@ export default {
clearInterval(this.timer1)
clearInterval(this.timer2)
this.refresh()
// if (window.screen.height <= 1080) {
// this.$refs.container.style.paddingTop = '0.8%'
// this.$refs.container.style.height = '90%'
// this.$refs.bottom.style.height = '2%'
// }
if (window.screen.height <= 1080) {
this.$refs.container.style.paddingTop = '0.8%'
this.$refs.container.style.height = '90%'
this.$refs.bottom.style.height = '2%'
}
},
beforeDestroy () {
this.$once('hook:beforeDestroy', () => {

View File

@@ -651,15 +651,15 @@
<script>
import TCanvas1 from './canvas_1.vue'
// import TCanvas2 from './canvas_2.vue'
import TCanvas2 from './canvas_2.vue'
import DevicePop from '@components/devicepop.vue'
import {homepageEquipment} from '@js/getData2.js'
// import {homepageEquipment} from '@js/mork2.js'
export default {
name: 'workshop',
components: {
// TCanvas: window.screen.height <= 1080 ? TCanvas2 : TCanvas1,
TCanvas: TCanvas1,
TCanvas: window.screen.height <= 1080 ? TCanvas2 : TCanvas1,
// TCanvas: TCanvas1,
DevicePop: DevicePop
},
data () {