Skip to content

restyle textposition produces javascript error #2688

Description

@kochelmonster

Try out the following example and click on "No Text" link.

<head><!-- Plotly.js --><scriptsrc="https://cdn.plot.ly/plotly-latest.min.js"></script></head><body><divid="myDiv"><!-- Plotly chart will be drawn inside this DIV --></div><script>varxValue=['Product A','Product B','Product C'];varyValue=[20,14,23];vartrace1={x: xValue,y: yValue,type: 'bar',text: yValue,textposition: 'auto',hoverinfo: 'none',marker: {color: 'rgb(158,202,225)',opacity: 0.6,line: {color: 'rbg(8,48,107)',width: 1.5}}};vardata=[trace1];varlayout={title: 'January 2013 Sales Report'};Plotly.newPlot('myDiv',data,layout);functionno_text(){Plotly.restyle('myDiv',{textposition: ['none']},[0]);}</script><ahref="javascript:no_text()">No Text</a></body>

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugsomething brokenregressionthis used to work

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions