@@ -43,7 +43,8 @@ var rules = {
4343 "X [data-title]:hover:before,X [data-title]:hover:after": "display:block;opacity:1;",
4444 "X [data-title]:before": "content:'';position:absolute;background:transparent;border:6px solid transparent;z-index:1002;margin-top:-12px;border-bottom-color:#69738a;margin-right:-6px;",
4545 "X [data-title]:after": "content:attr(data-title);background:#69738a;color:white;padding:8px 10px;font-size:12px;line-height:12px;white-space:nowrap;margin-right:-18px;border-radius:2px;",
46- Y: "position:fixed;top:50px;right:20px;z-index:10000;",
46+ Y: "font-family:'Open Sans';position:fixed;top:50px;right:20px;z-index:10000;font-size:10pt;max-width:180px;",
47+ "Y p": "margin:0;",
4748 "Y .notifier-note": "min-width:180px;max-width:250px;border:1px solid #fff;z-index:3000;margin:0;background-color:#8c97af;background-color:rgba(140,151,175,0.9);color:#fff;padding:10px;",
4849 "Y .notifier-close": "color:#fff;opacity:0.8;float:right;padding:0 5px;background:none;border:none;font-size:20px;font-weight:bold;line-height:20px;",
4950 "Y .notifier-close:hover": "color:#444;text-decoration:none;cursor:pointer;"
@@ -123,6 +124,10 @@ module.exports = {
123124 'movie': {
124125 'width': 1000,
125126 'path': 'm938 413l-188-125c0 37-17 71-44 94 64 38 107 107 107 187 0 121-98 219-219 219-121 0-219-98-219-219 0-61 25-117 66-156h-115c30 33 49 76 49 125 0 103-84 187-187 187s-188-84-188-187c0-57 26-107 65-141-38-22-65-62-65-109v-250c0-70 56-126 125-126h500c69 0 125 56 125 126l188-126c34 0 62 28 62 63v375c0 35-28 63-62 63z m-750 0c-69 0-125 56-125 125s56 125 125 125 125-56 125-125-56-125-125-125z m406-1c-87 0-157 70-157 157 0 86 70 156 157 156s156-70 156-156-70-157-156-157z'
127+ },
128+ 'disk': {
129+ 'width': 857.1,
130+ 'path': 'm214-7h429v214h-429v-214z m500 0h72v500q0 8-6 21t-11 20l-157 156q-5 6-19 12t-22 5v-232q0-22-15-38t-38-16h-322q-22 0-37 16t-16 38v232h-72v-714h72v232q0 22 16 38t37 16h465q22 0 38-16t15-38v-232z m-214 518v178q0 8-5 13t-13 5h-107q-7 0-13-5t-5-13v-178q0-8 5-13t13-5h107q7 0 13 5t5 13z m357-18v-518q0-22-15-38t-38-16h-750q-23 0-38 16t-16 38v750q0 22 16 38t38 16h517q23 0 50-12t42-26l156-157q16-15 27-42t11-49z'
126131 }
127132};
128133},{}],3:[function(require,module,exports){
@@ -53590,6 +53595,11 @@ proto.toImage = function() {
5359053595 });
5359153596};
5359253597
53598+ proto.sendDataToCloud = function() {
53599+ var gd = this.graphInfo;
53600+ Plotly.Plots.sendDataToCloud(gd)
53601+ };
53602+
5359353603/**
5359453604 *
5359553605 * @Property config specification hash of button parameters
@@ -53659,6 +53669,11 @@ proto.config = function config() {
5365953669 icon: 'camera',
5366053670 click: this.toImage
5366153671 },
53672+ sendDataToCloud: {
53673+ title: 'save and edit plot in cloud',
53674+ icon: 'disk',
53675+ click: this.sendDataToCloud
53676+ },
5366253677 // gl3d
5366353678 zoom3d: {
5366453679 title: 'Zoom',
@@ -60761,7 +60776,7 @@ module.exports = {
6076160776 showTips: true,
6076260777
6076360778 // link to open this plot in plotly
60764- showLink: true ,
60779+ showLink: false ,
6076560780
6076660781 // if we show a link, does it contain data or just link to a plotly file?
6076760782 sendData: true,
@@ -65319,15 +65334,15 @@ fx.modeBar = function(gd){
6531965334function chooseModebarButtons(fullLayout) {
6532065335 if(fullLayout._hasGL3D) {
6532165336 return [
65322- ['toImage'],
65337+ ['toImage', 'sendDataToCloud' ],
6532365338 ['orbitRotation', 'tableRotation', 'zoom3d', 'pan3d'],
6532465339 ['resetCameraDefault3d', 'resetCameraLastSave3d'],
6532565340 ['hoverClosest3d']
6532665341 ];
6532765342 }
6532865343 else if(fullLayout._hasGeo) {
6532965344 return [
65330- ['toImage'],
65345+ ['toImage', 'sendDataToCloud' ],
6533165346 ['zoomInGeo', 'zoomOutGeo', 'resetGeo'],
6533265347 ['hoverClosestGeo']
6533365348 ];
@@ -65345,9 +65360,9 @@ function chooseModebarButtons(fullLayout) {
6534565360 }
6534665361 }
6534765362
65348- if(allFixed) buttons = [['toImage']];
65363+ if(allFixed) buttons = [['toImage', 'sendDataToCloud' ]];
6534965364 else buttons = [
65350- ['toImage'],
65365+ ['toImage', 'sendDataToCloud' ],
6535165366 ['zoom2d', 'pan2d'],
6535265367 ['zoomIn2d', 'zoomOut2d', 'resetScale2d', 'autoScale2d']
6535365368 ];
@@ -71686,37 +71701,8 @@ function positionPlayWithData(gd, container){
7168671701 .text(gd._context.linkText + ' ' + String.fromCharCode(187));
7168771702
7168871703 if(gd._context.sendData) {
71689- link.on('click',function(){
71690- gd.emit('plotly_beforeexport');
71691-
71692- var baseUrl = (window.PLOTLYENV && window.PLOTLYENV.BASE_URL) || 'https://plot.ly';
71693-
71694- var hiddenformDiv = d3.select(gd)
71695- .append('div')
71696- .attr('id', 'hiddenform')
71697- .style('display', 'none');
71698-
71699- var hiddenform = hiddenformDiv
71700- .append('form')
71701- .attr({
71702- action: baseUrl + '/external',
71703- method: 'post',
71704- target: '_blank'
71705- });
71706-
71707- var hiddenformInput = hiddenform
71708- .append('input')
71709- .attr({
71710- type: 'text',
71711- name: 'data'
71712- });
71713-
71714- hiddenformInput.node().value = plots.graphJson(gd, false, 'keepdata');
71715- hiddenform.node().submit();
71716- hiddenformDiv.remove();
71717-
71718- gd.emit('plotly_afterexport');
71719- return false;
71704+ link.on('click', function() {
71705+ plots.sendDataToCloud(gd)
7172071706 });
7172171707 }
7172271708 else {
@@ -71728,6 +71714,38 @@ function positionPlayWithData(gd, container){
7172871714 });
7172971715 }
7173071716}
71717+ plots.sendDataToCloud = function(gd) {
71718+ gd.emit('plotly_beforeexport');
71719+
71720+ var baseUrl = (window.PLOTLYENV && window.PLOTLYENV.BASE_URL) || 'https://plot.ly';
71721+
71722+ var hiddenformDiv = d3.select(gd)
71723+ .append('div')
71724+ .attr('id', 'hiddenform')
71725+ .style('display', 'none');
71726+
71727+ var hiddenform = hiddenformDiv
71728+ .append('form')
71729+ .attr({
71730+ action: baseUrl + '/external',
71731+ method: 'post',
71732+ target: '_blank'
71733+ });
71734+
71735+ var hiddenformInput = hiddenform
71736+ .append('input')
71737+ .attr({
71738+ type: 'text',
71739+ name: 'data'
71740+ });
71741+
71742+ hiddenformInput.node().value = plots.graphJson(gd, false, 'keepdata');
71743+ hiddenform.node().submit();
71744+ hiddenformDiv.remove();
71745+
71746+ gd.emit('plotly_afterexport');
71747+ return false;
71748+ }
7173171749
7173271750plots.supplyDefaults = function(gd) {
7173371751 // fill in default values:
0 commit comments