diff --git a/src/assets/xicao-icon.png b/src/assets/xicao-icon.png index bde22bf..64d3c5f 100644 Binary files a/src/assets/xicao-icon.png and b/src/assets/xicao-icon.png differ diff --git a/src/components/boxes/XicaoTemp.vue b/src/components/boxes/XicaoTemp.vue index de95a57..3dabfa7 100644 --- a/src/components/boxes/XicaoTemp.vue +++ b/src/components/boxes/XicaoTemp.vue @@ -55,12 +55,12 @@ export default { } .vertical-line { - margin: 0 adjust(3px); - width: adjust(3px); + margin: 0 6px; + width: 6px; background: radial-gradient( ellipse at center, - #6fe2ff, - #52cbef80, + #3565ff, + #3565ff51, transparent, transparent ); diff --git a/src/components/groups/data.vue b/src/components/groups/data.vue index 3b5e8d7..7ecad9b 100644 --- a/src/components/groups/data.vue +++ b/src/components/groups/data.vue @@ -4,7 +4,7 @@ - + @@ -15,6 +15,7 @@ import GasFlow from "../boxes/GasFlow.vue"; import TopTemp from "../boxes/TopTemp.vue"; import BottomTemp from "../boxes/BottomTemp.vue"; import FanRuntime from "../boxes/FanRuntime.vue"; +import XicaoTemp from '../boxes/XicaoTemp.vue'; // import { mapState } from "vuex"; export default { @@ -26,6 +27,7 @@ export default { GasFlow, TopTemp, BottomTemp, + XicaoTemp }, data() { return {}; diff --git a/src/components/layout/SubContainer.vue b/src/components/layout/SubContainer.vue index ec7800e..f134a46 100644 --- a/src/components/layout/SubContainer.vue +++ b/src/components/layout/SubContainer.vue @@ -37,9 +37,9 @@ export default { gas: "icon-gas", xicao: "icon-xc", inWater: "icon-water-in", - fan: 'icon-fan', - ktop: 'icon-kiln-top', - kbtm: 'icon-kiln-bottom', + fan: "icon-fan", + ktop: "icon-kiln-top", + kbtm: "icon-kiln-bottom", }, }; }, @@ -82,8 +82,8 @@ export default { } .icon-xc { - background: url(../../assets/xicao-icon.png); - background-size: 100% 100%; + background: url(../../assets/xicao-icon.png) top 0 left 0 / 90% 75% no-repeat; + margin-right: 6px; } .icon-fan { @@ -92,17 +92,20 @@ export default { } .icon-kiln-top { - background: url(../../assets/kiln-top-icon.png) top 0 left 0 / 90% 75% no-repeat; + background: url(../../assets/kiln-top-icon.png) top 0 left 0 / 90% 75% + no-repeat; margin-right: 6px; } .icon-kiln-bottom { - background: url(../../assets/kiln-bottom-icon.png) top 0 left 0 / 90% 75% no-repeat; + background: url(../../assets/kiln-bottom-icon.png) top 0 left 0 / 90% 75% + no-repeat; margin-right: 6px; } .icon-water-in { - background: url(../../assets/water-temp.png) top 24% left 0 / 80% 75% no-repeat; + background: url(../../assets/water-temp.png) top 24% left 0 / 80% 75% + no-repeat; } .title { @@ -127,7 +130,7 @@ export default { } .content { - height: 1px; + height: 1px; flex: 1; } diff --git a/src/main.js b/src/main.js index a1a4810..a01e6e7 100644 --- a/src/main.js +++ b/src/main.js @@ -11,12 +11,6 @@ Vue.config.productionTip = false Vue.directive('title', title) -document.body.addEventListener('keydown', e => { - if (e.shiftKey && e.key === 'L') { - console.log('e', e.key) - } -}) - new Vue({ router, store, diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index a0838c3..94c8f21 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -1,14 +1,11 @@ @@ -17,11 +14,10 @@ import BigHeader from "../components/layout/Header.vue"; import Main from "../components/layout/Main.vue"; import LeftSide from "./LeftSide.vue"; import RightSide from "./RightSide.vue"; -import Slider from "../utils/slider.vue"; export default { name: "HomeView", - components: { BigHeader, Main, LeftSide, RightSide, Slider }, + components: { BigHeader, Main, LeftSide, RightSide }, props: {}, data() { return { @@ -37,17 +33,47 @@ export default { }; }, }, + mounted() { + const slider = document.createElement('div') + slider.id = 'slider' + slider.classList.add('slider') + const ranger = document.createElement('input') + ranger.type = 'range' + ranger.value = 100 + ranger.addEventListener('input', this.handleSlide) + slider.appendChild(ranger) + document.body.appendChild(slider) + + // this.$watch('value', val => { + // ranger.value = val + // }) + + document.addEventListener("keydown", (e) => { + if (e.shiftKey && e.key === "L") { + document.getElementById("slider").classList.toggle("show"); + } + }); + document.getElementById("slider").addEventListener("mouseleave", () => { + setTimeout(() => { + document.getElementById("slider").classList.remove("show"); + }, 200); + }); + }, + methods: { + handleSlide(e) { + this.value = e.target.value + window.scroll(0, 0) + }, + }, }; -