403 Forbidden


Disable Functions:
Path : /opt/wp/plugins/bluehost-wordpress-plugin/build/
File Upload :
Command :
Current File : //opt/wp/plugins/bluehost-wordpress-plugin/build/12-fc867bcb122494645473.js

(window.webpackJsonp_bluehost_wordpress_plugin=window.webpackJsonp_bluehost_wordpress_plugin||[]).push([[12],{134:function(e,t){function n(e,t,n,r,o,s,a){try{var i=e[s](a),c=i.value}catch(e){return void n(e)}i.done?t(c):Promise.resolve(c).then(r,o)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise((function(o,s){var a=e.apply(t,r);function i(e){n(a,o,s,i,c,"next",e)}function c(e){n(a,o,s,i,c,"throw",e)}i(void 0)}))}},e.exports.default=e.exports,e.exports.__esModule=!0},135:function(e,t,n){"use strict";n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return f})),n.d(t,"c",(function(){return m})),n.d(t,"d",(function(){return j})),n.d(t,"e",(function(){return y})),n.d(t,"f",(function(){return _})),n.d(t,"g",(function(){return S}));var r=n(38),o=n.n(r),s=n(4),a=n.n(s),i=n(1),c=n(5);function l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=Object(i.useState)(e),n=a()(t,2),r=n[0],s=n[1];function l(e){s([].concat(o()(r),[e]))}function u(e){return r.includes(e)}function p(e){s(Object(c.without)(r,e))}function h(e){u(e)?p(e):l(e)}return[{favorites:r},{addFavorite:l,hasFavorite:u,removeFavorite:p,setFavorites:s,toggleFavorite:h}]}var u=n(134),p=n.n(u),h=n(18),d=n.n(h),b=n(16),g=n.n(b);function f(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"themes",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=Object(i.useState)(!1),r=a()(n,2),o=r[0],s=r[1],c=Object(i.useState)(!1),l=a()(c,2),u=l[0],h=l[1],b=Object(i.useState)(!1),f=a()(b,2),m=f[0],v=f[1],O=Object(i.useState)(e),j=a()(O,2),y=j[0],_=j[1],w=Object(i.useState)(t),E=a()(w,2),k=E[0],S=E[1],P=Object(i.useState)({}),C=a()(P,2),x=C[0],T=C[1];return Object(i.useEffect)((function(){!function(){var e=p()(d.a.mark((function e(){var t,n,r,o,i,c,l;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:for(s(!1),h(!1),v(!0),e.prev=3,t=new URLSearchParams(""),n=0,r=Object.entries(k);n<r.length;n++)o=a()(r[n],2),i=o[0],c=o[1],t.append(i,c);return e.next=8,g()({path:"/mojo/v1/"+y+"?"+t.toString()});case 8:l=e.sent,T(l),e.next=16;break;case 12:e.prev=12,e.t0=e.catch(3),h(!0),T(e.t0);case 16:v(!1),s(!0);case 18:case"end":return e.stop()}}),e,null,[[3,12]])})));return function(){return e.apply(this,arguments)}}()()}),[y,k]),[{done:o,isError:u,isLoading:m,params:k,payload:x},{setType:_,setParams:S}]}function m(e){return[function(t,n){switch(n){case"favorites":return function(t){return Object(c.filter)(t,(function(t){return e.includes(t.id)}))}(t);default:return t}}]}var v=n(139),O=n.n(v);function j(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=Object(i.useState)(e),n=a()(t,2),r=n[0],o=n[1];function s(e){return r?new O.a(e,{threshold:.1,keys:["name","short_description","features","tags"]}).search(r):e}return[{query:r},{search:s,setQuery:o}]}function y(){function e(e){return e.sort((function(e,t){return e.created_timestamp>t.created_timestamp?1:e.created_timestamp<t.created_timestamp?-1:e.name<t.name?1:-1}))}function t(t){return Object(c.reverse)(e(t))}function n(e){return Object(c.sortBy)(e,(function(e){return parseInt(e.prices.single_domain_license,10)}))}function r(e){return Object(c.reverse)(n(e))}function o(e){return e.sort((function(e,t){return e.sales_count>t.sales_count?1:e.sales_count<t.sales_count?-1:e.name<t.name?1:-1}))}function s(e){return Object(c.reverse)(o(e))}return[function(a){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"sales",c=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"desc";switch(a=Object.values(a),i){case"date":return"desc"===c?t(a):e(a);case"price":return"desc"===c?r(a):n(a);default:return"desc"===c?s(a):o(a)}}]}function _(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:12,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=Object(i.useState)(e),o=a()(r,2),s=o[0],l=o[1],u=Object(i.useState)([]),p=a()(u,2),h=p[0],d=p[1],b=Object(i.useState)(t),g=a()(b,2),f=g[0],m=g[1],v=Object(i.useState)([]),O=a()(v,2),j=O[0],y=O[1],_=Object(i.useState)(1),w=a()(_,2),E=w[0],k=w[1],S=Object(i.useState)(n),P=a()(S,2),C=P[0],x=P[1];return Object(i.useEffect)((function(){var e=Object(c.chunk)(s,f);y(e),k(e.length)}),[s]),Object(i.useEffect)((function(){d(j[C-1])}),[j,C]),[{items:h,itemsPerPage:f,pageCount:E,pageNumber:C},{setCollection:l,setItemsPerPage:m,setPageNumber:x}]}var w=n(19),E=n.n(w),k=n(2);function S(){var e=Object(i.useState)(null),t=a()(e,2),n=t[0],r=t[1],o=Object(i.useState)(null),s=a()(o,2),c=s[0],l=s[1],u=Object(i.useState)(null),h=a()(u,2),b=h[0],f=h[1],m=Object(i.useState)(null),v=a()(m,2),O=v[0],j=v[1],y=Object(i.useState)(!1),_=a()(y,2),w=_[0],S=_[1],P=Object(i.useState)(!1),C=a()(P,2),x=C[0],T=C[1],M=Object(i.useState)(!1),N=a()(M,2),L=N[0],A=N[1],D=Object(i.useState)(null),F=a()(D,2),I=F[0],U=F[1],z=Object(i.useState)(null),q=a()(z,2),B=q[0],Q=q[1],R=Object(i.useState)(null),W=a()(R,2),H=W[0],V=W[1],Y=Object(i.useState)(null),J=a()(Y,2),K=J[0],$=J[1],G=Object(i.useState)(null),X=a()(G,2),Z=X[0],ee=X[1],te=Object(i.useState)(null),ne=a()(te,2),re=ne[0],oe=ne[1],se=Object(i.useState)(""),ae=a()(se,2),ie=ae[0],ce=ae[1],le=Object(k.__)("An unknown error has occurred.","bluehost-wordpress-plugin"),ue=function(){var e=p()(d.a.mark((function e(t){var n;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return T(!1),A(!0),f(null),e.prev=3,e.next=6,g()(t);case 6:if(!(n=e.sent).hasOwnProperty("status")||"error"!==n.status){e.next=9;break}throw new Error(n.message);case 9:return A(!1),e.abrupt("return",n);case 13:return e.prev=13,e.t0=e.catch(3),A(!1),T(!0),f(("object"===E()(e.t0)?e.t0.message:e.t0)||le),e.abrupt("return",null);case 19:case"end":return e.stop()}}),e,null,[[3,13]])})));return function(_x){return e.apply(this,arguments)}}(),pe=function(e){e.hasOwnProperty("stagingExists")&&j(e.stagingExists),e.hasOwnProperty("currentEnvironment")&&l("production"===e.currentEnvironment),e.hasOwnProperty("productionDir")&&U(e.productionDir),e.hasOwnProperty("productionThumbnailUrl")&&Q(e.productionThumbnailUrl),e.hasOwnProperty("productionUrl")&&V(e.productionUrl),e.hasOwnProperty("stagingDir")&&$(e.stagingDir),e.hasOwnProperty("stagingThumbnailUrl")&&ee(e.stagingThumbnailUrl),e.hasOwnProperty("stagingUrl")&&oe(e.stagingUrl),e.hasOwnProperty("creationDate")&&r(e.creationDate)};function he(){return(he=p()(d.a.mark((function e(){var t;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return S(!0),e.next=3,ue({path:"/bluehost/v1/staging",method:"POST"});case 3:(t=e.sent)&&(pe(t),f(t.message),T("error"===t.status)),S(!1);case 6:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function de(){return(de=p()(d.a.mark((function e(){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,ue({path:"/bluehost/v1/staging",method:"DELETE"});case 2:e.sent&&(j(!1),f(Object(k.__)("Staging website destroyed.","bluehost-wordpress-plugin")));case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function be(){return(be=p()(d.a.mark((function e(t){var n;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return ce(t),e.next=3,ue({path:"/bluehost/v1/staging/switch-to?env=".concat(t)});case 3:(n=e.sent)&&n.hasOwnProperty("load_page")&&(window.location.href=n.load_page);case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function ge(){return(ge=p()(d.a.mark((function e(){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,ue({path:"/bluehost/v1/staging/clone",method:"POST"});case 2:e.sent&&f(Object(k.__)("Website cloned successfully.","bluehost-wordpress-plugin"));case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function fe(){return(fe=p()(d.a.mark((function e(){var t,n=arguments;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:"all",e.next=3,ue({path:"/bluehost/v1/staging/deploy?type=".concat(t),method:"POST"});case 3:e.sent&&f(Object(k.__)("Changes deployed successfully.","bluehost-wordpress-plugin"));case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}return Object(i.useEffect)((function(){ue({path:"/bluehost/v1/staging"}).then(pe)}),[]),[{creationDate:n,hasStaging:O,isCreatingStaging:w,isError:x,isProduction:c,isLoading:L,notice:b,productionDir:I,productionThumbnailUrl:B,productionUrl:H,stagingDir:K,stagingThumbnailUrl:Z,stagingUrl:re,switchingTo:ie},{cloneEnv:function(){return ge.apply(this,arguments)},createEnv:function(){return he.apply(this,arguments)},deleteEnv:function(){return de.apply(this,arguments)},deployChanges:function(){return fe.apply(this,arguments)},setNotice:f,switchToEnv:function(e){return be.apply(this,arguments)}}]}},136:function(e,t,n){},137:function(e,t,n){},138:function(e,t,n){"use strict";n.d(t,"a",(function(){return g})),n.d(t,"b",(function(){return v})),n.d(t,"c",(function(){return M}));var r=n(14),o=n.n(r),s=n(1),a=n(10),i=n(26),c=n(2),l=n(3),u=n.n(l),p=n(5),h=n(133),d=n(8),b=n(12),g=function(e){var t=e.type,n=void 0===t?"base":t,r=e.descriptivePageTitle,l=void 0!==r&&r,g=o()(e,["type","descriptivePageTitle"]),f=document.querySelector(".bwa-route-contents"),m=Object(d.useLocation)(),v=Object(b.useSelect)((function(e){return e("bluehost/plugin").getTopLevelPages()}),[]);if(null==v)return!1;var O=function(){var e=Object(c.__)("Bluehost WordPress Plugin","bluehost-wordpress-plugin"),t=document.querySelector("h2");return!1!==l?l:null!==t?t.innerText:e};return Object(s.useEffect)((function(){var e,t,n,r,o;Object(a.d)(v),Object(a.c)((e=!1,t=m.pathname,(n=Object(p.keyBy)(v,"path"))[t]?e=n[t].slug:v.forEach((function(n){t.includes(n.path)&&(e=n.slug)})),e)),f.focus({preventScroll:!0}),r=m,o=O(),void 0!==r.state&&void 0!==r.state.redirect&&"unspecified-or-root"===r.state.redirect||Object(h.speak)(o,"assertive"),Object(a.g)(m,O())}),[m.pathname]),Object(s.createElement)("section",{className:u()(["component-template-"+n,"base-template","animated","fadeIn","page-fade-speed",g.className?g.className:null])},Object(s.createElement)(i.l,null),g.children)},f=n(11),m=n.n(f),v=(n(136),function(e){var t=e.type,n=void 0===t?"common":t,r=e.children,a=o()(e,["type","children"]);return Object(s.createElement)(g,m()({type:n},a),r)}),O=n(9),j=n.n(O),y=n(38),_=n.n(y),w=n(4),E=n.n(w),k=(n(137),n(6)),S=n(135),P=n(7);function C(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?C(Object(n),!0).forEach((function(t){j()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var T=[{label:Object(c.__)("Popular","bluehost-wordpress-plugin"),value:"sort-sales-desc"},{label:Object(c.__)("Price (High to Low)","bluehost-wordpress-plugin"),value:"sort-price-desc"},{label:Object(c.__)("Price (Low to High)","bluehost-wordpress-plugin"),value:"sort-price-asc"},{label:Object(c.__)("Date Added","bluehost-wordpress-plugin"),value:"sort-date-desc"}],M=function(e){var t=e.type,n=void 0===t?"marketplace":t,r=e.className,a=void 0===r?"":r,l=e.isLoading,p=e.payload,h=e.render,d=e.marketplaceType,b=void 0===d?"themes":d,g=o()(e,["type","className","isLoading","payload","render","marketplaceType"]),f=Object(S.a)(),O=E()(f,2),j=O[0].favorites,y=O[1],w=y.hasFavorite,C=y.toggleFavorite,M=Object(S.c)(j),N=E()(M,1)[0],L=Object(S.f)(),A=E()(L,2),D=A[0],F=D.items,I=D.itemsPerPage,U=D.pageCount,z=D.pageNumber,q=A[1],B=q.setCollection,Q=q.setPageNumber,R=Object(s.useState)("sort-sales-desc"),W=E()(R,2),H=W[0],V=W[1],Y=Object(S.e)(),J=E()(Y,1)[0],K=Object(S.d)(),$=E()(K,2),G=$[0].query,X=$[1],Z=X.search,ee=X.setQuery;return a=u()("bluehost-marketplace",a),Object(s.useEffect)((function(){var e=p.items||[],t=H.split("-"),n=E()(t,3),r=n[0],o=n[1],s=n[2];e="filter"===r?N(J(e,"sales"),o):J(e,o,s),e=Z(e,G),B(e),Q(1)}),[p,H,G]),Object(s.useEffect)((function(){window.scrollTo(0,0)}),[z]),Object(s.createElement)(v,m()({type:n,className:a,marketplaceType:b},g),Object(s.createElement)("section",{className:"".concat(a,"__header")},Object(s.createElement)("div",{className:"".concat(a,"__header-primary")},Object(s.createElement)(k.d,{level:"h2",size:1,className:"marketplace-page-title"},function(e){switch(e){case"plugins":return Object(c.__)("Premium Plugins","bluehost-wordpress-plugin");case"services":return Object(c.__)("Premium Services","bluehost-wordpress-plugin");default:return Object(c.__)("Premium Themes","bluehost-wordpress-plugin")}}(b)),Object(s.createElement)("div",{className:"".concat(a,"__pagination-container")},Object(s.createElement)(k.g,{callback:Q,currentPage:z,pageCount:U}))),Object(s.createElement)("div",{className:"".concat(a,"__header-secondary")},Object(s.createElement)(i.q,{value:G,onChange:ee}),Object(s.createElement)(k.c,{id:"sort-filter",label:Object(c.__)("Sort By","bluehost-wordpress-plugin"),onChange:function(e){return V(e)},options:T,value:H,width:178}))),Object(s.createElement)("div",{className:"".concat(a,"__content")},l?Object(s.createElement)(i.p,null,_()(Array(I).keys()).map((function(e){return Object(s.createElement)(i.o,{key:e})}))):F&&F.length?Object(s.createElement)(i.p,null,F.map((function(e){return h({item:x(x({},e),{},{marketplaceType:b}),hasFavorite:w,toggleFavorite:C})}))):"filter-favorites"===H?Object(s.createElement)("div",{className:"bluehost-no-results"},Object(s.createElement)(P.v,null),Object(s.createElement)("h2",null,Object(c.__)("You don't have any favorites yet.","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(c.__)("Add favorites by starring items you like.","bluehost-wordpress-plugin")),Object(s.createElement)("a",{href:"#",onClick:function(e){e.preventDefault(),V("sort-sales-desc")}},function(){switch(b){case"plugins":return Object(c.__)("View Plugins","bluehost-wordpress-plugin");case"services":return Object(c.__)("View Services","bluehost-wordpress-plugin");default:return Object(c.__)("View Themes","bluehost-wordpress-plugin")}}())):Object(s.createElement)(i.i,null)),Object(s.createElement)("footer",{className:"".concat(a,"__footer")},Object(s.createElement)("div",{className:"".concat(a,"__ad")}),Object(s.createElement)(k.g,{callback:Q,currentPage:z,pageCount:U})))}},139:function(e,t,n){e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){function r(e){return(r="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)}var o=n(1),s=n(7),a=s.get,i=(s.deepValue,s.isArray),c=function(){function e(t,n){var r=n.location,o=void 0===r?0:r,s=n.distance,i=void 0===s?100:s,c=n.threshold,l=void 0===c?.6:c,u=n.maxPatternLength,p=void 0===u?32:u,h=n.caseSensitive,d=void 0!==h&&h,b=n.tokenSeparator,g=void 0===b?/ +/g:b,f=n.findAllMatches,m=void 0!==f&&f,v=n.minMatchCharLength,O=void 0===v?1:v,j=n.id,y=void 0===j?null:j,_=n.keys,w=void 0===_?[]:_,E=n.shouldSort,k=void 0===E||E,S=n.getFn,P=void 0===S?a:S,C=n.sortFn,x=void 0===C?function(e,t){return e.score-t.score}:C,T=n.tokenize,M=void 0!==T&&T,N=n.matchAllTokens,L=void 0!==N&&N,A=n.includeMatches,D=void 0!==A&&A,F=n.includeScore,I=void 0!==F&&F,U=n.verbose,z=void 0!==U&&U;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options={location:o,distance:i,threshold:l,maxPatternLength:p,isCaseSensitive:d,tokenSeparator:g,findAllMatches:m,minMatchCharLength:O,id:y,keys:w,includeMatches:D,includeScore:I,shouldSort:k,getFn:P,sortFn:x,verbose:z,tokenize:M,matchAllTokens:L},this.setCollection(t),this._processKeys(w)}var t;return(t=[{key:"setCollection",value:function(e){return this.list=e,e}},{key:"_processKeys",value:function(e){if(this._keyWeights={},this._keyNames=[],e.length&&"string"==typeof e[0])for(var t=0,n=e.length;t<n;t+=1){var r=e[t];this._keyWeights[r]=1,this._keyNames.push(r)}else{for(var o=null,s=null,a=0,i=0,c=e.length;i<c;i+=1){var l=e[i];if(!l.hasOwnProperty("name"))throw new Error('Missing "name" property in key object');var u=l.name;if(this._keyNames.push(u),!l.hasOwnProperty("weight"))throw new Error('Missing "weight" property in key object');var p=l.weight;if(p<0||p>1)throw new Error('"weight" property in key must bein the range of [0, 1)');s=null==s?p:Math.max(s,p),o=null==o?p:Math.min(o,p),this._keyWeights[u]=p,a+=p}if(a>1)throw new Error("Total of weights cannot exceed 1")}}},{key:"search",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{limit:!1};this._log('---------\nSearch pattern: "'.concat(e,'"'));var n=this._prepareSearchers(e),r=n.tokenSearchers,o=n.fullSearcher,s=this._search(r,o);return this._computeScore(s),this.options.shouldSort&&this._sort(s),t.limit&&"number"==typeof t.limit&&(s=s.slice(0,t.limit)),this._format(s)}},{key:"_prepareSearchers",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=[];if(this.options.tokenize)for(var n=e.split(this.options.tokenSeparator),r=0,s=n.length;r<s;r+=1)t.push(new o(n[r],this.options));return{tokenSearchers:t,fullSearcher:new o(e,this.options)}}},{key:"_search",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0,n=this.list,r={},o=[];if("string"==typeof n[0]){for(var s=0,a=n.length;s<a;s+=1)this._analyze({key:"",value:n[s],record:s,index:s},{resultMap:r,results:o,tokenSearchers:e,fullSearcher:t});return o}for(var i=0,c=n.length;i<c;i+=1)for(var l=n[i],u=0,p=this._keyNames.length;u<p;u+=1){var h=this._keyNames[u];this._analyze({key:h,value:this.options.getFn(l,h),record:l,index:i},{resultMap:r,results:o,tokenSearchers:e,fullSearcher:t})}return o}},{key:"_analyze",value:function(e,t){var n=this,r=e.key,o=e.arrayIndex,s=void 0===o?-1:o,a=e.value,c=e.record,l=e.index,u=t.tokenSearchers,p=void 0===u?[]:u,h=t.fullSearcher,d=t.resultMap,b=void 0===d?{}:d,g=t.results,f=void 0===g?[]:g;!function e(t,o,s,a){if(null!=o)if("string"==typeof o){var c=!1,l=-1,u=0;n._log("\nKey: ".concat(""===r?"--":r));var d=h.search(o);if(n._log('Full text: "'.concat(o,'", score: ').concat(d.score)),n.options.tokenize){for(var g=o.split(n.options.tokenSeparator),m=g.length,v=[],O=0,j=p.length;O<j;O+=1){var y=p[O];n._log('\nPattern: "'.concat(y.pattern,'"'));for(var _=!1,w=0;w<m;w+=1){var E=g[w],k=y.search(E),S={};k.isMatch?(S[E]=k.score,c=!0,_=!0,v.push(k.score)):(S[E]=1,n.options.matchAllTokens||v.push(1)),n._log('Token: "'.concat(E,'", score: ').concat(S[E]))}_&&(u+=1)}l=v[0];for(var P=v.length,C=1;C<P;C+=1)l+=v[C];l/=P,n._log("Token score average:",l)}var x=d.score;l>-1&&(x=(x+l)/2),n._log("Score average:",x);var T=!n.options.tokenize||!n.options.matchAllTokens||u>=p.length;if(n._log("\nCheck Matches: ".concat(T)),(c||d.isMatch)&&T){var M={key:r,arrayIndex:t,value:o,score:x};n.options.includeMatches&&(M.matchedIndices=d.matchedIndices);var N=b[a];N?N.output.push(M):(b[a]={item:s,output:[M]},f.push(b[a]))}}else if(i(o))for(var L=0,A=o.length;L<A;L+=1)e(L,o[L],s,a)}(s,a,c,l)}},{key:"_computeScore",value:function(e){this._log("\n\nComputing score:\n");for(var t=this._keyWeights,n=!!Object.keys(t).length,r=0,o=e.length;r<o;r+=1){for(var s=e[r],a=s.output,i=a.length,c=1,l=0;l<i;l+=1){var u=a[l],p=u.key,h=n?t[p]:1,d=0===u.score&&t&&t[p]>0?Number.EPSILON:u.score;c*=Math.pow(d,h)}s.score=c,this._log(s)}}},{key:"_sort",value:function(e){this._log("\n\nSorting...."),e.sort(this.options.sortFn)}},{key:"_format",value:function(e){var t=[];if(this.options.verbose){var n=[];this._log("\n\nOutput:\n\n",JSON.stringify(e,(function(e,t){if("object"===r(t)&&null!==t){if(-1!==n.indexOf(t))return;n.push(t)}return t}),2)),n=null}var o=[];this.options.includeMatches&&o.push((function(e,t){var n=e.output;t.matches=[];for(var r=0,o=n.length;r<o;r+=1){var s=n[r];if(0!==s.matchedIndices.length){var a={indices:s.matchedIndices,value:s.value};s.key&&(a.key=s.key),s.hasOwnProperty("arrayIndex")&&s.arrayIndex>-1&&(a.arrayIndex=s.arrayIndex),t.matches.push(a)}}})),this.options.includeScore&&o.push((function(e,t){t.score=e.score}));for(var s=0,a=e.length;s<a;s+=1){var i=e[s];if(this.options.id&&(i.item=this.options.getFn(i.item,this.options.id)[0]),o.length){for(var c={item:i.item},l=0,u=o.length;l<u;l+=1)o[l](i,c);t.push(c)}else t.push(i.item)}return t}},{key:"_log",value:function(){var e;this.options.verbose&&(e=console).log.apply(e,arguments)}}])&&function(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)}}(e.prototype,t),e}();e.exports=c},function(e,t,n){var r=n(2),o=n(3),s=n(6),a=function(){function e(t,n){var r=n.location,o=void 0===r?0:r,a=n.distance,i=void 0===a?100:a,c=n.threshold,l=void 0===c?.6:c,u=n.maxPatternLength,p=void 0===u?32:u,h=n.isCaseSensitive,d=void 0!==h&&h,b=n.tokenSeparator,g=void 0===b?/ +/g:b,f=n.findAllMatches,m=void 0!==f&&f,v=n.minMatchCharLength,O=void 0===v?1:v,j=n.includeMatches,y=void 0!==j&&j;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options={location:o,distance:i,threshold:l,maxPatternLength:p,isCaseSensitive:d,tokenSeparator:g,findAllMatches:m,includeMatches:y,minMatchCharLength:O},this.pattern=d?t:t.toLowerCase(),this.pattern.length<=p&&(this.patternAlphabet=s(this.pattern))}var t;return(t=[{key:"search",value:function(e){var t=this.options,n=t.isCaseSensitive,s=t.includeMatches;if(n||(e=e.toLowerCase()),this.pattern===e){var a={isMatch:!0,score:0};return s&&(a.matchedIndices=[[0,e.length-1]]),a}var i=this.options,c=i.maxPatternLength,l=i.tokenSeparator;if(this.pattern.length>c)return r(e,this.pattern,l);var u=this.options,p=u.location,h=u.distance,d=u.threshold,b=u.findAllMatches,g=u.minMatchCharLength;return o(e,this.pattern,this.patternAlphabet,{location:p,distance:h,threshold:d,findAllMatches:b,minMatchCharLength:g,includeMatches:s})}}])&&function(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)}}(e.prototype,t),e}();e.exports=a},function(e,t){var n=/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g;e.exports=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:/ +/g,o=new RegExp(t.replace(n,"\\$&").replace(r,"|")),s=e.match(o),a=!!s,i=[];if(a)for(var c=0,l=s.length;c<l;c+=1){var u=s[c];i.push([e.indexOf(u),u.length-1])}return{score:a?.5:1,isMatch:a,matchedIndices:i}}},function(e,t,n){var r=n(4),o=n(5);e.exports=function(e,t,n,s){for(var a=s.location,i=void 0===a?0:a,c=s.distance,l=void 0===c?100:c,u=s.threshold,p=void 0===u?.6:u,h=s.findAllMatches,d=void 0!==h&&h,b=s.minMatchCharLength,g=void 0===b?1:b,f=s.includeMatches,m=void 0!==f&&f,v=i,O=e.length,j=p,y=e.indexOf(t,v),_=t.length,w=[],E=0;E<O;E+=1)w[E]=0;if(-1!==y){var k=r(t,{errors:0,currentLocation:y,expectedLocation:v,distance:l});if(j=Math.min(k,j),-1!==(y=e.lastIndexOf(t,v+_))){var S=r(t,{errors:0,currentLocation:y,expectedLocation:v,distance:l});j=Math.min(S,j)}}y=-1;for(var P=[],C=1,x=_+O,T=1<<(_<=31?_-1:30),M=0;M<_;M+=1){for(var N=0,L=x;N<L;)r(t,{errors:M,currentLocation:v+L,expectedLocation:v,distance:l})<=j?N=L:x=L,L=Math.floor((x-N)/2+N);x=L;var A=Math.max(1,v-L+1),D=d?O:Math.min(v+L,O)+_,F=Array(D+2);F[D+1]=(1<<M)-1;for(var I=D;I>=A;I-=1){var U=I-1,z=n[e.charAt(U)];if(z&&(w[U]=1),F[I]=(F[I+1]<<1|1)&z,0!==M&&(F[I]|=(P[I+1]|P[I])<<1|1|P[I+1]),F[I]&T&&(C=r(t,{errors:M,currentLocation:U,expectedLocation:v,distance:l}))<=j){if(j=C,(y=U)<=v)break;A=Math.max(1,2*v-y)}}if(r(t,{errors:M+1,currentLocation:v,expectedLocation:v,distance:l})>j)break;P=F}var q={isMatch:y>=0,score:0===C?.001:C};return m&&(q.matchedIndices=o(w,g)),q}},function(e,t){e.exports=function(e,t){var n=t.errors,r=void 0===n?0:n,o=t.currentLocation,s=void 0===o?0:o,a=t.expectedLocation,i=void 0===a?0:a,c=t.distance,l=void 0===c?100:c,u=r/e.length,p=Math.abs(i-s);return l?u+p/l:p?1:u}},function(e,t){e.exports=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=[],r=-1,o=-1,s=0,a=e.length;s<a;s+=1){var i=e[s];i&&-1===r?r=s:i||-1===r||((o=s-1)-r+1>=t&&n.push([r,o]),r=-1)}return e[s-1]&&s-r>=t&&n.push([r,s-1]),n}},function(e,t){e.exports=function(e){for(var t={},n=e.length,r=0;r<n;r+=1)t[e.charAt(r)]=0;for(var o=0;o<n;o+=1)t[e.charAt(o)]|=1<<n-o-1;return t}},function(e,t){var n=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},r=function(e){return null==e?"":function(e){if("string"==typeof e)return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)},o=function(e){return"string"==typeof e},s=function(e){return"number"==typeof e};e.exports={get:function(e,t){var a=[];return function e(t,i){if(i){var c=i.indexOf("."),l=i,u=null;-1!==c&&(l=i.slice(0,c),u=i.slice(c+1));var p=t[l];if(null!=p)if(u||!o(p)&&!s(p))if(n(p))for(var h=0,d=p.length;h<d;h+=1)e(p[h],u);else u&&e(p,u);else a.push(r(p))}else a.push(t)}(e,t),a},isArray:n,isString:o,isNum:s,toString:r}}])},166:function(e,t){e.exports=function(e){if(null==e)throw new TypeError("Cannot destructure undefined")},e.exports.default=e.exports,e.exports.__esModule=!0},203:function(e,t,n){},260:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return y}));var r=n(4),o=n.n(r),s=n(1),a=(n(203),n(26)),i=n(6),c=n(7),l=n(2),u=n(138),p=n(166),h=n.n(p);function d(e){var t=e.children;return t||(t=[Object(l.__)("You can clone your production site to update your staging site with new content.","bluehost-wordpress-plugin"),Object(l.__)("Making changes in a staging site doesn’t effect your live site.","bluehost-wordpress-plugin"),Object(l.__)("If you want changes in a staging site to take effect on your live site, deploy them.","bluehost-wordpress-plugin")]),Object(s.createElement)(a.r,{settings:{adaptiveHeight:!0,arrows:!1,autoplay:!0,autoplaySpeed:1e4,dots:!0,infinite:!0,pauseOnDotsHover:!0,pauseOnHover:!0}},s.Children.map(t,(function(e){return Object(s.createElement)("p",null,Object(s.createElement)("span",null,Object(l.__)("Tip:","bluehost-wordpress-plugin"))," ",e)})))}function b(e){return h()(e),Object(s.createElement)(a.k,{className:"bluehost-staging__overlay"},Object(s.createElement)("h1",null,Object(l.__)("Cloning Production Site","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(l.__)("This should only take a minute","bluehost-wordpress-plugin")),Object(s.createElement)("img",{className:"bluehost-staging__overlay-image",src:c.Q,width:"555",height:"421",alt:""}),Object(s.createElement)(d,null))}var g=function(e){var t=e.onClick,n=e.onClose;return Object(s.createElement)(a.h,{actionsComponent:Object(s.createElement)(s.Fragment,null,Object(s.createElement)(a.t,null,Object(l.__)("This action cannot be undone","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{onClick:n},Object(l.__)("Cancel","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{isPrimary:!0,onClick:t},Object(l.__)("Clone","bluehost-wordpress-plugin"))),onRequestClose:n,title:Object(l.__)("Clone production to staging?","bluehost-wordpress-plugin")},Object(s.createElement)("p",null,Object(l.__)("Are you sure you want to clone production to staging? This will permanently overwrite your staging site.","bluehost-wordpress-plugin")))};function f(e){return h()(e),Object(s.createElement)(a.k,{className:"bluehost-staging__overlay"},Object(s.createElement)("h1",null,Object(l.__)("Deleting Staging Site","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(l.__)("This should only take a minute","bluehost-wordpress-plugin")),Object(s.createElement)("img",{className:"bluehost-staging__overlay-image",src:c.Q,width:"555",height:"421",alt:""}),Object(s.createElement)(d,null))}var m=function(e){var t=e.onClick,n=e.onClose;return Object(s.createElement)(a.h,{actionsComponent:Object(s.createElement)(s.Fragment,null,Object(s.createElement)(a.t,null,Object(l.__)("This action cannot be undone","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{onClick:n},Object(l.__)("Cancel","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{isPrimary:!0,onClick:t},Object(l.__)("Delete","bluehost-wordpress-plugin"))),onRequestClose:n,title:Object(l.__)("Delete staging site?","bluehost-wordpress-plugin")},Object(s.createElement)("p",null,Object(l.__)("Are you sure you want to delete this staging site? This will permanently delete the staging instance from your site.","bluehost-wordpress-plugin")))};function v(e){var t=e.type,n=void 0===t?"all":t;return Object(s.createElement)(a.k,{className:"bluehost-staging__overlay"},Object(s.createElement)("h1",null,function(){switch(n){case"db":return Object(l.__)("Deploying Database to Production Site","bluehost-wordpress-plugin");case"files":return Object(l.__)("Deploying Files to Production Site","bluehost-wordpress-plugin");default:return Object(l.__)("Deploying to Production Site","bluehost-wordpress-plugin")}}()),Object(s.createElement)("p",null,Object(l.__)("This should only take a minute","bluehost-wordpress-plugin")),Object(s.createElement)("img",{className:"bluehost-staging__overlay-image",src:c.Q,width:"555",height:"421",alt:""}),Object(s.createElement)(d,null))}var O=function(e){var t,n,r=e.onClick,o=e.onClose,c=e.type;switch(void 0===c?"all":c){case"db":t=Object(l.__)("Deploy Database to Production?","bluehost-wordpress-plugin"),n=Object(l.__)("This will override your production site. Are you sure you want to deploy the database from staging to production?","bluehost-wordpress-plugin");break;case"files":t=Object(l.__)("Deploy Files to Production?","bluehost-wordpress-plugin"),n=Object(l.__)("This will override your production site. Are you sure you want to deploy all staging files to production?","bluehost-wordpress-plugin");break;default:t=Object(l.__)("Deploy to Production?","bluehost-wordpress-plugin"),n=Object(l.__)("This will override your production site. Are you sure you want to deploy everything from staging to production?","bluehost-wordpress-plugin")}return Object(s.createElement)(a.h,{actionsComponent:Object(s.createElement)(s.Fragment,null,Object(s.createElement)(a.t,null,Object(l.__)("This action cannot be undone","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{onClick:o},Object(l.__)("Cancel","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{className:"--delete",isPrimary:!0,onClick:r},Object(l.__)("Deploy","bluehost-wordpress-plugin"))),onRequestClose:o,title:t},Object(s.createElement)("p",null,n))},j=n(135);function y(){var e=Object(s.useState)("all"),t=o()(e,2),n=t[0],r=t[1],p=Object(s.useState)(!1),h=o()(p,2),y=h[0],_=h[1],w=Object(s.useState)(!1),E=o()(w,2),k=E[0],S=E[1],P=Object(s.useState)(!1),C=o()(P,2),x=C[0],T=C[1],M=Object(s.useState)(!1),N=o()(M,2),L=N[0],A=N[1],D=Object(s.useState)(!1),F=o()(D,2),I=F[0],U=F[1],z=Object(s.useState)(!1),q=o()(z,2),B=q[0],Q=q[1],R=Object(j.g)({}),W=o()(R,2),H=W[0],V=H.hasStaging,Y=H.isCreatingStaging,J=H.isError,K=H.isProduction,$=H.notice,G=(H.productionThumbnailUrl,H.productionUrl),X=(H.stagingThumbnailUrl,H.stagingUrl),Z=H.switchingTo,ee=W[1],te=ee.createEnv,ne=ee.cloneEnv,re=ee.deleteEnv,oe=ee.deployChanges,se=ee.setNotice,ae=ee.switchToEnv,ie=function(e){if($){var t=document.querySelector(".bluehost-snackbar");t&&!t.contains(e.target)&&se(null)}};return Object(s.useEffect)((function(){return $?document.addEventListener("mousedown",ie):document.removeEventListener("mousedown",ie),function(){document.removeEventListener("mousedown",ie)}}),[$]),Object(s.createElement)(u.b,{className:"bluehost-staging"},Object(s.createElement)(i.d,{level:"h2",size:1,className:"is-page-title"},Object(l.__)("Staging","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(l.__)("A staging site is a copy of your site where you can safely test changes before publishing them to your production site. It gives you a way to try new things, test updates, and then deploy them when you're ready.","bluehost-wordpress-plugin")),Object(s.createElement)("div",{className:"bluehost-staging__production-env"},Object(s.createElement)(i.d,{level:"h3",size:2},Object(l.__)("Production site","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(l.__)("This is your live website.","bluehost-wordpress-plugin")),Object(s.createElement)(a.e,{color:"green",deploymentActionsComponent:V&&Object(s.createElement)(i.b,{disabled:!K,isSecondary:!0,onClick:function(){return _(!0)}},Object(l.__)("Clone to Staging","bluehost-wordpress-plugin")),environmentName:Object(l.__)("Live Site","bluehost-wordpress-plugin"),radioButtonComponent:V&&Object(s.createElement)("label",null,K?Object(s.createElement)(c.A,null):Object(s.createElement)(c.z,null),Object(s.createElement)("span",{className:"sr-only"},Object(l.__)("Production","bluehost-wordpress-plugin")),Object(s.createElement)("input",{type:"radio",checked:!!K,onChange:function(){return ae("production")}})),title:G})),Object(s.createElement)("div",{className:"bluehost-staging__staging-env"},Object(s.createElement)(i.d,{level:"h3",size:2},Object(l.__)("Staging site","bluehost-wordpress-plugin")),Y?Object(s.createElement)("div",{className:"bluehost-staging__step --creation"},Object(s.createElement)(i.i,null),Object(s.createElement)("div",null,Object(l.__)("Creating your staging site. This usually takes a few minutes...","bluehost-wordpress-plugin")),Object(s.createElement)("p",null,Object(l.__)("You can wait or close this window and access your staging site from the staging menu after setup is complete.","bluehost-wordpress-plugin"))):V?Object(s.createElement)("div",{className:"bluehost-staging__step --ready"},Object(s.createElement)("p",null,Object(l.__)("This is an unpublished copy of your website.","bluehost-wordpress-plugin")),Object(s.createElement)(a.e,{color:"black",deploymentActionsComponent:Object(s.createElement)(a.d,{disabled:K,options:[{title:Object(l.__)("Deploy All Changes","bluehost-wordpress-plugin"),description:Object(l.__)("Deploy all changes you've made to the filesystem and database of your website.","bluehost-wordpress-plugin"),callback:function(){r("all"),T(!0)}},{title:Object(l.__)("Deploy Files Only","bluehost-wordpress-plugin"),description:Object(l.__)("This will only upload the files you've changed (i.e. html or css files).","bluehost-wordpress-plugin"),callback:function(){r("files"),T(!0)}},{title:Object(l.__)("Deploy Database","bluehost-wordpress-plugin"),description:Object(l.__)("Only upload changes you've made to the database on your staging server.","bluehost-wordpress-plugin"),callback:function(){r("db"),T(!0)}}],width:215}),environmentActionsComponent:K&&Object(s.createElement)(a.j,{label:Object(l.__)("Staging Options","bluehost-wordpress-plugin"),options:[{label:Object(l.__)("Delete","bluehost-wordpress-plugin"),callback:function(){return U(!0)}}]}),environmentName:Object(l.__)("Staging Site","bluehost-wordpress-plugin"),radioButtonComponent:Object(s.createElement)("label",null,K?Object(s.createElement)(c.z,null):Object(s.createElement)(c.A,null),Object(s.createElement)("span",{className:"sr-only"},Object(l.__)("Staging","bluehost-wordpress-plugin")),Object(s.createElement)("input",{type:"radio",checked:!K,onChange:function(){return ae("staging")}})),title:X})):Object(s.createElement)("div",{className:"bluehost-staging__step --default"},Object(s.createElement)("p",null,Object(l.__)("You don't have a staging site yet.","bluehost-wordpress-plugin")),Object(s.createElement)(i.b,{isPrimary:!0,onClick:te},Object(l.__)("Create Staging Site","bluehost-wordpress-plugin")))),$&&Object(s.createElement)(a.s,{status:J?"error":"success",title:J?Object(l.__)("Error","bluehost-wordpress-plugin"):Object(l.__)("Success","bluehost-wordpress-plugin"),isDismissible:!0,onRemove:function(){return se(null)}},Object(s.createElement)("p",null,$)),y&&Object(s.createElement)(g,{onClick:function(){_(!1),S(!0),ne().then((function(){return S(!1)}))},onClose:function(){return _(!1)}}),k&&Object(s.createElement)(b,null),I&&Object(s.createElement)(m,{onClick:function(){U(!1),Q(!0),re().then((function(){return Q(!1)}))},onClose:function(){return U(!1)}}),B&&Object(s.createElement)(f,null),x&&Object(s.createElement)(O,{onClick:function(){T(!1),A(!0),oe(n).then((function(){return A(!1)}))},onClose:function(){return T(!1)},type:n}),L&&Object(s.createElement)(v,{type:n}),Z&&Object(s.createElement)(a.k,{className:"bluehost-staging__overlay"},Object(s.createElement)("h1",null,Object(l.sprintf)(
/* translators: %s is replaced with the environment name (i.e. Production or Staging) */
Object(l.__)("Loading %s Site","bluehost-wordpress-plugin"),"production"===Z?Object(l.__)("Production","bluehost-wordpress-plugin"):Object(l.__)("Staging","bluehost-wordpress-plugin"))),Object(s.createElement)("p",null,Object(l.__)("This should only take a minute","bluehost-wordpress-plugin")),Object(s.createElement)("img",{className:"bluehost-staging__overlay-image",src:c.Q,width:"555",height:"421",alt:""}),Object(s.createElement)(d,null)))}}}]);

404 Not Found
[ LogOut ]