NabJa
July 24, 2019, 9:35am
1
Hi there,
I am trying to add annotations to a point in a 3D scatter plot upon a click.
Here is my example that does crash upon a click: 3D-plot-annotation-example
The example is based on example-link .
The errors I get:
Error: attribute transform: Trailing garbage, “rotate(0,NaN,NaN)”.
Error: attribute d: Expected number, “MNaN,NaNLNaN,NaN”.
Thank you …
Here’s a working example: https://codepen.io/etpinard/pen/bXebYX?editors=1010
Some notes:
you need to relayout into scene.annotations - not annotations which are reserved for (x,y) annotations
you need to register the event handler using .once (instead of .on) to workaround the 3d render loop (more on that topic in https://github.com/plotly/plotly.js/issues/1025 )