美文网首页
Echarts | 饼图引导线文字样式的调整

Echarts | 饼图引导线文字样式的调整

作者: J_SQ | 来源:发表于2019-10-16 14:46 被阅读0次

设计图

![image](https://img.haomeiwen.com/i14188382/6ca314f6a4ea1289.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)

没改之前

![image](https://img.haomeiwen.com/i14188382/896590a404ee389a.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)

实现代码如下:

 ```

series: [

          {

            label: {

              normal: {

                formatter: '{b|{b}}\n {c|{c}人} \n {a|{d}%}',//\n实现换行

                rich: {

                  a: {

                    color: '#333',

                    fontSize: 12,

                    lineHeight: 20

                  },

                  b: {

                    fontSize: 12,

                    lineHeight: 20,

                    color: '#333'

                  },

                  c: {

                    fontSize: 12,

                    lineHeight: 20,

                    color: '#333'

                  }

                }

              }

            }

          }

        ]

```

令人头大的echarts配置项,记录一下

相关文章

网友评论

      本文标题:Echarts | 饼图引导线文字样式的调整

      本文链接:https://www.haomeiwen.com/subject/wbfumctx.html