高级饼图¶
高级饼图¶
{% embed data=“{“url”:”https://stackblitz.com/edit/swimlane-pie-chart-advanced?embed=1&file=app/app.component.ts”,”type”:”link”,”title”:”advanced-pie-chart - StackBlitz”,”description”:”Advanced Pie Chart demo for ngx-charts”,”icon”:{“type”:”icon”,”url”:”https://c.staticblitz.com/assets/icon-664493542621427cc8adae5e8f50d632f87aaa6ea1ce5b01e9a3d05b57940a9f.png”,”aspectRatio”:0},”thumbnail”:{“type”:”thumbnail”,”url”:”https://c.staticblitz.com/assets/icon-664493542621427cc8adae5e8f50d632f87aaa6ea1ce5b01e9a3d05b57940a9f.png”,”aspectRatio”:0}}” %}
输入¶
属性 |
类型 |
De fa ul
Va lu
|
描述 |
---|---|---|---|
view |
number[] |
图表[宽度,高度]的尺寸。如果未定义,图表将适合于父容器的大小 |
|
resul ts |
obje ct[] |
图表数据 |
|
schem e |
obje ct |
图表的颜色方案 |
|
custo mColo rs |
func tion or obje ct |
自定义颜色图表。用于覆盖颜色的特定值 |
|
anima tions |
bool ean |
tr ue |
使动画 |
gradi ent |
bool ean |
fa ls e |
具有梯度,而不是纯色填充元件 |
activ eEntr ies |
obje ct[] |
[] |
元素亮点 |
label |
stri ng |
‘T ot al ’ |
the text to show under the total value |
toolt ipDis abled |
bool ean |
fa ls e |
显示或隐藏工具提示 |
toolt ipTem plate |
Temp late Ref |
工具提示中要显示的自定义 ng-template |
|
value Forma tting |
func tion |
function that formats the numerical value in the chart legend |
|
nameF ormat ting |
func tion |
function that formats name in the chart legend |
|
perce ntage Forma tting |
func tion |
function that formats the percentage number in the chart legend |
输出¶
属性 |
描述 |
---|---|
select |
单击事件 |
activate |
元件激活事件(鼠标输入) |
deactivate |
元件去激活事件(鼠标离开) |