undefinedfix
Sign in

Ecarts line chart gradient, legend does not gradient, how to achieve

Domski edited in Fri, 24 Jun 2022
      this.echarts1_option.option.series.push({
        name: this.cclass[index],
        data: element,
        type: 'line',
        areaStyle: {},
        itemStyle: {
          normal: {
            lineStyle: {
              color: color[index],
            },
            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
              { offset: 0, color: color[index] },
              { offset: 1, color: '#fff' },
            ]),
          },
        },
      });
1 Replies
obidano
commented on Sat, 25 Jun 2022

Have you solved the problem

lock This question has been locked and the reply function has been disabled.