. '),ye.current=Z}}};if(!1!==$.hasClassesTrait){var[we,Se]=(0,X.useClassList)(Z);_e.classList={get:()=>we,set:Z=>Se(Z)}}if(!1!==$.hasDisplayTrait){var[xe,Pe]=(0,X.useComponentDisplay)(Z);_e.display={get:()=>xe,set:Z=>Pe(!!Z)}}W.properties.forEach(($=>{var Y=void 0===$.initialValue?W.customData[$.name]:$.initialValue;"function"==typeof Y&&(Y=void 0,console.warn('Initial values for property "'.concat($.name,'" should not be a function')));var[ee,ae]=(0,X.useDynamicProperty)(Z,{handler:$.handlerId,validator:$.validator,forceDefault:$.forceDefault,initialValue:()=>Y});_e[$.name]={get:()=>ee,set:ae}}));var Re=(0,X.useComponentRegister)(Z,_e);return React.createElement(W.CustomComponent,{definition:$,settings:Y,instanceId:ae,component:Re,eventHandlers:pe,appData:le,pageData:ce,parentDataModel:de,pods:be,elRef:ye})}var ae={checkbox:Z=>"true"===Z,number:function number(Z){var W=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Number";if(""===Z||void 0===Z)return null;var $=Number(Z);if(!isNaN($))return $;BackendlessUI.logger.error('Can not cast to "'.concat(W,'" the following value from string="').concat(Z,'"'))},range:Z=>ae.number(Z,"Range"),json:Z=>{try{if(Z)return JSON.parse(Z)}catch(W){BackendlessUI.logger.error('Can not transform JSON value from string="'.concat(Z,'"'),W)}}};CustomComponentWrapper.normalize=Z=>{Z.customData={},Z.properties.forEach((W=>{if(W.name){var $="custom".concat(Y.x.capitalizeFirstLetter(W.name.toLowerCase()));Z.customData[W.name]=Z.data[$]||void 0,ae[W.type]&&(Z.customData[W.name]=ae[W.type](Z.customData[W.name])),delete Z.data[$]}})),Z.CustomComponent.normalizeProperties&&(Z.properties=Z.CustomComponent.normalizeProperties(Z.properties,{data:Z.customData}),Array.isArray(Z.properties)||(console.warn("CustomComponent.normalizeProperties method did not return a list of component properties"),Z.properties=[]),Z.properties=Z.properties.filter((Z=>function isPropertyValid(Z){var W=function validateProperty(Z){if(!Z.name)return'"property.name" property is missed';if(Z.validator&&"function"!=typeof Z.validator)return'"property.validator" can be only a function'}(Z);W&&console.warn("Can not assign a property to the custom component because of: ",W);return!W}(Z))))}},79554:(Z,W,$)=>{"use strict";$.d(W,{a:()=>Gt,Z:()=>Kt});var Y=$(15746),X=$(50066),ee=$(16557),ae=$(4781);function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _defineProperty(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z}function Block(Z){var{node:W,componentContext:$}=Z,{dataStore:ie,setDataStore:le,dynamicItemData:ce,dynamicListItems:de,setDynamicListItems:pe,itemsRenderer:fe}=Z,ye=(0,Y.useI18n)(W),be=(0,Y.useHandlerRunner)(Z),_e=(0,Y.useStyle)(Z),[we,Se]=(0,Y.useClassList)(Z),[xe,Pe]=(0,Y.useComponentDisplay)(Z),[Re,Te]=(0,Y.useDynamicProperty)(Z,{handler:"onAnchorAssignment",initialValue:()=>W.data.anchor}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipTextAssignment",initialValue:()=>W.data.tooltipText}),[Ve,ze]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipVisibilityAssignment"}),[We,He]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.tooltipPlacement}),Ye=(0,Y.useElRef)(),Qe={style:_e,classList:{get:()=>we,set:Z=>Se(Z)},display:{get:()=>xe,set:Z=>Pe(!!Z)},anchor:{get:()=>Re,set:Z=>Te(Z)},el:{get:()=>Ye.current},tooltipText:{get:()=>Ie,set:Z=>qe(Z)},tooltipPlacement:{get:()=>We,set:Z=>He(Z)},tooltipVisibility:{get:()=>Ve,set:Z=>ze(!!Z)}};pe&&(Qe.dynamicListItems={get:()=>de,set:Z=>pe(Z)}),(ie||ce)&&(Qe.dataStore=ie||ce),le&&(Qe.setDataStore=le),(0,Y.useComponentRegister)(Z,Qe),(0,Y.useComponentLifecycle)(Z);var Xe=(0,Y.useOnScrollHandler)(Z),et=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);if(!xe)return null;var tt=React.createElement("div",function _objectSpread(Z){for(var W=1;W
"bl-block";var ie=$(8679),le=$.n(ie);function Panel(Z){return Block(Z)}function Jumbotron(Z){return Block(Z)}le()(Panel,Block),Panel.getStaticClasses=()=>"bl-panel",le()(Jumbotron,Block),Jumbotron.getStaticClasses=()=>"bl-jumbotron";var ce=$(67294),de=$(66986),pe=["tooltipText","tooltipPlacement","tooltipControlled","tooltipVisibility"],fe=["icon","className","size"];function _extends(){return _extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W=0||(X[$]=Z[$]);return X}(Z,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(Z);for(Y=0;Y=0||Object.prototype.propertyIsEnumerable.call(Z,$)&&(X[$]=Z[$])}return X}var ye={default:"medium",inherit:"inherit",small:"small",medium:"medium",large:"large"},be=ce.forwardRef((function IconUI(Z,W){var{tooltipText:$,tooltipPlacement:ee,tooltipControlled:ie,tooltipVisibility:le}=Z,be=_objectWithoutProperties(Z,pe),{icon:_e,className:we,size:Se}=be,xe=_objectWithoutProperties(be,fe),Pe=(0,Y.useMemo)((()=>(Se&&!ye[Se]&&console.error('Invalid size "'.concat(Se,'" in the Icon Component, ')+"make sure the size value is one of [".concat(Object.keys(ye).join(","),"]")),ye[Se]||ye.default)),[Se]),Re=(0,Y.useMemo)((()=>_e&&_e.replace(/[-,\s]/g,"_").toLowerCase()),[_e]),Te=ce.createElement(de.Z.Icon,_extends({component:"i"},xe,{ref:W,fontSize:Pe,className:(0,X.cn)("bl-icon","material-icons-round",we)}),Re);return $?(0,ae.TC)(Te,{tooltipText:$,tooltipPlacement:ee,tooltipControlled:ie,tooltipVisibility:le}):Te}));function icon_extends(){return icon_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;WW.data.size}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onIconAssignment",initialValue:()=>W.data.icon}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipTextAssignment",initialValue:()=>W.data.tooltipText}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipVisibilityAssignment"}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.tooltipPlacement}),qe=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},icon:{get:()=>_e,set:we},el:{get:()=>qe.current},tooltipText:{get:()=>Se,set:Z=>xe(Z)},tooltipPlacement:{get:()=>Te,set:Z=>Ie(Z)},tooltipVisibility:{get:()=>Pe,set:Z=>Re(!!Z)},size:{get:()=>fe,set:ye}});var Ve=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);return de&&_e?ce.createElement(be,icon_extends({ref:qe,style:icon_objectSpread({},ae),className:(0,X.cn)(W.classes.root,ie),size:fe,icon:_e,tooltipText:$(Se),tooltipControlled:ee.available("onTooltipVisibilityAssignment"),tooltipVisibility:Pe,tooltipPlacement:Te},Ve)):null}Icon.normalize=function(Z){Z.data.size||(Z.data.size=_e)};var we=["tooltipText","tooltipPlacement","tooltipControlled","tooltipVisibility"],Se=["style","startIcon","endIcon","className","children"];function component_extends(){return component_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W=0||(X[$]=Z[$]);return X}(Z,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(Z);for(Y=0;Y=0||Object.prototype.propertyIsEnumerable.call(Z,$)&&(X[$]=Z[$])}return X}var xe={root:"bl-button",label:"bl-button-label",contained:"bl-button--contained",outlined:"bl-button--outlined",text:"bl-button--text",sizeSmall:"bl-button--small",sizeLarge:"bl-button--large",disableElevation:"bl-button--unelevated",disabled:"bl-button--disabled",startIcon:"bl-button-start-icon",endIcon:"bl-button-end-icon"},Pe=ce.forwardRef((function ButtonUI(Z,W){var{tooltipText:$,tooltipPlacement:Y,tooltipControlled:X,tooltipVisibility:ee}=Z,ie=component_objectWithoutProperties(Z,we),{style:le,startIcon:pe,endIcon:fe,className:ye,children:_e}=ie,Pe=component_objectWithoutProperties(ie,Se),Re=ce.createElement(de.Z.Button,component_extends({},Pe,{ref:W,style:component_objectSpread({textTransform:"initial"},le),className:ye,classes:xe,startIcon:pe?ce.createElement(be,{icon:pe}):void 0,endIcon:fe?ce.createElement(be,{icon:fe}):void 0}),_e||"");return $?(0,ae.TC)(Re,{tooltipText:$,tooltipPlacement:Y,tooltipControlled:X,tooltipVisibility:ee}):Re}));function button_extends(){return button_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W{if(Z&&!Te.includes(Z))return Ie};function Button(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useHandlerRunner)(Z),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onTypeAssignment",initialValue:()=>W.attrs.type}),[be,_e]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label||""}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onVariantAssignment",validator:variantValidator,initialValue:()=>W.data.variant}),[xe,Re]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.startIcon}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.endIcon}),[ze,We]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableElevation}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableRipple}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[et,tt]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipTextAssignment",initialValue:()=>W.data.tooltipText}),[nt,rt]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipVisibilityAssignment"}),[ot,at]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.tooltipPlacement}),it=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},type:{get:()=>fe,set:Z=>ye(Z)},disabled:{get:()=>Qe,set:Z=>Xe(!!Z)},variant:{get:()=>we,set:Z=>Se(Z)},size:{get:()=>xe,set:Z=>Re(Z)},startIcon:{get:()=>Te,set:Z=>Ie(Z)},endIcon:{get:()=>qe,set:Z=>Ve(Z)},disableElevation:{get:()=>ze,set:Z=>We(!!Z)},disableRipple:{get:()=>He,set:Z=>Ye(!!Z)},el:{get:()=>it.current},label:{get:()=>be,set:Z=>_e(Z)},tooltipText:{get:()=>et,set:Z=>tt(Z)},tooltipPlacement:{get:()=>ot,set:Z=>at(Z)},tooltipVisibility:{get:()=>nt,set:Z=>rt(!!Z)}});var st=(0,Y.useSimpleEventHandlers)(Z,["onClick"]);return de?ce.createElement(Pe,button_extends({ref:it,id:W.id,startIcon:Te,endIcon:qe,style:button_objectSpread({},ae),type:fe,variant:we,size:xe,className:(0,X.cn)(ie),disableElevation:ze,disableRipple:He,disabled:Qe,tooltipText:$(et),tooltipPlacement:ot,tooltipControlled:ee.available("onTooltipVisibilityAssignment"),tooltipVisibility:nt},st),$(be)||""):null}function chip_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function chip_objectSpread(Z){for(var W=1;Wce.createElement(de.Z.Icon,{component:"i",className:(0,X.cn)("material-icons-round","bl-chip-".concat(W,"-icon"))},Z),useIconName=Z=>ce.useMemo((()=>Z&&Z.replace(/[-,\s]/g,"_").toLowerCase()),[Z]);function asyncGeneratorStep(Z,W,$,Y,X,ee,ae){try{var ie=Z[ee](ae),le=ie.value}catch(Z){return void $(Z)}ie.done?W(le):Promise.resolve(le).then(Y,X)}function _asyncToGenerator(Z){return function(){var W=this,$=arguments;return new Promise((function(Y,X){var ee=Z.apply(W,$);function _next(Z){asyncGeneratorStep(ee,Y,X,_next,_throw,"next",Z)}function _throw(Z){asyncGeneratorStep(ee,Y,X,_next,_throw,"throw",Z)}_next(void 0)}))}}var qe={};function ColorPicker(Z){return qe.ColorPickerNode(Z)}function chart_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function chart_objectSpread(Z){for(var W=1;WW.data.accept}),[ze,We]=(0,Y.useDynamicProperty)(Z,{handler:"onMultipleFilesAssignment",initialValue:()=>"true"===W.data.multipleFiles}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.capture}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.processUploadInLogic}),[et,tt]=(0,Y.useDynamicProperty)(Z,{handler:"onDirectoryAssignment",initialValue:()=>W.data.directory}),[nt,rt]=(0,Y.useDynamicProperty)(Z,{handler:"onOverwriteAssignment",initialValue:()=>"true"===W.data.overwrite}),[ot,at]=(0,Y.useDynamicProperty)(Z,{handler:"onButtonLabelAssignment",initialValue:()=>W.data.buttonLabel||""}),[it,st]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.variant}),[ut,lt]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),[ct,dt]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableElevation}),[pt,ft]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableRipple}),[ht,mt]=(0,Y.useDynamicProperty)(Z,{handler:"onUploadSuccessMsgAssignment",initialValue:()=>W.data.uploadSuccessMsg}),[yt,vt]=(0,Y.useDynamicProperty)(Z,{handler:"onUploadFailMsgAssignment",initialValue:()=>W.data.uploadFailMsg}),[gt,bt]=(0,Y.useDynamicProperty)(Z,{handler:"onUploadProgressMsgAssignment",initialValue:()=>W.data.uploadProgressMsg}),[_t,wt]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),kt=function(){var Z=file_uploader_button_asyncToGenerator((function*(Z){var W;if(Z=Z||_e,0!==(null===(W=Z=ze?Z:[Z[0]])||void 0===W?void 0:W.length)){le(!0);try{if(ae.available("onBeforeUpload")){var $=yield ae("onBeforeUpload",{files:Z});Array.isArray($)&&(Z=$)}var Y=yield Promise.all(Z.map(function(){var Z=file_uploader_button_asyncToGenerator((function*(Z){var W=void 0===Z.overwrite?nt:Z.overwrite;if(ae.available("onFileNameAssignment")){var $=yield ae("onFileNameAssignment",{file:Z});if("string"!=typeof $)throw new Error("New File Name must be a string, check onFileNameAssignment handler in FileUploadButton component.");Z=new File([Z],$,{type:Z.type})}var{fileURL:Y}=yield Backendless.Files.upload(Z,et||"",!!W);return Y}));return function(W){return Z.apply(this,arguments)}}()));onUploadSuccess(ze?Y:Y[0])}catch(Z){onUploadFail(Z)}ee.current&&(ee.current.value="")}}));return function uploadFiles(W){return Z.apply(this,arguments)}}(),Ot=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:Se,reset:()=>{ie||(le(!1),fe(null),be(null),we([]))},uploadFiles:kt,classList:{get:()=>xe,set:Z=>Pe(Z)},display:{get:()=>Re,set:Z=>Te(!!Z)},accept:{get:()=>qe,set:Ve},capture:{get:()=>He,set:Ye},multipleFiles:{get:()=>ze,set:Z=>We(!!Z)},processUploadInLogic:{get:()=>Qe,set:Z=>Xe(!!Z)},directory:{get:()=>et,set:tt},overwrite:{get:()=>nt,set:Z=>rt(!!Z)},buttonLabel:{get:()=>ot,set:Z=>at(Z)},uploadSuccessMsg:{get:()=>ht,set:mt},uploadFailMsg:{get:()=>yt,set:vt},uploadProgressMsg:{get:()=>gt,set:bt},disabled:{get:()=>_t,set:Z=>wt(!!Z)},el:{get:()=>Ot&&Ot.current},variant:{get:()=>it,set:Z=>st(Z)},size:{get:()=>ut,set:Z=>lt(Z)},disableElevation:{get:()=>ct,set:Z=>dt(!!Z)},disableRipple:{get:()=>pt,set:Z=>ft(!!Z)}});var Et=function(){var Z=file_uploader_button_asyncToGenerator((function*(Z){var W=ze?[...Z.target.files]:[Z.target.files[0]];Qe?(we(W),ae("onSelectFiles",{selectedFiles:W})):yield kt(W)}));return function onChange(W){return Z.apply(this,arguments)}}(),onUploadSuccess=Z=>{le(!1),fe(!0),ae.available("onUploadSuccess")||Ie(Z),ae("onUploadSuccess",{uploadedFiles:Z})},onUploadFail=Z=>{le(!1),be(Z),ae("onUploadFail",{error:Z})};return Re?ce.createElement(ce.Fragment,null,ie&>&&ce.createElement("div",{style:{color:"#555"}},$(gt)),pe&&ht&&ce.createElement("div",{style:{color:"#39a139"}},$(ht)),ye&&yt&&ce.createElement("div",{style:{color:"#97181a"}},$(yt)),ce.createElement("span",{role:"none",ref:Ot}),!ie&&!ye&&!pe&&ce.createElement(de.Z.Button,{className:(0,X.cn)(xe),variant:it,size:ut,classes:{root:"bl-button",label:"bl-button-label",contained:"bl-button--contained",outlined:"bl-button--outlined",text:"bl-button--text",disableElevation:"bl-button--unelevated",disabled:"bl-button--disabled"},disableElevation:ct,disableRipple:pt,style:file_uploader_button_objectSpread({textTransform:"initial"},Se),id:W.id,disabled:!!_t,onClick:Z=>{Z.preventDefault(),ee.current.click()}},$(ot)||""),ce.createElement("input",{style:{display:"none"},ref:ee,type:"file",multiple:!!ze,accept:qe,capture:He||void 0,onChange:Et})):null}function form_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function form_defineProperty(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z}function Form(Z){var{node:W,dataStore:$,setDataStore:ae,componentContext:ie}=Z,le=(0,Y.useStyle)(Z),[ce,de]=(0,Y.useClassList)(Z),[pe,fe]=(0,Y.useComponentDisplay)(Z),ye=(0,Y.useHandlerRunner)({node:W,componentContext:ie}),be=(0,Y.useElRef)();function submit(){be.current&&be.current.requestSubmit()}function reset(){be.current&&be.current.reset()}(0,Y.useComponentRegister)(Z,{style:le,dataStore:$,setDataStore:ae,classList:{get:()=>ce,set:Z=>de(Z)},display:{get:()=>pe,set:Z=>fe(!!Z)},el:{get:()=>be.current},submit:{get:()=>submit},reset:{get:()=>reset}}),(0,Y.useComponentLifecycle)(Z);return pe?React.createElement("form",{ref:be,className:(0,X.cn)(W.staticClasses.root,ce),style:(0,X.j5)(le),onSubmit:Z=>{Z.preventDefault(),ye("onSubmit",{event:Z,data:$})},onReset:Z=>{Z.preventDefault();var W=function form_objectSpread(Z){for(var W=1;W{$[Z]=null})),ye("onReset",{event:Z,data:$,prevData:W})}},(0,ee.uC)(W.children,{componentContext:ie})):null}DateTimePicker.normalize=Z=>Ye.DateTimePickerNode.normalize(Z),DateTimePicker.settings=He,DateTimePicker.load=datetime_picker_asyncToGenerator((function*(){var{DateTimePickerNode:Z}=yield $.e(67).then($.bind($,99339));Ye.DateTimePickerNode=Z})),FileUploaderButton.normalize=function(Z){void 0===Z.data.variant&&(Z.data.variant=Z.data.outlined?"outlined":"contained")},Form.resolve=function(Z){return Z.dataContainer=!0,(0,ae.GW)(this,Z,ae.zJ)},Form.getStaticClasses=()=>"bl-form";var Qe=$(47323),Xe=$(61800);function google_api_loader_asyncGeneratorStep(Z,W,$,Y,X,ee,ae){try{var ie=Z[ee](ae),le=ie.value}catch(Z){return void $(Z)}ie.done?W(le):Promise.resolve(le).then(Y,X)}function google_api_loader_asyncToGenerator(Z){return function(){var W=this,$=arguments;return new Promise((function(Y,X){var ee=Z.apply(W,$);function _next(Z){google_api_loader_asyncGeneratorStep(ee,Y,X,_next,_throw,"next",Z)}function _throw(Z){google_api_loader_asyncGeneratorStep(ee,Y,X,_next,_throw,"throw",Z)}_next(void 0)}))}}var et=["places"];function GoogleMapApiLoader(Z){var{googleApiKey:W,children:$,libraries:X=et}=Z,[ee,ae]=(0,Y.useState)(!1),ie=(0,Y.useSafeAsync)();return(0,Y.useEffect)((()=>{ie(function loadLib(Z,W){return _loadLib.apply(this,arguments)}(W,X)).then((()=>ae(!0)))}),[W,X]),ee?$:null}var tt={};function composeLibURL(Z,W){var $={key:Z};W&&($.libraries=W);var Y=function toQueryParams(Z){return Object.keys(Z).map((W=>"".concat(W,"=").concat(Z[W]))).join("&")}($);return tt[Y]||(tt[Y]={},tt[Y].fnName="google_api_callback_".concat(Xe.h.mini()),tt[Y].callback=new Promise((Z=>{window[tt[Y].fnName]=()=>Z()}))),{url:"".concat("//maps.googleapis.com/maps/api/js","?").concat(Y,"&callback=").concat(tt[Y].fnName),callback:tt[Y].callback}}function _loadLib(){return(_loadLib=google_api_loader_asyncToGenerator((function*(Z,W){var{url:$,callback:Y}=composeLibURL(Z,W);yield Qe.Z.loadLibrary($),yield Y}))).apply(this,arguments)}function GoogleMarker(Z){var{mapRef:W,map:$,point:Y,showInfoWindow:X,onMarkerClick:ee}=Z;return(0,ce.useEffect)((()=>{var Z=new google.maps.Marker({title:Y.title,position:{lat:Y.lat,lng:Y.lng},map:$});return Z.data=Y,Z.addListener("click",(function(){ee?ee({point:Y}):X(Z)})),Y.autoOpenInfo&&X(Z),W.current.markers.push(Z),()=>{W.current.markers=W.current.markers.filter((W=>W!==Z)),Z.setMap(null)}}),[$,Y.infoWindow,Y.autoOpenInfo,Y.title,Y.lat,Y.lng]),null}var nt=["elRef","className","mapRef","style","onZoom","onPan","onMarkerClick","traffic","scrollWheel"];function google_map_objectWithoutProperties(Z,W){if(null==Z)return{};var $,Y,X=function google_map_objectWithoutPropertiesLoose(Z,W){if(null==Z)return{};var $,Y,X={},ee=Object.keys(Z);for(Y=0;Y=0||(X[$]=Z[$]);return X}(Z,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(Z);for(Y=0;Y=0||Object.prototype.propertyIsEnumerable.call(Z,$)&&(X[$]=Z[$])}return X}var rt=$(23493),ot=$.n(rt),at=$(24504);function autocomplete_google_places_extends(){return autocomplete_google_places_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W({freezeSettingCenter:!1,mapOptions:null,nextCenter:null,infoWindow:null,trafficLayer:null}))),xe=(0,Y.useMemo)((()=>({lat:ye.center.lat,lng:ye.center.lng})),[ye.center.lat,ye.center.lng]);Se.mapOptions=ye,Se.nextCenter=xe,fe||(ye.scrollWheel=fe);var Pe=ye.points||[],hideInfoWindow=()=>{_e&&Se.infoWindow.close()},Re=function showInfoWindow(Z){var{content:W,options:$}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};hideInfoWindow(),!Z||Z instanceof google.maps.Marker||(Z=ee.current.markers.find((W=>W.data===Z))),_e&&Z&&((W=W||Z.data.title||Z.data.infoWindow)&&Se.infoWindow.setContent(W),$&&Se.infoWindow.setOptions($),Se.infoWindow.open(_e,Z))};return ee.current&&(ee.current.showInfoWindow=Re,ee.current.hideInfoWindow=hideInfoWindow),(0,Y.useEffect)((()=>{if(_e&&!Se.freezeSettingCenter){var Z=_e.getCenter(),W=Z&&Z.toJSON()||{};(xe&&W.lat!==xe.lat||W.lng!==xe.lng)&&_e.setCenter(xe)}}),[_e,xe]),(0,Y.useEffect)((()=>{_e&&ye.zoom&&_e.getZoom()!==ye.zoom&&_e.setZoom(ye.zoom)}),[_e,ye.zoom]),(0,Y.useEffect)((()=>{_e&&ye.mapType&&_e.getMapTypeId()!==ye.mapType&&_e.setMapTypeId(ye.mapType)}),[_e,ye.mapType]),(0,Y.useEffect)((()=>{_e&&(pe&&(Se.trafficLayer=new google.maps.TrafficLayer,Se.trafficLayer.setMap(_e)),!pe&&Se.trafficLayer&&Se.trafficLayer.setMap(null))}),[_e,pe]),(0,Y.useEffect)((()=>{_e&&_e.setOptions({zoomControl:ye.zoomControl,mapTypeControl:ye.mapTypeControl,scaleControl:ye.scaleControl,streetViewControl:ye.streetViewControl,rotateControl:ye.rotateControl,fullscreenControl:ye.fullscreenControl,scrollwheel:ye.scrollWheel,gestureHandling:ye.gestureHandling})}),[_e,ye.zoomControl,ye.mapTypeControl,ye.scaleControl,ye.streetViewControl,ye.rotateControl,ye.fullscreenControl,ye.scrollWheel,ye.gestureHandling]),ce.createElement(GoogleMapApiLoader,{googleApiKey:be},ce.createElement("div",{ref:W,className:(0,X.cn)("bl-google-map",$),style:ae},ce.createElement("div",{style:{position:"relative",width:"auto",height:"auto",minWidth:"100%"}},ce.createElement("div",{ref:Z=>{if(Z&&!_e){Se.infoWindow=new google.maps.InfoWindow({content:""});var W=new google.maps.Map(Z,{disableDefaultUI:!0});W.addListener("dragstart",(()=>{Se.freezeSettingCenter=!0})),W.addListener("dragend",(()=>{Se.freezeSettingCenter=!1})),W.addListener("center_changed",(()=>{var Z=W.getCenter().toJSON(),$=Se.nextCenter;if(Z&&($.lat!==Z.lat||$.lng!==Z.lng)){var Y=W.getBounds(),X=Y.getNorthEast().toJSON(),ee=Y.getSouthWest().toJSON();le({currentCenter:Z,northEast:X,southWest:ee})}})),W.addListener("zoom_changed",(()=>{var Z=W.getZoom();Se.mapOptions.zoom!==Z&&ie({currentZoom:Z})})),W.addListener("maptypeid_changed",(()=>{if(Se.mapOptions.setMapType){var Z=W.getMapTypeId();Z!==Se.mapOptions.mapType&&Se.mapOptions.setMapType(Z)}})),we(W),ee.current={map:W,markers:[],showInfoWindow:Re,hideInfoWindow}}},style:{position:"absolute",width:"100%",height:"100%"}},_e&&Pe.map(((Z,W)=>ce.createElement(GoogleMarker,{key:W,mapRef:ee,map:_e,point:Z,showInfoWindow:Re,hideInfoWindow,onMarkerClick:de})))))))},AutocompleteGooglePlaces:function AutocompleteGooglePlaces(Z){var{searchMode:W,googleApiKey:$,onChange:ee,onKeyDown:ae,readOnly:ie,size:le,value:ce,classList:pe,variant:fe,style:ye}=Z,{label:be,placeholder:_e,inputRef:we,id:Se,required:xe,disabled:Pe,autoFocus:Re,simpleHandlers:Te}=Z,{queryPredictionsSettings:Ie,placesPredictionsSettings:qe}=Z,Ve=W===at.Q.AUTOCOMPLETE?qe:Ie,[ze,We]=(0,Y.useState)(""),[He,Ye]=function usePredictions(Z,W,$,X){var[ee,ae]=(0,Y.useState)([]),ie=(0,Y.useCallback)(ot()(BackendlessUI.GoogleAPI.getPlacesPredictions,200),[]);return(0,Y.useEffect)((()=>{if(""!==W){var Y=autocomplete_google_places_objectSpread(autocomplete_google_places_objectSpread({},X),{},{input:W});ie($,Y,(W=>{var $=Z?[Z]:[];W&&($=[...$,...W]),ae($)}))}else ae(Z?[Z]:[])}),[Z,W,$,X]),[ee,ae]}(ce,ze,W,Ve),Qe=(0,Y.useCallback)(((Z,W)=>{Ye((Z=>W?[W,...Z]:Z)),ee(W)}),[ee]);(0,Y.useEffect)((()=>{ce?"string"==typeof ce?We(ce):ce.description!==ze&&We(ce.description):We("")}),[ce]);var Xe=(0,Y.useCallback)(((Z,W)=>We(W)),[]),et=function useInputRenderer(Z){var{inputValue:W,variant:$,required:X,placeholder:ee,disabled:ae,readOnly:ie,onKeyDown:le,label:ce,inputRef:pe}=Z,{autoFocus:fe,simpleHandlers:ye}=Z;return(0,Y.useCallback)((Z=>{var Y=autocomplete_google_places_objectSpread(autocomplete_google_places_objectSpread({},Z.inputProps),{},{value:W}),be=autocomplete_google_places_objectSpread(autocomplete_google_places_objectSpread({},Z.InputProps),{},{readOnly:!!ie,classes:it.input}),_e=autocomplete_google_places_objectSpread(autocomplete_google_places_objectSpread({},Z.InputLabelProps),{},{classes:it.label,shrink:!!ee||void 0});return React.createElement(de.Z.TextField,autocomplete_google_places_extends({},Z,ye,{inputProps:Y,value:W,label:ce,type:"text",onKeyDown:le,inputRef:pe,autoFocus:fe,variant:$,required:X,placeholder:ee,disabled:ae,InputProps:be,InputLabelProps:_e}))}),[W,$,X,ee,ae,ie,le,ce,pe,fe,ye])}({inputValue:ze,variant:fe,required:xe,placeholder:_e,disabled:Pe,readOnly:ie,onKeyDown:ae,label:be,inputRef:we,autoFocus:Re,simpleHandlers:Te}),tt=(0,Y.useMemo)((()=>(0,X.cn)(pe,"bl-autocomplete-google-places-input","bl-autocomplete-google-places-input--".concat(fe),{"bl-autocomplete-google-places-input--disabled":Pe,"bl-autocomplete-google-places-input--required":xe,"bl-autocomplete-google-places-input--with-value":!!ce})),[pe,fe,Pe,xe,ce]);return React.createElement(GoogleMapApiLoader,{googleApiKey:$},React.createElement(de.Z.Autocomplete,{id:Se,options:He,value:ce,style:ye,disabled:Pe,size:le,onChange:Qe,renderOption,getOptionLabel,filterOptions:filterAutocompleteOptions,onInputChange:Xe,renderInput:et,className:tt,classes:it.autocomplete,autoComplete:!0,includeInputInList:!0,filterSelectedOptions:!0}))}};function google_map_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function google_map_objectSpread(Z){for(var W=1;W=0||(X[$]=Z[$]);return X}(Z,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(Z);for(Y=0;Y=0||Object.prototype.propertyIsEnumerable.call(Z,$)&&(X[$]=Z[$])}return X}var dt=ce.forwardRef((function IconButtonUI(Z,W){var{icon:$,className:Y}=Z,X=icon_button_component_objectWithoutProperties(Z,ct);return ce.createElement(Pe,icon_button_component_extends({},X,{ref:W,className:lt()("bl-icon-button",Y)}),ce.createElement(be,{icon:$}))}));function icon_button_extends(){return icon_button_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W=0||(X[$]=Z[$]);return X}(Z,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(Z);for(Y=0;Y=0||Object.prototype.propertyIsEnumerable.call(Z,$)&&(X[$]=Z[$])}return X}var yt={label:{root:"bl-input-label",focused:"bl-input-label--focused",disabled:"bl-input-label--disabled",required:"bl-input-label--required",filled:"bl-input-label--filled",outlined:"bl-input-label--outlined"},input:{root:"bl-input-input-root",focused:"bl-input-input--focused",disabled:"bl-input-input--disabled"}},vt=ce.forwardRef((function InputUI(Z,W){var{className:$,style:Y,errorMessage:ee,inputRef:ae,id:ie,value:le,rawValue:pe,disabled:fe,label:ye,readOnly:be,_required:_e}=Z,we=input_component_objectWithoutProperties(Z,ft),{type:Se,variant:xe,placeholder:Pe,autoFocus:Re,onChange:Te,onKeyDown:Ie}=we,qe=input_component_objectWithoutProperties(we,ht),{onKeyUp:Ve,onFocus:ze,onBlur:We,onWheel:He,size:Ye,maxLength:Qe,maxValue:Xe,minValue:et}=qe,tt=input_component_objectWithoutProperties(qe,mt);return ce.createElement(de.Z.TextField,input_component_extends({},tt,{style:Y,ref:W,inputRef:ae,id:ie,value:null==pe?"":pe.toString(),disabled:!!fe,label:ye||"",required:_e,type:Se||"text",variant:xe,size:Ye,placeholder:Pe||"",autoFocus:!!Re,onChange:Te,onKeyDown:Ie,onKeyUp:Ve,onFocus:ze,onBlur:We,onWheel:He,error:!!ee,helperText:ee||null,inputProps:{step:"number"===Se?"any":void 0,max:"number"===Se?Xe:void 0,min:"number"===Se?et:void 0,maxLength:Qe},InputProps:{classes:yt.input,readOnly:!!be},InputLabelProps:{classes:yt.label,shrink:!!Pe||void 0},className:(0,X.cn)($,"bl-input",{["bl-input--".concat(xe)]:!ee,"bl-input--disabled":!!fe,"bl-input--required":!!_e,"bl-input--with-value":!!le})}))}));function input_extends(){return input_extends=Object.assign?Object.assign.bind():function(Z){for(var W=1;W{if(W){var $=W.checkValidity();return""===Z?{value:null,valid:$}:{value:Number(Z),valid:$}}if(""===Z)return{value:null,valid:!0};var Y=Number(Z);return{value:Y,valid:String(Y)===String(Z)}}};function Input(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useUid)(),ae=(0,Y.useHandlerRunner)(Z),ie=(0,Y.useStyle)(Z),[le,de]=(0,Y.useClassList)(Z),[pe,fe]=(0,Y.useComponentDisplay)(Z),[ye,be]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.variant}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onTypeAssignment",initialValue:()=>W.data.type}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.maxLength||null}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.maxValue||null}),[ze,We]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.minValue||null}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",forceDefault:!0,initialValue:()=>function trimValue(Z){var{value:W,maxLength:$,type:Y}=Z;if(W&&"number"!==Y&&"number"!=typeof W)return+$?W.slice(0,+$):W;return W}({value:W.data.value,maxLength:Te,type:W.data.type})}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{handler:"onPlaceholderAssignment",initialValue:()=>W.data.placeholder}),[et,tt]=(0,Y.useDynamicProperty)(Z,{handler:"onReadOnlyStateAssignment",initialValue:()=>W.data.readonly}),[nt,rt]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[ot,at]=(0,Y.useDynamicProperty)(Z,{handler:"onRequiredStateAssignment",initialValue:()=>W.data.required}),[it,st]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.autofocus}),[ut,lt]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.scrollChanging}),[ct,dt]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>null}),[pt,ft]=(0,Y.useState)(He);(0,Y.useEffect)((()=>{ft(He)}),[He]);var ht=(0,Y.useMemo)((()=>convertValue(W.data.value).valid),[]),mt=(0,Y.useElRef)(),yt=(0,ce.useRef)(ht);function convertValue(Z,W){var{value:$,valid:Y}=gt[_e]?gt[_e](Z,W):{value:Z,valid:!0};return{value:$,valid:Y}}var bt=(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:de},display:{get:()=>pe,set:Z=>fe(!!Z)},variant:{get:()=>ye,set:be},value:{get:()=>He,set:function valueSetter(Z){var{value:W,valid:$}=convertValue(Z);$&&Ye(W)}},label:{get:()=>Pe,set:Re},type:{get:()=>_e,set:we},name:{get:()=>Se,set:xe},maxLength:{get:()=>Te,set:Z=>Ie(Z)},minValue:{get:()=>ze,set:We},maxValue:{get:()=>qe,set:Ve},readOnly:{get:()=>et,set:Z=>tt(!!Z)},disabled:{get:()=>nt,set:Z=>rt(!!Z)},required:{get:()=>ot,set:Z=>at(!!Z)},autoFocus:{get:()=>it,set:Z=>st(!!Z)},scrollChanging:{get:()=>ut,set:Z=>lt(!!Z)},el:{get:()=>mt.current},focus:()=>mt.current.focus(),isValidValue:{get:()=>yt.current},setError:{get:()=>ct,set:Z=>dt(Z)},placeholder:{get:()=>Qe,set:Xe}}),_t=(0,Y.useSimpleEventHandlers)(Z,["onFocus"]),wt=(0,Y.useCallback)((Z=>{var W=Z.target.checkValidity();"number"!==_e||W||(Ye(0),setTimeout((()=>{Ye("")}),0),yt.current=!0,ae("onChange",{event:Z,value:null,prevValue:He})),ae("onBlur",{event:Z})}),[_e,He]),kt=(0,Y.useCallback)((Z=>{var{altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X}=Z;"number"===_e&&setTimeout((()=>{var W=Z.target.checkValidity(),$=Z.target.validity;W?yt.current=!0:(yt.current=!1,ae("onInvalidValue",{event:Z,isValid:W,validityData:$}))}),0),ae("onKeyDown",{event:Z,altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X,component:bt})}),[bt,He,_e]),Ot=(0,Y.useCallback)((Z=>{var{altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X}=Z;ae("onKeyUp",{event:Z,altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X,component:bt})}),[bt]),Et=(0,Y.useMemo)((()=>{if(!ut&&"number"===_e)return Z=>Z.target.blur()}),[ut,_e]),St=(0,Y.useLayoutEffectProperty)(ot);if(!pe)return null;var xt=input_objectSpread({onChange:Z=>{var W=Z.target.value,{value:$,valid:Y}=convertValue(W,Z.target);if(Y&&!ae.available("onValueAssignment")){var X=W===(null==$?void 0:$.toString())?$:W;Ye(X)}ft(W),Y&&setTimeout((()=>{ae("onChange",{event:Z,value:$,prevValue:He})}),0)},onKeyDown:kt,onKeyUp:Ot,onWheel:Et},_t);return React.createElement(vt,input_extends({className:(0,X.cn)(le),style:input_objectSpread({},ie),inputRef:mt,id:ee,value:He,rawValue:pt,disabled:nt,maxLength:Te,minValue:ze,maxValue:qe,label:$(Pe),onBlur:wt,readOnly:et,_required:St,type:_e,variant:ye,placeholder:$(Qe),autoFocus:it,errorMessage:ct},xt))}function layout_cell_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function layout_cell_defineProperty(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z}function LayoutCell(Z){var{node:W,componentContext:$}=Z,{dataStore:ae,setDataStore:ie,dynamicItemData:le}=Z,de=(0,Y.useStyle)(Z),[pe,fe]=(0,Y.useClassList)(Z),[ye,be]=(0,Y.useComponentDisplay)(Z),[_e,we]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.sizeDesktop}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.sizeTablet}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.sizePhone}),Te=(0,Y.useElRef)(),Ie={style:de,classList:{get:()=>pe,set:Z=>fe(Z)},display:{get:()=>ye,set:Z=>be(!!Z)},sizeDesktop:{get:()=>_e,set:Z=>we(Z)},sizeTablet:{get:()=>Se,set:Z=>xe(Z)},sizePhone:{get:()=>Pe,set:Z=>Re(Z)},el:{get:()=>Te.current}};(ae||le)&&(Ie.dataStore=ae||le),ie&&(Ie.setDataStore=ie),(0,Y.useComponentRegister)(Z,Ie),(0,Y.useComponentLifecycle)(Z);var qe=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]),Ve=ce.useMemo((()=>(0,X.cn)("bl-layout-cell",pe,{["bl-layout-cell--".concat(_e,"-desktop")]:_e,["bl-layout-cell--".concat(Se,"-tablet")]:Se,["bl-layout-cell--".concat(Pe,"-phone")]:Pe})),[pe,_e,Se,Pe]);return ye?ce.createElement("div",function layout_cell_objectSpread(Z){for(var W=1;Wbe,set:Z=>_e(Z)},display:{get:()=>we,set:Z=>Se(!!Z)},el:{get:()=>xe.current}};(ae||le)&&(Pe.dataStore=ae||le),ie&&(Pe.setDataStore=ie),pe&&(Pe.dynamicListItems={get:()=>de,set:Z=>pe(Z)}),(0,Y.useComponentRegister)(Z,Pe),(0,Y.useComponentLifecycle)(Z);var Re=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);if(!we)return null;return ce.createElement("div",function layout_container_objectSpread(Z){for(var W=1;WW.data.gridGap}),Re=(0,Y.useElRef)(),Te={style:ye,classList:{get:()=>be,set:Z=>_e(Z)},gridGap:{get:()=>xe,set:Z=>Pe(Z)},display:{get:()=>we,set:Z=>Se(!!Z)},el:{get:()=>Re.current}};(ae||le)&&(Te.dataStore=ae||le),ie&&(Te.setDataStore=ie),pe&&(Te.dynamicListItems={get:()=>de,set:Z=>pe(Z)}),(0,Y.useComponentRegister)(Z,Te),(0,Y.useComponentLifecycle)(Z);var Ie=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);if(!we)return null;return ce.createElement("div",layout_row_objectSpread({ref:Re,style:layout_row_objectSpread({gridGap:xe?"".concat(xe,"px"):null},(0,X.j5)(ye)),className:(0,X.cn)("bl-layout-row",be)},Ie),...fe?fe():(0,ee.uC)(W.children,{componentContext:$}))}function link_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function link_objectSpread(Z){for(var W=1;W[...Z.attributes].filter((W=>((Z,W)=>!kt.test(W)&&!wt[Z.nodeName].includes(W))(Z,W.name))),prepareNode=Z=>(Z=>!!wt[Z.nodeName]||3===Z.nodeType)(Z)?(Z=>{Z.attributes&&(Z.childElementCount&&Z.childNodes.forEach((Z=>prepareNode(Z))),getUnsafeAttrs(Z).forEach((W=>Z.removeAttribute(W.name))))})(Z):Z.remove(),sanitize=Z=>{var W=document.createElement("div");return W.innerHTML=Z,W.childElementCount?(W.childNodes.forEach((Z=>prepareNode(Z))),W.innerHTML):Z};function paragraph_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function paragraph_objectSpread(Z){for(var W=1;Wce.createElement(de.Z.MenuItem,{key:W,value:Z.value,disabled:Z.disabled,classes:Pt.option},Z.label)))))}));function select_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function select_objectSpread(Z){for(var W=1;WW.data.variant}),[_e,we]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.rows}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.rowsMax}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{handler:"onPlaceholderAssignment",initialValue:()=>W.data.placeholder}),[ze,We]=(0,Y.useDynamicProperty)(Z,{handler:"onMaxLengthAssignment",initialValue:()=>W.data.maxLength}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",forceDefault:!0,initialValue:()=>W.data.value}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{handler:"onReadOnlyStateAssignment",initialValue:()=>W.data.readonly}),[et,tt]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[nt,rt]=(0,Y.useDynamicProperty)(Z,{handler:"onRequiredStateAssignment",initialValue:()=>W.data.required}),ot=(0,Y.useElRef)(),at=(0,Y.useSimpleEventHandlers)(Z,["onFocus","onBlur"]);(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:Z=>de(Z)},display:{get:()=>pe,set:Z=>fe(!!Z)},variant:{get:()=>ye,set:be},name:{get:()=>Pe,set:Re},label:{get:()=>Te,set:Ie},placeholder:{get:()=>qe,set:Ve},maxLength:{get:()=>ze,set:We},rows:{get:()=>_e,set:we},rowsMax:{get:()=>Se,set:xe},value:{get:()=>He,set:Ye},readOnly:{get:()=>Qe,set:Z=>Xe(!!Z)},disabled:{get:()=>et,set:Z=>tt(!!Z)},required:{get:()=>nt,set:Z=>rt(!!Z)},el:{get:()=>ot.current},focus:()=>ot.current.focus()});return pe?ce.createElement(Tt,textarea_extends({},at,{className:(0,X.cn)(le),style:textarea_objectSpread({},ie),id:ee,value:He,onChange:Z=>{var W=Z.target.value;ae.available("onValueAssignment")||Ye(W),ae("onChange",{event:Z,value:W,prevValue:He})},disabled:et,required:nt,readOnly:Qe,label:$(Te)||"",variant:ye,placeholder:$(qe),multiline:!0,minRows:_e,maxRows:Se,maxLength:ze,inputRef:ot})):null}Textarea.normalize=function(Z){void 0===Z.data.variant&&(Z.data.variant="outlined")};var Dt=$(34392);function video_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function video_objectSpread(Z){for(var W=1;W{var Z=W.startsWith(At)?W.replace(At,""):W.replace(Lt,""),ce=le?Lt:At,de=[];return $&&de.push("autoplay=1"),ee&&de.push("mute=1"),X&&de.push("loop=1&playlist=".concat(Z)),Y||de.push("controls=0"),ie||de.push("rel=0"),ae&&de.push("modestbranding=1"),"".concat(ce).concat(Z,"?").concat(de.join("&"))}),[W,$,Y,X,ee,ae,ie,le]);return ce.createElement("iframe",{style:{width:"100%",border:"none"},src:de,title:"YoutubeProviderVideo",allow:"".concat($?"autoplay; ":"","fullscreen"),allowFullScreen:!0})}function VimeoProvider(Z){var{source:W,autoplay:$,background:Y,controls:X,loop:ee,color:ae}=Z,ie=ce.useMemo((()=>{var Z=W.replace(It,""),ie=[];return $&&ie.push("autoplay=1"),Y&&ie.push("background=1"),ee&&ie.push("loop=1"),X||ie.push("title=0&portrait=0&badge=0"),ae&&ie.push("color=".concat(ae)),"".concat("https://player.vimeo.com/video/").concat(Z,"?").concat(ie.join("&"))}),[W,$,Y,X,ee,ae]);return ce.createElement("iframe",{style:{width:"100%",border:"none"},src:ie,title:"VimeoProviderVideo",allow:"".concat($?"autoplay; ":"","fullscreen"),allowFullScreen:!0})}function HTML5Provider(Z){var{source:W,autoplay:$,controls:Y,playsInline:X,mute:ee,loop:ae}=Z;return ce.createElement("video",{style:{width:"100%",border:"none"},src:BackendlessUI.provideFileUrl(W),autoPlay:$,muted:ee,loop:ae,controls:Y,playsInline:X})}function IFrameProvider(Z){var{source:W,autoplay:$}=Z,Y=ce.useMemo((()=>{var Z=[];return $&&Z.push("autoplay=1"),"".concat(W,"?").concat(Z.join("&"))}),[W,$]);return ce.createElement("iframe",{style:{width:"100%",border:"none"},src:Y,allowFullScreen:!0,title:"IFrameProviderVideo",allow:"".concat($?"autoplay; ":"","fullscreen")})}YoutubeProvider.match=Z=>Z.startsWith(At)||Z.startsWith(Lt),VimeoProvider.match=Z=>Z.startsWith(It),HTML5Provider.match=Z=>Mt.test(Z),IFrameProvider.match=Z=>Z.startsWith("http");var Nt=[YoutubeProvider,VimeoProvider,HTML5Provider,IFrameProvider];var Bt={root:"bl-slider",disabled:"bl-slider--disabled",rail:"bl-slider-rail",track:"bl-slider-track",mark:"bl-slider--mark",markActive:"bl-slider--mark-active",markLabel:"bl-slider--mark-label",thumb:"bl-slider-thumb",focusVisible:"bl-slider-thumb--focus",active:"bl-slider--active",valueLabel:"bl-slider--value-label",vertical:"bl-slider--vertical"},Ut=ce.forwardRef((function SliderUI(Z,W){var{className:$,marks:Y,style:X,value:ee,step:ie,min:le,max:pe,defaultValue:fe}=Z,{name:ye,disabled:be,onChange:_e,valueLabelDisplay:we,orientation:Se,valueLabelFormat:xe}=Z,{tooltipText:Pe,tooltipPlacement:Re,tooltipControlled:Te,tooltipVisibility:Ie}=Z,qe=ce.createElement(de.Z.Slider,{ref:W,className:$,style:X,name:ye,defaultValue:fe,value:ee,orientation:Se,valueLabelDisplay:we,valueLabelFormat:xe,marks:Y,max:pe,min:le,onChange:_e,step:ie,disabled:be,classes:Bt});return Pe?(0,ae.TC)(qe,{tooltipText:Pe,tooltipPlacement:Re,tooltipControlled:Te,tooltipVisibility:Ie}):qe}));function slider_ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function slider_objectSpread(Z){for(var W=1;WW.data.chartName}),fe=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:$,classList:{get:()=>ee,set:Z=>ae(Z)},display:{get:()=>ie,set:Z=>le(!!Z)},chartName:{get:()=>de,set:pe},el:{get:()=>fe.current}}),ie&&de?ce.createElement("div",{ref:fe,className:(0,X.cn)(ee,"bl-chart"),style:chart_objectSpread({},$)},ce.createElement("iframe",{style:{border:"none",height:"100%",width:"100%"},src:BackendlessUI.provideFileUrl("/chart-builder/".concat(de,"/index.html"))})):null},checkbox:function Checkbox(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useHandlerRunner)(Z),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[be,_e]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onCheckedStateAssignment",forceDefault:!0,initialValue:()=>W.data.checked}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipTextAssignment",initialValue:()=>W.data.tooltipText}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipVisibilityAssignment"}),[Ve,We]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.tooltipPlacement}),He=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},name:{get:()=>fe,set:ye},label:{get:()=>be,set:_e},checked:{get:()=>we,set:Z=>Se(!!Z)},disabled:{get:()=>xe,set:Z=>Pe(!!Z)},el:{get:()=>He.current},tooltipText:{get:()=>Re,set:Z=>Te(Z)},tooltipPlacement:{get:()=>Ve,set:Z=>We(Z)},tooltipVisibility:{get:()=>Ie,set:Z=>qe(!!Z)}}),de?ce.createElement(ze,{ref:He,style:checkbox_objectSpread({},ae),className:(0,X.cn)(ie),checked:we,disabled:xe,label:$(be),name:fe,onChange:Z=>{var W=Z.target.checked;ee.available("onCheckedStateAssignment")||Se(W),ee("onChange",{event:Z,value:W})},tooltipText:$(Re),tooltipPlacement:Ve,tooltipControlled:ee.available("onTooltipVisibilityAssignment"),tooltipVisibility:Ie}):null},"data-table":DataTable,"datetime-picker":DateTimePicker,divider:function Divider(Z){var W=(0,Y.useStyle)(Z),[$,ee]=(0,Y.useClassList)(Z),[ae,ie]=(0,Y.useComponentDisplay)(Z),le=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:W,classList:{get:()=>$,set:Z=>ee(Z)},display:{get:()=>ae,set:Z=>ie(!!Z)},el:{get:()=>le.current}}),ae?ce.createElement("hr",{style:divider_objectSpread({},W),ref:le,className:(0,X.cn)($,"bl-divider")}):null},"file-uploader-button":FileUploaderButton,form:Form,"google-map":function google_map_GoogleMap(Z){var{node:W}=Z,{googleApiKey:$}=BackendlessUI.getSettings(),X=(0,Y.useHandlerRunner)(Z),ee=(0,Y.useStyle)(Z),[ae,ie]=(0,Y.useClassList)(Z),[le,de]=(0,Y.useComponentDisplay)(Z),[pe,fe]=(0,Y.useDynamicProperty)(Z,{handler:"onMapTypeAssignment",initialValue:()=>W.data.mapType}),[ye,be]=(0,Y.useDynamicProperty)(Z,{handler:"onMapZoomAssignment",initialValue:()=>Math.max(1,Math.min(22,parseInt(W.data.mapZoom)))}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onMapCenterAssignment",initialValue:()=>function parseMapLocationString(Z){if(Z)try{return JSON.parse(Z)}catch(Z){return BackendlessUI.logger.warn("Could not parse map location",Z),{lat:0,lng:0}}}(W.data.mapCenter)}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{handler:"onZoomControlAssignment",initialValue:()=>"true"===W.data.zoomControl}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onMapTypeControlAssignment",initialValue:()=>"true"===W.data.mapTypeControl}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{handler:"onScaleControlAssignment",initialValue:()=>"true"===W.data.scaleControl}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{handler:"onStreetViewControlAssignment",initialValue:()=>"true"===W.data.streetViewControl}),[ze,We]=(0,Y.useDynamicProperty)(Z,{handler:"onRotateControlAssignment",initialValue:()=>"true"===W.data.rotateControl}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{handler:"onFullscreenControlAssignment",initialValue:()=>"true"===W.data.fullscreenControl}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{handler:"onTrafficAssignment",initialValue:()=>W.data.mapTraffic}),[et,tt]=(0,Y.useDynamicProperty)(Z,{handler:"onScrollWheelAssignment",initialValue:()=>W.data.mapScrollwheel}),[nt,rt]=(0,Y.useDynamicProperty)(Z,{handler:"onGestureHandlingAssignment",initialValue:()=>W.data.mapGestureHandling}),[ot,at]=(0,Y.useDynamicProperty)(Z,{handler:"onPointsAssignment",initialValue:()=>function parseMapPointsString(Z){if(Z)try{return JSON.parse(Z)}catch(Z){return BackendlessUI.logger.warn("Could not parse map location",Z),[]}}(W.data.mapPoints),sensitiveKeys:["infoWindow","autoOpenInfo","title","lat","lng"]}),it=(0,Y.useElRef)(),ut=(0,Y.useElRef)();if((0,Y.useComponentRegister)(Z,{style:ee,classList:{get:()=>ae,set:Z=>ie(Z)},display:{get:()=>le,set:Z=>de(!!Z)},mapType:{get:()=>pe,set:fe},zoom:{get:()=>ye,set:be},center:{get:()=>_e,set:we},points:{get:()=>ot,set:at},zoomControl:{get:()=>Se,set:xe},mapTypeControl:{get:()=>Pe,set:Re},scaleControl:{get:()=>Te,set:Ie},streetViewControl:{get:()=>qe,set:Ve},rotateControl:{get:()=>ze,set:We},fullscreenControl:{get:()=>He,set:Ye},traffic:{get:()=>Qe,set:Xe},scrollWheel:{get:()=>et,set:tt},gestureHandling:{get:()=>nt,set:rt},map:{get:()=>it.current},el:{get:()=>ut&&ut.current}}),(0,Y.useComponentLifecycle)(Z),!le||!$)return null;var lt=X.available("onMarkerClick")?Z=>{var{point:W}=Z;return X("onMarkerClick",{point:W})}:null;return ce.createElement(st.GoogleMap,{elRef:ut,mapRef:it,style:google_map_objectSpread({},ee),className:ae,googleApiKey:$,mapType:pe,setMapType:fe,zoom:ye,center:_e,points:ot,zoomControl:Se,mapTypeControl:Pe,scaleControl:Te,streetViewControl:qe,rotateControl:ze,fullscreenControl:He,onZoom:Z=>{var{currentZoom:W}=Z;be(W),X("onZoomChange",{value:W})},onPan:Z=>{var{currentCenter:W,northEast:$,southWest:Y}=Z;we(W),X("onPanChange",{value:W,northEast:$,southWest:Y})},onMarkerClick:lt,scrollWheel:et,gestureHandling:nt,traffic:Qe})},icon:Icon,"icon-button":function IconButton(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useHandlerRunner)(Z),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onTypeAssignment",initialValue:()=>W.attrs.type}),[be,_e]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.variant}),[we,Se]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onIconAssignment",initialValue:()=>W.data.icon}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableElevation}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.disableRipple}),[Ve,ze]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[We,He]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipTextAssignment",initialValue:()=>W.data.tooltipText}),[Ye,Qe]=(0,Y.useDynamicProperty)(Z,{handler:"onTooltipVisibilityAssignment"}),[Xe,et]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.tooltipPlacement}),tt=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},type:{get:()=>fe,set:Z=>ye(Z)},disabled:{get:()=>Ve,set:Z=>ze(!!Z)},variant:{get:()=>be,set:Z=>_e(Z)},size:{get:()=>we,set:Z=>Se(Z)},icon:{get:()=>xe,set:Z=>Pe(Z)},disableElevation:{get:()=>Re,set:Z=>Te(!!Z)},disableRipple:{get:()=>Ie,set:Z=>qe(!!Z)},el:{get:()=>tt.current},tooltipText:{get:()=>We,set:Z=>He(Z)},tooltipPlacement:{get:()=>Xe,set:Z=>et(Z)},tooltipVisibility:{get:()=>Ye,set:Z=>Qe(!!Z)}});var nt=(0,Y.useSimpleEventHandlers)(Z,["onClick"]);return de?ce.createElement(dt,icon_button_extends({ref:tt,style:ae,type:fe,variant:be,size:we,icon:xe,className:(0,X.cn)(ie),disableElevation:Re,disableRipple:Ie,disabled:Ve,tooltipText:$(We),tooltipControlled:ee.available("onTooltipVisibilityAssignment"),tooltipVisibility:Ye,tooltipPlacement:Xe},nt)):null},iframe:function Iframe(Z){var{node:W}=Z,$=(0,Y.useStyle)(Z),[ee,ae]=(0,Y.useClassList)(Z),[ie,le]=(0,Y.useComponentDisplay)(Z),[de,pe]=(0,Y.useDynamicProperty)(Z,{handler:"onSourceUrlAssignment",initialValue:()=>W.data.sourceUrl}),[fe,ye]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.title||""}),be=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:$,classList:{get:()=>ee,set:Z=>ae(Z)},display:{get:()=>ie,set:Z=>le(!!Z)},sourceUrl:{get:()=>de,set:pe},title:{get:()=>fe,set:ye},el:{get:()=>be.current}}),ie&&de?ce.createElement("div",{style:iframe_objectSpread({},$),ref:be,className:(0,X.cn)(ee,"bl-iframe")},ce.createElement("iframe",{style:{width:"100%",height:"100%",border:"none"},title:fe||"iframe",src:de})):null},image:function Image(Z){var{node:W}=Z,$=(0,Y.useStyle)(Z),[ee,ae]=(0,Y.useClassList)(Z),[ie,le]=(0,Y.useComponentDisplay)(Z),de=(0,Y.useHandlerRunner)(Z),[pe,fe]=(0,Y.useDynamicProperty)(Z,{handler:"onSourceUrlAssignment",initialValue:()=>W.data.url}),[ye,be]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.alt}),[_e,we]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.width}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.height}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.loadMode});(0,ce.useEffect)((()=>{ie&&pe&&de("onBeforeLoad",{sourceURL:pe})}),[ie,pe]);var Te=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:$,classList:{get:()=>ee,set:Z=>ae(Z)},display:{get:()=>ie,set:Z=>le(!!Z)},src:{get:()=>pe,set:fe},alt:{get:()=>ye,set:be},width:{get:()=>_e,set:we},height:{get:()=>Se,set:xe},loadMode:{get:()=>Pe,set:Re},el:{get:()=>Te.current}});var Ie=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut","onLoad","onError"]),qe=pe,Ve=(0,Y.useMemo)((()=>pt[Pe]?Pe:null),[Pe]);return ie&&qe?ce.createElement("img",image_objectSpread({style:image_objectSpread({},$),ref:Te,width:_e||void 0,height:Se||void 0,alt:ye||"image",loading:Ve||pt.lazy,className:(0,X.cn)(ee,"bl-image"),src:BackendlessUI.provideFileUrl(qe)},Ie)):null},input:Input,"layout-cell":LayoutCell,"layout-container":LayoutContainer,"layout-row":LayoutRow,link:function Link(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useHandlerRunner)(Z),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onTargetTypeAssignment",initialValue:()=>W.data.targetType}),[be,_e]=(0,Y.useDynamicProperty)(Z,{handler:"onTargetPathAssignment",initialValue:()=>W.data.targetPath}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onPageNameAssignment",initialValue:()=>W.data.pageName}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onTextAssignment",initialValue:()=>W.data.text}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.ariaLabel}),Ie=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},targetType:{get:()=>fe,set:ye},targetPath:{get:()=>be,set:_e},pageName:{get:()=>we,set:Se},text:{get:()=>xe,set:Pe},ariaLabel:{get:()=>Re,set:Te},el:{get:()=>Ie.current}});var qe=(0,Y.useMemo)((()=>we?BackendlessUI.Navigator.getNextPageUrl(we):fe===bt?"mailto:"+be:be||"#"),[we,be,fe]),Ve=(0,Y.useMemo)((()=>{if(fe===_t)return fe}),[fe]),ze=(0,Y.useSimpleEventHandlers)(Z,["onMouseOver","onMouseOut","onFocus","onBlur"]);return de?ce.createElement("a",link_objectSpread({style:link_objectSpread({},ae),ref:Ie,className:(0,X.cn)(ie,"bl-link"),"aria-label":Re||"link",target:Ve,href:qe,onClick:Z=>{ee.available("onClick")?(Z.preventDefault(),ee("onClick",{event:Z})):we&&fe!==_t&&(Z.preventDefault(),BackendlessUI.Navigator.goToPage(we))}},ze),$(xe)):null},paragraph:function Paragraph(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onContentAssignment",initialValue:()=>ce.createElement(ce.Fragment,null,...(0,ee.uC)(W.children))}),[be,_e]=(0,Y.useMemo)((()=>"string"==typeof fe?[{__html:sanitize($(fe))},null]:[void 0,fe]),[fe,BackendlessUI.I18n.lang]),we=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},content:{get:()=>fe,set:Z=>ye(Z)},el:{get:()=>we.current}}),(0,Y.useComponentLifecycle)(Z);var Se=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);return de?ce.createElement("div",paragraph_objectSpread({style:paragraph_objectSpread({whiteSpace:be?"break-spaces":void 0},ae),ref:we,className:(0,X.cn)(ie,"bl-paragraph"),dangerouslySetInnerHTML:$(be)},Se),$(_e)):null},"qr-code":QRCode,"radio-button":function RadioButton(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useUid)(),ae=(0,Y.useHandlerRunner)(Z),ie=(0,Y.useStyle)(Z),[le,de]=(0,Y.useClassList)(Z),[pe,fe]=(0,Y.useComponentDisplay)(Z),[ye,be]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",fromProps:()=>Z.groupName,initialValue:()=>Z.groupName||W.data.name}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",initialValue:()=>W.data.value}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onCheckedValueAssignment",fromProps:()=>Z.checkedValue,initialValue:()=>W.data.checked?W.data.value:null}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),qe=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:Z=>de(Z)},display:{get:()=>pe,set:Z=>fe(!!Z)},name:{get:()=>ye,set:be},label:{get:()=>_e,set:we},value:{get:()=>Se,set:xe},checkedValue:{get:()=>Pe,set:Re},disabled:{get:()=>Te,set:Z=>Ie(!!Z)},el:{get:()=>qe.current}});var Ve=Z.onChange||(Z=>{var W=Z.target.value;ae.available("onCheckedValueAssignment")||Re(W),ae("onChange",{event:Z,value:W})});return pe?ce.createElement(St,{ref:qe,label:$(_e),disabled:Te,style:radio_button_objectSpread({},ie),className:(0,X.cn)(le),name:ye,onChange:Ve,id:ee,value:Se,checkedValue:Pe}):null},"radio-buttons-group":function RadioButtonsGroup(Z){var{node:W,componentContext:$}=Z,ae=(0,Y.useHandlerRunner)(Z),ie=(0,Y.useStyle)(Z),[le,de]=(0,Y.useClassList)(Z),[pe,fe]=(0,Y.useComponentDisplay)(Z),[ye,be]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onCheckedValueAssignment",initialValue:()=>W.data.checkedValue}),Se=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:Z=>de(Z)},display:{get:()=>pe,set:Z=>fe(!!Z)},name:{get:()=>ye,set:be},checkedValue:{get:()=>_e,set:we},el:{get:()=>Se.current}}),(0,Y.useComponentLifecycle)(Z),pe?ce.createElement("div",{ref:Se,style:radio_buttons_group_objectSpread({},ie),className:(0,X.cn)(le,"bl-radio-button-group")},...(0,ee.uC)(W.children,{componentContext:$,groupName:ye,checkedValue:_e,onChange:Z=>{var W=Z.target.value;ae.available("onCheckedValueAssignment")||we(W),ae("onChange",{event:Z,checkedValue:W,prevValue:_e})}})):null},select:function Select(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useUid)(),ae=(0,Y.useHandlerRunner)(Z),ie=(0,Y.useStyle)(Z),[le,ce]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.variant||"outlined"}),[be,_e]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onOptionsAssignment",initialValue:()=>function parseOptions(Z){if(!Z)return[];try{return function convertFromJSON(Z){if("string"!=typeof Z)return console.error("Error while parsing Select options"),[];var W=JSON.parse(Z);if(!Array.isArray(W))return console.error("Error while parsing Select options"),[];return W}(Z)}catch(W){try{return function convertFromLegacy(Z){var W=[];return Z.split(";").forEach((Z=>{var[$,Y]=Z.split(":");W.push({value:$,label:Y})})),W}(Z)}catch(Z){console.error("Error while parsing Select options",Z)}}return[]}(W.data.options)}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onValueKeyAssignment",initialValue:()=>W.data.valueKey}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelKeyAssignment",initialValue:()=>W.data.labelKey}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",forceDefault:!0,initialValue:()=>W.data.value}),[Ve,ze]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[We,He]=(0,Y.useDynamicProperty)(Z,{handler:"onRequiredStateAssignment",initialValue:()=>W.data.required}),[Ye,Qe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),Xe=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:Z=>ce(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},label:{get:()=>be,set:_e},options:{get:()=>we,set:Se},valueKey:{get:()=>xe,set:Pe},labelKey:{get:()=>Re,set:Te},variant:{get:()=>fe,set:ye},value:{get:()=>Ie,set:qe},disabled:{get:()=>Ve,set:Z=>ze(!!Z)},required:{get:()=>We,set:Z=>He(!!Z)},size:{get:()=>Ye,set:Qe},el:{get:()=>Xe.current}});var et=(0,Y.useMemo)((()=>{var Z=[];if(Array.isArray(we)){var W=!1;for(var Y of we){var X=Y[xe||"value"];if(void 0===X)W||(console.error("Invalid option item in the Select Component, "+'make sure each option object has defined "'.concat(xe,'" property, otherwise the option will be skipped')),W=!0);else{var ee=Y[Re]||Y.label||X;Z.push({___rawValue:X,___option:Y,value:"".concat(X),label:$(ee),disabled:!!Y.disabled})}}}return Z}),[xt.K.getUpdatedAt(we),we,xe,Re,BackendlessUI.I18n.lang]);return de?React.createElement(Ct,{style:select_objectSpread({},ie),disabled:Ve,required:We,size:Ye,ref:Xe,variant:fe,className:(0,X.cn)(le),id:ee,label:$(be),value:Ie,onChange:Z=>{var W=et.find((W=>W.value===Z.target.value)).___rawValue;ae.available("onValueAssignment")||qe(W),ae("onChange",{value:W,prevValue:Ie})},options:et}):null},spinner:function Spinner(Z){var W=(0,Y.useStyle)(Z),[$,ee]=(0,Y.useClassList)(Z),[ae,ie]=(0,Y.useComponentDisplay)(Z),le=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:W,classList:{get:()=>$,set:Z=>ee(Z)},display:{get:()=>ae,set:Z=>ie(!!Z)},el:{get:()=>le.current}}),(0,Y.useComponentLifecycle)(Z),ae?ce.createElement("svg",{ref:le,className:(0,X.cn)("base-spinner",$),style:spinner_objectSpread(spinner_objectSpread({},W),{},{width:50,height:50})},ce.createElement("circle",{cx:"50%",cy:"50%",r:"40%",fill:"none",stroke:"currentColor",strokeWidth:3,strokeMiterlimit:10})):null},switch:function Switch(Z){var{node:W}=Z,$=(0,Y.useHandlerRunner)(Z),ee=(0,Y.useStyle)(Z),[ae,ie]=(0,Y.useClassList)(Z),[le,de]=(0,Y.useComponentDisplay)(Z),[pe,fe]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[ye,be]=(0,Y.useDynamicProperty)(Z,{handler:"onCheckedStateAssignment",forceDefault:!0,initialValue:()=>W.data.checked}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),Se=(0,Y.useElRef)();return(0,Y.useComponentRegister)(Z,{style:ee,classList:{get:()=>ae,set:Z=>ie(Z)},display:{get:()=>le,set:Z=>de(!!Z)},name:{get:()=>pe,set:fe},checked:{get:()=>ye,set:Z=>be(!!Z)},disabled:{get:()=>_e,set:Z=>we(!!Z)},el:{get:()=>Se.current}}),le?ce.createElement(Rt,{ref:Se,style:switch_objectSpread(switch_objectSpread({},ee),{},{display:"inline-flex",flexShrink:0}),className:(0,X.cn)(ae),checked:ye,disabled:_e,name:pe,onChange:Z=>{var W=Z.target.checked;$.available("onCheckedStateAssignment")||be(W),$("onChange",{event:Z,value:W})}}):null},text:function Text(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ae=(0,Y.useStyle)(Z),[ie,le]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onContentAssignment",initialValue:()=>W.data.content||ce.createElement(ce.Fragment,null,...(0,ee.uC)(W.children))}),[be,_e]=(0,Y.useMemo)((()=>{if("string"==typeof fe)return[{__html:sanitize($(fe))},null];if(null==fe)return[void 0,""];if(ce.isValidElement(fe))return[void 0,fe];if("number"==typeof fe)return[void 0,"".concat(fe)];try{return[void 0,JSON.stringify(fe)]}catch(Z){return console.warn("Can not stringify content, see the error below",{content:fe}),console.error(Z),[void 0,"TypeError: Converting circular structure to JSON"]}}),[fe,BackendlessUI.I18n.lang]),we=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ae,classList:{get:()=>ie,set:Z=>le(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},content:{get:()=>fe,set:ye},el:{get:()=>we.current}});var Se=(0,Y.useSimpleEventHandlers)(Z,["onClick","onMouseOver","onMouseOut"]);return de?ce.createElement(W.tagName,text_objectSpread({ref:we,className:(0,X.cn)(ie,"bl-text"),dangerouslySetInnerHTML:be,style:text_objectSpread({whiteSpace:"break-spaces"},ae)},Se),$(_e)):null},textarea:Textarea,video:function Video(Z){var{node:W}=Z,$=(0,Y.useStyle)(Z),[ee,ae]=(0,Y.useClassList)(Z),[ie,le]=(0,Y.useComponentDisplay)(Z),[de,pe]=(0,Y.useDynamicProperty)(Z,{handler:"onSourceAssignment",initialValue:()=>W.data.source}),[fe,ye]=(0,Y.useDynamicProperty)(Z,{handler:"onAutoplayAssignment",initialValue:()=>"true"===W.data.autoplay}),[be,_e]=(0,Y.useDynamicProperty)(Z,{handler:"onControlsAssignment",initialValue:()=>"true"===W.data.controls}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onLoopAssignment",initialValue:()=>"true"===W.data.loop}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onMuteAssignment",initialValue:()=>"true"===W.data.mute}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.playsinline}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{handler:"onBackgroundAssignment",initialValue:()=>"true"===W.data.background}),[Ve,ze]=(0,Y.useDynamicProperty)(Z,{handler:"onModestBrandingAssignment",initialValue:()=>"true"===W.data.modestBranding}),[We,He]=(0,Y.useDynamicProperty)(Z,{handler:"onShowRelatedAssignment",initialValue:()=>"true"===W.data.showRelated}),[Ye,Qe]=(0,Y.useDynamicProperty)(Z,{handler:"onNoCookieAssignment",initialValue:()=>"true"===W.data.noCookie}),[Xe,et]=(0,Y.useDynamicProperty)(Z,{handler:"onColorAssignment",initialValue:()=>W.data.color}),tt=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:$,classList:{get:()=>ee,set:Z=>ae(Z)},display:{get:()=>ie,set:Z=>le(!!Z)},source:{get:()=>de,set:pe},autoplay:{get:()=>fe,set:ye},controls:{get:()=>be,set:_e},playsInline:{get:()=>Re,set:Te},loop:{get:()=>we,set:Se},mute:{get:()=>xe,set:Pe},background:{get:()=>Ie,set:qe},modestBranding:{get:()=>Ve,set:ze},showRelated:{get:()=>We,set:He},noCookie:{get:()=>Ye,set:Qe},color:{get:()=>Xe,set:et},el:{get:()=>tt.current}}),(0,Y.useComponentLifecycle)(Z);var nt=function getProvider(Z){if(Z)for(var W of Nt)if(W.match(Z))return W}(de);if(!ie||!nt)return null;var rt={source:de,autoplay:fe,controls:be,playsInline:Re,loop:we,mute:xe,background:Ie,modestBranding:Ve,showRelated:We,noCookie:Ye,color:Xe};return ce.createElement("div",{ref:tt,className:(0,X.cn)(ee,"bl-video"),style:video_objectSpread({display:"flex",overflow:"hidden"},$)},ce.createElement(nt,rt))},slider:function Slider(Z){var{node:W}=Z,$=(0,Y.useHandlerRunner)(Z),ee=(0,Y.useStyle)(Z),[ae,ie]=(0,Y.useClassList)(Z),[le,de]=(0,Y.useComponentDisplay)(Z),[pe,fe]=(0,Y.useDynamicProperty)(Z,{handler:"onNameAssignment",initialValue:()=>W.data.name}),[ye,be]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.mode||"single"}),[_e,we]=(0,Y.useDynamicProperty)(Z,{handler:"onMinValueAssignment",initialValue:()=>toNumber(W.data.minValue,0)}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{handler:"onMaxValueAssignment",initialValue:()=>toNumber(W.data.maxValue,100)}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",forceDefault:!0,initialValue:()=>{if("range"===ye){if(!W.data.startValue||!W.data.endValue)return;return[ensureValue(W.data.startValue,{defaultValue:_e,minValue:_e,maxValue:Se}),ensureValue(W.data.endValue,{defaultValue:Se,minValue:_e,maxValue:Se})]}return ensureValue(W.data.value,{defaultValue:_e,minValue:_e,maxValue:Se})}}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>Math.abs(W.data.step)}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.valueLabelDisplay}),[ze,We]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.orientationVariant}),[He,Ye]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.marks}),[Qe,Xe]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),et=(0,Y.useElRef)(),tt=Se-_e,nt=ce.useMemo((()=>function isMarksVisible(Z,W,$,Y){if(!$||!Z||!W)return!1;return $/Wae,set:Z=>ie(Z)},display:{get:()=>le,set:Z=>de(!!Z)},name:{get:()=>pe,set:fe},value:{get:()=>Pe,set:Re},minValue:{get:()=>_e,set:we},maxValue:{get:()=>Se,set:xe},step:{get:()=>Te,set:Ie},valueLabelDisplay:{get:()=>qe,set:Ve},mode:{get:()=>ye,set:be},orientationVariant:{get:()=>ze,set:We},marks:{get:()=>He,set:Z=>Ye(!!Z)},disabled:{get:()=>Qe,set:Z=>Xe(!!Z)},el:{get:()=>et.current}});var rt=(0,Y.useMemo)((()=>"range"===ye?Array.isArray(Pe)?Pe:[_e,Se]:ensureValue(Pe,{defaultValue:_e,minValue:_e,maxValue:Se})),[ye,Pe,_e,Se]);return le?ce.createElement(Ut,{name:pe,disabled:Qe,onChange:(Z,W)=>{$.available("onValueAssignment")||Re(W),$("onChange",{event:Z,value:W,prevValue:rt})},valueLabelDisplay:qe,className:(0,X.cn)(ae),marks:nt,style:slider_objectSpread({},ee),value:rt,step:+Te||tt/100,ref:et,min:toNumber(_e,0),max:toNumber(Se,100),orientation:ze,valueLabelFormat:Z=>function nFormatter(Z){var W,$=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,Y=[{value:1,symbol:""},{value:1e3,symbol:"k"},{value:1e6,symbol:"M"},{value:1e9,symbol:"G"},{value:1e12,symbol:"T"},{value:1e15,symbol:"P"},{value:1e18,symbol:"E"}],X=/\.0+$|(\.[0-9]*[1-9])0+$/,ee=Math.sign(Z),ae=Z*ee;for(W=Y.length-1;W>0&&!(ae>=Y[W].value);W--);return(ae/Y[W].value).toFixed($).replace(X,"$1")*ee+Y[W].symbol}(Z)}):null},chip:function Chip(Z){var{node:W}=Z,$=(0,Y.useI18n)(W),ee=(0,Y.useStyle)(Z),[ae,ie]=(0,Y.useClassList)(Z),[le,pe]=(0,Y.useComponentDisplay)(Z),fe=(0,Y.useSimpleEventHandlers)(Z,["onClick","onDelete"]),[ye,be]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label||""}),[_e,we]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.variant}),[Se,xe]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),[Pe,Re]=(0,Y.useDynamicProperty)(Z,{handler:"onFrontIconAssignment",initialValue:()=>W.data.frontIcon}),[Te,Ie]=(0,Y.useDynamicProperty)(Z,{handler:"onDeleteIconAssignment",initialValue:()=>W.data.deleteIcon}),[qe,Ve]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),ze=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ee,classList:{get:()=>ae,set:Z=>ie(Z)},display:{get:()=>le,set:Z=>pe(!!Z)},disabled:{get:()=>qe,set:Z=>Ve(!!Z)},variant:{get:()=>_e,set:Z=>we(Z)},size:{get:()=>Se,set:Z=>xe(Z)},frontIcon:{get:()=>Pe,set:Re},deleteIcon:{get:()=>Te,set:Ie},el:{get:()=>ze.current},label:{get:()=>ye,set:Z=>be(Z)}});var We=useIconName(Pe),He=useIconName(Te||"cancel");if(!le)return null;var Ye=Pe&&createIconComponent(We,"front"),Qe=createIconComponent(He,"delete");return ce.createElement(de.Z.Chip,chip_objectSpread(chip_objectSpread({ref:ze,style:(0,X.j5)(ee),variant:_e,label:$(ye),size:Se,icon:Ye,id:W.id,className:(0,X.cn)(ae),classes:{root:"bl-chip",label:"bl-chip-label",outlined:"bl-chip--outlined",disabled:"bl-chip--disabled"},disabled:qe},fe),{},{deleteIcon:Qe}))},"color-picker":ColorPicker,"autocomplete-google-places":function autocomplete_google_places_AutocompleteGooglePlaces(Z){var{node:W}=Z,{googleApiKey:$}=BackendlessUI.getSettings(),X=(0,Y.useI18n)(W),ee=(0,Y.useUid)(),ae=(0,Y.useHandlerRunner)(Z),ie=(0,Y.useStyle)(Z),[le,ce]=(0,Y.useClassList)(Z),[de,pe]=(0,Y.useComponentDisplay)(Z),[fe,ye]=(0,Y.useDynamicProperty)(Z,{forceDefault:!0,initialValue:()=>W.data.variant||"standard"}),[be,_e]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.searchMode}),[we,Se]=(0,Y.useDynamicProperty)(Z,{handler:"onQueryPredictionsAssignment",initialValue:()=>null}),[xe,Pe]=(0,Y.useDynamicProperty)(Z,{handler:"onPlacesPredictionsAssignment",initialValue:()=>null}),[Re,Te]=(0,Y.useDynamicProperty)(Z,{handler:"onLabelAssignment",initialValue:()=>W.data.label}),[Ie,qe]=(0,Y.useDynamicProperty)(Z,{handler:"onValueAssignment",initialValue:()=>null}),[Ve,ze]=(0,Y.useDynamicProperty)(Z,{handler:"onPlaceholderAssignment",initialValue:()=>W.data.placeholder}),[We,He]=(0,Y.useDynamicProperty)(Z,{handler:"onReadOnlyStateAssignment",initialValue:()=>W.data.readonly}),[Ye,Qe]=(0,Y.useDynamicProperty)(Z,{handler:"onDisabledStateAssignment",initialValue:()=>W.data.disabled}),[Xe,et]=(0,Y.useDynamicProperty)(Z,{handler:"onRequiredStateAssignment",initialValue:()=>W.data.required}),[tt,nt]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>"true"===W.data.autofocus}),[rt,ot]=(0,Y.useDynamicProperty)(Z,{initialValue:()=>W.data.size}),at=(0,Y.useElRef)();(0,Y.useComponentRegister)(Z,{style:ie,classList:{get:()=>le,set:Z=>ce(Z)},display:{get:()=>de,set:Z=>pe(!!Z)},variant:{get:()=>fe,set:ye},value:{get:()=>Ie,set:qe},label:{get:()=>Re,set:Te},readOnly:{get:()=>We,set:Z=>He(!!Z)},disabled:{get:()=>Ye,set:Z=>Qe(!!Z)},required:{get:()=>Xe,set:Z=>et(!!Z)},autoFocus:{get:()=>tt,set:Z=>nt(!!Z)},el:{get:()=>at.current},focus:()=>at.current.focus(),size:{get:()=>rt,set:ot},placeholder:{get:()=>Ve,set:ze},searchMode:{get:()=>be,set:_e},placesPredictionsSettings:{get:()=>xe,set:Pe},queryPredictionsSettings:{get:()=>we,set:Se}}),(0,Y.useComponentLifecycle)(Z);var it=(0,Y.useSimpleEventHandlers)(Z,["onFocus","onBlur"]),ut=(0,Y.useCallback)((Z=>{ae.available("onValueAssignment")||qe(Z),ae("onChange",{event,value:Z,prevValue:Ie})}),[ae,qe,Ie]),lt=(0,Y.useCallback)((Z=>{var{altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X}=Z;ae("onKeyDown",{event:Z,altKey:W,ctrlKey:$,shiftKey:Y,keyCode:X})}),[ae]),ct=(0,Y.useLayoutEffectProperty)(Xe);return de?React.createElement(st.AutocompleteGooglePlaces,{searchMode:be,googleApiKey:$,onChange:ut,onKeyDown:lt,readOnly:We,size:rt,value:Ie,classList:le,variant:fe,style:ui_components_autocomplete_google_places_objectSpread({},ie),label:X(Re)||"",placeholder:X(Ve)||"",inputRef:at,id:ee,required:!!ct,disabled:!!Ye,autoFocus:!!tt,queryPredictionsSettings:we||{},placesPredictionsSettings:xe||{},simpleHandlers:it}):null},"view-data-grid":ViewDataGrid,"chart-visualization":ChartVisualization,"data-grid-visualization":DataGridVisualization,"calendar-visualization":CalendarVisualization,"layout-page-pod":function LayoutPagePOD(Z){var{componentContext:W}=Z,{pageComponent:$}=W,ee=(0,Y.useStyle)(Z),[ae]=(0,Y.useClassList)(Z);return React.createElement("div",{className:(0,X.cn)("bl-layout-page-pod",ae),style:(0,X.j5)(ee)},$)},"heat-map-visualization":HeatMapVisualization,"calendar-heatmap-visualization":CalendarHeatmapVisualization},Gt=Kt},39829:(Z,W,$)=>{"use strict";$.d(W,{h:()=>ReusableComponentInstance});var Y=$(16557),X=$(15746),ee=$(4781);function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _objectSpread(Z){for(var W=1;W_objectSpread(_objectSpread({},Z.componentContext),{},{rootComponentData:ee})),[Z.componentContext,ee]),ie=_objectSpread(_objectSpread({},Z),{},{componentContext:ae}),[le,ce]=(0,X.useComponentDisplay)(ie),de={display:{get:()=>le,set:Z=>ce(!!Z)}};return ee&&(de.dataStore=ee,de.setDataStore=Y),(0,X.useComponentRegister)(ie,de),(0,X.useComponentLifecycle)(ie),React.createElement(ReusableComponentClass,{node:W,componentContext:ie.componentContext,display:le})}function ReusableComponentClass(Z){var{node:W,componentContext:$,display:ee}=Z;return(0,X.useComponentLifecycle)(Z,{onBeforeMount:W.rootHandlers.onBeforeMount,onMounted:W.rootHandlers.onMounted,onBeforeUnmount:W.rootHandlers.onBeforeUnmount}),ee?(0,Y.uC)(W.children,{componentContext:$}):null}ReusableComponentInstance.resolve=function(Z){return(0,ee.GW)(this,Z,ee.zJ)}},34392:(Z,W)=>{W.W="\\.(mp4|webm|ogg|m3u8|ts|3gp|mov)$"},50066:(Z,W,$)=>{"use strict";$.d(W,{R0:()=>enrichWithSuffix,cn:()=>cn,j5:()=>normalizeStyle,sH:()=>ce});var Y=$(94184),X=$.n(Y);function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _defineProperty(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z}var ee=/^url\('?"?(.*?)'?"?\)$/i,ae=/.*\/~=~=~\//,ie=/[a-zA-Z%]+$/,le=["px","rem","em","%","cm","mm","in","pt","pc","vh","vw","ch","vmin","vmax"],ce={cn,normalizePropertyValue,normalizeDimensionValue:function normalizeDimensionValue(Z,W){return normalizePropertyValue(Z,le,W||"px")}};var de={backgroundImage(Z){var W=function resolveFileURL(Z){var W=ee.exec(Z),$=W&&W[1]||null;return $?$.replace(ae,"/"):$}(Z);return W?function toFileURL(Z){return Z?"url(".concat(Z,")"):"none"}(BackendlessUI.provideFileUrl(W)):Z}},pe=Object.keys(de);function normalizeStyle(Z){return Z=function _objectSpread(Z){for(var W=1;W{Z[W]&&(Z[W]=de[W](Z[W]))})),Z}function cn(){for(var Z=[],W=arguments.length,$=new Array(W),Y=0;Y{Array.isArray(W)?Z.push(...W):Z.push(W)})),X()(Z)||void 0}cn.mergeClasses=function(){for(var Z={},W=arguments.length,$=new Array(W),Y=0;Y{Object.keys(W||{}).forEach(($=>{Z[$]=cn(Z[$],W[$])}))})),Z};var addPrefixToItems=(Z,W)=>Z.map((Z=>Z&&"".concat(Z,"__").concat(W)));function enrichWithSuffix(Z,W){return Array.isArray(Z)?addPrefixToItems(Z,W):Z&&"string"==typeof Z?addPrefixToItems(Z.trim().split(" "),W).join(" "):""}function normalizePropertyValue(Z,W,$){if("string"==typeof Z&&Z){$||($=W[0]);var Y=parseFloat(Z),X=Z.match(ie);return X&&W.includes(X[0])?"".concat(Y).concat(X):"".concat(Y).concat($)}}},35327:(Z,W,$)=>{"use strict";function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _defineProperty(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z}$.d(W,{K:()=>DataStore});var Y=Symbol("isProxy"),X=Symbol("updateAt"),ee=Symbol("initedProxy"),ae=Symbol("contextProxy"),buildProxy=(Z,W)=>new Proxy(Z,{set:(Z,$,Y)=>(Z[$]!==Y&&(Z[$]=Y,W.onChange&&W.onChange("set",{property:$,value:Y})),!0),get(Z,$){if($===Y)return!0;if($===ae)return W;if($===X)return W.updateAt;var ie=Z[$];if($===ee)return ie;var le=ie&&ie[ee];if(le)return le;if(ie&&(Array.isArray(ie)||"object"==typeof ie&&ie.constructor===Object)){var ce=buildProxy(ie,W);return Object.defineProperty(ce,ee,{value:ce}),ce}return ie},deleteProperty:(Z,$)=>($ in Z&&(delete Z[$],W.onChange&&W.onChange("delete",{prop:$})),!0)});function DataStore(Z){var W={updateAt:Date.now(),listeners:[],addListener(Z){this.listeners.includes(Z)||this.listeners.push(Z)},removeListener(Z){this.listeners.includes(Z)&&this.listeners.splice(this.listeners.indexOf(Z),1)},onChange(Z,W){this.updateAt=Date.now(),this.listeners.forEach(($=>$(function _objectSpread(Z){for(var W=1;W!(!Z||!Z[Y]),DataStore.getUpdatedAt=Z=>Z&&Z[X],DataStore.getContext=Z=>Z&&Z[ae]},17788:(Z,W,$)=>{"use strict";$.d(W,{h:()=>isDataChanged});var Y=$(18446),X=$.n(Y);function isDataChanged(Z,W,$){if(typeof Z!=typeof W)return!0;if(Z===W)return!1;if(null===Z||null===W)return!0;if(Array.isArray(Z)&&Array.isArray(W)){if(Z.length!==W.length)return!0;for(var Y in Z)if(isDataChanged(Z[Y],W[Y],$))return!0;return!1}if(!$||!$.length)return!X()(Z,W);for(var ee=0;ee<$.length;ee++){var ae=$[ee];if(!X()(Z[ae],W[ae]))return!0}return!1}},15558:(Z,W,$)=>{"use strict";$.d(W,{E:()=>ie});var Y=new Date,X=Y.toLocaleDateString(),ee=Y.toLocaleDateString(),ae=Y.toLocaleString().replace(X,"").replace(ee,""),toTimestamp=Z=>{var W=new Date(Z);if(W.toLocaleString()===Z)return W.getTime()},isValid=Z=>!!toTimestamp(Z),combine=(Z,W)=>"".concat(Z).concat(ae).concat(W),ie={toTimestamp,isDateValid:Z=>isValid(combine(Z,ee)),isTimeValid:Z=>isValid(combine(ee,Z))}},40879:(Z,W,$)=>{"use strict";$.d(W,{K:()=>isMobileBrowser});var Y=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i,X=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i;function isMobileBrowser(){var Z=navigator.userAgent||navigator.vendor||window.opera;return Y.test(Z)||X.test(Z.substr(0,4))}},31828:(Z,W,$)=>{"use strict";$.d(W,{NM:()=>NotFoundPageError,nq:()=>NotFoundLayoutError,tY:()=>buildComponentError});var Y=$(16557);class NotFoundLayoutError extends Error{static wrap(Z){throw new NotFoundLayoutError(Z.message)}}class NotFoundPageError extends Error{static wrap(Z){throw new NotFoundPageError(Z.message)}}var buildComponentError=(Z,W)=>{var $,{handler:X}=W,ee=(0,Y.Qe)(Z),ae=['The error occurred in the "'.concat(ee,'" rendered by: ').concat(null===($=Z.parent)||void 0===$?void 0:$.renderCallstack),"Node UID: ".concat(Z.uid)];return X&&ae.push("Handler: ".concat(X)),ae.join("\n")}},82154:(Z,W,$)=>{"use strict";$.d(W,{v:()=>EventEmitter});class EventEmitter{constructor(){this.subsciptions={}}emit(Z,W){this.subsciptions[Z]&&this.subsciptions[Z].forEach((Z=>Z(W)))}on(Z,W){this.subsciptions[Z]=this.subsciptions[Z]||[],this.subsciptions[Z].push(W)}off(Z,W){this.subsciptions[Z]&&(this.subsciptions[Z]=W?this.subsciptions[Z].filter((Z=>Z!==W)):[],this.subsciptions[Z].length||delete this.subsciptions[Z])}count(Z){return this.subsciptions[Z]?this.subsciptions[Z].length:0}}},49561:(Z,W,$)=>{"use strict";$.d(W,{R:()=>ee});var Y=$(80504),X=$.n(Y),ee={generate:Z=>X()(Z)}},47323:(Z,W,$)=>{"use strict";$.d(W,{Z:()=>ae});var Y=$(5277),X=$.n(Y),ee=$(8327),ae={loadLibrary:Z=>Z?new Promise((W=>{X()(ee.j.ensureProtocol(Z),(()=>{W()}))})):Promise.reject(new Error('"url" argument must be a valid url'))}},16557:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{"use strict";__webpack_require__.d(__webpack_exports__,{$g:()=>enrichComponentTreeWithRenderCallstack,Qe:()=>getNodeDisplayName,X0:()=>prepareNodeChildren,uC:()=>renderNodes,x5:()=>enrichComponentTreeWithParents});var react__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(67294),hoist_non_react_statics__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(8679),hoist_non_react_statics__WEBPACK_IMPORTED_MODULE_1___default=__webpack_require__.n(hoist_non_react_statics__WEBPACK_IMPORTED_MODULE_1__),_string__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(78531),_uuid__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__(61800),_hash_sum__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__(49561),_settings__WEBPACK_IMPORTED_MODULE_5__=__webpack_require__(83884);function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _objectSpread(Z){for(var W=1;W"true"===Z,disabled:Z=>"true"===Z,readonly:Z=>"true"===Z,required:Z=>"true"===Z,raised:Z=>"true"===Z,unelevated:Z=>"true"===Z,outlined:Z=>"true"===Z,dense:Z=>"true"===Z};function prepareNode(Z,W){var $={context:Z=_objectSpread({},Z)};if(W.nodeType===document.TEXT_NODE)$.text=W.wholeText,"\n"===$.text&&($.text="");else if(W.nodeType===document.ELEMENT_NODE&&"SCRIPT"!==W.nodeName){var Y={},X={},ee={};Object.keys(W.dataset).forEach((Z=>{Z.startsWith("binding_")?ee[Z.replace("binding_","")]=W.dataset[Z]:X[Z]=AttrParsers[Z]?AttrParsers[Z](W.dataset[Z]):W.dataset[Z]})),W.getAttributeNames().filter((Z=>{"class"===Z||"style"===Z||Z.startsWith("data-")||(Y[Z]=W.getAttribute(Z))})),$.key=_uuid__WEBPACK_IMPORTED_MODULE_3__.h.short(),$.id=Y.id,$.uid=X.uid,$.moduleType=X.moduleType,$.moduleId=X.moduleId,!$.moduleId&&$.moduleType&&($.moduleId=$.moduleType,$.moduleType="system"),$.attrs=Y,$.style=composeNodeStyle(W),$.data=X,$.provideLogger=Z=>!Z||Z()?function(){return console.log(...arguments)}:()=>null,"true"===X.dynamicListBehaviour&&($.dynamicListBehaviour=!0),"true"===X.dataContainer&&($.dataContainer=!0),"true"===X.podContainer&&($.podContainer=!0),($.podContainer||"reusable"===$.moduleType||"custom"===$.moduleType)&&($.componentPath=Z.componentPath=Z.componentPath?"".concat(Z.componentPath,"/").concat($.uid):$.uid),$.hashSum=_hash_sum__WEBPACK_IMPORTED_MODULE_4__.R.generate($.componentPath||$.uid),$.dataBinding=ee;var ae=Array.prototype.slice.apply(W.classList);if($.classes={root:ae.join(" ")},$.tagName=W.tagName.toLowerCase(),"reusable"!==$.moduleType&&"custom"!==$.moduleType||parseNodePods(Z,$,W),$.podContainer){var ie=Z.pods[$.componentPath];$.children=null==ie?void 0:ie.children,$.podUID=null==ie?void 0:ie.podUID}else"reusable"===$.moduleType?$.children=prepareReusableComponentNodeChildren(Z,$):$.children=prepareNodeChildren(Z,W);if($.handlers=Z.requireHandlers($.uid)||{},$.moduleId){if($.Component=Z.requireComponent($),(0,_settings__WEBPACK_IMPORTED_MODULE_5__.a)($),!$.Component)throw new Error('Could not find "'.concat($.moduleType,'" module (').concat($.moduleId,")"));var le=$.Component,ce=le.displayName||le.name||"Component";if($.dataContainer&&(ce="".concat(ce," - DataContainer")),$.dynamicListBehaviour&&(ce="".concat(ce," - Repeater")),$.podContainer&&(ce="".concat(ce," - POD")),$.id&&(ce="".concat(ce,"(").concat($.id,")")),$.Component=function(Z){return React.createElement(le,Z)},$.Component.displayName="Node".concat(ce),$.Component.WrappedComponent=le,hoist_non_react_statics__WEBPACK_IMPORTED_MODULE_1___default()($.Component,le),"function"==typeof $.Component.normalize&&$.Component.normalize($),"function"==typeof $.Component.resolve&&($.Component=$.Component.resolve($)),"function"==typeof $.Component.getStaticClasses){var de=$.Component.getStaticClasses($);$.staticClasses="string"==typeof de?{root:de}:de}}delete $.attrs.id,delete $.data.uid,delete $.data.moduleType,delete $.data.moduleId,delete $.data.dynamicListBehaviour,delete $.data.dataContainer,delete $.data.podContainer}return $}var CSS_PROPERTIES_MAP={"overflow-y":"overflow","overflow-x":"overflow","background-repeat-y":"backgroundRepeat","background-repeat-x":"backgroundRepeat"};function composeNodeStyle(Z){for(var W={},$=0;$renderNode(Z,W,$))):[]}function enrichComponentTreeWithParents(Z){Array.isArray(Z.children)?Z.children.forEach((W=>{W.parent=Z,enrichComponentTreeWithParents(W)})):Z.children&&(Z.children.parent=Z,enrichComponentTreeWithParents(Z.children))}var getNodeDisplayName=Z=>Z.Component?Z.Component.displayName||Z.Component.name:Z.tagName;function enrichComponentTreeWithRenderCallstack(Z){Z.parent?Z.renderCallstack=getNodeDisplayName(Z)+" <- "+Z.parent.renderCallstack:Z.renderCallstack='Page "'.concat(Z.pageName,'"'),Array.isArray(Z.children)?Z.children.forEach(enrichComponentTreeWithRenderCallstack):Z.children&&enrichComponentTreeWithRenderCallstack(Z.children)}function renderNode(Z,W,$){return W=W||{},Z?Z.Component?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(Z.Component,_objectSpread({key:$,node:Z},W)):Z.tagName?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(Z.tagName,Object.assign({},Z.attrs,{style:Z.style,className:Z.classes.root||void 0}),...renderNodes(Z.children,{componentContext:W.componentContext})):Z.text||null:null}function parseNodePods(Z,W,$){if($&&$.childNodes&&$.childNodes.length)for(var Y=0;Y<$.childNodes.length;Y++){var X=$.childNodes[Y];if(X.nodeType===document.ELEMENT_NODE&&"SCRIPT"!==X.nodeName){var ee,ae=null==X||null===(ee=X.dataset)||void 0===ee?void 0:ee.podContext;if(ae){var ie="".concat(W.componentPath,"/").concat(ae);Z.pods[ie]={podUID:ae,children:prepareNodeChildren(_objectSpread(_objectSpread({},Z),{},{componentPath:ie}),X)}}}}}},63999:(Z,W,$)=>{"use strict";$.d(W,{L:()=>X});var Y=$(17563);function ownKeys(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function _objectSpread(Z){for(var W=1;W"string"==typeof Z?Z:Y.stringify(Z,W),parse(Z){var W=Y.parse(Z),$=Y.parse(Z,{parseNumbers:!0,parseBooleans:!0});for(var[X,ee]of Object.entries($))"number"==typeof ee&&W[X]!==String(ee)&&($[X]=W[X]);return $},excludeParams:(Z,W)=>Y.exclude(Z,W),appendParams(Z,W){var $=_objectSpread(_objectSpread({},X.parse(Z)),W);return Y.stringify($)}}},83884:(Z,W,$)=>{"use strict";function extendNode(Z){var W,{context:$,moduleId:X,moduleType:ee,Component:ae}=Z;if("reusable"===ee){var ie=$.resourcesManager.getReusableComponent(X);ie.extendNode(Z),W=ie.componentModel.settings||[]}else if("custom"===ee){var le=$.resourcesManager.getCustomComponent(Z.moduleId);le.extendNode(Z),W=le.model.settings||[]}else"system"===ee&&null!=ae&&ae.settings&&(W=ae.settings||[]);!function extendNodeSettings(Z){var{node:W,settings:$}=Z,X=W.context.resourcesManager.appConfig.componentsSettings[W.moduleId];W.settings={},Array.isArray($)&&$.forEach((Z=>{W.settings[Z.name]=void 0===(null==X?void 0:X[Z.name])?Z.defaultValue:X[Z.name],Y[Z.type]&&(W.settings[Z.name]=Y[Z.type](W.settings[Z.name]))}))}({node:Z,settings:W})}$.d(W,{a:()=>extendNode});var Y={number:function number(Z){var W=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Number";if("number"==typeof Z)return Z;if(""===Z||void 0===Z)return null;var $=Number(Z);if(!isNaN($))return $;BackendlessUI.logger.error('Can not cast to "'.concat(W,'" type the following component setting value "').concat(Z,'"'))},range:Z=>Y.number(Z,"Range"),json:Z=>{try{if(Z)return JSON.parse(Z)}catch(W){BackendlessUI.logger.error('Can not parse JSON setting value "'.concat(Z,'"'))}}}},78531:(Z,W,$)=>{"use strict";$.d(W,{x:()=>Y});var Y={snakeToCamel:Z=>Z.replace(/(-\w)/g,(Z=>Z[1].toUpperCase())),capitalizeFirstLetter:Z=>Z.charAt(0).toUpperCase()+Z.slice(1),pluralize(Z,W){return 1===W?Z:Z+(arguments.length>2&&void 0!==arguments[2]?arguments[2]:"s")}}},8327:(Z,W,$)=>{"use strict";$.d(W,{j:()=>X});var Y=$(63999),resolveLocalProtocol=()=>!location.protocol||"https:"!==location.protocol&&"http:"!==location.protocol?"https:":location.protocol,X={ensureProtocol:Z=>(Z=>["https://","http://","//"].some((W=>Z.startsWith(W))))(Z)?Z.startsWith("//")?"".concat(resolveLocalProtocol()).concat(Z):Z:"".concat(resolveLocalProtocol(),"//").concat(Z),appendParams:(Z,W)=>{var $=(Z=new URL(Z)).href.split("?")[0],X=Z.search,ee=Y.L.appendParams(X,W);return"".concat($,"?").concat(ee)}}},61800:(Z,W,$)=>{"use strict";$.d(W,{h:()=>Y});var chr4=()=>Math.random().toString(16).slice(-4),chr8=()=>"".concat(chr4()).concat(chr4()),Y={micro:()=>chr4(),mini:()=>chr8(),short:()=>"".concat(chr8()).concat(chr8()).concat(chr8()).concat(chr8()),long:()=>"".concat(chr8(),"-").concat(chr4(),"-").concat(chr4(),"-").concat(chr4(),"-").concat(chr8()).concat(chr4())}},41638:(Z,W)=>{var $,Y,X,ee;self,ee=()=>(()=>{var ee={6129:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(9853)),ce=function(){function e(Z){(0,ae.default)(this,e),this.app=Z}var Z,W,$,Y;return(0,ie.default)(e,[{key:"activateFlow",value:(Y=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error('The "flowName" argument must be provided and must be a string.');case 2:if(void 0===W||le.default.isObject(W)){$.next=4;break}throw new Error('The "initialData" argument must be an object.');case 4:return $.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.automationFlow(),"/activate-by-name"),data:{name:Z,initialData:W}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,W){return Y.apply(this,arguments)})},{key:"activateFlowById",value:($=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error('The "flowId" argument must be provided and must be a string.');case 2:if(void 0===W||le.default.isObject(W)){$.next=4;break}throw new Error('The "initialData" argument must be an object.');case 4:return $.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.automationFlow(),"/").concat(Z,"/activate"),data:W||{}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,W){return $.apply(this,arguments)})},{key:"activateFlowTrigger",value:(W=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error('The "flowName" argument must be provided and must be a string.');case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error('The "triggerName" argument must be provided and must be a string.');case 4:if(void 0===$||le.default.isObject($)){Y.next=6;break}throw new Error('The "data" argument must be an object.');case 6:return Y.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.automationFlowTrigger(),"/activate-by-name"),query:{flowName:Z,triggerName:W},data:$||{}}));case 7:case"end":return Y.stop()}}),e,this)}))),function(Z,$,Y){return W.apply(this,arguments)})},{key:"activateFlowTriggerById",value:(Z=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error('The "flowId" argument must be provided and must be a string.');case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error('The "triggerId" argument must be provided and must be a string.');case 4:if(void 0===$||le.default.isObject($)){Y.next=6;break}throw new Error('The "data" argument must be an object.');case 6:return Y.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.automationFlow(),"/").concat(Z,"/trigger/").concat(W,"/activate"),data:$||{}}));case 7:case"end":return Y.stop()}}),e,this)}))),function(W,$,Y){return Z.apply(this,arguments)})}]),e}();W.Z=ce},8435:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.isExecutionType=W.ExecutionTypes=W.EXECUTION_TYPE_HEADER=void 0,W.EXECUTION_TYPE_HEADER="bl-execution-type";var $={SYNC:"sync",ASYNC:"async",ASYNC_LOW_PRIORITY:"async-low-priority"};W.ExecutionTypes=$;var Y=Object.keys($).map((function(Z){return $[Z]}));W.isExecutionType=function(Z){return Y.includes(Z)}},9589:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(4687)),ee=Y($(8416)),ae=Y($(7156)),ie=Y($(6690)),le=Y($(9728)),ce=$(8435);function l(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function f(Z){for(var W=1;W{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(4687)),ee=Y($(8698)),ae=Y($(7156)),ie=Y($(6690)),le=Y($(9728)),ce=$(8435),de=function(){function e(Z){(0,ie.default)(this,e),this.app=Z}var Z;return(0,le.default)(e,[{key:"dispatch",value:(Z=(0,ae.default)(X.default.mark((function e(Z,W,$){var Y;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error("Event Name must be provided and must be a string.");case 2:if("string"==typeof W&&(0,ce.isExecutionType)(W)&&($=W,W=void 0),!W||"object"===(0,ee.default)(W)&&!Array.isArray(W)){X.next=5;break}throw new Error("Event Arguments must be an object.");case 5:return Y={},$&&(Y[ce.EXECUTION_TYPE_HEADER]=$),X.abrupt("return",this.app.request.post({url:this.app.urls.blEvent(Z),data:W||{},headers:Y}));case 8:case"end":return X.stop()}}),e,this)}))),function(W,$,Y){return Z.apply(this,arguments)})}]),e}();W.default=de},6912:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=$(8435),ie=Y($(9589)),le=Y($(3084)),ce=(0,X.default)((function e(Z){(0,ee.default)(this,e),this.app=Z,this.ExecutionTypes=ae.ExecutionTypes,this.CustomServices=new ie.default(Z),this.Events=new le.default(Z)}));W.Z=ce},8469:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(9853)),ce=function(){function e(Z){(0,ae.default)(this,e),this.app=Z,this.parsers={}}var Z,W,$,Y,ce,de;return(0,ie.default)(e,[{key:"setObjectFactory",value:function(Z,W){this.parsers[Z]=W}},{key:"parseItem",value:function(Z){var W=Z&&Z.___class;if(W){var $=this.parsers[W];$&&(Z=new $(Z))}return Z}},{key:"stringifyItem",value:function(Z){return le.default.isCustomClassInstance(Z)&&(Z.___class=Z.___class||le.default.getClassName(Z)),JSON.stringify(Z)}},{key:"put",value:(de=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:if(!$||!("number"!=typeof $||$<0)){Y.next=4;break}throw new Error("Cache TimeToLive must be a positive number.");case 4:return Y.abrupt("return",this.app.request.put({url:this.app.urls.cacheItem(Z),query:{timeout:$},headers:{"Content-Type":"application/json"},data:this.stringifyItem(W)}));case 5:case"end":return Y.stop()}}),e,this)}))),function(Z,W,$){return de.apply(this,arguments)})},{key:"get",value:(ce=(0,ee.default)(X.default.mark((function e(Z){var W=this;return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:return $.abrupt("return",this.app.request.get({url:this.app.urls.cacheItem(Z)}).then((function(Z){return W.parseItem(Z)})));case 3:case"end":return $.stop()}}),e,this)}))),function(Z){return ce.apply(this,arguments)})},{key:"remove",value:(Y=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.delete({url:this.app.urls.cacheItem(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return Y.apply(this,arguments)})},{key:"contains",value:($=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.get({url:this.app.urls.cacheItemCheck(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return $.apply(this,arguments)})},{key:"expireIn",value:(W=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:if(!("number"!=typeof W||W<=0)){$.next=4;break}throw new Error("Cache Expiration must be provided and must be a number of seconds.");case 4:return $.abrupt("return",this.app.request.put({url:this.app.urls.cacheItemExpireIn(Z),query:{timeout:W},data:{}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,$){return W.apply(this,arguments)})},{key:"expireAt",value:(Z=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error("Cache Key must be provided and must be a string.");case 2:if(!(W instanceof Date)){$.next=6;break}W=W.getTime(),$.next=8;break;case 6:if(!("number"!=typeof W||W<=0)){$.next=8;break}throw new Error("Cache Expiration must be provided and must be a timestamp or an instance of Date.");case 8:return $.abrupt("return",this.app.request.put({url:this.app.urls.cacheItemExpireAt(Z),query:{timestamp:W},data:{}}));case 9:case"end":return $.stop()}}),e,this)}))),function(W,$){return Z.apply(this,arguments)})}]),e}();W.Z=ce},5165:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=function(){function e(Z){(0,ae.default)(this,e),this.app=Z}var Z,W,$;return(0,ie.default)(e,[{key:"validatePlayPurchase",value:($=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Package Name must be provided and must be a string.");case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error("Product Id must be provided and must be a string.");case 4:if($&&"string"==typeof $){Y.next=6;break}throw new Error("Token must be provided and must be a string.");case 6:return Y.abrupt("return",this.app.request.get({url:this.app.urls.commerceValidate(Z,W,$)}));case 7:case"end":return Y.stop()}}),e,this)}))),function(Z,W,Y){return $.apply(this,arguments)})},{key:"cancelPlaySubscription",value:(W=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Package Name must be provided and must be a string.");case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error("Subscription Id must be provided and must be a string.");case 4:if($&&"string"==typeof $){Y.next=6;break}throw new Error("Token must be provided and must be a string.");case 6:return Y.abrupt("return",this.app.request.post({url:this.app.urls.commerceSubCancel(Z,W,$)}));case 7:case"end":return Y.stop()}}),e,this)}))),function(Z,$,Y){return W.apply(this,arguments)})},{key:"getPlaySubscriptionStatus",value:(Z=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Package Name must be provided and must be a string.");case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error("Subscription Id must be provided and must be a string.");case 4:if($&&"string"==typeof $){Y.next=6;break}throw new Error("Token must be provided and must be a string.");case 6:return Y.abrupt("return",this.app.request.get({url:this.app.urls.commerceSubStatus(Z,W,$)}));case 7:case"end":return Y.stop()}}),e,this)}))),function(W,$,Y){return Z.apply(this,arguments)})}]),e}();W.Z=le},5921:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z,W){if((0,X.default)(this,e),!Z||"string"!=typeof Z)throw new Error("Counter Name must be non empty String");this.name=Z,this.counters=W}return(0,ee.default)(e,[{key:"incrementAndGet",value:function(){return this.counters.incrementAndGet(this.name)}},{key:"getAndIncrement",value:function(){return this.counters.getAndIncrement(this.name)}},{key:"decrementAndGet",value:function(){return this.counters.decrementAndGet(this.name)}},{key:"getAndDecrement",value:function(){return this.counters.getAndDecrement(this.name)}},{key:"reset",value:function(){return this.counters.reset(this.name)}},{key:"get",value:function(){return this.counters.get(this.name)}},{key:"addAndGet",value:function(Z){return this.counters.addAndGet(this.name,Z)}},{key:"getAndAdd",value:function(Z){return this.counters.getAndAdd(this.name,Z)}},{key:"compareAndSet",value:function(Z,W){return this.counters.compareAndSet(this.name,Z,W)}}]),e}();W.default=ae},1062:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(5921)),ce=function(){function e(Z){(0,ae.default)(this,e),this.app=Z}var Z,W,$,Y,ce,de,pe,fe,ye,be;return(0,ie.default)(e,[{key:"of",value:function(Z){return new le.default(Z,this)}},{key:"list",value:(be=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(null==Z||"string"==typeof Z){W.next=2;break}throw new Error("Counters Pattern can be a string only");case 2:return W.abrupt("return",this.app.request.get({url:this.app.urls.countersList(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return be.apply(this,arguments)})},{key:"incrementAndGet",value:(ye=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.put({url:this.app.urls.counterIncrementAndGet(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return ye.apply(this,arguments)})},{key:"getAndIncrement",value:(fe=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.put({url:this.app.urls.counterGetAndIncrement(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return fe.apply(this,arguments)})},{key:"decrementAndGet",value:(pe=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.put({url:this.app.urls.counterDecrementAndGet(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return pe.apply(this,arguments)})},{key:"getAndDecrement",value:(de=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.put({url:this.app.urls.counterGetAndDecrement(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return de.apply(this,arguments)})},{key:"reset",value:(ce=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.put({url:this.app.urls.counterReset(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return ce.apply(this,arguments)})},{key:"get",value:(Y=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.get({url:this.app.urls.counter(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return Y.apply(this,arguments)})},{key:"addAndGet",value:($=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:if("number"==typeof W){$.next=4;break}throw new Error("Counter Value must be a number.");case 4:return $.abrupt("return",this.app.request.put({url:this.app.urls.counterAddAndGet(Z),query:{value:W}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,W){return $.apply(this,arguments)})},{key:"getAndAdd",value:(W=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:if("number"==typeof W){$.next=4;break}throw new Error("Counter Value must be a number.");case 4:return $.abrupt("return",this.app.request.put({url:this.app.urls.counterGetAndAdd(Z),query:{value:W}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,$){return W.apply(this,arguments)})},{key:"compareAndSet",value:(Z=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Counter Name must be provided and must be a string.");case 2:if("number"==typeof W){Y.next=4;break}throw new Error("Counter Expected Value must be a number.");case 4:if("number"==typeof $){Y.next=6;break}throw new Error("Counter Updated Value must be a number.");case 6:return Y.abrupt("return",this.app.request.put({url:this.app.urls.counterCompareAndSet(Z),query:{expected:W,updatedvalue:$}}));case 7:case"end":return Y.stop()}}),e,this)}))),function(W,$,Y){return Z.apply(this,arguments)})}]),e}();W.Z=ce},3082:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=W.PAGING_DEFAULTS=void 0;var X=Y($(8416)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(9853));function u(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}var le={pageSize:10,offset:0};W.PAGING_DEFAULTS=le;var ce=function(){function e(){(0,ee.default)(this,e),this.offset=le.offset,this.pageSize=le.pageSize,this.sortBy=null,this.groupBy=null,this.properties=null,this.excludeProps=null,this.whereClause=null,this.havingClause=null,this.relations=null,this.relationsDepth=null,this.relationsPageSize=null,this.distinct=!1}return(0,ae.default)(e,[{key:"setPageSize",value:function(Z){if(Z<=0)throw new Error("Page size must be a positive value.");return this.pageSize=Z,this}},{key:"getPageSize",value:function(){return this.pageSize}},{key:"setOffset",value:function(Z){if(Z<0)throw new Error("Offset cannot have a negative value.");return this.offset=Z,this}},{key:"getOffset",value:function(){return this.offset}},{key:"prepareNextPage",value:function(){return this.setOffset(this.offset+this.pageSize),this}},{key:"preparePreviousPage",value:function(){return this.setOffset(Math.max(this.offset-this.pageSize,0)),this}},{key:"getProperties",value:function(){return this.properties}},{key:"setProperties",value:function(Z){return this.properties=ie.default.castArray(Z),this}},{key:"addProperty",value:function(Z){return this.properties=this.properties||[],this.properties.push(Z),this}},{key:"addProperties",value:function(){for(var Z=this,W=arguments.length,$=new Array(W),Y=0;Y0&&W.push("pageSize=".concat(Z.pageSize)),Z.offset>0&&W.push("offset=".concat(Z.offset)),Array.isArray(Z.properties)&&Z.properties.length&&Z.properties.map((function(Z){W.push("property=".concat(encodeURIComponent(Z)))})),Array.isArray(Z.excludeProps)&&Z.excludeProps.length&&W.push("excludeProps=".concat(f(Z.excludeProps))),Z.where&&W.push("where=".concat(encodeURIComponent(Z.where))),Z.having&&W.push("having=".concat(encodeURIComponent(Z.having))),Z.sortBy&&W.push(Array.isArray(Z.sortBy)?"sortBy=".concat(f(Z.sortBy)):"sortBy=".concat(encodeURIComponent(Z.sortBy))),Z.groupBy&&W.push(Array.isArray(Z.groupBy)?"groupBy=".concat(f(Z.groupBy)):"groupBy=".concat(encodeURIComponent(Z.groupBy))),Array.isArray(Z.relations)&&W.push(Z.relations.length?"loadRelations=".concat(f(Z.relations)):"loadRelations=*"),Z.relationsDepth>0&&W.push("relationsDepth=".concat(Z.relationsDepth)),Z.relationsPageSize>0&&W.push("relationsPageSize=".concat(Z.relationsPageSize)),Z.distinct&&W.push("distinct=".concat(Z.distinct)),Z.fileReferencePrefix&&W.push("fileReferencePrefix=".concat(encodeURIComponent(Z.fileReferencePrefix))),W.join("&")}}}]),e}();function f(Z){return Z.map((function(Z){return encodeURIComponent(Z)})).join(",")}W.default=ce},8461:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.GeoTypes=void 0,W.GeoTypes={POINT:"Point",LINE_STRING:"LineString",POLYGON:"Polygon"}},7130:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.GEO_CLASSES=void 0,W.default=function(Z,W){var $=ye[Z.type];if(W=W||fe.default.valueBySRSId(Z.srsId),$)return $(Z.coordinates,W);throw new Error("There is no constructor for ".concat(Z.type))};var X,ee=Y($(8416)),ae=Y($(1589)),ie=Y($(7424)),le=Y($(679)),ce=Y($(3228)),de=Y($(2253)),pe=$(8461),fe=Y($(5599));W.GEO_CLASSES=["com.backendless.persistence.Polygon","com.backendless.persistence.LineString","com.backendless.persistence.Point","com.backendless.persistence.Geometry"];var d=function(Z,W){var $=(0,ie.default)(Z,2),Y=$[0],X=$[1];return new le.default(W).setX(Y).setY(X)},h=function(Z,W){var $=Z.map((function(Z){return d(Z,W)}));return new ce.default($,W)},ye=(X={},(0,ee.default)(X,pe.GeoTypes.POINT,d),(0,ee.default)(X,pe.GeoTypes.LINE_STRING,h),(0,ee.default)(X,pe.GeoTypes.POLYGON,(function(Z,W){var $=Z.map((function(Z){return h(Z,W)})),Y=(0,ae.default)($),X=Y[0],ee=Y.slice(1);return new de.default(X,ee,W)})),X)},1738:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(7130)),ie=function(){function e(Z){(0,X.default)(this,e),this.srs=Z}return(0,ee.default)(e,[{key:"read",value:function(Z){return(0,ae.default)(Z,this.srs)}}]),e}();W.default=ie},7705:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(5599)),ie=Y($(1738)),le=Y($(8048)),ce=function(){function e(Z){(0,X.default)(this,e),this.srs=Z||ae.default.DEFAULT}return(0,ee.default)(e,[{key:"getSRS",value:function(){return this.srs}},{key:"getGeojsonType",value:function(){}},{key:"getWktType",value:function(){}},{key:"wktCoordinatePairs",value:function(){}},{key:"jsonCoordinatePairs",value:function(){}},{key:"asGeoJSON",value:function(){return{type:this.getGeojsonType(),coordinates:this.jsonCoordinatePairs()}}},{key:"asWKT",value:function(){return this.getWktType()+"("+this.wktCoordinatePairs()+")"}},{key:"toJSON",value:function(){return this.asGeoJSON()}},{key:"toString",value:function(){return"'"+this.asWKT()+"'"}}],[{key:"fromWKT",value:function(Z,W){return new le.default(W).read(Z)}},{key:"fromGeoJSON",value:function(Z,W){return new ie.default(W).read(Z)}}]),e}();W.default=ce},3228:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(7705)),de=$(8461).GeoTypes.LINE_STRING,pe=de.toUpperCase(),fe=function(Z){(0,ae.default)(r,Z);var W=function l(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(Z,$){var Y;return(0,X.default)(this,r),(Y=W.call(this,$)).points=Z||[],Y}return(0,ee.default)(r,[{key:"getPoints",value:function(){return this.points}},{key:"setPoints",value:function(Z){return this.points=Z,this}},{key:"getGeojsonType",value:function(){return de}},{key:"getWktType",value:function(){return pe}},{key:"jsonCoordinatePairs",value:function(){var Z=[];return this.getPoints().forEach((function(W){Z.push([W.getX(),W.getY()])})),Z}},{key:"wktCoordinatePairs",value:function(){return this.getPoints().map((function(Z){return"".concat(Z.getX()," ").concat(Z.getY())})).join(",")}}]),r}(ce.default);W.default=fe},679:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(7705)),de=$(8461).GeoTypes.POINT,pe=de.toUpperCase(),fe=function(Z){(0,ae.default)(r,Z);var W=function l(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(Z){return(0,X.default)(this,r),W.call(this,Z)}return(0,ee.default)(r,[{key:"lng",get:function(){return this.getLongitude()},set:function(Z){this.setLongitude(Z)}},{key:"lat",get:function(){return this.getLatitude()},set:function(Z){this.setLatitude(Z)}},{key:"getX",value:function(){return this.x}},{key:"getY",value:function(){return this.y}},{key:"getLongitude",value:function(){return this.x}},{key:"getLatitude",value:function(){return this.y}},{key:"setX",value:function(Z){return this.x=Z,this}},{key:"setY",value:function(Z){return this.y=Z,this}},{key:"setLongitude",value:function(Z){return this.setX(Z)}},{key:"setLatitude",value:function(Z){return this.setY(Z)}},{key:"getGeojsonType",value:function(){return de}},{key:"getWktType",value:function(){return pe}},{key:"wktCoordinatePairs",value:function(){return"".concat(this.x," ").concat(this.y)}},{key:"jsonCoordinatePairs",value:function(){return[this.x,this.y]}},{key:"equals",value:function(Z){return this===Z||Z instanceof r&&Math.abs(Z.x-this.x)<1e-9&&Math.abs(Z.y-this.y)<1e-9&&this.srs===Z.srs}}]),r}(ce.default);W.default=fe},2253:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(861)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=Y($(7705)),pe=Y($(3228)),fe=$(8461).GeoTypes.POLYGON,ye=fe.toUpperCase(),be=function(Z){(0,ie.default)(r,Z);var W=function p(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,ce.default)(Z);if(W){var X=(0,ce.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,le.default)(this,$)}}(r);function r(Z,$,Y){var X;return(0,ee.default)(this,r),(X=W.call(this,Y)).setBoundary(Z),X.setHoles($),X}return(0,ae.default)(r,[{key:"getBoundary",value:function(){return this.boundary}},{key:"setBoundary",value:function(Z){if(!Z)throw new Error("The 'boundary' argument is required.");return Z instanceof pe.default||(Z=new pe.default(Z,this.srs)),this.boundary=Z,this}},{key:"getHoles",value:function(){return this.holes}},{key:"setHoles",value:function(Z){return this.holes=Z||[],this}},{key:"getGeojsonType",value:function(){return fe}},{key:"getWktType",value:function(){return ye}},{key:"jsonCoordinatePairs",value:function(){var Z=[];this.getBoundary().getPoints().forEach((function(W){Z.push([W.getX(),W.getY()])}));var W=this.holes.map((function(Z){return Z.getPoints().map((function(Z){return[Z.getX(),Z.getY()]}))}));return[Z].concat((0,X.default)(W))}},{key:"wktCoordinatePairs",value:function(){var Z=[this.getBoundary().wktCoordinatePairs()];return this.holes.forEach((function(W){return Z.push(W.wktCoordinatePairs())})),Z.map((function(Z){return"("+Z+")"})).join(",")}}]),r}(de.default);W.default=be},5599:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z){var W=Z.srsId,$=Z.name;(0,X.default)(this,e),this.srsId=W,this.name=$}return(0,ee.default)(e,[{key:"getSRSId",value:function(){return this.srsId}},{key:"getName",value:function(){return this.name}},{key:"toString",value:function(){return this.getName()+"("+this.getSRSId()+")"}}]),e}(),ie=new ae({srsId:0,name:"Cartesian"}),le=new ae({srsId:4200,name:"Pulkovo 1995"}),ce=new ae({srsId:4326,name:"WGS 84"}),de={CARTESIAN:ie,PULKOVO_1995:le,WGS84:ce,WGS84_PSEUDO_MERCATOR:new ae({srsId:3857,name:"WGS 84 / Pseudo-Mercator"}),WGS84_WORLD_MERCATOR:new ae({srsId:3395,name:"WGS 84 / World Mercator"}),DEFAULT:ce,SRS_MAP:{},valueBySRSId:function(Z){return de.SRS_MAP[Z]}};Object.keys(de).forEach((function(Z){if(de[Z]instanceof ae){var W=de[Z];de.SRS_MAP[W.getSRSId()]=W}}));var pe=de;W.default=pe},8048:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(3734)),ie=Y($(7130)),le=function(){function e(Z){(0,X.default)(this,e),this.srs=Z}return(0,ee.default)(e,[{key:"read",value:function(Z){var W=(0,ae.default)(Z);if(!W)throw new Error("WKT string is invalid");return(0,ie.default)(W,this.srs)}}]),e}();W.default=le},3734:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(861)),ee=$(8461),ae=/[-+]?([0-9]*\.[0-9]+|[0-9]+)([eE][-+]?[0-9]+)?/,ie=new RegExp("^"+ae.source+"(\\s"+ae.source+"){1,}");W.default=function(Z){var W=0,r=function($){var Y=Z.substring(W).match($);return Y?(W+=Y[0].length,Y[0]):null},n=function(){return r(/^\s*/)},i=function(){for(var Z,W,$=[];W=r(ie)||r(/^(,)/);)","===W?($.push(Z),Z=[]):W.split(/\s/g).some(isNaN)||(Z||(Z=[]),Z=[].concat((0,X.default)(Z),(0,X.default)(W.split(/\s/g).map(parseFloat)))),n();return Z?($.push(Z),$.length?$:null):null};return function(){if(!r(/^(point(\sz)?)/i))return null;if(n(),!r(/^(\()/))return null;n();var Z=i();return Z&&r(/^(\))/)?{type:ee.GeoTypes.POINT,coordinates:Z[0]}:null}()||function(){if(!r(/^(linestring(\sz)?)/i))return null;if(n(),!r(/^(\()/))return null;var Z=i();return Z&&r(/^(\))/)?{type:ee.GeoTypes.LINE_STRING,coordinates:Z}:null}()||function(){if(!r(/^(polygon(\sz)?)/i))return null;n();var Z=function(){n();for(var Z,W=0,$=[],Y=[$],X=$;Z=r(/^(\()/)||r(/^(\))/)||r(/^(,)/)||r(ie);){if("("===Z)Y.push(X),X=[],Y[Y.length-1].push(X),W++;else if(")"===Z){if(0===X.length)return null;if(!(X=Y.pop()))return null;if(0==--W)break}else if(","===Z)X=[],Y[Y.length-1].push(X);else{if(Z.split(/\s/g).some(isNaN))return null;Array.prototype.push.apply(X,Z.split(/\s/g).map(parseFloat))}n()}return 0!==W?null:$}();return Z?{type:ee.GeoTypes.POLYGON,coordinates:Z}:null}()}},6820:(Z,W,$)=>{"use strict";var Y=$(4836),X=$(8698);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var ee=Y($(6690)),ae=Y($(9728)),ie=Y($(1588)),le=Y($(1655)),ce=Y($(4993)),de=Y($(3808)),pe=Y($(9853)),fe=function(Z,W){if(Z&&Z.__esModule)return Z;if(null===Z||"object"!==X(Z)&&"function"!=typeof Z)return{default:Z};var $=d(W);if($&&$.has(Z))return $.get(Z);var Y={},ee=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ae in Z)if("default"!==ae&&Object.prototype.hasOwnProperty.call(Z,ae)){var ie=ee?Object.getOwnPropertyDescriptor(Z,ae):null;ie&&(ie.get||ie.set)?Object.defineProperty(Y,ae,ie):Y[ae]=Z[ae]}return Y.default=Z,$&&$.set(Z,Y),Y}($(3082));function d(Z){if("function"!=typeof WeakMap)return null;var W=new WeakMap,$=new WeakMap;return(d=function(Z){return Z?$:W})(Z)}var ye=function(Z){(0,le.default)(r,Z);var W=function h(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,de.default)(Z);if(W){var X=(0,de.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ce.default)(this,$)}}(r);function r(){var Z;return(0,ee.default)(this,r),(Z=W.call(this)).groupPageSize=fe.PAGING_DEFAULTS.pageSize,Z.recordsPageSize=fe.PAGING_DEFAULTS.pageSize,Z.groupDepth=null,Z.groupPath=null,Z}return(0,ae.default)(r,[{key:"setGroupPageSize",value:function(Z){if(Z<=0)throw new Error("Group page size must be a positive value.");return this.groupPageSize=Z,this}},{key:"getGroupPageSize",value:function(){return this.groupPageSize}},{key:"setRecordsPageSize",value:function(Z){if(Z<=0)throw new Error("Records page size must be a positive value.");return this.recordsPageSize=Z,this}},{key:"getRecordsPageSize",value:function(){return this.recordsPageSize}},{key:"setGroupDepth",value:function(Z){if(Z<0)throw new Error("Group depth cannot have a negative value.");return this.groupDepth=Z,this}},{key:"getGroupDepth",value:function(){return this.groupDepth}},{key:"getGroupPath",value:function(){return this.groupPath}},{key:"addGroupPath",value:function(Z){return this.groupPath=(this.groupPath||[]).concat(Z),this}},{key:"setGroupPath",value:function(Z){return this.groupPath=pe.default.castArray(Z),this}},{key:"toJSON",value:function(){var Z=(0,ie.default)((0,de.default)(r.prototype),"toJSON",this).call(this);return Z.groupDepth=this.getGroupDepth(),Z.groupPath=this.getGroupPath(),Z.groupPageSize=this.getGroupPageSize(),Z.recordsPageSize=this.getRecordsPageSize(),Z}}]),r}(fe.default);W.default=ye},7607:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(8416)),ie=Y($(6690)),le=Y($(9728)),ce=Y($(9853)),de=Y($(5602)),pe=Y($(9540)),fe=Y($(3082)),ye=Y($(6820)),be=Y($(3198)),_e=Y($(2496)),we=Y($(679)),Se=Y($(3228)),xe=Y($(2253)),Pe=Y($(7705)),Re=Y($(5599)),Te=Y($(8048)),Ie=Y($(1738)),qe=Y($(6064)),Ve=function(){function e(Z){(0,ie.default)(this,e),this.app=Z,this.classToTableMap=(0,ae.default)({},de.default.className,de.default),this.Permissions={FIND:new qe.default("FIND",Z),REMOVE:new qe.default("REMOVE",Z),UPDATE:new qe.default("UPDATE",Z)},this.QueryBuilder=fe.default,this.GroupQueryBuilder=ye.default,this.LoadRelationsQueryBuilder=be.default,this.JSONUpdateBuilder=_e.default,this.Point=we.default,this.LineString=Se.default,this.Polygon=xe.default,this.Geometry=Pe.default,this.GeoJSONParser=Ie.default,this.WKTParser=Te.default,this.SpatialReferenceSystem=Re.default}var Z,W;return(0,le.default)(e,[{key:"of",value:function(Z){return new pe.default(Z,this)}},{key:"describe",value:(W=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return Z="string"==typeof Z?Z:ce.default.getClassName(Z),W.abrupt("return",this.app.request.get({url:this.app.urls.dataTableProps(Z)}));case 2:case"end":return W.stop()}}),e,this)}))),function(Z){return W.apply(this,arguments)})},{key:"getTableNameById",value:(Z=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return W.abrupt("return",this.app.request.get({url:this.app.urls.dataTableNameById(Z)}));case 1:case"end":return W.stop()}}),e,this)}))),function(W){return Z.apply(this,arguments)})},{key:"mapTableToClass",value:function(Z,W){if("function"==typeof Z&&(W=Z,Z=ce.default.getClassName(W)),!Z||"string"!=typeof Z)throw new Error("Table Name must be provided and must be a string.");if(!W||"function"!=typeof W)throw new Error("Class must be provided and must be a constructor function.");this.classToTableMap[Z]=W}}]),e}();W.Z=Ve},2496:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(1655)),ee=Y($(4993)),ae=Y($(3808)),ie=Y($(6690)),le=Y($(9728)),ce=function(){function e(Z){(0,ie.default)(this,e),this.operationName=Z,this.args={}}return(0,le.default)(e,[{key:"addArgument",value:function(Z,W){if(void 0===W)throw new Error("You have to specify function's second argument");return this.args[Z]=W,this}},{key:"toJSON",value:function(){return this.validate(),{___operation:this.operationName,args:this.args}}},{key:"create",value:function(){return this.toJSON()}},{key:"validate",value:function(){if(!Object.keys(this.args).length)throw new Error("You have to add at least one argument")}}],[{key:"SET",value:function(){return new e("JSON_SET")}},{key:"INSERT",value:function(){return new e("JSON_INSERT")}},{key:"REPLACE",value:function(){return new e("JSON_REPLACE")}},{key:"REMOVE",value:function(){return new de}},{key:"ARRAY_APPEND",value:function(){return new e("JSON_ARRAY_APPEND")}},{key:"ARRAY_INSERT",value:function(){return new e("JSON_ARRAY_INSERT")}}]),e}();W.default=ce;var de=function(Z){(0,X.default)(r,Z);var W=function c(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,ae.default)(Z);if(W){var X=(0,ae.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ee.default)(this,$)}}(r);function r(){var Z;return(0,ie.default)(this,r),(Z=W.call(this,"JSON_REMOVE")).args=[],Z}return(0,le.default)(r,[{key:"addArgument",value:function(Z){return this.args.push(Z),this}},{key:"validate",value:function(){if(!this.args.length)throw new Error("You have to add at least one argument")}}]),r}(ce)},3198:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1588)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=function(Z){(0,ie.default)(r,Z);var W=function l(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,ce.default)(Z);if(W){var X=(0,ce.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,le.default)(this,$)}}(r);function r(Z){var $;return(0,X.default)(this,r),($=W.call(this)).relationModel=Z,$.relationName=null,$}return(0,ee.default)(r,[{key:"setRelationName",value:function(Z){return this.relationName=Z,this}},{key:"getRelationName",value:function(){return this.relationName}},{key:"setRelationModel",value:function(Z){return this.relationModel=Z,this}},{key:"getRelationModel",value:function(){return this.relationModel}},{key:"toJSON",value:function(){var Z=(0,ae.default)((0,ce.default)(r.prototype),"toJSON",this).call(this);return Z.relationName=this.getRelationName(),Z.relationModel=this.getRelationModel(),Z}}],[{key:"of",value:function(Z){return new this(Z)}}]),r}(Y($(3082)).default);W.default=de},6064:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(8416)),de=function(Z){(0,ae.default)(r,Z);var W=function l(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(){return(0,X.default)(this,r),W.apply(this,arguments)}return(0,ee.default)(r,[{key:"getRequestURL",value:function(Z,W){if(!W.___class||!W.objectId)throw new Error('"dataObject.___class" and "dataObject.objectId" need to be specified');return this.app.urls.dataObjectPermission(W.___class,Z,W.objectId)}}]),r}(Y($(394)).default);W.default=de,(0,ce.default)(de,"BACKWARD_COMPATIBILITY_LABEL","Backendless.Data.Permissions.{FIND|REMOVE|UPDATE}")},9350:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1588)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=$(9181),pe="created",fe="updated",ye="deleted",be="upserted",_e="bulk-created",we="bulk-updated",Se="bulk-deleted",xe="bulk-upserted",Pe="add",Re="set",Te="delete",Ie=[pe,fe,ye,be],qe=function(Z){(0,ie.default)(r,Z);var W=function f(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,ce.default)(Z);if(W){var X=(0,ce.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,le.default)(this,$)}}(r);function r(Z){var $;return(0,X.default)(this,r),($=W.call(this)).dataStore=Z,$.app=Z.app,$}return(0,ee.default)(r,[{key:"getSubscriptionOptions",value:function(){return{tableName:this.dataStore.className}}},{key:"addCreateListener",value:function(Z,W,$){this.addChangesListener(pe,Z,W,$)}},{key:"removeCreateListeners",value:function(Z,W){this.removeChangesListeners(pe,Z,W)}},{key:"removeCreateListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeCreateListeners(void 0,Z)}},{key:"addUpsertListener",value:function(Z,W,$){this.addChangesListener(be,Z,W,$)}},{key:"removeUpsertListeners",value:function(Z,W){this.removeChangesListeners(be,Z,W)}},{key:"removeUpsertListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeUpsertListeners(void 0,Z)}},{key:"addUpdateListener",value:function(Z,W,$){this.addChangesListener(fe,Z,W,$)}},{key:"removeUpdateListeners",value:function(Z,W){this.removeChangesListeners(fe,Z,W)}},{key:"removeUpdateListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeUpdateListeners(void 0,Z)}},{key:"addDeleteListener",value:function(Z,W,$){this.addChangesListener(ye,Z,W,$)}},{key:"removeDeleteListeners",value:function(Z,W){this.removeChangesListeners(ye,Z,W)}},{key:"removeDeleteListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeDeleteListeners(void 0,Z)}},{key:"addBulkCreateListener",value:function(Z,W,$){this.addChangesListener(_e,Z,W,$)}},{key:"removeBulkCreateListeners",value:function(){this.removeChangesListeners(_e)}},{key:"removeBulkCreateListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeChangesListeners(_e,void 0,Z)}},{key:"addBulkUpdateListener",value:function(Z,W,$){this.addChangesListener(we,Z,W,$)}},{key:"removeBulkUpdateListeners",value:function(Z,W){this.removeChangesListeners(we,Z,W)}},{key:"removeBulkUpdateListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeBulkUpdateListeners(void 0,Z)}},{key:"addBulkDeleteListener",value:function(Z,W,$){this.addChangesListener(Se,Z,W,$)}},{key:"removeBulkDeleteListeners",value:function(Z,W){this.removeChangesListeners(Se,Z,W)}},{key:"removeBulkDeleteListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeBulkDeleteListeners(void 0,Z)}},{key:"addBulkUpsertListener",value:function(Z,W,$){this.addChangesListener(xe,Z,W,$)}},{key:"removeBulkUpsertListeners",value:function(){this.removeChangesListeners(xe)}},{key:"removeBulkUpsertListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeChangesListeners(xe,void 0,Z)}},{key:"addSetRelationListener",value:function(Z,W,$,Y){this.addRelationsChangesListener(Re,Z,W,$,Y)}},{key:"removeSetRelationListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeRelationsChangesListeners(Re,void 0,Z)}},{key:"removeSetRelationListeners",value:function(Z,W){this.removeRelationsChangesListeners(Re,Z,W)}},{key:"addAddRelationListener",value:function(Z,W,$,Y){this.addRelationsChangesListener(Pe,Z,W,$,Y)}},{key:"removeAddRelationListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeRelationsChangesListeners(Pe,void 0,Z)}},{key:"removeAddRelationListeners",value:function(Z,W){this.removeRelationsChangesListeners(Pe,Z,W)}},{key:"addDeleteRelationListener",value:function(Z,W,$,Y){this.addRelationsChangesListener(Te,Z,W,$,Y)}},{key:"removeDeleteRelationListener",value:function(Z){if(!Z||"function"!=typeof Z)throw new Error("Listener Function must be passed.");this.removeRelationsChangesListeners(Te,void 0,Z)}},{key:"removeDeleteRelationListeners",value:function(Z,W){this.removeRelationsChangesListeners(Te,Z,W)}},{key:"addChangesListener",value:function(Z,W,$,Y){if("function"==typeof W&&(Y=$,$=W,W=void 0),"function"!=typeof $)throw new Error("Listener Function must be passed.");this.addSubscription(Z,this.app.RT.subscriptions.onObjectsChanges,{callback:$,onError:Y,parser:Ie.includes(Z)?this.parseObjectToInstance.bind(this):void 0,params:{event:Z,whereClause:W}})}},{key:"removeChangesListeners",value:function(Z,W,$){"function"==typeof W&&($=W,W=void 0),this.stopSubscription(Z,{matcher:function(Z){var Y=Z.params;return W?Y.whereClause===W:!$||Z.callback===$}})}},{key:"addRelationsChangesListener",value:function(Z,W,$,Y,X){if(!W||"string"!=typeof W)throw new Error("Relation Column Name must be a string.");if("function"==typeof $&&(X=Y,Y=$,$=void 0),"function"!=typeof Y)throw new Error("Listener Function must be passed.");if($){if(!Array.isArray($))throw new Error("Parent Objects must be an array");$=$.map((function(Z){return Z.objectId||Z}))}this.addSubscription(Z,this.app.RT.subscriptions.onRelationsChanges,{callback:Y,onError:X,params:{event:Z,relationColumnName:W,parentObjects:$}})}},{key:"removeRelationsChangesListeners",value:function(Z,W,$){"function"==typeof W&&($=W,W=void 0),this.stopSubscription(Z,{matcher:function(Z){var Y=Z.params;return W?Y.relationColumnName===W:!$||Z.callback===$}})}},{key:"removeAllListeners",value:function(){(0,ae.default)((0,ce.default)(r.prototype),"removeAllListeners",this).call(this)}},{key:"parseObjectToInstance",value:function(Z){return this.dataStore.parseResponse(Z)}}]),r}(de.RTListeners);W.default=qe},9540:(Z,W,$)=>{"use strict";var Y=$(4836),X=$(8698);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var ee=Y($(7424)),ae=Y($(215)),ie=Y($(4687)),le=Y($(8698)),ce=Y($(7156)),de=Y($(6690)),pe=Y($(9728)),fe=Y($(8416)),ye=Y($(9853)),be=Y($(7738)),_e=Y($(9350)),we=Y($(3082)),Se=Y($(3198)),xe=Y($(2496)),Pe=function(Z,W){if(Z&&Z.__esModule)return Z;if(null===Z||"object"!==X(Z)&&"function"!=typeof Z)return{default:Z};var $=E(W);if($&&$.has(Z))return $.get(Z);var Y={},ee=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ae in Z)if("default"!==ae&&Object.prototype.hasOwnProperty.call(Z,ae)){var ie=ee?Object.getOwnPropertyDescriptor(Z,ae):null;ie&&(ie.get||ie.set)?Object.defineProperty(Y,ae,ie):Y[ae]=Z[ae]}return Y.default=Z,$&&$.set(Z,Y),Y}($(7130)),Re=Y($(7705)),Te=["relationName","relationModel"];function E(Z){if("function"!=typeof WeakMap)return null;var W=new WeakMap,$=new WeakMap;return(E=function(Z){return Z?$:W})(Z)}function O(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function S(Z,W){var $=Z instanceof we.default?Z.toJSON():Z?function(Z){for(var W=1;W{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=(0,X.default)((function e(Z){if((0,ee.default)(this,e),!(Z&&Z.uuid&&Z.platform&&Z.version))throw new Error('Device properties object must consist of fields "uuid", "platform" and "version".');this.uuid=Z.uuid,this.platform=Z.platform.toUpperCase(),this.version=Z.version}));W.Z=ae},7738:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z){if((0,X.default)(this,e),!Z||"string"!=typeof Z)throw new Error("The Backendless.Expression class can be initialized with non empty string value only");this.value=Z}return(0,ee.default)(e,[{key:"toJSON",value:function(){return{___class:"BackendlessExpression",value:this.value}}}]),e}();W.default=ae},3011:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(4253)),ce=Y($(1141)),de=function(){function e(Z){(0,ae.default)(this,e),this.app=Z,this.Permissions={READ:new ce.default("READ",Z),DELETE:new ce.default("DELETE",Z),WRITE:new ce.default("WRITE",Z)}}var Z,W,$,Y,de,pe,fe,ye,be,_e,we,Se,xe;return(0,ie.default)(e,[{key:"saveFile",value:(xe=(0,ee.default)(X.default.mark((function e(Z,W,$,Y){var ee;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"filePath" must be provided and must be a string.');case 2:if(W&&"string"==typeof W){X.next=4;break}throw new Error("File Name must be provided and must be a string.");case 4:return X.next=6,le.default.toBase64($);case 6:return $=X.sent,ee={},"boolean"==typeof Y&&(ee.overwrite=Y),Z=le.default.trimSlashesInPath(Z),W=le.default.sanitizeFileName(W),X.abrupt("return",this.app.request.put({url:"".concat(this.app.urls.fileBinaryPath(Z),"/").concat(W),headers:{"Content-Type":"text/plain"},query:ee,data:$}));case 12:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y){return xe.apply(this,arguments)})},{key:"upload",value:(Se=(0,ee.default)(X.default.mark((function e(Z,W,$){var Y,ee,ae,ie;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Y={},"boolean"==typeof $&&(Y.overwrite=$),W=le.default.trimSlashesInPath(W),(ee=le.default.parseFilePath(W)).fileName&&(W=ee.filePath,ae=ee.fileName),"string"!=typeof Z){X.next=8;break}return ae||(ie=le.default.parseFilePath(Z),ae=ie.fileName),X.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.filePath(W),"/").concat(ae),query:Y,data:{url:Z}}));case 8:if(ae||(ae=le.default.getFileName(Z)),ae){X.next=11;break}throw new Error("Wrong type of the file source object. Can not get file name");case 11:return ae=le.default.sanitizeFileName(ae),X.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.filePath(W),"/").concat(ae),query:Y,form:{file:Z}}));case 13:case"end":return X.stop()}}),e,this)}))),function(Z,W,$){return Se.apply(this,arguments)})},{key:"append",value:(we=(0,ee.default)(X.default.mark((function e(Z,W,$){var Y,ee=arguments;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"filePath" must be provided and must be a string.');case 2:if(Z=le.default.trimSlashesInPath(Z),2===ee.length&&($=W,W=void 0,(Y=le.default.parseFilePath(Z)).fileName&&(Z=Y.filePath,W=Y.fileName)),W){X.next=6;break}throw new Error("Can not resolve target file name");case 6:if(W=le.default.sanitizeFileName(W),"string"!=typeof $){X.next=9;break}return X.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.fileAppendPath(Z),"/").concat(W),data:{url:$}}));case 9:if(!le.default.isBytesArray($)){X.next=14;break}return X.next=12,le.default.toBase64($);case 12:return $=X.sent,X.abrupt("return",this.app.request.put({url:"".concat(this.app.urls.fileAppendBinaryPath(Z),"/").concat(W),headers:{"Content-Type":"text/plain"},data:$}));case 14:return X.abrupt("return",this.app.request.post({url:"".concat(this.app.urls.fileAppendPath(Z),"/").concat(W),form:{file:$}}));case 15:case"end":return X.stop()}}),e,this)}))),function(Z,W,$){return we.apply(this,arguments)})},{key:"appendText",value:(_e=(0,ee.default)(X.default.mark((function e(Z,W,$){var Y,ee=arguments;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"filePath" must be provided and must be a string.');case 2:if(Z=le.default.trimSlashesInPath(Z),2===ee.length&&($=W,W=void 0,(Y=le.default.parseFilePath(Z)).fileName&&(Z=Y.filePath,W=Y.fileName)),W){X.next=6;break}throw new Error("Can not resolve target file name");case 6:if("string"==typeof $){X.next=8;break}throw new Error('"textContent" must be a string');case 8:return W=le.default.sanitizeFileName(W),X.abrupt("return",this.app.request.put({url:"".concat(this.app.urls.fileAppendPath(Z),"/").concat(W),headers:{"Content-Type":"text/plain"},data:$}));case 10:case"end":return X.stop()}}),e,this)}))),function(Z,W,$){return _e.apply(this,arguments)})},{key:"listing",value:(be=(0,ee.default)(X.default.mark((function e(Z,W,$,Y,ee){var ae;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(ae={},Z&&"string"==typeof Z){X.next=3;break}throw new Error('"filePath" must be provided and must be a string.');case 3:return Z=le.default.trimSlashesInPath(Z),W&&"string"==typeof W&&(ae.pattern=W),"boolean"==typeof $&&(ae.sub=$),"number"==typeof Y&&Y>=0&&(ae.pagesize=Y),"number"==typeof ee&&ee>=0&&(ae.offset=ee),X.abrupt("return",this.app.request.get({url:this.app.urls.filePath(Z),query:ae}));case 9:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y,X){return be.apply(this,arguments)})},{key:"renameFile",value:(ye=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(Z&&"string"==typeof Z){$.next=2;break}throw new Error('"oldPathName" must be provided and must be a string.');case 2:if(W&&"string"==typeof W){$.next=4;break}throw new Error("New File Name must be provided and must be a string.");case 4:return $.abrupt("return",this.app.request.put({url:this.app.urls.fileRename(),data:{oldPathName:le.default.ensureSlashInPath(Z),newName:W}}));case 5:case"end":return $.stop()}}),e,this)}))),function(Z,W){return ye.apply(this,arguments)})},{key:"moveFile",value:(fe=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return $.abrupt("return",this.app.request.put({url:this.app.urls.fileMove(),data:{sourcePath:le.default.ensureSlashInPath(Z),targetPath:le.default.ensureSlashInPath(W)}}));case 1:case"end":return $.stop()}}),e,this)}))),function(Z,W){return fe.apply(this,arguments)})},{key:"copyFile",value:(pe=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return $.abrupt("return",this.app.request.put({url:this.app.urls.fileCopy(),data:{sourcePath:le.default.ensureSlashInPath(Z),targetPath:le.default.ensureSlashInPath(W)}}));case 1:case"end":return $.stop()}}),e,this)}))),function(Z,W){return pe.apply(this,arguments)})},{key:"remove",value:(de=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error('"filePath" must be provided and must be a string.');case 2:return Z.startsWith("http://")||Z.startsWith("https://")||(Z=this.app.urls.filePath(Z)),W.abrupt("return",this.app.request.delete({url:Z}));case 4:case"end":return W.stop()}}),e,this)}))),function(Z){return de.apply(this,arguments)})},{key:"exists",value:(Y=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error('"filePath" must be provided and must be a string.');case 2:return Z=le.default.trimSlashesInPath(Z),W.abrupt("return",this.app.request.get({url:this.app.urls.filePath(Z),query:{action:"exists"}}));case 4:case"end":return W.stop()}}),e,this)}))),function(Z){return Y.apply(this,arguments)})},{key:"getFileCount",value:($=(0,ee.default)(X.default.mark((function e(Z,W,$,Y){return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"filesPath" must be provided and must be a string.');case 2:if(!W||"string"==typeof W){X.next=4;break}throw new Error("Files Pattern must be provided and must be a string.");case 4:return Z=le.default.trimSlashesInPath(Z),X.abrupt("return",this.app.request.get({url:this.app.urls.filePath(Z),query:{action:"count",pattern:W||"*",sub:!!$,countDirectories:!!Y}}));case 6:case"end":return X.stop()}}),e,this)}))),function(Z,W,Y,X){return $.apply(this,arguments)})},{key:"createDirectory",value:(W=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error('Directory "path" must be provided and must be a string.');case 2:return Z=le.default.trimSlashesInPath(Z),W.abrupt("return",this.app.request.post({url:this.app.urls.directoryPath(Z)}));case 4:case"end":return W.stop()}}),e,this)}))),function(Z){return W.apply(this,arguments)})},{key:"removeDirectory",value:(Z=(0,ee.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error('Directory "path" must be provided and must be a string.');case 2:return Z=le.default.trimSlashesInPath(Z),W.abrupt("return",this.app.request.delete({url:this.app.urls.filePath(Z)}));case 4:case"end":return W.stop()}}),e,this)}))),function(W){return Z.apply(this,arguments)})}]),e}();W.Z=de},1141:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(8416)),de=function(Z){(0,ae.default)(r,Z);var W=function l(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(){return(0,X.default)(this,r),W.apply(this,arguments)}return(0,ee.default)(r,[{key:"getRequestURL",value:function(Z,W){return this.app.urls.filePermission(Z,W)}}]),r}(Y($(394)).default);W.default=de,(0,ce.default)(de,"BACKWARD_COMPATIBILITY_LABEL","Backendless.Files.Permissions.{READ|DELETE|WRITE}")},4253:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(4687)),ee=Y($(7156)),ae={isBytesArray:function(Z){return"undefined"!=typeof Buffer&&Z instanceof Buffer||"undefined"!=typeof ArrayBuffer&&Z instanceof ArrayBuffer||Array.isArray(Z)},ensureSlashInPath:function(Z){return Z.startsWith("/")?Z:"/".concat(Z)},trimSlashesInPath:function(Z){return Z&&(Z.startsWith("/")&&(Z=Z.slice(1)),Z.endsWith("/")&&(Z=Z.slice(0,Z.length-1))),Z},parseFilePath:function(Z){var W={filePath:Z,fileName:null};if(Z){var $=Z.split("/");$[$.length-1].includes(".")&&(W.fileName=$.pop(),W.filePath=$.join("/"))}return W},sanitizeFileName:function(Z){return encodeURIComponent(Z).replace(/'/g,"%27").replace(/"/g,"%22")},getFileName:function(Z){if(Z.name)return Z.name;if(Z.path){var W=Z.path.split("/");return W[W.length-1]}},toBase64:function(Z){return(0,ee.default)(X.default.mark((function t(){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if("undefined"==typeof Blob||"undefined"==typeof FileReader){W.next=3;break}return Z instanceof Blob||(Z=new Blob([Z],{type:""})),W.abrupt("return",new Promise((function(W,$){var Y=new FileReader;Y.onerror=function(Z){return $(Z)},Y.onload=function(Z){return W(Z.target.result.split(";base64,")[1])},Y.readAsDataURL(Z)})));case 3:if("undefined"==typeof Buffer){W.next=5;break}return W.abrupt("return",Buffer.from(Z).toString("base64"));case 5:return W.abrupt("return",Z);case 6:case"end":return W.stop()}}),t)})))()}};W.default=ae},2257:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.HiveTypes=void 0,W.HiveTypes={KEY_VALUE:"key-value",LIST:"list",MAP:"map",SET:"set",SORTED_SET:"sorted-set"}},8512:(Z,W,$)=>{"use strict";var Y=$(4836);W.ZP=function(Z){function t(W){if(!W||"string"!=typeof W)throw new Error("Hive name must be provided and must be a string.");return new ie(W,{app:Z})}return t.getNames=function(){return Z.request.get({url:Z.urls.dataHives()})},t};var X=Y($(6690)),ee=Y($(9728)),ae=$(5766),ie=function(){function e(Z,W){(0,X.default)(this,e),this.hiveName=Z,this.app=W.app,this.KeyValueStore=ae.KeyValueStore.registerType(this),this.ListStore=ae.ListStore.registerType(this),this.MapStore=ae.MapStore.registerType(this),this.SetStore=ae.SetStore.registerType(this),this.SortedSetStore=ae.SortedSetStore.registerType(this)}return(0,ee.default)(e,[{key:"create",value:function(){return this.app.request.post({url:this.app.urls.dataHive(this.hiveName)})}},{key:"delete",value:function(){return this.app.request.delete({url:this.app.urls.dataHive(this.hiveName)})}},{key:"rename",value:function(Z){if(!Z||"string"!=typeof Z)throw new Error("New Hive name must be provided and must be a string.");return this.app.request.put({url:this.app.urls.dataHive(this.hiveName),query:{newName:Z}})}}]),e}()},9041:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.HiveStore=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(8416)),ce=Y($(9853));function l(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function f(Z){for(var W=1;W{"use strict";Object.defineProperty(W,"__esModule",{value:!0});var Y=$(3025);Object.keys(Y).forEach((function(Z){"default"!==Z&&"__esModule"!==Z&&(Z in W&&W[Z]===Y[Z]||Object.defineProperty(W,Z,{enumerable:!0,get:function(){return Y[Z]}}))}));var X=$(6502);Object.keys(X).forEach((function(Z){"default"!==Z&&"__esModule"!==Z&&(Z in W&&W[Z]===X[Z]||Object.defineProperty(W,Z,{enumerable:!0,get:function(){return X[Z]}}))}));var ee=$(5076);Object.keys(ee).forEach((function(Z){"default"!==Z&&"__esModule"!==Z&&(Z in W&&W[Z]===ee[Z]||Object.defineProperty(W,Z,{enumerable:!0,get:function(){return ee[Z]}}))}));var ae=$(5817);Object.keys(ae).forEach((function(Z){"default"!==Z&&"__esModule"!==Z&&(Z in W&&W[Z]===ae[Z]||Object.defineProperty(W,Z,{enumerable:!0,get:function(){return ae[Z]}}))}));var ie=$(9352);Object.keys(ie).forEach((function(Z){"default"!==Z&&"__esModule"!==Z&&(Z in W&&W[Z]===ie[Z]||Object.defineProperty(W,Z,{enumerable:!0,get:function(){return ie[Z]}}))}))},3025:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.KeyValueStore=void 0;var X=Y($(861)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=Y($(8416)),pe=$(2257),fe=$(9041),ye=Y($(9853)),be=$(9095);function y(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function v(Z){for(var W=1;W{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.ListStore=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(8416)),de=$(2257),pe=$(9041),fe=$(9095),ye=function(Z){(0,ae.default)(r,Z);var W=function d(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(){return(0,X.default)(this,r),W.apply(this,arguments)}return(0,ee.default)(r,[{key:"get",value:function(Z,W){if(void 0!==W){if(isNaN(W)||"number"!=typeof W)throw new Error("Index To must be a number.");if(isNaN(Z)||"number"!=typeof Z)throw new Error("Index From must be a number.");return this.app.request.get({url:this.getBaseURL(),query:{from:Z,to:W}})}if(void 0!==Z){if(isNaN(Z)||"number"!=typeof Z)throw new Error("Index must be a number.");return this.app.request.get({url:"".concat(this.getBaseURL(),"/").concat(Z)})}return this.app.request.get({url:this.getBaseURL()})}},{key:"length",value:function(){return this.app.request.get({url:"".concat(this.getBaseURL(),"/length")})}},{key:"insertBefore",value:function(Z,W){return this.insert(Z,W,!0)}},{key:"insertAfter",value:function(Z,W){return this.insert(Z,W,!1)}},{key:"insert",value:function(Z,W,$){if(!(0,fe.isHiveValueValid)(Z))throw new Error("ValueToInsert must be provided and must be one of types: string, number, boolean, object, array.");if(!(0,fe.isHiveValueValid)(W))throw new Error("AnchorValue must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/insert-").concat($?"before":"after"),data:{valueToInsert:Z,anchorValue:W}})}},{key:"deleteValue",value:function(Z,W){if(!(0,fe.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");if(void 0!==W&&(isNaN(W)||"number"!=typeof W))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/delete-value"),data:{value:Z,count:W}})}},{key:"addFirstValue",value:function(Z){if(!(0,fe.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add-first"),data:[Z]})}},{key:"addFirstValues",value:function(Z){if(!(Z&&Array.isArray(Z)&&Z.length&&(0,fe.isHiveValueValid)(Z)))throw new Error("Value must be provided and must be a list of valid JSON items.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add-first"),data:Z})}},{key:"addLastValue",value:function(Z){if(!(0,fe.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add-last"),data:[Z]})}},{key:"addLastValues",value:function(Z){if(!(Z&&Array.isArray(Z)&&Z.length&&(0,fe.isHiveValueValid)(Z)))throw new Error("Value must be provided and must be a list of valid JSON items.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add-last"),data:Z})}},{key:"deleteFirst",value:function(Z){if(void 0!==Z&&(isNaN(Z)||"number"!=typeof Z))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/get-first-and-delete"),query:{count:Z}})}},{key:"deleteLast",value:function(Z){if(void 0!==Z&&(isNaN(Z)||"number"!=typeof Z))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/get-last-and-delete"),query:{count:Z}})}}]),r}(pe.HiveStore);W.ListStore=ye,(0,ce.default)(ye,"TYPE",de.HiveTypes.LIST)},5076:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.MapStore=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(1655)),ie=Y($(4993)),le=Y($(3808)),ce=Y($(8416)),de=$(2257),pe=$(9041),fe=Y($(9853)),ye=$(9095),be=function(Z){(0,ae.default)(r,Z);var W=function h(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,le.default)(Z);if(W){var X=(0,le.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ie.default)(this,$)}}(r);function r(){return(0,X.default)(this,r),W.apply(this,arguments)}return(0,ee.default)(r,[{key:"get",value:function(Z){if(void 0!==Z&&"string"!=typeof Z&&!Array.isArray(Z))throw new Error("Key(s) must be a string or list of strings.");return this.app.request.post({url:this.getBaseURL(),data:fe.default.castArray(Z)})}},{key:"getValue",value:function(Z){if(!Z||"string"!=typeof Z)throw new Error("Key must be provided and must be a string.");return this.app.request.get({url:"".concat(this.getBaseURL(),"/get/").concat(Z)})}},{key:"keyExists",value:function(Z){if(!Z||"string"!=typeof Z)throw new Error("Key must be provided and must be a string.");return this.app.request.get({url:"".concat(this.getBaseURL(),"/exists/").concat(Z)})}},{key:"length",value:function(){return this.app.request.get({url:"".concat(this.getBaseURL(),"/length")})}},{key:"keys",value:function(){return this.app.request.get({url:"".concat(this.getBaseURL(),"/keys")})}},{key:"values",value:function(){return this.app.request.get({url:"".concat(this.getBaseURL(),"/values")})}},{key:"set",value:function(Z,W){if(!Z)throw new Error("First argument must be provided and must be a string or an object.");if(fe.default.isObject(Z)){if(!Object.keys(Z).length)throw new Error("Provided object must have at least 1 key.");return this.app.request.put({url:this.getBaseURL(),data:Z})}if("string"!=typeof Z)throw new Error("Key must be a string.");if(!(0,ye.isHiveValueValid)(W))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/set/").concat(Z),data:{value:W}})}},{key:"setWithOverwrite",value:function(Z,W,$){if(!Z||"string"!=typeof Z)throw new Error("Key must be provided and must be a string.");if(!(0,ye.isHiveValueValid)(W))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");if(void 0!==$&&"boolean"!=typeof $)throw new Error("Overwrite must be a boolean.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/set-with-overwrite/").concat(Z),data:{value:W,overwrite:$}})}},{key:"increment",value:function(Z,W){if(!Z||"string"!=typeof Z)throw new Error("Key must be provided and must be a string.");if(void 0!==W&&(isNaN(W)||"number"!=typeof W))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/increment/").concat(Z),query:{count:W}})}},{key:"decrement",value:function(Z,W){if(!Z||"string"!=typeof Z)throw new Error("Key must be provided and must be a string.");if(void 0!==W&&(isNaN(W)||"number"!=typeof W))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/decrement/").concat(Z),query:{count:W}})}},{key:"deleteKeys",value:function(Z){if(!Z||"string"!=typeof Z&&!Array.isArray(Z))throw new Error("Key(s) must be provided and must be a string or list of strings.");return this.app.request.delete({url:"".concat(this.getBaseURL(),"/by-obj-keys"),data:fe.default.castArray(Z)})}}]),r}(pe.HiveStore);W.MapStore=be,(0,ce.default)(be,"TYPE",de.HiveTypes.MAP)},5817:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.SetStore=void 0;var X=Y($(861)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=Y($(8416)),pe=$(9041),fe=$(2257),ye=$(9095),be=function(Z){(0,ie.default)(r,Z);var W=function h(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,ce.default)(Z);if(W){var X=(0,ce.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,le.default)(this,$)}}(r);function r(){return(0,ee.default)(this,r),W.apply(this,arguments)}return(0,ae.default)(r,[{key:"get",value:function(){return this.app.request.get({url:this.getBaseURL()})}},{key:"getRandom",value:function(Z){if(void 0!==Z&&(isNaN(Z)||"number"!=typeof Z))throw new Error("Count must be a number.");return this.app.request.get({url:"".concat(this.getBaseURL(),"/random"),query:{count:Z}})}},{key:"getRandomAndDelete",value:function(Z){if(void 0!==Z&&(isNaN(Z)||"number"!=typeof Z))throw new Error("Count must be a number.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/random"),query:{count:Z}})}},{key:"addValue",value:function(Z){if(!(0,ye.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add"),data:[Z]})}},{key:"addValues",value:function(Z){if(!(Z&&Array.isArray(Z)&&Z.length&&(0,ye.isHiveValueValid)(Z)))throw new Error("Value must be provided and must be a list of valid JSON items.");return this.app.request.put({url:"".concat(this.getBaseURL(),"/add"),data:Z})}},{key:"deleteValue",value:function(Z){if(!(0,ye.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.delete({url:"".concat(this.getBaseURL(),"/values"),data:[Z]})}},{key:"deleteValues",value:function(Z){if(!(Z&&Array.isArray(Z)&&Z.length&&(0,ye.isHiveValueValid)(Z)))throw new Error("Value must be provided and must be a list of valid JSON items.");return this.app.request.delete({url:"".concat(this.getBaseURL(),"/values"),data:Z})}},{key:"isValueMember",value:function(Z){if(!(0,ye.isHiveValueValid)(Z))throw new Error("Value must be provided and must be one of types: string, number, boolean, object, array.");return this.app.request.post({url:"".concat(this.getBaseURL(),"/contains"),data:[Z]})}},{key:"isValuesMembers",value:function(Z){if(!(Z&&Array.isArray(Z)&&Z.length&&(0,ye.isHiveValueValid)(Z)))throw new Error("Value must be provided and must be a list of valid JSON items.");return this.app.request.post({url:"".concat(this.getBaseURL(),"/contains"),data:Z})}},{key:"length",value:function(){return this.app.request.get({url:"".concat(this.getBaseURL(),"/length")})}}],[{key:"difference",value:function(Z){if(!Array.isArray(Z))throw new Error("Store keys must be provided and must be an array.");return this.app.request.post({url:"".concat(this.app.urls.hiveStore(this.hiveName,this.TYPE),"/action/difference"),data:Z})}},{key:"intersection",value:function(Z){if(!Array.isArray(Z))throw new Error("Store keys must be provided and must be an array.");return this.app.request.post({url:"".concat(this.app.urls.hiveStore(this.hiveName,this.TYPE),"/action/intersection"),data:Z})}},{key:"union",value:function(Z){if(!Array.isArray(Z))throw new Error("Store keys must be provided and must be an array.");return this.app.request.post({url:"".concat(this.app.urls.hiveStore(this.hiveName,this.TYPE),"/action/union"),data:Z})}}]),r}(pe.HiveStore);W.SetStore=be,(0,de.default)(be,"TYPE",fe.HiveTypes.SET),(0,de.default)(be,"STATIC_METHODS",[].concat((0,X.default)(pe.HiveStore.STATIC_METHODS),["difference","intersection","union"]))},9352:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.SortedSetStore=void 0;var X=Y($(861)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(1655)),le=Y($(4993)),ce=Y($(3808)),de=Y($(8416)),pe=$(9041),fe=$(2257),ye=Y($(9853)),be=$(5817),_e=$(9095);function v(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function m(Z){for(var W=1;W{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.isHiveValueValid=function(Z){if(null==Z)return!1;try{return!!JSON.stringify(Z)}catch(Z){return!1}}},5579:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(434)),ee=Y($(8416)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(8698)),ce=Y($(3930)),de=Y($(294)),pe=Y($(435)),fe=Y($(9853)),ye=Y($(7738));function h(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}var be={appId:null,apiKey:null,serverURL:"https://api.backendless.com",domain:null,apiURI:"/api",debugMode:!1,standalone:!1,XMLHttpRequest:"undefined"!=typeof XMLHttpRequest?XMLHttpRequest:void 0},_e=["appId","apiKey","domain"],we="object"===("undefined"==typeof self?"undefined":(0,le.default)(self))&&self.self===self&&self||"object"===(void 0===$.g?"undefined":(0,le.default)($.g))&&$.g.global===$.g&&$.g,Se=we&&we.Backendless,g=function(){for(var Z=arguments.length,W=new Array(Z),$=0;${"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(9853)),ie=Y($(1376)),le=Y($(4770)),ce=function(){function e(Z){(0,X.default)(this,e),this.app=Z,this.storageName=this.app.appId?"".concat("Backendless","_").concat(this.app.appId):"Backendless";var W=ae.default.isLocalStorageSupported?le.default:ie.default;this.setStorage(W),this.Keys={USER_TOKEN:"user-token",CURRENT_USER_ID:"current-user-id",STAY_LOGGED_IN:"stayLoggedIn"}}return(0,ee.default)(e,[{key:"setStorage",value:function(Z){this.storage=new Z(this.storageName,"Backendless")}},{key:"set",value:function(Z,W){this.storage.set(Z,W)}},{key:"get",value:function(Z){return this.storage.get(Z)}},{key:"remove",value:function(Z){this.storage.remove(Z)}}]),e}();W.Z=ce},4770:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z,W){(0,X.default)(this,e),this.storageName=Z,function(Z,W){if(!localStorage.getItem(Z.storageName)){var $=localStorage.getItem(W);$&&(localStorage.setItem(Z.storageName,$),localStorage.removeItem(W))}}(this,W)}return(0,ee.default)(e,[{key:"getStore",value:function(){try{return JSON.parse(localStorage.getItem(this.storageName))||{}}catch(Z){console.warn("Could not parse data from LocalStorage",Z)}return{}}},{key:"setStore",value:function(Z){localStorage.setItem(this.storageName,JSON.stringify(Z))}},{key:"get",value:function(Z){return this.getStore()[Z]}},{key:"set",value:function(Z,W){var $=this.getStore();$[Z]=W,this.setStore($)}},{key:"remove",value:function(Z){var W=this.getStore();delete W[Z],this.setStore(W)}}]),e}();W.default=ae},1376:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(){(0,X.default)(this,e),this.data={}}return(0,ee.default)(e,[{key:"get",value:function(Z){return this.data[Z]}},{key:"set",value:function(Z,W){this.data[Z]=W}},{key:"remove",value:function(Z){delete this.data[Z]}}]),e}();W.default=ae},7776:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(861)),ae=Y($(7156)),ie=Y($(6690)),le=Y($(9728)),ce=Y($(3842)),de=function(){function e(Z){(0,ie.default)(this,e),this.app=Z,this.reset(),Z.loggingConfig&&this.setConfig(Z.loggingConfig)}var Z;return(0,le.default)(e,[{key:"setConfig",value:function(Z){Z.levels&&(this.levels=Z.levels),Z.globalLevel&&(this.globalLevel=Z.globalLevel),Z.loadLevels&&this.loadLoggingLevels()}},{key:"reset",value:function(){this.levels={},this.globalLevel="all",this.loggers={},this.messages=[],this.numOfMessages=10,this.timeFrequency=1,this.messagesLimit=1e3}},{key:"loadLoggingLevels",value:function(){var Z=this;this.app.request.get({url:this.app.urls.loggingLevels()}).then((function(W){var $={};W.forEach((function(Z){$[Z.name]=Z.level}));var Y=$["Global logger"];Z.setConfig({loggers:$,globalLevel:Y})})).catch((function(Z){console.error("Could not load logging levels: ",Z)}))}},{key:"getLogger",value:function(Z){if(!Z||"string"!=typeof Z)throw new Error("Logger Name must be provided and must be a string.");return this.loggers[Z]||(this.loggers[Z]=new ce.default(Z,this)),this.loggers[Z]}},{key:"flush",value:(Z=(0,ae.default)(X.default.mark((function e(){var Z,W=this;return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return!this.flushRequest&&this.messages.length&&(this.stopFlushInterval(),Z=(0,ee.default)(this.messages),this.messages=[],this.flushRequest=this.app.request.put({url:this.app.urls.logging(),data:Z}).catch((function($){throw W.messages=[].concat((0,ee.default)(Z),(0,ee.default)(W.messages)),W.checkMessagesLimit(),$})).finally((function(){return delete W.flushRequest}))),$.abrupt("return",this.flushRequest);case 2:case"end":return $.stop()}}),e,this)}))),function(){return Z.apply(this,arguments)})},{key:"push",value:function(Z,W,$,Y){this.messages.push({logger:Z,message:f($),exception:Y,"log-level":W,timestamp:Date.now()}),this.checkMessagesLen()}},{key:"checkMessagesLen",value:function(){var Z=this;this.checkMessagesLenTimer&&clearTimeout(this.checkMessagesLenTimer),this.checkMessagesLenTimer=setTimeout((function(){Z.messages.length>=Z.numOfMessages?Z.flush():Z.startFlushInterval()}),0)}},{key:"checkMessagesLimit",value:function(){this.messages.length>this.messagesLimit&&(this.messages=this.messages.slice(this.messages.length-this.messagesLimit))}},{key:"startFlushInterval",value:function(){var Z=this;this.flushInterval||(this.flushInterval=setTimeout((function(){return Z.flush()}),1e3*this.timeFrequency))}},{key:"stopFlushInterval",value:function(){this.flushInterval&&(clearTimeout(this.flushInterval),delete this.flushInterval)}},{key:"setLogReportingPolicy",value:function(Z,W){void 0!==W&&this.timeFrequency!==W&&this.stopFlushInterval(),Z>this.messagesLimit&&(this.messagesLimit=Z),this.numOfMessages=Z,this.timeFrequency=W,this.checkMessagesLen()}},{key:"setMessagesLimit",value:function(Z){this.messagesLimit=Z,this.checkMessagesLimit()}}]),e}();function f(Z){return"string"==typeof Z?Z:void 0===Z?"undefined":"function"==typeof Z?Object.prototype.toString.call(Z):JSON.stringify(Z)}W.Z=de},3842:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae={off:0,fatal:1,error:2,warn:3,info:4,debug:5,trace:6,all:6},ie=function(){function e(Z,W){(0,X.default)(this,e),this.name=Z,this.logging=W}return(0,ee.default)(e,[{key:"debug",value:function(Z){return this.log("DEBUG",Z)}},{key:"info",value:function(Z){return this.log("INFO",Z)}},{key:"warn",value:function(Z,W){return this.log("WARN",Z,W)}},{key:"error",value:function(Z,W){return this.log("ERROR",Z,W)}},{key:"fatal",value:function(Z,W){return this.log("FATAL",Z,W)}},{key:"trace",value:function(Z){return this.log("TRACE",Z)}},{key:"log",value:function(Z,W,$){if(this.min(Z))return this.logging.push(this.name,Z,W,$)}},{key:"min",value:function(Z){Z=Z.toLowerCase();var W=this.logging.globalLevel,$=this.logging.levels[this.name];return!(W&&ae[W.toLowerCase()]=ae[Z])}}]),e}();W.default=ie},6496:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z){(0,X.default)(this,e),this.app=Z}return(0,ee.default)(e,[{key:"createTable",value:function(Z,W){if(!Z||"string"!=typeof Z)throw new Error("Table name must be provided and must be a string.");if(!Array.isArray(W))throw new Error("Columns must be a list.");return this.app.request.post({url:this.app.urls.managementDataTable(),data:{name:Z,columns:W}})}}]),e}();W.default=ae},9415:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=Y($(6496)),ie=(0,X.default)((function e(Z){(0,ee.default)(this,e),this.app=Z,this.Data=new ae.default(Z)}));W.Z=ie},1127:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X,ee,ae=Y($(6690)),ie=Y($(9728)),le=Y($(1588)),ce=Y($(1655)),de=Y($(4993)),pe=Y($(3808)),fe=Y($(6877)),ye=$(9181),be="MESSAGE",_e=(X=ye.RTScopeConnector.connectionRequired(),ee=function(Z){(0,ce.default)(r,Z);var W=function h(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,pe.default)(Z);if(W){var X=(0,pe.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,de.default)(this,$)}}(r);function r(Z,$){var Y;return(0,ae.default)(this,r),(Y=W.call(this,Z)).app=$,Y.connect(),Y}return(0,ie.default)(r,[{key:"connectSubscriber",get:function(){return this.app.RT.subscriptions.connectToPubSub}},{key:"usersSubscriber",get:function(){return this.app.RT.subscriptions.onPubSubUserStatus}},{key:"commandSubscriber",get:function(){return this.app.RT.subscriptions.onPubSubCommand}},{key:"commandSender",get:function(){return this.app.RT.methods.sendPubSubCommand}},{key:"getScopeOptions",value:function(){return{channel:this.options.name}}},{key:"connect",value:function(){if(this.app)return(0,le.default)((0,pe.default)(r.prototype),"connect",this).call(this)}},{key:"publish",value:function(Z,W,$){return this.app.Messaging.publish(this.options.name,Z,W,$)}},{key:"addMessageListener",value:function(Z,W,$){"function"==typeof Z&&($=W,W=Z,Z=void 0),this.addSubscription(be,this.app.RT.subscriptions.onPubSubMessage,{callback:W,onError:$,params:{selector:Z}})}},{key:"removeMessageListener",value:function(Z,W){if("function"==typeof Z&&(W=Z,Z=void 0),Z&&"string"!=typeof Z)throw new Error("Selector must be a string.");if("function"!=typeof W)throw new Error("Callback must be a function.");this.stopSubscription(be,{matcher:function($){return Z?$.params.selector===Z&&$.callback===W:$.callback===W}})}},{key:"removeMessageListeners",value:function(Z){if("string"!=typeof Z)throw new Error("Selector must be a string.");this.stopSubscription(be,{matcher:function(W){return W.params.selector===Z}})}},{key:"removeAllMessageListeners",value:function(){this.stopSubscription(be,{})}},{key:"addCommandListener",value:function(Z,W){return(0,le.default)((0,pe.default)(r.prototype),"addCommandListener",this).call(this,Z,W),this}},{key:"addUserStatusListener",value:function(Z,W){return(0,le.default)((0,pe.default)(r.prototype),"addUserStatusListener",this).call(this,Z,W),this}},{key:"removeCommandListener",value:function(Z){return(0,le.default)((0,pe.default)(r.prototype),"removeCommandListeners",this).call(this,Z),this}},{key:"removeCommandListeners",value:function(Z){return(0,le.default)((0,pe.default)(r.prototype),"removeCommandListeners",this).call(this,Z),this}},{key:"removeUserStatusListeners",value:function(Z){return(0,le.default)((0,pe.default)(r.prototype),"removeUserStatusListeners",this).call(this,Z),this}},{key:"addConnectListener",value:function(Z,W){return(0,le.default)((0,pe.default)(r.prototype),"addConnectListener",this).call(this,Z,W),this}},{key:"removeConnectListeners",value:function(Z,W){return(0,le.default)((0,pe.default)(r.prototype),"removeConnectListeners",this).call(this,Z,W),this}},{key:"removeAllListeners",value:function(){return(0,le.default)((0,pe.default)(r.prototype),"removeAllListeners",this).call(this),this}},{key:"send",value:function(Z,W){return(0,le.default)((0,pe.default)(r.prototype),"send",this).call(this,Z,W)}},{key:"join",value:function(){(0,le.default)((0,pe.default)(r.prototype),"connect",this).call(this)}},{key:"leave",value:function(){(0,le.default)((0,pe.default)(r.prototype),"disconnect",this).call(this)}},{key:"isJoined",value:function(){return(0,le.default)((0,pe.default)(r.prototype),"isConnected",this).call(this)}}]),r}(ye.RTScopeConnector),(0,fe.default)(ee.prototype,"addMessageListener",[X],Object.getOwnPropertyDescriptor(ee.prototype,"addMessageListener"),ee.prototype),ee);W.default=_e},3695:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=(0,X.default)((function e(Z){(0,ee.default)(this,e),Z=Z||{},this.textmessage=Z&&Z.textmessage,this.htmlmessage=Z&&Z.htmlmessage}));W.default=ae},7314:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=(0,X.default)((function e(Z){(0,ee.default)(this,e),Z=Z||{},this.publishPolicy=Z.publishPolicy||void 0,this.pushBroadcast=Z.pushBroadcast||void 0,this.pushSinglecast=Z.pushSinglecast||void 0,this.publishAt=Z.publishAt||void 0,this.repeatEvery=Z.repeatEvery||void 0,this.repeatExpiresAt=Z.repeatExpiresAt||void 0}));W.default=ae},4595:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(9853)),ie=function(){function e(Z){(0,X.default)(this,e),Z=Z||{},this.addresses=ae.default.castArray(Z.addresses),this.ccAddresses=ae.default.castArray(Z.ccAddresses),this.bccAddresses=ae.default.castArray(Z.bccAddresses),this.query=Z.query||null,this.uniqueEmails=Z.uniqueEmails||!1}return(0,ee.default)(e,[{key:"setTo",value:function(Z){return this.addresses=ae.default.castArray(Z),this}},{key:"addTo",value:function(Z){return this.addresses=this.addresses.concat(ae.default.castArray(Z)),this}},{key:"getTo",value:function(){return this.addresses}},{key:"setCc",value:function(Z){return this.ccAddresses=ae.default.castArray(Z),this}},{key:"addCc",value:function(Z){return this.ccAddresses=this.ccAddresses.concat(ae.default.castArray(Z)),this}},{key:"getCc",value:function(){return this.ccAddresses}},{key:"setBcc",value:function(Z){return this.bccAddresses=ae.default.castArray(Z),this}},{key:"addBcc",value:function(Z){return this.bccAddresses=this.bccAddresses.concat(ae.default.castArray(Z)),this}},{key:"getBcc",value:function(){return this.bccAddresses}},{key:"setQuery",value:function(Z){return this.query=Z,this}},{key:"getQuery",value:function(){return this.query}},{key:"setUniqueEmails",value:function(Z){return this.uniqueEmails=Z,this}},{key:"getUniqueEmails",value:function(){return this.uniqueEmails}},{key:"toJSON",value:function(){var Z={};return this.addresses.length>0&&(Z.addresses=this.addresses),this.ccAddresses.length>0&&(Z["cc-addresses"]=this.ccAddresses),this.bccAddresses.length>0&&(Z["bcc-addresses"]=this.bccAddresses),this.query&&(Z.criteria=this.query),Z.uniqueEmails=this.uniqueEmails,Z}}],[{key:"create",value:function(Z){return new e(Z)}}]),e}();W.default=ie},5500:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),Object.defineProperty(W,"Bodyparts",{enumerable:!0,get:function(){return ie.default}}),Object.defineProperty(W,"DeliveryOptions",{enumerable:!0,get:function(){return ae.default}}),Object.defineProperty(W,"EmailEnvelope",{enumerable:!0,get:function(){return le.default}}),Object.defineProperty(W,"PublishOptions",{enumerable:!0,get:function(){return ee.default}}),Object.defineProperty(W,"PublishOptionsHeaders",{enumerable:!0,get:function(){return X.default}});var X=Y($(2545)),ee=Y($(2467)),ae=Y($(7314)),ie=Y($(3695)),le=Y($(4595))},2545:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0,W.default={MESSAGE_TAG:"message",IOS_ALERT_TAG:"ios-alert",IOS_BADGE_TAG:"ios-badge",IOS_SOUND_TAG:"ios-sound",ANDROID_TICKER_TEXT_TAG:"android-ticker-text",ANDROID_CONTENT_TITLE_TAG:"android-content-title",ANDROID_CONTENT_TEXT_TAG:"android-content-text",ANDROID_ACTION_TAG:"android-action",WP_TYPE_TAG:"wp-type",WP_TITLE_TAG:"wp-title",WP_TOAST_SUBTITLE_TAG:"wp-subtitle",WP_TOAST_PARAMETER_TAG:"wp-parameter",WP_TILE_BACKGROUND_IMAGE:"wp-backgroundImage",WP_TILE_COUNT:"wp-count",WP_TILE_BACK_TITLE:"wp-backTitle",WP_TILE_BACK_BACKGROUND_IMAGE:"wp-backImage",WP_TILE_BACK_CONTENT:"wp-backContent",WP_RAW_DATA:"wp-raw"}},2467:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(9728)),ee=Y($(6690)),ae=(0,X.default)((function e(Z){(0,ee.default)(this,e),Z=Z||{},this.publisherId=Z.publisherId||void 0,this.headers=Z.headers||void 0,this.subtopic=Z.subtopic||void 0}));W.default=ae},898:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(434)),ae=Y($(8698)),ie=Y($(7156)),le=Y($(6690)),ce=Y($(9728)),de=Y($(1127)),pe=$(5500),fe=function(){function e(Z){(0,le.default)(this,e),this.app=Z,this.Bodyparts=pe.Bodyparts,this.PublishOptions=pe.PublishOptions,this.DeliveryOptions=pe.DeliveryOptions,this.PublishOptionsHeaders=pe.PublishOptionsHeaders,this.EmailEnvelope=pe.EmailEnvelope}var Z,W,$,Y,fe,ye,be,_e,we,Se,xe;return(0,ce.default)(e,[{key:"subscribe",value:function(Z){return d(Z),new de.default({name:Z},this.app)}},{key:"publish",value:(xe=(0,ie.default)(X.default.mark((function e(Z,W,$,Y){var ie;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(d(Z),ie={message:W},!$){X.next=6;break}if(!Array.isArray($)&&"object"===(0,ae.default)($)){X.next=5;break}throw new Error('"publishOptions" argument must be an object.');case 5:(0,ee.default)(ie,$);case 6:if(!Y){X.next=10;break}if(!Array.isArray(Y)&&"object"===(0,ae.default)(Y)){X.next=9;break}throw new Error('"deliveryOptions" argument must be an object.');case 9:(0,ee.default)(ie,Y);case 10:return X.abrupt("return",this.app.request.post({url:this.app.urls.messagingChannel(Z),data:ie}));case 11:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y){return xe.apply(this,arguments)})},{key:"deleteChannel",value:(Se=(0,ie.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return d(Z),W.abrupt("return",this.app.request.delete({url:this.app.urls.messagingChannelName(Z)}));case 2:case"end":return W.stop()}}),e,this)}))),function(Z){return Se.apply(this,arguments)})},{key:"pushWithTemplate",value:(we=(0,ie.default)(X.default.mark((function e(Z,W){var $;return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&"string"==typeof Z){Y.next=2;break}throw new Error("Push Template Name must be provided and must be a string.");case 2:return $={},W&&($.templateValues=W),Y.abrupt("return",this.app.request.post({url:this.app.urls.messagingPushWithTemplate(Z),data:$}));case 5:case"end":return Y.stop()}}),e,this)}))),function(Z,W){return we.apply(this,arguments)})},{key:"sendEmail",value:(_e=(0,ie.default)(X.default.mark((function e(Z,W,$,Y){var ee;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error("Email Subject must be provided and must be a string.");case 2:if(W&&!Array.isArray(W)&&"object"===(0,ae.default)(W)){X.next=4;break}throw new Error("BodyParts must be an object");case 4:if(W.textmessage||W.htmlmessage){X.next=6;break}throw new Error("BodyParts must contain at least one property of [ textmessage | htmlmessage ]");case 6:if(Array.isArray($)&&$.length){X.next=8;break}throw new Error("Recipients must be a non empty array.");case 8:return ee={subject:Z,bodyparts:W,to:$},Array.isArray(Y)&&Y.length&&(ee.attachment=Y),X.abrupt("return",this.app.request.post({url:this.app.urls.messagingEmail(),data:ee}));case 11:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y){return _e.apply(this,arguments)})},{key:"sendEmailFromTemplate",value:(be=(0,ie.default)(X.default.mark((function e(Z,W,$,Y){var ee;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error("Email Template Name must be provided and must be a string.");case 2:if(W instanceof pe.EmailEnvelope){X.next=4;break}throw new Error("EmailEnvelope is required and should be instance of Backendless.Messaging.EmailEnvelope");case 4:return(ee=W.toJSON())["template-name"]=Z,$&&!Array.isArray($)&&(ee["template-values"]=$),Array.isArray($)&&!Y&&(Y=$),Y&&(ee.attachment=Y),X.abrupt("return",this.app.request.post({url:this.app.urls.emailTemplateSend(),data:ee}));case 10:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y){return be.apply(this,arguments)})},{key:"cancel",value:(ye=(0,ie.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Message ID must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.delete({url:this.app.urls.messagingMessage(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return ye.apply(this,arguments)})},{key:"registerDevice",value:(fe=(0,ie.default)(X.default.mark((function e(Z,W,$){var Y,ee;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:return Y=this.app.device,ee={deviceToken:Z,deviceId:Y.uuid,os:Y.platform,osVersion:Y.version},Array.isArray(W)&&(ee.channels=W),"number"==typeof $?ee.expiration=$:$ instanceof Date&&(ee.expiration=$.getTime()/1e3),X.abrupt("return",this.app.request.post({url:this.app.urls.messagingRegistrations(),data:ee}));case 5:case"end":return X.stop()}}),e,this)}))),function(Z,W,$){return fe.apply(this,arguments)})},{key:"getRegistrations",value:(Y=(0,ie.default)(X.default.mark((function e(){var Z;return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return Z=this.app.device,W.abrupt("return",this.app.request.get({url:this.app.urls.messagingRegistrationDevice(Z.uuid)}));case 2:case"end":return W.stop()}}),e,this)}))),function(){return Y.apply(this,arguments)})},{key:"unregisterDevice",value:($=(0,ie.default)(X.default.mark((function e(){var Z;return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return Z=this.app.device,W.abrupt("return",this.app.request.delete({url:this.app.urls.messagingRegistrationDevice(Z.uuid)}));case 2:case"end":return W.stop()}}),e,this)}))),function(){return $.apply(this,arguments)})},{key:"getMessageStatus",value:(W=(0,ie.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Message ID must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.get({url:this.app.urls.messagingMessage(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(Z){return W.apply(this,arguments)})},{key:"getPushTemplates",value:(Z=(0,ie.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:if(Z&&"string"==typeof Z){W.next=2;break}throw new Error("Device Type must be provided and must be a string.");case 2:return W.abrupt("return",this.app.request.get({url:this.app.urls.messagingPushTemplates(Z)}));case 3:case"end":return W.stop()}}),e,this)}))),function(W){return Z.apply(this,arguments)})}]),e}();function d(Z){if(!Z||"string"!=typeof Z)throw new Error("Channel Name must be provided and must be a string.");if(Z.indexOf("/")>=0)throw new Error("Channel Name can not contain slash chars")}W.Z=fe},394:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(8416)),ie="GRANT",le="DENY",ce=function(){function e(Z,W){(0,X.default)(this,e),this.permission=Z,this.app=W,this.grantUser=this.backwardCompatibility("grantForUser","grantUser"),this.denyUser=this.backwardCompatibility("denyForUser","denyUser"),this.grantRole=this.backwardCompatibility("grantForRole","grantRole"),this.denyRole=this.backwardCompatibility("denyForRole","denyRole"),this.grant=this.backwardCompatibility("grantForAllUsers","grant"),this.deny=this.backwardCompatibility("denyForAllUsers","deny")}return(0,ee.default)(e,[{key:"backwardCompatibility",value:function(Z,W){var $=this,Y=this.constructor.BACKWARD_COMPATIBILITY_LABEL;return function(){var X='"'.concat(Y,".").concat(W,'" is deprecated and will be removed in the nearest release.'),ee='Please use "'.concat(Y,".").concat(Z,'" instead of.');return console.warn("".concat(X,"\n").concat(ee)),$[Z].apply($,arguments)}}},{key:"grantForUser",value:function(Z,W){return this.sendRequest(ie,W,{userId:Z})}},{key:"denyForUser",value:function(Z,W){return this.sendRequest(le,W,{userId:Z})}},{key:"grantForRole",value:function(Z,W){return this.sendRequest(ie,W,{roleName:Z})}},{key:"denyForRole",value:function(Z,W){return this.sendRequest(le,W,{roleName:Z})}},{key:"grantForAllUsers",value:function(Z){return this.sendRequest(ie,Z,{userId:"*"})}},{key:"denyForAllUsers",value:function(Z){return this.sendRequest(le,Z,{userId:"*"})}},{key:"grantForAllRoles",value:function(Z){return this.sendRequest(ie,Z,{roleName:"*"})}},{key:"denyForAllRoles",value:function(Z){return this.sendRequest(le,Z,{roleName:"*"})}},{key:"sendRequest",value:function(Z,W,$){var Y=$.userId,X=$.roleName,ee={permission:this.permission};return Y?ee.user=Y:X&&(ee.role=X),this.app.request.put({url:this.getRequestURL(Z,W),data:ee})}},{key:"getRequestURL",value:function(){}}]),e}();W.default=ce,(0,ae.default)(ce,"BACKWARD_COMPATIBILITY_LABEL",null)},294:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(8416)),ee=Y($(6690)),ae=Y($(9728)),ie=Y($(3930));function u(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function c(Z){for(var W=1;W{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X,ee,ae,ie,le,ce,de,pe,fe,ye,be=Y($(861)),_e=Y($(6690)),we=Y($(9728)),Se=Y($(6115)),xe=Y($(1588)),Pe=Y($(1655)),Re=Y($(4993)),Te=Y($(3808)),Ie=Y($(8416)),qe=Y($(6877)),Ve=$(9181);function _(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function R(Z){for(var W=1;W1?W-1:0),Y=1;Y2?Y-2:0),ee=2;ee{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=Y($(5476)),ie=function(){function e(Z){(0,X.default)(this,e),this.app=Z}return(0,ee.default)(e,[{key:"connect",value:function(Z){return new ae.default({name:Z},this.app)}}]),e}();W.Z=ie},9181:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=W.RTScopeConnector=W.RTListeners=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(1655)),ce=Y($(4993)),de=Y($(3808)),pe=Y($(3930)),fe=Y($(5786)),ye=Y($(9853)),be=fe.default.Listeners;W.RTListeners=be;var _e=fe.default.ScopeConnector;function m(Z){return pe.default.get("".concat(Z,"/info"))}W.RTScopeConnector=_e;var we=function(Z){(0,le.default)(r,Z);var W=function h(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=(0,de.default)(Z);if(W){var X=(0,de.default)(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return(0,ce.default)(this,$)}}(r);function r(Z){var $;(0,ae.default)(this,r);var Y,ie=Z.appId,le=Z.apiKey,ce=Z.appPath,de=Z.debugMode,pe=ye.default.uuid(),fe="".concat(ce,"/rt/lookup");return($=W.call(this,{appId:ie||void 0,lookupPath:fe,debugMode:de,connectQuery:function(){var W=Z.getCurrentUserToken();return{apiKey:le||void 0,clientId:pe,userToken:W}},socketConfigTransform:(Y=(0,ee.default)(X.default.mark((function e(Z){var W;return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:if(ie){$.next=7;break}return $.next=3,m(ce);case 3:W=$.sent,Z.url="".concat(Z.host,"/").concat(W.appId),Z.options.path="/".concat(W.appId),Z.options.query.apiKey=W.apiKey;case 7:return $.abrupt("return",Z);case 8:case"end":return $.stop()}}),e)}))),function(Z){return Y.apply(this,arguments)})})).app=Z,$}return(0,ie.default)(r,[{key:"updateUserTokenIfNeeded",value:function(){if(this.session){var Z=this.app.getCurrentUserToken();this.methods.setUserToken({userToken:Z})}}},{key:"setDebugMode",value:function(Z){this.setConfig({debugMode:Z})}}]),r}(fe.default);W.default=we},4172:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.OperationType=W.IsolationLevelEnum=void 0,W.OperationType={CREATE:"CREATE",CREATE_BULK:"CREATE_BULK",UPDATE:"UPDATE",UPDATE_BULK:"UPDATE_BULK",DELETE:"DELETE",DELETE_BULK:"DELETE_BULK",UPSERT:"UPSERT",UPSERT_BULK:"UPSERT_BULK",FIND:"FIND",ADD_RELATION:"ADD_RELATION",SET_RELATION:"SET_RELATION",DELETE_RELATION:"DELETE_RELATION"},W.IsolationLevelEnum={READ_UNCOMMITTED:"READ_UNCOMMITTED",READ_COMMITTED:"READ_COMMITTED",REPEATABLE_READ:"REPEATABLE_READ",SERIALIZABLE:"SERIALIZABLE"}},7890:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=function(Z){return function(W){(0,pe.default)(n,W);var $=S(n);function n(W){return(0,ce.default)(this,n),$.call(this,W,Z)}return(0,de.default)(n,null,[{key:"initFromJSON",value:function(Z){var W=new this(Z.transactionIsolation);return Z.operations.forEach((function(Z){xe.OperationJSONAdapter[Z.operationType](W,Z).setOpResultId(Z.opResultId)})),W}}]),n}(Ve)};var X=Y($(4687)),ee=Y($(8698)),ae=Y($(7156)),ie=Y($(215)),le=Y($(8416)),ce=Y($(6690)),de=Y($(9728)),pe=Y($(1655)),fe=Y($(4993)),ye=Y($(3808)),be=Y($(3496)),_e=Y($(9853)),we=Y($(3082)),Se=$(4172),xe=$(5561),Pe=$(3687),Re=$(3106),Te=["meta"];function E(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function O(Z){for(var W=1;W0&&(Y.pageSize=$.pageSize),$.offset>0&&(Y.offset=$.offset),$.properties&&(Y.properties=$.properties),$.excludeProps&&(Y.excludeProps=$.excludeProps),$.excludeProps&&(Y.excludeProps=$.excludeProps),$.where&&(Y.whereClause=$.where),$.having&&(Y.havingClause=$.having),$.groupBy&&(Y.groupBy=$.groupBy),$.sortBy&&(Y.queryOptions.sortBy=$.sortBy),$.relations&&(Y.queryOptions.related=$.relations),$.relationsDepth&&(Y.queryOptions.relationsDepth=$.relationsDepth),$.relationsPageSize>0&&(Y.queryOptions.relationsPageSize=$.relationsPageSize),this.addOperations(Se.OperationType.FIND,Z,Y)}},{key:"upsert",value:function(){var Z,W;if(1===arguments.length)Z=_e.default.getClassName(arguments.length<=0?void 0:arguments[0]),W=arguments.length<=0?void 0:arguments[0];else{if(2!==arguments.length)throw new Error("Invalid arguments");Z=arguments.length<=0?void 0:arguments[0],W=arguments.length<=1?void 0:arguments[1]}if(!Z||"string"!=typeof Z)throw new Error("Invalid arguments");if(!W||"object"!==(0,ee.default)(W)||Array.isArray(W))throw new Error("Invalid arguments");return this.addOperations(Se.OperationType.UPSERT,Z,W)}},{key:"create",value:function(){var Z,W;if(1===arguments.length)Z=_e.default.getClassName(arguments.length<=0?void 0:arguments[0]),W=arguments.length<=0?void 0:arguments[0];else{if(2!==arguments.length)throw new Error("Invalid arguments");Z=arguments.length<=0?void 0:arguments[0],W=arguments.length<=1?void 0:arguments[1]}if(!Z||"string"!=typeof Z)throw new Error("Invalid arguments");if(!W||"object"!==(0,ee.default)(W)||Array.isArray(W))throw new Error("Invalid arguments");return this.addOperations(Se.OperationType.CREATE,Z,W)}},{key:"update",value:function(){for(var Z,W,$=arguments.length,Y=new Array($),X=0;X<$;X++)Y[X]=arguments[X];if(1===Y.length)Z=_e.default.getClassName(Y[0]),W=Y[0];else if(2===Y.length&&"string"==typeof Y[0])Z=Y[0],W=Y[1];else{if(!(Y[0]instanceof Pe.OpResult||Y[0]instanceof Re.OpResultValueReference))throw new Error("Invalid arguments");if(Z=Y[0].getTableName(),W={objectId:Y[0]},3===Y.length&&"string"==typeof Y[1])W[Y[1]]=Y[2];else{if(2!==Y.length)throw new Error("Invalid arguments");W=O(O({},W),Y[1])}}if(!Z||"string"!=typeof Z)throw new Error("Invalid arguments");return this.addOperations(Se.OperationType.UPDATE,Z,W)}},{key:"delete",value:function(){for(var Z,W,$=arguments.length,Y=new Array($),X=0;X<$;X++)Y[X]=arguments[X];if(1===Y.length)Y[0]instanceof Pe.OpResult||Y[0]instanceof Re.OpResultValueReference?(Z=Y[0].getTableName(),W=Y[0]):Y[0]&&"object"===(0,ee.default)(Y[0])&&!Array.isArray(Y[0])&&(Z=_e.default.getClassName(Y[0]),W=Y[0].objectId);else{if(2!==Y.length)throw new Error("Invalid arguments");Z=Y[0],W=Y[1]&&Y[1].objectId||Y[1]}if(!W||Array.isArray(W)||"string"!=typeof W&&"object"!==(0,ee.default)(W))throw new Error("Invalid arguments");if(!Z||"string"!=typeof Z)throw new Error("Table Name must be a string.");return this.addOperations(Se.OperationType.DELETE,Z,W)}},{key:"bulkUpsert",value:function(Z,W){if(Array.isArray(Z)&&(W=Z,Z=_e.default.getClassName(W[0])),!W||!Array.isArray(W))throw new Error("Objects must be an array of objects.");if(!Z||"string"!=typeof Z)throw new Error("Table Name must be a string.");return this.addOperations(Se.OperationType.UPSERT_BULK,Z,W)}},{key:"bulkCreate",value:function(Z,W){if(Array.isArray(Z)&&(W=Z,Z=_e.default.getClassName(W[0])),!W||!Array.isArray(W))throw new Error("Objects must be an array of objects.");if(!Z||"string"!=typeof Z)throw new Error("Table Name must be a string.");return this.addOperations(Se.OperationType.CREATE_BULK,Z,W)}},{key:"bulkUpdate",value:function(){for(var Z,W={},$=arguments.length,Y=new Array($),X=0;X<$;X++)Y[X]=arguments[X];if(2===Y.length)W.changes=Y[1],"string"==typeof Y[0]?(Z=_e.default.getClassName(Y[1]),W.conditional=Y[0]):Y[0]instanceof Pe.OpResult&&(Z=Y[0].getTableName(),W.unconditional=Y[0]);else{if(3!==Y.length)throw new Error("Invalid arguments");if(Z=Y[0],W.changes=Y[2],"string"==typeof Y[1])W.conditional=Y[1];else{if(!Array.isArray(Y[1]))throw new Error("Invalid arguments");W.unconditional=Y[1].map((function(Z){return Z.objectId||Z}))}}if(!Z||"string"!=typeof Z)throw new Error("Table Name must be a string.");return this.addOperations(Se.OperationType.UPDATE_BULK,Z,W)}},{key:"bulkDelete",value:function(){for(var Z,W={},$=arguments.length,Y=new Array($),X=0;X<$;X++)Y[X]=arguments[X];if(1===Y.length)if(Y[0]instanceof Pe.OpResult)Z=Y[0].getTableName(),W.unconditional=Y[0];else{if(!Array.isArray(Y[0]))throw new Error("Invalid arguments");Z=_e.default.getClassName(Y[0][0]),W.unconditional=Y[0].map((function(Z){return Z.objectId}))}else{if(2!==Y.length)throw new Error("Invalid arguments");if(Z=Y[0],"string"==typeof Y[1])W.conditional=Y[1];else{if(!Array.isArray(Y[1]))throw new Error("Invalid arguments");W.unconditional=Y[1].map((function(Z){return Z.objectId||Z}))}}if(!Z||"string"!=typeof Z)throw new Error("Table Name must be a string.");return this.addOperations(Se.OperationType.DELETE_BULK,Z,W)}},{key:"addToRelation",value:function(){for(var Z=arguments.length,W=new Array(Z),$=0;${"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.OperationJSONAdapter=void 0;var X=Y($(8698)),ee=$(4172),ae=$(3687);function a(Z,W){if(Array.isArray(W))return W.map((function(W){return a(Z,W)}));if(W&&"object"===(0,X.default)(W)){if(W.___ref){var $=Z.getOpResultById(W.opResultId);return void 0!==W.resultIndex?$.resolveTo(W.resultIndex,W.propName):void 0!==W.propName?$.resolveTo(W.propName):$}var Y={};for(var ee in W)Y[ee]=a(Z,W[ee]);return Y}return W}var ie={CREATE:function(Z,W){var $=W.table,Y=W.payload;return Z.create.call(Z,$,a(Z,Y))},DELETE:function(Z,W){var $=W.table,Y=W.payload;return Z.delete.call(Z,$,a(Z,Y))},UPDATE:function(Z,W){var $=W.table,Y=W.payload;return Z.update.call(Z,$,a(Z,Y))},UPSERT:function(Z,W){var $=W.table,Y=W.payload;return Z.upsert.call(Z,$,a(Z,Y))},UPDATE_BULK:function(Z,W){var $=W.table,Y=W.payload,X=c(Z,{table:$,payload:Y});return X.push(a(Z,Y.changes)),Z.bulkUpdate.apply(Z,X)},DELETE_BULK:function(Z,W){var $=c(Z,{table:W.table,payload:W.payload});return Z.bulkDelete.apply(Z,$)},CREATE_BULK:function(Z,W){var $=W.table,Y=W.payload;return Z.bulkCreate.call(Z,$,a(Z,Y))},UPSERT_BULK:function(Z,W){var $=W.table,Y=W.payload;return Z.bulkUpsert.call(Z,$,a(Z,Y))},SET_RELATION:function(Z,W){return l(Z,"setRelation",{table:W.table,payload:W.payload})},DELETE_RELATION:function(Z,W){return l(Z,"deleteRelation",{table:W.table,payload:W.payload})},ADD_RELATION:function(Z,W){return l(Z,"addToRelation",{table:W.table,payload:W.payload})},FIND:function(Z,W){var $=W.table,Y=W.payload;return Z.addOperations(ee.OperationType.FIND,$,Y)}};function c(Z,W){var $=W.table,Y=W.payload,X=[];if(Y.conditional)X.push($),X.push(Y.conditional);else{var ee=a(Z,Y.unconditional);ee instanceof ae.OpResult||X.push($),X.push(ee)}return X}function l(Z,W,$){var Y=$.table,X=$.payload,ee=[Y];return"string"==typeof X.parentObject?ee.push({objectId:X.parentObject}):ee.push(a(Z,X.parentObject)),ee.push(X.relationColumn),ee.push(X.conditional||a(Z,X.unconditional)),Z[W].apply(Z,ee)}W.OperationJSONAdapter=ie},3106:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.OpResultValueReference=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z,W){var $=W.resultIndex,Y=W.propName;(0,X.default)(this,e),this.opResult=Z,this.resultIndex=$,this.propName=Y}return(0,ee.default)(e,[{key:"getTableName",value:function(){return this.opResult.getTableName()}},{key:"toJSON",value:function(){var Z=this.opResult.toJSON();return void 0!==this.resultIndex&&(Z.resultIndex=this.resultIndex),void 0!==this.propName&&(Z.propName=this.propName),!Z.propName&&this.opResult.isFindRef()&&(Z.propName="objectId"),Z}}]),e}();W.OpResultValueReference=ae},3687:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.OpResult=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=$(4172),ie=$(3106),le=function(){function e(Z,W){var $=W.operationType,Y=W.table,ee=W.payload;(0,X.default)(this,e),this.uow=Z,this.operationType=$,this.table=Y,this.payload=ee;var ae=this.uow.getOpStackName($,Y),ie=this.uow.getNextOpResultIndex(ae);this.opResultId="".concat(ae).concat(ie),this.result=null}return(0,ee.default)(e,[{key:"setResult",value:function(Z){this.result=Z}},{key:"getResult",value:function(){return this.result}},{key:"setError",value:function(Z){this.error=Z}},{key:"getError",value:function(){return this.error}},{key:"getType",value:function(){return this.operationType}},{key:"isFindRef",value:function(){return this.operationType===ae.OperationType.FIND}},{key:"isCollectionRef",value:function(){return this.operationType===ae.OperationType.FIND||this.operationType===ae.OperationType.CREATE_BULK}},{key:"isObjectRef",value:function(){return this.operationType===ae.OperationType.CREATE||this.operationType===ae.OperationType.UPDATE||this.operationType===ae.OperationType.UPSERT}},{key:"setOpResultId",value:function(Z){return this.opResultId=Z,this}},{key:"getOpResultId",value:function(){return this.opResultId}},{key:"getTableName",value:function(){return this.table}},{key:"resolveTo",value:function(Z,W){return"string"==typeof Z&&(W=Z,Z=void 0),new ie.OpResultValueReference(this,{resultIndex:Z,propName:W})}},{key:"toJSON",value:function(){var Z={___ref:!0,opResultId:this.opResultId};return this.isObjectRef()&&(Z.propName="objectId"),Z}}]),e}();W.OpResult=le},435:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z){(0,X.default)(this,e),this.app=Z}return(0,ee.default)(e,[{key:"root",value:function(){return this.app.appPath}},{key:"automation",value:function(){return"".concat(this.root(),"/automation")}},{key:"automationFlow",value:function(){return"".concat(this.automation(),"/flow")}},{key:"automationFlowTrigger",value:function(){return"".concat(this.automationFlow(),"/trigger")}},{key:"blServices",value:function(){return"".concat(this.root(),"/services")}},{key:"blServiceMethod",value:function(Z,W){return"".concat(this.blServices(),"/").concat(Z,"/").concat(W)}},{key:"blEvent",value:function(Z){return"".concat(this.root(),"/servercode/events/").concat(Z)}},{key:"logging",value:function(){return"".concat(this.root(),"/log")}},{key:"loggingLevels",value:function(){return"".concat(this.logging(),"/logger")}},{key:"cache",value:function(){return"".concat(this.root(),"/cache")}},{key:"cacheItem",value:function(Z){return"".concat(this.cache(),"/").concat(Z)}},{key:"cacheItemExpireIn",value:function(Z){return"".concat(this.cacheItem(Z),"/expireIn")}},{key:"cacheItemExpireAt",value:function(Z){return"".concat(this.cacheItem(Z),"/expireAt")}},{key:"cacheItemCheck",value:function(Z){return"".concat(this.cacheItem(Z),"/check")}},{key:"counters",value:function(){return"".concat(this.root(),"/counters")}},{key:"countersList",value:function(Z){return"".concat(this.counters(),"/").concat(Z||"*","/list")}},{key:"counter",value:function(Z){return"".concat(this.counters(),"/").concat(Z)}},{key:"counterAddAndGet",value:function(Z){return"".concat(this.counter(Z),"/incrementby/get")}},{key:"counterGetAndAdd",value:function(Z){return"".concat(this.counter(Z),"/get/incrementby")}},{key:"counterIncrementAndGet",value:function(Z){return"".concat(this.counter(Z),"/increment/get")}},{key:"counterDecrementAndGet",value:function(Z){return"".concat(this.counter(Z),"/decrement/get")}},{key:"counterGetAndDecrement",value:function(Z){return"".concat(this.counter(Z),"/get/decrement")}},{key:"counterGetAndIncrement",value:function(Z){return"".concat(this.counter(Z),"/get/increment")}},{key:"counterCompareAndSet",value:function(Z){return"".concat(this.counter(Z),"/get/compareandset")}},{key:"counterReset",value:function(Z){return"".concat(this.counter(Z),"/reset")}},{key:"data",value:function(){return"".concat(this.root(),"/data")}},{key:"dataGrouping",value:function(Z){return"".concat(this.data(),"/data-grouping/").concat(Z)}},{key:"dataTable",value:function(Z){return"".concat(this.data(),"/").concat(Z)}},{key:"dataTableUpsert",value:function(Z){return"".concat(this.data(),"/").concat(Z,"/upsert")}},{key:"dataTableDeepSave",value:function(Z){return"".concat(this.data(),"/").concat(Z,"/deep-save")}},{key:"dataTableFind",value:function(Z){return"".concat(this.dataTable(Z),"/find")}},{key:"dataTablePrimaryKey",value:function(Z){return"".concat(this.dataTable(Z),"/pk")}},{key:"dataTableObject",value:function(Z,W){return"".concat(this.dataTable(Z),"/").concat(encodeURIComponent(W))}},{key:"dataTableObjectRelation",value:function(Z,W,$){return"".concat(this.dataTableObject(Z,W),"/").concat($)}},{key:"dataTableCount",value:function(Z){return"".concat(this.dataTable(Z),"/count")}},{key:"dataTableProps",value:function(Z){return"".concat(this.dataTable(Z),"/properties")}},{key:"dataBulkTable",value:function(Z){return"".concat(this.data(),"/bulk/").concat(Z)}},{key:"dataBulkTableUpsert",value:function(Z){return"".concat(this.data(),"/bulkupsert/").concat(Z)}},{key:"dataBulkTableDelete",value:function(Z){return"".concat(this.dataBulkTable(Z),"/delete")}},{key:"dataObjectPermission",value:function(Z,W,$){return"".concat(this.dataTable(Z),"/permissions/").concat(W,"/").concat($)}},{key:"dataTableNameById",value:function(Z){return"".concat(this.data(),"/").concat(Z,"/table-name")}},{key:"transactions",value:function(){return"".concat(this.root(),"/transaction/unit-of-work")}},{key:"dataHives",value:function(){return"".concat(this.root(),"/hive")}},{key:"dataHive",value:function(Z){return"".concat(this.dataHives(),"/").concat(Z)}},{key:"hiveStore",value:function(Z,W){return"".concat(this.dataHive(Z),"/").concat(W)}},{key:"messaging",value:function(){return"".concat(this.root(),"/messaging")}},{key:"messagingPush",value:function(){return"".concat(this.messaging(),"/push")}},{key:"messagingPushTemplates",value:function(Z){return"".concat(this.messaging(),"/pushtemplates/").concat(Z)}},{key:"messagingPushWithTemplate",value:function(Z){return"".concat(this.messagingPush(),"/").concat(Z)}},{key:"messagingEmail",value:function(){return"".concat(this.messaging(),"/email")}},{key:"messagingChannel",value:function(Z){return"".concat(this.messaging(),"/").concat(Z)}},{key:"messagingChannels",value:function(){return"".concat(this.messaging(),"/channels")}},{key:"messagingChannelName",value:function(Z){return"".concat(this.messagingChannels(),"/").concat(Z)}},{key:"messagingMessage",value:function(Z){return"".concat(this.messaging(),"/").concat(Z)}},{key:"messagingRegistrations",value:function(){return"".concat(this.messaging(),"/registrations")}},{key:"messagingRegistrationDevice",value:function(Z){return"".concat(this.messagingRegistrations(),"/").concat(Z)}},{key:"emailTemplate",value:function(){return"".concat(this.root(),"/emailtemplate")}},{key:"emailTemplateSend",value:function(){return"".concat(this.emailTemplate(),"/send")}},{key:"commerce",value:function(){return"".concat(this.root(),"/commerce/googleplay")}},{key:"commerceValidate",value:function(Z,W,$){return"".concat(this.commerce(),"/validate/").concat(Z,"/inapp/").concat(W,"/purchases/").concat($)}},{key:"commerceSubCancel",value:function(Z,W,$){return"".concat(this.commerce(),"/").concat(Z,"/subscription/").concat(W,"/purchases/").concat($,"/cancel")}},{key:"commerceSubStatus",value:function(Z,W,$){return"".concat(this.commerce(),"/").concat(Z,"/subscription/").concat(W,"/purchases/").concat($)}},{key:"files",value:function(){return"".concat(this.root(),"/files")}},{key:"filePath",value:function(Z){return"".concat(this.files(),"/").concat(Z)}},{key:"directoryPath",value:function(Z){return"".concat(this.files(),"/").concat(Z,"/")}},{key:"fileCopy",value:function(){return"".concat(this.files(),"/copy")}},{key:"fileMove",value:function(){return"".concat(this.files(),"/move")}},{key:"fileRename",value:function(){return"".concat(this.files(),"/rename")}},{key:"filePermissions",value:function(){return"".concat(this.files(),"/permissions")}},{key:"filePermission",value:function(Z,W){return"".concat(this.filePermissions(),"/").concat(Z,"/").concat(encodeURIComponent(W))}},{key:"fileBinaryPath",value:function(Z){return"".concat(this.files(),"/binary/").concat(Z)}},{key:"fileAppendPath",value:function(Z){return"".concat(this.files(),"/append/").concat(Z)}},{key:"fileAppendBinaryPath",value:function(Z){return"".concat(this.files(),"/append/binary/").concat(Z)}},{key:"users",value:function(){return"".concat(this.root(),"/users")}},{key:"userObject",value:function(Z){return"".concat(this.users(),"/").concat(Z)}},{key:"userRegister",value:function(){return"".concat(this.users(),"/register")}},{key:"userLogin",value:function(){return"".concat(this.users(),"/login")}},{key:"userLogout",value:function(){return"".concat(this.users(),"/logout")}},{key:"userRoles",value:function(Z){return"".concat(this.users(),"/userroles").concat(Z?"/".concat(Z):"")}},{key:"usersRole",value:function(Z){return"".concat(this.users(),"/role/").concat(Z)}},{key:"userRoleOperation",value:function(Z){return"".concat(this.users(),"/").concat(Z)}},{key:"userClassProps",value:function(){return"".concat(this.users(),"/userclassprops")}},{key:"userRestorePassword",value:function(Z){return"".concat(this.users(),"/restorepassword/").concat(encodeURIComponent(Z))}},{key:"userTokenCheck",value:function(Z){return"".concat(this.users(),"/isvalidusertoken/").concat(Z)}},{key:"userVerifyPassowrd",value:function(){return"".concat(this.users(),"/verifypassowrd")}},{key:"userResendConfirmation",value:function(Z){return"".concat(this.users(),"/resendconfirmation/").concat(Z)}},{key:"userCreateConfirmationURL",value:function(Z){return"".concat(this.users(),"/createEmailConfirmationURL/").concat(Z)}},{key:"userSocial",value:function(){return"".concat(this.users(),"/social")}},{key:"userSocialOAuth",value:function(Z){return"".concat(this.userSocial(),"/oauth/").concat(Z.toLowerCase(),"/request_url")}},{key:"userSocialLogin",value:function(Z){return"".concat(this.userSocial(),"/").concat(Z.toLowerCase(),"/sdk/login")}},{key:"userOAuthLogin",value:function(Z){return"".concat(this.userSocial(),"/").concat(Z.toLowerCase(),"/login")}},{key:"userAuthorizationURL",value:function(Z){return"".concat(this.users(),"/oauth/").concat(Z.toLowerCase(),"/request_url")}},{key:"guestLogin",value:function(){return"".concat(this.users(),"/register/guest")}},{key:"userStatus",value:function(Z){return"".concat(this.userObject(Z),"/status")}},{key:"management",value:function(){return"".concat(this.root(),"/management")}},{key:"managementData",value:function(){return"".concat(this.management(),"/data")}},{key:"managementDataTable",value:function(){return"".concat(this.managementData(),"/table")}}]),e}();W.default=ae},9935:(Z,W,$)=>{"use strict";var Y=$(4836);W.i=function(){var Z="NodeJS";X.default.isBrowser&&(Z=navigator.userAgent?navigator.userAgent.toLowerCase():"hybrid-app");var W=/(chrome)[ \/]([\w.]+)/.exec(Z)||/(webkit)[ \/]([\w.]+)/.exec(Z)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(Z)||/(msie) ([\w.]+)/.exec(Z)||Z.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(Z)||[],$={browser:W[1]||"",version:W[2]||"0"},Y={};return $.browser&&(Y[$.browser]=!0,Y.version=$.version),Y};var X=Y($(9853))},9681:(Z,W,$)=>{"use strict";var Y=$(4836);W.Z=void 0;var X=Y($(4687)),ee=Y($(8416)),ae=Y($(7156)),ie=Y($(6690)),le=Y($(9728)),ce=$(9211),de=Y($(5602)),pe=Y($(8332)),fe=Y($(1571));function d(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function h(Z){for(var W=1;W{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(4687)),ee=Y($(8698)),ae=Y($(7156)),ie=Y($(6690)),le=Y($(9728)),ce=Y($(3082)),de=function(){function e(Z){(0,ie.default)(this,e),this.users=Z,this.app=Z.app}var Z,W,$,Y,de;return(0,le.default)(e,[{key:"findByRole",value:(de=(0,ae.default)(X.default.mark((function e(Z,W,$){var Y,ae=this;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error("Role Name must be a string and can not be empty");case 2:if(null==W||"boolean"==typeof W){X.next=4;break}throw new Error('The second argument "loadRoles" can be a boolean only');case 4:if(null==$||!Array.isArray($)&&"object"===(0,ee.default)($)){X.next=6;break}throw new Error('The third argument "query" can be an instance of DataQueryBuilder or a plain object only');case 6:return Y=[],"boolean"==typeof W&&Y.push("loadRoles=".concat(W)),$&&Y.push(ce.default.toQueryString($)),X.abrupt("return",this.app.request.get({url:this.app.urls.usersRole(Z),queryString:Y.join("&")}).then((function(Z){return ae.users.dataStore.parseResponse(Z)})));case 10:case"end":return X.stop()}}),e,this)}))),function(Z,W,$){return de.apply(this,arguments)})},{key:"getUserRoles",value:(Y=(0,ae.default)(X.default.mark((function e(Z){return X.default.wrap((function(W){for(;;)switch(W.prev=W.next){case 0:return W.abrupt("return",this.app.request.get({url:this.app.urls.userRoles(Z)}));case 1:case"end":return W.stop()}}),e,this)}))),function(Z){return Y.apply(this,arguments)})},{key:"assignRole",value:($=(0,ae.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return $.abrupt("return",this.changeRole(Z,W,"assignRole"));case 1:case"end":return $.stop()}}),e,this)}))),function(Z,W){return $.apply(this,arguments)})},{key:"unassignRole",value:(W=(0,ae.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return $.abrupt("return",this.changeRole(Z,W,"unassignRole"));case 1:case"end":return $.stop()}}),e,this)}))),function(Z,$){return W.apply(this,arguments)})},{key:"changeRole",value:(Z=(0,ae.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(Z&&("string"==typeof Z||"number"==typeof Z)){Y.next=2;break}throw new Error("User identity must be a string or number and can not be empty.");case 2:if(W&&"string"==typeof W){Y.next=4;break}throw new Error("Role Name must be a string and can not be empty.");case 4:return Y.abrupt("return",this.app.request.post({url:this.app.urls.userRoleOperation($),data:{user:Z,roleName:W}}));case 5:case"end":return Y.stop()}}),e,this)}))),function(W,$,Y){return Z.apply(this,arguments)})}]),e}();W.default=de},870:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.SocialContainer=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z,W){(0,X.default)(this,e),this.socialType=Z,this.container=W,W?this.processContainer():this.createContainer()}return(0,ee.default)(e,[{key:"processContainer",value:function(){var Z,W=this,$=this.container[0]||this.container,Y=document.createElement("div");Y.innerHTML="Loading...",$.appendChild(Y),$.style.cursor="wait",this.closeContainer=function(){$.style.cursor="default",$.removeChild(Z)},this.removeLoading=function(){$.removeChild(Y)},this.doAuthorizationActivity=function(Y){W.removeLoading(),(Z=document.createElement("iframe")).frameBorder=0,Z.width=$.style.width,Z.height=$.style.height,Z.id="SocialAuthFrame",Z.setAttribute("src",Y+"&output=embed"),$.appendChild(Z),Z.onload=function(){$.style.cursor="default"}}}},{key:"createContainer",value:function(){var Z=window.open("",this.socialType+" authorization","resizable=yes, scrollbars=yes, titlebar=yes, top=10, left=10");Z.document.getElementsByTagName("body")[0].innerHTML="Loading...",Z.document.getElementsByTagName("html")[0].style.cursor="wait",this.closeContainer=function(){Z.close()},this.doAuthorizationActivity=function(W){Z.location.href=W,Z.onload=function(){Z.document.getElementsByTagName("html")[0].style.cursor="default"}}}}]),e}();W.SocialContainer=ae},1571:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(4687)),ee=Y($(7156)),ae=Y($(6690)),ie=Y($(9728)),le=Y($(5602)),ce=$(870),de=function(){function e(Z){(0,ae.default)(this,e),this.users=Z,this.app=Z.app}var Z,W,$,Y,de,pe,fe,ye,be;return(0,ie.default)(e,[{key:"loginWithFacebook",value:(be=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:return Y.abrupt("return",this.loginWithContainer("facebook",Z,W,null,$));case 1:case"end":return Y.stop()}}),e,this)}))),function(Z,W,$){return be.apply(this,arguments)})},{key:"loginWithGooglePlus",value:(ye=(0,ee.default)(X.default.mark((function e(Z,W,$,Y){return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:return X.abrupt("return",this.loginWithContainer("googleplus",Z,W,$,Y));case 1:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,Y){return ye.apply(this,arguments)})},{key:"loginWithTwitter",value:(fe=(0,ee.default)(X.default.mark((function e(Z,W){return X.default.wrap((function($){for(;;)switch($.prev=$.next){case 0:return $.abrupt("return",this.loginWithContainer("twitter",Z,null,null,W));case 1:case"end":return $.stop()}}),e,this)}))),function(Z,W){return fe.apply(this,arguments)})},{key:"loginWithFacebookSdk",value:(pe=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:return Y.abrupt("return",this.sendWithAccessToken("facebook",Z,W,$));case 1:case"end":return Y.stop()}}),e,this)}))),function(Z,W,$){return pe.apply(this,arguments)})},{key:"loginWithGooglePlusSdk",value:(de=(0,ee.default)(X.default.mark((function e(Z,W,$){return X.default.wrap((function(Y){for(;;)switch(Y.prev=Y.next){case 0:return Y.abrupt("return",this.sendWithAccessToken("googleplus",Z,W,$));case 1:case"end":return Y.stop()}}),e,this)}))),function(Z,W,$){return de.apply(this,arguments)})},{key:"sendWithAccessToken",value:(Y=(0,ee.default)(X.default.mark((function e(Z,W,$,Y){var ee=this;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(W&&"string"==typeof W){X.next=2;break}throw new Error('"accessToken" must be non empty string.');case 2:return"boolean"==typeof $&&(Y=$,$=void 0),X.abrupt("return",this.app.request.post({url:this.app.urls.userSocialLogin(Z),data:{accessToken:W,fieldsMapping:$}}).then((function(Z){return ee.users.setCurrentUser(Z,Y)})));case 4:case"end":return X.stop()}}),e,this)}))),function(Z,W,$,X){return Y.apply(this,arguments)})},{key:"loginWithContainer",value:($=(0,ee.default)(X.default.mark((function e(Z,W,$,Y,ee){var ae,ie,le=this;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:return ae=new ce.SocialContainer(Z,Y),ie=function(){return new Promise((function(Z,W){f("message",window,(function r($){if($.origin===le.app.serverURL){var Y=JSON.parse($.data);Y.fault?W(new Error(Y.fault)):Z(Y),p("message",window,r),ae.closeContainer()}}))}))},X.abrupt("return",this.app.request.post({url:this.app.urls.userSocialOAuth(Z),data:{fieldsMapping:W||{},permissions:$||[]}}).then((function(Z){return ae.doAuthorizationActivity(Z)})).catch((function(Z){throw ae.closeContainer(),Z})).then(ie).then((function(Z){return le.users.setCurrentUser(Z,ee)})));case 3:case"end":return X.stop()}}),e,this)}))),function(Z,W,Y,X,ee){return $.apply(this,arguments)})},{key:"loginWithOauth2",value:(W=(0,ee.default)(X.default.mark((function e(Z,W,$,Y,ee){var ae=this;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"providerCode" must be non empty string.');case 2:if(W&&"string"==typeof W){X.next=4;break}throw new Error('"accessToken" must be non empty string.');case 4:return!$||$ instanceof le.default||(ee=Y,Y=$,$=void 0),"boolean"==typeof Y&&(ee=Y,Y=void 0),X.abrupt("return",this.app.request.post({url:this.app.urls.userOAuthLogin(Z),data:{accessToken:W,fieldsMapping:Y,guestUser:$}}).then((function(Z){return ae.users.setCurrentUser(Z,ee)})));case 7:case"end":return X.stop()}}),e,this)}))),function(Z,$,Y,X,ee){return W.apply(this,arguments)})},{key:"loginWithOauth1",value:(Z=(0,ee.default)(X.default.mark((function e(Z,W,$,Y,ee,ae){var ie=this;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(Z&&"string"==typeof Z){X.next=2;break}throw new Error('"providerCode" must be non empty string.');case 2:if(W&&"string"==typeof W){X.next=4;break}throw new Error('"accessToken" must be non empty string.');case 4:if($&&"string"==typeof $){X.next=6;break}throw new Error('"accessTokenSecret" must be non empty string.');case 6:return!Y||Y instanceof le.default||(ae=ee,ee=Y,Y=void 0),"boolean"==typeof ee&&(ae=ee,ee=void 0),X.abrupt("return",this.app.request.post({url:this.app.urls.userOAuthLogin(Z),data:{accessToken:W,accessTokenSecret:$,fieldsMapping:ee,guestUser:Y}}).then((function(Z){return ie.users.setCurrentUser(Z,ae)})));case 9:case"end":return X.stop()}}),e,this)}))),function(W,$,Y,X,ee,ae){return Z.apply(this,arguments)})}]),e}();function f(Z,W,$){W.addEventListener?W.addEventListener(Z,$,!1):W.attachEvent?W.attachEvent("on"+Z,$):W[Z]=$}function p(Z,W,$){W.removeEventListener?W.removeEventListener(Z,$,!1):W.detachEvent&&W.detachEvent("on"+Z,$),W[Z]=null}W.default=de},5602:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(6690)),ee=Y($(9728)),ae=function(){function e(Z){var W=this;(0,X.default)(this,e),Z=Z||{},Object.keys(Z).map((function($){W[$]=Z[$]})),this.___class=e.className}return(0,ee.default)(e,null,[{key:"className",get:function(){return"Users"}}]),e}();W.default=ae,ae.prototype.___class=ae.className},9211:(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.UsersUtils=void 0;var $={getClientUserLocale:function(){if("undefined"!=typeof navigator)return(navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.userLanguage||navigator.language||navigator.browserLanguage||navigator.systemLanguage||"").slice(0,2).toLowerCase()}};W.UsersUtils=$},9853:(Z,W,$)=>{"use strict";var Y=$(4836);Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($(8698)),ee={isBrowser:i(),isLocalStorageSupported:function(){try{if(i()&&window.localStorage)return localStorage.setItem("localStorageTest",!0),localStorage.removeItem("localStorageTest"),!0}catch(Z){}return!1}(),globalScope:"object"===("undefined"==typeof self?"undefined":(0,X.default)(self))&&self.self===self&&self||"object"===(void 0===$.g?"undefined":(0,X.default)($.g))&&$.g.global===$.g&&$.g,castArray:function(Z){return Array.isArray(Z)?Z:void 0===Z?[]:[Z]},isCustomClassInstance:function(Z){return!(!Z||"object"!==(0,X.default)(Z)||Array.isArray(Z))&&Z.constructor!==Object},getClassName:function(Z){if(Z&&Z.className)return Z.className;if("function"==typeof Z&&Z.name)return Z.name;if(Z&&"object"===(0,X.default)(Z)&&!Array.isArray(Z)){if(Z.___class)return Z.___class;if(Z.constructor!==Object)return ee.getClassName(Z.constructor)}return null},uuid:function(){var e=function(){return Math.random().toString(16).slice(-4).toUpperCase()};return"".concat("".concat(e()).concat(e()),"-").concat(e(),"-").concat(e(),"-").concat(e(),"-").concat("".concat(e()).concat(e()).concat(e()))},isObject:function(Z){return null!=Z&&"Object"===Z.constructor.name}};function i(){return"object"===("undefined"==typeof self?"undefined":(0,X.default)(self))&&self.self===self&&"object"===("undefined"==typeof window?"undefined":(0,X.default)(window))&&window===self}var ae=ee;W.default=ae},3930:function(ee,ae){var ie;"undefined"!=typeof self&&self,ie=function(){return function(Z){var W={};function r($){if(W[$])return W[$].exports;var Y=W[$]={i:$,l:!1,exports:{}};return Z[$].call(Y.exports,Y,Y.exports,r),Y.l=!0,Y.exports}return r.m=Z,r.c=W,r.d=function(Z,W,$){r.o(Z,W)||Object.defineProperty(Z,W,{configurable:!1,enumerable:!0,get:$})},r.n=function(Z){var W=Z&&Z.__esModule?function(){return Z.default}:function(){return Z};return r.d(W,"a",W),W},r.o=function(Z,W){return Object.prototype.hasOwnProperty.call(Z,W)},r.p="",r(r.s=3)}([function(Z,W,$){"use strict";(function(Z){function n(Z){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(Z){return typeof Z}:function(Z){return Z&&"function"==typeof Symbol&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z})(Z)}Object.defineProperty(W,"__esModule",{value:!0}),W.castArray=void 0,W.getFormData=i,W.isStream=W.isObject=W.isNodeJS=W.isFormData=W.isBrowser=void 0,W.setFormData=function(Z){X=Z},W.castArray=function(Z){return Array.isArray(Z)?Z:[Z]},W.isObject=function(Z){return null!=Z&&"object"===n(Z)},W.isFormData=function(Z){return!!Z&&(Z instanceof i()||Z&&Z.constructor&&0===Z.constructor.toString().trim().indexOf("function FormData"))},W.isStream=function(Z){return Z instanceof $(6).Stream};var Y=W.isNodeJS=function(){return void 0!==Z&&null!=Z.versions&&null!=Z.versions.node},X=(W.isBrowser=function(){return"undefined"!=typeof window&&void 0!==window.document},null);function i(){return X||(Y()||"undefined"==typeof FormData?$(7):FormData)}}).call(W,$(5))},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W,$){"use strict";function n(Z){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(Z){return typeof Z}:function(Z){return Z&&"function"==typeof Symbol&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z})(Z)}Object.defineProperty(W,"__esModule",{value:!0}),W.Request=void 0;var Y,X=$(12),ee=(Y=$(13))&&Y.__esModule?Y:{default:Y},ae=function(Z,W){if(Z&&Z.__esModule)return Z;if(null===Z||"object"!==n(Z)&&"function"!=typeof Z)return{default:Z};var $=l(W);if($&&$.has(Z))return $.get(Z);var Y={},X=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ee in Z)if("default"!==ee&&Object.prototype.hasOwnProperty.call(Z,ee)){var ae=X?Object.getOwnPropertyDescriptor(Z,ee):null;ae&&(ae.get||ae.set)?Object.defineProperty(Y,ee,ae):Y[ee]=Z[ee]}return Y.default=Z,$&&$.set(Z,Y),Y}($(14)),ie=$(0),le=$(15);function l(Z){if("function"!=typeof WeakMap)return null;var W=new WeakMap,$=new WeakMap;return(l=function(Z){return Z?$:W})(Z)}function f(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function p(Z){for(var W=1;W=200&&Z.status<300)return Z;throw new le.ResponseError(Z)}W.Request=function(Z){!function(Z,W){if("function"!=typeof W&&null!==W)throw new TypeError("Super expression must either be null or a function");Z.prototype=Object.create(W&&W.prototype,{constructor:{value:Z,writable:!0,configurable:!0}}),Object.defineProperty(Z,"prototype",{writable:!1}),W&&v(Z,W)}(i,Z);var W,$,Y=function m(Z){var W=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(Z){return!1}}();return function(){var $,Y=g(Z);if(W){var X=g(this).constructor;$=Reflect.construct(Y,arguments,X)}else $=Y.apply(this,arguments);return b(this,$)}}(i);function i(Z,W,$){var X;return function(Z,W){if(!(Z instanceof W))throw new TypeError("Cannot call a class as a function")}(this,i),(X=Y.call(this)).method=W,X.path=Z,X.body=$,X.tags=void 0,X.unwrap=!0,X.cacheTTL=0,X.headers={},X.queryParams={},X.encoding="utf8",X.timeout=0,X.withCredentials=null,X}return W=i,($=[{key:"set",value:function(Z,W){if((0,ie.isObject)(Z))for(var $ in Z)this.set($,Z[$]);else void 0!==W&&(this.headers[Z]=W);return this}},{key:"cacheTags",value:function(){for(var Z=arguments.length,W=new Array(Z),$=0;$0&&void 0!==arguments[0]?arguments[0]:15e3;return this.cacheTTL=Z,this}},{key:"resetCache",value:function(Z){return Z&&this.tags&&X.cache.deleteByTags(this.tags),this}},{key:"type",value:function(Z){return this.set("Content-Type",Z),this}},{key:"unwrapBody",value:function(Z){return this.unwrap=Z,this}},{key:"setEncoding",value:function(Z){return this.encoding=Z,this}},{key:"setWithCredentials",value:function(Z){return this.withCredentials=Z,this}},{key:"setTimeout",value:function(Z){return this.timeout=Z,this}},{key:"send",value:function(Z){var W=this;this.emit("request",this);var $=this.path,Y=ae.stringify(this.queryParams);if(Y&&($+="?"+Y),this.cacheTTL){var ee=X.cache.get($);if(void 0!==ee)return Promise.resolve(ee)}this.headers["Content-Type"]||!(0,ie.isObject)(Z)||(0,ie.isFormData)(Z)||this.type("application/json"),Z&&(Z="application/json"===this.headers["Content-Type"]&&"string"!=typeof Z?JSON.stringify(Z):Z),i.verbose&&console.log(this.method.toUpperCase(),decodeURIComponent($),Z,this.headers);var le="boolean"==typeof this.withCredentials?this.withCredentials:i.withCredentials,ce=i.send($,this.method.toUpperCase(),this.headers,Z,this.encoding,this.timeout,le).then(w).then(k).then((function(Z){return W.unwrap?Z.body:Z})).then((function(Z){return W.cacheTTL&&X.cache.set($,Z,W.tags,W.cacheTTL),Z})).then((function(Z){return W.tags&&"get"!==W.method&&X.cache.deleteByTags(W.tags),Z}));return ce.then((function(Z){W.emit("response",Z),W.emit("done",null,Z)})).catch((function(Z){W.emit("error",Z),W.emit("done",Z)})),ce}},{key:"then",value:function(Z,W){return this.promise=this.promise||this.send(this.body),this.promise.then(Z,W)}},{key:"catch",value:function(Z){return this.promise=this.promise||this.send(this.body),this.promise.catch(Z)}}])&&h(W.prototype,$),Object.defineProperty(W,"prototype",{writable:!1}),i}(ee.default)},function(Z,W,$){"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var Y=$(4),X=$(11),ee=$(2),ae=$(0);Object.defineProperty(ee.Request,"FormData",{get:function(){return(0,ae.getFormData)()},set:function(Z){(0,ae.setFormData)(Z)}}),ee.Request.XMLHttpRequest="undefined"!=typeof XMLHttpRequest?XMLHttpRequest:void 0,ee.Request.send=function(Z,W,$,ae,ie,le,ce){return(void 0!==ee.Request.XMLHttpRequest?X.sendXmlHttpRequest:Y.sendNodeAPIRequest)(Z,W,$,ae,ie,le,ce)},ee.Request.verbose=!1,ee.Request.withCredentials=!1,ee.Request.methods=["get","post","put","patch","delete"],ee.Request.methods.forEach((function(Z){ee.Request[Z]=function(W,$){return new ee.Request(W,Z,$)}})),(W=Z.exports=ee.Request).default=ee.Request},function(Z,W,$){"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.sendNodeAPIRequest=function(Z,W,X,ee,ae,ie,le){return new Promise((function(ce,de){var pe=$(8).parse(Z),fe=(0,Y.isFormData)(ee)&&ee,ye="https:"===pe.protocol,be={host:pe.hostname,port:pe.port||(ye?443:80),path:pe.pathname+(pe.search||""),method:W,headers:X,timeout:ie};"boolean"==typeof le&&(be.withCredentials=le);var y=function(){var Z=$(1).Buffer,W=$(ye?9:10).request(be,(function(W){var $=[],Y=[],X=0,ee="",ie=W.statusCode,le=W.statusMessage,pe=W.headers;W.on("data",(function(W){Z.isBuffer(W)?W.length&&(X+=W.length,Y.push(W)):$.push(W)})),W.on("end",(function(){X?(ee=Z.concat(Y,X),null!=ae&&(ee=ee.toString(ae))):$.length&&(ee=$.join()),ce({status:ie,statusText:le,headers:pe,body:ee})})),W.on("error",de)}));if(W.on("error",de),W.on("timeout",(function(){W.destroy(new Error("Connection aborted due to timeout"))})),ee){if((0,Y.isStream)(ee))return void ee.pipe(W);W.write(ee)}W.end()};if(fe)Object.assign(be.headers,fe.getHeaders()),fe.getLength((function(Z,W){Z||isNaN(W)||(be.headers["content-length"]=W),y()}));else{if(ee&&!be.headers["content-length"]){var _e=$(1).Buffer;be.headers["content-length"]=_e.byteLength(ee)}y()}}))};var Y=$(0)},function(Z,W){var $,Y,X=Z.exports={};function s(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(Z){if($===setTimeout)return setTimeout(Z,0);if(($===s||!$)&&setTimeout)return $=setTimeout,setTimeout(Z,0);try{return $(Z,0)}catch(W){try{return $.call(null,Z,0)}catch(W){return $.call(this,Z,0)}}}!function(){try{$="function"==typeof setTimeout?setTimeout:s}catch(Z){$=s}try{Y="function"==typeof clearTimeout?clearTimeout:i}catch(Z){Y=i}}();var ee,ae=[],ie=!1,le=-1;function p(){ie&&ee&&(ie=!1,ee.length?ae=ee.concat(ae):le=-1,ae.length&&d())}function d(){if(!ie){var Z=a(p);ie=!0;for(var W=ae.length;W;){for(ee=ae,ae=[];++le1)for(var $=1;$=Z.length?{done:!0}:{done:!1,value:Z[Y++]}},e:function(Z){throw Z},f:o}}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 X,ee=!0,ae=!1;return{s:function(){$=$.call(Z)},n:function(){var Z=$.next();return ee=Z.done,Z},e:function(Z){ae=!0,X=Z},f:function(){try{ee||null==$.return||$.return()}finally{if(ae)throw X}}}}function i(Z,W){if(Z){if("string"==typeof Z)return a(Z,W);var $=Object.prototype.toString.call(Z).slice(8,-1);return"Object"===$&&Z.constructor&&($=Z.constructor.name),"Map"===$||"Set"===$?Array.from(Z):"Arguments"===$||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test($)?a(Z,W):void 0}}function a(Z,W){(null==W||W>Z.length)&&(W=Z.length);for(var $=0,Y=new Array(W);$c())return W.value;this.map.delete(Z)}}},{key:"set",value:function(Z,W,$,Y){this.map.set(Z,function(Z,W,$){return{value:Z,tags:W,ttl:$}}(W,$,c()+Y)),this.flushInterval&&!this.flushTimer&&(this.flushTimer=setInterval(this.flush.bind(this),this.flushInterval),this.flushTimer.unref&&this.flushTimer.unref())}},{key:"delete",value:function(Z){this.map.delete(Z)}},{key:"deleteAll",value:function(){var Z,W=s(this.map);try{for(W.s();!(Z=W.n()).done;){var $=o(Z.value,1)[0];this.delete($)}}catch(Z){W.e(Z)}finally{W.f()}}},{key:"deleteByTags",value:function(Z){var W,$=s(this.map);try{for($.s();!(W=$.n()).done;){var Y=o(W.value,2),X=Y[0],ee=Y[1];ee.tags&&l(Z,ee.tags)&&this.delete(X)}}catch(Z){$.e(Z)}finally{$.f()}}},{key:"flush",value:function(){var Z,W=c(),$=s(this.map);try{for($.s();!(Z=$.n()).done;){var Y=o(Z.value,2),X=Y[0];Y[1].ttl1?W-1:0),Y=1;Y{var $,Y,X,ee;self,ee=()=>(()=>{var Z={"./node_modules/@babel/runtime/helpers/applyDecoratedDescriptor.js":Z=>{Z.exports=function(Z,W,$,Y,X){var ee={};return Object.keys(Y).forEach((function(Z){ee[Z]=Y[Z]})),ee.enumerable=!!ee.enumerable,ee.configurable=!!ee.configurable,("value"in ee||ee.initializer)&&(ee.writable=!0),ee=$.slice().reverse().reduce((function($,Y){return Y(Z,W,$)||$}),ee),X&&void 0!==ee.initializer&&(ee.value=ee.initializer?ee.initializer.call(X):void 0,ee.initializer=void 0),void 0===ee.initializer&&(Object.defineProperty(Z,W,ee),ee=null),ee},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/assertThisInitialized.js":Z=>{Z.exports=function(Z){if(void 0===Z)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return Z},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/asyncToGenerator.js":Z=>{function t(Z,W,$,Y,X,ee,ae){try{var ie=Z[ee](ae),le=ie.value}catch(Z){return void $(Z)}ie.done?W(le):Promise.resolve(le).then(Y,X)}Z.exports=function(Z){return function(){var W=this,$=arguments;return new Promise((function(Y,X){var ee=Z.apply(W,$);function a(Z){t(ee,Y,X,a,u,"next",Z)}function u(Z){t(ee,Y,X,a,u,"throw",Z)}a(void 0)}))}},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/classCallCheck.js":Z=>{Z.exports=function(Z,W){if(!(Z instanceof W))throw new TypeError("Cannot call a class as a function")},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/createClass.js":Z=>{function t(Z,W){for(var $=0;${Z.exports=function(Z,W,$){return W in Z?Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}):Z[W]=$,Z},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/get.js":(Z,W,$)=>{var Y=$("./node_modules/@babel/runtime/helpers/superPropBase.js");function o(){return"undefined"!=typeof Reflect&&Reflect.get?(Z.exports=o=Reflect.get.bind(),Z.exports.__esModule=!0,Z.exports.default=Z.exports):(Z.exports=o=function(Z,W,$){var X=Y(Z,W);if(X){var ee=Object.getOwnPropertyDescriptor(X,W);return ee.get?ee.get.call(arguments.length<3?Z:$):ee.value}},Z.exports.__esModule=!0,Z.exports.default=Z.exports),o.apply(this,arguments)}Z.exports=o,Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/getPrototypeOf.js":Z=>{function t(W){return Z.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(Z){return Z.__proto__||Object.getPrototypeOf(Z)},Z.exports.__esModule=!0,Z.exports.default=Z.exports,t(W)}Z.exports=t,Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/inherits.js":(Z,W,$)=>{var Y=$("./node_modules/@babel/runtime/helpers/setPrototypeOf.js");Z.exports=function(Z,W){if("function"!=typeof W&&null!==W)throw new TypeError("Super expression must either be null or a function");Z.prototype=Object.create(W&&W.prototype,{constructor:{value:Z,writable:!0,configurable:!0}}),Object.defineProperty(Z,"prototype",{writable:!1}),W&&Y(Z,W)},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/interopRequireDefault.js":Z=>{Z.exports=function(Z){return Z&&Z.__esModule?Z:{default:Z}},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/possibleConstructorReturn.js":(Z,W,$)=>{var Y=$("./node_modules/@babel/runtime/helpers/typeof.js").default,X=$("./node_modules/@babel/runtime/helpers/assertThisInitialized.js");Z.exports=function(Z,W){if(W&&("object"===Y(W)||"function"==typeof W))return W;if(void 0!==W)throw new TypeError("Derived constructors may only return object or undefined");return X(Z)},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/regeneratorRuntime.js":(Z,W,$)=>{var Y=$("./node_modules/@babel/runtime/helpers/typeof.js").default;function o(){"use strict";Z.exports=o=function(){return W},Z.exports.__esModule=!0,Z.exports.default=Z.exports;var W={},$=Object.prototype,X=$.hasOwnProperty,ee="function"==typeof Symbol?Symbol:{},ae=ee.iterator||"@@iterator",ie=ee.asyncIterator||"@@asyncIterator",le=ee.toStringTag||"@@toStringTag";function l(Z,W,$){return Object.defineProperty(Z,W,{value:$,enumerable:!0,configurable:!0,writable:!0}),Z[W]}try{l({},"")}catch(Z){l=function(Z,W,$){return Z[W]=$}}function f(Z,W,$,Y){var X=W&&W.prototype instanceof h?W:h,ee=Object.create(X.prototype),ae=new R(Y||[]);return ee._invoke=function(Z,W,$){var Y="suspendedStart";return function(X,ee){if("executing"===Y)throw new Error("Generator is already running");if("completed"===Y){if("throw"===X)throw ee;return{value:void 0,done:!0}}for($.method=X,$.arg=ee;;){var ae=$.delegate;if(ae){var ie=O(ae,$);if(ie){if(ie===ce)continue;return ie}}if("next"===$.method)$.sent=$._sent=$.arg;else if("throw"===$.method){if("suspendedStart"===Y)throw Y="completed",$.arg;$.dispatchException($.arg)}else"return"===$.method&&$.abrupt("return",$.arg);Y="executing";var le=p(Z,W,$);if("normal"===le.type){if(Y=$.done?"completed":"suspendedYield",le.arg===ce)continue;return{value:le.arg,done:$.done}}"throw"===le.type&&(Y="completed",$.method="throw",$.arg=le.arg)}}}(Z,$,ae),ee}function p(Z,W,$){try{return{type:"normal",arg:Z.call(W,$)}}catch(Z){return{type:"throw",arg:Z}}}W.wrap=f;var ce={};function h(){}function y(){}function v(){}var de={};l(de,ae,(function(){return this}));var pe=Object.getPrototypeOf,fe=pe&&pe(pe(x([])));fe&&fe!==$&&X.call(fe,ae)&&(de=fe);var ye=v.prototype=h.prototype=Object.create(de);function k(Z){["next","throw","return"].forEach((function(W){l(Z,W,(function(Z){return this._invoke(W,Z)}))}))}function E(Z,W){var $;this._invoke=function(ee,ae){function a(){return new W((function($,ie){!function r($,ee,ae,ie){var le=p(Z[$],Z,ee);if("throw"!==le.type){var ce=le.arg,de=ce.value;return de&&"object"==Y(de)&&X.call(de,"__await")?W.resolve(de.__await).then((function(Z){r("next",Z,ae,ie)}),(function(Z){r("throw",Z,ae,ie)})):W.resolve(de).then((function(Z){ce.value=Z,ae(ce)}),(function(Z){return r("throw",Z,ae,ie)}))}ie(le.arg)}(ee,ae,$,ie)}))}return $=$?$.then(a,a):a()}}function O(Z,W){var $=Z.iterator[W.method];if(void 0===$){if(W.delegate=null,"throw"===W.method){if(Z.iterator.return&&(W.method="return",W.arg=void 0,O(Z,W),"throw"===W.method))return ce;W.method="throw",W.arg=new TypeError("The iterator does not provide a 'throw' method")}return ce}var Y=p($,Z.iterator,W.arg);if("throw"===Y.type)return W.method="throw",W.arg=Y.arg,W.delegate=null,ce;var X=Y.arg;return X?X.done?(W[Z.resultName]=X.value,W.next=Z.nextLoc,"return"!==W.method&&(W.method="next",W.arg=void 0),W.delegate=null,ce):X:(W.method="throw",W.arg=new TypeError("iterator result is not an object"),W.delegate=null,ce)}function S(Z){var W={tryLoc:Z[0]};1 in Z&&(W.catchLoc=Z[1]),2 in Z&&(W.finallyLoc=Z[2],W.afterLoc=Z[3]),this.tryEntries.push(W)}function _(Z){var W=Z.completion||{};W.type="normal",delete W.arg,Z.completion=W}function R(Z){this.tryEntries=[{tryLoc:"root"}],Z.forEach(S,this),this.reset(!0)}function x(Z){if(Z){var W=Z[ae];if(W)return W.call(Z);if("function"==typeof Z.next)return Z;if(!isNaN(Z.length)){var $=-1,Y=function t(){for(;++$=0;--$){var Y=this.tryEntries[$],ee=Y.completion;if("root"===Y.tryLoc)return r("end");if(Y.tryLoc<=this.prev){var ae=X.call(Y,"catchLoc"),ie=X.call(Y,"finallyLoc");if(ae&&ie){if(this.prev=0;--$){var Y=this.tryEntries[$];if(Y.tryLoc<=this.prev&&X.call(Y,"finallyLoc")&&this.prev=0;--W){var $=this.tryEntries[W];if($.finallyLoc===Z)return this.complete($.completion,$.afterLoc),_($),ce}},catch:function(Z){for(var W=this.tryEntries.length-1;W>=0;--W){var $=this.tryEntries[W];if($.tryLoc===Z){var Y=$.completion;if("throw"===Y.type){var X=Y.arg;_($)}return X}}throw new Error("illegal catch attempt")},delegateYield:function(Z,W,$){return this.delegate={iterator:x(Z),resultName:W,nextLoc:$},"next"===this.method&&(this.arg=void 0),ce}},W}Z.exports=o,Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/setPrototypeOf.js":Z=>{function t(W,$){return Z.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(Z,W){return Z.__proto__=W,Z},Z.exports.__esModule=!0,Z.exports.default=Z.exports,t(W,$)}Z.exports=t,Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/superPropBase.js":(Z,W,$)=>{var Y=$("./node_modules/@babel/runtime/helpers/getPrototypeOf.js");Z.exports=function(Z,W){for(;!Object.prototype.hasOwnProperty.call(Z,W)&&null!==(Z=Y(Z)););return Z},Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/helpers/typeof.js":Z=>{function t(W){return Z.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(Z){return typeof Z}:function(Z){return Z&&"function"==typeof Symbol&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},Z.exports.__esModule=!0,Z.exports.default=Z.exports,t(W)}Z.exports=t,Z.exports.__esModule=!0,Z.exports.default=Z.exports},"./node_modules/@babel/runtime/regenerator/index.js":(Z,W,$)=>{const Y=$("./node_modules/@babel/runtime/helpers/regeneratorRuntime.js")();Z.exports=Y;try{regeneratorRuntime=Y}catch(Z){"object"==typeof globalThis?globalThis.regeneratorRuntime=Y:Function("r","regeneratorRuntime = r")(Y)}},"./node_modules/after/index.js":Z=>{function t(){}Z.exports=function(Z,W,$){var Y=!1;return $=$||t,s.count=Z,0===Z?W():s;function s(Z,X){if(s.count<=0)throw new Error("after called too many times");--s.count,Z?(Y=!0,W(Z),W=$):0!==s.count||Y||W(null,X)}}},"./node_modules/arraybuffer.slice/index.js":Z=>{Z.exports=function(Z,W,$){var Y=Z.byteLength;if(W=W||0,$=$||Y,Z.slice)return Z.slice(W,$);if(W<0&&(W+=Y),$<0&&($+=Y),$>Y&&($=Y),W>=Y||W>=$||0===Y)return new ArrayBuffer(0);for(var X=new Uint8Array(Z),ee=new Uint8Array($-W),ae=W,ie=0;ae<$;ae++,ie++)ee[ie]=X[ae];return ee.buffer}},"./src/client.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/regenerator/index.js")),ee=Y($("./node_modules/@babel/runtime/helpers/asyncToGenerator.js")),ae=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ie=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),le=Y($("./node_modules/@babel/runtime/helpers/defineProperty.js")),ce=$("./src/constants.js"),de=Y($("./src/config.js")),pe=Y($("./src/subscriptions.js")),fe=Y($("./src/methods.js")),ye=Y($("./src/session.js")),be=[ce.NativeSocketEvents.CONNECTING,ce.NativeSocketEvents.CONNECT,ce.NativeSocketEvents.CONNECT_ERROR,ce.NativeSocketEvents.DISCONNECT,ce.NativeSocketEvents.RECONNECT_ATTEMPT],_e=function(){function e(Z){var W=this;(0,ae.default)(this,e),(0,le.default)(this,"onConnectError",(function(){W.subscriptions.hasActivity()||W.methods.hasActivity()||(W.disconnect("There are no active subscriptions and methods"),W.connectible=!0)})),(0,le.default)(this,"connectOnMethod",(function(Z){return function(){for(var $=arguments.length,Y=new Array($),X=0;X<$;X++)Y[X]=arguments[X];if(W.connectible){var ee=W.provideConnection();W.connected&&ee.then((function(W){return W[Z].apply(W,Y)}))}}})),(0,le.default)(this,"on",this.connectOnMethod("on")),(0,le.default)(this,"emit",this.connectOnMethod("emit")),(0,le.default)(this,"onSessionDisconnect",(function(){W.subscriptions.stop(),W.methods.stop(),delete W.session,W.provideConnection()})),(0,le.default)(this,"emitSocketEventListeners",(function(Z){for(var $=arguments.length,Y=new Array($>1?$-1:0),X=1;X<$;X++)Y[X-1]=arguments[X];W.socketEvents[Z]&&W.socketEvents[Z].forEach((function(Z){return Z.apply(void 0,Y)}))})),(0,le.default)(this,"addConnectingEventListener",(function(Z){return W.addSocketEventListener(ce.NativeSocketEvents.CONNECTING,Z)})),(0,le.default)(this,"removeConnectingEventListener",(function(Z){return W.removeSocketEventListener(ce.NativeSocketEvents.CONNECTING,Z)})),(0,le.default)(this,"addConnectEventListener",(function(Z){return W.addSocketEventListener(ce.NativeSocketEvents.CONNECT,Z)})),(0,le.default)(this,"removeConnectEventListener",(function(Z){return W.removeSocketEventListener(ce.NativeSocketEvents.CONNECT,Z)})),(0,le.default)(this,"addConnectErrorEventListener",(function(Z){return W.addSocketEventListener(ce.NativeSocketEvents.CONNECT_ERROR,Z)})),(0,le.default)(this,"removeConnectErrorEventListener",(function(Z){return W.removeSocketEventListener(ce.NativeSocketEvents.CONNECT_ERROR,Z)})),(0,le.default)(this,"addDisconnectEventListener",(function(Z){return W.addSocketEventListener(ce.NativeSocketEvents.DISCONNECT,Z)})),(0,le.default)(this,"removeDisconnectEventListener",(function(Z){return W.removeSocketEventListener(ce.NativeSocketEvents.DISCONNECT,Z)})),(0,le.default)(this,"addReconnectAttemptEventListener",(function(Z){return W.addSocketEventListener(ce.NativeSocketEvents.RECONNECT_ATTEMPT,Z)})),(0,le.default)(this,"removeReconnectAttemptEventListener",(function(Z){return W.removeSocketEventListener(ce.NativeSocketEvents.RECONNECT_ATTEMPT,Z)})),(0,le.default)(this,"removeConnectionListeners",(function(){be.forEach((function(Z){return W.removeSocketEventListener(Z)}))})),this.config=new de.default(Z),this.resetSocketEvents();var $={onMessage:this.on.bind(this),emitMessage:this.emit.bind(this)};this.subscriptions=new pe.default($),this.methods=new fe.default($),this.connectible=!0,this.connected=!1}var Z;return(0,ie.default)(e,[{key:"resetSocketEvents",value:function(){this.socketEvents={},this.addConnectErrorEventListener(this.onConnectError)}},{key:"setConfig",value:function(Z){this.config.set(Z),this.session&&(this.disconnect("Re-config socket connection"),this.connect())}},{key:"provideConnection",value:function(){var Z=this;return this.session||(this.session=new ye.default(this.config,this.emitSocketEventListeners,this.onSessionDisconnect),this.session.getSocket().then((function(){Z.connected=!0,Z.methods.initialize(),Z.methods.restore(),Z.subscriptions.initialize(),Z.subscriptions.restore()}))),this.session.getSocket()}},{key:"getConnectionId",value:(Z=(0,ee.default)(X.default.mark((function e(){return X.default.wrap((function(Z){for(;;)switch(Z.prev=Z.next){case 0:if(!this.session){Z.next=4;break}return Z.next=3,this.session.getConnectionId();case 3:return Z.abrupt("return",Z.sent);case 4:return Z.abrupt("return",null);case 5:case"end":return Z.stop()}}),e,this)}))),function(){return Z.apply(this,arguments)})},{key:"connect",value:function(){this.connectible=!0,this.provideConnection()}},{key:"disconnect",value:function(Z){this.session&&(this.subscriptions.stop(),this.methods.stop(),this.session.terminate(),delete this.session,this.emitSocketEventListeners(ce.NativeSocketEvents.DISCONNECT,Z||"disconnected by client")),this.connectible=!1,this.connected=!1}},{key:"terminate",value:function(Z){this.resetSocketEvents(),this.subscriptions.reset(),this.methods.reset(),this.disconnect(Z||"Terminated by client")}},{key:"addSocketEventListener",value:function(Z,W){return this.socketEvents[Z]=this.socketEvents[Z]||[],this.socketEvents[Z].push(W),this}},{key:"removeSocketEventListener",value:function(Z,W){return this.socketEvents[Z]&&(this.socketEvents[Z]=W?this.socketEvents[Z].filter((function(Z){return Z!==W})):[],this.socketEvents[Z].length||delete this.socketEvents[Z]),this}}]),e}();W.default=_e},"./src/config.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/regenerator/index.js")),ee=Y($("./node_modules/@babel/runtime/helpers/asyncToGenerator.js")),ae=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ie=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),le=Y($("./node_modules/@babel/runtime/helpers/typeof.js")),ce=Y($("./node_modules/backendless-request/dist/backendless-request.js")),l=function(Z){return void 0===Z},f=function(Z){return"string"==typeof Z},p=function(Z){return"function"==typeof Z},d=function(Z){return"object"===(0,le.default)(Z)&&null!==Z},de=function(){function e(Z){(0,ae.default)(this,e),this.appId=null,this.lookupPath=null,this.lookupHeaders={},this.debugMode=!1,this.connectQuery={},this.socketConfigTransform=null,this.socketConfig=null,this.set(Z)}var Z;return(0,ie.default)(e,[{key:"set",value:function(Z){if(Z){if(!l(Z.appId)){if(!f(Z.appId))throw new Error('"appId" must be String.');this.appId=Z.appId}if(!l(Z.lookupPath)){if(!f(Z.lookupPath))throw new Error('"lookupPath" must be String.');this.lookupPath=Z.lookupPath}if(!l(Z.lookupHeaders)){if(!d(Z.lookupHeaders))throw new Error('"lookupHeaders" must be Object.');this.lookupHeaders=Z.lookupHeaders}if(l(Z.debugMode)||(this.debugMode=!!Z.debugMode),!l(Z.connectQuery))if(p(Z.connectQuery))this.getConnectQuery=Z.connectQuery;else{if(!d(Z.connectQuery))throw new Error('"connectQuery" must be Function or Object.');this.connectQuery=Z.connectQuery}if(!l(Z.socketConfigTransform)){if(!p(Z.socketConfigTransform))throw new Error('"socketConfigTransform" must be Function.');this.socketConfigTransform=Z.socketConfigTransform}}}},{key:"getConnectQuery",value:function(){return this.connectQuery}},{key:"prepare",value:(Z=(0,ee.default)(X.default.mark((function e(){var Z,W,$,Y,ee;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:if(f(this.lookupPath)){X.next=2;break}throw new Error("lookupPath must be String");case 2:return X.next=4,ce.default.get(this.lookupPath).set(this.lookupHeaders);case 4:if(Z=X.sent,W=this.appId?"".concat(Z,"/").concat(this.appId):Z,$=this.appId?"/".concat(this.appId):void 0,Y=this.getConnectQuery(),this.socketConfig={host:Z,url:W,options:{path:$,query:Y,forceNew:!0,autoConnect:!1,reconnection:!1}},!this.socketConfigTransform){X.next=14;break}return X.next=12,this.socketConfigTransform(this.socketConfig);case 12:(ee=X.sent)&&(this.socketConfig=ee);case 14:case"end":return X.stop()}}),e,this)}))),function(){return Z.apply(this,arguments)})},{key:"getSocketConfig",value:function(){return this.socketConfig}}]),e}();W.default=de},"./src/constants.js":(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.RTSubscriptionTypes=W.RTSocketEvents=W.RTMethodTypes=W.NativeSocketEvents=void 0,W.NativeSocketEvents={CONNECTING:"connecting",CONNECT:"connect",CONNECT_ERROR:"connect_error",CONNECT_TIMEOUT:"connect_timeout",DISCONNECT:"disconnect",RECONNECT:"reconnect",RECONNECT_ATTEMPT:"reconnect_attempt",RECONNECTING:"reconnecting",RECONNECT_ERROR:"reconnect_error",RECONNECT_FAILED:"reconnect_failed",ERROR:"error",PING:"ping",PONG:"pong"},W.RTSocketEvents={SUB_ON:"SUB_ON",SUB_OFF:"SUB_OFF",SUB_RES:"SUB_RES",SUB_READY:"SUB_READY",MET_REQ:"MET_REQ",MET_RES:"MET_RES"},W.RTSubscriptionTypes={OBJECTS_CHANGES:"OBJECTS_CHANGES",RELATIONS_CHANGES:"RELATIONS_CHANGES",PUB_SUB_CONNECT:"PUB_SUB_CONNECT",PUB_SUB_MESSAGES:"PUB_SUB_MESSAGES",PUB_SUB_COMMANDS:"PUB_SUB_COMMANDS",PUB_SUB_USERS:"PUB_SUB_USERS",RSO_CONNECT:"RSO_CONNECT",RSO_CHANGES:"RSO_CHANGES",RSO_CLEARED:"RSO_CLEARED",RSO_COMMANDS:"RSO_COMMANDS",RSO_INVOKE:"RSO_INVOKE",RSO_USERS:"RSO_USERS",LOGGING_MESSAGES:"LOGGING_MESSAGES",CONSOLE_MESSAGES:"CONSOLE_MESSAGES",DEVELOPER_MESSAGES:"DEVELOPER_MESSAGES"},W.RTMethodTypes={SET_USER_TOKEN:"SET_USER_TOKEN",RSO_GET:"RSO_GET",RSO_SET:"RSO_SET",RSO_CLEAR:"RSO_CLEAR",RSO_COMMAND:"RSO_COMMAND",RSO_INVOKE:"RSO_INVOKE",PUB_SUB_COMMAND:"PUB_SUB_COMMAND"}},"./src/index.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=W.RTScopeConnector=W.RTListeners=void 0;var X=Y($("./node_modules/@babel/runtime/helpers/typeof.js")),ee=Y($("./node_modules/backendless-request/dist/backendless-request.js")),ae=Y($("./src/client.js")),ie=Y($("./src/listeners.js")),le=Y($("./src/scope-connector.js")),ce="object"===("undefined"==typeof self?"undefined":(0,X.default)(self))&&self.self===self&&self||"object"===(void 0===$.g?"undefined":(0,X.default)($.g))&&$.g.global===$.g&&$.g;ae.default.Request=ee.default,ae.default.Listeners=ie.default,ae.default.ScopeConnector=le.default,ce&&(ce.BackendlessRTClient=ae.default),Z.exports=ae.default;var de=ae.default;W.default=de;var pe=ie.default;W.RTListeners=pe;var fe=le.default;W.RTScopeConnector=fe},"./src/listeners.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/helpers/defineProperty.js")),ee=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ae=Y($("./node_modules/@babel/runtime/helpers/createClass.js"));function a(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function u(Z){for(var W=1;W1?W-1:0),Y=1;Y{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ee=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),ae=Y($("./node_modules/@babel/runtime/helpers/defineProperty.js")),ie=$("./src/constants.js"),le=Y($("./src/utils.js")),c=function(Z){return function(W){return this.send(Z,W)}},ce=function(){function e(Z){var W=this,$=Z.onMessage,Y=Z.emitMessage;(0,X.default)(this,e),(0,ae.default)(this,"sendRequest",(function(Z){W.invocations[Z]&&W.emitMessage(ie.RTSocketEvents.MET_REQ,W.invocations[Z].data)})),(0,ae.default)(this,"onResponse",(function(Z){var $=Z.id,Y=Z.error,X=Z.result;if(W.invocations[$]){var ee=W.invocations[$];Y?ee.reject(Y):ee.resolve(X),delete W.invocations[$]}})),(0,ae.default)(this,"setUserToken",c(ie.RTMethodTypes.SET_USER_TOKEN).bind(this)),(0,ae.default)(this,"sendPubSubCommand",c(ie.RTMethodTypes.PUB_SUB_COMMAND).bind(this)),(0,ae.default)(this,"getRSO",c(ie.RTMethodTypes.RSO_GET).bind(this)),(0,ae.default)(this,"setRSO",c(ie.RTMethodTypes.RSO_SET).bind(this)),(0,ae.default)(this,"clearRSO",c(ie.RTMethodTypes.RSO_CLEAR).bind(this)),(0,ae.default)(this,"sendRSOCommand",c(ie.RTMethodTypes.RSO_COMMAND).bind(this)),(0,ae.default)(this,"invokeRSOMethod",c(ie.RTMethodTypes.RSO_INVOKE).bind(this)),this.onMessage=$,this.emitMessage=Y,this.invocations={}}return(0,ee.default)(e,[{key:"initialize",value:function(){this.onMessage(ie.RTSocketEvents.MET_RES,this.onResponse)}},{key:"restore",value:function(){var Z=this;Object.keys(this.invocations).forEach((function(W){Z.sendRequest(W)}))}},{key:"stop",value:function(){}},{key:"reset",value:function(){this.invocations={}}},{key:"hasActivity",value:function(){return!!Object.keys(this.invocations).length}},{key:"send",value:function(Z,W){var $=this,Y=le.default.generateUID();return this.invocations[Y]={data:{id:Y,name:Z,options:W}},this.sendRequest(Y),new Promise((function(Z,W){$.invocations[Y].resolve=Z,$.invocations[Y].reject=W}))}}]),e}();W.default=ce},"./src/scope-connector.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X,ee,ae,ie,le,ce,de,pe=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),fe=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),ye=Y($("./node_modules/@babel/runtime/helpers/get.js")),be=Y($("./node_modules/@babel/runtime/helpers/inherits.js")),_e=Y($("./node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")),we=Y($("./node_modules/@babel/runtime/helpers/getPrototypeOf.js")),Se=Y($("./node_modules/@babel/runtime/helpers/defineProperty.js")),xe=Y($("./node_modules/@babel/runtime/helpers/applyDecoratedDescriptor.js")),Pe=Y($("./src/listeners.js"));function w(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function k(Z){for(var W=1;W{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/regenerator/index.js")),ee=Y($("./node_modules/@babel/runtime/helpers/asyncToGenerator.js")),ae=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ie=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),le=$("./src/constants.js"),ce=Y($("./src/socket.js")),de=function(){function e(Z,W,$){(0,ae.default)(this,e),this.config=Z,this.dispatch=W,this.onDisconnect=$,this.connectAttempt=0,this.socketPromise=this.connect()}var Z;return(0,ie.default)(e,[{key:"terminate",value:function(){this.terminated||(this.terminated=!0,this.dispatch=function(){},this.socketPromise.then((function(Z){Z&&Z.close()})))}},{key:"getSocket",value:function(){var Z=this;return this.socketPromise.then((function(W){return Z.terminated?new Promise((function(){})):W}))}},{key:"getConnectionId",value:(Z=(0,ee.default)(X.default.mark((function e(){var Z,W,$,Y;return X.default.wrap((function(X){for(;;)switch(X.prev=X.next){case 0:return X.next=2,this.getSocket();case 2:return Y=X.sent,X.abrupt("return",(null==Y||null===(Z=Y.ioSocket)||void 0===Z||null===(W=Z.io)||void 0===W||null===($=W.engine)||void 0===$?void 0:$.id)||null);case 4:case"end":return X.stop()}}),e,this)}))),function(){return Z.apply(this,arguments)})},{key:"connect",value:function(){var Z=this;if(!this.terminated){this.connectAttempt=this.connectAttempt+1;var W=this.getNextReconnectionTimeout();return this.onConnecting(),this.connectAttempt>1&&this.onReconnectAttempt(this.connectAttempt-1,W),ce.default.connect(this.config,this.onSocketDisconnect.bind(this)).then((function(W){return Z.connectAttempt=0,Z.onConnect(),W})).catch((function($){if(Z.onConnectError($),!Z.terminated)return(Y=W,new Promise((function(Z){return setTimeout(Z,Y)}))).then((function(){return Z.connect()}));var Y}))}}},{key:"getNextReconnectionTimeout",value:function(){var Z=Math.ceil(this.connectAttempt/10),W=200*Math.pow(2,Z);return Math.min(W,6e4)}},{key:"onSocketDisconnect",value:function(Z){this.dispatch(le.NativeSocketEvents.DISCONNECT,Z),this.terminated||(this.terminate(),this.onDisconnect())}},{key:"onConnecting",value:function(){this.dispatch(le.NativeSocketEvents.CONNECTING)}},{key:"onConnect",value:function(){this.dispatch(le.NativeSocketEvents.CONNECT)}},{key:"onConnectError",value:function(Z){this.dispatch(le.NativeSocketEvents.CONNECT_ERROR,Z&&Z.message||Z)}},{key:"onReconnectAttempt",value:function(Z,W){this.dispatch(le.NativeSocketEvents.RECONNECT_ATTEMPT,Z,W)}}]),e}();W.default=de},"./src/socket-parser.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/component-emitter/index.js");function o(){}function s(Z){var $=""+Z.type;return W.BINARY_EVENT!==Z.type&&W.BINARY_ACK!==Z.type||($+=Z.attachments+"-"),Z.nsp&&"/"!==Z.nsp&&($+=Z.nsp+","),null!=Z.id&&($+=Z.id),null!=Z.data&&($+=JSON.stringify(Z.data)),$}function i(){}function a(){return{type:W.ERROR,data:"parser error"}}W.protocol=4,W.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],W.CONNECT=0,W.DISCONNECT=1,W.EVENT=2,W.ACK=3,W.ERROR=4,W.BINARY_EVENT=5,W.BINARY_ACK=6,W.Encoder=o,W.Decoder=i,o.prototype.encode=function(Z,W){W([s(Z)])},Y(i.prototype),i.prototype.add=function(Z){if("string"!=typeof Z)throw new Error("Unknown type: "+Z);this.emit("decoded",function(Z){var $=0,Y={type:Number(Z.charAt(0))};if(null==W.types[Y.type])return a();if(W.BINARY_EVENT===Y.type||W.BINARY_ACK===Y.type){for(var X="";"-"!==Z.charAt(++$)&&(X+=Z.charAt($),$!=Z.length););if(X!=Number(X)||"-"!==Z.charAt($))throw new Error("Illegal attachments");Y.attachments=Number(X)}if("/"===Z.charAt($+1))for(Y.nsp="";++$&&","!==(ae=Z.charAt($))&&(Y.nsp+=ae,$!==Z.length););else Y.nsp="/";var ee=Z.charAt($+1);if(""!==ee&&Number(ee)==ee){for(Y.id="";++$;){var ae;if(null==(ae=Z.charAt($))||Number(ae)!=ae){--$;break}if(Y.id+=Z.charAt($),$===Z.length)break}Y.id=Number(Y.id)}return Z.charAt(++$)&&(Y=function(Z,W){try{Z.data=JSON.parse(W)}catch(Z){return a()}return Z}(Y,Z.substr($))),Y}(Z))},i.prototype.destroy=function(){}},"./src/socket.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ee=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),ae=$("./src/constants.js"),ie=function(){function e(Z,W){(0,X.default)(this,e);var Y=$("./node_modules/socket.io-client/lib/index.js");this.config=Z,this.events={};var ee=Z.getSocketConfig(),ae=ee.url,ie=ee.options;this.ioSocket=Y(ae,ie)}return(0,ee.default)(e,[{key:"connect",value:function(){this.ioSocket.connect()}},{key:"close",value:function(){this.log("log","close socket"),this.events={},this.ioSocket.off(),this.ioSocket.close()}},{key:"on",value:function(Z,W){var $=this;this.events[Z]||this.ioSocket.on(Z,(function(W){return $.onEvent(Z,W)})),this.events[Z]=this.events[Z]||[],this.events[Z].push(W)}},{key:"off",value:function(Z,W){this.events[Z]=W?this.events[Z].filter((function(Z){return Z!==W})):[],this.events[Z].length||delete this.events[Z],this.events[Z]||this.ioSocket.off(Z)}},{key:"onEvent",value:function(Z,W){this.logMessage("FROM SERVER",Z,W),this.events[Z]&&this.events[Z].forEach((function(Z){return Z(W)}))}},{key:"emit",value:function(Z,W){this.logMessage("TO SERVER",Z,W),this.ioSocket.emit(Z,W)}},{key:"log",value:function(Z){if(this.config.debugMode){for(var W,$=arguments.length,Y=new Array($>1?$-1:0),X=1;X<$;X++)Y[X-1]=arguments[X];(W=console)[Z].apply(W,["[RT Client]:"].concat(Y))}}},{key:"logMessage",value:function(Z,W,$){this.log("log","[".concat(Z,"] - [event: ").concat(W,"] - arguments: ").concat(JSON.stringify($)," "))}}],[{key:"connect",value:function(Z,W){return Promise.resolve().then((function(){return Z.prepare()})).then((function(){return new Promise((function(W,$){var Y=new e(Z);function s(Z){Y.log("error","received one of [CONNECT_ERROR,CONNECT_TIMEOUT] socket event while connecting",Z),a(Z)}function a(Z){Y.log("log","close and reject socket with error:",Z),Y.close(),$(Z)}Y.on(ae.NativeSocketEvents.CONNECT,(function(){Y.log("log","socket connected"),W(Y)})),Y.on(ae.NativeSocketEvents.CONNECT_ERROR,s),Y.on(ae.NativeSocketEvents.CONNECT_TIMEOUT,s),Y.on(ae.NativeSocketEvents.ERROR,(function(Z){Y.log("error","received ERROR event while connecting",Z),a(Z)})),Y.connect()}))})).then((function(Z){return Z.on(ae.NativeSocketEvents.DISCONNECT,W),Z.on(ae.NativeSocketEvents.ERROR,W),Z}))}}]),e}();W.default=ie},"./src/subscriptions.js":(Z,W,$)=>{"use strict";var Y=$("./node_modules/@babel/runtime/helpers/interopRequireDefault.js");Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var X=Y($("./node_modules/@babel/runtime/helpers/classCallCheck.js")),ee=Y($("./node_modules/@babel/runtime/helpers/createClass.js")),ae=Y($("./node_modules/@babel/runtime/helpers/defineProperty.js")),ie=$("./src/constants.js"),le=Y($("./src/utils.js")),c=function(Z){return function(W,$){return this.subscribe(Z,W,$)}},ce=function(){function e(Z){var W=Z.onMessage,$=Z.emitMessage;(0,X.default)(this,e),(0,ae.default)(this,"onObjectsChanges",c(ie.RTSubscriptionTypes.OBJECTS_CHANGES).bind(this)),(0,ae.default)(this,"onRelationsChanges",c(ie.RTSubscriptionTypes.RELATIONS_CHANGES).bind(this)),(0,ae.default)(this,"connectToPubSub",c(ie.RTSubscriptionTypes.PUB_SUB_CONNECT).bind(this)),(0,ae.default)(this,"onPubSubMessage",c(ie.RTSubscriptionTypes.PUB_SUB_MESSAGES).bind(this)),(0,ae.default)(this,"onPubSubCommand",c(ie.RTSubscriptionTypes.PUB_SUB_COMMANDS).bind(this)),(0,ae.default)(this,"onPubSubUserStatus",c(ie.RTSubscriptionTypes.PUB_SUB_USERS).bind(this)),(0,ae.default)(this,"connectToRSO",c(ie.RTSubscriptionTypes.RSO_CONNECT).bind(this)),(0,ae.default)(this,"onRSOChanges",c(ie.RTSubscriptionTypes.RSO_CHANGES).bind(this)),(0,ae.default)(this,"onRSOClear",c(ie.RTSubscriptionTypes.RSO_CLEARED).bind(this)),(0,ae.default)(this,"onRSOCommand",c(ie.RTSubscriptionTypes.RSO_COMMANDS).bind(this)),(0,ae.default)(this,"onRSOInvoke",c(ie.RTSubscriptionTypes.RSO_INVOKE).bind(this)),(0,ae.default)(this,"onRSOUserStatus",c(ie.RTSubscriptionTypes.RSO_USERS).bind(this)),(0,ae.default)(this,"onLoggingMessages",c(ie.RTSubscriptionTypes.LOGGING_MESSAGES).bind(this)),(0,ae.default)(this,"onConsoleMessages",c(ie.RTSubscriptionTypes.CONSOLE_MESSAGES).bind(this)),(0,ae.default)(this,"onDeveloperMessage",c(ie.RTSubscriptionTypes.DEVELOPER_MESSAGES).bind(this)),this.onMessage=W,this.emitMessage=$,this.subscriptions={}}return(0,ee.default)(e,[{key:"initialize",value:function(){var Z=this;this.onMessage(ie.RTSocketEvents.SUB_READY,(function(W){return Z.onSubscriptionReady(W)})),this.onMessage(ie.RTSocketEvents.SUB_RES,(function(W){return Z.onSubscriptionResponse(W)}))}},{key:"stop",value:function(){var Z=this;Object.keys(this.subscriptions).forEach((function(W){Z.subscriptions[W].ready=!1}))}},{key:"reset",value:function(){var Z=this;Object.keys(this.subscriptions).forEach((function(W){return Z.stopSubscription(W)}))}},{key:"restore",value:function(){var Z=this;Object.keys(this.subscriptions).forEach((function(W){Z.startSubscription(W)}))}},{key:"hasActivity",value:function(){return!!Object.keys(this.subscriptions).length}},{key:"subscribe",value:function(Z,W,$){var Y=this,X=$.parser,ee=$.onData,ae=$.onError,ie=$.onStop,ce=$.onReady,de=le.default.generateUID();return this.subscriptions[de]={data:{id:de,name:Z,options:W},ready:!1,parser:X,onData:ee,onError:ae,onStop:ie,onReady:ce},this.startSubscription(de),{isReady:function(){return!!Y.subscriptions[de]&&Y.subscriptions[de].ready},stop:function(){Y.subscriptions[de]&&Y.offSubscription(de)}}}},{key:"startSubscription",value:function(Z){var W=this.subscriptions[Z];this.emitMessage(ie.RTSocketEvents.SUB_ON,W.data)}},{key:"stopSubscription",value:function(Z){var W=this.subscriptions[Z];W&&(W.onStop&&W.onStop(),delete this.subscriptions[Z])}},{key:"offSubscription",value:function(Z){this.subscriptions[Z]&&(this.emitMessage(ie.RTSocketEvents.SUB_OFF,{id:Z}),this.stopSubscription(Z))}},{key:"onSubscriptionReady",value:function(Z){var W=Z.id,$=this.subscriptions[W];$&&!$.ready&&($.ready=!0,$.onReady&&$.onReady())}},{key:"onSubscriptionResponse",value:function(Z){var W=Z.id,$=Z.data,Y=Z.error,X=this.subscriptions[W];X&&(Y?(X.onError&&X.onError(Y),this.stopSubscription(W)):(X.ready||(X.ready=!0,X.onReady&&X.onReady()),X.onData&&("function"==typeof X.parser&&($=X.parser($)),X.onData($))))}}]),e}();W.default=ce},"./src/utils.js":(Z,W)=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var $="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",Y={generateUID:function(){for(var Z="",W=0;W<8;W++)Z+=$.charAt(Math.floor(Math.random()*$.length));return Z+Date.now()}};W.default=Y},"./node_modules/backendless-request/dist/backendless-request.js":function(Z,W){var ee;"undefined"!=typeof self&&self,ee=function(){return function(Z){var W={};function r($){if(W[$])return W[$].exports;var Y=W[$]={i:$,l:!1,exports:{}};return Z[$].call(Y.exports,Y,Y.exports,r),Y.l=!0,Y.exports}return r.m=Z,r.c=W,r.d=function(Z,W,$){r.o(Z,W)||Object.defineProperty(Z,W,{configurable:!1,enumerable:!0,get:$})},r.n=function(Z){var W=Z&&Z.__esModule?function(){return Z.default}:function(){return Z};return r.d(W,"a",W),W},r.o=function(Z,W){return Object.prototype.hasOwnProperty.call(Z,W)},r.p="",r(r.s=3)}([function(Z,W,$){"use strict";function n(Z){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(Z){return typeof Z}:function(Z){return Z&&"function"==typeof Symbol&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z})(Z)}Object.defineProperty(W,"__esModule",{value:!0}),W.isStream=W.isObject=W.isFormData=W.castArray=void 0,W.castArray=function(Z){return Array.isArray(Z)?Z:[Z]},W.isObject=function(Z){return null!=Z&&"object"===n(Z)},W.isFormData=function(Z){return Z&&Z.constructor&&0===Z.constructor.toString().trim().indexOf("function FormData")},W.isStream=function(Z){return Z instanceof $(5).Stream}},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W,$){"use strict";function n(Z){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(Z){return typeof Z}:function(Z){return Z&&"function"==typeof Symbol&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z})(Z)}Object.defineProperty(W,"__esModule",{value:!0}),W.Request=void 0;var Y,X=$(10),ee=(Y=$(11))&&Y.__esModule?Y:{default:Y},ae=function(Z,W){if(Z&&Z.__esModule)return Z;if(null===Z||"object"!==n(Z)&&"function"!=typeof Z)return{default:Z};var $=l(W);if($&&$.has(Z))return $.get(Z);var Y={},X=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ee in Z)if("default"!==ee&&Object.prototype.hasOwnProperty.call(Z,ee)){var ae=X?Object.getOwnPropertyDescriptor(Z,ee):null;ae&&(ae.get||ae.set)?Object.defineProperty(Y,ee,ae):Y[ee]=Z[ee]}return Y.default=Z,$&&$.set(Z,Y),Y}($(12)),ie=$(0),le=$(13);function l(Z){if("function"!=typeof WeakMap)return null;var W=new WeakMap,$=new WeakMap;return(l=function(Z){return Z?$:W})(Z)}function f(Z,W){var $=Object.keys(Z);if(Object.getOwnPropertySymbols){var Y=Object.getOwnPropertySymbols(Z);W&&(Y=Y.filter((function(W){return Object.getOwnPropertyDescriptor(Z,W).enumerable}))),$.push.apply($,Y)}return $}function p(Z){for(var W=1;W0&&void 0!==arguments[0]?arguments[0]:15e3;return this.cacheTTL=Z,this}},{key:"resetCache",value:function(Z){return Z&&this.tags&&X.cache.deleteByTags(this.tags),this}},{key:"type",value:function(Z){return this.set("Content-Type",Z),this}},{key:"unwrapBody",value:function(Z){return this.unwrap=Z,this}},{key:"setEncoding",value:function(Z){return this.encoding=Z,this}},{key:"setTimeout",value:function(Z){return this.timeout=Z,this}},{key:"send",value:function(Z){var W=this;this.emit("request",this);var $=this.path,Y=ae.stringify(this.queryParams);if(Y&&($+="?"+Y),this.cacheTTL){var ee=X.cache.get($);if(void 0!==ee)return Promise.resolve(ee)}this.headers["Content-Type"]||!(0,ie.isObject)(Z)||(0,ie.isFormData)(Z)||this.type("application/json"),Z&&(Z="application/json"===this.headers["Content-Type"]&&"string"!=typeof Z?JSON.stringify(Z):Z),i.verbose&&console.log(this.method.toUpperCase(),decodeURIComponent($),Z,this.headers);var le=i.send($,this.method.toUpperCase(),this.headers,Z,this.encoding,this.timeout).then(w).then(k).then((function(Z){return W.unwrap?Z.body:Z})).then((function(Z){return W.cacheTTL&&X.cache.set($,Z,W.tags,W.cacheTTL),Z})).then((function(Z){return W.tags&&"get"!==W.method&&X.cache.deleteByTags(W.tags),Z}));return le.then((function(Z){W.emit("response",Z),W.emit("done",null,Z)})).catch((function(Z){W.emit("error",Z),W.emit("done",Z)})),le}},{key:"then",value:function(Z,W){return this.promise=this.promise||this.send(this.body),this.promise.then(Z,W)}},{key:"catch",value:function(Z){return this.promise=this.promise||this.send(this.body),this.promise.catch(Z)}}])&&h(W.prototype,$),Object.defineProperty(W,"prototype",{writable:!1}),i}(ee.default);function w(Z){try{return p(p({},Z),{},{body:JSON.parse(Z.body)})}catch(W){return Z}}function k(Z){if(Z.status>=200&&Z.status<300)return Z;throw new le.ResponseError(Z)}W.Request=ce},function(Z,W,$){"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.default=void 0;var Y=$(4),X=$(9),ee=$(2);Object.defineProperty(ee.Request,"FormData",{get:function(){return"undefined"!=typeof FormData?FormData:$(14)}}),ee.Request.XMLHttpRequest="undefined"!=typeof XMLHttpRequest?XMLHttpRequest:void 0,ee.Request.send=function(Z,W,$,ae,ie,le){return(void 0!==ee.Request.XMLHttpRequest?X.sendXmlHttpRequest:Y.sendNodeAPIRequest)(Z,W,$,ae,ie,le)},ee.Request.verbose=!1,ee.Request.methods=["get","post","put","patch","delete"],ee.Request.methods.forEach((function(Z){ee.Request[Z]=function(W,$){return new ee.Request(W,Z,$)}})),W=Z.exports=ee.Request;var ae=ee.Request;W.default=ae},function(Z,W,$){"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.sendNodeAPIRequest=function(Z,W,X,ee,ae,ie){return new Promise((function(le,ce){var de=$(6).parse(Z),pe=(0,Y.isFormData)(ee)&&ee,fe="https:"===de.protocol,ye={host:de.hostname,port:de.port||(fe?443:80),path:de.pathname+(de.search||""),method:W,headers:X,timeout:ie},h=function(){var Z=$(1).Buffer,W=$(fe?7:8).request(ye,(function(W){var $=[],Y=[],X=0,ee="",ie=W.statusCode,de=W.statusMessage,pe=W.headers;W.on("data",(function(W){Z.isBuffer(W)?W.length&&(X+=W.length,Y.push(W)):$.push(W)})),W.on("end",(function(){X?(ee=Z.concat(Y,X),null!=ae&&(ee=ee.toString(ae))):$.length&&(ee=$.join()),le({status:ie,statusText:de,headers:pe,body:ee})})),W.on("error",ce)}));if(W.on("error",ce),W.on("timeout",(function(){W.destroy(new Error("Connection aborted due to timeout"))})),ee){if((0,Y.isStream)(ee))return void ee.pipe(W);W.write(ee)}W.end()};if(pe)Object.assign(ye.headers,pe.getHeaders()),pe.getLength((function(Z,W){Z||isNaN(W)||(ye.headers["content-length"]=W),h()}));else{if(ee&&!ye.headers["content-length"]){var be=$(1).Buffer;ye.headers["content-length"]=be.byteLength(ee)}h()}}))};var Y=$(0)},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W){throw new Error('This Backendless JS SDK assembly is not intended for Node.js environment. You should use "lib" folder modules instead. For any questions please contact as at http://support.backendless.com/')},function(Z,W,$){"use strict";Object.defineProperty(W,"__esModule",{value:!0}),W.sendXmlHttpRequest=function(Z,W,$,X,ee,ae){return new Promise((function(ie,le){var ce=new Y.Request.XMLHttpRequest;ce.timeout=ae,ee||(ce.responseType="arraybuffer"),ce.open(W.toUpperCase(),Z,!0),ce.onload=function(){var Z,W,$=(Z=ce.getAllResponseHeaders(),W={},Z?(Z.split("\n").forEach((function(Z){var $=Z.indexOf(":"),Y=Z.substr(0,$).trim(),X=Z.substr($+1).trim();Y&&(W[Y]=W[Y]?W[Y]+", "+X:X)})),W):W),Y=ce,X={status:Y.status,statusText:Y.statusText,headers:$};"utf8"===ee?X.body=ce.response||ce.responseText:ce.response&&(X.body=new Uint8Array(ce.response)),ie(X),ce=null},ce.onerror=function(){le(new Error("Network Error")),ce=null},ce.ontimeout=function(){le(new Error("Connection aborted due to timeout")),ce=null},Object.keys($).forEach((function(Z){ce.setRequestHeader(Z,$[Z])})),ce.send(X)}))};var Y=$(2)},function(Z,W,$){"use strict";function n(Z,W){return function(Z){if(Array.isArray(Z))return Z}(Z)||function(Z,W){var $=null==Z?null:"undefined"!=typeof Symbol&&Z[Symbol.iterator]||Z["@@iterator"];if(null!=$){var Y,X,ee=[],ae=!0,ie=!1;try{for($=$.call(Z);!(ae=(Y=$.next()).done)&&(ee.push(Y.value),!W||ee.length!==W);ae=!0);}catch(Z){ie=!0,X=Z}finally{try{ae||null==$.return||$.return()}finally{if(ie)throw X}}return ee}}(Z,W)||s(Z,W)||function(){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 o(Z,W){var $="undefined"!=typeof Symbol&&Z[Symbol.iterator]||Z["@@iterator"];if(!$){if(Array.isArray(Z)||($=s(Z))||W&&Z&&"number"==typeof Z.length){$&&(Z=$);var Y=0,o=function(){};return{s:o,n:function(){return Y>=Z.length?{done:!0}:{done:!1,value:Z[Y++]}},e:function(Z){throw Z},f:o}}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 X,ee=!0,ae=!1;return{s:function(){$=$.call(Z)},n:function(){var Z=$.next();return ee=Z.done,Z},e:function(Z){ae=!0,X=Z},f:function(){try{ee||null==$.return||$.return()}finally{if(ae)throw X}}}}function s(Z,W){if(Z){if("string"==typeof Z)return i(Z,W);var $=Object.prototype.toString.call(Z).slice(8,-1);return"Object"===$&&Z.constructor&&($=Z.constructor.name),"Map"===$||"Set"===$?Array.from(Z):"Arguments"===$||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test($)?i(Z,W):void 0}}function i(Z,W){(null==W||W>Z.length)&&(W=Z.length);for(var $=0,Y=new Array(W);$u())return W.value;this.map.delete(Z)}}},{key:"set",value:function(Z,W,$,Y){this.map.set(Z,function(Z,W,$){return{value:Z,tags:W,ttl:$}}(W,$,u()+Y)),this.flushInterval&&!this.flushTimer&&(this.flushTimer=setInterval(this.flush.bind(this),this.flushInterval),this.flushTimer.unref&&this.flushTimer.unref())}},{key:"delete",value:function(Z){this.map.delete(Z)}},{key:"deleteAll",value:function(){var Z,W=o(this.map);try{for(W.s();!(Z=W.n()).done;){var $=n(Z.value,1)[0];this.delete($)}}catch(Z){W.e(Z)}finally{W.f()}}},{key:"deleteByTags",value:function(Z){var W,$=o(this.map);try{for($.s();!(W=$.n()).done;){var Y=n(W.value,2),X=Y[0],ee=Y[1];ee.tags&&c(Z,ee.tags)&&this.delete(X)}}catch(Z){$.e(Z)}finally{$.f()}}},{key:"flush",value:function(){var Z,W=u(),$=o(this.map);try{for($.s();!(Z=$.n()).done;){var Y=n(Z.value,2),X=Y[0];Y[1].ttl1?W-1:0),Y=1;Y{function t(Z){Z=Z||{},this.ms=Z.min||100,this.max=Z.max||1e4,this.factor=Z.factor||2,this.jitter=Z.jitter>0&&Z.jitter<=1?Z.jitter:0,this.attempts=0}Z.exports=t,t.prototype.duration=function(){var Z=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var W=Math.random(),$=Math.floor(W*this.jitter*Z);Z=0==(1&Math.floor(10*W))?Z-$:Z+$}return 0|Math.min(Z,this.max)},t.prototype.reset=function(){this.attempts=0},t.prototype.setMin=function(Z){this.ms=Z},t.prototype.setMax=function(Z){this.max=Z},t.prototype.setJitter=function(Z){this.jitter=Z}},"./node_modules/base64-arraybuffer/lib/base64-arraybuffer.js":(Z,W)=>{!function(){"use strict";for(var Z="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",$=new Uint8Array(256),Y=0;Y>2],ee+=Z[(3&Y[$])<<4|Y[$+1]>>4],ee+=Z[(15&Y[$+1])<<2|Y[$+2]>>6],ee+=Z[63&Y[$+2]];return X%3==2?ee=ee.substring(0,ee.length-1)+"=":X%3==1&&(ee=ee.substring(0,ee.length-2)+"=="),ee},W.decode=function(Z){var W,Y,X,ee,ae,ie=.75*Z.length,le=Z.length,ce=0;"="===Z[Z.length-1]&&(ie--,"="===Z[Z.length-2]&&ie--);var de=new ArrayBuffer(ie),pe=new Uint8Array(de);for(W=0;W>4,pe[ce++]=(15&X)<<4|ee>>2,pe[ce++]=(3&ee)<<6|63&ae;return de}}()},"./node_modules/blob/index.js":(Z,W,$)=>{var Y=$.g.BlobBuilder||$.g.WebKitBlobBuilder||$.g.MSBlobBuilder||$.g.MozBlobBuilder,X=function(){try{return 2===new Blob(["hi"]).size}catch(Z){return!1}}(),ee=X&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(Z){return!1}}(),ae=Y&&Y.prototype.append&&Y.prototype.getBlob;function a(Z){for(var W=0;W{var W=[].slice;Z.exports=function(Z,$){if("string"==typeof $&&($=Z[$]),"function"!=typeof $)throw new Error("bind() requires a function");var Y=W.call(arguments,2);return function(){return $.apply(Z,Y.concat(W.call(arguments)))}}},"./node_modules/component-emitter/index.js":Z=>{function t(Z){if(Z)return function(Z){for(var W in t.prototype)Z[W]=t.prototype[W];return Z}(Z)}Z.exports=t,t.prototype.on=t.prototype.addEventListener=function(Z,W){return this._callbacks=this._callbacks||{},(this._callbacks["$"+Z]=this._callbacks["$"+Z]||[]).push(W),this},t.prototype.once=function(Z,W){function r(){this.off(Z,r),W.apply(this,arguments)}return r.fn=W,this.on(Z,r),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(Z,W){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var $,Y=this._callbacks["$"+Z];if(!Y)return this;if(1==arguments.length)return delete this._callbacks["$"+Z],this;for(var X=0;X{Z.exports=function(Z,W){var r=function(){};r.prototype=W.prototype,Z.prototype=new r,Z.prototype.constructor=Z}},"./node_modules/debug/src/browser.js":(Z,W,$)=>{function n(){var Z;try{Z=W.storage.debug}catch(Z){}return!Z&&"undefined"!=typeof process&&"env"in process&&(Z=process.env.DEBUG),Z}(W=Z.exports=$("./node_modules/debug/src/debug.js")).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},W.formatArgs=function(Z){var $=this.useColors;if(Z[0]=($?"%c":"")+this.namespace+($?" %c":" ")+Z[0]+($?"%c ":" ")+"+"+W.humanize(this.diff),$){var Y="color: "+this.color;Z.splice(1,0,Y,"color: inherit");var X=0,ee=0;Z[0].replace(/%[a-zA-Z%]/g,(function(Z){"%%"!==Z&&(X++,"%c"===Z&&(ee=X))})),Z.splice(ee,0,Y)}},W.save=function(Z){try{null==Z?W.storage.removeItem("debug"):W.storage.debug=Z}catch(Z){}},W.load=n,W.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},W.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(Z){}}(),W.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],W.formatters.j=function(Z){try{return JSON.stringify(Z)}catch(Z){return"[UnexpectedJSONParseError]: "+Z.message}},W.enable(n())},"./node_modules/debug/src/debug.js":(Z,W,$)=>{var Y;function o(Z){function r(){if(r.enabled){var Z=r,$=+new Date,X=$-(Y||$);Z.diff=X,Z.prev=Y,Z.curr=$,Y=$;for(var ee=new Array(arguments.length),ae=0;ae{Z.exports=$("./node_modules/engine.io-client/lib/socket.js"),Z.exports.parser=$("./node_modules/engine.io-parser/lib/browser.js")},"./node_modules/engine.io-client/lib/socket.js":(Z,W,$)=>{var Y=$("./node_modules/engine.io-client/lib/transports/index.js"),X=$("./node_modules/component-emitter/index.js"),ee=$("./node_modules/debug/src/browser.js")("engine.io-client:socket"),ae=$("./node_modules/indexof/index.js"),ie=$("./node_modules/engine.io-parser/lib/browser.js"),le=$("./node_modules/parseuri/index.js"),ce=$("./node_modules/parseqs/index.js");function l(Z,W){if(!(this instanceof l))return new l(Z,W);W=W||{},Z&&"object"==typeof Z&&(W=Z,Z=null),Z?(Z=le(Z),W.hostname=Z.host,W.secure="https"===Z.protocol||"wss"===Z.protocol,W.port=Z.port,Z.query&&(W.query=Z.query)):W.host&&(W.hostname=le(W.host).host),this.secure=null!=W.secure?W.secure:$.g.location&&"https:"===location.protocol,W.hostname&&!W.port&&(W.port=this.secure?"443":"80"),this.agent=W.agent||!1,this.hostname=W.hostname||($.g.location?location.hostname:"localhost"),this.port=W.port||($.g.location&&location.port?location.port:this.secure?443:80),this.query=W.query||{},"string"==typeof this.query&&(this.query=ce.decode(this.query)),this.upgrade=!1!==W.upgrade,this.path=(W.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!W.forceJSONP,this.jsonp=!1!==W.jsonp,this.forceBase64=!!W.forceBase64,this.enablesXDR=!!W.enablesXDR,this.timestampParam=W.timestampParam||"t",this.timestampRequests=W.timestampRequests,this.transports=W.transports||["polling","websocket"],this.transportOptions=W.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=W.policyPort||843,this.rememberUpgrade=W.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=W.onlyBinaryUpgrades,this.perMessageDeflate=!1!==W.perMessageDeflate&&(W.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=W.pfx||null,this.key=W.key||null,this.passphrase=W.passphrase||null,this.cert=W.cert||null,this.ca=W.ca||null,this.ciphers=W.ciphers||null,this.rejectUnauthorized=void 0===W.rejectUnauthorized||W.rejectUnauthorized,this.forceNode=!!W.forceNode;var Y="object"==typeof $.g&&$.g;Y.global===Y&&(W.extraHeaders&&Object.keys(W.extraHeaders).length>0&&(this.extraHeaders=W.extraHeaders),W.localAddress&&(this.localAddress=W.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}Z.exports=l,l.priorWebsocketSuccess=!1,X(l.prototype),l.protocol=ie.protocol,l.Socket=l,l.Transport=$("./node_modules/engine.io-client/lib/transport.js"),l.transports=$("./node_modules/engine.io-client/lib/transports/index.js"),l.parser=$("./node_modules/engine.io-parser/lib/browser.js"),l.prototype.createTransport=function(Z){ee('creating transport "%s"',Z);var W=function(Z){var W={};for(var $ in Z)Z.hasOwnProperty($)&&(W[$]=Z[$]);return W}(this.query);W.EIO=ie.protocol,W.transport=Z;var $=this.transportOptions[Z]||{};return this.id&&(W.sid=this.id),new Y[Z]({query:W,socket:this,agent:$.agent||this.agent,hostname:$.hostname||this.hostname,port:$.port||this.port,secure:$.secure||this.secure,path:$.path||this.path,forceJSONP:$.forceJSONP||this.forceJSONP,jsonp:$.jsonp||this.jsonp,forceBase64:$.forceBase64||this.forceBase64,enablesXDR:$.enablesXDR||this.enablesXDR,timestampRequests:$.timestampRequests||this.timestampRequests,timestampParam:$.timestampParam||this.timestampParam,policyPort:$.policyPort||this.policyPort,pfx:$.pfx||this.pfx,key:$.key||this.key,passphrase:$.passphrase||this.passphrase,cert:$.cert||this.cert,ca:$.ca||this.ca,ciphers:$.ciphers||this.ciphers,rejectUnauthorized:$.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:$.perMessageDeflate||this.perMessageDeflate,extraHeaders:$.extraHeaders||this.extraHeaders,forceNode:$.forceNode||this.forceNode,localAddress:$.localAddress||this.localAddress,requestTimeout:$.requestTimeout||this.requestTimeout,protocols:$.protocols||void 0})},l.prototype.open=function(){var Z;if(this.rememberUpgrade&&l.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))Z="websocket";else{if(0===this.transports.length){var W=this;return void setTimeout((function(){W.emit("error","No transports available")}),0)}Z=this.transports[0]}this.readyState="opening";try{Z=this.createTransport(Z)}catch(Z){return this.transports.shift(),void this.open()}Z.open(),this.setTransport(Z)},l.prototype.setTransport=function(Z){ee("setting transport %s",Z.name);var W=this;this.transport&&(ee("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=Z,Z.on("drain",(function(){W.onDrain()})).on("packet",(function(Z){W.onPacket(Z)})).on("error",(function(Z){W.onError(Z)})).on("close",(function(){W.onClose("transport close")}))},l.prototype.probe=function(Z){ee('probing transport "%s"',Z);var W=this.createTransport(Z,{probe:1}),$=!1,Y=this;function o(){if(Y.onlyBinaryUpgrades){var X=!this.supportsBinary&&Y.transport.supportsBinary;$=$||X}$||(ee('probe transport "%s" opened',Z),W.send([{type:"ping",data:"probe"}]),W.once("packet",(function(X){if(!$)if("pong"===X.type&&"probe"===X.data){if(ee('probe transport "%s" pong',Z),Y.upgrading=!0,Y.emit("upgrading",W),!W)return;l.priorWebsocketSuccess="websocket"===W.name,ee('pausing current transport "%s"',Y.transport.name),Y.transport.pause((function(){$||"closed"!==Y.readyState&&(ee("changing transport and sending upgrade packet"),p(),Y.setTransport(W),W.send([{type:"upgrade"}]),Y.emit("upgrade",W),W=null,Y.upgrading=!1,Y.flush())}))}else{ee('probe transport "%s" failed',Z);var ae=new Error("probe error");ae.transport=W.name,Y.emit("upgradeError",ae)}})))}function i(){$||($=!0,p(),W.close(),W=null)}function a($){var X=new Error("probe error: "+$);X.transport=W.name,i(),ee('probe transport "%s" failed because of error: %s',Z,$),Y.emit("upgradeError",X)}function u(){a("transport closed")}function c(){a("socket closed")}function f(Z){W&&Z.name!==W.name&&(ee('"%s" works - aborting "%s"',Z.name,W.name),i())}function p(){W.removeListener("open",o),W.removeListener("error",a),W.removeListener("close",u),Y.removeListener("close",c),Y.removeListener("upgrading",f)}l.priorWebsocketSuccess=!1,W.once("open",o),W.once("error",a),W.once("close",u),this.once("close",c),this.once("upgrading",f),W.open()},l.prototype.onOpen=function(){if(ee("socket open"),this.readyState="open",l.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){ee("starting upgrade probes");for(var Z=0,W=this.upgrades.length;Z{var Y=$("./node_modules/engine.io-parser/lib/browser.js"),X=$("./node_modules/component-emitter/index.js");function s(Z){this.path=Z.path,this.hostname=Z.hostname,this.port=Z.port,this.secure=Z.secure,this.query=Z.query,this.timestampParam=Z.timestampParam,this.timestampRequests=Z.timestampRequests,this.readyState="",this.agent=Z.agent||!1,this.socket=Z.socket,this.enablesXDR=Z.enablesXDR,this.pfx=Z.pfx,this.key=Z.key,this.passphrase=Z.passphrase,this.cert=Z.cert,this.ca=Z.ca,this.ciphers=Z.ciphers,this.rejectUnauthorized=Z.rejectUnauthorized,this.forceNode=Z.forceNode,this.extraHeaders=Z.extraHeaders,this.localAddress=Z.localAddress}Z.exports=s,X(s.prototype),s.prototype.onError=function(Z,W){var $=new Error(Z);return $.type="TransportError",$.description=W,this.emit("error",$),this},s.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},s.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},s.prototype.send=function(Z){if("open"!==this.readyState)throw new Error("Transport not open");this.write(Z)},s.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},s.prototype.onData=function(Z){var W=Y.decodePacket(Z,this.socket.binaryType);this.onPacket(W)},s.prototype.onPacket=function(Z){this.emit("packet",Z)},s.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},"./node_modules/engine.io-client/lib/transports/index.js":(Z,W,$)=>{var Y=$("./node_modules/engine.io-client/lib/xmlhttprequest.js"),X=$("./node_modules/engine.io-client/lib/transports/polling-xhr.js"),ee=$("./node_modules/engine.io-client/lib/transports/polling-jsonp.js"),ae=$("./node_modules/engine.io-client/lib/transports/websocket.js");W.polling=function(Z){var W=!1,ae=!1,ie=!1!==Z.jsonp;if($.g.location){var le="https:"===location.protocol,ce=location.port;ce||(ce=le?443:80),W=Z.hostname!==location.hostname||ce!==Z.port,ae=Z.secure!==le}if(Z.xdomain=W,Z.xscheme=ae,"open"in new Y(Z)&&!Z.forceJSONP)return new X(Z);if(!ie)throw new Error("JSONP disabled");return new ee(Z)},W.websocket=ae},"./node_modules/engine.io-client/lib/transports/polling-jsonp.js":(Z,W,$)=>{var Y=$("./node_modules/engine.io-client/lib/transports/polling.js"),X=$("./node_modules/component-inherit/index.js");Z.exports=c;var ee,ae=/\n/g,ie=/\\n/g;function u(){}function c(Z){Y.call(this,Z),this.query=this.query||{},ee||($.g.___eio||($.g.___eio=[]),ee=$.g.___eio),this.index=ee.length;var W=this;ee.push((function(Z){W.onData(Z)})),this.query.j=this.index,$.g.document&&$.g.addEventListener&&$.g.addEventListener("beforeunload",(function(){W.script&&(W.script.onerror=u)}),!1)}X(c,Y),c.prototype.supportsBinary=!1,c.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),Y.prototype.doClose.call(this)},c.prototype.doPoll=function(){var Z=this,W=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),W.async=!0,W.src=this.uri(),W.onerror=function(W){Z.onError("jsonp poll error",W)};var $=document.getElementsByTagName("script")[0];$?$.parentNode.insertBefore(W,$):(document.head||document.body).appendChild(W),this.script=W,"undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent)&&setTimeout((function(){var Z=document.createElement("iframe");document.body.appendChild(Z),document.body.removeChild(Z)}),100)},c.prototype.doWrite=function(Z,W){var $=this;if(!this.form){var Y,X=document.createElement("form"),ee=document.createElement("textarea"),le=this.iframeId="eio_iframe_"+this.index;X.className="socketio",X.style.position="absolute",X.style.top="-1000px",X.style.left="-1000px",X.target=le,X.method="POST",X.setAttribute("accept-charset","utf-8"),ee.name="d",X.appendChild(ee),document.body.appendChild(X),this.form=X,this.area=ee}function c(){l(),W()}function l(){if($.iframe)try{$.form.removeChild($.iframe)}catch(Z){$.onError("jsonp polling iframe removal error",Z)}try{var Z='