Skip to content

Commit 196da4e

Browse files
plotlyoffline: use Plotly.newPlot (Plotly.plot removed since v1.59)
1 parent 7a7228a commit 196da4e

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

plotly/plotly_offline_aux/plotlyoffline.m

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,12 @@
5656
'</script>'], plotlyDomain, linkText);
5757

5858
% template Plotly.plot
59-
script = sprintf(['\n Plotly.plot("%s", {\n"data": %s,' ...
59+
script = sprintf(['\n Plotly.newPlot("%s", {\n"data": %s,' ...
6060
'\n"layout": %s,\n"frames": %s\n}).then(function(){'...
61+
'\n if (typeof $ !== "undefined") {' ...
6162
'\n $(".%s.loading").remove();' ...
6263
'\n $(".link--embedview").text("%s");'...
64+
'\n }' ...
6365
'\n });'], id, jData, jLayout, ...
6466
jFrames, id, linkText);
6567

0 commit comments

Comments
 (0)