define("modules/clean/api_v2/client",["require","exports","tslib","jquery","modules/clean/api_v2/error","modules/clean/devtools/perf_hub_actions","modules/constants/debug","modules/constants/request","modules/core/i18n","modules/core/cookies","modules/core/notify","modules/core/uri"],function(e,t,r,n,s,o,a,i,l,c,p,u){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var d=(function(){function e(e,t){if(void 0===e&&(e="async"),"async"===e){if(void 0!==t)throw new Error("syncMode is 'async'; do not specify a syncTimeout")}else{if("syncOrServiceWorker"===e)throw new Error("syncOrServiceWorker mode not yet supported");if(void 0===t)throw new Error("syncMode is "+e+", but syncTimeout was not specified");if(t<=0)throw new Error("syncMode is "+e+", and you passed syncTimeout="+t+". syncTimeout must be a positive number")}this.syncMode=e,this.syncTimeout=t}return e.prototype.rpc=function(t,r,n,s){null==n&&(n=null);var o=e.getHeaders(t,s),a=e.getRpcUriStringAndPath(r),i=JSON.stringify(n);return this.executeRpc(a.uriString,a.path,o,i)},e.prototype.upload=function(t,n,s,o,a){var i=e.getHeaders(t,r.__assign({"Dropbox-API-Arg":JSON.stringify(s)},a)),l=e.getRpcUriStringAndPath(n);return this.executeRpc(l.uriString,l.path,i,o,"application/octet-stream")},e.getHeaders=function(e,t){var n=c.read("__Host-js_csrf")||"";return r.__assign({"X-Dropbox-Uid":null!=e?e:i.LOGGED_OUT_X_DROPBOX_UID,"X-CSRF-Token":n},t)},e.getRpcUriStringAndPath=function(e){var t=new u({scheme:"https",authority:"www.dropbox.com",path:"/2/"+e});return a.CPROFILE_ENABLED&&t.setQuery({cProfile:a.CPROFILE_PARAMETER,parent_request_id:i.REQUEST_ID}),{uriString:t.toString(),path:t.getPath()}},e.prototype.executeRpc=function(e,t,r,n,s){switch(void 0===n&&(n=""),void 0===s&&(s="application/json"),this.syncMode){case"async":return this.executeAsyncRpc(e,t,r,n,s);case"sync":return this.executeSyncRpc(e,t,r,n,s);case"syncOrServiceWorker":throw new Error("syncOrServiceWorker mode not yet supported")}},e.prototype.executeAsyncRpc=function(t,r,s,o,a){return new Promise(function(i,l){return n.ajax({type:"POST",url:t,contentType:a,headers:s,data:o}).done(function(t,n,s){return i(e.processXHRSuccess(r,t,n,s))}).fail(function(t){return l(e.processXHRError(t))})})},e.prototype.executeSyncRpc=function(t,r,s,o,a){var i=Promise.resolve(null),l=function(t,n,s){i=Promise.resolve(e.processXHRSuccess(r,t,n,s))},c=function(t){i=Promise.reject(e.processXHRError(t))};return n.ajax({type:"POST",url:t,contentType:a,headers:s,data:o,async:!1,timeout:this.syncTimeout,success:l,error:c}),i},e.processXHRSuccess=function(e,t,r,n){return a.CPROFILE_ENABLED&&o.PerfHubActions.add_ajax_profile(n,e),null!=n.responseText?JSON.parse(n.responseText):null},e.processXHRError=function(e){return s.ApiError.parseResponse(e.status,e.getAllResponseHeaders(),e.responseText)},e})();t.ApiV2Client=d;var h=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t.prototype.rpc=function(t,r,n,s,o){return void 0===o&&(o=!1),e.prototype.rpc.call(this,t,r,n,s).catch(function(e){var t;return t=null!=e.error?e.error.console_error:e.message?e.message:l._("There was a problem completing this request."),o&&p.error(t),Promise.reject(e)})},t})(d);t.TeamActionsClient=h}),define("modules/clean/api_v2/error",["require","exports","tslib","modules/core/html","modules/core/i18n","external/underscore"],function(e,t,r,n,s,o){"use strict";function a(e){return function(t){if(t instanceof i)return e(t);throw t}}Object.defineProperty(t,"__esModule",{value:!0});var i=(function(){function e(e){this.message=e}return e.parseResponse=function(t,r,a,i){void 0===i&&(i=null);var l,c="";null==i&&(i=t in h?h[t]:t>=500?u:e);var p={raw:{status:t,headerString:r,responseBody:a},summary:null,error:{},headers:r?o.object(r.split("\n").map(function(e){return e.split(": ")})):{}};try{var d=JSON.parse(a)||{};p.error=d.error,p.summary=d.error_summary,c=null!=d.user_message?d.user_message.text:""}catch(e){}return 429!==t||c||(c=s._('Folder updates in progress — please try again later.\nLearn more')),l=new n(c),o.extend(new i(l),p)},e})();t.ApiError=i;var l=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t})(i);t.BadRequestError=l;var c=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t})(i);t.AuthError=c;var p=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t})(i);t.AppError=p;var u=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t})(i);t.ServerError=u;var d=(function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t})(i);t.RateLimitError=d,t.catchApiError=a;var h={400:l,401:c,409:p,429:d}}),function(){define("modules/clean/avatar/avatar_with_default",["external/react","modules/clean/avatar/photo_avatar","modules/clean/avatar/size","modules/clean/css"],function(e,t,r,n){var s,o;return o=r.VALID_AVATAR_DIMENSIONS,e.DOM,s=e.createFactory(t),e.createClass({displayName:"AvatarWithDefault",propTypes:{alt:e.PropTypes.string,dimension:e.PropTypes.oneOf(o).isRequired,defaultAvatar:e.PropTypes.element.isRequired,onPhotoClick:e.PropTypes.func,photoUrl:e.PropTypes.string,optionalClass:e.PropTypes.string,shape:e.PropTypes.oneOf(["CIRCLE","SQUARE"]).isRequired,onLoad:e.PropTypes.func,onError:e.PropTypes.func},getDefaultProps:function(){return{shape:"CIRCLE"}},componentDidMount:function(){if(n.require_css("/static/css/scooter/scooter-scoped-vflhQ6850.css"),null==this.props.photoUrl&&null!=this.props.onLoad)return this.props.onLoad()},render:function(){return null!=this.props.photoUrl?s({alt:this.props.alt,dimension:this.props.dimension,onClick:this.props.onPhotoClick,photoUrl:this.props.photoUrl,optionalClass:this.props.optionalClass,shape:this.props.shape,onLoad:this.props.onLoad,onError:this.props.onError}):this.props.defaultAvatar}})})}.call(this),function(){define("modules/clean/avatar/initials_avatar",["external/react","modules/clean/avatar/size","modules/clean/avatar/style","modules/clean/css"],function(e,t,r,n){var s,o,a;return s=t.VALID_AVATAR_DIMENSIONS,a=r.getClassName,o=e.DOM,e.createClass({displayName:"InitialsAvatar",propTypes:{alt:e.PropTypes.string,dimension:e.PropTypes.oneOf(s).isRequired,initials:e.PropTypes.string.isRequired,shape:e.PropTypes.oneOf(["CIRCLE","SQUARE"]).isRequired,color:e.PropTypes.string,onClick:e.PropTypes.func,optionalClass:e.PropTypes.string},componentDidMount:function(){return n.require_css("/static/css/scooter/scooter-scoped-vflhQ6850.css")},render:function(){var e;return e=["c-avatar--no-img","c-avatar--"+this.props.shape.toLowerCase()],null!=this.props.optionalClass&&e.push(this.props.optionalClass),null!=this.props.onClick&&this.props.alt?(e.push("u-unbutton"),o.button({className:a(this.props.dimension,e),onClick:this.props.onClick,style:this.getContainerStyle()},o.span({"aria-hidden":!0},this.props.initials),o.span({className:"ax-visually-hidden"},this.props.alt))):o.div({className:a(this.props.dimension,e),onClick:this.props.onClick,style:this.getContainerStyle()},this.props.alt?[o.span({key:"initials","aria-hidden":!0},this.props.initials),o.span({key:"alt",className:"ax-visually-hidden"},this.props.alt)]:this.props.initials)},getContainerStyle:function(){var e;return e={},this.props.color&&(e.backgroundColor=this.props.color),e}})})}.call(this),function(){var e=function(e,r){function n(){this.constructor=e}for(var s in r)t.call(r,s)&&(e[s]=r[s]);return n.prototype=r.prototype,e.prototype=new n,e.__super__=r.prototype,e},t={}.hasOwnProperty;define("modules/clean/avatar/photo_avatar",["external/react","modules/clean/avatar/size","modules/clean/avatar/style"],function(t,r,n){var s,o,a;return s=r.VALID_AVATAR_DIMENSIONS,n.dynamicInlineStyle,a=n.getClassName,o=t.DOM,(function(r){function n(){return n.__super__.constructor.apply(this,arguments)}return e(n,r),n.propTypes=function(){return{alt:t.PropTypes.string,dimension:t.PropTypes.oneOf(s).isRequired,photoUrl:t.PropTypes.string.isRequired,onClick:t.PropTypes.func,optionalClass:t.PropTypes.string,shape:t.PropTypes.oneOf(["CIRCLE","SQUARE"]),onLoad:t.PropTypes.func,onError:t.PropTypes.func}},n.defaultProps={shape:"CIRCLE"},n.prototype.render=function(){var e,t;return e=["c-avatar--"+this.props.shape.toLowerCase()],null!=this.props.optionalClass&&e.push(this.props.optionalClass),t=o.img({alt:this.props.alt||"",src:this.props.photoUrl,width:this.props.dimension,height:this.props.dimension,onLoad:this.props.onLoad,onError:this.props.onError}),null!=this.props.onClick&&this.props.alt?(e.push("u-unbutton"),o.button({className:a(this.props.dimension,e),onClick:this.props.onClick},t)):o.div({className:a(this.props.dimension,e),onClick:this.props.onClick},t)},n})(t.Component)})}.call(this),function(){define("modules/clean/avatar/size",[],function(){var e,t,r;return e={XSMALL:16,SMALL:24,MEDIUM:32,LARGE:48,XLARGE:64},t=(function(){var t;t=[];for(r in e)t.push(e[r]);return t})(),{AVATAR_DIMENSION_BY_SIZE:e,VALID_AVATAR_DIMENSIONS:t}})}.call(this),function(){define("modules/clean/avatar/style",["external/classnames","external/react","modules/clean/accessibility/utils"],function(e,t,r){var n,s,o,a;return s=r.accessibleColorPalette,n={16:"c-avatar--xs",24:"c-avatar--s",32:"c-avatar--m",48:"c-avatar--l",64:"c-avatar--xl"},o=function(e){var t,r;for(null==e&&(e=""),t=5381*e.length,r=0;r",{action:c,method:"post"}),u=0,d=o;u",{name:"ns_paths",value:s+"/"+n.filename(h.fq_path)}).appendTo(p)}r("",{name:"w",value:i}).appendTo(p),r(document.body).append(p),p.submit(),p.remove();var m}function u(e){for(var t=e.fq_paths,n=e.subject_uid,s=e.block_hash,o=e.parent_path,a=new l({scheme:"https",authority:"dl-web.dropbox.com",path:"/zip_batch",query:(d={},d._subject_uid=String(n),d)}).toString(),i=r("