(self.webpackChunkPlesk=self.webpackChunkPlesk||[]).push([["views/smb/web/view"],{765:(e,t,n)=>{"use strict";n.r(t),n.d(t,{useAddDomainFormInDrawer:()=>M});var a=n(153),i=n.n(a),s=n(154),r=n(261),l=n.n(r),o=n(302),c=n(405),m=n(556),d=n(144),u=n(155),p=n(766),E=n(722),b=n(767),_=n(576),g=n(769),h=n(770),f=n(772);const y=o.gql`
    query GetWebspaceIpAddress($id: ID!) {
        domain: node(id: $id) {
            ... on Domain {
                ipAddresses {
                    ipAddress(publicIp: true)
                }
            }
        }
    }
`,w=d.Locale.getSection("smb.components.forms.web.add-domain"),v=d.Locale.getTranslate("smb.components.forms.web.add-domain"),D=d.Locale.getTranslate("smb.components.forms.domain-info-section"),T=d.Locale.getTranslate("components.forms.ip-addresses-selector"),S=d.Locale.getTranslate("smb.components.forms.web._shared"),P=d.Locale.getTranslate("smb.components.forms.web.seo-settings"),k=d.Locale.getTranslate("admin.components.forms.admin-panel.form.contact-info"),C=d.Locale.getTranslate("components.buttons"),A=({id:e,showDomainRegistrationPromo:t,ipAddresses:a,allowCustomerCreation:r,allowWebspaceCreation:l,subscriptionsLookUpParams:o,canManageMailSettings:h,maxSysnameSize:A,isWindows:M,techDomain:L,settingsEnabled:U,settingsCollapsed:I,applicationWizardConfig:R,embeddedForms:O,applicationWizardEmbeddedForms:B,cancelLink:x,className:N,render:q,onProcess:W,onStepPropsChange:H,status:F,...$})=>{var K;const j=(0,c.useApolloClient)(),V=(0,m.useHistory)(),[J,z]=(0,s.useState)($.values),[Y,G]=(0,s.useState)(Boolean($.values.hostingSettings.root)),[Q,Z]=(0,s.useState)(!$.values.domainInfo),[X,ee]=(0,s.useState)($.webspaceIpAddress),[te,ne]=(0,s.useState)(null);(0,s.useEffect)((()=>{if(Y)return;let e=/^[a-zA-Z0-9\.\-\*]+$/.match(J.domainName.name)?J.domainName.name.replace(/\*/g,"_"):"";-1!==J.hostingSettings.rootPattern.indexOf("<domain>")&&(e=J.hostingSettings.rootPattern.replace("<domain>",e)),z((0,u.setIn)(J,"hostingSettings[root]",e))}),[J.domainName.name]),(0,s.useEffect)((()=>{J.domainName.webspace&&"new"!==J.domainName.webspace.id&&j.query({query:y,variables:{id:btoa(`Domain:${J.domainName.webspace.id}`)}}).then((({data:{domain:{ipAddresses:e}}})=>{ee(e[0].ipAddress)}))}),[J.domainName.webspace]);const ae=(e,t)=>{switch(z((n=>{if(n=(0,u.setIn)(n,e,t),"domainName[name]"===e&&!Q){let e=/^[a-zA-Z0-9_.\-]+$/.match(t)?n.domainName.type===p.TYPE_TECH?t.split(".")[0]:t:"";e=e.toLowerCase().substr(0,A),M&&"."===e.substr(-1)&&(e=e.substr(0,e.length-1)),n=(0,u.setIn)(n,"domainInfo[userName]",e||$.values.domainInfo.userName)}return n})),["domainInfo[ipSelector][ipv4]","domainInfo[ipSelector][ipv6]","domainInfo[userName]","domainInfo[password]"].includes(e)&&d.UAT.dispatchAction("CUSTOM-VALUE",{name:e}),e){case"hostingSettings[root]":G(!0);break;case"domainInfo[userName]":Z(!0)}},ie="1"===J.domainName.assignToCustomer||void 0!==J.domainName.targetWebspace||J.domainName.webspace&&"new"===J.domainName.webspace.id,se=ie||!X?Object.keys(a).map((e=>{const t=J.domainInfo.ipSelector[e];return"none"===t?null:a[e][t].split(" ")[0]})).filter(Boolean)[0]:X;(0,s.useEffect)((()=>{R.enabled||null==H||H({sideBanner:n(777),sideBannerContainer:{background:"#faf5f7"}})}),[R.enabled]);const re=R.enabled?f.default:E.default;return(0,s.createElement)(re,{vertical:!0,id:e,className:N,render:q,values:J,onFieldChange:ae,onSubmit:e=>(e.domainName.customer&&(e=(0,u.setIn)(e,"domainName[customer]",e.domainName.customer.id)),e.domainName.webspace&&(e=(0,u.setIn)(e,"domainName[webspace]",e.domainName.webspace.id)),e),onLongTask:e=>{ne(e),null==W||W(e),null==H||H({sideBanner:n(779),sideBannerContainer:{background:"#e0f3f9"}})},onStepChange:e=>{te||null==H||H("chooseApplicationStep"===e?{sideBanner:n(778),sideBannerContainer:{background:"#f3f4f5"}}:{sideBanner:n(777),sideBannerContainer:{background:"#faf5f7"}})},embeddedForms:O,wizardConfig:R,wizardEmbeddedForms:B,submitButton:{id:"btn-send",children:(0,s.createElement)(v,{content:"buttonAddDomain"})},applyButton:!1,cancelButton:!!x&&{id:"btn-cancel",children:(0,s.createElement)(C,{content:"cancel"}),onClick:()=>{V.push(x)}}},(F||[]).filter((({status:e})=>"warning"===e)).map((({content:e})=>(0,s.createElement)(u.StatusMessage,{intent:"warning",key:e},e))),t?(0,s.createElement)(_.default,null,(()=>new Jsw.Panel({cls:"tools-box",items:[{componentType:"Jsw.Hint",hint:w.lmsg("formRegistrationHint",{link:`<a href="${(0,d.prepareUrl)("/mpc/register-domains")}" target="_blank">${w.lmsg("portalLink")}</a>`})}]}))):null,(0,s.createElement)(p.default,i()({isEnabled:void 0!==J.domainName.type,isDefault:J.domainName.type===p.TYPE_TECH,typeName:"domainName[type]",name:"domainName[name]",ipAddress:se,onTypeChange:e=>ae("domainName[type]",e),onDomainNameChange:e=>ae("domainName[name]",e)},L)),void 0===J.domainName.assignToCustomer?null:(0,s.createElement)(u.Section,null,(0,s.createElement)(u.FormFieldCheckbox,{name:"domainName[assignToCustomer]",label:(0,s.createElement)(v,{content:"assignToCustomer"}),checkedValue:"1",uncheckedValue:"0"}),"1"===J.domainName.assignToCustomer?(0,s.createElement)(u.Section,{collapsible:!0},void 0===J.domainName.customer?null:(0,s.createElement)(b.default,{name:"domainName[customer]",label:(0,s.createElement)(v,{content:"customer"}),dataUrl:"/admin/customer/look-up",newItemValue:r?{id:"new",title:w.lmsg("createNewCustomer")}:null,locale:{label:w.lmsg("selectExistingCustomer")},required:!0}),void 0===J.domainName.customer||"new"===(null===(K=J.domainName.customer)||void 0===K?void 0:K.id)?(0,s.createElement)(s.Fragment,null,(0,s.createElement)(u.FormFieldText,{name:"customerInfo[customerContactInfo][contactName]",label:(0,s.createElement)(k,{content:"contactName"}),required:!0}),(0,s.createElement)(u.FormFieldText,{name:"customerInfo[customerContactInfo][email]",label:(0,s.createElement)(k,{content:"email"}),required:!0}),(0,s.createElement)("br",null),(0,s.createElement)(u.Heading,{level:"4"},(0,s.createElement)(v,{content:"customerLoginInfoHint"})),(0,s.createElement)(g.default,{prefix:"customerInfo[customerLoginInfo]"})):null):null),void 0===J.domainName.webspace||"1"===J.domainName.assignToCustomer?null:(0,s.createElement)(u.Section,null,(0,s.createElement)(b.default,{name:"domainName[webspace]",label:(0,s.createElement)(v,{content:"target"}),dataUrl:"/smb/web/subscription-look-up",newItemValue:l?{id:"new",title:w.lmsg("createNewTarget")}:null,locale:{label:w.lmsg("selectExistingTarget")},lookUpParams:o,required:!0})),ie?U?(0,s.createElement)(u.Section,{id:"domainInfo",title:(0,s.createElement)(v,{content:"webspaceLegend"}),collapsible:!0,collapsed:I},Object.keys(a).map((e=>(0,s.createElement)(u.FormFieldSelect,{key:e,name:`domainInfo[ipSelector][${e}]`,label:(0,s.createElement)(T,{content:Object.keys(a).length>1?`${e}Address`:"ipAddress"}),required:!0},Object.keys(a[e]).map((t=>(0,s.createElement)(u.SelectOption,{key:t,value:t},a[e][t])))))),(0,s.createElement)("br",null),(0,s.createElement)(u.Heading,{level:"4"},(0,s.createElement)(v,{content:"credentials"})),(0,s.createElement)(u.Text,{component:"p",intent:"muted"},(0,s.createElement)(v,{content:M?"credentialsHintWin":"credentialsHint"})),(0,s.createElement)(u.FormFieldText,{name:"domainInfo[userName]",label:(0,s.createElement)(D,{content:"userName"}),required:!0}),(0,s.createElement)(u.FormFieldPassword,{name:"domainInfo[password]",label:(0,s.createElement)(D,{content:"password"}),required:!0})):null:(0,s.createElement)(u.Section,null,(0,s.createElement)(u.FormFieldSelect,{name:"hostingType[hosting]",label:(0,s.createElement)(v,{content:"hostingManagementOptions"})},(0,s.createElement)(u.SelectOption,{value:"hosting",label:"hosting"},(0,s.createElement)(v,{content:"websiteHosting"})),(0,s.createElement)(u.SelectOption,{value:"forwarding",label:"forwarding"},(0,s.createElement)(v,{content:"websiteForwarding"})),(0,s.createElement)(u.SelectOption,{value:"none",label:"none"},(0,s.createElement)(v,{content:"websiteNoHosting"}))),void 0===J.dnsSettings?null:(0,s.createElement)(u.FormFieldCheckbox,{name:"dnsSettings[dns]",label:(0,s.createElement)(v,{content:"dns"}),description:(0,s.createElement)(v,{content:"dnsHint"}),disabled:J.domainName.type===p.TYPE_TECH,checkedValue:J.domainName.type===p.TYPE_TECH?null:"master",uncheckedValue:J.domainName.type===p.TYPE_TECH?null:"none"}),void 0===J.mailSettings?null:(0,s.createElement)(u.FormFieldCheckbox,{name:"mailSettings[mail]",label:(0,s.createElement)(v,{content:"mail"}),description:h?(0,s.createElement)(v,{content:"mailHint"}):(0,s.createElement)(v,{content:"mailHintNoPermission"}),disabled:J.domainName.type===p.TYPE_TECH,checkedValue:J.domainName.type===p.TYPE_TECH?null:"1",uncheckedValue:J.domainName.type===p.TYPE_TECH?null:"0"}),"hosting"===J.hostingType.hosting?(0,s.createElement)(u.Section,{id:"hostingSettings",title:(0,s.createElement)(v,{content:"hostingSettingsSectionLegend"}),collapsible:!0,collapsed:!0},(0,s.createElement)(u.FormField,{name:"hostingSettings[root]",label:(0,s.createElement)(S,{content:"documentRoot"}),description:(0,s.createElement)(S,{content:"documentRootHint"}),required:!0},(({getId:e,getName:t,getValue:n,setValue:a})=>(0,s.createElement)(s.Fragment,null,(0,s.createElement)(u.Icon,{name:"home"})," / ",(0,s.createElement)(u.Input,{id:e(),name:t(),value:n(),onChange:({target:e})=>a(e.value)})))),(0,s.createElement)(u.FormFieldRadioButtons,{name:"hostingSettings[seoRedirectDirection]",label:(0,s.createElement)(P,{content:"seoRedirectDirection"}),description:(0,s.createElement)(P,{content:"seoRedirectDirectionHint"}),required:!0,options:[{value:"www",label:`www.${J.domainName.name||"<your_domain>"}`},{value:"non-www",label:J.domainName.name||"<your_domain>"},{value:"none",label:(0,s.createElement)(P,{content:"seoRedirectDirectionNone"})}]})):null,"forwarding"===J.hostingType.hosting?(0,s.createElement)(u.Section,{id:"forwardingSettings",title:(0,s.createElement)(S,{content:"forwardingSettingsSectionLegend"}),collapsible:!0,collapsed:!0},(0,s.createElement)(u.FormFieldText,{name:"forwardingSettings[forwardTo]",label:(0,s.createElement)(S,{content:"forwardDestination"}),description:(0,s.createElement)(S,{content:"forwardDestinationHint"}),required:!0}),(0,s.createElement)(u.FormFieldRadioButtons,{name:"forwardingSettings[forwardingType]",label:(0,s.createElement)(S,{content:"forwardingTypeOptions"}),options:[{value:"std_fwd301",label:(0,s.createElement)(S,{content:"forwardingHttpCode301"}),description:(0,s.createElement)(S,{content:"forwardingHttpCode301Hint"})},{value:"std_fwd302",label:(0,s.createElement)(S,{content:"forwardingHttpCode302"}),description:(0,s.createElement)(S,{content:"forwardingHttpCode302Hint"})},{value:"frm_fwd",label:(0,s.createElement)(S,{content:"forwardingFrame"}),description:(0,s.createElement)(S,{content:"forwardingFrameHint"})}]})):null))};A.propTypes={id:l().string.isRequired,showDomainRegistrationPromo:l().bool,values:l().object.isRequired,ipAddresses:l().shape({ipv4:l().object,ipv6:l().object}).isRequired,allowCustomerCreation:l().bool,allowWebspaceCreation:l().bool,subscriptionsLookUpParams:l().object,webspaceIpAddress:l().string,canManageMailSettings:l().bool,maxSysnameSize:l().number.isRequired,isWindows:l().bool.isRequired,techDomain:l().object.isRequired,settingsEnabled:l().bool,settingsCollapsed:l().bool,applicationWizardConfig:l().object,cancelLink:l().string,embeddedForms:l().array,applicationWizardEmbeddedForms:l().array,className:l().string,render:l().func,onProcess:l().func,onStepPropsChange:l().func,status:l().array},A.defaultProps={showDomainRegistrationPromo:!1,allowCustomerCreation:!1,allowWebspaceCreation:!1,subscriptionsLookUpParams:null,webspaceIpAddress:null,canManageMailSettings:!1,settingsEnabled:!1,settingsCollapsed:!1,applicationWizardConfig:{},cancelLink:null,embeddedForms:void 0,applicationWizardEmbeddedForms:void 0,className:void 0,render:void 0,onProcess:void 0,onStepPropsChange:void 0,status:void 0};const M=(e,t)=>(0,h.default)(A,"add-domain",e,t);t.default=A},940:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155);const l=({error:e})=>{var t;return 400===(null===(t=e.networkError)||void 0===t?void 0:t.statusCode)?null:(0,a.createElement)(r.StatusMessage,{intent:"danger"},e.message)};l.propTypes={error:s().shape({message:s().string.isRequired,networkError:s().shape({statusCode:s().number})}).isRequired},t.default=l},772:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(261),l=n.n(r),o=n(144),c=n(773),m=n(774);const d=o.Locale.getTranslate("components.domain-applications.applications"),u=({onFieldChange:e,onStepChange:t,formPrefix:a,wizardConfig:r,embeddedForms:l,wizardEmbeddedForms:o,values:u,children:p,...E})=>{const[b,_]=(0,s.useState)([]),g=t=>{e("applicationName",t),_([...o.filter((({ext:e,name:n})=>t===`ext-${e}-${n}`)).filter((({content:e})=>Boolean(e))).map((({ext:e,name:t,...n})=>({key:`ext-${e}-${t}`,children:"",embeddedForms:[{name:t,...n}]})))])},h=[r.blankSite&&{name:"blank-site",icon:n(775),title:(0,s.createElement)(d,{content:"blank-site.title"}),description:(0,s.createElement)(d,{content:"blank-site.description"})},r.uploadFiles&&{name:"upload-files",icon:n(776),title:(0,s.createElement)(d,{content:"upload-files.title"}),description:(0,s.createElement)(d,{content:"upload-files.description"})},...o.map((({ext:e,name:t,title:n,icon:a,description:i})=>({name:`ext-${e}-${t}`,icon:a,title:n,description:i})))].filter(Boolean),f=[h.length>1&&{key:"chooseApplicationStep",children:(0,s.createElement)(c.default,{onApplicationSelect:g,applicationsList:h}),nextButton:!1},{key:"addDomainStep",formPrefix:a,children:p,embeddedForms:l}].filter(Boolean);(0,s.useEffect)((()=>{if(0===h.length&&g("blank-site"),1===h.length){const[{name:e}]=h;g(e)}}),[]);const y=u.applicationName&&1!==f.length?1:0;return(0,s.useEffect)((()=>{null==t||t(f[y].key)}),[y]),(0,s.createElement)(m.default,i()({},E,{values:u,onFieldChange:e,onStepChange:(t,n)=>0===n&&f.length>1?(e("applicationName",null),_([]),t):n,step:y,steps:[...f,...b]}))};u.propTypes={values:l().object.isRequired,onFieldChange:l().func.isRequired,onStepChange:l().func,children:l().node,formPrefix:l().string,wizardConfig:l().shape({enabled:l().bool,blankSite:l().bool,uploadFiles:l().bool}),embeddedForms:l().array,wizardEmbeddedForms:l().array},u.defaultProps={children:null,onStepChange:void 0,formPrefix:"",wizardConfig:{enabled:!0,blankSite:!0,uploadFiles:!0},embeddedForms:[],wizardEmbeddedForms:[]},t.default=u},773:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261),r=n.n(s);const l=n(144).Locale.getTranslate("components.domain-applications"),o=({onApplicationSelect:e,applicationsList:t})=>(0,a.createElement)(a.Fragment,null,(0,a.createElement)(i.Heading,{level:"3"},(0,a.createElement)(l,{content:"title"})),(0,a.createElement)(i.ItemList,{minColumnWidth:220,gap:"xs",selectable:!0},t.map((({name:t,icon:n,title:s,description:r})=>(0,a.createElement)(i.Item,{"data-action":t,key:t,icon:(0,a.createElement)(i.Icon,{src:n,intent:"info",size:"64"}),title:(0,a.createElement)(i.Heading,{level:"4"},s),onClick:()=>e(t)},(0,a.createElement)(i.Paragraph,null,r))))));o.propTypes={onApplicationSelect:r().func.isRequired,applicationsList:r().arrayOf(r().shape({name:r().string.isRequired,icon:r().string.isRequired,title:r().node,description:r().node}))},o.defaultProps={applicationsList:[]},t.default=o},771:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(155),l=n(144),o=n(261),c=n.n(o),m=n(615),d=n(635),u=n(582);const p="running",E=()=>(0,l.getComponent)("asyncProgressBarWrapper"),b=({children:e,dataType:t,isOpen:n,onClose:a,task:o,history:c,pageUrl:b,..._})=>{const[g,h]=(0,s.useState)([]),[f,y]=(0,s.useState)(null),[w,v]=(0,s.useState)(null),[D,T]=(0,s.useState)(null),S=o?o.id:null,{addToast:P}=(0,d.useToaster)(),k=()=>c&&w&&(0,u.isMatch)(w)&&!((e,t)=>{if(e===t)return!0;try{const n=new URLSearchParams(new URL(e,window.location.origin).search);return n.get("returnUrl")===t||n.get("pageUrl")===t}catch(e){}return!0})(w,b),C=({id:e,steps:t,status:a,errors:i,output:r,progressValue:o,progressTitle:c,progressTitleHtml:m})=>{if(!n||S!==e)return;const d=m||c,u=l.Task.STATUS_STARTED===a?p:a,E=e=>(e||[]).map((e=>(0,s.createElement)("div",{key:e},e)));T(u),t&&t.length?(y(d),h(t.map((({errors:e,...t})=>({children:E(e),...t}))))):h([{title:d,status:u,progress:Number(o),children:(0,s.createElement)(s.Fragment,null,E(i),E(r))}])};(0,s.useEffect)((()=>{const e=E();n?(null==e||e.hide(),h([]),y(null),v(null),T(null)):(async()=>{A()||await M(),null==e||e.show()})()}),[n]),(0,s.useEffect)((()=>{var e;S&&(null===(e=E())||void 0===e||e.update(),C(o))}),[S,o]),(0,m.default)("plesk:taskStepUpdate",C,l.Observer),(0,m.default)("plesk:taskComplete",(({id:e,redirect:t,status:a})=>{n&&S===e&&l.Task.STATUS_DONE===a&&v(t.url||t)}),l.Observer);const A=()=>l.Task.STATUS_NOT_STARTED===D||p===D,M=()=>{var e,t;return S&&(null===(e=E())||void 0===e||null===(t=e.getItems().find((e=>e.getId()===S)))||void 0===t?void 0:t.remove())};return(0,s.createElement)(r.Drawer,i()({"data-type":t,isOpen:n,onClose:()=>{w?k()?c.push(w,{reload:!0}):(0,l.redirect)(w):a()},progress:g.length?{cancelable:!1,title:f,steps:g,onFinish:()=>{M(),P({intent:"success",message:f||g[0].title})},autoCloseTimeout:1}:null,hideButton:A()},_),e)};b.propTypes={children:c().node,dataType:c().string.isRequired,isOpen:c().bool,onClose:c().func.isRequired,task:c().shape({id:c().string.isRequired,steps:c().array,status:c().string,progressTitle:c().string,progressTitleHtml:c().string}),history:c().object,pageUrl:c().string},b.defaultProps={children:null,isOpen:!1,task:null,history:null,pageUrl:null},t.default=b},767:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(768);const o=n(144).Locale.getSection("components.elements.lookup"),c=({data:e,dataUrl:t,lookUpParams:n,newItemValue:i,locale:s,placeholder:c,...m})=>(0,a.createElement)(r.FormField,m,(({getId:r,getName:m,getValue:d,setValue:u,isDisabled:p})=>(0,a.createElement)(l.default,{id:r(),name:m(),value:d(),onChange:e=>u(e),data:e,dataUrl:t,lookUpParams:n,newItemValue:i,locale:{...o.messages,...s},disabled:p(),placeholder:c})));c.propTypes={locale:s().object,data:s().array,dataUrl:s().string,lookUpParams:s().object,newItemValue:s().object,placeholder:s().string},c.defaultProps={locale:void 0,data:void 0,dataUrl:void 0,lookUpParams:void 0,newItemValue:void 0,placeholder:void 0},t.default=c},768:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(144),s=n(576);t.default=e=>{const[t,n]=(0,a.useState)(null);return(0,a.useEffect)((()=>{const t=new i.LookUp(e);return n(t),()=>{t.remove(),n(null)}}),[]),t?(0,a.createElement)(s.default,null,t):null}},774:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(155),r=n(154),l=n(722),o=n(144),c=n(261),m=n.n(c);const d=o.Locale.getTranslate("components.buttons"),u=({step:e,steps:t,onStepChange:n,onSubmit:a,submitButton:o,cancelButton:c,...m})=>{const u=(0,r.useRef)(),[p,E]=(0,r.useState)(0),b=p+e,{children:_,formPrefix:g,embeddedForms:h,backButton:f,nextButton:y}={backButton:{},nextButton:{},...t[b]},w=b===t.length-1,v=0===b,D=()=>{u.current.handleEmbeddedFormValues(),E((t=>n(t+e,t+e+1)-e))};return(0,r.createElement)(l.default,i()({},m,{ref:u,additionalButtons:[v&&c&&(0,r.createElement)(s.Button,i()({key:"cancel",children:(0,r.createElement)(d,{content:"cancel"})},c)),!v&&f&&(0,r.createElement)(s.Button,i()({key:"back",arrow:"backward",onClick:()=>{u.current.handleEmbeddedFormValues(),E((t=>n(t+e,t+e-1)-e))},children:(0,r.createElement)(d,{content:"back"})},f)),!w&&y&&(0,r.createElement)(s.Button,i()({key:"next",intent:"primary",onClick:D,arrow:"forward",children:(0,r.createElement)(d,{content:"nextWithoutArrow"})},y)),w&&o&&(0,r.createElement)(s.Button,i()({key:"submit",intent:"primary",arrow:"forward",onClick:()=>u.current.submit(),children:(0,r.createElement)(d,{content:"ok"})},o))],onSubmit:w?a:D,onError:a=>{const i=t.findIndex((({formPrefix:e})=>""===e)),s=Object.keys(a).map((e=>{const n=t.findIndex((({formPrefix:t,embeddedForms:n=[]})=>t===e||n.any((({name:t})=>t===e))));return n>=0?n:i}));E(n(b,s.length>0?Math.min(...s):e)-e)},applyButton:!1,submitButton:!1,cancelButton:!1,formPrefix:g,embeddedForms:h}),_)};u.propTypes={step:m().number,steps:m().arrayOf(m().shape({formPrefix:m().string,embeddedForms:m().array,children:m().node,nextButton:m().bool,backButton:m().bool})),onStepChange:m().func,onSubmit:m().func,submitButton:m().object,cancelButton:m().object},u.defaultProps={step:0,steps:[],onStepChange:(e,t)=>t,onSubmit:void 0,submitButton:{},cancelButton:{}},t.default=u},769:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(144),r=n(261),l=n.n(r);const o=s.Locale.getTranslate("admin.components.forms.admin-panel.form.login-info"),c=({prefix:e})=>(0,a.createElement)(a.Fragment,null,(0,a.createElement)(i.FormFieldText,{name:"".concat(e,"[userName]"),label:(0,a.createElement)(o,{content:"userName"}),required:!0,autoComplete:"off"}),(0,a.createElement)(i.FormFieldPassword,{name:"".concat(e,"[password]"),label:(0,a.createElement)(o,{content:"password"}),required:!0,autoComplete:"off"}),(0,a.createElement)(i.FormFieldCheckbox,{name:"".concat(e,"[isActivationRequired]"),label:(0,a.createElement)(o,{content:"emailActivation"}),description:(0,a.createElement)(o,{content:"emailActivationHint"}),checkedValue:"1",uncheckedValue:"0"}));c.propTypes={prefix:l().string.isRequired},t.default=c},781:(e,t,n)=>{"use strict";n.r(t);var a=n(144);t.default=({adminDescription:e,resellerDescription:t,ownerDescription:n,hideResellerTitleDescription:i,hideOwnerTitleDescription:s},r,l="hint")=>[e?(0,a.createElement)(`.${l}`,[(0,a.escapeHtml)(e.truncate(50,"...")),(0,a.createElement)("span.tooltipData",(0,a.escapeHtml)(e))]):"",t?(0,a.createElement)(`.${l}`,[`${i?"":`${r.lmsg("resellerDescription")}: `}${(0,a.escapeHtml)(t.truncate(50,"..."))}`,(0,a.createElement)("span.tooltipData",(0,a.escapeHtml)(t))]):"",n?(0,a.createElement)(`.${l}`,[`${s?"":`${r.lmsg("ownerDescription")}: `}${(0,a.escapeHtml)(n.truncate(50,"..."))}`,(0,a.createElement)("span.tooltipData",(0,a.escapeHtml)(n))]):""]},766:(e,t,n)=>{"use strict";n.r(t),n.d(t,{TYPE_TECH:()=>m,TYPE_CUSTOM:()=>d});var a=n(153),i=n.n(a),s=n(155),r=n(154),l=n(261),o=n.n(l),c=n(144);const m="tech",d="custom",u=c.Locale.getTranslate("components.forms.domain.tech-domain-name"),p=({isEnabled:e,isDefault:t,url:n,vendor:a,typeName:i,name:l,ipAddress:o,onDomainNameChange:c,onTypeChange:p})=>{const[_,g]=(0,r.useState)(e&&t?m:d);if(!e)return(0,r.createElement)(E,{name:l,isEnabled:!1,onDomainNameChange:c});const h=[{key:d,icon:(0,r.createElement)(s.Icon,{name:"ribbon",intent:"success"})},{key:m,icon:(0,r.createElement)(s.Icon,{name:"rocket",intent:"info"})}];return(0,r.createElement)(r.Fragment,null,(0,r.createElement)(s.Section,{title:(0,r.createElement)(u,{content:"title"}),vertical:!0},(0,r.createElement)(s.FormField,{name:i,onChange:e=>(e=>{g(e),p(e),c("")})(e)},(({getId:e,getName:t,getValue:n,setValue:a,isDisabled:i})=>(0,r.createElement)(r.Fragment,null,(0,r.createElement)(s.ItemList,{stretchable:!0,selectable:!0,minColumnWidth:270,gap:"sm",value:n(),onSelect:e=>a(e)},h.map((({key:e,icon:t})=>(0,r.createElement)(s.Item,{icon:t,key:e,value:e,"data-action":`use-${e}-domain`,title:(0,r.createElement)(s.Heading,{level:"4"},(0,r.createElement)(s.Paragraph,null,(0,r.createElement)(u,{content:`${e}DomainTitle`}))),disabled:i()},(0,r.createElement)(s.Text,{fontSize:"md"},(0,r.createElement)(u,{content:`${e}DomainText`})))))),(0,r.createElement)("input",{hidden:!0,id:e(),name:t(),value:n(),readOnly:!0}))))),_===m?(0,r.createElement)(b,{name:l,ipAddress:o,url:n,vendor:a,onDomainNameChange:c}):(0,r.createElement)(E,{name:l,isEnabled:!0,onDomainNameChange:c}))},E=({name:e,isEnabled:t,onDomainNameChange:n})=>(0,r.createElement)(s.Section,{vertical:!0},(0,r.createElement)(s.FormField,{name:e,label:t?(0,r.createElement)(u,{content:"customDomain"}):(0,r.createElement)(u,{content:"domainName"}),onChange:e=>n(e),required:!0},(({getId:e,getName:t,getValue:n,setValue:a,isDisabled:i})=>(0,r.createElement)(r.Fragment,null,(0,r.createElement)("span",{dir:"ltr"},"www. ",(0,r.createElement)(s.Input,{id:e(),name:t(),value:n(),placeholder:"domain.name",size:"lg",onChange:e=>a(e.target.value),disabled:i()}))))));E.propTypes={name:o().string.isRequired,isEnabled:o().bool.isRequired,onDomainNameChange:o().func.isRequired};const b=({name:e,onDomainNameChange:t,...n})=>(0,r.createElement)(s.Section,{vertical:!0},(0,r.createElement)(r.Fragment,null,(0,r.createElement)(s.FormField,{label:(0,r.createElement)(u,{content:"techDomain"}),name:e,onChange:e=>t(e)},(({getId:e,getName:t,...a})=>(0,r.createElement)(_,i()({id:e(),name:t()},a,n)))),(0,r.createElement)(s.Cuttable,{maxHeight:24},(0,r.createElement)(s.Paragraph,null,(0,r.createElement)(u,{content:"techDomainDesc"})),(0,r.createElement)("ul",null,(0,r.createElement)("li",null,(0,r.createElement)(u,{content:"techDomainRandom"})),(0,r.createElement)("li",null,(0,r.createElement)(u,{content:"techDomainDns"})),(0,r.createElement)("li",null,(0,r.createElement)(u,{content:"techDomainMail"}))),(0,r.createElement)(s.Paragraph,null,(0,r.createElement)(u,{content:"techDomainSwitch"})))));b.propTypes={name:o().string.isRequired,onDomainNameChange:o().func.isRequired};const _=({id:e,name:t,ipAddress:n,url:a,vendor:i,getValue:l,setValue:o})=>{const[c,m]=(0,r.useState)(!1),[d,p]=(0,r.useState)(n),[E,b]=(0,r.useState)({}),_=(0,r.useCallback)((async()=>{if(b({}),!l()||n!==d)if(n){m(!0);try{const e=await fetch(a,{method:"POST",body:JSON.stringify({ip_address:n,vendor:i})}),{subdomain:t}=await e.json();if(!t)return void b({error:(0,r.createElement)(u,{content:"error"})});o(t),p(n)}catch{b({error:(0,r.createElement)(u,{content:"error"})})}finally{m(!1)}}else b({noIpAddress:(0,r.createElement)(u,{content:"errorNoIpAddress"})})}),[l,o,n,d,a,i]);return(0,r.useEffect)((()=>{_()}),[n]),(0,r.createElement)(r.Fragment,null,c?(0,r.createElement)(s.Status,{progress:!0},(0,r.createElement)(u,{content:"generating"})):(0,r.createElement)(s.Text,{bold:!0},l()),(0,r.createElement)("input",{hidden:!0,id:e,name:t,value:l(),readOnly:!0}),Object.keys(E).map((e=>(0,r.createElement)(s.Alert,{key:e,intent:"danger"},(0,r.createElement)(s.Icon,{name:"exclamation-mark-circle-filled",intent:"danger"})," ",E[e]))))};_.propTypes={id:o().string.isRequired,name:o().string.isRequired,ipAddress:o().string,url:o().string.isRequired,vendor:o().string.isRequired,getValue:o().func.isRequired,setValue:o().func.isRequired},_.defaultProps={ipAddress:null},p.propTypes={isEnabled:o().bool.isRequired,isDefault:o().bool.isRequired,url:o().string.isRequired,vendor:o().string.isRequired,typeName:o().string.isRequired,name:o().string.isRequired,ipAddress:o().string,onDomainNameChange:o().func.isRequired,onTypeChange:o().func.isRequired},p.defaultProps={ipAddress:null},t.default=p},770:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(302),l=n(405),o=n(556),c=n(155),m=n(144),d=n(771);const u=r.gql`
    query GetAddDomainData {
        config {
            domainManagement {
                settings {
                    enabled
                    collapsed
                }
                applicationWizard {
                    enabled
                    blankSite
                    uploadFiles
                }
            }
            techDomain {
                url
                vendor
            }
        }
    }
`;t.default=(e,t,n,a)=>{const r=(0,l.useApolloClient)(),p=!!(0,o.useRouteMatch)(a),E=(0,o.useHistory)(),[b,_]=(0,s.useState)(null),[g,h]=(0,s.useState)(null),[f,y]=(0,s.useState)(null);(0,s.useEffect)((()=>{p&&(_(null),h(null),Promise.all([m.api.get(a),r.query({query:u})]).then((([e,{data:{config:t}}])=>{e.redirect?(0,m.redirect)(e.redirect):_({...e,techDomain:{url:`${t.techDomain.url}/api/subdomain`,vendor:t.techDomain.vendor},settingsEnabled:t.domainManagement.settings.enabled,settingsCollapsed:t.domainManagement.settings.collapsed,applicationWizardConfig:t.domainManagement.applicationWizard})})))}),[p,a,r]);const w=()=>{E.push(n)};return[(0,s.createElement)(d.default,i()({dataType:t,title:b?b.pageTitle:"",size:"sm",isOpen:p,onClose:w,form:b?(0,s.createElement)(e,i()({onCancel:w,onProcess:h,onStepPropsChange:y},b)):null,task:g,history:E,pageUrl:n},f),b?null:(0,s.createElement)(c.ContentLoader,null))]}},799:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(261),l=n.n(r),o=n(578),c=n.n(o),m=n(613),d=n(155);const u=({baseClassName:e,className:t,id:n,title:a,children:r,...l})=>{const[o,u]=(0,m.useLocalStorage)("".concat(n,"-hidden"));return(0,s.createElement)(d.Panel,i()({className:c()(e,t),id:n,title:a?(0,s.createElement)(d.Heading,{level:4},a):null,collapsible:!!n,collapsed:!!a&&"true"===o,onToggle:()=>u("true"===o?"false":"true")},l),r)};u.propTypes={id:l().string,title:l().any,children:l().any.isRequired,className:l().string,baseClassName:l().string},u.defaultProps={id:void 0,title:void 0,className:void 0,baseClassName:"side-panel"},t.default=u},800:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(144);const o=l.Locale.getSection("components.forms.admin-info"),c=l.Locale.getTranslate("components.forms.admin-info"),m=l.Locale.getSection("components.buttons"),d=({url:e,data:t,objectType:n,object:i})=>Object.keys(t).map((s=>(0,a.createElement)("div",{className:"side-panel__item",key:s},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(c,{content:"description".concat(s.capitalize())}),":")," ",(0,a.createElement)("b",null,(0,a.createElement)("span",{id:"".concat(s,"-description")},t[s]))," ",(0,a.createElement)(r.AuxiliaryActions,null,(0,a.createElement)(r.Link,{id:"".concat(s,"-description-edit"),onClick:()=>((t,a)=>{new l.CustomDescription.PopupForm({id:"editDescription",cls:"popup-panel",hint:o.lmsg("popupHint".concat(t.capitalize())),value:a,locale:{popupTitle:o.lmsg("popupTitle".concat(n.capitalize()),{descriptionType:o.lmsg("description".concat(t.capitalize())),name:i}),buttonOk:m.lmsg("save"),buttonCancel:m.lmsg("cancel")},handler(n){(0,l.redirectPost)(e,{type:t,description:n})}})})(s,t[s])},t[s]?(0,a.createElement)(c,{content:"edit"}):(0,a.createElement)(c,{content:"add"})),t[s]?(0,a.createElement)(r.Link,{id:"".concat(s,"-description-remove"),onClick:()=>(t=>{l.messageBox.show({type:Jsw.messageBox.TYPE_YESNO,subtype:"delete",buttonTitles:{yes:m.lmsg("yes"),no:m.lmsg("no"),wait:m.lmsg("wait")},text:o.lmsg("confirmOnRemove"),onYesClick(){(0,l.redirectPost)(e,{type:t,description:""})}})})(s)},(0,a.createElement)(c,{content:"remove"})):null))));d.propTypes={url:s().string.isRequired,data:s().shape({admin:s().string,reseller:s().string,owner:s().string}).isRequired,objectType:s().oneOf(["reseller","customer","subscription"]).isRequired,object:s().string.isRequired},t.default=d},908:(e,t,n)=>{"use strict";n.r(t);var a=n(148),i=n.n(a),s=n(144);class r extends s.Container{constructor(...e){super(...e),i()(this,"handleNextClick",(e=>{this._offset+=this._itemCount,this._showCurrentItems(),e.preventDefault()})),i()(this,"handlePrevClick",(e=>{this._offset-=this._itemCount,this._showCurrentItems(),e.preventDefault()})),i()(this,"handleSuccessExecute",(e=>{this._total=parseInt(e.total),this._togglePrev(),this._toggleNext(),this._renderCurrentItems(e.items);const t=document.getElementById(this._customSpotsBlock);0>=this._total&&t&&(t.style.display="none")})),i()(this,"handleFailureExecute",(()=>{const e=document.getElementById(this._customSpotsBlock);e&&(e.style.display="none")}))}_initConfiguration(e){super._initConfiguration({locale:s.Locale.getSection("components.custom-spots"),...e}),this._dataUrl=this._getConfigParam("dataUrl",""),this._customSpotsBlock=this._getConfigParam("customSpotsBlock",""),this._itemCount=parseInt(this._getConfigParam("itemCount","")),this._total=0,this._offset=0}_initComponentElement(){super._initComponentElement(),this._initLayout()}_initLayout(){this._componentElement.innerHTML='<div class="rss-feed-nav">'+'<a id="'.concat(this._id,'-prev" href="#">').concat(this.lmsg("prev"),"</a> ")+'<a id="'.concat(this._id,'-next" href="#">').concat(this.lmsg("next"),"</a>")+"</div>"}_renderItems(){return this._showCurrentItems(),!1}_addEvents(){this._componentElement.querySelector("#".concat(this._id,"-next")).addEventListener("click",this.handleNextClick),this._componentElement.querySelector("#".concat(this._id,"-prev")).addEventListener("click",this.handlePrevClick)}_togglePrev(){const e=this._componentElement.querySelector("#".concat(this._id,"-prev"));0>=this._offset?e.style.display="none":e.style.display=""}_toggleNext(){const e=this._componentElement.querySelector("#".concat(this._id,"-next"));this._total<=this._offset+this._itemCount?e.style.display="none":e.style.display=""}_renderCurrentItems(e){if(!e.length)return void(this._renderTarget.innerHTML="");let t='<ul id="rssFeedItems" class="rss-feed-list">';for(const n in e)e.hasOwnProperty(n)&&(t+='<li class="rss-feed-item">'+'<a href="'.concat((0,s.escapeHtml)(e[n].link),'" target="_blank">').concat((0,s.escapeHtml)(e[n].title),"</a>")+"<p>".concat(e[n].description,"</p>")+"</li>");t+="</ul>",this._renderTarget.innerHTML=t}_showCurrentItems(){this._renderTarget.innerHTML='<div class="ajax-loading">'.concat(this.lmsg("loading"),"</div>"),s.api.get(this._dataUrl,{offset:this._offset}).then(this.handleSuccessExecute).catch(this.handleFailureExecute)}}t.default=r},909:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155);const l=n(144).Locale.getTranslate("components.sidebar"),o=({limits:e})=>(0,a.createElement)(a.Fragment,null,(0,a.createElement)("div",{className:"side-panel__stat"},e.disk_space.title,": ",(0,a.createElement)("b",null,e.disk_space.percent),"%",(0,a.createElement)(r.ProgressBar,{progress:Math.min(e.disk_space.percent,100)}),e.disk_space.usageString),(0,a.createElement)("div",{className:"side-panel__stat"},e.max_traffic.title,": ",(0,a.createElement)("b",null,e.max_traffic.percent),"%",(0,a.createElement)(r.ProgressBar,{progress:Math.min(e.max_traffic.percent,100)}),e.max_traffic.usageString),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Action,{icon:{src:n(749)},href:"/smb/statistics"},(0,a.createElement)(l,{content:"statsMoreLink"}))));o.propTypes={limits:s().object.isRequired},t.default=o},910:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(738),r=n.n(s),l=n(154),o=n(261),c=n.n(o),m=n(155),d=n(405),u=n(302),p=n(144),E=n(799),b=n(744),_=n(741),g=n(745);function h(){const e=r()(["\n        {\n            config {\n                updates {\n                    showControls\n                }\n            }\n        }\n    "]);return h=function(){return e},e}const f=p.Locale.getTranslate("components.sidebar"),y=({hostname:e,publicIpAddress:t,ipAddress:a,os:s,productName:r,panelVersion:o,installedPatch:c,isUpdateAllowed:p,lastChecked:y,lastUpdate:w,changelogUrl:v,isAutoupdatesDisabled:D,updateSettingsUrl:T,availableUpgrade:S,upgradeWhatsNewUrl:P,updates:k,pum:C,isFail2banAvailable:A,fail2banStatus:M,isModSecurityAvailable:L,modSecurityState:U,isStatisticsAvailable:I})=>{var R,O;const{data:{config:B}={}}=(0,d.useQuery)((0,u.gql)(h())),x=(0,l.createElement)(l.Fragment,null,r," ",o,c?(0,l.createElement)(l.Fragment,null," ",(0,l.createElement)(f,{content:"installedPatchVersion",params:{installedPatch:c}})):null);return(0,l.createElement)(E.default,{id:"panel-web-panelSystemSection",title:(0,l.createElement)(f,{content:"panelSystemSection"})},(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Text,{intent:"muted"},(0,l.createElement)(f,{content:"hostname"}),":")," ",(0,l.createElement)("b",null,e)),(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Text,{intent:"muted"},(0,l.createElement)(f,{content:"ipAddress"}),":")," ",(0,l.createElement)("b",null,t||a)),(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Text,{intent:"muted"},(0,l.createElement)(f,{content:"os"}),":")," ",(0,l.createElement)("b",{dir:"ltr"},s)),(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Text,{intent:"muted"},(0,l.createElement)(f,{content:"product"}),":")," ",(0,l.createElement)("b",null,p?(0,l.createElement)(m.Popover,{className:"side-panel-popover",target:(0,l.createElement)(m.Link,null,x),title:(0,l.createElement)(f,{content:"product"})},!k&&y?(0,l.createElement)("div",{className:"side-panel-popover__item"},(0,l.createElement)(f,{content:"systemIsUp2date"})," ",(0,l.createElement)(m.Text,{intent:"muted"},(0,l.createElement)(f,{content:"checkedAt",params:{lastChecked:y}}))):null,(0,l.createElement)("div",{className:"side-panel-popover__item"},(0,l.createElement)(m.Action,{icon:{src:n(911)},href:v,target:"_blank"},(0,l.createElement)(f,{content:"seeChangelog"}))),(0,l.createElement)("div",{className:"side-panel-popover__item"},(0,l.createElement)(m.Action,{icon:{src:n(912)},href:"/admin/update/add-components",target:"_blank"},(0,l.createElement)(f,{content:"addComponents"}))),D?(0,l.createElement)("div",{className:"side-panel-popover__item"},(0,l.createElement)(m.Status,{icon:"exclamation-mark-circle-filled",intent:"warning",bottomAddon:(0,l.createElement)(m.Link,{href:"/smb/settings/tools-proxy?url=".concat(T)},(0,l.createElement)(f,{content:"enableAutoupdate"}))},(0,l.createElement)(f,{content:"autoupdatesIsDisabled"}))):null):x,w?(0,l.createElement)(f,{content:"lastUpdateDate",params:{lastUpdate:(0,l.createElement)(m.Text,{nowrap:!0},w,D?(0,l.createElement)(l.Fragment,null," ",(0,l.createElement)(m.Tooltip,{title:(0,l.createElement)(f,{content:"autoupdatesIsDisabledHint"})},(0,l.createElement)(m.Icon,{name:"exclamation-mark-circle-filled",intent:"warning"}))):null)}}):D?(0,l.createElement)(l.Fragment,null," ",(0,l.createElement)(m.Tooltip,{title:(0,l.createElement)(f,{content:"autoupdatesIsDisabledHint"})},(0,l.createElement)(m.Icon,{name:"exclamation-mark-circle-filled",intent:"warning"}))):null)),null!=B&&null!==(R=B.updates)&&void 0!==R&&R.showControls?(0,l.createElement)(_.default,{isAutoupdatesDisabled:D,updateSettingsUrl:T,availableUpgrade:S,upgradeWhatsNewUrl:P,lastChecked:y,changelogUrl:v}):null,null!=B&&null!==(O=B.updates)&&void 0!==O&&O.showControls&&k?(0,l.createElement)(b.default,i()({compact:!0},k)):null,C?(0,l.createElement)(g.default,i()({compact:!0},C)):null,A||L?(0,l.createElement)(l.Fragment,null,(0,l.createElement)("hr",null),(0,l.createElement)(m.Text,{component:"p",fontSize:"md"},(0,l.createElement)(f,{content:"systemSecurity"})),A?(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Link,{href:"/smb/settings/tools-proxy?url=/admin/server-protection/"},(0,l.createElement)(f,{content:"fail2banManagement"})),": ","on"===M?(0,l.createElement)(m.Status,{intent:"success"},(0,l.createElement)(f,{content:"fail2banActive"})):"failed"===M?(0,l.createElement)(m.Status,{intent:"danger"},(0,l.createElement)(f,{content:"fail2banError"})):(0,l.createElement)(m.Status,{intent:"inactive"},(0,l.createElement)(f,{content:"fail2banInactive"}))):null,L?(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Link,{href:"/smb/settings/tools-proxy?url=/admin/web-app-firewall/"},(0,l.createElement)(f,{content:"modSecurityManagement"})),": ","On"===U?(0,l.createElement)(m.Status,{intent:"success"},(0,l.createElement)(f,{content:"modSecurityStateOn"})):(0,l.createElement)(m.Status,{intent:"inactive"},(0,l.createElement)(f,{content:"modSecurityState".concat(U)}))):null):null,I?(0,l.createElement)(l.Fragment,null,(0,l.createElement)("hr",null),(0,l.createElement)("div",{className:"side-panel__item"},(0,l.createElement)(m.Link,{href:"/smb/settings/tools-proxy?url=/plesk/server/statistics/"},(0,l.createElement)(f,{content:"systemMoreLink"})))):null)};y.propTypes={hostname:c().string.isRequired,publicIpAddress:c().string,ipAddress:c().string.isRequired,os:c().string.isRequired,productName:c().string.isRequired,panelVersion:c().string.isRequired,installedPatch:c().string,isUpdateAllowed:c().bool.isRequired,isUpdatesAvailable:c().bool,lastChecked:c().string.isRequired,lastUpdate:c().string.isRequired,changelogUrl:c().string.isRequired,isAutoupdatesDisabled:c().bool.isRequired,updateSettingsUrl:c().string.isRequired,availableUpgrade:c().string,upgradeWhatsNewUrl:c().string,updates:c().shape(b.default.propTypes),pum:c().shape(g.default.propTypes),isFail2banAvailable:c().bool.isRequired,fail2banStatus:c().string.isRequired,isModSecurityAvailable:c().bool.isRequired,modSecurityState:c().string.isRequired,isStatisticsAvailable:c().bool.isRequired},y.defaultProps={publicIpAddress:void 0,installedPatch:void 0,isUpdatesAvailable:!1,availableUpgrade:void 0,upgradeWhatsNewUrl:void 0,updates:void 0,pum:void 0},t.default=y},907:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(144),o=n(799),c=n(576),m=n(908),d=n(909),u=n(910),p=n(913),E=n(800),b=n(582),_=n(556);const g=l.Locale.getSection("components.sidebar"),h=l.Locale.getTranslate("components.sidebar"),f=l.Locale.getTranslate("admin.components.elements.status"),y=l.Locale.getTranslate("admin.components.lists.subscriptions"),w=l.Locale.getSection("components.buttons"),v=({commonButtons:e,panelSystemSection:t,hostingSection:i,accountSection:s,solutionSection:v,removeSection:D,subscriptionInfoSection:T,panelStatSection:S,customButtons:P,isDomainRegistrationVisible:k,promoRssFeedItemCount:C})=>{const A=(0,_.useHistory)(),M=({id:e,url:t,attention:n})=>{l.messageBox.show({type:Jsw.messageBox.TYPE_YESNO,subtype:"toggle",text:g.lmsg("applyConfirmation"),onYesClick(){(0,l.redirectPost)(t,{redirect:`/admin/subscription/overview/id/${e}}`,ids:[e]})},needAttention:!0,needAttentionText:n,needAttentionBlockSubmit:!0,buttonTitles:{yes:w.lmsg("yes"),no:w.lmsg("no")}})};return(0,a.createElement)(a.Fragment,null,null!=e&&e.length?(0,a.createElement)(o.default,{id:"panel-web-commonButtonsSection"},(0,a.createElement)(r.ItemList,null,e.map((({id:e,href:t,target:n,icon:i,title:s,comment:l,selector:o,subscriptions:c})=>(0,a.createElement)(r.Item,{key:t,component:"a","data-identity":e,href:t,target:n||void 0,rel:n?"noopener noreferrer":void 0,icon:{src:i,size:16},tooltip:l,onClick:!1!==o&&c?e=>{"_blank"===n||t.startsWith("http")||(e.preventDefault(),(0,p.default)(c,s,t,A))}:void 0},s))))):null,t?(0,a.createElement)(u.default,t):null,i?(0,a.createElement)(o.default,{id:"panel-web-hostingSection",title:(0,a.createElement)(h,{content:"hostingSection"})},i.hosting?(0,a.createElement)(a.Fragment,null,i.hosting.ipV4Address?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},i.hosting.ipV6Address?(0,a.createElement)(h,{content:"ipV4Address"}):(0,a.createElement)(h,{content:"ipAddress"}),":")," ",(0,a.createElement)("b",null,i.hosting.ipV4Address," (",i.hosting.isIpV4Shared?(0,a.createElement)(h,{content:"ipAddressShared"}):(0,a.createElement)(h,{content:"ipAddressExclusive"}),")")):null,i.hosting.ipV6Address?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"ipV6Address"}),":")," ",(0,a.createElement)("b",null,i.hosting.ipV6Address," (",i.hosting.isIpV6Shared?(0,a.createElement)(h,{content:"ipAddressShared"}):(0,a.createElement)(h,{content:"ipAddressExclusive"}),")")):null,(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"sysUser"}),":")," ",(0,a.createElement)("b",null,i.hosting.sysUser))):(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(h,{content:"noHostingHint"})),i.subscriberLoginUrl?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Action,{icon:{src:n(823)},href:i.subscriberLoginUrl},i.subscriberLoginText)):null,i.isOutgoingMailLimitsAvailable?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"buttonEditOutgoingMailLimitsHint"})},(0,a.createElement)(r.Action,{id:"buttonEditOutgoingMailLimits",icon:{src:n(914)},href:`/admin/outgoing-mail/edit-limit/type/subscription/id/${i.id}/?redirect=/admin/subscription/overview/id/${i.id}`},(0,a.createElement)(h,{content:"buttonEditOutgoingMailLimits"})))):null,(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"subscriptionStatus"}),":")," ",(0,a.createElement)("b",null,(0,a.createElement)(r.Status,{intent:i.subscriptionStatusActive?"success":"danger"},i.subscriptionStatusActive?(0,a.createElement)(f,{content:"onStateSubscription"}):(0,a.createElement)(f,{content:"offStateSubscription"})))," ",(0,a.createElement)(r.AuxiliaryActions,null,(0,a.createElement)(r.Tooltip,{title:i.subscriptionStatusActive?(0,a.createElement)(h,{content:"buttonSuspendHint"}):(0,a.createElement)(h,{content:"buttonActivateHint"})},(0,a.createElement)(r.Link,{id:"buttonToggle",onClick:()=>{return e=i.id,void(0,l.redirectPost)(`/admin/subscription/toggle/id/${e}`);var e}},i.subscriptionStatusActive?(0,a.createElement)(h,{content:"buttonSuspend"}):(0,a.createElement)(h,{content:"buttonActivate"}))))),(0,a.createElement)(E.default,{url:`/admin/subscription/edit-description/id/${i.id}`,data:i.descriptions,objectType:"subscription",object:i.name}),i.statPanel?(0,a.createElement)(d.default,i.statPanel):null):null,s?(0,a.createElement)(o.default,{id:"panel-web-accountSection",title:(0,a.createElement)(h,{content:"accountSection"})},(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"subscriber"}),":")," ",(0,a.createElement)("b",null,s.subscriberOverviewUrl?(0,a.createElement)(b.default,{to:s.subscriberOverviewUrl},s.subscriberContactName+(s.subscriberCompanyName?` (${s.subscriberCompanyName})`:"")):s.subscriberContactName+(s.subscriberCompanyName?` (${s.subscriberCompanyName})`:""))," ",(0,a.createElement)(r.AuxiliaryActions,null,(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"buttonChangeOwnerHint"})},(0,a.createElement)(r.Link,{id:"buttonChangeOwner",onClick:()=>{return e=s.id,void(0,l.redirectPost)(`/plesk/client@any/domain@multi/chowner?overview=true&backUrl=${location.pathname}&del[0]=${e}`);var e}},(0,a.createElement)(h,{content:"buttonChangeOwner"}))))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"plan"}),":")," ",(0,a.createElement)("b",null,s.subscription?(0,a.createElement)(a.Fragment,null,(0,a.createElement)(b.default,{to:s.subscription.url},s.subscription.name),s.subscription.isLocked||!s.subscription.isSynchronized?(0,a.createElement)(a.Fragment,null," (",(0,a.createElement)(r.Tooltip,{title:s.subscription.isLocked?(0,a.createElement)(y,{content:"statusLocked"}):(0,a.createElement)(y,{content:"statusUnsynchronized"})},(0,a.createElement)(r.Status,{icon:{src:s.subscription.isLocked?n(814):n(815)}},s.subscription.isLocked?(0,a.createElement)(f,{content:"lockedStateDomain"}):(0,a.createElement)(f,{content:"unsynchronizedStateDomain"}))),")"):null):(0,a.createElement)(h,{content:"planCustom"}))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"addons"}),":")," ",(0,a.createElement)("b",null,s.addons.length?s.addons.map((({id:e,name:t})=>(0,a.createElement)(a.Fragment,{key:e},(0,a.createElement)(b.default,{to:`/admin/customer-service-plan/edit/id/${e}`},t),(0,a.createElement)("br",null)))):"—")),s.changeLimitsPermission&&s.vendorHasPlans?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"buttonSwitchToAnotherPlanHint"})},(0,a.createElement)(r.Action,{id:"buttonSwitchToAnotherPlan",icon:{src:n(915)},href:`/admin/subscription/change-current/id/${s.id}`},(0,a.createElement)(h,{content:"buttonSwitchToAnotherPlan"})))):null,(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"buttonManuallyEditParametersHint"})},(0,a.createElement)(r.Action,{id:"buttonManuallyEditParameters",icon:{src:n(914)},href:`/admin/subscription/edit/id/${s.id}/?redirect=/admin/subscription/overview/id/${s.id}`},(0,a.createElement)(h,{content:"buttonManuallyEditParameters"})))),s.changeLimitsPermission&&s.subscription&&(s.subscription.isLocked||!s.subscription.isSynchronized)?(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:s.subscription.isLocked?(0,a.createElement)(h,{content:"buttonUnlockAndSyncHint"}):(0,a.createElement)(h,{content:"buttonSyncHint"})},(0,a.createElement)(r.Action,{id:"buttonUnlockAndSync",icon:{src:n(916)},onClick:()=>{(0,l.redirectPost)(`/admin/subscription/synchronize/id/${s.id}`)}},s.subscription.isLocked?(0,a.createElement)(h,{content:"buttonUnlockAndSync"}):(0,a.createElement)(h,{content:"buttonSync"})))):null,(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"setupDate"}),":")," ",(0,a.createElement)("b",null,s.setupDate)),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"expirationDate"}),":")," ",(0,a.createElement)("b",null,s.expirationDate||"—"))):null,v?(0,a.createElement)(o.default,{id:"panel-web-solutionSection",title:(0,a.createElement)(h,{content:"solutionSection"})},(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"toCustomerApplyHint"})},(0,a.createElement)(r.Action,{id:"toCustomerApplyButton",icon:{src:n(917)},onClick:()=>{M({id:v.id,url:"/admin/business-model-upgrade/manual-subscription-solution/solution/toCustomer/",attention:l.Locale.getSection("admin.components.lists.businessmodelupgrade.subscriptions").lmsg("toCustomerApplyHint")})}},(0,a.createElement)(h,{content:"toCustomerApplyButton"})))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"toSubscriptionWithUsersApplyHint"})},(0,a.createElement)(r.Action,{id:"toSubscriptionWithUsersApplyButton",icon:{src:n(918)},onClick:()=>{M({id:v.id,url:"/admin/business-model-upgrade/manual-subscription-solution/solution/toSubscriptionWithUsers/",attention:l.Locale.getSection("admin.components.lists.businessmodelupgrade.subscriptions").lmsg("toSubscriptionWithUsersApplyHint")})}},(0,a.createElement)(h,{content:"toSubscriptionWithUsersApplyButton"})))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"toSubscriptionWithoutUsersApplyHint"})},(0,a.createElement)(r.Action,{id:"toSubscriptionWithoutUsersApplyButton",icon:{src:n(919)},onClick:()=>{M({id:v.id,url:"/admin/business-model-upgrade/manual-subscription-solution/solution/toSubscriptionWithoutUsers/",attention:l.Locale.getSection("admin.components.lists.businessmodelupgrade.subscriptions").lmsg("toSubscriptionWithoutUsersApplyHint")})}},(0,a.createElement)(h,{content:"toSubscriptionWithoutUsersApplyButton"}))))):null,D?(0,a.createElement)(o.default,{id:"panel-customer-removeSection"},(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(h,{content:"buttonRemoveSubscriptionHint"})},(0,a.createElement)(r.Action,{id:"buttonRemove",icon:{src:n(810)},onClick:()=>{l.messageBox.show({type:l.messageBox.TYPE_YESNO,subtype:l.messageBox.SUBTYPE_DELETE,text:g.lmsg("buttonRemoveSubscriptionConfirmationTitle",{name:`<b>${D.name}</b>`}),description:g.lmsg("buttonRemoveSubscriptionConfirmationDescription"),onYesClick(){(0,l.redirectPost)(`/admin/subscription/delete-current/id/${D.id}`)},isAjax:D.isHomonymSearchEnabled,requestUrl:"/admin/subscription/search-homonym-data/",requestParams:{ids:D.id},loadingTitle:l.Locale.getSection("components.homonyms").lmsg("loading")})}},(0,a.createElement)(h,{content:"buttonRemoveSubscription"}))))):null,T?(0,a.createElement)(o.default,{id:"panel-web-subscriptionInfoSection",title:(0,a.createElement)(h,{content:"subscriptionInfoSection"})},(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"subscription"}),":")," ",(0,a.createElement)("b",null,(0,a.createElement)(b.default,{to:T.subscriptionOverviewUrl},T.subscriptionName))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"subscriptionStatus"}),":")," ",(0,a.createElement)("b",null,(0,a.createElement)(r.Status,{intent:T.subscriptionStatusActive?"success":"danger"},T.subscriptionStatusActive?(0,a.createElement)(f,{content:"onStateSubscription"}):(0,a.createElement)(f,{content:"offStateSubscription"})))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(h,{content:"subscriber"}),":")," ",(0,a.createElement)("b",null,T.subscriberOverviewUrl?(0,a.createElement)(b.default,{to:T.subscriberOverviewUrl},T.subscriberContactName+(T.subscriberCompanyName?` (${T.subscriberCompanyName})`:"")):T.subscriberContactName+(T.subscriberCompanyName?` (${T.subscriberCompanyName})`:""))),(0,a.createElement)(d.default,T.statPanel)):null,S?(0,a.createElement)(o.default,{id:"panel-web-panelStatSection",title:(0,a.createElement)(h,{content:"panelStatSection"})},(0,a.createElement)(d.default,S)):null,P.length?(0,a.createElement)(o.default,{id:"panel-web-customButtonsSection",title:(0,a.createElement)(h,{content:"customButtonsSection"})},(0,a.createElement)("ul",null,P.map((({href:e,target:t,title:n})=>(0,a.createElement)("li",{key:n},(0,a.createElement)(r.Link,{href:e,target:t||void 0,rel:t?"noopener noreferrer":null},n)))))):null,k?(0,a.createElement)(o.default,{id:"panel-web-mpcDomainsSection",title:(0,a.createElement)(h,{content:"mpcDomainsSection"})},(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Action,{icon:{src:n(920)},href:"/smb/mpc/register-domains",target:"_blank"},(0,a.createElement)(h,{content:"buttonRegisterDomain"}))),(0,a.createElement)("div",{className:"side-panel__item"},(0,a.createElement)(r.Action,{icon:{src:n(921)},href:"/smb/mpc/manage-domains",target:"_blank"},(0,a.createElement)(h,{content:"buttonManageDomains"})))):null,C?(0,a.createElement)(o.default,{id:"panel-web-rssFeedCustomSpotSection",title:(0,a.createElement)(h,{content:"customSpotSection"})},(0,a.createElement)(c.default,{renderMode:"after"},(()=>new m.default({itemCount:C,dataUrl:"/smb/web/rss-feed-custom-spots-data"})))):null)};v.propTypes={commonButtons:s().array,panelSystemSection:s().shape(u.default.propTypes),hostingSection:s().shape({id:s().number.isRequired,name:s().string.isRequired,hosting:s().object,subscriberLoginUrl:s().string,subscriberLoginText:s().string,isOutgoingMailLimitsAvailable:s().bool,subscriptionStatusActive:s().bool,statPanel:s().object,descriptions:s().object.isRequired}),accountSection:s().shape({id:s().number.isRequired,subscriberContactName:s().string.isRequired,subscriberCompanyName:s().string.isRequired,subscriberOverviewUrl:s().string,subscription:s().object,addons:s().array.isRequired,changeLimitsPermission:s().bool.isRequired,vendorHasPlans:s().bool.isRequired,setupDate:s().string.isRequired,expirationDate:s().string.isRequired}),solutionSection:s().shape({id:s().number.isRequired}),removeSection:s().shape({id:s().number.isRequired,name:s().string.isRequired,isHomonymSearchEnabled:s().bool.isRequired}),subscriptionInfoSection:s().shape({subscriptionName:s().string.isRequired,subscriptionOverviewUrl:s().string.isRequired,subscriptionStatusActive:s().bool.isRequired,subscriberContactName:s().string.isRequired,subscriberCompanyName:s().string.isRequired,subscriberOverviewUrl:s().string,statPanel:s().shape({limits:s().object.isRequired})}),panelStatSection:s().shape({limits:s().object.isRequired}),customButtons:s().array,isDomainRegistrationVisible:s().bool,promoRssFeedItemCount:s().number},v.defaultProps={commonButtons:void 0,panelSystemSection:void 0,hostingSection:void 0,accountSection:void 0,solutionSection:void 0,removeSection:void 0,subscriptionInfoSection:void 0,panelStatSection:void 0,customButtons:[],isDomainRegistrationVisible:!1,promoRssFeedItemCount:void 0},t.default=v},906:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>a.default});var a=n(907)},913:(e,t,n)=>{"use strict";n.r(t);var a=n(144),i=n(582);t.default=(e,t,n,s)=>{const r=a.Locale.getSection("smb.controllers.web._shared"),l=e=>{const t=`/smb/account/switch/id/${e}?hideNotice=1&returnUrl=${encodeURIComponent(n)}`;(0,i.isMatch)(t)?s.push(t):(0,a.redirect)(t)};let o="";$A(e).each((function(e){o+=`<option value="${e.id}">${e.name}</option>`}));const c=r.lmsg("operationSelectorTitle"),m=`<p>${r.lmsg("operationSelectorHint")}</p><div class="form-row"><div class="field-name"><label for="subscription-selector">${c}</label></div><div class="field-value"><select id="subscription-selector">${o}</select></div></div>`;if(1===e.length)return void l(e[0].id);const d=new a.Popup({title:t,content:m,buttons:[{title:a.Locale.getSection("components.buttons").lmsg("ok"),handler(){l(d._componentElement.querySelector("select").value),d.hide()}},{title:a.Locale.getSection("components.buttons").lmsg("cancel"),handler(){d.hide()}}]})}},745:(e,t,n)=>{"use strict";n.r(t);var a=n(155),i=n(154),s=n(261),r=n.n(s),l=n(144),o=n(742);const c=l.Locale.getTranslate("admin.controllers.home.admin"),m=({compact:e,updates:t,lastChecked:n})=>(0,i.createElement)(o.default,{compact:e,title:t.length>1?(0,i.createElement)(c,{content:"updatesForPackagesAreAvailable",params:{packages:(0,i.createElement)(a.Link,{href:"/admin/pum/updates-list"},(0,i.createElement)(c,{content:"packages",params:{count:t.length}}))}}):(0,i.createElement)(c,{content:"updatesForPackageIsAvailable",params:{package:"".concat(t[0].name," ").concat(t[0].version_to)}}),hint:n?(0,i.createElement)(c,{content:"updatesLastChecked",params:{date:n}}):null},(0,i.createElement)(a.Button,{onClick:async()=>{const{PopupPackagesUpdate:e}=await Plesk.require("app/pum");new e({urls:{packageUpdateInfo:"/admin/pum/update-info",updatePackages:"/admin/pum/update"},packages:t})},intent:"primary"},t.length>1?(0,i.createElement)(c,{content:"updateAll"}):(0,i.createElement)(c,{content:"updateNow"})),"    ",(0,i.createElement)(a.Link,{href:"/admin/pum/updates-list"},(0,i.createElement)(c,{content:"showDetails"})));m.propTypes={compact:r().bool,updates:r().array,lastChecked:r().string},m.defaultProps={compact:!1,updates:[],lastChecked:null},t.default=m},742:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261),r=n.n(s);const l=({compact:e,title:t,hint:s,children:r})=>{const l=(0,a.createElement)(i.Icon,{src:n(743),size:"16"});return(0,a.createElement)(i.Alert,{intent:"info"},e?(0,a.createElement)(a.Fragment,null,(0,a.createElement)("p",null,l," ",t),(0,a.createElement)("p",null,r),s?(0,a.createElement)("p",null,(0,a.createElement)(i.Text,{intent:"muted"},s)):null):(0,a.createElement)(i.Media,{image:l},(0,a.createElement)(i.MediaSection,null,t),(0,a.createElement)(i.MediaSection,null,r),s?(0,a.createElement)(i.MediaSection,null,(0,a.createElement)(i.Text,{intent:"muted"},s)):null))};l.propTypes={compact:r().bool,title:r().any.isRequired,children:r().any.isRequired,hint:r().any},l.defaultProps={compact:!1,hint:null},t.default=l},744:(e,t,n)=>{"use strict";n.r(t);var a=n(738),i=n.n(a),s=n(155),r=n(154),l=n(261),o=n.n(l),c=n(302),m=n(405),d=n(144),u=n(742);function p(){const e=i()(["\n    mutation UpdateComponents {\n        updateComponents {\n            id\n        }\n    }\n"]);return p=function(){return e},e}const E=d.Locale.getTranslate("admin.controllers.home.admin"),b=(0,c.gql)(p()),_=({compact:e,availablePatch:t,updateWhatsNewUrl:n,runningTaskId:a})=>{const[i,l]=(0,r.useState)(a),[o,{loading:c}]=(0,m.useMutation)(b,{onCompleted:({updateComponents:e})=>{l(e.id)}});return(0,r.useEffect)((()=>{i&&d.Observer.append((({id:e})=>{+e==+i&&window.location.reload()}),"plesk:taskComplete")}),[i]),(0,r.createElement)(u.default,{compact:e,title:(0,r.createElement)(E,{content:"updatesAvailable",params:{version:t}})},(0,r.createElement)(s.Button,{intent:"primary",onClick:async()=>{(0,d.clearStatusMessages)();try{await o()}catch({message:e}){(0,d.addStatusMessage)("warning",e)}},state:c||i?"loading":null},(0,r.createElement)(E,{content:"installNow"})),"    ",(0,r.createElement)(s.Link,{href:"/admin/update",target:"_blank"},(0,r.createElement)(E,{content:"installShow"})),"    ",(0,r.createElement)(s.Link,{href:n,target:"_blank"},(0,r.createElement)(E,{content:"seeWhatsNew"})))};_.propTypes={compact:o().bool,availablePatch:o().string.isRequired,updateWhatsNewUrl:o().string.isRequired,runningTaskId:o().string},_.defaultProps={compact:!1,runningTaskId:void 0},t.default=_},741:(e,t,n)=>{"use strict";n.r(t);var a=n(155),i=n(154),s=n(144),r=n(261),l=n.n(r),o=n(742);const c=s.Locale.getTranslate("admin.controllers.home.admin"),m=({isClassicMode:e,isAutoupdatesDisabled:t,updateSettingsUrl:n,changelogUrl:r,availableUpgrade:l,upgradeWhatsNewUrl:m,...d})=>{const[u,p]=(0,i.useState)(!1),[E,b]=(0,i.useState)(l),[_,g]=(0,i.useState)(m),[h,f]=(0,i.useState)(d.lastChecked);return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(a.Heading,{component:"div",level:5},u?(0,i.createElement)(a.Status,{progress:!0},(0,i.createElement)(c,{content:"waitMessage"})):(0,i.createElement)(a.Link,{onClick:async()=>{p(!0),(0,s.clearStatusMessages)();const{status:e,lastChecked:t,statusMessages:n,newVersion:a,whatsNewUrl:i}=await s.api.post("/admin/home/check-for-updates");p(!1),"error"!==e?(b(a),g(i),f(t)):n.forEach((({status:e,content:t})=>{(0,s.addStatusMessage)(e,t)}))},"data-name":"checkForUpdates"},(0,i.createElement)(c,{content:"checkForUpdates"}))),h?(0,i.createElement)("p",null,(0,i.createElement)(a.Text,{intent:"muted","data-name":"lastCheckedDate"},(0,i.createElement)(c,{content:"checkedAt",params:{lastChecked:h}}))):null,e?(0,i.createElement)("p",null,(0,i.createElement)(a.Link,{href:r,target:"_blank"},(0,i.createElement)(c,{content:"seeChangelog"})),(0,i.createElement)("span",{className:"delimiter"}," | "),(0,i.createElement)(a.Link,{href:"/admin/update/add-components/",target:"_blank"},(0,i.createElement)(c,{content:"addComponents"}))):null,e&&t?(0,i.createElement)(a.Status,{intent:"warning"},(0,i.createElement)(a.Link,{href:n},(0,i.createElement)(c,{content:"enableAutoupdate"}))):null,E?(0,i.createElement)(o.default,{compact:!e,title:(0,i.createElement)(c,{content:"updateIsAvailable",params:{product:E}})},(0,i.createElement)(a.Button,{intent:"primary",component:"a",href:"/admin/update/product",target:"_blank",rel:"noopener noreferrer"},(0,i.createElement)(c,{content:"installNow"})),"    ",(0,i.createElement)(a.Link,{href:_,target:"_blank"},(0,i.createElement)(c,{content:"seeWhatsNew"}))):null)};m.propTypes={isClassicMode:l().bool,availableUpgrade:l().string,upgradeWhatsNewUrl:l().string,lastChecked:l().string.isRequired,changelogUrl:l().string.isRequired,updateSettingsUrl:l().string.isRequired,isAutoupdatesDisabled:l().bool.isRequired},m.defaultProps={isClassicMode:!1,availableUpgrade:null,upgradeWhatsNewUrl:null},t.default=m},950:(e,t,n)=>{"use strict";n.r(t),n.d(t,{ConnectionInfo:()=>b});var a=n(154),i=n(302),s=n(405),r=n(155),l=n(940),o=n(722),c=n(597),m=n(144),d=n(951),u=n(954);const p=i.gql`
    fragment DatabaseFields on Database {
        id
        name
        server {
            type
            fork
            host
            port
        }   
        defaultUser {
            id
            login
        }
        users {
            id
            login
        }
        isWebadminInstalled
    }
`,E=i.gql`
    ${p}
    query GetDomain($id: ID!) {
        domain: node(id: $id) {
            ... on Domain {
                id
                name(idn: false)
                sysUser {
                    login
                }
                ipAddresses {
                    ipAddress(publicIp: true)
                }
                databases {
                    ...DatabaseFields
                }
                applicationDatabases {
                    ...DatabaseFields
                }
                relatedDatabase {
                    ...DatabaseFields
                }
                baseDomain {
                    id
                    databases {
                        ...DatabaseFields
                    }
                }
            }
        }
    }
`,b=()=>{const[e,t]=(0,a.useState)([]),[n,i]=(0,a.useState)(null),[p,b]=(0,a.useState)(!1),[_,g]=(0,c.default)("connection-info"),h=_?JSON.parse(atob(_)):null,f=h?h.domainId:0,y=!!h,w=()=>{g(null)},{loading:v,data:D,error:T}=(0,s.useQuery)(E,{variables:{id:btoa(`Domain:${f}`)},skip:!y});(0,a.useEffect)((()=>{y&&(b(!0),m.api.get(`/smb/web/connection-info/id/${f}`).then((e=>{let n=[];e.statusMessages&&(n=e.statusMessages.filter((({status:e})=>"error"===e)).map((({content:e})=>e))),t(n),e.embeddedForms&&i({id:e.id,embeddedForms:e.embeddedForms}),b(!1)})).catch((e=>{t([e.message]),b(!1)})))}),[y,f]);const{messages:S}=m.Locale.getSection("components.forms.domain.connection-info");return(0,a.createElement)(r.LocaleProvider,{messages:S},(0,a.createElement)(r.Drawer,{title:(0,a.createElement)(r.Translate,{content:"title"}),subtitle:D?D.domain.name:null,size:"sm",isOpen:y,onClose:w,"data-type":"connection-info"},(()=>{if(v||p)return(0,a.createElement)(r.ContentLoader,null);if(T)return(0,a.createElement)(l.default,{error:T});if(!D)return(0,a.createElement)(r.ContentLoader,null);const t=D.domain.baseDomain?D.domain.baseDomain:D.domain,i=Number(atob(t.id).split(":")[1]),{databases:s}=t;let c=D.domain.relatedDatabase;return!c&&0<D.domain.applicationDatabases.length?c=D.domain.applicationDatabases[0]:!c&&0<s.length&&(c=s[0]),(0,a.createElement)(a.Fragment,null,e.map((e=>(0,a.createElement)(r.StatusMessage,{key:btoa(e),intent:"danger"},(0,a.createElement)("span",{dangerouslySetInnerHTML:{__html:e}})))),D.domain.sysUser?(0,a.createElement)(u.default,{domain:D.domain,showFtpAccounts:h&&h.showFtpAccounts,showManageAccess:h&&h.showManageAccess,isShellForbidden:h&&h.isShellForbidden,isParentOpen:y,onAction:w}):null,h&&h.showDatabases?(0,a.createElement)(d.default,{baseDomainId:i,database:c,databases:s,onAction:w}):null,n&&0<n.embeddedForms.length?(0,a.createElement)(o.default,{vertical:!0,id:n.id,embeddedForms:n.embeddedForms,submitButton:!1,applyButton:!1,cancelButton:!1,render:({renderForm:e})=>e({actionButtons:null})}):null)})()))};t.default=b},952:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261);const r=({content:e})=>(0,a.createElement)(i.Button,{ghost:!0,icon:"copy",tooltip:(0,a.createElement)(i.Translate,{content:"copyToClipboard"}),onClick:()=>(0,i.copyToClipboard)(e),"data-action":"copy-to-clipboard"});r.propTypes={content:n.n(s)().string.isRequired},t.default=r},951:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261),r=n.n(s),l=n(952),o=n(953),c=n(582);const m=({baseDomainId:e,database:t,databases:n,onAction:s})=>{const[r,m]=(0,a.useState)(!1);return(0,a.createElement)("div",{"data-section":"database"},(0,a.createElement)(i.Section,{title:(0,a.createElement)(i.Translate,{content:"database"})},0===n.length?(0,a.createElement)(i.Hint,null,(0,a.createElement)(i.Translate,{content:"databaseNotCreatedHint"})):1<n.length?(0,a.createElement)(i.Hint,null,(0,a.createElement)(i.Translate,{content:"databaseHint",params:{number:n.length}})):null),(0,a.createElement)(i.Section,null,t?(()=>{const e=t.server.port?`${t.server.host}:${t.server.port}`:t.server.host,n=t.server.fork||t.server.type;let s=t.defaultUser;!s&&0<t.users.length&&(s=t.users[0]);const c=s?Number(atob(s.id).split(":")[1]):null;return(0,a.createElement)(a.Fragment,null,(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"databaseHost"}),"data-type":"host"},(0,a.createElement)(i.Translate,{content:"databaseHostValue",params:{value:e,fork:(0,a.createElement)(i.Translate,{content:`databaseType.${n.toLowerCase()}`})}}),(0,a.createElement)(l.default,{content:e})),(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"databaseName"}),"data-type":"name"},t.name,(0,a.createElement)(l.default,{content:t.name})),s?(0,a.createElement)(a.Fragment,null,(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"username"}),"data-type":"login"},s.login,(0,a.createElement)(l.default,{content:s.login})),(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"password"}),"data-type":"password"},"•".repeat(16),(0,a.createElement)(o.default,{title:(0,a.createElement)(i.Translate,{content:"changeDatabaseUserPasswordTitle"}),notice:(0,a.createElement)(i.Translate,{content:"changeDatabaseUserPasswordNotice"}),handlerUrl:`/smb/database/change-user-password/id/${c}`,target:(0,a.createElement)(i.Button,{ghost:!0,icon:"pencil",tooltip:(0,a.createElement)(i.Translate,{content:"changePasswordTooltip"}),onClick:()=>m(!0),"data-type":"edit-password-button"}),visible:r,onClose:()=>m(!1)}))):null)})():null,(0,a.createElement)(i.SectionItem,null,(0,a.createElement)(i.Columns,{gap:"md"},(()=>{const n=[];if(!t)return n.push((0,a.createElement)(i.Column,{key:"addDatabase"},(0,a.createElement)(i.Action,{href:`/smb/database/create/domainId/${e}`,icon:"database-plus",onClick:s,"data-action":"create-database"},(0,a.createElement)(i.Translate,{content:"addDatabase"})))),n;if(t.isWebadminInstalled){const e=Number(atob(t.id).split(":")[1]);"MYSQL"===t.server.type?n.push((0,a.createElement)(i.Column,{key:"MYSQL"},(0,a.createElement)(i.Action,{href:`/smb/database/webadmin/id/${e}`,target:"dbedit",icon:"phpmyadmin",onClick:s,"data-action":"open-php-my-admin"},(0,a.createElement)(i.Translate,{content:"phpMyAdmin"})))):"MSSQL"===t.server.type&&n.push((0,a.createElement)(i.Column,{key:"MSSQL"},(0,a.createElement)(i.Action,{href:`/smb/database/webadmin/id/${e}`,target:"dbedit",icon:"database-box",onClick:s,"data-action":"open-my-little-admin"},(0,a.createElement)(i.Translate,{content:"myLittleAdmin"}))))}return n.push((0,a.createElement)(i.Column,{key:"manageDatabases"},(0,a.createElement)(i.Action,{component:c.default,to:`/smb/database/list/domainId/${e}`,icon:"database",onClick:s,"data-action":"manage-databases"},(0,a.createElement)(i.Translate,{content:"manageDatabases"})))),n})()))))};m.propTypes={baseDomainId:r().number.isRequired,database:r().object,databases:r().array,onAction:r().func},m.defaultProps={database:null,databases:[],onAction:()=>{}},t.default=m},953:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(723),r=n(144),l=n(261),o=n.n(l);const c=({title:e,notice:t,handlerUrl:n,target:l,visible:o,onClose:c})=>{const[m,d]=(0,a.useState)(void 0),[u,p]=(0,a.useState)([]),[E,b]=(0,a.useState)({}),_=()=>{c(),p([]),b({})};return(0,a.createElement)(i.Popover,{title:e,target:l,placement:"top-right",visible:o,onClose:_,"data-type":"edit-password"},(0,a.createElement)(i.Form,{vertical:!0,applyButton:!1,submitButton:{id:"btn-send",children:(0,a.createElement)(i.Translate,{content:"submit"===m?"buttonSaving":"buttonSave"})},cancelButton:{id:"btn-cancel",children:(0,a.createElement)(i.Translate,{content:"buttonCancel"}),onClick:_},state:m,errors:E,onSubmit:async e=>{d("submit");const t=await r.api.post(n,(0,s.toFormData)(e));d(null);let a=[],i={};"success"===t.status?_():(t.statusMessages&&(a=t.statusMessages.filter((({status:e})=>"error"===e)).map((({content:e})=>e))),t.message&&(i={password:{message:t.message}})),p(a),b(i)},"data-type":"form"},u.map((e=>(0,a.createElement)(i.StatusMessage,{key:btoa(e),intent:"danger"},(0,a.createElement)("span",{dangerouslySetInnerHTML:{__html:e}})))),t?(0,a.createElement)(i.StatusMessage,{intent:"info"},t):null,(0,a.createElement)(i.FormFieldPassword,{name:"password",label:(0,a.createElement)(i.Translate,{content:"newPassword"}),required:!0,"data-type":"password"})))};c.propTypes={title:o().node.isRequired,notice:o().node,handlerUrl:o().string.isRequired,target:o().element.isRequired,onClose:o().func.isRequired,visible:o().bool},c.defaultProps={notice:null,visible:!1},t.default=c},954:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261),r=n.n(s),l=n(953),o=n(955),c=n(952);const m=({domain:e,showFtpAccounts:t,showManageAccess:n,isShellForbidden:s,isParentOpen:r,onAction:m})=>{const[d,u]=(0,a.useState)(!1),p=e.baseDomain?e.baseDomain:e,E=Number(atob(p.id).split(":")[1]),b=n?(0,a.createElement)(i.Link,{href:(0,o.getContextUrl)(E,"/smb/web/edit"),onClick:m},(0,a.createElement)(i.Translate,{content:"systemUserCredentialsHintDetails"})):(0,a.createElement)(i.Popover,{target:(0,a.createElement)(i.Link,null,(0,a.createElement)(i.Translate,{content:"systemUserCredentialsHintDetails"})),placement:"bottom-left",visible:!!r&&null,"data-type":"details"},(0,a.createElement)(i.Paragraph,null,(0,a.createElement)(i.Translate,{content:s?"systemUserRemoveAccessDisabled":"systemUserRemoveAccessEnabled"}))),_=[];return t&&_.push((0,a.createElement)(i.Column,{key:"ftpAccounts"},(0,a.createElement)(i.Action,{href:(0,o.getContextUrl)(E,"/smb/ftp/users-list"),icon:"folder-key",onClick:m,"data-action":"show-ftp-accounts"},(0,a.createElement)(i.Translate,{content:"additionalFtpAccounts"})))),n&&_.push((0,a.createElement)(i.Column,{key:"manageAccess"},(0,a.createElement)(i.Action,{href:(0,o.getContextUrl)(E,"/smb/web/edit"),icon:"gear",onClick:m,"data-action":"manage-access"},(0,a.createElement)(i.Translate,{content:"manageAccess"})))),(0,a.createElement)("div",{"data-section":"user-credentials"},(0,a.createElement)(i.Section,{title:(0,a.createElement)(i.Translate,{content:"systemUserCredentials"})},(0,a.createElement)(i.Hint,null,(0,a.createElement)(i.Translate,{content:"systemUserCredentialsHint",params:{details:b}}))),(0,a.createElement)(i.Section,null,e.ipAddresses.map((({ipAddress:e})=>(0,a.createElement)(i.FormField,{key:e,label:(0,a.createElement)(i.Translate,{content:"ipAddress"}),"data-type":"ip-address"},e,(0,a.createElement)(c.default,{content:e})))),(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"username"}),"data-type":"login"},e.sysUser.login,(0,a.createElement)(c.default,{content:e.sysUser.login})),(0,a.createElement)(i.FormField,{label:(0,a.createElement)(i.Translate,{content:"password"}),"data-type":"password"},"•".repeat(16),n?(0,a.createElement)(l.default,{title:(0,a.createElement)(i.Translate,{content:"changeSystemUserPasswordTitle"}),handlerUrl:`/smb/web/change-password/id/${E}`,target:(0,a.createElement)(i.Button,{ghost:!0,icon:"pencil",tooltip:(0,a.createElement)(i.Translate,{content:"changePasswordTooltip"}),onClick:()=>u(!0),"data-type":"edit-password-button"}),visible:d,onClose:()=>u(!1)}):null),0<_.length?(0,a.createElement)(i.SectionItem,null,(0,a.createElement)(i.Columns,{gap:"md"},_)):null))};m.propTypes={domain:r().object.isRequired,showFtpAccounts:r().bool.isRequired,showManageAccess:r().bool.isRequired,isShellForbidden:r().bool.isRequired,isParentOpen:r().bool.isRequired,onAction:r().func},m.defaultProps={onAction:()=>{}},t.default=m},949:(e,t,n)=>{"use strict";n.r(t),n.d(t,{ConnectionInfo:()=>a.ConnectionInfo,default:()=>a.default});var a=n(950)},955:(e,t,n)=>{"use strict";n.r(t),n.d(t,{getContextUrl:()=>a});const a=(e,t)=>{const n=encodeURIComponent(t);return"/smb/account/switch/id/".concat(e,"?hideNotice=1&returnUrl=").concat(n)}},957:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(556),s=n(302),r=n(405),l=n(155),o=n(144),c=n(635),m=n(597),d=n(582);const u=o.Locale.getSection("components.forms.domain.rename"),p=s.gql`
    mutation RenameDomain($id: ID!, $name: String!) {
        renameDomain(input: { id: $id, name: $name }) {
            domain {
                name
            }
        }
    }
`,E=s.gql`
    mutation RenameDomainAlias($id: ID!, $name: String!) {
        renameDomainAlias(input: { id: $id, name: $name }) {
            domainAlias {
                name
            }
        }
    }
`;t.default=()=>{const e=(0,i.useHistory)(),[t,n]=(0,m.default)("rename-domain"),[s,o]=(0,a.useState)(null),[b,_]=(0,a.useState)(null),[g,h]=(0,a.useState)([]),{addToast:f}=(0,c.useToaster)(),{id:y,domainName:w,isDomainAlias:v,parentDomain:D}=t?JSON.parse(decodeURIComponent(atob(t))):{},T=D&&!v,[S]=(0,r.useMutation)(v?E:p);return(0,a.createElement)(l.LocaleProvider,{messages:u.messages},(0,a.createElement)(l.Dialog,{isOpen:null!==t,closable:"submit"!==s,title:(0,a.createElement)(l.Translate,{content:v?"titleAlias":"title"}),size:"xs",onClose:()=>n(null),form:{vertical:!0,state:s,errors:b,onSubmit:async({name:t})=>{if(o(null),_(null),h([]),t)try{o("submit"),await S({variables:{id:btoa(`${v?"DomainAlias":"Domain"}:${y}`),name:t}}),f({intent:"success",message:(0,a.createElement)(l.LocaleProvider,{messages:u.messages},(0,a.createElement)(l.Translate,{content:v?"successMessageAlias":"successMessage",params:{oldName:(0,a.createElement)("b",null,w),newName:(0,a.createElement)(d.default,{to:`/smb/web/overview/id/${y}/type/${v?"alias":"domain"}`},T?`${t}.${D.displayName}`:t)}}))}),e.push(window.location.pathname,{reload:!0})}catch({graphQLErrors:e}){"validate"===e[0].extensions.category?_(e[0].extensions.messages):h(e.map((({message:e})=>e)))}finally{o(null)}else _({name:{isEmpty:(0,a.createElement)(l.Translate,{content:"domainNameIsRequired"})}})},submitButton:{children:(0,a.createElement)(l.Translate,{content:"submit"===s?"submitButtonProgress":"submitButton"})}}},g.map((e=>(0,a.createElement)(l.StatusMessage,{intent:"danger",key:e},e))),(0,a.createElement)(l.Paragraph,null,(0,a.createElement)(l.Translate,{content:v?"hintAlias":"hint",params:{domainName:(0,a.createElement)(l.Text,{bold:!0},w)}})),(0,a.createElement)(l.FormField,{name:"name",label:(0,a.createElement)(l.Translate,{content:v?"nameAlias":"name"})},(({getValue:e,setValue:t,isDisabled:n})=>(0,a.createElement)("div",null,(0,a.createElement)(l.Input,{disabled:n(),value:e(),onChange:e=>t(e.target.value),size:T?"lg":"fill"}),T?(0,a.createElement)(l.Text,{bold:!0},` . ${D.displayName}`):null)))))}},956:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>a.default});var a=n(957)},941:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261);const s=({children:e})=>(0,a.createElement)("div",{className:"smb-web-view-dynamic-list-action-list"},e);s.propTypes={children:n.n(i)().any},s.defaultProps={children:void 0},t.default=s},931:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(556),l=n(144),o=n(155),c=n(932),m=n(576),d=n(582),u=n(934),p=n(935),E=n(926),b=n.n(E),_=n(784),g=n.n(_),h=n(785),f=n.n(h),y=n(936),w=n.n(y),v=n(937),D=n.n(v),T=n(925),S=n.n(T);class P extends l.ActiveList{_initConfiguration(e){super._initConfiguration(e),this.itemActions.delete=p.default}_addEvents(){super._addEvents(),this.data.forEach((e=>{const t=this.getItemElement(e);t.querySelectorAll(".caption-service-toolbar .item-visible .toggler").forEach((e=>{e.addEventListener("click",(t=>{const n=e.closest(".caption-service-toolbar").querySelector(".item-invisible");n.classList.remove("item-invisible"),n.classList.add("item-visible");const a=e.closest(".item-visible");a.classList.remove("item-visible"),a.classList.add("item-invisible"),t.stopPropagation(),t.preventDefault()}))})),t.querySelectorAll(".js-webadmin").forEach((e=>{e.addEventListener("click",(t=>{const n=e.closest("div").querySelector("select"),a=n.options[n.selectedIndex],{userLogin:i,passwordPrompt:s}=a.dataset,r={domainId:e.closest(".active-list-item").querySelector(".js-domain-id").value};if(i){const e=prompt(s);if(!e)return;r.dbPassword=e}(0,l.redirect)({url:a.value,method:r.dbPassword?"post":"get",data:r,target:"dbedit"}),t.stopPropagation(),t.preventDefault()}))}))})),this._componentElement.querySelectorAll(".caption-head .dropdown-toggle").forEach((e=>{l.DropdownManager.register(e,(()=>e.parentNode.classList.contains("open")),(()=>e.parentNode.classList.add("open")),(()=>e.parentNode.classList.remove("open")))}))}itemCaptionHeadView(e){const t=super.itemCaptionHeadView(e);e.customDescription&&Object.keys(e.customDescription).length&&t.children.push((0,l.createElement)(".caption-description",(0,l.createElement)(".caption-description-wrap",Object.keys(e.customDescription).map(((t,n)=>(0,l.createElement)(".description-item",(0,l.createElement)("span.description-item-text",n>0?`${this.lmsg(`${t}Description`)}: `:"",(0,l.escapeHtml)(e.customDescription[t].truncate(50)),(0,l.createElement)("span.tooltipData",(0,l.escapeHtml)(e.customDescription[t]))),(0,l.createElement)("span.description-item-buttons",(0,l.createElement)("a.toggler",{onclick:this._getConfigParam("onEditDescription").bind(this,e,t)},this.lmsg("buttonDescriptionEdit")),(0,l.createElement)("a.toggler",{onclick:this._getConfigParam("onRemoveDescription").bind(this,e,t)},this.lmsg("buttonDescriptionRemove")))))))));const n=[];if("vrt_hst"===e.hostingType){let t=[(0,l.createElement)("i.icon",(0,l.createElement)("img",{src:b()}))," ",(0,l.createElement)("span",`${e.webrootDir}/`)];e.filemanagerUrl&&(t=(0,l.createElement)("a.i-link",{href:e.filemanagerUrl,onclick:this.navigate},t,(0,l.createElement)("span.tooltipData",this.lmsg("websiteAtHint")))),n.push([`${this.lmsg("websiteAt")} `,(0,l.createElement)("b",t)]),e.purchaseDomainMessage&&n.push(e.purchaseDomainMessage);const a=e.ipv4Address&&e.ipv6Address?`${e.ipv4Address}(v4), ${e.ipv6Address}(v6)`:e.ipv4Address||e.ipv6Address;n.push((0,l.createElement)("span",this.lmsg("ipAddress"),": ",(0,l.createElement)("b",a))),n.push((0,l.createElement)("span",this.lmsg("sysUser"),": ",(0,l.createElement)("b",(0,l.escapeHtml)(e.sysUser))))}else"none"===e.hostingType?n.push([this.lmsg("noHosting"),e.showAddHostingButton?[" ",(0,l.createElement)("a",{href:(0,l.prepareUrl)(e.changeHostingUrl)},`[${this.lmsg("changeHosting")}]`)]:""]):"frm_fwd"===e.hostingType||"std_fwd"===e.hostingType?n.push([`${this.lmsg("forwardingTo")} `,(0,l.createElement)("a[target=_blank]",{href:(0,l.prepareUrl)(e.forwardingUrl)},(0,l.escapeHtml)(e.forwardingDisplayUrl))]):e.isDomainAlias&&n.push(e.description);if(void 0!==e.icpStatus){const t=l.Locale.getSection("components.icp-permit");n.push(`${t.lmsg("icpPermit")}: `,(0,l.createElement)("span.tooltipData",t.lmsg(e.icpStatus?"icpStatusAllowedDescription":"icpStatusNotAllowedDescription")),(0,l.createElement)(this.urls.icpPermitLearnMore?`a.i-link[target=_blank][href=${this.urls.icpPermitLearnMore}]`:"b",(0,l.createElement)("i.icon",(0,l.createElement)('img[alt=""]',{src:e.icpStatus?g():f()}))," ",e.icpPermit?(0,l.escapeHtml)(e.icpPermit):t.lmsg("icpStatusNotAllowed"))),e.isIcpChangeable&&(n.push((0,l.createElement)("a",{onclick:this._getConfigParam("onIcpPermit").bind(this,e)},t.lmsg(e.icpPermit?"changeIcpPermit":"enterIcpPermit"))),n.push((0,l.createElement)("a",{onclick:this._getConfigParam("onIcpStatus").bind(this,e)},t.lmsg(e.icpStatus?"revokeIcpStatus":"grantIcpStatus"))))}return t.children.push((0,l.createElement)(".caption-summary",(0,l.createElement)(".caption-summary-wrap",n.map((function(e){return(0,l.createElement)("span.summary-item",e)}))))),t.children.push((0,l.createElement)(".caption-toolbar",(0,l.createElement)(".caption-toolbar-wrap",(0,l.createElement)("a.i-link",{href:(0,l.prepareUrl)(e.hostingSettingsUrl)},(0,l.createElement)("i.icon",(0,l.createElement)('img[alt=""]',{src:w()}))," ",(0,l.createElement)("span",this.lmsg("hostingSettings")),(0,l.createElement)("span.tooltipData",this.lmsg("hostingSettingsHint"))),"none"!==e.hostingType?(0,l.createElement)("a.i-link[target=_blank]",{href:(0,l.escapeHtml)(e.siteUrl),"data-type":"buttonOpenDomain"},(0,l.createElement)("i.icon",(0,l.createElement)('img[alt=""]',{src:D()}))," ",(0,l.createElement)("span",this.lmsg("openSite")),(0,l.createElement)("span.tooltipData",this.lmsg("openSiteHint"))):"",e.previewUrl?(0,l.createElement)("a.i-link[target=_blank]",{href:e.previewUrl,"data-type":"buttonPreviewDomain"},(0,l.createElement)("i.icon",(0,l.createElement)('img[alt=""]',{src:S()}))," ",(0,l.createElement)("span",this.lmsg("previewSite")),(0,l.createElement)("span.tooltipData",this.lmsg("previewSiteHint"))):"",e.isSuspended&&e.error503PageUrl?(0,l.createElement)("a",{href:(0,l.prepareUrl)(e.error503PageUrl),"data-type":"buttonOpenErrorPage"},(0,l.createElement)("span",this.lmsg("error503PageLink"))):"",e.selfDescriptionType?[(0,l.createElement)("span.separator",(0,l.createElement)("span")),e.customDescription[e.selfDescriptionType]?"":(0,l.createElement)("a",{onclick:this._getConfigParam("onEditDescription").bind(this,e,e.selfDescriptionType)},this.lmsg("buttonDescription"))]:"",e.isMovable?(0,l.createElement)("a.i-link"+(e.movingError?".disabled":""),!e.movingError&&{onclick:()=>(0,u.default)(e),"data-type":"buttonMoveDomain"},(0,l.createElement)("span",this.lmsg("buttonMove")),(0,l.createElement)("span.tooltipData",e.movingError?e.movingError:this.lmsg(e.mainDomain?"buttonMoveMainHint":"buttonMoveHint"))):""))),t}itemCaptionHeadWrapView(e){const t=super.itemCaptionHeadWrapView(e);return t.children.push((0,l.createElement)("span.caption-head-status",(0,a.createElement)(o.LocaleProvider,{messages:this.getLocale().messages},(0,a.createElement)(c.default,{changeStatusLinks:e.changeStatusLinks,isActive:e.isActive,isSuspended:e.isSuspended})))),t}itemServiceQuickStartBlockView(e){return(0,l.createElement)(".quick-start-block",(0,l.createElement)(".quick-start-name",e.name),(0,l.createElement)(".quick-start-description",e.description),(0,l.createElement)(".quick-start-actions",e.actions.map((e=>(0,l.createElement)("a.btn",{href:e.href,target:e.newWindow?"_blank":null,onclick:this.navigate},(0,l.createElement)("i.icon",(0,l.createElement)("img[alt='']",{src:e.icon})),` ${e.title}`)))))}itemServiceDatabaseBlockView(e){return(0,l.createElement)(".caption-service-block",(0,l.createElement)("input.js-domain-id[type=hidden]",{value:e.domainId}),(0,l.createElement)("span.caption-service-title",(0,l.createElement)("i.caption-service-icon",(0,l.createElement)("a",{href:e.href},(0,l.createElement)("img",{src:e.icon,alt:e.title}))),(0,l.createElement)("span.caption-service-name",(0,l.createElement)("a",{href:e.href},(0,l.escapeHtml)(e.title)))),(0,l.createElement)(".caption-service-toolbar",e.create?(0,l.createElement)(".caption-service-item.item-visible",(0,l.createElement)("a.btn",{href:e.create.button.href},(0,l.escapeHtml)(e.create.button.title)),e.create.toggler?(0,l.createElement)("span.caption-service-text",`${(0,l.escapeHtml)(e.create.togglerText)} `,(0,l.createElement)("a.toggler",(0,l.escapeHtml)(e.create.toggler))):""):"",e.edit?(0,l.createElement)(`.caption-service-item.${e.edit.class}`,(0,l.createElement)("select",e.edit.databases.map((function(e){return(0,l.createElement)("option",e.attributes,e.title)}))),(0,l.createElement)("button.btn.js-webadmin[type=button]",e.edit.button.title)):""))}getItemOverviewUrl(e){const t=e.aliasId?e.aliasId:e.domainId,n=e.aliasId?"alias":"domain";return(0,l.prepareUrl)(`/smb/web/overview/id/${t}/type/${n}`)}getItemIdFromUrl(e){const t=e.match("/id/([0-9]+)/type/(domain|alias)");return t&&`${t[2]}:${t[1]}`}}const k=({history:e,...t})=>(0,a.createElement)(m.default,null,(()=>new P({...t,onNavigate:(0,d.createNavigateHandler)(e)})));k.propTypes={history:s().object.isRequired},t.default=(0,r.withRouter)(k)},930:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(148),r=n.n(s),l=n(154),o=n(261),c=n.n(o),m=n(155),d=n(144),u=n(931),p=n(938),E=n(958),b=n(960),_=n(969);class g extends l.Component{constructor(...e){super(...e),r()(this,"state",{showPromotion:this.props.showDynamicListPromotion,tourStep:this.props.dynamicListTourStep}),r()(this,"handleEditDescription",((e,t)=>{const n=new d.Locale(this.props.locale),a=d.Locale.getSection("components.forms.admin-info"),i=d.Locale.getSection("components.buttons"),[,s]=e.id.split(":");new d.CustomDescription.PopupForm({id:"editDescription",cls:"popup-panel",hint:a.lmsg(`popupHint${t.capitalize()}`),value:e.customDescription[t],locale:{popupTitle:n.lmsg("popupDescriptionTitle",{descriptionType:a.lmsg(`description${t.capitalize()}`),name:(0,d.escapeHtml)(e.displayName)}),buttonOk:i.lmsg("save"),buttonCancel:i.lmsg("cancel")},handler:e=>{(0,d.redirectPost)(this.props.urls["edit-description"],{id:s,description:e,type:t})}})})),r()(this,"handleRemoveDescription",((e,t)=>{const n=new d.Locale(this.props.locale),a=d.Locale.getSection("components.buttons"),[,i]=e.id.split(":");d.messageBox.show({type:d.messageBox.TYPE_YESNO,buttonTitles:{yes:a.lmsg("yes"),no:a.lmsg("no"),wait:a.lmsg("wait")},text:n.lmsg("confirmOnDeleteDescription"),onYesClick:()=>{(0,d.redirectPost)(this.props.urls["edit-description"],{id:i,description:"",type:t})}})})),r()(this,"handleIcpPermit",(({id:e,displayName:t,icpPermit:n})=>{const a=d.Locale.getSection("components.buttons"),i=d.Locale.getSection("components.icp-permit"),s=new d.PopupForm({cls:"popup-panel"});s.setBoxType("form-box"),s.setTitle(i.lmsg(n?"changeFormTitle":"enterFormTitle",{domainName:(0,d.escapeHtml)(t)})),(0,d.render)(document.getElementById(s._contentAreaId),(0,d.createElement)(".form-row",(0,d.createElement)(".field-name",(0,d.createElement)(`label[for=icp-permit-${e}]`,i.lmsg("icpPermit"))),(0,d.createElement)(".field-value",(0,d.createElement)(`input#icp-permit-${e}.input-text.f-middle-size[type=text]`,{value:n}))));const r=s.addRightButton(a.lmsg("save"),(function(){this._updateButton(r,{disabled:!0}),(0,d.redirectPost)((0,d.prepareUrl)("/smb/web/icp-permit"),{id:e,permit:document.getElementById(`icp-permit-${e}`).value})}),!0,!0);s.addRightButton(a.lmsg("cancel"),(function(){this.hide()}),!1,!1)})),r()(this,"handleIcpStatus",(({id:e,icpStatus:t})=>{(0,d.redirectPost)("/smb/web/icp-permit",{id:e,status:t?"false":"true"})})),r()(this,"handleClosePromotion",(()=>{this.setState({showPromotion:!1}),d.api.post("/smb/web/dynamic-list-promotion-hide")})),r()(this,"handleTourStepChange",(e=>{d.api.post("/smb/web/dynamic-list-tour",{step:e}),this.setState({tourStep:e})})),r()(this,"handleTourStart",(()=>{this.handleTourStepChange("intro")}))}render(){const{toolbar:e}=this.props;if(!e)return(0,l.createElement)(_.default,i()({},this.props.data[0],{locale:this.props.locale,icpPermitLearnMore:this.props.urls.icpPermitLearnMore,onEditDescription:this.handleEditDescription,onIcpPermit:this.handleIcpPermit,onIcpStatus:this.handleIcpStatus}));if(!e.hasDynamicView||"dynamic"!==e.listType)return(0,l.createElement)(u.default,i()({},this.props,{onEditDescription:this.handleEditDescription,onRemoveDescription:this.handleRemoveDescription,onIcpPermit:this.handleIcpPermit,onIcpStatus:this.handleIcpStatus}));const{locale:t,...n}=this.props,{showPromotion:a,tourStep:s}=this.state;return(0,l.createElement)(m.LocaleProvider,{messages:t},a?(0,l.createElement)(E.default,{onTourStart:this.handleTourStart,onClose:this.handleClosePromotion}):null,(0,l.createElement)(b.default,{step:s,onStepChange:this.handleTourStepChange}),(0,l.createElement)(p.default,i()({onEditDescription:this.handleEditDescription,onIcpPermit:this.handleIcpPermit,onIcpStatus:this.handleIcpStatus,"data-type":"dynamicList"},n)))}}g.propTypes={data:c().array.isRequired,urls:c().shape({"edit-description":c().string,icpPermitLearnMore:c().string}).isRequired,locale:c().object.isRequired,toolbar:c().object,showDynamicListPromotion:c().bool.isRequired,dynamicListTourStep:c().string.isRequired},g.defaultProps={toolbar:null},t.default=g},922:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(556),l=n(144),o=n(576),c=n(582),m=n(781),d=n(787),u=n.n(d),p=n(923),E=n.n(p),b=n(788),_=n.n(b),g=n(789),h=n.n(g),f=n(924),y=n.n(f),w=n(925),v=n.n(w),D=n(926),T=n.n(D),S=n(927),P=n.n(S),k=n(749),C=n.n(k),A=n(928),M=n.n(A),L=n(929),U=n.n(L),I=n(911),R=n.n(I),O=n(786),B=n.n(O),x=n(784),N=n.n(x),q=n(785),W=n.n(q);const H=({locale:e,data:t,allowCreateDomain:n,allowManageSubdomain:i,allowManageDomainAliases:s,isIcpSupported:d,icpPermitLearnMore:p,showAddHostingButton:b,hasWebspace:g,allowCreateWebspace:f,showDeleteButton:w,resourceUsage:D,isHomonymSearchEnabled:S,hasDynamicView:k,hasActiveView:A})=>{const L=(0,r.useHistory)(),I=(0,c.createNavigateHandler)(L);return e=new l.Locale(e),(0,a.createElement)(o.default,null,(()=>new l.Panel({cls:"list-box",items:[new l.List({id:"sites-list",disabledSelectHint:e.lmsg("disabledSelectHint"),data:t,dataUrl:"/web/list-data",isDisabledItem:e=>!e.isRemovable,columns:[n||i||s?l.list.COLUMN_SELECTION:null,{header:e.lmsg("domainHeader"),sortable:!0,dataIndex:"displayName",renderer(t){const n=t.aliasId?t.aliasId:t.domainId,a=t.aliasId?"alias":"domain";return(0,l.createElement)(t.isSubdomain||t.isDomainAlias?".level1":".",[(0,l.createElement)(t.mainDomain?"strong.primary-domain":".",(0,l.createElement)("a",{href:(0,l.prepareUrl)(`/smb/web/overview/id/${n}/type/${a}`),onclick:I},(0,l.escapeHtml)(t.displayName))),t.isSuspended?(0,l.createElement)(".hint-sub.hint-attention",[e.lmsg("suspended"),t.error503PageUrl?"&nbsp;":"",t.error503PageUrl?(0,l.createElement)("a",{href:(0,l.prepareUrl)(t.error503PageUrl)},e.lmsg("error503PageLink")):""]):"",t.isDisabled?(0,l.createElement)(".hint-sub.hint-attention",e.lmsg("disabled")):"",...t.customDescription?(0,m.default)({adminDescription:t.customDescription.admin,resellerDescription:t.customDescription.reseller,ownerDescription:t.customDescription.owner,hideResellerTitleDescription:!t.customDescription.admin,hideOwnerTitleDescription:!t.customDescription.admin&&!t.customDescription.reseller},e,"minor"):[]])}},d?{header:l.Locale.getSection("components.icp-permit").lmsg("icpPermit"),sortable:!0,dataIndex:"icpStatus",renderer(e){const t=l.Locale.getSection("components.icp-permit"),n=1==e.icpStatus?t.lmsg("icpStatusAllowedDescription"):t.lmsg("icpStatusNotAllowedDescription"),a=1==e.icpStatus?N():W(),i=e.icpPermit?(0,l.escapeHtml)(e.icpPermit):1==e.icpStatus?"":t.lmsg("icpStatusNotAllowed");return`<span class="tooltipData">${n}</span><img src="${a}" alt=""/>${p?`<a href="${p}" target="_blank">`:""}${i}${p?"</a>":""}`}}:null,{header:e.lmsg("hostingHeader"),sortable:!1,renderer({hostingType:t,webrootDir:n,filemanagerUrl:a,purchaseDomainMessage:i,changeHostingUrl:s,forwardingUrl:r,forwardingDisplayUrl:o,isDomainAlias:c,description:m}){if("vrt_hst"===t){a&&(n=(0,l.createElement)("a",{href:a,onclick:I},n));const t=[(0,l.createElement)("img",{src:u()})," ",e.lmsg("websiteAt")," ",n];return i&&t.push((0,l.createElement)("br"),(0,l.createElement)("img",{src:E()})," ",i),t}if("none"===t){const t=[(0,l.createElement)("img",{src:_()}),(0,l.createElement)("em.hint",e.lmsg("noHosting"))];return b&&t.push(" ",(0,l.createElement)("a",{href:(0,l.prepareUrl)(s)},"[",e.lmsg("add"),"]")),t}return"frm_fwd"===t||"std_fwd"===t?[(0,l.createElement)("img",{src:h()})," ",e.lmsg("forwardingTo")," ",(0,l.createElement)("a",{href:r,target:"_blank"},(0,l.escapeHtml)(o))]:c?[(0,l.createElement)("img",{src:y()})," ",m]:null}},{header:e.lmsg("diskUsage"),sortable:!1,dataIndex:"realSize",renderer:e=>(0,l.escapeHtml)(e.diskUsage)},{header:e.lmsg("traffic"),sortable:!1,dataIndex:"traffic"},{header:"",cls:"action-icon-set t-r",renderer:({previewUrl:t,filemanagerUrl:n,sitebuilderUrl:a,sitebuilderLegacyUrl:i,statisticsUrl:s,sslStatisticsUrl:r,certificatesUrl:o,logsUrl:c,dnsUrl:m})=>[t?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("previewHint")),(0,l.createElement)("a",{href:t,target:"_blank"},(0,l.createElement)("img",{src:v()}))]):(0,l.createElement)("img",{src:_()})," ",n?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("manageFilesHint")),(0,l.createElement)("a",{href:n,onclick:I},(0,l.createElement)("img",{src:T()}))]):(0,l.createElement)("img",{src:_()})," ",a?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("sitebuilderHint")),(0,l.createElement)("a",{href:(0,l.prepareUrl)(a),target:"_blank"},(0,l.createElement)("img",{src:P()}))]):(0,l.createElement)("img",{src:_()})," ",i?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("sitebuilderOldHint")),(0,l.createElement)("a",{href:i,target:"_blank"},(0,l.createElement)("img",{src:P()}))]):null,i?" ":null,s?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("webstatisticsHint")),(0,l.createElement)("a",{href:"#",onclick:s},(0,l.createElement)("img",{src:C()}))]):(0,l.createElement)("img",{src:_()})," ",r?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("webstatisticsSslHint")),(0,l.createElement)("a",{href:"#",onclick:r},(0,l.createElement)("img",{src:M()}))]):(0,l.createElement)("img",{src:_()})," ",o?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("certificatesHint")),(0,l.createElement)("a",{href:(0,l.prepareUrl)(o)},(0,l.createElement)("img",{src:U()}))]):(0,l.createElement)("img",{src:_()})," ",c?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("logsHint")),(0,l.createElement)("a",{href:(0,l.prepareUrl)(c)},(0,l.createElement)("img",{src:R()}))]):(0,l.createElement)("img",{src:_()})," ",m?(0,l.createElement)("span",[(0,l.createElement)("span.tooltipData",e.lmsg("dnsHint")),(0,l.createElement)("a",{href:(0,l.prepareUrl)(m),onclick:I},(0,l.createElement)("img",{src:B()}))]):(0,l.createElement)("img",{src:_()})]}].filter((e=>e)),operations:[g&&n||f?{componentType:l.SmallButton,id:"buttonAddDomain",cls:"s-btn sb-new-domain",title:e.lmsg("buttonAddDomain"),description:`${e.lmsg("buttonAddDomainHint")} ${D.maxSite}`,href:"/smb/web/add-domain",handler:I}:null,g&&i?{componentType:l.SmallButton,id:"buttonAddSubDomain",cls:"s-btn sb-new-subdomain",title:e.lmsg("buttonAddSubdomain"),description:`${e.lmsg("buttonAddSubdomainHint")} ${D.maxSubdom}`,href:"/smb/web/add-subdomain"}:null,s?{componentType:l.SmallButton,id:"buttonAddDomainAlias",cls:"s-btn sb-new-domain-alias",title:e.lmsg("buttonAddDomainAlias"),description:`${e.lmsg("buttonAddDomainAliasHint")} ${D.maxDomAliases}`,href:"/smb/web/add-domain-alias"}:null,g&&(n||i||s)?{componentType:l.bar.Separator}:null,g&&w?{componentType:l.SmallButton,id:"buttonRemoveSite",title:e.lmsg("buttonRemove"),description:e.lmsg("buttonRemoveHint"),cls:"s-btn sb-remove-selected",handler(t){var n;const a=(0,l.getComponent)("sites-list"),i=a.getSelectedItems();a.execGroupOperation({url:"/web/delete/",subtype:l.messageBox.SUBTYPE_DELETE,mouseEvent:t,text:e.formatMessage("removeConfirmation",{name:`<b>${(0,l.escapeHtml)(null===(n=i[0])||void 0===n?void 0:n.displayName)}</b>`,count:i.length}),isAjax:S,requestUrl:"/web/search-homonym-data/",loadingTitle:l.Locale.getSection("components.homonyms").lmsg("loading")})}}:null,k||A?{componentType:l.list.AdditionalActions,cls:"actions-menu list-type-switcher",titleAddCls:"sb-manage",operations:[{componentType:l.DropdownHeader,title:e.lmsg("modeTitle")},k?{componentType:l.SmallButton,id:"buttonDynamicList",title:e.lmsg("buttonDynamicList"),description:e.lmsg("buttonDynamicListHint"),cls:"sb-btn",addCls:"sb-dynamic-list",handler(){(0,l.redirect)("?list-type=dynamic")}}:null,A?{componentType:l.SmallButton,id:"buttonActiveList",title:e.lmsg("buttonActiveList"),description:e.lmsg("buttonActiveListHint"),cls:"sb-btn",addCls:"sb-active-list",handler(){(0,l.redirect)("?list-type=active")}}:null,{componentType:l.SmallButton,id:"buttonClassicList",title:e.lmsg("buttonClassicList"),description:e.lmsg("buttonClassicListHint"),cls:"sb-btn",addCls:"sb-classic-list",wrapperClass:"selected"}].filter(Boolean)}:null],onRedraw(){document.getElementById("sites-list").querySelectorAll('input[name="listCheckbox[]"]').forEach((function(e){e.addEventListener("click",(function(){if(e.closest("tr").querySelector("div.level1")){let t=e.closest("tr");for(;t=t.previousElementSibling;)if(!t.querySelector("div.level1")){if(!e.checked){const e=t.querySelector('input[name="listCheckbox[]"]');e&&(e.checked=!1,t.classList.remove("selected"))}break}}else{let t=e.closest("tr");for(;(t=t.nextElementSibling)&&t.querySelector("div.level1");)t.querySelector('input[name="listCheckbox[]"]').checked=e.checked,e.checked?t.classList.add("selected"):t.classList.remove("selected")}}))}))}})]})))};H.propTypes={locale:s().object.isRequired,data:s().object.isRequired,allowCreateDomain:s().bool.isRequired,allowManageSubdomain:s().bool.isRequired,allowManageDomainAliases:s().bool.isRequired,isIcpSupported:s().bool.isRequired,icpPermitLearnMore:s().string.isRequired,showAddHostingButton:s().bool.isRequired,hasWebspace:s().bool.isRequired,allowCreateWebspace:s().bool.isRequired,showDeleteButton:s().bool.isRequired,resourceUsage:s().object.isRequired,isHomonymSearchEnabled:s().bool.isRequired,hasDynamicView:s().bool.isRequired,hasActiveView:s().bool.isRequired},t.default=H},938:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(148),r=n.n(s),l=n(154),o=n(261),c=n.n(o),m=n(155),d=n(144),u=n(582),p=n(939),E=n(947),b=n(932),_=n(948),g=n(949),h=n(956);const f=e=>{const t={},n=e.reduce(((e,n)=>{if(n.parentDomain){const{parentDomain:a}=n;if(void 0===t[a.id]){const n={...a,data:[],virtual:!0,title:a.displayName};t[a.id]=n,e.push(n)}}else{const a={...n,data:[]};t[a.domainId]=a,e.push(a)}return e}),[]);return e.forEach((e=>{if(e.parentDomain){const n=e.parentDomain.id;t[n]&&t[n].data.push(e)}})),n},y=({id:e,data:t,pager:n})=>{const a=d.ActiveList.stateCollapsed(e,!0);return{data:f(t),pager:n,expandedRows:t.filter((e=>!a.get(e))).map((({id:e})=>e))}};class w extends l.Component{constructor(...e){super(...e),r()(this,"state",y(this.props)),r()(this,"handleExpandedRowsChange",(e=>{const t=d.ActiveList.stateCollapsed(this.props.id,!0);this.state.expandedRows.filter((t=>-1===e.indexOf(t))).forEach((e=>{t.set({id:e},!0)})),e.filter((e=>-1===this.state.expandedRows.indexOf(e))).forEach((e=>{t.set({id:e},!1)})),this.setState({expandedRows:e}),d.UAT.dispatchAction("EXPAND_ROWS",{expanded:e.join(";")})})),r()(this,"handlePageChange",(e=>{e!==this.state.pager.current&&this.reload({page:e})})),r()(this,"handleItemsPerPageChange",(e=>{e!==this.state.pager.itemCountPerPage&&this.reload({"items-per-page":"all"===e?1e5:e})})),r()(this,"reload",(e=>{const{id:t}=this.props;d.api.get((0,d.addUrlParams)("/smb/web/list-data",e)).then((({data:e,pager:n})=>{this.setState(y({id:t,data:e,pager:n}))}))})),r()(this,"renderItemTitle",(({title:e,virtual:t,domainId:n,aliasId:a})=>{const i=(0,l.createElement)(m.Text,{bold:!t,intent:t?"muted":void 0,className:"smb-web-view-dynamic-list-item-name"},e,(0,l.createElement)(m.Tooltip,{title:(0,l.createElement)(m.Translate,{content:"goToOverview"})},(0,l.createElement)(m.Action,{outerProps:{className:"smb-web-view-dynamic-list-item-action"},icon:{name:"chain",size:12},className:"smb-web-view-dynamic-list-item-link",component:u.default,to:`/smb/web/overview/id/${a||n}/type/${a?"alias":"domain"}`})));return t?{colSpan:4,children:i}:i})),r()(this,"renderItemStatus",(({changeStatusLinks:e,isActive:t,isSuspended:n})=>(0,l.createElement)(b.default,{changeStatusLinks:e,isActive:t,isSuspended:n}))),r()(this,"renderItemHostingType",(({aliasId:e,hostingType:t,forwardingDisplayUrl:n})=>{if(e)return(0,l.createElement)(m.Translate,{content:"domainAlias"});switch(t){case"vrt_hst":return(0,l.createElement)(m.Translate,{content:"website"});case"std_fwd":case"frm_fwd":return(0,l.createElement)(l.Fragment,null,(0,l.createElement)(m.Translate,{content:"forwardingTo"})," ",(a=n,(0,l.createElement)("span",{className:"smb-web-view-dynamic-list-item-name"},a)));case"none":return(0,l.createElement)(m.Translate,{content:"noHosting"});default:return null}var a})),r()(this,"renderItemActions",(e=>(0,l.createElement)(l.Fragment,null,(0,l.createElement)(E.default,e),this.renderRenameTour(e)))),r()(this,"renderRenameTour",(({domainId:e,allowRename:t,isDomainAlias:n})=>!n&&e===+this.props.showRenameTour&&t?(0,l.createElement)(_.default,{domainId:e,onClose:()=>d.api.post("/smb/web/dynamic-list-rename-promotion-hide")}):null)),r()(this,"renderItemBody",(e=>e.virtual?null:(0,l.createElement)(p.default,i()({icpPermitLearnMore:this.props.urls.icpPermitLearnMore,onEditDescription:this.props.onEditDescription,onIcpPermit:this.props.onIcpPermit,onIcpStatus:this.props.onIcpStatus},e))))}renderViewModes(){const{toolbar:{hasActiveView:e,hasClassicView:t}}=this.props,n=[(0,l.createElement)(m.MenuItem,{key:"dynamic",active:!0},(0,l.createElement)(m.Translate,{content:"typeDynamic"}))];return e&&n.push((0,l.createElement)(m.MenuItem,{key:"active",component:"a",href:"?list-type=active"},(0,l.createElement)(m.Translate,{content:"typeActive"}))),t&&n.push((0,l.createElement)(m.MenuItem,{key:"classic",component:"a",href:"?list-type=classic"},(0,l.createElement)(m.Translate,{content:"typeClassic"}))),n.length<2?null:(0,l.createElement)(m.ToolbarGroup,{title:""},(0,l.createElement)(m.Dropdown,{menu:(0,l.createElement)(m.Menu,null,(0,l.createElement)(m.MenuHeader,null,(0,l.createElement)(m.Translate,{content:"modeTitle"})),n),menuPlacement:"bottom-end"},(0,l.createElement)(m.Button,{"data-type":"listSettings"},(0,l.createElement)(m.Translate,{content:"buttonChangeView"}))))}render(){const{toolbar:e,urls:t}=this.props,{data:n,pager:a,expandedRows:i}=this.state,s=[{key:"title",title:(0,l.createElement)(m.Translate,{content:"titleHeader"}),render:this.renderItemTitle,sortable:!0,sort:()=>0,type:"title"},{key:"status",title:(0,l.createElement)(m.Translate,{content:"statusHeader"}),render:this.renderItemStatus,type:"controls"},{key:"hostingType",title:(0,l.createElement)(m.Translate,{content:"hostingHeader"}),render:this.renderItemHostingType},{key:"actions",width:"1%",render:this.renderItemActions,type:"actions"}];return(0,l.createElement)(l.Fragment,null,(0,l.createElement)(m.List,{toolbar:e?(0,l.createElement)(m.Toolbar,null,(0,l.createElement)(m.ToolbarGroup,{title:""},Object.keys(e.buttons).map((t=>{const{title:n,description:a,url:i}=e.buttons[t];return(0,l.createElement)(m.Button,{key:t,id:t,component:u.default,to:i,tooltip:a},n)}))),(0,l.createElement)(m.ToolbarExpander,null),this.renderViewModes()):null,columns:s,data:n,rowKey:"id",renderRowBody:this.renderItemBody,sortColumn:"title",sortDirection:"down"===e.sortDir?"DESC":"ASC",onSortChange:({sortDirection:e})=>{(0,d.redirect)(t["DESC"===e?"sort-down":"sort-up"])},expandedRows:i,onExpandedRowsChange:this.handleExpandedRowsChange,pagination:(0,l.createElement)(m.Pagination,{current:a.current,total:a.pageCount,onSelect:this.handlePageChange,itemsPerPage:1e5===a.itemCountPerPage?"all":a.itemCountPerPage,itemsPerPageOptions:[10,25,100,"all"],onItemsPerPageChange:this.handleItemsPerPageChange}),totalRows:a.totalItemCount,rowProps:e=>({virtual:e.virtual})}),(0,l.createElement)(g.default,null),(0,l.createElement)(h.default,null))}}w.propTypes={id:c().string.isRequired,urls:c().shape({icpPermitLearnMore:c().string}).isRequired,toolbar:c().object.isRequired,showRenameTour:c().string,onEditDescription:c().func.isRequired,onIcpPermit:c().func.isRequired,onIcpStatus:c().func.isRequired},w.defaultProps={showRenameTour:null},t.default=w},958:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(155),l=n(261),o=n.n(l);const c=({onTourStart:e,onClose:t,...a})=>(0,s.createElement)(r.Alert,i()({intent:"success",onClose:t},a),(0,s.createElement)(r.Media,{title:(0,s.createElement)(r.Translate,{component:r.Heading,level:5,content:"DynamicListPromotion.title"}),image:(0,s.createElement)(r.Icon,{src:n(959),size:"32"})},(0,s.createElement)(r.Translate,{content:"DynamicListPromotion.message",params:{link:(0,s.createElement)(r.Link,{onClick:e},(0,s.createElement)(r.Translate,{component:r.Text,bold:!0,content:"DynamicListPromotion.messageLink"}))}})));c.propTypes={onTourStart:o().func.isRequired,onClose:o().func.isRequired},t.default=c},939:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{"use strict";__webpack_require__.r(__webpack_exports__);var react__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(154),prop_types__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(261),prop_types__WEBPACK_IMPORTED_MODULE_1___default=__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_1__),_apollo_client__WEBPACK_IMPORTED_MODULE_10__=__webpack_require__(302),_apollo_client__WEBPACK_IMPORTED_MODULE_11__=__webpack_require__(405),_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(155),_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2___default=__webpack_require__.n(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__),plesk_components_ApolloErrorMessage__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__(940),plesk_components_Link__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__(582),jsw__WEBPACK_IMPORTED_MODULE_5__=__webpack_require__(144),_ActionList__WEBPACK_IMPORTED_MODULE_6__=__webpack_require__(941),_ItemSummary__WEBPACK_IMPORTED_MODULE_7__=__webpack_require__(942),_Screenshot__WEBPACK_IMPORTED_MODULE_8__=__webpack_require__(943),_components_JswComponent__WEBPACK_IMPORTED_MODULE_9__=__webpack_require__(576);const buttonsIconMap={buttonConnectionInfo:"connection",buttonFileManager:"folder-closed",buttonMail:"mail",buttonEmailAddresses:"mail",buttonMailLists:"book-email",buttonMailSettings:"mail-settings",buttonDatabases:"database",buttonWebScripting:"sliders",buttonLogs:"list",buttonVirtualFolder:"folders-tree",buttonFtpAccess:"folder-network",buttonBackup:"backup",buttonWebServerSettings:"web-settings",buttonSheduledTasks:"calendar-clock",buttonDnsSettings:"globe",buttonWhoisInfo:"globe",buttonHostingSettings:"key",buttonIssAppPool:"panels",buttonPhpSettings:"php",buttonAspNetSettings:"microsoft",buttonWebDeploy:"deploy",buttonApplications:"gear",buttonSsh:"panel-key",buttonRdesktop:"panel-key",buttonSslCertificates:"sertificate",buttonProtectedDirectories:"folder-key",buttonWebAppFirewall:"fire",buttonOutgoingSpamSettings:"limit",buttonHotlinkProtection:"shield-chain",buttonBandwidthLimiting:"boundary",buttonOdbcDataSources:"database-box",buttonFailedRequests:"net",buttonWebStatistics:"bar-chart-vertical",buttonWebStatisticsSsl:"bar-chart-vertical"},buttonsIconUrlMap={buttonWebUsers:__webpack_require__(944),buttonSitebuilder:__webpack_require__(945),buttonSiteCopy:__webpack_require__(946)},insertToPosition=(e,t,n)=>{e.splice(null!=n?n:e.length,0,t)},getSectionButtons=(e,t)=>e.filter((e=>e.section===t)),renderButton=({id:e,icon:t,title:n,label:a,description:i,href:s,target:r,onClick:l,additionalComments:o,noEscape:c,noEscapeTitle:m})=>{const d=Array.isArray(o)?o.map((e=>c?e:(0,jsw__WEBPACK_IMPORTED_MODULE_5__.escapeHtml)(e))).join("<br>"):null;return m&&(n=(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)("span",{dangerouslySetInnerHTML:{__html:n}})),a&&(n=(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(react__WEBPACK_IMPORTED_MODULE_0__.Fragment,null,n," ",(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Label,{intent:"success"},a))),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Item,{component:plesk_components_Link__WEBPACK_IMPORTED_MODULE_4__.default,to:s,target:r,rel:r&&"noopener noreferrer",key:e,id:e,icon:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Icon,{name:buttonsIconMap[e],src:buttonsIconUrlMap[e]||!buttonsIconMap[e]&&t,size:"16",intent:"inactive"}),title:n,description:i,onClick:l},d?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Text,{component:"div",intent:"muted",dangerouslySetInnerHTML:{__html:d}}):null)},renderItemPreview=e=>{const{buttons:t,previewUrl:n,siteUrl:a,screenshotUrl:i,hostingType:s,diskUsage:r,traffic:l}=e,o=t.filter((({id:e})=>-1!==["buttonWebStatistics","buttonWebStatisticsSsl"].indexOf(e)));return(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(react__WEBPACK_IMPORTED_MODULE_0__.Fragment,null,i?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_Screenshot__WEBPACK_IMPORTED_MODULE_8__.default,{url:i}):null,"none"!==s||n?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_ActionList__WEBPACK_IMPORTED_MODULE_6__.default,null,"none"!==s?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tooltip,{title:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"openSiteHint"})},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Action,{icon:"web",href:a,target:"_blank","data-type":"buttonOpenDomain"},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"openSite"}))):null,n?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tooltip,{title:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"previewSiteHint"})},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Action,{icon:"panel-eye",href:n,target:"_blank","data-type":"buttonPreviewDomain"},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"previewSite"}))):null):null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Paragraph,null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Text,{intent:"muted"},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"diskUsage"}))," ",r),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Paragraph,null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Text,{intent:"muted"},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"traffic"}))," ",l),o.length?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_ActionList__WEBPACK_IMPORTED_MODULE_6__.default,null,o.map((({id:e,icon:t,href:n,onClick:a,title:i,comment:s})=>(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tooltip,{key:e,title:s},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Action,{id:e,"data-type":e,icon:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Icon,{name:buttonsIconMap[e],src:!buttonsIconMap[e]&&t,size:"16"}),onClick:a,href:n},i))))):null)},renderDashboard=e=>{const t=[{filesAndDatabases:["buttonConnectionInfo","buttonFileManager","buttonDatabases","buttonOdbcDataSources","buttonFtpAccess","buttonBackup","buttonSsh","buttonRdesktop","buttonVirtualFolder","buttonWebDeploy","buttonSiteCopy"],security:["buttonSslCertificates","buttonProtectedDirectories","buttonWebAppFirewall","buttonHotlinkProtection"]},{devTools:["buttonPhpSettings","buttonAspNetSettings","buttonLogs","buttonSheduledTasks","buttonFailedRequests","buttonApplications","buttonSitebuilder"]}];return t.forEach((t=>{Object.keys(t).forEach((n=>{t[n]=t[n].map((t=>e.filter((e=>e.id===t))[0])).filter(Boolean),getSectionButtons(e,n).forEach((({order:e,...a})=>insertToPosition(t[n],a,e)))}))})),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Grid,{gap:"md",lg:t.length,xs:1,className:"smb-web-view-dynamic-list-actions","data-type":"dynamic-list-row-body"},t.map(((e,t)=>Object.keys(e).some((t=>e[t].length))?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.GridCol,{key:t},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Grid,{gap:"md"},Object.keys(e).map((t=>e[t].length?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.GridCol,{key:t},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Heading,{level:4},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:`${t}ButtonsGroup`})),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.ItemList,{className:"smb-web-view-dynamic-list-item-list"},e[t].map(renderButton))):null)))):null)))},renderButtonsTab=(e,t)=>(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tab,{title:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:t}),"data-type":t,key:t},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.ItemList,{className:"smb-web-view-dynamic-list-item-list",minColumnWidth:220},e.map(renderButton))),renderCustomTab=({id:e,title:t,content:n})=>(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tab,{title:t,"data-type":e,key:e},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_JswComponent__WEBPACK_IMPORTED_MODULE_9__.default,null,n)),renderTabs=(e,t,n,a,i,s)=>{if(!(t.length||n.length||a.length||i.length))return e;const r=[(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tab,{title:(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Translate,{content:"dashboardTab"}),"data-type":"dashboardTab",key:"dashboardTab"},e)];return a.length&&r.push(renderButtonsTab(a,"hostingTab")),t.length&&r.push(renderButtonsTab(t,"mailTab")),n.length&&r.push(renderButtonsTab(n,"extensionsTab")),s.length&&r.push(renderButtonsTab(s,"customButtonsTab")),i.length&&i.forEach((({order:e,...t})=>{insertToPosition(r,renderCustomTab(t),e)})),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Tabs,{"data-type":"domainTabs"},r)},GET_SITE=_apollo_client__WEBPACK_IMPORTED_MODULE_10__.gql`
    query getSite($id: ID!) {
        site(id: $id) {
            screenshotUrl
            customTabs {
                id
                siteId
                title
                content
                order
            }
            buttons {
                id
                siteId
                icon
                href
                handler
                target
                title
                label
                description
                comment
                additionalComments
                noEscape
                noEscapeTitle  
                section
                order
            }
        }
    }
`,DynamicListRowBody=({icpPermitLearnMore,onEditDescription,onIcpPermit,onIcpStatus,...item})=>{const{loading,data,error}=(0,_apollo_client__WEBPACK_IMPORTED_MODULE_11__.useQuery)(GET_SITE,{variables:{id:item.id}});if(error)return(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(plesk_components_ApolloErrorMessage__WEBPACK_IMPORTED_MODULE_3__.default,{error});if(loading)return(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.ContentLoader,null);const{screenshotUrl,customTabs}=data.site,{settings}=item,buttons=data.site.buttons.map((({handler,...props})=>({onClick:handler&&eval(`(${handler})`),...props})));let content=renderDashboard(buttons);const hostingButtons=["buttonWebScripting","buttonHostingSettings","buttonWebServerSettings","buttonDnsSettings","buttonWhoisInfo","buttonIssAppPool","buttonBandwidthLimiting","buttonWebUsers"].map((e=>buttons.filter((t=>t.id===e))[0])).filter(Boolean);getSectionButtons(buttons,"hosting").forEach((({order:e,...t})=>insertToPosition(hostingButtons,t,e)));const mailButtons=["buttonEmailAddresses","buttonMailSettings","buttonMailLists","buttonOutgoingSpamSettings"].map((e=>buttons.filter((t=>t.id===e))[0])).filter(Boolean);getSectionButtons(buttons,"mail").forEach((({order:e,...t})=>insertToPosition(mailButtons,t,e)));const extensionsButtons=buttons.filter((({id:e})=>0===e.indexOf("extensionButton_"))).filter((e=>!e.section)),customButtons=getSectionButtons(buttons,"customButtons");return content=renderTabs(content,mailButtons,extensionsButtons,hostingButtons,customTabs,customButtons),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(react__WEBPACK_IMPORTED_MODULE_0__.Fragment,null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Columns,{gap:"lg",vertical:540},(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Column,{width:306},renderItemPreview({...item,screenshotUrl,buttons})),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.Column,{fill:!0},content)),settings&&settings.length?(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(react__WEBPACK_IMPORTED_MODULE_0__.Fragment,null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)("hr",null),(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.SwitchesPanel,null,settings.map((({name:e,description:t,url:n,button:a,hint:i},s)=>(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_plesk_ui_library__WEBPACK_IMPORTED_MODULE_2__.SwitchesPanelItem,{key:s,intent:"sb-attention"===a?"warning":null,title:e,defaultChecked:"sb-off"!==a,fullDescription:t,switchProps:{tooltip:i},onChange:()=>{(0,jsw__WEBPACK_IMPORTED_MODULE_5__.redirectPost)(n)}}))))):null,(0,react__WEBPACK_IMPORTED_MODULE_0__.createElement)(_ItemSummary__WEBPACK_IMPORTED_MODULE_7__.default,{item,icpPermitLearnMore,onEditDescription,onIcpPermit,onIcpStatus}))};DynamicListRowBody.propTypes={icpPermitLearnMore:prop_types__WEBPACK_IMPORTED_MODULE_1___default().string.isRequired,onEditDescription:prop_types__WEBPACK_IMPORTED_MODULE_1___default().func.isRequired,onIcpPermit:prop_types__WEBPACK_IMPORTED_MODULE_1___default().func.isRequired,onIcpStatus:prop_types__WEBPACK_IMPORTED_MODULE_1___default().func.isRequired},__webpack_exports__.default=DynamicListRowBody},960:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(155),s=n(261),r=n.n(s),l=n(961),o=n.n(l),c=n(962),m=n.n(c),d=n(963),u=n.n(d),p=n(964),E=n.n(p),b=n(965),_=n.n(b),g=n(966),h=n.n(g),f=n(967),y=n.n(f),w=n(968),v=n.n(w);const D=(e,t)=>(0,a.createElement)("picture",null,(0,a.createElement)("source",{srcSet:e,type:"image/webp"}),(0,a.createElement)("img",{src:t,width:"308",height:"217",alt:""})),T=({onNext:e,onClose:t})=>(0,a.createElement)(i.Tour,{current:0,onClose:t},(0,a.createElement)(i.Spot,{selector:"tbody .pul-list__cell-expander > button",popup:{title:(0,a.createElement)(i.Translate,{content:"DynamicListTour.introTitle"}),image:D(o(),m()),children:(0,a.createElement)(i.Translate,{content:"DynamicListTour.introDescription"}),size:"sm",buttons:[(0,a.createElement)(i.Button,{key:"expand",onClick:e,intent:"primary"},(0,a.createElement)(i.Translate,{content:"DynamicListTour.introButtonTry"}))]}}));T.propTypes={onNext:r().func.isRequired,onClose:r().func.isRequired};const S=({step:e,onChange:t})=>{const[n,s]=(0,a.useState)([]),r=n.length>0,l='div[data-type="listActions"] div:last-child',o='button[data-type="listSettings"]';if((0,a.useState)((()=>{setTimeout((()=>{const e=["tabs",document.querySelector(l)?"secondary_actions":null,document.querySelector(o)?"previous_view":null].filter(Boolean);s(e)}))}),[]),!r)return null;const c=n.indexOf(e),m=(0,a.createElement)(i.Button,{key:"next",intent:"primary",arrow:"forward",onClick:()=>t(n[c+1])},(0,a.createElement)(i.Translate,{content:"DynamicListTour.buttonNext"})),d=(0,a.createElement)(i.Button,{key:"prev",ghost:!0,onClick:()=>t(n[c-1])},(0,a.createElement)(i.Translate,{content:"DynamicListTour.buttonPrev"})),p=(0,a.createElement)(i.Button,{key:"close",intent:"primary",onClick:()=>t("finish")},(0,a.createElement)(i.Translate,{content:"DynamicListTour.buttonGotIt"}));"secondary_actions"===e&&-1===n.indexOf(e)&&-1!==n.indexOf("previous_view")&&(e="previous_view");const b=n.indexOf(e),g=n.length-1;return(0,a.createElement)(i.Tour,{current:b,onClose:()=>t(c+1===n.length?"finish":"closed_".concat(e))},(0,a.createElement)(i.Spot,{selector:'div[data-type="domainTabs"] li:last-child',placement:"right",popup:{title:(0,a.createElement)(i.Translate,{content:"DynamicListTour.tabsTitle"}),image:D(y(),v()),children:(0,a.createElement)(i.Translate,{content:"DynamicListTour.tabsDescription"}),buttons:b===g?[p]:[m],size:"sm",placement:"right"}}),-1!==n.indexOf("secondary_actions")&&(0,a.createElement)(i.Spot,{selector:l,popup:{title:(0,a.createElement)(i.Translate,{content:"DynamicListTour.secondaryActionsTitle"}),image:D(u(),E()),children:(0,a.createElement)(i.Translate,{content:"DynamicListTour.secondaryActionsDescription"}),buttons:b===g?[d,p]:[d,m],size:"sm",placement:"left"}}),-1!==n.indexOf("previous_view")&&(0,a.createElement)(i.Spot,{selector:o,placement:"left",popup:{title:(0,a.createElement)(i.Translate,{content:"DynamicListTour.previousViewTitle"}),image:D(_(),h()),children:(0,a.createElement)(i.Translate,{content:"DynamicListTour.previousViewDescription"}),buttons:[d,p],size:"sm",placement:"left"}}))};S.propTypes={step:r().string.isRequired,onChange:r().func.isRequired};const P=({step:e,onStepChange:t})=>{switch(e){case"intro":return(0,a.createElement)(T,{onNext:()=>t("tabs"),onClose:()=>t("closed_intro")});case"tabs":case"secondary_actions":case"previous_view":return(0,a.createElement)(S,{step:e,onChange:t});default:return null}};P.propTypes={step:r().oneOf(["not_started","intro","closed_intro","tabs","closed_tabs","secondary_actions","closed_secondary_actions","previous_view","closed_previous_view","finish"]).isRequired,onStepChange:r().func.isRequired},t.default=P},947:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(144),o=n(582),c=n(934),m=n(935);const d=({hidePrimary:e,className:t,...n})=>{const{mainDomain:i,isMovable:s,movingError:d,allowRename:u,isRemovable:p,isSuspended:E,isDomainAlias:b,isSubdomain:_,filemanagerUrl:g,emailAddressesUrl:h,databasesUrl:f,databasesIsAvailable:y,hostingSettingsUrl:w,error503PageUrl:v,id:D,aliasId:T,domainId:S,displayName:P,parentDomain:k}=n;let C="buttonDeleteDomain";return b?C="buttonDeleteAlias":_&&(C="buttonDeleteSubdomain"),(0,a.createElement)(r.ListActions,{className:t,"data-type":"listActions","data-id":D},e?null:(0,a.createElement)(r.ListAction,{primary:!0,icon:"folder-closed",hidden:!g,component:o.default,to:g},(0,a.createElement)(r.Translate,{content:"buttonFileManager"})),e?null:(0,a.createElement)(r.ListAction,{primary:!0,icon:"mail",hidden:!h,component:"a",href:(0,l.prepareUrl)(h)},(0,a.createElement)(r.Translate,{content:"buttonEmailAddresses"})),e||!y?null:(0,a.createElement)(r.ListAction,{primary:!0,icon:"database",hidden:!f,component:o.default,to:f},(0,a.createElement)(r.Translate,{content:"buttonDatabases"})),e?null:(0,a.createElement)(r.ListAction,{primary:!0,icon:"sliders",hidden:!w,component:"a",href:(0,l.prepareUrl)(w)},(0,a.createElement)(r.Translate,{content:"buttonWebScripting"})),(0,a.createElement)(r.ListAction,{"data-type":"buttonMoveDomain",icon:"transfer",onClick:()=>(0,c.default)(n),disabled:!!d,tooltip:d||(0,a.createElement)(r.Translate,{content:i?"buttonMoveMainHint":"buttonMoveHint"}),hidden:!s},(0,a.createElement)(r.Translate,{content:"buttonMove"})),(0,a.createElement)(r.ListAction,{"data-type":"buttonRenameDomain",icon:"pencil",component:o.default,to:`?modals[rename-domain]=${btoa(encodeURIComponent(JSON.stringify({id:T||S,domainName:P,isDomainAlias:b,parentDomain:k})))}`,hidden:!u},(0,a.createElement)(r.Translate,{content:b?"buttonRenameAlias":"buttonRename"})),(0,a.createElement)(r.ListAction,{"data-type":"buttonOpenErrorPage",icon:"pencil",component:"a",href:(0,l.prepareUrl)(v),hidden:!(E&&v)},(0,a.createElement)(r.Translate,{content:"error503PageLink"})),(0,a.createElement)(r.ListAction,{"data-type":"buttonDeleteDomain",icon:"recycle",onClick:()=>(0,m.default)(n),tooltip:(0,a.createElement)(r.Translate,{content:`${C}Hint`}),hidden:!p},(0,a.createElement)(r.Translate,{content:C})))};d.propTypes={hidePrimary:s().bool,className:s().string},d.defaultProps={hidePrimary:!1,className:void 0},t.default=d},932:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(933);const o=({changeStatusLinks:e,isActive:t,isSuspended:n,className:i})=>{const s=(0,a.createElement)(r.Status,{intent:t?"success":n?"warning":"inactive",compact:!0},(0,a.createElement)(r.Translate,{content:t?"active":n?"suspended":"disabled"}));return e?(0,a.createElement)(r.Dropdown,{className:i,menu:(0,a.createElement)(r.Menu,null,Object.keys(e).map((t=>(0,a.createElement)(r.MenuItem,{key:t,onClick:()=>(0,l.default)(t,e[t]),"data-action":`domain-${t}`},(0,a.createElement)(r.Translate,{content:t})))))},(0,a.createElement)(r.Button,{ghost:!0,caret:!0,"data-type":"changeStatus"},s)):s};o.propTypes={changeStatusLinks:s().object,isActive:s().bool,isSuspended:s().bool,className:s().string},o.defaultProps={changeStatusLinks:null,isActive:!1,isSuspended:!1,className:void 0},t.default=o},942:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(144),o=n(582);const c=({item:e,icpPermitLearnMore:t,onEditDescription:n,onIcpPermit:i,onIcpStatus:s})=>{const{hostingType:c,webrootDir:m,ipv4Address:d,ipv6Address:u,filemanagerUrl:p,purchaseDomainMessage:E,sysUser:b,forwardingUrl:_,forwardingDisplayUrl:g,isDomainAlias:h,domainUrl:f,domainDisplayName:y,selfDescriptionType:w,customDescription:v,icpPermit:D,isIcpChangeable:T,icpStatus:S}=e,P=[];if("vrt_hst"===c?(P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"websiteAt"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"websiteAt"}))," ",p?(0,a.createElement)(r.Tooltip,{title:(0,a.createElement)(r.Translate,{content:"websiteAtHint"})},(0,a.createElement)(o.default,{to:p},m)):m)),E&&P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"purchaseDomainMessage"},(0,a.createElement)(r.Text,{intent:"muted",dangerouslySetInnerHTML:{__html:E}}))),P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"ipAddress"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"ipAddress"}))," ",d&&u?`${d}(v4), ${u}(v6)`:d||u)),P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"sysUser"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"sysUser"}))," ",b))):"none"===c?P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"noHosting"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"noHosting"})))):"frm_fwd"===c||"std_fwd"===c?P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"forwardingTo"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"forwardingTo"}))," ",(0,a.createElement)(r.Link,{target:"_blank",href:(0,l.prepareUrl)(_)},g))):h&&P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"domainAlias"},(0,a.createElement)(r.Text,{intent:"muted"},(0,a.createElement)(r.Translate,{content:"domainAliasDescription"}))," ",f?(0,a.createElement)(r.Link,{target:"_blank",href:(0,l.prepareUrl)(f)},y):y)),void 0!==S){const n=l.Locale.getSection("components.icp-permit");P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"icpPermitAllowed"},(0,a.createElement)(r.Text,{intent:"muted"},n.lmsg("icpPermit")),": ",(0,a.createElement)(r.Tooltip,{title:n.lmsg(S?"icpStatusAllowedDescription":"icpStatusNotAllowedDescription")},t?(0,a.createElement)(r.Link,{target:"_blank",href:t},D||n.lmsg("icpStatusNotAllowed")):(0,a.createElement)(r.Text,{bold:!0},D||n.lmsg("icpStatusNotAllowed"))))),T&&(P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"icpPermit"},(0,a.createElement)(r.Link,{onClick:()=>i(e)},n.lmsg(D?"changeIcpPermit":"enterIcpPermit")))),P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item",key:"icpStatus"},(0,a.createElement)(r.Link,{onClick:()=>s(e)},n.lmsg(S?"revokeIcpStatus":"grantIcpStatus")))))}return w&&P.push((0,a.createElement)("span",{className:"smb-web-view-dynamic-list-item-summary__item smb-web-view-dynamic-list-item-summary__item--aside",key:"domainAlias"},(0,a.createElement)(r.Link,{onClick:()=>n(e,w)},(0,a.createElement)(r.Translate,{content:v[w]?"buttonDescriptionEdit":"buttonDescriptionAdd"})))),(0,a.createElement)("div",{className:"smb-web-view-dynamic-list-item-summary"},P.length?(0,a.createElement)("div",{className:"smb-web-view-dynamic-list-item-summary__list"},P):null,v&&Object.keys(v).length?(0,a.createElement)("div",{className:"smb-web-view-dynamic-list-item-summary__description"},Object.keys(v).map((t=>{const i=t===w;return(0,a.createElement)("div",{key:t,className:"smb-web-view-dynamic-list-item-summary__description-item"},(0,a.createElement)(r.Text,{className:"smb-web-view-dynamic-list-item-summary__description-item-text",intent:i?null:"muted"},i?null:(0,a.createElement)(a.Fragment,null,(0,a.createElement)(r.Translate,{content:`${t}Description`})," "),v[t]),i?null:(0,a.createElement)(a.Fragment,null," ",(0,a.createElement)(r.Link,{onClick:()=>n(e,t)},(0,a.createElement)(r.Translate,{content:"buttonEdit"}))))}))):null)};c.propTypes={item:s().object.isRequired,icpPermitLearnMore:s().string.isRequired,onEditDescription:s().func.isRequired,onIcpPermit:s().func.isRequired,onIcpStatus:s().func.isRequired},t.default=c},969:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155),l=n(939),o=n(949),c=n(956);const m=({locale:e,...t})=>(0,a.createElement)(r.LocaleProvider,{messages:e},(0,a.createElement)(r.Panel,null,(0,a.createElement)(l.default,t)),(0,a.createElement)(o.default,null),(0,a.createElement)(c.default,null));m.propTypes={locale:s().object.isRequired},t.default=m},948:(e,t,n)=>{"use strict";n.r(t);var a=n(154),i=n(261),s=n.n(i),r=n(155);const l=({domainId:e,onClose:t})=>{const[n,i]=(0,a.useState)(0),s=()=>{i(null),t()};return(0,a.createElement)(r.Tour,{current:n,onClose:s},(0,a.createElement)(r.Spot,{selector:'div[data-type="listActions"][data-id="domain:'.concat(e,'"] div:last-child'),placement:"right",popup:{size:"xs",placement:"top-left",buttons:[(0,a.createElement)(r.Button,{key:"finish",onClick:s,intent:"primary","data-type":"close-rename-tour"},(0,a.createElement)(r.Translate,{content:"RenameTour.buttonGotIt"}))],children:(0,a.createElement)(r.Translate,{content:"RenameTour.description"})}}))};l.propTypes={domainId:s().number.isRequired,onClose:s().func.isRequired},t.default=l},943:(e,t,n)=>{"use strict";n.r(t);var a=n(155),i=n(154),s=n(261);const r=({url:e})=>(0,i.createElement)("div",{className:"smb-web-view-screenshot-loader"},(0,i.createElement)(a.PreviewPanel,{className:"smb-web-view-screenshot",image:e}));r.propTypes={url:n.n(s)().string.isRequired},t.default=r},905:(e,t,n)=>{"use strict";n.r(t);var a=n(153),i=n.n(a),s=n(154),r=n(261),l=n.n(r),o=n(155),c=n(602),m=n(648),d=n(765),u=n(906),p=n(922),E=n(930),b=n(932),_=n(947),g=n(948),h=n(144),f=n(613),y=n(405),w=n(302);const v=({allowCreateDomain:e,allowManageSubdomain:t,allowManageDomainAliases:n,showAddHostingButton:a,hasWebspace:r,allowCreateWebspace:l,showDeleteButton:o,isHomonymSearchEnabled:c,activeListProps:m,classicListProps:u})=>{const[b]=(0,d.useAddDomainFormInDrawer)("/smb/web/view","/smb/web/add-domain");return m?(0,s.createElement)(s.Fragment,null,b,(0,s.createElement)(E.default,m)):(0,s.createElement)(s.Fragment,null,b,(0,s.createElement)(p.default,i()({allowCreateDomain:e,allowManageSubdomain:t,allowManageDomainAliases:n,showAddHostingButton:a,hasWebspace:r,allowCreateWebspace:l,showDeleteButton:o,isHomonymSearchEnabled:c},u)))};v.propTypes={actionName:l().string.isRequired,allowCreateDomain:l().bool,allowManageSubdomain:l().bool,allowManageDomainAliases:l().bool,showAddHostingButton:l().bool,hasWebspace:l().bool,allowCreateWebspace:l().bool,showDeleteButton:l().bool,isHomonymSearchEnabled:l().bool,activeListProps:l().object,classicListProps:l().object,showRenameTour:l().bool},v.defaultProps={allowCreateDomain:!1,allowManageSubdomain:!1,allowManageDomainAliases:!1,showAddHostingButton:!1,hasWebspace:!1,allowCreateWebspace:!1,showDeleteButton:!1,isHomonymSearchEnabled:!1,activeListProps:null,classicListProps:null,showRenameTour:!1},v.contextTypes={locale:l().object},t.default=(0,c.withPageLayout)((0,m.withPageContent)(v),(({sidebarProps:e,pageContentHeader:t,activeListProps:n,showRenameTour:a})=>{const{data:{viewer:r}={}}=(0,y.useQuery)(w.gql`
        {
            viewer {
                login
            }
        }
    `),{isSecondaryCollapsible:l,secondaryCollapsed:c}=e,[m,d]=(0,s.useState)(l&&c),[p,E]=(0,f.useLocalStorage)(`SecondaryRemoveSurveyVisible_${r?r.login:""}`,l),v=()=>{const e=!m;d(e),h.api.post("/smb/ui-customization/sidebar-state",{isCollapsed:e}),h.UAT.dispatchAction("COLLAPSE_SECONDARY_SIDEBAR",{isCollapsed:e})};if(n&&!n.toolbar){const{locale:e,data:[r]}=n;t={...t,titleRightAddon:(0,s.createElement)(o.LocaleProvider,{messages:e},(0,s.createElement)(b.default,i()({className:"smb-web-view-overview__action"},r)),(0,s.createElement)(_.default,i()({className:"smb-web-view-overview__action",hidePrimary:!0},r)),a&&r.allowRename&&(0,s.createElement)(g.default,{domainId:r.domainId,onClose:()=>h.api.post("/smb/web/dynamic-list-rename-promotion-hide")})),pageSubtitle:r.aliasId?(0,s.createElement)(o.LocaleProvider,{messages:e},(0,s.createElement)(o.Translate,{content:"domainAlias"})):["std_fwd","frm_fwd"].includes(r.hostingType)?(0,s.createElement)(o.LocaleProvider,{messages:e},(0,s.createElement)(o.Translate,{content:"forwardingTo"})," ",(0,s.createElement)("b",null,r.forwardingDisplayUrl)):null}}l&&(t.titleRightAddon=[n&&!n.toolbar?t.titleRightAddon:null,(0,s.createElement)(o.Button,{key:"rightSidebarCollapseButton",className:"page-content-header__action",ghost:!0,icon:m?"sidebar-right-show":"sidebar-right-hide",id:"rightSidebarCollapseButton",onClick:v})]);const D=(0,s.createElement)("div",null,l&&"true"===p.toString()?(0,s.createElement)(o.Alert,{intent:"info",onClose:()=>{E(!1)}},(0,s.createElement)(o.Media,{image:(0,s.createElement)(o.Icon,{name:"question-mark-circle-filled",intent:"info",size:"16"})},(0,s.createElement)(o.LocaleProvider,{messages:h.Locale.getSection("components.layout").messages},(0,s.createElement)(o.MediaSection,null,(0,s.createElement)("b",null,(0,s.createElement)(o.Translate,{content:"removeSidebarSurveyQuestion"})),(0,s.createElement)("br",null),(0,s.createElement)("a",{href:"https://pt-research.typeform.com/to/GNlmMk8w",target:"_blank",rel:"noopener noreferrer"},(0,s.createElement)(o.Translate,{content:"threeMinutesSurveyLink"})))))):null,(0,s.createElement)(u.default,e));return{pageContentHeader:t,isSecondaryCollapsed:m,secondary:D}}))},933:(e,t,n)=>{"use strict";n.r(t);var a=n(144);const i=a.Locale.getSection("components.active-lists.sites"),s=a.Locale.getSection("components.buttons");t.default=(e,t)=>{"activate"!==e?a.messageBox.show({type:a.messageBox.TYPE_YESNO,buttonTitles:{yes:s.lmsg("yes"),no:s.lmsg("no")},text:i.lmsg(`${e}Hint`),subtype:"confirm",onYesClick(){(0,a.redirectPost)(t)}}):(0,a.redirectPost)(t)}},935:(e,t,n)=>{"use strict";n.r(t);var a=n(144);const i=a.Locale.getSection("components.active-lists.sites");t.default=({id:e,title:t,isDomainAlias:n,isSubdomain:s,relatedDomains:r})=>{let l,o;if(n?(l=i.lmsg("buttonDeleteAliasConfirmationText",{name:`<b>${(0,a.escapeHtml)(t)}</b>`}),o=""):s?(l=i.lmsg("buttonDeleteSubdomainConfirmationText",{name:`<b>${(0,a.escapeHtml)(t)}</b>`}),o=i.lmsg("buttonDeleteSubdomainConfirmationDescription")):(l=i.lmsg("buttonDeleteDomainConfirmationText",{name:`<b>${(0,a.escapeHtml)(t)}</b>`}),o=i.lmsg("buttonDeleteDomainConfirmationDescription")),0!==r.length){o=`${o}\n${i.lmsg("removingRelatedDomainsList",{domains:r.join(", ")})}`}return o=o.replace(/\n/g,"<br>"),a.messageBox.show({type:a.messageBox.TYPE_YESNO,subtype:a.messageBox.SUBTYPE_DELETE,text:l,description:o,onYesClick(){(0,a.redirectPost)("/smb/web/delete",{ids:{0:e},redirect:!0})}})}},934:(e,t,n)=>{"use strict";n.r(t),t.default=async({domainId:e,displayName:t,mainDomain:a})=>{const{default:i}=await n.e("views/smb/web/move").then(n.bind(n,1164));i({domainName:t,domainId:e,mainDomain:a})}},904:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>a.default});var a=n(905)},785:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/att-tr.png?f00bf7056f997d02b1565fff15ed7ab7"},912:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/components.png?b7a15e66fd28f6ecdcd7b3588b07cef9"},936:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/customize.png?847e39cbbadb3ad07a58c2ab7bded4e4"},810:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/delete.png?27d654be29d57ad05641c2ff392035fa"},786:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/dns.png?d10cfc4afe5c5c040eaf99c3ea14429d"},924:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/dom-aliases.png?3a23a15068824ee199f7f705ea14715f"},923:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/domain.png?efca404644beb4b094c73d06dacbbd17"},789:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/forward-to-dom.png?761778de5722f4bb1f3611d27968cb0f"},823:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/login.png?b68531bba0e522a3a35a90de80b8892a"},911:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/logs.png?1b342bff0b5eadc19b236cc85559c896"},921:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/manage.png?39b563c6c659ab707399af21034635be"},918:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/own-subs.png?dfc9feb73e544883b78f6295ca9be3b9"},925:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/preview.png?e5c602ef8c9bea2bb5365f17e8d050c9"},937:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/publish.png?25d5e7ba6e1c765930c21263cac36a08"},920:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/register-domain.png?25f131434960d2f52bd9a3abfe969069"},914:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/settings.png?dac579812d429f3f9a89bb44dbb5e2e9"},927:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/sitebuilder.png?9523bb6d24cda35e23ccbf6f9d1ec4fa"},788:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/spacer.png?4710d0e07ee1a4d7ebdb1972701168fa"},929:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/ssl-cert.png?10a58669d9847ffe0b1bc8bbe4497a03"},749:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/stats.png?6a39051adc0633466df48a83a804028c"},919:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/subs.png?48425a927960990e5069582d8b23e384"},814:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/subscription-status-locked.png?791d616dde33b19ebd4b7fbf3b305ffe"},784:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/subscription-status-ok.png?6d52f91c87cbdc73b4ef0b5ded92c441"},815:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/subscription-status-unsynchronized.png?c075e72041171bb35d0a9b6542518ccf"},915:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/switch-to-another-plan.png?bf73d7523194c242ccc2ac99a1e5e3e7"},916:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/unlock-and-sync.png?c4311ee92abdbcb4f0dc94ca2546bdfc"},743:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/update-light.png?74fefb9b3ca4a30e8fb17619678aa233"},917:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/upgrade-to-customer.png?96c47755ca77e0d103b9ea64e604ef9d"},928:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/web-stats-ssl.png?114121892fe2c3dc5638da0c7addbae3"},926:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/website-folder.png?18a72ed255a7afafb5d5e87257cdbf55"},787:e=>{e.exports=Jsw.skinUrl+"/icons/16/plesk/website.png?ac6aa9eaf06048cbd5799a61daad9766"},945:e=>{e.exports=Jsw.skinUrl+"/icons/svg/web-presence-builder.svg?645c91fdd6dae31207e09fba836a2200"},944:e=>{e.exports=Jsw.skinUrl+"/icons/svg/web-users.svg?c950d7262100d27e17cff1ba02e5e8d0"},946:e=>{e.exports=Jsw.skinUrl+"/icons/svg/website-copying.svg?37487e5486bbd6c26c2a4422a9ea1617"},779:e=>{e.exports=Jsw.skinUrl+"/images/add-domain/process.svg?2cd8b0c86019c2d951acd8c173a6974f"},778:e=>{e.exports=Jsw.skinUrl+"/images/add-domain/step1.svg?cdb98922dc6afaf36776f30b81762d6d"},777:e=>{e.exports=Jsw.skinUrl+"/images/add-domain/step2.svg?5c9d5f36abe3d2707367cb8a7f9e432a"},775:e=>{e.exports=Jsw.skinUrl+"/images/code.svg?e9fb9feb605b8cf334414f688a603918"},959:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-promotion.png?815ac9dd7887f339eaf1c58f3e36dd43"},966:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/change_view_trim_x2.gif?3bed0f2f125f61f8f9ed4e46bd205d72"},965:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/change_view_trim_x2.webp?be5d4bb5b8a045aa146594f54dafd6e6"},962:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/expand_trim_x2.gif?3a72c2d520cf18b9c8fd4ddef79998bd"},961:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/expand_trim_x2.webp?573d880814f2cffd6375348de0125c5e"},964:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/menu_trim_x2.gif?9c3abe5823568409ebc36a12b333618f"},963:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/menu_trim_x2.webp?631f9efd9992dbe9cfa3b342c3dac04f"},968:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/tabs_trim_x2.gif?967cbb2d4c8f8bdf075e126b5d7d685c"},967:e=>{e.exports=Jsw.skinUrl+"/images/dynamic-list-tour/tabs_trim_x2.webp?b956f7c113b66c4e42e649f30ba699c1"},776:e=>{e.exports=Jsw.skinUrl+"/images/upload-files.svg?e6091d3474a27a3eafe63b2d09b1b943"}}]);
//# sourceMappingURL=view.js.map?d6e5eb1d806c6467fdaa