|
@@ -2,14 +2,14 @@
|
|
|
<div class="safe">
|
|
|
<div class="bottomCard">
|
|
|
<div class="cardLine">
|
|
|
- <div class="lineItem card">
|
|
|
+ <div class="lineItem card" :style="isFullScreen ? 'height: 45vh' : 'height: 47vh'">
|
|
|
<Safecom
|
|
|
title="风机报警"
|
|
|
deviceType="windturbine"
|
|
|
alarmType="windturbine"
|
|
|
/>
|
|
|
</div>
|
|
|
- <div class="lineItem card">
|
|
|
+ <div class="lineItem card" :style="isFullScreen ? 'height: 45vh' : 'height: 47vh'">
|
|
|
<Safecom
|
|
|
title="风机预警"
|
|
|
deviceType="windturbine"
|
|
@@ -38,7 +38,7 @@
|
|
|
</div> -->
|
|
|
</div>
|
|
|
<div class="cardLine">
|
|
|
- <div class="lineItem card" style="height: 100%">
|
|
|
+ <div class="lineItem card" :style="isFullScreen ? 'height: 90vh' : 'height: 95vh'">
|
|
|
<Safecom
|
|
|
title="升压站报警"
|
|
|
deviceType="booststation"
|
|
@@ -56,9 +56,37 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</template>
|
|
|
-<script setup>
|
|
|
+<script>
|
|
|
import dayjs from "dayjs";
|
|
|
import Safecom from "@/views/IntegratedAlarm/safe/components/safecomponent.vue";
|
|
|
+export default {
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ isFullScreen: false
|
|
|
+ }
|
|
|
+ },
|
|
|
+ components: {
|
|
|
+ Safecom
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ const clientHeight =
|
|
|
+ document.documentElement.clientHeight || document.body.clientHeight;
|
|
|
+ if (clientHeight === 1080) {
|
|
|
+ this.isFullScreen = true;
|
|
|
+ } else {
|
|
|
+ this.isFullScreen = false;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ window.onresize = () => {
|
|
|
+ const clientHeight =
|
|
|
+ document.documentElement.clientHeight || document.body.clientHeight;
|
|
|
+ this.isFullScreen = window.screen.height == clientHeight;
|
|
|
+ };
|
|
|
+
|
|
|
+ console.log("isFullScreen=====>>>>", this.isFullScreen)
|
|
|
+ }
|
|
|
+}
|
|
|
</script>
|
|
|
|
|
|
<style lang="less" scoped>
|
|
@@ -76,10 +104,11 @@ import Safecom from "@/views/IntegratedAlarm/safe/components/safecomponent.vue";
|
|
|
.cardLine {
|
|
|
// width: calc(100% / 3 - 15px);
|
|
|
width: calc(100% / 2 - 15px);
|
|
|
- height: 100%;
|
|
|
+ // height: 100%;
|
|
|
+ height: 95vh;
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
- justify-content: space-between;
|
|
|
+ // justify-content: space-between;
|
|
|
align-items: center;
|
|
|
.lineItem {
|
|
|
width: 100%;
|