在ng2图表中将条形与条形标签对齐

时间:2019-02-22 07:28:29

标签: angular ng2-charts

我在我的角度应用程序中使用valor软件enter image description here的ng2图表绘制了条形图。 我的条形图和条形图标签彼此不对齐。https://valor-software.com/ng2-charts/ 这是在component.ts文件

中指定的条形图选项
const fixedOrder =['self_owner','wife','mother','son','grand_child']

const orderedArr=arr.sort(function(a, b) {
   return a.fixedOrder.indexOf(a.relation) - b.fixedOrder.indexOf(a.relation);
});

在我的component.html中,我插入了这样的条形图

<div id="app" class="demo"></div>

我尝试使用

swift package init --type library

在我的条形图选项中,但条形仍未与标签对齐。

0 个答案:

没有答案