{"remainingRequest":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xypm-web\\node_modules\\@jiaminghi\\data-view\\lib\\components\\decoration5\\src\\main.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\@jiaminghi\\data-view\\lib\\components\\decoration5\\src\\main.vue","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xypm-web\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\nimport autoResize from '../../../mixin/autoResize'\n\nimport { getPolylineLength } from '@jiaminghi/charts/lib/util'\n\nimport { deepMerge } from '@jiaminghi/charts/lib/util/index'\n\nimport { deepClone } from '@jiaminghi/c-render/lib/plugin/util'\n\nexport default {\n  name: 'DvDecoration5',\n  mixins: [autoResize],\n  props: {\n    color: {\n      type: Array,\n      default: () => ([])\n    },\n    dur: {\n      type: Number,\n      default: 1.2\n    }\n  },\n  data () {\n    return {\n      ref: 'decoration-5',\n\n      line1Points: '',\n      line2Points: '',\n\n      line1Length: 0,\n      line2Length: 0,\n\n      defaultColor: ['#3f96a5', '#3f96a5'],\n\n      mergedColor: []\n    }\n  },\n  watch: {\n    color () {\n      const { mergeColor } = this\n\n      mergeColor()\n    }\n  },\n  methods: {\n    afterAutoResizeMixinInit () {\n      const { calcSVGData } = this\n\n      calcSVGData()\n    },\n    calcSVGData () {\n      const { width, height } = this\n\n      let line1Points = [\n        [0, height * 0.2], [width * 0.18, height * 0.2], [width * 0.2, height * 0.4], [width * 0.25, height * 0.4],\n        [width * 0.27, height * 0.6], [width * 0.72, height * 0.6], [width * 0.75, height * 0.4],\n        [width * 0.8, height * 0.4], [width * 0.82, height * 0.2], [width, height * 0.2]\n      ]\n\n      let line2Points = [\n        [width * 0.3, height * 0.8], [width * 0.7, height * 0.8]\n      ]\n\n      const line1Length = getPolylineLength(line1Points)\n      const line2Length = getPolylineLength(line2Points)\n\n      line1Points = line1Points.map(point => point.join(',')).join(' ')\n      line2Points = line2Points.map(point => point.join(',')).join(' ')\n\n      this.line1Points = line1Points\n      this.line2Points = line2Points\n\n      this.line1Length = line1Length\n      this.line2Length = line2Length\n    },\n    onResize () {\n      const { calcSVGData } = this\n\n      calcSVGData()\n    },\n    mergeColor () {\n      const { color, defaultColor } = this\n\n      this.mergedColor = deepMerge(deepClone(defaultColor, true), color || [])\n    }\n  },\n  mounted () {\n    const { mergeColor } = this\n\n    mergeColor()\n  }\n}\n",null]}