@@ -41,7 +41,7 @@ var numericNameWarningCount = 0;
4141var numericNameWarningCountLimit = 5 ;
4242
4343/**
44- * Main plot-creation function
44+ * Internal plot-creation function
4545 *
4646 * @param {string id or DOM element } gd
4747 * the id or DOM element of the graph container div
@@ -61,7 +61,7 @@ var numericNameWarningCountLimit = 5;
6161 * object containing `data`, `layout`, `config`, and `frames` members
6262 *
6363 */
64- function plot ( gd , data , layout , config ) {
64+ function _doPlot ( gd , data , layout , config ) {
6565 var frames ;
6666
6767 gd = Lib . getGraphDiv ( gd ) ;
@@ -83,7 +83,7 @@ function plot(gd, data, layout, config) {
8383 // if there's no data or layout, and this isn't yet a plotly plot
8484 // container, log a warning to help plotly.js users debug
8585 if ( ! data && ! layout && ! Lib . isPlotDiv ( gd ) ) {
86- Lib . warn ( 'Calling Plotly.plot as if redrawing ' +
86+ Lib . warn ( 'Calling _doPlot as if redrawing ' +
8787 'but this container doesn\'t yet have a plot.' , gd ) ;
8888 }
8989
@@ -139,7 +139,7 @@ function plot(gd, data, layout, config) {
139139 var fullLayout = gd . _fullLayout ;
140140 var hasCartesian = fullLayout . _has ( 'cartesian' ) ;
141141
142- // so we don't try to re-call Plotly.plot from inside
142+ // so we don't try to re-call _doPlot from inside
143143 // legend and colorbar, if margins changed
144144 fullLayout . _replotting = true ;
145145
@@ -167,7 +167,7 @@ function plot(gd, data, layout, config) {
167167 // prepare the data and find the autorange
168168
169169 // generate calcdata, if we need to
170- // to force redoing calcdata, just delete it before calling Plotly.plot
170+ // to force redoing calcdata, just delete it before calling _doPlot
171171 var recalc = ! gd . calcdata || gd . calcdata . length !== ( gd . _fullData || [ ] ) . length ;
172172 if ( recalc ) Plots . doCalcdata ( gd ) ;
173173
@@ -552,7 +552,7 @@ function redraw(gd) {
552552 helpers . cleanLayout ( gd . layout ) ;
553553
554554 gd . calcdata = undefined ;
555- return exports . plot ( gd ) . then ( function ( ) {
555+ return exports . _doPlot ( gd ) . then ( function ( ) {
556556 gd . emit ( 'plotly_redraw' ) ;
557557 return gd ;
558558 } ) ;
@@ -573,7 +573,7 @@ function newPlot(gd, data, layout, config) {
573573 Plots . cleanPlot ( [ ] , { } , gd . _fullData || [ ] , gd . _fullLayout || { } ) ;
574574
575575 Plots . purge ( gd ) ;
576- return exports . plot ( gd , data , layout , config ) ;
576+ return exports . _doPlot ( gd , data , layout , config ) ;
577577}
578578
579579/**
@@ -1284,7 +1284,7 @@ function restyle(gd, astr, val, _traces) {
12841284 var seq = [ ] ;
12851285
12861286 if ( flags . fullReplot ) {
1287- seq . push ( exports . plot ) ;
1287+ seq . push ( exports . _doPlot ) ;
12881288 } else {
12891289 seq . push ( Plots . previousPromises ) ;
12901290
@@ -2313,7 +2313,7 @@ function update(gd, traceUpdate, layoutUpdate, _traces) {
23132313 // relayoutFlags.layoutReplot and restyleFlags.fullReplot are true
23142314 seq . push ( subroutines . layoutReplot ) ;
23152315 } else if ( restyleFlags . fullReplot ) {
2316- seq . push ( exports . plot ) ;
2316+ seq . push ( exports . _doPlot ) ;
23172317 } else {
23182318 seq . push ( Plots . previousPromises ) ;
23192319 axRangeSupplyDefaultsByPass ( gd , relayoutFlags , relayoutSpecs ) || Plots . supplyDefaults ( gd ) ;
@@ -2705,7 +2705,7 @@ function react(gd, data, layout, config) {
27052705 } ) ;
27062706 } else if ( restyleFlags . fullReplot || relayoutFlags . layoutReplot || configChanged ) {
27072707 gd . _fullLayout . _skipDefaults = true ;
2708- seq . push ( exports . plot ) ;
2708+ seq . push ( exports . _doPlot ) ;
27092709 } else {
27102710 for ( var componentType in relayoutFlags . arrays ) {
27112711 var indices = relayoutFlags . arrays [ componentType ] ;
@@ -3604,7 +3604,7 @@ function deleteFrames(gd, frameList) {
36043604}
36053605
36063606/**
3607- * Purge a graph container div back to its initial pre-Plotly.plot state
3607+ * Purge a graph container div back to its initial pre-_doPlot state
36083608 *
36093609 * @param {string id or DOM element } gd
36103610 * the id or DOM element of the graph container div
@@ -3627,7 +3627,7 @@ function purge(gd) {
36273627 // remove plot container
36283628 if ( fullLayout . _container ) fullLayout . _container . remove ( ) ;
36293629
3630- // in contrast to Plotly.Plots .purge which does NOT clear _context!
3630+ // in contrast to _doPlots .purge which does NOT clear _context!
36313631 delete gd . _context ;
36323632
36333633 return gd ;
@@ -3808,7 +3808,7 @@ exports.moveTraces = moveTraces;
38083808exports . prependTraces = prependTraces ;
38093809
38103810exports . newPlot = newPlot ;
3811- exports . plot = plot ;
3811+ exports . _doPlot = _doPlot ;
38123812exports . purge = purge ;
38133813
38143814exports . react = react ;
0 commit comments