(()=>{var e={3643:function(e){e.exports=function(){"use strict";function e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function t(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function n(n){for(var r=1;r<arguments.length;r++){var o=null!=arguments[r]?arguments[r]:{};r%2?t(Object(o),!0).forEach((function(t){e(n,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):t(Object(o)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))}))}return n}function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,s=e[Symbol.iterator]();!(r=(i=s.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw a}}return n}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function o(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function a(e){var t,n="algoliasearch-client-js-".concat(e.key),o=function(){return void 0===t&&(t=e.localStorage||window.localStorage),t},a=function(){return JSON.parse(o().getItem(n)||"{}")},i=function(e){o().setItem(n,JSON.stringify(e))},s=function(){var t=e.timeToLive?1e3*e.timeToLive:null,n=a(),o=Object.fromEntries(Object.entries(n).filter((function(e){return void 0!==r(e,2)[1].timestamp})));if(i(o),t){var s=Object.fromEntries(Object.entries(o).filter((function(e){var n=r(e,2)[1],o=(new Date).getTime();return!(n.timestamp+t<o)})));i(s)}};return{get:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{miss:function(){return Promise.resolve()}};return Promise.resolve().then((function(){s();var t=JSON.stringify(e);return a()[t]})).then((function(e){return Promise.all([e?e.value:t(),void 0!==e])})).then((function(e){var t=r(e,2),o=t[0],a=t[1];return Promise.all([o,a||n.miss(o)])})).then((function(e){return r(e,1)[0]}))},set:function(e,t){return Promise.resolve().then((function(){var r=a();return r[JSON.stringify(e)]={timestamp:(new Date).getTime(),value:t},o().setItem(n,JSON.stringify(r)),t}))},delete:function(e){return Promise.resolve().then((function(){var t=a();delete t[JSON.stringify(e)],o().setItem(n,JSON.stringify(t))}))},clear:function(){return Promise.resolve().then((function(){o().removeItem(n)}))}}}function i(e){var t=o(e.caches),n=t.shift();return void 0===n?{get:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{miss:function(){return Promise.resolve()}};return t().then((function(e){return Promise.all([e,n.miss(e)])})).then((function(e){return r(e,1)[0]}))},set:function(e,t){return Promise.resolve(t)},delete:function(e){return Promise.resolve()},clear:function(){return Promise.resolve()}}:{get:function(e,r){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{miss:function(){return Promise.resolve()}};return n.get(e,r,o).catch((function(){return i({caches:t}).get(e,r,o)}))},set:function(e,r){return n.set(e,r).catch((function(){return i({caches:t}).set(e,r)}))},delete:function(e){return n.delete(e).catch((function(){return i({caches:t}).delete(e)}))},clear:function(){return n.clear().catch((function(){return i({caches:t}).clear()}))}}}function s(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{serializable:!0},t={};return{get:function(n,r){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{miss:function(){return Promise.resolve()}},a=JSON.stringify(n);if(a in t)return Promise.resolve(e.serializable?JSON.parse(t[a]):t[a]);var i=r(),s=o&&o.miss||function(){return Promise.resolve()};return i.then((function(e){return s(e)})).then((function(){return i}))},set:function(n,r){return t[JSON.stringify(n)]=e.serializable?JSON.stringify(r):r,Promise.resolve(r)},delete:function(e){return delete t[JSON.stringify(e)],Promise.resolve()},clear:function(){return t={},Promise.resolve()}}}function l(e){for(var t=e.length-1;t>0;t--){var n=Math.floor(Math.random()*(t+1)),r=e[t];e[t]=e[n],e[n]=r}return e}function c(e,t){return t?(Object.keys(t).forEach((function(n){e[n]=t[n](e)})),e):e}function u(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=0;return e.replace(/%s/g,(function(){return encodeURIComponent(n[o++])}))}var d=0,p=1;function m(e,t){var n=e||{},r=n.data||{};return Object.keys(n).forEach((function(e){-1===["timeout","headers","queryParameters","data","cacheable"].indexOf(e)&&(r[e]=n[e])})),{data:Object.entries(r).length>0?r:void 0,timeout:n.timeout||t,headers:n.headers||{},queryParameters:n.queryParameters||{},cacheable:n.cacheable}}var f={Read:1,Write:2,Any:3};function h(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return n(n({},e),{},{status:t,lastUpdate:Date.now()})}function g(e){return"string"==typeof e?{protocol:"https",url:e,accept:f.Any}:{protocol:e.protocol||"https",url:e.url,accept:e.accept||f.Any}}var b="GET",v="POST";function y(e,t,r,a){var i=[],s=function(e,t){if(e.method!==b&&(void 0!==e.data||void 0!==t.data)){var r=Array.isArray(e.data)?e.data:n(n({},e.data),t.data);return JSON.stringify(r)}}(r,a),l=function(e,t){var r=n(n({},e.headers),t.headers),o={};return Object.keys(r).forEach((function(e){var t=r[e];o[e.toLowerCase()]=t})),o}(e,a),c=r.method,u=r.method!==b?{}:n(n({},r.data),a.data),d=n(n(n({"x-algolia-agent":e.userAgent.value},e.queryParameters),u),a.queryParameters),p=0,m=function t(n,o){var u=n.pop();if(void 0===u)throw{name:"RetryError",message:"Unreachable hosts - your application id may be incorrect. If the error persists, contact support@algolia.com.",transporterStackTrace:w(i)};var m={data:s,headers:l,method:c,url:k(u,r.path,d),connectTimeout:o(p,e.timeouts.connect),responseTimeout:o(p,a.timeout)},f=function(e){var t={request:m,response:e,host:u,triesLeft:n.length};return i.push(t),t},g={onSuccess:function(e){return function(e){try{return JSON.parse(e.content)}catch(t){throw function(e,t){return{name:"DeserializationError",message:e,response:t}}(t.message,e)}}(e)},onRetry:function(r){var a=f(r);return r.isTimedOut&&p++,Promise.all([e.logger.info("Retryable failure",S(a)),e.hostsCache.set(u,h(u,r.isTimedOut?3:2))]).then((function(){return t(n,o)}))},onFail:function(e){throw f(e),function(e,t){var n=e.content,r=e.status,o=n;try{o=JSON.parse(n).message}catch(e){}return function(e,t,n){return{name:"ApiError",message:e,status:t,transporterStackTrace:n}}(o,r,t)}(e,w(i))}};return e.requester.send(m).then((function(e){return function(e,t){return function(e){var t=e.status;return e.isTimedOut||function(e){var t=e.isTimedOut,n=e.status;return!t&&!~~n}(e)||2!=~~(t/100)&&4!=~~(t/100)}(e)?t.onRetry(e):2==~~(e.status/100)?t.onSuccess(e):t.onFail(e)}(e,g)}))};return function(e,t){return Promise.all(t.map((function(t){return e.get(t,(function(){return Promise.resolve(h(t))}))}))).then((function(e){var n=e.filter((function(e){return function(e){return 1===e.status||Date.now()-e.lastUpdate>12e4}(e)})),r=e.filter((function(e){return function(e){return 3===e.status&&Date.now()-e.lastUpdate<=12e4}(e)})),a=[].concat(o(n),o(r));return{getTimeout:function(e,t){return(0===r.length&&0===e?1:r.length+3+e)*t},statelessHosts:a.length>0?a.map((function(e){return g(e)})):t}}))}(e.hostsCache,t).then((function(e){return m(o(e.statelessHosts).reverse(),e.getTimeout)}))}function E(e){var t={value:"Algolia for JavaScript (".concat(e,")"),add:function(e){var n="; ".concat(e.segment).concat(void 0!==e.version?" (".concat(e.version,")"):"");return-1===t.value.indexOf(n)&&(t.value="".concat(t.value).concat(n)),t}};return t}function k(e,t,n){var r=_(n),o="".concat(e.protocol,"://").concat(e.url,"/").concat("/"===t.charAt(0)?t.substr(1):t);return r.length&&(o+="?".concat(r)),o}function _(e){return Object.keys(e).map((function(t){return u("%s=%s",t,(n=e[t],"[object Object]"===Object.prototype.toString.call(n)||"[object Array]"===Object.prototype.toString.call(n)?JSON.stringify(e[t]):e[t]));var n})).join("&")}function w(e){return e.map((function(e){return S(e)}))}function S(e){var t=e.request.headers["x-algolia-api-key"]?{"x-algolia-api-key":"*****"}:{};return n(n({},e),{},{request:n(n({},e.request),{},{headers:n(n({},e.request.headers),t)})})}var O=function(e){var t=e.appId,o=function(e,t,n){var r={"x-algolia-api-key":n,"x-algolia-application-id":t};return{headers:function(){return e===p?r:{}},queryParameters:function(){return e===d?r:{}}}}(void 0!==e.authMode?e.authMode:p,t,e.apiKey),a=function(e){var t=e.hostsCache,n=e.logger,o=e.requester,a=e.requestsCache,i=e.responsesCache,s=e.timeouts,l=e.userAgent,c=e.hosts,u=e.queryParameters,d={hostsCache:t,logger:n,requester:o,requestsCache:a,responsesCache:i,timeouts:s,userAgent:l,headers:e.headers,queryParameters:u,hosts:c.map((function(e){return g(e)})),read:function(e,t){var n=m(t,d.timeouts.read),o=function(){return y(d,d.hosts.filter((function(e){return!!(e.accept&f.Read)})),e,n)};if(!0!==(void 0!==n.cacheable?n.cacheable:e.cacheable))return o();var a={request:e,mappedRequestOptions:n,transporter:{queryParameters:d.queryParameters,headers:d.headers}};return d.responsesCache.get(a,(function(){return d.requestsCache.get(a,(function(){return d.requestsCache.set(a,o()).then((function(e){return Promise.all([d.requestsCache.delete(a),e])}),(function(e){return Promise.all([d.requestsCache.delete(a),Promise.reject(e)])})).then((function(e){var t=r(e,2);return t[0],t[1]}))}))}),{miss:function(e){return d.responsesCache.set(a,e)}})},write:function(e,t){return y(d,d.hosts.filter((function(e){return!!(e.accept&f.Write)})),e,m(t,d.timeouts.write))}};return d}(n(n({hosts:[{url:"".concat(t,"-dsn.algolia.net"),accept:f.Read},{url:"".concat(t,".algolia.net"),accept:f.Write}].concat(l([{url:"".concat(t,"-1.algolianet.com")},{url:"".concat(t,"-2.algolianet.com")},{url:"".concat(t,"-3.algolianet.com")}]))},e),{},{headers:n(n(n({},o.headers()),{"content-type":"application/x-www-form-urlencoded"}),e.headers),queryParameters:n(n({},o.queryParameters()),e.queryParameters)}));return c({transporter:a,appId:t,addAlgoliaAgent:function(e,t){a.userAgent.add({segment:e,version:t})},clearCache:function(){return Promise.all([a.requestsCache.clear(),a.responsesCache.clear()]).then((function(){}))}},e.methods)},C=function(e){return function(t,n){return t.method===b?e.transporter.read(t,n):e.transporter.write(t,n)}},x=function(e){return function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return c({transporter:e.transporter,appId:e.appId,indexName:t},n.methods)}},A=function(e){return function(t,r){var o=t.map((function(e){return n(n({},e),{},{params:_(e.params||{})})}));return e.transporter.read({method:v,path:"1/indexes/*/queries",data:{requests:o},cacheable:!0},r)}},I=function(e){return function(t,r){return Promise.all(t.map((function(t){var o=t.params,a=o.facetName,i=o.facetQuery,s=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(o,["facetName","facetQuery"]);return x(e)(t.indexName,{methods:{searchForFacetValues:N}}).searchForFacetValues(a,i,n(n({},r),s))})))}},P=function(e){return function(t,n,r){return e.transporter.read({method:v,path:u("1/answers/%s/prediction",e.indexName),data:{query:t,queryLanguages:n},cacheable:!0},r)}},T=function(e){return function(t,n){return e.transporter.read({method:v,path:u("1/indexes/%s/query",e.indexName),data:{query:t},cacheable:!0},n)}},N=function(e){return function(t,n,r){return e.transporter.read({method:v,path:u("1/indexes/%s/facets/%s/query",e.indexName,t),data:{facetQuery:n},cacheable:!0},r)}};function D(e,t,r){var o={appId:e,apiKey:t,timeouts:{connect:1,read:2,write:30},requester:{send:function(e){return new Promise((function(t){var n=new XMLHttpRequest;n.open(e.method,e.url,!0),Object.keys(e.headers).forEach((function(t){return n.setRequestHeader(t,e.headers[t])}));var r,o=function(e,r){return setTimeout((function(){n.abort(),t({status:0,content:r,isTimedOut:!0})}),1e3*e)},a=o(e.connectTimeout,"Connection timeout");n.onreadystatechange=function(){n.readyState>n.OPENED&&void 0===r&&(clearTimeout(a),r=o(e.responseTimeout,"Socket timeout"))},n.onerror=function(){0===n.status&&(clearTimeout(a),clearTimeout(r),t({content:n.responseText||"Network request failed",status:n.status,isTimedOut:!1}))},n.onload=function(){clearTimeout(a),clearTimeout(r),t({content:n.responseText,status:n.status,isTimedOut:!1})},n.send(e.data)}))}},logger:{debug:function(e,t){return Promise.resolve()},info:function(e,t){return Promise.resolve()},error:function(e,t){return console.error(e,t),Promise.resolve()}},responsesCache:s(),requestsCache:s({serializable:!1}),hostsCache:i({caches:[a({key:"".concat("4.19.1","-").concat(e)}),s()]}),userAgent:E("4.19.1").add({segment:"Browser",version:"lite"}),authMode:d};return O(n(n(n({},o),r),{},{methods:{search:A,searchForFacetValues:I,multipleQueries:A,multipleSearchForFacetValues:I,customRequest:C,initIndex:function(e){return function(t){return x(e)(t,{methods:{search:T,searchForFacetValues:N,findAnswers:P}})}}}}))}return D.version="4.19.1",D}()},2485:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var a=typeof n;if("string"===a||"number"===a)e.push(n);else if(Array.isArray(n)){if(n.length){var i=o.apply(null,n);i&&e.push(i)}}else if("object"===a)if(n.toString===Object.prototype.toString)for(var s in n)r.call(n,s)&&n[s]&&e.push(s);else e.push(n.toString())}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(n=function(){return o}.apply(t,[]))||(e.exports=n)}()},2963:(e,t,n)=>{"use strict";var r=n(4994);t.__esModule=!0,t.default=function(e,t){e.classList?e.classList.add(t):(0,o.default)(e,t)||("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))};var o=r(n(598));e.exports=t.default},598:(e,t)=>{"use strict";t.__esModule=!0,t.default=function(e,t){return e.classList?!!t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")},e.exports=t.default},788:e=>{"use strict";function t(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}e.exports=function(e,n){e.classList?e.classList.remove(n):"string"==typeof e.className?e.className=t(e.className,n):e.setAttribute("class",t(e.className&&e.className.baseVal||"",n))}},5127:()=>{!function(){"use strict";if("object"==typeof window)if("IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype)"isIntersecting"in window.IntersectionObserverEntry.prototype||Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});else{var e=window.document,t=[],n=null,r=null;a.prototype.THROTTLE_TIMEOUT=100,a.prototype.POLL_INTERVAL=null,a.prototype.USE_MUTATION_OBSERVER=!0,a._setupCrossOriginUpdater=function(){return n||(n=function(e,n){r=e&&n?u(e,n):{top:0,bottom:0,left:0,right:0,width:0,height:0},t.forEach((function(e){e._checkForIntersections()}))}),n},a._resetCrossOriginUpdater=function(){n=null,r=null},a.prototype.observe=function(e){if(!this._observationTargets.some((function(t){return t.element==e}))){if(!e||1!=e.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:e,entry:null}),this._monitorIntersections(e.ownerDocument),this._checkForIntersections()}},a.prototype.unobserve=function(e){this._observationTargets=this._observationTargets.filter((function(t){return t.element!=e})),this._unmonitorIntersections(e.ownerDocument),0==this._observationTargets.length&&this._unregisterInstance()},a.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorAllIntersections(),this._unregisterInstance()},a.prototype.takeRecords=function(){var e=this._queuedEntries.slice();return this._queuedEntries=[],e},a.prototype._initThresholds=function(e){var t=e||[0];return Array.isArray(t)||(t=[t]),t.sort().filter((function(e,t,n){if("number"!=typeof e||isNaN(e)||e<0||e>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return e!==n[t-1]}))},a.prototype._parseRootMargin=function(e){var t=(e||"0px").split(/\s+/).map((function(e){var t=/^(-?\d*\.?\d+)(px|%)$/.exec(e);if(!t)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(t[1]),unit:t[2]}}));return t[1]=t[1]||t[0],t[2]=t[2]||t[0],t[3]=t[3]||t[1],t},a.prototype._monitorIntersections=function(t){var n=t.defaultView;if(n&&-1==this._monitoringDocuments.indexOf(t)){var r=this._checkForIntersections,o=null,a=null;if(this.POLL_INTERVAL?o=n.setInterval(r,this.POLL_INTERVAL):(i(n,"resize",r,!0),i(t,"scroll",r,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in n&&(a=new n.MutationObserver(r)).observe(t,{attributes:!0,childList:!0,characterData:!0,subtree:!0})),this._monitoringDocuments.push(t),this._monitoringUnsubscribes.push((function(){var e=t.defaultView;e&&(o&&e.clearInterval(o),s(e,"resize",r,!0)),s(t,"scroll",r,!0),a&&a.disconnect()})),t!=(this.root&&this.root.ownerDocument||e)){var l=m(t);l&&this._monitorIntersections(l.ownerDocument)}}},a.prototype._unmonitorIntersections=function(t){var n=this._monitoringDocuments.indexOf(t);if(-1!=n){var r=this.root&&this.root.ownerDocument||e,o=this._observationTargets.some((function(e){var n=e.element.ownerDocument;if(n==t)return!0;for(;n&&n!=r;){var o=m(n);if((n=o&&o.ownerDocument)==t)return!0}return!1}));if(!o){var a=this._monitoringUnsubscribes[n];if(this._monitoringDocuments.splice(n,1),this._monitoringUnsubscribes.splice(n,1),a(),t!=r){var i=m(t);i&&this._unmonitorIntersections(i.ownerDocument)}}}},a.prototype._unmonitorAllIntersections=function(){var e=this._monitoringUnsubscribes.slice(0);this._monitoringDocuments.length=0,this._monitoringUnsubscribes.length=0;for(var t=0;t<e.length;t++)e[t]()},a.prototype._checkForIntersections=function(){if(this.root||!n||r){var e=this._rootIsInDom(),t=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(r){var a=r.element,i=l(a),s=this._rootContainsTarget(a),c=r.entry,u=e&&s&&this._computeTargetAndRootIntersection(a,i,t),d=r.entry=new o({time:window.performance&&performance.now&&performance.now(),target:a,boundingClientRect:i,rootBounds:n&&!this.root?null:t,intersectionRect:u});c?e&&s?this._hasCrossedThreshold(c,d)&&this._queuedEntries.push(d):c&&c.isIntersecting&&this._queuedEntries.push(d):this._queuedEntries.push(d)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)}},a.prototype._computeTargetAndRootIntersection=function(t,o,a){if("none"!=window.getComputedStyle(t).display){for(var i,s,c,d,m,f,h,g,b=o,v=p(t),y=!1;!y&&v;){var E=null,k=1==v.nodeType?window.getComputedStyle(v):{};if("none"==k.display)return null;if(v==this.root||9==v.nodeType)if(y=!0,v==this.root||v==e)n&&!this.root?!r||0==r.width&&0==r.height?(v=null,E=null,b=null):E=r:E=a;else{var _=p(v),w=_&&l(_),S=_&&this._computeTargetAndRootIntersection(_,w,a);w&&S?(v=_,E=u(w,S)):(v=null,b=null)}else{var O=v.ownerDocument;v!=O.body&&v!=O.documentElement&&"visible"!=k.overflow&&(E=l(v))}if(E&&(i=E,s=b,void 0,void 0,void 0,void 0,void 0,void 0,c=Math.max(i.top,s.top),d=Math.min(i.bottom,s.bottom),m=Math.max(i.left,s.left),g=d-c,b=(h=(f=Math.min(i.right,s.right))-m)>=0&&g>=0&&{top:c,bottom:d,left:m,right:f,width:h,height:g}||null),!b)break;v=v&&p(v)}return b}},a.prototype._getRootRect=function(){var t;if(this.root)t=l(this.root);else{var n=e.documentElement,r=e.body;t={top:0,left:0,right:n.clientWidth||r.clientWidth,width:n.clientWidth||r.clientWidth,bottom:n.clientHeight||r.clientHeight,height:n.clientHeight||r.clientHeight}}return this._expandRectByRootMargin(t)},a.prototype._expandRectByRootMargin=function(e){var t=this._rootMarginValues.map((function(t,n){return"px"==t.unit?t.value:t.value*(n%2?e.width:e.height)/100})),n={top:e.top-t[0],right:e.right+t[1],bottom:e.bottom+t[2],left:e.left-t[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},a.prototype._hasCrossedThreshold=function(e,t){var n=e&&e.isIntersecting?e.intersectionRatio||0:-1,r=t.isIntersecting?t.intersectionRatio||0:-1;if(n!==r)for(var o=0;o<this.thresholds.length;o++){var a=this.thresholds[o];if(a==n||a==r||a<n!=a<r)return!0}},a.prototype._rootIsInDom=function(){return!this.root||d(e,this.root)},a.prototype._rootContainsTarget=function(t){return d(this.root||e,t)&&(!this.root||this.root.ownerDocument==t.ownerDocument)},a.prototype._registerInstance=function(){t.indexOf(this)<0&&t.push(this)},a.prototype._unregisterInstance=function(){var e=t.indexOf(this);-1!=e&&t.splice(e,1)},window.IntersectionObserver=a,window.IntersectionObserverEntry=o}function o(e){this.time=e.time,this.target=e.target,this.rootBounds=c(e.rootBounds),this.boundingClientRect=c(e.boundingClientRect),this.intersectionRect=c(e.intersectionRect||{top:0,bottom:0,left:0,right:0,width:0,height:0}),this.isIntersecting=!!e.intersectionRect;var t=this.boundingClientRect,n=t.width*t.height,r=this.intersectionRect,o=r.width*r.height;this.intersectionRatio=n?Number((o/n).toFixed(4)):this.isIntersecting?1:0}function a(e,t){var n,r,o,a=t||{};if("function"!=typeof e)throw new Error("callback must be a function");if(a.root&&1!=a.root.nodeType)throw new Error("root must be an Element");this._checkForIntersections=(n=this._checkForIntersections.bind(this),r=this.THROTTLE_TIMEOUT,o=null,function(){o||(o=setTimeout((function(){n(),o=null}),r))}),this._callback=e,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(a.rootMargin),this.thresholds=this._initThresholds(a.threshold),this.root=a.root||null,this.rootMargin=this._rootMarginValues.map((function(e){return e.value+e.unit})).join(" "),this._monitoringDocuments=[],this._monitoringUnsubscribes=[]}function i(e,t,n,r){"function"==typeof e.addEventListener?e.addEventListener(t,n,r||!1):"function"==typeof e.attachEvent&&e.attachEvent("on"+t,n)}function s(e,t,n,r){"function"==typeof e.removeEventListener?e.removeEventListener(t,n,r||!1):"function"==typeof e.detatchEvent&&e.detatchEvent("on"+t,n)}function l(e){var t;try{t=e.getBoundingClientRect()}catch(e){}return t?(t.width&&t.height||(t={top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.right-t.left,height:t.bottom-t.top}),t):{top:0,bottom:0,left:0,right:0,width:0,height:0}}function c(e){return!e||"x"in e?e:{top:e.top,y:e.top,bottom:e.bottom,left:e.left,x:e.left,right:e.right,width:e.width,height:e.height}}function u(e,t){var n=t.top-e.top,r=t.left-e.left;return{top:n,left:r,height:t.height,width:t.width,bottom:n+t.height,right:r+t.width}}function d(e,t){for(var n=t;n;){if(n==e)return!0;n=p(n)}return!1}function p(t){var n=t.parentNode;return 9==t.nodeType&&t!=e?m(t):n&&11==n.nodeType&&n.host?n.host:n&&n.assignedSlot?n.assignedSlot.parentNode:n}function m(e){try{return e.defaultView&&e.defaultView.frameElement||null}catch(e){return null}}}()},3491:function(e){(function(){var t,n,r,o,a,i;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:"undefined"!=typeof process&&null!==process&&process.hrtime?(e.exports=function(){return(t()-a)/1e6},n=process.hrtime,o=(t=function(){var e;return 1e9*(e=n())[0]+e[1]})(),i=1e9*process.uptime(),a=o-i):Date.now?(e.exports=function(){return Date.now()-r},r=Date.now()):(e.exports=function(){return(new Date).getTime()-r},r=(new Date).getTime())}).call(this)},2694:(e,t,n)=>{"use strict";var r=n(6925);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:o};return n.PropTypes=n,n}},5556:(e,t,n)=>{e.exports=n(2694)()},6925:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},3146:(e,t,n)=>{for(var r=n(3491),o="undefined"==typeof window?n.g:window,a=["moz","webkit"],i="AnimationFrame",s=o["request"+i],l=o["cancel"+i]||o["cancelRequest"+i],c=0;!s&&c<a.length;c++)s=o[a[c]+"Request"+i],l=o[a[c]+"Cancel"+i]||o[a[c]+"CancelRequest"+i];if(!s||!l){var u=0,d=0,p=[],m=1e3/60;s=function(e){if(0===p.length){var t=r(),n=Math.max(0,m-(t-u));u=n+t,setTimeout((function(){var e=p.slice(0);p.length=0;for(var t=0;t<e.length;t++)if(!e[t].cancelled)try{e[t].callback(u)}catch(e){setTimeout((function(){throw e}),0)}}),Math.round(n))}return p.push({handle:++d,callback:e,cancelled:!1}),d},l=function(e){for(var t=0;t<p.length;t++)p[t].handle===e&&(p[t].cancelled=!0)}}e.exports=function(e){return s.call(o,e)},e.exports.cancel=function(){l.apply(o,arguments)},e.exports.polyfill=function(e){e||(e=o),e.requestAnimationFrame=s,e.cancelAnimationFrame=l}},1345:(e,t,n)=>{"use strict";function r(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);null!=e&&this.setState(e)}function o(e){this.setState(function(t){var n=this.constructor.getDerivedStateFromProps(e,t);return null!=n?n:null}.bind(this))}function a(e,t){try{var n=this.props,r=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(n,r)}finally{this.props=n,this.state=r}}function i(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if("function"!=typeof e.getDerivedStateFromProps&&"function"!=typeof t.getSnapshotBeforeUpdate)return e;var n=null,i=null,s=null;if("function"==typeof t.componentWillMount?n="componentWillMount":"function"==typeof t.UNSAFE_componentWillMount&&(n="UNSAFE_componentWillMount"),"function"==typeof t.componentWillReceiveProps?i="componentWillReceiveProps":"function"==typeof t.UNSAFE_componentWillReceiveProps&&(i="UNSAFE_componentWillReceiveProps"),"function"==typeof t.componentWillUpdate?s="componentWillUpdate":"function"==typeof t.UNSAFE_componentWillUpdate&&(s="UNSAFE_componentWillUpdate"),null!==n||null!==i||null!==s){var l=e.displayName||e.name,c="function"==typeof e.getDerivedStateFromProps?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n"+l+" uses "+c+" but also contains the following legacy lifecycles:"+(null!==n?"\n "+n:"")+(null!==i?"\n "+i:"")+(null!==s?"\n "+s:"")+"\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://fb.me/react-async-component-lifecycle-hooks")}if("function"==typeof e.getDerivedStateFromProps&&(t.componentWillMount=r,t.componentWillReceiveProps=o),"function"==typeof t.getSnapshotBeforeUpdate){if("function"!=typeof t.componentDidUpdate)throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=a;var u=t.componentDidUpdate;t.componentDidUpdate=function(e,t,n){var r=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:n;u.call(this,e,t,r)}}return e}n.r(t),n.d(t,{polyfill:()=>i}),r.__suppressDeprecationWarning=!0,o.__suppressDeprecationWarning=!0,a.__suppressDeprecationWarning=!0},8006:(e,t,n)=>{"use strict";var r=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},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=n(1609),i=l(a),s=l(n(5556));function l(e){return e&&e.__esModule?e:{default:e}}var c={position:"absolute",top:0,left:0,visibility:"hidden",height:0,overflow:"scroll",whiteSpace:"pre"},u=["extraWidth","injectStyles","inputClassName","inputRef","inputStyle","minWidth","onAutosize","placeholderIsMinWidth"],d=function(e,t){t.style.fontSize=e.fontSize,t.style.fontFamily=e.fontFamily,t.style.fontWeight=e.fontWeight,t.style.fontStyle=e.fontStyle,t.style.letterSpacing=e.letterSpacing,t.style.textTransform=e.textTransform},p=!("undefined"==typeof window||!window.navigator)&&/MSIE |Trident\/|Edge\//.test(window.navigator.userAgent),m=function(){return p?"_"+Math.random().toString(36).substr(2,12):void 0},f=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.inputRef=function(e){n.input=e,"function"==typeof n.props.inputRef&&n.props.inputRef(e)},n.placeHolderSizerRef=function(e){n.placeHolderSizer=e},n.sizerRef=function(e){n.sizer=e},n.state={inputWidth:e.minWidth,inputId:e.id||m()},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,[{key:"componentDidMount",value:function(){this.mounted=!0,this.copyInputStyles(),this.updateInputWidth()}},{key:"UNSAFE_componentWillReceiveProps",value:function(e){var t=e.id;t!==this.props.id&&this.setState({inputId:t||m()})}},{key:"componentDidUpdate",value:function(e,t){t.inputWidth!==this.state.inputWidth&&"function"==typeof this.props.onAutosize&&this.props.onAutosize(this.state.inputWidth),this.updateInputWidth()}},{key:"componentWillUnmount",value:function(){this.mounted=!1}},{key:"copyInputStyles",value:function(){if(this.mounted&&window.getComputedStyle){var e=this.input&&window.getComputedStyle(this.input);e&&(d(e,this.sizer),this.placeHolderSizer&&d(e,this.placeHolderSizer))}}},{key:"updateInputWidth",value:function(){if(this.mounted&&this.sizer&&void 0!==this.sizer.scrollWidth){var e=void 0;e=this.props.placeholder&&(!this.props.value||this.props.value&&this.props.placeholderIsMinWidth)?Math.max(this.sizer.scrollWidth,this.placeHolderSizer.scrollWidth)+2:this.sizer.scrollWidth+2,(e+="number"===this.props.type&&void 0===this.props.extraWidth?16:parseInt(this.props.extraWidth)||0)<this.props.minWidth&&(e=this.props.minWidth),e!==this.state.inputWidth&&this.setState({inputWidth:e})}}},{key:"getInput",value:function(){return this.input}},{key:"focus",value:function(){this.input.focus()}},{key:"blur",value:function(){this.input.blur()}},{key:"select",value:function(){this.input.select()}},{key:"renderStyles",value:function(){var e=this.props.injectStyles;return p&&e?i.default.createElement("style",{dangerouslySetInnerHTML:{__html:"input#"+this.state.inputId+"::-ms-clear {display: none;}"}}):null}},{key:"render",value:function(){var e=[this.props.defaultValue,this.props.value,""].reduce((function(e,t){return null!=e?e:t})),t=r({},this.props.style);t.display||(t.display="inline-block");var n=r({boxSizing:"content-box",width:this.state.inputWidth+"px"},this.props.inputStyle),o=function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(this.props,[]);return function(e){u.forEach((function(t){return delete e[t]}))}(o),o.className=this.props.inputClassName,o.id=this.state.inputId,o.style=n,i.default.createElement("div",{className:this.props.className,style:t},this.renderStyles(),i.default.createElement("input",r({},o,{ref:this.inputRef})),i.default.createElement("div",{ref:this.sizerRef,style:c},e),this.props.placeholder?i.default.createElement("div",{ref:this.placeHolderSizerRef,style:c},this.props.placeholder):null)}}]),t}(a.Component);f.propTypes={className:s.default.string,defaultValue:s.default.any,extraWidth:s.default.oneOfType([s.default.number,s.default.string]),id:s.default.string,injectStyles:s.default.bool,inputClassName:s.default.string,inputRef:s.default.func,inputStyle:s.default.object,minWidth:s.default.oneOfType([s.default.number,s.default.string]),onAutosize:s.default.func,onChange:s.default.func,placeholder:s.default.string,placeholderIsMinWidth:s.default.bool,style:s.default.object,value:s.default.any},f.defaultProps={minWidth:1,injectStyles:!0},t.A=f},220:(e,t,n)=>{"use strict";var r=n(6305),o=n(4994);t.A=void 0;var a=o(n(4634)),i=o(n(6305)),s=r(n(1609)),l=o(n(9893)),c=n(4848);function u(){}s.default.createElement;var d={contain:"react-Slidy--contain",cover:"react-Slidy--cover",fullHeight:"react-Slidy--fullHeight",fullWidth:"react-Slidy--fullWidth"};t.A=function(e){var t=e.ArrowLeft,r=e.ArrowRight,o=e.children,p=e.classNameBase,m=void 0===p?"react-Slidy":p,f=e.doAfterDestroy,h=void 0===f?u:f,g=e.doAfterInit,b=void 0===g?u:g,v=e.doAfterSlide,y=void 0===v?u:v,E=e.doBeforeSlide,k=void 0===E?u:E,_=e.imageObjectFit,w=e.infiniteLoop,S=void 0!==w&&w,O=e.itemsToPreload,C=void 0===O?1:O,x=e.initialSlide,A=void 0===x?0:x,I=e.ease,P=void 0===I?"ease":I,T=e.lazyLoadSlider,N=void 0===T||T,D=e.lazyLoadConfig,L=void 0===D?{offset:150}:D,F=e.keyboardNavigation,j=void 0!==F&&F,R=e.numOfSlides,M=void 0===R?1:R,B=e.sanitize,V=void 0===B||B,H=e.slide,z=void 0===H?0:H,U=e.slideSpeed,W=void 0===U?500:U,q=e.showArrows,G=void 0===q||q,K=e.useFullHeight,$=void 0!==K&&K,Y=e.useFullWidth,Z=void 0===Y||Y,J=(0,s.useState)(!N),Q=J[0],X=J[1],ee=(0,s.useRef)(null);(0,s.useEffect)((function(){var e;if(N){var t=function(){var t=L.offset,n=void 0===t?0:t;(e=new window.IntersectionObserver(te,{rootMargin:n+"px 0px 0px"})).observe(ee.current)};"IntersectionObserver"in window?t():Promise.resolve().then((function(){return(0,i.default)(n(5127))})).then(t)}return function(){return e&&e.disconnect()}}),[]);var te=function(e,t){var n=e[0];(n.isIntersecting||n.intersectionRatio>0)&&(t.unobserve(n.target),X(!0))},ne=Math.min(M,s.default.Children.count(o)),re=[m,$&&d.fullHeight,Z&&d.fullWidth,_&&d[_]].filter(Boolean).join(" "),oe={ArrowLeft:t,ArrowRight:r,children:o,classNameBase:m,doAfterDestroy:h,doAfterInit:b,doAfterSlide:y,doBeforeSlide:k,ease:P,infiniteLoop:S,initialSlide:A,itemsToPreload:C,keyboardNavigation:j,numOfSlides:M,showArrows:G,slide:z,slideSpeed:W};return(0,c.jsx)("div",{className:re,ref:ee,children:Q&&(0,c.jsx)(l.default,(0,a.default)({},oe,{numOfSlides:V?ne:M,children:o}))})}},9893:(e,t,n)=>{"use strict";var r=n(6305),o=n(4994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.ArrowLeft,n=e.ArrowRight,r=e.children,o=e.classNameBase,d=e.doAfterDestroy,p=e.doAfterInit,m=e.doAfterSlide,f=e.doBeforeSlide,h=e.ease,g=e.infiniteLoop,b=e.initialSlide,v=e.itemsToPreload,y=e.keyboardNavigation,E=e.numOfSlides,k=e.showArrows,_=e.slide,w=e.slideSpeed,S=(0,i.useState)({goTo:c,next:c,prev:c,updateItems:c}),O=S[0],C=S[1],x=(0,i.useState)(b),A=x[0],I=x[1],P=(0,i.useState)(b),T=P[0],N=P[1],D=(0,i.useRef)(null),L=(0,i.useRef)(null),F=function(e){return Array.isArray(e)?e:[e]}(r);(0,i.useEffect)((function(){_!==A&&O.goTo(_)}),[_]),(0,i.useEffect)((function(){var e,t=(0,s.default)(D.current,{ease:h,doAfterSlide:m,doBeforeSlide:f,numOfSlides:E,slideSpeed:w,infiniteLoop:g,slidesDOMEl:L.current,initialSlide:A,items:F.length,onNext:function(e){return I(e),e>T&&N(e),e},onPrev:function(e){return I(e),e}});return C(t),p(),y&&(e=function(e){39===e.keyCode?t.next(e):37===e.keyCode&&t.prev(e)},document.addEventListener("keydown",e)),function(){!function(e,t){e&&e.clean()&&e.destroy(),t()}(t,d),y&&document.removeEventListener("keydown",e)}}),[]),(0,i.useEffect)((function(){O&&O.updateItems(F.length)}));var j,R,M=function(e){var t=e.index,n=e.maxIndex,r=e.items,o=e.itemsToPreload,a=e.numOfSlides,i=Math.max(o,a);if(t>=r.length-a){var s=r.length>a?r.slice(0,a-1):[];return[].concat(r.slice(0,n+i),s)}return r.slice(0,n+i)}({index:A,maxIndex:T,items:F,itemsToPreload:v,numOfSlides:E}),B=function(e){return F.length>E&&O.next(e)};return(0,l.jsxs)(l.Fragment,{children:[k&&(0,l.jsxs)(l.Fragment,{children:[(j={disabled:0===A&&!g,onClick:function(e){return O.prev(e)}},R=o+"-arrow "+o+"-arrowLeft",t?(0,l.jsx)(t,(0,a.default)({},j,{className:R})):(0,l.jsx)("span",(0,a.default)({"aria-label":"Previous",className:R+" "+o+"-prev",role:"button"},j))),function(){var e={disabled:(F.length<=E||A===F.length-1)&&!g,onClick:B},t=o+"-arrow "+o+"-arrowRight";return n?(0,l.jsx)(n,(0,a.default)({},e,{className:t})):(0,l.jsx)("span",(0,a.default)({"aria-label":"Next",className:t+" "+o+"-next",role:"button"},e))}()]}),(0,l.jsx)("div",{ref:D,children:(0,l.jsx)("ul",{ref:L,children:M.map(u(E))})})]})};var a=o(n(4634)),i=r(n(1609)),s=o(n(7529)),l=n(4848);function c(e){}i.default.createElement;var u=function(e){return function(t,n){var r=1!==e?{width:100/e+"%"}:{};return(0,l.jsx)("li",{style:r,children:t},n)}}},7529:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.translate=s,t.infiniteIndex=l,t.clampNumber=c,t.default=function(e,t){var d=t.doAfterSlide,p=t.doBeforeSlide,m=t.ease,f=t.infiniteLoop,h=t.initialSlide,g=t.numOfSlides,b=t.onNext,v=t.onPrev,y=t.slidesDOMEl,E=t.slideSpeed,k=t.items;if(null!==e){var _=h,w=!1,S=!1,O=0,C=0,x=0,A=0;return y.addEventListener(o,T),e.addEventListener("touchstart",N,i),e.addEventListener("touchmove",D,i),e.addEventListener("touchend",L,i),0!==_&&I(0),{clean:function(){return function(e){for(;e.childElementCount>1;)null!==e&&e.removeChild(e.lastChild);return!0}(y)},destroy:function(){e.removeEventListener("touchstart",N,i),e.removeEventListener("touchmove",D,i),e.removeEventListener("touchend",L,i),y.removeEventListener(o,T)},goTo:F,next:function(e){e.preventDefault(),e.stopPropagation(),P(!0)},prev:function(e){e.preventDefault(),e.stopPropagation(),P(!1)},slide:P,updateItems:function(e){k=e}}}function I(e,t,n){void 0===t&&(t=""),void 0===n&&(n=0);var r=100/g;y.style.cssText=function(e,t,n,r,o){return""+(""!==t?"transition-timing-function: "+t+";":"")+(e?"transition-duration: "+e+"ms;":"")+"transform: "+s(n,r,o)+";"}(e,t,_,n,r)}function P(e){var t=_+1*(!0===e?1:-1);f&&(t=l(t,k)),F(t=c(t,0,k-1))}function T(){!0===S&&(I(0),S=!1)}function N(e){var t=u(e);w=void 0,x=t.pageX,A=t.pageY}function D(e){if(!(e.touches.length>1||e.scale&&1!==e.scale)){var t=u(e);O=t.pageX-x,C=t.pageY-A,void 0!==w?w||(e.preventDefault(),I(0,n,-1*O)):(w=a(O)<a(C))||(document.ontouchmove=function(e){return e.preventDefault()})}}function L(){if(document.ontouchmove=function(){return!0},!w){var e=a(O)>r,t=O<0;!0===e&&!1==(!1===t&&0===_||!0===t&&_===k-1)?P(t):I(E,n)}O=C=x=A=0}function F(e){e!==_&&(e<=k&&(p({currentSlide:_,nextSlide:e}),e>_?b(e):v(e),_=e),I(E,m),y.addEventListener(o,(function e(t){d({currentSlide:_}),t.currentTarget.removeEventListener(t.type,e)})))}};var n="linear",r=50,o="transitionend",a=Math.abs,i={passive:!1};function s(e,t,n){void 0===n&&(n=100);var r=e*n*-1;return"translate3d("+(t?"calc("+r+"% - "+t+"px)":r+"%")+", 0, 0)"}function l(e,t){return e<0?t-1:e>=t?0:e}function c(e,t,n){return Math.min(Math.max(e,t),n)}function u(e){return e.targetTouches?e.targetTouches[0]:e.touches[0]}},8514:(e,t,n)=>{"use strict";t.__esModule=!0,t.default=void 0,function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}t.default=e}(n(5556));var r=s(n(2963)),o=s(n(788)),a=s(n(1609)),i=s(n(495));function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=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},l.apply(this,arguments)}n(554);var c=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,r.default)(e,t)}))},u=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,o.default)(e,t)}))},d=function(e){var t,n;function r(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).onEnter=function(e,n){var r=t.getClassNames(n?"appear":"enter").className;t.removeClasses(e,"exit"),c(e,r),t.props.onEnter&&t.props.onEnter(e,n)},t.onEntering=function(e,n){var r=t.getClassNames(n?"appear":"enter").activeClassName;t.reflowAndAddClass(e,r),t.props.onEntering&&t.props.onEntering(e,n)},t.onEntered=function(e,n){var r=t.getClassNames("appear").doneClassName,o=t.getClassNames("enter").doneClassName,a=n?r+" "+o:o;t.removeClasses(e,n?"appear":"enter"),c(e,a),t.props.onEntered&&t.props.onEntered(e,n)},t.onExit=function(e){var n=t.getClassNames("exit").className;t.removeClasses(e,"appear"),t.removeClasses(e,"enter"),c(e,n),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var n=t.getClassNames("exit").activeClassName;t.reflowAndAddClass(e,n),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var n=t.getClassNames("exit").doneClassName;t.removeClasses(e,"exit"),c(e,n),t.props.onExited&&t.props.onExited(e)},t.getClassNames=function(e){var n=t.props.classNames,r="string"==typeof n,o=r?(r&&n?n+"-":"")+e:n[e];return{className:o,activeClassName:r?o+"-active":n[e+"Active"],doneClassName:r?o+"-done":n[e+"Done"]}},t}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.removeClasses=function(e,t){var n=this.getClassNames(t),r=n.className,o=n.activeClassName,a=n.doneClassName;r&&u(e,r),o&&u(e,o),a&&u(e,a)},o.reflowAndAddClass=function(e,t){t&&(e&&e.scrollTop,c(e,t))},o.render=function(){var e=l({},this.props);return delete e.classNames,a.default.createElement(i.default,l({},e,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},r}(a.default.Component);d.defaultProps={classNames:""},d.propTypes={};var p=d;t.default=p,e.exports=t.default},1369:(e,t,n)=>{"use strict";t.__esModule=!0,t.default=void 0,i(n(5556));var r=i(n(1609)),o=n(5795),a=i(n(2312));function i(e){return e&&e.__esModule?e:{default:e}}var s=function(e){var t,n;function i(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).handleEnter=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEnter",0,n)},t.handleEntering=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEntering",0,n)},t.handleEntered=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEntered",0,n)},t.handleExit=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExit",1,n)},t.handleExiting=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExiting",1,n)},t.handleExited=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExited",1,n)},t}n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var s=i.prototype;return s.handleLifecycle=function(e,t,n){var a,i=this.props.children,s=r.default.Children.toArray(i)[t];s.props[e]&&(a=s.props)[e].apply(a,n),this.props[e]&&this.props[e]((0,o.findDOMNode)(this))},s.render=function(){var e=this.props,t=e.children,n=e.in,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,["children","in"]),i=r.default.Children.toArray(t),s=i[0],l=i[1];return delete o.onEnter,delete o.onEntering,delete o.onEntered,delete o.onExit,delete o.onExiting,delete o.onExited,r.default.createElement(a.default,o,n?r.default.cloneElement(s,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):r.default.cloneElement(l,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},i}(r.default.Component);s.propTypes={};var l=s;t.default=l,e.exports=t.default},495:(e,t,n)=>{"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(5556)),o=s(n(1609)),a=s(n(5795)),i=n(1345);function s(e){return e&&e.__esModule?e:{default:e}}n(554);var l="unmounted";t.UNMOUNTED=l;var c="exited";t.EXITED=c;var u="entering";t.ENTERING=u;var d="entered";t.ENTERED=d;var p="exiting";t.EXITING=p;var m=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var o,a=n.transitionGroup,i=a&&!a.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(o=c,r.appearStatus=u):o=d:o=t.unmountOnExit||t.mountOnEnter?l:c,r.state={status:o},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&t.status===l?{status:c}:null},i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==u&&n!==d&&(t=u):n!==u&&n!==d||(t=p)}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},i.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=a.default.findDOMNode(this);t===u?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&this.state.status===c&&this.setState({status:l})},i.performEnter=function(e,t){var n=this,r=this.props.enter,o=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,a=this.getTimeouts(),i=o?a.appear:a.enter;t||r?(this.props.onEnter(e,o),this.safeSetState({status:u},(function(){n.props.onEntering(e,o),n.onTransitionEnd(e,i,(function(){n.safeSetState({status:d},(function(){n.props.onEntered(e,o)}))}))}))):this.safeSetState({status:d},(function(){n.props.onEntered(e)}))},i.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:p},(function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,(function(){t.safeSetState({status:c},(function(){t.props.onExited(e)}))}))}))):this.safeSetState({status:c},(function(){t.props.onExited(e)}))},i.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},i.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},i.onTransitionEnd=function(e,t,n){this.setNextCallback(n);var r=null==t&&!this.props.addEndListener;e&&!r?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},i.render=function(){var e=this.state.status;if(e===l)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var a=o.default.Children.only(n);return o.default.cloneElement(a,r)},r}(o.default.Component);function f(){}m.contextTypes={transitionGroup:r.object},m.childContextTypes={transitionGroup:function(){}},m.propTypes={},m.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:f,onEntering:f,onEntered:f,onExit:f,onExiting:f,onExited:f},m.UNMOUNTED=0,m.EXITED=1,m.ENTERING=2,m.ENTERED=3,m.EXITING=4;var h=(0,i.polyfill)(m);t.default=h},2312:(e,t,n)=>{"use strict";t.__esModule=!0,t.default=void 0;var r=s(n(5556)),o=s(n(1609)),a=n(1345),i=n(2958);function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=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},l.apply(this,arguments)}function c(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var u=Object.values||function(e){return Object.keys(e).map((function(t){return e[t]}))},d=function(e){var t,n;function r(t,n){var r,o=(r=e.call(this,t,n)||this).handleExited.bind(c(c(r)));return r.state={handleExited:o,firstRender:!0},r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var a=r.prototype;return a.getChildContext=function(){return{transitionGroup:{isMounting:!this.appeared}}},a.componentDidMount=function(){this.appeared=!0,this.mounted=!0},a.componentWillUnmount=function(){this.mounted=!1},r.getDerivedStateFromProps=function(e,t){var n=t.children,r=t.handleExited;return{children:t.firstRender?(0,i.getInitialChildMapping)(e,r):(0,i.getNextChildMapping)(e,n,r),firstRender:!1}},a.handleExited=function(e,t){var n=(0,i.getChildMapping)(this.props.children);e.key in n||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState((function(t){var n=l({},t.children);return delete n[e.key],{children:n}})))},a.render=function(){var e=this.props,t=e.component,n=e.childFactory,r=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,["component","childFactory"]),a=u(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?a:o.default.createElement(t,r,a)},r}(o.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var p=(0,a.polyfill)(d);t.default=p,e.exports=t.default},9790:(e,t,n)=>{"use strict";var r=s(n(8514)),o=s(n(1369)),a=s(n(2312)),i=s(n(495));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:i.default,TransitionGroup:a.default,ReplaceTransition:o.default,CSSTransition:r.default}},2958:(e,t,n)=>{"use strict";t.__esModule=!0,t.getChildMapping=o,t.mergeChildMappings=a,t.getInitialChildMapping=function(e,t){return o(e.children,(function(n){return(0,r.cloneElement)(n,{onExited:t.bind(null,n),in:!0,appear:i(n,"appear",e),enter:i(n,"enter",e),exit:i(n,"exit",e)})}))},t.getNextChildMapping=function(e,t,n){var s=o(e.children),l=a(t,s);return Object.keys(l).forEach((function(o){var a=l[o];if((0,r.isValidElement)(a)){var c=o in t,u=o in s,d=t[o],p=(0,r.isValidElement)(d)&&!d.props.in;!u||c&&!p?u||!c||p?u&&c&&(0,r.isValidElement)(d)&&(l[o]=(0,r.cloneElement)(a,{onExited:n.bind(null,a),in:d.props.in,exit:i(a,"exit",e),enter:i(a,"enter",e)})):l[o]=(0,r.cloneElement)(a,{in:!1}):l[o]=(0,r.cloneElement)(a,{onExited:n.bind(null,a),in:!0,exit:i(a,"exit",e),enter:i(a,"enter",e)})}})),l};var r=n(1609);function o(e,t){var n=Object.create(null);return e&&r.Children.map(e,(function(e){return e})).forEach((function(e){n[e.key]=function(e){return t&&(0,r.isValidElement)(e)?t(e):e}(e)})),n}function a(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,o=Object.create(null),a=[];for(var i in e)i in t?a.length&&(o[i]=a,a=[]):a.push(i);var s={};for(var l in t){if(o[l])for(r=0;r<o[l].length;r++){var c=o[l][r];s[o[l][r]]=n(c)}s[l]=n(l)}for(r=0;r<a.length;r++)s[a[r]]=n(a[r]);return s}function i(e,t,n){return null!=n[t]?n[t]:e.props[t]}},554:(e,t,n)=>{"use strict";var r;t.__esModule=!0,t.classNamesShape=t.timeoutsShape=void 0,(r=n(5556))&&r.__esModule,t.timeoutsShape=null,t.classNamesShape=null},1020:(e,t,n)=>{"use strict";var r=n(1609),o=Symbol.for("react.element"),a=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,a={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)i.call(t,r)&&!l.hasOwnProperty(r)&&(a[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===a[r]&&(a[r]=t[r]);return{$$typeof:o,type:e,key:c,ref:u,props:a,_owner:s.current}}t.Fragment=a,t.jsx=c,t.jsxs=c},4848:(e,t,n)=>{"use strict";e.exports=n(1020)},8226:e=>{e.exports=function(){"use strict";return function(e){var t="/*|*/",n=t+"}";function r(t){if(t)try{e(t+"}")}catch(e){}}return function(o,a,i,s,l,c,u,d,p,m){switch(o){case 1:if(0===p&&64===a.charCodeAt(0))return e(a+";"),"";break;case 2:if(0===d)return a+t;break;case 3:switch(d){case 102:case 112:return e(i[0]+a),"";default:return a+(0===m?t:"")}case-2:a.split(n).forEach(r)}}}}()},1609:e=>{"use strict";e.exports=window.React},5795:e=>{"use strict";e.exports=window.ReactDOM},4634:e=>{function t(){return e.exports=t=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},e.exports.__esModule=!0,e.exports.default=e.exports,t.apply(this,arguments)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},4994:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},6305:(e,t,n)=>{var r=n(3738).default;function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(o=function(e){return e?n:t})(e)}e.exports=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=o(t);if(n&&n.has(e))return n.get(e);var a={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var l=i?Object.getOwnPropertyDescriptor(e,s):null;l&&(l.get||l.set)?Object.defineProperty(a,s,l):a[s]=e[s]}return a.default=e,n&&n.set(e,a),a},e.exports.__esModule=!0,e.exports.default=e.exports},3738:e=>{function t(n){return e.exports=t="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.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var a=t[r]={exports:{}};return e[r].call(a.exports,a,a.exports,n),a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var o=r.length-1;o>-1&&(!e||!/^http(s?):/.test(e));)e=r[o--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e})(),(()=>{"use strict";var e=n(1609),t=n.n(e);const r=window.wp.element,o=window.wp.i18n,a=window.kadence.helpers,i=window.wp.primitives,s=(0,r.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{fillRule:"evenodd",d:"M19.75 11H21V8.667L19.875 4H4.125L3 8.667V11h1.25v8.75h15.5V11zm-1.5 0H5.75v7.25H10V13h4v5.25h4.25V11zm-5.5-5.5h2.067l.486 3.24.028.76H12.75v-4zm-3.567 0h2.067v4H8.669l.028-.76.486-3.24zm7.615 3.1l-.464-3.1h2.36l.806 3.345V9.5h-2.668l-.034-.9zM7.666 5.5h-2.36L4.5 8.845V9.5h2.668l.034-.9.464-3.1z",clipRule:"evenodd"})),l=(0,r.createElement)(i.SVG,{xmlns:"https://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{d:"M12 9c-.8 0-1.5.7-1.5 1.5S11.2 12 12 12s1.5-.7 1.5-1.5S12.8 9 12 9zm0-5c-3.6 0-6.5 2.8-6.5 6.2 0 .8.3 1.8.9 3.1.5 1.1 1.2 2.3 2 3.6.7 1 3 3.8 3.2 3.9l.4.5.4-.5c.2-.2 2.6-2.9 3.2-3.9.8-1.2 1.5-2.5 2-3.6.6-1.3.9-2.3.9-3.1C18.5 6.8 15.6 4 12 4zm4.3 8.7c-.5 1-1.1 2.2-1.9 3.4-.5.7-1.7 2.2-2.4 3-.7-.8-1.9-2.3-2.4-3-.8-1.2-1.4-2.3-1.9-3.3-.6-1.4-.7-2.2-.7-2.5 0-2.6 2.2-4.7 5-4.7s5 2.1 5 4.7c0 .2-.1 1-.7 2.4z"})),c=(0,r.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{d:"M20.5 16h-.7V8c0-1.1-.9-2-2-2H6.2c-1.1 0-2 .9-2 2v8h-.7c-.8 0-1.5.7-1.5 1.5h20c0-.8-.7-1.5-1.5-1.5zM5.7 8c0-.3.2-.5.5-.5h11.6c.3 0 .5.2.5.5v7.6H5.7V8z"})),u=n.p+"images/business-bg.9ea001c0.jpg",d=n.p+"images/education-bg.0ddd9432.jpg",p=n.p+"images/spa-bg.daf6c29b.jpg",m=n.p+"images/taxes-bg.fe6cba5c.jpg",f=[{value:"NEUTRAL",label:(0,o.__)("Neutral","kadence-blocks")},{value:"PROFESSIONAL",label:(0,o.__)("Professional","kadence-blocks")},{value:"FRIENDLY",label:(0,o.__)("Friendly","kadence-blocks")},{value:"INFORMATIVE",label:(0,o.__)("Informative","kadence-blocks")},{value:"ENGAGING",label:(0,o.__)("Engaging","kadence-blocks")},{value:"TRUSTWORTHY",label:(0,o.__)("Trustworthy","kadence-blocks")},{value:"CONVERSATIONAL",label:(0,o.__)("Conversational","kadence-blocks")},{value:"PERSUASIVE",label:(0,o.__)("Persuasive","kadence-blocks")},{value:"UPBEAT",label:(0,o.__)("Upbeat","kadence-blocks")},{value:"FUNNY",label:(0,o.__)("Funny","kadence-blocks")},{value:"INSPIRATIONAL",label:(0,o.__)("Inspirational","kadence-blocks")}],h="INDIVIDUAL",g=[{value:"COMPANY",label:(0,o.__)("A Company","kadence-blocks")},{value:h,label:(0,o.__)("An Individual","kadence-blocks")},{value:"ORGANIZATION",label:(0,o.__)("An Organization","kadence-blocks")}],b=[{value:"cs-CZ",label:(0,o.__)("Czech","kadence-blocks")},{value:"da-DK",label:(0,o.__)("Danish (Denmark)","kadence-blocks")},{value:"nl-BE",label:(0,o.__)("Dutch (Belgium)","kadence-blocks")},{value:"nl-N",label:(0,o.__)("Dutch (Netherlands)","kadence-blocks")},{value:"en-AU",label:(0,o.__)("English (Australia)","kadence-blocks")},{value:"en-CA",label:(0,o.__)("English (Canada)","kadence-blocks")},{value:"en-IN",label:(0,o.__)("English (India)","kadence-blocks")},{value:"en-NZ",label:(0,o.__)("English (New Zealand)","kadence-blocks")},{value:"en-GB",label:(0,o.__)("English (UK)","kadence-blocks")},{value:"en-US",label:(0,o.__)("English (US)","kadence-blocks")},{value:"fi-FI",label:(0,o.__)("Finnish","kadence-blocks")},{value:"fr-BE",label:(0,o.__)("French (Belgium)","kadence-blocks")},{value:"fr-CA",label:(0,o.__)("French (Canada)","kadence-blocks")},{value:"fr-FR",label:(0,o.__)("French (France)","kadence-blocks")},{value:"de-AT",label:(0,o.__)("German (Austria)","kadence-blocks")},{value:"de-BE",label:(0,o.__)("German (Belgium)","kadence-blocks")},{value:"de-DE",label:(0,o.__)("German (Germany)","kadence-blocks")},{value:"de-CH",label:(0,o.__)("German (Switzerland)","kadence-blocks")},{value:"hu-HU",label:(0,o.__)("Hungarian","kadence-blocks")},{value:"it-IT",label:(0,o.__)("Italian (Italy)","kadence-blocks")},{value:"pt-BR",label:(0,o.__)("Portuguese (Brazil)","kadence-blocks")},{value:"pt-PT",label:(0,o.__)("Portuguese (Portugal)","kadence-blocks")},{value:"es-AR",label:(0,o.__)("Spanish (Argentina)","kadence-blocks")},{value:"es-CO",label:(0,o.__)("Spanish (Colombia)","kadence-blocks")},{value:"es-419",label:(0,o.__)("Spanish (Latin America)","kadence-blocks")},{value:"es-MX",label:(0,o.__)("Spanish (Mexico)","kadence-blocks")},{value:"es-ES",label:(0,o.__)("Spanish (Spain)","kadence-blocks")},{value:"sv-SE",label:(0,o.__)("Swedish (Sweden)","kadence-blocks")},{value:"tr-TR",label:(0,o.__)("Turkish","kadence-blocks")}],v={COMPANY:{label:(0,o.__)("Company Name","kadence-blocks"),placeholder:(0,o.__)("Your Company","kadence-blocks")},INDIVIDUAL:{label:(0,o.__)("Name","kadence-blocks"),placeholder:(0,o.__)("Your Name","kadence-blocks")},ORGANIZATION:{label:(0,o.__)("Organization Name","kadence-blocks"),placeholder:(0,o.__)("Your Organization","kadence-blocks")}},y=[{label:(0,o.__)("I want to sell products","kadence-starter-templates"),description:(0,o.__)("Get example woocommerce content and see layouts that work better for online stores.","kadence-starter-templates"),icon:"cart",value:"ecommerce"},{label:(0,o.__)("I want to receive donations","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for non-profits.","kadence-starter-templates"),icon:"share-alt",value:"donations"},{label:(0,o.__)("I want to display events","kadence-starter-templates"),description:(0,o.__)("Get example events content and see layouts that work better for showcasing events.","kadence-starter-templates"),icon:"calendar-alt",value:"events"},{label:(0,o.__)("I want to offer courses","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for learning management.","kadence-starter-templates"),icon:"welcome-learn-more",value:"courses"},{label:(0,o.__)("I want to sell tickets to events","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for ticket sales.","kadence-starter-templates"),icon:"tickets-alt",value:"tickets"},{label:(0,o.__)("I want to generate leads","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for getting new leads.","kadence-starter-templates"),icon:"chart-bar",value:"landing"},{label:(0,o.__)("I want to display my services","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for service sites.","kadence-starter-templates"),icon:"businessperson",value:"services"},{label:(0,o.__)("I want to offer a membership","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for membership sites.","kadence-starter-templates"),icon:"money",value:"membership"},{label:(0,o.__)("I want to write blog posts","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for bloggers.","kadence-starter-templates"),icon:"welcome-write-blog",value:"blogging"},{label:(0,o.__)("I want to book appointments","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for bookings.","kadence-starter-templates"),icon:"edit-page",value:"booking"},{label:(0,o.__)("I want to display my photography","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for photographers.","kadence-starter-templates"),icon:"camera",value:"photography"},{label:(0,o.__)("I want to promote my podcast","kadence-starter-templates"),description:(0,o.__)("See layouts that work better for podcasters.","kadence-starter-templates"),icon:"microphone",value:"podcasting"}],E="Business Address",k="Service Area",_="Online Only",w=[{icon:s,text:(0,o.__)("Business Address","kadence-blocks"),value:E,help:(0,o.__)("E.g.: 1234 Street #1, Chicago, IL 60076, USA","kadence-blocks"),placeholder:(0,o.__)("Street Adress, City, State, Zipcode, Country","kadence-blocks")},{icon:l,text:(0,o.__)("Service Area","kadence-blocks"),value:k,help:(0,o.__)("E.g.: Chicago, USA","kadence-blocks"),placeholder:(0,o.__)("District, City, State, Zipcode, Country","kadence-blocks")},{icon:c,text:(0,o.__)("Online Only","kadence-blocks"),value:_,help:"",placeholder:""}],S={initial:{color:"#757575",message:(0,o.__)("The more detail you add, the better.","kadence-blocks")},weak:{color:"#DF3416",message:(0,o.__)("For better, more accurate copy enter a bit more content.","kadence-blocks")},medium:{color:"#B35F00",message:(0,o.__)("This is a great start. Try adding a bit more information to your description.","kadence-blocks")},strong:{color:"#1B8F6D",message:(0,o.__)("Excellent work! Want to add more? Keep going! More info means better content.","kadence-blocks")},enough:{color:"#1B8F6D",message:(0,o.__)("Excellent work! You have added enough information.","kadence-blocks")},less:{color:"#B35F00",message:(0,o.__)("ok, you've added a lot of information. Try removing some to get better results.","kadence-blocks")},muchLess:{color:"#DF3416",message:(0,o.__)("You've added too much information. Remove some to move forward.","kadence-blocks")}},O=[p,u,m,d],C={INDIVIDUAL:["What is your core offering or skill?","Tell your story. Be sure to feature your expertise and standout skills.","Describe your process, services, or products you offer.","What makes you stand out? Highlight your competitive edge and the value you bring?","Do you have work and recognitions to highlight?","What is the action you want visitors to take?"],COMPANY:["What is your core offering or business purpose?","What products and services do your offer?","Describe your team and/or brand story.","Highlight relevant numbers or statistics that support your value or impact.","What makes you stand out in your industry? Highlight your competitive edge and the value you bring.","List any notable partnerships.","What is the action you want visitors to take?"],ORGANIZATION:["What is your organization's purpose? How does your history and mission support that?","Describe your team and/or brand story.","Highlight relevant numbers or statistics that support your value or impact.","Do you offer any services or products?","List any notable partnerships.","What is the action you want visitors to take?"]},x="loading",A="notFound",I="error",P="success",T="allAdded",N={isComplete:!1,firstTime:!0,isSubmitted:!1,context:"kadence",currentPageIndex:0,companyName:"",entityType:h,locationType:"",locationInput:"",location:"",industry:"",missionStatement:"",keywords:[],tone:"NEUTRAL",privacyAgreement:!1,photoLibrary:"aiGenerated",photoCollectionChanged:!1,featuredImages:[],backgroundImages:[],customCollections:[{label:(0,o.__)("My Images","kadence-blocks"),value:"my-images",galleries:[{name:"featured",isLocal:!0,images:[]},{name:"background",isLocal:!0,images:[]}]}],saving:!1,saveError:!1,verticals:[],suggestedKeywords:[],suggestedKeywordsState:"",imageSearchQuery:"",lang:"",goals:[]},D=(0,r.createContext)();function L(e,t){switch(t.type){case"SET_CURRENT_PAGE_INDEX":return{...e,currentPageIndex:t.payload};case"SET_COMPANY_NAME":return{...e,companyName:t.payload};case"SET_LANG":return{...e,lang:t.payload};case"SET_SITE_GOALS":return{...e,goals:t.payload};case"SET_ENTITY_TYPE":return{...e,entityType:t.payload};case"SET_LOCATION":return{...e,location:t.payload};case"SET_LOCATION_INPUT":return{...e,locationInput:t.payload};case"SET_LOCATION_TYPE":return{...e,locationType:t.payload};case"SET_INDUSTRY":return{...e,industry:t.payload};case"SET_MISSION_STATEMENT":return{...e,missionStatement:t.payload};case"SET_KEYWORDS":return{...e,keywords:t.payload};case"SET_TONE":return{...e,tone:t.payload};case"SET_PRIVACY_AGREEMENT":return{...e,privacyAgreement:!e.privacyAgreement};case"SET_PHOTO_LIBRARY":return{...e,photoLibrary:t.payload};case"SET_PHOTO_LIBRARY_CHANGED":return{...e,photoCollectionChanged:t.payload};case"SET_FEATURED_IMAGES":return{...e,featuredImages:t.payload};case"SET_BACKGROUND_IMAGES":return{...e,backgroundImages:t.payload};case"SET_CUSTOM_COLLECTIONS":return{...e,customCollections:t.payload};case"SET_FEATURED_PREVIEW":return{...e,featuredImage:t.payload};case"SET_BACKGROUND_PREVIEW":return{...e,backgroundImage:t.payload};case"SET_SAVING":return{...e,saving:t.payload};case"SET_IMAGE_SEARCH_QUERY":return{...e,imageSearchQuery:t.payload};case"SET_SUGGESTED_KEYWORDS":return{...e,suggestedKeywords:t.payload};case"SET_SUGGESTED_KEYWORDS_STATE":return{...e,suggestedKeywordsState:t.payload};default:return e}}function F(e){return{...N,...e}}function j(t){const[n,o]=(0,r.useReducer)(L,t.value,F),a={state:n,dispatch:o};return(0,e.createElement)(D.Provider,{value:a},t.children)}function R(){const e=(0,r.useContext)(D);if(void 0===e)throw new Error("useKadenceAi must be used with KadenceAiProvider");return e}var M=n(3643),B=n.n(M);function V(e,t){var n=void 0;return function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];n&&clearTimeout(n),n=setTimeout((function(){return e.apply(void 0,o)}),t)}}function H(e){return e!==Object(e)}function z(e,t){if(e===t)return!0;if(H(e)||H(t)||"function"==typeof e||"function"==typeof t)return e===t;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n=0,r=Object.keys(e);n<r.length;n++){var o=r[n];if(!(o in t))return!1;if(!z(e[o],t[o]))return!1}return!0}var U=function(){};function W(e){var t=e.item,n=e.items,r=void 0===n?[]:n;return{index:t.__autocomplete_indexName,items:[t],positions:[1+r.findIndex((function(e){return e.objectID===t.objectID}))],queryID:t.__autocomplete_queryID,algoliaSource:["autocomplete"]}}function q(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var G=["items"],K=["items"];function $(e){return $="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 Y(e){return function(e){if(Array.isArray(e))return Z(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Z(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function J(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function Q(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function X(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Q(Object(n),!0).forEach((function(t){ee(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Q(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ee(e,t,n){return(t=function(e){var t=function(e){if("object"!==$(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==$(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===$(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function te(e){return e.map((function(e){var t=e.items,n=J(e,G);return X(X({},n),{},{objectIDs:(null==t?void 0:t.map((function(e){return e.objectID})))||n.objectIDs})}))}function ne(e){var t,n,r,o,a,i=(o=(e.version||"").split(".").map(Number),a=2,n=(t=function(e){if(Array.isArray(e))return e}(o)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,_x,a,i=[],_n=!0,s=!1;try{if(_x=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;_n=!1}else for(;!(_n=(r=_x.call(n)).done)&&(i.push(r.value),i.length!==t);_n=!0);}catch(e){s=!0,o=e}finally{try{if(!_n&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return i}}(o,a)||function(e,t){if(e){if("string"==typeof e)return q(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?q(e,t):void 0}}(o,a)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],r=t[1],n>=3||2===n&&r>=4||1===n&&r>=10);function s(t,n,r){if(i&&void 0!==r){var o=r[0].__autocomplete_algoliaCredentials,a={"X-Algolia-Application-Id":o.appId,"X-Algolia-API-Key":o.apiKey};e.apply(void 0,[t].concat(Y(n),[{headers:a}]))}else e.apply(void 0,[t].concat(Y(n)))}return{init:function(t,n){e("init",{appId:t,apiKey:n})},setUserToken:function(t){e("setUserToken",t)},clickedObjectIDsAfterSearch:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.length>0&&s("clickedObjectIDsAfterSearch",te(t),t[0].items)},clickedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.length>0&&s("clickedObjectIDs",te(t),t[0].items)},clickedFilters:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];n.length>0&&e.apply(void 0,["clickedFilters"].concat(n))},convertedObjectIDsAfterSearch:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.length>0&&s("convertedObjectIDsAfterSearch",te(t),t[0].items)},convertedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.length>0&&s("convertedObjectIDs",te(t),t[0].items)},convertedFilters:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];n.length>0&&e.apply(void 0,["convertedFilters"].concat(n))},viewedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.length>0&&t.reduce((function(e,t){var n=t.items,r=J(t,K);return[].concat(Y(e),Y(function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:20,n=[],r=0;r<e.objectIDs.length;r+=t)n.push(X(X({},e),{},{objectIDs:e.objectIDs.slice(r,r+t)}));return n}(X(X({},r),{},{objectIDs:(null==n?void 0:n.map((function(e){return e.objectID})))||r.objectIDs})).map((function(e){return{items:n,payload:e}}))))}),[]).forEach((function(e){var t=e.items;return s("viewedObjectIDs",[e.payload],t)}))},viewedFilters:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];n.length>0&&e.apply(void 0,["viewedFilters"].concat(n))}}}function re(e){var t=e.items.reduce((function(e,t){var n;return e[t.__autocomplete_indexName]=(null!==(n=e[t.__autocomplete_indexName])&&void 0!==n?n:[]).concat(t),e}),{});return Object.keys(t).map((function(e){return{index:e,items:t[e],algoliaSource:["autocomplete"]}}))}function oe(e){return e.objectID&&e.__autocomplete_indexName&&e.__autocomplete_queryID}function ae(e){return ae="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},ae(e)}function ie(e){return function(e){if(Array.isArray(e))return se(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return se(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?se(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function se(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function le(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?le(Object(n),!0).forEach((function(t){ue(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):le(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ue(e,t,n){return(t=function(e){var t=function(e){if("object"!==ae(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==ae(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ae(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var de="2.6.0",pe="https://cdn.jsdelivr.net/npm/search-insights@".concat(de,"/dist/search-insights.min.js"),me=V((function(e){var t=e.onItemsChange,n=e.items,r=e.insights,o=e.state;t({insights:r,insightsEvents:re({items:n}).map((function(e){return ce({eventName:"Items Viewed"},e)})),state:o})}),400);function fe(e){var t=function(e){return ce({onItemsChange:function(e){var t=e.insights,n=e.insightsEvents;t.viewedObjectIDs.apply(t,ie(n.map((function(e){return ce(ce({},e),{},{algoliaSource:[].concat(ie(e.algoliaSource||[]),["autocomplete-internal"])})}))))},onSelect:function(e){var t=e.insights,n=e.insightsEvents;t.clickedObjectIDsAfterSearch.apply(t,ie(n.map((function(e){return ce(ce({},e),{},{algoliaSource:[].concat(ie(e.algoliaSource||[]),["autocomplete-internal"])})}))))},onActive:U},e)}(e),n=t.insightsClient,r=t.onItemsChange,o=t.onSelect,a=t.onActive,i=n;n||"undefined"!=typeof window&&function(e){var t=e.window,n=t.AlgoliaAnalyticsObject||"aa";"string"==typeof n&&(i=t[n]),i||(t.AlgoliaAnalyticsObject=n,t[n]||(t[n]=function(){t[n].queue||(t[n].queue=[]);for(var e=arguments.length,r=new Array(e),o=0;o<e;o++)r[o]=arguments[o];t[n].queue.push(r)}),t[n].version=de,i=t[n],function(e){var t="[Autocomplete]: Could not load search-insights.js. Please load it manually following https://alg.li/insights-autocomplete";try{var n=e.document.createElement("script");n.async=!0,n.src=pe,n.onerror=function(){console.error(t)},document.body.appendChild(n)}catch(e){console.error(t)}}(t))}({window});var s=ne(i),l={current:[]},c=V((function(e){var t=e.state;if(t.isOpen){var n=t.collections.reduce((function(e,t){return[].concat(ie(e),ie(t.items))}),[]).filter(oe);z(l.current.map((function(e){return e.objectID})),n.map((function(e){return e.objectID})))||(l.current=n,n.length>0&&me({onItemsChange:r,items:n,insights:s,state:t}))}}),0);return{name:"aa.algoliaInsightsPlugin",subscribe:function(e){var t=e.setContext,n=e.onSelect,r=e.onActive;i("addAlgoliaAgent","insights-plugin"),t({algoliaInsightsPlugin:{__algoliaSearchParameters:{clickAnalytics:!0},insights:s}}),n((function(e){var t=e.item,n=e.state,r=e.event,a=e.source;oe(t)&&o({state:n,event:r,insights:s,item:t,insightsEvents:[ce({eventName:"Item Selected"},W({item:t,items:a.getItems().filter(oe)}))]})})),r((function(e){var t=e.item,n=e.source,r=e.state,o=e.event;oe(t)&&a({state:r,event:o,insights:s,item:t,insightsEvents:[ce({eventName:"Item Active"},W({item:t,items:n.getItems().filter(oe)}))]})}))},onStateChange:function(e){var t=e.state;c({state:t})},__autocomplete_pluginOptions:e}}function he(e){return he="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},he(e)}function ge(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function be(e,t,n){return(t=function(e){var t=function(e){if("object"!==he(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==he(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===he(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ve(e){return e.reduce((function(e,t){return e.concat(t)}),[])}function ye(e){return ye="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},ye(e)}function Ee(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ke(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ee(Object(n),!0).forEach((function(t){_e(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ee(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _e(e,t,n){return(t=function(e){var t=function(e){if("object"!==ye(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==ye(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ye(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function we(e){return 0===e.collections.length?0:e.collections.reduce((function(e,t){return e+t.items.length}),0)}var Se=0;function Oe(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Oe(Object(n),!0).forEach((function(t){xe(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Oe(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function xe(e,t,n){return(t=function(e){var t=function(e){if("object"!==Ae(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Ae(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ae(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ae(e){return Ae="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},Ae(e)}function Ie(e){return Ie="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},Ie(e)}function Pe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Te(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ne(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Te(Object(n),!0).forEach((function(t){De(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Te(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function De(e,t,n){return(t=function(e){var t=function(e){if("object"!==Ie(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Ie(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ie(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Le(e,t){var n,r="undefined"!=typeof window?window:{},o=e.plugins||[];return Ne(Ne({debug:!1,openOnFocus:!1,enterKeyHint:void 0,placeholder:"",autoFocus:!1,defaultActiveItemId:null,stallThreshold:300,insights:!1,environment:r,shouldPanelOpen:function(e){return we(e.state)>0},reshape:function(e){return e.sources}},e),{},{id:null!==(n=e.id)&&void 0!==n?n:"autocomplete-".concat(Se++),plugins:o,initialState:Ne({activeItemId:null,query:"",completion:null,collections:[],isOpen:!1,status:"idle",context:{}},e.initialState),onStateChange:function(t){var n;null===(n=e.onStateChange)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onStateChange)||void 0===n?void 0:n.call(e,t)}))},onSubmit:function(t){var n;null===(n=e.onSubmit)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onSubmit)||void 0===n?void 0:n.call(e,t)}))},onReset:function(t){var n;null===(n=e.onReset)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onReset)||void 0===n?void 0:n.call(e,t)}))},getSources:function(n){return Promise.all([].concat((r=o.map((function(e){return e.getSources})),function(e){if(Array.isArray(e))return Pe(e)}(r)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e,t){if(e){if("string"==typeof e)return Pe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Pe(e,t):void 0}}(r)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),[e.getSources]).filter(Boolean).map((function(e){return function(e,t){var n=[];return Promise.resolve(e(t)).then((function(e){return Array.isArray(e),Promise.all(e.filter((function(e){return Boolean(e)})).map((function(e){if(e.sourceId,n.includes(e.sourceId))throw new Error("[Autocomplete] The `sourceId` ".concat(JSON.stringify(e.sourceId)," is not unique."));n.push(e.sourceId);var t={getItemInputValue:function(e){return e.state.query},getItemUrl:function(){},onSelect:function(e){(0,e.setIsOpen)(!1)},onActive:U,onResolve:U};Object.keys(t).forEach((function(e){t[e].__default=!0}));var r=Ce(Ce({},t),e);return Promise.resolve(r)})))}))}(e,n)}))).then((function(e){return ve(e)})).then((function(e){return e.map((function(e){return Ne(Ne({},e),{},{onSelect:function(n){e.onSelect(n),t.forEach((function(e){var t;return null===(t=e.onSelect)||void 0===t?void 0:t.call(e,n)}))},onActive:function(n){e.onActive(n),t.forEach((function(e){var t;return null===(t=e.onActive)||void 0===t?void 0:t.call(e,n)}))},onResolve:function(n){e.onResolve(n),t.forEach((function(e){var t;return null===(t=e.onResolve)||void 0===t?void 0:t.call(e,n)}))}})}))}));var r},navigator:Ne({navigate:function(e){var t=e.itemUrl;r.location.assign(t)},navigateNewTab:function(e){var t=e.itemUrl,n=r.open(t,"_blank","noopener");null==n||n.focus()},navigateNewWindow:function(e){var t=e.itemUrl;r.open(t,"_blank","noopener")}},e.navigator)})}function Fe(e){return Fe="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},Fe(e)}function je(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Re(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?je(Object(n),!0).forEach((function(t){Me(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):je(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Me(e,t,n){return(t=function(e){var t=function(e){if("object"!==Fe(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Fe(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Fe(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Be(e){return Be="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},Be(e)}function Ve(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function He(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ve(Object(n),!0).forEach((function(t){ze(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ve(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ze(e,t,n){return(t=function(e){var t=function(e){if("object"!==Be(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Be(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Be(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ue(e){return function(e){if(Array.isArray(e))return We(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return We(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?We(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function We(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function qe(e){return Boolean(e.execute)}function Ge(e){var t=e.reduce((function(e,t){if(!qe(t))return e.push(t),e;var n=t.searchClient,r=t.execute,o=t.requesterId,a=t.requests,i=e.find((function(e){return qe(t)&&qe(e)&&e.searchClient===n&&Boolean(o)&&e.requesterId===o}));if(i){var s;(s=i.items).push.apply(s,Ue(a))}else{var l={execute:r,requesterId:o,items:a,searchClient:n};e.push(l)}return e}),[]),n=t.map((function(e){if(!qe(e))return Promise.resolve(e);var t=e,n=t.execute,r=t.items;return n({searchClient:t.searchClient,requests:r})}));return Promise.all(n).then((function(e){return ve(e)}))}function Ke(e,t){var n=t;return{then:function(t,r){return Ke(e.then(Ze(t,n,e),Ze(r,n,e)),n)},catch:function(t){return Ke(e.catch(Ze(t,n,e)),n)},finally:function(t){return t&&n.onCancelList.push(t),Ke(e.finally(Ze(t&&function(){return n.onCancelList=[],t()},n,e)),n)},cancel:function(){n.isCanceled=!0;var e=n.onCancelList;n.onCancelList=[],e.forEach((function(e){e()}))},isCanceled:function(){return!0===n.isCanceled}}}function $e(e){return Ke(new Promise((function(t,n){return e(t,n)})),{isCanceled:!1,onCancelList:[]})}function Ye(e){return Ke(e,{isCanceled:!1,onCancelList:[]})}function Ze(e,t,n){return e?function(n){return t.isCanceled?n:e(n)}:n}function Je(e){var t=function(e){var t=e.collections.map((function(e){return e.items.length})).reduce((function(e,t,n){var r=(e[n-1]||0)+t;return e.push(r),e}),[]).reduce((function(t,n){return n<=e.activeItemId?t+1:t}),0);return e.collections[t]}(e);if(!t)return null;var n=t.items[function(e){for(var t=e.state,n=e.collection,r=!1,o=0,a=0;!1===r;){var i=t.collections[o];if(i===n){r=!0;break}a+=i.items.length,o++}return t.activeItemId-a}({state:e,collection:t})],r=t.source;return{item:n,itemInputValue:r.getItemInputValue({item:n,state:e}),itemUrl:r.getItemUrl({item:n,state:e}),source:r}}function Qe(e){return Qe="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},Qe(e)}$e.resolve=function(e){return Ye(Promise.resolve(e))},$e.reject=function(e){return Ye(Promise.reject(e))};var Xe=["event","nextState","props","query","refresh","store"];function et(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?et(Object(n),!0).forEach((function(t){nt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):et(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function nt(e,t,n){return(t=function(e){var t=function(e){if("object"!==Qe(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Qe(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Qe(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rt,ot,at,it=null,st=(rt=-1,ot=-1,at=void 0,function(e){var t=++rt;return Promise.resolve(e).then((function(e){return at&&t<ot?at:(ot=t,at=e,e)}))});function lt(e){var t=e.event,n=e.nextState,r=void 0===n?{}:n,o=e.props,a=e.query,i=e.refresh,s=e.store,l=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,Xe);it&&o.environment.clearTimeout(it);var c=l.setCollections,u=l.setIsOpen,d=l.setQuery,p=l.setActiveItemId,m=l.setStatus;if(d(a),p(o.defaultActiveItemId),!a&&!1===o.openOnFocus){var f,h=s.getState().collections.map((function(e){return tt(tt({},e),{},{items:[]})}));m("idle"),c(h),u(null!==(f=r.isOpen)&&void 0!==f?f:o.shouldPanelOpen({state:s.getState()}));var g=Ye(st(h).then((function(){return Promise.resolve()})));return s.pendingRequests.add(g)}m("loading"),it=o.environment.setTimeout((function(){m("stalled")}),o.stallThreshold);var b=Ye(st(o.getSources(tt({query:a,refresh:i,state:s.getState()},l)).then((function(e){return Promise.all(e.map((function(e){return Promise.resolve(e.getItems(tt({query:a,refresh:i,state:s.getState()},l))).then((function(t){return function(e,t,n){if(o=e,Boolean(null==o?void 0:o.execute)){var r="algolia"===e.requesterId?Object.assign.apply(Object,[{}].concat(Ue(Object.keys(n.context).map((function(e){var t;return null===(t=n.context[e])||void 0===t?void 0:t.__algoliaSearchParameters}))))):{};return He(He({},e),{},{requests:e.queries.map((function(n){return{query:"algolia"===e.requesterId?He(He({},n),{},{params:He(He({},r),n.params)}):n,sourceId:t,transformResponse:e.transformResponse}}))})}var o;return{items:e,sourceId:t}}(t,e.sourceId,s.getState())}))}))).then(Ge).then((function(t){return function(e,t,n){return t.map((function(t){var r,o=e.filter((function(e){return e.sourceId===t.sourceId})),a=o.map((function(e){return e.items})),i=o[0].transformResponse,s=i?i({results:r=a,hits:r.map((function(e){return e.hits})).filter(Boolean),facetHits:r.map((function(e){var t;return null===(t=e.facetHits)||void 0===t?void 0:t.map((function(e){return{label:e.value,count:e.count,_highlightResult:{label:{value:e.highlighted}}}}))})).filter(Boolean)}):a;return t.onResolve({source:t,results:a,items:s,state:n.getState()}),Array.isArray(s),s.every(Boolean),'The `getItems` function from source "'.concat(t.sourceId,'" must return an array of items but returned ').concat(JSON.stringify(void 0),".\n\nDid you forget to return items?\n\nSee: https://www.algolia.com/doc/ui-libraries/autocomplete/core-concepts/sources/#param-getitems"),{source:t,items:s}}))}(t,e,s)})).then((function(e){return function(e){var t=e.props,n=e.state,r=e.collections.reduce((function(e,t){return Re(Re({},e),{},Me({},t.source.sourceId,Re(Re({},t.source),{},{getItems:function(){return ve(t.items)}})))}),{}),o=t.plugins.reduce((function(e,t){return t.reshape?t.reshape(e):e}),{sourcesBySourceId:r,state:n}).sourcesBySourceId;return ve(t.reshape({sourcesBySourceId:o,sources:Object.values(o),state:n})).filter(Boolean).map((function(e){return{source:e,items:e.getItems()}}))}({collections:e,props:o,state:s.getState()})}))})))).then((function(e){var n;m("idle"),c(e);var d=o.shouldPanelOpen({state:s.getState()});u(null!==(n=r.isOpen)&&void 0!==n?n:o.openOnFocus&&!a&&d||d);var p=Je(s.getState());if(null!==s.getState().activeItemId&&p){var f=p.item,h=p.itemInputValue,g=p.itemUrl,b=p.source;b.onActive(tt({event:t,item:f,itemInputValue:h,itemUrl:g,refresh:i,source:b,state:s.getState()},l))}})).finally((function(){m("idle"),it&&o.environment.clearTimeout(it)}));return s.pendingRequests.add(b)}function ct(e){return ct="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},ct(e)}var ut=["event","props","refresh","store"];function dt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function pt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?dt(Object(n),!0).forEach((function(t){mt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function mt(e,t,n){return(t=function(e){var t=function(e){if("object"!==ct(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==ct(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ct(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ft=/((gt|sm)-|galaxy nexus)|samsung[- ]|samsungbrowser/i;function ht(e){return ht="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},ht(e)}var gt=["props","refresh","store"],bt=["inputElement","formElement","panelElement"],vt=["inputElement"],yt=["inputElement","maxLength"],Et=["sourceIndex"],kt=["sourceIndex"],_t=["item","source","sourceIndex"];function wt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function St(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wt(Object(n),!0).forEach((function(t){Ot(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ot(e,t,n){return(t=function(e){var t=function(e){if("object"!==ht(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==ht(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ht(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ct(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function xt(e){var t=e.props,n=e.refresh,r=e.store,o=Ct(e,gt),a=function(e,t){return void 0!==t?"".concat(e,"-").concat(t):e};return{getEnvironmentProps:function(e){var n=e.inputElement,o=e.formElement,a=e.panelElement;function i(e){!r.getState().isOpen&&r.pendingRequests.isEmpty()||e.target===n||!1===[o,a].some((function(t){return(n=t)===(r=e.target)||n.contains(r);var n,r}))&&(r.dispatch("blur",null),t.debug||r.pendingRequests.cancelAll())}return St({onTouchStart:i,onMouseDown:i,onTouchMove:function(e){!1!==r.getState().isOpen&&n===t.environment.document.activeElement&&e.target!==n&&n.blur()}},Ct(e,bt))},getRootProps:function(e){return St({role:"combobox","aria-expanded":r.getState().isOpen,"aria-haspopup":"listbox","aria-owns":r.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label")},e)},getFormProps:function(e){return e.inputElement,St({action:"",noValidate:!0,role:"search",onSubmit:function(a){var i;a.preventDefault(),t.onSubmit(St({event:a,refresh:n,state:r.getState()},o)),r.dispatch("submit",null),null===(i=e.inputElement)||void 0===i||i.blur()},onReset:function(a){var i;a.preventDefault(),t.onReset(St({event:a,refresh:n,state:r.getState()},o)),r.dispatch("reset",null),null===(i=e.inputElement)||void 0===i||i.focus()}},Ct(e,vt))},getLabelProps:function(e){var n=e||{},r=n.sourceIndex,o=Ct(n,Et);return St({htmlFor:"".concat(a(t.id,r),"-input"),id:"".concat(a(t.id,r),"-label")},o)},getInputProps:function(e){var a;function i(e){(t.openOnFocus||Boolean(r.getState().query))&<(St({event:e,props:t,query:r.getState().completion||r.getState().query,refresh:n,store:r},o)),r.dispatch("focus",null)}var s,l=e||{},c=(l.inputElement,l.maxLength),u=void 0===c?512:c,d=Ct(l,yt),p=Je(r.getState()),m=(s=(null===(a=t.environment.navigator)||void 0===a?void 0:a.userAgent)||"",Boolean(s&&s.match(ft))),f=t.enterKeyHint||(null!=p&&p.itemUrl&&!m?"go":"search");return St({"aria-autocomplete":"both","aria-activedescendant":r.getState().isOpen&&null!==r.getState().activeItemId?"".concat(t.id,"-item-").concat(r.getState().activeItemId):void 0,"aria-controls":r.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label"),value:r.getState().completion||r.getState().query,id:"".concat(t.id,"-input"),autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",enterKeyHint:f,spellCheck:"false",autoFocus:t.autoFocus,placeholder:t.placeholder,maxLength:u,type:"search",onChange:function(e){lt(St({event:e,props:t,query:e.currentTarget.value.slice(0,u),refresh:n,store:r},o))},onKeyDown:function(e){!function(e){var t=e.event,n=e.props,r=e.refresh,o=e.store,a=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,ut);if("ArrowUp"===t.key||"ArrowDown"===t.key){var i=function(){var e=n.environment.document.getElementById("".concat(n.id,"-item-").concat(o.getState().activeItemId));e&&(e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded(!1):e.scrollIntoView(!1))},s=function(){var e=Je(o.getState());if(null!==o.getState().activeItemId&&e){var n=e.item,i=e.itemInputValue,s=e.itemUrl,l=e.source;l.onActive(pt({event:t,item:n,itemInputValue:i,itemUrl:s,refresh:r,source:l,state:o.getState()},a))}};t.preventDefault(),!1===o.getState().isOpen&&(n.openOnFocus||Boolean(o.getState().query))?lt(pt({event:t,props:n,query:o.getState().query,refresh:r,store:o},a)).then((function(){o.dispatch(t.key,{nextActiveItemId:n.defaultActiveItemId}),s(),setTimeout(i,0)})):(o.dispatch(t.key,{}),s(),i())}else if("Escape"===t.key)t.preventDefault(),o.dispatch(t.key,null),o.pendingRequests.cancelAll();else if("Tab"===t.key)o.dispatch("blur",null),o.pendingRequests.cancelAll();else if("Enter"===t.key){if(null===o.getState().activeItemId||o.getState().collections.every((function(e){return 0===e.items.length})))return void(n.debug||o.pendingRequests.cancelAll());t.preventDefault();var l=Je(o.getState()),c=l.item,u=l.itemInputValue,d=l.itemUrl,p=l.source;if(t.metaKey||t.ctrlKey)void 0!==d&&(p.onSelect(pt({event:t,item:c,itemInputValue:u,itemUrl:d,refresh:r,source:p,state:o.getState()},a)),n.navigator.navigateNewTab({itemUrl:d,item:c,state:o.getState()}));else if(t.shiftKey)void 0!==d&&(p.onSelect(pt({event:t,item:c,itemInputValue:u,itemUrl:d,refresh:r,source:p,state:o.getState()},a)),n.navigator.navigateNewWindow({itemUrl:d,item:c,state:o.getState()}));else if(t.altKey);else{if(void 0!==d)return p.onSelect(pt({event:t,item:c,itemInputValue:u,itemUrl:d,refresh:r,source:p,state:o.getState()},a)),void n.navigator.navigate({itemUrl:d,item:c,state:o.getState()});lt(pt({event:t,nextState:{isOpen:!1},props:n,query:u,refresh:r,store:o},a)).then((function(){p.onSelect(pt({event:t,item:c,itemInputValue:u,itemUrl:d,refresh:r,source:p,state:o.getState()},a))}))}}}(St({event:e,props:t,refresh:n,store:r},o))},onFocus:i,onBlur:U,onClick:function(n){e.inputElement!==t.environment.document.activeElement||r.getState().isOpen||i(n)}},d)},getPanelProps:function(e){return St({onMouseDown:function(e){e.preventDefault()},onMouseLeave:function(){r.dispatch("mouseleave",null)}},e)},getListProps:function(e){var n=e||{},r=n.sourceIndex,o=Ct(n,kt);return St({role:"listbox","aria-labelledby":"".concat(a(t.id,r),"-label"),id:"".concat(a(t.id,r),"-list")},o)},getItemProps:function(e){var i=e.item,s=e.source,l=e.sourceIndex,c=Ct(e,_t);return St({id:"".concat(a(t.id,l),"-item-").concat(i.__autocomplete_id),role:"option","aria-selected":r.getState().activeItemId===i.__autocomplete_id,onMouseMove:function(e){if(i.__autocomplete_id!==r.getState().activeItemId){r.dispatch("mousemove",i.__autocomplete_id);var t=Je(r.getState());if(null!==r.getState().activeItemId&&t){var a=t.item,s=t.itemInputValue,l=t.itemUrl,c=t.source;c.onActive(St({event:e,item:a,itemInputValue:s,itemUrl:l,refresh:n,source:c,state:r.getState()},o))}}},onMouseDown:function(e){e.preventDefault()},onClick:function(e){var a=s.getItemInputValue({item:i,state:r.getState()}),l=s.getItemUrl({item:i,state:r.getState()});(l?Promise.resolve():lt(St({event:e,nextState:{isOpen:!1},props:t,query:a,refresh:n,store:r},o))).then((function(){s.onSelect(St({event:e,item:i,itemInputValue:a,itemUrl:l,refresh:n,source:s,state:r.getState()},o))}))}},c)}}}var At=[{segment:"autocomplete-core",version:"1.10.0"}];function It(e){return It="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},It(e)}function Pt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Tt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pt(Object(n),!0).forEach((function(t){Nt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Nt(e,t,n){return(t=function(e){var t=function(e){if("object"!==It(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==It(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===It(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Dt(e){var t,n,r,o,a=e.plugins,i=e.options,s=null===(t=((null===(n=i.__autocomplete_metadata)||void 0===n?void 0:n.userAgents)||[])[0])||void 0===t?void 0:t.segment,l=s?Nt({},s,Object.keys((null===(r=i.__autocomplete_metadata)||void 0===r?void 0:r.options)||{})):{};return{plugins:a.map((function(e){return{name:e.name,options:Object.keys(e.__autocomplete_pluginOptions||[])}})),options:Tt({"autocomplete-core":Object.keys(i)},l),ua:At.concat((null===(o=i.__autocomplete_metadata)||void 0===o?void 0:o.userAgents)||[])}}function Lt(e){var t,n=e.state;return!1===n.isOpen||null===n.activeItemId?null:(null===(t=Je(n))||void 0===t?void 0:t.itemInputValue)||null}function Ft(e,t,n,r){if(!n)return null;if(e<0&&(null===t||null!==r&&0===t))return n+e;var o=(null===t?-1:t)+e;return o<=-1||o>=n?null===r?null:0:o}function jt(e){return jt="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},jt(e)}function Rt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rt(Object(n),!0).forEach((function(t){Bt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Bt(e,t,n){return(t=function(e){var t=function(e){if("object"!==jt(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==jt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===jt(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Vt=function(e,t){switch(t.type){case"setActiveItemId":case"mousemove":return Mt(Mt({},e),{},{activeItemId:t.payload});case"setQuery":return Mt(Mt({},e),{},{query:t.payload,completion:null});case"setCollections":return Mt(Mt({},e),{},{collections:t.payload});case"setIsOpen":return Mt(Mt({},e),{},{isOpen:t.payload});case"setStatus":return Mt(Mt({},e),{},{status:t.payload});case"setContext":return Mt(Mt({},e),{},{context:Mt(Mt({},e.context),t.payload)});case"ArrowDown":var n=Mt(Mt({},e),{},{activeItemId:t.payload.hasOwnProperty("nextActiveItemId")?t.payload.nextActiveItemId:Ft(1,e.activeItemId,we(e),t.props.defaultActiveItemId)});return Mt(Mt({},n),{},{completion:Lt({state:n})});case"ArrowUp":var r=Mt(Mt({},e),{},{activeItemId:Ft(-1,e.activeItemId,we(e),t.props.defaultActiveItemId)});return Mt(Mt({},r),{},{completion:Lt({state:r})});case"Escape":return e.isOpen?Mt(Mt({},e),{},{activeItemId:null,isOpen:!1,completion:null}):Mt(Mt({},e),{},{activeItemId:null,query:"",status:"idle",collections:[]});case"submit":return Mt(Mt({},e),{},{activeItemId:null,isOpen:!1,status:"idle"});case"reset":return Mt(Mt({},e),{},{activeItemId:!0===t.props.openOnFocus?t.props.defaultActiveItemId:null,status:"idle",query:""});case"focus":return Mt(Mt({},e),{},{activeItemId:t.props.defaultActiveItemId,isOpen:(t.props.openOnFocus||Boolean(e.query))&&t.props.shouldPanelOpen({state:e})});case"blur":return t.props.debug?e:Mt(Mt({},e),{},{isOpen:!1,activeItemId:null});case"mouseleave":return Mt(Mt({},e),{},{activeItemId:t.props.defaultActiveItemId});default:return"The reducer action ".concat(JSON.stringify(t.type)," is not supported."),e}};function Ht(e){return Ht="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},Ht(e)}function zt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ut(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zt(Object(n),!0).forEach((function(t){Wt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Wt(e,t,n){return(t=function(e){var t=function(e){if("object"!==Ht(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Ht(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ht(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qt(e){var t=[],n=Le(e,t),r=function(e,t,n){var r,o=t.initialState;return{getState:function(){return o},dispatch:function(r,a){var i=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ge(Object(n),!0).forEach((function(t){be(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ge(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},o);o=e(o,{type:r,props:t,payload:a}),n({state:o,prevState:i})},pendingRequests:(r=[],{add:function(e){return r.push(e),e.finally((function(){r=r.filter((function(t){return t!==e}))}))},cancelAll:function(){r.forEach((function(e){return e.cancel()}))},isEmpty:function(){return 0===r.length}})}}(Vt,n,(function(e){var t=e.prevState,r=e.state;n.onStateChange(Ut({prevState:t,state:r,refresh:i,navigator:n.navigator},o))})),o=function(e){var t=e.store;return{setActiveItemId:function(e){t.dispatch("setActiveItemId",e)},setQuery:function(e){t.dispatch("setQuery",e)},setCollections:function(e){var n=0,r=e.map((function(e){return ke(ke({},e),{},{items:ve(e.items).map((function(e){return ke(ke({},e),{},{__autocomplete_id:n++})}))})}));t.dispatch("setCollections",r)},setIsOpen:function(e){t.dispatch("setIsOpen",e)},setStatus:function(e){t.dispatch("setStatus",e)},setContext:function(e){t.dispatch("setContext",e)}}}({store:r}),a=xt(Ut({props:n,refresh:i,store:r,navigator:n.navigator},o));function i(){return lt(Ut({event:new Event("input"),nextState:{isOpen:r.getState().isOpen},props:n,navigator:n.navigator,query:r.getState().query,refresh:i,store:r},o))}if(e.insights&&!n.plugins.some((function(e){return"aa.algoliaInsightsPlugin"===e.name}))){var s="boolean"==typeof e.insights?{}:e.insights;n.plugins.push(fe(s))}return n.plugins.forEach((function(e){var r;return null===(r=e.subscribe)||void 0===r?void 0:r.call(e,Ut(Ut({},o),{},{navigator:n.navigator,refresh:i,onSelect:function(e){t.push({onSelect:e})},onActive:function(e){t.push({onActive:e})},onResolve:function(e){t.push({onResolve:e})}}))})),function(e){var t,n,r=e.metadata,o=e.environment;if(null===(t=o.navigator)||void 0===t||null===(n=t.userAgent)||void 0===n?void 0:n.includes("Algolia Crawler")){var a=o.document.createElement("meta"),i=o.document.querySelector("head");a.name="algolia:metadata",setTimeout((function(){a.content=JSON.stringify(r),i.appendChild(a)}),0)}}({metadata:Dt({plugins:n.plugins,options:e}),environment:n.environment}),Ut(Ut({refresh:i,navigator:n.navigator},a),o)}function Gt(e){return Gt="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},Gt(e)}var Kt=["params"];function $t(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Yt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$t(Object(n),!0).forEach((function(t){Zt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$t(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Zt(e,t,n){return(t=function(e){var t=function(e){if("object"!==Gt(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Gt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Gt(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jt(e){return function(e){if(Array.isArray(e))return Qt(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Qt(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Qt(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Qt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Xt(e){return Xt="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},Xt(e)}function en(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?en(Object(n),!0).forEach((function(t){nn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):en(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function nn(e,t,n){return(t=function(e){var t=function(e){if("object"!==Xt(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!==Xt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Xt(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rn=function(){function e(e){return function(e){var t=e.searchClient,n=e.queries,r=e.userAgents,o=void 0===r?[]:r;"function"==typeof t.addAlgoliaAgent&&[].concat(Jt(At),Jt(o)).forEach((function(e){var n=e.segment,r=e.version;t.addAlgoliaAgent(n,r)}));var a=function(e){var t=e.transporter||{},n=t.headers,r=void 0===n?{}:n,o=t.queryParameters,a=void 0===o?{}:o,i="x-algolia-application-id",s="x-algolia-api-key";return{appId:r[i]||a[i],apiKey:r[s]||a[s]}}(t),i=a.appId,s=a.apiKey;return Boolean(i),Boolean(s),t.search(n.map((function(e){var t=e.params;return Yt(Yt({},function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,Kt)),{},{params:Yt({hitsPerPage:5,highlightPreTag:"__aa-highlight__",highlightPostTag:"__/aa-highlight__"},t)})}))).then((function(e){return e.results.map((function(e,t){var r;return Yt(Yt({},e),{},{hits:null===(r=e.hits)||void 0===r?void 0:r.map((function(r){return Yt(Yt({},r),{},{__autocomplete_indexName:e.index||n[t].indexName,__autocomplete_queryID:e.queryID,__autocomplete_algoliaCredentials:{appId:i,apiKey:s}})}))})}))}))}({searchClient:e.searchClient,queries:e.requests.map((function(e){return e.query}))}).then((function(t){return t.map((function(t,n){var r=e.requests[n];return{items:t,sourceId:r.sourceId,transformResponse:r.transformResponse}}))}))}return function(t){return function(n){return tn(tn({requesterId:"algolia",execute:e},t),n)}}}();function on(e){return on="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},on(e)}const an=(0,r.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{d:"M13 5c-3.3 0-6 2.7-6 6 0 1.4.5 2.7 1.3 3.7l-3.8 3.8 1.1 1.1 3.8-3.8c1 .8 2.3 1.3 3.7 1.3 3.3 0 6-2.7 6-6S16.3 5 13 5zm0 10.5c-2.5 0-4.5-2-4.5-4.5s2-4.5 4.5-4.5 4.5 2 4.5 4.5-2 4.5-4.5 4.5z"})),sn=(0,r.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})),ln=window.wp.components,cn=B()("A3VQNQXTF3","1490aefba5f869d86cc5e27099af3306");function un(t){const[n,a]=(0,r.useState)({}),[i,s]=(0,r.useState)(!0),[l,c]=(0,r.useState)(!0),[u,d]=(0,r.useState)(""),p=(0,r.useRef)(null),m=(0,r.useRef)(null),f=(0,r.useRef)(null),h=(0,r.useRef)(null);(0,r.useEffect)((()=>{a((e=>({...e,query:t.currentValue})))}),[]),(0,r.useEffect)((()=>{d(t.currentValue)}),[t.currentValue]),(0,r.useEffect)((()=>{function e(e){p.current&&!p.current.contains(e.target)&&g.setIsOpen(!1)}return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)}),[p]),(0,r.useEffect)((()=>{s(function(){const{query:e,collections:t}=n;return(""===u||u!==e)&&(!(!e||""===e.trim())&&(!function(){const{collections:e,query:t}=n;return!(!Array.isArray(e)||!Array.isArray(e[0]?.items))&&!!e[0].items.filter((e=>e.name.toLowerCase()===t.toLowerCase())).length}()&&!(!l&&e&&t?.[0]?.items&&0===t[0].items.length)))}())}),[n.query,n.collections]),(0,r.useEffect)((()=>{const e=document.querySelector(".components-modal__frame.stellarwp").getBoundingClientRect(),t=h.current.getBoundingClientRect().bottom+180>e.bottom?"top":"bottom";if(n.isOpen){const e=document.querySelector(".aa-PanelWrapper"),n=e.clientHeight;"top"===t&&(e.style.top=`-${56+n}px`)}}),[n.isOpen]);const g=(0,r.useMemo)((()=>qt({onStateChange({state:e}){a(e)},getSources:()=>[{sourceId:"industries",getItemInputValue:({item:e})=>e.query,getItems({query:e}){return on((t={searchClient:cn,queries:[{indexName:"ai_modal_industries",query:e,params:{hitsPerPage:8,highlightPreTag:"<mark>",highlightPostTag:"</mark>"}}]}).searchClient),rn({transformResponse:function(e){return e.hits}})(t);var t},onSelect:e=>{t.onSelect(e.item.name),e.setQuery(e.item.name),c(!1)}}],openOnFocus:!1,...t})),[]);return(0,e.createElement)("div",{ref:p,className:"stellarwp-autocomplete-control"},t.label?(0,e.createElement)("label",{className:"components-input-control__label"},t.label):null,(0,e.createElement)("div",{className:"components-input-control__container"},(0,e.createElement)("div",{className:"aa-Autocomplete",...g.getRootProps({})},(0,e.createElement)("form",{className:"aa-Form",ref:m,...g.getFormProps({inputElement:f.current})},(0,e.createElement)("div",{className:"aa-InputWrapperPrefix"},(0,e.createElement)(ln.Button,{className:"aa-SubmitButton",icon:an,type:"submit",title:(0,o.__)("Submit","kadence-blocks")})),(0,e.createElement)("div",{className:"aa-InputWrapper"},(0,e.createElement)("input",{className:"aa-Input",ref:f,...g.getInputProps({}),onKeyDown:function(){c(!0)}})),(0,e.createElement)("div",{className:"aa-InputWrapperSuffix"},n.query&&(0,e.createElement)(ln.Button,{className:"aa-ClearButton",onClick:function(){t.onSelect(""),g.setQuery(""),g.refresh(),f.current.focus(),c(!0)},icon:sn}))),(0,e.createElement)("div",{ref:h,className:["aa-Panel","stalled"===n.status&&"aa-Panel--stalled"].filter(Boolean).join(" "),...g.getPanelProps({})},(n.isOpen||i)&&(0,e.createElement)("div",{className:"aa-PanelWrapper"},n.collections&&n.collections.map(((t,n)=>{const{source:r,items:o}=t;return(0,e.createElement)("div",{key:`source-${n}`,className:"aa-Source"},o.length>0&&(0,e.createElement)("ul",{className:"aa-List",...g.getListProps()},o.map((t=>(0,e.createElement)("li",{key:t.objectID,className:"aa-Item",...g.getItemProps({item:t,source:r}),dangerouslySetInnerHTML:{__html:t?._highlightResult?.name?.value?t._highlightResult.name.value:t.name}})))))})),i&&(0,e.createElement)(ln.Button,{className:"aa-ItemCreate",text:`+ ${(0,o.__)("Add","kadence-blocks")}: "${n.query}"`,onClick:function(){t.onSelect(n.query),a((e=>({...e,isOpen:!1}))),c(!0),s(!1)}}))))))}function dn(t){const{className:n="",...r}=t;return(0,e.createElement)(ln.Button,{className:`stellarwp ${n}`,...r})}var pn=n(2485),mn=n.n(pn);function fn(t){const{onDelete:n,text:r,className:a}=t,i=mn()("stellarwp","chip",a,{"has-icon":n});let s=null;return n&&(s=(0,e.createElement)(ln.Button,{icon:"no-alt",label:(0,o.__)("Delete Selection","kadence-blocks"),isSmall:!0,onClick:function(e){n&&n(e)}})),(0,e.createElement)("div",{className:i},r&&(0,e.createElement)("span",null,r),s)}function hn(){return(0,e.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none"},(0,e.createElement)("path",{d:"M4.37491 3.2665L5.83324 4.08317L5.01658 2.62484L5.83324 1.1665L4.37491 1.98317L2.91658 1.1665L3.73325 2.62484L2.91658 4.08317L4.37491 3.2665ZM11.3749 8.98317L9.91658 8.1665L10.7332 9.62484L9.91658 11.0832L11.3749 10.2665L12.8332 11.0832L12.0166 9.62484L12.8332 8.1665L11.3749 8.98317ZM12.8332 1.1665L11.3749 1.98317L9.91658 1.1665L10.7332 2.62484L9.91658 4.08317L11.3749 3.2665L12.8332 4.08317L12.0166 2.62484L12.8332 1.1665ZM8.38241 4.25234C8.15491 4.02484 7.78741 4.02484 7.55991 4.25234L0.752412 11.0598C0.524912 11.2873 0.524912 11.6548 0.752412 11.8823L2.11741 13.2473C2.34491 13.4748 2.71241 13.4748 2.93991 13.2473L9.74158 6.44567C9.96908 6.21817 9.96908 5.85067 9.74158 5.62317L8.38241 4.25234ZM7.78158 7.45484L6.54491 6.21817L7.96825 4.79484L9.20491 6.0315L7.78158 7.45484Z",fill:"black"}))}function gn(){return(0,e.createElement)(i.SVG,{width:"37",height:"28",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,e.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M26.884 27.9986H18.946C18.0865 27.9986 17.3888 27.3007 17.3888 26.4412C17.3888 25.5819 18.0865 24.884 18.946 24.884H24.1313C24.9405 24.8285 25.5806 24.1537 25.5806 23.3307C25.5806 22.4711 24.8828 21.7735 24.0233 21.7735H20.2322V21.7732H15.9094C15.0511 21.7732 14.3543 21.0765 14.3543 20.2182C14.3543 19.3599 15.0511 18.663 15.9094 18.663H16.8888L16.8868 18.661H18.3429C19.2008 18.661 19.8974 17.9646 19.8974 17.1067C19.8974 16.2488 19.2008 15.5525 18.3429 15.5525H14.6805V15.5511H7.00023C6.14238 15.5511 5.44581 14.8545 5.44581 13.9965C5.44581 13.1386 6.14238 12.442 7.00023 12.442H14.6805V12.4377H17.6876C18.5447 12.4377 19.2405 11.7418 19.2405 10.8846C19.2405 10.0274 18.5447 9.33155 17.6876 9.33155H17.0022L17.0023 9.33127H13.8087C12.9504 9.33127 12.2538 8.63444 12.2538 7.77632C12.2538 6.91786 12.9504 6.22103 13.8087 6.22103H21.183C21.2199 6.22103 21.2562 6.22227 21.2923 6.22475H23.9282C24.7875 6.22475 25.4853 5.52707 25.4853 4.66756C25.4853 3.80817 24.7875 3.11051 23.9282 3.11051H20.0535C19.247 3.05199 18.6102 2.37846 18.6102 1.55731C18.6102 0.697791 19.3078 2.94949e-10 20.1674 2.94949e-10H26.2711C26.2778 2.94949e-10 26.2844 -1.12778e-06 26.2916 0.000136145H33.4883L20.8783 13.7713L36.1306 28H26.9253L26.9231 27.9979C26.9102 27.9985 26.8972 27.9986 26.884 27.9986ZM11.9428 24.884C12.7993 24.884 13.4946 25.5793 13.4946 26.4357C13.4946 27.2922 12.7993 27.9874 11.9428 27.9874H6.24843C5.39208 27.9874 4.69675 27.2922 4.69675 26.4357C4.69675 25.5793 5.39208 24.884 6.24843 24.884H11.9428ZM9.68846 18.663C10.5474 18.663 11.2448 19.3603 11.2448 20.2195C11.2448 21.0783 10.5474 21.7758 9.68846 21.7758C8.82933 21.7758 8.13199 21.0783 8.13199 20.2195C8.13199 19.3603 8.82933 18.663 9.68846 18.663ZM1.55636 12.442C2.41547 12.442 3.11285 13.1393 3.11285 13.9984C3.11285 14.8574 2.41547 15.5548 1.55636 15.5548C0.697378 15.5548 0 14.8574 0 13.9984C0 13.1393 0.697378 12.442 1.55636 12.442ZM7.58797 6.22103C8.44693 6.22103 9.14443 6.91842 9.14443 7.7775C9.14443 8.63652 8.44693 9.33374 7.58797 9.33374C6.729 9.33374 6.0315 8.63652 6.0315 7.7775C6.0315 6.91842 6.729 6.22103 7.58797 6.22103ZM13.1696 2.94949e-10C14.0261 2.94949e-10 14.7213 0.695322 14.7213 1.55169C14.7213 2.4082 14.0261 3.10353 13.1696 3.10353H9.5702C8.71383 3.10353 8.01846 2.4082 8.01846 1.55169C8.01846 0.695322 8.71366 2.94949e-10 9.5702 2.94949e-10H13.1696Z",fill:"#0073E6"}))}function bn(){return(0,e.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none"},(0,e.createElement)("path",{d:"M5.25003 9.43241L2.81753 6.99991L1.9892 7.82241L5.25003 11.0832L12.25 4.08324L11.4275 3.26074L5.25003 9.43241Z",fill:"#0073E6"}))}function vn(){return(0,e.createElement)(i.SVG,{width:"12",height:"12",viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},(0,e.createElement)("style",null,"\n .spinner_qM83 { animation: spinner_8HQG 1.05s infinite; }\n .spinner_oXPr { animation-delay: 0.1s; }\n .spinner_ZTLf { animation-delay: 0.2s; }\n\t\t\t\t@keyframes spinner_8HQG {\n\t\t\t\t\t0%, 57.14% {\n\t\t\t\t\t\tanimation-timing-function: cubic-bezier(0.33, 0.66, 0.66, 1);\n\t\t\t\t\t\ttransform: translate(0);\n\t\t\t\t\t}\n\t\t\t\t\t28.57% {\n\t\t\t\t\t\tanimation-timing-function: cubic-bezier(0.33, 0, 0.66, 0.33);\n\t\t\t\t\t\ttransform: translateY(-3px);\n\t\t\t\t\t}\n\t\t\t\t\t100% {\n\t\t\t\t\t\ttransform: translate(0);\n\t\t\t\t\t}\n\t\t\t\t}\n "),(0,e.createElement)("circle",{className:"spinner_qM83",cx:"2",cy:"6",r:"1"}),(0,e.createElement)("circle",{className:"spinner_qM83 spinner_oXPr",cx:"6",cy:"6",r:"1"}),(0,e.createElement)("circle",{className:"spinner_qM83 spinner_ZTLf",cx:"10",cy:"6",r:"1"}))}function yn(){return(0,e.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"12",viewBox:"0 0 14 12",fill:"none"},(0,e.createElement)("path",{d:"M5.06667 7.71667L5.90132 5.90132L7.71667 5.06667L5.90132 4.23202L5.06667 2.41667L4.23202 4.23202L2.41667 5.06667L4.23202 5.90132L5.06667 7.71667ZM5.06667 10.1333L3.48333 6.65L0 5.06667L3.48333 3.48333L5.06667 0L6.65 3.48333L10.1333 5.06667L6.65 6.65L5.06667 10.1333ZM10.8 12L10.0167 10.25L8.26667 9.46667L10.0167 8.66667L10.8 6.93333L11.6 8.66667L13.3333 9.46667L11.6 10.25L10.8 12Z",fill:"#0073E6"}))}function En(){return(0,e.createElement)(i.SVG,{width:"16",height:"16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,e.createElement)("path",{d:"M8.00008 3C4.66675 3 1.82008 5.07333 0.666748 8C1.82008 10.9267 4.66675 13 8.00008 13C11.3334 13 14.1801 10.9267 15.3334 8C14.1801 5.07333 11.3334 3 8.00008 3ZM8.00008 11.3333C6.16008 11.3333 4.66675 9.84 4.66675 8C4.66675 6.16 6.16008 4.66667 8.00008 4.66667C9.84008 4.66667 11.3334 6.16 11.3334 8C11.3334 9.84 9.84008 11.3333 8.00008 11.3333ZM8.00008 6C6.89341 6 6.00008 6.89333 6.00008 8C6.00008 9.10667 6.89341 10 8.00008 10C9.10675 10 10.0001 9.10667 10.0001 8C10.0001 6.89333 9.10675 6 8.00008 6Z",fill:"black"}))}function kn(){return(0,e.createElement)(i.SVG,{width:"16",height:"16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,e.createElement)("path",{d:"M7.99996 4.66667C9.83996 4.66667 11.3333 6.16 11.3333 8C11.3333 8.43333 11.2466 8.84 11.0933 9.22L13.04 11.1667C14.0466 10.3267 14.84 9.24 15.3266 8C14.1733 5.07333 11.3266 3 7.99329 3C7.05996 3 6.16663 3.16667 5.33996 3.46667L6.77996 4.90667C7.15996 4.75333 7.56663 4.66667 7.99996 4.66667ZM1.33329 2.84667L3.15996 4.67333C2.05329 5.53333 1.18663 6.68 0.666626 8C1.81996 10.9267 4.66663 13 7.99996 13C9.03329 13 10.02 12.8 10.92 12.44L11.2 12.72L13.1533 14.6667L14 13.82L2.17996 2L1.33329 2.84667ZM5.01996 6.53333L6.05329 7.56667C6.01996 7.70667 5.99996 7.85333 5.99996 8C5.99996 9.10667 6.89329 10 7.99996 10C8.14663 10 8.29329 9.98 8.43329 9.94667L9.46663 10.98C9.01996 11.2 8.52663 11.3333 7.99996 11.3333C6.15996 11.3333 4.66663 9.84 4.66663 8C4.66663 7.47333 4.79996 6.98 5.01996 6.53333ZM7.89329 6.01333L9.99329 8.11333L10.0066 8.00667C10.0066 6.9 9.11329 6.00667 8.00663 6.00667L7.89329 6.01333Z",fill:"black"}))}function wn(t){const{id:n,tags:a,maxTags:i,selectedTags:s,suggestedKeywords:l,suggestedKeywordsState:c,children:u,placeholder:d,onSuggestedKeywordAdded:p,onTryAgain:m,onTagDeleted:f,...h}=t,g=n?`inspector-chips-input-control-${n}`:"",[b,v]=(0,r.useState)(""),[y,E]=(0,r.useState)();function k(){const e=b.replace(",","").trim(),t=[...a];0!==e.length&&(-1===t.indexOf(e)?(t.push(e),s(t),v("")):v(""))}return(0,e.createElement)(ln.BaseControl,{className:"stellarwp-chips-input",id:g,...h},(0,e.createElement)("div",{className:"stellarwp-chips-input__control",onClick:()=>y&&y.focus()},Array.isArray(a)&&a.map(((t,n)=>(0,e.createElement)(fn,{key:n,text:t,className:"chip--blue",onDelete:()=>function(e){const t=[...a];t.splice(t.indexOf(e),1),s(t),f(e)}(t)}))),Array.isArray(a)&&a.length<i&&(0,e.createElement)("input",{id:g,ref:E,className:"stellarwp-chips-input__input",type:"text",value:b,onKeyUp:function(e){const t="Enter"===e.key,n=","===e.key;(t||n)&&(e.preventDefault(),k())},onBlur:function(e){e.preventDefault(),k()},onChange:e=>{var t;" "!==(t=e.target.value)&&","!==t&&v(t)},placeholder:d&&a.length<i?d:""})),c!==T&&(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions"},(()=>{switch(c){case x:return(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions-loading"},(0,e.createElement)(ln.Icon,{icon:yn}),(0,o.__)("Kadence is looking for Keyword Suggestions","kadence-blocks"),(0,e.createElement)(ln.Icon,{icon:vn}));case P:return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions-title"},(0,o.__)("Suggested Keywords","kadence-blocks")),(0,e.createElement)("ul",{className:"stellarwp-chips-input__suggestions-list"},l.map(((t,n)=>(0,e.createElement)("li",{key:`${t}`,className:"stellarwp-chips-input__suggestions-list-item"},(0,e.createElement)("button",{onClick:()=>function(e){if(a.length>=i)return;const t=[...a];t.push(e),s(t),v(""),p(e)}(t),className:"stellarwp-chips-input__suggestions-button"},t))))));case A:return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions-title"},(0,o.__)("We couldn’t find any good Keywords.","kadence-blocks")),(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions-description"},(0,o.__)("No worries, you can add your own keywords. Make sure to use words that directly relate to your website's content and what you do. The more the better.","kadence-blocks")));case I:return(0,e.createElement)(ln.Flex,null,(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)("div",{className:"stellarwp-chips-input__suggestions-title"},(0,o.__)("Oops! Something went wrong.","kadence-blocks"))),(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)(ln.Button,{onClick:m,variant:"link",className:"stellarwp-chips-input__suggestions-try-button"},(0,o.__)("Try again.","kadence-blocks"))));default:return(0,e.createElement)(e.Fragment,null)}})()))}var Sn=Number.isNaN||function(e){return"number"==typeof e&&e!=e};function On(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!((r=e[n])===(o=t[n])||Sn(r)&&Sn(o)))return!1;var r,o;return!0}const Cn=function(e,t){var n;void 0===t&&(t=On);var r,o=[],a=!1;return function(){for(var i=[],s=0;s<arguments.length;s++)i[s]=arguments[s];return a&&n===this&&t(i,o)||(r=e.apply(this,i),a=!0,n=this,o=i),r}},xn={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},An=function(e){function t(e,r,l,c,p){for(var m,f,h,g,E,_=0,w=0,S=0,O=0,C=0,N=0,L=h=m=0,j=0,R=0,M=0,B=0,V=l.length,H=V-1,z="",U="",W="",q="";j<V;){if(f=l.charCodeAt(j),j===H&&0!==w+O+S+_&&(0!==w&&(f=47===w?10:47),O=S=_=0,V++,H++),0===w+O+S+_){if(j===H&&(0<R&&(z=z.replace(d,"")),0<z.trim().length)){switch(f){case 32:case 9:case 59:case 13:case 10:break;default:z+=l.charAt(j)}f=59}switch(f){case 123:for(m=(z=z.trim()).charCodeAt(0),h=1,B=++j;j<V;){switch(f=l.charCodeAt(j)){case 123:h++;break;case 125:h--;break;case 47:switch(f=l.charCodeAt(j+1)){case 42:case 47:e:{for(L=j+1;L<H;++L)switch(l.charCodeAt(L)){case 47:if(42===f&&42===l.charCodeAt(L-1)&&j+2!==L){j=L+1;break e}break;case 10:if(47===f){j=L+1;break e}}j=L}}break;case 91:f++;case 40:f++;case 34:case 39:for(;j++<H&&l.charCodeAt(j)!==f;);}if(0===h)break;j++}if(h=l.substring(B,j),0===m&&(m=(z=z.replace(u,"").trim()).charCodeAt(0)),64===m){switch(0<R&&(z=z.replace(d,"")),f=z.charCodeAt(1)){case 100:case 109:case 115:case 45:R=r;break;default:R=T}if(B=(h=t(r,R,h,f,p+1)).length,0<D&&(E=s(3,h,R=n(T,z,M),r,A,x,B,f,p,c),z=R.join(""),void 0!==E&&0===(B=(h=E.trim()).length)&&(f=0,h="")),0<B)switch(f){case 115:z=z.replace(k,i);case 100:case 109:case 45:h=z+"{"+h+"}";break;case 107:h=(z=z.replace(b,"$1 $2"))+"{"+h+"}",h=1===P||2===P&&a("@"+h,3)?"@-webkit-"+h+"@"+h:"@"+h;break;default:h=z+h,112===c&&(U+=h,h="")}else h=""}else h=t(r,n(r,z,M),h,c,p+1);W+=h,h=M=R=L=m=0,z="",f=l.charCodeAt(++j);break;case 125:case 59:if(1<(B=(z=(0<R?z.replace(d,""):z).trim()).length))switch(0===L&&(m=z.charCodeAt(0),45===m||96<m&&123>m)&&(B=(z=z.replace(" ",":")).length),0<D&&void 0!==(E=s(1,z,r,e,A,x,U.length,c,p,c))&&0===(B=(z=E.trim()).length)&&(z="\0\0"),m=z.charCodeAt(0),f=z.charCodeAt(1),m){case 0:break;case 64:if(105===f||99===f){q+=z+l.charAt(j);break}default:58!==z.charCodeAt(B-1)&&(U+=o(z,m,f,z.charCodeAt(2)))}M=R=L=m=0,z="",f=l.charCodeAt(++j)}}switch(f){case 13:case 10:47===w?w=0:0===1+m&&107!==c&&0<z.length&&(R=1,z+="\0"),0<D*F&&s(0,z,r,e,A,x,U.length,c,p,c),x=1,A++;break;case 59:case 125:if(0===w+O+S+_){x++;break}default:switch(x++,g=l.charAt(j),f){case 9:case 32:if(0===O+_+w)switch(C){case 44:case 58:case 9:case 32:g="";break;default:32!==f&&(g=" ")}break;case 0:g="\\0";break;case 12:g="\\f";break;case 11:g="\\v";break;case 38:0===O+w+_&&(R=M=1,g="\f"+g);break;case 108:if(0===O+w+_+I&&0<L)switch(j-L){case 2:112===C&&58===l.charCodeAt(j-3)&&(I=C);case 8:111===N&&(I=N)}break;case 58:0===O+w+_&&(L=j);break;case 44:0===w+S+O+_&&(R=1,g+="\r");break;case 34:case 39:0===w&&(O=O===f?0:0===O?f:O);break;case 91:0===O+w+S&&_++;break;case 93:0===O+w+S&&_--;break;case 41:0===O+w+_&&S--;break;case 40:0===O+w+_&&(0===m&&(2*C+3*N==533||(m=1)),S++);break;case 64:0===w+S+O+_+L+h&&(h=1);break;case 42:case 47:if(!(0<O+_+S))switch(w){case 0:switch(2*f+3*l.charCodeAt(j+1)){case 235:w=47;break;case 220:B=j,w=42}break;case 42:47===f&&42===C&&B+2!==j&&(33===l.charCodeAt(B+2)&&(U+=l.substring(B,j+1)),g="",w=0)}}0===w&&(z+=g)}N=C,C=f,j++}if(0<(B=U.length)){if(R=r,0<D&&void 0!==(E=s(2,U,R,e,A,x,B,c,p,c))&&0===(U=E).length)return q+U+W;if(U=R.join(",")+"{"+U+"}",0!=P*I){switch(2!==P||a(U,2)||(I=0),I){case 111:U=U.replace(y,":-moz-$1")+U;break;case 112:U=U.replace(v,"::-webkit-input-$1")+U.replace(v,"::-moz-$1")+U.replace(v,":-ms-input-$1")+U}I=0}}return q+U+W}function n(e,t,n){var o=t.trim().split(h);t=o;var a=o.length,i=e.length;switch(i){case 0:case 1:var s=0;for(e=0===i?"":e[0]+" ";s<a;++s)t[s]=r(e,t[s],n).trim();break;default:var l=s=0;for(t=[];s<a;++s)for(var c=0;c<i;++c)t[l++]=r(e[c]+" ",o[s],n).trim()}return t}function r(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(g,"$1"+e.trim());case 58:return e.trim()+t.replace(g,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(g,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function o(e,t,n,r){var i=e+";",s=2*t+3*n+4*r;if(944===s){e=i.indexOf(":",9)+1;var l=i.substring(e,i.length-1).trim();return l=i.substring(0,e).trim()+l+";",1===P||2===P&&a(l,1)?"-webkit-"+l+l:l}if(0===P||2===P&&!a(i,1))return i;switch(s){case 1015:return 97===i.charCodeAt(10)?"-webkit-"+i+i:i;case 951:return 116===i.charCodeAt(3)?"-webkit-"+i+i:i;case 963:return 110===i.charCodeAt(5)?"-webkit-"+i+i:i;case 1009:if(100!==i.charCodeAt(4))break;case 969:case 942:return"-webkit-"+i+i;case 978:return"-webkit-"+i+"-moz-"+i+i;case 1019:case 983:return"-webkit-"+i+"-moz-"+i+"-ms-"+i+i;case 883:if(45===i.charCodeAt(8))return"-webkit-"+i+i;if(0<i.indexOf("image-set(",11))return i.replace(C,"$1-webkit-$2")+i;break;case 932:if(45===i.charCodeAt(4))switch(i.charCodeAt(5)){case 103:return"-webkit-box-"+i.replace("-grow","")+"-webkit-"+i+"-ms-"+i.replace("grow","positive")+i;case 115:return"-webkit-"+i+"-ms-"+i.replace("shrink","negative")+i;case 98:return"-webkit-"+i+"-ms-"+i.replace("basis","preferred-size")+i}return"-webkit-"+i+"-ms-"+i+i;case 964:return"-webkit-"+i+"-ms-flex-"+i+i;case 1023:if(99!==i.charCodeAt(8))break;return"-webkit-box-pack"+(l=i.substring(i.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+i+"-ms-flex-pack"+l+i;case 1005:return m.test(i)?i.replace(p,":-webkit-")+i.replace(p,":-moz-")+i:i;case 1e3:switch(t=(l=i.substring(13).trim()).indexOf("-")+1,l.charCodeAt(0)+l.charCodeAt(t)){case 226:l=i.replace(E,"tb");break;case 232:l=i.replace(E,"tb-rl");break;case 220:l=i.replace(E,"lr");break;default:return i}return"-webkit-"+i+"-ms-"+l+i;case 1017:if(-1===i.indexOf("sticky",9))break;case 975:switch(t=(i=e).length-10,s=(l=(33===i.charCodeAt(t)?i.substring(0,t):i).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|l.charCodeAt(7))){case 203:if(111>l.charCodeAt(8))break;case 115:i=i.replace(l,"-webkit-"+l)+";"+i;break;case 207:case 102:i=i.replace(l,"-webkit-"+(102<s?"inline-":"")+"box")+";"+i.replace(l,"-webkit-"+l)+";"+i.replace(l,"-ms-"+l+"box")+";"+i}return i+";";case 938:if(45===i.charCodeAt(5))switch(i.charCodeAt(6)){case 105:return l=i.replace("-items",""),"-webkit-"+i+"-webkit-box-"+l+"-ms-flex-"+l+i;case 115:return"-webkit-"+i+"-ms-flex-item-"+i.replace(w,"")+i;default:return"-webkit-"+i+"-ms-flex-line-pack"+i.replace("align-content","").replace(w,"")+i}break;case 973:case 989:if(45!==i.charCodeAt(3)||122===i.charCodeAt(4))break;case 931:case 953:if(!0===O.test(e))return 115===(l=e.substring(e.indexOf(":")+1)).charCodeAt(0)?o(e.replace("stretch","fill-available"),t,n,r).replace(":fill-available",":stretch"):i.replace(l,"-webkit-"+l)+i.replace(l,"-moz-"+l.replace("fill-",""))+i;break;case 962:if(i="-webkit-"+i+(102===i.charCodeAt(5)?"-ms-"+i:"")+i,211===n+r&&105===i.charCodeAt(13)&&0<i.indexOf("transform",10))return i.substring(0,i.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+i}return i}function a(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),L(2!==t?r:r.replace(S,"$1"),n,t)}function i(e,t){var n=o(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace(_," or ($1)").substring(4):"("+t+")"}function s(e,t,n,r,o,a,i,s,l,u){for(var d,p=0,m=t;p<D;++p)switch(d=N[p].call(c,e,m,n,r,o,a,i,s,l,u)){case void 0:case!1:case!0:case null:break;default:m=d}if(m!==t)return m}function l(e){return void 0!==(e=e.prefix)&&(L=null,e?"function"!=typeof e?P=1:(P=2,L=e):P=0),l}function c(e,n){var r=e;if(33>r.charCodeAt(0)&&(r=r.trim()),r=[r],0<D){var o=s(-1,n,r,r,A,x,0,0,0,0);void 0!==o&&"string"==typeof o&&(n=o)}var a=t(T,r,n,0,0);return 0<D&&void 0!==(o=s(-2,a,r,r,A,x,a.length,0,0,0))&&(a=o),I=0,x=A=1,a}var u=/^\0+/g,d=/[\0\r\f]/g,p=/: */g,m=/zoo|gra/,f=/([,: ])(transform)/g,h=/,\r+?/g,g=/([\t\r\n ])*\f?&/g,b=/@(k\w+)\s*(\S*)\s*/,v=/::(place)/g,y=/:(read-only)/g,E=/[svh]\w+-[tblr]{2}/,k=/\(\s*(.*)\s*\)/g,_=/([\s\S]*?);/g,w=/-self|flex-/g,S=/[^]*?(:[rp][el]a[\w-]+)[^]*/,O=/stretch|:\s*\w+\-(?:conte|avail)/,C=/([^-])(image-set\()/,x=1,A=1,I=0,P=1,T=[],N=[],D=0,L=null,F=0;return c.use=function e(t){switch(t){case void 0:case null:D=N.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:N[D++]=t;break;case Boolean:F=0|!!t}}return e},c.set=l,void 0!==e&&l(e),c};var In,Pn,Tn=n(8226),Nn=n.n(Tn),Dn=/[A-Z]|^ms/g,Ln=(In=function(e){return e.replace(Dn,"-$&").toLowerCase()},Pn={},function(e){return void 0===Pn[e]&&(Pn[e]=In(e)),Pn[e]}),Fn=function(e,t){return null==t||"boolean"==typeof t?"":1===xn[e]||45===e.charCodeAt(1)||isNaN(t)||0===t?t:t+"px"},jn=function e(t){for(var n=t.length,r=0,o="";r<n;r++){var a=t[r];if(null!=a){var i=void 0;switch(typeof a){case"boolean":break;case"function":i=e([a()]);break;case"object":if(Array.isArray(a))i=e(a);else for(var s in i="",a)a[s]&&s&&(i&&(i+=" "),i+=s);break;default:i=a}i&&(o&&(o+=" "),o+=i)}}return o},Rn="undefined"!=typeof document;function Mn(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 Bn=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]=Mn(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=function(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]}(this.tags[this.tags.length-1]);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else{var r=Mn(this.opts);this.tags.push(r),r.appendChild(document.createTextNode(e+(t||"")))}this.ctr++,this.ctr%65e3==0&&this.tags.push(Mn(this.opts))},t.flush=function(){this.tags.forEach((function(e){return e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0,this.injected=!1},e}();var Vn=function(e,t){if(void 0!==e.__SECRET_EMOTION__)return e.__SECRET_EMOTION__;void 0===t&&(t={});var n,r,o=t.key||"css",a=Nn()((function(e){n+=e,Rn&&s.insert(e,c)}));void 0!==t.prefix&&(r={prefix:t.prefix});var i={registered:{},inserted:{},nonce:t.nonce,key:o},s=new Bn(t);Rn&&s.inject();var l=new An(r);l.use(t.stylisPlugins)(a);var c="";function u(e,t){if(null==e)return"";switch(typeof e){case"boolean":return"";case"function":return void 0!==e.__emotion_styles?e.toString():u.call(this,void 0===this?e():e(this.mergedProps,this.context),t);case"object":return f.call(this,e);default:var n=i.registered[e];return!1===t&&void 0!==n?n:e}}var d,p,m=new WeakMap;function f(e){if(m.has(e))return m.get(e);var t="";return Array.isArray(e)?e.forEach((function(e){t+=u.call(this,e,!1)}),this):Object.keys(e).forEach((function(n){"object"!=typeof e[n]?void 0!==i.registered[e[n]]?t+=n+"{"+i.registered[e[n]]+"}":t+=Ln(n)+":"+Fn(n,e[n])+";":Array.isArray(e[n])&&"string"==typeof e[n][0]&&void 0===i.registered[e[n][0]]?e[n].forEach((function(e){t+=Ln(n)+":"+Fn(n,e)+";"})):t+=n+"{"+u.call(this,e[n],!1)+"}"}),this),m.set(e,t),t}var h=/label:\s*([^\s;\n{]+)\s*;/g,g=function(e){var t=!0,n="",r="";null==e||void 0===e.raw?(t=!1,n+=u.call(this,e,!1)):n+=e[0];for(var o=arguments.length,a=new Array(o>1?o-1:0),i=1;i<o;i++)a[i-1]=arguments[i];return a.forEach((function(r,o){n+=u.call(this,r,46===n.charCodeAt(n.length-1)),!0===t&&void 0!==e[o+1]&&(n+=e[o+1])}),this),p=n,n=n.replace(h,(function(e,t){return r+="-"+t,""})),d=function(e,t){return function(e){for(var t,n=e.length,r=0,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)}(e+t)+t}(n,r),n};function b(e,t){void 0===i.inserted[d]&&(n="",l(e,t),i.inserted[d]=n)}var v=function(){var e=g.apply(this,arguments),t=o+"-"+d;return void 0===i.registered[t]&&(i.registered[t]=p),b("."+t,e),t};function y(e,t){var n="";return t.split(" ").forEach((function(t){void 0!==i.registered[t]?e.push(t):n+=t+" "})),n}function E(e,t){var n=[],r=y(n,e);return n.length<2?e:r+v(n,t)}function k(e){i.inserted[e]=!0}if(Rn){var _=document.querySelectorAll("[data-emotion-"+o+"]");Array.prototype.forEach.call(_,(function(e){s.tags[0].parentNode.insertBefore(e,s.tags[0]),e.getAttribute("data-emotion-"+o).split(" ").forEach(k)}))}var w={flush:function(){Rn&&(s.flush(),s.inject()),i.inserted={},i.registered={}},hydrate:function(e){e.forEach(k)},cx:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return E(jn(t))},merge:E,getRegisteredStyles:y,injectGlobal:function(){b("",g.apply(this,arguments))},keyframes:function(){var e=g.apply(this,arguments),t="animation-"+d;return b("","@keyframes "+t+"{"+e+"}"),t},css:v,sheet:s,caches:i};return e.__SECRET_EMOTION__=w,w}(void 0!==n.g?n.g:{}),Hn=(Vn.flush,Vn.hydrate,Vn.cx,Vn.merge,Vn.getRegisteredStyles,Vn.injectGlobal),zn=(Vn.keyframes,Vn.css),Un=(Vn.sheet,Vn.caches,n(5795)),Wn=n(5556),qn=n.n(Wn),Gn=n(3146),Kn=n.n(Gn),$n=n(8006),Yn=n(9790);function Zn(e){return Zn="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},Zn(e)}function Jn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Xn(e,t,n){return t&&Qn(e.prototype,t),n&&Qn(e,n),e}function er(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tr(){return tr=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},tr.apply(this,arguments)}function nr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){er(e,t,n[t])}))}return e}function rr(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ar(e,t)}function or(e){return or=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},or(e)}function ar(e,t){return ar=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ar(e,t)}function ir(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function sr(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function lr(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?sr(e):t}function cr(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var ur=function(){};function dr(e,t){return t?"-"===t[0]?e+t:e+"__"+t:e}function pr(e,t,n,r){var o=[t,r];if(n&&e)for(var a in n)n.hasOwnProperty(a)&&n[a]&&o.push("".concat(dr(e,a)));return o.filter((function(e){return e})).map((function(e){return String(e).trim()})).join(" ")}var mr=function(e){return Array.isArray(e)?e.filter(Boolean):"object"===Zn(e)&&null!==e?[e]:[]};function fr(e){return[document.documentElement,document.body,window].indexOf(e)>-1}function hr(e){return fr(e)?window.pageYOffset:e.scrollTop}function gr(e,t){fr(e)?window.scrollTo(0,t):e.scrollTop=t}function br(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:ur,o=hr(e),a=t-o,i=0;!function t(){var s,l=a*((s=(s=i+=10)/n-1)*s*s+1)+o;gr(e,l),i<n?Kn()(t):r(e)}()}function vr(){try{return document.createEvent("TouchEvent"),!0}catch(e){return!1}}var yr=function(e){return"auto"===e?"bottom":e},Er=function(e){function t(){var e,n;Jn(this,t);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(n=lr(this,(e=or(t)).call.apply(e,[this].concat(o))))),"state",{maxHeight:n.props.maxMenuHeight,placement:null}),er(sr(sr(n)),"getPlacement",(function(e){var t=n.props,r=t.minMenuHeight,o=t.maxMenuHeight,a=t.menuPlacement,i=t.menuPosition,s=t.menuShouldScrollIntoView,l=t.theme,c=n.context.getPortalPlacement;if(e){var u="fixed"===i,d=function(e){var t=e.maxHeight,n=e.menuEl,r=e.minHeight,o=e.placement,a=e.shouldScroll,i=e.isFixedPosition,s=e.theme.spacing,l=function(e){var t=getComputedStyle(e),n="absolute"===t.position,r=/(auto|scroll)/,o=document.documentElement;if("fixed"===t.position)return o;for(var a=e;a=a.parentElement;)if(t=getComputedStyle(a),(!n||"static"!==t.position)&&r.test(t.overflow+t.overflowY+t.overflowX))return a;return o}(n),c={placement:"bottom",maxHeight:t};if(!n||!n.offsetParent)return c;var u=l.getBoundingClientRect().height,d=n.getBoundingClientRect(),p=d.bottom,m=d.height,f=d.top,h=n.offsetParent.getBoundingClientRect().top,g=window.innerHeight,b=hr(l),v=parseInt(getComputedStyle(n).marginBottom,10),y=parseInt(getComputedStyle(n).marginTop,10),E=h-y,k=g-f,_=E+b,w=u-b-f,S=p-g+b+v,O=b+f-y,C=160;switch(o){case"auto":case"bottom":if(k>=m)return{placement:"bottom",maxHeight:t};if(w>=m&&!i)return a&&br(l,S,C),{placement:"bottom",maxHeight:t};if(!i&&w>=r||i&&k>=r)return a&&br(l,S,C),{placement:"bottom",maxHeight:i?k-v:w-v};if("auto"===o||i){var x=t,A=i?E:_;return A>=r&&(x=Math.min(A-v-s.controlHeight,t)),{placement:"top",maxHeight:x}}if("bottom"===o)return gr(l,S),{placement:"bottom",maxHeight:t};break;case"top":if(E>=m)return{placement:"top",maxHeight:t};if(_>=m&&!i)return a&&br(l,O,C),{placement:"top",maxHeight:t};if(!i&&_>=r||i&&E>=r){var I=t;return(!i&&_>=r||i&&E>=r)&&(I=i?E-y:_-y),a&&br(l,O,C),{placement:"top",maxHeight:I}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(o,'".'))}return c}({maxHeight:o,menuEl:e,minHeight:r,placement:a,shouldScroll:s&&!u,isFixedPosition:u,theme:l});c&&c(d),n.setState(d)}})),er(sr(sr(n)),"getUpdatedProps",(function(){var e=n.props.menuPlacement,t=n.state.placement||yr(e);return nr({},n.props,{placement:t,maxHeight:n.state.maxHeight})})),n}return rr(t,e),Xn(t,[{key:"render",value:function(){return(0,this.props.children)({ref:this.getPlacement,placerProps:this.getUpdatedProps()})}}]),t}(e.Component);er(Er,"contextTypes",{getPortalPlacement:qn().func});var kr=function(e){var t=e.theme,n=t.spacing.baseUnit;return{color:t.colors.neutral40,padding:"".concat(2*n,"px ").concat(3*n,"px"),textAlign:"center"}},_r=kr,wr=kr,Sr=function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps;return t().createElement("div",tr({className:o(zn(a("noOptionsMessage",e)),{"menu-notice":!0,"menu-notice--no-options":!0},r)},i),n)};Sr.defaultProps={children:"No options"};var Or=function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps;return t().createElement("div",tr({className:o(zn(a("loadingMessage",e)),{"menu-notice":!0,"menu-notice--loading":!0},r)},i),n)};Or.defaultProps={children:"Loading..."};var Cr=function(e){function n(){var e,t;Jn(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(t=lr(this,(e=or(n)).call.apply(e,[this].concat(o))))),"state",{placement:null}),er(sr(sr(t)),"getPortalPlacement",(function(e){var n=e.placement;n!==yr(t.props.menuPlacement)&&t.setState({placement:n})})),t}return rr(n,e),Xn(n,[{key:"getChildContext",value:function(){return{getPortalPlacement:this.getPortalPlacement}}},{key:"render",value:function(){var e=this.props,n=e.appendTo,r=e.children,o=e.controlElement,a=e.menuPlacement,i=e.menuPosition,s=e.getStyles,l="fixed"===i;if(!n&&!l||!o)return null;var c=this.state.placement||yr(a),u=function(e){var t=e.getBoundingClientRect();return{bottom:t.bottom,height:t.height,left:t.left,right:t.right,top:t.top,width:t.width}}(o),d=l?0:window.pageYOffset,p={offset:u[c]+d,position:i,rect:u},m=t().createElement("div",{className:zn(s("menuPortal",p))},r);return n?(0,Un.createPortal)(m,n):m}}]),n}(e.Component);er(Cr,"childContextTypes",{getPortalPlacement:qn().func});var xr=Array.isArray,Ar=Object.keys,Ir=Object.prototype.hasOwnProperty;function Pr(e,t){if(e===t)return!0;if(e&&t&&"object"==Zn(e)&&"object"==Zn(t)){var n,r,o,a=xr(e),i=xr(t);if(a&&i){if((r=e.length)!=t.length)return!1;for(n=r;0!=n--;)if(!Pr(e[n],t[n]))return!1;return!0}if(a!=i)return!1;var s=e instanceof Date,l=t instanceof Date;if(s!=l)return!1;if(s&&l)return e.getTime()==t.getTime();var c=e instanceof RegExp,u=t instanceof RegExp;if(c!=u)return!1;if(c&&u)return e.toString()==t.toString();var d=Ar(e);if((r=d.length)!==Ar(t).length)return!1;for(n=r;0!=n--;)if(!Ir.call(t,d[n]))return!1;for(n=r;0!=n--;)if(!("_owner"===(o=d[n])&&e.$$typeof||Pr(e[o],t[o])))return!1;return!0}return e!=e&&t!=t}function Tr(e,t){try{return Pr(e,t)}catch(e){if(e.message&&e.message.match(/stack|recursion/i))return console.warn("Warning: react-fast-compare does not handle circular references.",e.name,e.message),!1;throw e}}var Nr=[{base:"A",letters:/[\u0041\u24B6\uFF21\u00C0\u00C1\u00C2\u1EA6\u1EA4\u1EAA\u1EA8\u00C3\u0100\u0102\u1EB0\u1EAE\u1EB4\u1EB2\u0226\u01E0\u00C4\u01DE\u1EA2\u00C5\u01FA\u01CD\u0200\u0202\u1EA0\u1EAC\u1EB6\u1E00\u0104\u023A\u2C6F]/g},{base:"AA",letters:/[\uA732]/g},{base:"AE",letters:/[\u00C6\u01FC\u01E2]/g},{base:"AO",letters:/[\uA734]/g},{base:"AU",letters:/[\uA736]/g},{base:"AV",letters:/[\uA738\uA73A]/g},{base:"AY",letters:/[\uA73C]/g},{base:"B",letters:/[\u0042\u24B7\uFF22\u1E02\u1E04\u1E06\u0243\u0182\u0181]/g},{base:"C",letters:/[\u0043\u24B8\uFF23\u0106\u0108\u010A\u010C\u00C7\u1E08\u0187\u023B\uA73E]/g},{base:"D",letters:/[\u0044\u24B9\uFF24\u1E0A\u010E\u1E0C\u1E10\u1E12\u1E0E\u0110\u018B\u018A\u0189\uA779]/g},{base:"DZ",letters:/[\u01F1\u01C4]/g},{base:"Dz",letters:/[\u01F2\u01C5]/g},{base:"E",letters:/[\u0045\u24BA\uFF25\u00C8\u00C9\u00CA\u1EC0\u1EBE\u1EC4\u1EC2\u1EBC\u0112\u1E14\u1E16\u0114\u0116\u00CB\u1EBA\u011A\u0204\u0206\u1EB8\u1EC6\u0228\u1E1C\u0118\u1E18\u1E1A\u0190\u018E]/g},{base:"F",letters:/[\u0046\u24BB\uFF26\u1E1E\u0191\uA77B]/g},{base:"G",letters:/[\u0047\u24BC\uFF27\u01F4\u011C\u1E20\u011E\u0120\u01E6\u0122\u01E4\u0193\uA7A0\uA77D\uA77E]/g},{base:"H",letters:/[\u0048\u24BD\uFF28\u0124\u1E22\u1E26\u021E\u1E24\u1E28\u1E2A\u0126\u2C67\u2C75\uA78D]/g},{base:"I",letters:/[\u0049\u24BE\uFF29\u00CC\u00CD\u00CE\u0128\u012A\u012C\u0130\u00CF\u1E2E\u1EC8\u01CF\u0208\u020A\u1ECA\u012E\u1E2C\u0197]/g},{base:"J",letters:/[\u004A\u24BF\uFF2A\u0134\u0248]/g},{base:"K",letters:/[\u004B\u24C0\uFF2B\u1E30\u01E8\u1E32\u0136\u1E34\u0198\u2C69\uA740\uA742\uA744\uA7A2]/g},{base:"L",letters:/[\u004C\u24C1\uFF2C\u013F\u0139\u013D\u1E36\u1E38\u013B\u1E3C\u1E3A\u0141\u023D\u2C62\u2C60\uA748\uA746\uA780]/g},{base:"LJ",letters:/[\u01C7]/g},{base:"Lj",letters:/[\u01C8]/g},{base:"M",letters:/[\u004D\u24C2\uFF2D\u1E3E\u1E40\u1E42\u2C6E\u019C]/g},{base:"N",letters:/[\u004E\u24C3\uFF2E\u01F8\u0143\u00D1\u1E44\u0147\u1E46\u0145\u1E4A\u1E48\u0220\u019D\uA790\uA7A4]/g},{base:"NJ",letters:/[\u01CA]/g},{base:"Nj",letters:/[\u01CB]/g},{base:"O",letters:/[\u004F\u24C4\uFF2F\u00D2\u00D3\u00D4\u1ED2\u1ED0\u1ED6\u1ED4\u00D5\u1E4C\u022C\u1E4E\u014C\u1E50\u1E52\u014E\u022E\u0230\u00D6\u022A\u1ECE\u0150\u01D1\u020C\u020E\u01A0\u1EDC\u1EDA\u1EE0\u1EDE\u1EE2\u1ECC\u1ED8\u01EA\u01EC\u00D8\u01FE\u0186\u019F\uA74A\uA74C]/g},{base:"OI",letters:/[\u01A2]/g},{base:"OO",letters:/[\uA74E]/g},{base:"OU",letters:/[\u0222]/g},{base:"P",letters:/[\u0050\u24C5\uFF30\u1E54\u1E56\u01A4\u2C63\uA750\uA752\uA754]/g},{base:"Q",letters:/[\u0051\u24C6\uFF31\uA756\uA758\u024A]/g},{base:"R",letters:/[\u0052\u24C7\uFF32\u0154\u1E58\u0158\u0210\u0212\u1E5A\u1E5C\u0156\u1E5E\u024C\u2C64\uA75A\uA7A6\uA782]/g},{base:"S",letters:/[\u0053\u24C8\uFF33\u1E9E\u015A\u1E64\u015C\u1E60\u0160\u1E66\u1E62\u1E68\u0218\u015E\u2C7E\uA7A8\uA784]/g},{base:"T",letters:/[\u0054\u24C9\uFF34\u1E6A\u0164\u1E6C\u021A\u0162\u1E70\u1E6E\u0166\u01AC\u01AE\u023E\uA786]/g},{base:"TZ",letters:/[\uA728]/g},{base:"U",letters:/[\u0055\u24CA\uFF35\u00D9\u00DA\u00DB\u0168\u1E78\u016A\u1E7A\u016C\u00DC\u01DB\u01D7\u01D5\u01D9\u1EE6\u016E\u0170\u01D3\u0214\u0216\u01AF\u1EEA\u1EE8\u1EEE\u1EEC\u1EF0\u1EE4\u1E72\u0172\u1E76\u1E74\u0244]/g},{base:"V",letters:/[\u0056\u24CB\uFF36\u1E7C\u1E7E\u01B2\uA75E\u0245]/g},{base:"VY",letters:/[\uA760]/g},{base:"W",letters:/[\u0057\u24CC\uFF37\u1E80\u1E82\u0174\u1E86\u1E84\u1E88\u2C72]/g},{base:"X",letters:/[\u0058\u24CD\uFF38\u1E8A\u1E8C]/g},{base:"Y",letters:/[\u0059\u24CE\uFF39\u1EF2\u00DD\u0176\u1EF8\u0232\u1E8E\u0178\u1EF6\u1EF4\u01B3\u024E\u1EFE]/g},{base:"Z",letters:/[\u005A\u24CF\uFF3A\u0179\u1E90\u017B\u017D\u1E92\u1E94\u01B5\u0224\u2C7F\u2C6B\uA762]/g},{base:"a",letters:/[\u0061\u24D0\uFF41\u1E9A\u00E0\u00E1\u00E2\u1EA7\u1EA5\u1EAB\u1EA9\u00E3\u0101\u0103\u1EB1\u1EAF\u1EB5\u1EB3\u0227\u01E1\u00E4\u01DF\u1EA3\u00E5\u01FB\u01CE\u0201\u0203\u1EA1\u1EAD\u1EB7\u1E01\u0105\u2C65\u0250]/g},{base:"aa",letters:/[\uA733]/g},{base:"ae",letters:/[\u00E6\u01FD\u01E3]/g},{base:"ao",letters:/[\uA735]/g},{base:"au",letters:/[\uA737]/g},{base:"av",letters:/[\uA739\uA73B]/g},{base:"ay",letters:/[\uA73D]/g},{base:"b",letters:/[\u0062\u24D1\uFF42\u1E03\u1E05\u1E07\u0180\u0183\u0253]/g},{base:"c",letters:/[\u0063\u24D2\uFF43\u0107\u0109\u010B\u010D\u00E7\u1E09\u0188\u023C\uA73F\u2184]/g},{base:"d",letters:/[\u0064\u24D3\uFF44\u1E0B\u010F\u1E0D\u1E11\u1E13\u1E0F\u0111\u018C\u0256\u0257\uA77A]/g},{base:"dz",letters:/[\u01F3\u01C6]/g},{base:"e",letters:/[\u0065\u24D4\uFF45\u00E8\u00E9\u00EA\u1EC1\u1EBF\u1EC5\u1EC3\u1EBD\u0113\u1E15\u1E17\u0115\u0117\u00EB\u1EBB\u011B\u0205\u0207\u1EB9\u1EC7\u0229\u1E1D\u0119\u1E19\u1E1B\u0247\u025B\u01DD]/g},{base:"f",letters:/[\u0066\u24D5\uFF46\u1E1F\u0192\uA77C]/g},{base:"g",letters:/[\u0067\u24D6\uFF47\u01F5\u011D\u1E21\u011F\u0121\u01E7\u0123\u01E5\u0260\uA7A1\u1D79\uA77F]/g},{base:"h",letters:/[\u0068\u24D7\uFF48\u0125\u1E23\u1E27\u021F\u1E25\u1E29\u1E2B\u1E96\u0127\u2C68\u2C76\u0265]/g},{base:"hv",letters:/[\u0195]/g},{base:"i",letters:/[\u0069\u24D8\uFF49\u00EC\u00ED\u00EE\u0129\u012B\u012D\u00EF\u1E2F\u1EC9\u01D0\u0209\u020B\u1ECB\u012F\u1E2D\u0268\u0131]/g},{base:"j",letters:/[\u006A\u24D9\uFF4A\u0135\u01F0\u0249]/g},{base:"k",letters:/[\u006B\u24DA\uFF4B\u1E31\u01E9\u1E33\u0137\u1E35\u0199\u2C6A\uA741\uA743\uA745\uA7A3]/g},{base:"l",letters:/[\u006C\u24DB\uFF4C\u0140\u013A\u013E\u1E37\u1E39\u013C\u1E3D\u1E3B\u017F\u0142\u019A\u026B\u2C61\uA749\uA781\uA747]/g},{base:"lj",letters:/[\u01C9]/g},{base:"m",letters:/[\u006D\u24DC\uFF4D\u1E3F\u1E41\u1E43\u0271\u026F]/g},{base:"n",letters:/[\u006E\u24DD\uFF4E\u01F9\u0144\u00F1\u1E45\u0148\u1E47\u0146\u1E4B\u1E49\u019E\u0272\u0149\uA791\uA7A5]/g},{base:"nj",letters:/[\u01CC]/g},{base:"o",letters:/[\u006F\u24DE\uFF4F\u00F2\u00F3\u00F4\u1ED3\u1ED1\u1ED7\u1ED5\u00F5\u1E4D\u022D\u1E4F\u014D\u1E51\u1E53\u014F\u022F\u0231\u00F6\u022B\u1ECF\u0151\u01D2\u020D\u020F\u01A1\u1EDD\u1EDB\u1EE1\u1EDF\u1EE3\u1ECD\u1ED9\u01EB\u01ED\u00F8\u01FF\u0254\uA74B\uA74D\u0275]/g},{base:"oi",letters:/[\u01A3]/g},{base:"ou",letters:/[\u0223]/g},{base:"oo",letters:/[\uA74F]/g},{base:"p",letters:/[\u0070\u24DF\uFF50\u1E55\u1E57\u01A5\u1D7D\uA751\uA753\uA755]/g},{base:"q",letters:/[\u0071\u24E0\uFF51\u024B\uA757\uA759]/g},{base:"r",letters:/[\u0072\u24E1\uFF52\u0155\u1E59\u0159\u0211\u0213\u1E5B\u1E5D\u0157\u1E5F\u024D\u027D\uA75B\uA7A7\uA783]/g},{base:"s",letters:/[\u0073\u24E2\uFF53\u00DF\u015B\u1E65\u015D\u1E61\u0161\u1E67\u1E63\u1E69\u0219\u015F\u023F\uA7A9\uA785\u1E9B]/g},{base:"t",letters:/[\u0074\u24E3\uFF54\u1E6B\u1E97\u0165\u1E6D\u021B\u0163\u1E71\u1E6F\u0167\u01AD\u0288\u2C66\uA787]/g},{base:"tz",letters:/[\uA729]/g},{base:"u",letters:/[\u0075\u24E4\uFF55\u00F9\u00FA\u00FB\u0169\u1E79\u016B\u1E7B\u016D\u00FC\u01DC\u01D8\u01D6\u01DA\u1EE7\u016F\u0171\u01D4\u0215\u0217\u01B0\u1EEB\u1EE9\u1EEF\u1EED\u1EF1\u1EE5\u1E73\u0173\u1E77\u1E75\u0289]/g},{base:"v",letters:/[\u0076\u24E5\uFF56\u1E7D\u1E7F\u028B\uA75F\u028C]/g},{base:"vy",letters:/[\uA761]/g},{base:"w",letters:/[\u0077\u24E6\uFF57\u1E81\u1E83\u0175\u1E87\u1E85\u1E98\u1E89\u2C73]/g},{base:"x",letters:/[\u0078\u24E7\uFF58\u1E8B\u1E8D]/g},{base:"y",letters:/[\u0079\u24E8\uFF59\u1EF3\u00FD\u0177\u1EF9\u0233\u1E8F\u00FF\u1EF7\u1E99\u1EF5\u01B4\u024F\u1EFF]/g},{base:"z",letters:/[\u007A\u24E9\uFF5A\u017A\u1E91\u017C\u017E\u1E93\u1E95\u01B6\u0225\u0240\u2C6C\uA763]/g}],Dr=function(e){for(var t=0;t<Nr.length;t++)e=e.replace(Nr[t].letters,Nr[t].base);return e},Lr=function(e){return e.replace(/^\s+|\s+$/g,"")},Fr=function(e){return"".concat(e.label," ").concat(e.value)},jr=function(e){return t().createElement("span",tr({className:zn({label:"a11yText",zIndex:9999,border:0,clip:"rect(1px, 1px, 1px, 1px)",height:1,width:1,position:"absolute",overflow:"hidden",padding:0,whiteSpace:"nowrap",backgroundColor:"red",color:"blue"})},e))},Rr=function(e){function n(){return Jn(this,n),lr(this,or(n).apply(this,arguments))}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=(e.in,e.out,e.onExited,e.appear,e.enter,e.exit,e.innerRef),r=(e.emotion,ir(e,["in","out","onExited","appear","enter","exit","innerRef","emotion"]));return t().createElement("input",tr({ref:n},r,{className:zn({label:"dummyInput",background:0,border:0,fontSize:"inherit",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(0)"})}))}}]),n}(e.Component),Mr=function(e){function t(){return Jn(this,t),lr(this,or(t).apply(this,arguments))}return rr(t,e),Xn(t,[{key:"componentDidMount",value:function(){this.props.innerRef((0,Un.findDOMNode)(this))}},{key:"componentWillUnmount",value:function(){this.props.innerRef(null)}},{key:"render",value:function(){return this.props.children}}]),t}(e.Component),Br=["boxSizing","height","overflow","paddingRight","position"],Vr={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Hr(e){e.preventDefault()}function zr(e){e.stopPropagation()}function Ur(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;0===e?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function Wr(){return"ontouchstart"in window||navigator.maxTouchPoints}var qr=!("undefined"==typeof window||!window.document||!window.document.createElement),Gr=0,Kr=function(e){function t(){var e,n;Jn(this,t);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(n=lr(this,(e=or(t)).call.apply(e,[this].concat(o))))),"originalStyles",{}),er(sr(sr(n)),"listenerOptions",{capture:!1,passive:!1}),n}return rr(t,e),Xn(t,[{key:"componentDidMount",value:function(){var e=this;if(qr){var t=this.props,n=t.accountForScrollbars,r=t.touchScrollTarget,o=document.body,a=o&&o.style;if(n&&Br.forEach((function(t){var n=a&&a[t];e.originalStyles[t]=n})),n&&Gr<1){var i=parseInt(this.originalStyles.paddingRight,10)||0,s=document.body?document.body.clientWidth:0,l=window.innerWidth-s+i||0;Object.keys(Vr).forEach((function(e){var t=Vr[e];a&&(a[e]=t)})),a&&(a.paddingRight="".concat(l,"px"))}o&&Wr()&&(o.addEventListener("touchmove",Hr,this.listenerOptions),r&&(r.addEventListener("touchstart",Ur,this.listenerOptions),r.addEventListener("touchmove",zr,this.listenerOptions))),Gr+=1}}},{key:"componentWillUnmount",value:function(){var e=this;if(qr){var t=this.props,n=t.accountForScrollbars,r=t.touchScrollTarget,o=document.body,a=o&&o.style;Gr=Math.max(Gr-1,0),n&&Gr<1&&Br.forEach((function(t){var n=e.originalStyles[t];a&&(a[t]=n)})),o&&Wr()&&(o.removeEventListener("touchmove",Hr,this.listenerOptions),r&&(r.removeEventListener("touchstart",Ur,this.listenerOptions),r.removeEventListener("touchmove",zr,this.listenerOptions)))}}},{key:"render",value:function(){return null}}]),t}(e.Component);er(Kr,"defaultProps",{accountForScrollbars:!0});var $r=function(e){function n(){var e,t;Jn(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(t=lr(this,(e=or(n)).call.apply(e,[this].concat(o))))),"state",{touchScrollTarget:null}),er(sr(sr(t)),"getScrollTarget",(function(e){e!==t.state.touchScrollTarget&&t.setState({touchScrollTarget:e})})),er(sr(sr(t)),"blurSelectInput",(function(){document.activeElement&&document.activeElement.blur()})),t}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=e.children,r=e.isEnabled,o=this.state.touchScrollTarget;return r?t().createElement("div",null,t().createElement("div",{onClick:this.blurSelectInput,className:zn({position:"fixed",left:0,bottom:0,right:0,top:0})}),t().createElement(Mr,{innerRef:this.getScrollTarget},n),o?t().createElement(Kr,{touchScrollTarget:o}):null):n}}]),n}(e.PureComponent),Yr=function(e){function n(){var e,t;Jn(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(t=lr(this,(e=or(n)).call.apply(e,[this].concat(o))))),"isBottom",!1),er(sr(sr(t)),"isTop",!1),er(sr(sr(t)),"scrollTarget",void 0),er(sr(sr(t)),"touchStart",void 0),er(sr(sr(t)),"cancelScroll",(function(e){e.preventDefault(),e.stopPropagation()})),er(sr(sr(t)),"handleEventDelta",(function(e,n){var r=t.props,o=r.onBottomArrive,a=r.onBottomLeave,i=r.onTopArrive,s=r.onTopLeave,l=t.scrollTarget,c=l.scrollTop,u=l.scrollHeight,d=l.clientHeight,p=t.scrollTarget,m=n>0,f=u-d-c,h=!1;f>n&&t.isBottom&&(a&&a(e),t.isBottom=!1),m&&t.isTop&&(s&&s(e),t.isTop=!1),m&&n>f?(o&&!t.isBottom&&o(e),p.scrollTop=u,h=!0,t.isBottom=!0):!m&&-n>c&&(i&&!t.isTop&&i(e),p.scrollTop=0,h=!0,t.isTop=!0),h&&t.cancelScroll(e)})),er(sr(sr(t)),"onWheel",(function(e){t.handleEventDelta(e,e.deltaY)})),er(sr(sr(t)),"onTouchStart",(function(e){t.touchStart=e.changedTouches[0].clientY})),er(sr(sr(t)),"onTouchMove",(function(e){var n=t.touchStart-e.changedTouches[0].clientY;t.handleEventDelta(e,n)})),er(sr(sr(t)),"getScrollTarget",(function(e){t.scrollTarget=e})),t}return rr(n,e),Xn(n,[{key:"componentDidMount",value:function(){this.startListening(this.scrollTarget)}},{key:"componentWillUnmount",value:function(){this.stopListening(this.scrollTarget)}},{key:"startListening",value:function(e){e&&(e.scrollHeight<=e.clientHeight||("function"==typeof e.addEventListener&&e.addEventListener("wheel",this.onWheel,!1),"function"==typeof e.addEventListener&&e.addEventListener("touchstart",this.onTouchStart,!1),"function"==typeof e.addEventListener&&e.addEventListener("touchmove",this.onTouchMove,!1)))}},{key:"stopListening",value:function(e){e.scrollHeight<=e.clientHeight||("function"==typeof e.removeEventListener&&e.removeEventListener("wheel",this.onWheel,!1),"function"==typeof e.removeEventListener&&e.removeEventListener("touchstart",this.onTouchStart,!1),"function"==typeof e.removeEventListener&&e.removeEventListener("touchmove",this.onTouchMove,!1))}},{key:"render",value:function(){return t().createElement(Mr,{innerRef:this.getScrollTarget},this.props.children)}}]),n}(e.Component),Zr=function(e){function n(){return Jn(this,n),lr(this,or(n).apply(this,arguments))}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=e.isEnabled,r=ir(e,["isEnabled"]);return n?t().createElement(Yr,r):this.props.children}}]),n}(e.Component);er(Zr,"defaultProps",{isEnabled:!0});var Jr=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isSearchable,r=t.isMulti,o=t.label,a=t.isDisabled;switch(e){case"menu":return"Use Up and Down to choose options".concat(a?"":", press Enter to select the currently focused option",", press Escape to exit the menu, press Tab to select the option and exit the menu.");case"input":return"".concat(o||"Select"," is focused ").concat(n?",type to refine list":"",", press Down to open the menu, ").concat(r?" press left to focus selected values":"");case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value"}},Qr=function(e,t){var n=t.value,r=t.isDisabled;if(n)switch(e){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(n,", deselected.");case"select-option":return"option ".concat(n,r?" is disabled. Select another option.":", selected.")}},Xr=function(e){return!!e.isDisabled},eo=function(e){function n(){return Jn(this,n),lr(this,or(n).apply(this,arguments))}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=e.children,r=e.className,o=e.cx,a=e.isMulti,i=e.getStyles,s=e.hasValue;return t().createElement("div",{className:o(zn(i("valueContainer",this.props)),{"value-container":!0,"value-container--is-multi":a,"value-container--has-value":s},r)},n)}}]),n}(e.Component),to=function(e){var n=e.size,r=ir(e,["size"]);return t().createElement("svg",tr({height:n,width:n,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",className:zn({display:"inline-block",fill:"currentColor",lineHeight:1,stroke:"currentColor",strokeWidth:0})},r))},no=function(e){return t().createElement(to,tr({size:20},e),t().createElement("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},ro=function(e){return t().createElement(to,tr({size:20},e),t().createElement("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},oo=function(e){var t=e.isFocused,n=e.theme,r=n.spacing.baseUnit,o=n.colors;return{label:"indicatorContainer",color:t?o.neutral60:o.neutral20,display:"flex",padding:2*r,transition:"color 150ms",":hover":{color:t?o.neutral80:o.neutral40}}},ao=oo,io=oo,so="react-select-loading-indicator",lo=!1,co=function(e){var n=e.color,r=e.delay,o=e.offset;return t().createElement("span",{className:zn({animationDuration:"1s",animationDelay:"".concat(r,"ms"),animationIterationCount:"infinite",animationName:so,animationTimingFunction:"ease-in-out",backgroundColor:n,borderRadius:"1em",display:"inline-block",marginLeft:o?"1em":null,height:"1em",verticalAlign:"top",width:"1em"})})},uo=function(e){var n=e.className,r=e.cx,o=e.getStyles,a=e.innerProps,i=e.isFocused,s=e.isRtl,l=e.theme.colors,c=i?l.neutral80:l.neutral20;return lo||(Hn("@keyframes ",so,"{0%,80%,100%{opacity:0;}40%{opacity:1;}};"),lo=!0),t().createElement("div",tr({},a,{className:r(zn(o("loadingIndicator",e)),{indicator:!0,"loading-indicator":!0},n)}),t().createElement(co,{color:c,delay:0,offset:s}),t().createElement(co,{color:c,delay:160,offset:!0}),t().createElement(co,{color:c,delay:320,offset:!s}))};uo.defaultProps={size:4};var po=function(e){return{label:"input",background:0,border:0,fontSize:"inherit",opacity:e?0:1,outline:0,padding:0,color:"inherit"}},mo=function(e){var n=e.children,r=e.innerProps;return t().createElement("div",r,n)},fo=mo,ho=mo,go=function(e){function n(){return Jn(this,n),lr(this,or(n).apply(this,arguments))}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=e.children,r=e.innerProps;return t().createElement("div",r,n||t().createElement(no,{size:14}))}}]),n}(e.Component),bo=function(e){function n(){return Jn(this,n),lr(this,or(n).apply(this,arguments))}return rr(n,e),Xn(n,[{key:"render",value:function(){var e=this.props,n=e.children,r=e.className,o=e.components,a=e.cx,i=e.data,s=e.getStyles,l=e.innerProps,c=e.isDisabled,u=e.removeProps,d=e.selectProps,p=o.Container,m=o.Label,f=o.Remove,h=nr({className:a(zn(s("multiValue",this.props)),{"multi-value":!0,"multi-value--is-disabled":c},r)},l),g={className:a(zn(s("multiValueLabel",this.props)),{"multi-value__label":!0},r)},b=nr({className:a(zn(s("multiValueRemove",this.props)),{"multi-value__remove":!0},r)},u);return t().createElement(p,{data:i,innerProps:h,selectProps:d},t().createElement(m,{data:i,innerProps:g,selectProps:d},n),t().createElement(f,{data:i,innerProps:b,selectProps:d}))}}]),n}(e.Component);er(bo,"defaultProps",{cropWithEllipsis:!0});var vo={ClearIndicator:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps;return t().createElement("div",tr({},i,{className:o(zn(a("clearIndicator",e)),{indicator:!0,"clear-indicator":!0},r)}),n||t().createElement(no,null))},Control:function(e){var n=e.children,r=e.cx,o=e.getStyles,a=e.className,i=e.isDisabled,s=e.isFocused,l=e.innerRef,c=e.innerProps,u=e.menuIsOpen;return t().createElement("div",tr({ref:l,className:r(zn(o("control",e)),{control:!0,"control--is-disabled":i,"control--is-focused":s,"control--menu-is-open":u},a)},c),n)},DropdownIndicator:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps;return t().createElement("div",tr({},i,{className:o(zn(a("dropdownIndicator",e)),{indicator:!0,"dropdown-indicator":!0},r)}),n||t().createElement(ro,null))},DownChevron:ro,CrossIcon:no,Group:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.Heading,s=e.headingProps,l=e.label,c=e.theme,u=e.selectProps;return t().createElement("div",{className:o(zn(a("group",e)),{group:!0},r)},t().createElement(i,tr({},s,{selectProps:u,theme:c,getStyles:a,cx:o}),l),t().createElement("div",null,n))},GroupHeading:function(e){var n=e.className,r=e.cx,o=e.getStyles,a=e.theme,i=(e.selectProps,ir(e,["className","cx","getStyles","theme","selectProps"]));return t().createElement("div",tr({className:r(zn(o("groupHeading",nr({theme:a},i))),{"group-heading":!0},n)},i))},IndicatorsContainer:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles;return t().createElement("div",{className:o(zn(a("indicatorsContainer",e)),{indicators:!0},r)},n)},IndicatorSeparator:function(e){var n=e.className,r=e.cx,o=e.getStyles,a=e.innerProps;return t().createElement("span",tr({},a,{className:r(zn(o("indicatorSeparator",e)),{"indicator-separator":!0},n)}))},Input:function(e){var n=e.className,r=e.cx,o=e.getStyles,a=e.innerRef,i=e.isHidden,s=e.isDisabled,l=e.theme,c=(e.selectProps,ir(e,["className","cx","getStyles","innerRef","isHidden","isDisabled","theme","selectProps"]));return t().createElement("div",{className:zn(o("input",nr({theme:l},c)))},t().createElement($n.A,tr({className:r(null,{input:!0},n),inputRef:a,inputStyle:po(i),disabled:s},c)))},LoadingIndicator:uo,Menu:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerRef,s=e.innerProps,l=o(zn(a("menu",e)),{menu:!0},r);return t().createElement("div",tr({className:l},s,{ref:i}),n)},MenuList:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.isMulti,s=e.innerRef;return t().createElement("div",{className:o(zn(a("menuList",e)),{"menu-list":!0,"menu-list--is-multi":i},r),ref:s},n)},MenuPortal:Cr,LoadingMessage:Or,NoOptionsMessage:Sr,MultiValue:bo,MultiValueContainer:fo,MultiValueLabel:ho,MultiValueRemove:go,Option:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.isDisabled,s=e.isFocused,l=e.isSelected,c=e.innerRef,u=e.innerProps;return t().createElement("div",tr({ref:c,className:o(zn(a("option",e)),{option:!0,"option--is-disabled":i,"option--is-focused":s,"option--is-selected":l},r)},u),n)},Placeholder:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps;return t().createElement("div",tr({className:o(zn(a("placeholder",e)),{placeholder:!0},r)},i),n)},SelectContainer:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.innerProps,s=e.isDisabled,l=e.isRtl;return t().createElement("div",tr({className:o(zn(a("container",e)),{"--is-disabled":s,"--is-rtl":l},r)},i),n)},SingleValue:function(e){var n=e.children,r=e.className,o=e.cx,a=e.getStyles,i=e.isDisabled,s=e.innerProps;return t().createElement("div",tr({className:o(zn(a("singleValue",e)),{"single-value":!0,"single-value--is-disabled":i},r)},s),n)},ValueContainer:eo},yo=function(e){return nr({},vo,e.components)},Eo={clearIndicator:io,container:function(e){var t=e.isDisabled;return{label:"container",direction:e.isRtl?"rtl":null,pointerEvents:t?"none":null,position:"relative"}},control:function(e){var t=e.isDisabled,n=e.isFocused,r=e.theme,o=r.colors,a=r.borderRadius,i=r.spacing;return{label:"control",alignItems:"center",backgroundColor:t?o.neutral5:o.neutral0,borderColor:t?o.neutral10:n?o.primary:o.neutral20,borderRadius:a,borderStyle:"solid",borderWidth:1,boxShadow:n?"0 0 0 1px ".concat(o.primary):null,cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:i.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms","&:hover":{borderColor:n?o.primary:o.neutral30}}},dropdownIndicator:ao,group:function(e){var t=e.theme.spacing;return{paddingBottom:2*t.baseUnit,paddingTop:2*t.baseUnit}},groupHeading:function(e){var t=e.theme.spacing;return{label:"group",color:"#999",cursor:"default",display:"block",fontSize:"75%",fontWeight:"500",marginBottom:"0.25em",paddingLeft:3*t.baseUnit,paddingRight:3*t.baseUnit,textTransform:"uppercase"}},indicatorsContainer:function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},indicatorSeparator:function(e){var t=e.isDisabled,n=e.theme,r=n.spacing.baseUnit,o=n.colors;return{label:"indicatorSeparator",alignSelf:"stretch",backgroundColor:t?o.neutral10:o.neutral20,marginBottom:2*r,marginTop:2*r,width:1}},input:function(e){var t=e.isDisabled,n=e.theme,r=n.spacing,o=n.colors;return{margin:r.baseUnit/2,paddingBottom:r.baseUnit/2,paddingTop:r.baseUnit/2,visibility:t?"hidden":"visible",color:o.neutral80}},loadingIndicator:function(e){var t=e.isFocused,n=e.size,r=e.theme,o=r.colors,a=r.spacing.baseUnit;return{label:"loadingIndicator",color:t?o.neutral60:o.neutral20,display:"flex",padding:2*a,transition:"color 150ms",alignSelf:"center",fontSize:n,lineHeight:1,marginRight:n,textAlign:"center",verticalAlign:"middle"}},loadingMessage:wr,menu:function(e){var t,n=e.placement,r=e.theme,o=r.borderRadius,a=r.spacing,i=r.colors;return er(t={label:"menu"},function(e){return e?{bottom:"top",top:"bottom"}[e]:"bottom"}(n),"100%"),er(t,"backgroundColor",i.neutral0),er(t,"borderRadius",o),er(t,"boxShadow","0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)"),er(t,"marginBottom",a.menuGutter),er(t,"marginTop",a.menuGutter),er(t,"position","absolute"),er(t,"width","100%"),er(t,"zIndex",1),t},menuList:function(e){var t=e.maxHeight,n=e.theme.spacing.baseUnit;return{maxHeight:t,overflowY:"auto",paddingBottom:n,paddingTop:n,position:"relative",WebkitOverflowScrolling:"touch"}},menuPortal:function(e){var t=e.rect,n=e.offset,r=e.position;return{left:t.left,position:r,top:n,width:t.width,zIndex:1}},multiValue:function(e){var t=e.theme,n=t.spacing,r=t.borderRadius;return{label:"multiValue",backgroundColor:t.colors.neutral10,borderRadius:r/2,display:"flex",margin:n.baseUnit/2,minWidth:0}},multiValueLabel:function(e){var t=e.theme,n=t.borderRadius,r=t.colors,o=e.cropWithEllipsis;return{borderRadius:n/2,color:r.neutral80,fontSize:"85%",overflow:"hidden",padding:3,paddingLeft:6,textOverflow:o?"ellipsis":null,whiteSpace:"nowrap"}},multiValueRemove:function(e){var t=e.theme,n=t.spacing,r=t.borderRadius,o=t.colors;return{alignItems:"center",borderRadius:r/2,backgroundColor:e.isFocused&&o.dangerLight,display:"flex",paddingLeft:n.baseUnit,paddingRight:n.baseUnit,":hover":{backgroundColor:o.dangerLight,color:o.danger}}},noOptionsMessage:_r,option:function(e){var t=e.isDisabled,n=e.isFocused,r=e.isSelected,o=e.theme,a=o.spacing,i=o.colors;return{label:"option",backgroundColor:r?i.primary:n?i.primary25:"transparent",color:t?i.neutral20:r?i.neutral0:"inherit",cursor:"default",display:"block",fontSize:"inherit",padding:"".concat(2*a.baseUnit,"px ").concat(3*a.baseUnit,"px"),width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)",":active":{backgroundColor:!t&&(r?i.primary:i.primary50)}}},placeholder:function(e){var t=e.theme,n=t.spacing;return{label:"placeholder",color:t.colors.neutral50,marginLeft:n.baseUnit/2,marginRight:n.baseUnit/2,position:"absolute",top:"50%",transform:"translateY(-50%)"}},singleValue:function(e){var t=e.isDisabled,n=e.theme,r=n.spacing,o=n.colors;return{label:"singleValue",color:t?o.neutral40:o.neutral80,marginLeft:r.baseUnit/2,marginRight:r.baseUnit/2,maxWidth:"calc(100% - ".concat(2*r.baseUnit,"px)"),overflow:"hidden",position:"absolute",textOverflow:"ellipsis",whiteSpace:"nowrap",top:"50%",transform:"translateY(-50%)"}},valueContainer:function(e){var t=e.theme.spacing;return{alignItems:"center",display:"flex",flex:1,flexWrap:"wrap",padding:"".concat(t.baseUnit/2,"px ").concat(2*t.baseUnit,"px"),WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"}}},ko={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},_o={backspaceRemovesValue:!0,blurInputOnSelect:vr(),captureMenuScroll:!vr(),closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){var n=nr({ignoreCase:!0,ignoreAccents:!0,stringify:Fr,trim:!0,matchFrom:"any"},undefined),r=n.ignoreCase,o=n.ignoreAccents,a=n.stringify,i=n.trim,s=n.matchFrom,l=i?Lr(t):t,c=i?Lr(a(e)):a(e);return r&&(l=l.toLowerCase(),c=c.toLowerCase()),o&&(l=Dr(l),c=Dr(c)),"start"===s?c.substr(0,l.length)===l:c.indexOf(l)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:function(e){return e.label},getOptionValue:function(e){return e.value},isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:Xr,loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!function(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch(e){return!1}}(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:"0",tabSelectsValue:!0},wo=1,So=function(e){function n(e){var t;Jn(this,n),er(sr(sr(t=lr(this,or(n).call(this,e)))),"state",{ariaLiveSelection:"",ariaLiveContext:"",focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,menuOptions:{render:[],focusable:[]},selectValue:[]}),er(sr(sr(t)),"blockOptionHover",!1),er(sr(sr(t)),"isComposing",!1),er(sr(sr(t)),"clearFocusValueOnUpdate",!1),er(sr(sr(t)),"commonProps",void 0),er(sr(sr(t)),"components",void 0),er(sr(sr(t)),"hasGroups",!1),er(sr(sr(t)),"initialTouchX",0),er(sr(sr(t)),"initialTouchY",0),er(sr(sr(t)),"inputIsHiddenAfterUpdate",void 0),er(sr(sr(t)),"instancePrefix",""),er(sr(sr(t)),"openAfterFocus",!1),er(sr(sr(t)),"scrollToFocusedOptionOnUpdate",!1),er(sr(sr(t)),"userIsDragging",void 0),er(sr(sr(t)),"controlRef",null),er(sr(sr(t)),"getControlRef",(function(e){t.controlRef=e})),er(sr(sr(t)),"focusedOptionRef",null),er(sr(sr(t)),"getFocusedOptionRef",(function(e){t.focusedOptionRef=e})),er(sr(sr(t)),"menuListRef",null),er(sr(sr(t)),"getMenuListRef",(function(e){t.menuListRef=e})),er(sr(sr(t)),"inputRef",null),er(sr(sr(t)),"getInputRef",(function(e){t.inputRef=e})),er(sr(sr(t)),"cacheComponents",(function(e){t.components=yo({components:e})})),er(sr(sr(t)),"focus",t.focusInput),er(sr(sr(t)),"blur",t.blurInput),er(sr(sr(t)),"onChange",(function(e,n){var r=t.props;(0,r.onChange)(e,nr({},n,{name:r.name}))})),er(sr(sr(t)),"setValue",(function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"set-value",r=arguments.length>2?arguments[2]:void 0,o=t.props,a=o.closeMenuOnSelect,i=o.isMulti;t.onInputChange("",{action:"set-value"}),a&&(t.inputIsHiddenAfterUpdate=!i,t.onMenuClose()),t.clearFocusValueOnUpdate=!0,t.onChange(e,{action:n,option:r})})),er(sr(sr(t)),"selectOption",(function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,a=t.state.selectValue;if(o)if(t.isOptionSelected(e,a)){var i=t.getOptionValue(e);t.setValue(a.filter((function(e){return t.getOptionValue(e)!==i})),"deselect-option",e),t.announceAriaLiveSelection({event:"deselect-option",context:{value:t.getOptionLabel(e)}})}else t.isOptionDisabled(e,a)?t.announceAriaLiveSelection({event:"select-option",context:{value:t.getOptionLabel(e),isDisabled:!0}}):(t.setValue([].concat(cr(a),[e]),"select-option",e),t.announceAriaLiveSelection({event:"select-option",context:{value:t.getOptionLabel(e)}}));else t.isOptionDisabled(e,a)?t.announceAriaLiveSelection({event:"select-option",context:{value:t.getOptionLabel(e),isDisabled:!0}}):(t.setValue(e,"select-option"),t.announceAriaLiveSelection({event:"select-option",context:{value:t.getOptionLabel(e)}}));r&&t.blurInput()})),er(sr(sr(t)),"removeValue",(function(e){var n=t.state.selectValue,r=t.getOptionValue(e);t.onChange(n.filter((function(e){return t.getOptionValue(e)!==r})),{action:"remove-value",removedValue:e}),t.announceAriaLiveSelection({event:"remove-value",context:{value:e?t.getOptionLabel(e):""}}),t.focusInput()})),er(sr(sr(t)),"clearValue",(function(){var e=t.props.isMulti;t.onChange(e?[]:null,{action:"clear"})})),er(sr(sr(t)),"popValue",(function(){var e=t.state.selectValue,n=e[e.length-1];t.announceAriaLiveSelection({event:"pop-value",context:{value:n?t.getOptionLabel(n):""}}),t.onChange(e.slice(0,e.length-1),{action:"pop-value",removedValue:n})})),er(sr(sr(t)),"getOptionLabel",(function(e){return t.props.getOptionLabel(e)})),er(sr(sr(t)),"getOptionValue",(function(e){return t.props.getOptionValue(e)})),er(sr(sr(t)),"getStyles",(function(e,n){var r=Eo[e](n);r.boxSizing="border-box";var o=t.props.styles[e];return o?o(r,n):r})),er(sr(sr(t)),"getElementId",(function(e){return"".concat(t.instancePrefix,"-").concat(e)})),er(sr(sr(t)),"getActiveDescendentId",(function(){var e=t.props.menuIsOpen,n=t.state,r=n.menuOptions,o=n.focusedOption;if(o&&e){var a=r.focusable.indexOf(o),i=r.render[a];return i&&i.key}})),er(sr(sr(t)),"announceAriaLiveSelection",(function(e){var n=e.event,r=e.context;t.setState({ariaLiveSelection:Qr(n,r)})})),er(sr(sr(t)),"announceAriaLiveContext",(function(e){var n=e.event,r=e.context;t.setState({ariaLiveContext:Jr(n,nr({},r,{label:t.props["aria-label"]}))})})),er(sr(sr(t)),"onMenuMouseDown",(function(e){0===e.button&&(e.stopPropagation(),e.preventDefault(),t.focusInput())})),er(sr(sr(t)),"onMenuMouseMove",(function(e){t.blockOptionHover=!1})),er(sr(sr(t)),"onControlMouseDown",(function(e){var n=t.props.openMenuOnClick;t.state.isFocused?t.props.menuIsOpen?"INPUT"!==e.target.tagName&&t.onMenuClose():n&&t.openMenu("first"):(n&&(t.openAfterFocus=!0),t.focusInput()),"INPUT"!==e.target.tagName&&e.preventDefault()})),er(sr(sr(t)),"onDropdownIndicatorMouseDown",(function(e){if(!(e&&"mousedown"===e.type&&0!==e.button||t.props.isDisabled)){var n=t.props,r=n.isMulti,o=n.menuIsOpen;t.focusInput(),o?(t.inputIsHiddenAfterUpdate=!r,t.onMenuClose()):t.openMenu("first"),e.preventDefault(),e.stopPropagation()}})),er(sr(sr(t)),"onClearIndicatorMouseDown",(function(e){e&&"mousedown"===e.type&&0!==e.button||(t.clearValue(),e.stopPropagation(),t.openAfterFocus=!1,setTimeout((function(){return t.focusInput()})))})),er(sr(sr(t)),"onScroll",(function(e){"boolean"==typeof t.props.closeMenuOnScroll?e.target instanceof HTMLElement&&fr(e.target)&&t.props.onMenuClose():"function"==typeof t.props.closeMenuOnScroll&&t.props.closeMenuOnScroll(e)&&t.props.onMenuClose()})),er(sr(sr(t)),"onCompositionStart",(function(){t.isComposing=!0})),er(sr(sr(t)),"onCompositionEnd",(function(){t.isComposing=!1})),er(sr(sr(t)),"onTouchStart",(function(e){var n=e.touches.item(0);n&&(t.initialTouchX=n.clientX,t.initialTouchY=n.clientY,t.userIsDragging=!1)})),er(sr(sr(t)),"onTouchMove",(function(e){var n=e.touches.item(0);if(n){var r=Math.abs(n.clientX-t.initialTouchX),o=Math.abs(n.clientY-t.initialTouchY);t.userIsDragging=r>5||o>5}})),er(sr(sr(t)),"onTouchEnd",(function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)})),er(sr(sr(t)),"onControlTouchEnd",(function(e){t.userIsDragging||t.onControlMouseDown(e)})),er(sr(sr(t)),"onClearIndicatorTouchEnd",(function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)})),er(sr(sr(t)),"onDropdownIndicatorTouchEnd",(function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)})),er(sr(sr(t)),"handleInputChange",(function(e){var n=e.currentTarget.value;t.inputIsHiddenAfterUpdate=!1,t.onInputChange(n,{action:"input-change"}),t.onMenuOpen()})),er(sr(sr(t)),"onInputFocus",(function(e){var n=t.props,r=n.isSearchable,o=n.isMulti;t.props.onFocus&&t.props.onFocus(e),t.inputIsHiddenAfterUpdate=!1,t.announceAriaLiveContext({event:"input",context:{isSearchable:r,isMulti:o}}),t.setState({isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1})),er(sr(sr(t)),"onInputBlur",(function(e){t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur"}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))})),er(sr(sr(t)),"onOptionHover",(function(e){t.blockOptionHover||t.state.focusedOption===e||t.setState({focusedOption:e})})),er(sr(sr(t)),"shouldHideSelectedOptions",(function(){var e=t.props,n=e.hideSelectedOptions,r=e.isMulti;return void 0===n?r:n})),er(sr(sr(t)),"onKeyDown",(function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,a=n.escapeClearsValue,i=n.inputValue,s=n.isClearable,l=n.isDisabled,c=n.menuIsOpen,u=n.onKeyDown,d=n.tabSelectsValue,p=n.openMenuOnFocus,m=t.state,f=m.focusedOption,h=m.focusedValue,g=m.selectValue;if(!(l||"function"==typeof u&&(u(e),e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||i)return;t.focusValue("previous");break;case"ArrowRight":if(!r||i)return;t.focusValue("next");break;case"Delete":case"Backspace":if(i)return;if(h)t.removeValue(h);else{if(!o)return;r?t.popValue():s&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!c||!d||!f||p&&t.isOptionSelected(f,g))return;t.selectOption(f);break;case"Enter":if(229===e.keyCode)break;if(c){if(!f)return;if(t.isComposing)return;t.selectOption(f);break}return;case"Escape":c?(t.inputIsHiddenAfterUpdate=!1,t.onInputChange("",{action:"menu-close"}),t.onMenuClose()):s&&a&&t.clearValue();break;case" ":if(i)return;if(!c){t.openMenu("first");break}if(!f)return;t.selectOption(f);break;case"ArrowUp":c?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":c?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!c)return;t.focusOption("pageup");break;case"PageDown":if(!c)return;t.focusOption("pagedown");break;case"Home":if(!c)return;t.focusOption("first");break;case"End":if(!c)return;t.focusOption("last");break;default:return}e.preventDefault()}}));var r=e.value;t.cacheComponents=Cn(t.cacheComponents,Tr).bind(sr(sr(t))),t.cacheComponents(e.components),t.instancePrefix="react-select-"+(t.props.instanceId||++wo);var o=mr(r),a=t.buildMenuOptions(e,o);return t.state.menuOptions=a,t.state.selectValue=o,t}return rr(n,e),Xn(n,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput()}},{key:"componentWillReceiveProps",value:function(e){var t=this.props,n=t.options,r=t.value,o=t.inputValue;if(this.cacheComponents(e.components),e.value!==r||e.options!==n||e.inputValue!==o){var a=mr(e.value),i=this.buildMenuOptions(e,a),s=this.getNextFocusedValue(a),l=this.getNextFocusedOption(i.focusable);this.setState({menuOptions:i,selectValue:a,focusedOption:l,focusedValue:s})}null!=this.inputIsHiddenAfterUpdate&&(this.setState({inputIsHidden:this.inputIsHiddenAfterUpdate}),delete this.inputIsHiddenAfterUpdate)}},{key:"componentDidUpdate",value:function(e){var t,n,r,o,a,i=this.props,s=i.isDisabled,l=i.menuIsOpen,c=this.state.isFocused;(c&&!s&&e.isDisabled||c&&l&&!e.menuIsOpen)&&this.focusInput(),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(t=this.menuListRef,n=this.focusedOptionRef,r=t.getBoundingClientRect(),o=n.getBoundingClientRect(),a=n.offsetHeight/3,o.bottom+a>r.bottom?gr(t,Math.min(n.offsetTop+n.clientHeight-t.offsetHeight+a,t.scrollHeight)):o.top-a<r.top&&gr(t,Math.max(n.offsetTop-a,0))),this.scrollToFocusedOptionOnUpdate=!1}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){var e=this.props,t=e.isSearchable,n=e.isMulti;this.announceAriaLiveContext({event:"input",context:{isSearchable:t,isMulti:n}}),this.onInputChange("",{action:"menu-close"}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this.state,n=t.menuOptions,r=t.selectValue,o=t.isFocused,a=this.props.isMulti,i="first"===e?0:n.focusable.length-1;if(!a){var s=n.focusable.indexOf(r[0]);s>-1&&(i=s)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.inputIsHiddenAfterUpdate=!1,this.onMenuOpen(),this.setState({focusedValue:null,focusedOption:n.focusable[i]}),this.announceAriaLiveContext({event:"menu"})}},{key:"focusValue",value:function(e){var t=this.props,n=t.isMulti,r=t.isSearchable,o=this.state,a=o.selectValue,i=o.focusedValue;if(n){this.setState({focusedOption:null});var s=a.indexOf(i);i||(s=-1,this.announceAriaLiveContext({event:"value"}));var l=a.length-1,c=-1;if(a.length){switch(e){case"previous":c=0===s?0:-1===s?l:s-1;break;case"next":s>-1&&s<l&&(c=s+1)}-1===c&&this.announceAriaLiveContext({event:"input",context:{isSearchable:r,isMulti:n}}),this.setState({inputIsHidden:-1!==c,focusedValue:a[c]})}}}},{key:"focusOption",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state,r=n.focusedOption,o=n.menuOptions.focusable;if(o.length){var a=0,i=o.indexOf(r);r||(i=-1,this.announceAriaLiveContext({event:"menu"})),"up"===e?a=i>0?i-1:o.length-1:"down"===e?a=(i+1)%o.length:"pageup"===e?(a=i-t)<0&&(a=0):"pagedown"===e?(a=i+t)>o.length-1&&(a=o.length-1):"last"===e&&(a=o.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:o[a],focusedValue:null}),this.announceAriaLiveContext({event:"menu",context:{isDisabled:Xr(o[a])}})}}},{key:"getTheme",value:function(){return this.props.theme?"function"==typeof this.props.theme?this.props.theme(ko):nr({},ko,this.props.theme):ko}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.getStyles,n=this.setValue,r=this.selectOption,o=this.props,a=o.classNamePrefix,i=o.isMulti,s=o.isRtl,l=o.options,c=this.state.selectValue,u=this.hasValue();return{cx:pr.bind(null,a),clearValue:e,getStyles:t,getValue:function(){return c},hasValue:u,isMulti:i,isRtl:s,options:l,selectOption:r,setValue:n,selectProps:o,theme:this.getTheme()}}},{key:"getNextFocusedValue",value:function(e){if(this.clearFocusValueOnUpdate)return this.clearFocusValueOnUpdate=!1,null;var t=this.state,n=t.focusedValue,r=t.selectValue.indexOf(n);if(r>-1){if(e.indexOf(n)>-1)return n;if(r<e.length)return e[r]}return null}},{key:"getNextFocusedOption",value:function(e){var t=this.state.focusedOption;return t&&e.indexOf(t)>-1?t:e[0]}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.state.menuOptions.render.length}},{key:"countOptions",value:function(){return this.state.menuOptions.focusable.length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return"function"==typeof this.props.isOptionDisabled&&this.props.isOptionDisabled(e,t)}},{key:"isOptionSelected",value:function(e,t){var n=this;if(t.indexOf(e)>-1)return!0;if("function"==typeof this.props.isOptionSelected)return this.props.isOptionSelected(e,t);var r=this.getOptionValue(e);return t.some((function(e){return n.getOptionValue(e)===r}))}},{key:"filterOption",value:function(e,t){return!this.props.filterOption||this.props.filterOption(e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"==typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"buildMenuOptions",value:function(e,t){var n=this,r=e.inputValue,o=void 0===r?"":r,a=e.options,i=function(e,r){var a=n.isOptionDisabled(e,t),i=n.isOptionSelected(e,t),s=n.getOptionLabel(e),l=n.getOptionValue(e);if(!(n.shouldHideSelectedOptions()&&i||!n.filterOption({label:s,value:l,data:e},o))){var c=a?void 0:function(){return n.onOptionHover(e)},u=a?void 0:function(){return n.selectOption(e)},d="".concat(n.getElementId("option"),"-").concat(r);return{innerProps:{id:d,onClick:u,onMouseMove:c,onMouseOver:c,tabIndex:-1},data:e,isDisabled:a,isSelected:i,key:d,label:s,type:"option",value:l}}};return a.reduce((function(e,t,r){if(t.options){n.hasGroups||(n.hasGroups=!0);var o=t.options.map((function(t,n){var o=i(t,"".concat(r,"-").concat(n));return o&&e.focusable.push(t),o})).filter(Boolean);if(o.length){var a="".concat(n.getElementId("group"),"-").concat(r);e.render.push({type:"group",key:a,data:t,options:o})}}else{var s=i(t,"".concat(r));s&&(e.render.push(s),e.focusable.push(t))}return e}),{render:[],focusable:[]})}},{key:"constructAriaLiveMessage",value:function(){var e=this.state,t=e.ariaLiveContext,n=e.selectValue,r=e.focusedValue,o=e.focusedOption,a=this.props,i=a.options,s=a.menuIsOpen,l=a.inputValue,c=a.screenReaderStatus,u=r?function(e){var t=e.focusedValue,n=e.selectValue;return"value ".concat((0,e.getOptionLabel)(t)," focused, ").concat(n.indexOf(t)+1," of ").concat(n.length,".")}({focusedValue:r,getOptionLabel:this.getOptionLabel,selectValue:n}):"",d=o&&s?function(e){var t=e.focusedOption,n=e.options;return"option ".concat((0,e.getOptionLabel)(t)," focused").concat(t.isDisabled?" disabled":"",", ").concat(n.indexOf(t)+1," of ").concat(n.length,".")}({focusedOption:o,getOptionLabel:this.getOptionLabel,options:i}):"",p=function(e){var t=e.inputValue;return"".concat(e.screenReaderMessage).concat(t?" for search term "+t:"",".")}({inputValue:l,screenReaderMessage:c({count:this.countOptions()})});return"".concat(u," ").concat(d," ").concat(p," ").concat(t)}},{key:"renderInput",value:function(){var e=this.props,n=e.isDisabled,r=e.isSearchable,o=e.inputId,a=e.inputValue,i=e.tabIndex,s=this.components.Input,l=this.state.inputIsHidden,c=o||this.getElementId("input");if(!r)return t().createElement(Rr,{id:c,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:ur,onFocus:this.onInputFocus,readOnly:!0,disabled:n,tabIndex:i,value:""});var u={"aria-autocomplete":"list","aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"]},d=this.commonProps,p=d.cx,m=d.theme,f=d.selectProps;return t().createElement(s,tr({autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",cx:p,getStyles:this.getStyles,id:c,innerRef:this.getInputRef,isDisabled:n,isHidden:l,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,selectProps:f,spellCheck:"false",tabIndex:i,theme:m,type:"text",value:a},u))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,n=this.components,r=n.MultiValue,o=n.MultiValueContainer,a=n.MultiValueLabel,i=n.MultiValueRemove,s=n.SingleValue,l=n.Placeholder,c=this.commonProps,u=this.props,d=u.controlShouldRenderValue,p=u.isDisabled,m=u.isMulti,f=u.inputValue,h=u.placeholder,g=this.state,b=g.selectValue,v=g.focusedValue,y=g.isFocused;if(!this.hasValue()||!d)return f?null:t().createElement(l,tr({},c,{key:"placeholder",isDisabled:p,isFocused:y}),h);if(m)return b.map((function(n){var s=n===v;return t().createElement(r,tr({},c,{components:{Container:o,Label:a,Remove:i},isFocused:s,isDisabled:p,key:e.getOptionValue(n),removeProps:{onClick:function(){return e.removeValue(n)},onTouchEnd:function(){return e.removeValue(n)},onMouseDown:function(e){e.preventDefault(),e.stopPropagation()}},data:n}),e.formatOptionLabel(n,"value"))}));if(f)return null;var E=b[0];return t().createElement(s,tr({},c,{data:E,isDisabled:p}),this.formatOptionLabel(E,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.components.ClearIndicator,n=this.commonProps,r=this.props,o=r.isDisabled,a=r.isLoading,i=this.state.isFocused;if(!this.isClearable()||!e||o||!this.hasValue()||a)return null;var s={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return t().createElement(e,tr({},n,{innerProps:s,isFocused:i}))}},{key:"renderLoadingIndicator",value:function(){var e=this.components.LoadingIndicator,n=this.commonProps,r=this.props,o=r.isDisabled,a=r.isLoading,i=this.state.isFocused;return e&&a?t().createElement(e,tr({},n,{innerProps:{"aria-hidden":"true"},isDisabled:o,isFocused:i})):null}},{key:"renderIndicatorSeparator",value:function(){var e=this.components,n=e.DropdownIndicator,r=e.IndicatorSeparator;if(!n||!r)return null;var o=this.commonProps,a=this.props.isDisabled,i=this.state.isFocused;return t().createElement(r,tr({},o,{isDisabled:a,isFocused:i}))}},{key:"renderDropdownIndicator",value:function(){var e=this.components.DropdownIndicator;if(!e)return null;var n=this.commonProps,r=this.props.isDisabled,o=this.state.isFocused,a={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return t().createElement(e,tr({},n,{innerProps:a,isDisabled:r,isFocused:o}))}},{key:"renderMenu",value:function(){var e=this,n=this.components,r=n.Group,o=n.GroupHeading,a=n.Menu,i=n.MenuList,s=n.MenuPortal,l=n.LoadingMessage,c=n.NoOptionsMessage,u=n.Option,d=this.commonProps,p=this.state,m=p.focusedOption,f=p.menuOptions,h=this.props,g=h.captureMenuScroll,b=h.inputValue,v=h.isLoading,y=h.loadingMessage,E=h.minMenuHeight,k=h.maxMenuHeight,_=h.menuIsOpen,w=h.menuPlacement,S=h.menuPosition,O=h.menuPortalTarget,C=h.menuShouldBlockScroll,x=h.menuShouldScrollIntoView,A=h.noOptionsMessage,I=h.onMenuScrollToTop,P=h.onMenuScrollToBottom;if(!_)return null;var T,N=function(n){var r=m===n.data;return n.innerRef=r?e.getFocusedOptionRef:void 0,t().createElement(u,tr({},d,n,{isFocused:r}),e.formatOptionLabel(n.data,"menu"))};if(this.hasOptions())T=f.render.map((function(n){if("group"===n.type){n.type;var a=ir(n,["type"]),i="".concat(n.key,"-heading");return t().createElement(r,tr({},d,a,{Heading:o,headingProps:{id:i},label:e.formatGroupLabel(n.data)}),n.options.map((function(e){return N(e)})))}if("option"===n.type)return N(n)}));else if(v){var D=y({inputValue:b});if(null===D)return null;T=t().createElement(l,d,D)}else{var L=A({inputValue:b});if(null===L)return null;T=t().createElement(c,d,L)}var F={minMenuHeight:E,maxMenuHeight:k,menuPlacement:w,menuPosition:S,menuShouldScrollIntoView:x},j=t().createElement(Er,tr({},d,F),(function(n){var r=n.ref,o=n.placerProps,s=o.placement,l=o.maxHeight;return t().createElement(a,tr({},d,F,{innerRef:r,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove},isLoading:v,placement:s}),t().createElement(Zr,{isEnabled:g,onTopArrive:I,onBottomArrive:P},t().createElement($r,{isEnabled:C},t().createElement(i,tr({},d,{innerRef:e.getMenuListRef,isLoading:v,maxHeight:l}),T))))}));return O||"fixed"===S?t().createElement(s,tr({},d,{appendTo:O,controlElement:this.controlRef,menuPlacement:w,menuPosition:S}),j):j}},{key:"renderFormField",value:function(){var e=this,n=this.props,r=n.delimiter,o=n.isDisabled,a=n.isMulti,i=n.name,s=this.state.selectValue;if(i&&!o){if(a){if(r){var l=s.map((function(t){return e.getOptionValue(t)})).join(r);return t().createElement("input",{name:i,type:"hidden",value:l})}var c=s.length>0?s.map((function(n,r){return t().createElement("input",{key:"i-".concat(r),name:i,type:"hidden",value:e.getOptionValue(n)})})):t().createElement("input",{name:i,type:"hidden"});return t().createElement("div",null,c)}var u=s[0]?this.getOptionValue(s[0]):"";return t().createElement("input",{name:i,type:"hidden",value:u})}}},{key:"renderLiveRegion",value:function(){return this.state.isFocused?t().createElement(jr,{"aria-live":"assertive"},t().createElement("p",{id:"aria-selection-event"}," ",this.state.ariaLiveSelection),t().createElement("p",{id:"aria-context"}," ",this.constructAriaLiveMessage())):null}},{key:"render",value:function(){var e=this.components,n=e.Control,r=e.IndicatorsContainer,o=e.SelectContainer,a=e.ValueContainer,i=this.props,s=i.className,l=i.id,c=i.isDisabled,u=i.menuIsOpen,d=this.state.isFocused,p=this.commonProps=this.getCommonProps();return t().createElement(o,tr({},p,{className:s,innerProps:{id:l,onKeyDown:this.onKeyDown},isDisabled:c,isFocused:d}),this.renderLiveRegion(),t().createElement(n,tr({},p,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:c,isFocused:d,menuIsOpen:u}),t().createElement(a,tr({},p,{isDisabled:c}),this.renderPlaceholderOrValue(),this.renderInput()),t().createElement(r,tr({},p,{isDisabled:c}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}]),n}(e.Component);er(So,"defaultProps",_o);var Oo={defaultInputValue:"",defaultMenuIsOpen:!1,defaultValue:null},Co=function(n){var r,o;return o=r=function(e){function r(){var e,t;Jn(this,r);for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];return er(sr(sr(t=lr(this,(e=or(r)).call.apply(e,[this].concat(o))))),"select",void 0),er(sr(sr(t)),"state",{inputValue:void 0!==t.props.inputValue?t.props.inputValue:t.props.defaultInputValue,menuIsOpen:void 0!==t.props.menuIsOpen?t.props.menuIsOpen:t.props.defaultMenuIsOpen,value:void 0!==t.props.value?t.props.value:t.props.defaultValue}),er(sr(sr(t)),"onChange",(function(e,n){t.callProp("onChange",e,n),t.setState({value:e})})),er(sr(sr(t)),"onInputChange",(function(e,n){var r=t.callProp("onInputChange",e,n);t.setState({inputValue:void 0!==r?r:e})})),er(sr(sr(t)),"onMenuOpen",(function(){t.callProp("onMenuOpen"),t.setState({menuIsOpen:!0})})),er(sr(sr(t)),"onMenuClose",(function(){t.callProp("onMenuClose"),t.setState({menuIsOpen:!1})})),t}return rr(r,e),Xn(r,[{key:"focus",value:function(){this.select.focus()}},{key:"blur",value:function(){this.select.blur()}},{key:"getProp",value:function(e){return void 0!==this.props[e]?this.props[e]:this.state[e]}},{key:"callProp",value:function(e){if("function"==typeof this.props[e]){for(var t,n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return(t=this.props)[e].apply(t,r)}}},{key:"render",value:function(){var e=this,r=this.props,o=(r.defaultInputValue,r.defaultMenuIsOpen,r.defaultValue,ir(r,["defaultInputValue","defaultMenuIsOpen","defaultValue"]));return t().createElement(n,tr({},o,{ref:function(t){e.select=t},inputValue:this.getProp("inputValue"),menuIsOpen:this.getProp("menuIsOpen"),onChange:this.onChange,onInputChange:this.onInputChange,onMenuClose:this.onMenuClose,onMenuOpen:this.onMenuOpen,value:this.getProp("value")}))}}]),r}(e.Component),er(r,"defaultProps",Oo),o},xo={cacheOptions:!1,defaultOptions:!1,filterOption:null},Ao=function(n){var r,o;return o=r=function(e){function r(e){var t;return Jn(this,r),er(sr(sr(t=lr(this,or(r).call(this)))),"select",void 0),er(sr(sr(t)),"lastRequest",void 0),er(sr(sr(t)),"mounted",!1),er(sr(sr(t)),"optionsCache",{}),er(sr(sr(t)),"handleInputChange",(function(e,n){var r=t.props,o=r.cacheOptions,a=function(e,t,n){if(n){var r=n(e,t);if("string"==typeof r)return r}return e}(e,n,r.onInputChange);if(!a)return delete t.lastRequest,void t.setState({inputValue:"",loadedInputValue:"",loadedOptions:[],isLoading:!1,passEmptyOptions:!1});if(o&&t.optionsCache[a])t.setState({inputValue:a,loadedInputValue:a,loadedOptions:t.optionsCache[a],isLoading:!1,passEmptyOptions:!1});else{var i=t.lastRequest={};t.setState({inputValue:a,isLoading:!0,passEmptyOptions:!t.state.loadedInputValue},(function(){t.loadOptions(a,(function(e){t.mounted&&(e&&(t.optionsCache[a]=e),i===t.lastRequest&&(delete t.lastRequest,t.setState({isLoading:!1,loadedInputValue:a,loadedOptions:e||[],passEmptyOptions:!1})))}))}))}return a})),t.state={defaultOptions:Array.isArray(e.defaultOptions)?e.defaultOptions:void 0,inputValue:void 0!==e.inputValue?e.inputValue:"",isLoading:!0===e.defaultOptions,loadedOptions:[],passEmptyOptions:!1},t}return rr(r,e),Xn(r,[{key:"componentDidMount",value:function(){var e=this;this.mounted=!0;var t=this.props.defaultOptions,n=this.state.inputValue;!0===t&&this.loadOptions(n,(function(t){if(e.mounted){var n=!!e.lastRequest;e.setState({defaultOptions:t||[],isLoading:n})}}))}},{key:"componentWillReceiveProps",value:function(e){e.cacheOptions!==this.props.cacheOptions&&(this.optionsCache={}),e.defaultOptions!==this.props.defaultOptions&&this.setState({defaultOptions:Array.isArray(e.defaultOptions)?e.defaultOptions:void 0})}},{key:"componentWillUnmount",value:function(){this.mounted=!1}},{key:"focus",value:function(){this.select.focus()}},{key:"blur",value:function(){this.select.blur()}},{key:"loadOptions",value:function(e,t){var n=this.props.loadOptions;if(!n)return t();var r=n(e,t);r&&"function"==typeof r.then&&r.then(t,(function(){return t()}))}},{key:"render",value:function(){var e=this,r=this.props,o=(r.loadOptions,ir(r,["loadOptions"])),a=this.state,i=a.defaultOptions,s=a.inputValue,l=a.isLoading,c=a.loadedInputValue,u=a.loadedOptions,d=a.passEmptyOptions?[]:s&&c?u:i||[];return t().createElement(n,tr({},o,{ref:function(t){e.select=t},options:d,isLoading:l,onInputChange:this.handleInputChange}))}}]),r}(e.Component),er(r,"defaultProps",xo),o},Io=(Ao(Co(So)),function(){var e=arguments.length>1?arguments[1]:void 0,t=String(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").toLowerCase(),n=String(e.value).toLowerCase(),r=String(e.label).toLowerCase();return n===t||r===t}),Po=nr({allowCreateWhileLoading:!1,createOptionPosition:"last"},{formatCreateLabel:function(e){return'Create "'.concat(e,'"')},isValidNewOption:function(e,t,n){return!(!e||t.some((function(t){return Io(e,t)}))||n.some((function(t){return Io(e,t)})))},getNewOptionData:function(e,t){return{label:t,value:e,__isNew__:!0}}}),To=function(n){var r,o;return o=r=function(e){function r(e){var t;Jn(this,r),er(sr(sr(t=lr(this,or(r).call(this,e)))),"select",void 0),er(sr(sr(t)),"onChange",(function(e,n){var r=t.props,o=r.getNewOptionData,a=r.inputValue,i=r.isMulti,s=r.onChange,l=r.onCreateOption,c=r.value;if("select-option"!==n.action)return s(e,n);var u=t.state.newOption,d=Array.isArray(e)?e:[e];if(d[d.length-1]!==u)s(e,n);else if(l)l(a);else{var p=o(a,a);s(i?[].concat(cr(mr(c)),[p]):p,{action:"create-option"})}}));var n=e.options||[];return t.state={newOption:void 0,options:n},t}return rr(r,e),Xn(r,[{key:"componentWillReceiveProps",value:function(e){var t=e.allowCreateWhileLoading,n=e.createOptionPosition,r=e.formatCreateLabel,o=e.getNewOptionData,a=e.inputValue,i=e.isLoading,s=e.isValidNewOption,l=e.value,c=e.options||[],u=this.state.newOption;u=s(a,mr(l),c)?o(a,r(a)):void 0,this.setState({newOption:u,options:!t&&i||!u?c:"first"===n?[u].concat(cr(c)):[].concat(cr(c),[u])})}},{key:"focus",value:function(){this.select.focus()}},{key:"blur",value:function(){this.select.blur()}},{key:"render",value:function(){var e=this,r=tr({},this.props),o=this.state.options;return t().createElement(n,tr({},r,{ref:function(t){e.select=t},options:o,onChange:this.onChange}))}}]),r}(e.Component),er(r,"defaultProps",Po),o},No=Co(To(So)),Do=(Ao(Co(To(So))),function(e){var n=e.component,r=e.duration,o=void 0===r?1:r,a=e.in,i=(e.onExited,ir(e,["component","duration","in","onExited"])),s={entering:{opacity:0},entered:{opacity:1,transition:"opacity ".concat(o,"ms")},exiting:{opacity:0},exited:{opacity:0}};return t().createElement(Yn.Transition,{mountOnEnter:!0,unmountOnExit:!0,in:a,timeout:o},(function(e){var r={style:nr({},s[e])};return t().createElement(n,tr({innerProps:r},i))}))}),Lo=function(e){function n(){var e,t;Jn(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return er(sr(sr(t=lr(this,(e=or(n)).call.apply(e,[this].concat(o))))),"duration",260),er(sr(sr(t)),"rafID",void 0),er(sr(sr(t)),"state",{width:"auto"}),er(sr(sr(t)),"transition",{exiting:{width:0,transition:"width ".concat(t.duration,"ms ease-out")},exited:{width:0}}),er(sr(sr(t)),"getWidth",(function(e){e&&isNaN(t.state.width)&&(t.rafID=window.requestAnimationFrame((function(){var n=e.getBoundingClientRect().width;t.setState({width:n})})))})),er(sr(sr(t)),"getStyle",(function(e){return{overflow:"hidden",whiteSpace:"nowrap",width:e}})),er(sr(sr(t)),"getTransition",(function(e){return t.transition[e]})),t}return rr(n,e),Xn(n,[{key:"componentWillUnmount",value:function(){this.rafID&&window.cancelAnimationFrame(this.rafID)}},{key:"render",value:function(){var e=this,n=this.props,r=n.children,o=n.in,a=this.state.width;return t().createElement(Yn.Transition,{enter:!1,mountOnEnter:!0,unmountOnExit:!0,in:o,timeout:this.duration},(function(n){var o=nr({},e.getStyle(a),e.getTransition(n));return t().createElement("div",{ref:e.getWidth,style:o},r)}))}}]),n}(e.Component),Fo=function(e){return function(n){var r=n.in,o=n.onExited,a=ir(n,["in","onExited"]);return t().createElement(Lo,{in:r,onExited:o},t().createElement(e,tr({cropWithEllipsis:r},a)))}},jo=function(e){return function(n){return t().createElement(Do,tr({component:e,duration:n.isMulti?260:1},n))}},Ro=function(e){return function(n){return t().createElement(Do,tr({component:e},n))}},Mo=function(e){return function(n){return t().createElement(Yn.TransitionGroup,tr({component:e},n))}},Bo=function(){var e,n=yo({components:arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}}),r=n.Input,o=n.MultiValue,a=n.Placeholder,i=n.SingleValue,s=n.ValueContainer,l=ir(n,["Input","MultiValue","Placeholder","SingleValue","ValueContainer"]);return nr({Input:(e=r,function(n){n.in,n.onExited,n.appear,n.enter,n.exit;var r=ir(n,["in","onExited","appear","enter","exit"]);return t().createElement(e,r)}),MultiValue:Fo(o),Placeholder:jo(a),SingleValue:Ro(i),ValueContainer:Mo(s)},l)},Vo=Bo();Vo.Input,Vo.MultiValue,Vo.Placeholder,Vo.SingleValue,Vo.ValueContainer,Cn(Bo,Tr);const Ho=Co(So);function zo(t){const{headline:n,content:r,children:o}=t,a=mn()("form-section","stellarwp","stellarwp-body",{"has-children":o});return(0,e.createElement)("div",{className:a},n?(0,e.createElement)("h2",{className:"form-section__headline stellarwp-h2"},n):null,r?(0,e.createElement)("p",{className:"form-section__content stellarwp-small stellarwp-disabled"},r):null,o||null)}function Uo(t){const{icon:n,text:r="",value:o="",selected:a,onClick:i=()=>{}}=t,s=mn()("location-select-card",{"is-selected":a});return(0,e.createElement)(ln.Card,{className:s,as:"button",size:"small",isRounded:!0,onClick:()=>i(o)},(0,e.createElement)(ln.CardHeader,null,n?(0,e.createElement)(ln.Icon,{icon:n}):null),(0,e.createElement)(ln.CardBody,null,r))}function Wo(t){const{label:n,locations:r=[],selected:o,onChange:a=()=>{}}=t;return(0,e.createElement)(ln.Flex,{className:"location-select-control",direction:"column"},n?(0,e.createElement)("label",{className:"location-select-control__label"},n):null,(0,e.createElement)(ln.Flex,{className:"location-select-control__group",align:"initial"},r&&r.map((t=>(0,e.createElement)(ln.FlexBlock,null,(0,e.createElement)(Uo,{selected:o===t.value,icon:t.icon,text:t.text,value:t.value,onClick:a}))))))}(0,r.forwardRef)((function(t,n){const{maxMenuHeight:r,menuPlacement:o,label:a,options:i,value:s,prefix:l,...c}=t,u=mn()("components-input-control__container",{"has-prefix":!!l});return(0,e.createElement)("div",{className:"stellarwp components-creatable-control"},a?(0,e.createElement)("label",{className:"components-input-control__label"},a):null,(0,e.createElement)("div",{className:u,ref:n},l||null,(0,e.createElement)(No,{classNamePrefix:"stellarwp-creatable",maxMenuHeight:r,menuPlacement:o,styles:{control:(e,t)=>({...e,fontSize:16,boxShadow:"none",borderColor:t.isFocused?"#000000":"#DFDFDF"}),valueContainer:e=>({...e,paddingLeft:l?35:8}),menu:e=>({...e,fontSize:16}),indicatorsContainer:e=>({...e,color:"#000000"})},isClearable:!0,options:i,value:s,...c})))}));const qo={featuredTitle:(0,o.__)("Featured Images","kadence-blocks"),featuredDescription:(0,o.__)("Featured images are meant to draw attention, they are used to represent the content on your website.","kadence-blocks"),backgroundTitle:(0,o.__)("Background Images","kadence-blocks"),backgroundDescription:(0,o.__)("Background images are meant to enhance the overall look and feel, styling the background of sections in your website.","kadence-blocks")},Go={wrapper:{boxSizing:"border-box",maxWidth:1e3,margin:"auto"}};function Ko({loading:t,featured:n,background:r,updateCollection:o}){const a=e=>t=>{o(e,t)};return(0,e.createElement)("div",{className:"stellarwp-body",style:Go.wrapper},(0,e.createElement)(ln.Flex,{align:"top",gap:"5"},(0,e.createElement)(ln.FlexBlock,null,(0,e.createElement)(ka,{loading:t,photos:n?.images,isLocal:n?.isLocal,collectionLink:n?.pexelLink,title:qo.featuredTitle,description:qo.featuredDescription,updateCollection:a(0)})),(0,e.createElement)(ln.FlexBlock,null,(0,e.createElement)(ka,{loading:t,photos:r?.images,isLocal:r?.isLocal,collectionLink:r?.pexelLink,title:qo.backgroundTitle,description:qo.backgroundDescription,updateCollection:a(1)}))))}function $o(t){const{styles:n={},value:o,message:a,color:i}=t,[s,l]=(0,r.useState)({}),c={};return(0,r.useEffect)((()=>{const e=o-100;l((t=>({...t,backgroundColor:i||"blue",transform:`translateX(${e}%)`})))}),[o,i,a]),void 0!==o&&(c["aria-valuenow"]=Math.round(o),c["aria-valuemin"]=0,c["aria-valuemax"]=100),(0,e.createElement)("div",{className:"stellarwp-progress-bar",style:n},(0,e.createElement)("div",{className:"stellarwp-progress-bar__wrap",...c},(0,e.createElement)("span",{className:"stellarwp-progress-bar__bar",style:s})),a?(0,e.createElement)("span",{className:"stellarwp-progress-bar__message",style:{color:i||"inherit"}},a):null)}const Yo=(0,r.forwardRef)((function(t,n){const{maxMenuHeight:r,menuPlacement:o,menuPosition:a="absolute",isClearable:i,label:s,options:l,value:c,horizontal:u,...d}=t;return(0,e.createElement)("div",{className:"stellarwp components-select-control "+(u?"input-control-horizontal":"")},s?(0,e.createElement)("label",{className:"components-input-control__label"},s):null,(0,e.createElement)("div",{className:"components-input-control__container",ref:n},(0,e.createElement)(Ho,{classNamePrefix:"stellarwp-select",maxMenuHeight:r,menuPlacement:o,menuPosition:a,styles:{control:(e,t)=>({...e,fontSize:16,boxShadow:"none",borderColor:t.isFocused?"#000000":"#DFDFDF",width:"100%"}),valueContainer:e=>({...e,paddingLeft:16}),menu:e=>({...e,fontSize:16}),indicatorsContainer:e=>({...e,color:"#000000"})},isClearable:i,options:l,value:c,...d})))}));var Zo=n(220);function Jo({icon:t,...n}){return(0,e.createElement)("button",{...n},(0,e.createElement)("span",{role:"img","aria-label":"Arrow"},(0,e.createElement)(ln.Dashicon,{icon:t})))}function Qo(t){return(0,e.createElement)(Jo,{...t,icon:"arrow-left-alt2"})}function Xo(t){return(0,e.createElement)(Jo,{...t,icon:"arrow-right-alt2"})}function ea(t){const{slides:n=[],text:r,backgroundImage:o,doAfterSlide:a=()=>{},doBeforeSlide:i=()=>{}}=t;if(!n.length)return;const s=mn()("stellarwp-slider",{"has-background":o});return(0,e.createElement)("div",{className:s,style:{backgroundImage:`url(${o})`}},r?(0,e.createElement)("span",{className:"stellarwp-slider__text",align:"center"},r):null,(0,e.createElement)(Zo.A,{infiniteLoop:!0,ArrowLeft:Qo,ArrowRight:Xo,doAfterSlide:a,doBeforeSlide:i},n.map((e=>e))))}function ta(t){return(0,e.createElement)(ln.TextControl,{className:"stellarwp",...t})}const na=(0,r.forwardRef)((function(t,n){return(0,e.createElement)("div",{ref:n},(0,e.createElement)(ln.TextareaControl,{className:"stellarwp",...t}))}));function ra(t){const{progressBarProps:n,value:a,initialHeight:i=300,aiLoading:s,aiSuggestion:l,onUndo:c,onAccept:u,...d}=t,[p,m]=(0,r.useState)(null);return(0,r.useEffect)((()=>{p&&function(e){if(e){const t=e.querySelector("textarea");t.style.height="0px";const n=t.scrollHeight>i?t.scrollHeight:i;t.style.height=n+"px"}}(p)}),[p,a]),(0,e.createElement)("div",{className:"stellarwp-textarea-progress "+(l?"stellarwp-textarea-progress--suggestion-active":"")},(0,e.createElement)(na,{ref:m,...d,value:l||a}),!(l||s)&&(0,e.createElement)("div",{className:"stellarwp-ai-about-character-limits"},a.length,"/1000"),!l&&(0,e.createElement)($o,{...n}),(l||s)&&(0,e.createElement)(ln.Flex,{className:"stellarwp-textarea-progress__actions"},s&&(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)(ln.__experimentalView,{className:"stellarwp-textarea-progress__ai-loading"},(0,e.createElement)(ln.Icon,{icon:yn}),`${(0,o.__)("Kadence AI is writing","kadence-blocks")}`,(0,e.createElement)(ln.Icon,{icon:vn}))),l&&!s&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)(ln.Button,{className:"stellarwp-textarea-progress__undo-button",variant:"link",onClick:c},`${(0,o.__)("Undo","kadence-blocks")}`)),(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)(ln.Button,{className:"stellarwp-textarea-progress__approve-button",icon:bn,variant:"link",onClick:u},`${(0,o.__)("Use This Copy","kadence-blocks")}`)))))}function oa(t){const{label:n,description:r}=t;return(0,e.createElement)("div",{className:"tone-select__option"},(0,e.createElement)("b",null,n,"."),r?` ${r}`:null)}(0,r.forwardRef)((function(t,n){const{maxMenuHeight:r,menuPlacement:o,options:a=[],value:i,...s}=t;if(a.length)return(0,e.createElement)("div",{ref:n},(0,e.createElement)(Ho,{maxMenuHeight:r,menuPlacement:o,classNamePrefix:"stellarwp-tone",value:i,options:a,getOptionLabel:t=>(0,e.createElement)(oa,{...t}),...s}))}));const aa=window.wp.dom;function ia(t){const{pageNumber:n,isComplete:r=!1}=t,o=mn()("stellarwp","step-count",{"is-complete":r}),a=r?(0,e.createElement)(ln.Icon,{icon:"saved"}):n;return(0,e.createElement)("span",{className:o},a)}const sa=window.wp.apiFetch;var la=n.n(sa);function ca(){const[e,t]=(0,r.useState)(!1),[n,o]=(0,r.useState)(!1);return{loading:e,error:n,saveAiWizardData:async function(e){t(!0),o(!1);try{if(await la()({path:"/wp/v2/settings",method:"POST",data:{kadence_blocks_prophecy:JSON.stringify(e)}}))return t(!1),!0}catch(e){const n=e?.message?e.message:e;return console.log(`ERROR: ${n}`),t(!1),o(!0),!1}},getAiWizardData:async function(){t(!0),o(!1);try{const e=await la()({path:"/wp/v2/settings",method:"GET"});if(e&&(t(!1),e?.kadence_blocks_prophecy))return e.kadence_blocks_prophecy}catch(e){const n=e?.message?e.message:e;return console.log(`ERROR: ${n}`),t(!1),o(!0),{}}}}}function ua({className:t,contentLabel:n,logo:a,backButtonText:i=(0,o.__)("Back","kadence-blocks"),forwardButtonText:s=(0,o.__)("Next","kadence-blocks"),backButtonDisabled:l=!1,forwardButtonDisabled:c=!1,onPageChange:u=()=>{},onClose:d=()=>{},onPrimaryClick:p=()=>{},primaryButtonText:m=(0,o.__)("Save","kadence-blocks"),primaryButtonDisabled:f=!1,onSecondaryClick:h,secondaryButtonText:g,credits:b="",photographyOnly:v,pages:y=[],isFullScreen:E=!1}){const k=(0,r.useRef)(null),[_,w]=(0,r.useState)(0),[S,O]=(0,r.useState)(new Set),{saveAiWizardData:C}=ca();(0,r.useEffect)((()=>{u&&u(_),k.current&&aa.focus.tabbable.find(k.current)[0]?.focus()}),[_]);const x=y&&y?.[_]?.id?y[_].id:`page-${_}`,A=_>0,I=_<y.length-1,P=e=>S.has(e),{state:T,dispatch:N}=R();return 0===y.length?null:(0,e.createElement)(ln.Modal,{title:a,className:mn()("components-guide","stellarwp",t,x,{"is-fullscreen":E}),contentLabel:n,onRequestClose:d,ref:k},(0,e.createElement)("div",{className:"components-guide__container"},(0,e.createElement)("div",{className:"components-guide__page"},y[_].image,y[_].content)),(0,e.createElement)("div",{className:"components-guide__footer"},A&&(0,e.createElement)(dn,{className:"components-wizard__back-button",disabled:l,onClick:()=>{A&&w(_-1)}},i),y.length>1&&(0,e.createElement)("ul",{className:"components-guide__page-control","aria-label":(0,o.__)("Guide controls","kadence-blocks")},y.map(((t,n)=>{return(0,e.createElement)("li",{key:n,"aria-current":n===_?"step":void 0},(0,e.createElement)(dn,{key:n,className:mn()("wizard-step",{"is-complete":P(n),"is-current":n===_}),disabled:(r=n,r>S.size||null),icon:(0,e.createElement)(ia,{pageNumber:n+1,isComplete:P(n),isSelected:n===_}),"aria-label":(0,o.sprintf)(/* translators: 1: current page number 2: total number of pages */ /* translators: 1: current page number 2: total number of pages */ (0,o.__)("Page %1$d of %2$d","kadence-blocks"),n+1,y.length),text:t.step,onClick:()=>w(n)}));var r}))),I&&(0,e.createElement)(dn,{variant:"primary",className:"components-wizard__forward-button",disabled:c,onClick:async function(){if(!I)return;N({type:"SET_SAVING",payload:!0});const{firstTime:e,saving:t,saveError:n,...r}=T;await C({firstTime:!1,...r})&&(N({type:"SET_SAVING",payload:!1}),w(_+1),O((e=>{const t=new Set(e.values());return t.add(_),t})))}},s),!I&&(0,e.createElement)("div",{className:"components-wizard__finish-button-container"},h&&"function"==typeof h?(0,e.createElement)(dn,{variant:"link",className:"components-wizard__secondary-button",onClick:h},g||""):null,v&&(0,e.createElement)(dn,{variant:"primary",className:"components-wizard__primary-button",disabled:f,onClick:p},m),!v&&(0,e.createElement)("div",{className:"kt-generate-wrap"},(0,e.createElement)(dn,{variant:"primary",className:"components-wizard__primary-button",disabled:f,onClick:p},m+" "+(0,o.__)("(70 Credits)","kadence-blocks"))))))}const da=window.wp.data,pa=[],ma=()=>{const{wp:e}=window;return e.media.view.MediaFrame.Select.extend({featuredImageToolbar(t){this.createSelectToolbar(t,{text:e.media.view.l10n.setFeaturedImage,state:this.options.state})},editState(){const t=this.state("featured-image").get("selection"),n=new e.media.view.EditImage({model:t.single(),controller:this}).render();this.content.set(n),n.loadEditor()},createStates:function(){this.on("toolbar:create:featured-image",this.featuredImageToolbar,this),this.on("content:render:edit-image",this.editState,this),this.states.add([new e.media.controller.FeaturedImage,new e.media.controller.EditImage({model:this.options.editImage})])}})},fa=()=>{const{wp:e}=window;return e.media.view.MediaFrame.Post.extend({galleryToolbar(){const t=this.state().get("editing");this.toolbar.set(new e.media.view.Toolbar({controller:this,items:{insert:{style:"primary",text:t?(0,o.__)("Update Collection","kadence-blocks"):(0,o.__)("Create Collection","kadence-blocks"),priority:80,requires:{library:!0},click(){const e=this.controller,t=e.state();e.close(),t.trigger("update",t.get("library")),e.setState(e.options.state),e.reset()}}}}))},galleryEditToolbar(){const t=this.state().get("editing");this.toolbar.set(new e.media.view.Toolbar({controller:this,items:{insert:{style:"primary",text:t?(0,o.__)("Update Collection","kadence-blocks"):(0,o.__)("Add to Collection","kadence-blocks"),priority:80,requires:{library:!0},click(){const e=this.controller,t=e.state();e.close(),t.trigger("update",t.get("library")),e.setState(e.options.state),e.reset()}}}}))},galleryAddToolbar(){this.toolbar.set(new e.media.view.Toolbar({controller:this,items:{insert:{style:"primary",text:(0,o.__)("Add to Collection","kadence-blocks"),priority:80,requires:{selection:!0},click(){const e=this.controller,t=e.state();e.state("gallery-edit").get("library").add(t.get("selection").models),t.trigger("reset"),e.setState("gallery-edit"),this.controller.modal.focusManager.focus()}}}}))},editState(){const t=this.state("gallery").get("selection"),n=new e.media.view.EditImage({model:t.single(),controller:this}).render();this.content.set(n),n.loadEditor()},createStates:function(){this.on("toolbar:create:main-gallery",this.galleryToolbar,this),this.on("toolbar:create:gallery-add",this.galleryAddToolbar,this),this.on("toolbar:create:gallery-edit",this.galleryEditToolbar,this),this.on("content:render:edit-image",this.editState,this),this.states.add([new e.media.controller.Library({id:"gallery",title:(0,o.__)("Create Collection","kadence-blocks"),priority:40,toolbar:"main-gallery",filterable:"uploaded",multiple:"add",editable:!1,library:e.media.query({type:"image",...this.options.library})}),new e.media.controller.EditImage({model:this.options.editImage}),new e.media.controller.GalleryEdit({title:(0,o.__)("Edit Collection","kadence-blocks"),library:this.options.selection,editing:this.options.editing,menu:"gallery",displaySettings:!1,multiple:!0}),new e.media.controller.GalleryAdd({title:(0,o.__)("Add to Collection","kadence-blocks")})])}})},ha=e=>["sizes","mime","type","subtype","id","url","alt","link","caption"].reduce(((t,n)=>(e?.hasOwnProperty(n)&&(t[n]=e[n]),t)),{}),ga=e=>{const{wp:t}=window;return t.media.query({order:"ASC",orderby:"post__in",post__in:e,posts_per_page:-1,query:!0,type:"image"})};class ba extends r.Component{constructor({allowedTypes:e,gallery:t=!1,unstableFeaturedImageFlow:n=!1,modalClass:r,multiple:a=!1,title:i=(0,o.__)("Select or Upload Media")}){super(...arguments),this.openModal=this.openModal.bind(this),this.onOpen=this.onOpen.bind(this),this.onSelect=this.onSelect.bind(this),this.onUpdate=this.onUpdate.bind(this),this.onClose=this.onClose.bind(this);const{wp:s}=window;if(t)this.buildAndSetGalleryFrame();else{const t={title:i,multiple:a};e&&(t.library={type:e}),this.frame=s.media(t)}r&&this.frame.$el.addClass(r),n&&this.buildAndSetFeatureImageFrame(),this.initializeListeners()}initializeListeners(){this.frame.on("select",this.onSelect),this.frame.on("update",this.onUpdate),this.frame.on("open",this.onOpen),this.frame.on("close",this.onClose)}buildAndSetGalleryFrame(){const{addToGallery:e=!1,allowedTypes:t,multiple:n=!1,value:r=pa}=this.props;if(r===this.lastGalleryValue)return;const{wp:o}=window;let a;this.lastGalleryValue=r,this.frame&&this.frame.remove(),a=e?"gallery-library":r&&r.length?"gallery-edit":"gallery",this.GalleryDetailsMediaFrame||(this.GalleryDetailsMediaFrame=fa());const i=ga(r),s=new o.media.model.Selection(i.models,{props:i.props.toJSON(),multiple:n});this.frame=new this.GalleryDetailsMediaFrame({mimeType:t,state:a,multiple:n,selection:s,editing:!(!r||!r.length)}),o.media.frame=this.frame,this.initializeListeners()}buildAndSetFeatureImageFrame(){const{wp:e}=window,t=ma(),n=ga(this.props.value),r=new e.media.model.Selection(n.models,{props:n.props.toJSON()});this.frame=new t({mimeType:this.props.allowedTypes,state:"featured-image",multiple:this.props.multiple,selection:r,editing:!!this.props.value}),e.media.frame=this.frame}componentWillUnmount(){this.frame.remove()}onUpdate(e){const{onSelect:t,multiple:n=!1}=this.props,r=this.frame.state(),o=e||r.get("selection");o&&o.models.length&&t(n?o.models.map((e=>ha(e.toJSON()))):ha(o.models[0].toJSON()))}onSelect(){const{onSelect:e,multiple:t=!1}=this.props,n=this.frame.state().get("selection").toJSON();e(t?n:n[0])}onOpen(){const{wp:e}=window,{value:t}=this.props;if(this.updateCollection(),this.props.mode&&this.frame.content.mode(this.props.mode),!(Array.isArray(t)?t?.length:t))return;const n=this.props.gallery,r=this.frame.state().get("selection"),o=Array.isArray(t)?t:[t];n||o.forEach((t=>{r.add(e.media.attachment(t))}));const a=ga(o);a.more().done((function(){n&&a?.models?.length&&r.add(a.models)}))}onClose(){const{onClose:e}=this.props;e&&e()}updateCollection(){const e=this.frame.content.get();if(e&&e.collection){const t=e.collection;t.toArray().forEach((e=>e.trigger("destroy",e))),t.mirroring._hasMore=!0,t.more()}}openModal(){this.props.gallery&&this.buildAndSetGalleryFrame(),this.frame.open()}render(){return this.props.render({open:this.openModal})}}const va=ba,ya={wrapper:{boxSizing:"border-box",width:"100%",padding:32,paddingBottom:"16px",marginLeft:"auto",marginRight:"auto",border:"1px solid #DFDFDF",borderRadius:"4px",display:"flex",flexDirection:"column",gap:"24px"},gridWrapper:{maxHeight:"318px",height:"500px",overflow:"hidden",overflowY:"auto",marginRight:"-8px",paddingRight:"9px",position:"relative"},loading:{position:"absolute",inset:"0 0 0 0",backgroundColor:"rgba(255,255,255,0.95)",display:"flex",alignItems:"center",justifyContent:"center",zIndex:1},grid:{display:"grid",gridTemplateColumns:"1fr 1fr 1fr 1fr",gap:"16px"},square:{position:"relative",width:"100%",height:"100%",backgroundColor:"#fcfcfc",backgroundSize:"cover",aspectRatio:"1/1"},placeholder:{background:"#F5F5F5",height:"100%",width:"100%",zIndex:2},img:{objectFit:"cover",objectPosition:"center",width:"100%",position:"relative",zIndex:2,aspectRatio:"1/1"},linkWrapper:{paddingTop:16,textAlign:"center",borderTop:"1px solid #DFDFDF"},contentWrapper:{gap:8,textAlign:"center"},title:{fontSize:"14px",fontWeight:600},description:{fontSize:"14px",marginTop:"8px"},importWrapper:{position:"relative",marginBottom:"-24px"},importNotice:{position:"absolute",top:"0",width:"100%",height:"318px",backgroundColor:"rgba(255,255,255,0.9)",display:"flex",fontSize:"18px",alignItems:"center",justifyContent:"center",zIndex:11},spinner:{marginRight:"8px",marginLeft:"8px",marginTop:"4px",marginBottom:"4px"}},Ea=["image"];function ka({photos:t,loading:n,isLocal:a,collectionLink:i,title:s,description:l,updateCollection:c}){const u=function(e){const[t,n]=(0,r.useState)();return(0,r.useEffect)((()=>{if(!e)return void n([]);const t=e.length;if(t<12){const r=12-t,o=[...e,...Array.from(Array(r)).map(((e,t)=>({alt:`placeholder${t+1}`})))];n(o)}else n(e)}),[e]),t}(t),[d,p]=(0,r.useState)(!1),[m,f]=(0,r.useState)([]),[h,g]=(0,r.useState)([]);return(0,r.useEffect)((()=>{if(t){const e=[];t.forEach((function(t){e.push(t.id)})),g(e)}else g([])}),[t]),(0,e.createElement)("div",{style:ya.wrapper},(0,e.createElement)("div",{style:ya.contentWrapper},(0,e.createElement)("div",{style:ya.title},s," "),(0,e.createElement)("div",{style:ya.description},l)),(0,e.createElement)("div",{style:ya.importWrapper,className:"kb-images-custom-import"},n&&(0,e.createElement)("div",{style:ya.importNotice,className:"kb-importing-information"},(0,e.createElement)(ln.Spinner,{style:ya.spinner})," ",(0,o.__)("Loading…","kadence-blocks")),d&&(0,e.createElement)("div",{style:ya.importNotice,className:"kb-importing-information"},(0,e.createElement)(ln.Spinner,{style:ya.spinner})," ",(0,o.__)("Importing Images…","kadence-blocks"))),(0,e.createElement)("div",{style:ya.gridWrapper,className:"kb-images-custom-scroll-bar"},(0,e.createElement)("div",{style:ya.grid},u&&u.length>0?u.map(((t,n)=>(0,e.createElement)(ln.FlexBlock,{style:ya.square,key:n},(0,e.createElement)(ln.FlexBlock,{className:"loading-behind-image",style:ya.loading},(0,e.createElement)(ln.Spinner,null)),t?.sizes?(0,e.createElement)("img",{style:ya.img,alt:t.alt,src:t?.sizes?.[0]?.src?t.sizes[0].src:t?.url}):(0,e.createElement)(ln.FlexBlock,{style:{...ya.square,...ya.placeholder},key:t.alt})))):Array.from("123456789ABC").map((t=>(0,e.createElement)(ln.FlexBlock,{style:{...ya.square,...ya.placeholder},key:t}))))),(0,e.createElement)(ln.Flex,null,(0,e.createElement)(ln.FlexBlock,{style:ya.linkWrapper},(0,e.createElement)(va,{onSelect:e=>function(e){const t=e.map((e=>({id:e.id,post_id:e.id,alt:e.alt||e.name,url:e?.sizes?.large?.url||e?.sizes?.full?.url,sizes:[{name:"thumbnail",src:e?.sizes?.thumbnail?.url||e?.sizes?.large?.url||e?.sizes?.full?.url}]})));c(t)}(e),allowedTypes:Ea,multiple:!0,gallery:!0,title:"Edit Collection",value:h,render:({open:n})=>(0,e.createElement)(dn,{variant:"link",disabled:d,text:(0,o.__)("Edit Collection","kadence-blocks"),onClick:()=>function(e){d||(!a&&t?.length>0?async function(e){p(!0);const n=await async function(e){try{return await la()({path:"/kb-design-library/v1/process_images",method:"POST",data:{images:e}})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),!1}}(t);if(!1!==n){const t=[];n.forEach((function(e){t.push(e.id)})),g(t),setTimeout((function(){e(),p(!1)}),100)}else p(!1)}(e):e())}(n),style:{fontSize:"14px"}})}))))}const _a=function(e){let{icon:t,size:n=24,...o}=e;return(0,r.cloneElement)(t,{width:n,height:n,...o})},wa=(0,r.createElement)(i.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},(0,r.createElement)(i.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"})),Sa=(0,r.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(i.Path,{d:"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"})),Oa=({onComplete:t,onCancel:n})=>{const[o,a]=(0,r.useState)(null);return(0,e.createElement)("div",{className:"advanced-select-menu__input"},(0,e.createElement)("input",{className:"advanced-select-menu__input-item",onChange:e=>a(e.target.value),onKeyDown:function(e){e.stopPropagation(),"Enter"===e.key&&t(o)},placeholder:"Rename this collection",autoFocus:!0,onClick:function(e){e.stopPropagation()}}),(0,e.createElement)("div",{className:"advanced-select-menu__option-item__actions is-edit"},(0,e.createElement)(dn,{size:"small",variant:"link",onClick:n},"Cancel"),(0,e.createElement)(dn,{size:"small",variant:"primary",onClick:function(e){e.stopPropagation(),t(o)}},"Save")))},Ca=(0,e.createElement)("svg",{viewBox:"0 0 18 18",fill:"none"},(0,e.createElement)("path",{d:"M2.25 12.9374V15.7499H5.0625L13.3575 7.45492L10.545 4.64242L2.25 12.9374ZM15.5325 5.27992C15.825 4.98742 15.825 4.51492 15.5325 4.22242L13.7775 2.46742C13.485 2.17492 13.0125 2.17492 12.72 2.46742L11.3475 3.83992L14.16 6.65242L15.5325 5.27992Z",fill:"currentColor"})),xa=(0,e.createElement)("svg",{viewBox:"0 0 18 18",fill:"none"},(0,e.createElement)("path",{d:"M4.5 14.25C4.5 15.075 5.175 15.75 6 15.75H12C12.825 15.75 13.5 15.075 13.5 14.25V5.25H4.5V14.25ZM6 6.75H12V14.25H6V6.75ZM11.625 3L10.875 2.25H7.125L6.375 3H3.75V4.5H14.25V3H11.625Z",fill:"currentColor"})),Aa=(0,e.createElement)("svg",{viewBox:"0 0 18 16",fill:"none"},(0,e.createElement)("path",{d:"M6.99984 10.1458L8.04315 7.87665L10.3123 6.83333L8.04315 5.79002L6.99984 3.52083L5.95653 5.79002L3.68734 6.83333L5.95653 7.87665L6.99984 10.1458ZM6.99984 13.1667L5.02067 8.8125L0.666504 6.83333L5.02067 4.85417L6.99984 0.5L8.979 4.85417L13.3332 6.83333L8.979 8.8125L6.99984 13.1667ZM14.1665 15.5L13.1873 13.3125L10.9998 12.3333L13.1873 11.3333L14.1665 9.16667L15.1665 11.3333L17.3332 12.3333L15.1665 13.3125L14.1665 15.5Z",fill:"currentColor"})),Ia=({option:t,onOptionSelect:n,isActive:o,doNotClose:a})=>{const[i,s]=(0,r.useState)("default"),{updateRecord:l,deleteRecord:c}=(0,r.useContext)(Ta);(0,r.useEffect)((()=>{a("default"!==i)}),[i]);const u=e=>t=>{t.stopPropagation(),s(e)};return(0,e.createElement)("div",{className:`advanced-select-menu__option-item${o?" is-active":""}${t.useActions?" use-actions":""}`},"edit"!==i&&(0,e.createElement)("div",{className:"advanced-select-menu__option-item__label",onClick:e=>n(t)},"aiGenerated"===t.value&&(0,e.createElement)(_a,{icon:Aa,size:17}),t.label),"default"===i&&t.useActions&&(0,e.createElement)("div",{className:"advanced-select-menu__option-item__actions is-icons"},(0,e.createElement)(_a,{icon:Ca,size:17,onClick:u("edit")}),(0,e.createElement)(_a,{icon:xa,size:17,onClick:u("delete")})),"edit"===i&&(0,e.createElement)(Oa,{onComplete:function(e){l(e||t.label,t.value),s("default")},onCancel:u("default")}),"delete"===i&&(0,e.createElement)("div",{className:"advanced-select-menu__option-item__actions is-delete"},(0,e.createElement)(dn,{size:"small",variant:"link",onClick:u("default")},"Cancel"),(0,e.createElement)(dn,{size:"small",isDestructive:!0,onClick:function(e){e.stopPropagation(),c(t.value),s("default")}},"Delete Collection")))},Pa=function(t){const{width:n,options:a,onSelect:i,value:s,allowClose:l}=t,{createRecord:c}=(0,r.useContext)(Ta),[u,d]=(0,r.useState)([]),[p,m]=(0,r.useState)(!1);(0,r.useEffect)((()=>{a&&a.length>0&&d(a.reduce(((e,t)=>t.options&&0!==t.options.length?[...e,t]:e),[]))}),[a]);const f=e=>t=>{t.stopPropagation(),m(e)};function h(e){i(e)}return(0,e.createElement)("div",{className:"stellarwp advanced-select-menu",style:{width:n}},p?(0,e.createElement)("div",{className:"advanced-select-menu__create-input"},(0,e.createElement)(Oa,{onComplete:function(e){c(e),m(!1)},onCancel:f(!1)})):(0,e.createElement)(dn,{className:"advanced-select-menu__create",onClick:f(!0)},(0,o.__)("Make My Own Collection","kadence-blocks"),(0,e.createElement)(_a,{icon:Sa,size:20})),u&&u.length>0&&u.map((t=>(0,e.createElement)("div",{className:"advanced-select-menu__option-wrapper",key:t.label},(0,e.createElement)("div",{className:"advanced-select-menu__option-category"},t.label),t.options.map((t=>(0,e.createElement)(Ia,{key:t.value,option:t,onOptionSelect:h,isActive:s===t.value,doNotClose:e=>l(!e)})))))))},Ta=(0,r.createContext)({}),Na=(0,r.forwardRef)((function(t,n){const{value:o,label:a,options:i,onChange:s,createRecord:l,updateRecord:c,deleteRecord:u}=t,[d,p]=(0,r.useState)("auto"),[m,f]=(0,r.useState)(!1),[h,g]=(0,r.useState)(!0),b=(0,r.useRef)();function v(e){e.stopPropagation(),b?.current&&e?.target&&!b.current.contains(e.target)&&h&&f(!1)}function y(){}return(0,r.useEffect)((()=>{b&&b.current&&p(b.current.clientWidth-32+"px")}),[b]),(0,r.useEffect)((()=>(document.addEventListener("click",v),()=>{document.removeEventListener("click",v)})),[h]),(0,e.createElement)(Ta.Provider,{value:{createRecord:l,updateRecord:c,deleteRecord:u}},(0,e.createElement)("div",{className:"stellarwp components-advanced-select",ref:n},a&&(0,e.createElement)("label",{className:"components-input-control__label"},a),(0,e.createElement)("div",{className:"stellarwp-advancedSelect",ref:b},(0,e.createElement)(dn,{className:m?"is-open":"",onClick:()=>f(!m)},(0,e.createElement)("div",{className:"stellarwp-advancedSelect__button-content"},(0,e.createElement)("div",{className:"stellarwp-advancedSelect__button-label"},o?.label),(0,e.createElement)("div",{className:"stellarwp-advancedSelect__button-icon"},(0,e.createElement)(_a,{size:25,icon:wa}))),m&&(0,e.createElement)(ln.Popover,{placement:"bottom-start",offset:8,animate:!1,className:"stellarwp-advancedSelect__content",onClose:y,onFocusOutside:y},(0,e.createElement)(Pa,{width:d,options:i,onSelect:s,value:o?.value,allowClose:g}))))))}));function Da({items:t=[],selectedItems:n=[],onChange:a}){const[i,s]=(0,r.useState)(t);return(0,r.useEffect)((()=>{s(t)}),[t]),(0,r.useEffect)((()=>{console.log("selectedItems",n)}),[n]),(0,e.createElement)("div",{className:"ai-wizard-button-list"},(0,e.createElement)(ln.ButtonGroup,{className:"ai-wizard-button-list_wrapper"},i.map((t=>(0,e.createElement)("div",{className:"ai-wizard-button-list_item_wrap"},(0,e.createElement)(dn,{className:"ai-wizard-button-list_item"+(n.includes(t.value)?" is-selected":""),onClick:e=>function(e){const t=[...n];console.log("tempSelected",t),console.log("item Selected",e);const r=t.indexOf(e);-1!==r?t.splice(r,1):t.push(e),a(t)}(t.value)},(0,e.createElement)("div",{className:"ai-wizard-button-list_item-icon"},(0,e.createElement)(ln.Icon,{icon:t.icon})),(0,e.createElement)("div",{className:"ai-wizard-button-list_item-content"},(0,e.createElement)("div",{className:"ai-wizard-button-list_item-title-area"},(0,e.createElement)("div",{className:"ai-wizard-button-list_item-title"},t.label)),t.description&&(0,e.createElement)("div",{className:"ai-wizard-button-list_item-description"},t.description)),(0,e.createElement)("div",{className:"ai-wizard-button-list_item-active"},(0,e.createElement)(ln.Icon,{icon:"saved"}),n.length>1&&n[0]===t.value&&(0,e.createElement)("div",{className:"ai-wizard-button-list_item-primary"},(0,o.__)("Primary","kadence-starter-templates")))),n.includes(t.value)&&n.length>1&&n[0]!==t.value&&(0,e.createElement)(dn,{className:"ai-wizard-button-list_item-make-primary",onClick:e=>function(e){const t=[...n];console.log("tempSelected",t),console.log("item Selected",e);const r=t.indexOf(e);if(console.log("item index",r),-1!==r){const[e]=t.splice(r,1);console.log("item",e),t.unshift(e),console.log("return selected",i.filter((e=>t.includes(e.value)))),a(t)}}(t.value)},(0,o.__)("Make Primary","kadence-starter-templates")))))))}const La=n.p+"images/ai-modal-intro.f66e5f62.png",Fa={background:{height:"100%",background:"linear-gradient(90deg, rgba(0, 115, 230, 0) 0, rgba(0, 115, 230, 0) 60%, #0073E6 99.44%)"},headline:{maxWidth:420},content:{maxWidth:480,marginLeft:32},imageWrapper:{overflow:"hidden"},image:{maxHeight:"60vh",borderRadius:8}},ja=(0,o.__)("Elevate Your Website Creation: Design Library + Kadence AI","kadence-blocks"),Ra=(0,o.__)("Introducing Kadence AI, our AI-powered engine for creating websites.","kadence-blocks"),Ma=(0,o.__)("Forget about learning AI - just tell us about yourself, and let Kadence AI take care of the rest. Say goodbye to blank screen anxiety. Welcome effective content that represents your brand.","kadence-blocks");function Ba({children:t}){if(t)return(0,e.createElement)(ln.Card,{isBorderless:!0,size:"large",className:"slide-card"},(0,e.createElement)(ln.CardBody,null,t))}function Va({headline:t,content:n}){return(0,e.createElement)("div",{className:"slide-card-row"},t?(0,e.createElement)("p",{className:"slide-card-row__headline"},(0,e.createElement)("b",null,t)):null,n?(0,e.createElement)("div",{className:"slide-card-row__content"},n):null)}function Ha(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(Va,{headline:(0,o.__)("I am","kadence-blocks"),content:(0,o.__)("An Organization","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Organization Name","kadence-blocks"),content:(0,o.__)("Education 4All","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Where are you based?","kadence-blocks"),content:(0,e.createElement)(e.Fragment,null,(0,e.createElement)("b",null,(0,o.__)("Service Area","kadence-blocks"),": "),(0,o.__)("Latin America","kadence-blocks"))}),(0,e.createElement)(Va,{headline:(0,o.__)("What industry are you in?","kadence-blocks"),content:(0,o.__)("Charity","kadence-blocks")})))}function za(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(Va,{headline:(0,o.__)("I am","kadence-blocks"),content:(0,o.__)("A company","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Company Name","kadence-blocks"),content:(0,o.__)("Healing Touch","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Where are you based?","kadence-blocks"),content:(0,e.createElement)(e.Fragment,null,(0,e.createElement)("b",null,(0,o.__)("Business Address","kadence-blocks"),": "),(0,o.__)("123 Some St., Seattle, Washington","kadence-blocks"))}),(0,e.createElement)(Va,{headline:(0,o.__)("What industry are you in?","kadence-blocks"),content:(0,o.__)("Spa","kadence-blocks")})))}function Ua(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(Va,{headline:(0,o.__)("I am","kadence-blocks"),content:(0,o.__)("A company","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Company Name","kadence-blocks"),content:(0,o.__)("Prospera","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Where are you based?","kadence-blocks"),content:(0,e.createElement)(e.Fragment,null,(0,e.createElement)("b",null,(0,o.__)("Online Only","kadence-blocks")))}),(0,e.createElement)(Va,{headline:(0,o.__)("What industry are you in?","kadence-blocks"),content:(0,o.__)("Professional Services","kadence-blocks")})))}function Wa(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(Va,{headline:(0,o.__)("I am","kadence-blocks"),content:(0,o.__)("An Individual","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Your Name","kadence-blocks"),content:(0,o.__)("Spencer Sharp","kadence-blocks")}),(0,e.createElement)(Va,{headline:(0,o.__)("Where are you based?","kadence-blocks"),content:(0,e.createElement)(e.Fragment,null,(0,e.createElement)("b",null,(0,o.__)("Service Area","kadence-blocks"),": "),(0,o.__)("USA","kadence-blocks"))}),(0,e.createElement)(Va,{headline:(0,o.__)("What industry are you in?","kadence-blocks"),content:(0,o.__)("Coaching","kadence-blocks")})))}const qa={container:{height:"100%"},leftContent:{maxWidth:640,marginInline:"auto"},rightContent:{marginRight:32,height:"100%",display:"flex",flexDirection:"column"},formWrapper:{maxWidth:504,paddingRight:32,paddingLeft:32},inputError:{fontSize:11,color:"red"}},Ga=(0,o.__)("Your Information","kadence-blocks"),Ka=(0,o.__)("Please provide detailed information about yourself, your company, or your organization to enhance the quality of our results.","kadence-blocks"),$a=["Education 4All is a non-profit organization dedicated to providing \n underprivileged children with access to quality education.","Through initiatives like school infrastructure development, teacher \n training, curriculum development, and learning resource provision, we empower \n children, their families, and communities.","Our mission is to break the cycle of poverty by equipping children with the \n tools they need for a brighter future and fostering sustainable development."];function Ya(){return(0,e.createElement)(Ba,null,(0,e.createElement)(Va,{headline:(0,o.__)("Tell us about your organization","kadence-blocks"),content:$a.map(((t,n)=>(0,e.createElement)("p",{key:n},t)))}))}const Za=["Healing Touch is a leading massage therapy business renowned \n for our personalized, holistic treatments offered in a tranquil environment.","Our team of highly skilled therapists seamlessly blends various techniques to \n cater to the unique needs of each individual, offering effective relief from \n tension, pain, and stress.","Our services encompass a wide range of offerings, including Swedish, deep \n tissue, hot stone, and prenatal massage, along with complementary treatments \n like reflexology, acupuncture, and energy work.","With an unwavering commitment to excellence and promoting relaxation, we are \n dedicated to helping our valued clients restore vitality and achieve a \n profound state of deep relaxation."];function Ja(){return(0,e.createElement)(Ba,null,(0,e.createElement)(Va,{headline:(0,o.__)("Tell us about your business","kadence-blocks"),content:Za.map(((t,n)=>(0,e.createElement)("p",{key:n},t)))}))}const Qa=["Prospera is a trusted bookkeeping and accounting services company dedicated \n to helping businesses thrive financially.","We specialize in comprehensive bookkeeping, accurate financial reporting, \n tax preparation, and strategic financial planning.","Our tailored solutions cater to small and medium-sized enterprises, entrepreneurs, and professionals, providing them \n with the unique value of expertise, accuracy, and timely insights.","With Prospera, businesses gain the financial clarity and support they need to make \n informed decisions and achieve long-term prosperity."];function Xa(){return(0,e.createElement)(Ba,null,(0,e.createElement)(Va,{headline:(0,o.__)("Tell us about your business","kadence-blocks"),content:Qa.map(((t,n)=>(0,e.createElement)("p",{key:n},t)))}))}const ei=["I'm Spencer Sharp, a business coach who is genuinely committed to helping \n entrepreneurs and professionals build businesses they are passionate about \n and lead fulfilling lives.","With practical solutions and personalized guidance, I provide the support \n you need to achieve your goals.","Together, we'll work on creating systems for organization, clarity, and \n growth.","I'll empower you to become a strong leader, take control of your finances, \n and develop effective strategies for marketing, lead conversion, and \n customer fulfillment.","I’ll be your guide on this journey to success, ensuring that your business \n thrives while you live a rewarding life."];function ti(){return(0,e.createElement)(Ba,null,(0,e.createElement)(Va,{headline:(0,o.__)("Tell us about yourself","kadence-blocks"),content:ei.map(((t,n)=>(0,e.createElement)("p",{key:n},t)))}))}const ni={container:{height:"100%"},leftContent:{maxWidth:640,marginInline:"auto"},rightContent:{marginRight:32,height:"100%",display:"flex",flexDirection:"column"},formWrapper:{maxWidth:504,paddingRight:32,paddingLeft:32},textareaWrapper:{position:"relative"},tooltip:{position:"absolute",top:16,left:"100%",borderRadius:"0px 4px 4px 0px",padding:12,backgroundColor:"#FAFAFA",width:200,zIndex:1,title:{fontSize:12,fontWeight:600},content:{fontSize:11,lineHeight:"14px",letterSpacing:-.2,listStyle:"disc",paddingLeft:14}}},ri=(0,o.__)("Craft a brief description that explains who you are, your primary attributes and highlight what differentiates you.","kadence-blocks"),oi={COMPANY:` ${(0,o.__)("business","kadence-blocks")}`,INDIVIDUAL:(0,o.__)("self","kadence-blocks"),ORGANIZATION:` ${(0,o.__)("organization","kadence-blocks")}`},ai=window.wp.url;function ii({tone:t,headline:n,content:r}){return(0,e.createElement)("div",{className:"slide-card-row--tone"},t?(0,e.createElement)(fn,{text:`${(0,o.__)("Tone","kadence-blocks")}: ${t}`}):null,n?(0,e.createElement)("p",{className:"slide-card-row__headline"},n):null,r?(0,e.createElement)("p",{className:"slide-card-row__content"},r):null)}function si(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(ii,{tone:(0,o.__)("Professional","kadence-blocks"),headline:(0,o.__)("Elevate Your Well-being with Healing Touch's Expert Care","kadence-blocks"),content:(0,o.__)('"Experience the pinnacle of wellness and rejuvenation as our skilled therapists provide you with expert care and tailored massage therapy at Healing Touch."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Friendly","kadence-blocks"),headline:(0,o.__)("Welcome to Your Personal Oasis","kadence-blocks"),content:(0,o.__)('"Immerse yourself in the ultimate relaxation experience at Healing Touch, where our friendly team of skilled therapists will whisk you away to a serene sanctuary of bliss and rejuvenation."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Informative","kadence-blocks"),headline:(0,o.__)("Discover the Secrets of Blissful Wellness","kadence-blocks"),content:(0,o.__)('"Experience the transformative power of professional massage therapy and unlock a world of relaxation, pain relief, and enhanced well-being at Healing Touch."',"kadence-blocks")})))}function li(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(ii,{tone:(0,o.__)("Engaging","kadence-blocks"),headline:(0,o.__)("Unleash Your Inner Bliss with Healing Touch","kadence-blocks"),content:(0,o.__)('"Discover a transformative sanctuary where your senses will awaken, your spirit will rejuvenate, and your well-being will flourish. Experience the power of Healing Touch today."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Trustworthy","kadence-blocks"),headline:(0,o.__)("Your Path to Trusted Wellness Begins at Healing Touch","kadence-blocks"),content:(0,o.__)('"Experience the highest standard of care and expertise as our dedicated team guides you on your journey to holistic well-being at Healing Touch."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Conversational","kadence-blocks"),headline:(0,o.__)("Let's Find Your Perfect Massage Experience at Healing Touch","kadence-blocks"),content:(0,o.__)('"Ready to discover the ultimate relaxation? Let us guide you in finding the perfect massage tailored to your unique needs at Healing Touch."',"kadence-blocks")})))}function ci(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(ii,{tone:(0,o.__)("Persuasive","kadence-blocks"),headline:(0,o.__)("Embrace the Power of Healing Touch for Unparalleled Relaxation","kadence-blocks"),content:(0,o.__)('"Immerse yourself in a world of relaxation, rejuvenation, and renewed vitality with Healing Touch\'s expert massage therapy, tailored to revitalize your mind, body, and spirit."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Upbeat","kadence-blocks"),headline:(0,o.__)("Elevate Your Senses, Renew Your Spirit","kadence-blocks"),content:(0,o.__)('"Step into a world of pure bliss and let our expert therapists at Healing Touch Spa uplift your spirits and rejuvenate your body with our invigorating massage therapies."',"kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Funny","kadence-blocks"),headline:(0,o.__)("Knead a Laugh? Healing Touch Puts the 'Ahh' in Spa-tacular Massages!","kadence-blocks"),content:(0,o.__)('"Get ready to unwind, untangle, and unleash your inner noodle with Healing Touch\'s hilariously heavenly massages!"',"kadence-blocks")})))}function ui(){return(0,e.createElement)(Ba,null,(0,e.createElement)(ln.__experimentalVStack,{spacing:"6"},(0,e.createElement)(ii,{tone:(0,o.__)("Inspirational","kadence-blocks"),headline:(0,o.__)("Ignite Your Inner Spark, Transform Your Life at Healing","kadence-blocks"),content:(0,o.__)("“Embrace the power of self-care and unlock your body's innate healing potential, as our skilled practitioners rejuvenate your mind, body, and spirit with transformative therapies.\"","kadence-blocks")}),(0,e.createElement)(ii,{tone:(0,o.__)("Neutral","kadence-blocks"),headline:(0,o.__)("Discover the Essence of Healing Touch at Healing Touch Spa","kadence-blocks"),content:(0,o.__)('"Experience a range of therapeutic treatments and indulge in a serene atmosphere, where you can unwind and rejuvenate your body and mind."',"kadence-blocks")})))}const{getSuggestedKeywords:di}={getSuggestedKeywords:async function({name:e,entity_type:t,industry:n,location:r,lang:o,description:i}){try{const s=await la()({path:"/kb-design-library/v1/get_keywords",method:"POST",data:{name:e,entity_type:t?.toLowerCase(),industry:n,location:r,description:i,lang:o||"en-US",count:10}}),l=(0,a.SafeParseJSON)(s,!1);return Promise.resolve(l?.keywords)}catch(e){const t=e?.message?e.message:e;return Promise.reject(t)}}},{getImageSearchQuery:pi}={getImageSearchQuery:async function({name:e,entity_type:t,industry:n,location:r,description:o}){try{const i=await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_search_query"),method:"POST",data:{name:e,entity_type:t?.toLowerCase(),industry:n,location:r,description:o}});console.log("response",i);const s=(0,a.SafeParseJSON)(i,!1);return Promise.resolve(s)}catch(e){const t=e?.message?e.message:e;return Promise.reject(t)}}},mi={container:{height:"100%"},leftContent:{maxWidth:640,marginInline:"auto"},rightContent:{marginRight:32,height:"100%",display:"flex",flexDirection:"column"},formWrapper:{maxWidth:504,paddingRight:32,paddingLeft:32},helperText:{fontSize:12},keywordsLength:{good:"green",poor:"red"}},fi={container:{height:"100%"},leftContent:{maxWidth:940,marginInline:"auto"},rightContent:{marginRight:32,height:"100%",display:"flex",flexDirection:"column"},formWrapper:{paddingRight:32,paddingLeft:32},textareaWrapper:{position:"relative"},image:{borderRadius:"20px",background:`url(${m}) no-repeat center center`,height:"100%",backgroundSize:"cover"}};function hi(){const{state:{customCollections:e,imageSearchQuery:t},dispatch:n}=R(),{loading:i,verticals:s,getPreMadeCollectionByIndustry:l}=function(){const[e,t]=(0,r.useState)(!0),[n,i]=(0,r.useState)([]),[s,l]=(0,r.useState)([]);return(0,r.useEffect)((()=>{t(!0),async function(){try{let e=[];const t=await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_image_collections")}),n=(0,a.SafeParseJSON)(t,!1);n?.data?.collections&&(e=n.data.collections,i(e),sessionStorage.setItem("kadence_ai_collections",JSON.stringify(e)))}catch(e){const t=e?.message?e.message:e;console.log(`ERROR: ${t}`)}finally{t(!1)}}(),async function(){for(let e=0;e<3;e++)try{const e=await la()({path:"/kb-design-library/v1/get_verticals"}),t=(0,a.SafeParseJSON)(e,!1);if(t&&t?.data){let e=t.data.reduce(((e,t)=>[...e,...t.sub_verticals.map((e=>({label:e,value:e})))]),[]);e.sort((function(e,t){return e.label<t.label?-1:e.label>t.label?1:0})),e=e.filter((e=>"Other"!==e.value)),e.unshift({label:(0,o.__)("AI Search Collection","kadence-blocks"),value:"aiGenerated",galleries:[{name:"featured",images:[]},{name:"background",images:[]}]}),l(e),sessionStorage.setItem("kadence_ai_verticals",JSON.stringify(e));break}}catch(e){const t=e?.message?e.message:e;console.log(`ERROR: ${t}`)}t(!1)}()}),[]),{loading:e,verticals:s,getPreMadeCollectionByIndustry:async function(e,t=""){const r=Array.isArray(e)?e:[e];try{const o=await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_images",{industries:r,industry:t,image_type:"JPEG",image_sizes:kadenceExtensionImagePicker.image_sizes})}),i=(0,a.SafeParseJSON)(o,!1);return i&&i?.data?"aiGenerated"===e?[{name:"featured",images:i?.data?.images.slice(0,12)},{name:"background",images:i?.data?.images.slice(12,24)}]:i.data.map((e=>{const t=n.find((t=>t.collection_slug===e.collection_slug));return{name:e.collection_slug,images:e.images,pexelLink:t?.collection_url||""}})):[]}catch(e){const t=e?.message?e.message:e;console.log(`ERROR: ${t}`)}}}}(),[c,u]=(0,r.useState)(!0),[d,p]=(0,r.useState)();return(0,r.useEffect)((()=>{u(!0),function(){if(e)p(e);else{const e=[{label:(0,o.__)("My Images","kadence-blocks"),value:"my-collections",galleries:[{name:"featured",isLocal:!0,images:[]},{name:"background",isLocal:!0,images:[]}]}];p(e)}u(!1)}()}),[]),{loading:!(!c&&!i),preMadeCollections:s,wordpressCollections:d,getCollectionGalleries:async function(e){if(e&&d){if(d&&d.length>0){const t=d.find((t=>t.value===e));if(t)return t.galleries}return await l(e,t)}},updateGalleries:function(e,t){if(!e)return{};let r={};const o=d.findIndex((t=>t.value===e));if(o>-1){const e=[...d];return e[o].galleries=t,n({type:"SET_CUSTOM_COLLECTIONS",payload:e}),p(e),e[o].value}const a=s.find((t=>t.value===e)),i=d.reduce(((t,n)=>n.createdFrom===e&&n.version>t?n.version:t),0);r={label:`${a.label} (Edited${i>0?` ${i+1}`:""})`,value:`${e}_${i}_${(new Date).getTime().toString().slice(-6)}`,createdFrom:e,version:i+1,galleries:t};const l=[r,...d];return n({type:"SET_CUSTOM_COLLECTIONS",payload:l}),p(l),r.value},createCollection:function(e,t){if(!e)return{};const r={label:e,value:`${e.replace(/ /g,"")}_0_${(new Date).getTime().toString().slice(-6)}`,createdFrom:null,version:0,galleries:t},o=[r,...d];return n({type:"SET_CUSTOM_COLLECTIONS",payload:o}),p(o),r.value},updateCollectionName:function(e,t){if(!t||!e)return"";const r=d.findIndex((e=>e.value===t));if(-1===r)return"";const o=[...d];return o[r].label=e,n({type:"SET_CUSTOM_COLLECTIONS",payload:o}),p(o),o[r].value},deleteCollection:function(e){if(!e)return;const t=d.findIndex((t=>t.value===e));if(-1===t)return;const r=[...d];r.splice(t,1),n({type:"SET_CUSTOM_COLLECTIONS",payload:r}),p(r)}}}const gi={topSection:{borderBottom:"1px solid #DFDFDF",marginBottom:"40px",paddingBottom:"24px",position:"relative"},selectWrapper:{maxWidth:500},selectControl:{width:"100%",textAlign:"center"},alignCenter:{alignItems:"center"}};function bi(t){const{photographyOnly:n}=t,{state:{photoLibrary:a,imageSearchQuery:i},dispatch:s}=R(),{preMadeCollections:l,wordpressCollections:c,getCollectionGalleries:u,updateGalleries:d,createCollection:p,updateCollectionName:m,deleteCollection:f}=hi(),[h,g]=(0,r.useState)([]),[b,v]=(0,r.useState)(!1),[y,E]=(0,r.useState)([{},{}]),[k,_]=(0,r.useState)(!1),[w,S]=(0,r.useState)(""),[O,C]=(0,r.useState)(!1),[x,A]=(0,r.useState)();async function I(e=null){if(b)return;v(!0);const t=await u(e||a);t&&E(t),v(!1)}function P(e){let t=e;e?.value&&(t=e.value),t!==a?(s({type:"SET_PHOTO_LIBRARY",payload:t}),s({type:"SET_PHOTO_LIBRARY_CHANGED",payload:!0}),E([{},{}]),I(t)):(s({type:"SET_PHOTO_LIBRARY_CHANGED",payload:!1}),I(t))}(0,r.useEffect)((()=>{s({type:"SET_PHOTO_LIBRARY_CHANGED",payload:!1})}),[]),(0,r.useEffect)((()=>{l&&c&&(g([{label:(0,o.__)("My Collections","kadence-blocks"),options:c.map((e=>({label:e.label,value:e.value,useActions:!0})))},{label:"Premade Collections",options:l.map((e=>({label:e.label,value:e.value,useActions:!1})))}]),I())}),[l,c]),(0,r.useEffect)((()=>{l&&c&&I()}),[i]);const T=a&&l&&l.filter((e=>e.value===a));return(0,e.createElement)("div",{className:"stellarwp-ai-photography-library"},(0,e.createElement)(ln.Flex,{justify:"center",style:gi.topSection},(0,e.createElement)(ln.FlexBlock,{style:gi.selectWrapper},(0,e.createElement)(ln.Flex,{className:"stellarwp-ai-photography-library__selection",direction:"row"},(0,e.createElement)(Na,{label:(0,o.__)("Use Images From:","kadence-blocks"),options:h||[],value:h?.length>0?function(e,t){for(const n of e){const e=n.options.find((e=>e.value===t));if(e)return e}return null}(h,a):"",onChange:e=>{P(e.value)},createRecord:function(e){P(p(e,[{name:"featured",images:[]},{name:"background",images:[]}]))},updateRecord:function(e,t){const n=m(e,t);a===n&&P(n)},deleteRecord:function(e){a===e&&P(h[1].options[0]),f(e)}})))),"aiGenerated"!==a&&(0,e.createElement)(e.Fragment,null,T&&(0,e.createElement)("div",{className:"kb-photography-explained-wrap"},(0,e.createElement)("p",null,(0,o.__)("Fine-tune your collection by selecting 'Edit Collection' below.","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("or -","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("Kickstart your collection with the 'AI Search Collection' or create your own from scratch using the drop-down menu above.","kadence-blocks"))),!T&&(0,e.createElement)("div",{className:"kb-photography-explained-wrap"},(0,e.createElement)("p",null,(0,o.__)("Fine-tune your collection by selecting 'Edit Collection' below.","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("or -","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("Kickstart your collection with the 'AI Search Collection' or explore our pre-made collections using the drop-down menu above.","kadence-blocks")))),"aiGenerated"===a&&(0,e.createElement)("div",{className:"kb-photography-explained-wrap ai-generated-search-edit-wrap"},(0,e.createElement)("p",{className:"ai-generated-search-edit-text"},!n&&(0,o.__)("Ta-Da! We searched the Pexels Image Library to find royalty-free images for your site.","kadence-blocks"),!n&&(0,e.createElement)("br",null),(0,o.__)("You can adjust search terms by clicking","kadence-blocks"),(0,e.createElement)(ln.Button,{variant:"link",disabled:k,ref:A,text:(0,o.__)("Edit AI Search Query","kadence-blocks"),onClick:()=>_(!0),style:{fontSize:"14px"}}),(0,o.__)("or fine-tune your collection by selecting 'Edit Collection' below.","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("or -","kadence-blocks")),(0,e.createElement)("p",null,(0,o.__)("Explore our pre-made collections or create your own from scratch using the drop-down menu above.","kadence-blocks")),k&&(0,e.createElement)(ln.Popover,{onClose:()=>{w&&w!==i&&s({type:"SET_IMAGE_SEARCH_QUERY",payload:w}),_(!1)},placement:"bottom",anchor:x,className:"ai-generated-search-edit-popover-settings"},(0,e.createElement)(ln.TextareaControl,{label:(0,o.__)("Search Query","kadence-blocks"),help:(0,o.__)("Customize the image search query.","kadence-blocks"),value:O?"":""!==w?w:i,onChange:e=>{C(""===e),S(e)},onKeyDown:e=>{e.keyCode===ENTER&&(e.preventDefault(),w&&w!==i&&(s({type:"SET_IMAGE_SEARCH_QUERY",payload:w}),E([{},{}])),_(!1))}}),(0,e.createElement)(ln.Button,{variant:"primary",text:(0,o.__)("Save","kadence-blocks"),onClick:()=>{w&&w!==i&&(s({type:"SET_IMAGE_SEARCH_QUERY",payload:w}),E([{},{}])),_(!1)}}))),(0,e.createElement)(Ko,{loading:b,featured:y[0]||{},background:y[1]||{},updateCollection:function(e,t){const n=[{name:"featured",isLocal:!!y?.[0]?.isLocal,images:y?.[0]?.images},{name:"background",isLocal:!!y?.[1]?.isLocal,images:y?.[1]?.images}];n[e].images=t,n[e].isLocal=!0,function(e){let t=e;e?.value&&(t=e.value),t!==a?(s({type:"SET_PHOTO_LIBRARY",payload:t}),s({type:"SET_PHOTO_LIBRARY_CHANGED",payload:!0}),E([{},{}])):I(t)}(d(a,n))}}))}function vi(e,t){if(!e)throw new Error("useAiWizardHelper requires state");return{isForwardButtonDisabled:function(){const{currentPageIndex:n,locationType:r,locationInput:o,keywords:a,missionStatement:i}=e,s=function(){const n=Array.isArray(t)&&t[e.currentPageIndex]?.required?t[e.currentPageIndex]?.required:[],r=n.filter((t=>"string"==typeof e[t]?e[t].trim().length:Array.isArray(e[t])?e[t].length:"boolean"==typeof e[t]?!!e[t]:void 0));return n.filter((e=>!r.includes(e)))}(),l=t?.[n]?.id;switch(l){case"industry-information":return s.length>0||r!==_&&!o;case"about-your-site":return!(i.length>=200&&i.length<1500&&!(s.length>0));case"the-details":return!(a.length>=5&&!(s.length>0));default:return s.length>0}},isFinishButtonDisabled:function(){const{saving:t}=e;return t}}}const yi="/kb-design-library/v1/get_images",{kadence_blocks_params:Ei}=window;function ki(){const[e,t]=(0,r.useState)(!1),[n,o]=(0,r.useState)(!1),[i,s]=(0,r.useState)(!1),[l,c]=(0,r.useState)(!1);let u=void 0!==Ei&&Ei?.proData&&Ei?.proData?.api_key?Ei.proData.api_key:"",d=void 0!==Ei&&Ei?.proData&&Ei?.proData?.api_email?Ei.proData.api_email:"";const p=void 0!==Ei&&Ei?.proData&&Ei?.proData?.product_id?Ei.proData.product_id:"";return u||(u=void 0!==Ei&&Ei?.proData&&Ei?.proData?.ithemes_key?Ei.proData.ithemes_key:"",u&&(d="iThemes")),{error:l,getAIContentData:async function(e){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get",{context:e})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getLocalAIContentData:async function(){try{return await la()({path:"/kb-design-library/v1/get_all_items"})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getAIContentDataReload:async function(e){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get",{force_reload:!0,context:e})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},saveAIWizardData:async function(e){t(!0),c(!1);try{if(await la()({path:"/wp/v2/settings",method:"POST",data:{kadence_blocks_prophecy:JSON.stringify(e)}}))return t(!1),!0}catch(e){const n=e?.message?e.message:e;return console.log(`ERROR: ${n}`),t(!1),c(!0),!1}},getAIWizardData:async function(e=!1){t(!0),c(!1);const n=!(!window?.kadence_blocks_params_wizard?.settings||!window?.kadence_blocks_params_wizard?.settings?.context)&&window.kadence_blocks_params_wizard.settings;if(!e&&n)return t(!1),console.log("Preloaded Wizard Data"),n;try{const e=await la()({path:"/wp/v2/settings",method:"GET"});if(e&&(t(!1),e?.kadence_blocks_prophecy))return window?.kadence_blocks_params_wizard||(window.kadence_blocks_params_wizard={}),window.kadence_blocks_params_wizard.settings=e.kadence_blocks_prophecy,e.kadence_blocks_prophecy}catch(e){const n=e?.message?e.message:e;return console.log(`ERROR: ${n}`),t(!1),c(!0),{}}},getCollectionByIndustry:async function(e){if(!e?.photoLibrary)return[];const t=!(!e?.customCollections||!e?.customCollections.some((t=>t.value===e?.photoLibrary)))&&e?.customCollections.find((t=>t.value===e?.photoLibrary));if(t){const e={data:[]};if(t?.galleries?.[0]?.images){const n=t?.galleries?.[0]?.images.map(((e,t)=>{const n={};return e?.alt&&(n.alt=e.alt),e?.url&&(n.url=e.url),e?.width&&(n.width=e.width),e?.height&&(n.height=e.height),e?.photographer&&(n.photographer=e.photographer),e?.photographer_url&&(n.photographer_url=e.photographer_url),e?.id&&(n.id=e.id),e?.sizes?.[1]?.src?e.sizes.find((e=>"large"===e.name))?n.sizes=[{src:e.sizes.find((e=>"large"===e.name)).src}]:e.sizes.find((e=>"2048x2048"===e.name))?n.sizes=[{src:e.sizes.find((e=>"2048x2048"===e.name)).src}]:e.sizes.find((e=>"scaled"===e.name))?n.sizes=[{src:e.sizes.find((e=>"scaled"===e.name)).src}]:n.sizes=[{src:e.sizes[1].src}]:n.sizes=[{src:e.url}],n}));e.data.push({images:n})}if(t?.galleries?.[1]?.images){const n=t?.galleries?.[1]?.images.map(((e,t)=>{const n={};return e?.alt&&(n.alt=e.alt),e?.url&&(n.url=e.url),e?.width&&(n.width=e.width),e?.height&&(n.height=e.height),e?.photographer&&(n.photographer=e.photographer),e?.photographer_url&&(n.photographer_url=e.photographer_url),e?.id&&(n.id=e.id),n.sizes=e?.sizes?.[1]?.src?[{src:e.sizes[1].src}]:[{src:e.url}],n}));e.data.push({images:n})}return e}if("aiGenerated"===e?.photoLibrary){const t=Array.isArray(e.photoLibrary)?e?.photoLibrary:[e.photoLibrary];try{const n=await la()({path:(0,ai.addQueryArgs)(yi,{industries:t,industry:e?.imageSearchQuery})}),r=(0,a.SafeParseJSON)(n,!1);return r?{data:[{name:"featured",images:r?.data?.images.slice(0,12)},{name:"background",images:r?.data?.images.slice(12,24)}]}:[]}catch(e){const t=e?.message?e.message:e;console.log(`ERROR: ${t}`)}}const n=Array.isArray(e.photoLibrary)?e?.photoLibrary:[e.photoLibrary];try{const e=await la()({path:(0,ai.addQueryArgs)(yi,{industries:n})});return(0,a.SafeParseJSON)(e,!1)||[]}catch(e){const t=e?.message?e.message:e;console.log(`ERROR: ${t}`)}},getPatterns:async function(e,t,n=null,r=null){if("section"===e&&!t){const e=!!(window?.kadence_blocks_params_library?.library_sections&&window?.kadence_blocks_params_library?.library_sections.length>0)&&window.kadence_blocks_params_library.library_sections;if(e)return console.log("Preloaded Patterns"),e}try{const o=await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_library",{force_reload:t,library:e,library_url:n||"",key:r||e})});return"section"===e&&(window?.kadence_blocks_params_library||(window.kadence_blocks_params_library={}),window.kadence_blocks_params_library.library_sections=o),o}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getPatternCategories:async function(e,t,n=null,r=null){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_library_categories",{force_reload:t,library:e,library_url:n||"",key:r||e})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getPattern:async function(e,t,n,r,o=null,a=null){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_pattern_content",{library:e,library_url:o||"",key:a||e,pattern_id:n||"",pattern_type:t||"",pattern_style:r||"",api_key:u,api_email:d,product_id:p})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},processPattern:async function(e,t="",n=""){try{return await la()({path:"/kb-design-library/v1/process_pattern",method:"POST",data:{content:e,image_library:t,forms:n}})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getLocalAIContexts:async function(){try{return await la()({path:"/kb-design-library/v1/get_local_contexts"})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getInitialAIContent:async function(){try{return await la()({path:"/kb-design-library/v1/get_initial_jobs"})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getAllAIContentData:async function(e=!1){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get-all-ai",{force_reload:e})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getAIContentRemaining:async function(e=!1){try{return await la()({path:(0,ai.addQueryArgs)("/kb-design-library/v1/get_remaining_jobs",{force_reload:e})})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}},getAvailableCredits:async function(){try{return await la()({path:"/kb-design-library/v1/get_remaining_credits"})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"error"}}}}async function _i(e,t){try{return await la()({path:"/kb-design-library/v1/handle_event",method:"POST",data:{event_label:e,event_data:t||{}}})}catch(e){const t=e?.message?e.message:e;return console.log(`ERROR: ${t}`),"failed"}}const wi=[{id:"how-it-works",content:(0,e.createElement)((function(){return(0,e.createElement)(ln.Flex,{style:Fa.background},(0,e.createElement)(ln.Flex,{gap:22.5},(0,e.createElement)(ln.FlexBlock,null,(0,e.createElement)(ln.Flex,{className:"inner",justify:"end"},(0,e.createElement)(ln.FlexBlock,{style:Fa.content,className:"stellarwp-body"},(0,e.createElement)("h1",{className:"stellarwp-h1",style:Fa.headline},ja),(0,e.createElement)("p",null,Ra),(0,e.createElement)("p",null,Ma)))),(0,e.createElement)(ln.FlexBlock,{style:Fa.imageWrapper},(0,e.createElement)("img",{src:La,style:Fa.image}))))}),null),step:"How it Works",required:[]},{id:"industry-information",content:(0,e.createElement)((function(){const[t,n]=(0,r.useState)(null),[a,i]=(0,r.useState)(""),[s,l]=(0,r.useState)(0),{state:c,dispatch:u}=R(),{companyName:d,entityType:p,locationInput:m,lang:f,locationType:h,industry:y}=c;function S(e){return p&&v?.[p]?.[e]?v[p][e]:"..."}return(0,r.useEffect)((()=>{const e=g.filter((e=>e.value===p));e.length&&n(e[0])}),[p]),(0,r.useEffect)((()=>{const e=b.filter((e=>e.value===f));if(e.length)i(e[0]);else{const e=b.filter((e=>"en-US"===e.value));e.length&&i(e[0])}}),[f]),(0,r.useEffect)((()=>{switch(h){case E:return void u({type:"SET_LOCATION",payload:`${E}: ${m}`});case k:u({type:"SET_LOCATION",payload:`${k}: ${m}`})}}),[m,h]),(0,e.createElement)(ln.Flex,{gap:0,align:"normal",style:qa.container},(0,e.createElement)(ln.FlexBlock,{style:{alignSelf:"center"}},(0,e.createElement)(ln.Flex,{justify:"center",style:qa.leftContent},(0,e.createElement)(ln.FlexBlock,{style:qa.formWrapper,className:"stellarwp-body"},(0,e.createElement)(zo,{headline:(0,e.createElement)("span",{className:"has-beta-pill"},(0,o.__)("Your Sites's Language","kadence-blocks")," ",(0,e.createElement)("span",{className:"beta-pill"},"Beta")),content:(0,o.__)("Select your preferred language for AI-generated content on your site. Note: AI content quality varies by language due to available training data; English is best supported.","kadence-blocks")},(0,e.createElement)(ln.__experimentalVStack,{spacing:4,style:{margin:"0 auto 30px"}},(0,e.createElement)(Yo,{label:"",value:a,onChange:function(e){u({type:"SET_LANG",payload:e.value})},options:b}))),(0,e.createElement)(zo,{headline:Ga,content:Ka},(0,e.createElement)(ln.__experimentalVStack,{spacing:4,style:{margin:"0 auto"}},(0,e.createElement)(Yo,{label:(0,o.__)("I am","kadence-blocks"),value:t,onChange:function(e){u({type:"SET_ENTITY_TYPE",payload:e.value})},options:g}),(0,e.createElement)(ta,{label:S("label"),autoFocus:!0,placeholder:S("placeholder"),value:d,onChange:e=>{e&&e.length>75&&(e=e.substring(0,75)),u({type:"SET_COMPANY_NAME",payload:e})}}),(0,e.createElement)(Wo,{label:(0,o.__)("Where are you based?","kadence-blocks"),locations:w,selected:h,onChange:function(e){e===_&&(u({type:"SET_LOCATION",payload:_}),u({type:"SET_LOCATION_TYPE",payload:_})),u({type:"SET_LOCATION_TYPE",payload:e})}}),h&&h!==_?(0,e.createElement)(ta,{label:"Location",placeholder:function(){if(h!==_){const e=w.filter((e=>e.value===h));return e.length&&e[0]?.placeholder?e[0].placeholder:"..."}return"..."}(),value:m,onChange:e=>{e&&e.length>140&&(e=e.substring(0,140)),u({type:"SET_LOCATION_INPUT",payload:e})},help:function(){if(h!==_){const e=w.filter((e=>e.value===h));return e.length&&e[0]?.help?e[0].help:""}return""}()}):null,(0,e.createElement)(un,{label:(0,o.__)("What Industry are you in?","kadence-blocks"),placeholder:(0,o.__)("Find your industry","kadence-blocks"),detachedMediaQuery:"none",onSelect:function(e){e&&e.length>75&&(e=e.substring(0,75)),u({type:"SET_INDUSTRY",payload:e})},currentValue:y||"",initialState:{isOpen:!1,query:y||"",params:{hitsPerPage:8,highlightPreTag:"<mark>",highlightPostTag:"</mark>"}}})))))),(0,e.createElement)(ln.FlexBlock,{display:"flex"},(0,e.createElement)(ln.Flex,{justify:"center"},(0,e.createElement)(ln.FlexBlock,{style:qa.rightContent},(0,e.createElement)(ea,{backgroundImage:O[s],text:(0,o.__)("Not sure where to start? Here's some real life examples!","kadence-blocks"),doBeforeSlide:e=>l(e.nextSlide),slides:[(0,e.createElement)(za,null),(0,e.createElement)(Wa,null),(0,e.createElement)(Ua,null),(0,e.createElement)(Ha,null)]})))))}),null),step:"Industry Information",required:["entityType","companyName","location","industry"]},{id:"about-your-site",content:(0,e.createElement)((function(){const[t,n]=(0,r.useState)(),[a,i]=(0,r.useState)(0),[s,l]=(0,r.useState)(0),[c,u]=(0,r.useState)(!1),[d,p]=(0,r.useState)(""),[m,f]=(0,r.useState)(!1),[g,v]=(0,r.useState)(""),{state:y,dispatch:E}=R(),{missionStatement:k,entityType:_,lang:w,companyName:x}=y,A=(0,o.sprintf)( // translators: %s: entity type // translators: %s: entity type (0,o.__)("Tell us about your %s","kadence-blocks"),oi[_]),I=b.filter((e=>e.value===(w||"en-US"))),P=(0,o.sprintf)( // translators: %s: language // translators: %s: language (0,o.__)("This should be written in %s.","kadence-blocks"),I?.[0]?.label?I[0].label:"your site language"),{getMissionStatement:T}={getMissionStatement:async function(e,t){try{const n=new URL(window.location.href),r=window?.kadence_blocks_params?.proData?.domain?window.kadence_blocks_params.proData.domain:n.hostname;let o=window?.kadence_blocks_params?.proData?.api_key?window.kadence_blocks_params.proData.api_key:"";o||(o=window?.kadenceHomeParams?.apiKey?window.kadenceHomeParams.apiKey:"");let a=window?.kadence_blocks_params?.site_name?window.kadence_blocks_params.site_name:"";a||(a=window?.kadenceHomeParams?.site_name?window.kadenceHomeParams.site_name:"");let i=window?.kadence_blocks_params?.pSlug?window.kadence_blocks_params.pSlug:"";i||(i=window?.kadenceHomeParams?.pSlug?window.kadenceHomeParams.pSlug:"");let s=window?.kadence_blocks_params?.pVersion?window.kadence_blocks_params.pVersion:"";s||(s=window?.kadenceHomeParams?.pVersion?window.kadenceHomeParams.pVersion:"");const l={domain:r,key:o,site_name:a,product_slug:i,product_version:s},c=await fetch("https://content.startertemplatecloud.com/wp-json/prophecy/v1/proxy/intake/improve-mission-statement",{method:"POST",headers:{"Content-Type":"application/json","X-Prophecy-Token":btoa(JSON.stringify(l))},body:JSON.stringify({text:e,lang:t||"en-US",stream:!0})});if(200!==c?.status){if(424===c?.status)return Promise.reject("license");const e=c?.message?c.message:c;return Promise.reject(e)}return c.body}catch(e){const t=e?.message?e.message:e;return Promise.reject(t)}}};return(0,r.useEffect)((()=>{const e=Math.round(k.length/300*100);0==e&&n("initial"),e<50&&e>0&&n("weak"),e>=50&&e<100&&n("medium"),e>=100&&e<200&&n("strong"),e>=200&&e<400&&n("enough"),e>=400&&e<500&&n("less"),e>=500&&n("muchLess"),i(e)}),[k]),(0,e.createElement)(ln.Flex,{gap:0,align:"normal",style:ni.container},(0,e.createElement)(ln.FlexBlock,{style:{alignSelf:"center"}},(0,e.createElement)(ln.Flex,{justify:"center",style:ni.leftContent},(0,e.createElement)(ln.FlexBlock,{style:ni.formWrapper,className:"stellarwp-body"},(0,e.createElement)(zo,{headline:A,content:w&&"en-US"!==w?P+" "+ri:ri},(0,e.createElement)(ln.__experimentalView,{style:ni.textareaWrapper},(0,e.createElement)(ra,{hideLabelFromVision:!0,label:A,placeholder:_===h?(0,o.sprintf)( // translators: %s: company or individual name // translators: %s: company or individual name (0,o.__)("I am %s, a…","kadence-blocks"),x):(0,o.sprintf)( // translators: %s: company or individual name // translators: %s: company or individual name (0,o.__)("%s is a…","kadence-blocks"),x),value:k,onChange:e=>{E({type:"SET_MISSION_STATEMENT",payload:e}),E({type:"SET_IMAGE_SEARCH_QUERY",payload:""})},progressBarProps:{value:a>=100?100:a,color:S?.[t]?.color?S[t].color:"red",message:S?.[t]?.message?S[t].message:""},disabled:d,aiLoading:m,aiSuggestion:d,onUndo:()=>p(""),onAccept:()=>{E({type:"SET_MISSION_STATEMENT",payload:d}),p("")}}),c&&(0,e.createElement)(ln.__experimentalVStack,{style:ni.tooltip},(0,e.createElement)(ln.__experimentalText,{style:ni.tooltip.title},(0,o.__)("Thought Starters","kadence-blocks")),C[_].length>0&&(0,e.createElement)("ul",{style:ni.tooltip.content},C[_].map((t=>(0,e.createElement)("li",{key:t},t)))))),!d&&!m&&(0,e.createElement)(e.Fragment,null,g&&(0,e.createElement)("div",{className:"stellarwp-ai-error-text"},(0,e.createElement)("div",{className:"stellarwp-ai-error-content"},"license"===g?(0,o.__)("Error, license key invalid."):(0,o.__)("Error, AI improve failed, please try again."))),(0,e.createElement)(ln.Flex,{justify:"space-between"},(0,e.createElement)(ln.FlexItem,null,a>=100&&a<400&&(0,e.createElement)(dn,{className:"stellarwp-ai-improve-button",icon:hn,onClick:()=>{return e=k,f(!0),v(""),void T(e,w).then((e=>{const t=e.getReader();t.read().then((function e({done:n,value:r}){if(n)return void f(!1);const o=function(e){const t=(new TextDecoder).decode(e).split("\n"),n={content:""};return t.forEach((e=>{const t=e.indexOf(":");if(-1!==t){const r=e.slice(0,t).trim(),o=e.slice(t+1).trim();if("data"===r&&"content"!==o)try{const e=JSON.parse(o);e.content&&(n.content+=e.content)}catch(e){console.error("Error parsing JSON data:",e)}}})),n}(r);return o?.content&&p((e=>e+o.content)),t.read().then(e)})),f(!1)})).catch((e=>{v("license"===e?"license":"error"),console.log(e),f(!1)}));var e}},(0,o.__)("Improve with AI","kadence-blocks"))),(0,e.createElement)(ln.FlexItem,null,(0,e.createElement)(dn,{size:"small",className:"stellarwp-show-tips-button",icon:c?kn:En,iconPosition:"right",onClick:()=>u((e=>!e))},c?(0,o.__)("Hide Tips","kadence-blocks"):(0,o.__)("Show Tips","kadence-blocks"))))))))),(0,e.createElement)(ln.FlexBlock,{display:"flex"},(0,e.createElement)(ln.Flex,{justify:"center"},(0,e.createElement)(ln.FlexBlock,{style:ni.rightContent},(0,e.createElement)(ea,{backgroundImage:O[s],text:(0,o.__)("Not sure where to start? Here's some real life examples!","kadence-blocks"),doBeforeSlide:e=>l(e.nextSlide),slides:[(0,e.createElement)(Ja,null),(0,e.createElement)(ti,null),(0,e.createElement)(Xa,null),(0,e.createElement)(Ya,null)]})))))}),null),step:"About Your Site",required:["missionStatement"]},{id:"the-details",content:(0,e.createElement)((function(){const{state:t,dispatch:n}=R(),{companyName:a,entityType:i,industry:s,keywords:l,location:c,missionStatement:u,suggestedKeywords:d,suggestedKeywordsState:p,tone:m,lang:h,imageSearchQuery:g}=t,[b,v]=(0,r.useState)(null),[y,E]=(0,r.useState)(null),[k,_]=(0,r.useState)(null),[w,S]=(0,r.useState)(null),[C,N]=(0,r.useState)(),{menuHeight:D,menuPlacement:L}=function(e,t){const[n,o]=(0,r.useState)(300),[a,i]=(0,r.useState)("auto");return(0,r.useEffect)((()=>{function n(){if(e&&t){const n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),a=n.bottom-(r.bottom+30),s=a<150?"top":"auto";i(s),o("top"===s?300:a)}}return n(),window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)}),[e,t]),{menuPlacement:a,menuHeight:n}}(k,w);function F(){n({type:"SET_SUGGESTED_KEYWORDS_STATE",payload:x}),di({name:a,entity_type:i,industry:s,location:c,lang:h,description:u}).then((e=>{N(e),n({type:"SET_SUGGESTED_KEYWORDS",payload:e}),n({type:"SET_SUGGESTED_KEYWORDS_STATE",payload:e?.length?P:A})})).catch((()=>{n({type:"SET_SUGGESTED_KEYWORDS_STATE",payload:I})}))}return(0,r.useEffect)((()=>{l.length>0&&l.length<5?v("poor"):l.length>=5&&v("good")}),[l]),(0,r.useEffect)((()=>{const e=f.filter((e=>e.value===m));e.length&&E(e[0])}),[m]),(0,r.useEffect)((()=>{F(),g||pi({name:a,entity_type:i,industry:s,location:c,description:u}).then((e=>{console.log("Image Search AI Terms"),console.log(e),e?.query&&n({type:"SET_IMAGE_SEARCH_QUERY",payload:e.query})})).catch((()=>{console.log("error")}))}),[]),(0,e.createElement)(ln.Flex,{gap:0,align:"normal",style:mi.container,ref:_},(0,e.createElement)(ln.FlexBlock,{style:{alignSelf:"center"}},(0,e.createElement)(ln.Flex,{justify:"center",style:mi.leftContent},(0,e.createElement)(ln.FlexBlock,{style:mi.formWrapper,className:"stellarwp-body"},(0,e.createElement)(ln.__experimentalVStack,{spacing:"8",style:{margin:"0 auto"}},(0,e.createElement)(zo,{headline:(0,o.__)("Add some keywords","kadence-blocks"),content:(0,o.__)("Keywords assist the AI in identifying the most relevant topics to write about.","kadence-blocks")},(0,e.createElement)(wn,{id:"2",label:(0,o.__)("Keywords","kadence-blocks"),hideLabelFromVision:!0,placeholder:(0,o.__)("Add Keyword…","kadence-blocks"),tags:l,maxTags:10,selectedTags:e=>n({type:"SET_KEYWORDS",payload:e}),suggestedKeywords:d,suggestedKeywordsState:p,onSuggestedKeywordAdded:function(e){const t=d.filter((t=>t!==e));n({type:"SET_SUGGESTED_KEYWORDS",payload:t}),0===t.length&&n({type:"SET_SUGGESTED_KEYWORDS_STATE",payload:T})},onTryAgain:F,onTagDeleted:function(e){C?.includes(e)&&n({type:"SET_SUGGESTED_KEYWORDS",payload:[...d,e]})},help:(0,e.createElement)(e.Fragment,null,(0,e.createElement)(ln.Flex,{align:"flex-start",as:"span",style:mi.helperText},(0,e.createElement)(ln.FlexBlock,{as:"span"},(0,o.__)("Separate with commas or the Enter key. Enter between 5 and 10 keywords","kadence-blocks")),(0,e.createElement)(ln.FlexItem,{as:"span",style:{color:b&&mi.keywordsLength.hasOwnProperty(b)?mi.keywordsLength[b]:"inherit"}},`${l.length}/10`)))})),(0,e.createElement)(zo,{headline:(0,o.__)("Choose your tone","kadence-blocks"),content:(0,o.__)("The tone allows the AI to reflect your personality in its communication style. Select a tone that closely aligns with your own.","kadence-blocks")},(0,e.createElement)(Yo,{ref:S,maxMenuHeight:D,menuPlacement:L,options:f,value:y,onChange:e=>n({type:"SET_TONE",payload:e.value})})))))),(0,e.createElement)(ln.FlexBlock,{display:"flex"},(0,e.createElement)(ln.Flex,{justify:"center"},(0,e.createElement)(ln.FlexBlock,{style:mi.rightContent},(0,e.createElement)(ea,{backgroundImage:O[0],text:(0,o.__)("Not sure where to start? Here's some real life examples!","kadence-blocks"),slides:[(0,e.createElement)(si,null),(0,e.createElement)(li,null),(0,e.createElement)(ci,null),(0,e.createElement)(ui,null)]})))))}),null),step:"The Details",required:["keywords","tone"]},{id:"goals",content:(0,e.createElement)((function(){const{state:t,dispatch:n}=R(),[a,i]=(0,r.useState)([]);return(0,r.useEffect)((()=>{const e=[];Object.keys(y).map((n=>{e.push({id:n,label:y[n].label,value:y[n].value,icon:y[n].icon,description:y[n]?.description?y[n].description:"",isIncluded:t.goals.includes(y[n].value),isPrimary:t.goals.includes(y[n].value)&&t.goals[0]===y[n].value})})),i(e)}),[]),(0,e.createElement)(ln.Flex,{gap:0,align:"normal",style:fi.container},(0,e.createElement)(ln.FlexBlock,{style:{alignSelf:"center",flex:"3 1 0%"}},(0,e.createElement)(ln.Flex,{justify:"center",style:fi.leftContent},(0,e.createElement)(ln.FlexBlock,{style:fi.formWrapper,className:"stellarwp-body"},(0,e.createElement)(zo,{headline:(0,e.createElement)("span",{className:"has-beta-pill"},(0,o.__)("What are the goals of this site?","kadence-blocks")," ",(0,e.createElement)("span",{className:"beta-pill"},"Beta")),content:(0,o.__)("Select all that apply, it is ok to select none. This will be used to help determine content to show for your specific site. NOTE: This is in early stages and has minimal effects currently, but is improving.","kadence-blocks")},(0,e.createElement)(ln.__experimentalView,{style:fi.textareaWrapper},(0,e.createElement)(ln.__experimentalVStack,null,y.length>0&&(0,e.createElement)(Da,{onChange:function(e){n({type:"SET_SITE_GOALS",payload:e})},items:a,selectedItems:t.goals}))))))),(0,e.createElement)(ln.FlexBlock,{display:"flex",style:{flex:"2 1 0%"}},(0,e.createElement)(ln.Flex,{justify:"center"},(0,e.createElement)(ln.FlexBlock,{style:fi.rightContent},(0,e.createElement)("div",{style:fi.image})))))}),null),step:"Site Goals",required:[]},{id:"photography",content:(0,e.createElement)(bi,null),step:"Photography",required:[]}],Si=[{id:"photography",content:(0,e.createElement)(bi,{photographyOnly:!0}),step:"Photography",required:[]}];function Oi(e){const{state:{firstTime:t}}=R();return e?Si:t?wi:wi.filter((e=>"how-it-works"!==e.id))}function Ci(t){const{loading:n,onWizardClose:r,onPrimaryAction:a,photographyOnly:i,credits:s,isFullScreen:l}=t,{state:c,dispatch:u}=R(),{isComplete:d,firstTime:p,isSubmitted:m,currentPageIndex:f,saving:h,saveError:g,...b}=c,{isForwardButtonDisabled:v,isFinishButtonDisabled:y}=vi(c,Oi(i)),{saveAiWizardData:E,getAiWizardData:k}=ca();async function _(){p&&_i("ai_wizard_started"),await E({firstTime:!1,isSubmitted:!0,isComplete:d,...b})&&(r("saved"),w("ai_wizard_update"))}async function w(e){const t=await k();t&&_i(e,JSON.parse(t))}return n?(0,e.createElement)(e.Fragment,null):(0,e.createElement)(ua,{isFirstTime:p,logo:(0,e.createElement)(gn,null),pages:Oi(i),forwardButtonDisabled:v(),onPageChange:e=>u({type:"SET_CURRENT_PAGE_INDEX",payload:e}),onClose:function(e){if("blur"!==e.type&&(27!==e.keyCode||"keydown"!==e.type))return r()},onPrimaryClick:function(e){"blur"===e.type||27===e.keyCode&&"keydown"===e.type||("click"===e.type&&e.target.classList.contains("components-wizard__primary-button")&&(i?_().then((()=>{a("photography",!1),w("collection_updated")})):(async function(){await E({firstTime:!1,isSubmitted:!0,isComplete:!0,...b})&&w("ai_wizard_complete")}(),a(e,!0))),r())},primaryButtonText:i?(0,o.__)("Update My Design Library","kadence-blocks"):(0,o.__)("Generate Initial Content","kadence-blocks"),primaryButtonDisabled:y(),onSecondaryClick:i?null:function(e){"blur"===e.type||27===e.keyCode&&"keydown"===e.type||("click"===e.type&&e.target.classList.contains("components-wizard__secondary-button")&&(c.photoCollectionChanged?_().then((()=>{w("collection_updated")})):_()),r())},secondaryButtonText:(0,o.__)("Save","kadence-blocks"),credits:s,photographyOnly:i,isFullScreen:l})}function xi({photographyOnly:t=!1,onClose:n,onPrimaryAction:o,onSecondaryAction:i,credits:s="",isFullScreen:l=!1}){const[c,u]=(0,r.useState)(),{loading:d,getAiWizardData:p}=ca();return(0,r.useEffect)((()=>{!async function(){const e=(0,a.SafeParseJSON)(await p());u(e)}()}),[]),(0,e.createElement)(e.Fragment,null,c&&!d&&(0,e.createElement)(j,{value:c},(0,e.createElement)(Ci,{loading:d,onWizardClose:n,onPrimaryAction:o,onSecondaryAction:i,photographyOnly:t,credits:s,isFullScreen:l})))}function Ai(){const t=(0,da.useSelect)((e=>e("core/notices").getNotices().filter((e=>"snackbar"===e.type))),[]),n=(0,da.useSelect)((e=>e("core/notices").getNotices().filter((e=>"default"===e.type))),[]),{removeNotice:r}=(0,da.useDispatch)("core/notices");return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(ln.NoticeList,{className:"components-editor-notices__default",notices:n,onRemove:r}),(0,e.createElement)(ln.SnackbarList,{className:"components-editor-notices__snackbar",notices:t,onRemove:r}))}function Ii({variant:t,icon:n,heading:r,content:o,link:a,linkTarget:i="_self",label:s=""}){return(0,e.createElement)("div",{className:`kb-action-card kb-action-card--${t}`},(0,e.createElement)("div",{className:"kb-action-card__icon"},n),(0,e.createElement)("div",{className:"kb-action-card__heading"},r),(0,e.createElement)("div",{className:"kb-action-card__content"},o),a&&(0,e.createElement)("a",{href:a,className:"kb-action-card__link","aria-label":s||void 0,target:i}))}function Pi({category:t,heading:n,description:r,link:o,linkTarget:a="_blank"}){return(0,e.createElement)("a",{href:o,target:a,className:"kb-article-card"},t&&(0,e.createElement)("div",{className:"kb-article-card__category"},t),(0,e.createElement)("div",{className:"kb-article-card__heading"},n),(0,e.createElement)("div",{className:"kb-article-card__description"},r))}function Ti({articles:t}){const n=function(){const[e,t]=(0,r.useState)({width:0,height:0});return(0,r.useEffect)((()=>{function e(){t({width:window.innerWidth,height:window.innerHeight})}return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),[]),e}();let o=1;return n.width>768&&(o=2),n.width>1200&&(o=3),(0,e.createElement)("div",{className:"kb-article-slider"},t.length>0&&(0,e.createElement)(Zo.A,{numOfSlides:o},t.map((t=>(0,e.createElement)("div",{className:"kb-article-slider__single"},(0,e.createElement)(Pi,{key:t.heading,...t}))))))}function Ni({text:t,href:n,onClick:r}){return(0,e.createElement)(dn,{className:"kb-dashboard-button",variant:"primary",onClick:r,href:n},(0,e.createElement)("span",null,t))}const Di=window.kadence.icons,Li=(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",clipRule:"evenodd",viewBox:"0 0 1600 240"},(0,e.createElement)("path",{fill:"none",d:"M0 0H1600V240H0z"}),(0,e.createElement)("g",{fill:"#fff"},(0,e.createElement)("path",{d:"M221.13 222.132h-57.915c-6.271 0-11.361-5.092-11.361-11.363 0-6.269 5.09-11.361 11.361-11.361h37.831c5.904-.405 10.574-5.328 10.574-11.333 0-6.271-5.091-11.361-11.362-11.361h-27.659v-.002H141.06c-6.262 0-11.346-5.083-11.346-11.345 0-6.262 5.084-11.347 11.346-11.347h7.146l-.015-.014h10.624c6.259 0 11.341-5.081 11.341-11.34 0-6.259-5.082-11.339-11.341-11.339h-26.721v-.01H76.061c-6.259 0-11.341-5.082-11.341-11.342 0-6.259 5.082-11.342 11.341-11.342h56.033v-.031h21.94c6.253 0 11.33-5.077 11.33-11.331s-5.077-11.331-11.33-11.331h-5.001l.001-.002-23.3-.001c-6.262.001-11.345-5.084-11.345-11.345 0-6.263 5.083-11.347 11.345-11.347h53.802c.269 0 .534.01.797.027h19.232c6.269 0 11.36-5.089 11.36-11.361 0-6.269-5.091-11.36-11.36-11.36h-28.27c-5.884-.427-10.53-5.341-10.53-11.331 0-6.271 5.09-11.362 11.361-11.362h44.532l.15.001h52.506l-92.001 100.473 111.279 103.81h-67.161l-.016-.015a6.714 6.714 0 01-.285.005zm-109.01-22.724c6.249 0 11.322 5.073 11.322 11.321 0 6.249-5.073 11.321-11.322 11.321H70.575c-6.248 0-11.32-5.072-11.32-11.321 0-6.248 5.073-11.321 11.321-11.321h41.544zM95.673 154.02c6.267 0 11.355 5.088 11.355 11.356 0 6.266-5.088 11.355-11.355 11.355-6.268 0-11.356-5.089-11.356-11.355 0-6.268 5.088-11.356 11.356-11.356zm-59.331-45.387c6.269 0 11.357 5.088 11.357 11.356 0 6.267-5.088 11.355-11.356 11.355-6.267 0-11.355-5.088-11.355-11.355 0-6.268 5.088-11.356 11.355-11.356zm44.005-45.387c6.267 0 11.356 5.088 11.356 11.356 0 6.267-5.089 11.354-11.356 11.354-6.267 0-11.356-5.087-11.356-11.354 0-6.268 5.089-11.356 11.356-11.356zm40.723-45.388c6.249 0 11.321 5.073 11.321 11.321 0 6.249-5.072 11.322-11.321 11.322H94.81c-6.248 0-11.321-5.073-11.321-11.322 0-6.248 5.072-11.321 11.321-11.321h26.26z"}),(0,e.createElement)("path",{fillRule:"nonzero",d:"M1340.97 132.65l19.465-73.534h30.948l18.687 73.312 18.688-73.312h31.771l-32.927 123.475h-30.124l-21.981-80.594-21.98 80.594h-30.124l-33.009-123.475h31.771l18.815 73.533zm131.561 49.942V59.118h59.264c28.811 0 43.217 11.854 43.217 35.561 0 24.584-14.378 36.878-43.134 36.878h-29.223v51.035h-30.124zm59.515-100.343h-29.391v26.259h29.144c9.932-.165 15.036-4.692 15.311-13.582-.275-8.122-5.296-12.348-15.064-12.677z"}),(0,e.createElement)("g",{fillRule:"nonzero"},(0,e.createElement)("path",{d:"M365.698 58.581h24.695v49.39l41.158-49.39h27.741l-48.32 57.622 58.445 65.852h-32.104l-46.92-53.34v53.34h-24.695V58.581zM476.97 182.055L526.36 58.58h24.695l49.308 123.393-26.259.082-7.409-18.933H510.72l-7.408 18.933H476.97zm62.396-90.548l-18.768 46.92h37.043l-18.275-46.92zM642.654 157.442V83.276h22.884c21.896 0 32.872 12.346 32.927 37.042-.055 24.694-11.031 37.069-32.927 37.124h-22.884zm22.884 24.613c38.415 0 57.622-20.579 57.622-61.738 0-41.213-19.207-61.819-57.622-61.819h-47.579v123.557h47.579zM748.494 182.055V58.662l90.712-.082v23.049h-66.017v26.341h49.472v22.966h-49.472v28.07h65.853v23.049h-90.548zM863.223 182.055V58.58h8.232l77.378 77.378V58.58h24.695v123.475h-9.055L887.918 105.5v76.555h-24.695zM1053.85 182.055c-17.451-.055-32.09-5.968-43.916-17.739-11.826-11.772-17.739-26.519-17.739-44.245.055-17.341 5.981-31.925 17.78-43.751 11.799-11.826 26.424-17.739 43.875-17.739 17.616 0 32.734 5.488 45.356 16.463l-16.463 18.028c-8.396-6.586-18.027-9.878-28.893-9.878-11.085.054-20.017 3.512-26.794 10.371-6.778 6.86-10.166 15.641-10.166 26.342.055 11.469 3.484 20.579 10.289 27.329s15.75 10.125 26.836 10.125c11.085 0 20.661-3.265 28.728-9.796l16.463 18.028c-12.567 10.975-27.685 16.463-45.356 16.463zM1124.62 182.055V58.662l90.713-.082v23.049h-66.018v26.341h49.473v22.966h-49.473v28.07h65.854v23.049h-90.549z"}))));function Fi({heading:t,subHeading:n,subHeadingPro:i,imageSrc:s,buttonText:l,isUserAuthenticated:c,activateUrl:u,onUpdateWizard:d,showControls:p,isNetworkAdmin:m,siteName:f=""}){const h=!(!window?.kadenceHomeParams?.pro||"true"!==kadenceHomeParams.pro),g=window?.kadence_blocks_params?.proData?.api_key?kadence_blocks_params.proData.api_key:"",[b,v]=(0,r.useState)(!1),[y,E]=(0,r.useState)(!1),{getAIContentRemaining:k,getAvailableCredits:_}=ki(),w=f||(0,o.__)("Something Great!","kadence-blocks"),S=c?(0,e.createElement)("div",null," ",w):"";return(0,e.createElement)("div",{className:"kb-large-banner"},(0,e.createElement)("div",{className:"kb-large-banner__logo"},Li),(0,e.createElement)("div",{className:"kb-large-banner__content"},(0,e.createElement)("div",{className:"kb-large-banner__heading"},t,S),!c&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"kb-large-banner__subheading"},h?i:n),p&&(0,e.createElement)("a",{className:"uplink-authorize",href:u},h&&g?(0,o.__)("Connect Blocks Pro License to Site","kadence-blocks"):l),!p&&(0,e.createElement)("p",{className:"uplink-authorize-note"},(0,o.__)("Authorization needed from network admin","kadence-blocks"))),c&&!m&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)(ln.Button,{onClick:d,iconPosition:"left",icon:Di.aiIcon,text:(0,o.__)("Update Kadence AI Details","kadence-blocks"),className:"kadence-update-ai-wizard",variant:"link"}))),c&&(0,e.createElement)("div",{className:"kb-large-banner__tooltip"},(0,e.createElement)(ln.Button,{onClick:()=>{!1===y&&async function(){const e=await _(),t=(0,a.SafeParseJSON)(localStorage.getItem("kadenceBlocksPrebuilt"),!0);"error"===e?(console.log("Error getting credits"),t.credits="fetch",localStorage.setItem("kadenceBlocksPrebuilt",JSON.stringify(t)),E(0)):""===e?(t.credits=0,localStorage.setItem("kadenceBlocksPrebuilt",JSON.stringify(t)),E(0)):(t.credits=parseInt(e),localStorage.setItem("kadenceBlocksPrebuilt",JSON.stringify(t)),E(parseInt(e)))}(),v((e=>!e))},variant:"link",icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},(0,e.createElement)("path",{d:"M11 7H13V9H11V7ZM11 11H13V17H11V11ZM12 2C6.48 2 2 6.48 2 12C2 17.52 6.48 22 12 22C17.52 22 22 17.52 22 12C22 6.48 17.52 2 12 2ZM12 20C7.59 20 4 16.41 4 12C4 7.59 7.59 4 12 4C16.41 4 20 7.59 20 12C20 16.41 16.41 20 12 20Z",fill:"white"}))},b&&(0,e.createElement)(ln.Popover,{className:"kb-large-banner__tooltip_popup",placement:"left",onClose:()=>{console.log("close"),v(!1)}},!1===y?(0,e.createElement)(ln.Spinner,null):"",!1===y?(0,o.__)("Fetching Available Credits"):y+" "+(0,o.__)("Credits Available","kadence-blocks")))))}function ji({title:t,icon:n,variant:r="black"}){return(0,e.createElement)("div",{className:`kb-section-title kb-section-title--${r}`},(0,e.createElement)("div",{className:"kb-section-title__title"},t),(0,e.createElement)("div",{className:"kb-section-title__icon"},n))}function Ri({image:t,tag:n,heading:r,description:o,href:a,buttonText:i,flip:s=!1}){return(0,e.createElement)("div",{className:"kb-upsell-content "+(s?"kb-upsell-content--flipped":"")},t&&(0,e.createElement)("img",{className:"kb-upsell-content__image",src:t}),(0,e.createElement)("div",{className:"kb-upsell-content__container"},n&&(0,e.createElement)("div",{className:"kb-upsell-content__tag"},n),r&&(0,e.createElement)("div",{className:"kb-upsell-content__heading"},r),o&&(0,e.createElement)("div",{className:"kb-upsell-content__description"},o),a&&i&&(0,e.createElement)(Ni,{variant:"primary",text:i,href:a})))}const Mi=n.p+"images/blocks-pro.89bfc5a5.png",Bi=n.p+"images/bundles.dba79a46.png",Vi={largeBanner:{heading:(0,e.createElement)(e.Fragment,null,(0,o.__)("Let's build,","kadence-blocks")),subHeading:"",imageSrc:""},actionCards:{title:(0,e.createElement)(ji,{title:(0,o.__)("Start Building with Kadence AI","kadence-blocks"),icon:Di.aiIcon}),cards:[{icon:(0,e.createElement)(ln.Icon,{icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"25",height:"25",viewBox:"0 0 25 25",fill:"none"},(0,e.createElement)("g",{clipPath:"url(#clip0_3059_18235)"},(0,e.createElement)("path",{d:"M1.56776 21.2781C1.8869 21.2781 2.13423 21.2103 2.30975 21.0747C2.48526 20.939 2.62887 20.7076 2.74057 20.3806L4.28438 16.144H11.3452L12.889 20.3806C13.0007 20.7076 13.1443 20.939 13.3198 21.0747C13.4953 21.2103 13.7387 21.2781 14.0499 21.2781C14.369 21.2781 14.6223 21.1904 14.8098 21.0148C14.9973 20.8393 15.091 20.6 15.091 20.2968C15.091 20.1133 15.0471 19.8979 14.9593 19.6506L9.34661 4.71518C9.203 4.34019 9.00753 4.06295 8.76019 3.88344C8.51287 3.70393 8.19773 3.61417 7.81477 3.61417C7.07279 3.61417 6.57016 3.97718 6.30687 4.7032L0.694142 19.6625C0.606381 19.8779 0.5625 20.0934 0.5625 20.3088C0.5625 20.612 0.652256 20.8493 0.831768 21.0208C1.01128 21.1924 1.25661 21.2781 1.56776 21.2781ZM4.89472 14.3131L7.8028 6.25897H7.86264L10.7707 14.3131H4.89472ZM16.6108 24.9162H23.5998C24.1583 24.9162 24.4375 24.6808 24.4375 24.2102C24.4375 23.7474 24.1583 23.5161 23.5998 23.5161H20.9191V1.38822H23.5998C24.1583 1.38822 24.4375 1.15286 24.4375 0.682145C24.4375 0.227382 24.1583 0 23.5998 0H16.6108C16.0604 0 15.7851 0.227382 15.7851 0.682145C15.7851 1.15286 16.0604 1.38822 16.6108 1.38822H19.3036V23.5161H16.6108C16.0604 23.5161 15.7851 23.7474 15.7851 24.2102C15.7851 24.6808 16.0604 24.9162 16.6108 24.9162Z",fill:"#161A1E"})),(0,e.createElement)("defs",null,(0,e.createElement)("clipPath",{id:"clip0_3059_18235"},(0,e.createElement)("rect",{width:"23.875",height:"25",fill:"white",transform:"translate(0.5625)"}))))}),heading:(0,o.__)("Build a page with AI-powered patterns","kadence-blocks"),content:(0,o.__)("Take your site further with hundreds of beautiful patterns filled with custom content developed just for your site.","kadence-blocks"),variant:"blue",link:"/wp-admin/post-new.php?post_type=page"},{icon:(0,e.createElement)(ln.Icon,{icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"25",height:"25",viewBox:"0 0 25 25",fill:"none"},(0,e.createElement)("g",{clipPath:"url(#clip0_3059_18235)"},(0,e.createElement)("path",{d:"M1.56776 21.2781C1.8869 21.2781 2.13423 21.2103 2.30975 21.0747C2.48526 20.939 2.62887 20.7076 2.74057 20.3806L4.28438 16.144H11.3452L12.889 20.3806C13.0007 20.7076 13.1443 20.939 13.3198 21.0747C13.4953 21.2103 13.7387 21.2781 14.0499 21.2781C14.369 21.2781 14.6223 21.1904 14.8098 21.0148C14.9973 20.8393 15.091 20.6 15.091 20.2968C15.091 20.1133 15.0471 19.8979 14.9593 19.6506L9.34661 4.71518C9.203 4.34019 9.00753 4.06295 8.76019 3.88344C8.51287 3.70393 8.19773 3.61417 7.81477 3.61417C7.07279 3.61417 6.57016 3.97718 6.30687 4.7032L0.694142 19.6625C0.606381 19.8779 0.5625 20.0934 0.5625 20.3088C0.5625 20.612 0.652256 20.8493 0.831768 21.0208C1.01128 21.1924 1.25661 21.2781 1.56776 21.2781ZM4.89472 14.3131L7.8028 6.25897H7.86264L10.7707 14.3131H4.89472ZM16.6108 24.9162H23.5998C24.1583 24.9162 24.4375 24.6808 24.4375 24.2102C24.4375 23.7474 24.1583 23.5161 23.5998 23.5161H20.9191V1.38822H23.5998C24.1583 1.38822 24.4375 1.15286 24.4375 0.682145C24.4375 0.227382 24.1583 0 23.5998 0H16.6108C16.0604 0 15.7851 0.227382 15.7851 0.682145C15.7851 1.15286 16.0604 1.38822 16.6108 1.38822H19.3036V23.5161H16.6108C16.0604 23.5161 15.7851 23.7474 15.7851 24.2102C15.7851 24.6808 16.0604 24.9162 16.6108 24.9162Z",fill:"#161A1E"})),(0,e.createElement)("defs",null,(0,e.createElement)("clipPath",{id:"clip0_3059_18235"},(0,e.createElement)("rect",{width:"23.875",height:"25",fill:"white",transform:"translate(0.5625)"}))))}),heading:(0,o.__)("Get started with full pages","kadence-blocks"),content:(0,o.__)("Choose from a variety of pages featuring exclusively tailored content for your site.","kadence-blocks"),variant:"green",link:"/wp-admin/post-new.php?post_type=page"},{icon:(0,e.createElement)(ln.Icon,{icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"25",height:"25",viewBox:"0 0 25 25",fill:"none"},(0,e.createElement)("g",{clipPath:"url(#clip0_3059_18235)"},(0,e.createElement)("path",{d:"M1.56776 21.2781C1.8869 21.2781 2.13423 21.2103 2.30975 21.0747C2.48526 20.939 2.62887 20.7076 2.74057 20.3806L4.28438 16.144H11.3452L12.889 20.3806C13.0007 20.7076 13.1443 20.939 13.3198 21.0747C13.4953 21.2103 13.7387 21.2781 14.0499 21.2781C14.369 21.2781 14.6223 21.1904 14.8098 21.0148C14.9973 20.8393 15.091 20.6 15.091 20.2968C15.091 20.1133 15.0471 19.8979 14.9593 19.6506L9.34661 4.71518C9.203 4.34019 9.00753 4.06295 8.76019 3.88344C8.51287 3.70393 8.19773 3.61417 7.81477 3.61417C7.07279 3.61417 6.57016 3.97718 6.30687 4.7032L0.694142 19.6625C0.606381 19.8779 0.5625 20.0934 0.5625 20.3088C0.5625 20.612 0.652256 20.8493 0.831768 21.0208C1.01128 21.1924 1.25661 21.2781 1.56776 21.2781ZM4.89472 14.3131L7.8028 6.25897H7.86264L10.7707 14.3131H4.89472ZM16.6108 24.9162H23.5998C24.1583 24.9162 24.4375 24.6808 24.4375 24.2102C24.4375 23.7474 24.1583 23.5161 23.5998 23.5161H20.9191V1.38822H23.5998C24.1583 1.38822 24.4375 1.15286 24.4375 0.682145C24.4375 0.227382 24.1583 0 23.5998 0H16.6108C16.0604 0 15.7851 0.227382 15.7851 0.682145C15.7851 1.15286 16.0604 1.38822 16.6108 1.38822H19.3036V23.5161H16.6108C16.0604 23.5161 15.7851 23.7474 15.7851 24.2102C15.7851 24.6808 16.0604 24.9162 16.6108 24.9162Z",fill:"#161A1E"})),(0,e.createElement)("defs",null,(0,e.createElement)("clipPath",{id:"clip0_3059_18235"},(0,e.createElement)("rect",{width:"23.875",height:"25",fill:"white",transform:"translate(0.5625)"}))))}),heading:(0,o.__)("Fine-tune your content","kadence-blocks"),content:(0,o.__)("Write your own prompts to generate AI content from scratch or fine-tune existing copy.","kadence-blocks"),variant:"yellow"}]},upsellContents:[{image:Mi,tag:(0,o.__)("Upgrade","kadence-blocks"),heading:(0,o.__)("Elevate your pages with Blocks Pro","kadence-blocks"),description:(0,o.__)("Unleash limitless creativity with our custom block library - enhance your content with animations, dynamic texts, custom fonts and icons, and more!","kadence-blocks"),href:"https://www.kadencewp.com/kadence-blocks/pro/",buttonText:(0,o.__)("Upgrade to Blocks Pro","kadence-blocks")},{image:Bi,tag:(0,o.__)("Go Pro","kadence-blocks"),heading:(0,o.__)("Achieve more with Bundles","kadence-blocks"),description:(0,o.__)("Elevate your site development process with our Pro Bundles. Jump start your site with a Pro Starter Template, and turbocharge your page building with Theme Pro and Blocks Pro – now powered by Kadence AI. Plus, unlock the potential of Custom Fonts, Cloud, Conversions, and so much more.","kadence-blocks"),href:"https://www.kadencewp.com/pricing/",buttonText:(0,o.__)("Go Pro with a Bundle","kadence-blocks"),flip:!0}],knowledgeBase:{heading:(0,o.__)(" Need Help Getting Started?","kadence-blocks"),articles:[{category:(0,o.__)("Kadence AI","kadence-blocks"),heading:(0,o.__)("Update AI Settings","kadence-blocks"),description:(0,o.__)("Update Kadence AI settings. Regenerate contexts for patterns and pages to reflect your updated needs.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/design-libary-changing-ai-details/",linkTarget:"_blank"},{category:(0,o.__)("Kadence AI","kadence-blocks"),heading:(0,o.__)("Customize Image Collections","kadence-blocks"),description:(0,o.__)("Update your Design Library imagery using premade collections or create and customize your own.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/design-library-changing-ai-image-collections/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks","kadence-blocks"),heading:(0,o.__)("Row Layout Block","kadence-blocks"),description:(0,o.__)("Use the Row Layout block to improve the column functionality and create responsive post/page layouts.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/row-layout-block-2/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks","kadence-blocks"),heading:(0,o.__)("Advanced Text Block","kadence-blocks"),description:(0,o.__)("Use the Advanced Text block to add text to your page/post with advanced customization - now with AI.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/advanced-heading-block/",linkTarget:"_blank"},{category:(0,o.__)("Support","kadence-blocks"),heading:(0,o.__)("Need more help?","kadence-blocks"),description:(0,o.__)("Didn't find what you were looking for? Find more articles in our knowledge base.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/",linkTarget:"_blank"}]}},Hi={largeBanner:{heading:(0,e.createElement)(e.Fragment,null,(0,o.__)("Kadence is better with AI.","kadence-blocks")," ",Di.aiIcon),subHeading:(0,o.__)("Elevate your web development game with Kadence AI. Supercharge your pattern and page library's potential with tailored content - get building pages in no time. Try Kadence AI today with 250 free credits!","kadence-blocks"),subHeadingPro:(0,o.__)("Elevate your web development game with Kadence AI. Supercharge your pattern and page library's potential with tailored content - get building pages in no time. Connect to your account to use Kadence AI with Kadence Blocks Pro","kadence-blocks"),buttonText:(0,o.__)("Get Started with Kadence AI","kadence-blocks")},actionCards:{title:(0,e.createElement)(ji,{title:(0,o.__)("Streamlined site building","kadence-blocks")}),cards:[{icon:(0,e.createElement)(ln.Icon,{icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"25",height:"25",viewBox:"0 0 25 25",fill:"none"},(0,e.createElement)("g",{clipPath:"url(#clip0_3059_18235)"},(0,e.createElement)("path",{d:"M1.56776 21.2781C1.8869 21.2781 2.13423 21.2103 2.30975 21.0747C2.48526 20.939 2.62887 20.7076 2.74057 20.3806L4.28438 16.144H11.3452L12.889 20.3806C13.0007 20.7076 13.1443 20.939 13.3198 21.0747C13.4953 21.2103 13.7387 21.2781 14.0499 21.2781C14.369 21.2781 14.6223 21.1904 14.8098 21.0148C14.9973 20.8393 15.091 20.6 15.091 20.2968C15.091 20.1133 15.0471 19.8979 14.9593 19.6506L9.34661 4.71518C9.203 4.34019 9.00753 4.06295 8.76019 3.88344C8.51287 3.70393 8.19773 3.61417 7.81477 3.61417C7.07279 3.61417 6.57016 3.97718 6.30687 4.7032L0.694142 19.6625C0.606381 19.8779 0.5625 20.0934 0.5625 20.3088C0.5625 20.612 0.652256 20.8493 0.831768 21.0208C1.01128 21.1924 1.25661 21.2781 1.56776 21.2781ZM4.89472 14.3131L7.8028 6.25897H7.86264L10.7707 14.3131H4.89472ZM16.6108 24.9162H23.5998C24.1583 24.9162 24.4375 24.6808 24.4375 24.2102C24.4375 23.7474 24.1583 23.5161 23.5998 23.5161H20.9191V1.38822H23.5998C24.1583 1.38822 24.4375 1.15286 24.4375 0.682145C24.4375 0.227382 24.1583 0 23.5998 0H16.6108C16.0604 0 15.7851 0.227382 15.7851 0.682145C15.7851 1.15286 16.0604 1.38822 16.6108 1.38822H19.3036V23.5161H16.6108C16.0604 23.5161 15.7851 23.7474 15.7851 24.2102C15.7851 24.6808 16.0604 24.9162 16.6108 24.9162Z",fill:"#161A1E"})),(0,e.createElement)("defs",null,(0,e.createElement)("clipPath",{id:"clip0_3059_18235"},(0,e.createElement)("rect",{width:"23.875",height:"25",fill:"white",transform:"translate(0.5625)"}))))}),heading:(0,o.__)("A content-rich design library that is uniquely yours","kadence-blocks"),content:(0,o.__)("Jump-start your site-building process with unique content and gorgeous designs. Learn more about the AI-Powered Design Library.","kadence-blocks"),link:"https://www.kadencewp.com/wordpress-solutions/kadence-ai/",variant:"blue"},{icon:(0,e.createElement)(ln.Icon,{icon:(0,e.createElement)(ln.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"25",height:"25",viewBox:"0 0 25 25",fill:"none"},(0,e.createElement)("g",{clipPath:"url(#clip0_3059_18235)"},(0,e.createElement)("path",{d:"M1.56776 21.2781C1.8869 21.2781 2.13423 21.2103 2.30975 21.0747C2.48526 20.939 2.62887 20.7076 2.74057 20.3806L4.28438 16.144H11.3452L12.889 20.3806C13.0007 20.7076 13.1443 20.939 13.3198 21.0747C13.4953 21.2103 13.7387 21.2781 14.0499 21.2781C14.369 21.2781 14.6223 21.1904 14.8098 21.0148C14.9973 20.8393 15.091 20.6 15.091 20.2968C15.091 20.1133 15.0471 19.8979 14.9593 19.6506L9.34661 4.71518C9.203 4.34019 9.00753 4.06295 8.76019 3.88344C8.51287 3.70393 8.19773 3.61417 7.81477 3.61417C7.07279 3.61417 6.57016 3.97718 6.30687 4.7032L0.694142 19.6625C0.606381 19.8779 0.5625 20.0934 0.5625 20.3088C0.5625 20.612 0.652256 20.8493 0.831768 21.0208C1.01128 21.1924 1.25661 21.2781 1.56776 21.2781ZM4.89472 14.3131L7.8028 6.25897H7.86264L10.7707 14.3131H4.89472ZM16.6108 24.9162H23.5998C24.1583 24.9162 24.4375 24.6808 24.4375 24.2102C24.4375 23.7474 24.1583 23.5161 23.5998 23.5161H20.9191V1.38822H23.5998C24.1583 1.38822 24.4375 1.15286 24.4375 0.682145C24.4375 0.227382 24.1583 0 23.5998 0H16.6108C16.0604 0 15.7851 0.227382 15.7851 0.682145C15.7851 1.15286 16.0604 1.38822 16.6108 1.38822H19.3036V23.5161H16.6108C16.0604 23.5161 15.7851 23.7474 15.7851 24.2102C15.7851 24.6808 16.0604 24.9162 16.6108 24.9162Z",fill:"#161A1E"})),(0,e.createElement)("defs",null,(0,e.createElement)("clipPath",{id:"clip0_3059_18235"},(0,e.createElement)("rect",{width:"23.875",height:"25",fill:"white",transform:"translate(0.5625)"}))))}),heading:(0,o.__)("Fine-Tuned Editing","kadence-blocks"),content:(0,o.__)("Get your messaging on point with in-line AI-assisted editing. Learn More about the inline AI.","kadence-blocks"),link:"https://www.kadencewp.com/wordpress-solutions/kadence-ai/",variant:"green"}]},upsellContents:[{image:Mi,tag:(0,o.__)("Upgrade"),heading:(0,o.__)("Elevate your pages with Blocks Pro","kadence-blocks"),description:(0,o.__)("Unleash limitless creativity with our custom block library - enhance your content with animations, dynamic texts, custom fonts and icons, and more!","kadence-blocks"),href:"https://www.kadencewp.com/blocks-pro/",buttonText:(0,o.__)("Upgrade to Blocks Pro","kadence-blocks")},{image:Bi,tag:(0,o.__)("Go Pro","kadence-blocks"),heading:(0,o.__)("Kadence Blocks works better with Kadence Theme","kadence-blocks"),description:(0,o.__)("Level up with Kadence Blocks and Theme. Kickstart your site using Starter Templates, customize with ease, and elevate your pattern library's style with the Kadence Theme.","kadence-blocks"),href:"https://wordpress.org/themes/kadence/",buttonText:(0,o.__)("Try Kadence Theme Free","kadence-blocks"),flip:!0}],knowledgeBase:{heading:(0,o.__)(" Need Help Getting Started?","kadence-blocks"),articles:[{category:(0,o.__)("Kadence Blocks","kadence-blocks"),heading:(0,o.__)("Using the Design Library","kadence-blocks"),description:(0,o.__)("Use fully designed patterns and pages on your site with your own customizer settings - now with AI.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/how-to-control-the-kadence-design-library/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks","kadence-blocks"),heading:(0,o.__)("Row Layout Block","kadence-blocks"),description:(0,o.__)("Use the Row Layout block to improve the column functionality and create responsive post/page layouts.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/row-layout-block-2/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks","kadence-blocks"),heading:(0,o.__)("Advanced Text Block","kadence-blocks"),description:(0,o.__)("Use the Advanced Text block to add text to your page/post with advanced customization - now with AI.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/advanced-heading-block/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks Pro","kadence-blocks"),heading:(0,o.__)("Kadence Blocks Pro Plugin","kadence-blocks"),description:(0,o.__)("Install and activate the Kadence Blocks Pro plugin, and get an overview of the Pro features available.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/kadence-blocks-pro-plugin/",linkTarget:"_blank"},{category:(0,o.__)("Kadence Blocks Pro","kadence-blocks"),heading:(0,o.__)("Advanced Slider","kadence-blocks"),description:(0,o.__)("Showcase products or highlight important visual content using the Advanced Slider block.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/docs/kadence-blocks/advanced-slider/",linkTarget:"_blank"},{category:(0,o.__)("Support","kadence-blocks"),heading:(0,o.__)("Need more help?","kadence-blocks"),description:(0,o.__)("Didn't find what you were looking for? Find more articles in our knowledge base.","kadence-blocks"),link:"https://www.kadencewp.com/help-center/",linkTarget:"_blank"}]}},zi=(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",clipRule:"evenodd",viewBox:"0 0 1600 240"},(0,e.createElement)("path",{fill:"none",d:"M0 0H1600V240H0z"}),(0,e.createElement)("g",{fill:"#fff"},(0,e.createElement)("path",{d:"M221.13 222.132h-57.915c-6.271 0-11.361-5.092-11.361-11.363 0-6.269 5.09-11.361 11.361-11.361h37.831c5.904-.405 10.574-5.328 10.574-11.333 0-6.271-5.091-11.361-11.362-11.361h-27.659v-.002H141.06c-6.262 0-11.346-5.083-11.346-11.345 0-6.262 5.084-11.347 11.346-11.347h7.146l-.015-.014h10.624c6.259 0 11.341-5.081 11.341-11.34 0-6.259-5.082-11.339-11.341-11.339h-26.721v-.01H76.061c-6.259 0-11.341-5.082-11.341-11.342 0-6.259 5.082-11.342 11.341-11.342h56.033v-.031h21.94c6.253 0 11.33-5.077 11.33-11.331s-5.077-11.331-11.33-11.331h-5.001l.001-.002-23.3-.001c-6.262.001-11.345-5.084-11.345-11.345 0-6.263 5.083-11.347 11.345-11.347h53.802c.269 0 .534.01.797.027h19.232c6.269 0 11.36-5.089 11.36-11.361 0-6.269-5.091-11.36-11.36-11.36h-28.27c-5.884-.427-10.53-5.341-10.53-11.331 0-6.271 5.09-11.362 11.361-11.362h44.532l.15.001h52.506l-92.001 100.473 111.279 103.81h-67.161l-.016-.015a6.714 6.714 0 01-.285.005zm-109.01-22.724c6.249 0 11.322 5.073 11.322 11.321 0 6.249-5.073 11.321-11.322 11.321H70.575c-6.248 0-11.32-5.072-11.32-11.321 0-6.248 5.073-11.321 11.321-11.321h41.544zM95.673 154.02c6.267 0 11.355 5.088 11.355 11.356 0 6.266-5.088 11.355-11.355 11.355-6.268 0-11.356-5.089-11.356-11.355 0-6.268 5.088-11.356 11.356-11.356zm-59.331-45.387c6.269 0 11.357 5.088 11.357 11.356 0 6.267-5.088 11.355-11.356 11.355-6.267 0-11.355-5.088-11.355-11.355 0-6.268 5.088-11.356 11.355-11.356zm44.005-45.387c6.267 0 11.356 5.088 11.356 11.356 0 6.267-5.089 11.354-11.356 11.354-6.267 0-11.356-5.087-11.356-11.354 0-6.268 5.089-11.356 11.356-11.356zm40.723-45.388c6.249 0 11.321 5.073 11.321 11.321 0 6.249-5.072 11.322-11.321 11.322H94.81c-6.248 0-11.321-5.073-11.321-11.322 0-6.248 5.072-11.321 11.321-11.321h26.26z"}),(0,e.createElement)("path",{fillRule:"nonzero",d:"M1340.97 132.65l19.465-73.534h30.948l18.687 73.312 18.688-73.312h31.771l-32.927 123.475h-30.124l-21.981-80.594-21.98 80.594h-30.124l-33.009-123.475h31.771l18.815 73.533zm131.561 49.942V59.118h59.264c28.811 0 43.217 11.854 43.217 35.561 0 24.584-14.378 36.878-43.134 36.878h-29.223v51.035h-30.124zm59.515-100.343h-29.391v26.259h29.144c9.932-.165 15.036-4.692 15.311-13.582-.275-8.122-5.296-12.348-15.064-12.677z"}),(0,e.createElement)("g",{fillRule:"nonzero"},(0,e.createElement)("path",{d:"M365.698 58.581h24.695v49.39l41.158-49.39h27.741l-48.32 57.622 58.445 65.852h-32.104l-46.92-53.34v53.34h-24.695V58.581zM476.97 182.055L526.36 58.58h24.695l49.308 123.393-26.259.082-7.409-18.933H510.72l-7.408 18.933H476.97zm62.396-90.548l-18.768 46.92h37.043l-18.275-46.92zM642.654 157.442V83.276h22.884c21.896 0 32.872 12.346 32.927 37.042-.055 24.694-11.031 37.069-32.927 37.124h-22.884zm22.884 24.613c38.415 0 57.622-20.579 57.622-61.738 0-41.213-19.207-61.819-57.622-61.819h-47.579v123.557h47.579zM748.494 182.055V58.662l90.712-.082v23.049h-66.017v26.341h49.472v22.966h-49.472v28.07h65.853v23.049h-90.548zM863.223 182.055V58.58h8.232l77.378 77.378V58.58h24.695v123.475h-9.055L887.918 105.5v76.555h-24.695zM1053.85 182.055c-17.451-.055-32.09-5.968-43.916-17.739-11.826-11.772-17.739-26.519-17.739-44.245.055-17.341 5.981-31.925 17.78-43.751 11.799-11.826 26.424-17.739 43.875-17.739 17.616 0 32.734 5.488 45.356 16.463l-16.463 18.028c-8.396-6.586-18.027-9.878-28.893-9.878-11.085.054-20.017 3.512-26.794 10.371-6.778 6.86-10.166 15.641-10.166 26.342.055 11.469 3.484 20.579 10.289 27.329s15.75 10.125 26.836 10.125c11.085 0 20.661-3.265 28.728-9.796l16.463 18.028c-12.567 10.975-27.685 16.463-45.356 16.463zM1124.62 182.055V58.662l90.713-.082v23.049h-66.018v26.341h49.473v22.966h-49.473v28.07h65.854v23.049h-90.549z"}))));function Ui(){return(0,e.createElement)("div",{className:"kb-large-banner"},(0,e.createElement)("div",{className:"kb-large-banner__logo"},zi),(0,e.createElement)("div",{className:"kb-large-banner__content"},(0,e.createElement)("div",{className:"kb-large-banner__heading"},(0,o.__)("Kadence is better with AI.","kadence-blocks")," ",Di.aiIcon),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"kb-large-banner__subheading"},(0,o.__)("Elevate your web development game with Kadence AI. Supercharge your pattern and page library's potential with tailored content - get building pages in no time.","kadence-blocks")),(0,e.createElement)("p",{className:"disabled-authorize-note"},(0,o.__)("Kadence AI is disabled by site admin.","kadence-blocks")))))}const Wi=window.wp.notices;function qi(){const[t,n]=(0,r.useState)(!1),a=new URLSearchParams(window.location.search),i=a.get("uplink_token"),{getInitialAIContent:s,getAllAIContentData:l,getAvailableCredits:c}=ki(),[u,d]=(0,r.useState)("start"),[p,m]=(0,r.useState)(!1),f=!!kadenceHomeParams.isAuthorized,h=!!kadenceHomeParams.isNetworkAdmin,g=!!kadenceHomeParams.isNetworkEnabled,b=!!kadenceHomeParams.isAIDisabled,v=!(!window?.kadenceHomeParams?.pro||"true"!==kadenceHomeParams.pro),y=!!(h&&g||!h&&!g),E=f?Vi:Hi;(0,r.useEffect)((()=>{i&&(a.delete("uplink_token"),a.delete("uplink_license"),a.delete("uplink_slug"),a.delete("_uplink_nonce"),history.pushState(null,"",window.location.pathname+"?"+a.toString())),i&&f&&n(!0),f&&"start"===u?S():d("not-authenticated")}),[]);const{createErrorNotice:k,createSuccessNotice:_,createNotice:w}=(0,da.useDispatch)(Wi.store);async function S(){const e=await l(!0);"empty"===e?(console.log("No Local AI Content"),d("empty")):"loading"===e?("getInitial"!==u&&d("getInitial"),console.log("Still Loading"),setTimeout((()=>{S()}),5e3)):"error"===e?(console.log("Error to load Local"),d("failed")):e&&d("infoLoaded")}(0,r.useEffect)((()=>{p&&"infoLoaded"===u&&w("info",(0,o.__)("AI Content generated. You can find AI content in your design library in the editor.","kadence-blocks"),{type:"default"}),"getInitial"===u&&m(!0)}),[u]);const O=(0,e.createElement)(e.Fragment,null,(0,o.__)("AI access authorized.","kadence-blocks")," ",(0,e.createElement)("a",{href:kadenceHomeParams.disconnectUrl},(0,o.__)("Disconnect?","kadence-blocks")));return b?(0,e.createElement)(e.Fragment,null,(0,e.createElement)(Ui,null),(0,e.createElement)("div",{className:"kb-section kb-section--dark"},(0,e.createElement)("div",{className:"kb-container"},(0,e.createElement)(ji,{title:E.knowledgeBase.heading,variant:"white"}),(0,e.createElement)(Ti,{articles:E.knowledgeBase.articles})))):(0,e.createElement)(e.Fragment,null,(0,e.createElement)(Fi,{...E?.largeBanner,activateUrl:kadenceHomeParams.authUrl,onUpdateWizard:()=>n(!0),isUserAuthenticated:f,showControls:y,isNetworkAdmin:h}),"getInitial"===u&&(0,e.createElement)("div",{className:"components-notice kadence-ai-notice is-info"},(0,e.createElement)("div",{className:"components-notice__content"},(0,e.createElement)(ln.Spinner,null),(0,o.__)("Generating AI Content, this happens in the background, you can leave this page. You can find AI content in your design library in the editor.","kadence-blocks"))),(0,e.createElement)(Ai,null),(0,e.createElement)("div",{className:"kb-container"},(0,e.createElement)("div",{className:"kb-section"},E.actionCards.title,E.actionCards.cards.length>0&&(0,e.createElement)("div",{className:"kb-auto-grid"},E.actionCards.cards.map((t=>(0,e.createElement)(Ii,{key:t.heading,...t}))))),!v&&E.upsellContents.length>0&&E.upsellContents.map((t=>(0,e.createElement)("div",{className:"kb-section",key:t.heading},(0,e.createElement)(Ri,{...t})))),!h&&t&&(0,e.createElement)(xi,{onClose:e=>{n(!1),e&&"saved"===e&&_((0,o.__)("Saved"),{type:"snackbar"})},onPrimaryAction:(e,t)=>{t&&(d("getInitial"),console.log("Rebuild AI Content",u),async function(){_((0,o.__)("Generating AI Content"),{type:"snackbar"});const e=await s();console.log("response",e),"error"===e||"failed"===e?(k((0,o.__)("Error generating AI content, Please Retry"),{type:"snackbar"}),console.log("Error getting AI Content."),d("failed")):e?.error&&e?.context?(d("failed"),k((0,o.__)("Error, Some AI Contexts could not be started, Please Retry"),{type:"snackbar"}),console.log("Error getting all new AI Content.")):setTimeout((()=>{S()}),1e4)}())},photographyOnly:!1,credits:!1,isFullScreen:!0})),(0,e.createElement)("div",{className:"kb-section kb-section--dark"},(0,e.createElement)("div",{className:"kb-container"},(0,e.createElement)(ji,{title:E.knowledgeBase.heading,variant:"white"}),(0,e.createElement)(Ti,{articles:E.knowledgeBase.articles}))),(0,e.createElement)("div",{className:"kb-footer-status"},y&&(0,e.createElement)("p",null,f?O:(0,o.__)("AI access is not authorized.","kadence-blocks")),!y&&(0,e.createElement)("p",null,f?(0,o.__)("AI access authorized.","kadence-blocks"):(0,o.__)("AI access is not authorized.","kadence-blocks"))))}wp.domReady((()=>{const t=document.querySelector(".kadence_blocks_home_main");(0,r.createRoot)(t).render((0,e.createElement)(qi,null))}))})(),(this.kadence=this.kadence||{})["admin-kadence-home"]={}})();