Skip to content

Commit

Permalink
apply chart-studio.plotly.com and other fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
archmoj committed Mar 26, 2020
1 parent 9959cb8 commit d81e598
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions src/plot_api/plot_config.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ var configAttributes = {
valType: 'string',
dflt: '',
description: [
'When set it determines base URL e.g. \'https://plotly.com\' for',
'the \'Edit in Chart Studio\' (aka sendDataToCloud) mode bar button',
'When set it determines base URL for',
'the \'Edit in Chart Studio\' `showEditInChartStudio`/`showSendToCloud` mode bar button',
'and the showLink/sendData on-graph link.',
'To enable sending your data to Plotly\'s public cloud, you need to',
'To enable sending your data to Chart Studio Cloud, you need to',
'set both `plotlyServerURL` to \'https://chart-studio.plotly.com\' and',
'also set `showSendToCloud` to true.'
].join(' ')
Expand Down Expand Up @@ -265,7 +265,7 @@ var configAttributes = {
dflt: false,
description: [
'Should we include a ModeBar button, labeled "Edit in Chart Studio",',
'that sends this chart to plotly.com (formerly plot.ly) or another plotly server',
'that sends this chart to chart-studio.plotly.com (formerly plot.ly) or another plotly server',
'as specified by `plotlyServerURL` for editing, export, etc? Prior to version 1.43.0',
'this button was included by default, now it is opt-in using this flag.',
'Note that this button can (depending on `plotlyServerURL` being set) send your data',
Expand Down
10 changes: 5 additions & 5 deletions test/jasmine/tests/config_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -505,7 +505,7 @@ describe('config argument', function() {
Plotly.plot(gd, [], {})
.then(function() {
expect(gd._context.plotlyServerURL).not.toBe('https://plot.ly');
expect(gd._context.plotlyServerURL).not.toBe('https://plotly.com');
expect(gd._context.plotlyServerURL).not.toBe('https://chart-studio.plotly.com');
expect(gd._context.plotlyServerURL).toBe('');

Plotly.Plots.sendDataToCloud(gd);
Expand All @@ -515,15 +515,15 @@ describe('config argument', function() {
.then(done);
});

it('should be able to connect to plotly cloud when set to https://plotly.com', function(done) {
it('should be able to connect to Chart Studio Cloud when set to https://chart-studio.plotly.com', function(done) {
Plotly.plot(gd, [], {}, {
plotlyServerURL: 'https://plotly.com'
plotlyServerURL: 'https://chart-studio.plotly.com'
})
.then(function() {
expect(gd._context.plotlyServerURL).toBe('https://plotly.com');
expect(gd._context.plotlyServerURL).toBe('https://chart-studio.plotly.com');

Plotly.Plots.sendDataToCloud(gd);
expect(form.action).toBe('https://plotly.com/external');
expect(form.action).toBe('https://chart-studio.plotly.com/external');
expect(form.method).toBe('post');
})
.catch(failTest)
Expand Down

0 comments on commit d81e598

Please sign in to comment.