diff --git a/pluginTester/scripts/framework/app.min.js b/pluginTester/scripts/framework/app.min.js old mode 100644 new mode 100755 index babface7..814040cb --- a/pluginTester/scripts/framework/app.min.js +++ b/pluginTester/scripts/framework/app.min.js @@ -7,13 +7,13 @@ "use strict";!function(){function e(t){return this.promise=new Promise(t),this.promise.success=function(t){return this.then(t),this},this.promise.error=function(t){return this.then(null,t),this},this.promise}function o(){}console.log("httpClient is loading"),o.get=function(t,e){return o.request("GET",t,void 0,e)},o.post=function(t,e,n){return o.request("POST",t,e)},o.put=function(t,e,n){return o.request("PUT",t,e)},o.jsonp=function(t,e){function n(t){this.promise=new Promise(t)}return n.prototype.success=function(t){return this.promise.then(t,null),this},n.prototype.error=function(t){return this.promise.then(null,t),this},new n(function(r,s){setTimeout(function(){console.info("Angular $http is not ready"),window.bfUtils.http.jsonp(t,e).success(function(t,e,n,o){return r(t,e,n,o)}).error(function(t,e,n,o){return s(t,e,n,o)})},200)})},o.request=function(o,r,s,t){return console.log("httpClient create request for url: ",r," using method: ",o),new e(function(e,t){var n=new XMLHttpRequest;n.onload=function(){console.log("httpClient read response for url: ",r," using method: ",o);n.status,n.statusText;var t="response"in n?n.response:n.responseText;e(t?JSON.parse(t):null)},n.onerror=function(){console.log("httpClient failed for url: ",r," using method: ",o),t(new TypeError("Network request failed"))},n.ontimeout=function(){console.log("httpClient timed out for url: ",r," using method: ",o),t(new TypeError("Network request failed"))},console.log("httpClient requesting for url: ",r," using method: ",o),n.open(o,r,!0),n.send(s)})},window.httpClient=o}(); "use strict";function _slicedToArray(t,e){return _arrayWithHoles(t)||_iterableToArrayLimit(t,e)||_unsupportedIterableToArray(t,e)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(t,e){if(t){if("string"==typeof t)return _arrayLikeToArray(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Map"===(n="Object"===n&&t.constructor?t.constructor.name:n)||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(t,e):void 0}}function _arrayLikeToArray(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);nr.length)&&(t=r.length);for(var a=0,e=new Array(t);al.settings.maxAgeRequired?this.error=l.options.errorMessages.maxAge+" "+l.settings.maxAgeRequired:l.settings.minAgeIsRequired&&l.settings.minAgeRequired&&ef.settings.maxNumRequired&&f.settings.maxNumEnabled?this.error=f.options.errorMessages.maxNum+" "+f.settings.maxNumRequired:ee.maxLength&&(e.value=e.value.substring(0,e.maxLength))},editVisibilityOptions:function(e,s){var t=new ComponentUIAPI;t.openDrawer({header:e.field.label,listItems:[{text:"Public"},{text:"Private"}],enableFilter:!1},function(e,i){return e?console.error(e):(i&&s(null,i),void t.closeDrawer())})}};function gm_authFailure(){customRegistration.googleMapServices.checkMapsApiKeyErrors&&(customRegistration.googleMapServices.mapsApiKeyError="There seems to be an issue with google maps key")} +"use strict";var customRegistration={googleMapServices:{},get wl_name(){var e="Full ";return e=appContext&&appContext.currentApp&&appContext.currentApp.config?appContext.currentApp.config.whitlabelName+" ":e},getFields:function(t,e){var l,r,o,n,u,d,i=t.customRegistrationSettings;i&&i.singlePage&&i.singlePage.formControls?(l=[],r={},o=[],n="",u=t.defaults||{},i.singlePage.formControls.forEach(function(e,i){var s;t.isProfileMode&&"registrationOnly"===e.settings.displayOn||("custom"!=e.type?(s={control:e,controlIndex:i,fields:l,rules:r,initializers:o,isProfileMode:t.isProfileMode,defaults:t.defaults,refreshUI:t.refreshUI},customRegistration.preparePresetField(s)):(i={control:e,controlIndex:i,fields:l,defaults:t.defaults},customRegistration.prepareCustomField(i)))}),d=function(e,i){var s=e.field;"edit"!==e.mode||"email"!==s.name&&!s.preventEditing?"edit"===e.mode&&"profilePicture"===s.name?(s.value=e.profilePicture,s.validate(s.value,function(e,i){n=e?e:null})):"multipleSelect"===s.type?s.validate(s.values):s.validate(s.value):s.error=null,i&&i(null,{profilePictureError:n})},e(null,{fields:l,rules:r,initializers:o,fetch:function(i,e){var s,t,r=!1,o={},a=[];i&&i.validateFields&&l.forEach(function(e){if(i.field=e,d(i),e.error&&(r=!0),e.isCustom)switch(e.type){case"singleSelect":a.push({id:e.id,tag:e.tag,type:e.type,value:e.value,displayValue:e.displayValue,visibilityChoice:e.visibilityChoice});break;case"multipleSelect":a.push({id:e.id,type:e.type,values:e.values,visibilityChoice:e.visibilityChoice});break;case"text":case"number":case"textarea":a.push({id:e.id,type:e.type,value:e.value,visibilityChoice:e.visibilityChoice})}else o[e.name]={value:e.value,extra:e.extra,messages:e.messages,visibilityChoice:e.visibilityChoice}}),r?e({profilePictureError:n},null):((t=(s={user:u}).user).email=o.email.value,t.password=o.password?o.password.value:void 0,t.firstName=o.firstName?o.firstName.value:t.firstName,t.lastName=o.lastName?o.lastName.value:t.lastName,t.displayName=o.displayName?o.displayName.value:t.displayName,t.userProfile=t.userProfile||{},t.userProfile.address=t.userProfile.address||{},t.userProfile.address.fullAddress=o.address?o.address.value:t.userProfile.address.fullAddress,t.userProfile.address.customFields=t.userProfile.address.customFields||{},t.userProfile.address.customFields.aptNo=o.aptNo?o.aptNo.value:t.userProfile.address.customFields.aptNo,t.userProfile.address.customFields.zipCode=o.zipCode?o.zipCode.value:t.userProfile.address.customFields.zipCode,t.userProfile.address.geoLocation=o.address?o.address.value?o.address.extra:void 0:t.userProfile.address.geoLocation,t.userProfile.addressVisibilityChoice=o.address?o.address.visibilityChoice:o.zipCode?o.zipCode.visibilityChoice:t.userProfile.addressVisibilityChoice,t.userProfile.bio=o.bio?o.bio.value:t.userProfile.bio,t.userProfile.bioVisibilityChoice=o.bio?o.bio.visibilityChoice:t.userProfile.bioVisibilityChoice,t.userProfile.birthDate=o.birthDate?o.birthDate.value?new Date(o.birthDate.value):null:"string"==typeof t.userProfile.birthDate?new Date(t.userProfile.birthDate):t.userProfile.birthDate,t.userProfile.birthDateVisibilityChoice=o.birthDate?o.birthDate.visibilityChoice:t.userProfile.birthDateVisibilityChoice,t.userProfile.tel=o.tel?o.tel.value:t.userProfile.tel,t.userProfile.telVisibilityChoice=o.tel?o.tel.visibilityChoice:t.userProfile.telVisibilityChoice,t.userProfile.emailVisibilityChoice=o.email?o.email.visibilityChoice:t.userProfile.emailVisibilityChoice,t.userProfile.customTypeFields=t.userProfile.customTypeFields||[],a.forEach(function(i){var e=t.userProfile.customTypeFields.findIndex(function(e){return i.id===e.id});0<=e?t.userProfile.customTypeFields[e]=i:t.userProfile.customTypeFields.push(i)}),delete t.imageUrl,s.messages={emailAlreadyInUse:o.email.messages.emailAlreadyInUse},o.displayName&&o.displayName.messages&&(s.messages.fullNameAlreadyInUse=o.displayName.messages.fullNameAlreadyInUse),s.profilePictureFile=o.profilePicture?o.profilePicture.value:void 0,e(null,s))},checkFieldsErrors:function(i,s){i&&i.validateFields&&l.forEach(function(e){i.field=e,d(i,s)})}})):e(null,null)},preparePresetField:function(a){var t,e,i,s,l=a.control,r=a.controlIndex,o=a.fields,n=a.rules,u=a.initializers;switch(l.id){case"fullName":l.active&&(l.settings.displayNameEnabled&&(o.push({id:l.id,type:"text",viewType:"none",name:"displayName",maxLength:150,order:r,label:l.options.fieldsLabels.displayName,iconClass:l.icon||"glyphicon glyphicon-font",validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.fullNameRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults?a.defaults.displayName:void 0}),n.checkUniqueName=l.active&&l.settings&&l.settings.unique&&l.settings.required&&l.settings.displayNameEnabled),l.settings.firstNameEnabled&&o.push({type:"text",viewType:"text",name:"firstName",maxLength:150,order:r,label:l.options.fieldsLabels.firstName,iconClass:l.icon||"glyphicon glyphicon-font",validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.fullNameRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults?a.defaults.firstName:void 0}),l.settings.lastNameEnabled&&o.push({type:"text",viewType:"text",name:"lastName",maxLength:150,order:r,label:l.options.fieldsLabels.lastName,iconClass:l.icon||"glyphicon glyphicon-font",validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.fullNameRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults?a.defaults.lastName:void 0}));break;case"email":var d="userChoice"===l.settings.visibility?"public":void 0,d=a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.emailVisibilityChoice||d;o.push({type:"email",viewType:"email",name:"email",order:r,label:l.options.fieldsLabels.email,info:l.options.infoMessages?l.options.infoMessages.assistiveText:void 0,iconClass:l.icon||"glyphicon glyphicon-send",visibility:l.settings.visibility||"private",visibilityChoice:d,validate:function(e){this.error=null,e&&e.trim().length?window.validator.validateEmail(e)?e&&e.trim().length||(this.error=l.options.errorMessages.emailAlreadyInUse):this.error=l.options.errorMessages.emailInvalidFormat:this.error=l.options.errorMessages.emailRequired},touch:function(e,i){!e&&i&&i.target&&(e=i.target.value),this.validate(e)},messages:l.options.errorMessages,value:a.defaults?a.defaults.email:void 0});break;case"address":l.active&&(t=l.options.addressGoogleApiKey,e="userChoice"===l.settings.visibility?"public":void 0,e=a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.addressVisibilityChoice||e,l.options.addressGoogleApiKey&&u.push(function(){setTimeout(function(){var e=document.getElementById("customRegistrationScript"),i=e&&e.src,s="https://maps.googleapis.com/maps/api/js?key=".concat(t,"&libraries=places&callback=googleMapsInitCallback");e&&i!=s&&document.getElementsByTagName("head")[0].removeChild(e),customRegistration.googleMapServices.mapsApiKeyError=null,i!=s&&((e=document.createElement("script")).id="customRegistrationScript",e.src=s,e.type="text/javascript",document.getElementsByTagName("head")[0].appendChild(e)),window.googleMapsInitCallback=function(){customRegistration.googleMapServices.autoAddressCompleteService=new google.maps.places.AutocompleteService,customRegistration.googleMapServices.addressGeocoder=new google.maps.Geocoder},a.refreshUI&&a.refreshUI()},0)}),l.settings.showFullAddress&&(o.push({type:"text",viewType:"text",name:"address",maxLength:150,order:r,label:l.options.fieldsLabels.address,iconClass:l.icon||"glyphicon glyphicon-pushpin",visibility:l.settings.visibility||"private",visibilityChoice:e,preventEditing:!1===l.settings.allowEditingInProfile,change:function(e){var s=this;s.extra=null,customRegistration.googleMapServices.mapsApiKeyError&&(s.error=customRegistration.googleMapServices.mapsApiKeyError),customRegistration.googleMapServices.autoAddressCompleteService?(customRegistration.googleMapServices.checkMapsApiKeyErrors=!0,setTimeout(function(){customRegistration.googleMapServices.checkMapsApiKeyErrors=!1},3e3),customRegistration.googleMapServices.autoAddressCompleteService.getPlacePredictions({input:e,types:["street_number","street_address","route"]},function(e,i){i!==google.maps.places.PlacesServiceStatus.OK&&(s.error=l.options.errorMessages.invalidGoogleAddress),s.suggestions=e,a.refreshUI&&a.refreshUI()})):s.error=l.options.errorMessages.invalidGoogleAddress},selectSuggestion:function(r){var o=this;o.error=null,o.suggestions=null,o.value=r.description,customRegistration.googleMapServices.addressGeocoder.geocode({placeId:r.place_id},function(e,i){var s,t;e&&e[0]&&e[0]?(s=e[0].geometry.location.lat(),t=e[0].geometry.location.lng(),l.settings.required&&(e[0].address_components.find(function(e){return e.types&&e.types.find(function(e){return"street_number"===e||"street_address"===e||"route"===e})})||(o.error=l.options.errorMessages.invalidGoogleAddress)),o.extra={lat:s,lng:t,place:r,addressComponents:e[0].address_components}):o.error=l.options.errorMessages.invalidGoogleAddress,a.refreshUI&&a.refreshUI()})},validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required?e&&e.trim().length&&!this.extra&&(this.error=l.options.errorMessages.invalidGoogleAddress):this.error=l.options.errorMessages.addressRequired},touch:function(e){this.suggestions&&this.suggestions.length||this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this),this.change(this.value)},messages:l.options.errorMessages,value:a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.address?a.defaults.userProfile.address.fullAddress:void 0,extra:a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.address?a.defaults.userProfile.address.geoLocation:void 0}),l.settings.showAptNo&&o.push({type:"text",viewType:"text",name:"aptNo",maxLength:150,order:r,label:l.options.fieldsLabels.aptNo,iconClass:l.icon||"glyphicon glyphicon-pushpin",containerClass:"small-login-field",preventEditing:!1===l.settings.allowEditingInProfile,validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.addressRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.address&&a.defaults.userProfile.address.customFields?a.defaults.userProfile.address.customFields.aptNo:void 0})),l.settings.showZipCode&&o.push({type:"text",viewType:"text",name:"zipCode",maxLength:150,order:r,label:l.options.fieldsLabels.zipCode,iconClass:l.icon||"glyphicon glyphicon-pushpin",visibility:l.settings.visibility||"private",visibilityChoice:e,preventEditing:!1===l.settings.allowEditingInProfile,validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.addressRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.address&&a.defaults.userProfile.address.customFields?a.defaults.userProfile.address.customFields.zipCode:void 0}));break;case"password":a.isProfileMode||(o.push({type:"password",name:"password",order:r,label:l.options.fieldsLabels.password,iconClass:l.icon||"glyphicon glyphicon-lock",togglePasswordVisibility:"showHidePassword"===l.settings.validation,info:"simple"===l.settings.passwordStrength?l.options.infoMessages.passwordSimpleRules:l.options.infoMessages.passwordRules,validate:function(e){this.error=null,"retypePassword"===l.settings.validation&&(o.find(function(e){return"retypePassword"===e.name}).error=null),e&&e.trim().length?window.validator.validatePassword(e,{simplePasswordValidation:"simple"===l.settings.passwordStrength})||(this.error="simple"===l.settings.passwordStrength?l.options.errorMessages.invalidPasswordSimpleRules:l.options.errorMessages.invalidPasswordRules):this.error=l.options.errorMessages.passwordRequired},touch:function(e){this.validate(e)},messages:l.options.errorMessages}),"retypePassword"===l.settings.validation&&o.push({type:"password",name:"retypePassword",order:r,label:l.options.fieldsLabels.retypePassword,iconClass:l.icon||"glyphicon glyphicon-lock",togglePasswordVisibility:"showHidePassword"===l.settings.validation,validate:function(e){var i=o.find(function(e){return"password"===e.name});this.error=null,e&&e.trim().length?i.value!==e&&(this.error=l.options.errorMessages.passwordsDontMatch):this.error=l.options.errorMessages.passwordRequired},touch:function(e){this.validate(e)},messages:l.options.errorMessages})),n.passwordStrength=l.settings.passwordStrength;break;case"bio":l.active&&(e="userChoice"===l.settings.visibility?"public":void 0,e=a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.bioVisibilityChoice||e,o.push({type:"textarea",viewType:"multiline",name:"bio",maxLength:1024,order:r,label:l.options.fieldsLabels.bio,info:l.options.infoMessages?l.options.infoMessages.assistiveText:void 0,iconClass:l.icon||"glyphicon glyphicon-list-alt",visibility:l.settings.visibility||"private",visibilityChoice:e,preventEditing:!1===l.settings.allowEditingInProfile,validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required||(this.error=l.options.errorMessages.bioRequired)},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults&&a.defaults.userProfile?a.defaults.userProfile.bio:void 0}));break;case"telephone":l.active&&(i="userChoice"===l.settings.visibility?"public":void 0,i=a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.telVisibilityChoice||i,o.push({type:"tel",viewType:"text",name:"tel",maxLength:150,order:r,label:l.options.fieldsLabels.tel,info:l.settings.showReasonForTelephone?l.options.infoMessages.reasonForTelephone:null,iconClass:l.icon||"glyphicon glyphicon-earphone",visibility:l.settings.visibility||"private",visibilityChoice:i,preventEditing:!1===l.settings.allowEditingInProfile,validate:function(e){this.error=null,e&&e.trim().length||!l.settings.required?e&&(/^(?:(?:\(?(?:00|\+)([1-4]\d\d|[1-9]\d?)\)?)?[\-\.\ \\\/]?)?((?:\(?\d{1,}\)?[\-\.\ \\\/]?){0,})(?:[\-\.\ \\\/]?(?:#|ext\.?|extension|x)[\-\.\ \\\/]?(\d+))?$/i.test(e)||(this.error=l.options.errorMessages.invalidEntry)):this.error=l.options.errorMessages.invalidEntry},touch:function(e){this.validate(e)},enforceMaxLength:function(){customRegistration.enforceMaxLength(this)},messages:l.options.errorMessages,value:a.defaults&&a.defaults.userProfile?a.defaults.userProfile.tel:void 0}));break;case"birthDate":l.active&&(i="userChoice"===l.settings.visibility?"public":void 0,i=a.defaults&&a.defaults.userProfile&&a.defaults.userProfile.birthDateVisibilityChoice||i,s=function(e){return e?moment(e).format("L"):null},o.push({type:"date",viewType:"text",name:"birthDate",order:r,label:l.options.fieldsLabels.dateBirth,info:l.options.infoMessages?l.options.infoMessages.assistiveText:void 0,minDate:l.settings.maxAgeIsRequired&&l.settings.maxAgeRequired?moment().subtract(l.settings.maxAgeRequired,"years").toDate():void 0,maxDate:l.settings.minAgeIsRequired&&l.settings.minAgeRequired?moment().subtract(l.settings.minAgeRequired,"years").toDate():void 0,iconClass:l.icon||"glyphicon glyphicon-calendar",displayValue:s(a.defaults&&a.defaults.userProfile?a.defaults.userProfile.birthDate:void 0),visibility:l.settings.visibility||"private",visibilityChoice:i,preventEditing:!1===l.settings.allowEditingInProfile,validate:function(e){this.error=null,e?(e=moment(e),e=moment().diff(e,"years"),l.settings.maxAgeIsRequired&&l.settings.maxAgeRequired&&e>l.settings.maxAgeRequired?this.error=l.options.errorMessages.maxAge+" "+l.settings.maxAgeRequired:l.settings.minAgeIsRequired&&l.settings.minAgeRequired&&ef.settings.maxNumRequired&&f.settings.maxNumEnabled?this.error=f.options.errorMessages.maxNum+" "+f.settings.maxNumRequired:ee.maxLength&&(e.value=e.value.substring(0,e.maxLength))},editVisibilityOptions:function(e,s){var t=new ComponentUIAPI;t.openDrawer({header:e.field.label,listItems:[{text:"Public"},{text:"Private"}],enableFilter:!1},function(e,i){return e?console.error(e):(i&&s(null,i),void t.closeDrawer())})}};function gm_authFailure(){customRegistration.googleMapServices.checkMapsApiKeyErrors&&(customRegistration.googleMapServices.mapsApiKeyError="There seems to be an issue with google maps key")} "use strict";function _readOnlyError(e){throw new TypeError('"'+e+'" is read-only')}function ownKeys(t,e){var n,a=Object.keys(t);return Object.getOwnPropertySymbols&&(n=Object.getOwnPropertySymbols(t),e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),a.push.apply(a,n)),a}function _objectSpread(t){for(var e=1;e=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:t}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,o=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){a=!0,s=e},f:function(){try{o||null==n.return||n.return()}finally{if(a)throw s}}}}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:t}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,o=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){a=!0,s=e},f:function(){try{o||null==n.return||n.return()}finally{if(a)throw s}}}}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);nn?e(null,i.value):(o[t]=void 0,e(null,null))},FirebaseAPI._setUser=function(n,e){n=n.appId+"_"+n.instanceId+"_"+n.integrationToken;o[n]={createdOn:new Date,value:e}},authAPI.onLogout(function(){o={}})}(); "use strict";function _slicedToArray(e,t){return _arrayWithHoles(e)||_iterableToArrayLimit(e,t)||_unsupportedIterableToArray(e,t)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n