最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - NVD3 - removing options for stackedAreaChart - Stack Overflow

programmeradmin5浏览0评论

I'm using the stacked area chart in NVD3, but I don't want it to show the three options for Stacked, Stream, and Expanded.

Is there a flag I can pass to remove the UI element to switch between them and pick which one to use?

I'm using the stacked area chart in NVD3, but I don't want it to show the three options for Stacked, Stream, and Expanded.

Is there a flag I can pass to remove the UI element to switch between them and pick which one to use?

Share Improve this question edited May 4, 2016 at 17:59 Mosh Feu 29.3k18 gold badges93 silver badges141 bronze badges asked Aug 25, 2013 at 18:54 LeopdLeopd 42.8k32 gold badges135 silver badges172 bronze badges
Add a ment  | 

3 Answers 3

Reset to default 12

You can pass .showControls(false) to the model to disable this.

 $scope.options = {
            chart: {
               ..
                showControls: false,
                }
        };

Add showControls: false , to your options

Alternatively, if you're using angular-nvd3, you can use CSS.

svg {
    .nv-controlsWrap {
        display: none;
    }
}
发布评论

评论列表(0)

  1. 暂无评论