@appbaseio/reactivesearch-vue 1.33.12 → 1.33.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/dist/@appbaseio/reactivesearch-vue.umd.js +3 -3
  2. package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
  3. package/dist/@appbaseio/reactivesearch-vue.umd.min.js +3 -3
  4. package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
  5. package/dist/cjs/DataSearch.js +2 -2
  6. package/dist/cjs/{DropDown-1c69b067.js → DropDown-7a52c661.js} +1 -1
  7. package/dist/cjs/DynamicRangeSlider.js +1 -1
  8. package/dist/cjs/MultiDropdownList.js +2 -2
  9. package/dist/cjs/MultiList.js +1 -1
  10. package/dist/cjs/MultiRange.js +1 -1
  11. package/dist/cjs/{Pagination-07f4dbad.js → Pagination-e56a5b79.js} +1 -1
  12. package/dist/cjs/RangeInput.js +1 -1
  13. package/dist/cjs/RangeSlider.js +1 -1
  14. package/dist/cjs/ReactiveBase.js +1 -2
  15. package/dist/cjs/ReactiveComponent.js +1 -1
  16. package/dist/cjs/{ReactiveComponentPrivate-fe54dfe2.js → ReactiveComponentPrivate-244c6055.js} +2 -2
  17. package/dist/cjs/ReactiveComponentPrivate.js +5 -5
  18. package/dist/cjs/ReactiveGoogleMap.js +2 -2
  19. package/dist/cjs/ReactiveList.js +2 -2
  20. package/dist/cjs/ResultCard.js +1 -1
  21. package/dist/cjs/ResultList.js +1 -1
  22. package/dist/cjs/SelectedFilters.js +1 -1
  23. package/dist/cjs/SingleDropdownList.js +2 -2
  24. package/dist/cjs/SingleList.js +1 -1
  25. package/dist/cjs/SingleRange.js +1 -1
  26. package/dist/cjs/{Tags-8fbad58b.js → Tags-4ec43831.js} +1 -1
  27. package/dist/cjs/ToggleButton.js +1 -1
  28. package/dist/cjs/index.js +5 -5
  29. package/dist/cjs/install.js +5 -5
  30. package/dist/cjs/version.js +1 -1
  31. package/dist/cjs/{vueTypes-7cfc2f98.js → vueTypes-b7007f5f.js} +2 -1
  32. package/dist/es/DataSearch.js +2 -2
  33. package/dist/es/{DropDown-40687515.js → DropDown-2c0dd714.js} +1 -1
  34. package/dist/es/DynamicRangeSlider.js +1 -1
  35. package/dist/es/MultiDropdownList.js +2 -2
  36. package/dist/es/MultiList.js +1 -1
  37. package/dist/es/MultiRange.js +1 -1
  38. package/dist/es/{Pagination-28e56c5c.js → Pagination-edeb7dbe.js} +1 -1
  39. package/dist/es/RangeInput.js +1 -1
  40. package/dist/es/RangeSlider.js +1 -1
  41. package/dist/es/ReactiveBase.js +1 -2
  42. package/dist/es/ReactiveComponent.js +1 -1
  43. package/dist/es/{ReactiveComponentPrivate-799f2576.js → ReactiveComponentPrivate-6f16e1b7.js} +2 -2
  44. package/dist/es/ReactiveComponentPrivate.js +5 -5
  45. package/dist/es/ReactiveGoogleMap.js +2 -2
  46. package/dist/es/ReactiveList.js +2 -2
  47. package/dist/es/ResultCard.js +1 -1
  48. package/dist/es/ResultList.js +1 -1
  49. package/dist/es/SelectedFilters.js +1 -1
  50. package/dist/es/SingleDropdownList.js +2 -2
  51. package/dist/es/SingleList.js +1 -1
  52. package/dist/es/SingleRange.js +1 -1
  53. package/dist/es/{Tags-7f4665a9.js → Tags-1c2d6c4d.js} +1 -1
  54. package/dist/es/ToggleButton.js +1 -1
  55. package/dist/es/index.js +5 -5
  56. package/dist/es/install.js +5 -5
  57. package/dist/es/version.js +1 -1
  58. package/dist/es/{vueTypes-8986b709.js → vueTypes-66ebc93e.js} +2 -1
  59. package/package.json +1 -1
@@ -10,14 +10,14 @@
10
10
  *
11
11
  * Copyright (c) 2014-2017, Jon Schlinkert.
12
12
  * Released under the MIT License.
13
- */function isObjectObject(e){return!0===isObject(e)&&"[object Object]"===Object.prototype.toString.call(e)}function isPlainObject$1(e){var t,n;return!1!==isObjectObject(e)&&("function"==typeof(t=e.constructor)&&(!1!==isObjectObject(n=t.prototype)&&!1!==n.hasOwnProperty("isPrototypeOf")))}var ObjProto=Object.prototype,toString=ObjProto.toString,hasOwn=ObjProto.hasOwnProperty,FN_MATCH_REGEXP=/^\s*function (\w+)/;function getType(e){var t=null!=e?e.type?e.type:e:null,n=t&&t.toString().match(FN_MATCH_REGEXP);return n&&n[1]}function getNativeType(e){if(null==e)return null;var t=e.constructor.toString().match(FN_MATCH_REGEXP);return t&&t[1]}function noop(){}var stubTrue=function(){return!0},has=function(e,t){return hasOwn.call(e,t)},isInteger=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},isArray=Array.isArray||function(e){return"[object Array]"===toString.call(e)},isFunction=function(e){return"[object Function]"===toString.call(e)};function withDefault(e){return Object.defineProperty(e,"def",{value:function(e){return void 0!==e||this.default?isFunction(e)||validateType(this,e)?(isArray(e)?this.default=function(){return[].concat(e)}:isPlainObject$1(e)?this.default=function(){return Object.assign({},e)}:this.default=e,this):(warn(this._vueTypes_name+' - invalid default value: "'+e+'"',e),this):this},enumerable:!1,writable:!1})}function withRequired(e){return Object.defineProperty(e,"isRequired",{get:function(){return this.required=!0,this},enumerable:!1})}function withValidate(e){return Object.defineProperty(e,"validate",{value:function(e){return this.validator=e.bind(this),this},enumerable:!1})}function toType(e,t,n){return void 0===n&&(n=!1),Object.defineProperty(t,"_vueTypes_name",{enumerable:!1,writable:!1,value:e}),withDefault(withRequired(t)),n?withValidate(t):Object.defineProperty(t,"validate",{value:function(){return warn(e+' - "validate" method not supported on this type'),this},enumerable:!1}),isFunction(t.validator)&&(t.validator=t.validator.bind(t)),t}function validateType(e,t,n){void 0===n&&(n=!1);var r,o=e,s=!0;isPlainObject$1(e)||(o={type:e});var a,i=o._vueTypes_name?o._vueTypes_name+" - ":"";if(hasOwn.call(o,"type")&&null!==o.type){if(void 0===o.type)throw new TypeError("[VueTypes error]: Setting type to undefined is not allowed.");if(!o.required&&void 0===t)return s;isArray(o.type)?(s=o.type.some((function(e){return validateType(e,t,!0)})),r=o.type.map((function(e){return getType(e)})).join(" or ")):s="Array"===(r=getType(o))?isArray(t):"Object"===r?isPlainObject$1(t):"String"===r||"Number"===r||"Boolean"===r||"Function"===r?getNativeType(t)===r:t instanceof o.type}return s?hasOwn.call(o,"validator")&&isFunction(o.validator)?(n&&(a=warn,warn=noop),s=o.validator(t),a&&(warn=a),s||!1!==n||warn(i+"custom validation failed"),s):s:(!1===n&&warn(i+'value "'+t+'" should be of type "'+r+'"'),!1)}var warn=noop,typeDefaults=function(){return{func:function(){},bool:!0,string:"",number:0,array:function(){return[]},object:function(){return{}},integer:0}},setDefaults=function(e){var t=typeDefaults();return Object.defineProperty(e,"sensibleDefaults",{enumerable:!1,set:function(e){t=!1===e?{}:!0===e?typeDefaults():e},get:function(){return t}})};function _objectWithoutPropertiesLoose$1(e,t){if(null==e)return{};var n,r,o={},s=Object.keys(e);for(r=0;r<s.length;r++)n=s[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}var VueTypes={get any(){return toType("any",{type:null},!0)},get func(){return toType("function",{type:Function},!0).def(VueTypes.sensibleDefaults.func)},get bool(){return toType("boolean",{type:Boolean},!0).def(VueTypes.sensibleDefaults.bool)},get string(){return toType("string",{type:String},!0).def(VueTypes.sensibleDefaults.string)},get number(){return toType("number",{type:Number},!0).def(VueTypes.sensibleDefaults.number)},get array(){return toType("array",{type:Array},!0).def(VueTypes.sensibleDefaults.array)},get object(){return toType("object",{type:Object},!0).def(VueTypes.sensibleDefaults.object)},get integer(){return toType("integer",{type:Number,validator:function(e){return isInteger(e)}}).def(VueTypes.sensibleDefaults.integer)},get symbol(){return toType("symbol",{type:null,validator:function(e){return"symbol"==typeof e}},!0)},extend:function(e){if(void 0===e&&(e={}),isArray(e))return e.forEach((function(e){return VueTypes.extend(e)})),this;var t=e,n=t.name,r=t.validate,o=void 0!==r&&r,s=t.getter,a=void 0!==s&&s,i=_objectWithoutPropertiesLoose$1(t,["name","validate","getter"]);if(has(VueTypes,n))throw new TypeError('[VueTypes error]: Type "'+n+'" already defined');var u,l=i.type,c=i.validator,p=void 0===c?stubTrue:c;if(l&&l._vueTypes_name){delete i.type;for(var d=["type","required","default"],h=0;h<d.length;h+=1){var f=d[h];void 0!==l[f]&&(i[f]=l[f])}o=!1,isFunction(l.validator)&&(i.validator=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return l.validator.apply(l,t)&&p.apply(this,t)})}if(a)u={get:function(){return toType(n,Object.assign({},i),o)},enumerable:!0,configurable:!1};else{var m=i.validator;u={value:function(){var e=toType(n,Object.assign({},i),o);if(m){for(var t=arguments.length,r=new Array(t),s=0;s<t;s++)r[s]=arguments[s];e.validator=m.bind.apply(m,[e].concat(r))}return e},writable:!1,enumerable:!0,configurable:!1}}return Object.defineProperty(this,n,u)},custom:function(e,t){if(void 0===t&&(t="custom validation failed"),"function"!=typeof e)throw new TypeError("[VueTypes error]: You must provide a function as argument");return toType(e.name||"<<anonymous function>>",{validator:function(n){var r=e(n);return r||warn(this._vueTypes_name+" - "+t),r}})},oneOf:function(e){if(!isArray(e))throw new TypeError("[VueTypes error]: You must provide an array as argument");var t='oneOf - value should be one of "'+e.join('", "')+'"',n=e.reduce((function(e,t){return null!=t&&-1===e.indexOf(t.constructor)&&e.push(t.constructor),e}),[]);return toType("oneOf",{type:n.length>0?n:null,validator:function(n){var r=-1!==e.indexOf(n);return r||warn(t),r}})},instanceOf:function(e){return toType("instanceOf",{type:e})},oneOfType:function(e){if(!isArray(e))throw new TypeError("[VueTypes error]: You must provide an array as argument");var t=!1,n=e.reduce((function(e,n){if(isPlainObject$1(n)){if("oneOf"===n._vueTypes_name)return e.concat(n.type||[]);if(isFunction(n.validator))return t=!0,e;if(n.type){if(isArray(n.type))return e.concat(n.type);e.push(n.type)}return e}return e.push(n),e}),[]);if(!t)return toType("oneOfType",{type:n});var r=e.map((function(e){return e&&isArray(e.type)?e.type.map(getType):getType(e)})).reduce((function(e,t){return e.concat(isArray(t)?t:[t])}),[]).join('", "');return this.custom((function(t){var n=e.some((function(e){return"oneOf"===e._vueTypes_name?!e.type||validateType(e.type,t,!0):validateType(e,t,!0)}));return n||warn('oneOfType - value type should be one of "'+r+'"'),n}))},arrayOf:function(e){return toType("arrayOf",{type:Array,validator:function(t){var n=t.every((function(t){return validateType(e,t)}));return n||warn('arrayOf - value must be an array of "'+getType(e)+'"'),n}})},objectOf:function(e){return toType("objectOf",{type:Object,validator:function(t){var n=Object.keys(t).every((function(n){return validateType(e,t[n])}));return n||warn('objectOf - value must be an object of "'+getType(e)+'"'),n}})},shape:function(e){var t=Object.keys(e),n=t.filter((function(t){return e[t]&&!0===e[t].required})),r=toType("shape",{type:Object,validator:function(r){var o=this;if(!isPlainObject$1(r))return!1;var s=Object.keys(r);return n.length>0&&n.some((function(e){return-1===s.indexOf(e)}))?(warn('shape - at least one of required properties "'+n.join('", "')+'" is not present'),!1):s.every((function(n){return-1===t.indexOf(n)?!0===o._vueTypes_isLoose||(warn('shape - object is missing "'+n+'" property'),!1):validateType(e[n],r[n])}))}});return Object.defineProperty(r,"_vueTypes_isLoose",{enumerable:!1,writable:!0,value:!1}),Object.defineProperty(r,"loose",{get:function(){return this._vueTypes_isLoose=!0,this},enumerable:!1}),r}};setDefaults(VueTypes),VueTypes.utils={validate:function(e,t){return validateType(t,e,!0)},toType:toType};var global$1="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{};function memoize(e){var t={};return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var unitlessKeys={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function murmurhash2_32_gc(e){for(var t,n=e.length,r=n^n,o=0;n>=4;)t=1540483477*(65535&(t=255&e.charCodeAt(o)|(255&e.charCodeAt(++o))<<8|(255&e.charCodeAt(++o))<<16|(255&e.charCodeAt(++o))<<24))+((1540483477*(t>>>16)&65535)<<16),r=1540483477*(65535&r)+((1540483477*(r>>>16)&65535)<<16)^(t=1540483477*(65535&(t^=t>>>24))+((1540483477*(t>>>16)&65535)<<16)),n-=4,++o;switch(n){case 3:r^=(255&e.charCodeAt(o+2))<<16;case 2:r^=(255&e.charCodeAt(o+1))<<8;case 1:r=1540483477*(65535&(r^=255&e.charCodeAt(o)))+((1540483477*(r>>>16)&65535)<<16)}return r=1540483477*(65535&(r^=r>>>13))+((1540483477*(r>>>16)&65535)<<16),((r^=r>>>15)>>>0).toString(36)}function stylis_min(e){function t(e,t,r){var o=t.trim().split(f);t=o;var s=o.length,a=e.length;switch(a){case 0:case 1:var i=0;for(e=0===a?"":e[0]+" ";i<s;++i)t[i]=n(e,t[i],r).trim();break;default:var u=i=0;for(t=[];i<s;++i)for(var l=0;l<a;++l)t[u++]=n(e[l]+" ",o[i],r).trim()}return t}function n(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function r(e,t,n,s){var a=e+";",i=2*t+3*n+4*s;if(944===i){e=a.indexOf(":",9)+1;var u=a.substring(e,a.length-1).trim();return u=a.substring(0,e).trim()+u+";",1===R||2===R&&o(u,1)?"-webkit-"+u+u:u}if(0===R||2===R&&!o(a,1))return a;switch(i){case 1015:return 97===a.charCodeAt(10)?"-webkit-"+a+a:a;case 951:return 116===a.charCodeAt(3)?"-webkit-"+a+a:a;case 963:return 110===a.charCodeAt(5)?"-webkit-"+a+a:a;case 1009:if(100!==a.charCodeAt(4))break;case 969:case 942:return"-webkit-"+a+a;case 978:return"-webkit-"+a+"-moz-"+a+a;case 1019:case 983:return"-webkit-"+a+"-moz-"+a+"-ms-"+a+a;case 883:if(45===a.charCodeAt(8))return"-webkit-"+a+a;if(0<a.indexOf("image-set(",11))return a.replace(S,"$1-webkit-$2")+a;break;case 932:if(45===a.charCodeAt(4))switch(a.charCodeAt(5)){case 103:return"-webkit-box-"+a.replace("-grow","")+"-webkit-"+a+"-ms-"+a.replace("grow","positive")+a;case 115:return"-webkit-"+a+"-ms-"+a.replace("shrink","negative")+a;case 98:return"-webkit-"+a+"-ms-"+a.replace("basis","preferred-size")+a}return"-webkit-"+a+"-ms-"+a+a;case 964:return"-webkit-"+a+"-ms-flex-"+a+a;case 1023:if(99!==a.charCodeAt(8))break;return"-webkit-box-pack"+(u=a.substring(a.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+a+"-ms-flex-pack"+u+a;case 1005:return d.test(a)?a.replace(p,":-webkit-")+a.replace(p,":-moz-")+a:a;case 1e3:switch(t=(u=a.substring(13).trim()).indexOf("-")+1,u.charCodeAt(0)+u.charCodeAt(t)){case 226:u=a.replace(_,"tb");break;case 232:u=a.replace(_,"tb-rl");break;case 220:u=a.replace(_,"lr");break;default:return a}return"-webkit-"+a+"-ms-"+u+a;case 1017:if(-1===a.indexOf("sticky",9))break;case 975:switch(t=(a=e).length-10,i=(u=(33===a.charCodeAt(t)?a.substring(0,t):a).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|u.charCodeAt(7))){case 203:if(111>u.charCodeAt(8))break;case 115:a=a.replace(u,"-webkit-"+u)+";"+a;break;case 207:case 102:a=a.replace(u,"-webkit-"+(102<i?"inline-":"")+"box")+";"+a.replace(u,"-webkit-"+u)+";"+a.replace(u,"-ms-"+u+"box")+";"+a}return a+";";case 938:if(45===a.charCodeAt(5))switch(a.charCodeAt(6)){case 105:return u=a.replace("-items",""),"-webkit-"+a+"-webkit-box-"+u+"-ms-flex-"+u+a;case 115:return"-webkit-"+a+"-ms-flex-item-"+a.replace(C,"")+a;default:return"-webkit-"+a+"-ms-flex-line-pack"+a.replace("align-content","").replace(C,"")+a}break;case 973:case 989:if(45!==a.charCodeAt(3)||122===a.charCodeAt(4))break;case 931:case 953:if(!0===T.test(e))return 115===(u=e.substring(e.indexOf(":")+1)).charCodeAt(0)?r(e.replace("stretch","fill-available"),t,n,s).replace(":fill-available",":stretch"):a.replace(u,"-webkit-"+u)+a.replace(u,"-moz-"+u.replace("fill-",""))+a;break;case 962:if(a="-webkit-"+a+(102===a.charCodeAt(5)?"-ms-"+a:"")+a,211===n+s&&105===a.charCodeAt(13)&&0<a.indexOf("transform",10))return a.substring(0,a.indexOf(";",27)+1).replace(h,"$1-webkit-$2")+a}return a}function o(e,t){var n=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?n:10);return n=e.substring(n+1,e.length-1),A(2!==t?r:r.replace(O,"$1"),n,t)}function s(e,t){var n=r(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace($," or ($1)").substring(4):"("+t+")"}function a(e,t,n,r,o,s,a,i,l,c){for(var p,d=0,h=t;d<x;++d)switch(p=I[d].call(u,e,h,n,r,o,s,a,i,l,c)){case void 0:case!1:case!0:case null:break;default:h=p}if(h!==t)return h}function i(e){return void 0!==(e=e.prefix)&&(A=null,e?"function"!=typeof e?R=1:(R=2,A=e):R=0),i}function u(e,n){var i=e;if(33>i.charCodeAt(0)&&(i=i.trim()),i=[i],0<x){var u=a(-1,n,i,i,P,w,0,0,0,0);void 0!==u&&"string"==typeof u&&(n=u)}var p=function e(n,i,u,p,d){for(var h,f,m,_,$,C=0,O=0,T=0,S=0,I=0,A=0,j=m=h=0,V=0,M=0,Q=0,D=0,F=u.length,N=F-1,q="",B="",U="",H="";V<F;){if(f=u.charCodeAt(V),V===N&&0!==O+S+T+C&&(0!==O&&(f=47===O?10:47),S=T=C=0,F++,N++),0===O+S+T+C){if(V===N&&(0<M&&(q=q.replace(c,"")),0<q.trim().length)){switch(f){case 32:case 9:case 59:case 13:case 10:break;default:q+=u.charAt(V)}f=59}switch(f){case 123:for(h=(q=q.trim()).charCodeAt(0),m=1,D=++V;V<F;){switch(f=u.charCodeAt(V)){case 123:m++;break;case 125:m--;break;case 47:switch(f=u.charCodeAt(V+1)){case 42:case 47:e:{for(j=V+1;j<N;++j)switch(u.charCodeAt(j)){case 47:if(42===f&&42===u.charCodeAt(j-1)&&V+2!==j){V=j+1;break e}break;case 10:if(47===f){V=j+1;break e}}V=j}}break;case 91:f++;case 40:f++;case 34:case 39:for(;V++<N&&u.charCodeAt(V)!==f;);}if(0===m)break;V++}switch(m=u.substring(D,V),0===h&&(h=(q=q.replace(l,"").trim()).charCodeAt(0)),h){case 64:switch(0<M&&(q=q.replace(c,"")),f=q.charCodeAt(1)){case 100:case 109:case 115:case 45:M=i;break;default:M=k}if(D=(m=e(i,M,m,f,d+1)).length,0<x&&($=a(3,m,M=t(k,q,Q),i,P,w,D,f,d,p),q=M.join(""),void 0!==$&&0===(D=(m=$.trim()).length)&&(f=0,m="")),0<D)switch(f){case 115:q=q.replace(b,s);case 100:case 109:case 45:m=q+"{"+m+"}";break;case 107:m=(q=q.replace(g,"$1 $2"))+"{"+m+"}",m=1===R||2===R&&o("@"+m,3)?"@-webkit-"+m+"@"+m:"@"+m;break;default:m=q+m,112===p&&(B+=m,m="")}else m="";break;default:m=e(i,t(i,q,Q),m,p,d+1)}U+=m,m=Q=M=j=h=0,q="",f=u.charCodeAt(++V);break;case 125:case 59:if(1<(D=(q=(0<M?q.replace(c,""):q).trim()).length))switch(0===j&&(h=q.charCodeAt(0),45===h||96<h&&123>h)&&(D=(q=q.replace(" ",":")).length),0<x&&void 0!==($=a(1,q,i,n,P,w,B.length,p,d,p))&&0===(D=(q=$.trim()).length)&&(q="\0\0"),h=q.charCodeAt(0),f=q.charCodeAt(1),h){case 0:break;case 64:if(105===f||99===f){H+=q+u.charAt(V);break}default:58!==q.charCodeAt(D-1)&&(B+=r(q,h,f,q.charCodeAt(2)))}Q=M=j=h=0,q="",f=u.charCodeAt(++V)}}switch(f){case 13:case 10:47===O?O=0:0===1+h&&107!==p&&0<q.length&&(M=1,q+="\0"),0<x*L&&a(0,q,i,n,P,w,B.length,p,d,p),w=1,P++;break;case 59:case 125:if(0===O+S+T+C){w++;break}default:switch(w++,_=u.charAt(V),f){case 9:case 32:if(0===S+C+O)switch(I){case 44:case 58:case 9:case 32:_="";break;default:32!==f&&(_=" ")}break;case 0:_="\\0";break;case 12:_="\\f";break;case 11:_="\\v";break;case 38:0===S+O+C&&(M=Q=1,_="\f"+_);break;case 108:if(0===S+O+C+E&&0<j)switch(V-j){case 2:112===I&&58===u.charCodeAt(V-3)&&(E=I);case 8:111===A&&(E=A)}break;case 58:0===S+O+C&&(j=V);break;case 44:0===O+T+S+C&&(M=1,_+="\r");break;case 34:case 39:0===O&&(S=S===f?0:0===S?f:S);break;case 91:0===S+O+T&&C++;break;case 93:0===S+O+T&&C--;break;case 41:0===S+O+C&&T--;break;case 40:if(0===S+O+C){if(0===h)switch(2*I+3*A){case 533:break;default:h=1}T++}break;case 64:0===O+T+S+C+j+m&&(m=1);break;case 42:case 47:if(!(0<S+C+T))switch(O){case 0:switch(2*f+3*u.charCodeAt(V+1)){case 235:O=47;break;case 220:D=V,O=42}break;case 42:47===f&&42===I&&D+2!==V&&(33===u.charCodeAt(D+2)&&(B+=u.substring(D,V+1)),_="",O=0)}}0===O&&(q+=_)}A=I,I=f,V++}if(0<(D=B.length)){if(M=i,0<x&&(void 0!==($=a(2,B,M,n,P,w,D,p,d,p))&&0===(B=$).length))return H+B+U;if(B=M.join(",")+"{"+B+"}",0!=R*E){switch(2!==R||o(B,2)||(E=0),E){case 111:B=B.replace(v,":-moz-$1")+B;break;case 112:B=B.replace(y,"::-webkit-input-$1")+B.replace(y,"::-moz-$1")+B.replace(y,":-ms-input-$1")+B}E=0}}return H+B+U}(k,i,n,0,0);return 0<x&&(void 0!==(u=a(-2,p,i,i,P,w,p.length,0,0,0))&&(p=u)),"",E=0,w=P=1,p}var l=/^\0+/g,c=/[\0\r\f]/g,p=/: */g,d=/zoo|gra/,h=/([,: ])(transform)/g,f=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,g=/@(k\w+)\s*(\S*)\s*/,y=/::(place)/g,v=/:(read-only)/g,_=/[svh]\w+-[tblr]{2}/,b=/\(\s*(.*)\s*\)/g,$=/([\s\S]*?);/g,C=/-self|flex-/g,O=/[^]*?(:[rp][el]a[\w-]+)[^]*/,T=/stretch|:\s*\w+\-(?:conte|avail)/,S=/([^-])(image-set\()/,w=1,P=1,E=0,R=1,k=[],I=[],x=0,A=null,L=0;return u.use=function e(t){switch(t){case void 0:case null:x=I.length=0;break;default:switch(t.constructor){case Array:for(var n=0,r=t.length;n<r;++n)e(t[n]);break;case Function:I[x++]=t;break;case Boolean:L=0|!!t}}return e},u.set=i,void 0!==e&&i(e),u}var stylisRuleSheet=createCommonjsModule((function(e,t){e.exports=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,o,s,a,i,u,l,c,p){switch(n){case 1:if(0===c&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===l)return r+"/*|*/";break;case 3:switch(l){case 102:case 112:return e(o[0]+r),"";default:return r+(0===p?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t)}}}})),hyphenateRegex=/[A-Z]|^ms/g,processStyleName=memoize((function(e){return e.replace(hyphenateRegex,"-$&").toLowerCase()})),processStyleValue=function(e,t){return null==t||"boolean"==typeof t?"":1===unitlessKeys[e]||45===e.charCodeAt(1)||isNaN(t)||0===t?t:t+"px"},classnames=function e(t){for(var n=t.length,r=0,o="";r<n;r++){var s=t[r];if(null!=s){var a=void 0;switch(typeof s){case"boolean":break;case"function":a=e([s()]);break;case"object":if(Array.isArray(s))a=e(s);else for(var i in a="",s)s[i]&&i&&(a&&(a+=" "),a+=i);break;default:a=s}a&&(o&&(o+=" "),o+=a)}}return o},isBrowser="undefined"!=typeof document;function sheetForTag(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function makeStyleTag(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key||""),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),(void 0!==e.container?e.container:document.head).appendChild(t),t}var StyleSheet=function(){function e(e){this.isSpeedy=!0,this.tags=[],this.ctr=0,this.opts=e}var t=e.prototype;return t.inject=function(){if(this.injected)throw new Error("already injected!");this.tags[0]=makeStyleTag(this.opts),this.injected=!0},t.speedy=function(e){if(0!==this.ctr)throw new Error("cannot change speedy now");this.isSpeedy=!!e},t.insert=function(e,t){if(this.isSpeedy){var n=sheetForTag(this.tags[this.tags.length-1]);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else{var r=makeStyleTag(this.opts);this.tags.push(r),r.appendChild(document.createTextNode(e+(t||"")))}this.ctr++,this.ctr%65e3==0&&this.tags.push(makeStyleTag(this.opts))},t.flush=function(){this.tags.forEach((function(e){return e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0,this.injected=!1},e}();function createEmotion(e,t){if(void 0!==e.__SECRET_EMOTION__)return e.__SECRET_EMOTION__;void 0===t&&(t={});var n,r=t.key||"css";var o,s=stylisRuleSheet((function(e){n+=e,isBrowser&&i.insert(e,l)}));void 0!==t.prefix&&(o={prefix:t.prefix});var a={registered:{},inserted:{},nonce:t.nonce,key:r},i=new StyleSheet(t);isBrowser&&i.inject();var u=new stylis_min(o);u.use(t.stylisPlugins)(s);var l="";function c(e,t){if(null==e)return"";switch(typeof e){case"boolean":return"";case"function":if(void 0!==e.__emotion_styles){var n=e.toString();return n}return c.call(this,void 0===this?e():e(this.mergedProps,this.context),t);case"object":return f.call(this,e);default:var r=a.registered[e];return!1===t&&void 0!==r?r:e}}var p,d,h=new WeakMap;function f(e){if(h.has(e))return h.get(e);var t="";return Array.isArray(e)?e.forEach((function(e){t+=c.call(this,e,!1)}),this):Object.keys(e).forEach((function(n){"object"!=typeof e[n]?void 0!==a.registered[e[n]]?t+=n+"{"+a.registered[e[n]]+"}":t+=processStyleName(n)+":"+processStyleValue(n,e[n])+";":Array.isArray(e[n])&&"string"==typeof e[n][0]&&void 0===a.registered[e[n][0]]?e[n].forEach((function(e){t+=processStyleName(n)+":"+processStyleValue(n,e)+";"})):t+=n+"{"+c.call(this,e[n],!1)+"}"}),this),h.set(e,t),t}var m=/label:\s*([^\s;\n{]+)\s*;/g,g=function(e,t){return murmurhash2_32_gc(e+t)+t},y=function(e){var t=!0,n="",r="";null==e||void 0===e.raw?(t=!1,n+=c.call(this,e,!1)):n+=e[0];for(var o=arguments.length,s=new Array(o>1?o-1:0),a=1;a<o;a++)s[a-1]=arguments[a];return s.forEach((function(r,o){n+=c.call(this,r,46===n.charCodeAt(n.length-1)),!0===t&&void 0!==e[o+1]&&(n+=e[o+1])}),this),d=n,n=n.replace(m,(function(e,t){return r+="-"+t,""})),p=g(n,r),n};function v(e,t){void 0===a.inserted[p]&&(n="",u(e,t),a.inserted[p]=n)}var _=function(){var e=y.apply(this,arguments),t=r+"-"+p;return void 0===a.registered[t]&&(a.registered[t]=d),v("."+t,e),t};function b(e,t){var n="";return t.split(" ").forEach((function(t){void 0!==a.registered[t]?e.push(t):n+=t+" "})),n}function $(e,t){var n=[],r=b(n,e);return n.length<2?e:r+_(n,t)}function C(e){a.inserted[e]=!0}if(isBrowser){var O=document.querySelectorAll("[data-emotion-"+r+"]");Array.prototype.forEach.call(O,(function(e){i.tags[0].parentNode.insertBefore(e,i.tags[0]),e.getAttribute("data-emotion-"+r).split(" ").forEach(C)}))}var T={flush:function(){isBrowser&&(i.flush(),i.inject()),a.inserted={},a.registered={}},hydrate:function(e){e.forEach(C)},cx:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return $(classnames(t))},merge:$,getRegisteredStyles:b,injectGlobal:function(){var e=y.apply(this,arguments);v("",e)},keyframes:function(){var e=y.apply(this,arguments),t="animation-"+p;return v("","@keyframes "+t+"{"+e+"}"),t},css:_,sheet:i,caches:a};return e.__SECRET_EMOTION__=T,T}var context=void 0!==global$1?global$1:{},_createEmotion=createEmotion(context),flush=_createEmotion.flush,hydrate=_createEmotion.hydrate,cx=_createEmotion.cx,merge=_createEmotion.merge,getRegisteredStyles=_createEmotion.getRegisteredStyles,injectGlobal=_createEmotion.injectGlobal,keyframes=_createEmotion.keyframes,css=_createEmotion.css,sheet=_createEmotion.sheet,caches=_createEmotion.caches,index=function(e){for(var t=arguments,n=1;n<arguments.length;n++)for(var r in arguments[n])e[r]=t[n][r];return e},nanoAssign_common=index,STYLES_KEY="__emotion_styles";function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function stringifyClass(e){return Array.isArray(e)?e.join(" "):"object"===_typeof(e)?Object.keys(e).filter((function(t){return Boolean(e[t])})).join(" "):e}var index$1=function(e,t){var n,r,o,s;void 0!==t&&(n=t.e,r=t.label,o=t.target,s=t.props);var a=e.__emotion_real===e,i=void 0===n&&a&&e.__emotion_base||e;return function(){var t=a&&void 0!==e[STYLES_KEY]?e[STYLES_KEY].slice(0):[];if(void 0!==r&&t.push("label:".concat(r,";")),void 0===n){for(var u=arguments.length,l=new Array(u),c=0;c<u;c++)l[c]=arguments[c];if(null===l[0]||void 0===l[0].raw)t.push.apply(t,l);else{t.push(l[0][0]);for(var p=l.length,d=1;d<p;d++)t.push(l[d],l[0][d])}}var h={name:"Styled".concat(e.name||r||"Component"),functional:!0,inject:{theme:{from:"theme_reactivesearch",default:null}},props:s,render:function(r,s){var a=s.data,i=s.children,u=s.props,l=s.injections,c="",p=[],d=stringifyClass(a.class),h={};for(var f in a.attrs)"$"!==f[0]&&(h[f]=a.attrs[f]);if(d&&(c+=void 0===n?getRegisteredStyles(p,d):"".concat(d," ")),void 0===n){var m={mergedProps:nanoAssign_common({theme:l.theme},u)};c+=css.apply(m,t.concat(p))}else c+=n;return void 0!==o&&(c+=" ".concat(o)),r(e,nanoAssign_common({},a,{attrs:h,class:c}),i)}};return h[STYLES_KEY]=t,h.__emotion_base=i,h.__emotion_real=h,Object.defineProperty(h,"toString",{enumerable:!1,value:function(){return".".concat(o)}}),h}};function _extends$1(){return(_extends$1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function colorToInt(e){return Math.round(255*e)}function convertToInt(e,t,n){return colorToInt(e)+","+colorToInt(t)+","+colorToInt(n)}function hslToRgb(e,t,n,r){if(void 0===r&&(r=convertToInt),0===t)return r(n,n,n);var o=e%360/60,s=(1-Math.abs(2*n-1))*t,a=s*(1-Math.abs(o%2-1)),i=0,u=0,l=0;o>=0&&o<1?(i=s,u=a):o>=1&&o<2?(i=a,u=s):o>=2&&o<3?(u=s,l=a):o>=3&&o<4?(u=a,l=s):o>=4&&o<5?(i=a,l=s):o>=5&&o<6&&(i=s,l=a);var c=n-s/2;return r(i+c,u+c,l+c)}var namedColorMap={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function nameToHex(e){if("string"!=typeof e)return e;var t=e.toLowerCase();return namedColorMap[t]?"#"+namedColorMap[t]:e}var hexRegex=/^#[a-fA-F0-9]{6}$/,hexRgbaRegex=/^#[a-fA-F0-9]{8}$/,reducedHexRegex=/^#[a-fA-F0-9]{3}$/,reducedRgbaHexRegex=/^#[a-fA-F0-9]{4}$/,rgbRegex=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/,rgbaRegex=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/,hslRegex=/^hsl\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*\)$/,hslaRegex=/^hsla\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/;function parseToRgb(e){if("string"!=typeof e)throw new Error("Passed an incorrect argument to a color function, please pass a string representation of a color.");var t=nameToHex(e);if(t.match(hexRegex))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(hexRgbaRegex)){var n=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:n}}if(t.match(reducedHexRegex))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(reducedRgbaHexRegex)){var r=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:r}}var o=rgbRegex.exec(t);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10)};var s=rgbaRegex.exec(t);if(s)return{red:parseInt(""+s[1],10),green:parseInt(""+s[2],10),blue:parseInt(""+s[3],10),alpha:parseFloat(""+s[4])};var a=hslRegex.exec(t);if(a){var i="rgb("+hslToRgb(parseInt(""+a[1],10),parseInt(""+a[2],10)/100,parseInt(""+a[3],10)/100)+")",u=rgbRegex.exec(i);if(!u)throw new Error("Couldn't generate valid rgb string from "+t+", it returned "+i+".");return{red:parseInt(""+u[1],10),green:parseInt(""+u[2],10),blue:parseInt(""+u[3],10)}}var l=hslaRegex.exec(t);if(l){var c="rgb("+hslToRgb(parseInt(""+l[1],10),parseInt(""+l[2],10)/100,parseInt(""+l[3],10)/100)+")",p=rgbRegex.exec(c);if(!p)throw new Error("Couldn't generate valid rgb string from "+t+", it returned "+c+".");return{red:parseInt(""+p[1],10),green:parseInt(""+p[2],10),blue:parseInt(""+p[3],10),alpha:parseFloat(""+l[4])}}throw new Error("Couldn't parse the color string. Please provide the color as a string in hex, rgb, rgba, hsl or hsla notation.")}function rgbToHsl(e){var t,n=e.red/255,r=e.green/255,o=e.blue/255,s=Math.max(n,r,o),a=Math.min(n,r,o),i=(s+a)/2;if(s===a)return void 0!==e.alpha?{hue:0,saturation:0,lightness:i,alpha:e.alpha}:{hue:0,saturation:0,lightness:i};var u=s-a,l=i>.5?u/(2-s-a):u/(s+a);switch(s){case n:t=(r-o)/u+(r<o?6:0);break;case r:t=(o-n)/u+2;break;default:t=(n-r)/u+4}return t*=60,void 0!==e.alpha?{hue:t,saturation:l,lightness:i,alpha:e.alpha}:{hue:t,saturation:l,lightness:i}}function parseToHsl(e){return rgbToHsl(parseToRgb(e))}var reduceHexValue=function(e){return 7===e.length&&e[1]===e[2]&&e[3]===e[4]&&e[5]===e[6]?"#"+e[1]+e[3]+e[5]:e};function numberToHex(e){var t=e.toString(16);return 1===t.length?"0"+t:t}function colorToHex(e){return numberToHex(Math.round(255*e))}function convertToHex(e,t,n){return reduceHexValue("#"+colorToHex(e)+colorToHex(t)+colorToHex(n))}function hslToHex(e,t,n){return hslToRgb(e,t,n,convertToHex)}function hsl(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return hslToHex(e,t,n);if("object"==typeof e&&void 0===t&&void 0===n)return hslToHex(e.hue,e.saturation,e.lightness);throw new Error("Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).")}function hsla(e,t,n,r){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n&&"number"==typeof r)return r>=1?hslToHex(e,t,n):"rgba("+hslToRgb(e,t,n)+","+r+")";if("object"==typeof e&&void 0===t&&void 0===n&&void 0===r)return e.alpha>=1?hslToHex(e.hue,e.saturation,e.lightness):"rgba("+hslToRgb(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Error("Passed invalid arguments to hsla, please pass multiple numbers e.g. hsl(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).")}function rgb(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return reduceHexValue("#"+numberToHex(e)+numberToHex(t)+numberToHex(n));if("object"==typeof e&&void 0===t&&void 0===n)return reduceHexValue("#"+numberToHex(e.red)+numberToHex(e.green)+numberToHex(e.blue));throw new Error("Passed invalid arguments to rgb, please pass multiple numbers e.g. rgb(255, 205, 100) or an object e.g. rgb({ red: 255, green: 205, blue: 100 }).")}function rgba(e,t,n,r){if("string"==typeof e&&"number"==typeof t){var o=parseToRgb(e);return"rgba("+o.red+","+o.green+","+o.blue+","+t+")"}if("number"==typeof e&&"number"==typeof t&&"number"==typeof n&&"number"==typeof r)return r>=1?rgb(e,t,n):"rgba("+e+","+t+","+n+","+r+")";if("object"==typeof e&&void 0===t&&void 0===n&&void 0===r)return e.alpha>=1?rgb(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")";throw new Error("Passed invalid arguments to rgba, please pass multiple numbers e.g. rgb(255, 205, 100, 0.75) or an object e.g. rgb({ red: 255, green: 205, blue: 100, alpha: 0.75 }).")}var isRgb=function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&("number"!=typeof e.alpha||void 0===e.alpha)},isRgba=function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&"number"==typeof e.alpha},isHsl=function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&("number"!=typeof e.alpha||void 0===e.alpha)},isHsla=function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&"number"==typeof e.alpha},errMsg="Passed invalid argument to toColorString, please pass a RgbColor, RgbaColor, HslColor or HslaColor object.";function toColorString(e){if("object"!=typeof e)throw new Error(errMsg);if(isRgba(e))return rgba(e);if(isRgb(e))return rgb(e);if(isHsla(e))return hsla(e);if(isHsl(e))return hsl(e);throw new Error(errMsg)}function curried(e,t,n){return function(){var r=n.concat(Array.prototype.slice.call(arguments));return r.length>=t?e.apply(this,r):curried(e,t,r)}}function curry(e){return curried(e,e.length,[])}function guard(e,t,n){return Math.max(e,Math.min(t,n))}function darken(e,t){var n=parseToHsl(t);return toColorString(_extends$1({},n,{lightness:guard(0,1,n.lightness-parseFloat(e))}))}var curriedDarken=curry(darken);function lighten(e,t){var n=parseToHsl(t);return toColorString(_extends$1({},n,{lightness:guard(0,1,n.lightness+parseFloat(e))}))}var curriedLighten=curry(lighten),_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,filters=function(e){var t=e.colors.borderColor;return css(_templateObject||(_templateObject=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -3px;\n\tmax-width: 100%;\n\n\tbutton {\n\t\tmargin: 2px 3px;\n\t\tpadding: 5px 8px;\n\t\tfont-size: 0.85rem;\n\t\tposition: relative;\n\n\t\tspan:first-child {\n\t\t\tmax-width: 260px;\n\t\t\twhite-space: nowrap;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\tmargin-right: 26px;\n\t\t}\n\n\t\tspan:last-child {\n\t\t\tdisplay: flex;\n\t\t\theight: 100%;\n\t\t\ttop: 0;\n\t\t\tright: 8px;\n\t\t\tposition: absolute;\n\t\t\talign-items: center;\n\t\t\tborder-left: 1px solid ",";\n\t\t\tpadding-left: 8px;\n\t\t\tmargin-left: 8px;\n\t\t}\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tspan:first-child {\n\t\t\t\ttext-decoration: line-through;\n\t\t\t}\n\t\t}\n\t}\n"])),t||"#fff")},pagination=css(_templateObject2||(_templateObject2=_taggedTemplateLiteralLoose(["\n\tmargin: 10px -3px;\n\tmax-width: 100%;\n\ttext-align: center;\n\n\tbutton {\n\t\tmargin: 0 3px;\n\t}\n"]))),toggleButtons=css(_templateObject3||(_templateObject3=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -3px;\n\tmax-width: 100%;\n\n\tbutton {\n\t\tmargin: 3px 3px;\n\t}\n"]))),numberBoxContainer=css(_templateObject4||(_templateObject4=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -5px;\n\tbutton {\n\t\tmargin: 5px;\n\t}\n\tspan {\n\t\tmargin: 0 5px;\n\t}\n"]))),primary=function(e){var t=e.theme;return css(_templateObject5||(_templateObject5=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: ",";\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.primaryColor,t.colors.primaryTextColor,curriedDarken(.1,t.colors.primaryColor))},large=function(){return css(_templateObject6||(_templateObject6=_taggedTemplateLiteralLoose(["\n\tmin-height: 40px;\n\tpadding: 10px 20px;\n"])))},disabled=function(e){var t=e.theme;return css(_templateObject7||(_templateObject7=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: #ccc;\n\tcursor: not-allowed;\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fafafa",t.colors.backgroundColor?curriedLighten(.2,t.colors.backgroundColor):"#fafafa")},Button=index$1("button")(_templateObject8||(_templateObject8=_taggedTemplateLiteralLoose(["\n\tdisplay: inline-flex;\n\tjustify-content: center;\n\talign-items: center;\n\tborder-radius: 3px;\n\tborder: 1px solid transparent;\n\tmin-height: 30px;\n\tword-wrap: break-word;\n\tpadding: 5px 12px;\n\tline-height: 1.2rem;\n\tbackground-color: ",";\n\tcolor: ",";\n\tcursor: pointer;\n\tuser-select: none;\n\ttransition: all 0.3s ease;\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n\n\t&:focus {\n\t\toutline: 0;\n\t\tborder-color: ",";\n\t\tbox-shadow: ",";\n\t}\n\n\t",";\n\t",";\n\t",";\n\n\t&.enter-btn {\n\t\tborder-top-left-radius: 0px;\n\t\tborder-bottom-left-radius: 0px;\n\t\theight: 100%;\n\t}\n"])),(function(e){return e.theme.colors.backgroundColor||"#eee"}),(function(e){return e.theme.colors.textColor}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedDarken(.1,t.colors.backgroundColor):"#ccc"}),(function(e){return rgba(e.theme.colors.primaryColor,.6)}),(function(e){return"0 0 0 2px "+rgba(e.theme.colors.primaryColor,.3)}),(function(e){return e.primary?primary:null}),(function(e){return e.disabled?disabled:null}),(function(e){return e.large&&large})),loadMoreContainer=css({margin:"5px 0",display:"flex",justifyContent:"center"});VueTypes.sensibleDefaults=!1;var reactKeyType=VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string),VueTypes.object,VueTypes.arrayOf(VueTypes.object)]);function validateLocation(e){return e&&e.lat&&e.lng?isNaN(e.lat)?(console.error(new Error("lat value must be a number")),!1):isNaN(e.lat)?(console.error(new Error("lng value must be a number")),!1):e.lat<-90||e.lat>90?(console.error(new Error("lat value should be between -90 and 90.")),!1):!(e.lat<-180||e.lat>180)||(console.error(new Error("lng value should be between -180 and 180.")),!1):(console.error(new Error("location must be an object with lat and lng keys defined")),!1)}var types={any:VueTypes.any,bool:VueTypes.bool,boolRequired:VueTypes.bool.isRequired,components:VueTypes.arrayOf(VueTypes.string),children:VueTypes.any,data:VueTypes.arrayOf(VueTypes.object),dataFieldArray:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]).isRequired,dataNumberBox:VueTypes.shape({label:VueTypes.string,start:VueTypes.number.isRequired,end:VueTypes.number.isRequired}).isRequired,date:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]),dateObject:VueTypes.object,excludeFields:VueTypes.arrayOf(VueTypes.string),fieldWeights:VueTypes.arrayOf(VueTypes.number),filterLabel:VueTypes.string,func:VueTypes.func,funcRequired:VueTypes.func.isRequired,fuzziness:VueTypes.oneOf([0,1,2,"AUTO"]),headers:VueTypes.object,hits:VueTypes.arrayOf(VueTypes.object),iconPosition:VueTypes.oneOf(["left","right"]),includeFields:VueTypes.arrayOf(VueTypes.string),labelPosition:VueTypes.oneOf(["left","right","top","bottom"]),number:VueTypes.number,options:VueTypes.oneOfType([VueTypes.arrayOf(VueTypes.object),VueTypes.object]),paginationAt:VueTypes.oneOf(["top","bottom","both"]),range:VueTypes.shape({start:VueTypes.number.isRequired,end:VueTypes.number.isRequired}),rangeLabels:VueTypes.shape({start:VueTypes.string.isRequired,end:VueTypes.string.isRequired}),react:VueTypes.shape({and:reactKeyType,or:reactKeyType,not:reactKeyType}),selectedValues:VueTypes.object,selectedValue:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string),VueTypes.arrayOf(VueTypes.object),VueTypes.object,Number,VueTypes.arrayOf(Number)]),suggestions:VueTypes.arrayOf(VueTypes.object),supportedOrientations:VueTypes.oneOf(["portrait","portrait-upside-down","landscape","landscape-left","landscape-right"]),sortBy:VueTypes.oneOf(["asc","desc"]),sortOptions:VueTypes.arrayOf(VueTypes.shape({label:VueTypes.string,dataField:VueTypes.string,sortBy:VueTypes.string})),sortByWithCount:VueTypes.oneOf(["asc","desc","count"]),stats:VueTypes.arrayOf(VueTypes.object),string:VueTypes.string,stringArray:VueTypes.arrayOf(VueTypes.string),stringOrArray:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]),stringRequired:VueTypes.string.isRequired,style:VueTypes.object,themePreset:VueTypes.oneOf(["light","dark"]),queryFormatSearch:VueTypes.oneOf(["and","or"]),queryFormatNumberBox:VueTypes.oneOf(["exact","lte","gte"]),params:VueTypes.object.isRequired,props:VueTypes.object,rangeLabelsAlign:VueTypes.oneOf(["left","right"]),title:VueTypes.oneOfType([VueTypes.string,VueTypes.any]),tooltipTrigger:VueTypes.oneOf(["always","none","hover"]),location:VueTypes.custom(validateLocation),unit:VueTypes.oneOf(["mi","miles","yd","yards","ft","feet","in","inch","km","kilometers","m","meters","cm","centimeters","mm","millimeters","NM","nmi","nauticalmiles"]),value:VueTypes.string.def(void 0),analyticsConfig:VueTypes.shape({emptyQuery:VueTypes.bool,suggestionAnalytics:VueTypes.bool,userId:VueTypes.string,customEvents:VueTypes.object}),appbaseConfig:VueTypes.shape({recordAnalytics:VueTypes.bool,emptyQuery:VueTypes.bool,suggestionAnalytics:VueTypes.bool,enableQueryRules:VueTypes.bool,enableSearchRelevancy:VueTypes.bool,userId:VueTypes.string,useCache:VueTypes.bool,customEvents:VueTypes.object,enableTelemetry:VueTypes.bool.def(!0)}).def({}),mongodb:VueTypes.shape({db:VueTypes.string,collection:VueTypes.string}),endpointConfig:VueTypes.shape({url:VueTypes.string.isRequired,method:VueTypes.string,headers:VueTypes.object,body:VueTypes.object})},getClassName=lib_8.getClassName,handleA11yAction=lib_8.handleA11yAction;function getStartPage(e,t,n){var r=parseInt(e/2,10),o=t-(n?Math.ceil(r/2)-1:r);return o>1?o:2}var Pagination={name:"Pagination",functional:!0,props:{currentPage:types.number,innerClass:types.style,pages:types.number,setPage:types.func,totalPages:types.number,showEndPage:VueTypes.bool,prevLabel:types.string,nextLabel:types.string},render:function(e,t){var n=arguments[0],r=t.props,o=function(){r.currentPage&&r.setPage(r.currentPage-1)},s=function(){r.currentPage<r.totalPages-1&&r.setPage(r.currentPage+1)};if(!r.totalPages)return null;var a=getClassName(r.innerClass,"button"),i=0===r.currentPage,u=a||i?a+" "+(i?"active":""):"",l=function(e){var t=r.pages,o=r.currentPage,s=r.totalPages,i=r.setPage,u=r.showEndPage,l="start"===e?getStartPage(t,o,u):Math.max(2,Math.ceil(s-(t-1)/2+1)),c=[],p=l;if(l<=s){var d=t<s?l+(t-1):s+1;u&&(d="start"===e?l+(Math.ceil(t/2)-t%2):s+1),o>s-t+2&&(l=Math.max(2,s-t+2),d=l+t);for(var h=function(e){var t=o===e-1,r=n(Button,{class:a||t?a+" "+(t?"active":""):"",attrs:{primary:t,tabIndex:"0",alt:"page-"+e},on:{keyPress:function(t){return handleA11yAction(t,(function(){return i(e-1)}))},click:function(){return i(e-1)}}},[e]);e<=s+1&&(c.push(r),e===Math.min(s+1,d)-1&&(p=e))},f=l;f<Math.min(s+1,d);f+=1)h(f)}return[c,l,p]},c=function(){var e=r.showEndPage,t=r.currentPage,n=r.totalPages,o=r.pages;return e?t<=n-o+2||n<o?l("start")[0]:null:l("start")[0]};return n("div",{class:pagination+" "+getClassName(r.innerClass,"pagination")},[n(Button,{class:getClassName(r.innerClass,"button")||"",attrs:{disabled:0===r.currentPage,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,o)},click:o}},[r.prevLabel||"Prev"]),n(Button,{class:u,attrs:{primary:i,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,(function(){return r.setPage(0)}))},click:function(){return r.setPage(0)}}},["1"]),r.showEndPage&&r.currentPage>=Math.floor(r.pages/2)+!!(r.pages%2)&&2!==l("start")[1]?n("span",["..."]):null,c(),r.showEndPage&&r.pages>2&&r.currentPage<=r.totalPages-Math.ceil(.75*r.pages)&&l("start")[2]!==l("end")[1]-1?n("span",["..."]):null,r.showEndPage&&r.totalPages>=r.pages&&l("end")[0],n(Button,{class:getClassName(r.innerClass,"button")||"",attrs:{disabled:r.currentPage>=r.totalPages-1,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,s)},click:s}},[r.nextLabel||"Next"])])}},_templateObject$1;Pagination.install=function(e){e.component(Pagination.name,Pagination)};var PoweredByImage=index$1("img")(_templateObject$1||(_templateObject$1=_taggedTemplateLiteralLoose(["\n\twidth: 110px;\n"]))),PoweredBy={functional:!0,render:function(e){return e("a",{attrs:{href:"https://appbase.io/",target:"_blank",rel:"noopener noreferrer"}},[e(PoweredByImage,{attrs:{src:"https://cdn.jsdelivr.net/gh/appbaseio/cdn@d2ec210045e59104ee5485841fa17b23fc83f097/appbase/logos/rbc-logo.svg"}})])}},hasOwn$1=Object.prototype.hasOwnProperty;function is(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!=e&&t!=t}function shallowEqual(e,t){if(is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=0;o<n.length;o+=1)if(!hasOwn$1.call(t,n[o])||!is(e[n[o]],t[n[o]]))return!1;return!0}var defaultMapState=function(){return{}},defaultMapDispatch={},normalizeMapState=function(e){if("function"==typeof e)return e;if(e===Object(e))return function(t,n){return Object.keys(e).filter((function(t){return"function"==typeof e[t]})).reduce((function(r,o){var s;return _extends({},r,((s={})[o]=e[o](t,n),s))}),{})};throw new Error("[revux] - mapState provided to connect is invalid")},connector=function(e,t){return void 0===e&&(e=defaultMapState),void 0===t&&(t=defaultMapDispatch),function(n){var r=normalizeMapState(e);return{name:"connect-"+n.name,mixins:[n],inject:["$$store"],data:function(){var e=_extends({},r(this.$$store.getState(),this.$props||{}),bindActionCreators(t,this.$$store.dispatch));return Object.keys(e).reduce((function(t,n){var r;return _extends({},t,((r={})[n]=e[n],r))}),{})},created:function(){var e=this;this._unsubscribe=function(e,t,n){var r=t(e.getState());return e.subscribe((function(){var o=t(e.getState());if(!shallowEqual(r,o)){var s=r;n(r=o,s)}}))}(this.$$store,(function(t){return r(t,e.$props||{})}),(function(t){Object.keys(t).forEach((function(n){e.$set(e,n,t[n])}))}))},beforeDestroy:function(){this._unsubscribe()}}}},defaultQueryUtil=lib_8.updateDefaultQuery,customQueryUtil=lib_8.updateCustomQuery,isEqual=lib_8.isEqual,connect=function(){return connector.apply(void 0,arguments)},X_SEARCH_CLIENT="ReactiveSearch Vue",composeThemeObject=function(e,t){return void 0===e&&(e={}),void 0===t&&(t={}),{typography:_extends({},e.typography,t.typography),colors:_extends({},e.colors,t.colors),component:_extends({},e.component,t.component)}},isFunction$1=function(e){return"function"==typeof e};function parseValueArray(e,t){var n;Array.isArray(e)?n=[].concat(e):n=Object.keys(e).map((function(t){return e[t]?t:null}));return n.includes(t)?n.filter((function(e){return e!==t})):[].concat(n,[t])}var getComponent=function(e,t){void 0===e&&(e={}),void 0===t&&(t={});var n=(t.$scopedSlots||t.$props).render;return n?n(e):null},hasCustomRenderer=function(e){void 0===e&&(e={});var t=(e.$scopedSlots||e.$props).render;return Boolean(t)},getValidPropsKeys=function(e){return void 0===e&&(e={}),Object.keys(e).filter((function(e){return constants_3$1.includes(e)}))},isEvent=function(e){return!!(e&&e.stopPropagation&&e.preventDefault)},updateDefaultQuery=function(e,t,n,r){defaultQueryUtil(e,_extends({},n,{setDefaultQuery:t}),r)},updateCustomQuery=function(e,t,n,r){customQueryUtil(e,_extends({},n,{setCustomQuery:t}),r)},isQueryIdentical=function(e,t,n,r){return"function"!=typeof e||"function"!=typeof t||isEqual(t(n,r),e(n,r))},getQuerySuggestionsComponent=function(e,t){void 0===e&&(e={}),void 0===t&&(t={});var n=t.$scopedSlots||t.$props,r=n.renderQuerySuggestions,o=n.renderPopularSuggestions||r;return o?o(e):null},hasQuerySuggestionsRenderer=function(e){void 0===e&&(e={});var t=e.$scopedSlots||e.$props,n=t.renderQuerySuggestions,r=t.renderPopularSuggestions;return Boolean(r)||Boolean(n)},getCamelCase=function(e){void 0===e&&(e="");var t=e.split("-").map((function(e,t){return t?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e})).join("");return["u-r-l-params"].includes(e)&&(t=t[0].toUpperCase()+t.substring(1)),t||""},isEmpty=function(e){return!(e&&e.length&&Object.keys(e).length)};function isNumeric(e){return/^-?\d+$/.test(e)}function isHotkeyCombination(e){return"string"==typeof e&&-1!==e.indexOf("+")}function getCharFromCharCode(e){var t=e,n=t-48*Math.floor(t/48);return String.fromCharCode(t>=96?n:t)}function parseFocusShortcuts(e){if(isEmpty(e))return[];var t=[];return e.forEach((function(e){if("string"==typeof e)if(isHotkeyCombination(e)){for(var n,r=e.split("+"),o=[],s=0;s<r.length;s+=1)isNumeric(r[s])?o.push(getCharFromCharCode(+r[s])):o.push(r[s]);n=o.join("+"),t.push(n)}else isNumeric(e)?t.push(getCharFromCharCode(+e)):t.push(e);else t.push(getCharFromCharCode(e))})),t}var MODIFIER_KEYS=["shift","ctrl","alt","control","option","cmd","command"];function extractModifierKeysFromFocusShortcuts(e){return e.filter((function(e){return MODIFIER_KEYS.includes(e)}))}function decodeHtml(e){return"string"!=typeof e?e:e.replace(/&#([0-9]{1,3});/gi,(function(e,t){var n=parseInt(t,10);return String.fromCharCode(n)}))}var addComponent=lib_5.addComponent,removeComponent=lib_5.removeComponent,watchComponent=lib_5.watchComponent,setQueryListener=lib_5.setQueryListener,setComponentProps=lib_5.setComponentProps,updateComponentProps=lib_5.updateComponentProps,pushToAndClause=lib_8.pushToAndClause,checkPropChange=lib_8.checkPropChange,checkSomePropChange=lib_8.checkSomePropChange,ComponentWrapper=function(e,t){return void 0===t&&(t={componentType:null,internalComponent:!1}),{name:"ComponentWrapper",$timestamp:null,props:{destroyOnUnmount:VueTypes.bool.def(!0)},created:function(){var e=_extends({},this.$attrs),t={};Object.keys(e).forEach((function(n){t[getCamelCase(n)]=e[n]})),this.componentProps=t,this.componentId=this.componentProps.componentId,this.react=this.componentProps.react,this.$timestamp=(new Date).getTime()},beforeMount:function(){var e=this,n=[];this.$$store&&(n=this.$$store.getState().components);if(this.destroyOnUnmount||-1===n.indexOf(this.componentProps.componentId)){this.addComponent(this.componentId,this.$timestamp);this.setQueryListener(this.componentId,(function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];e.$emit.apply(e,["queryChange"].concat(n)),e.$emit.apply(e,["query-change"].concat(n))}),(function(t){e.$emit("error",t)})),this.setComponentProps(this.componentId,this.componentProps,t.componentType)}(t.internalComponent||this.componentProps.defaultQuery&&t.componentType===constants_1$1.reactiveComponent)&&(this.internalComponent=transform_11(this.componentId)),this.internalComponent&&(this.destroyOnUnmount||-1===n.indexOf(this.internalComponent))&&(this.addComponent(this.internalComponent,this.$timestamp),this.setComponentProps(this.internalComponent,this.componentProps,t.componentType))},mounted:function(){this.internalComponent&&this.setReact(this.componentProps)},beforeDestroy:function(){if(this.destroyOnUnmount){var e={};if(this.$$store)e=this.$$store.getState().registeredComponentsTimestamps;e[this.componentId]===this.$timestamp&&(this.removeComponent(this.componentId),this.internalComponent&&this.removeComponent(this.internalComponent))}},watch:{$attrs:{deep:!0,handler:function(e){var n=this,r=getValidPropsKeys(e);checkSomePropChange(e,this.savedComponentProps,r,(function(){n.updateComponentProps(n.componentId,e,t.componentType),n.updateComponentProps(n.internalComponent,e,t.componentType)}))}},react:function(e,t){var n=this;checkPropChange(e,t,(function(){return n.setReact(n.componentProps)}))}},methods:{setReact:function(e){var t=e.react,n=e.executeInitialQuery;if(this.internalComponent)if(t){var r=pushToAndClause(t,this.internalComponent);this.watchComponent(e.componentId,r,n)}else this.watchComponent(e.componentId,{and:this.internalComponent},n);else this.watchComponent(e.componentId,t,n)}},render:function(t){return t(e,{attrs:this.$attrs,on:this.$listeners,scopedSlots:this.$scopedSlots,slots:this.$slots})}}},mapStateToProps=function(e,t){return{savedComponentProps:e.props[t.componentId]}},mapDispatchToProps={addComponent:addComponent,removeComponent:removeComponent,setQueryListener:setQueryListener,watchComponent:watchComponent,setComponentProps:setComponentProps,updateComponentProps:updateComponentProps},ComponentWrapper$1=function(e,t){return void 0===t&&(t={}),connect(mapStateToProps,mapDispatchToProps)(ComponentWrapper(e,t))},deepValue=function(e,t){return t.split(".").reduce((function(e,t){return e?e[t]:null}),e)},PreferencesConsumer=function PreferencesConsumer(component){return{name:"PreferencesConsumer",inject:{$searchPreferences:{default:null}},render:function render(h){var _this=this,userProps=Object.keys(this.$attrs).reduce((function(e,t){var n;return _extends({},e,((n={})[getCamelCase(t)]=_this.$attrs[t],n))}),{}),context=this.$searchPreferences;if(!userProps||!userProps.componentId)throw Error("ReactiveSearch: componentId is required");var componentId=userProps.componentId,preferencesPath=userProps.preferencesPath,preferences;context&&(preferences=deepValue(context,preferencesPath||["componentSettings",componentId].join(".")));var componentProps=userProps;return preferences&&(componentProps=preferences.rsConfig?_extends({},preferences.rsConfig,componentProps):_extends({},preferences,componentProps),void 0!==preferences.enabled&&!preferences.enabled)?null:(Object.keys(componentProps).forEach((function(p){"string"==typeof componentProps[p]&&["defaultQuery","customQuery","setOption"].includes(p)&&(componentProps[p]=eval(componentProps[p]))})),h(component,{attrs:componentProps,on:this.$listeners,scopedSlots:this.$scopedSlots,slots:this.$slots}))}}};function _extends$2(){return(_extends$2=Object.assign?Object.assign.bind():function(e){for(var t,n=1;n<arguments.length;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)}var normalMerge=["attrs","props","domProps"],toArrayMerge=["class","style","directives"],functionalMerge=["on","nativeOn"],mergeJsxProps=function(e){return e.reduce((function(e,t){for(var n in t)if(e[n])if(-1!==normalMerge.indexOf(n))e[n]=_extends$2({},e[n],t[n]);else if(-1!==toArrayMerge.indexOf(n)){var r=e[n]instanceof Array?e[n]:[e[n]],o=t[n]instanceof Array?t[n]:[t[n]];e[n]=[].concat(r,o)}else if(-1!==functionalMerge.indexOf(n))for(var s in t[n])if(e[n][s]){var a=e[n][s]instanceof Array?e[n][s]:[e[n][s]],i=t[n][s]instanceof Array?t[n][s]:[t[n][s]];e[n][s]=[].concat(a,i)}else e[n][s]=t[n][s];else if("hook"===n)for(var u in t[n])e[n][u]=e[n][u]?mergeFn(e[n][u],t[n][u]):t[n][u];else e[n]=t[n];else e[n]=t[n];return e}),{})},mergeFn=function(e,t){return function(){e&&e.apply(this,arguments),t&&t.apply(this,arguments)}},helper$1=mergeJsxProps,_templateObject$2,Title=index$1("h2")(_templateObject$2||(_templateObject$2=_taggedTemplateLiteralLoose(["\n\tmargin: 0 0 8px;\n\tfont-size: 1rem;\n\tcolor: ",";\n"])),(function(e){return e.theme.colors.titleColor})),_templateObject$3,_templateObject2$1,_templateObject3$1,_templateObject4$1,container=css(_templateObject$3||(_templateObject$3=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\tflex-direction: column;\n\tmargin: 0;\n\tborder-radius: 0.25rem;\n\toverflow: hidden;\n"]))),smallImage=css(_templateObject2$1||(_templateObject2$1=_taggedTemplateLiteralLoose(["\n\twidth: 100px;\n\theight: 100px;\n"]))),Image=index$1("div")(_templateObject3$1||(_templateObject3$1=_taggedTemplateLiteralLoose(["\n\twidth: 160px;\n\theight: 160px;\n\t",";\n\tmargin: 0;\n\tbackground-size: contain;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n\tbackground-image: ",";\n"])),(function(e){return e.small?smallImage:null}),(function(e){return"url("+e.src+")"})),ListItem=index$1("a")(_templateObject4$1||(_templateObject4$1=_taggedTemplateLiteralLoose(["\n\twidth: 100%;\n\theight: auto;\n\toutline: none;\n\ttext-decoration: none;\n\tborder-radius: 0;\n\tbackground-color: ",";\n\tdisplay: flex;\n\tflex-direction: row;\n\tmargin: 0;\n\tpadding: 10px;\n\tborder-bottom: 1px solid ",";\n\tcolor: ",";\n\t","; all 0.3s ease;\n\n\t&:hover, &:focus {\n\t\tbackground-color: ",";\n\t}\n\n\t&:last-child {\n\t\tborder: 0;\n\t}\n\n\th2 {\n\t\twidth: 100%;\n\t\tline-height: 1.2rem;\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t\tmargin: 0;\n\t\tpadding: 0 0 8px;\n\t}\n\n\tp {\n\t\tmargin: 0;\n\t}\n\n\tarticle {\n\t\twidth: ",";\n\t\tpadding-left: ",";\n\t\tfont-size: 0.9rem;\n\t}\n\n\t&:hover, &:focus {\n\t\tbox-shadow: 0 0 0 0 rgba(0,0,0,0.10);\n\t}\n\n\t@media (max-width: 420px) {\n\t\tmin-width: 0;\n\t\tmargin: 0;\n\t\tborder-radius: 0;\n\t\tbox-shadow: none;\n\t\tborder: 1px solid #eee;\n\n\t\t&:hover, &:focus {\n\t\t\tbox-shadow: 0;\n\t\t}\n\t}\n"])),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fff"}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.3,t.colors.backgroundColor):curriedLighten(.68,t.colors.textColor)}),(function(e){return e.theme.colors.textColor}),(function(e){return e.href?"cursor: pointer":null}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.2,t.colors.backgroundColor):"#fdfefd"}),(function(e){return e.image?e.small?"calc(100% - 100px)":"calc(100% - 160px)":"100%"}),(function(e){return e.image?"10px":0})),ResultListWrapper={name:"ResultListWrapper",functional:!0,render:function(e,t){var n=t.props,r=t.children,o=arguments[0];return o("div",helper$1([{attrs:{className:container}},n]),[r])}},_templateObject$4,_templateObject2$2,_templateObject3$2;ResultListWrapper.install=function(e){e.component(ResultListWrapper.name,ResultListWrapper)};var container$1=css(_templateObject$4||(_templateObject$4=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\tflex-direction: row;\n\tjustify-content: center;\n\tflex-wrap: wrap;\n\tmargin: 0 -8px;\n\n\t@media (max-width: 420px) {\n\t\tmargin: 0;\n\t}\n"]))),Image$1=index$1("div")(_templateObject2$2||(_templateObject2$2=_taggedTemplateLiteralLoose(["\n\twidth: calc(100% + 20px);\n\theight: 220px;\n\tmargin: -10px -10px 0;\n\tbackground-color: ",";\n\tbackground-size: contain;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n"])),(function(e){return e.theme.colors.backgroundColor||"#fcfcfc"})),Card=index$1("a")(_templateObject3$2||(_templateObject3$2=_taggedTemplateLiteralLoose(["\n\twidth: auto;\n\tflex-grow: 1;\n\toutline: none;\n\ttext-decoration: none;\n\tmin-width: 240px;\n\tmax-width: 250px;\n\tborder-radius: 0.25rem;\n\tbackground-color: ",";\n\theight: 300px;\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\tmargin: 8px;\n\tpadding: 10px;\n\toverflow: hidden;\n\tbox-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.2);\n\tcolor: ",";\n\t",";\n\ttransition: all 0.3s ease;\n\n\th2 {\n\t\twidth: 100%;\n\t\tfont-size: 0.9rem;\n\t\tline-height: 1.2rem;\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t\tmargin: 0;\n\t\tpadding: 10px 0 8px;\n\t}\n\n\tp {\n\t\tmargin: 0;\n\t}\n\n\tarticle {\n\t\tflex-grow: 1;\n\t\tfont-size: 0.9rem;\n\t}\n\n\t&:hover,\n\t&:focus {\n\t\tbox-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.3);\n\t}\n\n\t@media (max-width: 420px) {\n\t\twidth: 50%;\n\t\tmin-width: 0;\n\t\theight: 210px;\n\t\tmargin: 0;\n\t\tborder-radius: 0;\n\t\tbox-shadow: none;\n\t\tborder: 1px solid #eee;\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tbox-shadow: 0;\n\t\t}\n\t}\n"])),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fff"}),(function(e){return e.theme.colors.textColor}),(function(e){return e.href?"cursor: pointer":null})),ResultCardsWrapper={name:"ResultCardsWrapper",functional:!0,render:function(e,t){var n=t.props,r=t.children,o=arguments[0];return o("div",helper$1([{attrs:{className:container$1}},n]),[r])}},_templateObject$5,_templateObject2$3,_templateObject3$3,_templateObject4$2,_templateObject5$1,_templateObject6$1,_templateObject7$1,_templateObject8$1,_templateObject9,_templateObject10,_templateObject11;ResultCardsWrapper.install=function(e){e.component(ResultCardsWrapper.name,ResultCardsWrapper)};var leftLabel=css(_templateObject$5||(_templateObject$5=_taggedTemplateLiteralLoose(["\n\tflex-direction: row;\n\talign-items: center;\n"]))),rightLabel=css(_templateObject2$3||(_templateObject2$3=_taggedTemplateLiteralLoose(["\n\tflex-direction: row-reverse;\n\talign-items: center;\n"]))),topLabel=css(_templateObject3$3||(_templateObject3$3=_taggedTemplateLiteralLoose(["\n\tflex-direction: column;\n"]))),bottomLabel=css(_templateObject4$2||(_templateObject4$2=_taggedTemplateLiteralLoose(["\n\tflex-direction: column-reverse;\n"]))),border=function(e){var t=e.theme.colors;return css(_templateObject5$1||(_templateObject5$1=_taggedTemplateLiteralLoose(["\n\tborder: 1px solid ",";\n"])),t.borderColor||"#ccc")},Flex=index$1("div")(_templateObject6$1||(_templateObject6$1=_taggedTemplateLiteralLoose(["\n\tdisplay: ",";\n\t",";\n\t",";\n\t",";\n\t",";\n\t",";\n\n\t",";\n\t",";\n\n\t",";\n\t",";\n\t",";\n\n\tsvg.cancel-icon {\n\t\tcursor: pointer;\n\t\tfill: ",";\n\t\tflex-basis: 30px;\n\n\t\t&:hover {\n\t\t\tfill: ",";\n\t\t}\n\t}\n"])),(function(e){return e.inline?"inline-flex":"flex"}),(function(e){return("left"===e.labelPosition||"right"===e.iconPosition)&&leftLabel}),(function(e){return("right"===e.labelPosition||"left"===e.iconPosition)&&rightLabel}),(function(e){return"top"===e.labelPosition&&topLabel}),(function(e){return"bottom"===e.labelPosition&&bottomLabel}),(function(e){return e.showBorder&&border}),(function(e){return e.justifyContent&&css(_templateObject7$1||(_templateObject7$1=_taggedTemplateLiteralLoose(["\n\t\t\tjustify-content: ",";\n\t\t"])),e.justifyContent)}),(function(e){return e.alignItems&&css(_templateObject8$1||(_templateObject8$1=_taggedTemplateLiteralLoose(["\n\t\t\talign-items: ",";\n\t\t"])),e.alignItems)}),(function(e){return e.flex&&css(_templateObject9||(_templateObject9=_taggedTemplateLiteralLoose(["\n\t\t\tflex: ",";\n\t\t"])),e.flex)}),(function(e){return e.direction&&css(_templateObject10||(_templateObject10=_taggedTemplateLiteralLoose(["\n\t\t\tflex-direction: ",";\n\t\t"])),e.direction)}),(function(e){return e.basis&&css(_templateObject11||(_templateObject11=_taggedTemplateLiteralLoose(["\n\t\t\tflex-basis: ",";\n\t\t"])),e.basis)}),(function(e){var t=e.theme.colors;return t.borderColor||curriedLighten(.3,t.textColor)}),(function(e){return e.theme.colors.textColor})),_templateObject$6,_templateObject2$4,resultStats=css(_templateObject$6||(_templateObject$6=_taggedTemplateLiteralLoose(["\n\tflex-grow: 1;\n\tfont-size: 0.82rem;\n"]))),sortOptions=css(_templateObject2$4||(_templateObject2$4=_taggedTemplateLiteralLoose(["\n\tcolor: #424242;\n\theight: 32px;\n\tfont-size: 0.82rem;\n\tpadding: 0 25px 0 10px;\n\tbackground: url(data:image/svg+xml;base64,PHN2ZyBpZD0iTGF5ZXJfMSIgZGF0YS1uYW1lPSJMYXllciAxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0Ljk1IDEwIj48ZGVmcz48c3R5bGU+LmNscy0xe2ZpbGw6I2ZmZjt9LmNscy0ye2ZpbGw6IzQ0NDt9PC9zdHlsZT48L2RlZnM+PHRpdGxlPmFycm93czwvdGl0bGU+PHJlY3QgY2xhc3M9ImNscy0xIiB3aWR0aD0iNC45NSIgaGVpZ2h0PSIxMCIvPjxwb2x5Z29uIGNsYXNzPSJjbHMtMiIgcG9pbnRzPSIxLjQxIDQuNjcgMi40OCAzLjE4IDMuNTQgNC42NyAxLjQxIDQuNjciLz48cG9seWdvbiBjbGFzcz0iY2xzLTIiIHBvaW50cz0iMy41NCA1LjMzIDIuNDggNi44MiAxLjQxIDUuMzMgMy41NCA1LjMzIi8+PC9zdmc+)\n\t\tno-repeat 95% 50%;\n\tbackground-color: #fff;\n\t-moz-appearance: none;\n\t-webkit-appearance: none;\n\tappearance: none;\n\t-webkit-border-radius: 0;\n\tborder-radius: 0;\n\tborder: 0;\n\toutline: 1px solid #ddd;\n\toutline-offset: -1px;\n"]))),recordImpressions=lib_5.recordImpressions,isEqual$1=lib_8.isEqual,debounce=function(e,t){clearTimeout(e._tId),e._tId=setTimeout((function(){e()}),t)},ImpressionTracker={name:"ImpressionTracker",inject:["$$store"],props:{hits:types.hits},created:function(){this.currentHits=[],this.trackedIds={},this.waitingToBeTracked={}},mounted:function(){this.setCurrentHits(this.hits),window&&window.addEventListener("scroll",this.tracker)},destroy:function(){this.clearTrackerInterval()},watch:{hits:function(e,t){if(e&&e!==t){var n=t.map((function(e){return e._id})),r=e.map((function(e){return e._id}));isEqual$1(r,n)||this.setCurrentHits(e)}}},methods:{inViewPort:function(e){var t=e.getBoundingClientRect();return t.top>=0&&t.left>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},setCurrentHits:function(e){this.currentHits=e,this.trackedIds={},e&&e.length&&(this.tracker(),this.setTrackerInterval())},recordImpression:function(){var e=this;if(Object.keys(this.waitingToBeTracked).length){var t=_extends({},this.waitingToBeTracked);Object.keys(t).forEach((function(n){t[n]&&t[n].length&&(e.trackImpressions(n,t[n]),delete e.waitingToBeTracked[n])}))}},addToWaitingList:function(e){var t=this.getQueryId();if(e&&t){var n={id:e._id,index:e._index};this.waitingToBeTracked[t]?this.waitingToBeTracked[t].push(n):this.waitingToBeTracked[t]=[n]}},tracker:function(){var e=this;this.getHitIds().length?(window&&document&&this.getHitIds().forEach((function(t){var n=document.getElementById(t);if(n&&e.inViewPort(n)){var r=e.currentHits.find((function(e){return e._id===t}));e.trackedIds[t]=!0,e.addToWaitingList(r)}})),debounce(this.recordImpression,300)):this.clearTrackerInterval()},setTrackerInterval:function(){this.intervalID=setInterval(this.tracker,1e3)},clearTrackerInterval:function(){this.intervalID&&(clearInterval(this.intervalID),this.intervalID=null)},getQueryId:function(){var e=this.$$store?this.$$store.getState():null;return e?e.analytics.searchId:null},getHitIds:function(){var e=this;return this.currentHits.map((function(e){return e._id})).filter((function(t){return!e.trackedIds[t]}))}},render:function(){return this.$slots.default}},mapDispatchToProps$1={trackImpressions:recordImpressions},ImpressionTracker$1=connect((function(){return null}),mapDispatchToProps$1)(ImpressionTracker),setQueryOptions=lib_5.setQueryOptions,updateQuery=lib_5.updateQuery,loadMore=lib_5.loadMore,setValue=lib_5.setValue,updateComponentProps$1=lib_5.updateComponentProps,setDefaultQuery=lib_5.setDefaultQuery,recordResultClick=lib_5.recordResultClick,isEqual$2=lib_8.isEqual,getQueryOptions=lib_8.getQueryOptions,getClassName$1=lib_8.getClassName,parseHits=lib_8.parseHits,getCompositeAggsQuery=lib_8.getCompositeAggsQuery,getResultStats=lib_8.getResultStats,extractQueryFromCustomQuery=lib_8.extractQueryFromCustomQuery,getOptionsForCustomQuery=lib_8.getOptionsForCustomQuery,ReactiveList={name:"ReactiveList",components:{ResultListWrapper:ResultListWrapper,ResultCardsWrapper:ResultCardsWrapper},data:function(){var e=0,t=this.defaultPage||-1;return t>=0?e=t:this.currentPage&&(e=Math.max(this.currentPage-1,0)),this.__state={from:e*this.size,currentPageState:e},this.__state},created:function(){var e=this,t=this.$props,n=t.distinctField,r=t.distinctFieldConfig,o=t.index;this.pagination&&this.aggregationField&&console.warn("Pagination is not supported when aggregationField is present. The list will be rendered with infinite scroll"),this.enableAppbase&&this.aggregationField&&""!==this.aggregationField&&console.warn("Warning(ReactiveSearch): The `aggregationField` prop has been marked as deprecated, please use the `distinctField` prop instead."),this.enableAppbase||!n&&!r||console.warn("Warning(ReactiveSearch): In order to use the `distinctField` and `distinctFieldConfig` props, the `enableAppbase` prop must be set to true in `ReactiveBase`."),!this.enableAppbase&&o&&console.warn("Warning(ReactiveSearch): In order to use the `index` prop, the `enableAppbase` prop must be set to true in `ReactiveBase`.");var s=this.defaultPage||-1;s>=0&&(this.currentPageState=s,this.from=this.currentPageState*this.$props.size),this.internalComponent=this.$props.componentId+"__internal",this.sortOptionIndex=0,this.defaultSortOption&&this.sortOptions&&Array.isArray(this.sortOptions)&&(this.sortOptionIndex=this.sortOptions.findIndex((function(t){return t.label===e.defaultSortOption}))),this.urlSortOption&&(this.sortOptionIndex=this.$props.sortOptions.findIndex((function(t){return t.label===e.urlSortOption}))||0),this.updateComponentProps(this.componentId,{from:this.from},constants_1$1.reactiveList),this.updateComponentProps(this.internalComponent,{from:this.from},constants_1$1.reactiveList)},props:{currentPage:VueTypes.number.def(0),includeFields:types.includeFields,className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,aggregationField:types.string,aggregationSize:VueTypes.number,defaultQuery:types.func,defaultSortOption:types.string,excludeFields:types.excludeFields,innerClass:types.style,listClass:VueTypes.string.def(""),loader:types.title,render:types.func,renderItem:types.func,renderNoResults:VueTypes.any.def("No Results found."),renderError:types.title,renderResultStats:types.func,pages:VueTypes.number.def(5),pagination:VueTypes.bool.def(!1),infiniteScroll:VueTypes.bool.def(!0),paginationAt:VueTypes.oneOf(["top","bottom","both"]).def("bottom"),react:types.react,scrollOnChange:VueTypes.bool.def(!0),showResultStats:VueTypes.bool.def(!0),showEndPage:VueTypes.bool.def(!1),size:VueTypes.number.def(10),sortBy:types.sortBy,sortOptions:types.sortOptions,URLParams:VueTypes.bool.def(!1),prevLabel:types.string,nextLabel:types.string,distinctField:types.string,distinctFieldConfig:types.props,index:VueTypes.string,endpoint:types.endpointConfig},computed:{shouldRenderPagination:function(){return this.pagination&&!this.aggregationField},totalPages:function(){return Math.ceil(this.total/this.$props.size)||0},hasPageChangeListener:function(){return this.$listeners&&this.$listeners.pageChange},hasResultStatsListener:function(){return this.$listeners&&this.$listeners.resultStats},stats:function(){return _extends({},getResultStats(this),{currentPage:this.currentPageState,displayedResults:this.data.length})},hasCustomRender:function(){return hasCustomRenderer(this)},showInfiniteScroll:function(){return this.infiniteScroll&&!this.shouldRenderPagination},data:function(){var e=parseHits(this.hits)||[],t=parseHits(this.promotedResults)||[],n=e;if(t.length){var r=t.map((function(e){return e._id})).filter(Boolean);r&&(n=n.filter((function(e){return!r.includes(e._id)}))),n=[].concat(t,n)}return helper_15(n)}},watch:{sortOptions:function(e,t){isEqual$2(t,e)||this.updateQueryOptions(this.$props)},sortBy:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},size:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},dataField:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},includeFields:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},excludeFields:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},defaultQuery:function(e,t){if(!isQueryIdentical(e,t,null,this.$props)){var n=getQueryOptions(this.$props);n.from=0,this.$defaultQuery=e(null,this.$props);var r=extractQueryFromCustomQuery(this.$defaultQuery),o=getOptionsForCustomQuery(this.$defaultQuery);o&&(n=_extends({},n,o)),updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props),this.setQueryOptions(this.$props.componentId,_extends({},n,this.getAggsQuery()),!r),this.updateQuery({componentId:this.internalComponent,query:r},!0),this.currentPageState=0,this.from=0}},promotedResults:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},hidden:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},time:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},hits:function(e,t){this.$emit("data",this.getData()),this.shouldRenderPagination?this.isLoading&&(t||e)&&(this.hasPageChangeListener?(this.$emit("pageChange",this.currentPageState+1,this.totalPages),this.$emit("page-change",this.currentPageState+1,this.totalPages)):this.scrollOnChange&&window.scrollTo(0,0)):t&&e&&(t.length===e.length&&e.length!==this.$props.total||e.length<t.length&&(this.scrollOnChange&&window.scrollTo(0,0),this.from=0))},rawData:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},currentPage:function(e,t){t!==e&&e>0&&e<=this.totalPages&&this.setPage(e-1)},infiniteScroll:function(e,t){e!==t&&(e&&!this.pagination?window.addEventListener("scroll",this.scrollHandler):window.removeEventListener("scroll",this.scrollHandler))},pagination:function(e,t){e!==t&&(!e&&this.infiniteScroll?window.addEventListener("scroll",this.scrollHandler):window.removeEventListener("scroll",this.scrollHandler))},defaultPage:function(e,t){this.currentPageState!==e&&t!==e&&this.setPage(e>=0?e:0)}},mounted:function(){this.defaultPage<0&&this.currentPage>0&&this.setPageURL(this.$props.componentId,this.currentPage,this.$props.componentId,!1,this.URLParams);var e=getQueryOptions(this.$props);if(e.from=this.$data.from,this.sortOptions&&this.sortOptions[this.sortOptionIndex]){var t,n=this.sortOptions[this.sortOptionIndex].dataField,r=this.sortOptions[this.sortOptionIndex].sortBy;e.sort=[(t={},t[n]={order:r},t)],this.updateComponentProps(this.componentId,{dataField:n,sortBy:r},constants_1$1.reactiveList)}else if(this.$props.sortBy){var o;e.sort=[(o={},o[this.$props.dataField]={order:this.$props.sortBy},o)]}this.$defaultQuery=null,this.$props.defaultQuery&&(this.$defaultQuery=this.$props.defaultQuery(),e=_extends({},e,getOptionsForCustomQuery(this.$defaultQuery)),updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props));var s=extractQueryFromCustomQuery(this.$defaultQuery);this.setQueryOptions(this.$props.componentId,_extends({},e,this.getAggsQuery()),!1),this.$defaultQuery?this.updateQuery({componentId:this.internalComponent,query:s},!1):this.updateQuery({componentId:this.internalComponent,query:null},!1),this.showInfiniteScroll&&window.addEventListener("scroll",this.scrollHandler)},beforeDestroy:function(){this.showInfiniteScroll&&window.removeEventListener("scroll",this.scrollHandler)},render:function(){var e=arguments[0],t=this.$data.hits,n=parseHits(t)||[];return e("div",{style:this.$props.style,class:this.$props.className},[this.isLoading&&this.shouldRenderPagination&&this.showInfiniteScroll&&(this.$scopedSlots.loader||this.$props.loader),this.renderErrorComponent(),e(Flex,{attrs:{labelPosition:this.sortOptions?"right":"left"},class:getClassName$1(this.$props.innerClass,"resultsInfo")},[this.sortOptions?this.renderSortOptions():null,this.$props.showResultStats&&n.length?this.renderStats():null]),!this.isLoading&&t&&0===t.length?this.renderNoResult():null,!this.shouldRenderPagination||"top"!==this.$props.paginationAt&&"both"!==this.$props.paginationAt?null:e(Pagination,{attrs:{pages:this.$props.pages,totalPages:this.totalPages,currentPage:this.currentPageState,setPage:this.setPage,innerClass:this.$props.innerClass,prevLabel:this.$props.prevLabel,nextLabel:this.$props.nextLabel}}),this.renderResults(),this.isLoading&&!this.shouldRenderPagination?this.$scopedSlots.loader||this.$props.loader||e("div",{style:{textAlign:"center",margin:"20px 0",color:"#666"}},["Loading..."]):null,!this.shouldRenderPagination||"bottom"!==this.$props.paginationAt&&"both"!==this.$props.paginationAt?null:e(Pagination,{attrs:{pages:this.$props.pages,totalPages:Math.ceil(this.$data.total/this.$props.size),currentPage:this.currentPageState,setPage:this.setPage,showEndPage:this.$props.showEndPage,innerClass:this.$props.innerClass,prevLabel:this.$props.prevLabel,nextLabel:this.$props.nextLabel}}),this.url.endsWith("appbase.io")&&n.length?e(Flex,{attrs:{direction:"row-reverse"},class:getClassName$1(this.$props.innerClass,"poweredBy")},[e(PoweredBy)]):null])},methods:{renderErrorComponent:function(){var e=this.$scopedSlots.renderError||this.$props.renderError;return e&&this.error&&!this.isLoading?isFunction$1(e)?e(this.error):e:null},renderResults:function(){var e=this,t=this.$createElement,n=this.$props.size,r=this.$scopedSlots.renderItem||this.$props.renderItem,o=this.hasCustomRender?this.getComponent():t("div",{class:this.$props.listClass+" "+getClassName$1(this.$props.innerClass,"list")},[this.data.map((function(t,o){return r({item:t,count:e.currentPageState*n+o+1,triggerClickAnalytics:function(){return e.triggerClickAnalytics(e.currentPageState*n+o)}})}))]);return this.analytics?t(ImpressionTracker$1,{attrs:{hits:this.data}},[o]):o},updateQueryOptions:function(e){var t=getQueryOptions(e);if(t.from=this.$data.from,e.sortOptions&&Array.isArray(e.sortOptions)){var n,r=e.defaultSortOption?e.sortOptions.findIndex((function(t){return t.label===e.defaultSortOption})):0;if(e.sortOptions[r])t.sort=[(n={},n[e.sortOptions[r].dataField]={order:e.sortOptions[r].sortBy},n)]}else if(e.sortBy){var o;t.sort=[(o={},o[e.dataField]={order:e.sortBy},o)]}this.setQueryOptions(this.$props.componentId,_extends({},t,this.getAggsQuery()),!0)},getAggsQuery:function(){var e=this.$props,t=e.size,n=e.aggregationField,r=this.$data.afterKey,o={size:t};return n&&(o.aggs=getCompositeAggsQuery({props:this.$props,after:r||null,showTopHits:!0}).aggs),o},scrollHandler:function(){!this.isLoading&&window.innerHeight+window.pageYOffset+300>=document.body.scrollHeight&&this.loadMore()},loadMore:function(){if((!this.aggregationField||this.afterKey)&&this.hits&&!this.shouldRenderPagination&&this.total>this.hits.length){var e=this.$data.from+this.$props.size;if(this.hits.length<e)return;var t=_extends({},getQueryOptions(this.$props),this.getAggsQuery());this.from=e,updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props),this.loadMoreAction(this.$props.componentId,_extends({},t,{from:e}),!0,!!this.aggregationField)}},setPage:function(e){if(e!==this.currentPageState){this.$emit("pageClick",e+1),this.$emit("page-click",e+1);var t=this.$props.size*e,n=getQueryOptions(this.$props);n.from=this.$data.from,this.from=t,this.currentPageState=e,this.loadMoreAction(this.$props.componentId,_extends({},n,{from:t}),!1),this.setPageURL(this.$props.componentId,e+1,this.$props.componentId,!1,this.URLParams)}},renderStats:function(){var e=this.$createElement,t=this.$scopedSlots.renderResultStats||this.$props.renderResultStats;return t&&this.$data.total?t(this.stats):this.stats.numberOfResults?e("p",{class:resultStats+" "+getClassName$1(this.$props.innerClass,"resultStats")},[this.stats.numberOfResults," results found in ",this.stats.time||0,"ms"]):null},renderNoResult:function(){var e=this.$createElement,t=this.$scopedSlots.renderNoResults||this.$props.renderNoResults;return this.$scopedSlots.renderNoResults?isFunction$1(t)?t():t:e("p",{class:getClassName$1(this.$props.innerClass,"noResults")||null},[isFunction$1(t)?t():t])},handleSortChange:function(e){var t=e.target.value;if(this.sortOptions&&this.sortOptions[t]){var n,r=getQueryOptions(this.$props);r.from=0;var o=this.sortOptions[t].dataField,s=this.sortOptions[t].sortBy;r.sort=[(n={},n[o]={order:s},n)],this.sortOptionIndex=t,this.updateComponentProps(this.componentId,{dataField:o,sortBy:s},constants_1$1.reactiveList),this.setQueryOptions(this.$props.componentId,r,!0),this.setPage(0),this.currentPageState=0,this.from=0;var a=this.$props.sortOptions[this.sortOptionIndex]?this.$props.sortOptions[this.sortOptionIndex].label:null;this.setPageURL(this.$props.componentId+"sortOption",a,this.$props.componentId+"sortOption",!1,this.$props.URLParams)}},triggerClickAnalytics:function(e,t){var n=t;if(!n){var r=this.getData().data.find((function(t){return t._click_id===e}));r&&r._id&&(n=r._id)}this.recordResultClick(e,n)},renderSortOptions:function(){var e=this.$createElement;return e("select",{class:sortOptions+" "+getClassName$1(this.$props.innerClass,"sortOptions"),attrs:{name:"sort-options","aria-label":"Sort options"},on:{change:this.handleSortChange},domProps:{value:this.sortOptionIndex}},[this.sortOptions.map((function(t,n){return e("option",{key:t.label,domProps:{value:n}},[t.label])}))])},withClickIds:function(e){var t=this.getAllData().base;return e.map((function(e,n){return _extends({},e,{_click_id:t+n})}))},getAllData:function(){var e=this.size,t=this.promotedResults,n=this.aggregationData,r=this.customData,o=this.currentPage,s=this.hits,a=o*e;return{results:parseHits(s)||[],customData:r||{},promotedResults:parseHits(t)||[],aggregationData:n,loadMore:this.loadMore,base:a,triggerClickAnalytics:this.triggerClickAnalytics}},getData:function(){var e=this.getAllData(),t=e.promotedResults,n=e.aggregationData,r=e.customData;return{data:this.data,aggregationData:this.withClickIds(n||[]),promotedData:this.withClickIds(t||[]),rawData:this.rawData,resultStats:this.stats,customData:r}},getComponent:function(){var e=_extends({error:this.error,loading:this.isLoading||!1,loadMore:this.loadMore,triggerClickAnalytics:this.triggerClickAnalytics,setPage:this.setPage},this.getData());return getComponent(e,this)}}},mapStateToProps$1=function(e,t){return{defaultPage:e.selectedValues[t.componentId]&&e.selectedValues[t.componentId].value-1,urlSortOption:e.selectedValues[t.componentId+"sortOption"]&&e.selectedValues[t.componentId+"sortOption"].value,hits:e.hits[t.componentId]&&e.hits[t.componentId].hits,rawData:e.rawData[t.componentId],aggregationData:e.compositeAggregations[t.componentId],promotedResults:e.promotedResults[t.componentId],customData:e.customData[t.componentId],time:e.hits[t.componentId]&&e.hits[t.componentId].time,total:e.hits[t.componentId]&&e.hits[t.componentId].total,hidden:e.hits[t.componentId]&&e.hits[t.componentId].hidden,analytics:e.config&&e.config.analytics,enableAppbase:e.config.enableAppbase,url:e.config.url,error:e.error[t.componentId],afterKey:e.aggregations[t.componentId]&&e.aggregations[t.componentId][t.aggregationField]&&e.aggregations[t.componentId][t.aggregationField].after_key,componentProps:e.props[t.componentId],isLoading:e.isLoading[t.componentId]}},mapDispatchtoProps={loadMoreAction:loadMore,setPageURL:setValue,setQueryOptions:setQueryOptions,updateQuery:updateQuery,updateComponentProps:updateComponentProps$1,setDefaultQuery:setDefaultQuery,recordResultClick:recordResultClick};ReactiveList.generateQueryOptions=function(e){var t=getQueryOptions(e),n=e.size,r=e.dataField,o=e.defaultSortOption,s=e.sortOptions,a=e.currentPage,i=e.sortBy;t.from=a?(a-1)*(n||10):0,t.size=n||10;if(s)t.sort=[function(){var e;if(o){var t,n=s.find((function(e){return e.label===o}));if(n)return(t={})[n.dataField]={order:n.sortBy},t}return(e={})[s[0].dataField]={order:s[0].sortBy},e}()];else if(i){var u;t.sort=[(u={},u[r]={order:i},u)]}return t},ReactiveList.hasInternalComponent=function(){return!0};var RLConnected=PreferencesConsumer(ComponentWrapper$1(connect(mapStateToProps$1,mapDispatchtoProps)(ReactiveList),{componentType:constants_1$1.reactiveList,internalComponent:ReactiveList.hasInternalComponent()}));function URL$1(e){var t=RegExp("^(([^:/?#]*)?://)?(((.*)?@)?([^/?#]*)?)([^?#]*)(\\?([^#]*))?(#(.*))?"),n=e.match(t);return{protocol:n[2],auth:n[5],host:n[6],path:n[7],query:n[9],hash:n[11]}}RLConnected.name=ReactiveList.name,RLConnected.generateQueryOptions=ReactiveList.generateQueryOptions,RLConnected.hasInternalComponent=ReactiveList.hasInternalComponent,RLConnected.install=function(e){e.component(RLConnected.name,RLConnected),e.component(ResultListWrapper.name,ResultListWrapper),e.component(ResultCardsWrapper.name,ResultCardsWrapper)},RLConnected.componentType=constants_1$1.reactiveList;var urlParserLite=URL$1;function hasOwnProperty(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var decode=function(e,t,n,r){t=t||"&",n=n||"=";var o={};if("string"!=typeof e||0===e.length)return o;var s=/\+/g;e=e.split(t);var a=1e3;r&&"number"==typeof r.maxKeys&&(a=r.maxKeys);var i=e.length;a>0&&i>a&&(i=a);for(var u=0;u<i;++u){var l,c,p,d,h=e[u].replace(s,"%20"),f=h.indexOf(n);f>=0?(l=h.substr(0,f),c=h.substr(f+1)):(l=h,c=""),p=decodeURIComponent(l),d=decodeURIComponent(c),hasOwnProperty(o,p)?Array.isArray(o[p])?o[p].push(d):o[p]=[o[p],d]:o[p]=d}return o},stringifyPrimitive=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}},encode=function(e,t,n,r){return t=t||"&",n=n||"=",null===e&&(e=void 0),"object"==typeof e?Object.keys(e).map((function(r){var o=encodeURIComponent(stringifyPrimitive(r))+n;return Array.isArray(e[r])?e[r].map((function(e){return o+encodeURIComponent(stringifyPrimitive(e))})).join(t):o+encodeURIComponent(stringifyPrimitive(e[r]))})).filter(Boolean).join(t):r?encodeURIComponent(stringifyPrimitive(r))+n+encodeURIComponent(stringifyPrimitive(e)):""},querystring=createCommonjsModule((function(e,t){t.decode=t.parse=decode,t.encode=t.stringify=encode})),querystring_1=querystring.decode,querystring_2=querystring.parse,querystring_3=querystring.encode,querystring_4=querystring.stringify,_typeof$1="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function contains(e,t){return-1!==e.indexOf(t)}function isAppbase(e){return contains(e,"scalr.api.appbase.io")}function btoa$1(){for(var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r=t,o="",s=0,a=0,i=n;r.charAt(0|a)||(i="=",a%1);o+=i.charAt(63&s>>8-a%1*8)){if((e=r.charCodeAt(a+=3/4))>255)throw new Error('"btoa" failed: The string to be encoded contains characters outside of the Latin1 range.');s=s<<8|e}return o}function validateRSQuery(e){if(e&&"[object Array]"===Object.prototype.toString.call(e)){for(var t=0;t<e.length;t+=1){var n=e[t];if(!n)return new Error("query object can not have an empty value");if(!n.id)return new Error("'id' field must be present in query object")}return!0}return new Error("invalid query value, 'query' value must be an array")}function validate(e,t){var n=[],r={object:null,string:"",number:0};Object.keys(t).forEach((function(o){var s=t[o].split("|").find((function(t){return _typeof$1(e[o])===t}));s&&e[o]!==r[s]||n.push(o)}));for(var o="",s=0;s<n.length;s+=1)o+=n[s]+", ";return!(n.length>0)||new Error("fields missing: "+o)}function removeUndefined(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e||0!==Object.keys(e).length||e.constructor!==Object?JSON.parse(JSON.stringify(e)):null}function encodeHeaders(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n={};return t?Object.keys(e).forEach((function(t){n[t]=encodeURI(e[t])})):n=e,n}function getMongoRequest(e,t){var n={};return e&&(n.index=e),t&&(t.db&&(n.db=t.db),t.collection&&(n.collection=t.collection)),n}function getTelemetryHeaders(e,t){var n={};return t?(Object.assign(n,{"X-Search-Client":"Appbase JS"}),!1===e&&Object.assign(n,{"X-Enable-Telemetry":e}),n):n}var backendAlias={MONGODB:"mongodb",ELASTICSEARCH:"elasticsearch"},dataTypes={ARRAY:"array",FUNCTION:"function",OBJECT:"object",NUMBER:"number",BOOLEAN:"boolean",STRING:"string"},checkDataType=function(e){return(void 0===e?"undefined":_typeof$1(e))===dataTypes.OBJECT?Array.isArray(e)?dataTypes.ARRAY:dataTypes.OBJECT:void 0===e?"undefined":_typeof$1(e)};function validateSchema(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=Object.keys(e).filter((function(t){return!!e[t]})),o=Object.keys(t),s=[];o.forEach((function(e){t[e].required&&s.push(e)})),s.forEach((function(e){if(!r.includes(e))throw new Error(e+" is required when using the "+n+" Search backend.")})),r.forEach((function(r){if(!o.includes(r))throw new Error(r+" property isn't accepted property by "+n+" backend.");var s=Array.isArray(t[r].type)?t[r].type:[].concat(t[r].type),a=checkDataType(e[r]);if(!s.includes(a))throw new Error("The property "+r+" is expected with type(s) ["+s.join(", ")+"], but type was set as "+a+".")}))}function isValidHttpUrl(e){var t=void 0;try{t=new URL(e)}catch(e){return!1}return"http:"===t.protocol||"https:"===t.protocol}var mongodb={url:{type:dataTypes.STRING,required:!0},app:{type:dataTypes.STRING,required:!1},credentials:{type:dataTypes.STRING,required:!1},enableTelemetry:{type:dataTypes.BOOLEAN,required:!1},mongodb:{type:dataTypes.OBJECT,required:!0},username:{type:dataTypes.STRING,required:!1},password:{type:dataTypes.STRING,required:!1}},elasticsearch={url:{type:dataTypes.STRING,required:!0},app:{type:dataTypes.STRING,required:!0},credentials:{type:dataTypes.STRING,required:!1},enableTelemetry:{type:dataTypes.BOOLEAN,required:!1},username:{type:dataTypes.STRING,required:!1},password:{type:dataTypes.STRING,required:!1}},SCHEMA={mongodb:mongodb,elasticsearch:elasticsearch};function AppBase(e){var t=urlParserLite((e.endpoint?e.endpoint.url:e.url)||""),n=t.auth,r=void 0===n?null:n,o=t.host,s=void 0===o?"":o,a=t.path,i=void 0===a?"":a,u=t.protocol,l=void 0===u?"":u,c=e.url;"/"===(c=s+i).slice(-1)&&(c=c.slice(0,-1));var p=backendAlias[e.mongodb?"MONGODB":"ELASTICSEARCH"],d=SCHEMA[p];if(e.endpoint&&isValidHttpUrl(e.endpoint.url)&&(d.url.required=!1,d.app.required=!1,d.credentials.required=!1),validateSchema({url:e.url,app:e.app,credentials:e.credentials,username:e.username,password:e.password,enableTelemetry:e.enableTelemetry,mongodb:e.mongodb},d,p),"string"!=typeof l||""===l)throw new Error("Protocol is not present in url. URL should be of the form https://appbase-demo-ansible-abxiydt-arc.searchbase.io");var h=r||null;if("string"==typeof e.credentials&&""!==e.credentials?h=e.credentials:"string"==typeof e.username&&""!==e.username&&"string"==typeof e.password&&""!==e.password&&(h=e.username+":"+e.password),!e.mongodb&&isAppbase(c)&&null===h)throw new Error("Authentication information is not present. Did you add credentials?");this.url=c,this.protocol=l,this.app=e.app,this.credentials=h,e.mongodb&&(this.mongodb=e.mongodb),"boolean"==typeof e.enableTelemetry&&(this.enableTelemetry=e.enableTelemetry)}function fetchRequest(e){var t=this;return new Promise((function(n,r){var o=removeUndefined(e);try{var s=o.method,a=o.path,i=o.params,u=o.body,l=o.isRSAPI,c=o.isSuggestionsAPI,p=o.isMongoRequest,d=void 0!==p&&p,h=c?".suggestions":t.app,f=u,m=a.endsWith("msearch")||a.endsWith("bulk")?"application/x-ndjson":"application/json",g=Object.assign({},{Accept:"application/json","Content-Type":m},e.headers,t.headers),y=Date.now();t.credentials&&(g.Authorization="Basic "+btoa$1(t.credentials));var v={method:s,headers:g};if(Array.isArray(f)){var _="";f.forEach((function(e){_+=JSON.stringify(e),_+="\n"})),f=_}else f=JSON.stringify(f)||{};0!==Object.keys(f).length&&(v.body=f);var b={},$="";i&&($="?"+querystring.stringify(i));var C=d?t.protocol+"://"+t.url:t.protocol+"://"+t.url+"/"+h+"/"+a+$;return function(e){if(t.transformRequest&&"function"==typeof t.transformRequest){var n=t.transformRequest(e);return n instanceof Promise?n:Promise.resolve(n)}return Promise.resolve(e)}(Object.assign({},{url:C},v)).then((function(e){var t=Object.assign({},e),o=t.url;return delete t.url,fetch$1(o||C,Object.assign({},t,{headers:l&&!d?Object.assign({},t.headers,{"x-timestamp":(new Date).getTime()}):t.headers})).then((function(e){return e.status>=500?r(e):(b=e.headers,e.json().then((function(t){if(e.status>=400)return r(e);if(t&&t.error)return r(t);if(l&&t&&"[object Object]"===Object.prototype.toString.call(t)&&u&&u.query&&u.query instanceof Array){var o=0,s=u.query.filter((function(e){return e.execute||void 0===e.execute})).length;if(t&&Object.keys(t).forEach((function(e){t[e]&&Object.prototype.hasOwnProperty.call(t[e],"error")&&t[e].error&&(o+=1)})),o>0&&s===o)return r(t)}if(t&&t.responses instanceof Array&&t.responses.length===t.responses.filter((function(e){return Object.prototype.hasOwnProperty.call(e,"error")})).length)return r(t);var a=Object.assign({},t,{_timestamp:y,_headers:b});return n(a)})).catch((function(e){return r(e)})))})).catch((function(e){return r(e)}))})).catch((function(e){return r(e)}))}catch(e){return r(e)}}))}function indexApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id,a=t.body;delete t.type,delete t.body,delete t.id;var i=void 0;return i=s?o?o+"/"+encodeURIComponent(s):encodeURIComponent(s):o,this.performFetchRequest({method:"POST",path:i,params:t,body:a})}function getApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id;delete t.type,delete t.id;var a=o+"/"+encodeURIComponent(s);return this.performFetchRequest({method:"GET",path:a,params:t})}function updateApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number",body:"object"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id,a=t.body;delete t.type,delete t.id,delete t.body;var i=o+"/"+encodeURIComponent(s)+"/_update";return this.performFetchRequest({method:"POST",path:i,params:t,body:a})}function deleteApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id;delete t.type,delete t.id;var a=o+"/"+encodeURIComponent(s);return this.performFetchRequest({method:"DELETE",path:a,params:t})}function bulkApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=t.type,o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_bulk":"_bulk",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function searchApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=void 0;r=Array.isArray(t.type)?t.type.join():t.type;var o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_search":"_search",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function msearchApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=void 0;r=Array.isArray(t.type)?t.type.join():t.type;var o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_msearch":"_msearch",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function reactiveSearchApi(e,t,n){var r=removeUndefined(t),o=validateRSQuery(e);if(!0!==o)throw o;var s={settings:r,query:e};return this.mongodb&&Object.assign(s,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch",body:s,headers:getTelemetryHeaders(this.enableTelemetry,!this.mongodb),isRSAPI:!0,isMongoRequest:!!this.mongodb,params:n})}function reactiveSearchv3Api(e,t,n){var r=removeUndefined(t),o=validateRSQuery(e);if(!0!==o)throw o;var s={settings:r,query:e};return this.mongodb&&Object.assign(s,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch.v3",body:s,headers:getTelemetryHeaders(this.enableTelemetry,!this.mongodb),isRSAPI:!0,isMongoRequest:!!this.mongodb,params:n})}function getMappings(){return this.performFetchRequest({method:"GET",path:"_mapping"})}function getSuggestionsv3Api(e,t){var n=removeUndefined(t),r=validateRSQuery(e);if(!0!==r)throw r;var o={settings:n,query:e};return this.mongodb&&Object.assign(o,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch.v3",body:o,headers:getTelemetryHeaders(this.enableTelemetry),isRSAPI:!0,isSuggestionsAPI:!0,isMongoRequest:!!this.mongodb})}function appbasejs(e){var t=new AppBase(e);return AppBase.prototype.performFetchRequest=fetchRequest,AppBase.prototype.index=indexApi,AppBase.prototype.get=getApi,AppBase.prototype.update=updateApi,AppBase.prototype.delete=deleteApi,AppBase.prototype.bulk=bulkApi,AppBase.prototype.search=searchApi,AppBase.prototype.msearch=msearchApi,AppBase.prototype.reactiveSearch=reactiveSearchApi,AppBase.prototype.reactiveSearchv3=reactiveSearchv3Api,AppBase.prototype.getQuerySuggestions=getSuggestionsv3Api,AppBase.prototype.getMappings=getMappings,AppBase.prototype.setHeaders=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.headers=t?encodeHeaders(e):e},"undefined"!=typeof window&&(window.Appbase=t),t}function _extends$3(){return(_extends$3=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function btoa$2(e){void 0===e&&(e="");for(var t,n=e,r="",o=0,s=0,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.charAt(0|s)||(a="=",s%1);r+=a.charAt(63&o>>8-s%1*8)){if((t=n.charCodeAt(s+=3/4))>255)throw new Error('"btoa" failed: The string to be encoded contains characters outside of the Latin1 range.');o=o<<8|t}return r}function validateIndex(e){if(!e)throw new Error("appbase-analytics: A valid index must be present to record analytics events.")}function validateCredentials(e){if(!e)throw new Error("appbase-analytics: Auth credentials is missing.")}function validateURL(e){if(!e)throw new Error("appbase-analytics: URL is missing.")}function validateQuery(e,t){if(null==e&&!t)throw new Error("appbase-analytics: query or queryID must be present to register a click/conversion event")}function validateQueryID(e){if(!e)throw new Error("appbase-analytics: queryID must be present to save search/favorite")}function validateClickObjects(e){if(!e||Object.keys(e).length<1)throw new Error("appbase-analytics: at least one click object must be present to register a click event")}function validateConversionObjects(e){if(!e||Object.keys(e).length<1)throw new Error("appbase-analytics: at least one click object must be present to register a click event")}function initClient(e){void 0===e&&(e={});var t={credentials:e.credentials,index:e.index,url:e.url,userID:e.userID,globalCustomEvents:e.globalCustomEvents,queryID:"",headers:null,_request:function(e,n,r,o,s){var a=_extends$3({user_id:t.userID},r,{custom_events:_extends$3({},r&&r.custom_events,{},t.globalCustomEvents)}),i="";return o&&(i=Object.keys(o).map((function(e){return e+"="+o[e]})).join("&")),fetch$1(t.url+"/"+n+"?"+i,{method:e,headers:_extends$3({},t.headers,{"Content-Type":"application/json",Authorization:"Basic "+btoa$2(t.credentials)}),body:"GET"===e?null:JSON.stringify(a)}).then((function(e){s&&s(null,e)})).catch((function(e){s&&s(e,null)}))}};return validateIndex(t.index),validateCredentials(t.credentials),validateURL(t.url),t.search=function(e,n){validateQuery(e.query,e.queryID);if(t._request){var r={query:e.query,query_id:e.queryID,custom_events:e.customEvents,filters:e.filters,hits:e.hits,impressions:e.impressions};t._request("PUT",t.index+"/_analytics/search",r,null,(function(e,r){r?r.json().then((function(o){o&&o.query_id&&(t.queryID=o.query_id),n&&n(e,r)})).catch((function(e){n&&n(e,r)})):n&&n(e,r)}))}},t.click=function(e,n){if(validateQuery(e.query,e.queryID),validateClickObjects(e.objects),t._request){var r={click_on:e.objects,click_type:e.isSuggestionClick?"suggestion":"result",query:e.query,query_id:e.queryID,custom_events:e.customEvents,meta:e.meta};t._request("PUT",t.index+"/_analytics/click",r,null,n)}},t.conversion=function(e,n){if(validateQuery(null,e.queryID),validateConversionObjects(e.objects),t._request){var r={conversion_on:e.objects,query_id:e.queryID,meta:e.meta};t._request("PUT",t.index+"/_analytics/conversion",r,null,n)}},t.saveSearch=function(e,n){validateQueryID(e.queryID);var r={query_id:e.queryID,save_search_id:e.saveSearchID,save_search_meta:e.saveSearchMeta,user_id:e.userID,custom_events:e.customEvents};t._request("PUT","_analytics/save-search",r,null,n)},t.deleteSavedSearch=function(e,n){t._request("DELETE","_analytics/save-search/"+e,null,null,n)},t.getSavedSearches=function(e,n){t._request&&t._request("GET","_analytics/saved-searches",null,e,n)},t.favorite=function(e,n){if(validateQueryID(e.queryID),!e.favoriteOn||""===e.favoriteOn)throw new Error("appbase-analytics: favoriteOn property is required");if(!e.source)throw new Error("appbase-analytics: source property is required");var r={query_id:e.queryID,favorite_on:e.favoriteOn,source:e.source,id:e.id,meta:e.meta,user_id:e.userID,custom_events:e.customEvents};t._request("PUT","_analytics/favorite",r,null,n)},t.getFavorites=function(e,n){t._request&&t._request("GET","_analytics/favorites",null,e,n)},t.setUserID=function(e){t.userID=e},t.setGlobalCustomEvents=function(e){t.globalCustomEvents=e},t.setHeaders=function(e){t.headers=e},t.getQueryID=function(){return t.queryID},t}var index$2={init:initClient};
13
+ */function isObjectObject(e){return!0===isObject(e)&&"[object Object]"===Object.prototype.toString.call(e)}function isPlainObject$1(e){var t,n;return!1!==isObjectObject(e)&&("function"==typeof(t=e.constructor)&&(!1!==isObjectObject(n=t.prototype)&&!1!==n.hasOwnProperty("isPrototypeOf")))}var ObjProto=Object.prototype,toString=ObjProto.toString,hasOwn=ObjProto.hasOwnProperty,FN_MATCH_REGEXP=/^\s*function (\w+)/;function getType(e){var t=null!=e?e.type?e.type:e:null,n=t&&t.toString().match(FN_MATCH_REGEXP);return n&&n[1]}function getNativeType(e){if(null==e)return null;var t=e.constructor.toString().match(FN_MATCH_REGEXP);return t&&t[1]}function noop(){}var stubTrue=function(){return!0},has=function(e,t){return hasOwn.call(e,t)},isInteger=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},isArray=Array.isArray||function(e){return"[object Array]"===toString.call(e)},isFunction=function(e){return"[object Function]"===toString.call(e)};function withDefault(e){return Object.defineProperty(e,"def",{value:function(e){return void 0!==e||this.default?isFunction(e)||validateType(this,e)?(isArray(e)?this.default=function(){return[].concat(e)}:isPlainObject$1(e)?this.default=function(){return Object.assign({},e)}:this.default=e,this):(warn(this._vueTypes_name+' - invalid default value: "'+e+'"',e),this):this},enumerable:!1,writable:!1})}function withRequired(e){return Object.defineProperty(e,"isRequired",{get:function(){return this.required=!0,this},enumerable:!1})}function withValidate(e){return Object.defineProperty(e,"validate",{value:function(e){return this.validator=e.bind(this),this},enumerable:!1})}function toType(e,t,n){return void 0===n&&(n=!1),Object.defineProperty(t,"_vueTypes_name",{enumerable:!1,writable:!1,value:e}),withDefault(withRequired(t)),n?withValidate(t):Object.defineProperty(t,"validate",{value:function(){return warn(e+' - "validate" method not supported on this type'),this},enumerable:!1}),isFunction(t.validator)&&(t.validator=t.validator.bind(t)),t}function validateType(e,t,n){void 0===n&&(n=!1);var r,o=e,s=!0;isPlainObject$1(e)||(o={type:e});var a,i=o._vueTypes_name?o._vueTypes_name+" - ":"";if(hasOwn.call(o,"type")&&null!==o.type){if(void 0===o.type)throw new TypeError("[VueTypes error]: Setting type to undefined is not allowed.");if(!o.required&&void 0===t)return s;isArray(o.type)?(s=o.type.some((function(e){return validateType(e,t,!0)})),r=o.type.map((function(e){return getType(e)})).join(" or ")):s="Array"===(r=getType(o))?isArray(t):"Object"===r?isPlainObject$1(t):"String"===r||"Number"===r||"Boolean"===r||"Function"===r?getNativeType(t)===r:t instanceof o.type}return s?hasOwn.call(o,"validator")&&isFunction(o.validator)?(n&&(a=warn,warn=noop),s=o.validator(t),a&&(warn=a),s||!1!==n||warn(i+"custom validation failed"),s):s:(!1===n&&warn(i+'value "'+t+'" should be of type "'+r+'"'),!1)}var warn=noop,typeDefaults=function(){return{func:function(){},bool:!0,string:"",number:0,array:function(){return[]},object:function(){return{}},integer:0}},setDefaults=function(e){var t=typeDefaults();return Object.defineProperty(e,"sensibleDefaults",{enumerable:!1,set:function(e){t=!1===e?{}:!0===e?typeDefaults():e},get:function(){return t}})};function _objectWithoutPropertiesLoose$1(e,t){if(null==e)return{};var n,r,o={},s=Object.keys(e);for(r=0;r<s.length;r++)n=s[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}var VueTypes={get any(){return toType("any",{type:null},!0)},get func(){return toType("function",{type:Function},!0).def(VueTypes.sensibleDefaults.func)},get bool(){return toType("boolean",{type:Boolean},!0).def(VueTypes.sensibleDefaults.bool)},get string(){return toType("string",{type:String},!0).def(VueTypes.sensibleDefaults.string)},get number(){return toType("number",{type:Number},!0).def(VueTypes.sensibleDefaults.number)},get array(){return toType("array",{type:Array},!0).def(VueTypes.sensibleDefaults.array)},get object(){return toType("object",{type:Object},!0).def(VueTypes.sensibleDefaults.object)},get integer(){return toType("integer",{type:Number,validator:function(e){return isInteger(e)}}).def(VueTypes.sensibleDefaults.integer)},get symbol(){return toType("symbol",{type:null,validator:function(e){return"symbol"==typeof e}},!0)},extend:function(e){if(void 0===e&&(e={}),isArray(e))return e.forEach((function(e){return VueTypes.extend(e)})),this;var t=e,n=t.name,r=t.validate,o=void 0!==r&&r,s=t.getter,a=void 0!==s&&s,i=_objectWithoutPropertiesLoose$1(t,["name","validate","getter"]);if(has(VueTypes,n))throw new TypeError('[VueTypes error]: Type "'+n+'" already defined');var u,l=i.type,c=i.validator,p=void 0===c?stubTrue:c;if(l&&l._vueTypes_name){delete i.type;for(var d=["type","required","default"],h=0;h<d.length;h+=1){var f=d[h];void 0!==l[f]&&(i[f]=l[f])}o=!1,isFunction(l.validator)&&(i.validator=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return l.validator.apply(l,t)&&p.apply(this,t)})}if(a)u={get:function(){return toType(n,Object.assign({},i),o)},enumerable:!0,configurable:!1};else{var m=i.validator;u={value:function(){var e=toType(n,Object.assign({},i),o);if(m){for(var t=arguments.length,r=new Array(t),s=0;s<t;s++)r[s]=arguments[s];e.validator=m.bind.apply(m,[e].concat(r))}return e},writable:!1,enumerable:!0,configurable:!1}}return Object.defineProperty(this,n,u)},custom:function(e,t){if(void 0===t&&(t="custom validation failed"),"function"!=typeof e)throw new TypeError("[VueTypes error]: You must provide a function as argument");return toType(e.name||"<<anonymous function>>",{validator:function(n){var r=e(n);return r||warn(this._vueTypes_name+" - "+t),r}})},oneOf:function(e){if(!isArray(e))throw new TypeError("[VueTypes error]: You must provide an array as argument");var t='oneOf - value should be one of "'+e.join('", "')+'"',n=e.reduce((function(e,t){return null!=t&&-1===e.indexOf(t.constructor)&&e.push(t.constructor),e}),[]);return toType("oneOf",{type:n.length>0?n:null,validator:function(n){var r=-1!==e.indexOf(n);return r||warn(t),r}})},instanceOf:function(e){return toType("instanceOf",{type:e})},oneOfType:function(e){if(!isArray(e))throw new TypeError("[VueTypes error]: You must provide an array as argument");var t=!1,n=e.reduce((function(e,n){if(isPlainObject$1(n)){if("oneOf"===n._vueTypes_name)return e.concat(n.type||[]);if(isFunction(n.validator))return t=!0,e;if(n.type){if(isArray(n.type))return e.concat(n.type);e.push(n.type)}return e}return e.push(n),e}),[]);if(!t)return toType("oneOfType",{type:n});var r=e.map((function(e){return e&&isArray(e.type)?e.type.map(getType):getType(e)})).reduce((function(e,t){return e.concat(isArray(t)?t:[t])}),[]).join('", "');return this.custom((function(t){var n=e.some((function(e){return"oneOf"===e._vueTypes_name?!e.type||validateType(e.type,t,!0):validateType(e,t,!0)}));return n||warn('oneOfType - value type should be one of "'+r+'"'),n}))},arrayOf:function(e){return toType("arrayOf",{type:Array,validator:function(t){var n=t.every((function(t){return validateType(e,t)}));return n||warn('arrayOf - value must be an array of "'+getType(e)+'"'),n}})},objectOf:function(e){return toType("objectOf",{type:Object,validator:function(t){var n=Object.keys(t).every((function(n){return validateType(e,t[n])}));return n||warn('objectOf - value must be an object of "'+getType(e)+'"'),n}})},shape:function(e){var t=Object.keys(e),n=t.filter((function(t){return e[t]&&!0===e[t].required})),r=toType("shape",{type:Object,validator:function(r){var o=this;if(!isPlainObject$1(r))return!1;var s=Object.keys(r);return n.length>0&&n.some((function(e){return-1===s.indexOf(e)}))?(warn('shape - at least one of required properties "'+n.join('", "')+'" is not present'),!1):s.every((function(n){return-1===t.indexOf(n)?!0===o._vueTypes_isLoose||(warn('shape - object is missing "'+n+'" property'),!1):validateType(e[n],r[n])}))}});return Object.defineProperty(r,"_vueTypes_isLoose",{enumerable:!1,writable:!0,value:!1}),Object.defineProperty(r,"loose",{get:function(){return this._vueTypes_isLoose=!0,this},enumerable:!1}),r}};setDefaults(VueTypes),VueTypes.utils={validate:function(e,t){return validateType(t,e,!0)},toType:toType};var global$1="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{};function memoize(e){var t={};return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var unitlessKeys={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function murmurhash2_32_gc(e){for(var t,n=e.length,r=n^n,o=0;n>=4;)t=1540483477*(65535&(t=255&e.charCodeAt(o)|(255&e.charCodeAt(++o))<<8|(255&e.charCodeAt(++o))<<16|(255&e.charCodeAt(++o))<<24))+((1540483477*(t>>>16)&65535)<<16),r=1540483477*(65535&r)+((1540483477*(r>>>16)&65535)<<16)^(t=1540483477*(65535&(t^=t>>>24))+((1540483477*(t>>>16)&65535)<<16)),n-=4,++o;switch(n){case 3:r^=(255&e.charCodeAt(o+2))<<16;case 2:r^=(255&e.charCodeAt(o+1))<<8;case 1:r=1540483477*(65535&(r^=255&e.charCodeAt(o)))+((1540483477*(r>>>16)&65535)<<16)}return r=1540483477*(65535&(r^=r>>>13))+((1540483477*(r>>>16)&65535)<<16),((r^=r>>>15)>>>0).toString(36)}function stylis_min(e){function t(e,t,r){var o=t.trim().split(f);t=o;var s=o.length,a=e.length;switch(a){case 0:case 1:var i=0;for(e=0===a?"":e[0]+" ";i<s;++i)t[i]=n(e,t[i],r).trim();break;default:var u=i=0;for(t=[];i<s;++i)for(var l=0;l<a;++l)t[u++]=n(e[l]+" ",o[i],r).trim()}return t}function n(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function r(e,t,n,s){var a=e+";",i=2*t+3*n+4*s;if(944===i){e=a.indexOf(":",9)+1;var u=a.substring(e,a.length-1).trim();return u=a.substring(0,e).trim()+u+";",1===R||2===R&&o(u,1)?"-webkit-"+u+u:u}if(0===R||2===R&&!o(a,1))return a;switch(i){case 1015:return 97===a.charCodeAt(10)?"-webkit-"+a+a:a;case 951:return 116===a.charCodeAt(3)?"-webkit-"+a+a:a;case 963:return 110===a.charCodeAt(5)?"-webkit-"+a+a:a;case 1009:if(100!==a.charCodeAt(4))break;case 969:case 942:return"-webkit-"+a+a;case 978:return"-webkit-"+a+"-moz-"+a+a;case 1019:case 983:return"-webkit-"+a+"-moz-"+a+"-ms-"+a+a;case 883:if(45===a.charCodeAt(8))return"-webkit-"+a+a;if(0<a.indexOf("image-set(",11))return a.replace(S,"$1-webkit-$2")+a;break;case 932:if(45===a.charCodeAt(4))switch(a.charCodeAt(5)){case 103:return"-webkit-box-"+a.replace("-grow","")+"-webkit-"+a+"-ms-"+a.replace("grow","positive")+a;case 115:return"-webkit-"+a+"-ms-"+a.replace("shrink","negative")+a;case 98:return"-webkit-"+a+"-ms-"+a.replace("basis","preferred-size")+a}return"-webkit-"+a+"-ms-"+a+a;case 964:return"-webkit-"+a+"-ms-flex-"+a+a;case 1023:if(99!==a.charCodeAt(8))break;return"-webkit-box-pack"+(u=a.substring(a.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+a+"-ms-flex-pack"+u+a;case 1005:return d.test(a)?a.replace(p,":-webkit-")+a.replace(p,":-moz-")+a:a;case 1e3:switch(t=(u=a.substring(13).trim()).indexOf("-")+1,u.charCodeAt(0)+u.charCodeAt(t)){case 226:u=a.replace(_,"tb");break;case 232:u=a.replace(_,"tb-rl");break;case 220:u=a.replace(_,"lr");break;default:return a}return"-webkit-"+a+"-ms-"+u+a;case 1017:if(-1===a.indexOf("sticky",9))break;case 975:switch(t=(a=e).length-10,i=(u=(33===a.charCodeAt(t)?a.substring(0,t):a).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|u.charCodeAt(7))){case 203:if(111>u.charCodeAt(8))break;case 115:a=a.replace(u,"-webkit-"+u)+";"+a;break;case 207:case 102:a=a.replace(u,"-webkit-"+(102<i?"inline-":"")+"box")+";"+a.replace(u,"-webkit-"+u)+";"+a.replace(u,"-ms-"+u+"box")+";"+a}return a+";";case 938:if(45===a.charCodeAt(5))switch(a.charCodeAt(6)){case 105:return u=a.replace("-items",""),"-webkit-"+a+"-webkit-box-"+u+"-ms-flex-"+u+a;case 115:return"-webkit-"+a+"-ms-flex-item-"+a.replace(C,"")+a;default:return"-webkit-"+a+"-ms-flex-line-pack"+a.replace("align-content","").replace(C,"")+a}break;case 973:case 989:if(45!==a.charCodeAt(3)||122===a.charCodeAt(4))break;case 931:case 953:if(!0===T.test(e))return 115===(u=e.substring(e.indexOf(":")+1)).charCodeAt(0)?r(e.replace("stretch","fill-available"),t,n,s).replace(":fill-available",":stretch"):a.replace(u,"-webkit-"+u)+a.replace(u,"-moz-"+u.replace("fill-",""))+a;break;case 962:if(a="-webkit-"+a+(102===a.charCodeAt(5)?"-ms-"+a:"")+a,211===n+s&&105===a.charCodeAt(13)&&0<a.indexOf("transform",10))return a.substring(0,a.indexOf(";",27)+1).replace(h,"$1-webkit-$2")+a}return a}function o(e,t){var n=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?n:10);return n=e.substring(n+1,e.length-1),A(2!==t?r:r.replace(O,"$1"),n,t)}function s(e,t){var n=r(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace($," or ($1)").substring(4):"("+t+")"}function a(e,t,n,r,o,s,a,i,l,c){for(var p,d=0,h=t;d<x;++d)switch(p=I[d].call(u,e,h,n,r,o,s,a,i,l,c)){case void 0:case!1:case!0:case null:break;default:h=p}if(h!==t)return h}function i(e){return void 0!==(e=e.prefix)&&(A=null,e?"function"!=typeof e?R=1:(R=2,A=e):R=0),i}function u(e,n){var i=e;if(33>i.charCodeAt(0)&&(i=i.trim()),i=[i],0<x){var u=a(-1,n,i,i,P,w,0,0,0,0);void 0!==u&&"string"==typeof u&&(n=u)}var p=function e(n,i,u,p,d){for(var h,f,m,_,$,C=0,O=0,T=0,S=0,I=0,A=0,j=m=h=0,V=0,M=0,Q=0,D=0,F=u.length,N=F-1,q="",B="",U="",H="";V<F;){if(f=u.charCodeAt(V),V===N&&0!==O+S+T+C&&(0!==O&&(f=47===O?10:47),S=T=C=0,F++,N++),0===O+S+T+C){if(V===N&&(0<M&&(q=q.replace(c,"")),0<q.trim().length)){switch(f){case 32:case 9:case 59:case 13:case 10:break;default:q+=u.charAt(V)}f=59}switch(f){case 123:for(h=(q=q.trim()).charCodeAt(0),m=1,D=++V;V<F;){switch(f=u.charCodeAt(V)){case 123:m++;break;case 125:m--;break;case 47:switch(f=u.charCodeAt(V+1)){case 42:case 47:e:{for(j=V+1;j<N;++j)switch(u.charCodeAt(j)){case 47:if(42===f&&42===u.charCodeAt(j-1)&&V+2!==j){V=j+1;break e}break;case 10:if(47===f){V=j+1;break e}}V=j}}break;case 91:f++;case 40:f++;case 34:case 39:for(;V++<N&&u.charCodeAt(V)!==f;);}if(0===m)break;V++}switch(m=u.substring(D,V),0===h&&(h=(q=q.replace(l,"").trim()).charCodeAt(0)),h){case 64:switch(0<M&&(q=q.replace(c,"")),f=q.charCodeAt(1)){case 100:case 109:case 115:case 45:M=i;break;default:M=k}if(D=(m=e(i,M,m,f,d+1)).length,0<x&&($=a(3,m,M=t(k,q,Q),i,P,w,D,f,d,p),q=M.join(""),void 0!==$&&0===(D=(m=$.trim()).length)&&(f=0,m="")),0<D)switch(f){case 115:q=q.replace(b,s);case 100:case 109:case 45:m=q+"{"+m+"}";break;case 107:m=(q=q.replace(g,"$1 $2"))+"{"+m+"}",m=1===R||2===R&&o("@"+m,3)?"@-webkit-"+m+"@"+m:"@"+m;break;default:m=q+m,112===p&&(B+=m,m="")}else m="";break;default:m=e(i,t(i,q,Q),m,p,d+1)}U+=m,m=Q=M=j=h=0,q="",f=u.charCodeAt(++V);break;case 125:case 59:if(1<(D=(q=(0<M?q.replace(c,""):q).trim()).length))switch(0===j&&(h=q.charCodeAt(0),45===h||96<h&&123>h)&&(D=(q=q.replace(" ",":")).length),0<x&&void 0!==($=a(1,q,i,n,P,w,B.length,p,d,p))&&0===(D=(q=$.trim()).length)&&(q="\0\0"),h=q.charCodeAt(0),f=q.charCodeAt(1),h){case 0:break;case 64:if(105===f||99===f){H+=q+u.charAt(V);break}default:58!==q.charCodeAt(D-1)&&(B+=r(q,h,f,q.charCodeAt(2)))}Q=M=j=h=0,q="",f=u.charCodeAt(++V)}}switch(f){case 13:case 10:47===O?O=0:0===1+h&&107!==p&&0<q.length&&(M=1,q+="\0"),0<x*L&&a(0,q,i,n,P,w,B.length,p,d,p),w=1,P++;break;case 59:case 125:if(0===O+S+T+C){w++;break}default:switch(w++,_=u.charAt(V),f){case 9:case 32:if(0===S+C+O)switch(I){case 44:case 58:case 9:case 32:_="";break;default:32!==f&&(_=" ")}break;case 0:_="\\0";break;case 12:_="\\f";break;case 11:_="\\v";break;case 38:0===S+O+C&&(M=Q=1,_="\f"+_);break;case 108:if(0===S+O+C+E&&0<j)switch(V-j){case 2:112===I&&58===u.charCodeAt(V-3)&&(E=I);case 8:111===A&&(E=A)}break;case 58:0===S+O+C&&(j=V);break;case 44:0===O+T+S+C&&(M=1,_+="\r");break;case 34:case 39:0===O&&(S=S===f?0:0===S?f:S);break;case 91:0===S+O+T&&C++;break;case 93:0===S+O+T&&C--;break;case 41:0===S+O+C&&T--;break;case 40:if(0===S+O+C){if(0===h)switch(2*I+3*A){case 533:break;default:h=1}T++}break;case 64:0===O+T+S+C+j+m&&(m=1);break;case 42:case 47:if(!(0<S+C+T))switch(O){case 0:switch(2*f+3*u.charCodeAt(V+1)){case 235:O=47;break;case 220:D=V,O=42}break;case 42:47===f&&42===I&&D+2!==V&&(33===u.charCodeAt(D+2)&&(B+=u.substring(D,V+1)),_="",O=0)}}0===O&&(q+=_)}A=I,I=f,V++}if(0<(D=B.length)){if(M=i,0<x&&(void 0!==($=a(2,B,M,n,P,w,D,p,d,p))&&0===(B=$).length))return H+B+U;if(B=M.join(",")+"{"+B+"}",0!=R*E){switch(2!==R||o(B,2)||(E=0),E){case 111:B=B.replace(v,":-moz-$1")+B;break;case 112:B=B.replace(y,"::-webkit-input-$1")+B.replace(y,"::-moz-$1")+B.replace(y,":-ms-input-$1")+B}E=0}}return H+B+U}(k,i,n,0,0);return 0<x&&(void 0!==(u=a(-2,p,i,i,P,w,p.length,0,0,0))&&(p=u)),"",E=0,w=P=1,p}var l=/^\0+/g,c=/[\0\r\f]/g,p=/: */g,d=/zoo|gra/,h=/([,: ])(transform)/g,f=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,g=/@(k\w+)\s*(\S*)\s*/,y=/::(place)/g,v=/:(read-only)/g,_=/[svh]\w+-[tblr]{2}/,b=/\(\s*(.*)\s*\)/g,$=/([\s\S]*?);/g,C=/-self|flex-/g,O=/[^]*?(:[rp][el]a[\w-]+)[^]*/,T=/stretch|:\s*\w+\-(?:conte|avail)/,S=/([^-])(image-set\()/,w=1,P=1,E=0,R=1,k=[],I=[],x=0,A=null,L=0;return u.use=function e(t){switch(t){case void 0:case null:x=I.length=0;break;default:switch(t.constructor){case Array:for(var n=0,r=t.length;n<r;++n)e(t[n]);break;case Function:I[x++]=t;break;case Boolean:L=0|!!t}}return e},u.set=i,void 0!==e&&i(e),u}var stylisRuleSheet=createCommonjsModule((function(e,t){e.exports=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,o,s,a,i,u,l,c,p){switch(n){case 1:if(0===c&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===l)return r+"/*|*/";break;case 3:switch(l){case 102:case 112:return e(o[0]+r),"";default:return r+(0===p?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t)}}}})),hyphenateRegex=/[A-Z]|^ms/g,processStyleName=memoize((function(e){return e.replace(hyphenateRegex,"-$&").toLowerCase()})),processStyleValue=function(e,t){return null==t||"boolean"==typeof t?"":1===unitlessKeys[e]||45===e.charCodeAt(1)||isNaN(t)||0===t?t:t+"px"},classnames=function e(t){for(var n=t.length,r=0,o="";r<n;r++){var s=t[r];if(null!=s){var a=void 0;switch(typeof s){case"boolean":break;case"function":a=e([s()]);break;case"object":if(Array.isArray(s))a=e(s);else for(var i in a="",s)s[i]&&i&&(a&&(a+=" "),a+=i);break;default:a=s}a&&(o&&(o+=" "),o+=a)}}return o},isBrowser="undefined"!=typeof document;function sheetForTag(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function makeStyleTag(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key||""),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),(void 0!==e.container?e.container:document.head).appendChild(t),t}var StyleSheet=function(){function e(e){this.isSpeedy=!0,this.tags=[],this.ctr=0,this.opts=e}var t=e.prototype;return t.inject=function(){if(this.injected)throw new Error("already injected!");this.tags[0]=makeStyleTag(this.opts),this.injected=!0},t.speedy=function(e){if(0!==this.ctr)throw new Error("cannot change speedy now");this.isSpeedy=!!e},t.insert=function(e,t){if(this.isSpeedy){var n=sheetForTag(this.tags[this.tags.length-1]);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else{var r=makeStyleTag(this.opts);this.tags.push(r),r.appendChild(document.createTextNode(e+(t||"")))}this.ctr++,this.ctr%65e3==0&&this.tags.push(makeStyleTag(this.opts))},t.flush=function(){this.tags.forEach((function(e){return e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0,this.injected=!1},e}();function createEmotion(e,t){if(void 0!==e.__SECRET_EMOTION__)return e.__SECRET_EMOTION__;void 0===t&&(t={});var n,r=t.key||"css";var o,s=stylisRuleSheet((function(e){n+=e,isBrowser&&i.insert(e,l)}));void 0!==t.prefix&&(o={prefix:t.prefix});var a={registered:{},inserted:{},nonce:t.nonce,key:r},i=new StyleSheet(t);isBrowser&&i.inject();var u=new stylis_min(o);u.use(t.stylisPlugins)(s);var l="";function c(e,t){if(null==e)return"";switch(typeof e){case"boolean":return"";case"function":if(void 0!==e.__emotion_styles){var n=e.toString();return n}return c.call(this,void 0===this?e():e(this.mergedProps,this.context),t);case"object":return f.call(this,e);default:var r=a.registered[e];return!1===t&&void 0!==r?r:e}}var p,d,h=new WeakMap;function f(e){if(h.has(e))return h.get(e);var t="";return Array.isArray(e)?e.forEach((function(e){t+=c.call(this,e,!1)}),this):Object.keys(e).forEach((function(n){"object"!=typeof e[n]?void 0!==a.registered[e[n]]?t+=n+"{"+a.registered[e[n]]+"}":t+=processStyleName(n)+":"+processStyleValue(n,e[n])+";":Array.isArray(e[n])&&"string"==typeof e[n][0]&&void 0===a.registered[e[n][0]]?e[n].forEach((function(e){t+=processStyleName(n)+":"+processStyleValue(n,e)+";"})):t+=n+"{"+c.call(this,e[n],!1)+"}"}),this),h.set(e,t),t}var m=/label:\s*([^\s;\n{]+)\s*;/g,g=function(e,t){return murmurhash2_32_gc(e+t)+t},y=function(e){var t=!0,n="",r="";null==e||void 0===e.raw?(t=!1,n+=c.call(this,e,!1)):n+=e[0];for(var o=arguments.length,s=new Array(o>1?o-1:0),a=1;a<o;a++)s[a-1]=arguments[a];return s.forEach((function(r,o){n+=c.call(this,r,46===n.charCodeAt(n.length-1)),!0===t&&void 0!==e[o+1]&&(n+=e[o+1])}),this),d=n,n=n.replace(m,(function(e,t){return r+="-"+t,""})),p=g(n,r),n};function v(e,t){void 0===a.inserted[p]&&(n="",u(e,t),a.inserted[p]=n)}var _=function(){var e=y.apply(this,arguments),t=r+"-"+p;return void 0===a.registered[t]&&(a.registered[t]=d),v("."+t,e),t};function b(e,t){var n="";return t.split(" ").forEach((function(t){void 0!==a.registered[t]?e.push(t):n+=t+" "})),n}function $(e,t){var n=[],r=b(n,e);return n.length<2?e:r+_(n,t)}function C(e){a.inserted[e]=!0}if(isBrowser){var O=document.querySelectorAll("[data-emotion-"+r+"]");Array.prototype.forEach.call(O,(function(e){i.tags[0].parentNode.insertBefore(e,i.tags[0]),e.getAttribute("data-emotion-"+r).split(" ").forEach(C)}))}var T={flush:function(){isBrowser&&(i.flush(),i.inject()),a.inserted={},a.registered={}},hydrate:function(e){e.forEach(C)},cx:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return $(classnames(t))},merge:$,getRegisteredStyles:b,injectGlobal:function(){var e=y.apply(this,arguments);v("",e)},keyframes:function(){var e=y.apply(this,arguments),t="animation-"+p;return v("","@keyframes "+t+"{"+e+"}"),t},css:_,sheet:i,caches:a};return e.__SECRET_EMOTION__=T,T}var context=void 0!==global$1?global$1:{},_createEmotion=createEmotion(context),flush=_createEmotion.flush,hydrate=_createEmotion.hydrate,cx=_createEmotion.cx,merge=_createEmotion.merge,getRegisteredStyles=_createEmotion.getRegisteredStyles,injectGlobal=_createEmotion.injectGlobal,keyframes=_createEmotion.keyframes,css=_createEmotion.css,sheet=_createEmotion.sheet,caches=_createEmotion.caches,index=function(e){for(var t=arguments,n=1;n<arguments.length;n++)for(var r in arguments[n])e[r]=t[n][r];return e},nanoAssign_common=index,STYLES_KEY="__emotion_styles";function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function stringifyClass(e){return Array.isArray(e)?e.join(" "):"object"===_typeof(e)?Object.keys(e).filter((function(t){return Boolean(e[t])})).join(" "):e}var index$1=function(e,t){var n,r,o,s;void 0!==t&&(n=t.e,r=t.label,o=t.target,s=t.props);var a=e.__emotion_real===e,i=void 0===n&&a&&e.__emotion_base||e;return function(){var t=a&&void 0!==e[STYLES_KEY]?e[STYLES_KEY].slice(0):[];if(void 0!==r&&t.push("label:".concat(r,";")),void 0===n){for(var u=arguments.length,l=new Array(u),c=0;c<u;c++)l[c]=arguments[c];if(null===l[0]||void 0===l[0].raw)t.push.apply(t,l);else{t.push(l[0][0]);for(var p=l.length,d=1;d<p;d++)t.push(l[d],l[0][d])}}var h={name:"Styled".concat(e.name||r||"Component"),functional:!0,inject:{theme:{from:"theme_reactivesearch",default:null}},props:s,render:function(r,s){var a=s.data,i=s.children,u=s.props,l=s.injections,c="",p=[],d=stringifyClass(a.class),h={};for(var f in a.attrs)"$"!==f[0]&&(h[f]=a.attrs[f]);if(d&&(c+=void 0===n?getRegisteredStyles(p,d):"".concat(d," ")),void 0===n){var m={mergedProps:nanoAssign_common({theme:l.theme},u)};c+=css.apply(m,t.concat(p))}else c+=n;return void 0!==o&&(c+=" ".concat(o)),r(e,nanoAssign_common({},a,{attrs:h,class:c}),i)}};return h[STYLES_KEY]=t,h.__emotion_base=i,h.__emotion_real=h,Object.defineProperty(h,"toString",{enumerable:!1,value:function(){return".".concat(o)}}),h}};function _extends$1(){return(_extends$1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function colorToInt(e){return Math.round(255*e)}function convertToInt(e,t,n){return colorToInt(e)+","+colorToInt(t)+","+colorToInt(n)}function hslToRgb(e,t,n,r){if(void 0===r&&(r=convertToInt),0===t)return r(n,n,n);var o=e%360/60,s=(1-Math.abs(2*n-1))*t,a=s*(1-Math.abs(o%2-1)),i=0,u=0,l=0;o>=0&&o<1?(i=s,u=a):o>=1&&o<2?(i=a,u=s):o>=2&&o<3?(u=s,l=a):o>=3&&o<4?(u=a,l=s):o>=4&&o<5?(i=a,l=s):o>=5&&o<6&&(i=s,l=a);var c=n-s/2;return r(i+c,u+c,l+c)}var namedColorMap={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function nameToHex(e){if("string"!=typeof e)return e;var t=e.toLowerCase();return namedColorMap[t]?"#"+namedColorMap[t]:e}var hexRegex=/^#[a-fA-F0-9]{6}$/,hexRgbaRegex=/^#[a-fA-F0-9]{8}$/,reducedHexRegex=/^#[a-fA-F0-9]{3}$/,reducedRgbaHexRegex=/^#[a-fA-F0-9]{4}$/,rgbRegex=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/,rgbaRegex=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/,hslRegex=/^hsl\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*\)$/,hslaRegex=/^hsla\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/;function parseToRgb(e){if("string"!=typeof e)throw new Error("Passed an incorrect argument to a color function, please pass a string representation of a color.");var t=nameToHex(e);if(t.match(hexRegex))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(hexRgbaRegex)){var n=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:n}}if(t.match(reducedHexRegex))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(reducedRgbaHexRegex)){var r=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:r}}var o=rgbRegex.exec(t);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10)};var s=rgbaRegex.exec(t);if(s)return{red:parseInt(""+s[1],10),green:parseInt(""+s[2],10),blue:parseInt(""+s[3],10),alpha:parseFloat(""+s[4])};var a=hslRegex.exec(t);if(a){var i="rgb("+hslToRgb(parseInt(""+a[1],10),parseInt(""+a[2],10)/100,parseInt(""+a[3],10)/100)+")",u=rgbRegex.exec(i);if(!u)throw new Error("Couldn't generate valid rgb string from "+t+", it returned "+i+".");return{red:parseInt(""+u[1],10),green:parseInt(""+u[2],10),blue:parseInt(""+u[3],10)}}var l=hslaRegex.exec(t);if(l){var c="rgb("+hslToRgb(parseInt(""+l[1],10),parseInt(""+l[2],10)/100,parseInt(""+l[3],10)/100)+")",p=rgbRegex.exec(c);if(!p)throw new Error("Couldn't generate valid rgb string from "+t+", it returned "+c+".");return{red:parseInt(""+p[1],10),green:parseInt(""+p[2],10),blue:parseInt(""+p[3],10),alpha:parseFloat(""+l[4])}}throw new Error("Couldn't parse the color string. Please provide the color as a string in hex, rgb, rgba, hsl or hsla notation.")}function rgbToHsl(e){var t,n=e.red/255,r=e.green/255,o=e.blue/255,s=Math.max(n,r,o),a=Math.min(n,r,o),i=(s+a)/2;if(s===a)return void 0!==e.alpha?{hue:0,saturation:0,lightness:i,alpha:e.alpha}:{hue:0,saturation:0,lightness:i};var u=s-a,l=i>.5?u/(2-s-a):u/(s+a);switch(s){case n:t=(r-o)/u+(r<o?6:0);break;case r:t=(o-n)/u+2;break;default:t=(n-r)/u+4}return t*=60,void 0!==e.alpha?{hue:t,saturation:l,lightness:i,alpha:e.alpha}:{hue:t,saturation:l,lightness:i}}function parseToHsl(e){return rgbToHsl(parseToRgb(e))}var reduceHexValue=function(e){return 7===e.length&&e[1]===e[2]&&e[3]===e[4]&&e[5]===e[6]?"#"+e[1]+e[3]+e[5]:e};function numberToHex(e){var t=e.toString(16);return 1===t.length?"0"+t:t}function colorToHex(e){return numberToHex(Math.round(255*e))}function convertToHex(e,t,n){return reduceHexValue("#"+colorToHex(e)+colorToHex(t)+colorToHex(n))}function hslToHex(e,t,n){return hslToRgb(e,t,n,convertToHex)}function hsl(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return hslToHex(e,t,n);if("object"==typeof e&&void 0===t&&void 0===n)return hslToHex(e.hue,e.saturation,e.lightness);throw new Error("Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).")}function hsla(e,t,n,r){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n&&"number"==typeof r)return r>=1?hslToHex(e,t,n):"rgba("+hslToRgb(e,t,n)+","+r+")";if("object"==typeof e&&void 0===t&&void 0===n&&void 0===r)return e.alpha>=1?hslToHex(e.hue,e.saturation,e.lightness):"rgba("+hslToRgb(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Error("Passed invalid arguments to hsla, please pass multiple numbers e.g. hsl(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).")}function rgb(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return reduceHexValue("#"+numberToHex(e)+numberToHex(t)+numberToHex(n));if("object"==typeof e&&void 0===t&&void 0===n)return reduceHexValue("#"+numberToHex(e.red)+numberToHex(e.green)+numberToHex(e.blue));throw new Error("Passed invalid arguments to rgb, please pass multiple numbers e.g. rgb(255, 205, 100) or an object e.g. rgb({ red: 255, green: 205, blue: 100 }).")}function rgba(e,t,n,r){if("string"==typeof e&&"number"==typeof t){var o=parseToRgb(e);return"rgba("+o.red+","+o.green+","+o.blue+","+t+")"}if("number"==typeof e&&"number"==typeof t&&"number"==typeof n&&"number"==typeof r)return r>=1?rgb(e,t,n):"rgba("+e+","+t+","+n+","+r+")";if("object"==typeof e&&void 0===t&&void 0===n&&void 0===r)return e.alpha>=1?rgb(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")";throw new Error("Passed invalid arguments to rgba, please pass multiple numbers e.g. rgb(255, 205, 100, 0.75) or an object e.g. rgb({ red: 255, green: 205, blue: 100, alpha: 0.75 }).")}var isRgb=function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&("number"!=typeof e.alpha||void 0===e.alpha)},isRgba=function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&"number"==typeof e.alpha},isHsl=function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&("number"!=typeof e.alpha||void 0===e.alpha)},isHsla=function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&"number"==typeof e.alpha},errMsg="Passed invalid argument to toColorString, please pass a RgbColor, RgbaColor, HslColor or HslaColor object.";function toColorString(e){if("object"!=typeof e)throw new Error(errMsg);if(isRgba(e))return rgba(e);if(isRgb(e))return rgb(e);if(isHsla(e))return hsla(e);if(isHsl(e))return hsl(e);throw new Error(errMsg)}function curried(e,t,n){return function(){var r=n.concat(Array.prototype.slice.call(arguments));return r.length>=t?e.apply(this,r):curried(e,t,r)}}function curry(e){return curried(e,e.length,[])}function guard(e,t,n){return Math.max(e,Math.min(t,n))}function darken(e,t){var n=parseToHsl(t);return toColorString(_extends$1({},n,{lightness:guard(0,1,n.lightness-parseFloat(e))}))}var curriedDarken=curry(darken);function lighten(e,t){var n=parseToHsl(t);return toColorString(_extends$1({},n,{lightness:guard(0,1,n.lightness+parseFloat(e))}))}var curriedLighten=curry(lighten),_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,filters=function(e){var t=e.colors.borderColor;return css(_templateObject||(_templateObject=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -3px;\n\tmax-width: 100%;\n\n\tbutton {\n\t\tmargin: 2px 3px;\n\t\tpadding: 5px 8px;\n\t\tfont-size: 0.85rem;\n\t\tposition: relative;\n\n\t\tspan:first-child {\n\t\t\tmax-width: 260px;\n\t\t\twhite-space: nowrap;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\tmargin-right: 26px;\n\t\t}\n\n\t\tspan:last-child {\n\t\t\tdisplay: flex;\n\t\t\theight: 100%;\n\t\t\ttop: 0;\n\t\t\tright: 8px;\n\t\t\tposition: absolute;\n\t\t\talign-items: center;\n\t\t\tborder-left: 1px solid ",";\n\t\t\tpadding-left: 8px;\n\t\t\tmargin-left: 8px;\n\t\t}\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tspan:first-child {\n\t\t\t\ttext-decoration: line-through;\n\t\t\t}\n\t\t}\n\t}\n"])),t||"#fff")},pagination=css(_templateObject2||(_templateObject2=_taggedTemplateLiteralLoose(["\n\tmargin: 10px -3px;\n\tmax-width: 100%;\n\ttext-align: center;\n\n\tbutton {\n\t\tmargin: 0 3px;\n\t}\n"]))),toggleButtons=css(_templateObject3||(_templateObject3=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -3px;\n\tmax-width: 100%;\n\n\tbutton {\n\t\tmargin: 3px 3px;\n\t}\n"]))),numberBoxContainer=css(_templateObject4||(_templateObject4=_taggedTemplateLiteralLoose(["\n\tmargin: 0 -5px;\n\tbutton {\n\t\tmargin: 5px;\n\t}\n\tspan {\n\t\tmargin: 0 5px;\n\t}\n"]))),primary=function(e){var t=e.theme;return css(_templateObject5||(_templateObject5=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: ",";\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.primaryColor,t.colors.primaryTextColor,curriedDarken(.1,t.colors.primaryColor))},large=function(){return css(_templateObject6||(_templateObject6=_taggedTemplateLiteralLoose(["\n\tmin-height: 40px;\n\tpadding: 10px 20px;\n"])))},disabled=function(e){var t=e.theme;return css(_templateObject7||(_templateObject7=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: #ccc;\n\tcursor: not-allowed;\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fafafa",t.colors.backgroundColor?curriedLighten(.2,t.colors.backgroundColor):"#fafafa")},Button=index$1("button")(_templateObject8||(_templateObject8=_taggedTemplateLiteralLoose(["\n\tdisplay: inline-flex;\n\tjustify-content: center;\n\talign-items: center;\n\tborder-radius: 3px;\n\tborder: 1px solid transparent;\n\tmin-height: 30px;\n\tword-wrap: break-word;\n\tpadding: 5px 12px;\n\tline-height: 1.2rem;\n\tbackground-color: ",";\n\tcolor: ",";\n\tcursor: pointer;\n\tuser-select: none;\n\ttransition: all 0.3s ease;\n\n\t&:hover,\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n\n\t&:focus {\n\t\toutline: 0;\n\t\tborder-color: ",";\n\t\tbox-shadow: ",";\n\t}\n\n\t",";\n\t",";\n\t",";\n\n\t&.enter-btn {\n\t\tborder-top-left-radius: 0px;\n\t\tborder-bottom-left-radius: 0px;\n\t\theight: 100%;\n\t}\n"])),(function(e){return e.theme.colors.backgroundColor||"#eee"}),(function(e){return e.theme.colors.textColor}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedDarken(.1,t.colors.backgroundColor):"#ccc"}),(function(e){return rgba(e.theme.colors.primaryColor,.6)}),(function(e){return"0 0 0 2px "+rgba(e.theme.colors.primaryColor,.3)}),(function(e){return e.primary?primary:null}),(function(e){return e.disabled?disabled:null}),(function(e){return e.large&&large})),loadMoreContainer=css({margin:"5px 0",display:"flex",justifyContent:"center"});VueTypes.sensibleDefaults=!1;var reactKeyType=VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string),VueTypes.object,VueTypes.arrayOf(VueTypes.object)]);function validateLocation(e){return e&&e.lat&&e.lng?isNaN(e.lat)?(console.error(new Error("lat value must be a number")),!1):isNaN(e.lat)?(console.error(new Error("lng value must be a number")),!1):e.lat<-90||e.lat>90?(console.error(new Error("lat value should be between -90 and 90.")),!1):!(e.lat<-180||e.lat>180)||(console.error(new Error("lng value should be between -180 and 180.")),!1):(console.error(new Error("location must be an object with lat and lng keys defined")),!1)}var types={any:VueTypes.any,bool:VueTypes.bool,boolRequired:VueTypes.bool.isRequired,components:VueTypes.arrayOf(VueTypes.string),children:VueTypes.any,data:VueTypes.arrayOf(VueTypes.object),dataFieldArray:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]).isRequired,dataNumberBox:VueTypes.shape({label:VueTypes.string,start:VueTypes.number.isRequired,end:VueTypes.number.isRequired}).isRequired,date:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]),dateObject:VueTypes.object,excludeFields:VueTypes.arrayOf(VueTypes.string),fieldWeights:VueTypes.arrayOf(VueTypes.number),filterLabel:VueTypes.string,func:VueTypes.func,funcRequired:VueTypes.func.isRequired,fuzziness:VueTypes.oneOf([0,1,2,"AUTO"]),headers:VueTypes.object,hits:VueTypes.arrayOf(VueTypes.object),iconPosition:VueTypes.oneOf(["left","right"]),includeFields:VueTypes.arrayOf(VueTypes.string),labelPosition:VueTypes.oneOf(["left","right","top","bottom"]),number:VueTypes.number,options:VueTypes.oneOfType([VueTypes.arrayOf(VueTypes.object),VueTypes.object]),paginationAt:VueTypes.oneOf(["top","bottom","both"]),range:VueTypes.shape({start:VueTypes.number.isRequired,end:VueTypes.number.isRequired}),rangeLabels:VueTypes.shape({start:VueTypes.string.isRequired,end:VueTypes.string.isRequired}),react:VueTypes.shape({and:reactKeyType,or:reactKeyType,not:reactKeyType}),selectedValues:VueTypes.object,selectedValue:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string),VueTypes.arrayOf(VueTypes.object),VueTypes.object,Number,VueTypes.arrayOf(Number)]),suggestions:VueTypes.arrayOf(VueTypes.object),supportedOrientations:VueTypes.oneOf(["portrait","portrait-upside-down","landscape","landscape-left","landscape-right"]),sortBy:VueTypes.oneOf(["asc","desc"]),sortOptions:VueTypes.arrayOf(VueTypes.shape({label:VueTypes.string,dataField:VueTypes.string,sortBy:VueTypes.string})),sortByWithCount:VueTypes.oneOf(["asc","desc","count"]),stats:VueTypes.arrayOf(VueTypes.object),string:VueTypes.string,stringArray:VueTypes.arrayOf(VueTypes.string),stringOrArray:VueTypes.oneOfType([VueTypes.string,VueTypes.arrayOf(VueTypes.string)]),stringRequired:VueTypes.string.isRequired,style:VueTypes.object,themePreset:VueTypes.oneOf(["light","dark"]),queryFormatSearch:VueTypes.oneOf(["and","or"]),queryFormatNumberBox:VueTypes.oneOf(["exact","lte","gte"]),params:VueTypes.object.isRequired,props:VueTypes.object,rangeLabelsAlign:VueTypes.oneOf(["left","right"]),title:VueTypes.oneOfType([VueTypes.string,VueTypes.any]),tooltipTrigger:VueTypes.oneOf(["always","none","hover"]),location:VueTypes.custom(validateLocation),unit:VueTypes.oneOf(["mi","miles","yd","yards","ft","feet","in","inch","km","kilometers","m","meters","cm","centimeters","mm","millimeters","NM","nmi","nauticalmiles"]),value:VueTypes.string.def(void 0),analyticsConfig:VueTypes.shape({emptyQuery:VueTypes.bool,suggestionAnalytics:VueTypes.bool,userId:VueTypes.string,customEvents:VueTypes.object}),appbaseConfig:VueTypes.shape({recordAnalytics:VueTypes.bool,emptyQuery:VueTypes.bool,suggestionAnalytics:VueTypes.bool,enableQueryRules:VueTypes.bool,enableSearchRelevancy:VueTypes.bool,userId:VueTypes.string,useCache:VueTypes.bool,customEvents:VueTypes.object,enableTelemetry:VueTypes.bool.def(!0),queryParams:VueTypes.object}).def({}),mongodb:VueTypes.shape({db:VueTypes.string,collection:VueTypes.string}),endpointConfig:VueTypes.shape({url:VueTypes.string.isRequired,method:VueTypes.string,headers:VueTypes.object,body:VueTypes.object})},getClassName=lib_8.getClassName,handleA11yAction=lib_8.handleA11yAction;function getStartPage(e,t,n){var r=parseInt(e/2,10),o=t-(n?Math.ceil(r/2)-1:r);return o>1?o:2}var Pagination={name:"Pagination",functional:!0,props:{currentPage:types.number,innerClass:types.style,pages:types.number,setPage:types.func,totalPages:types.number,showEndPage:VueTypes.bool,prevLabel:types.string,nextLabel:types.string},render:function(e,t){var n=arguments[0],r=t.props,o=function(){r.currentPage&&r.setPage(r.currentPage-1)},s=function(){r.currentPage<r.totalPages-1&&r.setPage(r.currentPage+1)};if(!r.totalPages)return null;var a=getClassName(r.innerClass,"button"),i=0===r.currentPage,u=a||i?a+" "+(i?"active":""):"",l=function(e){var t=r.pages,o=r.currentPage,s=r.totalPages,i=r.setPage,u=r.showEndPage,l="start"===e?getStartPage(t,o,u):Math.max(2,Math.ceil(s-(t-1)/2+1)),c=[],p=l;if(l<=s){var d=t<s?l+(t-1):s+1;u&&(d="start"===e?l+(Math.ceil(t/2)-t%2):s+1),o>s-t+2&&(l=Math.max(2,s-t+2),d=l+t);for(var h=function(e){var t=o===e-1,r=n(Button,{class:a||t?a+" "+(t?"active":""):"",attrs:{primary:t,tabIndex:"0",alt:"page-"+e},on:{keyPress:function(t){return handleA11yAction(t,(function(){return i(e-1)}))},click:function(){return i(e-1)}}},[e]);e<=s+1&&(c.push(r),e===Math.min(s+1,d)-1&&(p=e))},f=l;f<Math.min(s+1,d);f+=1)h(f)}return[c,l,p]},c=function(){var e=r.showEndPage,t=r.currentPage,n=r.totalPages,o=r.pages;return e?t<=n-o+2||n<o?l("start")[0]:null:l("start")[0]};return n("div",{class:pagination+" "+getClassName(r.innerClass,"pagination")},[n(Button,{class:getClassName(r.innerClass,"button")||"",attrs:{disabled:0===r.currentPage,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,o)},click:o}},[r.prevLabel||"Prev"]),n(Button,{class:u,attrs:{primary:i,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,(function(){return r.setPage(0)}))},click:function(){return r.setPage(0)}}},["1"]),r.showEndPage&&r.currentPage>=Math.floor(r.pages/2)+!!(r.pages%2)&&2!==l("start")[1]?n("span",["..."]):null,c(),r.showEndPage&&r.pages>2&&r.currentPage<=r.totalPages-Math.ceil(.75*r.pages)&&l("start")[2]!==l("end")[1]-1?n("span",["..."]):null,r.showEndPage&&r.totalPages>=r.pages&&l("end")[0],n(Button,{class:getClassName(r.innerClass,"button")||"",attrs:{disabled:r.currentPage>=r.totalPages-1,tabIndex:"0"},on:{keyPress:function(e){return handleA11yAction(e,s)},click:s}},[r.nextLabel||"Next"])])}},_templateObject$1;Pagination.install=function(e){e.component(Pagination.name,Pagination)};var PoweredByImage=index$1("img")(_templateObject$1||(_templateObject$1=_taggedTemplateLiteralLoose(["\n\twidth: 110px;\n"]))),PoweredBy={functional:!0,render:function(e){return e("a",{attrs:{href:"https://appbase.io/",target:"_blank",rel:"noopener noreferrer"}},[e(PoweredByImage,{attrs:{src:"https://cdn.jsdelivr.net/gh/appbaseio/cdn@d2ec210045e59104ee5485841fa17b23fc83f097/appbase/logos/rbc-logo.svg"}})])}},hasOwn$1=Object.prototype.hasOwnProperty;function is(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!=e&&t!=t}function shallowEqual(e,t){if(is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=0;o<n.length;o+=1)if(!hasOwn$1.call(t,n[o])||!is(e[n[o]],t[n[o]]))return!1;return!0}var defaultMapState=function(){return{}},defaultMapDispatch={},normalizeMapState=function(e){if("function"==typeof e)return e;if(e===Object(e))return function(t,n){return Object.keys(e).filter((function(t){return"function"==typeof e[t]})).reduce((function(r,o){var s;return _extends({},r,((s={})[o]=e[o](t,n),s))}),{})};throw new Error("[revux] - mapState provided to connect is invalid")},connector=function(e,t){return void 0===e&&(e=defaultMapState),void 0===t&&(t=defaultMapDispatch),function(n){var r=normalizeMapState(e);return{name:"connect-"+n.name,mixins:[n],inject:["$$store"],data:function(){var e=_extends({},r(this.$$store.getState(),this.$props||{}),bindActionCreators(t,this.$$store.dispatch));return Object.keys(e).reduce((function(t,n){var r;return _extends({},t,((r={})[n]=e[n],r))}),{})},created:function(){var e=this;this._unsubscribe=function(e,t,n){var r=t(e.getState());return e.subscribe((function(){var o=t(e.getState());if(!shallowEqual(r,o)){var s=r;n(r=o,s)}}))}(this.$$store,(function(t){return r(t,e.$props||{})}),(function(t){Object.keys(t).forEach((function(n){e.$set(e,n,t[n])}))}))},beforeDestroy:function(){this._unsubscribe()}}}},defaultQueryUtil=lib_8.updateDefaultQuery,customQueryUtil=lib_8.updateCustomQuery,isEqual=lib_8.isEqual,connect=function(){return connector.apply(void 0,arguments)},X_SEARCH_CLIENT="ReactiveSearch Vue",composeThemeObject=function(e,t){return void 0===e&&(e={}),void 0===t&&(t={}),{typography:_extends({},e.typography,t.typography),colors:_extends({},e.colors,t.colors),component:_extends({},e.component,t.component)}},isFunction$1=function(e){return"function"==typeof e};function parseValueArray(e,t){var n;Array.isArray(e)?n=[].concat(e):n=Object.keys(e).map((function(t){return e[t]?t:null}));return n.includes(t)?n.filter((function(e){return e!==t})):[].concat(n,[t])}var getComponent=function(e,t){void 0===e&&(e={}),void 0===t&&(t={});var n=(t.$scopedSlots||t.$props).render;return n?n(e):null},hasCustomRenderer=function(e){void 0===e&&(e={});var t=(e.$scopedSlots||e.$props).render;return Boolean(t)},getValidPropsKeys=function(e){return void 0===e&&(e={}),Object.keys(e).filter((function(e){return constants_3$1.includes(e)}))},isEvent=function(e){return!!(e&&e.stopPropagation&&e.preventDefault)},updateDefaultQuery=function(e,t,n,r){defaultQueryUtil(e,_extends({},n,{setDefaultQuery:t}),r)},updateCustomQuery=function(e,t,n,r){customQueryUtil(e,_extends({},n,{setCustomQuery:t}),r)},isQueryIdentical=function(e,t,n,r){return"function"!=typeof e||"function"!=typeof t||isEqual(t(n,r),e(n,r))},getQuerySuggestionsComponent=function(e,t){void 0===e&&(e={}),void 0===t&&(t={});var n=t.$scopedSlots||t.$props,r=n.renderQuerySuggestions,o=n.renderPopularSuggestions||r;return o?o(e):null},hasQuerySuggestionsRenderer=function(e){void 0===e&&(e={});var t=e.$scopedSlots||e.$props,n=t.renderQuerySuggestions,r=t.renderPopularSuggestions;return Boolean(r)||Boolean(n)},getCamelCase=function(e){void 0===e&&(e="");var t=e.split("-").map((function(e,t){return t?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e})).join("");return["u-r-l-params"].includes(e)&&(t=t[0].toUpperCase()+t.substring(1)),t||""},isEmpty=function(e){return!(e&&e.length&&Object.keys(e).length)};function isNumeric(e){return/^-?\d+$/.test(e)}function isHotkeyCombination(e){return"string"==typeof e&&-1!==e.indexOf("+")}function getCharFromCharCode(e){var t=e,n=t-48*Math.floor(t/48);return String.fromCharCode(t>=96?n:t)}function parseFocusShortcuts(e){if(isEmpty(e))return[];var t=[];return e.forEach((function(e){if("string"==typeof e)if(isHotkeyCombination(e)){for(var n,r=e.split("+"),o=[],s=0;s<r.length;s+=1)isNumeric(r[s])?o.push(getCharFromCharCode(+r[s])):o.push(r[s]);n=o.join("+"),t.push(n)}else isNumeric(e)?t.push(getCharFromCharCode(+e)):t.push(e);else t.push(getCharFromCharCode(e))})),t}var MODIFIER_KEYS=["shift","ctrl","alt","control","option","cmd","command"];function extractModifierKeysFromFocusShortcuts(e){return e.filter((function(e){return MODIFIER_KEYS.includes(e)}))}function decodeHtml(e){return"string"!=typeof e?e:e.replace(/&#([0-9]{1,3});/gi,(function(e,t){var n=parseInt(t,10);return String.fromCharCode(n)}))}var addComponent=lib_5.addComponent,removeComponent=lib_5.removeComponent,watchComponent=lib_5.watchComponent,setQueryListener=lib_5.setQueryListener,setComponentProps=lib_5.setComponentProps,updateComponentProps=lib_5.updateComponentProps,pushToAndClause=lib_8.pushToAndClause,checkPropChange=lib_8.checkPropChange,checkSomePropChange=lib_8.checkSomePropChange,ComponentWrapper=function(e,t){return void 0===t&&(t={componentType:null,internalComponent:!1}),{name:"ComponentWrapper",$timestamp:null,props:{destroyOnUnmount:VueTypes.bool.def(!0)},created:function(){var e=_extends({},this.$attrs),t={};Object.keys(e).forEach((function(n){t[getCamelCase(n)]=e[n]})),this.componentProps=t,this.componentId=this.componentProps.componentId,this.react=this.componentProps.react,this.$timestamp=(new Date).getTime()},beforeMount:function(){var e=this,n=[];this.$$store&&(n=this.$$store.getState().components);if(this.destroyOnUnmount||-1===n.indexOf(this.componentProps.componentId)){this.addComponent(this.componentId,this.$timestamp);this.setQueryListener(this.componentId,(function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];e.$emit.apply(e,["queryChange"].concat(n)),e.$emit.apply(e,["query-change"].concat(n))}),(function(t){e.$emit("error",t)})),this.setComponentProps(this.componentId,this.componentProps,t.componentType)}(t.internalComponent||this.componentProps.defaultQuery&&t.componentType===constants_1$1.reactiveComponent)&&(this.internalComponent=transform_11(this.componentId)),this.internalComponent&&(this.destroyOnUnmount||-1===n.indexOf(this.internalComponent))&&(this.addComponent(this.internalComponent,this.$timestamp),this.setComponentProps(this.internalComponent,this.componentProps,t.componentType))},mounted:function(){this.internalComponent&&this.setReact(this.componentProps)},beforeDestroy:function(){if(this.destroyOnUnmount){var e={};if(this.$$store)e=this.$$store.getState().registeredComponentsTimestamps;e[this.componentId]===this.$timestamp&&(this.removeComponent(this.componentId),this.internalComponent&&this.removeComponent(this.internalComponent))}},watch:{$attrs:{deep:!0,handler:function(e){var n=this,r=getValidPropsKeys(e);checkSomePropChange(e,this.savedComponentProps,r,(function(){n.updateComponentProps(n.componentId,e,t.componentType),n.updateComponentProps(n.internalComponent,e,t.componentType)}))}},react:function(e,t){var n=this;checkPropChange(e,t,(function(){return n.setReact(n.componentProps)}))}},methods:{setReact:function(e){var t=e.react,n=e.executeInitialQuery;if(this.internalComponent)if(t){var r=pushToAndClause(t,this.internalComponent);this.watchComponent(e.componentId,r,n)}else this.watchComponent(e.componentId,{and:this.internalComponent},n);else this.watchComponent(e.componentId,t,n)}},render:function(t){return t(e,{attrs:this.$attrs,on:this.$listeners,scopedSlots:this.$scopedSlots,slots:this.$slots})}}},mapStateToProps=function(e,t){return{savedComponentProps:e.props[t.componentId]}},mapDispatchToProps={addComponent:addComponent,removeComponent:removeComponent,setQueryListener:setQueryListener,watchComponent:watchComponent,setComponentProps:setComponentProps,updateComponentProps:updateComponentProps},ComponentWrapper$1=function(e,t){return void 0===t&&(t={}),connect(mapStateToProps,mapDispatchToProps)(ComponentWrapper(e,t))},deepValue=function(e,t){return t.split(".").reduce((function(e,t){return e?e[t]:null}),e)},PreferencesConsumer=function PreferencesConsumer(component){return{name:"PreferencesConsumer",inject:{$searchPreferences:{default:null}},render:function render(h){var _this=this,userProps=Object.keys(this.$attrs).reduce((function(e,t){var n;return _extends({},e,((n={})[getCamelCase(t)]=_this.$attrs[t],n))}),{}),context=this.$searchPreferences;if(!userProps||!userProps.componentId)throw Error("ReactiveSearch: componentId is required");var componentId=userProps.componentId,preferencesPath=userProps.preferencesPath,preferences;context&&(preferences=deepValue(context,preferencesPath||["componentSettings",componentId].join(".")));var componentProps=userProps;return preferences&&(componentProps=preferences.rsConfig?_extends({},preferences.rsConfig,componentProps):_extends({},preferences,componentProps),void 0!==preferences.enabled&&!preferences.enabled)?null:(Object.keys(componentProps).forEach((function(p){"string"==typeof componentProps[p]&&["defaultQuery","customQuery","setOption"].includes(p)&&(componentProps[p]=eval(componentProps[p]))})),h(component,{attrs:componentProps,on:this.$listeners,scopedSlots:this.$scopedSlots,slots:this.$slots}))}}};function _extends$2(){return(_extends$2=Object.assign?Object.assign.bind():function(e){for(var t,n=1;n<arguments.length;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)}var normalMerge=["attrs","props","domProps"],toArrayMerge=["class","style","directives"],functionalMerge=["on","nativeOn"],mergeJsxProps=function(e){return e.reduce((function(e,t){for(var n in t)if(e[n])if(-1!==normalMerge.indexOf(n))e[n]=_extends$2({},e[n],t[n]);else if(-1!==toArrayMerge.indexOf(n)){var r=e[n]instanceof Array?e[n]:[e[n]],o=t[n]instanceof Array?t[n]:[t[n]];e[n]=[].concat(r,o)}else if(-1!==functionalMerge.indexOf(n))for(var s in t[n])if(e[n][s]){var a=e[n][s]instanceof Array?e[n][s]:[e[n][s]],i=t[n][s]instanceof Array?t[n][s]:[t[n][s]];e[n][s]=[].concat(a,i)}else e[n][s]=t[n][s];else if("hook"===n)for(var u in t[n])e[n][u]=e[n][u]?mergeFn(e[n][u],t[n][u]):t[n][u];else e[n]=t[n];else e[n]=t[n];return e}),{})},mergeFn=function(e,t){return function(){e&&e.apply(this,arguments),t&&t.apply(this,arguments)}},helper$1=mergeJsxProps,_templateObject$2,Title=index$1("h2")(_templateObject$2||(_templateObject$2=_taggedTemplateLiteralLoose(["\n\tmargin: 0 0 8px;\n\tfont-size: 1rem;\n\tcolor: ",";\n"])),(function(e){return e.theme.colors.titleColor})),_templateObject$3,_templateObject2$1,_templateObject3$1,_templateObject4$1,container=css(_templateObject$3||(_templateObject$3=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\tflex-direction: column;\n\tmargin: 0;\n\tborder-radius: 0.25rem;\n\toverflow: hidden;\n"]))),smallImage=css(_templateObject2$1||(_templateObject2$1=_taggedTemplateLiteralLoose(["\n\twidth: 100px;\n\theight: 100px;\n"]))),Image=index$1("div")(_templateObject3$1||(_templateObject3$1=_taggedTemplateLiteralLoose(["\n\twidth: 160px;\n\theight: 160px;\n\t",";\n\tmargin: 0;\n\tbackground-size: contain;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n\tbackground-image: ",";\n"])),(function(e){return e.small?smallImage:null}),(function(e){return"url("+e.src+")"})),ListItem=index$1("a")(_templateObject4$1||(_templateObject4$1=_taggedTemplateLiteralLoose(["\n\twidth: 100%;\n\theight: auto;\n\toutline: none;\n\ttext-decoration: none;\n\tborder-radius: 0;\n\tbackground-color: ",";\n\tdisplay: flex;\n\tflex-direction: row;\n\tmargin: 0;\n\tpadding: 10px;\n\tborder-bottom: 1px solid ",";\n\tcolor: ",";\n\t","; all 0.3s ease;\n\n\t&:hover, &:focus {\n\t\tbackground-color: ",";\n\t}\n\n\t&:last-child {\n\t\tborder: 0;\n\t}\n\n\th2 {\n\t\twidth: 100%;\n\t\tline-height: 1.2rem;\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t\tmargin: 0;\n\t\tpadding: 0 0 8px;\n\t}\n\n\tp {\n\t\tmargin: 0;\n\t}\n\n\tarticle {\n\t\twidth: ",";\n\t\tpadding-left: ",";\n\t\tfont-size: 0.9rem;\n\t}\n\n\t&:hover, &:focus {\n\t\tbox-shadow: 0 0 0 0 rgba(0,0,0,0.10);\n\t}\n\n\t@media (max-width: 420px) {\n\t\tmin-width: 0;\n\t\tmargin: 0;\n\t\tborder-radius: 0;\n\t\tbox-shadow: none;\n\t\tborder: 1px solid #eee;\n\n\t\t&:hover, &:focus {\n\t\t\tbox-shadow: 0;\n\t\t}\n\t}\n"])),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fff"}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.3,t.colors.backgroundColor):curriedLighten(.68,t.colors.textColor)}),(function(e){return e.theme.colors.textColor}),(function(e){return e.href?"cursor: pointer":null}),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.2,t.colors.backgroundColor):"#fdfefd"}),(function(e){return e.image?e.small?"calc(100% - 100px)":"calc(100% - 160px)":"100%"}),(function(e){return e.image?"10px":0})),ResultListWrapper={name:"ResultListWrapper",functional:!0,render:function(e,t){var n=t.props,r=t.children,o=arguments[0];return o("div",helper$1([{attrs:{className:container}},n]),[r])}},_templateObject$4,_templateObject2$2,_templateObject3$2;ResultListWrapper.install=function(e){e.component(ResultListWrapper.name,ResultListWrapper)};var container$1=css(_templateObject$4||(_templateObject$4=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\tflex-direction: row;\n\tjustify-content: center;\n\tflex-wrap: wrap;\n\tmargin: 0 -8px;\n\n\t@media (max-width: 420px) {\n\t\tmargin: 0;\n\t}\n"]))),Image$1=index$1("div")(_templateObject2$2||(_templateObject2$2=_taggedTemplateLiteralLoose(["\n\twidth: calc(100% + 20px);\n\theight: 220px;\n\tmargin: -10px -10px 0;\n\tbackground-color: ",";\n\tbackground-size: contain;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n"])),(function(e){return e.theme.colors.backgroundColor||"#fcfcfc"})),Card=index$1("a")(_templateObject3$2||(_templateObject3$2=_taggedTemplateLiteralLoose(["\n\twidth: auto;\n\tflex-grow: 1;\n\toutline: none;\n\ttext-decoration: none;\n\tmin-width: 240px;\n\tmax-width: 250px;\n\tborder-radius: 0.25rem;\n\tbackground-color: ",";\n\theight: 300px;\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\tmargin: 8px;\n\tpadding: 10px;\n\toverflow: hidden;\n\tbox-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.2);\n\tcolor: ",";\n\t",";\n\ttransition: all 0.3s ease;\n\n\th2 {\n\t\twidth: 100%;\n\t\tfont-size: 0.9rem;\n\t\tline-height: 1.2rem;\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t\tmargin: 0;\n\t\tpadding: 10px 0 8px;\n\t}\n\n\tp {\n\t\tmargin: 0;\n\t}\n\n\tarticle {\n\t\tflex-grow: 1;\n\t\tfont-size: 0.9rem;\n\t}\n\n\t&:hover,\n\t&:focus {\n\t\tbox-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.3);\n\t}\n\n\t@media (max-width: 420px) {\n\t\twidth: 50%;\n\t\tmin-width: 0;\n\t\theight: 210px;\n\t\tmargin: 0;\n\t\tborder-radius: 0;\n\t\tbox-shadow: none;\n\t\tborder: 1px solid #eee;\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tbox-shadow: 0;\n\t\t}\n\t}\n"])),(function(e){var t=e.theme;return t.colors.backgroundColor?curriedLighten(.1,t.colors.backgroundColor):"#fff"}),(function(e){return e.theme.colors.textColor}),(function(e){return e.href?"cursor: pointer":null})),ResultCardsWrapper={name:"ResultCardsWrapper",functional:!0,render:function(e,t){var n=t.props,r=t.children,o=arguments[0];return o("div",helper$1([{attrs:{className:container$1}},n]),[r])}},_templateObject$5,_templateObject2$3,_templateObject3$3,_templateObject4$2,_templateObject5$1,_templateObject6$1,_templateObject7$1,_templateObject8$1,_templateObject9,_templateObject10,_templateObject11;ResultCardsWrapper.install=function(e){e.component(ResultCardsWrapper.name,ResultCardsWrapper)};var leftLabel=css(_templateObject$5||(_templateObject$5=_taggedTemplateLiteralLoose(["\n\tflex-direction: row;\n\talign-items: center;\n"]))),rightLabel=css(_templateObject2$3||(_templateObject2$3=_taggedTemplateLiteralLoose(["\n\tflex-direction: row-reverse;\n\talign-items: center;\n"]))),topLabel=css(_templateObject3$3||(_templateObject3$3=_taggedTemplateLiteralLoose(["\n\tflex-direction: column;\n"]))),bottomLabel=css(_templateObject4$2||(_templateObject4$2=_taggedTemplateLiteralLoose(["\n\tflex-direction: column-reverse;\n"]))),border=function(e){var t=e.theme.colors;return css(_templateObject5$1||(_templateObject5$1=_taggedTemplateLiteralLoose(["\n\tborder: 1px solid ",";\n"])),t.borderColor||"#ccc")},Flex=index$1("div")(_templateObject6$1||(_templateObject6$1=_taggedTemplateLiteralLoose(["\n\tdisplay: ",";\n\t",";\n\t",";\n\t",";\n\t",";\n\t",";\n\n\t",";\n\t",";\n\n\t",";\n\t",";\n\t",";\n\n\tsvg.cancel-icon {\n\t\tcursor: pointer;\n\t\tfill: ",";\n\t\tflex-basis: 30px;\n\n\t\t&:hover {\n\t\t\tfill: ",";\n\t\t}\n\t}\n"])),(function(e){return e.inline?"inline-flex":"flex"}),(function(e){return("left"===e.labelPosition||"right"===e.iconPosition)&&leftLabel}),(function(e){return("right"===e.labelPosition||"left"===e.iconPosition)&&rightLabel}),(function(e){return"top"===e.labelPosition&&topLabel}),(function(e){return"bottom"===e.labelPosition&&bottomLabel}),(function(e){return e.showBorder&&border}),(function(e){return e.justifyContent&&css(_templateObject7$1||(_templateObject7$1=_taggedTemplateLiteralLoose(["\n\t\t\tjustify-content: ",";\n\t\t"])),e.justifyContent)}),(function(e){return e.alignItems&&css(_templateObject8$1||(_templateObject8$1=_taggedTemplateLiteralLoose(["\n\t\t\talign-items: ",";\n\t\t"])),e.alignItems)}),(function(e){return e.flex&&css(_templateObject9||(_templateObject9=_taggedTemplateLiteralLoose(["\n\t\t\tflex: ",";\n\t\t"])),e.flex)}),(function(e){return e.direction&&css(_templateObject10||(_templateObject10=_taggedTemplateLiteralLoose(["\n\t\t\tflex-direction: ",";\n\t\t"])),e.direction)}),(function(e){return e.basis&&css(_templateObject11||(_templateObject11=_taggedTemplateLiteralLoose(["\n\t\t\tflex-basis: ",";\n\t\t"])),e.basis)}),(function(e){var t=e.theme.colors;return t.borderColor||curriedLighten(.3,t.textColor)}),(function(e){return e.theme.colors.textColor})),_templateObject$6,_templateObject2$4,resultStats=css(_templateObject$6||(_templateObject$6=_taggedTemplateLiteralLoose(["\n\tflex-grow: 1;\n\tfont-size: 0.82rem;\n"]))),sortOptions=css(_templateObject2$4||(_templateObject2$4=_taggedTemplateLiteralLoose(["\n\tcolor: #424242;\n\theight: 32px;\n\tfont-size: 0.82rem;\n\tpadding: 0 25px 0 10px;\n\tbackground: url(data:image/svg+xml;base64,PHN2ZyBpZD0iTGF5ZXJfMSIgZGF0YS1uYW1lPSJMYXllciAxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0Ljk1IDEwIj48ZGVmcz48c3R5bGU+LmNscy0xe2ZpbGw6I2ZmZjt9LmNscy0ye2ZpbGw6IzQ0NDt9PC9zdHlsZT48L2RlZnM+PHRpdGxlPmFycm93czwvdGl0bGU+PHJlY3QgY2xhc3M9ImNscy0xIiB3aWR0aD0iNC45NSIgaGVpZ2h0PSIxMCIvPjxwb2x5Z29uIGNsYXNzPSJjbHMtMiIgcG9pbnRzPSIxLjQxIDQuNjcgMi40OCAzLjE4IDMuNTQgNC42NyAxLjQxIDQuNjciLz48cG9seWdvbiBjbGFzcz0iY2xzLTIiIHBvaW50cz0iMy41NCA1LjMzIDIuNDggNi44MiAxLjQxIDUuMzMgMy41NCA1LjMzIi8+PC9zdmc+)\n\t\tno-repeat 95% 50%;\n\tbackground-color: #fff;\n\t-moz-appearance: none;\n\t-webkit-appearance: none;\n\tappearance: none;\n\t-webkit-border-radius: 0;\n\tborder-radius: 0;\n\tborder: 0;\n\toutline: 1px solid #ddd;\n\toutline-offset: -1px;\n"]))),recordImpressions=lib_5.recordImpressions,isEqual$1=lib_8.isEqual,debounce=function(e,t){clearTimeout(e._tId),e._tId=setTimeout((function(){e()}),t)},ImpressionTracker={name:"ImpressionTracker",inject:["$$store"],props:{hits:types.hits},created:function(){this.currentHits=[],this.trackedIds={},this.waitingToBeTracked={}},mounted:function(){this.setCurrentHits(this.hits),window&&window.addEventListener("scroll",this.tracker)},destroy:function(){this.clearTrackerInterval()},watch:{hits:function(e,t){if(e&&e!==t){var n=t.map((function(e){return e._id})),r=e.map((function(e){return e._id}));isEqual$1(r,n)||this.setCurrentHits(e)}}},methods:{inViewPort:function(e){var t=e.getBoundingClientRect();return t.top>=0&&t.left>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},setCurrentHits:function(e){this.currentHits=e,this.trackedIds={},e&&e.length&&(this.tracker(),this.setTrackerInterval())},recordImpression:function(){var e=this;if(Object.keys(this.waitingToBeTracked).length){var t=_extends({},this.waitingToBeTracked);Object.keys(t).forEach((function(n){t[n]&&t[n].length&&(e.trackImpressions(n,t[n]),delete e.waitingToBeTracked[n])}))}},addToWaitingList:function(e){var t=this.getQueryId();if(e&&t){var n={id:e._id,index:e._index};this.waitingToBeTracked[t]?this.waitingToBeTracked[t].push(n):this.waitingToBeTracked[t]=[n]}},tracker:function(){var e=this;this.getHitIds().length?(window&&document&&this.getHitIds().forEach((function(t){var n=document.getElementById(t);if(n&&e.inViewPort(n)){var r=e.currentHits.find((function(e){return e._id===t}));e.trackedIds[t]=!0,e.addToWaitingList(r)}})),debounce(this.recordImpression,300)):this.clearTrackerInterval()},setTrackerInterval:function(){this.intervalID=setInterval(this.tracker,1e3)},clearTrackerInterval:function(){this.intervalID&&(clearInterval(this.intervalID),this.intervalID=null)},getQueryId:function(){var e=this.$$store?this.$$store.getState():null;return e?e.analytics.searchId:null},getHitIds:function(){var e=this;return this.currentHits.map((function(e){return e._id})).filter((function(t){return!e.trackedIds[t]}))}},render:function(){return this.$slots.default}},mapDispatchToProps$1={trackImpressions:recordImpressions},ImpressionTracker$1=connect((function(){return null}),mapDispatchToProps$1)(ImpressionTracker),setQueryOptions=lib_5.setQueryOptions,updateQuery=lib_5.updateQuery,loadMore=lib_5.loadMore,setValue=lib_5.setValue,updateComponentProps$1=lib_5.updateComponentProps,setDefaultQuery=lib_5.setDefaultQuery,recordResultClick=lib_5.recordResultClick,isEqual$2=lib_8.isEqual,getQueryOptions=lib_8.getQueryOptions,getClassName$1=lib_8.getClassName,parseHits=lib_8.parseHits,getCompositeAggsQuery=lib_8.getCompositeAggsQuery,getResultStats=lib_8.getResultStats,extractQueryFromCustomQuery=lib_8.extractQueryFromCustomQuery,getOptionsForCustomQuery=lib_8.getOptionsForCustomQuery,ReactiveList={name:"ReactiveList",components:{ResultListWrapper:ResultListWrapper,ResultCardsWrapper:ResultCardsWrapper},data:function(){var e=0,t=this.defaultPage||-1;return t>=0?e=t:this.currentPage&&(e=Math.max(this.currentPage-1,0)),this.__state={from:e*this.size,currentPageState:e},this.__state},created:function(){var e=this,t=this.$props,n=t.distinctField,r=t.distinctFieldConfig,o=t.index;this.pagination&&this.aggregationField&&console.warn("Pagination is not supported when aggregationField is present. The list will be rendered with infinite scroll"),this.enableAppbase&&this.aggregationField&&""!==this.aggregationField&&console.warn("Warning(ReactiveSearch): The `aggregationField` prop has been marked as deprecated, please use the `distinctField` prop instead."),this.enableAppbase||!n&&!r||console.warn("Warning(ReactiveSearch): In order to use the `distinctField` and `distinctFieldConfig` props, the `enableAppbase` prop must be set to true in `ReactiveBase`."),!this.enableAppbase&&o&&console.warn("Warning(ReactiveSearch): In order to use the `index` prop, the `enableAppbase` prop must be set to true in `ReactiveBase`.");var s=this.defaultPage||-1;s>=0&&(this.currentPageState=s,this.from=this.currentPageState*this.$props.size),this.internalComponent=this.$props.componentId+"__internal",this.sortOptionIndex=0,this.defaultSortOption&&this.sortOptions&&Array.isArray(this.sortOptions)&&(this.sortOptionIndex=this.sortOptions.findIndex((function(t){return t.label===e.defaultSortOption}))),this.urlSortOption&&(this.sortOptionIndex=this.$props.sortOptions.findIndex((function(t){return t.label===e.urlSortOption}))||0),this.updateComponentProps(this.componentId,{from:this.from},constants_1$1.reactiveList),this.updateComponentProps(this.internalComponent,{from:this.from},constants_1$1.reactiveList)},props:{currentPage:VueTypes.number.def(0),includeFields:types.includeFields,className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,aggregationField:types.string,aggregationSize:VueTypes.number,defaultQuery:types.func,defaultSortOption:types.string,excludeFields:types.excludeFields,innerClass:types.style,listClass:VueTypes.string.def(""),loader:types.title,render:types.func,renderItem:types.func,renderNoResults:VueTypes.any.def("No Results found."),renderError:types.title,renderResultStats:types.func,pages:VueTypes.number.def(5),pagination:VueTypes.bool.def(!1),infiniteScroll:VueTypes.bool.def(!0),paginationAt:VueTypes.oneOf(["top","bottom","both"]).def("bottom"),react:types.react,scrollOnChange:VueTypes.bool.def(!0),showResultStats:VueTypes.bool.def(!0),showEndPage:VueTypes.bool.def(!1),size:VueTypes.number.def(10),sortBy:types.sortBy,sortOptions:types.sortOptions,URLParams:VueTypes.bool.def(!1),prevLabel:types.string,nextLabel:types.string,distinctField:types.string,distinctFieldConfig:types.props,index:VueTypes.string,endpoint:types.endpointConfig},computed:{shouldRenderPagination:function(){return this.pagination&&!this.aggregationField},totalPages:function(){return Math.ceil(this.total/this.$props.size)||0},hasPageChangeListener:function(){return this.$listeners&&this.$listeners.pageChange},hasResultStatsListener:function(){return this.$listeners&&this.$listeners.resultStats},stats:function(){return _extends({},getResultStats(this),{currentPage:this.currentPageState,displayedResults:this.data.length})},hasCustomRender:function(){return hasCustomRenderer(this)},showInfiniteScroll:function(){return this.infiniteScroll&&!this.shouldRenderPagination},data:function(){var e=parseHits(this.hits)||[],t=parseHits(this.promotedResults)||[],n=e;if(t.length){var r=t.map((function(e){return e._id})).filter(Boolean);r&&(n=n.filter((function(e){return!r.includes(e._id)}))),n=[].concat(t,n)}return helper_15(n)}},watch:{sortOptions:function(e,t){isEqual$2(t,e)||this.updateQueryOptions(this.$props)},sortBy:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},size:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},dataField:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},includeFields:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},excludeFields:function(e,t){t!==e&&this.updateQueryOptions(this.$props)},defaultQuery:function(e,t){if(!isQueryIdentical(e,t,null,this.$props)){var n=getQueryOptions(this.$props);n.from=0,this.$defaultQuery=e(null,this.$props);var r=extractQueryFromCustomQuery(this.$defaultQuery),o=getOptionsForCustomQuery(this.$defaultQuery);o&&(n=_extends({},n,o)),updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props),this.setQueryOptions(this.$props.componentId,_extends({},n,this.getAggsQuery()),!r),this.updateQuery({componentId:this.internalComponent,query:r},!0),this.currentPageState=0,this.from=0}},promotedResults:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},hidden:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},time:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},hits:function(e,t){this.$emit("data",this.getData()),this.shouldRenderPagination?this.isLoading&&(t||e)&&(this.hasPageChangeListener?(this.$emit("pageChange",this.currentPageState+1,this.totalPages),this.$emit("page-change",this.currentPageState+1,this.totalPages)):this.scrollOnChange&&window.scrollTo(0,0)):t&&e&&(t.length===e.length&&e.length!==this.$props.total||e.length<t.length&&(this.scrollOnChange&&window.scrollTo(0,0),this.from=0))},rawData:function(e,t){isEqual$2(e,t)||this.$emit("data",this.getData())},currentPage:function(e,t){t!==e&&e>0&&e<=this.totalPages&&this.setPage(e-1)},infiniteScroll:function(e,t){e!==t&&(e&&!this.pagination?window.addEventListener("scroll",this.scrollHandler):window.removeEventListener("scroll",this.scrollHandler))},pagination:function(e,t){e!==t&&(!e&&this.infiniteScroll?window.addEventListener("scroll",this.scrollHandler):window.removeEventListener("scroll",this.scrollHandler))},defaultPage:function(e,t){this.currentPageState!==e&&t!==e&&this.setPage(e>=0?e:0)}},mounted:function(){this.defaultPage<0&&this.currentPage>0&&this.setPageURL(this.$props.componentId,this.currentPage,this.$props.componentId,!1,this.URLParams);var e=getQueryOptions(this.$props);if(e.from=this.$data.from,this.sortOptions&&this.sortOptions[this.sortOptionIndex]){var t,n=this.sortOptions[this.sortOptionIndex].dataField,r=this.sortOptions[this.sortOptionIndex].sortBy;e.sort=[(t={},t[n]={order:r},t)],this.updateComponentProps(this.componentId,{dataField:n,sortBy:r},constants_1$1.reactiveList)}else if(this.$props.sortBy){var o;e.sort=[(o={},o[this.$props.dataField]={order:this.$props.sortBy},o)]}this.$defaultQuery=null,this.$props.defaultQuery&&(this.$defaultQuery=this.$props.defaultQuery(),e=_extends({},e,getOptionsForCustomQuery(this.$defaultQuery)),updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props));var s=extractQueryFromCustomQuery(this.$defaultQuery);this.setQueryOptions(this.$props.componentId,_extends({},e,this.getAggsQuery()),!1),this.$defaultQuery?this.updateQuery({componentId:this.internalComponent,query:s},!1):this.updateQuery({componentId:this.internalComponent,query:null},!1),this.showInfiniteScroll&&window.addEventListener("scroll",this.scrollHandler)},beforeDestroy:function(){this.showInfiniteScroll&&window.removeEventListener("scroll",this.scrollHandler)},render:function(){var e=arguments[0],t=this.$data.hits,n=parseHits(t)||[];return e("div",{style:this.$props.style,class:this.$props.className},[this.isLoading&&this.shouldRenderPagination&&this.showInfiniteScroll&&(this.$scopedSlots.loader||this.$props.loader),this.renderErrorComponent(),e(Flex,{attrs:{labelPosition:this.sortOptions?"right":"left"},class:getClassName$1(this.$props.innerClass,"resultsInfo")},[this.sortOptions?this.renderSortOptions():null,this.$props.showResultStats&&n.length?this.renderStats():null]),!this.isLoading&&t&&0===t.length?this.renderNoResult():null,!this.shouldRenderPagination||"top"!==this.$props.paginationAt&&"both"!==this.$props.paginationAt?null:e(Pagination,{attrs:{pages:this.$props.pages,totalPages:this.totalPages,currentPage:this.currentPageState,setPage:this.setPage,innerClass:this.$props.innerClass,prevLabel:this.$props.prevLabel,nextLabel:this.$props.nextLabel}}),this.renderResults(),this.isLoading&&!this.shouldRenderPagination?this.$scopedSlots.loader||this.$props.loader||e("div",{style:{textAlign:"center",margin:"20px 0",color:"#666"}},["Loading..."]):null,!this.shouldRenderPagination||"bottom"!==this.$props.paginationAt&&"both"!==this.$props.paginationAt?null:e(Pagination,{attrs:{pages:this.$props.pages,totalPages:Math.ceil(this.$data.total/this.$props.size),currentPage:this.currentPageState,setPage:this.setPage,showEndPage:this.$props.showEndPage,innerClass:this.$props.innerClass,prevLabel:this.$props.prevLabel,nextLabel:this.$props.nextLabel}}),this.url.endsWith("appbase.io")&&n.length?e(Flex,{attrs:{direction:"row-reverse"},class:getClassName$1(this.$props.innerClass,"poweredBy")},[e(PoweredBy)]):null])},methods:{renderErrorComponent:function(){var e=this.$scopedSlots.renderError||this.$props.renderError;return e&&this.error&&!this.isLoading?isFunction$1(e)?e(this.error):e:null},renderResults:function(){var e=this,t=this.$createElement,n=this.$props.size,r=this.$scopedSlots.renderItem||this.$props.renderItem,o=this.hasCustomRender?this.getComponent():t("div",{class:this.$props.listClass+" "+getClassName$1(this.$props.innerClass,"list")},[this.data.map((function(t,o){return r({item:t,count:e.currentPageState*n+o+1,triggerClickAnalytics:function(){return e.triggerClickAnalytics(e.currentPageState*n+o)}})}))]);return this.analytics?t(ImpressionTracker$1,{attrs:{hits:this.data}},[o]):o},updateQueryOptions:function(e){var t=getQueryOptions(e);if(t.from=this.$data.from,e.sortOptions&&Array.isArray(e.sortOptions)){var n,r=e.defaultSortOption?e.sortOptions.findIndex((function(t){return t.label===e.defaultSortOption})):0;if(e.sortOptions[r])t.sort=[(n={},n[e.sortOptions[r].dataField]={order:e.sortOptions[r].sortBy},n)]}else if(e.sortBy){var o;t.sort=[(o={},o[e.dataField]={order:e.sortBy},o)]}this.setQueryOptions(this.$props.componentId,_extends({},t,this.getAggsQuery()),!0)},getAggsQuery:function(){var e=this.$props,t=e.size,n=e.aggregationField,r=this.$data.afterKey,o={size:t};return n&&(o.aggs=getCompositeAggsQuery({props:this.$props,after:r||null,showTopHits:!0}).aggs),o},scrollHandler:function(){!this.isLoading&&window.innerHeight+window.pageYOffset+300>=document.body.scrollHeight&&this.loadMore()},loadMore:function(){if((!this.aggregationField||this.afterKey)&&this.hits&&!this.shouldRenderPagination&&this.total>this.hits.length){var e=this.$data.from+this.$props.size;if(this.hits.length<e)return;var t=_extends({},getQueryOptions(this.$props),this.getAggsQuery());this.from=e,updateDefaultQuery(this.componentId,this.setDefaultQuery,this.$props),this.loadMoreAction(this.$props.componentId,_extends({},t,{from:e}),!0,!!this.aggregationField)}},setPage:function(e){if(e!==this.currentPageState){this.$emit("pageClick",e+1),this.$emit("page-click",e+1);var t=this.$props.size*e,n=getQueryOptions(this.$props);n.from=this.$data.from,this.from=t,this.currentPageState=e,this.loadMoreAction(this.$props.componentId,_extends({},n,{from:t}),!1),this.setPageURL(this.$props.componentId,e+1,this.$props.componentId,!1,this.URLParams)}},renderStats:function(){var e=this.$createElement,t=this.$scopedSlots.renderResultStats||this.$props.renderResultStats;return t&&this.$data.total?t(this.stats):this.stats.numberOfResults?e("p",{class:resultStats+" "+getClassName$1(this.$props.innerClass,"resultStats")},[this.stats.numberOfResults," results found in ",this.stats.time||0,"ms"]):null},renderNoResult:function(){var e=this.$createElement,t=this.$scopedSlots.renderNoResults||this.$props.renderNoResults;return this.$scopedSlots.renderNoResults?isFunction$1(t)?t():t:e("p",{class:getClassName$1(this.$props.innerClass,"noResults")||null},[isFunction$1(t)?t():t])},handleSortChange:function(e){var t=e.target.value;if(this.sortOptions&&this.sortOptions[t]){var n,r=getQueryOptions(this.$props);r.from=0;var o=this.sortOptions[t].dataField,s=this.sortOptions[t].sortBy;r.sort=[(n={},n[o]={order:s},n)],this.sortOptionIndex=t,this.updateComponentProps(this.componentId,{dataField:o,sortBy:s},constants_1$1.reactiveList),this.setQueryOptions(this.$props.componentId,r,!0),this.setPage(0),this.currentPageState=0,this.from=0;var a=this.$props.sortOptions[this.sortOptionIndex]?this.$props.sortOptions[this.sortOptionIndex].label:null;this.setPageURL(this.$props.componentId+"sortOption",a,this.$props.componentId+"sortOption",!1,this.$props.URLParams)}},triggerClickAnalytics:function(e,t){var n=t;if(!n){var r=this.getData().data.find((function(t){return t._click_id===e}));r&&r._id&&(n=r._id)}this.recordResultClick(e,n)},renderSortOptions:function(){var e=this.$createElement;return e("select",{class:sortOptions+" "+getClassName$1(this.$props.innerClass,"sortOptions"),attrs:{name:"sort-options","aria-label":"Sort options"},on:{change:this.handleSortChange},domProps:{value:this.sortOptionIndex}},[this.sortOptions.map((function(t,n){return e("option",{key:t.label,domProps:{value:n}},[t.label])}))])},withClickIds:function(e){var t=this.getAllData().base;return e.map((function(e,n){return _extends({},e,{_click_id:t+n})}))},getAllData:function(){var e=this.size,t=this.promotedResults,n=this.aggregationData,r=this.customData,o=this.currentPage,s=this.hits,a=o*e;return{results:parseHits(s)||[],customData:r||{},promotedResults:parseHits(t)||[],aggregationData:n,loadMore:this.loadMore,base:a,triggerClickAnalytics:this.triggerClickAnalytics}},getData:function(){var e=this.getAllData(),t=e.promotedResults,n=e.aggregationData,r=e.customData;return{data:this.data,aggregationData:this.withClickIds(n||[]),promotedData:this.withClickIds(t||[]),rawData:this.rawData,resultStats:this.stats,customData:r}},getComponent:function(){var e=_extends({error:this.error,loading:this.isLoading||!1,loadMore:this.loadMore,triggerClickAnalytics:this.triggerClickAnalytics,setPage:this.setPage},this.getData());return getComponent(e,this)}}},mapStateToProps$1=function(e,t){return{defaultPage:e.selectedValues[t.componentId]&&e.selectedValues[t.componentId].value-1,urlSortOption:e.selectedValues[t.componentId+"sortOption"]&&e.selectedValues[t.componentId+"sortOption"].value,hits:e.hits[t.componentId]&&e.hits[t.componentId].hits,rawData:e.rawData[t.componentId],aggregationData:e.compositeAggregations[t.componentId],promotedResults:e.promotedResults[t.componentId],customData:e.customData[t.componentId],time:e.hits[t.componentId]&&e.hits[t.componentId].time,total:e.hits[t.componentId]&&e.hits[t.componentId].total,hidden:e.hits[t.componentId]&&e.hits[t.componentId].hidden,analytics:e.config&&e.config.analytics,enableAppbase:e.config.enableAppbase,url:e.config.url,error:e.error[t.componentId],afterKey:e.aggregations[t.componentId]&&e.aggregations[t.componentId][t.aggregationField]&&e.aggregations[t.componentId][t.aggregationField].after_key,componentProps:e.props[t.componentId],isLoading:e.isLoading[t.componentId]}},mapDispatchtoProps={loadMoreAction:loadMore,setPageURL:setValue,setQueryOptions:setQueryOptions,updateQuery:updateQuery,updateComponentProps:updateComponentProps$1,setDefaultQuery:setDefaultQuery,recordResultClick:recordResultClick};ReactiveList.generateQueryOptions=function(e){var t=getQueryOptions(e),n=e.size,r=e.dataField,o=e.defaultSortOption,s=e.sortOptions,a=e.currentPage,i=e.sortBy;t.from=a?(a-1)*(n||10):0,t.size=n||10;if(s)t.sort=[function(){var e;if(o){var t,n=s.find((function(e){return e.label===o}));if(n)return(t={})[n.dataField]={order:n.sortBy},t}return(e={})[s[0].dataField]={order:s[0].sortBy},e}()];else if(i){var u;t.sort=[(u={},u[r]={order:i},u)]}return t},ReactiveList.hasInternalComponent=function(){return!0};var RLConnected=PreferencesConsumer(ComponentWrapper$1(connect(mapStateToProps$1,mapDispatchtoProps)(ReactiveList),{componentType:constants_1$1.reactiveList,internalComponent:ReactiveList.hasInternalComponent()}));function URL$1(e){var t=RegExp("^(([^:/?#]*)?://)?(((.*)?@)?([^/?#]*)?)([^?#]*)(\\?([^#]*))?(#(.*))?"),n=e.match(t);return{protocol:n[2],auth:n[5],host:n[6],path:n[7],query:n[9],hash:n[11]}}RLConnected.name=ReactiveList.name,RLConnected.generateQueryOptions=ReactiveList.generateQueryOptions,RLConnected.hasInternalComponent=ReactiveList.hasInternalComponent,RLConnected.install=function(e){e.component(RLConnected.name,RLConnected),e.component(ResultListWrapper.name,ResultListWrapper),e.component(ResultCardsWrapper.name,ResultCardsWrapper)},RLConnected.componentType=constants_1$1.reactiveList;var urlParserLite=URL$1;function hasOwnProperty(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var decode=function(e,t,n,r){t=t||"&",n=n||"=";var o={};if("string"!=typeof e||0===e.length)return o;var s=/\+/g;e=e.split(t);var a=1e3;r&&"number"==typeof r.maxKeys&&(a=r.maxKeys);var i=e.length;a>0&&i>a&&(i=a);for(var u=0;u<i;++u){var l,c,p,d,h=e[u].replace(s,"%20"),f=h.indexOf(n);f>=0?(l=h.substr(0,f),c=h.substr(f+1)):(l=h,c=""),p=decodeURIComponent(l),d=decodeURIComponent(c),hasOwnProperty(o,p)?Array.isArray(o[p])?o[p].push(d):o[p]=[o[p],d]:o[p]=d}return o},stringifyPrimitive=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}},encode=function(e,t,n,r){return t=t||"&",n=n||"=",null===e&&(e=void 0),"object"==typeof e?Object.keys(e).map((function(r){var o=encodeURIComponent(stringifyPrimitive(r))+n;return Array.isArray(e[r])?e[r].map((function(e){return o+encodeURIComponent(stringifyPrimitive(e))})).join(t):o+encodeURIComponent(stringifyPrimitive(e[r]))})).filter(Boolean).join(t):r?encodeURIComponent(stringifyPrimitive(r))+n+encodeURIComponent(stringifyPrimitive(e)):""},querystring=createCommonjsModule((function(e,t){t.decode=t.parse=decode,t.encode=t.stringify=encode})),querystring_1=querystring.decode,querystring_2=querystring.parse,querystring_3=querystring.encode,querystring_4=querystring.stringify,_typeof$1="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function contains(e,t){return-1!==e.indexOf(t)}function isAppbase(e){return contains(e,"scalr.api.appbase.io")}function btoa$1(){for(var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r=t,o="",s=0,a=0,i=n;r.charAt(0|a)||(i="=",a%1);o+=i.charAt(63&s>>8-a%1*8)){if((e=r.charCodeAt(a+=3/4))>255)throw new Error('"btoa" failed: The string to be encoded contains characters outside of the Latin1 range.');s=s<<8|e}return o}function validateRSQuery(e){if(e&&"[object Array]"===Object.prototype.toString.call(e)){for(var t=0;t<e.length;t+=1){var n=e[t];if(!n)return new Error("query object can not have an empty value");if(!n.id)return new Error("'id' field must be present in query object")}return!0}return new Error("invalid query value, 'query' value must be an array")}function validate(e,t){var n=[],r={object:null,string:"",number:0};Object.keys(t).forEach((function(o){var s=t[o].split("|").find((function(t){return _typeof$1(e[o])===t}));s&&e[o]!==r[s]||n.push(o)}));for(var o="",s=0;s<n.length;s+=1)o+=n[s]+", ";return!(n.length>0)||new Error("fields missing: "+o)}function removeUndefined(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e||0!==Object.keys(e).length||e.constructor!==Object?JSON.parse(JSON.stringify(e)):null}function encodeHeaders(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n={};return t?Object.keys(e).forEach((function(t){n[t]=encodeURI(e[t])})):n=e,n}function getMongoRequest(e,t){var n={};return e&&(n.index=e),t&&(t.db&&(n.db=t.db),t.collection&&(n.collection=t.collection)),n}function getTelemetryHeaders(e,t){var n={};return t?(Object.assign(n,{"X-Search-Client":"Appbase JS"}),!1===e&&Object.assign(n,{"X-Enable-Telemetry":e}),n):n}var backendAlias={MONGODB:"mongodb",ELASTICSEARCH:"elasticsearch"},dataTypes={ARRAY:"array",FUNCTION:"function",OBJECT:"object",NUMBER:"number",BOOLEAN:"boolean",STRING:"string"},checkDataType=function(e){return(void 0===e?"undefined":_typeof$1(e))===dataTypes.OBJECT?Array.isArray(e)?dataTypes.ARRAY:dataTypes.OBJECT:void 0===e?"undefined":_typeof$1(e)};function validateSchema(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=Object.keys(e).filter((function(t){return!!e[t]})),o=Object.keys(t),s=[];o.forEach((function(e){t[e].required&&s.push(e)})),s.forEach((function(e){if(!r.includes(e))throw new Error(e+" is required when using the "+n+" Search backend.")})),r.forEach((function(r){if(!o.includes(r))throw new Error(r+" property isn't accepted property by "+n+" backend.");var s=Array.isArray(t[r].type)?t[r].type:[].concat(t[r].type),a=checkDataType(e[r]);if(!s.includes(a))throw new Error("The property "+r+" is expected with type(s) ["+s.join(", ")+"], but type was set as "+a+".")}))}function isValidHttpUrl(e){var t=void 0;try{t=new URL(e)}catch(e){return!1}return"http:"===t.protocol||"https:"===t.protocol}var mongodb={url:{type:dataTypes.STRING,required:!0},app:{type:dataTypes.STRING,required:!1},credentials:{type:dataTypes.STRING,required:!1},enableTelemetry:{type:dataTypes.BOOLEAN,required:!1},mongodb:{type:dataTypes.OBJECT,required:!0},username:{type:dataTypes.STRING,required:!1},password:{type:dataTypes.STRING,required:!1}},elasticsearch={url:{type:dataTypes.STRING,required:!0},app:{type:dataTypes.STRING,required:!0},credentials:{type:dataTypes.STRING,required:!1},enableTelemetry:{type:dataTypes.BOOLEAN,required:!1},username:{type:dataTypes.STRING,required:!1},password:{type:dataTypes.STRING,required:!1}},SCHEMA={mongodb:mongodb,elasticsearch:elasticsearch};function AppBase(e){var t=urlParserLite((e.endpoint?e.endpoint.url:e.url)||""),n=t.auth,r=void 0===n?null:n,o=t.host,s=void 0===o?"":o,a=t.path,i=void 0===a?"":a,u=t.protocol,l=void 0===u?"":u,c=e.url;"/"===(c=s+i).slice(-1)&&(c=c.slice(0,-1));var p=backendAlias[e.mongodb?"MONGODB":"ELASTICSEARCH"],d=SCHEMA[p];if(e.endpoint&&isValidHttpUrl(e.endpoint.url)&&(d.url.required=!1,d.app.required=!1,d.credentials.required=!1),validateSchema({url:e.url,app:e.app,credentials:e.credentials,username:e.username,password:e.password,enableTelemetry:e.enableTelemetry,mongodb:e.mongodb},d,p),"string"!=typeof l||""===l)throw new Error("Protocol is not present in url. URL should be of the form https://appbase-demo-ansible-abxiydt-arc.searchbase.io");var h=r||null;if("string"==typeof e.credentials&&""!==e.credentials?h=e.credentials:"string"==typeof e.username&&""!==e.username&&"string"==typeof e.password&&""!==e.password&&(h=e.username+":"+e.password),!e.mongodb&&isAppbase(c)&&null===h)throw new Error("Authentication information is not present. Did you add credentials?");this.url=c,this.protocol=l,this.app=e.app,this.credentials=h,e.mongodb&&(this.mongodb=e.mongodb),"boolean"==typeof e.enableTelemetry&&(this.enableTelemetry=e.enableTelemetry)}function fetchRequest(e){var t=this;return new Promise((function(n,r){var o=removeUndefined(e);try{var s=o.method,a=o.path,i=o.params,u=o.body,l=o.isRSAPI,c=o.isSuggestionsAPI,p=o.isMongoRequest,d=void 0!==p&&p,h=c?".suggestions":t.app,f=u,m=a.endsWith("msearch")||a.endsWith("bulk")?"application/x-ndjson":"application/json",g=Object.assign({},{Accept:"application/json","Content-Type":m},e.headers,t.headers),y=Date.now();t.credentials&&(g.Authorization="Basic "+btoa$1(t.credentials));var v={method:s,headers:g};if(Array.isArray(f)){var _="";f.forEach((function(e){_+=JSON.stringify(e),_+="\n"})),f=_}else f=JSON.stringify(f)||{};0!==Object.keys(f).length&&(v.body=f);var b={},$="";i&&($="?"+querystring.stringify(i));var C=d?t.protocol+"://"+t.url:t.protocol+"://"+t.url+"/"+h+"/"+a+$;return function(e){if(t.transformRequest&&"function"==typeof t.transformRequest){var n=t.transformRequest(e);return n instanceof Promise?n:Promise.resolve(n)}return Promise.resolve(e)}(Object.assign({},{url:C},v)).then((function(e){var t=Object.assign({},e),o=t.url;return delete t.url,fetch$1(o||C,Object.assign({},t,{headers:l&&!d?Object.assign({},t.headers,{"x-timestamp":(new Date).getTime()}):t.headers})).then((function(e){return e.status>=500?r(e):(b=e.headers,e.json().then((function(t){if(e.status>=400)return r(e);if(t&&t.error)return r(t);if(l&&t&&"[object Object]"===Object.prototype.toString.call(t)&&u&&u.query&&u.query instanceof Array){var o=0,s=u.query.filter((function(e){return e.execute||void 0===e.execute})).length;if(t&&Object.keys(t).forEach((function(e){t[e]&&Object.prototype.hasOwnProperty.call(t[e],"error")&&t[e].error&&(o+=1)})),o>0&&s===o)return r(t)}if(t&&t.responses instanceof Array&&t.responses.length===t.responses.filter((function(e){return Object.prototype.hasOwnProperty.call(e,"error")})).length)return r(t);var a=Object.assign({},t,{_timestamp:y,_headers:b});return n(a)})).catch((function(e){return r(e)})))})).catch((function(e){return r(e)}))})).catch((function(e){return r(e)}))}catch(e){return r(e)}}))}function indexApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id,a=t.body;delete t.type,delete t.body,delete t.id;var i=void 0;return i=s?o?o+"/"+encodeURIComponent(s):encodeURIComponent(s):o,this.performFetchRequest({method:"POST",path:i,params:t,body:a})}function getApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id;delete t.type,delete t.id;var a=o+"/"+encodeURIComponent(s);return this.performFetchRequest({method:"GET",path:a,params:t})}function updateApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number",body:"object"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id,a=t.body;delete t.type,delete t.id,delete t.body;var i=o+"/"+encodeURIComponent(s)+"/_update";return this.performFetchRequest({method:"POST",path:i,params:t,body:a})}function deleteApi(e){var t=removeUndefined(e),n=validate(t,{id:"string|number"});if(!0!==n)throw n;var r=t.type,o=void 0===r?"_doc":r,s=t.id;delete t.type,delete t.id;var a=o+"/"+encodeURIComponent(s);return this.performFetchRequest({method:"DELETE",path:a,params:t})}function bulkApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=t.type,o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_bulk":"_bulk",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function searchApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=void 0;r=Array.isArray(t.type)?t.type.join():t.type;var o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_search":"_search",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function msearchApi(e){var t=removeUndefined(e),n=validate(t,{body:"object"});if(!0!==n)throw n;var r=void 0;r=Array.isArray(t.type)?t.type.join():t.type;var o=t.body;delete t.type,delete t.body;var s=void 0;return s=r?r+"/_msearch":"_msearch",this.performFetchRequest({method:"POST",path:s,params:t,body:o})}function reactiveSearchApi(e,t,n){var r=removeUndefined(t),o=validateRSQuery(e);if(!0!==o)throw o;var s={settings:r,query:e};return this.mongodb&&Object.assign(s,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch",body:s,headers:getTelemetryHeaders(this.enableTelemetry,!this.mongodb),isRSAPI:!0,isMongoRequest:!!this.mongodb,params:n})}function reactiveSearchv3Api(e,t,n){var r=removeUndefined(t),o=validateRSQuery(e);if(!0!==o)throw o;var s={settings:r,query:e};return this.mongodb&&Object.assign(s,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch.v3",body:s,headers:getTelemetryHeaders(this.enableTelemetry,!this.mongodb),isRSAPI:!0,isMongoRequest:!!this.mongodb,params:n})}function getMappings(){return this.performFetchRequest({method:"GET",path:"_mapping"})}function getSuggestionsv3Api(e,t){var n=removeUndefined(t),r=validateRSQuery(e);if(!0!==r)throw r;var o={settings:n,query:e};return this.mongodb&&Object.assign(o,{mongodb:getMongoRequest(this.app,this.mongodb)}),this.performFetchRequest({method:"POST",path:"_reactivesearch.v3",body:o,headers:getTelemetryHeaders(this.enableTelemetry),isRSAPI:!0,isSuggestionsAPI:!0,isMongoRequest:!!this.mongodb})}function appbasejs(e){var t=new AppBase(e);return AppBase.prototype.performFetchRequest=fetchRequest,AppBase.prototype.index=indexApi,AppBase.prototype.get=getApi,AppBase.prototype.update=updateApi,AppBase.prototype.delete=deleteApi,AppBase.prototype.bulk=bulkApi,AppBase.prototype.search=searchApi,AppBase.prototype.msearch=msearchApi,AppBase.prototype.reactiveSearch=reactiveSearchApi,AppBase.prototype.reactiveSearchv3=reactiveSearchv3Api,AppBase.prototype.getQuerySuggestions=getSuggestionsv3Api,AppBase.prototype.getMappings=getMappings,AppBase.prototype.setHeaders=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.headers=t?encodeHeaders(e):e},"undefined"!=typeof window&&(window.Appbase=t),t}function _extends$3(){return(_extends$3=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function btoa$2(e){void 0===e&&(e="");for(var t,n=e,r="",o=0,s=0,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.charAt(0|s)||(a="=",s%1);r+=a.charAt(63&o>>8-s%1*8)){if((t=n.charCodeAt(s+=3/4))>255)throw new Error('"btoa" failed: The string to be encoded contains characters outside of the Latin1 range.');o=o<<8|t}return r}function validateIndex(e){if(!e)throw new Error("appbase-analytics: A valid index must be present to record analytics events.")}function validateCredentials(e){if(!e)throw new Error("appbase-analytics: Auth credentials is missing.")}function validateURL(e){if(!e)throw new Error("appbase-analytics: URL is missing.")}function validateQuery(e,t){if(null==e&&!t)throw new Error("appbase-analytics: query or queryID must be present to register a click/conversion event")}function validateQueryID(e){if(!e)throw new Error("appbase-analytics: queryID must be present to save search/favorite")}function validateClickObjects(e){if(!e||Object.keys(e).length<1)throw new Error("appbase-analytics: at least one click object must be present to register a click event")}function validateConversionObjects(e){if(!e||Object.keys(e).length<1)throw new Error("appbase-analytics: at least one click object must be present to register a click event")}function initClient(e){void 0===e&&(e={});var t={credentials:e.credentials,index:e.index,url:e.url,userID:e.userID,globalCustomEvents:e.globalCustomEvents,queryID:"",headers:null,_request:function(e,n,r,o,s){var a=_extends$3({user_id:t.userID},r,{custom_events:_extends$3({},r&&r.custom_events,{},t.globalCustomEvents)}),i="";return o&&(i=Object.keys(o).map((function(e){return e+"="+o[e]})).join("&")),fetch$1(t.url+"/"+n+"?"+i,{method:e,headers:_extends$3({},t.headers,{"Content-Type":"application/json",Authorization:"Basic "+btoa$2(t.credentials)}),body:"GET"===e?null:JSON.stringify(a)}).then((function(e){s&&s(null,e)})).catch((function(e){s&&s(e,null)}))}};return validateIndex(t.index),validateCredentials(t.credentials),validateURL(t.url),t.search=function(e,n){validateQuery(e.query,e.queryID);if(t._request){var r={query:e.query,query_id:e.queryID,custom_events:e.customEvents,filters:e.filters,hits:e.hits,impressions:e.impressions};t._request("PUT",t.index+"/_analytics/search",r,null,(function(e,r){r?r.json().then((function(o){o&&o.query_id&&(t.queryID=o.query_id),n&&n(e,r)})).catch((function(e){n&&n(e,r)})):n&&n(e,r)}))}},t.click=function(e,n){if(validateQuery(e.query,e.queryID),validateClickObjects(e.objects),t._request){var r={click_on:e.objects,click_type:e.isSuggestionClick?"suggestion":"result",query:e.query,query_id:e.queryID,custom_events:e.customEvents,meta:e.meta};t._request("PUT",t.index+"/_analytics/click",r,null,n)}},t.conversion=function(e,n){if(validateQuery(null,e.queryID),validateConversionObjects(e.objects),t._request){var r={conversion_on:e.objects,query_id:e.queryID,meta:e.meta};t._request("PUT",t.index+"/_analytics/conversion",r,null,n)}},t.saveSearch=function(e,n){validateQueryID(e.queryID);var r={query_id:e.queryID,save_search_id:e.saveSearchID,save_search_meta:e.saveSearchMeta,user_id:e.userID,custom_events:e.customEvents};t._request("PUT","_analytics/save-search",r,null,n)},t.deleteSavedSearch=function(e,n){t._request("DELETE","_analytics/save-search/"+e,null,null,n)},t.getSavedSearches=function(e,n){t._request&&t._request("GET","_analytics/saved-searches",null,e,n)},t.favorite=function(e,n){if(validateQueryID(e.queryID),!e.favoriteOn||""===e.favoriteOn)throw new Error("appbase-analytics: favoriteOn property is required");if(!e.source)throw new Error("appbase-analytics: source property is required");var r={query_id:e.queryID,favorite_on:e.favoriteOn,source:e.source,id:e.id,meta:e.meta,user_id:e.userID,custom_events:e.customEvents};t._request("PUT","_analytics/favorite",r,null,n)},t.getFavorites=function(e,n){t._request&&t._request("GET","_analytics/favorites",null,e,n)},t.setUserID=function(e){t.userID=e},t.setGlobalCustomEvents=function(e){t.globalCustomEvents=e},t.setHeaders=function(e){t.headers=e},t.getQueryID=function(){return t.queryID},t}var index$2={init:initClient};
14
14
  /**
15
15
  *
16
16
  *
17
17
  * @author Jerry Bendy <jerry@icewingcc.com>
18
18
  * @licence MIT
19
19
  *
20
- */!function(e){var t,n=e.URLSearchParams&&e.URLSearchParams.prototype.get?e.URLSearchParams:null,r=n&&"a=1"===new n({a:1}).toString(),o=n&&"+"===new n("s=%2B").get("s"),s=!n||((t=new n).append("s"," &"),"s=+%26"===t.toString()),a=c.prototype,i=!(!e.Symbol||!e.Symbol.iterator);if(!(n&&r&&o&&s)){a.append=function(e,t){m(this.__URLSearchParams__,e,t)},a.delete=function(e){delete this.__URLSearchParams__[e]},a.get=function(e){var t=this.__URLSearchParams__;return e in t?t[e][0]:null},a.getAll=function(e){var t=this.__URLSearchParams__;return e in t?t[e].slice(0):[]},a.has=function(e){return e in this.__URLSearchParams__},a.set=function(e,t){this.__URLSearchParams__[e]=[""+t]},a.toString=function(){var e,t,n,r,o=this.__URLSearchParams__,s=[];for(t in o)for(n=p(t),e=0,r=o[t];e<r.length;e++)s.push(n+"="+p(r[e]));return s.join("&")};var u=!!o&&n&&!r&&e.Proxy;Object.defineProperty(e,"URLSearchParams",{value:u?new Proxy(n,{construct:function(e,t){return new e(new c(t[0]).toString())}}):c});var l=e.URLSearchParams.prototype;l.polyfill=!0,l.forEach=l.forEach||function(e,t){var n=f(this.toString());Object.getOwnPropertyNames(n).forEach((function(r){n[r].forEach((function(n){e.call(t,n,r,this)}),this)}),this)},l.sort=l.sort||function(){var e,t,n,r=f(this.toString()),o=[];for(e in r)o.push(e);for(o.sort(),t=0;t<o.length;t++)this.delete(o[t]);for(t=0;t<o.length;t++){var s=o[t],a=r[s];for(n=0;n<a.length;n++)this.append(s,a[n])}},l.keys=l.keys||function(){var e=[];return this.forEach((function(t,n){e.push(n)})),h(e)},l.values=l.values||function(){var e=[];return this.forEach((function(t){e.push(t)})),h(e)},l.entries=l.entries||function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),h(e)},i&&(l[e.Symbol.iterator]=l[e.Symbol.iterator]||l.entries)}function c(e){((e=e||"")instanceof URLSearchParams||e instanceof c)&&(e=e.toString()),this.__URLSearchParams__=f(e)}function p(e){var t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'\(\)~]|%20|%00/g,(function(e){return t[e]}))}function d(e){return e.replace(/[ +]/g,"%20").replace(/(%[a-f0-9]{2})+/gi,(function(e){return decodeURIComponent(e)}))}function h(t){var n={next:function(){var e=t.shift();return{done:void 0===e,value:e}}};return i&&(n[e.Symbol.iterator]=function(){return n}),n}function f(e){var t={};if("object"==typeof e)if(g(e))for(var n=0;n<e.length;n++){var r=e[n];if(!g(r)||2!==r.length)throw new TypeError("Failed to construct 'URLSearchParams': Sequence initializer must only contain pair elements");m(t,r[0],r[1])}else for(var o in e)e.hasOwnProperty(o)&&m(t,o,e[o]);else{0===e.indexOf("?")&&(e=e.slice(1));for(var s=e.split("&"),a=0;a<s.length;a++){var i=s[a],u=i.indexOf("=");-1<u?m(t,d(i.slice(0,u)),d(i.slice(u+1))):i&&m(t,d(i),"")}}return t}function m(e,t,n){var r="string"==typeof n?n:null!=n&&"function"==typeof n.toString?n.toString():JSON.stringify(n);t in e?e[t].push(r):e[t]=[r]}function g(e){return!!e&&"[object Array]"===Object.prototype.toString.call(e)}}(void 0!==commonjsGlobal?commonjsGlobal:"undefined"!=typeof window?window:commonjsGlobal);var Provider={name:"Provider",props:{store:{type:Object,required:!0,validator:function(e){if(!e.dispatch&&!e.subscribe&&!e.getState)throw new Error("[reactivesearch-vue] - store provided is not a valid redux store");return!0}},analyticsRef:{type:Object,required:!1}},provide:function(){return{$$store:this.store,$analytics:this.analyticsRef}},render:function(e){return this.$slots.default.length>1?e("div",this.$slots.default):this.$slots.default[0]}},_templateObject$7,Base={functional:!0,render:function(e,t){var n=t.data.attrs.as,r=void 0===n?"div":n,o=t.data,s=t.children;return delete o.attrs.as,e(r,helper$1([{},o]),[s])}},Base$1=index$1(Base)(_templateObject$7||(_templateObject$7=_taggedTemplateLiteralLoose(["\n\tfont-family: ",";\n\tfont-size: ",";\n\tcolor: ",";\n\twidth: 100%;\n\n\tinput,\n\tbutton,\n\ttextarea,\n\tselect {\n\t\tfont-family: ",";\n\t}\n\n\t*,\n\t*:before,\n\t*:after {\n\t\tbox-sizing: border-box;\n\t}\n"])),(function(e){return e.theme.typography.fontFamily}),(function(e){return e.theme.typography.fontSize}),(function(e){return e.theme.colors.textColor}),(function(e){return e.theme.typography.fontFamily})),setHeaders=lib_5.setHeaders,setValue$1=lib_5.setValue,isEqual$3=lib_8.isEqual,URLParamsProvider={name:"URLParamsProvider",props:{className:types.string,headers:types.headers,getSearchParams:types.func,setSearchParams:types.func,as:VueTypes.string.def("div")},mounted:function(){var e=this;this.init(),window.onpopstate=function(){e.init();var t=Array.from(e.params.keys());Object.keys(e.currentSelectedState).filter((function(e){return!t.includes(e)})).forEach((function(t){e.setValue(t,null,void 0,void 0,void 0,void 0,void 0,void 0,"URL")})),Array.from(e.params.entries()).forEach((function(t){try{var n=t[0],r=t[1],o=e.selectedValues[n]||{label:n},s=o.label,a=o.showFilter,i=o.URLParams;e.setValue(n,JSON.parse(r),s,a,i,void 0,void 0,void 0,"URL")}catch(e){console.error(e)}}))}},watch:{$route:function(){this.checkForURLParamsChange()},selectedValues:function(e,t){var n=this;if(!isEqual$3(e,t)){this.searchString=this.$props.getSearchParams?this.$props.getSearchParams():window.location.search,this.params=new URLSearchParams(this.searchString);var r=Object.keys(e),o=Array.from(this.params.keys()),s=!1;r.filter((function(t){return e[t].URLParams})).forEach((function(r){var a=e[r];n.hasValidValue(e[r])||n.hasValidValue(t[r])?a.URLParams?a.category?n.setURL(r,n.getValue({category:a.category,value:a.value}))&&(s=!0):n.setURL(r,n.getValue(a.value))&&(s=!0):(n.params.delete(r),s=!0):!n.hasValidValue(e[r])&&o.includes(r)&&(n.params.delete(r),s=!0)})),Object.keys(e).filter((function(e){return!r.includes(e)})).forEach((function(e){n.params.delete(e),s=!0})),r.length||Array.from(this.params.keys()).forEach((function(e){n.searchComponents&&n.searchComponents.includes(e)&&(n.params.delete(e),s=!0)})),s&&this.pushToHistory()}},headers:function(e,t){isEqual$3(t,e)||this.setHeaders(e)}},methods:{init:function(){this.searchString=this.$props.getSearchParams?this.$props.getSearchParams():window.location.search,this.params=new URLSearchParams(this.searchString),this.currentSelectedState=this.selectedValues||{}},checkForURLParamsChange:function(){var e;window&&((this.$props.getSearchParams?this.$props.getSearchParams():window.location.search)!==this.searchString&&("function"==typeof Event?e=new Event("popstate"):(e=document.createEvent("Event")).initEvent("popstate",!0,!0),window.dispatchEvent(e)))},hasValidValue:function(e){return!!e&&(Array.isArray(e.value)?!!e.value.length:!!e.value)},getValue:function(e){var t=this;return Array.isArray(e)&&e.length?e.map((function(e){return t.getValue(e)})):e&&"object"==typeof e?e.location||e.category?e:e.label||e.key||null:e},setURL:function(e,t){if(!t||"string"==typeof t&&""===t.trim()||Array.isArray(t)&&0===t.length)return this.params.delete(e),!0;var n=JSON.stringify(t);return n!==this.params.get(e)&&(this.params.set(e,n),!0)},pushToHistory:function(){var e=this.params.toString()?"?"+this.params.toString():"",t=""+window.location.href.split("?")[0]+e;this.$props.setSearchParams?this.$props.setSearchParams(t):window.history.pushState&&window.history.pushState({path:t},"",t),this.init()}},render:function(){var e=arguments[0],t=this.$slots.default;return e(Base$1,{attrs:{as:this.$props.as},class:this.$props.className},[t])}},mapStateToProps$2=function(e){return{selectedValues:e.selectedValues,searchComponents:e.components}},mapDispatchtoProps$1={setHeaders:setHeaders,setValue:setValue$1};URLParamsProvider.install=function(e){e.component(URLParamsProvider.name,URLParamsProvider)};var URLParamsProvider$1=connect(mapStateToProps$2,mapDispatchtoProps$1)(URLParamsProvider),typography={fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Noto Sans", "Ubuntu", "Droid Sans", "Helvetica Neue", sans-serif',fontSize:"16px"},light={typography:typography,colors:{textColor:"#424242",primaryTextColor:"#fff",primaryColor:"#0B6AFF",titleColor:"#424242",alertColor:"#d9534f",borderColor:"#595959"}},dark={typography:typography,colors:{textColor:"#fff",backgroundColor:"#212121",primaryTextColor:"#fff",primaryColor:"#2196F3",titleColor:"#fff",alertColor:"#d9534f",borderColor:"#666"}};function getTheme(e){return"light"===e?light:dark}var ReactiveBase={name:"ReactiveBase",data:function(){return this.state={key:"__REACTIVE_BASE__"},this.state},created:function(){this.setStore(this.$props)},mounted:function(){var e=this.enableAppbase,t=this.endpoint;!e&&t&&console.warn("Warning(ReactiveSearch): The `endpoint` prop works only when `enableAppbase` prop is set to true.")},props:{app:types.string,analytics:VueTypes.bool,appbaseConfig:types.appbaseConfig,enableAppbase:VueTypes.bool.def(!1),credentials:types.string,headers:types.headers,queryParams:types.string,theme:VueTypes.object.def({}),themePreset:VueTypes.string.def("light"),type:types.string,url:types.string,mapKey:types.string,initialQueriesSyncTime:types.number,className:types.string,initialState:VueTypes.object.def({}),transformRequest:types.func,transformResponse:types.func,as:VueTypes.string.def("div"),getSearchParams:types.func,setSearchParams:types.func,mongodb:types.mongodb,endpoint:types.endpointConfig,preferences:VueTypes.object},provide:function(){return{theme_reactivesearch:composeThemeObject(getTheme(this.$props.themePreset),this.$props.theme),store:this.store,$searchPreferences:this.preferences}},watch:{app:function(){this.updateState(this.$props)},url:function(){this.updateState(this.$props)},type:function(){this.updateState(this.$props)},credentials:function(){this.updateState(this.$props)},mapKey:function(){this.updateState(this.$props)},headers:function(){this.updateState(this.$props)},appbaseConfig:function(e,t){helper_33(e,t)||this.store&&this.store.dispatch(analytics_3$1(e))},mongodb:function(){this.updateState(this.$props)}},computed:{getHeaders:function(){var e=this.$props,t=e.enableAppbase,n=e.headers,r=e.appbaseConfig,o=e.mongodb,s=e.endpoint,a=(r||{}).enableTelemetry;return _extends({},t&&!o&&_extends({"X-Search-Client":X_SEARCH_CLIENT},!1===a&&{"X-Enable-Telemetry":!1}),n,t&&s&&s.headers&&_extends({},s.headers))}},methods:{updateState:function(e){this.setStore(e),this.key=this.state.key+"-0"},setStore:function(e){var t=e.url&&""!==e.url.trim()&&!e.credentials?null:e.credentials,n=e.url&&""!==e.url.trim()?e.url:"";if(e.enableAppbase&&e.endpoint){if(!e.endpoint.url)throw Error("Error(ReactiveSearch): The `endpoint` prop object requires `url` property.");n=e.endpoint.url}var r={url:n,app:e.app,credentials:t,type:e.type?e.type:"*",transformRequest:e.transformRequest,transformResponse:e.transformResponse,enableAppbase:e.enableAppbase,analytics:e.appbaseConfig?e.appbaseConfig.recordAnalytics:e.analytics,analyticsConfig:e.appbaseConfig,mongodb:e.mongodb,endpoint:e.endpoint},o="";o="undefined"!=typeof window?window.location.search:e.queryParams||"";var s=new URLSearchParams(o),a={},i={};Array.from(s.keys()).forEach((function(e){try{var t,n,r=JSON.parse(s.get(e)),o={};r.value?o.value=r.value:o.value=r,r.category&&(o.category=r.category),o.reference="URL",a=_extends({},a,((t={})[e]=o,t)),i=_extends({},i,((n={})[e]=o.value,n))}catch(e){}}));var u=e.themePreset,l=e.enableAppbase,c=e.endpoint,p=appbasejs(r);p.transformRequest=function(t){var n=l?helper_1(t,c):t;return e.transformRequest?e.transformRequest(n):n},this.$props.transformResponse&&(p.transformResponse=this.$props.transformResponse);var d={url:n&&n.replace(/\/\/.*@/,"//"),credentials:p.credentials,index:p.app||"_default",globalCustomEvents:this.$props.appbaseConfig&&this.$props.appbaseConfig.customEvents};try{if(this.$props.endpoint&&this.$props.endpoint.url){d.url=this.$props.endpoint.url.replace(/\/\/(.*?)\/.*/,"//$1");var h=this.$props.endpoint.headers&&this.$props.endpoint.headers.Authorization;d.credentials=h&&h.replace("Basic ",""),d.credentials=d.credentials&&atob(d.credentials)}}catch(e){console.error("Endpoint not set correctly for analytics"),console.error(e)}var f=null;r.analytics&&(f=index$2.init(d));var m=_extends({config:_extends({},r,{initialQueriesSyncTime:e.initialQueriesSyncTime,initialTimestamp:(new Date).getTime(),mapKey:e.mapKey,themePreset:u}),appbaseRef:p,analyticsRef:f,selectedValues:a,urlValues:i,headers:this.getHeaders},this.$props.initialState);this.store=configureStore(m),this.analyticsRef=f}},render:function(){var e=arguments[0],t=this.$slots.default,n=this.$props,r=n.style,o=n.className;return e(Provider,{attrs:{store:this.store,analyticsRef:this.analyticsRef}},[e(URLParamsProvider$1,{attrs:{as:this.$props.as,headers:this.getHeaders,className:o,getSearchParams:this.getSearchParams,setSearchParams:this.setSearchParams},style:r},[t])])},install:function(e){e.component(ReactiveBase.name,ReactiveBase)}},isff="undefined"!=typeof navigator&&navigator.userAgent.toLowerCase().indexOf("firefox")>0;function addEvent(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r):e.attachEvent&&e.attachEvent("on".concat(t),(function(){n(window.event)}))}function getMods(e,t){for(var n=t.slice(0,t.length-1),r=0;r<n.length;r++)n[r]=e[n[r].toLowerCase()];return n}function getKeys(e){"string"!=typeof e&&(e="");for(var t=(e=e.replace(/\s/g,"")).split(","),n=t.lastIndexOf("");n>=0;)t[n-1]+=",",t.splice(n,1),n=t.lastIndexOf("");return t}function compareArray(e,t){for(var n=e.length>=t.length?e:t,r=e.length>=t.length?t:e,o=!0,s=0;s<n.length;s++)-1===r.indexOf(n[s])&&(o=!1);return o}for(var _keyMap={backspace:8,"⌫":8,tab:9,clear:12,enter:13,"↩":13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":isff?173:189,"=":isff?61:187,";":isff?59:186,"'":222,"[":219,"]":221,"\\":220},_modifier={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,command:91},modifierMap={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},_mods={16:!1,18:!1,17:!1,91:!1},_handlers={},k=1;k<20;k++)_keyMap["f".concat(k)]=111+k;var _downKeys=[],winListendFocus=!1,_scope="all",elementHasBindEvent=[],code=function(e){return _keyMap[e.toLowerCase()]||_modifier[e.toLowerCase()]||e.toUpperCase().charCodeAt(0)},getKey=function(e){return Object.keys(_keyMap).find((function(t){return _keyMap[t]===e}))},getModifier=function(e){return Object.keys(_modifier).find((function(t){return _modifier[t]===e}))};function setScope(e){_scope=e||"all"}function getScope(){return _scope||"all"}function getPressedKeyCodes(){return _downKeys.slice(0)}function getPressedKeyString(){return _downKeys.map((function(e){return getKey(e)||getModifier(e)||String.fromCharCode(e)}))}function filter(e){var t=e.target||e.srcElement,n=t.tagName,r=!0;return!t.isContentEditable&&("INPUT"!==n&&"TEXTAREA"!==n&&"SELECT"!==n||t.readOnly)||(r=!1),r}function isPressed(e){return"string"==typeof e&&(e=code(e)),-1!==_downKeys.indexOf(e)}function deleteScope(e,t){var n,r;for(var o in e||(e=getScope()),_handlers)if(Object.prototype.hasOwnProperty.call(_handlers,o))for(n=_handlers[o],r=0;r<n.length;)n[r].scope===e?n.splice(r,1):r++;getScope()===e&&setScope(t||"all")}function clearModifier(e){var t=e.keyCode||e.which||e.charCode,n=_downKeys.indexOf(t);if(n>=0&&_downKeys.splice(n,1),e.key&&"meta"===e.key.toLowerCase()&&_downKeys.splice(0,_downKeys.length),93!==t&&224!==t||(t=91),t in _mods)for(var r in _mods[t]=!1,_modifier)_modifier[r]===t&&(hotkeys[r]=!1)}function unbind(e){if(void 0===e)Object.keys(_handlers).forEach((function(e){return delete _handlers[e]}));else if(Array.isArray(e))e.forEach((function(e){e.key&&eachUnbind(e)}));else if("object"==typeof e)e.key&&eachUnbind(e);else if("string"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n[0],s=n[1];"function"==typeof o&&(s=o,o=""),eachUnbind({key:e,scope:o,method:s,splitKey:"+"})}}var eachUnbind=function(e){var t=e.key,n=e.scope,r=e.method,o=e.splitKey,s=void 0===o?"+":o;getKeys(t).forEach((function(e){var t=e.split(s),o=t.length,a=t[o-1],i="*"===a?"*":code(a);if(_handlers[i]){n||(n=getScope());var u=o>1?getMods(_modifier,t):[];_handlers[i]=_handlers[i].filter((function(e){return!((!r||e.method===r)&&e.scope===n&&compareArray(e.mods,u))}))}}))};function eventHandler(e,t,n,r){var o;if(t.element===r&&(t.scope===n||"all"===t.scope)){for(var s in o=t.mods.length>0,_mods)Object.prototype.hasOwnProperty.call(_mods,s)&&(!_mods[s]&&t.mods.indexOf(+s)>-1||_mods[s]&&-1===t.mods.indexOf(+s))&&(o=!1);(0!==t.mods.length||_mods[16]||_mods[18]||_mods[17]||_mods[91])&&!o&&"*"!==t.shortcut||!1===t.method(e,t)&&(e.preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation&&e.stopPropagation(),e.cancelBubble&&(e.cancelBubble=!0))}}function dispatch(e,t){var n=_handlers["*"],r=e.keyCode||e.which||e.charCode;if(hotkeys.filter.call(this,e)){if(93!==r&&224!==r||(r=91),-1===_downKeys.indexOf(r)&&229!==r&&_downKeys.push(r),["ctrlKey","altKey","shiftKey","metaKey"].forEach((function(t){var n=modifierMap[t];e[t]&&-1===_downKeys.indexOf(n)?_downKeys.push(n):!e[t]&&_downKeys.indexOf(n)>-1?_downKeys.splice(_downKeys.indexOf(n),1):"metaKey"===t&&e[t]&&3===_downKeys.length&&(e.ctrlKey||e.shiftKey||e.altKey||(_downKeys=_downKeys.slice(_downKeys.indexOf(n))))})),r in _mods){for(var o in _mods[r]=!0,_modifier)_modifier[o]===r&&(hotkeys[o]=!0);if(!n)return}for(var s in _mods)Object.prototype.hasOwnProperty.call(_mods,s)&&(_mods[s]=e[modifierMap[s]]);e.getModifierState&&(!e.altKey||e.ctrlKey)&&e.getModifierState("AltGraph")&&(-1===_downKeys.indexOf(17)&&_downKeys.push(17),-1===_downKeys.indexOf(18)&&_downKeys.push(18),_mods[17]=!0,_mods[18]=!0);var a=getScope();if(n)for(var i=0;i<n.length;i++)n[i].scope===a&&("keydown"===e.type&&n[i].keydown||"keyup"===e.type&&n[i].keyup)&&eventHandler(e,n[i],a,t);if(r in _handlers)for(var u=0;u<_handlers[r].length;u++)if(("keydown"===e.type&&_handlers[r][u].keydown||"keyup"===e.type&&_handlers[r][u].keyup)&&_handlers[r][u].key){for(var l=_handlers[r][u],c=l.splitKey,p=l.key.split(c),d=[],h=0;h<p.length;h++)d.push(code(p[h]));d.sort().join("")===_downKeys.sort().join("")&&eventHandler(e,l,a,t)}}}function isElementBind(e){return elementHasBindEvent.indexOf(e)>-1}function hotkeys(e,t,n){_downKeys=[];var r=getKeys(e),o=[],s="all",a=document,i=0,u=!1,l=!0,c="+",p=!1;for(void 0===n&&"function"==typeof t&&(n=t),"[object Object]"===Object.prototype.toString.call(t)&&(t.scope&&(s=t.scope),t.element&&(a=t.element),t.keyup&&(u=t.keyup),void 0!==t.keydown&&(l=t.keydown),void 0!==t.capture&&(p=t.capture),"string"==typeof t.splitKey&&(c=t.splitKey)),"string"==typeof t&&(s=t);i<r.length;i++)o=[],(e=r[i].split(c)).length>1&&(o=getMods(_modifier,e)),(e="*"===(e=e[e.length-1])?"*":code(e))in _handlers||(_handlers[e]=[]),_handlers[e].push({keyup:u,keydown:l,scope:s,mods:o,shortcut:r[i],method:n,key:r[i],splitKey:c,element:a});void 0!==a&&!isElementBind(a)&&window&&(elementHasBindEvent.push(a),addEvent(a,"keydown",(function(e){dispatch(e,a)}),p),winListendFocus||(winListendFocus=!0,addEvent(window,"focus",(function(){_downKeys=[]}),p)),addEvent(a,"keyup",(function(e){dispatch(e,a),clearModifier(e)}),p))}function trigger(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"all";Object.keys(_handlers).forEach((function(n){_handlers[n].filter((function(n){return n.scope===t&&n.shortcut===e})).forEach((function(e){e&&e.method&&e.method()}))}))}var _api={getPressedKeyString:getPressedKeyString,setScope:setScope,getScope:getScope,deleteScope:deleteScope,getPressedKeyCodes:getPressedKeyCodes,isPressed:isPressed,filter:filter,trigger:trigger,unbind:unbind,keyMap:_keyMap,modifier:_modifier,modifierMap:modifierMap},_templateObject$8;for(var a in _api)Object.prototype.hasOwnProperty.call(_api,a)&&(hotkeys[a]=_api[a]);if("undefined"!=typeof window){var _hotkeys=window.hotkeys;hotkeys.noConflict=function(e){return e&&window.hotkeys===hotkeys&&(window.hotkeys=_hotkeys),hotkeys},window.hotkeys=hotkeys}var InputGroup=index$1("div")(_templateObject$8||(_templateObject$8=_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: stretch;\n width: 100%;\n"]))),_templateObject$9;InputGroup.defaultProps={className:"input-group"};var InputWrapper=index$1("span")(_templateObject$9||(_templateObject$9=_taggedTemplateLiteralLoose(["\n flex: 1;\n position: relative;\n"]))),_templateObject$a,InputAddon=index$1("span")(_templateObject$a||(_templateObject$a=_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #fafafa;\n border: 1px solid #ccc;\n border-radius: 2px;\n color: rgba(0, 0, 0, 0.85);\n font-size: 14px;\n font-weight: 400;\n padding: 0 11px;\n position: relative;\n transition: all 0.3s;\n box-sizing: border-box;\n overflow: hidden;\n\n &:first-of-type {\n border-right: none;\n }\n &:last-of-type {\n border-left: none;\n }\n"]))),_templateObject$b,_templateObject2$5,_templateObject3$4,_templateObject4$3,_templateObject5$2,_templateObject6$2,_templateObject7$2,_templateObject8$2,_templateObject9$1,_templateObject10$1,_templateObject11$1,_templateObject12,_templateObject13,_templateObject14,_templateObject15,_templateObject16;InputAddon.defaultProps={className:"input-addon"};var alertBorder=function(e){var t=e.theme;return css(_templateObject$b||(_templateObject$b=_taggedTemplateLiteralLoose(["\n\tborder: 1px solid ",";\n"])),t.colors.alertColor)},input=css(_templateObject2$5||(_templateObject2$5=_taggedTemplateLiteralLoose(["\n\twidth: 100%;\n\tline-height: 1.5;\n\tmin-height: 42px;\n\tpadding: 8px 12px;\n\tborder: 1px solid #ccc;\n\tbackground-color: #fafafa;\n\tfont-size: 0.9rem;\n\toutline: none;\n\theight: 100%;\n\n\t&:focus {\n\t\tbackground-color: #fff;\n\t}\n"]))),dark$1=function(e){return css(_templateObject3$4||(_templateObject3$4=_taggedTemplateLiteralLoose(["\n\tborder-color: ",";\n"])),e.colors.borderColor)},darkInput=function(e){var t=e.theme;return css(_templateObject4$3||(_templateObject4$3=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: ",";\n\t",";\n\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.backgroundColor,t.colors.textColor,dark$1(t),t.colors.backgroundColor)},Input=index$1("input")(_templateObject5$2||(_templateObject5$2=_taggedTemplateLiteralLoose(["\n\t",";\n\t",";\n\n\t",";\n\n\t",";\n\n\t",";\n\t",";\n\n\t",";\n\n\t",";\n\t",";\n\t",";\n\n\t",";\n"])),input,(function(e){var t=e.themePreset,n=e.theme;return"dark"===t&&darkInput({theme:n})}),(function(e){return e.showIcon&&"left"===e.iconPosition&&css(_templateObject6$2||(_templateObject6$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-left: 36px;\n\t\t"])))}),(function(e){return e.showIcon&&"right"===e.iconPosition&&css(_templateObject7$2||(_templateObject7$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showClear&&css(_templateObject8$2||(_templateObject8$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&css(_templateObject9$1||(_templateObject9$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showClear&&e.showIcon&&"right"===e.iconPosition&&css(_templateObject10$1||(_templateObject10$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&e.showIcon&&"right"===e.iconPosition&&css(_templateObject11$1||(_templateObject11$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&e.showIcon&&css(_templateObject12||(_templateObject12=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showClear&&e.showIcon&&e.showVoiceSearch&&"right"===e.iconPosition&&css(_templateObject13||(_templateObject13=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 90px;\n\t\t"])))}),(function(e){return e.alert&&alertBorder})),suggestions$1=function(e,t){return css(_templateObject14||(_templateObject14=_taggedTemplateLiteralLoose(["\n\tdisplay: block;\n\twidth: 100%;\n\tborder: 1px solid #ccc;\n\tborder-top: none;\n\tbackground-color: #fff;\n\tfont-size: 0.9rem;\n\tz-index: 3;\n\tposition: absolute;\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n\tmax-height: min(100vh, 402px);\n\toverflow-y: auto;\n\n\t&.small {\n\t\ttop: 30px;\n\t}\n\n\tli {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tcursor: pointer;\n\t\tpadding: 10px;\n\t\tuser-select: none;\n\n\t\t& > .trim {\n\t\t\tdisplay: -webkit-box;\n\t\t\tdisplay: block;\n\t\t\twidth: 100%;\n\t\t\tmax-height: 2.3rem;\n\t\t\tline-height: 1.2rem;\n\t\t\t-webkit-line-clamp: 2;\n\t\t\t-webkit-box-orient: vertical;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\twhite-space: nowrap;\n\t\t}\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tbackground-color: #eee;\n\t\t}\n\t}\n\n\t",";\n"])),"dark"===e&&t&&dark$1(t))},suggestionsContainer=css(_templateObject15||(_templateObject15=_taggedTemplateLiteralLoose(["\n\tposition: relative;\n\t.cancel-icon {\n\t\tcursor: pointer;\n\t}\n"]))),noSuggestions=function(e,t){return css(_templateObject16||(_templateObject16=_taggedTemplateLiteralLoose(["\n\tdisplay: block;\n\twidth: 100%;\n\tborder: 1px solid #ccc;\n\tborder-top: none;\n\tbackground-color: #fff;\n\tfont-size: 0.9rem;\n\tz-index: 3;\n\tposition: absolute;\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n\tmax-height: 260px;\n\toverflow-y: auto;\n\n\t&.small {\n\t\ttop: 30px;\n\t}\n\n\tli {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tpadding: 10px;\n\t\tuser-select: none;\n\n\t\t& > .trim {\n\t\t\tdisplay: -webkit-box;\n\t\t\tdisplay: block;\n\t\t\twidth: 100%;\n\t\t\tmax-height: 2.3rem;\n\t\t\tline-height: 1.2rem;\n\t\t\t-webkit-line-clamp: 2;\n\t\t\t-webkit-box-orient: vertical;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\twhite-space: nowrap;\n\t\t}\n\t}\n\n\t","\n"])),"dark"===e&&t&&dark$1(t))},_templateObject$c,_templateObject2$6,_templateObject3$5,_templateObject4$4,IconGroup=index$1("div")(_templateObject$c||(_templateObject$c=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tgrid-gap: 6px;\n\tmargin: 0 10px;\n\theight: 100%;\n\n\t",";\n\n\t",";\n"])),(function(e){return"absolute"===e.positionType?css(_templateObject2$6||(_templateObject2$6=_taggedTemplateLiteralLoose(["\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: 50%;\n\t\t\t\ttransform: translateY(-50%);\n\t\t\t"]))):null}),(function(e){var t=e.groupPosition;return css("right"===t?_templateObject3$5||(_templateObject3$5=_taggedTemplateLiteralLoose(["\n\t\t\t\t\tright: 0;\n\t\t\t "])):_templateObject4$4||(_templateObject4$4=_taggedTemplateLiteralLoose(["\n\t\t\t\t\tleft: 0;\n\t\t\t "])))})),_templateObject$d,IconWrapper=index$1("div")(_templateObject$d||(_templateObject$d=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tmax-width: 23px;\n\twidth: max-content;\n\tcursor: pointer;\n\theight: 100%;min-width:20px;\n\n\tsvg.search-icon {\n\t\tfill: ",";\n\t\ttransform:scale(1.5);\n\t}\n\n\tsvg.cancel-icon {\n\t\tfill: ",";\n\t}\n"])),(function(e){return e.theme.colors.primaryColor}),(function(e){return e.theme.colors.borderColor||"#000"}));function t(e){return"object"==typeof e&&null!=e&&1===e.nodeType}function e(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function n(t,n){if(t.clientHeight<t.scrollHeight||t.clientWidth<t.scrollWidth){var r=getComputedStyle(t,null);return e(r.overflowY,n)||e(r.overflowX,n)||function(e){var t=function(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(t)}return!1}function r(e,t,n,r,o,s,a,i){return s<e&&a>t||s>e&&a<t?0:s<=e&&i<=n||a>=t&&i>=n?s-e-r:a>t&&i<n||s<e&&i>n?a-t+o:0}function computeScrollIntoView(e,o){var s=window,a=o.scrollMode,i=o.block,u=o.inline,l=o.boundary,c=o.skipOverflowHiddenElements,p="function"==typeof l?l:function(e){return e!==l};if(!t(e))throw new TypeError("Invalid target");for(var d=document.scrollingElement||document.documentElement,h=[],f=e;t(f)&&p(f);){if((f=f.parentElement)===d){h.push(f);break}null!=f&&f===document.body&&n(f)&&!n(document.documentElement)||null!=f&&n(f,c)&&h.push(f)}for(var m=s.visualViewport?s.visualViewport.width:innerWidth,g=s.visualViewport?s.visualViewport.height:innerHeight,y=window.scrollX||pageXOffset,v=window.scrollY||pageYOffset,_=e.getBoundingClientRect(),b=_.height,$=_.width,C=_.top,O=_.right,T=_.bottom,S=_.left,w="start"===i||"nearest"===i?C:"end"===i?T:C+b/2,P="center"===u?S+$/2:"end"===u?O:S,E=[],R=0;R<h.length;R++){var k=h[R],I=k.getBoundingClientRect(),x=I.height,A=I.width,L=I.top,j=I.right,V=I.bottom,M=I.left;if("if-needed"===a&&C>=0&&S>=0&&T<=g&&O<=m&&C>=L&&T<=V&&S>=M&&O<=j)return E;var Q=getComputedStyle(k),D=parseInt(Q.borderLeftWidth,10),F=parseInt(Q.borderTopWidth,10),N=parseInt(Q.borderRightWidth,10),q=parseInt(Q.borderBottomWidth,10),B=0,U=0,H="offsetWidth"in k?k.offsetWidth-k.clientWidth-D-N:0,z="offsetHeight"in k?k.offsetHeight-k.clientHeight-F-q:0;if(d===k)B="start"===i?w:"end"===i?w-g:"nearest"===i?r(v,v+g,g,F,q,v+w,v+w+b,b):w-g/2,U="start"===u?P:"center"===u?P-m/2:"end"===u?P-m:r(y,y+m,m,D,N,y+P,y+P+$,$),B=Math.max(0,B+v),U=Math.max(0,U+y);else{B="start"===i?w-L-F:"end"===i?w-V+q+z:"nearest"===i?r(L,V,x,F,q+z,w,w+b,b):w-(L+x/2)+z/2,U="start"===u?P-M-D:"center"===u?P-(M+A/2)+H/2:"end"===u?P-j+N+H:r(M,j,A,D,N+H,P,P+$,$);var W=k.scrollLeft,G=k.scrollTop;w+=G-(B=Math.max(0,Math.min(G+B,k.scrollHeight-x+z))),P+=W-(U=Math.max(0,Math.min(W+U,k.scrollWidth-A+H)))}E.push({el:k,top:B,left:U})}return E}var scrollIntoView=function(e,t){null!==e&&computeScrollIntoView(e,{boundary:t,block:"nearest",scrollMode:"if-needed"}).forEach((function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r}))},Downshift={props:["isOpen","inputValue","selectedItem","highlightedIndex","handleChange","itemToString","handleMouseup"],data:function(){return{isMouseDown:!1,internal_isOpen:!1,internal_inputValue:"",internal_selectedItem:null,internal_highlightedIndex:null}},computed:{mergedState:function(){var e=this;return Object.keys(this.$props).reduce((function(t,n){var r;return _extends({},t,((r={})[n]=e.isControlledProp(n)?e.$props[n]:e["internal_"+n],r))}),{})},internalItemCount:function(){return this.items.length}},mounted:function(){window.addEventListener("mousedown",this.handleWindowMousedown),window.addEventListener("mouseup",this.handleWindowMouseup)},beforeDestroy:function(){window.removeEventListener("mousedown",this.handleWindowMousedown),window.removeEventListener("mouseup",this.handleWindowMouseup)},methods:{handleWindowMousedown:function(){this.isMouseDown=!0},handleWindowMouseup:function(e){this.isMouseDown=!1,e.target!==this.$refs.rootNode&&this.$refs.rootNode.contains(e.target)||!this.mergedState.isOpen||this.isMouseDown||(this.reset(),this.$props.handleMouseup&&this.$props.handleMouseup({isOpen:!1}))},keyDownArrowDown:function(e){e.preventDefault();var t=e.shiftKey?5:1;this.mergedState.isOpen?this.changeHighlightedIndex(t):(this.setState({isOpen:!0}),this.setHighlightedIndex())},keyDownArrowUp:function(e){e.preventDefault();var t=e.shiftKey?-5:-1;this.mergedState.isOpen?this.changeHighlightedIndex(t):(this.setState({isOpen:!0}),this.setHighlightedIndex())},keyDownEnter:function(e){this.mergedState.isOpen&&(e.preventDefault(),this.selectHighlightedItem())},keyDownEscape:function(e){e.preventDefault(),this.reset()},selectHighlightedItem:function(){return this.selectItemAtIndex(this.mergedState.highlightedIndex)},selectItemAtIndex:function(e){var t=this.items[e];null!=t&&this.selectItem(t)},selectItem:function(e){this.$props.handleChange&&this.$props.handleChange(e),this.setState({isOpen:!1,highlightedIndex:null,selectedItem:e,inputValue:function(){return this.isControlledProp("selectedItem")?"":"object"==typeof e?e.label||"":e}.call(this)})},changeHighlightedIndex:function(e){if(!(this.internalItemCount<0)){var t=this.mergedState.highlightedIndex;null===t&&(t=e>0?-1:this.internalItemCount+1);var n=t+e;n<0?n=this.internalItemCount:n>this.internalItemCount&&(n=0),this.setHighlightedIndex(n)}},setHighlightedIndex:function(e){void 0===e&&(e=null),this.setState({highlightedIndex:e});var t=document.getElementById("Downshift"+e);scrollIntoView(t,this.rootNode)},reset:function(){var e=this.mergedState.selectedItem;this.setState({isOpen:!1,highlightedIndex:null,inputValue:e})},getItemProps:function(e){var t=e.index,n=e.item,r=t;return void 0===t?(this.$props.itemToString?this.items.push(this.$props.itemToString(n)):this.items.push(n),r=this.items.indexOf(n)):this.items[r]=n,{id:"Downshift"+r}},getItemEvents:function(e){var t=e.index,n=e.item,r=t;void 0===t&&(r=this.items.indexOf(n));var o=this;return{mouseenter:function(){o.setHighlightedIndex(r)},click:function(e){e.stopPropagation(),o.selectItemAtIndex(r)}}},getInputProps:function(e){var t=e.value,n=this.mergedState.inputValue;return t!==n&&this.setState({inputValue:t}),{value:n}},getButtonProps:function(e){var t=this,n=e.onClick,r=e.onKeyDown,o=e.onKeyUp,s=e.onBlur;return{click:function(e){t.setState({isOpen:!0,inputValue:e.target.value}),n&&n(e)},keydown:function(e){e.key&&t["keyDown"+e.key]&&t["keyDown"+e.key].call(t,e),r&&r(e)},keyup:function(e){o&&o(e)},blur:function(e){s&&s(e)}}},getInputEvents:function(e){var t=this,n=e.onInput,r=e.onBlur,o=e.onFocus,s=e.onKeyPress,a=e.onKeyDown,i=e.onKeyUp;return{input:function(e){t.setState({isOpen:!0,inputValue:e.target.value}),n&&n(e)},focus:function(e){o&&o(e)},keydown:function(e){e.key&&t["keyDown"+e.key]&&t["keyDown"+e.key].call(t,e),a&&a(e)},keypress:function(e){s&&s(e)},keyup:function(e){i&&i(e)},blur:function(e){r&&r(e)},click:e.onClick}},getHelpersAndState:function(){return _extends({getItemProps:this.getItemProps,getItemEvents:this.getItemEvents,getInputProps:this.getInputProps,getInputEvents:this.getInputEvents,getButtonProps:this.getButtonProps,setHighlightedIndex:this.setHighlightedIndex},this.mergedState)},isControlledProp:function(e){return void 0!==this.$props[e]},setState:function(e){var t=this;Object.keys(e).forEach((function(n){t.isControlledProp(n)?(t.$emit(n+"Change",e[n]),t.$emit(n+"-change",e[n])):t["internal_"+n]=e[n]})),this.$emit("stateChange",this.mergedState),this.$emit("state-change",this.mergedState)}},render:function(){var e=arguments[0];return this.items=[],e("div",{ref:"rootNode"},[this.$scopedSlots.default&&this.$scopedSlots.default(_extends({},this.getHelpersAndState()))])}},_templateObject$e,Container=index$1("div")(_templateObject$e||(_templateObject$e=_taggedTemplateLiteralLoose(["\n\t",";\n"])),(function(e){return e.theme.component})),getClassName$2=lib_8.getClassName,SuggestionWrapper={name:"SuggestionWrapper",props:{innerClassName:types.string,themePreset:types.themePreset,innerClass:types.style},render:function(){var e=arguments[0],t=this.$props,n=t.themePreset,r=t.innerClass,o=t.innerClassName;return e("div",{class:noSuggestions(n)+" "+getClassName$2(r,o||"")},[e("li",[this.$scopedSlots.default()])])}},dist=createCommonjsModule((function(e){e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(2);Object.defineProperty(t,"combineChunks",{enumerable:!0,get:function(){return r.combineChunks}}),Object.defineProperty(t,"fillInChunks",{enumerable:!0,get:function(){return r.fillInChunks}}),Object.defineProperty(t,"findAll",{enumerable:!0,get:function(){return r.findAll}}),Object.defineProperty(t,"findChunks",{enumerable:!0,get:function(){return r.findChunks}})},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});t.findAll=function(e){var t=e.autoEscape,s=e.caseSensitive,a=void 0!==s&&s,i=e.findChunks,u=void 0===i?r:i,l=e.sanitize,c=e.searchWords,p=e.textToHighlight;return o({chunksToHighlight:n({chunks:u({autoEscape:t,caseSensitive:a,sanitize:l,searchWords:c,textToHighlight:p})}),totalLength:p?p.length:0})};var n=t.combineChunks=function(e){var t=e.chunks;return t=t.sort((function(e,t){return e.start-t.start})).reduce((function(e,t){if(0===e.length)return[t];var n=e.pop();if(t.start<=n.end){var r=Math.max(n.end,t.end);e.push({highlight:!1,start:n.start,end:r})}else e.push(n,t);return e}),[])},r=function(e){var t=e.autoEscape,n=e.caseSensitive,r=e.sanitize,o=void 0===r?s:r,a=e.searchWords,i=e.textToHighlight;return i=o(i),a.filter((function(e){return e})).reduce((function(e,r){r=o(r),t&&(r=r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"));for(var s=new RegExp(r,n?"g":"gi"),a=void 0;a=s.exec(i);){var u=a.index,l=s.lastIndex;l>u&&e.push({highlight:!1,start:u,end:l}),a.index===s.lastIndex&&s.lastIndex++}return e}),[])};t.findChunks=r;var o=t.fillInChunks=function(e){var t=e.chunksToHighlight,n=e.totalLength,r=[],o=function(e,t,n){t-e>0&&r.push({start:e,end:t,highlight:n})};if(0===t.length)o(0,n,!1);else{var s=0;t.forEach((function(e){o(s,e.start,!1),o(e.start,e.end,!0),s=e.end})),o(s,n,!1)}return r};function s(e){return e}}])}));unwrapExports(dist);var dist_1=dist.findAll;
20
+ */!function(e){var t,n=e.URLSearchParams&&e.URLSearchParams.prototype.get?e.URLSearchParams:null,r=n&&"a=1"===new n({a:1}).toString(),o=n&&"+"===new n("s=%2B").get("s"),s=!n||((t=new n).append("s"," &"),"s=+%26"===t.toString()),a=c.prototype,i=!(!e.Symbol||!e.Symbol.iterator);if(!(n&&r&&o&&s)){a.append=function(e,t){m(this.__URLSearchParams__,e,t)},a.delete=function(e){delete this.__URLSearchParams__[e]},a.get=function(e){var t=this.__URLSearchParams__;return e in t?t[e][0]:null},a.getAll=function(e){var t=this.__URLSearchParams__;return e in t?t[e].slice(0):[]},a.has=function(e){return e in this.__URLSearchParams__},a.set=function(e,t){this.__URLSearchParams__[e]=[""+t]},a.toString=function(){var e,t,n,r,o=this.__URLSearchParams__,s=[];for(t in o)for(n=p(t),e=0,r=o[t];e<r.length;e++)s.push(n+"="+p(r[e]));return s.join("&")};var u=!!o&&n&&!r&&e.Proxy;Object.defineProperty(e,"URLSearchParams",{value:u?new Proxy(n,{construct:function(e,t){return new e(new c(t[0]).toString())}}):c});var l=e.URLSearchParams.prototype;l.polyfill=!0,l.forEach=l.forEach||function(e,t){var n=f(this.toString());Object.getOwnPropertyNames(n).forEach((function(r){n[r].forEach((function(n){e.call(t,n,r,this)}),this)}),this)},l.sort=l.sort||function(){var e,t,n,r=f(this.toString()),o=[];for(e in r)o.push(e);for(o.sort(),t=0;t<o.length;t++)this.delete(o[t]);for(t=0;t<o.length;t++){var s=o[t],a=r[s];for(n=0;n<a.length;n++)this.append(s,a[n])}},l.keys=l.keys||function(){var e=[];return this.forEach((function(t,n){e.push(n)})),h(e)},l.values=l.values||function(){var e=[];return this.forEach((function(t){e.push(t)})),h(e)},l.entries=l.entries||function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),h(e)},i&&(l[e.Symbol.iterator]=l[e.Symbol.iterator]||l.entries)}function c(e){((e=e||"")instanceof URLSearchParams||e instanceof c)&&(e=e.toString()),this.__URLSearchParams__=f(e)}function p(e){var t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'\(\)~]|%20|%00/g,(function(e){return t[e]}))}function d(e){return e.replace(/[ +]/g,"%20").replace(/(%[a-f0-9]{2})+/gi,(function(e){return decodeURIComponent(e)}))}function h(t){var n={next:function(){var e=t.shift();return{done:void 0===e,value:e}}};return i&&(n[e.Symbol.iterator]=function(){return n}),n}function f(e){var t={};if("object"==typeof e)if(g(e))for(var n=0;n<e.length;n++){var r=e[n];if(!g(r)||2!==r.length)throw new TypeError("Failed to construct 'URLSearchParams': Sequence initializer must only contain pair elements");m(t,r[0],r[1])}else for(var o in e)e.hasOwnProperty(o)&&m(t,o,e[o]);else{0===e.indexOf("?")&&(e=e.slice(1));for(var s=e.split("&"),a=0;a<s.length;a++){var i=s[a],u=i.indexOf("=");-1<u?m(t,d(i.slice(0,u)),d(i.slice(u+1))):i&&m(t,d(i),"")}}return t}function m(e,t,n){var r="string"==typeof n?n:null!=n&&"function"==typeof n.toString?n.toString():JSON.stringify(n);t in e?e[t].push(r):e[t]=[r]}function g(e){return!!e&&"[object Array]"===Object.prototype.toString.call(e)}}(void 0!==commonjsGlobal?commonjsGlobal:"undefined"!=typeof window?window:commonjsGlobal);var Provider={name:"Provider",props:{store:{type:Object,required:!0,validator:function(e){if(!e.dispatch&&!e.subscribe&&!e.getState)throw new Error("[reactivesearch-vue] - store provided is not a valid redux store");return!0}},analyticsRef:{type:Object,required:!1}},provide:function(){return{$$store:this.store,$analytics:this.analyticsRef}},render:function(e){return this.$slots.default.length>1?e("div",this.$slots.default):this.$slots.default[0]}},_templateObject$7,Base={functional:!0,render:function(e,t){var n=t.data.attrs.as,r=void 0===n?"div":n,o=t.data,s=t.children;return delete o.attrs.as,e(r,helper$1([{},o]),[s])}},Base$1=index$1(Base)(_templateObject$7||(_templateObject$7=_taggedTemplateLiteralLoose(["\n\tfont-family: ",";\n\tfont-size: ",";\n\tcolor: ",";\n\twidth: 100%;\n\n\tinput,\n\tbutton,\n\ttextarea,\n\tselect {\n\t\tfont-family: ",";\n\t}\n\n\t*,\n\t*:before,\n\t*:after {\n\t\tbox-sizing: border-box;\n\t}\n"])),(function(e){return e.theme.typography.fontFamily}),(function(e){return e.theme.typography.fontSize}),(function(e){return e.theme.colors.textColor}),(function(e){return e.theme.typography.fontFamily})),setHeaders=lib_5.setHeaders,setValue$1=lib_5.setValue,isEqual$3=lib_8.isEqual,URLParamsProvider={name:"URLParamsProvider",props:{className:types.string,headers:types.headers,getSearchParams:types.func,setSearchParams:types.func,as:VueTypes.string.def("div")},mounted:function(){var e=this;this.init(),window.onpopstate=function(){e.init();var t=Array.from(e.params.keys());Object.keys(e.currentSelectedState).filter((function(e){return!t.includes(e)})).forEach((function(t){e.setValue(t,null,void 0,void 0,void 0,void 0,void 0,void 0,"URL")})),Array.from(e.params.entries()).forEach((function(t){try{var n=t[0],r=t[1],o=e.selectedValues[n]||{label:n},s=o.label,a=o.showFilter,i=o.URLParams;e.setValue(n,JSON.parse(r),s,a,i,void 0,void 0,void 0,"URL")}catch(e){console.error(e)}}))}},watch:{$route:function(){this.checkForURLParamsChange()},selectedValues:function(e,t){var n=this;if(!isEqual$3(e,t)){this.searchString=this.$props.getSearchParams?this.$props.getSearchParams():window.location.search,this.params=new URLSearchParams(this.searchString);var r=Object.keys(e),o=Array.from(this.params.keys()),s=!1;r.filter((function(t){return e[t].URLParams})).forEach((function(r){var a=e[r];n.hasValidValue(e[r])||n.hasValidValue(t[r])?a.URLParams?a.category?n.setURL(r,n.getValue({category:a.category,value:a.value}))&&(s=!0):n.setURL(r,n.getValue(a.value))&&(s=!0):(n.params.delete(r),s=!0):!n.hasValidValue(e[r])&&o.includes(r)&&(n.params.delete(r),s=!0)})),Object.keys(e).filter((function(e){return!r.includes(e)})).forEach((function(e){n.params.delete(e),s=!0})),r.length||Array.from(this.params.keys()).forEach((function(e){n.searchComponents&&n.searchComponents.includes(e)&&(n.params.delete(e),s=!0)})),s&&this.pushToHistory()}},headers:function(e,t){isEqual$3(t,e)||this.setHeaders(e)}},methods:{init:function(){this.searchString=this.$props.getSearchParams?this.$props.getSearchParams():window.location.search,this.params=new URLSearchParams(this.searchString),this.currentSelectedState=this.selectedValues||{}},checkForURLParamsChange:function(){var e;window&&((this.$props.getSearchParams?this.$props.getSearchParams():window.location.search)!==this.searchString&&("function"==typeof Event?e=new Event("popstate"):(e=document.createEvent("Event")).initEvent("popstate",!0,!0),window.dispatchEvent(e)))},hasValidValue:function(e){return!!e&&(Array.isArray(e.value)?!!e.value.length:!!e.value)},getValue:function(e){var t=this;return Array.isArray(e)&&e.length?e.map((function(e){return t.getValue(e)})):e&&"object"==typeof e?e.location||e.category?e:e.label||e.key||null:e},setURL:function(e,t){if(!t||"string"==typeof t&&""===t.trim()||Array.isArray(t)&&0===t.length)return this.params.delete(e),!0;var n=JSON.stringify(t);return n!==this.params.get(e)&&(this.params.set(e,n),!0)},pushToHistory:function(){var e=this.params.toString()?"?"+this.params.toString():"",t=""+window.location.href.split("?")[0]+e;this.$props.setSearchParams?this.$props.setSearchParams(t):window.history.pushState&&window.history.pushState({path:t},"",t),this.init()}},render:function(){var e=arguments[0],t=this.$slots.default;return e(Base$1,{attrs:{as:this.$props.as},class:this.$props.className},[t])}},mapStateToProps$2=function(e){return{selectedValues:e.selectedValues,searchComponents:e.components}},mapDispatchtoProps$1={setHeaders:setHeaders,setValue:setValue$1};URLParamsProvider.install=function(e){e.component(URLParamsProvider.name,URLParamsProvider)};var URLParamsProvider$1=connect(mapStateToProps$2,mapDispatchtoProps$1)(URLParamsProvider),typography={fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Noto Sans", "Ubuntu", "Droid Sans", "Helvetica Neue", sans-serif',fontSize:"16px"},light={typography:typography,colors:{textColor:"#424242",primaryTextColor:"#fff",primaryColor:"#0B6AFF",titleColor:"#424242",alertColor:"#d9534f",borderColor:"#595959"}},dark={typography:typography,colors:{textColor:"#fff",backgroundColor:"#212121",primaryTextColor:"#fff",primaryColor:"#2196F3",titleColor:"#fff",alertColor:"#d9534f",borderColor:"#666"}};function getTheme(e){return"light"===e?light:dark}var ReactiveBase={name:"ReactiveBase",data:function(){return this.state={key:"__REACTIVE_BASE__"},this.state},created:function(){this.setStore(this.$props)},mounted:function(){var e=this.enableAppbase,t=this.endpoint;!e&&t&&console.warn("Warning(ReactiveSearch): The `endpoint` prop works only when `enableAppbase` prop is set to true.")},props:{app:types.string,analytics:VueTypes.bool,appbaseConfig:types.appbaseConfig,enableAppbase:VueTypes.bool.def(!1),credentials:types.string,headers:types.headers,theme:VueTypes.object.def({}),themePreset:VueTypes.string.def("light"),type:types.string,url:types.string,mapKey:types.string,initialQueriesSyncTime:types.number,className:types.string,initialState:VueTypes.object.def({}),transformRequest:types.func,transformResponse:types.func,as:VueTypes.string.def("div"),getSearchParams:types.func,setSearchParams:types.func,mongodb:types.mongodb,endpoint:types.endpointConfig,preferences:VueTypes.object},provide:function(){return{theme_reactivesearch:composeThemeObject(getTheme(this.$props.themePreset),this.$props.theme),store:this.store,$searchPreferences:this.preferences}},watch:{app:function(){this.updateState(this.$props)},url:function(){this.updateState(this.$props)},type:function(){this.updateState(this.$props)},credentials:function(){this.updateState(this.$props)},mapKey:function(){this.updateState(this.$props)},headers:function(){this.updateState(this.$props)},appbaseConfig:function(e,t){helper_33(e,t)||this.store&&this.store.dispatch(analytics_3$1(e))},mongodb:function(){this.updateState(this.$props)}},computed:{getHeaders:function(){var e=this.$props,t=e.enableAppbase,n=e.headers,r=e.appbaseConfig,o=e.mongodb,s=e.endpoint,a=(r||{}).enableTelemetry;return _extends({},t&&!o&&_extends({"X-Search-Client":X_SEARCH_CLIENT},!1===a&&{"X-Enable-Telemetry":!1}),n,t&&s&&s.headers&&_extends({},s.headers))}},methods:{updateState:function(e){this.setStore(e),this.key=this.state.key+"-0"},setStore:function(e){var t=e.url&&""!==e.url.trim()&&!e.credentials?null:e.credentials,n=e.url&&""!==e.url.trim()?e.url:"";if(e.enableAppbase&&e.endpoint){if(!e.endpoint.url)throw Error("Error(ReactiveSearch): The `endpoint` prop object requires `url` property.");n=e.endpoint.url}var r={url:n,app:e.app,credentials:t,type:e.type?e.type:"*",transformRequest:e.transformRequest,transformResponse:e.transformResponse,enableAppbase:e.enableAppbase,analytics:e.appbaseConfig?e.appbaseConfig.recordAnalytics:e.analytics,analyticsConfig:e.appbaseConfig,mongodb:e.mongodb,endpoint:e.endpoint},o="";o="undefined"!=typeof window?window.location.search:e.queryParams||"";var s=new URLSearchParams(o),a={},i={};Array.from(s.keys()).forEach((function(e){try{var t,n,r=JSON.parse(s.get(e)),o={};r.value?o.value=r.value:o.value=r,r.category&&(o.category=r.category),o.reference="URL",a=_extends({},a,((t={})[e]=o,t)),i=_extends({},i,((n={})[e]=o.value,n))}catch(e){}}));var u=e.themePreset,l=e.enableAppbase,c=e.endpoint,p=appbasejs(r);p.transformRequest=function(t){var n=l?helper_1(t,c):t;return e.transformRequest?e.transformRequest(n):n},this.$props.transformResponse&&(p.transformResponse=this.$props.transformResponse);var d={url:n&&n.replace(/\/\/.*@/,"//"),credentials:p.credentials,index:p.app||"_default",globalCustomEvents:this.$props.appbaseConfig&&this.$props.appbaseConfig.customEvents};try{if(this.$props.endpoint&&this.$props.endpoint.url){d.url=this.$props.endpoint.url.replace(/\/\/(.*?)\/.*/,"//$1");var h=this.$props.endpoint.headers&&this.$props.endpoint.headers.Authorization;d.credentials=h&&h.replace("Basic ",""),d.credentials=d.credentials&&atob(d.credentials)}}catch(e){console.error("Endpoint not set correctly for analytics"),console.error(e)}var f=null;r.analytics&&(f=index$2.init(d));var m=_extends({config:_extends({},r,{initialQueriesSyncTime:e.initialQueriesSyncTime,initialTimestamp:(new Date).getTime(),mapKey:e.mapKey,themePreset:u}),appbaseRef:p,analyticsRef:f,selectedValues:a,urlValues:i,headers:this.getHeaders},this.$props.initialState);this.store=configureStore(m),this.analyticsRef=f}},render:function(){var e=arguments[0],t=this.$slots.default,n=this.$props,r=n.style,o=n.className;return e(Provider,{attrs:{store:this.store,analyticsRef:this.analyticsRef}},[e(URLParamsProvider$1,{attrs:{as:this.$props.as,headers:this.getHeaders,className:o,getSearchParams:this.getSearchParams,setSearchParams:this.setSearchParams},style:r},[t])])},install:function(e){e.component(ReactiveBase.name,ReactiveBase)}},isff="undefined"!=typeof navigator&&navigator.userAgent.toLowerCase().indexOf("firefox")>0;function addEvent(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r):e.attachEvent&&e.attachEvent("on".concat(t),(function(){n(window.event)}))}function getMods(e,t){for(var n=t.slice(0,t.length-1),r=0;r<n.length;r++)n[r]=e[n[r].toLowerCase()];return n}function getKeys(e){"string"!=typeof e&&(e="");for(var t=(e=e.replace(/\s/g,"")).split(","),n=t.lastIndexOf("");n>=0;)t[n-1]+=",",t.splice(n,1),n=t.lastIndexOf("");return t}function compareArray(e,t){for(var n=e.length>=t.length?e:t,r=e.length>=t.length?t:e,o=!0,s=0;s<n.length;s++)-1===r.indexOf(n[s])&&(o=!1);return o}for(var _keyMap={backspace:8,"⌫":8,tab:9,clear:12,enter:13,"↩":13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":isff?173:189,"=":isff?61:187,";":isff?59:186,"'":222,"[":219,"]":221,"\\":220},_modifier={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,command:91},modifierMap={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},_mods={16:!1,18:!1,17:!1,91:!1},_handlers={},k=1;k<20;k++)_keyMap["f".concat(k)]=111+k;var _downKeys=[],winListendFocus=!1,_scope="all",elementHasBindEvent=[],code=function(e){return _keyMap[e.toLowerCase()]||_modifier[e.toLowerCase()]||e.toUpperCase().charCodeAt(0)},getKey=function(e){return Object.keys(_keyMap).find((function(t){return _keyMap[t]===e}))},getModifier=function(e){return Object.keys(_modifier).find((function(t){return _modifier[t]===e}))};function setScope(e){_scope=e||"all"}function getScope(){return _scope||"all"}function getPressedKeyCodes(){return _downKeys.slice(0)}function getPressedKeyString(){return _downKeys.map((function(e){return getKey(e)||getModifier(e)||String.fromCharCode(e)}))}function filter(e){var t=e.target||e.srcElement,n=t.tagName,r=!0;return!t.isContentEditable&&("INPUT"!==n&&"TEXTAREA"!==n&&"SELECT"!==n||t.readOnly)||(r=!1),r}function isPressed(e){return"string"==typeof e&&(e=code(e)),-1!==_downKeys.indexOf(e)}function deleteScope(e,t){var n,r;for(var o in e||(e=getScope()),_handlers)if(Object.prototype.hasOwnProperty.call(_handlers,o))for(n=_handlers[o],r=0;r<n.length;)n[r].scope===e?n.splice(r,1):r++;getScope()===e&&setScope(t||"all")}function clearModifier(e){var t=e.keyCode||e.which||e.charCode,n=_downKeys.indexOf(t);if(n>=0&&_downKeys.splice(n,1),e.key&&"meta"===e.key.toLowerCase()&&_downKeys.splice(0,_downKeys.length),93!==t&&224!==t||(t=91),t in _mods)for(var r in _mods[t]=!1,_modifier)_modifier[r]===t&&(hotkeys[r]=!1)}function unbind(e){if(void 0===e)Object.keys(_handlers).forEach((function(e){return delete _handlers[e]}));else if(Array.isArray(e))e.forEach((function(e){e.key&&eachUnbind(e)}));else if("object"==typeof e)e.key&&eachUnbind(e);else if("string"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n[0],s=n[1];"function"==typeof o&&(s=o,o=""),eachUnbind({key:e,scope:o,method:s,splitKey:"+"})}}var eachUnbind=function(e){var t=e.key,n=e.scope,r=e.method,o=e.splitKey,s=void 0===o?"+":o;getKeys(t).forEach((function(e){var t=e.split(s),o=t.length,a=t[o-1],i="*"===a?"*":code(a);if(_handlers[i]){n||(n=getScope());var u=o>1?getMods(_modifier,t):[];_handlers[i]=_handlers[i].filter((function(e){return!((!r||e.method===r)&&e.scope===n&&compareArray(e.mods,u))}))}}))};function eventHandler(e,t,n,r){var o;if(t.element===r&&(t.scope===n||"all"===t.scope)){for(var s in o=t.mods.length>0,_mods)Object.prototype.hasOwnProperty.call(_mods,s)&&(!_mods[s]&&t.mods.indexOf(+s)>-1||_mods[s]&&-1===t.mods.indexOf(+s))&&(o=!1);(0!==t.mods.length||_mods[16]||_mods[18]||_mods[17]||_mods[91])&&!o&&"*"!==t.shortcut||!1===t.method(e,t)&&(e.preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation&&e.stopPropagation(),e.cancelBubble&&(e.cancelBubble=!0))}}function dispatch(e,t){var n=_handlers["*"],r=e.keyCode||e.which||e.charCode;if(hotkeys.filter.call(this,e)){if(93!==r&&224!==r||(r=91),-1===_downKeys.indexOf(r)&&229!==r&&_downKeys.push(r),["ctrlKey","altKey","shiftKey","metaKey"].forEach((function(t){var n=modifierMap[t];e[t]&&-1===_downKeys.indexOf(n)?_downKeys.push(n):!e[t]&&_downKeys.indexOf(n)>-1?_downKeys.splice(_downKeys.indexOf(n),1):"metaKey"===t&&e[t]&&3===_downKeys.length&&(e.ctrlKey||e.shiftKey||e.altKey||(_downKeys=_downKeys.slice(_downKeys.indexOf(n))))})),r in _mods){for(var o in _mods[r]=!0,_modifier)_modifier[o]===r&&(hotkeys[o]=!0);if(!n)return}for(var s in _mods)Object.prototype.hasOwnProperty.call(_mods,s)&&(_mods[s]=e[modifierMap[s]]);e.getModifierState&&(!e.altKey||e.ctrlKey)&&e.getModifierState("AltGraph")&&(-1===_downKeys.indexOf(17)&&_downKeys.push(17),-1===_downKeys.indexOf(18)&&_downKeys.push(18),_mods[17]=!0,_mods[18]=!0);var a=getScope();if(n)for(var i=0;i<n.length;i++)n[i].scope===a&&("keydown"===e.type&&n[i].keydown||"keyup"===e.type&&n[i].keyup)&&eventHandler(e,n[i],a,t);if(r in _handlers)for(var u=0;u<_handlers[r].length;u++)if(("keydown"===e.type&&_handlers[r][u].keydown||"keyup"===e.type&&_handlers[r][u].keyup)&&_handlers[r][u].key){for(var l=_handlers[r][u],c=l.splitKey,p=l.key.split(c),d=[],h=0;h<p.length;h++)d.push(code(p[h]));d.sort().join("")===_downKeys.sort().join("")&&eventHandler(e,l,a,t)}}}function isElementBind(e){return elementHasBindEvent.indexOf(e)>-1}function hotkeys(e,t,n){_downKeys=[];var r=getKeys(e),o=[],s="all",a=document,i=0,u=!1,l=!0,c="+",p=!1;for(void 0===n&&"function"==typeof t&&(n=t),"[object Object]"===Object.prototype.toString.call(t)&&(t.scope&&(s=t.scope),t.element&&(a=t.element),t.keyup&&(u=t.keyup),void 0!==t.keydown&&(l=t.keydown),void 0!==t.capture&&(p=t.capture),"string"==typeof t.splitKey&&(c=t.splitKey)),"string"==typeof t&&(s=t);i<r.length;i++)o=[],(e=r[i].split(c)).length>1&&(o=getMods(_modifier,e)),(e="*"===(e=e[e.length-1])?"*":code(e))in _handlers||(_handlers[e]=[]),_handlers[e].push({keyup:u,keydown:l,scope:s,mods:o,shortcut:r[i],method:n,key:r[i],splitKey:c,element:a});void 0!==a&&!isElementBind(a)&&window&&(elementHasBindEvent.push(a),addEvent(a,"keydown",(function(e){dispatch(e,a)}),p),winListendFocus||(winListendFocus=!0,addEvent(window,"focus",(function(){_downKeys=[]}),p)),addEvent(a,"keyup",(function(e){dispatch(e,a),clearModifier(e)}),p))}function trigger(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"all";Object.keys(_handlers).forEach((function(n){_handlers[n].filter((function(n){return n.scope===t&&n.shortcut===e})).forEach((function(e){e&&e.method&&e.method()}))}))}var _api={getPressedKeyString:getPressedKeyString,setScope:setScope,getScope:getScope,deleteScope:deleteScope,getPressedKeyCodes:getPressedKeyCodes,isPressed:isPressed,filter:filter,trigger:trigger,unbind:unbind,keyMap:_keyMap,modifier:_modifier,modifierMap:modifierMap},_templateObject$8;for(var a in _api)Object.prototype.hasOwnProperty.call(_api,a)&&(hotkeys[a]=_api[a]);if("undefined"!=typeof window){var _hotkeys=window.hotkeys;hotkeys.noConflict=function(e){return e&&window.hotkeys===hotkeys&&(window.hotkeys=_hotkeys),hotkeys},window.hotkeys=hotkeys}var InputGroup=index$1("div")(_templateObject$8||(_templateObject$8=_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: stretch;\n width: 100%;\n"]))),_templateObject$9;InputGroup.defaultProps={className:"input-group"};var InputWrapper=index$1("span")(_templateObject$9||(_templateObject$9=_taggedTemplateLiteralLoose(["\n flex: 1;\n position: relative;\n"]))),_templateObject$a,InputAddon=index$1("span")(_templateObject$a||(_templateObject$a=_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #fafafa;\n border: 1px solid #ccc;\n border-radius: 2px;\n color: rgba(0, 0, 0, 0.85);\n font-size: 14px;\n font-weight: 400;\n padding: 0 11px;\n position: relative;\n transition: all 0.3s;\n box-sizing: border-box;\n overflow: hidden;\n\n &:first-of-type {\n border-right: none;\n }\n &:last-of-type {\n border-left: none;\n }\n"]))),_templateObject$b,_templateObject2$5,_templateObject3$4,_templateObject4$3,_templateObject5$2,_templateObject6$2,_templateObject7$2,_templateObject8$2,_templateObject9$1,_templateObject10$1,_templateObject11$1,_templateObject12,_templateObject13,_templateObject14,_templateObject15,_templateObject16;InputAddon.defaultProps={className:"input-addon"};var alertBorder=function(e){var t=e.theme;return css(_templateObject$b||(_templateObject$b=_taggedTemplateLiteralLoose(["\n\tborder: 1px solid ",";\n"])),t.colors.alertColor)},input=css(_templateObject2$5||(_templateObject2$5=_taggedTemplateLiteralLoose(["\n\twidth: 100%;\n\tline-height: 1.5;\n\tmin-height: 42px;\n\tpadding: 8px 12px;\n\tborder: 1px solid #ccc;\n\tbackground-color: #fafafa;\n\tfont-size: 0.9rem;\n\toutline: none;\n\theight: 100%;\n\n\t&:focus {\n\t\tbackground-color: #fff;\n\t}\n"]))),dark$1=function(e){return css(_templateObject3$4||(_templateObject3$4=_taggedTemplateLiteralLoose(["\n\tborder-color: ",";\n"])),e.colors.borderColor)},darkInput=function(e){var t=e.theme;return css(_templateObject4$3||(_templateObject4$3=_taggedTemplateLiteralLoose(["\n\tbackground-color: ",";\n\tcolor: ",";\n\t",";\n\n\t&:focus {\n\t\tbackground-color: ",";\n\t}\n"])),t.colors.backgroundColor,t.colors.textColor,dark$1(t),t.colors.backgroundColor)},Input=index$1("input")(_templateObject5$2||(_templateObject5$2=_taggedTemplateLiteralLoose(["\n\t",";\n\t",";\n\n\t",";\n\n\t",";\n\n\t",";\n\t",";\n\n\t",";\n\n\t",";\n\t",";\n\t",";\n\n\t",";\n"])),input,(function(e){var t=e.themePreset,n=e.theme;return"dark"===t&&darkInput({theme:n})}),(function(e){return e.showIcon&&"left"===e.iconPosition&&css(_templateObject6$2||(_templateObject6$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-left: 36px;\n\t\t"])))}),(function(e){return e.showIcon&&"right"===e.iconPosition&&css(_templateObject7$2||(_templateObject7$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showClear&&css(_templateObject8$2||(_templateObject8$2=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&css(_templateObject9$1||(_templateObject9$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 36px;\n\t\t"])))}),(function(e){return e.showClear&&e.showIcon&&"right"===e.iconPosition&&css(_templateObject10$1||(_templateObject10$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&e.showIcon&&"right"===e.iconPosition&&css(_templateObject11$1||(_templateObject11$1=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showVoiceSearch&&e.showIcon&&css(_templateObject12||(_templateObject12=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 66px;\n\t\t"])))}),(function(e){return e.showClear&&e.showIcon&&e.showVoiceSearch&&"right"===e.iconPosition&&css(_templateObject13||(_templateObject13=_taggedTemplateLiteralLoose(["\n\t\t\tpadding-right: 90px;\n\t\t"])))}),(function(e){return e.alert&&alertBorder})),suggestions$1=function(e,t){return css(_templateObject14||(_templateObject14=_taggedTemplateLiteralLoose(["\n\tdisplay: block;\n\twidth: 100%;\n\tborder: 1px solid #ccc;\n\tborder-top: none;\n\tbackground-color: #fff;\n\tfont-size: 0.9rem;\n\tz-index: 3;\n\tposition: absolute;\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n\tmax-height: min(100vh, 402px);\n\toverflow-y: auto;\n\n\t&.small {\n\t\ttop: 30px;\n\t}\n\n\tli {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tcursor: pointer;\n\t\tpadding: 10px;\n\t\tuser-select: none;\n\n\t\t& > .trim {\n\t\t\tdisplay: -webkit-box;\n\t\t\tdisplay: block;\n\t\t\twidth: 100%;\n\t\t\tmax-height: 2.3rem;\n\t\t\tline-height: 1.2rem;\n\t\t\t-webkit-line-clamp: 2;\n\t\t\t-webkit-box-orient: vertical;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\twhite-space: nowrap;\n\t\t}\n\n\t\t&:hover,\n\t\t&:focus {\n\t\t\tbackground-color: #eee;\n\t\t}\n\t}\n\n\t",";\n"])),"dark"===e&&t&&dark$1(t))},suggestionsContainer=css(_templateObject15||(_templateObject15=_taggedTemplateLiteralLoose(["\n\tposition: relative;\n\t.cancel-icon {\n\t\tcursor: pointer;\n\t}\n"]))),noSuggestions=function(e,t){return css(_templateObject16||(_templateObject16=_taggedTemplateLiteralLoose(["\n\tdisplay: block;\n\twidth: 100%;\n\tborder: 1px solid #ccc;\n\tborder-top: none;\n\tbackground-color: #fff;\n\tfont-size: 0.9rem;\n\tz-index: 3;\n\tposition: absolute;\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n\tmax-height: 260px;\n\toverflow-y: auto;\n\n\t&.small {\n\t\ttop: 30px;\n\t}\n\n\tli {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tpadding: 10px;\n\t\tuser-select: none;\n\n\t\t& > .trim {\n\t\t\tdisplay: -webkit-box;\n\t\t\tdisplay: block;\n\t\t\twidth: 100%;\n\t\t\tmax-height: 2.3rem;\n\t\t\tline-height: 1.2rem;\n\t\t\t-webkit-line-clamp: 2;\n\t\t\t-webkit-box-orient: vertical;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t\twhite-space: nowrap;\n\t\t}\n\t}\n\n\t","\n"])),"dark"===e&&t&&dark$1(t))},_templateObject$c,_templateObject2$6,_templateObject3$5,_templateObject4$4,IconGroup=index$1("div")(_templateObject$c||(_templateObject$c=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tgrid-gap: 6px;\n\tmargin: 0 10px;\n\theight: 100%;\n\n\t",";\n\n\t",";\n"])),(function(e){return"absolute"===e.positionType?css(_templateObject2$6||(_templateObject2$6=_taggedTemplateLiteralLoose(["\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: 50%;\n\t\t\t\ttransform: translateY(-50%);\n\t\t\t"]))):null}),(function(e){var t=e.groupPosition;return css("right"===t?_templateObject3$5||(_templateObject3$5=_taggedTemplateLiteralLoose(["\n\t\t\t\t\tright: 0;\n\t\t\t "])):_templateObject4$4||(_templateObject4$4=_taggedTemplateLiteralLoose(["\n\t\t\t\t\tleft: 0;\n\t\t\t "])))})),_templateObject$d,IconWrapper=index$1("div")(_templateObject$d||(_templateObject$d=_taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tmax-width: 23px;\n\twidth: max-content;\n\tcursor: pointer;\n\theight: 100%;min-width:20px;\n\n\tsvg.search-icon {\n\t\tfill: ",";\n\t\ttransform:scale(1.5);\n\t}\n\n\tsvg.cancel-icon {\n\t\tfill: ",";\n\t}\n"])),(function(e){return e.theme.colors.primaryColor}),(function(e){return e.theme.colors.borderColor||"#000"}));function t(e){return"object"==typeof e&&null!=e&&1===e.nodeType}function e(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function n(t,n){if(t.clientHeight<t.scrollHeight||t.clientWidth<t.scrollWidth){var r=getComputedStyle(t,null);return e(r.overflowY,n)||e(r.overflowX,n)||function(e){var t=function(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(t)}return!1}function r(e,t,n,r,o,s,a,i){return s<e&&a>t||s>e&&a<t?0:s<=e&&i<=n||a>=t&&i>=n?s-e-r:a>t&&i<n||s<e&&i>n?a-t+o:0}function computeScrollIntoView(e,o){var s=window,a=o.scrollMode,i=o.block,u=o.inline,l=o.boundary,c=o.skipOverflowHiddenElements,p="function"==typeof l?l:function(e){return e!==l};if(!t(e))throw new TypeError("Invalid target");for(var d=document.scrollingElement||document.documentElement,h=[],f=e;t(f)&&p(f);){if((f=f.parentElement)===d){h.push(f);break}null!=f&&f===document.body&&n(f)&&!n(document.documentElement)||null!=f&&n(f,c)&&h.push(f)}for(var m=s.visualViewport?s.visualViewport.width:innerWidth,g=s.visualViewport?s.visualViewport.height:innerHeight,y=window.scrollX||pageXOffset,v=window.scrollY||pageYOffset,_=e.getBoundingClientRect(),b=_.height,$=_.width,C=_.top,O=_.right,T=_.bottom,S=_.left,w="start"===i||"nearest"===i?C:"end"===i?T:C+b/2,P="center"===u?S+$/2:"end"===u?O:S,E=[],R=0;R<h.length;R++){var k=h[R],I=k.getBoundingClientRect(),x=I.height,A=I.width,L=I.top,j=I.right,V=I.bottom,M=I.left;if("if-needed"===a&&C>=0&&S>=0&&T<=g&&O<=m&&C>=L&&T<=V&&S>=M&&O<=j)return E;var Q=getComputedStyle(k),D=parseInt(Q.borderLeftWidth,10),F=parseInt(Q.borderTopWidth,10),N=parseInt(Q.borderRightWidth,10),q=parseInt(Q.borderBottomWidth,10),B=0,U=0,H="offsetWidth"in k?k.offsetWidth-k.clientWidth-D-N:0,z="offsetHeight"in k?k.offsetHeight-k.clientHeight-F-q:0;if(d===k)B="start"===i?w:"end"===i?w-g:"nearest"===i?r(v,v+g,g,F,q,v+w,v+w+b,b):w-g/2,U="start"===u?P:"center"===u?P-m/2:"end"===u?P-m:r(y,y+m,m,D,N,y+P,y+P+$,$),B=Math.max(0,B+v),U=Math.max(0,U+y);else{B="start"===i?w-L-F:"end"===i?w-V+q+z:"nearest"===i?r(L,V,x,F,q+z,w,w+b,b):w-(L+x/2)+z/2,U="start"===u?P-M-D:"center"===u?P-(M+A/2)+H/2:"end"===u?P-j+N+H:r(M,j,A,D,N+H,P,P+$,$);var W=k.scrollLeft,G=k.scrollTop;w+=G-(B=Math.max(0,Math.min(G+B,k.scrollHeight-x+z))),P+=W-(U=Math.max(0,Math.min(W+U,k.scrollWidth-A+H)))}E.push({el:k,top:B,left:U})}return E}var scrollIntoView=function(e,t){null!==e&&computeScrollIntoView(e,{boundary:t,block:"nearest",scrollMode:"if-needed"}).forEach((function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r}))},Downshift={props:["isOpen","inputValue","selectedItem","highlightedIndex","handleChange","itemToString","handleMouseup"],data:function(){return{isMouseDown:!1,internal_isOpen:!1,internal_inputValue:"",internal_selectedItem:null,internal_highlightedIndex:null}},computed:{mergedState:function(){var e=this;return Object.keys(this.$props).reduce((function(t,n){var r;return _extends({},t,((r={})[n]=e.isControlledProp(n)?e.$props[n]:e["internal_"+n],r))}),{})},internalItemCount:function(){return this.items.length}},mounted:function(){window.addEventListener("mousedown",this.handleWindowMousedown),window.addEventListener("mouseup",this.handleWindowMouseup)},beforeDestroy:function(){window.removeEventListener("mousedown",this.handleWindowMousedown),window.removeEventListener("mouseup",this.handleWindowMouseup)},methods:{handleWindowMousedown:function(){this.isMouseDown=!0},handleWindowMouseup:function(e){this.isMouseDown=!1,e.target!==this.$refs.rootNode&&this.$refs.rootNode.contains(e.target)||!this.mergedState.isOpen||this.isMouseDown||(this.reset(),this.$props.handleMouseup&&this.$props.handleMouseup({isOpen:!1}))},keyDownArrowDown:function(e){e.preventDefault();var t=e.shiftKey?5:1;this.mergedState.isOpen?this.changeHighlightedIndex(t):(this.setState({isOpen:!0}),this.setHighlightedIndex())},keyDownArrowUp:function(e){e.preventDefault();var t=e.shiftKey?-5:-1;this.mergedState.isOpen?this.changeHighlightedIndex(t):(this.setState({isOpen:!0}),this.setHighlightedIndex())},keyDownEnter:function(e){this.mergedState.isOpen&&(e.preventDefault(),this.selectHighlightedItem())},keyDownEscape:function(e){e.preventDefault(),this.reset()},selectHighlightedItem:function(){return this.selectItemAtIndex(this.mergedState.highlightedIndex)},selectItemAtIndex:function(e){var t=this.items[e];null!=t&&this.selectItem(t)},selectItem:function(e){this.$props.handleChange&&this.$props.handleChange(e),this.setState({isOpen:!1,highlightedIndex:null,selectedItem:e,inputValue:function(){return this.isControlledProp("selectedItem")?"":"object"==typeof e?e.label||"":e}.call(this)})},changeHighlightedIndex:function(e){if(!(this.internalItemCount<0)){var t=this.mergedState.highlightedIndex;null===t&&(t=e>0?-1:this.internalItemCount+1);var n=t+e;n<0?n=this.internalItemCount:n>this.internalItemCount&&(n=0),this.setHighlightedIndex(n)}},setHighlightedIndex:function(e){void 0===e&&(e=null),this.setState({highlightedIndex:e});var t=document.getElementById("Downshift"+e);scrollIntoView(t,this.rootNode)},reset:function(){var e=this.mergedState.selectedItem;this.setState({isOpen:!1,highlightedIndex:null,inputValue:e})},getItemProps:function(e){var t=e.index,n=e.item,r=t;return void 0===t?(this.$props.itemToString?this.items.push(this.$props.itemToString(n)):this.items.push(n),r=this.items.indexOf(n)):this.items[r]=n,{id:"Downshift"+r}},getItemEvents:function(e){var t=e.index,n=e.item,r=t;void 0===t&&(r=this.items.indexOf(n));var o=this;return{mouseenter:function(){o.setHighlightedIndex(r)},click:function(e){e.stopPropagation(),o.selectItemAtIndex(r)}}},getInputProps:function(e){var t=e.value,n=this.mergedState.inputValue;return t!==n&&this.setState({inputValue:t}),{value:n}},getButtonProps:function(e){var t=this,n=e.onClick,r=e.onKeyDown,o=e.onKeyUp,s=e.onBlur;return{click:function(e){t.setState({isOpen:!0,inputValue:e.target.value}),n&&n(e)},keydown:function(e){e.key&&t["keyDown"+e.key]&&t["keyDown"+e.key].call(t,e),r&&r(e)},keyup:function(e){o&&o(e)},blur:function(e){s&&s(e)}}},getInputEvents:function(e){var t=this,n=e.onInput,r=e.onBlur,o=e.onFocus,s=e.onKeyPress,a=e.onKeyDown,i=e.onKeyUp;return{input:function(e){t.setState({isOpen:!0,inputValue:e.target.value}),n&&n(e)},focus:function(e){o&&o(e)},keydown:function(e){e.key&&t["keyDown"+e.key]&&t["keyDown"+e.key].call(t,e),a&&a(e)},keypress:function(e){s&&s(e)},keyup:function(e){i&&i(e)},blur:function(e){r&&r(e)},click:e.onClick}},getHelpersAndState:function(){return _extends({getItemProps:this.getItemProps,getItemEvents:this.getItemEvents,getInputProps:this.getInputProps,getInputEvents:this.getInputEvents,getButtonProps:this.getButtonProps,setHighlightedIndex:this.setHighlightedIndex},this.mergedState)},isControlledProp:function(e){return void 0!==this.$props[e]},setState:function(e){var t=this;Object.keys(e).forEach((function(n){t.isControlledProp(n)?(t.$emit(n+"Change",e[n]),t.$emit(n+"-change",e[n])):t["internal_"+n]=e[n]})),this.$emit("stateChange",this.mergedState),this.$emit("state-change",this.mergedState)}},render:function(){var e=arguments[0];return this.items=[],e("div",{ref:"rootNode"},[this.$scopedSlots.default&&this.$scopedSlots.default(_extends({},this.getHelpersAndState()))])}},_templateObject$e,Container=index$1("div")(_templateObject$e||(_templateObject$e=_taggedTemplateLiteralLoose(["\n\t",";\n"])),(function(e){return e.theme.component})),getClassName$2=lib_8.getClassName,SuggestionWrapper={name:"SuggestionWrapper",props:{innerClassName:types.string,themePreset:types.themePreset,innerClass:types.style},render:function(){var e=arguments[0],t=this.$props,n=t.themePreset,r=t.innerClass,o=t.innerClassName;return e("div",{class:noSuggestions(n)+" "+getClassName$2(r,o||"")},[e("li",[this.$scopedSlots.default()])])}},dist=createCommonjsModule((function(e){e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(2);Object.defineProperty(t,"combineChunks",{enumerable:!0,get:function(){return r.combineChunks}}),Object.defineProperty(t,"fillInChunks",{enumerable:!0,get:function(){return r.fillInChunks}}),Object.defineProperty(t,"findAll",{enumerable:!0,get:function(){return r.findAll}}),Object.defineProperty(t,"findChunks",{enumerable:!0,get:function(){return r.findChunks}})},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});t.findAll=function(e){var t=e.autoEscape,s=e.caseSensitive,a=void 0!==s&&s,i=e.findChunks,u=void 0===i?r:i,l=e.sanitize,c=e.searchWords,p=e.textToHighlight;return o({chunksToHighlight:n({chunks:u({autoEscape:t,caseSensitive:a,sanitize:l,searchWords:c,textToHighlight:p})}),totalLength:p?p.length:0})};var n=t.combineChunks=function(e){var t=e.chunks;return t=t.sort((function(e,t){return e.start-t.start})).reduce((function(e,t){if(0===e.length)return[t];var n=e.pop();if(t.start<=n.end){var r=Math.max(n.end,t.end);e.push({highlight:!1,start:n.start,end:r})}else e.push(n,t);return e}),[])},r=function(e){var t=e.autoEscape,n=e.caseSensitive,r=e.sanitize,o=void 0===r?s:r,a=e.searchWords,i=e.textToHighlight;return i=o(i),a.filter((function(e){return e})).reduce((function(e,r){r=o(r),t&&(r=r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"));for(var s=new RegExp(r,n?"g":"gi"),a=void 0;a=s.exec(i);){var u=a.index,l=s.lastIndex;l>u&&e.push({highlight:!1,start:u,end:l}),a.index===s.lastIndex&&s.lastIndex++}return e}),[])};t.findChunks=r;var o=t.fillInChunks=function(e){var t=e.chunksToHighlight,n=e.totalLength,r=[],o=function(e,t,n){t-e>0&&r.push({start:e,end:t,highlight:n})};if(0===t.length)o(0,n,!1);else{var s=0;t.forEach((function(e){o(s,e.start,!1),o(e.start,e.end,!0),s=e.end})),o(s,n,!1)}return r};function s(e){return e}}])}));unwrapExports(dist);var dist_1=dist.findAll;
21
21
  /*!
22
22
  * vue-highlight-words © Yichang Liu, 2019
23
23
  *
@@ -47,5 +47,5 @@ var index$3={name:"NoSsr",functional:!0,props:{placeholder:String,placeholderTag
47
47
  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
48
48
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
49
49
  PERFORMANCE OF THIS SOFTWARE.
50
- ***************************************************************************** */function __rest(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}var Cluster=function(){function e(e){var t=e.markers,n=e.position;this.markers=t,n&&(n instanceof google.maps.LatLng?this._position=n:this._position=new google.maps.LatLng(n))}var t=e.prototype;return t.push=function(e){this.markers.push(e)},t.delete=function(){this.marker&&(this.marker.setMap(null),delete this.marker),this.markers.length=0},_createClass(e,[{key:"bounds",get:function(){if(0!==this.markers.length||this._position)return this.markers.reduce((function(e,t){return e.extend(t.getPosition())}),new google.maps.LatLngBounds(this._position,this._position))}},{key:"position",get:function(){return this._position||this.bounds.getCenter()}},{key:"count",get:function(){return this.markers.filter((function(e){return e.getVisible()})).length}}]),e}(),AbstractAlgorithm=function(){function e(e){var t=e.maxZoom,n=void 0===t?16:t;this.maxZoom=n}return e.prototype.noop=function(e){var t=e.markers;return _noop(t)},e}(),_noop=function(e){return e.map((function(e){return new Cluster({position:e.getPosition(),markers:[e]})}))},SuperClusterAlgorithm=function(e){function t(t){var n,r=t.maxZoom,o=t.radius,s=void 0===o?60:o,a=__rest(t,["maxZoom","radius"]);return(n=e.call(this,{maxZoom:r})||this).superCluster=new Supercluster(Object.assign({maxZoom:n.maxZoom,radius:s},a)),n.state={zoom:null},n}_inheritsLoose(t,e);var n=t.prototype;return n.calculate=function(e){var t=!1;if(!fastDeepEqual(e.markers,this.markers)){t=!0,this.markers=[].concat(e.markers);var n=this.markers.map((function(e){return{type:"Feature",geometry:{type:"Point",coordinates:[e.getPosition().lng(),e.getPosition().lat()]},properties:{marker:e}}}));this.superCluster.load(n)}var r={zoom:e.map.getZoom()};return t||this.state.zoom>this.maxZoom&&r.zoom>this.maxZoom||(t=t||!fastDeepEqual(this.state,r)),this.state=r,t&&(this.clusters=this.cluster(e)),{clusters:this.clusters,changed:t}},n.cluster=function(e){var t=e.map;return this.superCluster.getClusters([-180,-90,180,90],Math.round(t.getZoom())).map(this.transformCluster.bind(this))},n.transformCluster=function(e){var t=e.geometry.coordinates,n=t[0],r=t[1],o=e.properties;if(o.cluster)return new Cluster({markers:this.superCluster.getLeaves(o.cluster_id,1/0).map((function(e){return e.properties.marker})),position:new google.maps.LatLng({lat:r,lng:n})});var s=o.marker;return new Cluster({markers:[s],position:s.getPosition()})},t}(AbstractAlgorithm),ClusterStats=function(e,t){this.markers={sum:e.length};var n=t.map((function(e){return e.count})),r=n.reduce((function(e,t){return e+t}),0);this.clusters={count:t.length,markers:{mean:r/t.length,sum:r,min:Math.min.apply(Math,n),max:Math.max.apply(Math,n)}}},DefaultRenderer=function(){function e(){}return e.prototype.render=function(e,t){var n=e.count,r=e.position,o=n>Math.max(10,t.clusters.markers.mean)?"#ff0000":"#0000ff",s=window.btoa('\n <svg fill="'+o+'" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240">\n <circle cx="120" cy="120" opacity=".6" r="70" />\n <circle cx="120" cy="120" opacity=".3" r="90" />\n <circle cx="120" cy="120" opacity=".2" r="110" />\n </svg>');return new google.maps.Marker({position:r,icon:{url:"data:image/svg+xml;base64,"+s,scaledSize:new google.maps.Size(45,45)},label:{text:String(n),color:"rgba(255,255,255,0.9)",fontSize:"12px"},title:"Cluster of "+n+" markers",zIndex:Number(google.maps.Marker.MAX_ZINDEX)+n})},e}();function extend$1(e,t){for(var n in t.prototype)e.prototype[n]=t.prototype[n]}var OverlayViewSafe=function e(){extend$1(e,google.maps.OverlayView)},MarkerClustererEvents;!function(e){e.CLUSTERING_BEGIN="clusteringbegin",e.CLUSTERING_END="clusteringend",e.CLUSTER_CLICK="click"}(MarkerClustererEvents||(MarkerClustererEvents={}));var defaultOnClusterClickHandler=function(e,t,n){n.fitBounds(t.bounds)},MarkerClusterer=function(e){function t(t){var n,r=t.map,o=t.markers,s=void 0===o?[]:o,a=t.algorithm,i=void 0===a?new SuperClusterAlgorithm({}):a,u=t.renderer,l=void 0===u?new DefaultRenderer:u,c=t.onClusterClick,p=void 0===c?defaultOnClusterClickHandler:c;return(n=e.call(this)||this).markers=[].concat(s),n.clusters=[],n.algorithm=i,n.renderer=l,n.onClusterClick=p,r&&n.setMap(r),n}_inheritsLoose(t,e);var n=t.prototype;return n.addMarker=function(e,t){this.markers.includes(e)||(this.markers.push(e),t||this.render())},n.addMarkers=function(e,t){var n=this;e.forEach((function(e){n.addMarker(e,!0)})),t||this.render()},n.removeMarker=function(e,t){var n=this.markers.indexOf(e);return-1!==n&&(e.setMap(null),this.markers.splice(n,1),t||this.render(),!0)},n.removeMarkers=function(e,t){var n=this,r=!1;return e.forEach((function(e){r=n.removeMarker(e,!0)||r})),r&&!t&&this.render(),r},n.clearMarkers=function(e){this.markers.length=0,e||this.render()},n.render=function(){var e=this.getMap();if(e instanceof google.maps.Map&&this.getProjection()){google.maps.event.trigger(this,MarkerClustererEvents.CLUSTERING_BEGIN,this);var t=this.algorithm.calculate({markers:this.markers,map:e,mapCanvasProjection:this.getProjection()}),n=t.clusters,r=t.changed;(r||null==r)&&(this.reset(),this.clusters=n,this.renderClusters()),google.maps.event.trigger(this,MarkerClustererEvents.CLUSTERING_END,this)}},n.onAdd=function(){this.idleListener=this.getMap().addListener("idle",this.render.bind(this)),this.render()},n.onRemove=function(){google.maps.event.removeListener(this.idleListener),this.reset()},n.reset=function(){this.markers.forEach((function(e){return e.setMap(null)})),this.clusters.forEach((function(e){return e.delete()})),this.clusters=[]},n.renderClusters=function(){var e=this,t=new ClusterStats(this.markers,this.clusters),n=this.getMap();this.clusters.forEach((function(r){1===r.markers.length?r.marker=r.markers[0]:(r.marker=e.renderer.render(r,t),e.onClusterClick&&r.marker.addListener("click",(function(t){google.maps.event.trigger(e,MarkerClustererEvents.CLUSTER_CLICK,r),e.onClusterClick(t,r,n)}))),r.marker.setMap(n)}))},t}(OverlayViewSafe),_excluded$6=["options"],script$2={name:"ClusterIcon",mixins:[mapElementMixin],provide:function(){var e=this,t=["click","rightclick","dblclick","drag","dragstart","dragend","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,clusterIconMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$6));if(void 0===MarkerClusterer)throw new Error("MarkerClusterer is not installed! require() it or include it from https://cdnjs.cloudflare.com/ajax/libs/js-marker-clusterer/1.0.0/markerclusterer.js");var s=o.map,a=o.markers,i=o.algorithm,u=o.onClusterClick,l=o.renderer;return e.$clusterObject=new MarkerClusterer({map:s,markers:a,algorithm:i,onClusterClick:u,renderer:l}),bindProps(e,e.$clusterObject,{}),bindEvents(e,e.$clusterObject,t),Object.keys({}).forEach((function(t){({})[t].twoWay&&e.$on(t.toLowerCase()+"_changed",e.reinsertMarkers)})),e.$clusterObject})).catch((function(e){throw e}));return this.$clusterPromise=n,{$clusterPromise:n}},props:{algorithm:{type:Object,default:void 0},onClusterClick:{type:Function,default:void 0},renderer:{type:Object,default:void 0},options:{type:Object,default:void 0}},beforeDestroy:function(){var e=this;this.$children.forEach((function(t){t.$clusterObject===e.$clusterObject&&(t.$clusterObject=null)})),this.$clusterObject&&this.$clusterObject.clearMarkers()},destroyed:function(){this.$clusterObject&&this.$clusterObject.setMap&&this.$clusterObject.setMap(null)},updated:function(){this.$clusterObject&&this.$clusterObject.render()},methods:{reinsertMarkers:function(){var e=[].concat(this.$clusterObject.markers);this.$clusterObject.clearMarkers(),this.$clusterObject.addMarkers(e)}}},__vue_script__$2=script$2,__vue_render__$1=function(){var e=this.$createElement;return(this._self._c||e)("div",[this._t("default")],2)},__vue_staticRenderFns__$1=[],__vue_inject_styles__$2=void 0,__vue_scope_id__$2=void 0,__vue_module_identifier__$2=void 0,__vue_is_functional_template__$2=!1,__vue_component__$2=normalizeComponent({render:__vue_render__$1,staticRenderFns:__vue_staticRenderFns__$1},__vue_inject_styles__$2,__vue_script__$2,__vue_scope_id__$2,__vue_is_functional_template__$2,__vue_module_identifier__$2,!1,void 0,void 0,void 0),_excluded$7=["options"],script$3={name:"DrawingManager",mixins:[mapElementMixin],provide:function(){var e=this,t=this.$mapPromise.then((function(t){e.$map=t;var n=_extends({},e.options,{map:t},getPropsValues(e,drawingManagerMappedProps)),r=(n.options,_objectWithoutPropertiesLoose(n,_excluded$7));e.drawingModes=Object.keys(r).reduce((function(e,t){var n=t.split("Options");return n.length>1&&e.push(n[0]),e}),[]);var o=e.position&&google.maps.ControlPosition[e.position]?google.maps.ControlPosition[e.position]:google.maps.ControlPosition.TOP_LEFT;return r.drawingMode=null,r.drawingControl=!e.$scopedSlots.default,r.drawingControlOptions={drawingModes:e.drawingModes,position:o},e.$drawingManagerObject=new google.maps.drawing.DrawingManager(r),bindProps(e,e.$drawingManagerObject,drawingManagerMappedProps),e.$drawingManagerObject.addListener("overlaycomplete",(function(t){return e.addShape(t)})),e.$map.addListener("click",e.clearSelection),e&&e.finalShapes&&e.finalShapes.length&&e.drawAll(),e.$drawingManagerObject})).catch((function(e){throw e}));return this.$drawingManagerPromise=t,{$drawingManagerPromise:t}},props:{circleOptions:{type:Object,default:void 0},markerOptions:{type:Object,default:void 0},polygonOptions:{type:Object,default:void 0},polylineOptions:{type:Object,default:void 0},rectangleOptions:{type:Object,default:void 0},position:{type:String,default:""},shapes:{type:Array,required:!0}},data:function(){return{selectedShape:null,drawingModes:[],options:{drawingMode:null,drawingControl:!0,drawingControlOptions:{}},finalShapes:[]}},watch:{position:function(e){if(this.$drawingManagerObject){var t={position:e&&google.maps.ControlPosition[e]?google.maps.ControlPosition[e]:google.maps.ControlPosition.TOP_LEFT,drawingModes:this.drawingModes};this.$drawingManagerObject.setOptions({drawingControlOptions:t})}},circleOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({circleOptions:e})},markerOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({markerOptions:e})},polygonOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({polygonOptions:e})},polylineOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({polylineOptions:e})},rectangleOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({rectangleOptions:e})}},mounted:function(){this.finalShapes=[].concat(this.shapes)},destroyed:function(){this.clearAll(),this.$drawingManagerObject&&this.$drawingManagerObject.setMap&&this.$drawingManagerObject.setMap(null)},methods:{setDrawingMode:function(e){this.$drawingManagerObject.setDrawingMode(e)},drawAll:function(){var e=this,t={circle:google.maps.Circle,marker:google.maps.Marker,polygon:google.maps.Polygon,polyline:google.maps.Polyline,rectangle:google.maps.Rectangle},n=this;this.finalShapes.forEach((function(r){var o=new t[r.type](r.overlay);o.setMap(e.$map),r.overlay=o,google.maps.event.addListener(o,"click",(function(){n.setSelection(r)}))}))},clearAll:function(){this.clearSelection(),this.finalShapes.forEach((function(e){e.overlay.setMap(null)}))},clearSelection:function(){this.selectedShape&&(this.selectedShape.overlay.set("fillColor","#777"),this.selectedShape.overlay.set("strokeColor","#999"),this.selectedShape.overlay.setEditable(!1),this.selectedShape.overlay.setDraggable(!1),this.selectedShape=null)},setSelection:function(e){this.clearSelection(),this.selectedShape=e,e.overlay.setEditable(!0),e.overlay.setDraggable(!0),this.selectedShape.overlay.set("fillColor","#555"),this.selectedShape.overlay.set("strokeColor","#777")},deleteSelection:function(){if(this.selectedShape){this.selectedShape.overlay.setMap(null);var e=this.finalShapes.indexOf(this.selectedShape);e>-1&&this.finalShapes.splice(e,1)}},addShape:function(e){this.setDrawingMode(null),this.finalShapes.push(e),this.$emit("update:shapes",[].concat(this.finalShapes));var t=this;google.maps.event.addListener(e.overlay,"click",(function(){t.setSelection(e)})),google.maps.event.addListener(e.overlay,"rightclick",(function(){t.deleteSelection()})),this.setSelection(e)}}},__vue_script__$3=script$3,__vue_render__$2=function(){var e=this.$createElement;return(this._self._c||e)("div",[this._t("default",null,{setDrawingMode:this.setDrawingMode,deleteSelection:this.deleteSelection})],2)},__vue_staticRenderFns__$2=[],__vue_inject_styles__$3=void 0,__vue_scope_id__$3=void 0,__vue_module_identifier__$3=void 0,__vue_is_functional_template__$3=!1,__vue_component__$3=normalizeComponent({render:__vue_render__$2,staticRenderFns:__vue_staticRenderFns__$2},__vue_inject_styles__$3,__vue_script__$3,__vue_scope_id__$3,__vue_is_functional_template__$3,__vue_module_identifier__$3,!1,void 0,void 0,void 0),_excluded$8=["options"],script$4={name:"HeatmapLayer",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=[],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:e.$map},getPropsValues(e,heatMapLayerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$8));return e.$heatmapLayerObject=new google.maps.visualization.HeatmapLayer(o),bindProps(e,e.$heatmapLayerObject,heatMapLayerMappedProps),bindEvents(e,e.$heatmapLayerObject,t),e.$heatmapLayerObject})).catch((function(e){throw e}));return this.$heatmapLayerPromise=n,{$heatmapLayerPromise:n}},props:{options:{type:Object,default:function(){}},data:{type:Array,default:void 0}},destroyed:function(){this.$heatmapLayerObject&&this.$heatmapLayerObject.setMap&&this.$heatmapLayerObject.setMap(null)}},__vue_script__$4=script$4,__vue_inject_styles__$4=void 0,__vue_scope_id__$4=void 0,__vue_module_identifier__$4=void 0,__vue_is_functional_template__$4=void 0,__vue_component__$4=normalizeComponent({},__vue_inject_styles__$4,__vue_script__$4,__vue_scope_id__$4,__vue_is_functional_template__$4,__vue_module_identifier__$4,!1,void 0,void 0,void 0),_excluded$9=["options","position"],script$5={name:"InfoWindow",mixins:[mapElementMixin],inject:{$markerPromise:{default:null}},provide:function(){var e=this,t=["domready","closeclick","content_changed"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,infoWindowMappedProps)),o=(r.options,r.position,_objectWithoutPropertiesLoose(r,_excluded$9));return o.content=e.$refs.flyaway,e.$markerPromise&&e.$markerPromise.then((function(t){return e.$markerObject=t,t})),e.$infoWindowObject=new google.maps.InfoWindow(o),bindProps(e,e.$infoWindowObject,infoWindowMappedProps),bindEvents(e,e.$infoWindowObject,t),e._openInfoWindow(),e.$watch("opened",(function(){e._openInfoWindow()})),e.$infoWindowObject})).catch((function(e){throw e}));return this.$infoWindowPromise=n,{$infoWindowPromise:n}},props:{content:{type:[String,Object],default:void 0},opened:{type:Boolean,default:!0},position:{type:Object,default:void 0},zIndex:{type:Number,default:0},options:{type:Object,required:!1,default:void 0}},mounted:function(){var e=this.$refs.flyaway;e.parentNode.removeChild(e)},destroyed:function(){this.$infoWindowObject&&this.$infoWindowObject.setMap&&this.$infoWindowObject.setMap(null)},methods:{_openInfoWindow:function(){this.opened?null!==this.$markerObject?this.$infoWindowObject.open(this.$map,this.$markerObject):this.$infoWindowObject.open(this.$map):this.$infoWindowObject.close()}}},__vue_script__$5=script$5,__vue_render__$3=function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{ref:"flyaway"},[this._t("default")],2)])},__vue_staticRenderFns__$3=[],__vue_inject_styles__$5=void 0,__vue_scope_id__$5=void 0,__vue_module_identifier__$5=void 0,__vue_is_functional_template__$5=!1,__vue_component__$5=normalizeComponent({render:__vue_render__$3,staticRenderFns:__vue_staticRenderFns__$3},__vue_inject_styles__$5,__vue_script__$5,__vue_scope_id__$5,__vue_is_functional_template__$5,__vue_module_identifier__$5,!1,void 0,void 0,void 0),_excluded$a=["options"],script$6={name:"KmlLayer",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","rightclick","dblclick","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,kmlLayerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$a));return e.$kmlLayerObject=new google.maps.KmlLayer(o),bindProps(e,e.$kmlLayerObject,kmlLayerMappedProps),bindEvents(e,e.$kmlLayerObject,t),e.$kmlLayerObject})).catch((function(e){throw e}));return this.$kmlLayerPromise=n,{$kmlLayerPromise:n}},props:{clickable:{type:Boolean,default:!0},map:{type:Object,default:void 0},preserveViewport:{type:Boolean,default:!1},screenOverlays:{type:Boolean,default:!1},suppressInfoWindows:{type:Boolean,default:void 0},url:{type:String,default:""},zIndex:{type:Number,default:void 0},options:{type:Object,default:void 0}},destroyed:function(){this.$kmlLayerObject&&this.$kmlLayerObject.setMap&&this.$kmlLayerObject.setMap(null)}},__vue_script__$6=script$6,__vue_inject_styles__$6=void 0,__vue_scope_id__$6=void 0,__vue_module_identifier__$6=void 0,__vue_is_functional_template__$6=void 0,__vue_component__$6=normalizeComponent({},__vue_inject_styles__$6,__vue_script__$6,__vue_scope_id__$6,__vue_is_functional_template__$6,__vue_module_identifier__$6,!1,void 0,void 0,void 0),mountableMixin={props:["resizeBus"],data:function(){return{_actualResizeBus:null}},created:function(){void 0===this.resizeBus?this.$data._actualResizeBus=this.$gmapDefaultResizeBus:this.$data._actualResizeBus=this.resizeBus},methods:{_resizeCallback:function(){this.resize()},_delayedResizeCallback:function(){var e=this;this.$nextTick((function(){return e._resizeCallback()}))}},watch:{resizeBus:function(e){this.$data._actualResizeBus=e},"$data._actualResizeBus":function(e,t){t&&t.$off("resize",this._delayedResizeCallback),e&&e.$on("resize",this._delayedResizeCallback)}},destroyed:function(){this.$data._actualResizeBus&&this.$data._actualResizeBus.$off("resize",this._delayedResizeCallback)}},_excluded$b=["options"],script$7={name:"MapLayer",mixins:[mountableMixin],provide:function(){var e=this;return this.$mapPromise=new Promise((function(t,n){e.$mapPromiseDeferred={resolve:t,reject:n}})),{$mapPromise:this.$mapPromise}},props:{center:{type:Object,required:!0},zoom:{type:Number,required:!1,default:void 0},heading:{type:Number,default:void 0},mapTypeId:{type:String,default:"roadmap"},tilt:{type:Number,default:void 0},options:{type:Object,default:void 0}},data:function(){return{recyclePrefix:"__gmc__"}},computed:{finalLat:function(){return this.center&&"function"==typeof this.center.lat?this.center.lat():this.center.lat},finalLng:function(){return this.center&&"function"==typeof this.center.lng?this.center.lng():this.center.lng},finalLatLng:function(){return{lat:this.finalLat,lng:this.finalLng}}},watch:{zoom:function(e){this.$mapObject&&this.$mapObject.setZoom(e)}},beforeDestroy:function(){var e=this.getRecycleKey();window[e]&&(window[e].div=this.$mapObject.getDiv())},mounted:function(){var e=this;return this.$gmapApiPromiseLazy().then((function(){var t=e.$refs["vue-map"],n=_extends({},e.options,getPropsValues(e,mapMappedProps)),r=(n.options,_objectWithoutPropertiesLoose(n,_excluded$b)),o=e.getRecycleKey();return e&&e.options&&e.options.recycle&&window[o]?(t.appendChild(window[o].div),e.$mapObject=window[o].map,e.$mapObject.setOptions(r)):(e.$mapObject=new google.maps.Map(t,r),window[o]={map:e.$mapObject}),bindProps(e,e.$mapObject,mapMappedProps),bindEvents(e,e.$mapObject,["bounds_changed","click","dblclick","drag","dragend","dragstart","idle","mousemove","mouseout","mouseover","resize","rightclick","tilesloaded"]),twoWayBindingWrapper((function(t,n,r){e.$mapObject.addListener("center_changed",(function(){r()&&e.$emit("center_changed",e.$mapObject.getCenter()),n()}));watchPrimitiveProperties(e,["finalLat","finalLng"],(function(){t(),e.$mapObject.setCenter(e.finalLatLng)}))})),e.$mapObject.addListener("zoom_changed",(function(){e.$emit("zoom_changed",e.$mapObject.getZoom())})),e.$mapObject.addListener("bounds_changed",(function(){e.$emit("bounds_changed",e.$mapObject.getBounds())})),e.$mapPromiseDeferred.resolve(e.$mapObject),e.$mapObject})).catch((function(e){throw e}))},methods:{resize:function(){this.$mapObject&&google.maps.event.trigger(this.$mapObject,"resize")},resizePreserveCenter:function(){if(this.$mapObject){var e=this.$mapObject.getCenter();google.maps.event.trigger(this.$mapObject,"resize"),this.$mapObject.setCenter(e)}},_resizeCallback:function(){this.resizePreserveCenter()},panBy:function(){var e;this.$mapObject&&(e=this.$mapObject).panBy.apply(e,arguments)},panTo:function(){var e;this.$mapObject&&(e=this.$mapObject).panTo.apply(e,arguments)},panToBounds:function(){var e;this.$mapObject&&(e=this.$mapObject).panToBounds.apply(e,arguments)},fitBounds:function(){var e;this.$mapObject&&(e=this.$mapObject).fitBounds.apply(e,arguments)},getRecycleKey:function(){return this&&this.options&&this.options.recycle?this.recyclePrefix+this.options.recycle:this.recyclePrefix}},destroyed:function(){this.$mapObject&&this.$mapObject.setMap&&this.$mapObject.setMap(null)}},isOldIE="undefined"!=typeof navigator&&/msie [6-9]\\b/.test(navigator.userAgent.toLowerCase()),HEAD;function createInjector(e){return function(e,t){return addStyle(e,t)}}var styles={};function addStyle(e,t){var n=isOldIE?t.media||"default":e,r=styles[n]||(styles[n]={ids:new Set,styles:[]});if(!r.ids.has(e)){r.ids.add(e);var o=t.source;if(t.map&&(o+="\n/*# sourceURL="+t.map.sources[0]+" */",o+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(t.map))))+" */"),r.element||(r.element=document.createElement("style"),r.element.type="text/css",t.media&&r.element.setAttribute("media",t.media),void 0===HEAD&&(HEAD=document.head||document.getElementsByTagName("head")[0]),HEAD.appendChild(r.element)),"styleSheet"in r.element)r.styles.push(o),r.element.styleSheet.cssText=r.styles.filter(Boolean).join("\n");else{var s=r.ids.size-1,a=document.createTextNode(o),i=r.element.childNodes;i[s]&&r.element.removeChild(i[s]),i.length?r.element.insertBefore(a,i[s]):r.element.appendChild(a)}}}var __vue_script__$7=script$7,__vue_render__$4=function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"vue-map-container"},[t("div",{ref:"vue-map",staticClass:"vue-map"}),this._v(" "),t("div",{staticClass:"vue-map-hidden"},[this._t("default")],2),this._v(" "),this._t("visible")],2)},__vue_staticRenderFns__$4=[],__vue_inject_styles__$7=function(e){e&&e("data-v-58f81a38_0",{source:".vue-map-container{position:relative}.vue-map-container .vue-map{left:0;right:0;top:0;bottom:0;position:absolute}.vue-map-hidden{display:none}",map:void 0,media:void 0})},__vue_scope_id__$7=void 0,__vue_module_identifier__$7=void 0,__vue_is_functional_template__$7=!1,__vue_component__$7=normalizeComponent({render:__vue_render__$4,staticRenderFns:__vue_staticRenderFns__$4},__vue_inject_styles__$7,__vue_script__$7,__vue_scope_id__$7,__vue_is_functional_template__$7,__vue_module_identifier__$7,!1,createInjector,void 0,void 0),_excluded$c=["options"],script$8={name:"MarkerIcon",mixins:[mapElementMixin],inject:{$clusterPromise:{default:null}},provide:function(){var e=this,t=["click","rightclick","dblclick","drag","dragstart","dragend","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,markerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$c));return e.$clusterPromise&&(o.map=null),e.$markerObject=new google.maps.Marker(o),bindProps(e,e.$markerObject,markerMappedProps),bindEvents(e,e.$markerObject,t),e.$markerObject.addListener("dragend",(function(){var t=e.$markerObject.getPosition();e.$emit("update:position",{lat:t.lat(),lng:t.lng()})})),e.$clusterPromise&&e.$clusterPromise.then((function(t){t.addMarker(e.$markerObject),e.$clusterObject=t})),e.$markerObject})).catch((function(e){throw e}));return this.$markerPromise=n,{$markerPromise:n}},props:{animation:{type:Number,default:void 0},attribution:{type:Object,default:void 0},clickable:{type:Boolean,default:!0},cursor:{type:String,default:void 0},draggable:{type:Boolean,default:!1},icon:{type:[String,Object],default:void 0},label:{type:[String,Object],default:void 0},opacity:{type:Number,default:1},options:{type:Object,default:void 0},place:{type:Object,default:void 0},position:{type:Object,default:void 0},shape:{type:Object,default:void 0},title:{type:String,default:void 0},visible:{type:Boolean,default:!0},zIndex:{type:Number,default:void 0}},destroyed:function(){this.$markerObject&&(this.$clusterObject?this.$clusterObject.removeMarker(this.$markerObject,!0):this.$markerObject&&this.$markerObject.setMap&&this.$markerObject.setMap(null))},render:function(e){return this.$slots.default&&0!==this.$slots.default.length?1===this.$slots.default.length?this.$slots.default[0]:e("div",this.$slots.default):""}},__vue_script__$8=script$8,__vue_inject_styles__$8=void 0,__vue_scope_id__$8=void 0,__vue_module_identifier__$8=void 0,__vue_is_functional_template__$8=void 0,__vue_component__$8=normalizeComponent({},__vue_inject_styles__$8,__vue_script__$8,__vue_scope_id__$8,__vue_is_functional_template__$8,__vue_module_identifier__$8,!1,void 0,void 0,void 0),_excluded$d=["placeholder","place","defaultPlace","className","label","selectFirstOnEnter"],script$9={name:"PlaceInput",props:{bounds:{type:Object,default:void 0},defaultPlace:{type:String,default:""},componentRestrictions:{type:Object,default:null},types:{type:Array,default:void 0},placeholder:{required:!1,type:String,default:void 0},className:{required:!1,type:String,default:void 0},label:{required:!1,type:String,default:null},selectFirstOnEnter:{require:!1,type:Boolean,default:!1}},created:function(){window.console.warn("The PlaceInput class is deprecated! Please consider using the Autocomplete input instead, it will be removed in the next major release of this plugin.")},mounted:function(){var e=this,t=this.$refs.input;t.value=this.defaultPlace,this.$watch("defaultPlace",(function(){t.value=e.defaultPlace})),this.$gmapApiPromiseLazy().then((function(){var t=getPropsValues(e,placeInputMappedProps);if(e.selectFirstOnEnter&&downArrowSimulator(e.$refs.input),"function"!=typeof google.maps.places.Autocomplete)throw new Error("google.maps.places.Autocomplete is undefined. Did you add 'places' to libraries when loading Google Maps?");e.$autoCompleter=new google.maps.places.Autocomplete(e.$refs.input,t);var n=_objectWithoutPropertiesLoose(placeInputMappedProps,_excluded$d);bindProps(e,e.$autoCompleter,n),e.$autoCompleter.addListener("place_changed",(function(){e.$emit("place_changed",e.$autoCompleter.getPlace())}))}))},destroyed:function(){this.$autoCompleter&&this.$autoCompleter.setMap&&this.$autoCompleter.setMap(null)}},__vue_script__$9=script$9,__vue_render__$5=function(){var e=this.$createElement,t=this._self._c||e;return t("label",[t("span",{domProps:{textContent:this._s(this.label)}}),this._v(" "),t("input",{ref:"input",class:this.className,attrs:{type:"text",placeholder:this.placeholder}})])},__vue_staticRenderFns__$5=[],__vue_inject_styles__$9=void 0,__vue_scope_id__$9=void 0,__vue_module_identifier__$9=void 0,__vue_is_functional_template__$9=!1,__vue_component__$9=normalizeComponent({render:__vue_render__$5,staticRenderFns:__vue_staticRenderFns__$5},__vue_inject_styles__$9,__vue_script__$9,__vue_scope_id__$9,__vue_is_functional_template__$9,__vue_module_identifier__$9,!1,void 0,void 0,void 0),_excluded$e=["options","path","paths"],script$a={name:"PolygonShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,polygonMappedProps)),o=(r.options,r.path,r.paths,_objectWithoutPropertiesLoose(r,_excluded$e));e.$polygonObject=new google.maps.Polygon(o),bindProps(e,e.$polygonObject,polygonMappedProps),bindEvents(e,e.$polygonObject,t);var s=function(){};return e.$watch("paths",(function(t){if(t){s(),e.$polygonObject.setPaths(t);for(var n=function(){e.$emit("paths_changed",e.$polygonObject.getPaths())},r=[],o=e.$polygonObject.getPaths(),a=0;a<o.getLength();a+=1){var i=o.getAt(a);r.push([i,i.addListener("insert_at",n)]),r.push([i,i.addListener("remove_at",n)]),r.push([i,i.addListener("set_at",n)])}r.push([o,o.addListener("insert_at",n)]),r.push([o,o.addListener("remove_at",n)]),r.push([o,o.addListener("set_at",n)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$watch("path",(function(t){if(t){s(),e.$polygonObject.setPaths(t);var n=e.$polygonObject.getPath(),r=[],o=function(){e.$emit("path_changed",e.$polygonObject.getPath())};r.push([n,n.addListener("insert_at",o)]),r.push([n,n.addListener("remove_at",o)]),r.push([n,n.addListener("set_at",o)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$polygonObject})).catch((function(e){throw e}));return this.$polygonPromise=n,{$polygonPromise:n}},props:{deepWatch:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},fillColor:{type:String,default:""},fillOpacity:{type:Number,default:1},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokePosition:{type:Number,default:0},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0},path:{type:Array,noBind:!0,default:void 0},paths:{type:Array,noBind:!0,default:void 0}},destroyed:function(){this.$polygonObject&&this.$polygonObject.setMap&&this.$polygonObject.setMap(null)}},__vue_script__$a=script$a,__vue_inject_styles__$a=void 0,__vue_scope_id__$a=void 0,__vue_module_identifier__$a=void 0,__vue_is_functional_template__$a=void 0,__vue_component__$a=normalizeComponent({},__vue_inject_styles__$a,__vue_script__$a,__vue_scope_id__$a,__vue_is_functional_template__$a,__vue_module_identifier__$a,!1,void 0,void 0,void 0),_excluded$f=["options"],script$b={name:"PolylineShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,polylineMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$f));e.$polylineObject=new google.maps.Polyline(o),bindProps(e,e.$polylineObject,polylineMappedProps),bindEvents(e,e.$polylineObject,t);var s=function(){};return e.$watch("path",(function(t){if(t){s(),e.$polylineObject.setPath(t);var n=e.$polylineObject.getPath(),r=[],o=function(){e.$emit("path_changed",e.$polylineObject.getPath())};r.push([n,n.addListener("insert_at",o)]),r.push([n,n.addListener("remove_at",o)]),r.push([n,n.addListener("set_at",o)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$polylineObject})).catch((function(e){throw e}));return this.$polylinePromise=n,{$polylinePromise:n}},props:{deepWatch:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},draggable:{type:Boolean},editable:{type:Boolean},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0},path:{type:Array,default:void 0}},destroyed:function(){this.$polylineObject&&this.$polylineObject.setMap&&this.$polylineObject.setMap(null)}},__vue_script__$b=script$b,__vue_inject_styles__$b=void 0,__vue_scope_id__$b=void 0,__vue_module_identifier__$b=void 0,__vue_is_functional_template__$b=void 0,__vue_component__$b=normalizeComponent({},__vue_inject_styles__$b,__vue_script__$b,__vue_scope_id__$b,__vue_is_functional_template__$b,__vue_module_identifier__$b,!1,void 0,void 0,void 0),_excluded$g=["options"],script$c={name:"RectangleShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,rectangleMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$g));return e.$rectangleObject=new google.maps.Rectangle(o),bindProps(e,e.$rectangleObject,rectangleMappedProps),bindEvents(e,e.$rectangleObject,t),e.$rectangleObject})).catch((function(e){throw e}));return this.$rectanglePromise=n,{$rectanglePromise:n}},props:{bounds:{type:Object,default:void 0},clickable:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},fillColor:{type:String,default:""},fillOpacity:{type:Number,default:1},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokePosition:{type:Number,default:0},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0}},destroyed:function(){this.$rectangleObject&&this.$rectangleObject.setMap&&this.$rectangleObject.setMap(null)}},__vue_script__$c=script$c,__vue_inject_styles__$c=void 0,__vue_scope_id__$c=void 0,__vue_module_identifier__$c=void 0,__vue_is_functional_template__$c=void 0,__vue_component__$c=normalizeComponent({},__vue_inject_styles__$c,__vue_script__$c,__vue_scope_id__$c,__vue_is_functional_template__$c,__vue_module_identifier__$c,!1,void 0,void 0,void 0),_excluded$h=["options"],script$d={name:"StreetViewPanorama",mixins:[mountableMixin],provide:function(){var e=this;return this.$panoPromise=new Promise((function(t,n){e.$panoPromiseDeferred={resolve:t,reject:n}})),{$panoPromise:this.$panoPromise,$mapPromise:this.$panoPromise}},props:{zoom:{type:Number,default:void 0},pov:{type:Object,default:void 0},position:{type:Object,default:void 0},pano:{type:String,default:void 0},motionTracking:{type:Boolean},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0}},replace:!1,computed:{finalLat:function(){return this.position&&"function"==typeof this.position.lat?this.position.lat():this.position.lat},finalLng:function(){return this.position&&"function"==typeof this.position.lng?this.position.lng():this.position.lng},finalLatLng:function(){return{lat:this.finalLat,lng:this.finalLng}}},watch:{zoom:function(e){this.$panoObject&&this.$panoObject.setZoom(e)}},mounted:function(){var e=this,t=["closeclick","status_changed"];return this.$gmapApiPromiseLazy().then((function(){var n=e.$refs["vue-street-view-pano"],r=_extends({},e.options,getPropsValues(e,streetViewPanoramaMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$h));return e.$panoObject=new google.maps.StreetViewPanorama(n,o),bindProps(e,e.$panoObject,streetViewPanoramaMappedProps),bindEvents(e,e.$panoObject,t),twoWayBindingWrapper((function(t,n,r){t(),e.$panoObject.addListener("position_changed",(function(){r()&&e.$emit("position_changed",e.$panoObject.getPosition()),n()}));watchPrimitiveProperties(e,["finalLat","finalLng"],(function(){t(),e.$panoObject.setPosition(e.finalLatLng)}))})),e.$panoPromiseDeferred.resolve(e.$panoObject),e.$panoPromise})).catch((function(e){throw e}))},methods:{resize:function(){this.$panoObject&&google.maps.event.trigger(this.$panoObject,"resize")}},destroyed:function(){this.$panoObject&&this.$panoObject.setMap&&this.$panoObject.setMap(null)}},__vue_script__$d=script$d,__vue_render__$6=function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"vue-street-view-pano-container"},[t("div",{ref:"vue-street-view-pano",staticClass:"vue-street-view-pano"}),this._v(" "),this._t("default")],2)},__vue_staticRenderFns__$6=[],__vue_inject_styles__$d=function(e){e&&e("data-v-32786ad9_0",{source:".vue-street-view-pano-container{position:relative}.vue-street-view-pano-container .vue-street-view-pano{left:0;right:0;top:0;bottom:0;position:absolute}",map:void 0,media:void 0})},__vue_scope_id__$d=void 0,__vue_module_identifier__$d=void 0,__vue_is_functional_template__$d=!1,__vue_component__$d=normalizeComponent({render:__vue_render__$6,staticRenderFns:__vue_staticRenderFns__$6},__vue_inject_styles__$d,__vue_script__$d,__vue_scope_id__$d,__vue_is_functional_template__$d,__vue_module_identifier__$d,!1,createInjector,void 0,void 0);function createCallbackAndChecksIfMapIsLoaded(e,t){var n=!1;window.GoogleMapsCallback=function(){try{e(),n=!0,t&&t()}catch(e){window.console.error("Error executing the GoogleMapsCallback",e)}};var r=setTimeout((function(){var e=setInterval((function(){r&&(clearTimeout(r),r=void 0),null==(window&&window.google&&window.google.maps)||n||(window.GoogleMapsCallback(),n=!0),n&&(clearInterval(e),e=void 0)}),500)}),1e3)}function getPromiseLazyCreatorFn(e,t){return function(n){function r(){return t.isReady=!0,window.google}if(n&&n.load&&n.load.key||n.dynamicLoad)return getLazyValue((function(){return"undefined"==typeof window?new Promise((function(){})).then(r):new Promise((function(t,r){try{createCallbackAndChecksIfMapIsLoaded(t,window[n&&n.load&&n.load.customCallback]),n.dynamicLoad||e(n.load,n.loadCn)}catch(e){r(e)}})).then(r)}));var o=new Promise((function(e){"undefined"!=typeof window&&createCallbackAndChecksIfMapIsLoaded(e,window[n&&n.load&&n.load.customCallback])})).then(r);return getLazyValue((function(){return o}))}}function createGoogleMapsAPIInitializer(){var e=!1;return function(t,n){if("object"!==_typeof$2(t))throw new Error("options should be an object");if("undefined"!=typeof document){var r=_objectSpread2$1({},t),o=r.libraries;if(e)window.console.info("You already started the loading of google maps");else{e=!0;var s="boolean"==typeof n&&n?"https://maps.google.cn":"https://maps.googleapis.com",a=document.createElement("SCRIPT");Array.isArray(o)&&(r.libraries=o.join(",")),r.callback="GoogleMapsCallback";var i=Object.keys(r).map((function(e){return"".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(r[e]))})).join("&"),u="".concat(s,"/maps/api/js?").concat(i);a.setAttribute("src",u),a.setAttribute("async",""),a.setAttribute("defer",""),document.head.appendChild(a)}}}}var googleMapsApiInitializer=createGoogleMapsAPIInitializer(),GoogleMapsApi,components={HeatmapLayer:__vue_component__$4,KmlLayer:__vue_component__$6,Marker:__vue_component__$8,Polyline:__vue_component__$b,Polygon:__vue_component__$a,Circle:__vue_component__$1,Cluster:__vue_component__$2,Rectangle:__vue_component__$c,DrawingManager:__vue_component__$3,InfoWindow:__vue_component__$5,MapLayer:__vue_component__$7,PlaceInput:__vue_component__$9,Autocomplete:__vue_component__,StreetViewPanorama:__vue_component__$d,MapElementMixin:mapElementMixin,MountableMixin:mountableMixin};function gmapVuePluginInstallFn(e,t){var n=_objectSpread2$1({dynamicLoad:!1,installComponents:!0,autoBindAllEvents:!1,load:{libraries:"places"}},t);GoogleMapsApi=new e({data:{isReady:!1}});var r=new e,o=getPromiseLazyCreatorFn(googleMapsApiInitializer,GoogleMapsApi)(n);e.mixin({created:function(){this.$gmapDefaultResizeBus=r,this.$gmapApiPromiseLazy=o,this.$gmapOptions=n}}),e.$gmapDefaultResizeBus=r,e.$gmapApiPromiseLazy=o,e.$gmapOptions=n,n.installComponents&&(e.component("GmapMap",__vue_component__$7),e.component("GmapMarker",__vue_component__$8),e.component("GmapInfoWindow",__vue_component__$5),e.component("GmapHeatmapLayer",__vue_component__$4),e.component("GmapKmlLayer",__vue_component__$6),e.component("GmapPolyline",__vue_component__$b),e.component("GmapPolygon",__vue_component__$a),e.component("GmapCircle",__vue_component__$1),e.component("GmapRectangle",__vue_component__$c),e.component("GmapDrawingManager",__vue_component__$3),e.component("GmapAutocomplete",__vue_component__),e.component("GmapPlaceInput",__vue_component__$9),e.component("GmapStreetViewPanorama",__vue_component__$d))}for(var main={install:gmapVuePluginInstallFn},BASE32_CODES="0123456789bcdefghjkmnpqrstuvwxyz",BASE32_CODES_DICT={},i=0;i<BASE32_CODES.length;i++)BASE32_CODES_DICT[BASE32_CODES.charAt(i)]=i;var ENCODE_AUTO="auto",MIN_LAT=-90,MAX_LAT=90,MIN_LON=-180,MAX_LON=180,SIGFIG_HASH_LENGTH=[0,5,7,8,11,12,13,15,16,17,18],encode$1=function(e,t,n){if(n===ENCODE_AUTO){if("number"==typeof e||"number"==typeof t)throw new Error("string notation required for auto precision.");var r=e.split(".")[1].length,o=t.split(".")[1].length,s=Math.max(r,o);n=SIGFIG_HASH_LENGTH[s]}else void 0===n&&(n=9);for(var a,i=[],u=0,l=0,c=0,p=MAX_LAT,d=MIN_LAT,h=MAX_LON,f=MIN_LON;i.length<n;)if(l%2==0?t>(a=(h+f)/2)?(c=1+(c<<1),f=a):(c=0+(c<<1),h=a):e>(a=(p+d)/2)?(c=1+(c<<1),d=a):(c=0+(c<<1),p=a),l++,5===++u){var m=BASE32_CODES[c];i.push(m),u=0,c=0}return i.join("")},encode_int=function(e,t,n){n=n||52;for(var r,o=0,s=MAX_LAT,a=MIN_LAT,i=MAX_LON,u=MIN_LON,l=0;o<n;)l*=2,o%2==0?t>(r=(i+u)/2)?(l+=1,u=r):i=r:e>(r=(s+a)/2)?(l+=1,a=r):s=r,o++;return l},decode_bbox=function(e){for(var t,n=!0,r=MAX_LAT,o=MIN_LAT,s=MAX_LON,a=MIN_LON,i=0,u=0,l=e.length;u<l;u++){var c=e[u].toLowerCase();i=BASE32_CODES_DICT[c];for(var p=4;p>=0;p--){var d=i>>p&1;n?(t=(s+a)/2,1===d?a=t:s=t):(t=(r+o)/2,1===d?o=t:r=t),n=!n}}return[o,a,r,s]},decode_bbox_int=function(e,t){for(var n=MAX_LAT,r=MIN_LAT,o=MAX_LON,s=MIN_LON,a=0,i=(t=t||52)/2,u=0;u<i;u++)a=get_bit(e,2*(i-u)-1),0===get_bit(e,2*(i-u)-2)?n=(n+r)/2:r=(n+r)/2,0===a?o=(o+s)/2:s=(o+s)/2;return[r,s,n,o]};function get_bit(e,t){return e/Math.pow(2,t)&1}var decode$1=function(e){var t=decode_bbox(e),n=(t[0]+t[2])/2,r=(t[1]+t[3])/2;return{latitude:n,longitude:r,error:{latitude:t[2]-n,longitude:t[3]-r}}},decode_int=function(e,t){var n=decode_bbox_int(e,t),r=(n[0]+n[2])/2,o=(n[1]+n[3])/2;return{latitude:r,longitude:o,error:{latitude:n[2]-r,longitude:n[3]-o}}},neighbor=function(e,t){var n=decode$1(e),r=n.latitude+t[0]*n.error.latitude*2,o=n.longitude+t[1]*n.error.longitude*2;return o=ensure_valid_lon(o),r=ensure_valid_lat(r),encode$1(r,o,e.length)},neighbor_int=function(e,t,n){var r=decode_int(e,n=n||52),o=r.latitude+t[0]*r.error.latitude*2,s=r.longitude+t[1]*r.error.longitude*2;return s=ensure_valid_lon(s),o=ensure_valid_lat(o),encode_int(o,s,n)},neighbors=function(e){var t,n,r=e.length,o=decode$1(e),s=o.latitude,a=o.longitude,i=2*o.error.latitude,u=2*o.error.longitude;function l(e,o){return t=s+e*i,n=ensure_valid_lon(n=a+o*u),t=ensure_valid_lat(t),encode$1(t,n,r)}return[l(1,0),l(1,1),l(0,1),l(-1,1),l(-1,0),l(-1,-1),l(0,-1),l(1,-1)]},neighbors_int=function(e,t){var n,r,o=decode_int(e,t=t||52),s=o.latitude,a=o.longitude,i=2*o.error.latitude,u=2*o.error.longitude;function l(e,o){return n=s+e*i,r=ensure_valid_lon(r=a+o*u),n=ensure_valid_lat(n),encode_int(n,r,t)}return[l(1,0),l(1,1),l(0,1),l(-1,1),l(-1,0),l(-1,-1),l(0,-1),l(1,-1)]},bboxes=function(e,t,n,r,o){for(var s=encode$1(e,t,o=o||9),a=encode$1(n,r,o),i=decode$1(s),u=2*i.error.latitude,l=2*i.error.longitude,c=decode_bbox(s),p=decode_bbox(a),d=Math.round((p[0]-c[0])/u),h=Math.round((p[1]-c[1])/l),f=[],m=0;m<=d;m++)for(var g=0;g<=h;g++)f.push(neighbor(s,[m,g]));return f},bboxes_int=function(e,t,n,r,o){for(var s=encode_int(e,t,o=o||52),a=encode_int(n,r,o),i=decode_int(s,o),u=2*i.error.latitude,l=2*i.error.longitude,c=decode_bbox_int(s,o),p=decode_bbox_int(a,o),d=Math.round((p[0]-c[0])/u),h=Math.round((p[1]-c[1])/l),f=[],m=0;m<=d;m++)for(var g=0;g<=h;g++)f.push(neighbor_int(s,[m,g],o));return f};function ensure_valid_lon(e){return e>MAX_LON?MIN_LON+e%MAX_LON:e<MIN_LON?MAX_LON+e%MAX_LON:e}function ensure_valid_lat(e){return e>MAX_LAT?MAX_LAT:e<MIN_LAT?MIN_LAT:e}var geohash={ENCODE_AUTO:ENCODE_AUTO,encode:encode$1,encode_uint64:encode_int,encode_int:encode_int,decode:decode$1,decode_int:decode_int,decode_uint64:decode_int,decode_bbox:decode_bbox,decode_bbox_uint64:decode_bbox_int,decode_bbox_int:decode_bbox_int,neighbor:neighbor,neighbor_int:neighbor_int,neighbors:neighbors,neighbors_int:neighbors_int,bboxes:bboxes,bboxes_int:bboxes_int},main$1=geohash,setStreaming=lib_5.setStreaming,setQueryOptions$c=lib_5.setQueryOptions,updateQuery$d=lib_5.updateQuery,loadMore$1=lib_5.loadMore,setValue$3=lib_5.setValue,updateComponentProps$3=lib_5.updateComponentProps,setDefaultQuery$8=lib_5.setDefaultQuery,recordResultClick$1=lib_5.recordResultClick,setMapData=lib_5.setMapData,isEqual$h=lib_8.isEqual,getQueryOptions$5=lib_8.getQueryOptions,getClassName$h=lib_8.getClassName,parseHits$2=lib_8.parseHits,getOptionsFromQuery$4=lib_8.getOptionsFromQuery,getResultStats$4=lib_8.getResultStats,MAP_CENTER={lat:37.7749,lng:122.4194},style={width:"100%",height:"100vh",position:"relative"};function getPrecision(e){if(isNaN(e))return 0;for(var t=1,n=0;Math.round(e*t)/t!==e;)t*=10,n+=1;return n}function withDistinctLat(e,t){var n=getPrecision(e.lat),r=n>=6?4:n-2,o=1/Math.pow(10,r)*t;return _extends({},e,{lat:parseFloat((e.lat+o).toFixed(n))})}function getLocationObject(e){switch(Array.isArray(e)?"array":typeof e){case"string":if(e.indexOf(",")>-1){var t=e.split(",");return{lat:parseFloat(t[0]),lng:parseFloat(t[1])}}var n=main$1.decode(e);return{lat:n.latitude,lng:n.longitude};case"array":return{lat:e[1],lng:e[0]};default:return e}}var ReactiveMap={name:"ReactiveMap",props:{className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,react:types.react,size:types.number,sortBy:types.sortBy,URLParams:VueTypes.bool,autoCenter:VueTypes.bool,getMapRef:VueTypes.func.isRequired,getMapPromise:VueTypes.func,center:types.location,defaultCenter:types.location,defaultPin:types.string,defaultZoom:VueTypes.number.def(13),defaultQuery:types.func,innerClass:types.style,loader:types.title,render:types.func,renderItem:types.func,renderError:types.title,pages:VueTypes.number.def(5),currentPage:VueTypes.number.def(0),pagination:VueTypes.bool,showMarkers:VueTypes.bool,defaultSearchAsMove:VueTypes.bool,showSearchAsMove:VueTypes.bool,defaultRadius:types.number,unit:types.string,autoClosePopover:VueTypes.bool,renderMap:VueTypes.func.isRequired,renderPopover:VueTypes.func,calculateMarkers:VueTypes.func,searchAsMoveLabel:VueTypes.string.def("Search as I move the map")},preserveCenter:!1,data:function(){var e=this.$props,t=0;return e.currentPage&&(t=Math.max(e.currentPage-1,0)),this.__state={from:t*e.size,zoom:e.defaultZoom,searchAsMove:e.defaultSearchAsMove,currentPageState:t,mapBoxBounds:null,markersData:null},this.__state},computed:{totalPages:function(){return Math.ceil(this.total/this.$props.size)||0},stats:function(){var e=this.getAllData().resultsToRender;return _extends({},getResultStats$4(this),{currentPage:this.currentPageState,displayedResults:e.length})},hasCustomRender:function(){return hasCustomRenderer(this)}},watch:{defaultZoom:function(e){this.zoom=e},currentPage:function(e,t){t!==e&&e>0&&e<=this.totalPages&&this.setPage(e-1)},defaultQuery:function(e,t){var n=this;isQueryIdentical(e,t,null,this.$props)||this.getMapPromise().then((function(){var t=getQueryOptions$5(n.$props);if(t.from=0,n.$defaultQuery=e(null,n.$props),n.setDefaultQueryForRSAPI(),n.$defaultQuery){var r=n.$defaultQuery||{},o=r.sort,s=r.query;o&&(t.sort=n.$defaultQuery.sort),getOptionsFromQuery$4(n.$defaultQuery)&&(t=_extends({},t,getOptionsFromQuery$4(n.$defaultQuery))),n.setQueryOptions(n.$props.componentId,t,!1);var a={mapBoxBounds:n.mapBoxBounds};n.setMapData(n.componentId,s,!0,!0,a),n.currentPageState=0,n.from=0}}))},promotedResults:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},hidden:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},time:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},hits:function(e,t){this.$emit("data",this.getData()),this.pagination&&this.isLoading&&(t||e)&&this.$emit("page-change",this.currentPageState+1,this.totalPages)},rawData:function(e,t){var n=this;if(!isEqual$h(e,t)){var r=this.promotedResults,o=this.hits,s=parseHits$2(o)||[],a=parseHits$2(r)||[],i=s;if(a.length){var u=a.map((function(e){return e._id})).filter(Boolean);u&&(i=i.filter((function(e){return!u.includes(e._id)}))),i=[].concat(a,i)}i=i.filter((function(e){return!!e[n.dataField]})).map((function(e){var t;return _extends({},e,((t={})[n.dataField]=getLocationObject(e[n.dataField]),t))})),this.filteredResults=this.addNoise(i),this.calculateMarkers&&(this.markersData=this.calculateMarkers({data:this.filteredResults,rawData:this.rawData})||[]),this.$emit("data",this.getData())}},center:function(e,t){if(!isEqual$h(e,t)){var n=!!this.center,r=this.getGeoQuery(this.$props);this.setDefaultQueryForRSAPI();var o={mapBoxBounds:this.mapBoxBounds};this.setMapData(this.componentId,r,n,!0,o)}}},methods:{parseLocation:function(e){return Array.isArray(e)?{lat:Number(e[0]),lng:Number(e[1])}:{lat:e?Number(e.lat):this.defaultCenter.lat,lng:e?Number(void 0===e.lon?e.lng:e.lon):this.defaultCenter.lng}},getDefaultCenter:function(){return this.defaultCenter?this.parseLocation(this.defaultCenter):this.parseLocation(MAP_CENTER)},addNoise:function(e){var t=this,n={},r=[];return e.forEach((function(e){var o=_extends({},e),s=t.parseLocation(e[t.dataField]),a=JSON.stringify(s),i=n[a]||0;o[t.dataField]=i?withDistinctLat(s,i):s,r=[].concat(r,[o]),n[a]=i+1})),r},getPosition:function(e){return e?this.parseLocation(e[this.dataField]):null},getHitsCenter:function(e){var t=this,n=e.map((function(e){return e[t.dataField]}));if(n.length){var r=n.length,o=0,s=0,a=0;n.forEach((function(e){if(e){var t,n,r=getLocationObject(e);t=r.lat*Math.PI/180,n=(void 0!==r.lng?r.lng:r.lon)*Math.PI/180;var i=Math.cos(t)*Math.cos(n),u=Math.cos(t)*Math.sin(n),l=Math.sin(t);o+=i,s+=u,a+=l}})),o/=r,s/=r,a/=r;var i=Math.atan2(s,o),u=Math.sqrt(o*o+s*s);return{lat:180*Math.atan2(a,u)/Math.PI,lng:180*i/Math.PI}}return!1},getCenter:function(e){var t=this;if(this.center)return this.parseLocation(this.center);var n=this.getMapRef();if(n&&"function"==typeof n.getCenter&&this.$options.preserveCenter){var r=n.getCenter();return setTimeout((function(){t.$options.preserveCenter=!1}),100),this.parseLocation({lat:r.lat(),lng:r.lng()})}return e&&e.length?this.autoCenter?this.getHitsCenter(e)||this.getDefaultCenter():e[0]&&e[0][this.dataField]?this.getPosition(e[0]):this.getDefaultCenter():this.getDefaultCenter()},handleZoomChange:function(e){if(e){var t=this.zoom;this.searchAsMove?(this.zoom=e,this.$options.preserveCenter=!0,this.setGeoQuery(!0)):this.zoom=e,t!==e&&this.$emit("zoom-changed",e)}},handleOnDragEnd:function(){this.searchAsMove&&(this.$options.preserveCenter=!0,this.setGeoQuery(!0)),this.$emit("drag-end")},handlePreserveCenter:function(e){this.$options.preserveCenter=e},handleOnIdle:function(){if(this.hits&&this.hits.length&&this.searchAsMove){var e=!!this.center;this.setGeoQuery(e)}this.$emit("idle")},setGeoQuery:function(e){if(void 0===e&&(e=!1),(e||!this.skipBoundingBox&&!this.mapBoxBounds)&&(this.$defaultQuery=this.getGeoQuery(),this.$defaultQuery)){var t=!!this.center,n=this.searchAsMove,r={mapBoxBounds:this.mapBoxBounds};this.setMapData(this.componentId,this.$defaultQuery,t,n,r)}this.skipBoundingBox=!1},getMapParams:function(){var e=this.getData().data,t=this.showMarkers,n=this.defaultPin,r=this.renderPopover,o=this.autoClosePopover,s=this.renderItem;return{resultsToRender:e,center:this.getCenter(e),getPosition:this.getPosition,zoom:this.zoom,renderItem:s,showMarkers:t,defaultPin:n,renderPopover:r,autoClosePopover:o,renderSearchAsMove:this.renderSearchAsMove,handlePreserveCenter:this.handlePreserveCenter,preserveCenter:this.$options.preserveCenter,handleOnDragEnd:this.handleOnDragEnd,handleOnIdle:this.handleOnIdle,handleZoomChange:this.handleZoomChange}},getAllData:function(){var e=this.size,t=this.promotedResults,n=this.customData,r=this.currentPage,o=this.hits,s=parseHits$2(o)||[],a=parseHits$2(t)||[],i=r*e,u=this.filteredResults||[];return this.markersData&&(u=this.markersData),{results:s,resultsToRender:u,customData:n||{},promotedResults:a,loadMore:this.loadMore,base:i,triggerClickAnalytics:this.triggerClickAnalytics}},getData:function(){var e=this.getAllData(),t=e.promotedResults,n=e.aggregationData,r=e.customData,o=e.resultsToRender;return{data:this.withClickIds(o),aggregationData:this.withClickIds(n||[]),promotedData:this.withClickIds(t),rawData:this.rawData,resultStats:this.stats,customData:r}},getComponent:function(){var e=_extends({error:this.error,loading:this.isLoading,loadMore:this.loadMore,triggerClickAnalytics:this.triggerClickAnalytics,setPage:this.setPage},this.getData());return getComponent(e,this)},setPage:function(e){if(e!==this.currentPageState){this.$emit("pageClick",e+1),this.$emit("page-click",e+1);var t=this.size*e,n=getQueryOptions$5(this.$props);n.from=this.$data.from,this.from=t,this.currentPageState=e,this.loadMoreAction(this.componentId,_extends({},n,{from:t}),!1),this.URLParams&&this.setPageURL(this.componentId,e+1,this.componentId,!1,!0)}},setDefaultQueryForRSAPI:function(){if(this.defaultQuery&&"function"==typeof this.defaultQuery){var e=this.defaultQuery();this.setDefaultQuery(this.componentId,e)}},getArrPosition:function(e){return{lat:e.lat,lon:e.lon||e.lng}},getGeoQuery:function(e){void 0===e&&(e=this.$props),this.$defaultQuery=e.defaultQuery?e.defaultQuery():null;var t,n,r,o=this.getMapRef(),s=!(!o||"function"!=typeof o.getBounds)&&o.getBounds();if(s){var a;t=s.getNorthEast().lat(),n=s.getSouthWest().lat(),r=s.getNorthEast().lng();var i={top_left:[s.getSouthWest().lng(),t],bottom_right:[r,n]};this.mapBoxBounds=i;var u={geo_bounding_box:(a={},a[this.dataField]=i,a)};if(this.$defaultQuery){var l=(this.$defaultQuery||{}).query;if(l)return{must:[u,l]}}return u}return this.$defaultQuery?this.$defaultQuery.query:null},getGeoDistanceQuery:function(){var e,t=this.center||this.defaultCenter;return t&&this.defaultRadius?(this.skipBoundingBox=!0,{geo_distance:(e={distance:""+this.defaultRadius+this.unit},e[this.dataField]=this.getArrPosition(t),e)}):null},loadMore:function(){if(this.hits&&!this.pagination&&this.total!==this.hits.length){var e=this.from+this.size,t=getQueryOptions$5(this.$props);this.from=e,this.loadMoreAction(this.componentId,_extends({},t,{from:e}),!0)}},triggerClickAnalytics:function(e,t){var n=t;if(!n){var r=this.getData().data.find((function(t){return t._click_id===e}));r&&r._id&&(n=r._id)}this.recordResultClick(e,n)},withClickIds:function(e){var t=this.getAllData().base;return e.map((function(e,n){return _extends({},e,{_click_id:t+n})}))},toggleSearchAsMove:function(){this.searchAsMove=!this.searchAsMove,this.$emit("search-as-move",this.searchAsMove)},renderErrorComponent:function(){var e=this.$scopedSlots.renderError||this.$props.renderError;return e&&this.error&&!this.isLoading?isFunction$1(e)?e(this.error):e:null},renderSearchAsMove:function(){var e=this.$createElement;return this.showSearchAsMove?e("div",{style:{position:"absolute",bottom:"30px",left:"10px",width:"240px",backgroundColor:"#fff",padding:"8px 10px",boxShadow:"rgba(0,0,0,0.3) 0px 1px 4px -1px",borderRadius:2,zIndex:1e4},attrs:{className:getClassName$h(this.innerClass,"checkboxContainer")||null}},[e(Checkbox,{attrs:{type:"checkbox",id:this.$props.componentId+"-searchasmove",checked:this.searchAsMove,show:!0},class:getClassName$h(this.$props.innerClass,"checkbox"),on:{click:this.toggleSearchAsMove}}),e("label",{attrs:{className:getClassName$h(this.innerClass,"label")||null,for:this.$props.componentId+"-searchasmove"}},[this.searchAsMoveLabel])]):null},renderPagination:function(){return(0,this.$createElement)(Pagination,{attrs:{pages:this.pages,totalPages:this.totalPages,currentPage:this.currentPageState,setPage:this.setPage,innerClass:this.innerClass}})}},created:function(){this.defaultPage>=0&&(this.currentPageState=this.defaultPage,this.from=this.currentPageState*this.$props.size),this.internalComponent=this.$props.componentId+"__internal",this.updateComponentProps(this.componentId,{from:this.from},constants_1$1.reactiveMap),this.updateComponentProps(this.internalComponent,{from:this.from},constants_1$1.reactiveMap),this.setDefaultQueryForRSAPI()},mounted:function(){var e=this;this.getMapPromise().then((function(){e.defaultPage<0&&e.currentPage>0&&e.$props.URLParams&&e.setPageURL(e.$props.componentId,e.currentPage,e.$props.componentId,!1,!0);var t,n=getQueryOptions$5(e.$props);(n.from=e.$data.from,e.$props.sortBy)&&(n.sort=[(t={},t[e.$props.dataField]={order:e.$props.sortBy},t)]);if(e.$defaultQuery=null,e.$props.defaultQuery){if(e.$defaultQuery=e.$props.defaultQuery(),e.setDefaultQueryForRSAPI(),e.$defaultQuery){n=_extends({},n,getOptionsFromQuery$4(e.$defaultQuery)),e.$defaultQuery.sort&&(n.sort=e.$defaultQuery.sort);var r={mapBoxBounds:e.mapBoxBounds};e.$defaultQuery&&(e.setMapData(e.componentId,e.$defaultQuery.query,!0,!1,r),e.setQueryOptions(e.componentId,n))}}else{var o=e.getGeoDistanceQuery();if(o){var s=!!e.center,a=e.searchAsMove,i=e.center||e.defaultCenter,u=e.getArrPosition(i),l={distance:e.defaultRadius,coordinates:u.lat+", "+u.lon};e.setMapData(e.componentId,o,s,a,l)}e.setQueryOptions(e.componentId,n)}}))},render:function(){var e=arguments[0],t=this.$scopedSlots.loader||this.$props.loader;return e("div",{style:_extends({},style,this.$props.style),class:this.$props.className},[this.renderErrorComponent(),this.isLoading&&t,this.hasCustomRender?this.getComponent():null,this.renderMap(this.getMapParams()),this.pagination?this.renderPagination():null])}},mapStateToProps$i=function(e,t){return{defaultPage:e.selectedValues[t.componentId]&&e.selectedValues[t.componentId].value-1||-1,error:e.error[t.componentId],isLoading:e.isLoading[t.componentId],hits:e.hits[t.componentId]&&e.hits[t.componentId].hits,promotedResults:e.promotedResults[t.componentId],customData:e.customData[t.componentId],total:e.hits[t.componentId]&&e.hits[t.componentId].total,time:e.hits[t.componentId]&&e.hits[t.componentId].time,rawData:e.rawData[t.componentId],hidden:e.hits[t.componentId]&&e.hits[t.componentId].hidden}},mapDispatchToProps$4={loadMoreAction:loadMore$1,setPageURL:setValue$3,setQueryOptions:setQueryOptions$c,setStreaming:setStreaming,updateQuery:updateQuery$d,updateComponentProps:updateComponentProps$3,setDefaultQuery:setDefaultQuery$8,recordResultClick:recordResultClick$1,setMapData:setMapData},RMConnected=PreferencesConsumer(ComponentWrapper$1(connect(mapStateToProps$i,mapDispatchToProps$4)(ReactiveMap),{componentType:constants_1$1.reactiveMap,internalComponent:!0}));ReactiveMap.install=function(e){e.component(ReactiveMap.name,RMConnected)},ReactiveMap.componentType=constants_1$1.reactiveMap;var infoWindowMappedProps$1={content:{type:Object,twoWay:!0},options:{type:Object,required:!1,default:function(){return{}}},position:{type:Object,twoWay:!0},zIndex:{type:Number,twoWay:!0}};function bindEvents$1(e,t,n){n.forEach((function(n){(e.$gmapOptions.autoBindAllEvents||e.$listeners[n])&&t.addListener(n,(function(t){e.$emit(n,t)}))}))}function capitalizeFirstLetter$1(e){return e.charAt(0).toUpperCase()+e.slice(1)}function getPropsValues$1(e,t){return Object.keys(t).reduce((function(t,n){return void 0!==e[n]&&(t[n]=e[n]),t}),{})}function watchPrimitiveProperties$1(e,t,n,r){void 0===r&&(r=!1);var o=!1;function s(){o||(o=!0,e.$nextTick((function(){o=!1,n()})))}t.forEach((function(t){e.$watch(t,s,{immediate:r})}))}function bindProps$1(e,t,n){Object.keys(n).forEach((function(r){var o=n[r],s=o.twoWay,a=o.type,i=o.trackProperties;if(!o.noBind){var u="set"+capitalizeFirstLetter$1(r),l="get"+capitalizeFirstLetter$1(r),c=r.toLowerCase()+"_changed",p=e[r];if(void 0===t[u])throw new Error(u+" is not a method of (the Maps object corresponding to) "+e.$options._componentTag);a===Object&&i?watchPrimitiveProperties$1(e,i.map((function(e){return r+"."+e})),(function(){t[u](e[r])}),void 0!==e[r]):e.$watch(r,(function(){var n=e[r];t[u](n)}),{immediate:void 0!==p,deep:a===Object}),s&&(e.$gmapOptions.autoBindAllEvents||e.$listeners[c])&&t.addListener(c,(function(){e.$emit(c,t[l]())}))}}))}var _excluded$i=["options","position"],InfoWindowClusterManager={name:"InfoWindowClusterManager",inject:{$markerPromise:{default:null},$mapPromise:{}},provide:function(){var e=this,t=["domready","closeclick","content_changed"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues$1(e,infoWindowMappedProps$1)),o=(r.options,r.position,_objectWithoutPropertiesLoose(r,_excluded$i));o.content=e.$refs.flyaway,e.$markerPromise&&e.$markerPromise.then((function(n){return e.$markerObject=n,e.$infoWindowObject=new google.maps.InfoWindow(o),bindProps$1(e,e.$infoWindowObject,infoWindowMappedProps$1),bindEvents$1(e,e.$infoWindowObject,t),e._openInfoWindow(),e.$watch("opened",(function(){e._openInfoWindow()})),e.$infoWindowObject}))})).catch((function(e){throw e}));return this.$infoWindowPromise=n,{$infoWindowPromise:n}},props:{content:{type:[String,Object],default:void 0},opened:{type:Boolean,default:!0},position:{type:Object,default:void 0},zIndex:{type:Number,default:0},options:{type:Object,required:!1,default:void 0}},mounted:function(){var e=this.$refs.flyaway;e.parentNode.removeChild(e)},destroyed:function(){this.$infoWindowObject&&this.$infoWindowObject.setMap&&this.$infoWindowObject.setMap(null)},methods:{_openInfoWindow:function(){this.opened?null!==this.$markerObject?this.$infoWindowObject.open(this.$map,this.$markerObject):this.$infoWindowObject.open(this.$map):this.$infoWindowObject.close()}},render:function(){var e=arguments[0];return e("div",[e("div",{ref:"flyaway"},[this.$scopedSlots.default()])])}},InfoWindowWrapper={name:"InfoWindowWrapperClusterManager",props:{id:VueTypes.string,renderPopover:VueTypes.func,infoWindowProps:VueTypes.object,events:VueTypes.object,marker:VueTypes.Object},data:function(){return{infoWindowRef:null}},provide:function(){return{$markerPromise:Promise.resolve(this.marker)}},mounted:function(){this.infoWindowRef=this.$refs[this.id+"-Info-Window"]},methods:{handleClose:function(){this.infoWindowRef.$infoWindowObject.close()}},render:function(){var e=arguments[0],t=this.renderPopover,n=this.events;return e(InfoWindowClusterManager,{ref:this.id+"-Info-Window",props:_extends({},this.infoWindowProps),on:_extends({},n)},[e("div",[t(this.handleClose)])])}},_excluded$j=["options"],isEqual$i=lib_8.isEqual,recordResultClick$2=lib_5.recordResultClick,ClusterMarkers={name:"ClusterMarkers",props:{markers:VueTypes.array,getPosition:VueTypes.func,defaultPin:VueTypes.string,renderItem:VueTypes.func,markerProps:VueTypes.object,handlePreserveCenter:VueTypes.func.isRequired,autoClosePopover:VueTypes.bool,renderPopover:VueTypes.func,highlightMarkerOnHover:VueTypes.bool},inject:{$clusterPromise:{default:null},$mapPromise:{}},data:function(){return{openMarkers:{}}},mounted:function(){this.buildMarkers(this.markers)},destroy:function(){this.buildMarkers([])},watch:{markers:function(e,t){isEqual$i(t,e)||this.buildMarkers(e)}},methods:{triggerAnalytics:function(e,t){this.recordResultClick(e,t)},setOpenMarkers:function(e){this.openMarkers=e},closeMarker:function(e){var t=this.$props,n=t.autoClosePopover,r=t.handlePreserveCenter,o=e.metaData&&e.metaData._id,s=this.openMarkers,a=(s[o],_objectWithoutPropertiesLoose(s,[o].map(_toPropertyKey))),i=n?{}:a;this.setOpenMarkers(i),r(!0),this.$emit("close-marker-popover",e)},openMarker:function(e,t){var n,r,o=this.autoClosePopover,s=this.handlePreserveCenter,a=e.metaData&&e.metaData._id,i=o?((n={})[a]=e,n):_extends({},this.openMarkers,((r={})[a]=e,r));this.setOpenMarkers(i),s(!0),this.triggerAnalytics(a,t),this.$emit("open-marker-popover",e)},removeMarkers:function(){this.$clusterObject&&(this.$clusterObject.clearMarkers(!0),this.$markers=[])},buildMarkers:function(e){var t=this;this.$mapPromise.then((function(n){t.$clusterPromise&&t.$clusterPromise.then((function(r){var o=[],s=[],a={};(t.$markers||[]).forEach((function(e){e.metaData&&e.metaData._id&&(a[e.metaData._id]=!1)})),e.forEach((function(e,r){if(e._id&&void 0!==a[e._id])a[e._id]=!0;else{var s=_extends({},t.markerProps,{metaData:e,map:n,position:t.getPosition(e)});if(t.renderItem){var i=t.renderItem(e);"label"in i&&(s.label=i.label),"icon"in i&&(s.icon=i.icon)}else t.defaultPin&&(s.icon={url:t.defaultPin});s.options;var u=_objectWithoutPropertiesLoose(s,_excluded$j);t.$clusterPromise&&(u.map=null);var l=new google.maps.Marker(u);l.addListener("click",(function(){t.openMarker(l,r)})),o.push(l)}}));var i=[];o.forEach((function(e){i.push(e)})),(t.$markers||[]).forEach((function(e){e.metaData&&e.metaData._id&&(a[e.metaData._id]?i.push(e):s.push(e))})),r.removeMarkers(s),r.addMarkers(o),t.$clusterObject=r,t.$map=n,t.$markers=i}))})).catch((function(e){throw e}))}},render:function(){var e=this,t=arguments[0];return this.renderPopover?t("div",[Object.keys(this.openMarkers).map((function(n){var r=e.openMarkers[n],o=r.metaData;return t(InfoWindowWrapper,{key:n+"-InfoWindow",attrs:{id:n,renderPopover:function(t){return e.renderPopover({item:o,handleClose:function(){t(),e.closeMarker(o)}})},marker:r,infoWindowProps:{zIndex:500},events:{closeclick:function(){return e.closeMarker(r)}}}})}))]):null}},mapDispatchToProps$5={recordResultClick:recordResultClick$2},ClusterManager=connect((function(){return null}),mapDispatchToProps$5)(ClusterMarkers),InfoWindow=components.InfoWindow,InfoWindowWrapper$1={name:"InfoWindowWrapper",props:{id:VueTypes.string,renderPopover:VueTypes.func,infoWindowProps:VueTypes.object,events:VueTypes.object},data:function(){return{infoWindowRef:null}},mounted:function(){this.infoWindowRef=this.$refs[this.id+"-Info-Window"]},methods:{handleClose:function(){this.infoWindowRef.$infoWindowObject.close()}},render:function(){var e=arguments[0],t=this.renderPopover,n=this.events;return e(InfoWindow,{ref:this.id+"-Info-Window",props:_extends({},this.infoWindowProps),on:_extends({},n)},[e("div",[t(this.handleClose)])])}},MapElementMixin=components.MapElementMixin,MarkerWithLabel={name:"MarkerWithLabel",props:{metaData:{type:Object,default:void 0},marker:{type:Object,default:void 0},offsetX:{type:Number,default:0},offsetY:{type:Number,default:0},alignment:{type:String,default:"top"},zIndex:{type:Number,default:50},cssPosition:{type:Boolean,default:!1},renderMarker:VueTypes.func.isRequired,handleMouseOver:VueTypes.func,handleFocus:VueTypes.func,handleMouseOut:VueTypes.func,handleBlur:VueTypes.func,handleClick:VueTypes.func},data:function(){return{opacity:.01}},mixins:[MapElementMixin],inject:{$clusterPromise:{default:null}},computed:{lat:function(){return parseFloat(Number.isNaN(this.marker.lat)?this.marker.latitude:this.marker.lat)},lng:function(){return parseFloat(Number.isNaN(this.marker.lng)?this.marker.longitude:this.marker.lng)},latLng:function(){return this.marker instanceof window.google.maps.LatLng?this.marker:new window.google.maps.LatLng(this.lat,this.lng)}},watch:{marker:function(){var e=this;this.$mapPromise.then((function(){return e.$overlay.setPosition()}))},zIndex:function(){this.$overlay&&this.$overlay.repaint()}},beforeCreate:function(e){return this.$clusterPromise&&(e.map=null),this.$clusterPromise},destroyed:function(){this.$clusterObject?this.$clusterObject.removeMarker(this.$overlay,!0):this.$overlay&&(this.$overlay.setMap(null),this.$overlay=void 0)},provide:function(){var e=this,t=this;return this.$mapPromise.then((function(n){var r=function(e){function n(n){var r;return(r=e.call(this)||this).metaData=t.metaData,r.setMap(n),r.draw=function(){return r.repaint()},r.setPosition=function(){return r.repaint()},r.getVisible=function(){return!0},r}_inheritsLoose(n,e);var r=n.prototype;return r.repaint=function(){var e=t.$el,n=this.getProjection();if(n&&e){var r,o,s=n.fromLatLngToDivPixel(t.latLng);switch(t.alignment){case"top":r=s.x-e.offsetWidth/2,o=s.y-e.offsetHeight;break;case"bottom":r=s.x-e.offsetWidth/2,o=s.y;break;case"left":r=s.x-e.offsetWidth,o=s.y-e.offsetHeight/2;break;case"right":r=s.x,o=s.y-e.offsetHeight/2;break;case"center":r=s.x-e.offsetWidth/2,o=s.y-e.offsetHeight/2;break;case"topleft":case"lefttop":r=s.x-e.offsetWidth,o=s.y-e.offsetHeight;break;case"topright":case"righttop":r=s.x,o=s.y-e.offsetHeight;break;case"bottomleft":case"leftop":r=s.x-e.offsetWidth,o=s.y;break;case"bottomright":case"rightbottom":r=s.x,o=s.y;break;default:throw new Error("Invalid alignment type of custom marker!")}t.cssPosition?e.style.transform="translate("+(r+t.offsetX)+"px, "+(o+t.offsetY)+"px)":(e.style.left=r+t.offsetX+"px",e.style.top=o+t.offsetY+"px"),e.style["z-index"]=t.zIndex}},r.onAdd=function(){this.$clusterObject?this.$clusterObject.removeMarker(this.$overlay,!0):this.$overlay&&(this.$overlay.setMap(null),this.$overlay=void 0);var e=t.$el,n=this.getPanes();e.style.position="absolute",e.style.display="inline-block",e.style.zIndex=t.zIndex,n.overlayLayer.appendChild(e),n.overlayMouseTarget.appendChild(e),this.getDraggable=function(){return!1},this.getPosition=function(){return new window.google.maps.LatLng(t.lat,t.lng)},t.afterCreate(this)},r.onRemove=function(){if(t.$el){var e=window.navigator.userAgent;e.indexOf("MSIE ")>0||e.match(/Trident.*rv\:11\./)?t.$el.parentNode.removeChild(t.$el):t.$el.remove()}},n}(window.google.maps.OverlayView);e.$overlay=new r(n),setTimeout((function(){e.$overlay&&(e.$overlay.repaint(),e.opacity=1)}),100)}))},methods:{afterCreate:function(e){var t=this;this.$clusterPromise&&!this.isMarkerAdded&&this.$clusterPromise.then((function(n){n.addMarker(e),t.$clusterObject=n,t.isMarkerAdded=!0}))}},render:function(){var e=arguments[0];return e("div",{style:{opacity:this.opacity},on:{mouseover:this.handleMouseOver,mouseout:this.handleMouseOut,click:this.handleClick}},[this.renderMarker()])}},_templateObject$q,_templateObject2$c,_templateObject3$8,MapPin=index$1("div")(_templateObject$q||(_templateObject$q=_taggedTemplateLiteralLoose(["\n\theight: 24px;\n\twidth: auto;\n\tbackground-color: #fff;\n\tborder-radius: 2px;\n\tcolor: #222;\n\tbox-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.15);\n\tpadding: 3px 6px;\n\tfont-size: 15px;\n"]))),MapPinArrow=index$1("div")(_templateObject2$c||(_templateObject2$c=_taggedTemplateLiteralLoose(["\n\tborder-color: rgba(0, 0, 0, 0.2);\n\tborder-style: solid;\n\tborder-width: 0 1px 1px 0;\n\tmargin-left: -6px;\n\tbackground-color: #fff;\n\tmargin-top: -6px;\n\twidth: 12px;\n\theight: 12px;\n\t-webkit-transform: rotate(45deg);\n\t-ms-transform: rotate(45deg);\n\ttransform: rotate(45deg);\n"]))),mapPinWrapper=css(_templateObject3$8||(_templateObject3$8=_taggedTemplateLiteralLoose(["\n\t&:hover,\n\t&:focus {\n\t\tz-index: 200;\n\t}\n"]))),Marker=components.Marker,recordResultClick$3=lib_5.recordResultClick,GoogleMapMarker={name:"GoogleMapMarker",props:{index:VueTypes.number,marker:VueTypes.object.isRequired,getPosition:VueTypes.func.isRequired,defaultPin:VueTypes.string,renderItem:VueTypes.func,setOpenMarkers:VueTypes.func.isRequired,handlePreserveCenter:VueTypes.func.isRequired,autoClosePopover:VueTypes.bool,openMarkers:VueTypes.object,renderPopover:VueTypes.func,highlightMarkerOnHover:VueTypes.bool},data:function(){return{zIndex:0,markerIcon:null}},methods:{setIcon:function(e){this.markerIcon=e},increaseMarkerZIndex:function(){var e=this.$props.handlePreserveCenter;this.highlightMarkerOnHover&&(this.zIndex+=1),e(!0)},removeMarkerZIndex:function(){var e=this.$props.handlePreserveCenter;this.highlightMarkerOnHover&&(this.zIndex-=1),e(!0)},openMarker:function(){var e,t,n=this.$props,r=n.setOpenMarkers,o=n.openMarkers,s=n.marker,a=n.autoClosePopover,i=n.handlePreserveCenter,u=s._id;r(a?((e={})[u]=!0,e):_extends({},o,((t={})[u]=!0,t))),i(!0),this.triggerAnalytics(),s.setIcon=this.setIcon,this.$emit("open-marker-popover",s)},closeMarker:function(){var e=this.$props,t=e.setOpenMarkers,n=e.marker,r=e.autoClosePopover,o=e.handlePreserveCenter,s=e.openMarkers,a=n._id,i=(s[a],_objectWithoutPropertiesLoose(s,[a].map(_toPropertyKey)));t(r?{}:i),o(!0),n.setIcon=this.setIcon,this.$emit("close-marker-popover",n)},triggerAnalytics:function(){this.recordResultClick(this.index,this.marker._id)},renderPopoverClick:function(e){var t,n=this,r=this.$createElement,o=this.$props,s=o.getPosition,a=o.renderPopover,i=o.openMarkers;return t={position:s(e),defaultOptions:{pixelOffset:new window.google.maps.Size(0,-30)}},e._id in i?r(InfoWindowWrapper$1,{key:e._id+"-InfoWindow",attrs:{id:e._id,renderPopover:function(t){return a({item:e,handleClose:function(){t(),n.closeMarker()}})},infoWindowProps:{zIndex:500,position:t.position,options:t.defaultOptions},events:{closeclick:function(){return n.closeMarker()}}}}):null}},render:function(){var e=this,t=arguments[0],n=this.$props,r=n.getPosition,o=n.renderItem,s=n.defaultPin,a=n.renderPopover,i=n.markerProps,u=n.marker,l={};if(this.zIndex&&(l.zIndex=window.google.maps.Marker.MAX_ZINDEX+this.zIndex),o){u.setIcon=this.setIcon;var c=o(u);if("label"in c)return t(MarkerWithLabel,{key:u._id,attrs:{metaData:u,marker:r(u),labelAnchor:new window.google.maps.Point(0,30),handleMouseOver:this.increaseMarkerZIndex,handleMouseOut:this.removeMarkerZIndex,handleClick:this.openMarker,zIndex:l.zIndex,renderMarker:function(){return t("div",{attrs:{css:mapPinWrapper}},[t(MapPin,[c.label]),t(MapPinArrow),a?e.renderPopoverClick(u,!0):null])}},props:_extends({},i)});if(!("icon"in c))return t(MarkerWithLabel,{key:u._id,attrs:{metaData:u,marker:r(u),handleClick:this.openMarker,handleMouseOver:this.increaseMarkerZIndex,handleMouseOut:this.removeMarkerZIndex,zIndex:l.zIndex,renderMarker:function(){return t("div",{attrs:{css:mapPinWrapper}},["function"==typeof c.custom?c.custom(u):c.custom,a?e.renderPopoverClick(u,!0):null])}},props:_extends({},i)});l.icon=c.icon}else s&&(l.icon={url:s});return t(Marker,{key:u._id,attrs:{zIndex:l.zIndex,position:r(u),options:{metaData:u},icon:this.markerIcon||l.icon},on:{click:function(){return e.openMarker()},mouseover:this.increaseMarkerZIndex,mouseout:this.removeMarkerZIndex},props:_extends({},i)},[a?this.renderPopoverClick(u):null])}},mapDispatchToProps$6={recordResultClick:recordResultClick$3},GoogleMapMarker$1=connect((function(){return null}),mapDispatchToProps$6)(GoogleMapMarker),Cluster$1=components.Cluster,GoogleMapMarkers={name:"GoogleMapMarkers",props:{resultsToRender:VueTypes.array,getPosition:VueTypes.func,renderItem:VueTypes.func,renderClusterPopover:VueTypes.func,defaultPin:VueTypes.string,autoClosePopover:VueTypes.bool,handlePreserveCenter:VueTypes.func,renderPopover:VueTypes.func,markerProps:VueTypes.object,clusterProps:VueTypes.object,showMarkerClusters:VueTypes.bool,highlightMarkerOnHover:VueTypes.bool},data:function(){return{openMarkers:{},clickedCluster:null,clusterMarkers:[]}},methods:{setOpenMarkers:function(e){this.openMarkers=e},getAdditionalProps:function(){return{position:{lat:this.clickedCluster.getCenter().lat(),lng:this.clickedCluster.getCenter().lng()},defaultOptions:{pixelOffset:new window.google.maps.Size(0,-30)}}},closeMarker:function(){this.clickedCluster=null,this.clusterMarkers=[],this.$emit("close-cluster-popover")}},render:function(){var e=this,t=arguments[0],n=this.$props.resultsToRender,r=this.openMarkers,o={openMarkers:r,setMarkerOnTop:this.setMarkerOnTop,setOpenMarkers:this.setOpenMarkers,getPosition:this.getPosition,renderItem:this.renderItem,defaultPin:this.defaultPin,autoClosePopover:this.autoClosePopover,handlePreserveCenter:this.handlePreserveCenter,renderPopover:this.renderPopover,markerProps:this.markerProps,showMarkerClusters:this.showMarkerClusters,highlightMarkerOnHover:this.highlightMarkerOnHover};return this.showMarkerClusters?t("div",[t(Cluster$1,{props:_extends({},this.clusterProps),on:{click:function(t){var n=t.markers.map((function(e){return e.metaData}));e.clickedCluster=t,e.clusterMarkers=n,e.$emit("open-cluster-popover",e.clusterMarkers)}},ref:"clusterRef"},[t(ClusterManager,{attrs:{getPosition:o.getPosition,markers:n,defaultPin:o.defaultPin,renderItem:o.renderItem,markerProps:o.markerProps,handlePreserveCenter:o.handlePreserveCenter,autoClosePopover:o.autoClosePopover,renderPopover:o.renderPopover,highlightMarkerOnHover:o.highlightMarkerOnHover},on:_extends({},this.$listeners)})]),this.clickedCluster&&this.renderClusterPopover?t(InfoWindowWrapper$1,{attrs:{id:"cluster",infoWindowProps:{zIndex:500,position:this.getAdditionalProps().position,options:this.getAdditionalProps().defaultOptions},renderPopover:function(t){return e.renderClusterPopover({markers:e.clusterMarkers,cluster:e.clickedCluster,handleClose:function(){t(),e.closeMarker()}})},events:{closeclick:this.closeMarker}}}):null]):t("div",[n.map((function(n,r){return t(GoogleMapMarker$1,{attrs:{index:r,marker:n},props:_extends({},o),on:_extends({},e.$listeners)})}))])}},Map=components.MapLayer,ReactiveGoogleMap={name:"ReactiveGoogleMap",props:{className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,defaultQuery:VueTypes.func,loader:types.title,defaultZoom:VueTypes.number.def(13),react:types.react,size:types.number,sortBy:types.sortBy,URLParams:VueTypes.bool,mapProps:VueTypes.object,showMarkers:VueTypes.bool.def(!0),showMarkerClusters:VueTypes.bool.def(!1),searchAsMove:VueTypes.bool.def(!1),searchAsMoveLabel:VueTypes.string,markerProps:VueTypes.object,clusterProps:VueTypes.object,renderItem:VueTypes.func,showSearchAsMove:VueTypes.bool.def(!0),autoClosePopover:VueTypes.bool,pagination:VueTypes.bool,defaultPin:VueTypes.string,autoCenter:VueTypes.bool,defaultCenter:types.location,center:types.location,defaultRadius:types.number,unit:types.string,pages:VueTypes.number.def(5),calculateMarkers:VueTypes.func,highlightMarkerOnHover:VueTypes.bool.def(!0)},created:function(){var e=this;this.mapRefPromiseResolve=null,this.mapRefPromiseRejecter=null,this.mapRefPromise=new Promise((function(t,n){e.mapRefPromiseResolver=t,e.mapRefPromiseRejecter=n}))},methods:{renderMap:function(e){var t=this,n=e.resultsToRender,r=e.center,o=e.zoom,s=e.handleZoomChange,a=e.handleOnDragEnd,i=e.handleOnIdle,u=e.renderSearchAsMove,l=e.handlePreserveCenter,c=e.getPosition,p=e.autoClosePopover,d=e.defaultPin,h=this.$createElement;return h("div",{style:{width:"100%",height:"100%",position:"relative"}},[h(Map,{ref:"mapRef",attrs:{"map-type-id":"terrain",options:{zoomControl:!0},center:r,zoom:o},style:{height:"100%"},props:_extends({},this.mapProps),on:{zoom_changed:s,dragend:a,idle:i}},[this.showMarkers?h(GoogleMapMarkers,{attrs:{resultsToRender:n,getPosition:c,markerProps:this.markerProps,clusterProps:this.clusterProps,handlePreserveCenter:l,highlightMarkerOnHover:this.highlightMarkerOnHover,renderItem:this.$scopedSlots.renderItem?function(){return{custom:t.$scopedSlots.renderItem}}:this.renderItem,defaultPin:d,autoClosePopover:p,renderPopover:this.$scopedSlots.renderPopover,renderClusterPopover:this.$scopedSlots.renderClusterPopover,showMarkerClusters:this.showMarkerClusters},on:_extends({},this.$listeners)}):null]),u()])},getMapRef:function(){return this.mapRef},getMapRefPromise:function(){return this.mapRefPromise},removeMarkers:function(){for(var e,t=this;t;)if(t&&t.$options&&"connect-ClusterMarkers"===t.$options.name)e=t,t=null;else if(t.$children){t=t.$children[0]}else t=null;e&&e.removeMarkers&&e.removeMarkers()}},mounted:function(){var e=this;this.$refs.mapRef&&this.$refs.mapRef.$mapPromise.then((function(t){e.mapRef=t,e.mapRefPromiseResolver(e.mapRef)})).catch(this.mapRefPromiseRejecter)},render:function(){var e=arguments[0];return e(RMConnected,helper$1([{attrs:{getMapRef:this.getMapRef,getMapPromise:this.getMapRefPromise,renderMap:this.renderMap,componentId:this.componentId,className:this.className,dataField:this.dataField,defaultZoom:this.defaultZoom,react:this.react,size:this.size,sortBy:this.sortBy,pagination:this.pagination,uRLParams:this.URLParams,defaultSearchAsMove:this.searchAsMove,showSearchAsMove:this.showSearchAsMove,searchAsMoveLabel:this.searchAsMoveLabel,showMarkers:this.showMarkers,markerProps:this.markerProps,autoClosePopover:this.autoClosePopover,defaultPin:this.defaultPin,defaultQuery:this.defaultQuery,autoCenter:this.autoCenter,defaultCenter:this.defaultCenter,defaultRadius:this.defaultRadius,unit:this.unit,pages:this.pages,center:this.center,loader:this.loader,calculateMarkers:this.calculateMarkers}},{scopedSlots:this.$scopedSlots,on:this.$listeners}]))},install:function(e,t){e.component(ReactiveGoogleMap.name,ReactiveGoogleMap),t&&t.key||console.error("ReactiveSearch: map key is required to use ReactiveGoogleMap component"),e.use(main,{load:{key:t.key,libraries:"places"},installComponents:!1})}};ReactiveGoogleMap.componentType=constants_1$1.reactiveMap;var _excluded$k=["aggs","size"],_excluded2=["query"],_excluded3=["query"],_componentTypeToDefau,X_SEARCH_CLIENT$1="ReactiveSearch Vue",componentsWithoutFilters=[constants_1$1.numberBox,constants_1$1.ratingsFilter],resultComponents=[constants_1$1.reactiveList,constants_1$1.reactiveMap],componentTypeToDefaultValue=(_componentTypeToDefau={},_componentTypeToDefau[constants_1$1.singleList]="",_componentTypeToDefau[constants_1$1.multiList]=[],_componentTypeToDefau[constants_1$1.singleDataList]="",_componentTypeToDefau[constants_1$1.singleDropdownList]="",_componentTypeToDefau[constants_1$1.multiDataList]=[],_componentTypeToDefau[constants_1$1.multiDropdownList]=[],_componentTypeToDefau[constants_1$1.tagCloud]="",_componentTypeToDefau[constants_1$1.toggleButton]="",_componentTypeToDefau[constants_1$1.singleDropdownRange]="",_componentTypeToDefau[constants_1$1.multiDropdownRange]=[],_componentTypeToDefau[constants_1$1.singleRange]="",_componentTypeToDefau[constants_1$1.multiRange]=[],_componentTypeToDefau);function getValue(e,t,n,r){if(e&&e[t])try{return{value:JSON.parse(e[t]),reference:"URL"}}catch(n){return{value:e[t],reference:"URL"}}return{value:n||componentTypeToDefaultValue[r]||null,reference:"DEFAULT"}}function parseValue(e,t){return t.source&&t.source.parseValue?t.source.parseValue(e,t):e}function getDefaultQuery(e,t){var n=parseValue(t,e);if(e.defaultQuery){var r=e.defaultQuery(n,e);return _extends({query:helper_22(r)},helper_23(r))}return e.source.defaultQuery?{query:e.source.defaultQuery(n,e)}:{}}function getCustomQuery(e,t){var n=parseValue(t,e);if(e.customQuery){var r=e.customQuery(n,e);return _extends({query:helper_22(r)},helper_23(r))}return e.source.defaultQuery?{query:e.source.defaultQuery(n,e)}:null}function initReactivesearch(e,t,n){return new Promise((function(r,o){var s=n.url&&""!==n.url.trim()&&!n.credentials?null:n.credentials,a=!n.appbaseConfig||void 0===n.appbaseConfig.enableTelemetry||n.appbaseConfig.enableTelemetry,i=_extends({},n.enableAppbase&&_extends({"X-Search-Client":X_SEARCH_CLIENT$1},!1===a&&{"X-Enable-Telemetry":!1}),n.headers,n.enableAppbase&&n.endpoint&&n.endpoint.headers?n.endpoint.headers:{}),u=n.url&&""!==n.url.trim()?n.url:"https://scalr.api.appbase.io",l=n.transformRequest||null;n.enableAppbase&&n.endpoint&&(n.endpoint.url&&(u=n.endpoint.url),l=function(e){var t=helper_1(e,n.endpoint);return n.transformRequest?n.transformRequest(t):t});var c={url:u,app:n.app,credentials:s,transformRequest:l,type:n.type?n.type:"*",transformResponse:n.transformResponse||null,graphQLUrl:n.graphQLUrl||"",headers:i,analyticsConfig:n.appbaseConfig||null,enableAppbase:n.enableAppbase,endpoint:n.endpoint},p=appbasejs(c);c.transformRequest&&(p.transformRequest=c.transformRequest),c.transformResponse&&(p.transformResponse=c.transformResponse);var d=[],h={},f={},m={},g={},y={},v=[],_={},b=[],$={},C={},O={},T={},S={},w={},P={};e.forEach((function(e){var n=e.source.componentType;d=[].concat(d,[e.componentId]);var r={};Object.keys(e).forEach((function(t){constants_3$1.includes(t)&&(r[t]=e[t])}));var o=!1;e.source.hasInternalComponent&&(o=e.source.hasInternalComponent(e));var s=resultComponents.includes(n),a=e.componentId+"__internal",i=e.filterLabel||e.componentId,u=getValue(t,e.componentId,e.value||e.defaultValue,n),l=u.value,c=u.reference,p=void 0===e.showFilter||e.showFilter;componentsWithoutFilters.includes(n)&&(p=!1),h=valueReducer(h,{type:"SET_VALUE",component:e.componentId,label:i,value:l,reference:c,showFilter:p,URLParams:e.URLParams||!1}),e.customQuery&&"function"==typeof e.customQuery&&(S[e.componentId]=e.customQuery(l,r)),e.defaultQuery&&"function"==typeof e.defaultQuery&&(w[e.componentId]=e.defaultQuery(l,r));var m={};e&&e.source.generateQueryOptions&&(m=_extends({},m,e.source.generateQueryOptions(e)));var v={};if(e.source.highlightQuery&&(v=e.source.highlightQuery(e)),m&&Object.keys(m).length||v&&Object.keys(v).length){var _=m||{},b=_.aggs,$=_.size,C=_objectWithoutPropertiesLoose(_,_excluded$k);if(b&&Object.keys(b).length&&(o=!0,m=_extends({},m,{aggs:b,size:void 0===$?100:$})),C&&Object.keys(C).length||v&&Object.keys(v).length){C||(C={}),v||(v={});var O=_extends({},C,v,{size:$});if(o&&(O=_extends({},C,v)),s){var T=e.currentPage?e.currentPage-1:0;h[e.componentId]&&h[e.componentId].value&&(T=h[e.componentId].value-1||0);var E=e.size||10,R=T*E;r.from=R,O=_extends({},O,v,{size:E,from:R})}m=_extends({},m,O)}}if(e.react||o||s){var k=e.react;(o||s)&&(k=helper_38(k,a)),y=dependencyTreeReducer(y,{type:"WATCH_COMPONENT",component:e.componentId,react:k})}if(o&&!transform_8(e.componentType)){var I=getDefaultQuery(e,l)||{},x=I.query,A=_objectWithoutPropertiesLoose(I,_excluded2);f=queryReducer(f,{type:"SET_QUERY",component:a,query:x}),g=queryOptionsReducer(g,{type:"SET_QUERY_OPTIONS",component:a,options:_extends({},m,A)})}var L=getCustomQuery(e,l)||{},j=L.query,V=_objectWithoutPropertiesLoose(L,_excluded3),M=j;f=queryReducer(f,{type:"SET_QUERY",component:e.componentId,query:M}),g=queryOptionsReducer(g,{type:"SET_QUERY_OPTIONS",component:e.componentId,options:_extends({},V)}),r.componentType=n,P[e.componentId]=r})),T={components:d,dependencyTree:y,queryList:f,queryOptions:g,selectedValues:h,internalValues:{},props:P,customQueries:S,defaultQueries:w},e.forEach((function(e){var t=helper_37(e.componentId,y,f,g),r=t.queryObj,o=t.options,s=["aggs","from","sort"];if(r&&Object.keys(r).length||o&&Object.keys(o).some((function(e){return s.includes(e)}))){var a;(!r||r&&!Object.keys(r).length)&&(r={match_all:{}}),b=[].concat(b,[e.componentId]);var i=_extends({query:_extends({},r)},o,g[e.componentId]);if(m=_extends({},m,((a={})[e.componentId]=i,a)),n.enableAppbase){var u,l=transform_5(e.componentId,transform_3(T,e.componentId,g&&Object.keys(g[e.componentId]).length?{from:g[e.componentId].from}:null));if(l)_=_extends({},_,((u={})[e.componentId]=l,u),transform_2(T,e.componentId,b))}else{var p=c&&c.analyticsConfig&&c.analyticsConfig.userId?c.analyticsConfig.userId+"_"+e:e;v=[].concat(v,[{preference:p},i])}}})),T.queryLog=m;var E=function(e,t){return c.transformResponse&&"function"==typeof c.transformResponse?c.transformResponse(e,t):new Promise((function(t){return t(e)}))},R=function(e){var t=b.map((function(t,n){return new Promise((function(r,o){E(e.responses[n],t).then((function(e){var n,o;e.aggregations&&(C=_extends({},C,((o={})[t]=e.aggregations,o)),O=compositeAggsReducer(O,{type:constants_10,aggregations:e.aggregations,append:!1}));$=_extends({},$,((n={})[t]={hits:e.hits.hits,total:"object"==typeof e.hits.total?e.hits.total.value:e.hits.total,time:e.took},n)),r()})).catch((function(e){return o(e)}))}))}));Promise.all(t).then((function(){T=_extends({},T,{hits:$,aggregations:C}),r(T)}))};if(c.graphQLUrl){(function(e){if(c.transformRequest&&"function"==typeof c.transformRequest){var t=c.transformRequest(e);return t instanceof Promise?t:Promise.resolve(t)}return Promise.resolve(e)})(v).then((function(e){fetchGraphQL(c.graphQLUrl,c.url,c.credentials,c.app,e).then((function(e){R(e)})).catch((function(e){return o(e)}))})).catch((function(e){return o(e)}))}else if(n.enableAppbase&&Object.keys(_).length){v=Object.keys(_).map((function(e){return _[e]}));var k={};c.analyticsConfig&&(k.recordAnalytics=utils_2(c.analyticsConfig.recordAnalytics)?c.analyticsConfig.recordAnalytics:void 0,k.userId=utils_2(c.analyticsConfig.userId)?c.analyticsConfig.userId:void 0,k.enableQueryRules=utils_2(c.analyticsConfig.enableQueryRules)?c.analyticsConfig.enableQueryRules:void 0,k.customEvents=utils_2(c.analyticsConfig.customEvents)?c.analyticsConfig.customEvents:void 0),p.reactiveSearchv3(v,k).then((function(e){!function(e){var t={},n={},o={},s={},a=b.map((function(r){return new Promise((function(a,i){E(e[r],r).then((function(e){if(e){var i,u;if(e.promoted&&(t[r]=e.promoted.map((function(e){return _extends({},e.doc,{_position:e.position})}))),n[r]=e,e.customData&&(o[r]=e.customData),e.settings&&(s[r]=e.settings),e.aggregations)C=_extends({},C,((u={})[r]=e.aggregations,u));var l=e.hits?e.hits:e[r].hits;$=_extends({},$,((i={})[r]={hits:l.hits,total:"object"==typeof l.total?l.total.value:l.total,time:e.took},i)),a()}})).catch((function(e){return i(e)}))}))}));Promise.all(a).then((function(){T=_extends({},T,{hits:$,aggregations:C,compositeAggregations:O,promotedResults:t,settings:s,customData:o,rawData:n}),r(T)}))}(e)})).catch((function(e){return o(e)}))}else p.msearch({type:"*"===c.type?"":c.type,body:v}).then((function(e){R(e)})).catch((function(e){return o(e)}))}))}var version="1.33.12",components$1=[RLConnected,ResultCard,ResultList,ReactiveBase,DSConnected,SBConnected,ListConnected,ListConnected$1,RangeConnected$1,RangeConnected$2,RangeConnected$3,RangeConnected,RcConnected,RcConnected$1,RcConnected$2,TBConnected,ListConnected$2,ListConnected$3,StateProviderConnected,RangeConnected$4];function install(e){components$1.map((function(t){return e.use(t),null}))}"undefined"!=typeof window&&window.Vue&&install(window.Vue);var index$4={version:version,install:install};exports.DataSearch=DSConnected,exports.DynamicRangeSlider=RangeConnected,exports.MultiDropdownList=ListConnected$3,exports.MultiList=ListConnected$1,exports.MultiRange=RangeConnected$2,exports.RangeInput=RangeConnected$4,exports.RangeSlider=RangeConnected$3,exports.ReactiveBase=ReactiveBase,exports.ReactiveComponent=RcConnected,exports.ReactiveComponentPrivate=RcConnected$1,exports.ReactiveGoogleMap=ReactiveGoogleMap,exports.ReactiveList=RLConnected,exports.ResultCard=ResultCard,exports.ResultList=ResultList,exports.SearchBox=SBConnected,exports.SelectedFilters=RcConnected$2,exports.SingleDropdownList=ListConnected$2,exports.SingleList=ListConnected,exports.SingleRange=RangeConnected$1,exports.StateProvider=StateProviderConnected,exports.ToggleButton=TBConnected,exports.componentTypes=constants_1$1,exports.default=index$4,exports.initReactivesearch=initReactivesearch,exports.install=install,exports.version=version,Object.defineProperty(exports,"__esModule",{value:!0})}));
50
+ ***************************************************************************** */function __rest(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}var Cluster=function(){function e(e){var t=e.markers,n=e.position;this.markers=t,n&&(n instanceof google.maps.LatLng?this._position=n:this._position=new google.maps.LatLng(n))}var t=e.prototype;return t.push=function(e){this.markers.push(e)},t.delete=function(){this.marker&&(this.marker.setMap(null),delete this.marker),this.markers.length=0},_createClass(e,[{key:"bounds",get:function(){if(0!==this.markers.length||this._position)return this.markers.reduce((function(e,t){return e.extend(t.getPosition())}),new google.maps.LatLngBounds(this._position,this._position))}},{key:"position",get:function(){return this._position||this.bounds.getCenter()}},{key:"count",get:function(){return this.markers.filter((function(e){return e.getVisible()})).length}}]),e}(),AbstractAlgorithm=function(){function e(e){var t=e.maxZoom,n=void 0===t?16:t;this.maxZoom=n}return e.prototype.noop=function(e){var t=e.markers;return _noop(t)},e}(),_noop=function(e){return e.map((function(e){return new Cluster({position:e.getPosition(),markers:[e]})}))},SuperClusterAlgorithm=function(e){function t(t){var n,r=t.maxZoom,o=t.radius,s=void 0===o?60:o,a=__rest(t,["maxZoom","radius"]);return(n=e.call(this,{maxZoom:r})||this).superCluster=new Supercluster(Object.assign({maxZoom:n.maxZoom,radius:s},a)),n.state={zoom:null},n}_inheritsLoose(t,e);var n=t.prototype;return n.calculate=function(e){var t=!1;if(!fastDeepEqual(e.markers,this.markers)){t=!0,this.markers=[].concat(e.markers);var n=this.markers.map((function(e){return{type:"Feature",geometry:{type:"Point",coordinates:[e.getPosition().lng(),e.getPosition().lat()]},properties:{marker:e}}}));this.superCluster.load(n)}var r={zoom:e.map.getZoom()};return t||this.state.zoom>this.maxZoom&&r.zoom>this.maxZoom||(t=t||!fastDeepEqual(this.state,r)),this.state=r,t&&(this.clusters=this.cluster(e)),{clusters:this.clusters,changed:t}},n.cluster=function(e){var t=e.map;return this.superCluster.getClusters([-180,-90,180,90],Math.round(t.getZoom())).map(this.transformCluster.bind(this))},n.transformCluster=function(e){var t=e.geometry.coordinates,n=t[0],r=t[1],o=e.properties;if(o.cluster)return new Cluster({markers:this.superCluster.getLeaves(o.cluster_id,1/0).map((function(e){return e.properties.marker})),position:new google.maps.LatLng({lat:r,lng:n})});var s=o.marker;return new Cluster({markers:[s],position:s.getPosition()})},t}(AbstractAlgorithm),ClusterStats=function(e,t){this.markers={sum:e.length};var n=t.map((function(e){return e.count})),r=n.reduce((function(e,t){return e+t}),0);this.clusters={count:t.length,markers:{mean:r/t.length,sum:r,min:Math.min.apply(Math,n),max:Math.max.apply(Math,n)}}},DefaultRenderer=function(){function e(){}return e.prototype.render=function(e,t){var n=e.count,r=e.position,o=n>Math.max(10,t.clusters.markers.mean)?"#ff0000":"#0000ff",s=window.btoa('\n <svg fill="'+o+'" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240">\n <circle cx="120" cy="120" opacity=".6" r="70" />\n <circle cx="120" cy="120" opacity=".3" r="90" />\n <circle cx="120" cy="120" opacity=".2" r="110" />\n </svg>');return new google.maps.Marker({position:r,icon:{url:"data:image/svg+xml;base64,"+s,scaledSize:new google.maps.Size(45,45)},label:{text:String(n),color:"rgba(255,255,255,0.9)",fontSize:"12px"},title:"Cluster of "+n+" markers",zIndex:Number(google.maps.Marker.MAX_ZINDEX)+n})},e}();function extend$1(e,t){for(var n in t.prototype)e.prototype[n]=t.prototype[n]}var OverlayViewSafe=function e(){extend$1(e,google.maps.OverlayView)},MarkerClustererEvents;!function(e){e.CLUSTERING_BEGIN="clusteringbegin",e.CLUSTERING_END="clusteringend",e.CLUSTER_CLICK="click"}(MarkerClustererEvents||(MarkerClustererEvents={}));var defaultOnClusterClickHandler=function(e,t,n){n.fitBounds(t.bounds)},MarkerClusterer=function(e){function t(t){var n,r=t.map,o=t.markers,s=void 0===o?[]:o,a=t.algorithm,i=void 0===a?new SuperClusterAlgorithm({}):a,u=t.renderer,l=void 0===u?new DefaultRenderer:u,c=t.onClusterClick,p=void 0===c?defaultOnClusterClickHandler:c;return(n=e.call(this)||this).markers=[].concat(s),n.clusters=[],n.algorithm=i,n.renderer=l,n.onClusterClick=p,r&&n.setMap(r),n}_inheritsLoose(t,e);var n=t.prototype;return n.addMarker=function(e,t){this.markers.includes(e)||(this.markers.push(e),t||this.render())},n.addMarkers=function(e,t){var n=this;e.forEach((function(e){n.addMarker(e,!0)})),t||this.render()},n.removeMarker=function(e,t){var n=this.markers.indexOf(e);return-1!==n&&(e.setMap(null),this.markers.splice(n,1),t||this.render(),!0)},n.removeMarkers=function(e,t){var n=this,r=!1;return e.forEach((function(e){r=n.removeMarker(e,!0)||r})),r&&!t&&this.render(),r},n.clearMarkers=function(e){this.markers.length=0,e||this.render()},n.render=function(){var e=this.getMap();if(e instanceof google.maps.Map&&this.getProjection()){google.maps.event.trigger(this,MarkerClustererEvents.CLUSTERING_BEGIN,this);var t=this.algorithm.calculate({markers:this.markers,map:e,mapCanvasProjection:this.getProjection()}),n=t.clusters,r=t.changed;(r||null==r)&&(this.reset(),this.clusters=n,this.renderClusters()),google.maps.event.trigger(this,MarkerClustererEvents.CLUSTERING_END,this)}},n.onAdd=function(){this.idleListener=this.getMap().addListener("idle",this.render.bind(this)),this.render()},n.onRemove=function(){google.maps.event.removeListener(this.idleListener),this.reset()},n.reset=function(){this.markers.forEach((function(e){return e.setMap(null)})),this.clusters.forEach((function(e){return e.delete()})),this.clusters=[]},n.renderClusters=function(){var e=this,t=new ClusterStats(this.markers,this.clusters),n=this.getMap();this.clusters.forEach((function(r){1===r.markers.length?r.marker=r.markers[0]:(r.marker=e.renderer.render(r,t),e.onClusterClick&&r.marker.addListener("click",(function(t){google.maps.event.trigger(e,MarkerClustererEvents.CLUSTER_CLICK,r),e.onClusterClick(t,r,n)}))),r.marker.setMap(n)}))},t}(OverlayViewSafe),_excluded$6=["options"],script$2={name:"ClusterIcon",mixins:[mapElementMixin],provide:function(){var e=this,t=["click","rightclick","dblclick","drag","dragstart","dragend","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,clusterIconMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$6));if(void 0===MarkerClusterer)throw new Error("MarkerClusterer is not installed! require() it or include it from https://cdnjs.cloudflare.com/ajax/libs/js-marker-clusterer/1.0.0/markerclusterer.js");var s=o.map,a=o.markers,i=o.algorithm,u=o.onClusterClick,l=o.renderer;return e.$clusterObject=new MarkerClusterer({map:s,markers:a,algorithm:i,onClusterClick:u,renderer:l}),bindProps(e,e.$clusterObject,{}),bindEvents(e,e.$clusterObject,t),Object.keys({}).forEach((function(t){({})[t].twoWay&&e.$on(t.toLowerCase()+"_changed",e.reinsertMarkers)})),e.$clusterObject})).catch((function(e){throw e}));return this.$clusterPromise=n,{$clusterPromise:n}},props:{algorithm:{type:Object,default:void 0},onClusterClick:{type:Function,default:void 0},renderer:{type:Object,default:void 0},options:{type:Object,default:void 0}},beforeDestroy:function(){var e=this;this.$children.forEach((function(t){t.$clusterObject===e.$clusterObject&&(t.$clusterObject=null)})),this.$clusterObject&&this.$clusterObject.clearMarkers()},destroyed:function(){this.$clusterObject&&this.$clusterObject.setMap&&this.$clusterObject.setMap(null)},updated:function(){this.$clusterObject&&this.$clusterObject.render()},methods:{reinsertMarkers:function(){var e=[].concat(this.$clusterObject.markers);this.$clusterObject.clearMarkers(),this.$clusterObject.addMarkers(e)}}},__vue_script__$2=script$2,__vue_render__$1=function(){var e=this.$createElement;return(this._self._c||e)("div",[this._t("default")],2)},__vue_staticRenderFns__$1=[],__vue_inject_styles__$2=void 0,__vue_scope_id__$2=void 0,__vue_module_identifier__$2=void 0,__vue_is_functional_template__$2=!1,__vue_component__$2=normalizeComponent({render:__vue_render__$1,staticRenderFns:__vue_staticRenderFns__$1},__vue_inject_styles__$2,__vue_script__$2,__vue_scope_id__$2,__vue_is_functional_template__$2,__vue_module_identifier__$2,!1,void 0,void 0,void 0),_excluded$7=["options"],script$3={name:"DrawingManager",mixins:[mapElementMixin],provide:function(){var e=this,t=this.$mapPromise.then((function(t){e.$map=t;var n=_extends({},e.options,{map:t},getPropsValues(e,drawingManagerMappedProps)),r=(n.options,_objectWithoutPropertiesLoose(n,_excluded$7));e.drawingModes=Object.keys(r).reduce((function(e,t){var n=t.split("Options");return n.length>1&&e.push(n[0]),e}),[]);var o=e.position&&google.maps.ControlPosition[e.position]?google.maps.ControlPosition[e.position]:google.maps.ControlPosition.TOP_LEFT;return r.drawingMode=null,r.drawingControl=!e.$scopedSlots.default,r.drawingControlOptions={drawingModes:e.drawingModes,position:o},e.$drawingManagerObject=new google.maps.drawing.DrawingManager(r),bindProps(e,e.$drawingManagerObject,drawingManagerMappedProps),e.$drawingManagerObject.addListener("overlaycomplete",(function(t){return e.addShape(t)})),e.$map.addListener("click",e.clearSelection),e&&e.finalShapes&&e.finalShapes.length&&e.drawAll(),e.$drawingManagerObject})).catch((function(e){throw e}));return this.$drawingManagerPromise=t,{$drawingManagerPromise:t}},props:{circleOptions:{type:Object,default:void 0},markerOptions:{type:Object,default:void 0},polygonOptions:{type:Object,default:void 0},polylineOptions:{type:Object,default:void 0},rectangleOptions:{type:Object,default:void 0},position:{type:String,default:""},shapes:{type:Array,required:!0}},data:function(){return{selectedShape:null,drawingModes:[],options:{drawingMode:null,drawingControl:!0,drawingControlOptions:{}},finalShapes:[]}},watch:{position:function(e){if(this.$drawingManagerObject){var t={position:e&&google.maps.ControlPosition[e]?google.maps.ControlPosition[e]:google.maps.ControlPosition.TOP_LEFT,drawingModes:this.drawingModes};this.$drawingManagerObject.setOptions({drawingControlOptions:t})}},circleOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({circleOptions:e})},markerOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({markerOptions:e})},polygonOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({polygonOptions:e})},polylineOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({polylineOptions:e})},rectangleOptions:function(e){this.$drawingManagerObject&&this.$drawingManagerObject.setOptions({rectangleOptions:e})}},mounted:function(){this.finalShapes=[].concat(this.shapes)},destroyed:function(){this.clearAll(),this.$drawingManagerObject&&this.$drawingManagerObject.setMap&&this.$drawingManagerObject.setMap(null)},methods:{setDrawingMode:function(e){this.$drawingManagerObject.setDrawingMode(e)},drawAll:function(){var e=this,t={circle:google.maps.Circle,marker:google.maps.Marker,polygon:google.maps.Polygon,polyline:google.maps.Polyline,rectangle:google.maps.Rectangle},n=this;this.finalShapes.forEach((function(r){var o=new t[r.type](r.overlay);o.setMap(e.$map),r.overlay=o,google.maps.event.addListener(o,"click",(function(){n.setSelection(r)}))}))},clearAll:function(){this.clearSelection(),this.finalShapes.forEach((function(e){e.overlay.setMap(null)}))},clearSelection:function(){this.selectedShape&&(this.selectedShape.overlay.set("fillColor","#777"),this.selectedShape.overlay.set("strokeColor","#999"),this.selectedShape.overlay.setEditable(!1),this.selectedShape.overlay.setDraggable(!1),this.selectedShape=null)},setSelection:function(e){this.clearSelection(),this.selectedShape=e,e.overlay.setEditable(!0),e.overlay.setDraggable(!0),this.selectedShape.overlay.set("fillColor","#555"),this.selectedShape.overlay.set("strokeColor","#777")},deleteSelection:function(){if(this.selectedShape){this.selectedShape.overlay.setMap(null);var e=this.finalShapes.indexOf(this.selectedShape);e>-1&&this.finalShapes.splice(e,1)}},addShape:function(e){this.setDrawingMode(null),this.finalShapes.push(e),this.$emit("update:shapes",[].concat(this.finalShapes));var t=this;google.maps.event.addListener(e.overlay,"click",(function(){t.setSelection(e)})),google.maps.event.addListener(e.overlay,"rightclick",(function(){t.deleteSelection()})),this.setSelection(e)}}},__vue_script__$3=script$3,__vue_render__$2=function(){var e=this.$createElement;return(this._self._c||e)("div",[this._t("default",null,{setDrawingMode:this.setDrawingMode,deleteSelection:this.deleteSelection})],2)},__vue_staticRenderFns__$2=[],__vue_inject_styles__$3=void 0,__vue_scope_id__$3=void 0,__vue_module_identifier__$3=void 0,__vue_is_functional_template__$3=!1,__vue_component__$3=normalizeComponent({render:__vue_render__$2,staticRenderFns:__vue_staticRenderFns__$2},__vue_inject_styles__$3,__vue_script__$3,__vue_scope_id__$3,__vue_is_functional_template__$3,__vue_module_identifier__$3,!1,void 0,void 0,void 0),_excluded$8=["options"],script$4={name:"HeatmapLayer",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=[],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:e.$map},getPropsValues(e,heatMapLayerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$8));return e.$heatmapLayerObject=new google.maps.visualization.HeatmapLayer(o),bindProps(e,e.$heatmapLayerObject,heatMapLayerMappedProps),bindEvents(e,e.$heatmapLayerObject,t),e.$heatmapLayerObject})).catch((function(e){throw e}));return this.$heatmapLayerPromise=n,{$heatmapLayerPromise:n}},props:{options:{type:Object,default:function(){}},data:{type:Array,default:void 0}},destroyed:function(){this.$heatmapLayerObject&&this.$heatmapLayerObject.setMap&&this.$heatmapLayerObject.setMap(null)}},__vue_script__$4=script$4,__vue_inject_styles__$4=void 0,__vue_scope_id__$4=void 0,__vue_module_identifier__$4=void 0,__vue_is_functional_template__$4=void 0,__vue_component__$4=normalizeComponent({},__vue_inject_styles__$4,__vue_script__$4,__vue_scope_id__$4,__vue_is_functional_template__$4,__vue_module_identifier__$4,!1,void 0,void 0,void 0),_excluded$9=["options","position"],script$5={name:"InfoWindow",mixins:[mapElementMixin],inject:{$markerPromise:{default:null}},provide:function(){var e=this,t=["domready","closeclick","content_changed"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,infoWindowMappedProps)),o=(r.options,r.position,_objectWithoutPropertiesLoose(r,_excluded$9));return o.content=e.$refs.flyaway,e.$markerPromise&&e.$markerPromise.then((function(t){return e.$markerObject=t,t})),e.$infoWindowObject=new google.maps.InfoWindow(o),bindProps(e,e.$infoWindowObject,infoWindowMappedProps),bindEvents(e,e.$infoWindowObject,t),e._openInfoWindow(),e.$watch("opened",(function(){e._openInfoWindow()})),e.$infoWindowObject})).catch((function(e){throw e}));return this.$infoWindowPromise=n,{$infoWindowPromise:n}},props:{content:{type:[String,Object],default:void 0},opened:{type:Boolean,default:!0},position:{type:Object,default:void 0},zIndex:{type:Number,default:0},options:{type:Object,required:!1,default:void 0}},mounted:function(){var e=this.$refs.flyaway;e.parentNode.removeChild(e)},destroyed:function(){this.$infoWindowObject&&this.$infoWindowObject.setMap&&this.$infoWindowObject.setMap(null)},methods:{_openInfoWindow:function(){this.opened?null!==this.$markerObject?this.$infoWindowObject.open(this.$map,this.$markerObject):this.$infoWindowObject.open(this.$map):this.$infoWindowObject.close()}}},__vue_script__$5=script$5,__vue_render__$3=function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{ref:"flyaway"},[this._t("default")],2)])},__vue_staticRenderFns__$3=[],__vue_inject_styles__$5=void 0,__vue_scope_id__$5=void 0,__vue_module_identifier__$5=void 0,__vue_is_functional_template__$5=!1,__vue_component__$5=normalizeComponent({render:__vue_render__$3,staticRenderFns:__vue_staticRenderFns__$3},__vue_inject_styles__$5,__vue_script__$5,__vue_scope_id__$5,__vue_is_functional_template__$5,__vue_module_identifier__$5,!1,void 0,void 0,void 0),_excluded$a=["options"],script$6={name:"KmlLayer",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","rightclick","dblclick","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,kmlLayerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$a));return e.$kmlLayerObject=new google.maps.KmlLayer(o),bindProps(e,e.$kmlLayerObject,kmlLayerMappedProps),bindEvents(e,e.$kmlLayerObject,t),e.$kmlLayerObject})).catch((function(e){throw e}));return this.$kmlLayerPromise=n,{$kmlLayerPromise:n}},props:{clickable:{type:Boolean,default:!0},map:{type:Object,default:void 0},preserveViewport:{type:Boolean,default:!1},screenOverlays:{type:Boolean,default:!1},suppressInfoWindows:{type:Boolean,default:void 0},url:{type:String,default:""},zIndex:{type:Number,default:void 0},options:{type:Object,default:void 0}},destroyed:function(){this.$kmlLayerObject&&this.$kmlLayerObject.setMap&&this.$kmlLayerObject.setMap(null)}},__vue_script__$6=script$6,__vue_inject_styles__$6=void 0,__vue_scope_id__$6=void 0,__vue_module_identifier__$6=void 0,__vue_is_functional_template__$6=void 0,__vue_component__$6=normalizeComponent({},__vue_inject_styles__$6,__vue_script__$6,__vue_scope_id__$6,__vue_is_functional_template__$6,__vue_module_identifier__$6,!1,void 0,void 0,void 0),mountableMixin={props:["resizeBus"],data:function(){return{_actualResizeBus:null}},created:function(){void 0===this.resizeBus?this.$data._actualResizeBus=this.$gmapDefaultResizeBus:this.$data._actualResizeBus=this.resizeBus},methods:{_resizeCallback:function(){this.resize()},_delayedResizeCallback:function(){var e=this;this.$nextTick((function(){return e._resizeCallback()}))}},watch:{resizeBus:function(e){this.$data._actualResizeBus=e},"$data._actualResizeBus":function(e,t){t&&t.$off("resize",this._delayedResizeCallback),e&&e.$on("resize",this._delayedResizeCallback)}},destroyed:function(){this.$data._actualResizeBus&&this.$data._actualResizeBus.$off("resize",this._delayedResizeCallback)}},_excluded$b=["options"],script$7={name:"MapLayer",mixins:[mountableMixin],provide:function(){var e=this;return this.$mapPromise=new Promise((function(t,n){e.$mapPromiseDeferred={resolve:t,reject:n}})),{$mapPromise:this.$mapPromise}},props:{center:{type:Object,required:!0},zoom:{type:Number,required:!1,default:void 0},heading:{type:Number,default:void 0},mapTypeId:{type:String,default:"roadmap"},tilt:{type:Number,default:void 0},options:{type:Object,default:void 0}},data:function(){return{recyclePrefix:"__gmc__"}},computed:{finalLat:function(){return this.center&&"function"==typeof this.center.lat?this.center.lat():this.center.lat},finalLng:function(){return this.center&&"function"==typeof this.center.lng?this.center.lng():this.center.lng},finalLatLng:function(){return{lat:this.finalLat,lng:this.finalLng}}},watch:{zoom:function(e){this.$mapObject&&this.$mapObject.setZoom(e)}},beforeDestroy:function(){var e=this.getRecycleKey();window[e]&&(window[e].div=this.$mapObject.getDiv())},mounted:function(){var e=this;return this.$gmapApiPromiseLazy().then((function(){var t=e.$refs["vue-map"],n=_extends({},e.options,getPropsValues(e,mapMappedProps)),r=(n.options,_objectWithoutPropertiesLoose(n,_excluded$b)),o=e.getRecycleKey();return e&&e.options&&e.options.recycle&&window[o]?(t.appendChild(window[o].div),e.$mapObject=window[o].map,e.$mapObject.setOptions(r)):(e.$mapObject=new google.maps.Map(t,r),window[o]={map:e.$mapObject}),bindProps(e,e.$mapObject,mapMappedProps),bindEvents(e,e.$mapObject,["bounds_changed","click","dblclick","drag","dragend","dragstart","idle","mousemove","mouseout","mouseover","resize","rightclick","tilesloaded"]),twoWayBindingWrapper((function(t,n,r){e.$mapObject.addListener("center_changed",(function(){r()&&e.$emit("center_changed",e.$mapObject.getCenter()),n()}));watchPrimitiveProperties(e,["finalLat","finalLng"],(function(){t(),e.$mapObject.setCenter(e.finalLatLng)}))})),e.$mapObject.addListener("zoom_changed",(function(){e.$emit("zoom_changed",e.$mapObject.getZoom())})),e.$mapObject.addListener("bounds_changed",(function(){e.$emit("bounds_changed",e.$mapObject.getBounds())})),e.$mapPromiseDeferred.resolve(e.$mapObject),e.$mapObject})).catch((function(e){throw e}))},methods:{resize:function(){this.$mapObject&&google.maps.event.trigger(this.$mapObject,"resize")},resizePreserveCenter:function(){if(this.$mapObject){var e=this.$mapObject.getCenter();google.maps.event.trigger(this.$mapObject,"resize"),this.$mapObject.setCenter(e)}},_resizeCallback:function(){this.resizePreserveCenter()},panBy:function(){var e;this.$mapObject&&(e=this.$mapObject).panBy.apply(e,arguments)},panTo:function(){var e;this.$mapObject&&(e=this.$mapObject).panTo.apply(e,arguments)},panToBounds:function(){var e;this.$mapObject&&(e=this.$mapObject).panToBounds.apply(e,arguments)},fitBounds:function(){var e;this.$mapObject&&(e=this.$mapObject).fitBounds.apply(e,arguments)},getRecycleKey:function(){return this&&this.options&&this.options.recycle?this.recyclePrefix+this.options.recycle:this.recyclePrefix}},destroyed:function(){this.$mapObject&&this.$mapObject.setMap&&this.$mapObject.setMap(null)}},isOldIE="undefined"!=typeof navigator&&/msie [6-9]\\b/.test(navigator.userAgent.toLowerCase()),HEAD;function createInjector(e){return function(e,t){return addStyle(e,t)}}var styles={};function addStyle(e,t){var n=isOldIE?t.media||"default":e,r=styles[n]||(styles[n]={ids:new Set,styles:[]});if(!r.ids.has(e)){r.ids.add(e);var o=t.source;if(t.map&&(o+="\n/*# sourceURL="+t.map.sources[0]+" */",o+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(t.map))))+" */"),r.element||(r.element=document.createElement("style"),r.element.type="text/css",t.media&&r.element.setAttribute("media",t.media),void 0===HEAD&&(HEAD=document.head||document.getElementsByTagName("head")[0]),HEAD.appendChild(r.element)),"styleSheet"in r.element)r.styles.push(o),r.element.styleSheet.cssText=r.styles.filter(Boolean).join("\n");else{var s=r.ids.size-1,a=document.createTextNode(o),i=r.element.childNodes;i[s]&&r.element.removeChild(i[s]),i.length?r.element.insertBefore(a,i[s]):r.element.appendChild(a)}}}var __vue_script__$7=script$7,__vue_render__$4=function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"vue-map-container"},[t("div",{ref:"vue-map",staticClass:"vue-map"}),this._v(" "),t("div",{staticClass:"vue-map-hidden"},[this._t("default")],2),this._v(" "),this._t("visible")],2)},__vue_staticRenderFns__$4=[],__vue_inject_styles__$7=function(e){e&&e("data-v-58f81a38_0",{source:".vue-map-container{position:relative}.vue-map-container .vue-map{left:0;right:0;top:0;bottom:0;position:absolute}.vue-map-hidden{display:none}",map:void 0,media:void 0})},__vue_scope_id__$7=void 0,__vue_module_identifier__$7=void 0,__vue_is_functional_template__$7=!1,__vue_component__$7=normalizeComponent({render:__vue_render__$4,staticRenderFns:__vue_staticRenderFns__$4},__vue_inject_styles__$7,__vue_script__$7,__vue_scope_id__$7,__vue_is_functional_template__$7,__vue_module_identifier__$7,!1,createInjector,void 0,void 0),_excluded$c=["options"],script$8={name:"MarkerIcon",mixins:[mapElementMixin],inject:{$clusterPromise:{default:null}},provide:function(){var e=this,t=["click","rightclick","dblclick","drag","dragstart","dragend","mouseup","mousedown","mouseover","mouseout"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,markerMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$c));return e.$clusterPromise&&(o.map=null),e.$markerObject=new google.maps.Marker(o),bindProps(e,e.$markerObject,markerMappedProps),bindEvents(e,e.$markerObject,t),e.$markerObject.addListener("dragend",(function(){var t=e.$markerObject.getPosition();e.$emit("update:position",{lat:t.lat(),lng:t.lng()})})),e.$clusterPromise&&e.$clusterPromise.then((function(t){t.addMarker(e.$markerObject),e.$clusterObject=t})),e.$markerObject})).catch((function(e){throw e}));return this.$markerPromise=n,{$markerPromise:n}},props:{animation:{type:Number,default:void 0},attribution:{type:Object,default:void 0},clickable:{type:Boolean,default:!0},cursor:{type:String,default:void 0},draggable:{type:Boolean,default:!1},icon:{type:[String,Object],default:void 0},label:{type:[String,Object],default:void 0},opacity:{type:Number,default:1},options:{type:Object,default:void 0},place:{type:Object,default:void 0},position:{type:Object,default:void 0},shape:{type:Object,default:void 0},title:{type:String,default:void 0},visible:{type:Boolean,default:!0},zIndex:{type:Number,default:void 0}},destroyed:function(){this.$markerObject&&(this.$clusterObject?this.$clusterObject.removeMarker(this.$markerObject,!0):this.$markerObject&&this.$markerObject.setMap&&this.$markerObject.setMap(null))},render:function(e){return this.$slots.default&&0!==this.$slots.default.length?1===this.$slots.default.length?this.$slots.default[0]:e("div",this.$slots.default):""}},__vue_script__$8=script$8,__vue_inject_styles__$8=void 0,__vue_scope_id__$8=void 0,__vue_module_identifier__$8=void 0,__vue_is_functional_template__$8=void 0,__vue_component__$8=normalizeComponent({},__vue_inject_styles__$8,__vue_script__$8,__vue_scope_id__$8,__vue_is_functional_template__$8,__vue_module_identifier__$8,!1,void 0,void 0,void 0),_excluded$d=["placeholder","place","defaultPlace","className","label","selectFirstOnEnter"],script$9={name:"PlaceInput",props:{bounds:{type:Object,default:void 0},defaultPlace:{type:String,default:""},componentRestrictions:{type:Object,default:null},types:{type:Array,default:void 0},placeholder:{required:!1,type:String,default:void 0},className:{required:!1,type:String,default:void 0},label:{required:!1,type:String,default:null},selectFirstOnEnter:{require:!1,type:Boolean,default:!1}},created:function(){window.console.warn("The PlaceInput class is deprecated! Please consider using the Autocomplete input instead, it will be removed in the next major release of this plugin.")},mounted:function(){var e=this,t=this.$refs.input;t.value=this.defaultPlace,this.$watch("defaultPlace",(function(){t.value=e.defaultPlace})),this.$gmapApiPromiseLazy().then((function(){var t=getPropsValues(e,placeInputMappedProps);if(e.selectFirstOnEnter&&downArrowSimulator(e.$refs.input),"function"!=typeof google.maps.places.Autocomplete)throw new Error("google.maps.places.Autocomplete is undefined. Did you add 'places' to libraries when loading Google Maps?");e.$autoCompleter=new google.maps.places.Autocomplete(e.$refs.input,t);var n=_objectWithoutPropertiesLoose(placeInputMappedProps,_excluded$d);bindProps(e,e.$autoCompleter,n),e.$autoCompleter.addListener("place_changed",(function(){e.$emit("place_changed",e.$autoCompleter.getPlace())}))}))},destroyed:function(){this.$autoCompleter&&this.$autoCompleter.setMap&&this.$autoCompleter.setMap(null)}},__vue_script__$9=script$9,__vue_render__$5=function(){var e=this.$createElement,t=this._self._c||e;return t("label",[t("span",{domProps:{textContent:this._s(this.label)}}),this._v(" "),t("input",{ref:"input",class:this.className,attrs:{type:"text",placeholder:this.placeholder}})])},__vue_staticRenderFns__$5=[],__vue_inject_styles__$9=void 0,__vue_scope_id__$9=void 0,__vue_module_identifier__$9=void 0,__vue_is_functional_template__$9=!1,__vue_component__$9=normalizeComponent({render:__vue_render__$5,staticRenderFns:__vue_staticRenderFns__$5},__vue_inject_styles__$9,__vue_script__$9,__vue_scope_id__$9,__vue_is_functional_template__$9,__vue_module_identifier__$9,!1,void 0,void 0,void 0),_excluded$e=["options","path","paths"],script$a={name:"PolygonShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,polygonMappedProps)),o=(r.options,r.path,r.paths,_objectWithoutPropertiesLoose(r,_excluded$e));e.$polygonObject=new google.maps.Polygon(o),bindProps(e,e.$polygonObject,polygonMappedProps),bindEvents(e,e.$polygonObject,t);var s=function(){};return e.$watch("paths",(function(t){if(t){s(),e.$polygonObject.setPaths(t);for(var n=function(){e.$emit("paths_changed",e.$polygonObject.getPaths())},r=[],o=e.$polygonObject.getPaths(),a=0;a<o.getLength();a+=1){var i=o.getAt(a);r.push([i,i.addListener("insert_at",n)]),r.push([i,i.addListener("remove_at",n)]),r.push([i,i.addListener("set_at",n)])}r.push([o,o.addListener("insert_at",n)]),r.push([o,o.addListener("remove_at",n)]),r.push([o,o.addListener("set_at",n)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$watch("path",(function(t){if(t){s(),e.$polygonObject.setPaths(t);var n=e.$polygonObject.getPath(),r=[],o=function(){e.$emit("path_changed",e.$polygonObject.getPath())};r.push([n,n.addListener("insert_at",o)]),r.push([n,n.addListener("remove_at",o)]),r.push([n,n.addListener("set_at",o)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$polygonObject})).catch((function(e){throw e}));return this.$polygonPromise=n,{$polygonPromise:n}},props:{deepWatch:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},fillColor:{type:String,default:""},fillOpacity:{type:Number,default:1},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokePosition:{type:Number,default:0},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0},path:{type:Array,noBind:!0,default:void 0},paths:{type:Array,noBind:!0,default:void 0}},destroyed:function(){this.$polygonObject&&this.$polygonObject.setMap&&this.$polygonObject.setMap(null)}},__vue_script__$a=script$a,__vue_inject_styles__$a=void 0,__vue_scope_id__$a=void 0,__vue_module_identifier__$a=void 0,__vue_is_functional_template__$a=void 0,__vue_component__$a=normalizeComponent({},__vue_inject_styles__$a,__vue_script__$a,__vue_scope_id__$a,__vue_is_functional_template__$a,__vue_module_identifier__$a,!1,void 0,void 0,void 0),_excluded$f=["options"],script$b={name:"PolylineShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,polylineMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$f));e.$polylineObject=new google.maps.Polyline(o),bindProps(e,e.$polylineObject,polylineMappedProps),bindEvents(e,e.$polylineObject,t);var s=function(){};return e.$watch("path",(function(t){if(t){s(),e.$polylineObject.setPath(t);var n=e.$polylineObject.getPath(),r=[],o=function(){e.$emit("path_changed",e.$polylineObject.getPath())};r.push([n,n.addListener("insert_at",o)]),r.push([n,n.addListener("remove_at",o)]),r.push([n,n.addListener("set_at",o)]),s=function(){r.forEach((function(e){var t=e[1];google.maps.event.removeListener(t)}))}}}),{deep:e.deepWatch,immediate:!0}),e.$polylineObject})).catch((function(e){throw e}));return this.$polylinePromise=n,{$polylinePromise:n}},props:{deepWatch:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},draggable:{type:Boolean},editable:{type:Boolean},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0},path:{type:Array,default:void 0}},destroyed:function(){this.$polylineObject&&this.$polylineObject.setMap&&this.$polylineObject.setMap(null)}},__vue_script__$b=script$b,__vue_inject_styles__$b=void 0,__vue_scope_id__$b=void 0,__vue_module_identifier__$b=void 0,__vue_is_functional_template__$b=void 0,__vue_component__$b=normalizeComponent({},__vue_inject_styles__$b,__vue_script__$b,__vue_scope_id__$b,__vue_is_functional_template__$b,__vue_module_identifier__$b,!1,void 0,void 0,void 0),_excluded$g=["options"],script$c={name:"RectangleShape",mixins:[mapElementMixin],render:function(){return""},provide:function(){var e=this,t=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues(e,rectangleMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$g));return e.$rectangleObject=new google.maps.Rectangle(o),bindProps(e,e.$rectangleObject,rectangleMappedProps),bindEvents(e,e.$rectangleObject,t),e.$rectangleObject})).catch((function(e){throw e}));return this.$rectanglePromise=n,{$rectanglePromise:n}},props:{bounds:{type:Object,default:void 0},clickable:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},fillColor:{type:String,default:""},fillOpacity:{type:Number,default:1},strokeColor:{type:String,default:""},strokeOpacity:{type:Number,default:1},strokePosition:{type:Number,default:0},strokeWeight:{type:Number,default:1},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0}},destroyed:function(){this.$rectangleObject&&this.$rectangleObject.setMap&&this.$rectangleObject.setMap(null)}},__vue_script__$c=script$c,__vue_inject_styles__$c=void 0,__vue_scope_id__$c=void 0,__vue_module_identifier__$c=void 0,__vue_is_functional_template__$c=void 0,__vue_component__$c=normalizeComponent({},__vue_inject_styles__$c,__vue_script__$c,__vue_scope_id__$c,__vue_is_functional_template__$c,__vue_module_identifier__$c,!1,void 0,void 0,void 0),_excluded$h=["options"],script$d={name:"StreetViewPanorama",mixins:[mountableMixin],provide:function(){var e=this;return this.$panoPromise=new Promise((function(t,n){e.$panoPromiseDeferred={resolve:t,reject:n}})),{$panoPromise:this.$panoPromise,$mapPromise:this.$panoPromise}},props:{zoom:{type:Number,default:void 0},pov:{type:Object,default:void 0},position:{type:Object,default:void 0},pano:{type:String,default:void 0},motionTracking:{type:Boolean},visible:{type:Boolean,default:!0},options:{type:Object,default:void 0}},replace:!1,computed:{finalLat:function(){return this.position&&"function"==typeof this.position.lat?this.position.lat():this.position.lat},finalLng:function(){return this.position&&"function"==typeof this.position.lng?this.position.lng():this.position.lng},finalLatLng:function(){return{lat:this.finalLat,lng:this.finalLng}}},watch:{zoom:function(e){this.$panoObject&&this.$panoObject.setZoom(e)}},mounted:function(){var e=this,t=["closeclick","status_changed"];return this.$gmapApiPromiseLazy().then((function(){var n=e.$refs["vue-street-view-pano"],r=_extends({},e.options,getPropsValues(e,streetViewPanoramaMappedProps)),o=(r.options,_objectWithoutPropertiesLoose(r,_excluded$h));return e.$panoObject=new google.maps.StreetViewPanorama(n,o),bindProps(e,e.$panoObject,streetViewPanoramaMappedProps),bindEvents(e,e.$panoObject,t),twoWayBindingWrapper((function(t,n,r){t(),e.$panoObject.addListener("position_changed",(function(){r()&&e.$emit("position_changed",e.$panoObject.getPosition()),n()}));watchPrimitiveProperties(e,["finalLat","finalLng"],(function(){t(),e.$panoObject.setPosition(e.finalLatLng)}))})),e.$panoPromiseDeferred.resolve(e.$panoObject),e.$panoPromise})).catch((function(e){throw e}))},methods:{resize:function(){this.$panoObject&&google.maps.event.trigger(this.$panoObject,"resize")}},destroyed:function(){this.$panoObject&&this.$panoObject.setMap&&this.$panoObject.setMap(null)}},__vue_script__$d=script$d,__vue_render__$6=function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"vue-street-view-pano-container"},[t("div",{ref:"vue-street-view-pano",staticClass:"vue-street-view-pano"}),this._v(" "),this._t("default")],2)},__vue_staticRenderFns__$6=[],__vue_inject_styles__$d=function(e){e&&e("data-v-32786ad9_0",{source:".vue-street-view-pano-container{position:relative}.vue-street-view-pano-container .vue-street-view-pano{left:0;right:0;top:0;bottom:0;position:absolute}",map:void 0,media:void 0})},__vue_scope_id__$d=void 0,__vue_module_identifier__$d=void 0,__vue_is_functional_template__$d=!1,__vue_component__$d=normalizeComponent({render:__vue_render__$6,staticRenderFns:__vue_staticRenderFns__$6},__vue_inject_styles__$d,__vue_script__$d,__vue_scope_id__$d,__vue_is_functional_template__$d,__vue_module_identifier__$d,!1,createInjector,void 0,void 0);function createCallbackAndChecksIfMapIsLoaded(e,t){var n=!1;window.GoogleMapsCallback=function(){try{e(),n=!0,t&&t()}catch(e){window.console.error("Error executing the GoogleMapsCallback",e)}};var r=setTimeout((function(){var e=setInterval((function(){r&&(clearTimeout(r),r=void 0),null==(window&&window.google&&window.google.maps)||n||(window.GoogleMapsCallback(),n=!0),n&&(clearInterval(e),e=void 0)}),500)}),1e3)}function getPromiseLazyCreatorFn(e,t){return function(n){function r(){return t.isReady=!0,window.google}if(n&&n.load&&n.load.key||n.dynamicLoad)return getLazyValue((function(){return"undefined"==typeof window?new Promise((function(){})).then(r):new Promise((function(t,r){try{createCallbackAndChecksIfMapIsLoaded(t,window[n&&n.load&&n.load.customCallback]),n.dynamicLoad||e(n.load,n.loadCn)}catch(e){r(e)}})).then(r)}));var o=new Promise((function(e){"undefined"!=typeof window&&createCallbackAndChecksIfMapIsLoaded(e,window[n&&n.load&&n.load.customCallback])})).then(r);return getLazyValue((function(){return o}))}}function createGoogleMapsAPIInitializer(){var e=!1;return function(t,n){if("object"!==_typeof$2(t))throw new Error("options should be an object");if("undefined"!=typeof document){var r=_objectSpread2$1({},t),o=r.libraries;if(e)window.console.info("You already started the loading of google maps");else{e=!0;var s="boolean"==typeof n&&n?"https://maps.google.cn":"https://maps.googleapis.com",a=document.createElement("SCRIPT");Array.isArray(o)&&(r.libraries=o.join(",")),r.callback="GoogleMapsCallback";var i=Object.keys(r).map((function(e){return"".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(r[e]))})).join("&"),u="".concat(s,"/maps/api/js?").concat(i);a.setAttribute("src",u),a.setAttribute("async",""),a.setAttribute("defer",""),document.head.appendChild(a)}}}}var googleMapsApiInitializer=createGoogleMapsAPIInitializer(),GoogleMapsApi,components={HeatmapLayer:__vue_component__$4,KmlLayer:__vue_component__$6,Marker:__vue_component__$8,Polyline:__vue_component__$b,Polygon:__vue_component__$a,Circle:__vue_component__$1,Cluster:__vue_component__$2,Rectangle:__vue_component__$c,DrawingManager:__vue_component__$3,InfoWindow:__vue_component__$5,MapLayer:__vue_component__$7,PlaceInput:__vue_component__$9,Autocomplete:__vue_component__,StreetViewPanorama:__vue_component__$d,MapElementMixin:mapElementMixin,MountableMixin:mountableMixin};function gmapVuePluginInstallFn(e,t){var n=_objectSpread2$1({dynamicLoad:!1,installComponents:!0,autoBindAllEvents:!1,load:{libraries:"places"}},t);GoogleMapsApi=new e({data:{isReady:!1}});var r=new e,o=getPromiseLazyCreatorFn(googleMapsApiInitializer,GoogleMapsApi)(n);e.mixin({created:function(){this.$gmapDefaultResizeBus=r,this.$gmapApiPromiseLazy=o,this.$gmapOptions=n}}),e.$gmapDefaultResizeBus=r,e.$gmapApiPromiseLazy=o,e.$gmapOptions=n,n.installComponents&&(e.component("GmapMap",__vue_component__$7),e.component("GmapMarker",__vue_component__$8),e.component("GmapInfoWindow",__vue_component__$5),e.component("GmapHeatmapLayer",__vue_component__$4),e.component("GmapKmlLayer",__vue_component__$6),e.component("GmapPolyline",__vue_component__$b),e.component("GmapPolygon",__vue_component__$a),e.component("GmapCircle",__vue_component__$1),e.component("GmapRectangle",__vue_component__$c),e.component("GmapDrawingManager",__vue_component__$3),e.component("GmapAutocomplete",__vue_component__),e.component("GmapPlaceInput",__vue_component__$9),e.component("GmapStreetViewPanorama",__vue_component__$d))}for(var main={install:gmapVuePluginInstallFn},BASE32_CODES="0123456789bcdefghjkmnpqrstuvwxyz",BASE32_CODES_DICT={},i=0;i<BASE32_CODES.length;i++)BASE32_CODES_DICT[BASE32_CODES.charAt(i)]=i;var ENCODE_AUTO="auto",MIN_LAT=-90,MAX_LAT=90,MIN_LON=-180,MAX_LON=180,SIGFIG_HASH_LENGTH=[0,5,7,8,11,12,13,15,16,17,18],encode$1=function(e,t,n){if(n===ENCODE_AUTO){if("number"==typeof e||"number"==typeof t)throw new Error("string notation required for auto precision.");var r=e.split(".")[1].length,o=t.split(".")[1].length,s=Math.max(r,o);n=SIGFIG_HASH_LENGTH[s]}else void 0===n&&(n=9);for(var a,i=[],u=0,l=0,c=0,p=MAX_LAT,d=MIN_LAT,h=MAX_LON,f=MIN_LON;i.length<n;)if(l%2==0?t>(a=(h+f)/2)?(c=1+(c<<1),f=a):(c=0+(c<<1),h=a):e>(a=(p+d)/2)?(c=1+(c<<1),d=a):(c=0+(c<<1),p=a),l++,5===++u){var m=BASE32_CODES[c];i.push(m),u=0,c=0}return i.join("")},encode_int=function(e,t,n){n=n||52;for(var r,o=0,s=MAX_LAT,a=MIN_LAT,i=MAX_LON,u=MIN_LON,l=0;o<n;)l*=2,o%2==0?t>(r=(i+u)/2)?(l+=1,u=r):i=r:e>(r=(s+a)/2)?(l+=1,a=r):s=r,o++;return l},decode_bbox=function(e){for(var t,n=!0,r=MAX_LAT,o=MIN_LAT,s=MAX_LON,a=MIN_LON,i=0,u=0,l=e.length;u<l;u++){var c=e[u].toLowerCase();i=BASE32_CODES_DICT[c];for(var p=4;p>=0;p--){var d=i>>p&1;n?(t=(s+a)/2,1===d?a=t:s=t):(t=(r+o)/2,1===d?o=t:r=t),n=!n}}return[o,a,r,s]},decode_bbox_int=function(e,t){for(var n=MAX_LAT,r=MIN_LAT,o=MAX_LON,s=MIN_LON,a=0,i=(t=t||52)/2,u=0;u<i;u++)a=get_bit(e,2*(i-u)-1),0===get_bit(e,2*(i-u)-2)?n=(n+r)/2:r=(n+r)/2,0===a?o=(o+s)/2:s=(o+s)/2;return[r,s,n,o]};function get_bit(e,t){return e/Math.pow(2,t)&1}var decode$1=function(e){var t=decode_bbox(e),n=(t[0]+t[2])/2,r=(t[1]+t[3])/2;return{latitude:n,longitude:r,error:{latitude:t[2]-n,longitude:t[3]-r}}},decode_int=function(e,t){var n=decode_bbox_int(e,t),r=(n[0]+n[2])/2,o=(n[1]+n[3])/2;return{latitude:r,longitude:o,error:{latitude:n[2]-r,longitude:n[3]-o}}},neighbor=function(e,t){var n=decode$1(e),r=n.latitude+t[0]*n.error.latitude*2,o=n.longitude+t[1]*n.error.longitude*2;return o=ensure_valid_lon(o),r=ensure_valid_lat(r),encode$1(r,o,e.length)},neighbor_int=function(e,t,n){var r=decode_int(e,n=n||52),o=r.latitude+t[0]*r.error.latitude*2,s=r.longitude+t[1]*r.error.longitude*2;return s=ensure_valid_lon(s),o=ensure_valid_lat(o),encode_int(o,s,n)},neighbors=function(e){var t,n,r=e.length,o=decode$1(e),s=o.latitude,a=o.longitude,i=2*o.error.latitude,u=2*o.error.longitude;function l(e,o){return t=s+e*i,n=ensure_valid_lon(n=a+o*u),t=ensure_valid_lat(t),encode$1(t,n,r)}return[l(1,0),l(1,1),l(0,1),l(-1,1),l(-1,0),l(-1,-1),l(0,-1),l(1,-1)]},neighbors_int=function(e,t){var n,r,o=decode_int(e,t=t||52),s=o.latitude,a=o.longitude,i=2*o.error.latitude,u=2*o.error.longitude;function l(e,o){return n=s+e*i,r=ensure_valid_lon(r=a+o*u),n=ensure_valid_lat(n),encode_int(n,r,t)}return[l(1,0),l(1,1),l(0,1),l(-1,1),l(-1,0),l(-1,-1),l(0,-1),l(1,-1)]},bboxes=function(e,t,n,r,o){for(var s=encode$1(e,t,o=o||9),a=encode$1(n,r,o),i=decode$1(s),u=2*i.error.latitude,l=2*i.error.longitude,c=decode_bbox(s),p=decode_bbox(a),d=Math.round((p[0]-c[0])/u),h=Math.round((p[1]-c[1])/l),f=[],m=0;m<=d;m++)for(var g=0;g<=h;g++)f.push(neighbor(s,[m,g]));return f},bboxes_int=function(e,t,n,r,o){for(var s=encode_int(e,t,o=o||52),a=encode_int(n,r,o),i=decode_int(s,o),u=2*i.error.latitude,l=2*i.error.longitude,c=decode_bbox_int(s,o),p=decode_bbox_int(a,o),d=Math.round((p[0]-c[0])/u),h=Math.round((p[1]-c[1])/l),f=[],m=0;m<=d;m++)for(var g=0;g<=h;g++)f.push(neighbor_int(s,[m,g],o));return f};function ensure_valid_lon(e){return e>MAX_LON?MIN_LON+e%MAX_LON:e<MIN_LON?MAX_LON+e%MAX_LON:e}function ensure_valid_lat(e){return e>MAX_LAT?MAX_LAT:e<MIN_LAT?MIN_LAT:e}var geohash={ENCODE_AUTO:ENCODE_AUTO,encode:encode$1,encode_uint64:encode_int,encode_int:encode_int,decode:decode$1,decode_int:decode_int,decode_uint64:decode_int,decode_bbox:decode_bbox,decode_bbox_uint64:decode_bbox_int,decode_bbox_int:decode_bbox_int,neighbor:neighbor,neighbor_int:neighbor_int,neighbors:neighbors,neighbors_int:neighbors_int,bboxes:bboxes,bboxes_int:bboxes_int},main$1=geohash,setStreaming=lib_5.setStreaming,setQueryOptions$c=lib_5.setQueryOptions,updateQuery$d=lib_5.updateQuery,loadMore$1=lib_5.loadMore,setValue$3=lib_5.setValue,updateComponentProps$3=lib_5.updateComponentProps,setDefaultQuery$8=lib_5.setDefaultQuery,recordResultClick$1=lib_5.recordResultClick,setMapData=lib_5.setMapData,isEqual$h=lib_8.isEqual,getQueryOptions$5=lib_8.getQueryOptions,getClassName$h=lib_8.getClassName,parseHits$2=lib_8.parseHits,getOptionsFromQuery$4=lib_8.getOptionsFromQuery,getResultStats$4=lib_8.getResultStats,MAP_CENTER={lat:37.7749,lng:122.4194},style={width:"100%",height:"100vh",position:"relative"};function getPrecision(e){if(isNaN(e))return 0;for(var t=1,n=0;Math.round(e*t)/t!==e;)t*=10,n+=1;return n}function withDistinctLat(e,t){var n=getPrecision(e.lat),r=n>=6?4:n-2,o=1/Math.pow(10,r)*t;return _extends({},e,{lat:parseFloat((e.lat+o).toFixed(n))})}function getLocationObject(e){switch(Array.isArray(e)?"array":typeof e){case"string":if(e.indexOf(",")>-1){var t=e.split(",");return{lat:parseFloat(t[0]),lng:parseFloat(t[1])}}var n=main$1.decode(e);return{lat:n.latitude,lng:n.longitude};case"array":return{lat:e[1],lng:e[0]};default:return e}}var ReactiveMap={name:"ReactiveMap",props:{className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,react:types.react,size:types.number,sortBy:types.sortBy,URLParams:VueTypes.bool,autoCenter:VueTypes.bool,getMapRef:VueTypes.func.isRequired,getMapPromise:VueTypes.func,center:types.location,defaultCenter:types.location,defaultPin:types.string,defaultZoom:VueTypes.number.def(13),defaultQuery:types.func,innerClass:types.style,loader:types.title,render:types.func,renderItem:types.func,renderError:types.title,pages:VueTypes.number.def(5),currentPage:VueTypes.number.def(0),pagination:VueTypes.bool,showMarkers:VueTypes.bool,defaultSearchAsMove:VueTypes.bool,showSearchAsMove:VueTypes.bool,defaultRadius:types.number,unit:types.string,autoClosePopover:VueTypes.bool,renderMap:VueTypes.func.isRequired,renderPopover:VueTypes.func,calculateMarkers:VueTypes.func,searchAsMoveLabel:VueTypes.string.def("Search as I move the map")},preserveCenter:!1,data:function(){var e=this.$props,t=0;return e.currentPage&&(t=Math.max(e.currentPage-1,0)),this.__state={from:t*e.size,zoom:e.defaultZoom,searchAsMove:e.defaultSearchAsMove,currentPageState:t,mapBoxBounds:null,markersData:null},this.__state},computed:{totalPages:function(){return Math.ceil(this.total/this.$props.size)||0},stats:function(){var e=this.getAllData().resultsToRender;return _extends({},getResultStats$4(this),{currentPage:this.currentPageState,displayedResults:e.length})},hasCustomRender:function(){return hasCustomRenderer(this)}},watch:{defaultZoom:function(e){this.zoom=e},currentPage:function(e,t){t!==e&&e>0&&e<=this.totalPages&&this.setPage(e-1)},defaultQuery:function(e,t){var n=this;isQueryIdentical(e,t,null,this.$props)||this.getMapPromise().then((function(){var t=getQueryOptions$5(n.$props);if(t.from=0,n.$defaultQuery=e(null,n.$props),n.setDefaultQueryForRSAPI(),n.$defaultQuery){var r=n.$defaultQuery||{},o=r.sort,s=r.query;o&&(t.sort=n.$defaultQuery.sort),getOptionsFromQuery$4(n.$defaultQuery)&&(t=_extends({},t,getOptionsFromQuery$4(n.$defaultQuery))),n.setQueryOptions(n.$props.componentId,t,!1);var a={mapBoxBounds:n.mapBoxBounds};n.setMapData(n.componentId,s,!0,!0,a),n.currentPageState=0,n.from=0}}))},promotedResults:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},hidden:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},time:function(e,t){isEqual$h(e,t)||this.$emit("data",this.getData())},hits:function(e,t){this.$emit("data",this.getData()),this.pagination&&this.isLoading&&(t||e)&&this.$emit("page-change",this.currentPageState+1,this.totalPages)},rawData:function(e,t){var n=this;if(!isEqual$h(e,t)){var r=this.promotedResults,o=this.hits,s=parseHits$2(o)||[],a=parseHits$2(r)||[],i=s;if(a.length){var u=a.map((function(e){return e._id})).filter(Boolean);u&&(i=i.filter((function(e){return!u.includes(e._id)}))),i=[].concat(a,i)}i=i.filter((function(e){return!!e[n.dataField]})).map((function(e){var t;return _extends({},e,((t={})[n.dataField]=getLocationObject(e[n.dataField]),t))})),this.filteredResults=this.addNoise(i),this.calculateMarkers&&(this.markersData=this.calculateMarkers({data:this.filteredResults,rawData:this.rawData})||[]),this.$emit("data",this.getData())}},center:function(e,t){if(!isEqual$h(e,t)){var n=!!this.center,r=this.getGeoQuery(this.$props);this.setDefaultQueryForRSAPI();var o={mapBoxBounds:this.mapBoxBounds};this.setMapData(this.componentId,r,n,!0,o)}}},methods:{parseLocation:function(e){return Array.isArray(e)?{lat:Number(e[0]),lng:Number(e[1])}:{lat:e?Number(e.lat):this.defaultCenter.lat,lng:e?Number(void 0===e.lon?e.lng:e.lon):this.defaultCenter.lng}},getDefaultCenter:function(){return this.defaultCenter?this.parseLocation(this.defaultCenter):this.parseLocation(MAP_CENTER)},addNoise:function(e){var t=this,n={},r=[];return e.forEach((function(e){var o=_extends({},e),s=t.parseLocation(e[t.dataField]),a=JSON.stringify(s),i=n[a]||0;o[t.dataField]=i?withDistinctLat(s,i):s,r=[].concat(r,[o]),n[a]=i+1})),r},getPosition:function(e){return e?this.parseLocation(e[this.dataField]):null},getHitsCenter:function(e){var t=this,n=e.map((function(e){return e[t.dataField]}));if(n.length){var r=n.length,o=0,s=0,a=0;n.forEach((function(e){if(e){var t,n,r=getLocationObject(e);t=r.lat*Math.PI/180,n=(void 0!==r.lng?r.lng:r.lon)*Math.PI/180;var i=Math.cos(t)*Math.cos(n),u=Math.cos(t)*Math.sin(n),l=Math.sin(t);o+=i,s+=u,a+=l}})),o/=r,s/=r,a/=r;var i=Math.atan2(s,o),u=Math.sqrt(o*o+s*s);return{lat:180*Math.atan2(a,u)/Math.PI,lng:180*i/Math.PI}}return!1},getCenter:function(e){var t=this;if(this.center)return this.parseLocation(this.center);var n=this.getMapRef();if(n&&"function"==typeof n.getCenter&&this.$options.preserveCenter){var r=n.getCenter();return setTimeout((function(){t.$options.preserveCenter=!1}),100),this.parseLocation({lat:r.lat(),lng:r.lng()})}return e&&e.length?this.autoCenter?this.getHitsCenter(e)||this.getDefaultCenter():e[0]&&e[0][this.dataField]?this.getPosition(e[0]):this.getDefaultCenter():this.getDefaultCenter()},handleZoomChange:function(e){if(e){var t=this.zoom;this.searchAsMove?(this.zoom=e,this.$options.preserveCenter=!0,this.setGeoQuery(!0)):this.zoom=e,t!==e&&this.$emit("zoom-changed",e)}},handleOnDragEnd:function(){this.searchAsMove&&(this.$options.preserveCenter=!0,this.setGeoQuery(!0)),this.$emit("drag-end")},handlePreserveCenter:function(e){this.$options.preserveCenter=e},handleOnIdle:function(){if(this.hits&&this.hits.length&&this.searchAsMove){var e=!!this.center;this.setGeoQuery(e)}this.$emit("idle")},setGeoQuery:function(e){if(void 0===e&&(e=!1),(e||!this.skipBoundingBox&&!this.mapBoxBounds)&&(this.$defaultQuery=this.getGeoQuery(),this.$defaultQuery)){var t=!!this.center,n=this.searchAsMove,r={mapBoxBounds:this.mapBoxBounds};this.setMapData(this.componentId,this.$defaultQuery,t,n,r)}this.skipBoundingBox=!1},getMapParams:function(){var e=this.getData().data,t=this.showMarkers,n=this.defaultPin,r=this.renderPopover,o=this.autoClosePopover,s=this.renderItem;return{resultsToRender:e,center:this.getCenter(e),getPosition:this.getPosition,zoom:this.zoom,renderItem:s,showMarkers:t,defaultPin:n,renderPopover:r,autoClosePopover:o,renderSearchAsMove:this.renderSearchAsMove,handlePreserveCenter:this.handlePreserveCenter,preserveCenter:this.$options.preserveCenter,handleOnDragEnd:this.handleOnDragEnd,handleOnIdle:this.handleOnIdle,handleZoomChange:this.handleZoomChange}},getAllData:function(){var e=this.size,t=this.promotedResults,n=this.customData,r=this.currentPage,o=this.hits,s=parseHits$2(o)||[],a=parseHits$2(t)||[],i=r*e,u=this.filteredResults||[];return this.markersData&&(u=this.markersData),{results:s,resultsToRender:u,customData:n||{},promotedResults:a,loadMore:this.loadMore,base:i,triggerClickAnalytics:this.triggerClickAnalytics}},getData:function(){var e=this.getAllData(),t=e.promotedResults,n=e.aggregationData,r=e.customData,o=e.resultsToRender;return{data:this.withClickIds(o),aggregationData:this.withClickIds(n||[]),promotedData:this.withClickIds(t),rawData:this.rawData,resultStats:this.stats,customData:r}},getComponent:function(){var e=_extends({error:this.error,loading:this.isLoading,loadMore:this.loadMore,triggerClickAnalytics:this.triggerClickAnalytics,setPage:this.setPage},this.getData());return getComponent(e,this)},setPage:function(e){if(e!==this.currentPageState){this.$emit("pageClick",e+1),this.$emit("page-click",e+1);var t=this.size*e,n=getQueryOptions$5(this.$props);n.from=this.$data.from,this.from=t,this.currentPageState=e,this.loadMoreAction(this.componentId,_extends({},n,{from:t}),!1),this.URLParams&&this.setPageURL(this.componentId,e+1,this.componentId,!1,!0)}},setDefaultQueryForRSAPI:function(){if(this.defaultQuery&&"function"==typeof this.defaultQuery){var e=this.defaultQuery();this.setDefaultQuery(this.componentId,e)}},getArrPosition:function(e){return{lat:e.lat,lon:e.lon||e.lng}},getGeoQuery:function(e){void 0===e&&(e=this.$props),this.$defaultQuery=e.defaultQuery?e.defaultQuery():null;var t,n,r,o=this.getMapRef(),s=!(!o||"function"!=typeof o.getBounds)&&o.getBounds();if(s){var a;t=s.getNorthEast().lat(),n=s.getSouthWest().lat(),r=s.getNorthEast().lng();var i={top_left:[s.getSouthWest().lng(),t],bottom_right:[r,n]};this.mapBoxBounds=i;var u={geo_bounding_box:(a={},a[this.dataField]=i,a)};if(this.$defaultQuery){var l=(this.$defaultQuery||{}).query;if(l)return{must:[u,l]}}return u}return this.$defaultQuery?this.$defaultQuery.query:null},getGeoDistanceQuery:function(){var e,t=this.center||this.defaultCenter;return t&&this.defaultRadius?(this.skipBoundingBox=!0,{geo_distance:(e={distance:""+this.defaultRadius+this.unit},e[this.dataField]=this.getArrPosition(t),e)}):null},loadMore:function(){if(this.hits&&!this.pagination&&this.total!==this.hits.length){var e=this.from+this.size,t=getQueryOptions$5(this.$props);this.from=e,this.loadMoreAction(this.componentId,_extends({},t,{from:e}),!0)}},triggerClickAnalytics:function(e,t){var n=t;if(!n){var r=this.getData().data.find((function(t){return t._click_id===e}));r&&r._id&&(n=r._id)}this.recordResultClick(e,n)},withClickIds:function(e){var t=this.getAllData().base;return e.map((function(e,n){return _extends({},e,{_click_id:t+n})}))},toggleSearchAsMove:function(){this.searchAsMove=!this.searchAsMove,this.$emit("search-as-move",this.searchAsMove)},renderErrorComponent:function(){var e=this.$scopedSlots.renderError||this.$props.renderError;return e&&this.error&&!this.isLoading?isFunction$1(e)?e(this.error):e:null},renderSearchAsMove:function(){var e=this.$createElement;return this.showSearchAsMove?e("div",{style:{position:"absolute",bottom:"30px",left:"10px",width:"240px",backgroundColor:"#fff",padding:"8px 10px",boxShadow:"rgba(0,0,0,0.3) 0px 1px 4px -1px",borderRadius:2,zIndex:1e4},attrs:{className:getClassName$h(this.innerClass,"checkboxContainer")||null}},[e(Checkbox,{attrs:{type:"checkbox",id:this.$props.componentId+"-searchasmove",checked:this.searchAsMove,show:!0},class:getClassName$h(this.$props.innerClass,"checkbox"),on:{click:this.toggleSearchAsMove}}),e("label",{attrs:{className:getClassName$h(this.innerClass,"label")||null,for:this.$props.componentId+"-searchasmove"}},[this.searchAsMoveLabel])]):null},renderPagination:function(){return(0,this.$createElement)(Pagination,{attrs:{pages:this.pages,totalPages:this.totalPages,currentPage:this.currentPageState,setPage:this.setPage,innerClass:this.innerClass}})}},created:function(){this.defaultPage>=0&&(this.currentPageState=this.defaultPage,this.from=this.currentPageState*this.$props.size),this.internalComponent=this.$props.componentId+"__internal",this.updateComponentProps(this.componentId,{from:this.from},constants_1$1.reactiveMap),this.updateComponentProps(this.internalComponent,{from:this.from},constants_1$1.reactiveMap),this.setDefaultQueryForRSAPI()},mounted:function(){var e=this;this.getMapPromise().then((function(){e.defaultPage<0&&e.currentPage>0&&e.$props.URLParams&&e.setPageURL(e.$props.componentId,e.currentPage,e.$props.componentId,!1,!0);var t,n=getQueryOptions$5(e.$props);(n.from=e.$data.from,e.$props.sortBy)&&(n.sort=[(t={},t[e.$props.dataField]={order:e.$props.sortBy},t)]);if(e.$defaultQuery=null,e.$props.defaultQuery){if(e.$defaultQuery=e.$props.defaultQuery(),e.setDefaultQueryForRSAPI(),e.$defaultQuery){n=_extends({},n,getOptionsFromQuery$4(e.$defaultQuery)),e.$defaultQuery.sort&&(n.sort=e.$defaultQuery.sort);var r={mapBoxBounds:e.mapBoxBounds};e.$defaultQuery&&(e.setMapData(e.componentId,e.$defaultQuery.query,!0,!1,r),e.setQueryOptions(e.componentId,n))}}else{var o=e.getGeoDistanceQuery();if(o){var s=!!e.center,a=e.searchAsMove,i=e.center||e.defaultCenter,u=e.getArrPosition(i),l={distance:e.defaultRadius,coordinates:u.lat+", "+u.lon};e.setMapData(e.componentId,o,s,a,l)}e.setQueryOptions(e.componentId,n)}}))},render:function(){var e=arguments[0],t=this.$scopedSlots.loader||this.$props.loader;return e("div",{style:_extends({},style,this.$props.style),class:this.$props.className},[this.renderErrorComponent(),this.isLoading&&t,this.hasCustomRender?this.getComponent():null,this.renderMap(this.getMapParams()),this.pagination?this.renderPagination():null])}},mapStateToProps$i=function(e,t){return{defaultPage:e.selectedValues[t.componentId]&&e.selectedValues[t.componentId].value-1||-1,error:e.error[t.componentId],isLoading:e.isLoading[t.componentId],hits:e.hits[t.componentId]&&e.hits[t.componentId].hits,promotedResults:e.promotedResults[t.componentId],customData:e.customData[t.componentId],total:e.hits[t.componentId]&&e.hits[t.componentId].total,time:e.hits[t.componentId]&&e.hits[t.componentId].time,rawData:e.rawData[t.componentId],hidden:e.hits[t.componentId]&&e.hits[t.componentId].hidden}},mapDispatchToProps$4={loadMoreAction:loadMore$1,setPageURL:setValue$3,setQueryOptions:setQueryOptions$c,setStreaming:setStreaming,updateQuery:updateQuery$d,updateComponentProps:updateComponentProps$3,setDefaultQuery:setDefaultQuery$8,recordResultClick:recordResultClick$1,setMapData:setMapData},RMConnected=PreferencesConsumer(ComponentWrapper$1(connect(mapStateToProps$i,mapDispatchToProps$4)(ReactiveMap),{componentType:constants_1$1.reactiveMap,internalComponent:!0}));ReactiveMap.install=function(e){e.component(ReactiveMap.name,RMConnected)},ReactiveMap.componentType=constants_1$1.reactiveMap;var infoWindowMappedProps$1={content:{type:Object,twoWay:!0},options:{type:Object,required:!1,default:function(){return{}}},position:{type:Object,twoWay:!0},zIndex:{type:Number,twoWay:!0}};function bindEvents$1(e,t,n){n.forEach((function(n){(e.$gmapOptions.autoBindAllEvents||e.$listeners[n])&&t.addListener(n,(function(t){e.$emit(n,t)}))}))}function capitalizeFirstLetter$1(e){return e.charAt(0).toUpperCase()+e.slice(1)}function getPropsValues$1(e,t){return Object.keys(t).reduce((function(t,n){return void 0!==e[n]&&(t[n]=e[n]),t}),{})}function watchPrimitiveProperties$1(e,t,n,r){void 0===r&&(r=!1);var o=!1;function s(){o||(o=!0,e.$nextTick((function(){o=!1,n()})))}t.forEach((function(t){e.$watch(t,s,{immediate:r})}))}function bindProps$1(e,t,n){Object.keys(n).forEach((function(r){var o=n[r],s=o.twoWay,a=o.type,i=o.trackProperties;if(!o.noBind){var u="set"+capitalizeFirstLetter$1(r),l="get"+capitalizeFirstLetter$1(r),c=r.toLowerCase()+"_changed",p=e[r];if(void 0===t[u])throw new Error(u+" is not a method of (the Maps object corresponding to) "+e.$options._componentTag);a===Object&&i?watchPrimitiveProperties$1(e,i.map((function(e){return r+"."+e})),(function(){t[u](e[r])}),void 0!==e[r]):e.$watch(r,(function(){var n=e[r];t[u](n)}),{immediate:void 0!==p,deep:a===Object}),s&&(e.$gmapOptions.autoBindAllEvents||e.$listeners[c])&&t.addListener(c,(function(){e.$emit(c,t[l]())}))}}))}var _excluded$i=["options","position"],InfoWindowClusterManager={name:"InfoWindowClusterManager",inject:{$markerPromise:{default:null},$mapPromise:{}},provide:function(){var e=this,t=["domready","closeclick","content_changed"],n=this.$mapPromise.then((function(n){e.$map=n;var r=_extends({},e.options,{map:n},getPropsValues$1(e,infoWindowMappedProps$1)),o=(r.options,r.position,_objectWithoutPropertiesLoose(r,_excluded$i));o.content=e.$refs.flyaway,e.$markerPromise&&e.$markerPromise.then((function(n){return e.$markerObject=n,e.$infoWindowObject=new google.maps.InfoWindow(o),bindProps$1(e,e.$infoWindowObject,infoWindowMappedProps$1),bindEvents$1(e,e.$infoWindowObject,t),e._openInfoWindow(),e.$watch("opened",(function(){e._openInfoWindow()})),e.$infoWindowObject}))})).catch((function(e){throw e}));return this.$infoWindowPromise=n,{$infoWindowPromise:n}},props:{content:{type:[String,Object],default:void 0},opened:{type:Boolean,default:!0},position:{type:Object,default:void 0},zIndex:{type:Number,default:0},options:{type:Object,required:!1,default:void 0}},mounted:function(){var e=this.$refs.flyaway;e.parentNode.removeChild(e)},destroyed:function(){this.$infoWindowObject&&this.$infoWindowObject.setMap&&this.$infoWindowObject.setMap(null)},methods:{_openInfoWindow:function(){this.opened?null!==this.$markerObject?this.$infoWindowObject.open(this.$map,this.$markerObject):this.$infoWindowObject.open(this.$map):this.$infoWindowObject.close()}},render:function(){var e=arguments[0];return e("div",[e("div",{ref:"flyaway"},[this.$scopedSlots.default()])])}},InfoWindowWrapper={name:"InfoWindowWrapperClusterManager",props:{id:VueTypes.string,renderPopover:VueTypes.func,infoWindowProps:VueTypes.object,events:VueTypes.object,marker:VueTypes.Object},data:function(){return{infoWindowRef:null}},provide:function(){return{$markerPromise:Promise.resolve(this.marker)}},mounted:function(){this.infoWindowRef=this.$refs[this.id+"-Info-Window"]},methods:{handleClose:function(){this.infoWindowRef.$infoWindowObject.close()}},render:function(){var e=arguments[0],t=this.renderPopover,n=this.events;return e(InfoWindowClusterManager,{ref:this.id+"-Info-Window",props:_extends({},this.infoWindowProps),on:_extends({},n)},[e("div",[t(this.handleClose)])])}},_excluded$j=["options"],isEqual$i=lib_8.isEqual,recordResultClick$2=lib_5.recordResultClick,ClusterMarkers={name:"ClusterMarkers",props:{markers:VueTypes.array,getPosition:VueTypes.func,defaultPin:VueTypes.string,renderItem:VueTypes.func,markerProps:VueTypes.object,handlePreserveCenter:VueTypes.func.isRequired,autoClosePopover:VueTypes.bool,renderPopover:VueTypes.func,highlightMarkerOnHover:VueTypes.bool},inject:{$clusterPromise:{default:null},$mapPromise:{}},data:function(){return{openMarkers:{}}},mounted:function(){this.buildMarkers(this.markers)},destroy:function(){this.buildMarkers([])},watch:{markers:function(e,t){isEqual$i(t,e)||this.buildMarkers(e)}},methods:{triggerAnalytics:function(e,t){this.recordResultClick(e,t)},setOpenMarkers:function(e){this.openMarkers=e},closeMarker:function(e){var t=this.$props,n=t.autoClosePopover,r=t.handlePreserveCenter,o=e.metaData&&e.metaData._id,s=this.openMarkers,a=(s[o],_objectWithoutPropertiesLoose(s,[o].map(_toPropertyKey))),i=n?{}:a;this.setOpenMarkers(i),r(!0),this.$emit("close-marker-popover",e)},openMarker:function(e,t){var n,r,o=this.autoClosePopover,s=this.handlePreserveCenter,a=e.metaData&&e.metaData._id,i=o?((n={})[a]=e,n):_extends({},this.openMarkers,((r={})[a]=e,r));this.setOpenMarkers(i),s(!0),this.triggerAnalytics(a,t),this.$emit("open-marker-popover",e)},removeMarkers:function(){this.$clusterObject&&(this.$clusterObject.clearMarkers(!0),this.$markers=[])},buildMarkers:function(e){var t=this;this.$mapPromise.then((function(n){t.$clusterPromise&&t.$clusterPromise.then((function(r){var o=[],s=[],a={};(t.$markers||[]).forEach((function(e){e.metaData&&e.metaData._id&&(a[e.metaData._id]=!1)})),e.forEach((function(e,r){if(e._id&&void 0!==a[e._id])a[e._id]=!0;else{var s=_extends({},t.markerProps,{metaData:e,map:n,position:t.getPosition(e)});if(t.renderItem){var i=t.renderItem(e);"label"in i&&(s.label=i.label),"icon"in i&&(s.icon=i.icon)}else t.defaultPin&&(s.icon={url:t.defaultPin});s.options;var u=_objectWithoutPropertiesLoose(s,_excluded$j);t.$clusterPromise&&(u.map=null);var l=new google.maps.Marker(u);l.addListener("click",(function(){t.openMarker(l,r)})),o.push(l)}}));var i=[];o.forEach((function(e){i.push(e)})),(t.$markers||[]).forEach((function(e){e.metaData&&e.metaData._id&&(a[e.metaData._id]?i.push(e):s.push(e))})),r.removeMarkers(s),r.addMarkers(o),t.$clusterObject=r,t.$map=n,t.$markers=i}))})).catch((function(e){throw e}))}},render:function(){var e=this,t=arguments[0];return this.renderPopover?t("div",[Object.keys(this.openMarkers).map((function(n){var r=e.openMarkers[n],o=r.metaData;return t(InfoWindowWrapper,{key:n+"-InfoWindow",attrs:{id:n,renderPopover:function(t){return e.renderPopover({item:o,handleClose:function(){t(),e.closeMarker(o)}})},marker:r,infoWindowProps:{zIndex:500},events:{closeclick:function(){return e.closeMarker(r)}}}})}))]):null}},mapDispatchToProps$5={recordResultClick:recordResultClick$2},ClusterManager=connect((function(){return null}),mapDispatchToProps$5)(ClusterMarkers),InfoWindow=components.InfoWindow,InfoWindowWrapper$1={name:"InfoWindowWrapper",props:{id:VueTypes.string,renderPopover:VueTypes.func,infoWindowProps:VueTypes.object,events:VueTypes.object},data:function(){return{infoWindowRef:null}},mounted:function(){this.infoWindowRef=this.$refs[this.id+"-Info-Window"]},methods:{handleClose:function(){this.infoWindowRef.$infoWindowObject.close()}},render:function(){var e=arguments[0],t=this.renderPopover,n=this.events;return e(InfoWindow,{ref:this.id+"-Info-Window",props:_extends({},this.infoWindowProps),on:_extends({},n)},[e("div",[t(this.handleClose)])])}},MapElementMixin=components.MapElementMixin,MarkerWithLabel={name:"MarkerWithLabel",props:{metaData:{type:Object,default:void 0},marker:{type:Object,default:void 0},offsetX:{type:Number,default:0},offsetY:{type:Number,default:0},alignment:{type:String,default:"top"},zIndex:{type:Number,default:50},cssPosition:{type:Boolean,default:!1},renderMarker:VueTypes.func.isRequired,handleMouseOver:VueTypes.func,handleFocus:VueTypes.func,handleMouseOut:VueTypes.func,handleBlur:VueTypes.func,handleClick:VueTypes.func},data:function(){return{opacity:.01}},mixins:[MapElementMixin],inject:{$clusterPromise:{default:null}},computed:{lat:function(){return parseFloat(Number.isNaN(this.marker.lat)?this.marker.latitude:this.marker.lat)},lng:function(){return parseFloat(Number.isNaN(this.marker.lng)?this.marker.longitude:this.marker.lng)},latLng:function(){return this.marker instanceof window.google.maps.LatLng?this.marker:new window.google.maps.LatLng(this.lat,this.lng)}},watch:{marker:function(){var e=this;this.$mapPromise.then((function(){return e.$overlay.setPosition()}))},zIndex:function(){this.$overlay&&this.$overlay.repaint()}},beforeCreate:function(e){return this.$clusterPromise&&(e.map=null),this.$clusterPromise},destroyed:function(){this.$clusterObject?this.$clusterObject.removeMarker(this.$overlay,!0):this.$overlay&&(this.$overlay.setMap(null),this.$overlay=void 0)},provide:function(){var e=this,t=this;return this.$mapPromise.then((function(n){var r=function(e){function n(n){var r;return(r=e.call(this)||this).metaData=t.metaData,r.setMap(n),r.draw=function(){return r.repaint()},r.setPosition=function(){return r.repaint()},r.getVisible=function(){return!0},r}_inheritsLoose(n,e);var r=n.prototype;return r.repaint=function(){var e=t.$el,n=this.getProjection();if(n&&e){var r,o,s=n.fromLatLngToDivPixel(t.latLng);switch(t.alignment){case"top":r=s.x-e.offsetWidth/2,o=s.y-e.offsetHeight;break;case"bottom":r=s.x-e.offsetWidth/2,o=s.y;break;case"left":r=s.x-e.offsetWidth,o=s.y-e.offsetHeight/2;break;case"right":r=s.x,o=s.y-e.offsetHeight/2;break;case"center":r=s.x-e.offsetWidth/2,o=s.y-e.offsetHeight/2;break;case"topleft":case"lefttop":r=s.x-e.offsetWidth,o=s.y-e.offsetHeight;break;case"topright":case"righttop":r=s.x,o=s.y-e.offsetHeight;break;case"bottomleft":case"leftop":r=s.x-e.offsetWidth,o=s.y;break;case"bottomright":case"rightbottom":r=s.x,o=s.y;break;default:throw new Error("Invalid alignment type of custom marker!")}t.cssPosition?e.style.transform="translate("+(r+t.offsetX)+"px, "+(o+t.offsetY)+"px)":(e.style.left=r+t.offsetX+"px",e.style.top=o+t.offsetY+"px"),e.style["z-index"]=t.zIndex}},r.onAdd=function(){this.$clusterObject?this.$clusterObject.removeMarker(this.$overlay,!0):this.$overlay&&(this.$overlay.setMap(null),this.$overlay=void 0);var e=t.$el,n=this.getPanes();e.style.position="absolute",e.style.display="inline-block",e.style.zIndex=t.zIndex,n.overlayLayer.appendChild(e),n.overlayMouseTarget.appendChild(e),this.getDraggable=function(){return!1},this.getPosition=function(){return new window.google.maps.LatLng(t.lat,t.lng)},t.afterCreate(this)},r.onRemove=function(){if(t.$el){var e=window.navigator.userAgent;e.indexOf("MSIE ")>0||e.match(/Trident.*rv\:11\./)?t.$el.parentNode.removeChild(t.$el):t.$el.remove()}},n}(window.google.maps.OverlayView);e.$overlay=new r(n),setTimeout((function(){e.$overlay&&(e.$overlay.repaint(),e.opacity=1)}),100)}))},methods:{afterCreate:function(e){var t=this;this.$clusterPromise&&!this.isMarkerAdded&&this.$clusterPromise.then((function(n){n.addMarker(e),t.$clusterObject=n,t.isMarkerAdded=!0}))}},render:function(){var e=arguments[0];return e("div",{style:{opacity:this.opacity},on:{mouseover:this.handleMouseOver,mouseout:this.handleMouseOut,click:this.handleClick}},[this.renderMarker()])}},_templateObject$q,_templateObject2$c,_templateObject3$8,MapPin=index$1("div")(_templateObject$q||(_templateObject$q=_taggedTemplateLiteralLoose(["\n\theight: 24px;\n\twidth: auto;\n\tbackground-color: #fff;\n\tborder-radius: 2px;\n\tcolor: #222;\n\tbox-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.15);\n\tpadding: 3px 6px;\n\tfont-size: 15px;\n"]))),MapPinArrow=index$1("div")(_templateObject2$c||(_templateObject2$c=_taggedTemplateLiteralLoose(["\n\tborder-color: rgba(0, 0, 0, 0.2);\n\tborder-style: solid;\n\tborder-width: 0 1px 1px 0;\n\tmargin-left: -6px;\n\tbackground-color: #fff;\n\tmargin-top: -6px;\n\twidth: 12px;\n\theight: 12px;\n\t-webkit-transform: rotate(45deg);\n\t-ms-transform: rotate(45deg);\n\ttransform: rotate(45deg);\n"]))),mapPinWrapper=css(_templateObject3$8||(_templateObject3$8=_taggedTemplateLiteralLoose(["\n\t&:hover,\n\t&:focus {\n\t\tz-index: 200;\n\t}\n"]))),Marker=components.Marker,recordResultClick$3=lib_5.recordResultClick,GoogleMapMarker={name:"GoogleMapMarker",props:{index:VueTypes.number,marker:VueTypes.object.isRequired,getPosition:VueTypes.func.isRequired,defaultPin:VueTypes.string,renderItem:VueTypes.func,setOpenMarkers:VueTypes.func.isRequired,handlePreserveCenter:VueTypes.func.isRequired,autoClosePopover:VueTypes.bool,openMarkers:VueTypes.object,renderPopover:VueTypes.func,highlightMarkerOnHover:VueTypes.bool},data:function(){return{zIndex:0,markerIcon:null}},methods:{setIcon:function(e){this.markerIcon=e},increaseMarkerZIndex:function(){var e=this.$props.handlePreserveCenter;this.highlightMarkerOnHover&&(this.zIndex+=1),e(!0)},removeMarkerZIndex:function(){var e=this.$props.handlePreserveCenter;this.highlightMarkerOnHover&&(this.zIndex-=1),e(!0)},openMarker:function(){var e,t,n=this.$props,r=n.setOpenMarkers,o=n.openMarkers,s=n.marker,a=n.autoClosePopover,i=n.handlePreserveCenter,u=s._id;r(a?((e={})[u]=!0,e):_extends({},o,((t={})[u]=!0,t))),i(!0),this.triggerAnalytics(),s.setIcon=this.setIcon,this.$emit("open-marker-popover",s)},closeMarker:function(){var e=this.$props,t=e.setOpenMarkers,n=e.marker,r=e.autoClosePopover,o=e.handlePreserveCenter,s=e.openMarkers,a=n._id,i=(s[a],_objectWithoutPropertiesLoose(s,[a].map(_toPropertyKey)));t(r?{}:i),o(!0),n.setIcon=this.setIcon,this.$emit("close-marker-popover",n)},triggerAnalytics:function(){this.recordResultClick(this.index,this.marker._id)},renderPopoverClick:function(e){var t,n=this,r=this.$createElement,o=this.$props,s=o.getPosition,a=o.renderPopover,i=o.openMarkers;return t={position:s(e),defaultOptions:{pixelOffset:new window.google.maps.Size(0,-30)}},e._id in i?r(InfoWindowWrapper$1,{key:e._id+"-InfoWindow",attrs:{id:e._id,renderPopover:function(t){return a({item:e,handleClose:function(){t(),n.closeMarker()}})},infoWindowProps:{zIndex:500,position:t.position,options:t.defaultOptions},events:{closeclick:function(){return n.closeMarker()}}}}):null}},render:function(){var e=this,t=arguments[0],n=this.$props,r=n.getPosition,o=n.renderItem,s=n.defaultPin,a=n.renderPopover,i=n.markerProps,u=n.marker,l={};if(this.zIndex&&(l.zIndex=window.google.maps.Marker.MAX_ZINDEX+this.zIndex),o){u.setIcon=this.setIcon;var c=o(u);if("label"in c)return t(MarkerWithLabel,{key:u._id,attrs:{metaData:u,marker:r(u),labelAnchor:new window.google.maps.Point(0,30),handleMouseOver:this.increaseMarkerZIndex,handleMouseOut:this.removeMarkerZIndex,handleClick:this.openMarker,zIndex:l.zIndex,renderMarker:function(){return t("div",{attrs:{css:mapPinWrapper}},[t(MapPin,[c.label]),t(MapPinArrow),a?e.renderPopoverClick(u,!0):null])}},props:_extends({},i)});if(!("icon"in c))return t(MarkerWithLabel,{key:u._id,attrs:{metaData:u,marker:r(u),handleClick:this.openMarker,handleMouseOver:this.increaseMarkerZIndex,handleMouseOut:this.removeMarkerZIndex,zIndex:l.zIndex,renderMarker:function(){return t("div",{attrs:{css:mapPinWrapper}},["function"==typeof c.custom?c.custom(u):c.custom,a?e.renderPopoverClick(u,!0):null])}},props:_extends({},i)});l.icon=c.icon}else s&&(l.icon={url:s});return t(Marker,{key:u._id,attrs:{zIndex:l.zIndex,position:r(u),options:{metaData:u},icon:this.markerIcon||l.icon},on:{click:function(){return e.openMarker()},mouseover:this.increaseMarkerZIndex,mouseout:this.removeMarkerZIndex},props:_extends({},i)},[a?this.renderPopoverClick(u):null])}},mapDispatchToProps$6={recordResultClick:recordResultClick$3},GoogleMapMarker$1=connect((function(){return null}),mapDispatchToProps$6)(GoogleMapMarker),Cluster$1=components.Cluster,GoogleMapMarkers={name:"GoogleMapMarkers",props:{resultsToRender:VueTypes.array,getPosition:VueTypes.func,renderItem:VueTypes.func,renderClusterPopover:VueTypes.func,defaultPin:VueTypes.string,autoClosePopover:VueTypes.bool,handlePreserveCenter:VueTypes.func,renderPopover:VueTypes.func,markerProps:VueTypes.object,clusterProps:VueTypes.object,showMarkerClusters:VueTypes.bool,highlightMarkerOnHover:VueTypes.bool},data:function(){return{openMarkers:{},clickedCluster:null,clusterMarkers:[]}},methods:{setOpenMarkers:function(e){this.openMarkers=e},getAdditionalProps:function(){return{position:{lat:this.clickedCluster.getCenter().lat(),lng:this.clickedCluster.getCenter().lng()},defaultOptions:{pixelOffset:new window.google.maps.Size(0,-30)}}},closeMarker:function(){this.clickedCluster=null,this.clusterMarkers=[],this.$emit("close-cluster-popover")}},render:function(){var e=this,t=arguments[0],n=this.$props.resultsToRender,r=this.openMarkers,o={openMarkers:r,setMarkerOnTop:this.setMarkerOnTop,setOpenMarkers:this.setOpenMarkers,getPosition:this.getPosition,renderItem:this.renderItem,defaultPin:this.defaultPin,autoClosePopover:this.autoClosePopover,handlePreserveCenter:this.handlePreserveCenter,renderPopover:this.renderPopover,markerProps:this.markerProps,showMarkerClusters:this.showMarkerClusters,highlightMarkerOnHover:this.highlightMarkerOnHover};return this.showMarkerClusters?t("div",[t(Cluster$1,{props:_extends({},this.clusterProps),on:{click:function(t){var n=t.markers.map((function(e){return e.metaData}));e.clickedCluster=t,e.clusterMarkers=n,e.$emit("open-cluster-popover",e.clusterMarkers)}},ref:"clusterRef"},[t(ClusterManager,{attrs:{getPosition:o.getPosition,markers:n,defaultPin:o.defaultPin,renderItem:o.renderItem,markerProps:o.markerProps,handlePreserveCenter:o.handlePreserveCenter,autoClosePopover:o.autoClosePopover,renderPopover:o.renderPopover,highlightMarkerOnHover:o.highlightMarkerOnHover},on:_extends({},this.$listeners)})]),this.clickedCluster&&this.renderClusterPopover?t(InfoWindowWrapper$1,{attrs:{id:"cluster",infoWindowProps:{zIndex:500,position:this.getAdditionalProps().position,options:this.getAdditionalProps().defaultOptions},renderPopover:function(t){return e.renderClusterPopover({markers:e.clusterMarkers,cluster:e.clickedCluster,handleClose:function(){t(),e.closeMarker()}})},events:{closeclick:this.closeMarker}}}):null]):t("div",[n.map((function(n,r){return t(GoogleMapMarker$1,{attrs:{index:r,marker:n},props:_extends({},o),on:_extends({},e.$listeners)})}))])}},Map=components.MapLayer,ReactiveGoogleMap={name:"ReactiveGoogleMap",props:{className:types.string,componentId:types.stringRequired,dataField:types.stringRequired,defaultQuery:VueTypes.func,loader:types.title,defaultZoom:VueTypes.number.def(13),react:types.react,size:types.number,sortBy:types.sortBy,URLParams:VueTypes.bool,mapProps:VueTypes.object,showMarkers:VueTypes.bool.def(!0),showMarkerClusters:VueTypes.bool.def(!1),searchAsMove:VueTypes.bool.def(!1),searchAsMoveLabel:VueTypes.string,markerProps:VueTypes.object,clusterProps:VueTypes.object,renderItem:VueTypes.func,showSearchAsMove:VueTypes.bool.def(!0),autoClosePopover:VueTypes.bool,pagination:VueTypes.bool,defaultPin:VueTypes.string,autoCenter:VueTypes.bool,defaultCenter:types.location,center:types.location,defaultRadius:types.number,unit:types.string,pages:VueTypes.number.def(5),calculateMarkers:VueTypes.func,highlightMarkerOnHover:VueTypes.bool.def(!0)},created:function(){var e=this;this.mapRefPromiseResolve=null,this.mapRefPromiseRejecter=null,this.mapRefPromise=new Promise((function(t,n){e.mapRefPromiseResolver=t,e.mapRefPromiseRejecter=n}))},methods:{renderMap:function(e){var t=this,n=e.resultsToRender,r=e.center,o=e.zoom,s=e.handleZoomChange,a=e.handleOnDragEnd,i=e.handleOnIdle,u=e.renderSearchAsMove,l=e.handlePreserveCenter,c=e.getPosition,p=e.autoClosePopover,d=e.defaultPin,h=this.$createElement;return h("div",{style:{width:"100%",height:"100%",position:"relative"}},[h(Map,{ref:"mapRef",attrs:{"map-type-id":"terrain",options:{zoomControl:!0},center:r,zoom:o},style:{height:"100%"},props:_extends({},this.mapProps),on:{zoom_changed:s,dragend:a,idle:i}},[this.showMarkers?h(GoogleMapMarkers,{attrs:{resultsToRender:n,getPosition:c,markerProps:this.markerProps,clusterProps:this.clusterProps,handlePreserveCenter:l,highlightMarkerOnHover:this.highlightMarkerOnHover,renderItem:this.$scopedSlots.renderItem?function(){return{custom:t.$scopedSlots.renderItem}}:this.renderItem,defaultPin:d,autoClosePopover:p,renderPopover:this.$scopedSlots.renderPopover,renderClusterPopover:this.$scopedSlots.renderClusterPopover,showMarkerClusters:this.showMarkerClusters},on:_extends({},this.$listeners)}):null]),u()])},getMapRef:function(){return this.mapRef},getMapRefPromise:function(){return this.mapRefPromise},removeMarkers:function(){for(var e,t=this;t;)if(t&&t.$options&&"connect-ClusterMarkers"===t.$options.name)e=t,t=null;else if(t.$children){t=t.$children[0]}else t=null;e&&e.removeMarkers&&e.removeMarkers()}},mounted:function(){var e=this;this.$refs.mapRef&&this.$refs.mapRef.$mapPromise.then((function(t){e.mapRef=t,e.mapRefPromiseResolver(e.mapRef)})).catch(this.mapRefPromiseRejecter)},render:function(){var e=arguments[0];return e(RMConnected,helper$1([{attrs:{getMapRef:this.getMapRef,getMapPromise:this.getMapRefPromise,renderMap:this.renderMap,componentId:this.componentId,className:this.className,dataField:this.dataField,defaultZoom:this.defaultZoom,react:this.react,size:this.size,sortBy:this.sortBy,pagination:this.pagination,uRLParams:this.URLParams,defaultSearchAsMove:this.searchAsMove,showSearchAsMove:this.showSearchAsMove,searchAsMoveLabel:this.searchAsMoveLabel,showMarkers:this.showMarkers,markerProps:this.markerProps,autoClosePopover:this.autoClosePopover,defaultPin:this.defaultPin,defaultQuery:this.defaultQuery,autoCenter:this.autoCenter,defaultCenter:this.defaultCenter,defaultRadius:this.defaultRadius,unit:this.unit,pages:this.pages,center:this.center,loader:this.loader,calculateMarkers:this.calculateMarkers}},{scopedSlots:this.$scopedSlots,on:this.$listeners}]))},install:function(e,t){e.component(ReactiveGoogleMap.name,ReactiveGoogleMap),t&&t.key||console.error("ReactiveSearch: map key is required to use ReactiveGoogleMap component"),e.use(main,{load:{key:t.key,libraries:"places"},installComponents:!1})}};ReactiveGoogleMap.componentType=constants_1$1.reactiveMap;var _excluded$k=["aggs","size"],_excluded2=["query"],_excluded3=["query"],_componentTypeToDefau,X_SEARCH_CLIENT$1="ReactiveSearch Vue",componentsWithoutFilters=[constants_1$1.numberBox,constants_1$1.ratingsFilter],resultComponents=[constants_1$1.reactiveList,constants_1$1.reactiveMap],componentTypeToDefaultValue=(_componentTypeToDefau={},_componentTypeToDefau[constants_1$1.singleList]="",_componentTypeToDefau[constants_1$1.multiList]=[],_componentTypeToDefau[constants_1$1.singleDataList]="",_componentTypeToDefau[constants_1$1.singleDropdownList]="",_componentTypeToDefau[constants_1$1.multiDataList]=[],_componentTypeToDefau[constants_1$1.multiDropdownList]=[],_componentTypeToDefau[constants_1$1.tagCloud]="",_componentTypeToDefau[constants_1$1.toggleButton]="",_componentTypeToDefau[constants_1$1.singleDropdownRange]="",_componentTypeToDefau[constants_1$1.multiDropdownRange]=[],_componentTypeToDefau[constants_1$1.singleRange]="",_componentTypeToDefau[constants_1$1.multiRange]=[],_componentTypeToDefau);function getValue(e,t,n,r){if(e&&e[t])try{return{value:JSON.parse(e[t]),reference:"URL"}}catch(n){return{value:e[t],reference:"URL"}}return{value:n||componentTypeToDefaultValue[r]||null,reference:"DEFAULT"}}function parseValue(e,t){return t.source&&t.source.parseValue?t.source.parseValue(e,t):e}function getDefaultQuery(e,t){var n=parseValue(t,e);if(e.defaultQuery){var r=e.defaultQuery(n,e);return _extends({query:helper_22(r)},helper_23(r))}return e.source.defaultQuery?{query:e.source.defaultQuery(n,e)}:{}}function getCustomQuery(e,t){var n=parseValue(t,e);if(e.customQuery){var r=e.customQuery(n,e);return _extends({query:helper_22(r)},helper_23(r))}return e.source.defaultQuery?{query:e.source.defaultQuery(n,e)}:null}function initReactivesearch(e,t,n){return new Promise((function(r,o){var s=n.url&&""!==n.url.trim()&&!n.credentials?null:n.credentials,a=!n.appbaseConfig||void 0===n.appbaseConfig.enableTelemetry||n.appbaseConfig.enableTelemetry,i=_extends({},n.enableAppbase&&_extends({"X-Search-Client":X_SEARCH_CLIENT$1},!1===a&&{"X-Enable-Telemetry":!1}),n.headers,n.enableAppbase&&n.endpoint&&n.endpoint.headers?n.endpoint.headers:{}),u=n.url&&""!==n.url.trim()?n.url:"https://scalr.api.appbase.io",l=n.transformRequest||null;n.enableAppbase&&n.endpoint&&(n.endpoint.url&&(u=n.endpoint.url),l=function(e){var t=helper_1(e,n.endpoint);return n.transformRequest?n.transformRequest(t):t});var c={url:u,app:n.app,credentials:s,transformRequest:l,type:n.type?n.type:"*",transformResponse:n.transformResponse||null,graphQLUrl:n.graphQLUrl||"",headers:i,analyticsConfig:n.appbaseConfig||null,enableAppbase:n.enableAppbase,endpoint:n.endpoint},p=appbasejs(c);c.transformRequest&&(p.transformRequest=c.transformRequest),c.transformResponse&&(p.transformResponse=c.transformResponse);var d=[],h={},f={},m={},g={},y={},v=[],_={},b=[],$={},C={},O={},T={},S={},w={},P={};e.forEach((function(e){var n=e.source.componentType;d=[].concat(d,[e.componentId]);var r={};Object.keys(e).forEach((function(t){constants_3$1.includes(t)&&(r[t]=e[t])}));var o=!1;e.source.hasInternalComponent&&(o=e.source.hasInternalComponent(e));var s=resultComponents.includes(n),a=e.componentId+"__internal",i=e.filterLabel||e.componentId,u=getValue(t,e.componentId,e.value||e.defaultValue,n),l=u.value,c=u.reference,p=void 0===e.showFilter||e.showFilter;componentsWithoutFilters.includes(n)&&(p=!1),h=valueReducer(h,{type:"SET_VALUE",component:e.componentId,label:i,value:l,reference:c,showFilter:p,URLParams:e.URLParams||!1}),e.customQuery&&"function"==typeof e.customQuery&&(S[e.componentId]=e.customQuery(l,r)),e.defaultQuery&&"function"==typeof e.defaultQuery&&(w[e.componentId]=e.defaultQuery(l,r));var m={};e&&e.source.generateQueryOptions&&(m=_extends({},m,e.source.generateQueryOptions(e)));var v={};if(e.source.highlightQuery&&(v=e.source.highlightQuery(e)),m&&Object.keys(m).length||v&&Object.keys(v).length){var _=m||{},b=_.aggs,$=_.size,C=_objectWithoutPropertiesLoose(_,_excluded$k);if(b&&Object.keys(b).length&&(o=!0,m=_extends({},m,{aggs:b,size:void 0===$?100:$})),C&&Object.keys(C).length||v&&Object.keys(v).length){C||(C={}),v||(v={});var O=_extends({},C,v,{size:$});if(o&&(O=_extends({},C,v)),s){var T=e.currentPage?e.currentPage-1:0;h[e.componentId]&&h[e.componentId].value&&(T=h[e.componentId].value-1||0);var E=e.size||10,R=T*E;r.from=R,O=_extends({},O,v,{size:E,from:R})}m=_extends({},m,O)}}if(e.react||o||s){var k=e.react;(o||s)&&(k=helper_38(k,a)),y=dependencyTreeReducer(y,{type:"WATCH_COMPONENT",component:e.componentId,react:k})}if(o&&!transform_8(e.componentType)){var I=getDefaultQuery(e,l)||{},x=I.query,A=_objectWithoutPropertiesLoose(I,_excluded2);f=queryReducer(f,{type:"SET_QUERY",component:a,query:x}),g=queryOptionsReducer(g,{type:"SET_QUERY_OPTIONS",component:a,options:_extends({},m,A)})}var L=getCustomQuery(e,l)||{},j=L.query,V=_objectWithoutPropertiesLoose(L,_excluded3),M=j;f=queryReducer(f,{type:"SET_QUERY",component:e.componentId,query:M}),g=queryOptionsReducer(g,{type:"SET_QUERY_OPTIONS",component:e.componentId,options:_extends({},V)}),r.componentType=n,P[e.componentId]=r})),T={components:d,dependencyTree:y,queryList:f,queryOptions:g,selectedValues:h,internalValues:{},props:P,customQueries:S,defaultQueries:w},e.forEach((function(e){var t=helper_37(e.componentId,y,f,g),r=t.queryObj,o=t.options,s=["aggs","from","sort"];if(r&&Object.keys(r).length||o&&Object.keys(o).some((function(e){return s.includes(e)}))){var a;(!r||r&&!Object.keys(r).length)&&(r={match_all:{}}),b=[].concat(b,[e.componentId]);var i=_extends({query:_extends({},r)},o,g[e.componentId]);if(m=_extends({},m,((a={})[e.componentId]=i,a)),n.enableAppbase){var u,l=transform_5(e.componentId,transform_3(T,e.componentId,g&&Object.keys(g[e.componentId]).length?{from:g[e.componentId].from}:null));if(l)_=_extends({},_,((u={})[e.componentId]=l,u),transform_2(T,e.componentId,b))}else{var p=c&&c.analyticsConfig&&c.analyticsConfig.userId?c.analyticsConfig.userId+"_"+e:e;v=[].concat(v,[{preference:p},i])}}})),T.queryLog=m;var E=function(e,t){return c.transformResponse&&"function"==typeof c.transformResponse?c.transformResponse(e,t):new Promise((function(t){return t(e)}))},R=function(e){var t=b.map((function(t,n){return new Promise((function(r,o){E(e.responses[n],t).then((function(e){var n,o;e.aggregations&&(C=_extends({},C,((o={})[t]=e.aggregations,o)),O=compositeAggsReducer(O,{type:constants_10,aggregations:e.aggregations,append:!1}));$=_extends({},$,((n={})[t]={hits:e.hits.hits,total:"object"==typeof e.hits.total?e.hits.total.value:e.hits.total,time:e.took},n)),r()})).catch((function(e){return o(e)}))}))}));Promise.all(t).then((function(){T=_extends({},T,{hits:$,aggregations:C}),r(T)}))};if(c.graphQLUrl){(function(e){if(c.transformRequest&&"function"==typeof c.transformRequest){var t=c.transformRequest(e);return t instanceof Promise?t:Promise.resolve(t)}return Promise.resolve(e)})(v).then((function(e){fetchGraphQL(c.graphQLUrl,c.url,c.credentials,c.app,e).then((function(e){R(e)})).catch((function(e){return o(e)}))})).catch((function(e){return o(e)}))}else if(n.enableAppbase&&Object.keys(_).length){v=Object.keys(_).map((function(e){return _[e]}));var k={};c.analyticsConfig&&(k.recordAnalytics=utils_2(c.analyticsConfig.recordAnalytics)?c.analyticsConfig.recordAnalytics:void 0,k.userId=utils_2(c.analyticsConfig.userId)?c.analyticsConfig.userId:void 0,k.enableQueryRules=utils_2(c.analyticsConfig.enableQueryRules)?c.analyticsConfig.enableQueryRules:void 0,k.customEvents=utils_2(c.analyticsConfig.customEvents)?c.analyticsConfig.customEvents:void 0),p.reactiveSearchv3(v,k).then((function(e){!function(e){var t={},n={},o={},s={},a=b.map((function(r){return new Promise((function(a,i){E(e[r],r).then((function(e){if(e){var i,u;if(e.promoted&&(t[r]=e.promoted.map((function(e){return _extends({},e.doc,{_position:e.position})}))),n[r]=e,e.customData&&(o[r]=e.customData),e.settings&&(s[r]=e.settings),e.aggregations)C=_extends({},C,((u={})[r]=e.aggregations,u));var l=e.hits?e.hits:e[r].hits;$=_extends({},$,((i={})[r]={hits:l.hits,total:"object"==typeof l.total?l.total.value:l.total,time:e.took},i)),a()}})).catch((function(e){return i(e)}))}))}));Promise.all(a).then((function(){T=_extends({},T,{hits:$,aggregations:C,compositeAggregations:O,promotedResults:t,settings:s,customData:o,rawData:n}),r(T)}))}(e)})).catch((function(e){return o(e)}))}else p.msearch({type:"*"===c.type?"":c.type,body:v}).then((function(e){R(e)})).catch((function(e){return o(e)}))}))}var version="1.33.13",components$1=[RLConnected,ResultCard,ResultList,ReactiveBase,DSConnected,SBConnected,ListConnected,ListConnected$1,RangeConnected$1,RangeConnected$2,RangeConnected$3,RangeConnected,RcConnected,RcConnected$1,RcConnected$2,TBConnected,ListConnected$2,ListConnected$3,StateProviderConnected,RangeConnected$4];function install(e){components$1.map((function(t){return e.use(t),null}))}"undefined"!=typeof window&&window.Vue&&install(window.Vue);var index$4={version:version,install:install};exports.DataSearch=DSConnected,exports.DynamicRangeSlider=RangeConnected,exports.MultiDropdownList=ListConnected$3,exports.MultiList=ListConnected$1,exports.MultiRange=RangeConnected$2,exports.RangeInput=RangeConnected$4,exports.RangeSlider=RangeConnected$3,exports.ReactiveBase=ReactiveBase,exports.ReactiveComponent=RcConnected,exports.ReactiveComponentPrivate=RcConnected$1,exports.ReactiveGoogleMap=ReactiveGoogleMap,exports.ReactiveList=RLConnected,exports.ResultCard=ResultCard,exports.ResultList=ResultList,exports.SearchBox=SBConnected,exports.SelectedFilters=RcConnected$2,exports.SingleDropdownList=ListConnected$2,exports.SingleList=ListConnected,exports.SingleRange=RangeConnected$1,exports.StateProvider=StateProviderConnected,exports.ToggleButton=TBConnected,exports.componentTypes=constants_1$1,exports.default=index$4,exports.initReactivesearch=initReactivesearch,exports.install=install,exports.version=version,Object.defineProperty(exports,"__esModule",{value:!0})}));
51
51
  //# sourceMappingURL=reactivesearch-vue.umd.min.js.map