Commit 2eb6b3e1 by 匡雅琴

样式调整

1 parent 2f93be75
...@@ -121,9 +121,16 @@ export default { ...@@ -121,9 +121,16 @@ export default {
mounted() { mounted() {
this.lineDom = document.getElementById(this.domId) this.lineDom = document.getElementById(this.domId)
this[this.domId] = echarts.init(this.lineDom) this[this.domId] = echarts.init(this.lineDom)
this.chartReaize()
this.chartBindEvent() this.chartBindEvent()
}, },
methods: { methods: {
chartReaize() {
window.addEventListener('resize', () => {
console.log(444)
this[this.domId].resize()
})
},
chartBindEvent() { chartBindEvent() {
this[this.domId].setOption(this.lineOptions) this[this.domId].setOption(this.lineOptions)
if (this.revese === false) return if (this.revese === false) return
...@@ -142,9 +149,10 @@ export default { ...@@ -142,9 +149,10 @@ export default {
this.chartAction(yIndex) this.chartAction(yIndex)
}, 500) }, 500)
) )
window.addEventListener('resize', () => { // window.addEventListener('resize', () => {
this[this.domId].resize() // console.log(444);
}) // this[this.domId].resize()
// })
this[this.domId].getZr().on( this[this.domId].getZr().on(
'mouseout', 'mouseout',
utils.debounce(() => { utils.debounce(() => {
...@@ -179,8 +187,8 @@ export default { ...@@ -179,8 +187,8 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.line-box { .line-box {
height: 100%; // height: 100%;
color: #ffffff; // color: #ffffff;
.txt-orange { .txt-orange {
color: #eb6001; color: #eb6001;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!