angular-nvd3 迷你图和尾随 currentValue 数字
angular-nvd3 sparkline and trailing currentValue number
我才刚刚开始了解 nvd3。我实际上是在使用 angular-nvd3 来构建迷你图。我找不到的选项是如何摆脱尾随的 currentValue。我以为 showValues 可能就是它,但实际上我看不出有什么不同。
这个 plunker 显示了一个迷你图,其末尾带有“23”,表示最后一个值。这就是我想要摆脱的。
http://plnkr.co/edit/CcLayxryGZJGc5vBNpyB?p=preview
$scope.options = {
chart: {
type: 'sparklinePlus',
height: 300,
showValues: false
}
};
有什么帮助吗?
将此添加到样式以隐藏最后一个值
显示带有文本标签的组none。
<style>
.nv-valueWrap {display:none;}
</style>
工作代码here
只需设置未记录*选项 showLastValue
$scope.options = {
chart: {
type: 'sparklinePlus',
height: 300,
showLastValue: false,
}
};
* 我在依赖库 nvds http://nvd3-community.github.io/nvd3/examples/documentation.html
的 LineChart 的 "new" 文档中找到了这个
这是一个工作示例:
http://plnkr.co/edit/310OK7vgHuxcXj0GWkpc?p=preview
我才刚刚开始了解 nvd3。我实际上是在使用 angular-nvd3 来构建迷你图。我找不到的选项是如何摆脱尾随的 currentValue。我以为 showValues 可能就是它,但实际上我看不出有什么不同。
这个 plunker 显示了一个迷你图,其末尾带有“23”,表示最后一个值。这就是我想要摆脱的。
http://plnkr.co/edit/CcLayxryGZJGc5vBNpyB?p=preview
$scope.options = {
chart: {
type: 'sparklinePlus',
height: 300,
showValues: false
}
};
有什么帮助吗?
将此添加到样式以隐藏最后一个值
显示带有文本标签的组none。
<style>
.nv-valueWrap {display:none;}
</style>
工作代码here
只需设置未记录*选项 showLastValue
$scope.options = {
chart: {
type: 'sparklinePlus',
height: 300,
showLastValue: false,
}
};
* 我在依赖库 nvds http://nvd3-community.github.io/nvd3/examples/documentation.html
的 LineChart 的 "new" 文档中找到了这个这是一个工作示例: http://plnkr.co/edit/310OK7vgHuxcXj0GWkpc?p=preview