text: /*! spJsomFluent "0.1.31" - https://github.com/TjWheeler/spJsomFluent */
  var spJsom=function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";n.r(t);var r,i,o,s=function(){function e(){}return e.reject=function(e,t){e.reject(this,{get_message:function(){return t}})},e.notImplementedPromise=function(){var t=$.Deferred();return e.reject(t,"Not Implemented"),t.promise()},e.FilterArray=function(e,t){for(var n=[],r=0;r<e.length;r++)t(e[r],r)&&n.push(e[r]);return n},e.executeQuery=function(e){var t=$.Deferred();return e.executeQueryAsync(function(e,n){t.resolve(e,n)},function(e,n){t.reject(e,n)}),t.promise()},e}(),u=function(){function e(e){this.context=e}return e.prototype.setWelcomePage=function(e,t){var n=$.Deferred(),r=e.get_rootFolder();return this.context.load(e),this.context.load(r),r.set_welcomePage(t),r.update(),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(r)}),n.promise()},e.prototype.setTitle=function(e,t){var n=$.Deferred();return this.context.load(e),e.set_title(t),e.update(),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve()}),n.promise()},e.prototype.setLogoUrl=function(e,t){var n=$.Deferred();return this.context.load(e),e.set_siteLogoUrl(t),e.update(),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve()}),n.promise()},e.prototype.activateFeature=function(e,t,n){var r=$.Deferred();return this.context.load(e),e.get_features().add(t,n,SP.FeatureDefinitionScope.web),e.update(),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve()}),r.promise()},e.prototype.createWeb=function(e,t,n,r,i){void 0===i&&(i=!0);var o=$.Deferred(),u=new SP.WebCreationInformation;u.set_url(e),u.set_title(n),u.set_webTemplate(r),u.set_useSamePermissionsAsParentSite(i);var a=t.get_webs().add(u);return this.context.load(a),s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve(a)}),o.promise()},e.prototype.doesWebExist=function(e){var t=$.Deferred(),n=[];return this.getAllWebs(this.context,this.context.get_site().get_rootWeb(),n).fail(function(e,n){t.reject(e,n)}).done(function(){for(var r=0;r<n.length;r++)if(e.toLowerCase()===n[r].get_serverRelativeUrl()||e.toLowerCase()===n[r].get_url())return void t.resolve(!0);t.resolve(!1)}),t.promise()},e.prototype.getWebs=function(e){var t=$.Deferred(),n=[];return this.getAllWebs(this.context,e,n).fail(function(e,n){t.reject(e,n)}).done(function(){t.resolve(n)}),t.promise()},e.prototype.getAllWebs=function(e,t,n){var r=this,i=$.Deferred(),o=t.get_webs();return e.load(o),s.executeQuery(e).fail(function(e,t){i.reject(e,t)}).done(function(){for(var t=[],s=0;s<o.get_count();s++){var u=o.getItemAtIndex(s);n.push(u),t.push(r.getAllWebs(e,u,n))}t.length?$.when.apply($,t).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve()}):i.resolve()}),i.promise()},e}(),a=function(){function e(e){this._fluent=null,this._helperName="web",this.webHelper=null,this._fluent=e,this.webHelper=new u(e.context)}return e.prototype.setWelcomePage=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".setWelcomePage",function(){return n.webHelper.setWelcomePage(e,t)})},e.prototype.create=function(e,t,n,r,i){var o=this;return void 0===i&&(i=!0),this._fluent.chainAction(this._helperName+".create",function(){return o.webHelper.createWeb(e,t,n,r,i)})},e.prototype.exists=function(e){var t=this;return this._fluent.chainAction(this._helperName+".exists",function(){return t.webHelper.doesWebExist(e)})},e.prototype.getWebs=function(e){var t=this;return this._fluent.chainAction(this._helperName+".getWebs",function(){return t.webHelper.getWebs(e)})},e.prototype.setTitle=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".setTitle",function(){return n.webHelper.setTitle(e,t)})},e.prototype.setLogoUrl=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".setLogoUrl",function(){return n.webHelper.setLogoUrl(e,t)})},e.prototype.activateFeature=function(e,t,n){var r=this;return void 0===n&&(n=!0),this._fluent.chainAction(this._helperName+".activateFeature",function(){return r.webHelper.activateFeature(e,t,n)})},e}(),l=function(){function e(e){this.context=e}return e.prototype.hasWebPermission=function(e,t){var n=$.Deferred();return this.context.load(t,"EffectiveBasePermissions"),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(t.get_effectiveBasePermissions().has(e))}),n.promise()},e.prototype.hasListPermission=function(e,t){var n=$.Deferred();return this.context.load(t,"EffectiveBasePermissions"),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(t.get_effectiveBasePermissions().has(e))}),n.promise()},e.prototype.hasItemPermission=function(e,t){var n=$.Deferred();return this.context.load(t,"EffectiveBasePermissions"),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(t.get_effectiveBasePermissions().has(e))}),n.promise()},e}(),c=function(){function e(e){this._fluent=null,this._helperName="permission",this.permissionHelper=null,this._fluent=e,this.permissionHelper=new l(e.context)}return e.prototype.hasWebPermission=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".hasWebPermission",function(){return n.permissionHelper.hasWebPermission(e,t)})},e.prototype.hasListPermission=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".hasListPermission",function(){return n.permissionHelper.hasListPermission(e,t)})},e.prototype.hasItemPermission=function(e,t){var n=this;return this._fluent.chainAction(this._helperName+".hasItemPermission",function(){return n.permissionHelper.hasItemPermission(e,t)})},e}(),f=function(){function e(){}return e.prototype.uploadFileAsArrayBuffer=function(e,t,n,r,i){void 0===i&&(i=null);var o=$.Deferred();return this.getArrayBuffer(e).fail(function(e){console.error("Get file buffer failed: "+e),o.reject(e)}).done(function(e){var i={url:t+"/_api/web/lists/getByTitle('"+n+"')/RootFolder/Files/Add(url='"+r+"', overwrite=true)",type:"POST",data:e,processData:!1,headers:{accept:"application/json;odata=verbose","X-RequestDigest":jQuery("#__REQUESTDIGEST").val()}};$.ajax(i).fail(function(e,t){e&&e.responseText&&e.responseText.indexOf("The security validation for this page is invalid")>-1?(console.error("SharePoint Page Validation has expired, please refresh."),o.reject(e,"SharePoint Page Validation has expired, please save your work and refresh the page.")):(console.error("Upload file failed: "+t),o.reject(e,t))}).done(function(e,t,n){e.d?o.resolve(e.d):o.resolve(e)})}),o.promise()},e.prototype.updateListItem=function(e,t,n,r){void 0===r&&(r="*"),r&&(r=r.replace(/{|}/g,"").toLowerCase()),void 0===n.__metadata&&(n.__metadata={type:"SP.ListItem"});var i=e+"/_api/Web/GetFileByServerRelativeUrl('"+t+"')/ListItemAllFields ";return $.ajax({url:i,type:"POST",data:JSON.stringify(n),headers:{"X-RequestDigest":$("#__REQUESTDIGEST").val(),"content-type":"application/json;odata=verbose","IF-MATCH":r,"X-HTTP-Method":"MERGE"}})},e.prototype.getArrayBuffer=function(e){var t=$.Deferred(),n=new FileReader;return n.onloadend=function(e){t.resolve(e.target.result)},n.onerror=function(e){t.reject(e.target.error)},n.readAsArrayBuffer(e),t.promise()},e}(),h=function(){function e(e){this.context=e}return e.prototype.createList=function(e,t,n){var r=$.Deferred(),i=new SP.ListCreationInformation;i.set_title(t),i.set_templateType(n);var o=e.get_lists().add(i);return this.context.load(o),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve(o)}),r.promise()},e.prototype.setAlerts=function(e,t,n){var r=$.Deferred(),i=e.get_lists().getByTitle(t);return this.context.load(i),i.set_enableAssignToEmail(n),i.update(),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve()}),r.promise()},e.prototype.setListItemProperties=function(e,t){var n=$.Deferred();for(var r in t)void 0!==t[r]&&e.set_item(r,t[r]);return e.update(),this.context.load(e),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(e)}),n.promise()},e.prototype.exists=function(e,t){var n=$.Deferred(),r=e.get_lists();return this.context.load(r),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){for(var e=0;e<r.get_count();e++)if(r.getItemAtIndex(e).get_title().toLowerCase()===t.toLowerCase())return void n.resolve(!0);n.resolve(!1)}),n.promise()},e.prototype.createListItemWithContentTypeName=function(e,t,n,r){var i=$.Deferred(),o=this.context,u=e.get_lists().getByTitle(t),a=new SP.ListItemCreationInformation,l=u.get_contentTypes();return o.load(l),s.executeQuery(o).fail(function(e,t){i.reject(e,t)}).done(function(){for(var e=null,t=0;t<l.get_count();t++){var c=l.getItemAtIndex(t);if(c.get_name()===n){e=c.get_id().get_stringValue();break}}var f=u.addItem(a);for(var h in e&&f.set_item("ContentTypeId",e),r)void 0!==r[h]&&f.set_item(h,r[h]);f.update(),o.load(f),s.executeQuery(o).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve(f)})}),i.promise()},e.prototype.createListItem=function(e,t,n){var r=$.Deferred(),i=this.context,o=e.get_lists().getByTitle(t),u=new SP.ListItemCreationInformation,a=o.addItem(u);for(var l in n)void 0!==n[l]&&a.set_item(l,n[l]);return a.update(),i.load(a),s.executeQuery(i).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve(a)}),r.promise()},e.prototype.loadListItem=function(e,t){void 0===t&&(t=null);var n=$.Deferred();return t&&t.length?this.context.load(e,t):this.context.load(e),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(e)}),n.promise()},e.prototype.getFile=function(e){var t=$.Deferred(),n=this.context.get_site().get_rootWeb().getFileByServerRelativeUrl(e);return this.context.load(n),s.executeQuery(this.context).fail(function(e,n){t.reject(e,n)}).done(function(){t.resolve(n)}),t.promise()},e.prototype.checkInFile=function(e,t,n,r){var i=$.Deferred(),o=e.getFileByServerRelativeUrl(t);return this.context.load(o),o.checkIn(n,r),s.executeQuery(this.context).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve(o)}),i.promise()},e.prototype.uploadFile=function(e,t,n,r){var i=this,o=$.Deferred();return r||(r=n.name),this.context.load(e),s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){(new f).uploadFileAsArrayBuffer(n,e.get_url(),t,r).fail(function(e,t){o.reject(e,t)}).done(function(t){var n=e.getFileByServerRelativeUrl(t.ServerRelativeUrl);i.context.load(n),s.executeQuery(i.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve(n)})})}),o.promise()},e.prototype.checkOutFile=function(e,t){var n=$.Deferred(),r=e.getFileByServerRelativeUrl(t);return this.context.load(r),r.checkOut(),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(r)}),n.promise()},e.prototype.getList=function(e,t){var n=$.Deferred(),r=e.get_lists().getByTitle(t);return this.context.load(r),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve(r)}),n.promise()},e.prototype.deleteList=function(e,t){var n=$.Deferred(),r=e.get_lists().getByTitle(t);return this.context.load(r),r.deleteObject(),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve()}),n.promise()},e.prototype.getFileListItem=function(e,t,n){void 0===n&&(n=null);var r=e.getFileByServerRelativeUrl(t).get_listItemAllFields();return this.loadListItem(r)},e.prototype.getListItemById=function(e,t,n,r){void 0===r&&(r=null);var i=e.get_lists().getByTitle(t).getItemById(n);return this.loadListItem(i,r)},e.prototype.deleteListItemById=function(e,t,n){var r=$.Deferred(),i=e.get_lists().getByTitle(t).getItemById(n);return this.context.load(i),i.deleteObject(),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve()}),r.promise()},e.prototype.getListItems=function(e,t,n){var r=$.Deferred(),i=e.get_lists().getByTitle(t),o=new SP.CamlQuery;n||(n="<View><Query></Query></Where>"),o.set_viewXml(n);var u=i.getItems(o);return this.context.load(u),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve(u)}),r.promise()},e.prototype.addContentTypeListAssociation=function(e,t,n){var r=this,i=$.Deferred(),o=e.get_lists().getByTitle(t),u=o.get_contentTypes();this.context.load(o),this.context.load(u);var a=this.context.get_site().get_rootWeb().get_contentTypes(),l=function(e,t){for(var n=0;n<e.get_count();n++)if(e.getItemAtIndex(n).get_name().toLowerCase()===t.toLowerCase())return e.getItemAtIndex(n);return null};return this.context.load(a),s.executeQuery(this.context).fail(function(e,t){i.reject(e,t)}).done(function(){var e=l(a,n);if(e){var t=l(u,n);if(t)i.resolve(t);else{o.get_contentTypesEnabled()||o.set_contentTypesEnabled(!0);var c=o.get_contentTypes().addExistingContentType(e);o.update(),s.executeQuery(r.context).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve(c)})}}else s.reject(i,"Content Type "+n+" not found")}),i.promise()},e.prototype.removeContentTypeListAssociation=function(e,t,n){var r=this,i=$.Deferred(),o=e.get_lists().getByTitle(t),u=o.get_contentTypes();this.context.load(o),this.context.load(u);return s.executeQuery(this.context).fail(function(e,t){i.reject(e,t)}).done(function(){var e=function(e,t){for(var n=0;n<e.get_count();n++)if(e.getItemAtIndex(n).get_name().toLowerCase()===t.toLowerCase())return e.getItemAtIndex(n);return null}(u,n);e?(e.deleteObject(),o.update(),s.executeQuery(r.context).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve()})):i.resolve()}),i.promise()},e.prototype.setDefaultValueOnList=function(e,t,n,r){var i=this,o=$.Deferred(),u=e.get_lists().getByTitle(t),a=u.get_fields();this.context.load(u),this.context.load(a);return s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){var e=function(e,t){for(var n=0;n<e.get_count();n++)if(e.getItemAtIndex(n).get_internalName().toLowerCase()===t.toLowerCase())return e.getItemAtIndex(n);return null}(a,n);e?(e.set_defaultValue(r),e.update(),s.executeQuery(i.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve()})):s.reject(o,"Field "+n+" not found")}),o.promise()},e}(),p=function(){function e(e){this.fluent=null,this.listHelper=null,this._helperName="list",this.fluent=e,this.listHelper=new h(e.context)}return e.prototype.create=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".create",function(){return r.listHelper.createList(e,t,n)})},e.prototype.exists=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".exists",function(){return n.listHelper.exists(e,t)})},e.prototype.delete=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".delete",function(){return n.listHelper.deleteList(e,t)})},e.prototype.get=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".get",function(){return n.listHelper.getList(e,t)})},e.prototype.addContentTypeListAssociation=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".addContentTypeListAssociation",function(){return r.listHelper.addContentTypeListAssociation(e,t,n)})},e.prototype.removeContentTypeListAssociation=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".removeContentTypeListAssociation",function(){return r.listHelper.removeContentTypeListAssociation(e,t,n)})},e.prototype.setDefaultValueOnList=function(e,t,n,r){var i=this;return this.fluent.chainAction(this._helperName+".setDefaultValueOnList",function(){return i.listHelper.setDefaultValueOnList(e,t,n,r)})},e.prototype.setAlerts=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".setAlerts",function(){return r.listHelper.setAlerts(e,t,n)})},e}(),d=function(){function e(e){this.fluent=null,this.listHelper=null,this._helperName="listItem",this.fluent=e,this.listHelper=new h(e.context)}return e.prototype.update=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".update",function(){return n.listHelper.setListItemProperties(e,t)})},e.prototype.createWithContentType=function(e,t,n,r){var i=this;return this.fluent.chainAction(this._helperName+".createWithContentType",function(){return i.listHelper.createListItemWithContentTypeName(e,t,n,r)})},e.prototype.create=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".create",function(){return r.listHelper.createListItem(e,t,n)})},e.prototype.get=function(e,t,n,r){var i=this;return void 0===r&&(r=null),this.fluent.chainAction(this._helperName+".get",function(){return i.listHelper.getListItemById(e,t,n,r)})},e.prototype.getFileListItem=function(e,t,n){var r=this;return void 0===n&&(n=null),this.fluent.chainAction(this._helperName+".getFileListItem",function(){return r.listHelper.getFileListItem(e,t,n)})},e.prototype.deleteById=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".deleteById",function(){return r.listHelper.deleteListItemById(e,t,n)})},e.prototype.query=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".query",function(){return r.listHelper.getListItems(e,t,n)})},e.prototype.getAll=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".query",function(){return n.listHelper.getListItems(e,t,"<View></View>")})},e}(),g=function(){function e(e){this.fluent=null,this.listHelper=null,this._helperName="file",this.fluent=e,this.listHelper=new h(e.context)}return e.prototype.get=function(e){var t=this;return this.fluent.chainAction(this._helperName+".getListItem",function(){return t.listHelper.getFile(e)})},e.prototype.getListItem=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".getListItem",function(){return n.listHelper.getFileListItem(e,t)})},e.prototype.checkIn=function(e,t,n,r){var i=this;return this.fluent.chainAction(this._helperName+".checkInFile",function(){return i.listHelper.checkInFile(e,t,n,r)})},e.prototype.checkOut=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".checkOutFile",function(){return n.listHelper.checkOutFile(e,t)})},e.prototype.uploadFile=function(e,t,n,r){var i=this;return this.fluent.chainAction(this._helperName+".uploadFile",function(){return i.listHelper.uploadFile(e,t,n,r)})},e}(),m=function(){function e(e){this.context=e}return e.prototype.getUserByEmail=function(e){return this.loadUser(this.context.get_web().ensureUser(e))},e.prototype.getUserById=function(e){return this.loadUser(this.context.get_web().get_siteUsers().getById(e))},e.prototype.loadUser=function(e){var t=$.Deferred();return this.context.load(e),this.context.executeQueryAsync(function(n,r){t.resolve(e)},function(e,n){console.error(n.get_message()),t.reject(e,n)}),t.promise()},e.prototype.getCurrentUser=function(){var e=$.Deferred(),t=this.context.get_web().get_currentUser();return this.context.load(t),this.context.executeQueryAsync(function(n,r){e.resolve(t)},function(t,n){console.error(n.get_message()),e.reject(t,n)}),e.promise()},e.prototype.getCurrentUserProfileProperties=function(){var e=this,t=$.Deferred();return SP.SOD.executeFunc("userprofile","SP.UserProfiles.PeopleManager",function(){var n=e.context,r=n.get_web().get_currentUser(),i=new SP.UserProfiles.PeopleManager(n).getMyProperties();n.load(r),n.load(i),n.executeQueryAsync(function(e,n){t.resolve(i.get_userProfileProperties())},function(e,n){console.error(n.get_message()),t.reject(e,n)})}),t.promise()},e.prototype.getCurrentUserManager=function(){var e=this,t=$.Deferred(),n=new SP.UserProfiles.PeopleManager(this.context),r=this.context.get_web().get_currentUser().get_email(),i=new SP.UserProfiles.UserProfilePropertiesForUser(this.context,"i:0#.f|membership|"+r,["Manager"]),o=n.getUserProfilePropertiesFor(i);return this.context.load(i),s.executeQuery(this.context).fail(function(e,n){t.reject(e,n)}).done(function(){if(o[0]){var n=e.context.get_web().ensureUser(o[0]);e.context.load(n),s.executeQuery(e.context).fail(function(e,n){t.reject(e,n)}).done(function(){t.resolve(n)})}else t.resolve(null)}),t.promise()},e}(),y=function(){function e(e){this._fluent=null,this._helperName="userProfile",this.userHelper=null,this._fluent=e,this.userHelper=new m(e.context)}return e.prototype.get=function(e){var t=this;return this._fluent.chainAction(this._helperName+".get",function(){return t.userHelper.getUserByEmail(e)})},e.prototype.getById=function(e){var t=this;return this._fluent.chainAction(this._helperName+".getById",function(){return t.userHelper.getUserById(e)})},e.prototype.getCurrentUser=function(){var e=this;return this._fluent.chainAction(this._helperName+".getCurrentUser",function(){return e.userHelper.getCurrentUser()})},e.prototype.getCurrentUserProfileProperties=function(){var e=this;return this._fluent.registerDependency(T.UserProfile),this._fluent.chainAction(this._helperName+".getCurrentUserProfileProperties",function(){return e.userHelper.getCurrentUserProfileProperties()})},e.prototype.getCurrentUserManager=function(){var e=this;return this._fluent.registerDependency(T.UserProfile),this._fluent.chainAction(this._helperName+".getCurrentUserManager",function(){return e.userHelper.getCurrentUserManager()})},e}(),v=function(){function e(e){this.context=e}return e.prototype.deleteQuicklaunchNodes=function(e){return this.deleteNodes(e.get_navigation().get_quickLaunch())},e.prototype.deleteTopNavigationNodes=function(e){return this.deleteNodes(e.get_navigation().get_topNavigationBar())},e.prototype.deleteQuicklaunchNode=function(e,t){return this.deleteNode(e.get_navigation().get_quickLaunch(),t)},e.prototype.deleteTopQuicklaunchNode=function(e,t){return this.deleteNode(e.get_navigation().get_topNavigationBar(),t)},e.prototype.setCurrentNavigation=function(e,t,n,r){var i=this;void 0===n&&(n=!0),void 0===r&&(r=!0);var o=$.Deferred(),u=e.get_allProperties();this.context.load(e),this.context.load(u);var a=function(){r&&n?u.set_item("__CurrentNavigationIncludeTypes","3"):r&&!n?u.set_item("__CurrentNavigationIncludeTypes","2"):!r&&n?u.set_item("__CurrentNavigationIncludeTypes","1"):r||n||u.set_item("__CurrentNavigationIncludeTypes","0")};return s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){var n=new SP.Publishing.Navigation.WebNavigationSettings(i.context,e);switch(t){case I.Inherit:n.get_currentNavigation().set_source(SP.Publishing.Navigation.StandardNavigationSource.inheritFromParentWeb);break;case I.Managed:s.reject(o,"Not implemented");break;case I.StructuralWithSiblings:n.get_currentNavigation().set_source(SP.Publishing.Navigation.StandardNavigationSource.portalProvider),u.set_item("__NavigationShowSiblings","True"),a(),e.update();break;case I.StructuralChildrenOnly:n.get_currentNavigation().set_source(SP.Publishing.Navigation.StandardNavigationSource.portalProvider),u.set_item("__NavigationShowSiblings","False"),a(),e.update();break;default:s.reject(o,"Unknown Navigation Type")}n.update(null),s.executeQuery(i.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve()})}),o.promise()},e.prototype.deleteNodes=function(e){var t=this,n=$.Deferred();return this.context.load(e),s.executeQuery(this.context).fail(function(e,t){n.reject(e,t)}).done(function(){for(var r=e.getEnumerator(),i=[];r.moveNext();)i.push(r.get_current());for(var o=0;o<i.length;o++)i[o].deleteObject();s.executeQuery(t.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve()})}),n.promise()},e.prototype.deleteNode=function(e,t){var n=this,r=$.Deferred();return this.context.load(e),s.executeQuery(this.context).fail(function(e,t){r.reject(e,t)}).done(function(){for(var i=e.getEnumerator(),o=[];i.moveNext();){var u=i.get_current();u.get_title()===t&&o.push(u)}for(var a=0;a<o.length;a++)o[a].deleteObject();s.executeQuery(n.context).fail(function(e,t){r.reject(e,t)}).done(function(){r.resolve()})}),r.promise()},e.prototype.createQuicklaunchNode=function(e,t,n,r){return void 0===r&&(r=!0),this.createNode(e.get_navigation().get_quickLaunch(),t,n,r)},e.prototype.createTopNavigationNode=function(e,t,n,r){return void 0===r&&(r=!0),this.createNode(e.get_navigation().get_topNavigationBar(),t,n,r)},e.prototype.createNode=function(e,t,n,r){void 0===r&&(r=!0);var i=$.Deferred();this.context.load(e);var o=new SP.NavigationNodeCreationInformation;o.set_title(t),o.set_url(n),o.set_asLastNode(r);var u=e.add(o);return this.context.load(e),s.executeQuery(this.context).fail(function(e,t){i.reject(e,t)}).done(function(){i.resolve(u)}),i.promise()},e}(),_=function(){function e(e){this.fluent=null,this.navigationHelper=null,this._helperName="navigation",this.fluent=e,this.navigationHelper=new v(e.context)}return e.prototype.createNode=function(e,t,n,r,i){var o=this;return void 0===i&&(i=!0),this.fluent.chainAction(this._helperName+".createNode",function(){if(t==A.Quicklaunch)return o.navigationHelper.createQuicklaunchNode(e,n,r,i);if(t==A.TopNavigation)return o.navigationHelper.createTopNavigationNode(e,n,r,i);throw"Unknown location "+t})},e.prototype.deleteAllNodes=function(e,t){var n=this;return this.fluent.chainAction(this._helperName+".deleteAllNodes",function(){if(t==A.Quicklaunch)return n.navigationHelper.deleteQuicklaunchNodes(e);if(t==A.TopNavigation)return n.navigationHelper.deleteTopNavigationNodes(e);throw"Unknown location "+t})},e.prototype.deleteNode=function(e,t,n){var r=this;return this.fluent.chainAction(this._helperName+".deleteNode",function(){if(t==A.Quicklaunch)return r.navigationHelper.deleteQuicklaunchNode(e,n);if(t==A.TopNavigation)return r.navigationHelper.deleteTopQuicklaunchNode(e,n);throw"Unknown location "+t})},e.prototype.setCurrentNavigation=function(e,t,n,r){var i=this;return void 0===n&&(n=!1),void 0===r&&(r=!1),this.fluent.registerDependency(T.Publishing),this.fluent.chainAction(this._helperName+".setCurrentNavigation",function(){return i.navigationHelper.setCurrentNavigation(e,t,n,r)})},e}();!function(e){e[e.Contains=0]="Contains",e[e.BeginsWith=1]="BeginsWith",e[e.Eq=2]="Eq",e[e.Geq=3]="Geq",e[e.Leq=4]="Leq",e[e.Lt=5]="Lt",e[e.Gt=6]="Gt",e[e.Neq=7]="Neq",e[e.DateRangesOverlap=8]="DateRangesOverlap",e[e.IsNotNull=9]="IsNotNull",e[e.IsNull=10]="IsNull"}(r||(r={})),function(e){e[e.Now=0]="Now",e[e.Today=1]="Today",e[e.Week=2]="Week",e[e.Month=3]="Month",e[e.Year=4]="Year"}(i||(i={})),function(e){e[e.SUM=0]="SUM",e[e.COUNT=1]="COUNT",e[e.AVG=2]="AVG",e[e.MAX=3]="MAX",e[e.MIN=4]="MIN",e[e.STDEV=5]="STDEV",e[e.VAR=6]="VAR"}(o||(o={}));var x=function(){function e(){this.value=""}return e.prototype.add=function(e){this.value+=e},e.prototype.toString=function(){return this.value},e}(),b=function(){function e(){this.camlClauses=[],this.orderByFields=[],this.requireAll=!0,this.viewFieldsString="",this.groupByFieldsString="",this.aggregationFieldsString="",this.begin(!0)}return Object.defineProperty(e.prototype,"query",{get:function(){return this.buildQuery()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"viewFields",{get:function(){return this.viewFieldsString},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"totalClauses",{get:function(){return this.camlClauses.length},enumerable:!0,configurable:!0}),e.prototype.setFilter=function(e){var t=0===e.indexOf("<Where>"),n=new x;t||n.add("<Where>"),n.add(e),t||n.add("</Where>"),this.directCaml=n.toString()},e.prototype.buildQuery=function(){if(this.recurrence)return"<Where>"+this.recurrence+"</Where>";var e="";if(this.directCaml)e+=this.directCaml;else if(!this.directCaml&&this.camlClauses.length>0){if(e+="<Where>",this.camlClauses.length>1)for(var t=this.camlClauses.length-1;t>0;)e+=this.requireAll?"<And>":"<Or>",t--,0;for(var n=0,r=0;r<this.camlClauses.length;r++){e+=this.camlClauses[r],++n>1&&(e+=this.requireAll?"</And>":"</Or>",0)}e+="</Where>"}if(this.orderByFields.length>0){e+="<OrderBy>";for(r=0;r<this.orderByFields.length;r++){var i=this.orderByFields[r];e+='<FieldRef Name="'+i.fieldRef+'" Ascending="'+(i.ascending?"TRUE":"FALSE")+'" />'}e+="</OrderBy>"}return e},Object.defineProperty(e.prototype,"viewXml",{get:function(){var e="";this.viewFields&&(e="<ViewFields>"+this.viewFields+"</ViewFields>");var t="";this.groupByFieldsString&&(t='<GroupBy Collapse="TRUE" GroupLimit="1999">'+this.groupByFieldsString+"</GroupBy>");var n="";if(this.orderByFields&&this.orderByFields.length){n="<OrderBy>";for(var r=0;r<this.orderByFields.length;r++)n+='<FieldRef Name="'+this.orderByFields[r].fieldRef+'" Ascending="'+(this.orderByFields[r].ascending?"TRUE":"FALSE")+'"/>';n+="</OrderBy>"}var i="";this.aggregationFieldsString&&(i='<Aggregations Value="On">'+this.aggregationFieldsString+"</Aggregations>");var o="";return this.queryOptions&&(o="<QueryOptions>\n                "+this.queryOptions+"\n            </QueryOptions>"),"<View"+(this.viewScope?" "+this.viewScope:"")+">"+e+"<Query>"+t+(this.orderByFields&&this.orderByFields.length>0||this.totalClauses>0||this.directCaml?this.query:"")+n+"</Query>"+o+i+(this.rowLimit?"<RowLimit>"+this.rowLimit+"</RowLimit>":"")+"</View>"},enumerable:!0,configurable:!0}),e.prototype.begin=function(e){this.camlClauses=[],this.requireAll=e,this.recurrence=null,this.viewFieldsString="",this.orderByFields=[],this.directCaml=null},e.prototype.getNullClause=function(e){var t="";return e&&(t='<IsNull><FieldRef Name="'+e+'" /></IsNull>'),t},e.prototype.getClause=function(e,t,n,i){return"<"+r[e]+'><FieldRef Name="'+t+'" /><Value Type="'+i+'">'+n+"</Value></"+r[e]+">"},e.prototype.getDateTimeClause=function(e,t,n,i){return"<"+r[e]+'><FieldRef Name="'+t+'" /><Value Type="DateTime" '+(i?"IncludeTimeValue='TRUE'":"")+">"+n+"</Value></"+r[e]+">"},e.prototype.addNullClause=function(e){this.camlClauses.push(this.getNullClause(e))},e.prototype.addTextClause=function(e,t,n){this.camlClauses.push(this.getClause(e,t,n,"Text"))},e.prototype.addBooleanClause=function(e,t,n){this.camlClauses.push(this.getClause(e,t,n?"1":"0","Integer"))},e.prototype.addNumberClause=function(e,t,n){this.camlClauses.push(this.getClause(e,t,n.toString(),"Number"))},e.prototype.addDateTimeClause=function(e,t,n,r){this.camlClauses.push(this.getDateTimeClause(e,t,n,r))},e.prototype.addLookupClause=function(e,t,n,i){var o="<"+r[e]+'><FieldRef Name="'+t+'" LookupId="True" /><Value Type="'+i+'">'+n+"</Value></"+r[e]+">";this.camlClauses.push(o)},e.prototype.addAggregation=function(e,t){this.aggregationFieldsString=this.aggregationFieldsString+'<FieldRef Name="'+e.replace(" ","_x0020_")+'" Type="'+o[t]+'" />'},e.prototype.recurrenceQuery=function(e){this.recurrence='<DateRangesOverlap><FieldRef Name="EventDate"/><FieldRef Name="EndDate"/><FieldRef Name="RecurrenceID"/><Value><'+i[e]+"/></Value></DateRangesOverlap>",this.queryOptions+="<CalendarDate>2018-01-01T12:00:00Z</CalendarDate>\n            <RecurrencePatternXMLVersion>v3</RecurrencePatternXMLVersion>\n            <ExpandRecurrence>TRUE</ExpandRecurrence>"},e.prototype.addViewField=function(e){this.viewFieldsString=this.viewFieldsString+'<FieldRef Name="'+e.replace(" ","_x0020_")+'"/>'},e.prototype.addViewFields=function(e){for(var t=0;t<e.length;t++)this.addViewField(e[t])},e.prototype.addGroupByField=function(e){this.groupByFieldsString=this.groupByFieldsString+'<FieldRef Name="'+e.replace(" ","_x0020_")+'"/>'},e.prototype.addGroupByFields=function(e){for(var t=0;t<e.length;t++)this.addGroupByField(e[t])},e.prototype.addOrderBy=function(e,t){var n=new N;n.fieldRef=e,n.ascending=t,this.orderByFields.push(n)},e.prototype.addDaysToDate=function(e,t){return e.setDate(e.getDate()+t),e},e}(),N=function(){return function(){}}(),P=function(){function e(e){this.context=e}return e.prototype.createPublishingPage=function(e,t,n,r){var i=this,o=$.Deferred();r||(r=t.replace(".aspx",""));var u=this.context.get_site().get_rootWeb().getFileByServerRelativeUrl(n).get_listItemAllFields();this.context.load(u);var a=new SP.Publishing.PublishingPageInformation;a.set_name(t),a.set_pageLayoutListItem(u);var l=SP.Publishing.PublishingWeb.getPublishingWeb(this.context,e);this.context.load(l);var c=l.addPublishingPage(a);this.context.load(c);var f=c.get_listItem();return this.context.load(f),s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){f.set_item("Title",r),f.update(),s.executeQuery(i.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve(c)})}),o.promise()},e.prototype.getPublishingLayout=function(e){var t=$.Deferred(),n=this.context.get_site().get_rootWeb().getFileByServerRelativeUrl(e).get_listItemAllFields();return this.context.load(n),s.executeQuery(this.context).fail(function(e,n){t.reject(e,n)}).done(function(){t.resolve(n)}),t.promise()},e.prototype.setLayout=function(e,t,n){var i=this,o=$.Deferred(),u=this.context.get_site().get_rootWeb().getFileByServerRelativeUrl(n).get_listItemAllFields();this.context.load(u);var a=new b;a.addTextClause(r.Eq,"FileLeafRef",t);var l=e.get_lists().getByTitle("Pages"),c=new SP.CamlQuery;c.set_viewXml(a.viewXml);var f=l.getItems(c);return this.context.load(f),s.executeQuery(this.context).fail(function(e,t){o.reject(e,t)}).done(function(){0===f.get_count()&&o.reject(i,{get_message:function(){return"Page not found"}});var e=f.getItemAtIndex(0);e.set_item("PublishingPageLayout",n),e.update(),s.executeQuery(i.context).fail(function(e,t){o.reject(e,t)}).done(function(){o.resolve()})}),o.promise()},e}(),w=function(){function e(e){this.fluent=null,this._helperName="publishingPage",this.fluent=e,this.pageHelper=new P(e.context)}return e.prototype.create=function(e,t,n,r){var i=this;return this.fluent.registerDependency(T.Publishing),this.fluent.chainAction(this._helperName+".create",function(){return i.pageHelper.createPublishingPage(e,t,n,r)})},e.prototype.getLayout=function(e){var t=this;return this.fluent.chainAction(this._helperName+".getLayout",function(){return t.pageHelper.getPublishingLayout(e)})},e.prototype.setLayout=function(e,t,n){var r=this;return this.fluent.registerDependency(T.Publishing),this.fluent.chainAction(this._helperName+".setLayout",function(){return r.pageHelper.setLayout(e,t,n)})},e}();n.d(t,"Fluent",function(){return j}),n.d(t,"NavigationLocation",function(){return A}),n.d(t,"NavigationType",function(){return I}),n.d(t,"Dependency",function(){return T}),n.d(t,"FluentCommand",function(){return S}),n.d(t,"ActionCommand",function(){return F}),n.d(t,"ActionResult",function(){return D}),n.d(t,"WhenCommand",function(){return B});var C,A,I,T,L=(C=function(e,t){return(C=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}C(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),j=function(){function e(){this.commands=[],this.results=[],this.dependencies=[],this.settings={timeoutMilliseconds:5e3,enableDependencyTimeout:!0},this.totalCommands=0}return e.prototype.withContext=function(e){return this.context=e,this},e.prototype.withSettings=function(e){for(var t in e)void 0!==this.settings[t]&&(this.settings[t]=e[t]);return this},e.prototype.withDependency=function(e){return this.registerDependency(e),this},Object.defineProperty(e.prototype,"promise",{get:function(){return this.resultPromise.promise()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"permission",{get:function(){return new c(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"list",{get:function(){return new p(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"listItem",{get:function(){return new d(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"file",{get:function(){return new g(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"publishingPage",{get:function(){return new w(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"web",{get:function(){return new a(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"user",{get:function(){return new y(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"navigation",{get:function(){return new _(this)},enumerable:!0,configurable:!0}),e.prototype.execute=function(){var e=this;if(this.resultPromise=$.Deferred(),this.settings.enableDependencyTimeout)var t=setTimeout(function(){s.reject(e.resultPromise,"Timeout waiting for dependencies to load")},this.settings.timeoutMilliseconds);return this.totalCommands=this.getAvailableActionCommandCount(),this.loadDependencies().done(function(){e.continue()}).always(function(){e.settings.enableDependencyTimeout&&clearTimeout(t)}),this.resultPromise.promise()},e.prototype.onActionExecuted=function(e){return this.onExecuted=e,this},e.prototype.onActionExecuting=function(e){return this.onExecuting=e,this},e.prototype.update=function(e){var t=this;if(this.peekLastCommand()&&this.peekLastCommand().constructor!==F)throw"Illegal operation: The last command must be an ActionCommand";var n=new B;return n.action=function(){var n=$.Deferred(),r=t.peekLastResult();return r?(e.apply(void 0,r.result),s.executeQuery(t.context).fail(function(e,t){n.reject(e,t)}).done(function(){n.resolve()})):t.failChain(t,"No action to process for update"),n.promise()},this.commands.push(n),this},e.prototype.when=function(e){var t=this;if(this.peekLastCommand()&&this.peekLastCommand().constructor!==F)throw"Illegal operation: The last command must be an ActionCommand";var n=new B;return n.action=function(){var n=$.Deferred(),r=t.peekLastResult();if(r){if(!r.success)throw"Illegal operation: The last command should have succeeded for this call to have been made.  This is an issue in the fluent api";e.apply(void 0,r.result)?n.resolve():t.reject(n,t,"Predicate returned false")}else t.failChain(t,"No action to process for when");return n.promise()},this.commands.push(n),this},e.prototype.whenAll=function(e){var t=this;if(this.peekLastCommand()&&this.peekLastCommand().constructor!==F)throw"Illegal operation: The last command must be an ActionCommand";var n=new B;return n.action=function(){var n=$.Deferred(),r=t.peekLastResult();if(r){if(!r.success)throw"Illegal operation: The last command should have succeeded for this call to have been made.  This is an issue in the fluent api";e(t.results)?n.resolve():t.reject(n,t,"Predicate returned false")}else t.failChain(t,"No action to process for whenAll");return n.promise()},this.commands.push(n),this},e.prototype.whenTrue=function(){var e=this;if(this.peekLastCommand()&&this.peekLastCommand().constructor!==F)throw"Illegal operation: The last command must be an ActionCommand";var t=new B;return t.action=function(){var t=$.Deferred(),n=e.peekLastResult();if(n){if(!n.success)throw"Illegal operation: The last command should have succeeded for this call to have been made.  This is an issue in the fluent api";n.result&&n.result.length&&n.result[0]?t.resolve():e.reject(t,e,"Result is not true")}else e.failChain(e,"No action to process for whenTrue");return t.promise()},this.commands.push(t),this},e.prototype.whenFalse=function(){var e=this;if(this.peekLastCommand()&&this.peekLastCommand().constructor!==F)throw"Illegal operation: The last command must be an ActionCommand";var t=new B;return t.action=function(){var t=$.Deferred(),n=e.peekLastResult();if(n){if(!n.success)throw"Illegal operation: The last command should have succeeded for this call to have been made.  This is an issue in the fluent api";n.result&&n.result.length&&!n.result[0]?t.resolve():e.reject(t,e,"Result is not false")}else e.failChain(e,"No action to process for whenFalse");return t.promise()},this.commands.push(t),this},e.prototype.chainAction=function(e,t){var n=new F;return n.name=e,n.action=t,this.commands.push(n),this},e.prototype.chain=function(e){return this.commands.push(e),this},e.executeQuery=function(e){return s.executeQuery(e)},e.prototype.registerDependency=function(e){-1===this.dependencies.indexOf(e)&&this.dependencies.push(e)},e.prototype.continue=function(){var e=this;if(!this.context)throw"context not set, you must call withContext";var t=this.commands.shift();if(t&&t.action){if(t.constructor===F&&this.onExecuting){var n=this.totalCommands-this.getAvailableActionCommandCount();this.onExecuting(t.name,n,this.totalCommands)}t.action().done(function(n,r,i,o,s,u,a){if(t.constructor===F){var l=[];e.storeResult(n,l),e.storeResult(r,l),e.storeResult(i,l),e.storeResult(o,l),e.storeResult(s,l),e.storeResult(u,l),e.storeResult(a,l),e.addResult(t,!0,l),e.onExecuted&&e.onExecuted(t.name,!0,l)}e.commands.length?e.continue():e.resolveChain()}).fail(function(n,r){if(t.constructor===F){var i=[];return e.storeResult(n,i),e.storeResult(r,i),e.addResult(t,!1,i),e.onExecuted&&e.onExecuted(t.name,!1,{sender:n,args:r}),void e.failChain(n,r)}e.resolveChain()})}else this.resolveChain()},e.prototype.storeResult=function(e,t){void 0!==e&&t.push(e)},e.prototype.resolveChain=function(){this.resultPromise.resolve(this.results)},e.prototype.failChain=function(e,t){"string"==typeof t&&(t={get_message:function(){return t}}),this.resultPromise.reject(e,t)},e.prototype.reject=function(e,t,n){"string"==typeof n&&(n={get_message:function(){return n}}),e.reject(t,n)},e.prototype.addResult=function(e,t,n){var r=new D;r.name=e.name,r.success=t,r.result=n,this.results.push(r)},e.prototype.loadDependencies=function(){for(var e=$.Deferred(),t=["SP.js","SP.Runtime.js"],n=0;n<this.dependencies.length;n++)switch(this.dependencies[n]){case T.UserProfile:window.LoadSodByKey("userprofile"),t.push("userprofile");break;case T.Publishing:SP.SOD.registerSod("SP.Publishing.js",SP.Utilities.Utility.getLayoutsPageUrl("sp.publishing.js")),t.push("SP.Publishing.js");break;case T.Taxonomy:SP.SOD.registerSod("sp.taxonomy.js",SP.Utilities.Utility.getLayoutsPageUrl("sp.taxonomy.js")),t.push("sp.taxonomy.js");break;default:throw"Depenency not implemented"}return SP.SOD.loadMultiple(t,function(){e.resolve()}),e.promise()},e.prototype.peekLastCommand=function(){return this.commands.length?this.commands[this.commands.length-1]:null},e.prototype.peekLastResult=function(){return this.results.length?this.results[this.results.length-1]:null},e.prototype.getAvailableActionCommandCount=function(){for(var e=0,t=0;t<this.commands.length;t++)this.commands[t].constructor===F&&e++;return e},e}();!function(e){e[e.TopNavigation=0]="TopNavigation",e[e.Quicklaunch=1]="Quicklaunch"}(A||(A={})),function(e){e[e.Inherit=0]="Inherit",e[e.Managed=1]="Managed",e[e.StructuralWithSiblings=2]="StructuralWithSiblings",e[e.StructuralChildrenOnly=3]="StructuralChildrenOnly"}(I||(I={})),function(e){e[e.Publishing=0]="Publishing",e[e.UserProfile=1]="UserProfile",e[e.Taxonomy=2]="Taxonomy"}(T||(T={}));var S=function(){return function(){}}(),F=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return L(t,e),t}(S),D=function(){return function(){}}(),B=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return L(t,e),t}(S)}]);
  //# sourceMappingURL=spJsomFluent.js.map