https://foriio.com/assets/js/components-CustomDomain-CustomDomainPage.580d52a78d1cd2d1b785.bundle.js
1"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[1826],{58095:(e,n,t)=>{t.r(n),t.d(n,{default:()=>Me}),t(98992),t(72577),t(81454);var o,i,r,a,l=t(96540),c=t(95093),u=t.n(c),d=t(61225),s=t(51510),m=(t(37550),t(41082)),p=t(44125),f=t(79312),g=t(63529),h=t(36324),y=t(77264),b=t(80462);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 x(e,n){for(var t=0;t<n.length;t++){var o=n[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,P(o.key),o)}}function v(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(v=function(){return!!e})()}function w(e){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},w(e)}function C(e,n){return C=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,n){return e.__proto__=n,e},C(e,n)}function E(e,n,t){return(n=P(n))in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function P(e){var n=function(e){if("object"!=_(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var t=n.call(e,"string");if("object"!=_(t))return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==_(n)?n:n+""}function j(e,n){return n||(n=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}var D=s.Ay.div.withConfig({displayName:"CustomDomainSearchForm__InputGroupContainer",componentId:"sc-lstl1v-0"})(["display:flex;flex-direction:row;justify-content:center;height:70px;",""],h.$_.tablet(o||(o=j(["\n height: 45px;\n "])))),O=s.Ay.input.withConfig({displayName:"CustomDomainSearchForm__TextInput",componentId:"sc-lstl1v-1"})(["font-family:'Noto Sans JP';border:1px solid #bdbdbd;box-sizing:border-box;border-radius:70px 0px 0px 70px;font-size:21px;height:70px;width:100%;padding:25px 30px;outline:none;&::placeholder{font-weight:500;color:#bdbdbd;}",""],h.$_.tablet(i||(i=j(["\n width: 100%;\n height: 42px;\n padding: 10px 17px;\n font-size: 14px;\n "])))),S=s.Ay.div.withConfig({displayName:"CustomDomainSearchForm__InputGroupText",componentId:"sc-lstl1v-2"})(["display:flex;flex-direction:row;align-items:center;color:#828282;font-size:28px;line-height:44px;letter-spacing:0.03em;background-color:#dddddd;padding:0 20px;",""],h.$_.tablet(r||(r=j(["\n border-radius: 0 70px 70px 0;\n font-size: 16px;\n line-height: 25px;\n height: 42px;\n "])))),A=(0,s.AH)(["border-radius:0px 70px 70px 0px;max-height:70px;font-size:21px;font-weight:500;",""],h.$_.tablet(a||(a=j(["\n border-radius: 70px;\n margin-top: 10px;\n width: 100%;\n max-height: 42px;\n font-size: 16px;\n "])))),N=s.Ay.div.withConfig({displayName:"CustomDomainSearchForm__ErrorMessage",componentId:"sc-lstl1v-3"})(["text-align:center;color:#eb5757;margin:12px 0 0 0;"]),I=(0,s.Ay)(p.n9).withConfig({displayName:"CustomDomainSearchForm__SearchButton",componentId:"sc-lstl1v-4"})([""," width:200px;"],A),z=function(e){function n(){var e;!function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,o=new Array(t),i=0;i<t;i++)o[i]=arguments[i];return E(e=function(e,n,t){return n=w(n),function(e,n){if(n&&("object"==_(n)||"function"==typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,v()?Reflect.construct(n,t||[],w(e).constructor):n.apply(e,t))}(this,n,[].concat(o)),"state",{domain:"",errorMessage:""}),E(e,"handleOnChangeCustomDomain",function(n){e.setState({domain:n.target.value.toLowerCase()})}),E(e,"resetSearchField",function(){e.setState({domain:""})}),E(e,"handleOnSubmitSearch",function(n){n.preventDefault();var t=e.props,o=t.dispatch,i=t.domainSearches,r=t.t,a=e.state.domain;if(i.some(function(e){return e.domain==="".concat(a,".com")}))return e.resetSearchField(),e.setState({errorMessage:r("domainRepeatError")}),setTimeout(function(){e.setState({errorMessage:""})},3e3);if(a){var l=a.replace(".com","").replace("www.","");o((0,g.Lay)("".concat(l,".com")))}(0,y.sx)({event:"GAEvent",category:"click: search-for-domain",action:"Clicked search domain button",label:"".concat(a)}),b.A.track("search_buy_new_domain",{searched_domain:a}),e.resetSearchField()}
1),E(e,"renderSearchButton",function(){var n=e.props,t=n.t,o=n.domainStatus.loading,i=n.isMobile;return l.createElement(I,{text:t("search"),icon:o?l.createElement(m.Nl,{color:"#fff",size:i?16:21}):l.createElement(m.WI,{color:"#fff",size:i?16:21}),type:"submit",disabled:o})}),e}return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&C(e,n)}(n,e),t=n,o=[{key:"render",value:function(){var e=this.props,n=e.t,t=e.isMobile,o=this.state,i=o.domain,r=o.errorMessage;return l.createElement(l.Fragment,null,l.createElement("form",{onSubmit:this.handleOnSubmitSearch},l.createElement(D,null,l.createElement(O,{value:i,onChange:this.handleOnChangeCustomDomain,placeholder:n("searchDomain")}),l.createElement(S,null,".com"),!t&&this.renderSearchButton()),t&&this.renderSearchButton()),r&&l.createElement(N,null,r))}}],o&&x(t.prototype,o),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,o}(l.Component);const $=(0,f.Tl)("customDomain")((0,h.Fb)((0,d.Ng)(function(e){return{domainStatus:e.domainStatus}})(z)));var k=t(85897),T=t(73200),G=t(69750),R=t(54625),F=t(56347),B=t(17264),L=t(54011);function M(e){return M="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},M(e)}var J,H,Y,K,U,W,q,Z,Q,V,X,ee,ne,te,oe,ie,re,ae,le,ce,ue,de=["small"];function se(e,n){for(var t=0;t<n.length;t++){var o=n[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,he(o.key),o)}}function me(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(me=function(){return!!e})()}function pe(e){return pe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},pe(e)}function fe(e,n){return fe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,n){return e.__proto__=n,e},fe(e,n)}function ge(e,n,t){return(n=he(n))in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function he(e){var n=function(e){if("object"!=M(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var t=n.call(e,"string");if("object"!=M(t))return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==M(n)?n:n+""}function ye(e,n){return n||(n=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}var be=s.Ay.div.withConfig({displayName:"CustomDomainPage__Container",componentId:"sc-11hjcdi-0"})(["margin-top:80px;display:flex;flex-direction:column;gap:44px;"," ",""],h.$_.tablet(J||(J=ye(["\n margin-top: 50px;\n gap: 32px;\n "]))),h.$_.phone(H||(H=ye(["\n gap: 24px;\n "])))),_e=s.Ay.div.withConfig({displayName:"CustomDomainPage__Title",componentId:"sc-11hjcdi-1"})(["font-family:'Noto Sans JP';font-weight:bold;font-size:32px;line-height:46px;text-align:center;color:#000;",""],h.$_.phone(Y||(Y=ye(["\n font-size: 28px;\n "])))),xe=s.Ay.div.withConfig({displayName:"CustomDomainPage__WhatIsDomain",componentId:"sc-11hjcdi-2"})(["font-family:'Noto Sans JP';font-weight:bold;font-size:24px;line-height:38px;text-align:center;letter-spacing:0.03em;color:#222222;margin-top:94px;margin-bottom:45px;",""],h.$_.tablet(K||(K=ye(["\n margin-top: 60px;\n margin-bottom: 0px;\n "])))),ve=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainGuidesContainer",componentId:"sc-11hjcdi-3"})(["display:flex;flex-direction:row;justify-content:space-between;",""],h.$_.tablet(U||(U=ye(["\n flex-direction: column;\n "])))),we=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainGuideContainer",componentId:"sc-11hjcdi-4"})(["display:flex;flex-direction:column;"]),Ce=(0,s.Ay)(we).withConfig({displayName:"CustomDomainPage__DomainGuideContainer2",componentId:"sc-11hjcdi-5"})(["margin:0 20px;",""],h.$_.tablet(W||(W=ye(["\n margin: 28px 0;\n "])))),Ee=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainGuideTitle",componentId:"sc-11hjcdi-6"})(["font-family:'Noto Sans JP';font-weight:500;font-size:21px;line-height:33px;letter-spacing:0.03em;color:#222222;margin-bottom:20px;"]),Pe=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainGuideDescription",componentId:"sc-11hjcdi-7"})(["font-family:'Noto Sans JP';font-size:15px;line-height:24px;letter-spacing:0.02em;color:#828282;white-space:pre-wrap;"]),je=s.Ay.div.withConfig({displayName:"CustomDomainPage__PageToggleContainer",componentId:"sc-11hjcdi-8"})(["box-sizing:border-box;display:flex;justify-content:space-between;width:100%;border-radius:70px;background-color:#f2f2f2;padding:15px;height:100px;",""],h.$_.tablet(q||(q=ye(["\n height: 45px;\n padding: 0;\n "])))),De=function(e){e.small;var n=function(e,n){if(null==e)return{};var t,o,i=function(e,n){if(null==e)return{};var t={};for(var o in e)if({}.hasOwnProperty.call(e,o)){if(-1!==n.indexOf(o))continue;t[o]=e[o]}return t}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(o=0;o<r.length;o++)t=r[o],-1===n.indexOf(t)&&{}.propertyIsEnumerable.call(e,t)&&(i[t]=e[t])}return i}(e,de);return l.createElement(R.N_,n)},Oe=(0,s.Ay)(De).withConfig({displayName:"CustomDomainPage__StyledLink",componentId:"sc-11hjcdi-9"})(["width:50%;",""],h.$_.phone(Z||(Z=ye(["\n width: ",";\n "])),function(e){return e.small?"40%":"60%"})),Se=s.Ay.p.withConfig({displayName:"CustomDomainPage__ToggleText",componentId:"sc-11hjcdi-10"})(["background-color:",";color:",";margin:0;align-items:center;border-radius:70px;display:flex;font-size:21px;font-weight:700;height:100%;justify-content:center;line-height:158%;text-align:center;width:100%;"," ",""],function(e){return e.active?"#5863F8":"transparent"}
1,function(e){return e.active?"#ffffff":"#222222"},h.$_.tablet(Q||(Q=ye(["\n font-size: 18px;\n "]))),h.$_.phone(V||(V=ye(["\n font-size: 12px;\n "])))),Ae=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainContainer",componentId:"sc-11hjcdi-11"})(["display:flex;flex-direction:column;"]),Ne=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainHeadingRow",componentId:"sc-11hjcdi-12"})(["padding:12px 0;border-bottom:solid 1px #dddddd;display:grid;grid-template-columns:1fr 1fr 140px;grid-column-gap:18px;"]),Ie=s.Ay.h5.withConfig({displayName:"CustomDomainPage__DomainTitle",componentId:"sc-11hjcdi-13"})(["margin:0;color:#222;font-size:24px;font-weight:700;",""],h.$_.tablet(X||(X=ye(["\n grid-column: 1 / span 2;\n font-size: 20px;\n "])))),ze=(0,s.Ay)(Ie).withConfig({displayName:"CustomDomainPage__DomainTitleRight",componentId:"sc-11hjcdi-14"})(["margin:0;text-align:right;",""],h.$_.tablet(ee||(ee=ye(["\n display: none;\n "])))),$e=(0,s.i7)(["0%{opacity:0;}100%{opacity:1;}"]),ke=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainRow",componentId:"sc-11hjcdi-15"})(["animation:"," 0.5s ease-in-out;align-items:center;border-bottom:solid 1px #dddddd;display:grid;grid-template-columns:1fr 1fr 140px;grid-column-gap:18px;padding:30px 0;",""],$e,h.$_.tablet(ne||(ne=ye(["\n display: none;\n "])))),Te=(0,s.Ay)(ke).withConfig({displayName:"CustomDomainPage__DomainRowMobile",componentId:"sc-11hjcdi-16"})(["display:none;grid-template-columns:3fr 4fr 3fr;grid-template-rows:auto auto;",""],h.$_.tablet(te||(te=ye(["\n animation: "," 0.5s ease-in-out;\n display: grid;\n padding: 12px 0;\n row-gap: 6px;\n "])),$e)),Ge=s.Ay.p.withConfig({displayName:"CustomDomainPage__DomainName",componentId:"sc-11hjcdi-17"})(["margin:0;flex:1;color:#222;font-size:24px;font-weight:500;"," ",""],h.$_.tablet(oe||(oe=ye(["\n grid-column: 1 / span 2;\n word-wrap: break-word;\n "]))),h.$_.phone(ie||(ie=ye(["\n font-size: 20px;\n "])))),Re=s.Ay.div.withConfig({displayName:"CustomDomainPage__DomainPriceContainer",componentId:"sc-11hjcdi-18"})(["display:flex;align-items:center;justify-content:right;gap:6px;",""],h.$_.tablet(re||(re=ye(["\n grid-column: 1 / span 2;\n grid-row: 2;\n justify-content: left;\n "])))),Fe=s.Ay.p.withConfig({displayName:"CustomDomainPage__PriceText",componentId:"sc-11hjcdi-19"})(["margin:0;color:#4f4f4f;text-align:right;font-size:22px;font-weight:500;"," ",""],h.$_.tablet(ae||(ae=ye(["\n text-align: left;\n "]))),h.$_.phone(le||(le=ye(["\n font-size: 16px;\n "])))),Be=(0,s.Ay)(p.n9).withConfig({displayName:"CustomDomainPage__RegisterButton",componentId:"sc-11hjcdi-20"})(["border-radius:40px;width:140px;"," ",""],h.$_.tablet(ce||(ce=ye(["\n grid-column: 3;\n margin-left: auto;\n "]))),h.$_.phone(ue||(ue=ye(["\n font-size: 15px;\n width: 110px;\n "])))),Le=function(e){function n(){var e;!function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,o=new Array(t),i=0;i<t;i++)o[i]=arguments[i];return ge(e=function(e,n,t){return n=pe(n),function(e,n){if(n&&("object"==M(n)||"function"==typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,me()?Reflect.construct(n,t||[],pe(e).constructor):n.apply(e,t))}(this,n,[].concat(o)),"state",{}),ge(e,"handleOnClickRegister",function(n,t){var o=e.props.history,i=(0,L.A)();B.A.set("register_domain_funnel_id",i,{path:"/"}),(0,y.sx)({event:"GAEvent",category:"click: register-domain",action:"Clicked resgister domain",label:"".concat(n)}),b.A.track("register_domain_click",{domain_name:n,price_per_year:t,register_domain_funnel_id:i}),o.push("/domain/registration/details",{domain:n})}),e}return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&fe(e,n)}(n,e),t=n,o=[{key:"componentDidMount",value:function(){var e=this.props.dispatch;e((0,g.Y5$)()),e((0,g.nZe)()),e((0,g.Pi6)())}},{key:"render",value:function(){var e,n=this,t=this.props,o=t.t,i=t.auth,r=t.domains,a=r.loaded,c=r.data,d=t.domainSearches,s=t.domainPrice,m=t.domainPlans;
1if(a&&(c.length||i.user.subscription.settings.custom_domain)){if(null==c?void 0:c.find(function(e){return u()().isBefore(e.expires_at)}))return l.createElement(F.rd,{to:"/settings/domain"});if(i.user.subscription.settings.custom_domain)return l.createElement(F.rd,{to:"/settings/domain"})}return l.createElement(l.Fragment,null,l.createElement(be,null,l.createElement(_e,null,o("acquireDomain")),l.createElement(je,null,l.createElement(Oe,{small:!0,to:"/domain"},l.createElement(Se,{active:!0},o("purchaseDomain"))),l.createElement(Oe,{to:"/domain/owned"},l.createElement(Se,null,o("setOwnedDomain")))),(!a||d.loading||m.loading)&&l.createElement(k.default,null),a&&d.loaded&&m.loaded&&l.createElement(l.Fragment,null,l.createElement("div",null,l.createElement($,{domainSearches:null==d?void 0:d.data})),l.createElement(Ae,null,l.createElement(Ne,null,l.createElement(Ie,null,o("domainName")),l.createElement(ze,null,o("price"))),null==d||null===(e=d.data)||void 0===e?void 0:e.map(function(e){return l.createElement("div",{key:null==e?void 0:e.domain},l.createElement(ke,null,l.createElement(Ge,null,null==e?void 0:e.domain),l.createElement(Re,null,l.createElement(Fe,null,o("domainPricePerYear",{price:s}))),l.createElement(Be,{disabled:!(null!=e&&e.is_available),onClick:function(){return n.handleOnClickRegister(null==e?void 0:e.domain,s)}},null!=e&&e.is_available?o("register"):o("notAvailable"))),l.createElement(Te,null,l.createElement(Ge,null,null==e?void 0:e.domain),l.createElement(Re,null,l.createElement(Fe,null,o("domainPricePerYear",{price:s}))),l.createElement(Be,{disabled:!(null!=e&&e.is_available),onClick:function(){return n.handleOnClickRegister(null==e?void 0:e.domain,s)}},null!=e&&e.is_available?o("register"):o("notAvailable"))))}))),l.createElement(xe,null,o("whatIsDomain")),l.createElement(ve,null,l.createElement(we,null,l.createElement(Ee,null,o("domainGuideTitle1")),l.createElement(Pe,null,o("domainGuideDescription1"))),l.createElement(Ce,null,l.createElement(Ee,null,o("domainGuideTitle2")),l.createElement(Pe,null,o("domainGuideDescription2"))),l.createElement(we,null,l.createElement(Ee,null,o("domainGuideTitle3")),l.createElement(Pe,null,o("domainGuideDescription3"))))),l.createElement(T.A,null))}}],o&&se(t.prototype,o),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,o}(l.Component);const Me=(0,f.Tl)("customDomain")((0,h.Fb)((0,d.Ng)(function(e){var n,t,o,i,r=e.auth,a=e.domains,l=e.domainSearches,c=e.domainPlans;return{domains:a,domainSearches:l,domainPlans:c,domainPrice:null!==(n=null===(t=c.data.find(function(e){return"domain_com_2000"===e.nickname}))||void 0===t?void 0:t.amount)&&void 0!==n?n:null,auth:r,error:(!(null!=r&&null!==(o=r.user)&&void 0!==o&&o.subscription)||(null==r||null===(i=r.user)||void 0===i||null===(i=i.subscription)||void 0===i?void 0:i.manual))&&{status:403}}})((0,G.A)(Le))))}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.