1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="7ee670c9-3c9a-456c-851c-4e4cddc65ad4",e._sentryDebugIdIdentifier="sentry-dbid-7ee670c9-3c9a-456c-851c-4e4cddc65ad4")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1080],{1044:(e,t,n)=>{"use strict";n.d(t,{A:()=>p});var o=n(42969),i=n(14232),r=n(28118),a=n(1796),s=n(34626),c=n(4917),l=n.n(c),d=n(55700),u=n(37876);function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let p=(0,r.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.className,r=e.data,c=e.options,m=e.optionLabel,p=e.optionValue,x=e.fetch,g=e.meta,f=e.query,b=e.updateQuery,j=e.updateFilter,v=e.reset,y=e.onSelect,A=e.size,w=void 0===A?"medium":A,C=e.id,T=e["aria-labelledby"],k=(0,i.useState)(!1),S=k[0],I=k[1],P=(0,i.useState)(!1),O=P[0],N=P[1],z=(0,i.useState)(null),D=z[0],H=z[1],F=(0,i.useRef)(!1);(0,i.useEffect)(function(){return function(){return v()}},[]),(0,i.useEffect)(function(){R()},[c,r,m,p]);var R=function(){if(!r)return void H(null);var e,t,n=r.ctaLink?r.ctaLink.replace(/^\//,""):r.permalink,i=c.find(function(e){return e.permalink===n}),a=null!=r.id&&""!==r.id?c.find(function(e){return String(e[p])===String(r.id)}):null,s=null!=i?i:a;s?H(s):r.ctaLinkName?H((0,o.default)((0,o.default)((0,o.default)({},m,r.ctaLinkName),p,null!=(e=null!=(t=r[p])?t:r.id)?e:r.ctaLink),"permalink",n)):H(null)},E=(0,i.useCallback)(function(){return x?(N(!0),Promise.resolve(x()).finally(function(){N(!1),F.current=!1})):Promise.resolve()},[x]),U=(0,i.useCallback)(function(){if(g&&f&&!F.current&&!O){var e,t,n=(null!=(e=g.all)?e:0)-(null!=(t=g.hidden)?t:0);c.length>=n||(F.current=!0,b({page:f.page+1}),E())}},[g,f,c.length,O,b,E]),B=(0,i.useMemo)(function(){return l()(function(e){v(),j({search:e}),E()},500)},[v,j,E]);(0,i.useEffect)(function(){return function(){B.cancel()}},[B]);var L=t("editor:editor.selectProject");return(0,u.jsx)(a.A,{id:C,className:n,size:w,fullWidth:!0,disableClearable:!0,options:c,loading:O,value:D,onChange:function(e,t){t?(H(t),y(t)):H(null)},onOpen:function(){S||(E(),I(!0))},onClose:function(){I(!1),v()},onInputChange:function(e,t,n){"input"===n&&B(t)},getOptionLabel:function(e){var t;return null!=(t=null==e?void 0:e[m])?t:""},isOptionEqualToValue:function(e,t){return String(null==e?void 0:e[p])===String(null==t?void 0:t[p])},filterOptions:function(e){return e},sx:d.OP,slotProps:h(h({},d.HE),{},{listbox:h(h({},d.HE.listbox),{},{onScroll:function(e){var t=e.currentTarget;t.scrollTop+t.clientHeight>=t.scrollHeight-24&&U()}})}),renderOption:function(e,t){var n;return(0,d.uk)(e,null!=(n=null==t?void 0:t[m])?n:"")},renderInput:function(e){return(0,u.jsx)(s.A,h(h({},e),{},{size:w,variant:"outlined",placeholder:L,title:(null==D?void 0:D[m])||void 0,slotProps:{htmlInput:h(h({},e.inputProps),T?{"aria-labelledby":T}:{"aria-label":L})}}))}})})},2649:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.e361744bc188f964.jpg"},3016:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.1db2c13c5ce8f90e.jpg"},5454:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.4a5e21b2314724e5.jpg"},6899:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var o=n(47091),i=n.n(o),r=n(14232),a=n(37876);let s=(0,r.memo)(function(e){var t,n,o=e.url,s=e.update,c=e.positionX,l=e.positionY,d={x:void 0===c?50:c,y:void 0===l?50:l},u=(0,r.useRef)(null),m=(0,r.useState)(0),h=m[0],p=m[1],x=(0,r.useState)(0),g=x[0],f=x[1];(0,r.useEffect)(function(){n=u.current.getBoundingClientRect(),t=document.querySelector(".focal-point-container .image-dot"),y()});var b=function(e,t){return e/t*100},j=function(e,t){if(e>100)throw Error("Invalid number, percent can't be more than 100");return e/100*t},v=function(e){n=document.querySelector(".focal-point-container .pointer-control img").getBoundingClientRect();var t=Math.round(b(e.clientX-n.x,n.width)),o=Math.round(b(e.clientY-n.y,n.height));t<=0?d.x=0:t>=100?d.x=100:d.x=t,o<=0?d.y=0:o>=100?d.y=100:d.y=o},y=function(){p(j(d.x,n.width)-t.offsetWidth/2),f(j(d.y,n.height)-t.offsetHeight/2),s(d)};return(0,a.jsxs)("div",{className:"jsx-3297605560",children:[(0,a.jsx)("div",{className:"jsx-3297605560 focal-point-container",children:(0,a.jsx)("div",{onPointerDown:function(e){v(e),y()},className:"jsx-3297605560 pointer-control",children:(0,a.jsxs)("div",{className:"jsx-3297605560 preview-container",children:[(0,a.jsx)("img",{ref:u,alt:"focal point",draggable:"false",src:o,style:{objectFit:"contain"},className:"jsx-3297605560 preview-image"}),(0,a.jsx)("div",{style:{left:"".concat(h,"px"),top:"".concat(g,"px")},className:"jsx-3297605560 image-dot"})]})})}),(0,a.jsx)(i(),{id:"3297605560",children:[".focal-point-container.jsx-3297605560 .image-dot.jsx-3297605560{position:absolute;
1top:calc(50% - 10px);left:calc(50% - 10px);width:20px;height:20px;background:hsla(0,100%,50%,1);border-radius:20px;border:2px solid white;box-shadow:0 0 4px black;}",".focal-point-container.jsx-3297605560 .pointer-control.jsx-3297605560{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;position:relative;}",".preview-image.jsx-3297605560{height:200px;margin-bottom:12px;background-size:contain;background-repeat:no-repeat;background-color:#efefef;background-position:center center;}",".preview-container.jsx-3297605560{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]})]})})},7648:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/ten.bbeaf07566903741.jpg"},9049:()=>{},10203:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-jpg-solid-24.138f8ef187197ac8.png"},10326:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.ac2e6f9a3215257e.jpg"},10359:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/five.6619902c840f59fb.jpg"},11134:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.903ea45455237762.jpg"},11227:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.d79f03a5e7143b88.jpg"},11770:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.fc4c11407e4323c0.jpg"},13453:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.3c88ef0fd96e3c74.jpg"},13685:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.992b60a828e166fb.jpg"},13939:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.a0e3197b7c351c69.jpg"},16488:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/bondi.1d2d71b070c8254a.jpg"},18597:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-blank-regular-24.4808100aa6a9c3c2.png"},18905:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.c0d0aa60279078a6.jpg"},19247:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-png-solid-24.7b2cc85edc163c17.png"},19884:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/goldcoast.2a70fbdaf770fcd7.jpg"},21171:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/five.11569cd3cc93c4c2.jpg"},21564:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/four.f02ac9fc003095d7.jpg"},21670:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-doc-solid-24.380c197bf85cf56c.png"},22063:(e,t,n)=>{"use strict";n.d(t,{A:()=>g});var o=n(42969),i=n(59860),r=n(14232),a=n(34626),s=n(30528),c=n(31123),l=n(46620),d=n(28118),u=n(37876),m=["value","defaultValue","onChange","onClear","slotProps","type","select","size"];function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?h(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var x=new Set(["number","password"]);function g(e){var t,n,o,h=e.value,g=e.defaultValue,f=e.onChange,b=e.onClear,j=e.slotProps,v=e.type,y=e.select,A=e.size,w=void 0===A?"medium":A,C=(0,i.A)(e,m),T=(0,d.useTranslation)("common").t,k=void 0!==h,S=(0,r.useState)(null!=g?g:""),I=S[0],P=S[1];if((0,r.useEffect)(function(){k||P(null!=g?g:"")},[g,k]),y||x.has(null!=v?v:"text"))return(0,u.jsx)(a.A,p({value:h,defaultValue:g,onChange:f,type:v,select:y,size:w,slotProps:j},C));var O=k?null!=h?h:"":I,N=(null==j||null==(t=j.htmlInput)?void 0:t.readOnly)!==!0&&(null==(n=C.inputProps)?void 0:n.readOnly)!==!0&&String(O).length>0&&(b||f),z=null==j||null==(o=j.input)?void 0:o.endAdornment,D=N?(0,u.jsx)(s.A,{position:"end",children:(0,u.jsx)(c.A,{size:"small","aria-label":T("common.clear"),onClick:function(e){e.preventDefault(),k||P(""),b?b():f&&f({target:{value:""}})},edge:"end",sx:{p:.25},children:(0,u.jsx)(l.A,{sx:{fontSize:20}})})}):null,H=p(p({},j),{},{input:p(p({},null==j?void 0:j.input),{},{endAdornment:z||D?(0,u.jsxs)(u.Fragment,{children:[z,D]}):void 0})});return(0,u.jsx)(a.A,p({value:O,onChange:function(e){k||P(e.target.value),null==f||f(e)},type:v,size:w,slotProps:H},C))}},23587:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.8d0dc1fe5086eeb2.jpg"},23937:(e,t,n)=>{"use strict";n.d(t,{A:()=>d});var o=n(42969),i=n(59860),r=n(39976),a=n(37876),s=["checked","onChange","id","slotProps"];function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?c(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function d(e){var t=e.checked,n=e.onChange,o=e.id,c=e.slotProps,d=(0,i.A)(e,s);return(0,a.jsx)(r.A,l({checked:!!t,onChange:function(e){return n(e.target.checked)},id:o,slotProps:l(l({},c),{},{input:l(l({role:"switch"},o?{id:o}:{}),"object"==typeof(null==c?void 0:c.input)?c.input:null)})},d))}},24795:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var o=n(42969),i=n(59234),r=n(46783),a=n(62631),s=n(68843),c=n(37876);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let u=function(e){var t=e.title,n=e.description,o=e.sx;return(0,c.jsxs)(i.A,{sx:d({minWidth:0},o),children:[(0,c.jsx)(r.A,{component:"p",variant:"body1",color:"text.primary",sx:d({m:0,mb:.5},a.m),children:t}),(0,c.jsx)(s.A,{sx:{mb:.5},children:n})]})}},26404:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.417a4b058355ef33.jpg"},27917:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/six.47f63b37955a46fa.jpg"},30341:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.4d9928b516768117.jpg"}
1,30354:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>ci});var o=n(31777),i=n(83129),r=n(63857),a=n(44478),s=n(47091),c=n.n(s),l=n(60180),d=n.n(l),u=n(14232),m=n(28118),h=n(52630),p=n(92105),x=n(59234),g=n(65595),f=n(52970),b=n(15969),j=n(5784),v=n(32430),y=n(74570),A=n(86085),w=n(31123),C=n(69692),T=n(64658),k=n(80505),S=n.n(k),I=n(89099),P=n.n(I),O=n(18847),N=n.n(O),z=n(46783),D=n(89487),H=n(43284),F=n(69364),R=n.n(F),E=n(42969),U=n(62886),B=n(58498),L=n(67872),_=n(30731),W=n(5714),M=n(24795),K=n(75612),Y=n(796),V=n(63160),q=n(16765),Q=n(49387),Z=n(74593),G=n(45574),X=n(62069),$=n(29043),J=n(54920),ee=n(31314),et=n(73275),en=n(12336),eo=n(47172),ei=n(62631),er=n(30069),ea=n(7194),es=n(22063),ec=n(99469),el=n(56296),ed=n(60858),eu=n(98512),em=n(21471),eh=n(72440),ep=n(33248),ex=n(52077),eg=n(58535),ef=n(71929),eb=n(65588),ej=n(13434),ev=n(19058),ey=n(23937),eA=n(37902),ew=n(92181),eC=n(83902);let eT=(0,o.Ng)(function(e){return{imageKey:"image",uploading:e.hubPageRevision.uploadingFile,uploadError:e.hubPageRevision.fileUploadError,dataTestId:"admin-hubs-editor-imagemanager"}},function(e){return(0,i.zH)({uploadImage:er.QM},e)})(eC.A);var ek=n(94525),eS=n(6899),eI=n(37876),eP={width:1,mb:3,border:1,borderColor:"divider",borderRadius:1,position:"relative",overflow:"hidden",cursor:"pointer","@keyframes fadein":{from:{opacity:0}
1,to:{opacity:1}},animation:"fadein 3s","&:hover":{borderColor:"primary.main",boxShadow:1,"& .project-image-choose":{mt:"-45px"}}},eO=(0,u.memo)(function(e){var t,n,o,i=e.t,a=e.afterUpdate,s=(e.imageUrl,e.currentImage),c=e.updateSectionData,l=e.sectionId,m=e.projectImages,p=e.tabKey,g=e.updateSite,f=e.isHeader,b=(e.imgixUrl,e.title),j=e.imageSettingsToggler,v=e.activeImageTab,y=e.imgFocusEnabled,A=e.imgFocusX,w=e.imgFocusY,C=e.isProject,T=e.deleteKey,k=e.dataTestId,S=e.uploading,I=void 0!==S&&S,P=e.uploadError,O=void 0===P?"":P,N=(0,u.useState)(!1),D=N[0],H=N[1],F=(0,u.useState)((0,ej.yt)(s)),R=F[0],E=F[1],U=(0,u.useState)(""),B=U[0],L=U[1],_=(0,u.useState)(A),W=_[0],M=_[1],K=(0,u.useState)(w),Y=K[0],V=K[1],q=(0,u.useState)(!1),Q=q[0],Z=q[1],G=(0,u.useState)(!1),X=G[0],$=G[1],J=(0,u.useState)(""),ee=J[0],et=J[1],en=(0,u.useRef)(!1),eo=s?(0,ej.yt)(s,200):"",ei=s?(0,ej.yt)(s):"",er=!R&&!!ei,ea=(R||"")!==(ei||"")||!!B,es=Q||I,ec=X||er||es,eC=function(e){("cropImage"!==e||R)&&j(e)};(0,u.useEffect)(function(){E((0,ej.yt)(s)),L(""),$(!1),et("")},[s]),(0,u.useEffect)(function(){R||"cropImage"!==v||j("upload")},[R,v,j]),(0,u.useEffect)(function(){if(D){if(I){en.current=!1,et("");return}!en.current&&O&&(et(String(O)),$(!1))}},[O,I,D]);var eO=function(){s?j("cropImage"):j("upload"),L(""),$(!1),et(""),en.current=!0,H(!0)},eN=(t=(0,r.A)(d().mark(function e(t){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:f?g("logoUrl",t):a(t),j("upload"),L(""),$(!1),et(""),H(!1);case 6:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)}),ez=(n=(0,r.A)(d().mark(function e(){var t,n,o;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!es){e.next=2;break}return e.abrupt("return");case 2:if(Z(!0),e.prev=3,"cropImage"!==v){e.next=15;break}return t=(0,ej.JU)(s),e.next=8,eb.A.perform(B);case 8:return n=e.sent,E(o=t?"".concat(n,"/unsplash-").concat(t):n),e.next=13,eN(o);case 13:e.next=18;break;case 15:return e.next=17,eN(R);case 17:c("imgFocusEnabled",!1,l,p);case 18:return e.prev=18,Z(!1),e.finish(18);case 21:case"end":return e.stop()}},e,null,[[3,,18,21]])})),function(){return n.apply(this,arguments)}),eD=function(){es||(E(s?(0,ej.yt)(s):""),L(""),$(!1),et(""),en.current=!0,j("upload"),H(!1))},eH=(o=(0,r.A)(d().mark(function e(t){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:E(t),L(""),j("upload");case 3:case"end":return e.stop()}},e)})),function(e){return o.apply(this,arguments)}),eF=function(e){E(e),L("")};return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsxs)(x.A,{sx:{mt:.75,display:"flex",flexDirection:"column"},children:[!s&&(0,eI.jsxs)(x.A,{onClick:eO,role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),eO())},"data-testid":"".concat(k,"-imageUpload"),sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:1,height:200,mb:1.5,px:2,cursor:"pointer",border:1,borderStyle:"dashed",borderColor:"divider",borderRadius:1,bgcolor:"grey.100"},children:[(0,eI.jsx)(ex.A,{sx:{fontSize:30,color:"action.active"}}),(0,eI.jsx)(z.A,{component:"p",variant:"body2",color:"text.secondary",align:"center",children:i("project:project.clickToUpload")}),(0,eI.jsx)(z.A,{component:"p",variant:"body2",color:"text.secondary",align:"center",children:i("editor:editor.images.banner.uploadImageTypeText")})]}),!!s&&(y?(0,eI.jsx)(eS.A,{url:eo,update:function(e){M(e.x),V(e.y),void 0===p?(c("imgFocalX",W,l),c("imgFocalY",Y,l)):C||T===p||(c("imgFocalX",W,l,p),c("imgFocalY",Y,l,p))},positionX:W,positionY:Y}):(0,eI.jsx)(x.A,{component:"img",src:eo,alt:"",sx:{display:"block",width:1,height:200,mb:1.5,objectFit:"contain",objectPosition:"center",bgcolor:"grey.200"}}))]}),!f&&(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:1,pr:2},children:[(0,eI.jsx)(el.A,{tooltip:i("common:common.imageFocalPointTooltip"),placement:"top","aria-label":i("common:common.imageFocalPoint"),children:(0,eI.jsx)("label",{htmlFor:"".concat(k,"-focalPoint"),children:i("common:common.imageFocalPoint")})}),(0,eI.jsx)(ey.A,{id:"".concat(k,"-focalPoint"),"data-testid":"".concat(k,"-focalPoint"),size:"medium",className:"auto-notify-switch",checked:y&&!!s,onChange:function(e){return c("imgFocusEnabled",e,l,p)}})]}),(0,eI.jsxs)(x.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:1},children:[(0,eI.jsx)(em.A,{variant:"contained",color:"primary",onClick:eO,"data-testid":"".concat(k,"-editImageBtn"),children:s?i("editor:editor.update"):i("editor:editor.uploadImage")}),(0,eI.jsx)(eg.A,{"data-testid":"".concat(k,"-deleteBtn"),onClick:function(){f&&g("logoUrl",""),c("image","",l,p),E("")},disabled:!s}
1)]}),(0,eI.jsxs)(ed.A,{title:i("editor:editor.uploadOrEdit",{title:b}),width:"80vw",visible:D,onClose:eD,closeDisabled:ec,footer:(0,eI.jsxs)(ek.A,{children:[(0,eI.jsx)(em.A,{variant:"contained",color:"primary",onClick:ez,loading:Q,loadingPosition:"start",disabled:I||!ea,"data-testid":"".concat(k,"-saveBtn"),children:i("common:common.save")}),(0,eI.jsx)(em.A,{variant:"outlined",onClick:eD,disabled:es,"data-testid":"".concat(k,"-cancelBtn"),children:i("common:common.cancel")})]}),children:[(0,eI.jsxs)(ep.A,{value:v,onChange:function(e,t){return eC(t)},textColor:"inherit",sx:eA.R,children:[(0,eI.jsx)(eh.A,{value:"upload",label:(0,eI.jsx)(x.A,{component:"span","data-testid":"".concat(k,"-upload"),children:i("common:common.upload")})}),(0,eI.jsx)(eh.A,{value:"unsplash",label:(0,eI.jsx)(x.A,{component:"span","data-testid":"".concat(k,"-imagesByUnsplash"),children:(0,eI.jsxs)(eI.Fragment,{children:[i("editor:editor.imagesByUnsplash"),(0,eI.jsx)(x.A,{component:"span",sx:{fontSize:10,color:"error.main",px:.75,fontWeight:300,borderRadius:1,bgcolor:function(e){return(0,ew.X4)(e.palette.error.main,.08)},ml:1.25,textTransform:"uppercase",textDecoration:"none",border:1,borderColor:"error.main"},children:i("project:project.newIdentifier")})]})})}),(0,eI.jsx)(eh.A,{value:"cropImage",disabled:!R,label:(0,eI.jsx)(x.A,{component:"span","data-testid":"".concat(k,"-editImage"),children:i("editor:editor.imageEditor")})})]}),"upload"===v?(0,eI.jsxs)(x.A,{sx:{overflowY:"auto",minHeight:"calc(100vh - 60px)"},children:[(0,eI.jsx)(eT,{onActionComplete:function(e,t){if("delete"===e){E(""),L(""),$(!1),et("");return}"string"==typeof t&&t&&(E(t),et(""),$(!0))},imageUrl:R}),X||er?(0,eI.jsx)(eu.A,{severity:"info",sx:{mt:1.5,mb:2},"data-testid":"".concat(k,"-clickSaveHint"),children:er?i("editor:editor.image.clickSaveToApplyDelete"):i("editor:editor.image.clickSaveToApply")}):null,ee?(0,eI.jsxs)(eu.A,{severity:"error",sx:{mt:1.5,mb:2},"data-testid":"".concat(k,"-uploadFailedHint"),onClose:function(){et(""),en.current=!0},children:[R?i("editor:editor.image.uploadFailedKeepPrevious"):i("editor:editor.image.uploadFailed"),ee?" (".concat(ee,")"):null]}):null,(0,eI.jsx)(x.A,{sx:{mt:3},children:(0,eI.jsx)(h.A,{container:!0,spacing:3,children:m.map(function(e,t){return(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsxs)(x.A,{onClick:function(t){return eF(e,t)},role:"button","data-testid":"".concat(k,"-chooseThisImage"),sx:eP,children:[(0,eI.jsx)(x.A,{sx:{width:1,height:300,backgroundImage:"url(".concat(e,")"),backgroundSize:"cover",backgroundRepeat:"no-repeat"}}),(0,eI.jsx)(x.A,{className:"project-image-choose",sx:{mb:0,p:1.5,bgcolor:"primary.main",color:"primary.contrastText",textAlign:"center",fontWeight:"bold",mt:5,position:"absolute",width:1,transition:"margin-top 0.1s ease-in-out"},children:i("editor:editor.chooseThisImage")})]})},t)})})})]}):null,"unsplash"===v?(0,eI.jsx)(x.A,{sx:{overflowY:"auto",minHeight:"calc(100vh - 60px)"},children:(0,eI.jsx)(ev.A,{onImageSelect:eH,minHeightOfModal:600})}):null,"cropImage"===v&&R?(0,eI.jsx)(x.A,{sx:{width:"91.666%"},children:(0,eI.jsx)(ef.A,{src:R,onComplete:function(e){e&&e.toBlob(function(e){e&&(e.name=s&&s.split("/")[4],L(e))})},dataTestId:k})}):null]})]})});let eN=(0,m.withTranslation)(["common","editor","project"])(eO);var ez=n(66689),eD=function(e){var t=e.reduce(function(e,t){return t.imageUrl?e.concat(t.imageUrl):e},[]),n=e.reduce(function(e,t){return t.bannerUrl?e.concat(t.bannerUrl):e},[]);return[].concat((0,a.A)(t),(0,a.A)(n))};let eH=(0,o.Ng)(function(e){return{uploading:e.hubPageRevision.uploadingFile,uploadError:e.hubPageRevision.fileUploadError,imageUrl:e.hubPageRevision.uploadedFileUrl,projectImages:eD(e.projects.projects),activeImageTab:e.project.activeImageTab,dataTestId:"admin-hubs-editor-drawers-image-manage"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSite:ea.hj,saveSite:ea.X8,imageSettingsToggler:ez.xd},e)})(eN);var eF=(0,u.memo)(function(e){var t=e.t,n=e.updateSectionData,o=e.logoUrl,i=e.data,r=e.sectionId,a=e.updateSite,s=e.dataTestId,c=i.signInText,l=i.signInUrl,d=i.signUpText,m=i.signUpUrl;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.images.logoImage"),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return a("logoUrl",e)},currentImage:o,sectionId:r,isHeader:!0,imgixUrl:!0,title:t("editor:editor.images.logoImage")})}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:t("editor:editor.signInText"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-signInText"),name:"signInText",value:"Sign in"===c?t("editor:editor.signIn"):c,onChange:function(e){return n("signInText",e.target.value,r)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:t("editor:editor.helpTexts.signInUrl"),placement:"right",children:t("editor:editor.signInUrl")}),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-signInUrl"),name:"signInUrl",value:l,onCh
1ange:function(e){return n("signInUrl",e.target.value,r)}})})})]}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:t("editor:editor.registerText"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-registerText"),name:"signUpText",value:"Register"===d?t("editor:editor.register"):d,onChange:function(e){return n("signUpText",e.target.value,r)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:t("editor:editor.helpTexts.registerUrl"),placement:"right",children:t("editor:editor.registerUrl")}),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-registerUrl"),name:"signUpUrl",value:m,onChange:function(e){return n("signUpUrl",e.target.value,r)}})})})]}),(0,eI.jsx)(el.A,{textVariant:"body2",mb:1.5,children:t("editor:editor.headerDescription")})]})});let eR=(0,m.withTranslation)(["common","editor"])(eF),eE=(0,o.Ng)(function(e,t){return{logoUrl:e.currentSite.site.logoUrl,data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-navigations-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSite:ea.hj,saveSite:ea.X8},e)})(eR);var eU=n(61761),eB=(0,u.memo)(function(e){var t=e.t,n=e.updateSectionTheme,o=e.mainNavbarBackgroundColor,i=e.mainNavbarTextColor,r=e.sectionId,a=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.mainNavbarTextColor"),children:(0,eI.jsx)(eU.A,{color:i,fieldKey:"mainNavbarTextColor",onChange:function(e){return n("mainNavbarTextColor",e,r)},"data-testid":"".concat(a,"-mainNavbarTextColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.mainNavbarBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o,fieldKey:"mainNavbarBackgroundColor",onChange:function(e){return n("mainNavbarBackgroundColor",e,r)},"data-testid":"".concat(a,"-mainNavbarBackgroundColor")})})]})});let eL=(0,m.withTranslation)(["common","editor"])(eB),e_=(0,o.Ng)(function(e,t){return{mainNavbarBackgroundColor:e.hubPageRevision.revision.sections[t.sectionId].theme.mainNavbarBackgroundColor,mainNavbarTextColor:e.hubPageRevision.revision.sections[t.sectionId].theme.mainNavbarTextColor,dataTestId:"admin-hubs-editor-sections-navigations-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(eL);var eW=n(68843),eM=n(38586),eK=n(79837),eY=n(60964);let eV=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.content,o=e.updateFilters,i=e.dataTestId,r=(0,u.useState)(!1),a=r[0],s=r[1];return(0,u.useEffect)(function(){o({state:n})}),(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(em.A,{"data-testid":"".concat(i,"-editLinks"),variant:"contained",color:"primary",onClick:function(){return s(!0)},children:t("editor:editor.editLinks")}),(0,eI.jsxs)(eM.A,{width:"80vw",open:a,closeBarOnly:!0,onClose:function(){s(!1)},contentSx:{mx:0,my:0},slotProps:{root:{keepMounted:!1}},children:[(0,eI.jsx)(eK.A,{content:n}),(0,eI.jsx)(eY.A,{navigation:!0})]})]})});var eq=n(93055);let eQ=(0,o.Ng)(function(){return{dataTestId:"admin-hubs-editor-drawers-nav-links-editor"}},function(e){return(0,i.zH)({updateFilters:eq.v},e)})(eV);var eZ=n(63256);let eG=(0,m.withTranslation)(["editor"])(function(e){var t=e.t;return(0,eI.jsx)(eI.Fragment,{children:(0,eI.jsxs)(ec.A,{children:[(0,eI.jsx)(eZ.A,{label:t("editor:editor.navigationLinks"),sx:{mt:2}}),(0,eI.jsx)(eW.A,{sx:{mb:2.5},children:t("editor:editor.navigationLinksDescription")}),(0,eI.jsx)(eQ,{content:"header"})]})})});var eX=n(59860),e$=n(63065),eJ=n(2708),e0=n(4053),e1=n(46721),e2=n(26555),e3=n(26858),e5=n(10805),e4=n(20267),e9=n(42453),e6=n(68959),e8=n(55643),e7=n(44434),te=n(21014),tt=["title","icon","className","data-testid"];function tn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function to(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?tn(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var ti=(0,u.forwardRef)(function(e,t){var n=e.title,o=e.icon,i=e.className,r=e["data-testid"],a=(0,eX.A)(e,tt);return(0,eI.jsx)(g.A,{title:n,children:(0,eI.jsx)("span",to(to({ref:t,className:i},a),{},{style:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:(0,eI.jsx)(o,{"data-testid":r,sx:{fontSize:20,display:"block",color:"inherit"}})}))})});let tr=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.sectionId,o=e.updateSectionMeta,i=e.hidden,r=e.deleteSection,a=e.textTabPane,s=e.colorTabPane,c=e.fontTabPane,l=e.layoutTabPane,d=e.linksTabPane,m=e.canBeHidden,h=void 0===m||m,p=e.canBeDeleted,g=void 0===p||p,f=e.canBeMovedUp,b=e.canBeMovedDown,j=e.moveSection,v=e.dataTestId,y=(0,u.useState)("details"),A=y[0],C=y[1],T=(0,u.useState)(null),k=T[0],S=T[1],I=function(){return S(null)};return(0,eI.jsxs)(x.A,{children:[(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",borderBottom:1,borderColor:"divider"},children:[(0,eI.jsxs)(ep.A,{value:A,onChange:function(e,t){return C(t)},variant:"scrollable",scrollButtons:"auto",textColor:"inherit",sx:to({flex:1,alignSelf:"stretch",borderBottom:"none"},eA.i),children:[(0,eI.jsx)(eh.A,{value:"details","aria-label":t("editor:editor.content"),icon:(0,eI.jsx)(ti,{title:t("editor:editor.content"),icon:e2.A,"data-testid":"".concat(v,"-content")}),iconPosition:"top"}),(0,eI.jsx)(eh.A,{value:"color","aria-label":t("editor:editor.color"),icon:(0,eI.jsx)(ti,{title:t("editor:editor.color"),icon:e3.A,"data-testid":"".concat(v,"-color")}),iconPosition:"top"}),c&&(0,eI.jsx)(eh.A,{value:"font","aria-label":t("editor:editor.font"),icon:(0,eI.jsx)(ti,{title:t("editor:editor.font"),icon:e5.A,"data-testid":"".concat(v,"-font")}),iconPosition:"top"}),l&&(0,eI.jsx)(eh.A,{value:"layout","aria-label":t("editor:editor.layout"),icon:(0,eI.jsx)(ti,{title:t("editor:editor.layout"),icon:_.A,"data-testid":"".concat(v,"-layout")}),iconPosition:"top"}),d&&(0,eI.jsx)(eh.A,{value:"links","aria-label":t("editor:editor.links"),icon:(0,eI.jsx)(ti,{title:t("editor:editor.links"),icon:e4.A,"data-testid":"".concat(v,"-links")}),iconPosition:"top"})]}),(h||g)&&(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(w.A,{"aria-label":t("common:common.more"),"data-testid":"".concat(v,"-threeDots"),onClick:function(e){return S(e.currentTarget)},size:"medium",sx:{color:"text.primary",ml:.75,flexShrink:0},children:(0,eI.jsx)(e9.A,{sx:{fontSize:25}})}),(0,eI.jsxs)(e$.A,{anchorEl:k,open:!!k,onClose:I,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:[h&&(0,eI.jsxs)(eJ.A,{onClick:function(){o("hidden",!i,n),I()},"data-testid":"".concat(v,"-hideUnhide"),children:[(0,eI.jsx)(e0.A,{children:i?(0,eI.jsx)(e6.A,{fontSize:"small"}):(0,eI.jsx)(eo.A,{fontSize:"small"})}),(0,eI.jsx)(e1.A,{primary:t(i?"editor:editor.unhideThisSection":"editor:editor.hideThisSection")})]}),f&&(0,eI.jsxs)(eJ.A,{onClick:function(){j(n,"before"),I()},"data-testid":"".concat(v,"-moveSectionUp"),children:[(0,eI.jsx)(e0.A,{children:(0,eI.jsx)(e8.A,{fontSize:"small"})}),(0,eI.jsx)(e1.A,{primary:t("editor:editor.moveSectionUp")})]}),b&&(0,eI.jsxs)(eJ.A,{onClick:function(){j(n,"after"),I()},"data-testid":"".concat(v,"-moveSectionDown"),children:[(0,eI.jsx)(e0.A,{children:(0,eI.jsx)(e7.A,{fontSize:"small"})}),(0,eI.jsx)(e1.A,{primary:t("editor:editor.moveSectionDown")})]}),g&&(0,eI.jsxs)(eJ.A,{onClick:function(){r(n),I()},"data-testid":"".concat(v,"-deleteSection"),sx:{color:"error.main"},children:[(0,eI.jsx)(e0.A,{children:(0,eI.jsx)(te.A,{sx:{color:"error.main"}})}),(0,eI.jsx)(e1.A,{primary:t("editor:editor.deleteSection")})]})]})]})]}),(0,eI.jsxs)(x.A,{sx:{pt:2,px:2,pb:2},children:["details"===A&&(0,eI.jsx)(a,{sectionId:n}),"color"===A&&(0,eI.jsx)(s,{sectionId:n}),c&&"font"===A&&(0,eI.jsx)(c,{sectionId:n}),l&&"layout"===A&&(0,eI.jsx)(l,{sectionId:n}),d&&"links"===A&&(0,eI.jsx)(d,{sectionId:n})]})]})}),ta=(0,o.Ng)(function(e,t){var n=e.hubPageRevision.revision.sections,o=t.sectionId;return{hidden:n[t.sectionId].meta.hidden,canBeMovedUp:-1===[0,1,n.length-1].indexOf(o),canBeMovedDown:-1===[0,n.length-2,n.length-1].indexOf(o),dataTestId:"admin-hubs-editor-section-controls"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA,moveSection:er.hB},e)})(tr),ts=function(e){var t=e.sectionId;return(0,eI.jsx)(ta,{textTabPane:eE,colorTabPane:e_,linksTabPane:eG,sectionId:t,hidden:!1,canBeHidden:!1,canBeDeleted:!1})};var tc=n(65013),tl=n.n(tc),td=n(34626),tu=n(1796),tm=n(55700),th=n(79834),tp=n(300),tx=n(9948),tg=n(11695),tf=n(1044);function tb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function tj(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?tb(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tb(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var tv=(0,u.memo)(function(e){var t,n,o,i,r=e.data,a=e.sectionId,s=e.t,c=e.theme,l=e.hubs,d=e.projects,m=e.projectsQuery,p=e.projectsMeta,g=e.fetchingHubs,f=e.isHubEnabled,b=e.isHubAdminEnabled,j=e.fetchHubs,v=e.updateSectionData,y=e.updateSectionTheme,A=e.updateProjectQuery,w=e.updateProjectFilter,C=e.fetchProjects,T=e.resetProjects,k=e.dataTestId,S=b&&f;(0,u.useEffect)(function(){S&&j()},[]),(0,u.useEffect)(function(){(null==r?void 0:r.ctaLinkType)==="signInPage"&&(null==r?void 0:r.ctaLink)!=="/login"&&(null==r?void 0:r.ctaText)!==""&&v("ctaLink","/login",a)},[r]);var I=function(e){switch(v("ctaLinkType",e,a),e){case"signInPage":v("ctaLink","/login",a);break;case"registerPage":v("ctaLink","/register",a);break;case"projects":case"customUrl":case"hubs":v("ctaLink","",a)}},P=function(e){var t=tl()(l,function(t){return t.id===e});v("hubId",t.id,a),v("ctaLink",t.permalink,a),v("title",t.name,a),v("description",t.description,a),v("image",t.imageUrl,a)},O=function(e){v("ctaLink","/".concat(e.permalink),a),v("ctaLinkName",e.name,a)};return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:s("editor:editor.images.bannerImageHelp"),placement:"top",children:s("editor:editor.images.bannerImage")}),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return v("image",e,a)},currentImage:r.image,sectionId:a,title:s("editor:editor.images.bannerImage"),imgFocusEnabled:r.imgFocusEnabled,imgFocusX:r.imgFocalX,imgFocusY:r.imgFocalY})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:(0,eI.jsx)(tg.A,{html:s("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":s("common:common.images.imageAltText"),children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(k,"-imageAltText"),children:s("common:common.images.imageAltText")})}),extra:(null==r||null==(t=r.altText)?void 0:t.length)===125?s("common:common.maxCharactersReached"):void 0,children:(0,eI.jsx)(es.A,{id:"".concat(k,"-imageAltText"),fullWidth:!0,variant:"outlined",name:"bannerAltText",value:r.altText,onChange:function(e){return v("altText",e.target.value,a)},slotProps:{htmlInput:{id:"".concat(k,"-imageAltText"),maxLength:125}},"data-testid":"".concat(k,"-imageAltText"),error:(null==r||null==(n=r.altText)?void 0:n.length)===125})}),(0,eI.jsx)(th.A,{label:s("editor:editor.displayFullBannerImage"),control:(0,eI.jsx)(ey.A,{name:"fullHeight",checked:r.fullHeight,onChange:function(e){v("fullHeight",e,a)},"data-testid":"".concat(k,"-displayFullBannerImage")})}),r.fullHeight&&(0,eI.jsx)(el.A,{textVariant:"body2",mb:3,children:s("editor:editor.helpTexts.fullHeight")}),!r.fullHeight&&(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(ec.A,{sx:{display:"grid",gridTemplateColumns:"1fr auto",alignItems:"center",columnGap:2,"& > :first-of-type":{mb:0},"& > :nth-of-type(2)":{width:"auto"}},label:(0,eI.jsx)(el.A,{tooltip:s("editor:editor.helpTexts.bannerHeight"),placement:"top",children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(k,"-height"),children:s("editor:editor.heightOfBanner")})}),children:(0,eI.jsx)(td.A,{id:"".concat(k,"-height"),type:"number",size:"medium",variant:"outlined",sx:{width:80},value:null!=(o=c.minHeight)?o:"",slotProps:{htmlInput:{id:"".concat(k,"-height"),min:300,max:800,step:50}},onChange:function(e){var t=e.target.value;if(""===t)return void y("minHeight",void 0,a);var n=Number(t);Number.isNaN(n)||y("minHeight",n,a)},onBlur:function(e){var t=e.target.value;if(""!==t){var n=Number(t);if(Number.isNaN(n))return void y("minHeight",void 0,a);var o=Math.min(800,Math.max(300,n));o!==c.minHeight&&y("minHeight",o,a)}},disabled:!(r.title||r.description||r.ctaText),className:"testId-".concat(k,"-height")})}),(0,eI.jsx)(ec.A,{label:s("common:common.title"),children:(0,eI.jsx)(es.A,{fullWidth:!0,variant:"outlined",name:"title",value:r.title,onChange:function(e){return v("title",e.target.value,a)},"data-testid":"".concat(k,"-title")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(x.A,{component:"label",id:"".concat(k,"-description-label"),htmlFor:"".concat(k,"-description"),children:s("common:common.description")}),className:"testId-".concat(k,"-froala"),children:(0,eI.jsx)(tp.A,{id:"".concat(k,"-description"),labelledBy:"".concat(k,"-description-label"),name:"description",value:r.description,onChange:function(e){return v("description",e.target.value,a)},config:(0,tx.J)("HomePageBanner"),dataTestId:"froala-editor-hub-banner-description"})}),(0,eI.jsxs)(x.A,{sx:{display:"grid",width:"100%",gap:3,gridTemplateColumns:"repeat(2, minmax(0, 1fr))"},children:[(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:s("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(k,"-btnText"),children:s("editor:editor.ctaText")})}),children:(0,eI.jsx)(es.A,{id:"".concat(k,"-btnText"),fullWidth:!0,size:"medium",variant:"outlined",name:"ctaText",value:r.ctaText,onChange:function(e){return v("ctaText",e.target.value,a)},slotProps:{htmlInput:{id:"".concat(k,"-btnText")}},"data-testid":"".concat(k,"-btnText")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:s("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:(0,eI.jsx)(x.A,{component:"label",id:"".concat(k,"-btnURL-label"),htmlFor:"".concat(k,"-btnURL"),children:s("editor:editor.ctaLink")})}),children:(0,eI.jsxs)(td.A,{id:"".concat(k,"-btnURL"),select:!0,fullWidth:!0,size:"medium",variant:"outlined",value:r.ctaLinkType,onCh
1ange:function(e){return I(e.target.value)},className:"testId-".concat(k,"-btnURL"),slotProps:{select:{labelId:"".concat(k,"-btnURL-label")}},children:[(0,eI.jsx)(eJ.A,{value:"signInPage",children:s("common:common.signInPage")}),(0,eI.jsx)(eJ.A,{value:"registerPage",children:s("common:common.registerPage")}),(0,eI.jsx)(eJ.A,{value:"projects",children:s("common:common.projects")}),S&&(0,eI.jsx)(eJ.A,{value:"hubs",children:s("common:common.hubs")}),(0,eI.jsx)(eJ.A,{value:"customUrl",children:s("common:common.customURL")})]})})]}),"projects"===r.ctaLinkType&&(0,eI.jsx)(ec.A,{label:s("editor:editor.selectProject"),children:(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(k,"-selectProject"),data:r,options:d,optionLabel:"name",optionValue:"permalink",fetch:C,meta:p,query:m,updateQuery:A,updateFilter:w,reset:T,onSelect:function(e){return O(e)}})}),"hubs"===r.ctaLinkType&&S&&(0,eI.jsx)(ec.A,{label:s("editor:editor.selectHub"),children:(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(k,"-selectHub"),options:l,getOptionLabel:function(e){return e.name},sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,value:null!=(i=l.find(function(e){return e.id===r.hubId}))?i:null,onChange:function(e,t){t&&P(t.id)},disabled:!l.length||g,renderInput:function(e){return(0,eI.jsx)(td.A,tj(tj({},e),{},{size:"medium",placeholder:s("editor:editor.selectHub"),variant:"outlined"}))}})}),"customUrl"===r.ctaLinkType&&(0,eI.jsx)(h.A,{container:!0,spacing:3,sx:{mb:2.5},children:(0,eI.jsx)(h.A,{size:{xs:12,md:12},children:(0,eI.jsx)(es.A,{fullWidth:!0,size:"medium",variant:"outlined",name:"ctaCustomTextUrl",value:r.ctaLink,onChange:function(e){v("ctaLink",e.target.value,a)},"data-testid":"".concat(k,"-ctaCustomTextUrl")})})}),(0,eI.jsx)(th.A,{label:s("editor:editor.openInNewTab"),control:(0,eI.jsx)(ey.A,{name:"openInNewTab",checked:r.openInNewTab,onChange:function(e){return v("openInNewTab",e,a)},"data-testid":"".concat(k,"-openInNewTab")})})]})]})});let ty=(0,m.withTranslation)(["common","editor"])(tv);var tA=n(7073);let tw=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],theme:e.hubPageRevision.revision.sections[t.sectionId].theme,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,hub:e.hub.hub,dataTestId:"admin-hubs-editor-sections-banner-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionTheme:er.oz,updateProjectQuery:tA.oR,updateProjectFilter:tA.vm,resetProjects:tA.r$,fetchProjects:tA.O$},e)})(ty);var tC=n(76159),tT=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId,a=function(e){return function(n){return i(e,n,t)}};return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:a("textColor"),"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:a("ctaBackgroundColor"),"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:a("ctaBackgroundHoverColor"),"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:a("ctaTextColor"),"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:a("ctaTextHoverColor"),"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:a("backgroundColor"),"data-testid":"".concat(r,"-backgroundColor")})}),(0,eI.jsx)(tC.A,{label:n("editor:editor.backgroundColourOpacity"),value:o.bannerOpacity,min:80,max:100,unit:"%",onChange:function(e){return i("bannerOpacity",e,t)},className:"testId-".concat(r,"-backgroundColourOpacity")})]})});let tk=(0,m.withTranslation)(["common","editor"])(tT),tS=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-banner-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(tk);var tI=n(69332);let tP=(0,m.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.titleFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(tC.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,eI.jsx)(tC.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),tO=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-banner-font"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(tP);var tN=n(92449),tz=n(79711),tD=n(64529),tH=n(81347),tF=n(10359),tR=n(68593),tE=n(74692),tU=n(36345),tB="blue.600",tL={display:"block",width:"100%",height:"auto",borderRadius:1};let t_=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(function(e){var t=e.updateSectionTheme,n=e.sectionId,o=e.layout,i=e.layouts,r=e.dataTestId,a=(0,m.useTranslation)("editor").t,s=(0,u.useRef)([]);(0,u.useEffect)(function(){var e=s.current;return function(){e.forEach(clearTimeout)}},[]);var c=function(e){document.getElementById("home-page-view-section-".concat(e))&&document.getElementById("home-page-view-section-".concat(e)).scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})};return(0,eI.jsx)(u.Fragment,{children:i.map(function(e,i){var l=o===e.id;return(0,eI.jsxs)(tE.A,{disableRipple:!0,"aria-pressed":l,"aria-label":"".concat(a("editor:editor.layout")," ").concat(i+1),"data-testid":"".concat(r,"-").concat(e.id),sx:{display:"block",position:"relative",width:"100%",mb:3,p:0,border:1,borderColor:l?tB:"grey.300",borderRadius:1,boxShadow:l?function(e){return e.shadows[2]}:"none",animation:"layoutFadeIn 3s","@keyframes layoutFadeIn":{from:{opacity:0}
1,to:{opacity:1}},"&:last-of-type":{mb:0},"&:hover, &.Mui-focusVisible":{borderColor:tB,boxShadow:function(e){return e.shadows[2]}},"&:hover .layout-check":{opacity:l?1:.6}},onClick:function(){t("layout",e.id,n);var o=setTimeout(function(){c(n)},1e3);s.current.push(o)},children:[(0,eI.jsx)(x.A,{component:"img",src:e.imageUrl,alt:"",sx:tL}),(0,eI.jsx)(x.A,{className:"layout-check",sx:{position:"absolute",top:6,left:6,width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",border:1,borderColor:"common.white",bgcolor:"success.main",color:"common.white",opacity:+!!l},children:(0,eI.jsx)(tU.A,{sx:{fontSize:14}})})]},e.id)})})}),tW=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-banner-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:tN},{id:"two",imageUrl:tz},{id:"three",imageUrl:tD},{id:"four",imageUrl:tH},{id:"five",imageUrl:tF},{id:"six",imageUrl:tR}],sectionId:t})}),tM=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-banner"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:tw,colorTabPane:tS,fontTabPane:tO,layoutTabPane:tW,sectionId:t,hidden:n})});var tK=n(66354),tY=n(75564),tV=n(74679),tq=n(22586),tQ=n(6471),tZ=n(80677),tG=n(37485);function tX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function t$(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tX(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var tJ={width:150,flexShrink:0},t0=(0,u.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.fetchingTools,i=e.fetchingHubs,r=e.deleteSectionData,a=e.fetchProject,s=e.fetchTools,c=e.resetTools,l=e.fetchHubs,d=e.meta,m=e.projects,p=e.projectsQuery,j=e.projectsMeta,v=e.tools,y=e.hubs,A=e.projectTags,w=e.sectionId,C=e.selectedProject,T=e.t,k=e.isHubEnabled,S=e.isHubAdminEnabled,I=e.updateProject,P=e.updateSectionData,O=e.updateSectionMeta,N=e.updateProjectQuery,z=e.updateProjectFilter,D=e.fetchProjects,H=e.resetProjects,F=e.reorderHubpageItems,R=e.hub,E=e.dataTestId,U=S&&k,B=(0,u.useState)(null),L=B[0],_=B[1],W=(0,u.useState)([])[1],M=(0,u.useState)(String(n[0].id)),K=M[0],Y=M[1],V=(0,u.useState)(!1),q=V[0],Q=V[1],Z=(0,u.useState)(!1),G=Z[0],X=Z[1];(0,tG.A)(w,F,n.length,"hub-page-tabs",!d.autoAddProjects),(0,u.useEffect)(function(){null!=R&&R.id&&z({parent_id:R.id})},[null==R?void 0:R.id,z]),(0,u.useEffect)(function(){C.id&&null!==L&&(P("image",C.imageUrl||C.bannerUrl,w,L),P("title",C.name,w,L),P("description",C.description,w,L),P("permalink","/".concat(C.permalink),w,L),P("id",C.id,w,L),P("state",C.state,w,L),P("publishedAt",C.publishedAt,w,L),P("isSiteProject",!0,w,L)),_(null),W(n.map(function(e){return e.id}))},[C,n]),(0,u.useEffect)(function(){"tools"!==n[0].ctaLinkType||q||(I("id",n[0].projectId),s(),Q(!0))},[v]),(0,u.useEffect)(function(){U&&l()},[U,l]);var $=function(e,t){P("ctaLinkType",e,w,t),P("permalink","",w,t),P("id",n[0].id+t,w,t),Y(String(n[0].id+t)),P("image","",w,t),P("title","",w,t),P("description","",w,t),P("ctaLink","",w,t),P("ctaLinkName","",w,t),P("status","",w,t),c()},J=function(e,t){var n=m.filter(function(t){return t.id===e.id});if(n.length>0){var o=n[0].imageUrl,i=n[0].bannerUrl;P("image",o||i,w,t)}I("permalink",e.permalink),I("id",e.id),P("projectId",e.id,w,t),P("image",e.imageUrl,w,t),P("ctaLink","/".concat(e.permalink),w,t),P("ctaLinkName",e.name,w,t),s()},ee=function(e,t){var n=tl()(v,function(t){return t.id===e});n&&(P("toolId",n.id,w,t),P("title",n.name,w,t),P("description",n.description,w,t),P("permalink","SurveyTool"===n.type?n.path.replace("survey_tools","surveys"):n.path,w,t),P("status",n.state,w,t))},et=function(e,t){var n=tl()(y,function(t){return t.id===e});n&&(P("hubId",n.id,w,t),P("permalink",n.permalink,w,t),P("title",n.name,w,t),P("description",n.description,w,t),P("image",n.imageUrl,w,t))},en=function(e,t){Y(String(e.id)),_(t),a(e.id).then(function(){P("ctaLink","/".concat(e.permalink),w,t),P("ctaLinkName",e.name,w,t)})},eo=d.autoAddProjectsTags||[];return(0,eI.jsxs)(x.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,eI.jsx)(ec.A,{label:T("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(E,"-sectionTitle"),name:"title",value:d.title,onChange:function(e){return O("title",e.target.value,w)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:(0,eI.jsx)(el.A,{tooltip:T("editor:editor.helpTexts.displayPublishDate"),placement:"top",children:(0,eI.jsx)(x.A,{component:"span",title:T("editor:editor.displayPublishDate"),children:T("editor:editor.displayPublishDate")})}),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(E,"-displayPublishDate"),name:"showPublishDate",checked:d.showPublishDate,onChange:function(e){return O("showPublishDate",e,w)}})})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:(0,eI.jsx)(el.A,{tooltip:T("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"top",children:(0,eI.jsx)(x.A,{component:"span",title:T("editor:editor.ctaText"),children:T("editor:editor.ctaText")})}),control:(0,eI.jsx)(x.A,{sx:{mr:0},children:(0,eI.jsx)(es.A,{size:"medium",variant:"outlined","data-testid":"".concat(E,"-buttonEmptyCTAText"),name:"ctaText",value:d.ctaText,onChange:function(e){return O("ctaText",e.target.value,w)},sx:tJ})})})}),(0,eI.jsx)(tV.A,{sx:{mt:0}}),(0,eI.jsx)(ec.A,{label:T("editor:editor.helpTexts.projectSelectionMode"),sx:{mt:3},children:(0,eI.jsxs)(b.A,{exclusive:!0,value:d.autoAddProjects?"true":"false",onChange:function(e,t){null!=t&&O("autoAddProjects","true"===t,w)},size:"medium",className:"testId-".concat(E,"-projectSelectionMode"),children:[(0,eI.jsx)(f.A,{value:"true","data-testid":"".concat(E,"-autoSelect"),children:T("editor:editor.autoSelect")}),(0,eI.jsx)(f.A,{value:"false","data-testid":"".concat(E,"-manualSelect"),children:T("editor:editor.manualSelect")})]})}),d.autoAddProjects?(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:T("editor:editor.selectProjectTags"),children:(0,eI.jsx)(td.A,{select:!0,fullWidth:!0,size:"medium",variant:"outlined",className:"testId-".concat(E,"-selectProjectTags"),placeholder:T("editor:editor.selectProjectTags"),value:eo,onChange:function(e){return O("autoAddProjectsTags",e.target.value,w)},slotProps:{select:{multiple:!0,displayEmpty:!0,renderValue:function(e){var t=new Set(("string"==typeof e?[e]:e).map(function(e){return String(e)})),n=A.filter(function(e){return t.has(String(e.id))}).map(function(e){return e.name});return n.length?n.join(", "):""}}},children:A.map(function(e){return(0,eI.jsx)(eJ.A,{value:e.id,children:e.name},e.id)})})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:(0,eI.jsx)(x.A,{component:"span",title:T("editor:editor.showProjectStatus"),children:T("editor:editor.showProjectStatus")}),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(E,"-showProjectStatus"),name:"showProjectStatus",checked:d.showProjectStatus,onChange:function(e){return O("showProjectStatus",e,
1w)}})})}),(0,eI.jsx)(ec.A,{label:T("editor:editor.filterByProjectStatus"),children:(0,eI.jsxs)(b.A,{exclusive:!0,value:d.autoAddProjectsStatus,onChange:function(e,t){null!=t&&O("autoAddProjectsStatus",t,w)},size:"medium",className:"testId-".concat(E,"-filterByProjectStatus"),children:[(0,eI.jsx)(f.A,{value:"all","data-testid":"".concat(E,"-all"),children:T("common:common.all")}),(0,eI.jsx)(f.A,{value:"published","data-testid":"".concat(E,"-published"),children:T("common:common.published")}),(0,eI.jsx)(f.A,{value:"archived","data-testid":"".concat(E,"-archived"),children:T("common:common.archived")})]})}),(0,eI.jsx)(ec.A,{label:T("editor:editor.orderProjectsBy"),children:(0,eI.jsxs)(b.A,{exclusive:!0,value:d.autoAddProjectsOrder,onChange:function(e,t){null!=t&&O("autoAddProjectsOrder",t,w)},size:"medium",className:"testId-".concat(E,"-orderProjectsBy"),children:[(0,eI.jsx)(f.A,{value:"datePublished","data-testid":"".concat(E,"-datePublished"),children:T("common:common.datePublished")}),(0,eI.jsx)(f.A,{value:"name","data-testid":"".concat(E,"-title"),children:T("common:common.title")})]})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:(0,eI.jsx)(x.A,{component:"span",title:T("editor:editor.numberOfProjectsToDisplay"),children:T("editor:editor.numberOfProjectsToDisplay")}),control:(0,eI.jsx)(td.A,{type:"number",size:"medium",className:"testId-".concat(E,"-numberOfProjectsToDisplay"),style:{width:60},value:d.autoAddProjectsLimit,slotProps:{htmlInput:{min:1}},onChange:function(e){var t=e.target.value;if(""!==t){var n=Number(t);Number.isNaN(n)||n<1||n!==d.autoAddProjectsLimit&&O("autoAddProjectsLimit",n,w)}}})})})]}):(0,eI.jsxs)(x.A,{children:[(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(w),value:K,onChange:function(e,t){Y(t);var o=n.filter(function(e){return String(e.id)===String(t)});o.length>0&&"tools"===o[0].ctaLinkType&&(I("id",o[0].projectId),s())},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(E,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(T("editor:editor.project")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(tQ.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:T("editor:editor.addNewProject"),children:(0,eI.jsx)(em.A,{variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(w,e),Y(String(e))},"data-testid":"".concat(E,"-addNewProject"),children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){var a,s;return String(e.id)===K?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsxs)(h.A,{container:!0,spacing:3,sx:{mb:1.25},children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(E,"-cardType-").concat(e.id),sx:{display:"block",typography:"body1",color:"text.primary"},children:T("editor:editor.cardType")})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsxs)(td.A,{id:"".concat(E,"-cardType-").concat(e.id),select:!0,fullWidth:!0,size:"medium",variant:"outlined",placeholder:T("common:common.select"),className:"testId-".concat(E,"-cardType"),value:e.ctaLinkType,onChange:function(e){return $(e.target.value,t)},slotProps:{select:{displayEmpty:!0}},children:[(0,eI.jsx)(eJ.A,{value:"projects",children:T("common:common.projects")}),(0,eI.jsx)(eJ.A,{value:"tools",children:T("common:common.tools")}),U&&(0,eI.jsx)(eJ.A,{value:"hubs",children:T("common:common.hubs")}),(0,eI.jsx)(eJ.A,{value:"customUrl",children:T("common:common.customURL")})]})})]}),"projects"===e.ctaLinkType&&(0,eI.jsx)(ec.A,{label:T("editor:editor.selectProject"),children:(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(E,"-selectProject"),data:e,options:m,optionLabel:"name",optionValue:"id",fetch:D,meta:j,query:p,updateQuery:N,updateFilter:z,reset:H,onSelect:function(e){return en(e,t)}})}),"tools"===e.ctaLinkType&&(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(ec.A,{label:T("editor:editor.selectProject"),children:(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(E,"-selectProjectTools"),data:e,options:m,optionLabel:"name",optionValue:"id",fetch:D,meta:j,query:p,updateQuery:N,updateFilter:z,reset:H,onSelect:function(e){return J(e,t)}})}),(0,eI.jsx)(ec.A,{label:T("editor:editor.selectTool"),children:(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(E,"-selectTool"),options:v,getOptionLabel:function(e){return e.name},sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,value:null!=(a=v.find(function(t){return t.id===e.toolId}
1))?a:null,onChange:function(e,n){n&&ee(n.id,t)},disabled:!v.length||o,renderInput:function(e){return(0,eI.jsx)(td.A,t$(t$({},e),{},{placeholder:T("editor:editor.selectTool"),size:"medium",variant:"outlined"}))}})})]}),"hubs"===e.ctaLinkType&&U&&(0,eI.jsx)(ec.A,{label:T("editor:editor.selectHub"),children:(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(E,"-selectHub"),options:y,getOptionLabel:function(e){return e.name},sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,isOptionEqualToValue:function(e,t){return(null==e?void 0:e.id)===(null==t?void 0:t.id)},value:null!=(s=y.find(function(t){return t.id===e.hubId}))?s:null,onChange:function(e,n){n&&et(n.id,t)},disabled:!y.length||i,renderInput:function(e){return(0,eI.jsx)(td.A,t$(t$({},e),{},{placeholder:T("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}})}),"customUrl"===e.ctaLinkType&&(0,eI.jsx)(ec.A,{sx:{mb:0},children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(E,"-customUrl"),name:"ctaCustomTextUrl",value:e.permalink,placeholder:"https://",onChange:function(e){P("permalink",e.target.value,w,t)}})}),(0,eI.jsx)(ec.A,{sx:{mt:1.25},label:(0,eI.jsx)(el.A,{tooltip:T("editor:editor.projectImageTooltip"),placement:"top",children:T("editor:editor.images.projectImage")}),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return P("image",e,w,t)},currentImage:e.image,sectionId:w,tabKey:t,title:T("editor:editor.images.projectImage"),imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY,isProject:G})}),(0,eI.jsx)(ec.A,{label:T("common:common.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(E,"-title"),name:"title",value:e.title,onChange:function(e){return P("title",e.target.value,w,t)}})}),(0,eI.jsx)(ec.A,{label:T("common:common.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(E,"-description"),name:"description",value:(0,tZ.A)(e.description),onChange:function(e){return P("description",e.target.value,w,t)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:T("editor:editor.openInNewTab"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(E,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return P("openInNewTab",e,w,t)}})})}),(0,eI.jsx)(ec.A,{extra:1===n.length?T("editor:editor.helpTexts.needAtleastOneProject"):void 0,children:(0,eI.jsx)(em.A,{variant:"contained",color:"error",onClick:function(){0===t?Y(String(n[t+1].id)):Y(String(n[t-1].id)),X(!0),r(w,t)},disabled:1===n.length,"data-testid":"".concat(E,"-deleteProject"),children:T("editor:editor.deleteProject")})})]},e.id):null})]})]})});let t1=(0,m.withTranslation)(["common"])(t0),t2=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,tools:e.tools.tools,selectedProject:e.project.project,projectTags:e.projectTags.tags,fetchingTools:e.tools.fetching,fetchingHubs:e.hubs.fetching,hubs:e.hubs.hubs,isHubEnabled:e.features.features.hasOwnProperty("self_service_hubs")&&e.features.features.self_service_hubs.enabled,isHubAdminEnabled:e.features.features.hasOwnProperty("hub_admin")&&e.features.features.hub_admin.enabled,hub:e.hub.hub,dataTestId:"admin-hubs-editor-sections-projects-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,fetchProject:ez.Sw,fetchTools:tK.W,fetchHubs:tY.R5,resetTools:tK.L,updateProject:ez.vr,updateProjectQuery:tA.oR,updateProjectFilter:tA.vm,fetchProjects:tA.O$,resetProjects:tA.r$,reorderHubpageItems:er.Kc},e)})(t1);var t3={styles:(0,eI.jsx)(c(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"}
1,t5=(t3.className,t3.styles),t4=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),t5]})});let t9=(0,m.withTranslation)(["common","editor"])(t4),t6=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-projects-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(t9);var t8=n(96757),t7=n(23587),ne=n(13685),nt=n(98943),nn=n(21171),no=n(27917),ni=n(64790),nr=n(42436),na=n(65824),ns=n(7648),nc=n(38364);let nl=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:t8},{id:"two",imageUrl:t7},{id:"three",imageUrl:ne},{id:"four",imageUrl:nt},{id:"five",imageUrl:nn},{id:"six",imageUrl:no},{id:"seven",imageUrl:ni},{id:"eight",imageUrl:nr},{id:"nine",imageUrl:na},{id:"ten",imageUrl:ns},{id:"eleven",imageUrl:nc}],sectionId:t})}),nd=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-projects-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(nl),nu=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-projects"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:t2,colorTabPane:t6,layoutTabPane:nd,sectionId:t,hidden:n})});function nm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function nh(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nm(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nm(Object(n)).forEac
1h(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var np={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},nx=np.className,ng=np.styles,nf=(0,u.memo)(function(e){var t,n,o=e.data,i=e.fetchTools,r=e.fetchingTools,a=e.fetchingHubs,s=e.meta,c=(e.project,e.projects),l=e.projectsQuery,d=e.projectsMeta,m=e.resetTools,p=e.sectionId,g=e.t,j=e.tools,v=e.hubs,y=e.fetchHubs,A=e.updateProject,w=e.isHubAdminEnabled,C=e.isHubEnabled,T=e.updateSectionMeta,k=e.updateSectionData,S=e.updateProjectQuery,I=e.updateProjectFilter,P=e.fetchProjects,O=e.resetProjects,N=e.dataTestId,z=(0,u.useState)(!1),D=z[0],H=z[1],F=w&&C;(0,u.useEffect)(function(){C&&w&&y()},[C,w,y]),(0,u.useEffect)(function(){"tool"!==s.contentType||D||(A("id",o.projectId),i(),H(!0))},[j]);var R=function(e){T("contentType",e,p),k("image","",p),k("title","",p),k("description","",p),k("id","",p),k("ctaLink","",p),k("ctaLinkName","",p),k("status","",p),k("hubId","",p),k("projectId","",p),"project"===e?k("ctaText",g("editor:editor.viewProject"),p):k("ctaText",g("editor:editor.viewTool"),p),m()},E=function(e){A("permalink",e.permalink),A("id",e.id),k("projectId",e.id,p),k("image",e.imageUrl,p),k("ctaLink","/".concat(e.permalink),p),k("ctaLinkName",e.name,p),i()},U=function(e){var t=tl()(j,function(t){return t.id===e});t&&(k("title",t.name,p),k("description",t.description,p),k("id",t.id,p),k("ctaLink","SurveyTool"===t.type?t.path.replace("survey_tools","surveys"):t.path,p),k("status",t.state,p))},B=function(e){var t=tl()(v,function(t){return t.id===e});k("hubId",t.id,p),k("ctaLink",t.permalink,p),k("title",t.name,p),k("description",t.description,p),k("image",t.imageUrl,p)},L=function(e){k("image",e.imageUrl,p),k("title",e.name,p),k("description",e.description,p),k("ctaLink","/".concat(e.permalink),p),k("ctaLinkName",e.name,p),k("id",e.id,p),k("status",e.state,p)},_=null!=(t=j.find(function(e){return e.id===o.id}))?t:null;return(0,eI.jsxs)("div",{className:"".concat(nx," items"),children:[(0,eI.jsx)(ec.A,{label:g("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-sectionTitle"),name:"title",value:s.title,onChange:function(e){return T("title",e.target.value,p)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:2,sx:{justifyContent:"space-between"},children:[(0,eI.jsx)(h.A,{size:{xs:12,md:10},children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(N,"-showProjectStatus"),sx:{display:"block",cursor:"default"},title:g("editor:editor.showProjectStatus"),children:g("editor:editor.showProjectStatus")})}),(0,eI.jsx)(h.A,{size:{xs:12,md:2},children:(0,eI.jsx)(ey.A,{id:"".concat(N,"-showProjectStatus"),"data-testid":"".concat(N,"-showProjectStatus"),name:"showCardStatus",checked:s.showCardStatus,onChange:function(e){return T("showCardStatus",e,p)},inputProps:{"aria-label":g("editor:editor.showProjectStatus")}})})]})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:2,sx:{justifyContent:"space-between"},children:[(0,eI.jsx)(h.A,{size:{xs:12,md:10},children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(N,"-showCtabutton"),sx:{display:"block",cursor:"default"},title:g("editor:editor.showCtabutton"),children:g("editor:editor.showCtabutton")})}),(0,eI.jsx)(h.A,{size:{xs:12,md:2},children:(0,eI.jsx)(ey.A,{id:"".concat(N,"-showCtabutton"),"data-testid":"".concat(N,"-showCtabutton"),name:"showCtabutton",checked:s.showCtabutton,onChange:function(e){return T("showCtabutton",e,p)},inputProps:{"aria-label":g("editor:editor.showCtabutton")}})})]})}),(0,eI.jsx)(ec.A,{label:g("editor:editor.selectContentType"),children:(0,eI.jsxs)(b.A,{exclusive:!0,value:s.contentType,onChange:function(e,t){null!=t&&R(t)},size:"medium",className:"testId-".concat(N,"-selectContentType"),children:[(0,eI.jsx)(f.A,{value:"project","data-testid":"".concat(N,"-project"),children:g("editor:editor.project")}),(0,eI.jsx)(f.A,{value:"tool","data-testid":"".concat(N,"-tool"),children:g("editor:editor.tool")}),F&&(0,eI.jsx)(f.A,{value:"hubs","data-testid":"".concat(N,"-hub"),children:g("common:common.hub")})]})}),(0,eI.jsxs)(ec.A,{label:g("editor:editor.selectContent"),children:["tool"===s.contentType&&(0,eI.jsxs)(x.A,{sx:{display:"flex",flexDirection:"column",gap:1.5,width:"100%"},children:[(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(N,"-selectProjectTool"),data:o,options:c,optionLabel:"name",optionValue:"id",fetch:P,meta:d,query:l,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return E(e)}},"with-tool"),(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(N,"-selectTool"),options:j,getOptionLabel:function(e){return e.name}
1,sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,value:_,onChange:function(e,t){t&&U(t.id)},disabled:!j.length||r,renderInput:function(e){return(0,eI.jsx)(td.A,nh(nh({},e),{},{placeholder:g("editor:editor.selectTool"),size:"medium",variant:"outlined"}))}})]}),"hubs"===s.contentType&&F&&(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(N,"-selectHub"),options:v,getOptionLabel:function(e){return e.name},sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,value:null!=(n=v.find(function(e){return e.id===o.hubId}))?n:null,onChange:function(e,t){t&&B(t.id)},disabled:!v.length||a,renderInput:function(e){return(0,eI.jsx)(td.A,nh(nh({},e),{},{placeholder:g("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}}),"project"===s.contentType&&(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(N,"-selectProject"),data:o,options:c,optionLabel:"name",optionValue:"id",fetch:P,meta:d,query:l,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return L(e)}},"without-tool")]}),(0,eI.jsx)(ec.A,{label:"project"===s.contentType?(0,eI.jsx)(el.A,{tooltip:g("editor:editor.images.projectImageHelp"),placement:"top",children:g("editor:editor.images.projectImage")}):g("editor:editor.images.image"),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return k("image",e,p)},currentImage:o.image,sectionId:p,title:g("editor:editor.images.projectImage"),imgFocusEnabled:o.imgFocusEnabled,imgFocusX:o.imgFocalX,imgFocusY:o.imgFocalY})}),(0,eI.jsx)(ec.A,{label:g("common:common.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-title"),name:"title",value:o.title,onChange:function(e){return k("title",e.target.value,p)}})}),(0,eI.jsx)(ec.A,{label:g("common:common.description"),children:(0,eI.jsx)(tp.A,{name:"description",value:o.description,onChange:function(e){return k("description",e.target.value,p)},config:(0,tx.J)("HomePageFeatured"),dataTestId:"froala-editor-hub-featured-description"})}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:g("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:g("editor:editor.ctaText")}),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-ctaText"),name:"ctaText",value:o.ctaText,onChange:function(e){return k("ctaText",e.target.value,p)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:g("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:g("editor:editor.ctaLink")}),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-ctaLink"),name:"ctaLink",value:o.ctaLink,onChange:function(e){return k("ctaLink",e.target.value,p)}})})})]}),ng]})});let nb=(0,m.withTranslation)(["common"])(nf),nj=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],meta:e.hubPageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,project:e.project.project,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,hub:e.hub.hub,tools:e.tools.tools,fetchingTools:e.tools.fetching,dataTestId:"admin-hubs-editor-sections-featured-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,fetchTools:tK.W,resetTools:tK.L,updateProject:ez.vr,updateProjectQuery:tA.oR,updateProjectFilter:tA.vm,resetProjects:tA.r$,fetchProjects:tA.O$},e)})(nb);var nv={styles:(0,eI.jsx)(c(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"},ny=(nv.className,nv.styles),nA=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroun
1dColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),ny]})});let nw=(0,m.withTranslation)(["common","editor"])(nA),nC=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-featured-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(nw);var nT=n(18905),nk=n(89671),nS=n(2649);let nI=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:nT},{id:"two",imageUrl:nk},{id:"three",imageUrl:nS}],sectionId:t})}),nP=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-featured-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(nI),nO=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-featured"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:nj,colorTabPane:nC,layoutTabPane:nP,sectionId:t,hidden:n})});var nN=(0,u.memo)(function(e){var t,n,o=e.data,i=e.t,r=e.sectionId,a=e.updateSectionData,s=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:i("editor:editor.images.bannerImage"),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return a("image",e,r)},currentImage:o.image,sectionId:r,title:i("editor:editor.images.bannerImage"),imgFocusEnabled:o.imgFocusEnabled,imgFocusX:o.imgFocalX,imgFocusY:o.imgFocalY})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:(0,eI.jsx)(tg.A,{html:i("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":i("common:common.images.imageAltText"),children:i("common:common.images.imageAltText")}),extra:(null==o||null==(t=o.altText)?void 0:t.length)===125?i("common:common.maxCharactersReached"):void 0,children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-imageAltText"),name:"registerBannerAltText",value:o.altText,onChange:function(e){return a("altText",e.target.value,r)},slotProps:{htmlInput:{maxLength:125}},error:(null==o||null==(n=o.altText)?void 0:n.length)===125})}),(0,eI.jsx)(ec.A,{label:i("editor:editor.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-title"),name:"title",value:o.title,onChange:function(e){return a("title",e.target.value,r)}})}),(0,eI.jsx)(ec.A,{label:i("editor:editor.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-description"),name:"description",value:o.description,onChange:function(e){return a("description",e.target.value,r)}})}),(0,eI.jsxs)(ec.A,{label:i("editor:editor.buttonText"),children:[(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-ctaText"),name:"ctaText",value:o.ctaText,onChange:function(e){return a("ctaText",e.target.value,r)}}),(0,eI.jsx)(el.A,{textVariant:"body2",mt:.5,mb:1.5,children:i("editor:editor.registerBannerButtonDescription")})]})]})});let nz=(0,m.withTranslation)(["common","editor"])(nN),nD=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-registerwidget-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(nz);var nH=n(92592),nF={styles:(0,eI.jsx)(c(),{id:"1759500438",children:[".color-preview-container.jsx-1759500438{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-1759500438{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-1759500438:hover{cursor:pointer;}",".style-title.jsx-1759500438{margin-right:5px;display:inline-block;margin-top:5px;}",".slider-value.jsx-1759500438{margin-right:10px;float:right;margin-top:5px;}",".color-description.jsx-1759500438{color:#8c8c8c;margin:0px;font-size:12px;line-height:20px;margin-bottom:12px;}"]}),className:"jsx-1759500438"},nR=nF.className,nE=nF.styles,nU=(0,u.memo)(function(e){var t=e.t,n=e.sectionId,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,n)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:t("editor:editor.helpTexts.ctaBackgroun
1dColor"),placement:"right",children:t("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,n)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,n)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,n)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,n)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,n)},"data-testid":"".concat(r,"-backgroundColor")})}),(0,eI.jsxs)("div",{children:[(0,eI.jsxs)("div",{children:[(0,eI.jsx)("span",{className:"".concat(nR," style-title"),children:t("editor:editor.backgroundColourOpacity")}),(0,eI.jsxs)("span",{className:"".concat(nR," slider-value"),children:[o.bannerOpacity,"%"]})]}),(0,eI.jsx)(nH.Ay,{className:"testId-".concat(r,"-backgroundColourOpacity"),value:o.bannerOpacity,max:100,min:80,onChange:function(e,t){return i("bannerOpacity",t,n)}})]}),nE]})});let nB=(0,m.withTranslation)(["common","editor"])(nU),nL=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-registerwidget-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(nB),n_=(0,m.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.titleFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(tC.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,eI.jsx)(tC.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),nW=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-registerwidget-tabs-font"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(n_);var nM=n(11227),nK=n(74385),nY=n(71999);let nV=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:nM},{id:"two",imageUrl:nK},{id:"three",imageUrl:nY}],sectionId:t})}),nq=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-registerwidget-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(nV),nQ=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-registerwidget"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:nD,colorTabPane:nL,fontTabPane:nW,layoutTabPane:nq,sectionId:t,hidden:n})});var nZ=n(33713),nG=n(53045);function nX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function n$(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?nX(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var nJ={styles:(0,eI.jsx)(c(),{id:"3375603841",children:[".items.jsx-3375603841{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".style-title.jsx-3375603841{margin-right:5px;display:inline-block;margin-top:20px;}",".slider-value.jsx-3375603841{margin-right:10px;float:right;margin-top:20px;}",".button-url-row.jsx-3375603841{margin-bottom:20px;}"]}),className:"jsx-3375603841"},n0=nJ.className,n1=nJ.styles,n2=(0,u.memo)(function(e){var t,n,o,i,r=e.addSectionData,a=e.data,s=e.deleteSectionData,c=e.meta,l=e.sectionId,d=e.t,m=e.theme,p=e.hubs,f=e.projects,b=e.projectsQuery,j=e.projectsMeta,v=e.isHubEnabled,y=e.isHubAdminEnabled,A=e.fetchHubs,w=e.fetchingHubs,C=e.updateSectionMeta,T=e.updateSectionData,k=e.updateSectionTheme,S=e.updateProjectQuery,I=e.updateProjectFilter,P=e.fetchProjects,O=e.resetProjects,N=e.reorderHubpageItems,z=e.dataTestId,D=y&&v,H=a&&a[0]&&a[0].id||0,F=(0,u.useState)(String(H)),R=F[0],E=F[1],U=(0,u.useState)(),B=U[0],L=U[1];(0,tG.A)(l,N,a.length,"hub-page-tabs"),(0,u.useEffect)(function(){D&&A()},[D,A]);var W=function(e,t){switch(T("ctaLinkType",e,l,t),e){case"signInPage":T("ctaLink","/login",l,t);break;case"registerPage":T("ctaLink","/register",l,t);break;case"projects":case"customUrl":case"hubs":T("ctaLink","",l,t)}},M=function(e,t){var n=tl()(p,function(t){return t.id===e});T("hubId",n.id,l,t),T("ctaLink",n.permalink,l,t),T("title",n.name,l,t),T("description",n.description,l,t),T("image",n.imageUrl,l,t)},K=function(e,t){T("ctaLink","/".concat(e.permalink),l,t),T("ctaLinkName",e.name,l,t)};return(0,eI.jsxs)("div",{className:"".concat(n0," items"),children:[(0,eI.jsx)(ec.A,{label:d("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-sectionTitle"),name:"title",value:null!=(t=c.title)?t:"",onChange:function(e){return C("title",e.target.value,l)}})}),(0,eI.jsxs)("div",{children:[(0,eI.jsxs)("div",{children:[(0,eI.jsx)(nG.A,{className:"".concat(n0," style-title"),children:d("editor:editor.sliderSpeed")}),(0,eI.jsxs)("span",{className:"".concat(n0," slider-value"),children:[(m.autoplaySpeed||7e3)/1e3," ",d("editor:editor.seconds")]})]}),(0,eI.jsx)(nH.Ay,{className:"testId-".concat(z,"-sliderSpeed"),value:(m.autoplaySpeed||7e3)/1e3,max:10,min:2,onChange:function(e,t){return k("autoplaySpeed",1e3*t,l)}})]}),(0,eI.jsx)(ec.A,{label:d("editor:editor.heightOfSlide"),children:(0,eI.jsx)(td.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-heightOfSlide"),value:null!=(n=m.minHeight)?n:"",slotProps:{htmlInput:{min:400,max:800,step:50}},onChange:function(e){var t=e.target.value;if(""===t)return void k("minHeight",void 0,l);var n=Number(t);Number.isNaN(n)||k("minHeight",n,l)},onBlur:function(e){var t=e.target.value;if(""!==t){var n=Number(t);if(Number.isNaN(n))return void k("minHeight",void 0,l);var o=Math.min(800,Math.max(400,n));o!==m.minHeight&&k("minHeight",o,l)}}})}),(0,eI.jsxs)(nZ.A,{direction:"row",spacing:1.25,sx:{mb:2,alignItems:"flex-end"},children:[(0,eI.jsx)(ec.A,{label:d("editor:editor.helpTexts.titleTruncate"),sx:{flex:1,minWidth:0,mb:0},children:(0,eI.jsx)(td.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-titleTruncate"),value:null!=(o=m.titleLength)?o:"",slotProps:{htmlInput:{min:0,step:10}},onChange:function(e){return k("titleLength",""===e.target.value?void 0:Number(e.target.value),l)},onBlur:function(e){""===e.target.value&&k("titleLength",50,l)}})}),(0,eI.jsx)(ec.A,{label:d("editor:editor.helpTexts.descriptionTruncate"),sx:{flex:1,minWidth:0,mb:0},children:(0,eI.jsx)(td.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-descriptionTruncate"),value:null!=(i=m.descriptionLength)?i:"",slotProps:{htmlInput:{min:0,step:10}
1},onChange:function(e){return k("descriptionLength",""===e.target.value?void 0:Number(e.target.value),l)},onBlur:function(e){""===e.target.value&&k("descriptionLength",90,l)}})})]}),(0,eI.jsx)(el.A,{textVariant:"body2",mt:.5,mb:3,children:d("editor:editor.helpTexts.truncate")}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(l),value:R,onChange:function(e,t){return E(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:a&&a.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(z,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(d("editor:editor.slide")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(_.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:d("editor:editor.addNewSlide"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(z,"-addNewSlide"),variant:"text",onClick:function(){var e=crypto.getRandomValues(new Uint32Array(1))[0]%1e4;r(l,e),E(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),a&&a.map(function(e,t){var n,o,i;return String(e.id)===R?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{label:d("editor:editor.images.sliderImage"),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return T("image",e,l,t)},currentImage:e.image,sectionId:l,tabKey:t,title:d("editor:editor.images.sliderImage"),imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY,deleteKey:B})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:(0,eI.jsx)(tg.A,{html:d("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":d("common:common.images.imageAltText"),children:d("common:common.images.imageAltText")}),extra:(null==e||null==(n=e.altText)?void 0:n.length)===125?d("common:common.maxCharactersReached"):void 0,children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-imageAltText"),name:"sliderAltText",value:e.altText,onChange:function(e){return T("altText",e.target.value,l,t)},slotProps:{htmlInput:{maxLength:125}},error:(null==e||null==(o=e.altText)?void 0:o.length)===125})}),(0,eI.jsx)(ec.A,{label:d("common:common.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-title"),name:"title",value:e.title,onChange:function(e){return T("title",e.target.value,l,t)}})}),(0,eI.jsx)(ec.A,{label:d("common:common.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-description"),name:"description",value:e.description,onChange:function(e){return T("description",e.target.value,l,t)}})}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:d("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:d("editor:editor.ctaText")}),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-ctaText"),name:"ctaText",value:e.ctaText,onChange:function(e){return T("ctaText",e.target.value,l,t)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:d("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:d("editor:editor.ctaLink")}),children:(0,eI.jsxs)(td.A,{select:!0,fullWidth:!0,size:"medium",variant:"outlined",className:"testId-".concat(z,"-ctaLink"),value:e.ctaLinkType,onChange:function(e){return W(e.target.value,t)},slotProps:{select:{displayEmpty:!0}},children:[(0,eI.jsx)(eJ.A,{value:"signInPage",children:d("common:common.signInPage")}),(0,eI.jsx)(eJ.A,{value:"registerPage",children:d("common:common.registerPage")}),(0,eI.jsx)(eJ.A,{value:"projects",children:d("common:common.projects")}),D&&(0,eI.jsx)(eJ.A,{value:"hubs",children:d("common:common.hubs")}),(0,eI.jsx)(eJ.A,{value:"customUrl",children:d("common:common.customURL")})]})})})]}),"projects"===e.ctaLinkType&&(0,eI.jsx)(ec.A,{label:d("editor:editor.selectProject"),children:(0,eI.jsx)(tf.A,{size:"medium",className:"testId-".concat(z,"-selectProject"),data:e,options:f,optionLabel:"name",optionValue:"permalink",fetch:P,meta:j,query:b,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return K(e,t)}})}),"hubs"===e.ctaLinkType&&D&&(0,eI.jsx)(ec.A,{label:d("editor:editor.selectHub"),children:(0,eI.jsx)(tu.A,{size:"medium",className:"testId-".concat(z,"-selectHub"),options:p,getOptionLabel:function(e){return e.name},sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,value:null!=(i=p.find(function(t){return t.id===e.hubId}
1))?i:null,onChange:function(e,n){n&&M(n.id,t)},disabled:!p.length||w,renderInput:function(e){return(0,eI.jsx)(td.A,n$(n$({},e),{},{placeholder:d("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}})}),"customUrl"===e.ctaLinkType&&(0,eI.jsx)(h.A,{container:!0,spacing:3,className:"".concat(n0," button-url-row"),children:(0,eI.jsx)(h.A,{size:{xs:12,md:12},children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-customUrl"),name:"ctaCustomTextUrl",value:e.ctaLink,onChange:function(e){T("ctaLink",e.target.value,l,t)}})})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:d("editor:editor.openInNewTab"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(z,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return T("openInNewTab",e,l,t)}})})}),(0,eI.jsx)(ec.A,{extra:1===a.length?d("editor:editor.helpTexts.needAtleastOneSlide"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(z,"-deleteSlide"),variant:"contained",color:"error",onClick:function(){0===t?(E(String(a[t+1].id)),L()):(E(String(a[t-1].id)),L(t)),s(l,t)},disabled:1===a.length,children:d("editor:editor.deleteSlide")})})]},e.id):null}),n1]})});let n3=(0,m.withTranslation)(["common","editor"])(n2),n5=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,theme:e.hubPageRevision.revision.sections[t.sectionId].theme,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,dataTestId:"admin-hubs-editor-sections-carousal-tabs-text"}},function(e){return(0,i.zH)((0,E.default)((0,E.default)((0,E.default)((0,E.default)((0,E.default)((0,E.default)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,updateSectionTheme:er.oz},"updateSectionTheme",er.oz),"updateProjectQuery",tA.oR),"updateProjectFilter",tA.vm),"fetchProjects",tA.s5),"resetProjects",tA.r$),"reorderHubpageItems",er.Kc),e)})(n3);var n4={styles:(0,eI.jsx)(c(),{id:"541989964",children:[".color-preview-container.jsx-541989964{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-541989964{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-541989964:hover{cursor:pointer;}",".style-title.jsx-541989964{margin-right:5px;display:inline-block;margin-top:5px;}",".slider-value.jsx-541989964{margin-right:10px;float:right;margin-top:5px;}"]}),className:"jsx-541989964"},n9=n4.className,n6=n4.styles,n8=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}
1),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),(0,eI.jsxs)("div",{children:[(0,eI.jsxs)("div",{children:[(0,eI.jsx)("span",{className:"".concat(n9," style-title"),children:n("editor:editor.backgroundColourOpacity")}),(0,eI.jsxs)("span",{className:"".concat(n9," slider-value"),children:[o.cardOpacity,"%"]})]}),(0,eI.jsx)(nH.Ay,{className:"testId-".concat(r,"-backgroundColourOpacity"),value:o.cardOpacity,max:100,min:80,onChange:function(e,n){return i("cardOpacity",n,t)}})]}),n6]})});let n7=(0,m.withTranslation)(["common","editor"])(n8),oe=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-carousal-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(n7),ot=(0,m.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.titleFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,tI.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,eI.jsx)(eJ.A,{value:100,children:n("editor:editor.fonts.light")}),(0,eI.jsx)(eJ.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,eI.jsx)(eJ.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,eI.jsx)(tC.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,eI.jsx)(tC.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),on=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-carousal-tabs-font"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ot);var oo=n(38597),oi=n(13939),or=n(30341);let oa=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:oo},{id:"two",imageUrl:oi},{id:"three",imageUrl:or}],sectionId:t})}),os=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-carousal-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(oa),oc=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-carousal"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:n5,colorTabPane:oe,fontTabPane:on,layoutTabPane:os,sectionId:t,hidden:n})});var ol=n(31810),od={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},ou=od.className,om=od.styles,oh=(0,u.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,c=e.updateSectionData,l=e.reorderHubpageItems,d=e.dataTestId,m=(0,u.useState)(String(n[0].id)),p=m[0],f=m[1];return(0,tG.A)(r,l,n.length,"hub-page-tabs"),(0,eI.jsxs)("div",{className:"".concat(ou," items"),children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(r),value:p,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(d,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(a("editor:editor.member")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(ol.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:a("editor:editor.addNewMember"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-addNewMember"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===p?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.images.profilePhoto"),children:(0,eI.jsx)(eH,{afterUpdate:function(e){return c("image",e,r,t)},currentImage:e.image,sectionId:r,tabKey:t,title:a("editor:editor.images.profilePhoto"),imgixUrl:!0,imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY})}),(0,eI.jsx)(ec.A,{label:a("common:common.name"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-name"),name:"name",value:e.name,onChange:function(e){return c("name",e.target.value,r,t)}})}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.occupation"),sx:{mb:0,width:"100%"},children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-occupation"),name:"occupation",value:e.occupation,onChange:function(e){return c("occupation",e.target.value,r,t)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.company"),sx:{mb:0,width:"100%"},children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-company"),name:"company",value:e.company,onChange:function(e){return c("company",e.target.value,r,t)}})})})]}),(0,eI.jsx)(ec.A,{label:a("editor:editor.email"),sx:{mt:1.5},children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-email"),name:"email",value:e.email,onChange:function(e){return c("email",e.target.value,r,t)}})}),(0,eI.jsx)(ec.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneMember"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-deleteMember"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteMember")})})]},e.id):null}),om]})});let op=(0,m.withTranslation)(["common","editor"])(oh),ox=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-hubs-editor-sections-whoslistening-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,reorderHubpageItems:er.Kc},e)})(op);var og=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let of=(0,m.withTranslation)(["common","editor"])(og),ob=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-whoslistening-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(of);var oj=n(89580),ov=n(91846),oy=n(99508),oA=n(21564);let ow=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:oj},{id:"two",imageUrl:ov},{id:"three",imageUrl:oy},{id:"four",imageUrl:oA}],sectionId:t})}),oC=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-whoslistening-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ow),oT=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-whoslistening"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:ox,colorTabPane:ob,layoutTabPane:oC,sectionId:t,hidden:n})});var ok=n(71858),oS=n(34586),oI=n(67412),oP=n(79712),oO=n(99612),oN=n(95980),oz=n(46504),oD=n(56887),oH=n(18597),oF=n(94674),oR=n(21670),oE=n(97330),oU=n(10203),oB=n(19247),oL=n(87996),o_=n(96963),oW=n(68697),oM=n(59934),oK=n(92706),oY=n(42205),oV=n(97014),oq=n(32653),oQ=n(55188),oZ={styles:(0,eI.jsx)(c(),{id:"998109262",children:[".image-wrapper.jsx-998109262{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;}",".image.jsx-998109262{width:80px;height:80px;background-color:#fff;margin-bottom:24px;border:1px solid #e8e8e8;border-radius:4px;padding:12px;margin-right:12px;}",".image.jsx-998109262:hover{cursor:pointer;border-color:#0e4b70;box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".content.jsx-998109262{overflow-y:scroll;padding:0 24px;min-height:calc(100vh - 60px);}",".upload-container.jsx-998109262{height:calc(100vh - 110px);display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;
1-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".preview-container.jsx-998109262{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".preview-image.jsx-998109262{height:32px;width:32px;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;background-color:#fafafa;padding:8px 0;border-radius:4px;margin-right:12px;background-size:contain;background-repeat:no-repeat;}",".preview-image.jsx-998109262:hover{cursor:pointer;}"]}),className:"jsx-998109262"},oG=oZ.className,oX=oZ.styles,o$=[oS,oI,oP,oO,oN,oz,oD,oH,oF,oR,oE,oU,oB,oL,o_,oW,oM,oK,oY,oV,oq,oQ],oJ=(0,u.memo)(function(e){var t,n,o=e.t,i=e.uploadFile,a=e.afterUpdate,s=e.imageUrl,c=e.uploading,l=e.uploadError,m=e.currentImage,h=e.dataTestId,p=(0,u.useState)(!1),g=p[0],f=p[1],b=(0,u.useState)("icons"),j=b[0],v=b[1],y=(0,u.useRef)(null),A=(0,u.useRef)(!1);return(0,u.useEffect)(function(){if(A.current&&!c){if(l){A.current=!1;return}s&&(A.current=!1,a(s),f(!1))}},[c,l,s,a]),(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsxs)("div",{className:"".concat(oG," preview-container"),children:[(0,eI.jsx)("div",{className:"".concat(oG," preview-image"),"data-testid":"".concat(h,"-editImage"),style:{backgroundImage:"url(".concat(m,")")},onClick:function(){return f(!0)},role:"button"}),(0,eI.jsx)(em.A,{"data-testid":"".concat(h,"-update"),variant:"contained",color:"primary",size:"small",sx:{px:1.25,py:.25,minHeight:32,flexShrink:0,whiteSpace:"nowrap"},onClick:function(){return f(!0)},children:o("editor:editor.update")})]}),(0,eI.jsxs)(eM.A,{open:g,onClose:function(){return f(!1)},title:o("editor:editor.icons"),width:"80vw",slotProps:{root:{keepMounted:!1}},contentSx:{p:0,flex:1,bgcolor:"rgb(235, 236, 239)",overflow:"hidden"},children:[(0,eI.jsx)(x.A,{sx:{borderBottom:1,borderColor:"divider",bgcolor:"#fff",px:2},children:(0,eI.jsxs)(ep.A,{value:j,onChange:function(e,t){return v(t)},children:[(0,eI.jsx)(eh.A,{value:"icons",label:(0,eI.jsx)("div",{"data-testid":"".concat(h,"-icons"),children:o("editor:editor.icons")})}),(0,eI.jsx)(eh.A,{value:"upload",label:(0,eI.jsx)("div",{"data-testid":"".concat(h,"-upload"),children:o("common:common.upload")})})]})}),(0,eI.jsx)("div",{className:"".concat(oG," content"),children:"icons"===j?(0,eI.jsx)("div",{className:"".concat(oG," image-wrapper"),children:o$.map(function(e,t){return(0,eI.jsx)("img",{"data-testid":"".concat(h,"-").concat(t),role:"button",alt:"",className:"".concat(oG," image"),src:e,onClick:function(){a(e),f(!1)}},t)})}):(t=(0,r.A)(d().mark(function e(t){var n;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.target.files&&t.target.files[0]){e.next=3;break}return e.abrupt("return");case 3:return A.current=!0,e.next=6,i(n);case 6:t.target.value="";case 7:case"end":return e.stop()}},e)})),n=function(e){return t.apply(this,arguments)},(0,eI.jsxs)(x.A,{sx:{position:"relative"},className:"".concat(oG," upload-container"),"data-testid":"".concat(h,"-clickOrDragToUpload"),children:[(0,eI.jsx)("input",{ref:y,type:"file",name:"file",accept:"image/*",style:{display:"none"},onChange:n}),c?(0,eI.jsx)(ok.A,{}):(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(ex.A,{sx:{fontSize:48,color:"text.secondary",mb:1}}),(0,eI.jsx)(z.A,{color:"text.secondary",children:o("editor:editor.clickOrDragToUpload")}),(0,eI.jsx)(em.A,{variant:"outlined",sx:{mt:2},onClick:function(){return y.current&&y.current.click()},children:o("common:common.upload")})]})]}))})]}),oX]})});let o0=(0,m.withTranslation)(["common","editor"])(oJ),o1=(0,o.Ng)(function(e){return{uploading:e.hubPageRevision.uploadingFile,uploadError:e.hubPageRevision.fileUploadError,imageUrl:e.hubPageRevision.uploadedFileUrl,dataTestId:"admin-hubs-editor-drawers-icon-manage"}},function(e){return(0,i.zH)({uploadFile:er.QM},e)})(o0);var o2={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},o3=o2.className,o5=o2.styles,o4=(0,u.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,c=e.updateSectionData,l=e.reorderHubpageItems,d=e.dataTestId,m=(0,u.useState)(String(n[0].id)),p=m[0],f=m[1];return(0,tG.A)(r,l,n.length,"hub-page-tabs"),(0,eI.jsxs)("div",{className:"".concat(o3," items"),children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(o1,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(r),value:p,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(d,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(a("editor:editor.link")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(e4.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:a("editor:editor.addNewLink"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-addNewLink"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===p?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("common:common.name"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-name"),name:"name",value:e.name,onChange:function(e){return c("name",e.target.value,r,t)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.url"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-url"),name:"url",value:e.url,onChange:function(e){return c("url",e.target.value,r,t)}})})})]}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:a("editor:editor.openInNewTab"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(d,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return c("openInNewTab",e,r,t)}})})}),(0,eI.jsx)(ec.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-deleteLink"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteLink")})})]},e.id):null}),o5]})});let o9=(0,m.withTranslation)(["common","editor"])(o4),o6=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-hubs-editor-sections-important-links-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,reorderHubpageItems:er.Kc},e)})(o9);var o8=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let o7=(0,m.withTranslation)(["common","editor"])(o8),ie=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-important-links-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(o7);var it=n(13453),io=n(40523);let ii=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:it},{id:"two",imageUrl:io}],sectionId:t})}),ir=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-important-links-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ii),ia=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-important-links"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:o6,colorTabPane:ie,layoutTabPane:ir,sectionId:t,hidden:n})});var is=n(99768),ic=n(23876),il=n(46741),id={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},iu=id.className,im=id.styles,ih=(0,u.memo)(function(e){var t=e.addSectionData,n=e.deleteSectionData,o=e.data,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionData,l=e.updateSectionMeta,d=e.reorderHubpageItems,m=e.lang,p=e.dataTestId,j=(0,u.useState)(String(o[0].id)),v=j[0],y=j[1];return(0,tG.A)(r,d,o.length,"hub-page-tabs"),(0,eI.jsxs)("div",{"data-testid":"homepage-editor-keydates-section-content",className:"jsx-1881360264 "+"".concat(iu," items"),children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-sectionTitle"),name:"title",value:i.title,onChange:function(e){return l("title",e.target.value,r)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(o1,{afterUpdate:function(e){return l("icon",e,r)},currentImage:i.icon})})]})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(r),value:v,onCh
1ange:function(e,t){return y(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:o.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(p,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(a("editor:editor.date")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(il.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:a("editor:editor.addNewDate"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(p,"-addNewDate"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),y(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),o.map(function(e,t){return String(e.id)===v?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.eventType"),children:(0,eI.jsxs)(b.A,{exclusive:!0,className:"testId-".concat(p,"-eventType"),value:e.multiDayEvent?"true":"false",onChange:function(e,n){null!=n&&s("multiDayEvent","false"!==n,r,t)},size:"medium",children:[(0,eI.jsx)(f.A,{value:"false","data-testid":"".concat(p,"-singleDay"),children:a("editor:editor.singleDay")}),(0,eI.jsx)(f.A,{value:"true","data-testid":"".concat(p,"-multiDay"),children:a("editor:editor.multiDay")})]})}),(0,eI.jsx)(h.A,{container:!0,spacing:3,children:e.multiDayEvent?(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.startDate"),children:(0,eI.jsx)(is.A,{className:"testId-".concat(p,"-startDate"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.startDate,altFormat:"fr-CA"===m?"j F Y":"F j, Y",dateFormat:"fr-CA"===m?"j F Y":"F j, Y",locale:"fr-CA"===m?ic.French:""},onChange:function(e,n){return s("startDate",n,r,t)},value:e.startDate},"fr-CA"===m?ic.French:"")})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.endDate"),children:(0,eI.jsx)(is.A,{className:"testId-".concat(p,"-endDate"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.endDate,altFormat:"fr-CA"===m?"j F Y":"F j, Y",dateFormat:"fr-CA"===m?"j F Y":"F j, Y",locale:"fr-CA"===m?ic.French:""},onChange:function(e,n){return s("endDate",n,r,t)},value:e.endDate},"fr-CA"===m?ic.French:"")})})]}):(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.startDate"),children:(0,eI.jsx)(is.A,{className:"testId-".concat(p,"-startDateSingle"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.startDate,altFormat:"fr-CA"===m?"j F Y":"F j, Y",dateFormat:"fr-CA"===m?"j F Y":"F j, Y",locale:"fr-CA"===m?ic.French:""},onChange:function(e,n){return s("startDate",n,r,t)},value:e.startDate},"fr-CA"===m?ic.French:"")})})}),(0,eI.jsx)(ec.A,{label:a("common:common.name"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-name"),name:"name",value:e.name,onChange:function(e){return s("name",e.target.value,r,t)}})}),(0,eI.jsx)(ec.A,{label:a("common:common.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-description"),name:"description",value:e.description,onChange:function(e){return s("description",e.target.value,r,t)}})}),(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.linkText"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-linkText"),name:"linkText",value:e.linkText,onChange:function(e){return s("linkText",e.target.value,r,t)}})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:a("editor:editor.linkUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-linkUrl"),name:"linkUrl",value:e.linkUrl,onChange:function(e){return s("linkUrl",e.target.value,r,t)}})})})]}),(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(th.A,{sx:{mb:0},label:a("editor:editor.openInNewTab"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(p,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return s("openInNewTab",e,r,t)}})})}),(0,eI.jsx)(ec.A,{extra:1===o.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(p,"-deleteDate"),variant:"contained",color:"error",onClick:function(){0===t?y(String(o[t+1].id)):y(String(o[t-1].id)),n(r,t)},disabled:1===o.length,children:a("editor:editor.deleteDate")})})]},e.id):null}),(0,eI.jsx)(c(),{id:"1881360264",children:[".hpe-flatpickr-alt-input{box-sizing:border-box;width:100%;min-height:40px;padding:8px 14px;border:1px solid rgba(0,0,0,0.23);border-radius:4px;font:inherit;background:#fff;}",".hpe-flatpickr-alt-input:hover{border-color:rgba(0,0,0,0.87);}",".hpe-flatpickr-alt-input:focus{border-color:#1976d2;outline:0;box-shadow:0 0 0 1px #1976d2;}"]}),im]})});let ip=(0,m.withTranslation)(["common","editor"])(ih),ix=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,theme:e.hubPageRevision.revision.sections[t.sectionId].theme,currentUser:e.currentUser.user,dataTestId:"admin-hubs-editor-sections-keydates-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,reorderHubpageItems:er.Kc},e)})(ip);var ig=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}
1),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let ib=(0,m.withTranslation)(["common","editor"])(ig),ij=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-keydates-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ib);var iv=n(10326),iy=n(3016),iA=n(11770);let iw=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:iv},{id:"two",imageUrl:iy},{id:"three",imageUrl:iA}],sectionId:t})}),iC=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-keydates-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(iw),iT=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-keydates"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:ix,colorTabPane:ij,layoutTabPane:iC,sectionId:t,hidden:n})});var ik={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},iS=ik.className,iI=ik.styles,iP=(0,u.memo)(function(e){var t,n=e.addSectionData,o=e.data,i=e.deleteSectionData,a=e.meta,s=e.sectionId,c=e.t,l=e.updateSectionMeta,m=e.updateSectionData,p=e.uploadFile,j=e.uploadingFile,v=e.uploadedFileUrl,y=e.reorderHubpageItems,A=e.dataTestId,w=(0,u.useState)(String(o[0].id)),C=w[0],T=w[1],k=(0,u.useRef)(null),S=(0,u.useRef)(null),I=(0,u.useRef)(null),P=(0,u.useRef)(!1);(0,tG.A)(s,y,o.length,"hub-page-tabs"),(0,u.useEffect)(function(){if(j){P.current=!0;return}if(null!=S.current&&P.current&&v){P.current=!1;var e=S.current;S.current=null,m("url",v,s,e),I.current&&(m("name",I.current,s,e),I.current=null)}},[j,v,s,m]);var O=function(e){S.current=e,k.current&&k.current.click()},N=(t=(0,r.A)(d().mark(function e(t){var n;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.target.files&&t.target.files[0]){e.next=4;break}return S.current=null,e.abrupt("return");case 4:return I.current=n.name,e.next=7,p(n);case 7:t.target.value="";case 8:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)});return(0,eI.jsxs)("div",{className:"".concat(iS," items"),children:[(0,eI.jsx)("input",{ref:k,type:"file",style:{display:"none"},onChange:N}),(0,eI.jsx)(ec.A,{label:c("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(A,"-sectionTitle"),name:"title",value:a.title,onChange:function(e){return l("title",e.target.value,s)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:c("editor:editor.images.icon")}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(o1,{afterUpdate:function(e){return l("icon",e,s)},currentImage:a.icon})})]})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(s),value:C,onChange:function(e,t){return T(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:o.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(A,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(c("editor:editor.document")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(et.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:c("editor:editor.addNewDocument"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(A,"-addNewDocument"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());n(s,e),T(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),o.map(function(e,t){return String(e.id)===C?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(b.A,{exclusive:!0,value:e.isUploaded?"true":"false",onChange:function(e,n){null!=n&&m("isUploaded","false"!==n,s,t)},size:"medium",children:[(0,eI.jsx)(f.A,{value:"true",className:"testId-".concat(A,"-uploadDocument"),children:c("editor:editor.uploadDocument")}),(0,eI.jsx)(f.A,{value:"false",className:"testId-".concat(A,"-linkDocument"),children:c("editor:editor.linkDocument")})]})}),(0,eI.jsx)(h.A,{container:!0,spacing:3,children:e.isUploaded?(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(ec.A,{label:c("editor:editor.chooseDocument"),children:(0,eI.jsx)(em.A,{className:"testId-".concat(A,"-chooseDocument"),variant:"contained",color:"primary",sx:{whiteSpace:"nowrap"},disabled:j,onClick:function(){return O(t)},startIcon:j?(0,eI.jsx)(ok.A,{size:18,color:"inherit"}):(0,eI.jsx)(ex.A,{}),children:e.url?c("editor:editor.changeDocument"):c("editor:editor.chooseDocument")})})}):(0,eI.jsx)(h.A,{size:{xs:12,md:12},children:(0,eI.jsx)(ec.A,{label:c("editor:editor.urlOfExternalDocument"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(A,"-urlOfExternalDocument"),name:"url",value:e.url,onChange:function(e){return m("url",e.target.value,s,t)}})})})}),(0,eI.jsx)(ec.A,{label:c("common:common.name"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(A,"-name"),name:"name",value:e.name,onChange:function(e){return m("name",e.target.value,s,t)}})}),(0,eI.jsx)(ec.A,{extra:1===o.length?c("editor:editor.helpTexts.needAtleastOneDocument"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(A,"-deleteDocument"),variant:"contained",color:"error",onClick:function(){0===t?T(String(o[t+1].id)):T(String(o[t-1].id)),i(s,t)},disabled:1===o.length,children:c("editor:editor.deleteDocument")})})]},e.id):null}),iI]})});let iO=(0,m.withTranslation)(["common","editor"])(iP),iN=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,uploadingFile:e.hubPageRevision.uploadingFile,uploadedFileUrl:e.hubPageRevision.uploadedFileUrl,dataTestId:"admin-hubs-editor-sections-documents-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,uploadFile:er.QM,reorderHubpageItems:er.Kc},e)})(iO);var iz=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let iD=(0,m.withTranslation)(["common","editor"])(iz),iH=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-documents-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(iD);var iF=n(68617),iR=n(82999),iE=n(82089);let iU=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:iF},{id:"two",imageUrl:iR},{id:"three",imageUrl:iE}],sectionId:t})}),iB=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-documents-text-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(iU),iL=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-documents"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:iN,colorTabPane:iH,layoutTabPane:iB,sectionId:t,hidden:n})});var i_=n(62446),iW={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},iM=iW.className,iK=iW.styles,iY=(0,u.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,c=e.updateSectionData,l=e.reorderHubpageItems,d=e.dataTestId,m=(0,u.useState)(String(n[0].id)),p=m[0],f=m[1];return(0,tG.A)(r,l,n.length,"hub-page-tabs"),(0,eI.jsxs)("div",{className:"".concat(iM," items"),children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(o1,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(r),value:p,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(d,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(a("editor:editor.stage")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(i_.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:a("editor:editor.addNewStage"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-addNewStage"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===p?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.setCurrentStage"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-setCurrentStage"),variant:"contained",color:"primary",onClick:function(){return s("currentStage",t,r)},disabled:i.currentStage===t,children:a("editor:editor.setCurrentStage")})}),(0,eI.jsx)(ec.A,{label:a("common:common.name"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-name"),name:"name",value:e.name,onChange:function(e){return c("name",e.target.value,r,t)}})}),(0,eI.jsx)(ec.A,{label:a("common:common.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-description"),name:"description",value:e.description,onChange:function(e){return c("description",e.target.value,r,t)}})}),(0,eI.jsx)(ec.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneStage"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-deleteStage"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteStage")})})]},e.id):null}),iK]})});let iV=(0,m.withTranslation)(["common","editor"])(iY),iq=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-hubs-editor-sections-lifecycle-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,reorderHubpageItems:er.Kc},e)})(iV);var iQ=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let iZ=(0,m.withTranslation)(["common","editor"])(iQ),iG=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-lifecycle-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(iZ);var iX=n(26404),i$=n(5454);let iJ=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:iX},{id:"two",imageUrl:i$}],sectionId:t})}),i0=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-lifecycle-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(iJ),i1=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-lifecycle"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:iq,colorTabPane:iG,layoutTabPane:i0,sectionId:t,hidden:n})});var i2=n(87046),i3={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},i5=i3.className,i4=i3.styles,i9=(0,u.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,c=e.updateSectionData,l=e.reorderHubpageItems,d=e.dataTestId,m=(0,u.useState)(String(n[0].id)),p=m[0],f=m[1];return(0,tG.A)(r,l,n.length,"hub-page-tabs"),(0,eI.jsxs)("div",{className:"".concat(i5," items"),children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,eI.jsx)(h.A,{size:{xs:12,md:6},children:(0,eI.jsx)(o1,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,eI.jsx)(ep.A,{className:"hub-page-tabs-".concat(r),value:p,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,eI.jsx)(eh.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(d,"-").concat(e.id),label:(0,eI.jsx)(g.A,{title:"".concat(a("editor:editor.question")," ").concat(t+1),children:(0,eI.jsxs)(x.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,eI.jsx)(i2.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,eI.jsx)(g.A,{title:a("editor:editor.addNewFAQ"),children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-addNewFAQ"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,eI.jsx)(tq.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===p?(0,eI.jsxs)(x.A,{sx:{pt:2},children:[(0,eI.jsx)(ec.A,{label:a("editor:editor.question"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-question"),name:"question",value:e.question,onChange:function(e){return c("question",e.target.value,r,t)}})}),(0,eI.jsx)(ec.A,{label:a("editor:editor.answer"),children:(0,eI.jsx)(tp.A,{name:"answer",value:e.answer,onChange:function(e){return c("answer",e.target.value,r,t)},config:(0,tx.J)("HomePageFaq"),dataTestId:"froala-editor-home-faq-answer-".concat(r,"-").concat(t)})}),(0,eI.jsx)(ec.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,eI.jsx)(em.A,{"data-testid":"".concat(d,"-deleteLink"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteLink")})})]},e.id):null}),i4]})});let i6=(0,m.withTranslation)(["common","editor"])(i9),i8=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-hubs-editor-sections-faq-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,reorderHubpageItems:er.Kc},e)})(i6);var i7=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let re=(0,m.withTranslation)(["common","editor"])(i7),rt=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-faq-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(re);var rn=n(82379),ro=n(64801);let ri=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:rn},{id:"two",imageUrl:ro}],sectionId:t})}),rr=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-faq-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ri),ra=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-faq"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:i8,colorTabPane:rt,layoutTabPane:rr,sectionId:t,hidden:n})});var rs={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},rc=rs.className,rl=rs.styles,rd=(0,u.memo)(function(e){var t=e.data,n=e.sectionId,o=e.t,i=e.updateSectionData,r=e.dataTestId;return(0,eI.jsxs)("div",{className:"".concat(rc," items"),children:[(0,eI.jsx)(ec.A,{label:o("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",defaultValue:t.title,onChange:function(e){return i("title",e.target.value,n)}})}),(0,eI.jsx)(ec.A,{label:o("editor:editor.content"),children:(0,eI.jsx)(tp.A,{name:"content",value:t.content,onChange:function(e){var o=e.target.value;(null==t?void 0:t.content)!==o&&i("content",o,n)},config:(0,tx.J)("HomePageCustom"),dataTestId:"froala-editor-hub-custom-content"})}),rl]})});let ru=(0,m.withTranslation)(["editor"])(rd),rm=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-custom-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(ru);var rh=(0,u.memo)(function(e){var t=e.t,n=e.sectionId,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,n)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,n)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,n)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rp=(0,m.withTranslation)(["common","editor"])(rh),rx=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-custom-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(rp),rg=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-custom"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:rm,colorTabPane:rx,sectionId:t,hidden:n})});var rf=(0,u.memo)(function(e){var t=e.t,n=e.updateSectionData,o=(e.logoUrl,e.data),i=e.sectionId,r=(e.updateSite,e.saveSite,e.dataTestId),a=o.facebookUrl,s=o.twitterUrl,c=o.googleUrl,l=o.instagramUrl,d=o.linkedinUrl,m=o.youtubeUrl;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.facebookUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-facebookUrl"),name:"facebookUrl",value:a,onChange:function(e){return n("facebookUrl",e.target.value,i)}})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.twitterUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-twitterUrl"),name:"twitterUrl",value:s,onChange:function(e){return n("twitterUrl",e.target.value,i)}})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.googleUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-googleUrl"),name:"googleUrl",value:c,onChange:function(e){return n("googleUrl",e.target.value,i)}})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.instagramUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-instagramUrl"),name:"instagramUrl",value:l,onCh
1ange:function(e){return n("instagramUrl",e.target.value,i)}})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.linkedinUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-linkedinUrl"),name:"linkedinUrl",value:d,onChange:function(e){return n("linkedinUrl",e.target.value,i)}})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.youtubeUrl"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-youtubeUrl"),name:"youtubeUrl",value:m,onChange:function(e){return n("youtubeUrl",e.target.value,i)}})})]})});let rb=(0,m.withTranslation)(["common","editor"])(rf),rj=(0,o.Ng)(function(e,t){return{logoUrl:e.currentSite.site.logoUrl,data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-footer-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,updateSite:ea.hj,saveSite:ea.X8},e)})(rb);var rv=(0,u.memo)(function(e){var t=e.t,n=e.updateSectionTheme,o=e.backgroundColor,i=(e.ctaBackgroundColor,e.ctaTextColor,e.textColor),r=e.sectionId,a=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:t("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:i,fieldKey:"textColor",onChange:function(e){return n("textColor",e,r)},"data-testid":"".concat(a,"-textColor")})}),(0,eI.jsx)(ec.A,{label:t("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o,fieldKey:"backgroundColor",onChange:function(e){return n("backgroundColor",e,r)},"data-testid":"".concat(a,"-backgroundColor")})})]})});let ry=(0,m.withTranslation)(["common","editor"])(rv),rA=(0,o.Ng)(function(e,t){return{backgroundColor:e.hubPageRevision.revision.sections[t.sectionId].theme.backgroundColor,textColor:e.hubPageRevision.revision.sections[t.sectionId].theme.textColor,dataTestId:"admin-hubs-editor-sections-footer-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ry),rw=(0,m.withTranslation)(["editor"])(function(e){var t=e.t;return(0,eI.jsx)(eI.Fragment,{children:(0,eI.jsxs)(ec.A,{children:[(0,eI.jsx)(eZ.A,{label:t("editor:editor.navigationLinks"),sx:{mt:2}}),(0,eI.jsx)(eW.A,{sx:{mb:2.5},children:t("editor:editor.footerLinksDescription")}),(0,eI.jsx)(eQ,{content:"footer"})]})})}),rC=(0,o.Ng)(function(){return{dataTestId:"admin-hubs-editor-sections-footer"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:rj,colorTabPane:rA,linksTabPane:rw,sectionId:t,hidden:n,canBeHidden:!1,canBeDeleted:!1})});var rT={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},rk=rT.className,rS=rT.styles,rI=(0,u.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,eI.jsxs)("div",{className:"".concat(rk," items"),children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})}),rS]})});let rP=(0,m.withTranslation)(["common"])(rI),rO=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-title-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(rP);var rN=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rz=(0,m.withTranslation)(["common","editor"])(rN),rD=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-title-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(rz);var rH=n(41657),rF=n(71847);let rR=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:rH},{id:"two",imageUrl:rF}],sectionId:t})}),rE=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-title-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(rR),rU=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-title"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:rO,colorTabPane:rD,layoutTabPane:rE,sectionId:t,hidden:n})});var rB=(0,u.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,eI.jsx)(x.A,{sx:{display:"flex",flexDirection:"column"},children:(0,eI.jsxs)(ec.A,{label:n("editor:editor.content"),children:[(0,eI.jsx)(es.A,{multiline:!0,minRows:14,maxRows:14,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-html"),name:"html",value:t.html,onChange:function(e){return i(e.target.name,e.target.value,o)}}),(0,eI.jsx)(el.A,{textVariant:"body2",mt:.5,children:n("editor:editor.htmlHelperText")})]})})});let rL=(0,m.withTranslation)(["common"])(rB),r_=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-html-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(rL);var rW=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rM=(0,m.withTranslation)(["common","editor"])(rW),rK=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-html-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(rM);var rY=n(41048);let rV=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:rY}],sectionId:t})}),rq=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-html-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(rV),rQ=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-html"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:r_,colorTabPane:rK,layoutTabPane:rq,sectionId:t,hidden:n})});var rZ={styles:(0,eI.jsx)(c(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},rG=rZ.className,rX=rZ.styles,r$=(0,u.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,eI.jsxs)("div",{className:"".concat(rG," items"),children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-title"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.description"),children:(0,eI.jsx)(td.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-description"),name:"description",value:t.description,onChange:function(e){return i("description",e.target.value,o)}})}),rX]})});let rJ=(0,m.withTranslation)(["common"])(r$),r0=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-titlewithdesc-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(rJ);var r1=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionDescriptionColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionDescriptionColor,fieldKey:"sectionDescriptionColor",onChange:function(e){return i("sectionDescriptionColor",e,t)},"data-testid":"".concat(r,"-sectionDescriptionColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let r2=(0,m.withTranslation)(["common","editor"])(r1),r3=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-titlewithdesc-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(r2);var r5=n(33893);let r4=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:r5}],sectionId:t})}),r9=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-titlewithdesc-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(r4),r6=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-titlewithdesc"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:r0,colorTabPane:r3,layoutTabPane:r9,sectionId:t,hidden:n})});var r8=(0,u.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,eI.jsxs)(x.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.selectVideoType"),children:(0,eI.jsxs)(td.A,{select:!0,className:"testId-".concat(r,"-selectVideoType"),size:"medium",fullWidth:!0,variant:"outlined",value:t.type,onCh
1ange:function(e){return i("type",e.target.value,o)},children:[(0,eI.jsx)(eJ.A,{value:"Youtube",children:n("editor:editor.youtube")}),(0,eI.jsx)(eJ.A,{value:"Vimeo",children:n("editor:editor.vimeo")})]})}),(0,eI.jsxs)(ec.A,{label:n("editor:editor.url"),children:[(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-url"),name:"url",value:t.url,onChange:function(e){return i("url",e.target.value,o)}}),(0,eI.jsx)(el.A,{textVariant:"body2",mt:.5,children:n("editor:editor.youtubeHelpText")})]}),(0,eI.jsx)(ec.A,{label:n("editor:editor.title"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-title"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})})]})});let r7=(0,m.withTranslation)(["common","editor"])(r8),ae=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-hubs-editor-sections-video-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ},e)})(r7);var at=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let an=(0,m.withTranslation)(["common","editor"])(at),ao=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-video-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(an);var ai=n(11134);let ar=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:ai}],sectionId:t})}),aa=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-video-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ar),as=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-video"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:ae,colorTabPane:ao,layoutTabPane:aa,sectionId:t,hidden:n})});var ac=n(3513);function al(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var ad=(0,u.memo)(function(e){e.data;var t=e.meta,n=e.sectionId,o=e.t,i=e.updateSectionMeta,r=e.dataTestId,a=(0,u.useState)(!1),s=a[0],c=a[1];return(0,eI.jsxs)(x.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,eI.jsx)(ec.A,{label:o("editor:editor.sectionTitle"),children:(0,eI.jsx)(es.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showSearch"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showSearch"),name:"showSearch",checked:t.showSearch,onChange:function(e){return i("showSearch",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showTagsFilter"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showTagsFilter"),name:"showTagsFilter",checked:t.showTagsFilter,onChange:function(e){return i("showTagsFilter",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showYearFilter"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showYearFilter"),name:"showYearFilter",checked:t.showYearFilter,onChange:function(e){return i("showYearFilter",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showStateFilter"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showStateFilter"),name:"showStateFilter",checked:t.showStateFilter,onChange:function(e){return i("showStateFilter",e,n)}})}),!s&&(0,eI.jsx)(ec.A,{children:(0,eI.jsx)(ac.A,{component:"button",type:"button",onClick:function(){return c(!0)},"data-testid":"".concat(r,"-showMoreOptions"),sx:{cursor:"pointer"},children:o("editor:editor.showMoreOptions")})}),s&&(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(th.A,{label:o("editor:editor.showResetFilterButton"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showResetFilterButton"),name:"showResetFilterButton",checked:t.showResetFilterButton,onChange:function(e){return i("showResetFilterButton",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showProjectName"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showProjectName"),name:"showProjectName",checked:t.showProjectName,onChange:function(e){return i("showProjectName",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showProjectDescription"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showProjectDescription"),name:"showProjectDescription",checked:t.showProjectDescription,onChange:function(e){return i("showProjectDescription",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.showProjectStatus"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-showProjectStatus"),name:"showProjectStatus",checked:t.showProjectStatus,onChange:function(e){return i("showProjectStatus",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.displayViewProjectButton"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-displayViewProjectButton"),name:"showViewProjectButton",checked:t.showViewProjectButton,onChange:function(e){return i("showViewProjectButton",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.displayPublishDate"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-displayPublishDate"),name:"showProjectTimestamp",checked:t.showProjectTimestamp,onChange:function(e){return i("showProjectTimestamp",e,n)}})}),(0,eI.jsx)(th.A,{label:o("editor:editor.projectPaginationView"),control:(0,eI.jsx)(ey.A,{"data-testid":"".concat(r,"-projectPaginationView"),name:"projectPaginationView",checked:t.projectPaginationView,onChange:function(e){return i("projectPaginationView",e,n)}})}),(0,eI.jsx)(ec.A,{children:(0,eI.jsxs)(h.A,{container:!0,spacing:2,sx:{justifyContent:"space-between",alignItems:"center"},children:[(0,eI.jsx)(h.A,{size:{xs:12,md:8},children:(0,eI.jsx)(x.A,{component:"label",htmlFor:"".concat(r,"-projectsPerPage"),sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?al(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):al(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({display:"block",color:"text.primary"},ei.m),children:o("editor:editor.projectsPerPage")})}),(0,eI.jsx)(h.A,{size:{xs:12,md:4},children:(0,eI.jsx)(td.A,{id:"".concat(r,"-projectsPerPage"),type:"number",size:"medium",fullWidth:!0,variant:"outlined",className:"testId-".concat(r,"-projectsPerPage"),disabled:!t.projectPaginationView,value:t.projectsPerPage,slotProps:{htmlInput:{id:"".concat(r,"-projectsPerPage"),min:1}},onChange:function(e){return i("projectsPerPage",Number(e.target.value),n)}})})]})})]})]})});let au=(0,m.withTranslation)(["common"])(ad),am=(0,o.Ng)(function(e,t){return{data:e.hubPageRevision.revision.sections[t.sectionId].data,meta:e.hubPageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,selectedProject:e.project.project,projectTags:e.projectTags.tags,hub:e.hub.hub,dataTestId:"admin-hubs-editor-sections-projectfinder-tabs-text"}},function(e){return(0,i.zH)({updateSectionData:er.pZ,updateSectionMeta:er.YS,addSectionData:er.ZD,deleteSectionData:er.bL,updateFilters:tA.vm,reorderHubpageItems:er.Kc},e)})(au);var ah={styles:(0,eI.jsx)(c(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"},ap=(ah.className,ah.styles),ax=(0,u.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(ec.A,{label:n("editor:editor.sectionTitleColor"),children:(0,eI.jsx)(eU.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.textColor"),children:(0,eI.jsx)(eU.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,eI.jsx)(ec.A,{label:(0,eI.jsx)(el.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,eI.jsx)(eU.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,eI.jsx)(ec.A,{label:n("editor:editor.backgroundColor"),children:(0,eI.jsx)(eU.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),ap]})});let ag=(0,m.withTranslation)(["common","editor"])(ax),af=(0,o.Ng)(function(e,t){return{theme:e.hubPageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-hubs-editor-sections-projectfinder-tabs-color"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(ag);var ab=n(81816),aj=n(88786);let av=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,eI.jsx)(t_,{layouts:[{id:"one",imageUrl:ab},{id:"two",imageUrl:aj}],sectionId:t})}),ay=(0,o.Ng)(function(e,t){return{layout:e.hubPageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-hubs-editor-sections-projectfinder-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:er.oz},e)})(av),aA=(0,o.Ng)(function(e,t){return{hidden:e.hubPageRevision.revision.sections[t.sectionId].meta.hidden,dataTestId:"admin-hubs-editor-sections-projectfinder"}},function(e){return(0,i.zH)({updateSectionMeta:er.YS,deleteSection:er.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,eI.jsx)(ta,{textTabPane:am,colorTabPane:af,layoutTabPane:ay,sectionId:t,hidden:n})});function aw(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function aC(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?aw(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aw(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var aT={borderRadius:1,border:0,bgcolor:"background.paper","&::before":{display:"none"},"&:hover, &.Mui-expanded":{boxShadow:function(e){return e.shadows[2]}}},ak={fontSize:22,color:"action.active",display:"block",flexShrink:0},aS=["navigation","footer"];let aI=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.sections,o=e.currentSectionId,i=e.setCurrentSectionId,r=e.dataTestId,a=function(e){var t=document.getElementById("hub-page-view-section-".concat(e));t&&t.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})},s=function(e,t){switch(e){case"custom":return(0,eI.jsx)(rg,{sectionId:t});case"whosListening":return(0,eI.jsx)(oT,{sectionId:t});case"footer":return(0,eI.jsx)(rC,{sectionId:t});case"carousel":return(0,eI.jsx)(oc,{sectionId:t});case"navigation":return(0,eI.jsx)(ts,{sectionId:t});case"banner":return(0,eI.jsx)(tM,{sectionId:t});case"projects":default:return(0,eI.jsx)(nu,{sectionId:t});case"projectFinder":return(0,eI.jsx)(aA,{sectionId:t});case"featured":return(0,eI.jsx)(nO,{sectionId:t});case"registerWidget":return(0,eI.jsx)(nQ,{sectionId:t});case"importantLinks":return(0,eI.jsx)(ia,{sectionId:t});case"keyDates":return(0,eI.jsx)(iT,{sectionId:t});case"documents":return(0,eI.jsx)(iL,{sectionId:t});case"lifeCycle":return(0,eI.jsx)(i1,{sectionId:t});case"faq":return(0,eI.jsx)(ra,{sectionId:t});case"title":return(0,eI.jsx)(rU,{sectionId:t});case"titleWithDescription":return(0,eI.jsx)(r6,{sectionId:t});case"video":return(0,eI.jsx)(as,{sectionId:t});case"html":return(0,eI.jsx)(rQ,{sectionId:t})}},c=function(e){switch(e){case"custom":return(0,eI.jsx)(et.A,{sx:ak});case"whosListening":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/who-listen.svg",height:"20px",alt:""});case"footer":return(0,eI.jsx)(ee.A,{sx:ak});case"carousel":default:return(0,eI.jsx)(K.A,{sx:ak});case"video":return(0,eI.jsx)(X.A,{sx:ak});case"navigation":return(0,eI.jsx)(V.A,{sx:ak});case"banner":return(0,eI.jsx)(Y.A,{sx:ak});case"projects":return(0,eI.jsx)(q.A,{sx:ak});case"projectFinder":return(0,eI.jsx)(en.A,{sx:ak});case"featured":return(0,eI.jsx)(Q.A,{sx:ak});case"registerWidget":return(0,eI.jsx)(Z.A,{sx:ak});case"title":return(0,eI.jsx)($.A,{sx:ak});case"titleWithDescription":return(0,eI.jsx)(J.A,{sx:ak});case"importantLinks":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/links.svg",height:"20px",alt:""});case"html":return(0,eI.jsx)(G.A,{sx:ak});case"keyDates":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/key-dates.svg",height:"20px",alt:""});case"documents":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/documents.svg",height:"20px",alt:""});case"lifeCycle":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/lifecycle.svg",alt:""});case"faq":return(0,eI.jsx)("img",{src:"/static/assets/images/widgets/faq.svg",height:"20px",alt:""})}};return(0,eI.jsx)(eI.Fragment,{children:n.map(function(e,n){if(-1!==aS.indexOf(e.meta.type))return null;var l=String(o)===String(n);return(0,eI.jsx)(x.A,{sx:{mb:1.5},children:(0,eI.jsxs)(U.A,{disableGutters:!0,elevation:0,square:!0,expanded:l,onChange:function(e,t){t?(a(n),i(n)):String(o)===String(n)&&i("")},slotProps:{transition:{unmountOnExit:!0}},className:"testId-".concat(r,"-").concat(e.meta.type,"--").concat(n),sx:aT,children:[(0,eI.jsxs)(L.A,{expandIcon:null,id:"hub-page-editor-section-".concat(n,"-header"),"data-testid":"".concat(r,"-section-header-").concat(n),slotProps:{content:{sx:{alignItems:"center",gap:1,my:1,width:"100%",mr:0}}},sx:aC({bgcolor:"grey.100",px:1.5},l&&{borderBottom:1,borderColor:"divider"}),children:[(0,eI.jsx)(x.A,{sx:{display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,minWidth:32},children:c(e.meta.type)}),(0,eI.jsx)(z.A,{component:"span",variant:"body1",color:"text.primary",sx:aC(aC({},ei.m),{},{flex:1,minWidth:0,textTransform:"capitalize"}),children:t("editor:editor.sectionTypes.".concat(e.meta.type,"Section"))}),e.meta.hidden?(0,eI.jsx)(eo.A,{fontSize:"small",color:"action",sx:{flexShrink:0},"aria-label":t("editor:editor.hideThisSection")}):null]}),(0,eI.jsx)(B.A,{sx:{pt:2,px:0,pb:0,bgcolor:"common.white"},children:s(e.meta.type,n)})]})},n)})})}),aP=(0,o.Ng)(function(e){return{sections:e.hubPageRevision.revision.sections,currentSectionId:e.hubPageRevision.currentSectionId,dataTestId:"admin-hubs-editor-sidebar-section-gallery"}},function(e){return(0,i.zH)({setCurrentSectionId:er.Qu},e)}
1)(aI);var aO=n(16488),aN=n(86169),az=n(78438),aD=n(93490),aH=n(19884),aF=n(78938);let aR=(0,m.withTranslation)(["common","editor"])(function(e){var t,n,o=e.t,i=e.currentTemplateId,r=e.showTemplatesDrawer,a=e.dataTestId,s=[{id:"bondi",description:o("editor:editor.themes.bondi")},{id:"whitehaven",description:o("editor:editor.themes.whitehaven2")},{id:"cottesloe",description:o("editor:editor.themes.cottesloe")},{id:"burleigh",description:o("editor:editor.themes.burleigh")},{id:"goldcoast",description:o("editor:editor.themes.goldCoast")},{id:"crestview",description:o("editor:editor.themes.crestview")}],c="torquay"===i?"goldcoast":i||"bondi",l=null!=(t=tl()(s,function(e){return e.id===c}))?t:s[0];switch(l.id){case"bondi":default:n=aO;break;case"whitehaven":n=aN;break;case"cottesloe":n=az;break;case"burleigh":n=aD;break;case"goldcoast":n=aH;break;case"crestview":n=aF}return(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsxs)(x.A,{sx:{width:"90%",mx:"5%",mt:1.25,mb:3,border:1,borderColor:"primary.main",borderRadius:1,position:"relative",overflow:"hidden","&:hover":{boxShadow:2,"& [data-template-preview-image]":{backgroundPosition:"bottom center",transition:"background-position 5s ease-in-out 0s"}}},children:[(0,eI.jsx)(x.A,{"data-template-preview-image":!0,sx:{height:400,width:1,backgroundSize:"100% auto",backgroundRepeat:"no-repeat",backgroundPosition:"top center",transition:"background-position 0.5s ease-in-out 0s",backgroundImage:"url(".concat(n,")")}}),(0,eI.jsx)(x.A,{sx:{mb:0,p:1.5,bgcolor:"common.white",textAlign:"center",mt:"-70px",width:1},children:(0,eI.jsxs)(nG.A,{sx:{fontWeight:"bold"},children:[o("editor:editor.currentTemplate")," - ",l.description]})})]}),(0,eI.jsx)(x.A,{sx:{display:"flex",justifyContent:"center",mb:1.25},children:(0,eI.jsx)(em.A,{variant:"contained",color:"primary",onClick:function(){return r(!0)},"data-testid":"".concat(a,"-change-template"),children:o("editor:editor.changeTemplate")})}),(0,eI.jsx)(x.A,{sx:{display:"flex",justifyContent:"center",mb:1.5},children:(0,eI.jsx)(eW.A,{component:"div",sx:{textAlign:"center",lineHeight:1.43},children:(0,eI.jsx)(el.A,{textVariant:"body2",children:o("editor:editor.changeTemplateDescription")})})})]})}),aE=(0,o.Ng)(function(e){return{currentTemplateId:e.hubPageRevision.revision.meta.templateId,dataTestId:"admin-hubs-editor-sidebar-current-template"}},function(e){return(0,i.zH)({showTemplatesDrawer:er.Es},e)})(aR);function aU(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var aB=[{key:"templates",titleKey:"editor:editor.templates",helpKey:"editor:editor.helpText.templates",icon:_.A,component:aE},{key:"sections",titleKey:"editor:editor.sections",helpKey:"editor:editor.helpText.sections",icon:W.A,component:aP}];let aL=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.activeKey,o=e.changeHubPageSectionKey,i=e.dataTestId;return(0,eI.jsx)(eI.Fragment,{children:aB.map(function(e,r){var a,s=e.component,c=e.icon,l=n===e.key;return(0,eI.jsx)(x.A,{sx:{mb:1.5,borderRadius:1,border:1,borderColor:"divider",bgcolor:"background.paper",overflow:"hidden",transition:function(e){return e.transitions.create(["box-shadow"],{duration:e.transitions.duration.short})},"&:hover":{boxShadow:function(e){return e.shadows[4]}}},children:(0,eI.jsxs)(U.A,{disableGutters:!0,elevation:0,expanded:l,onChange:(a=e.key,function(e,t){t?o(a):n===a&&o("")}),slotProps:{transition:{unmountOnExit:!1}},sx:{bgcolor:"background.paper"},children:[(0,eI.jsx)(L.A,{expandIcon:null,"aria-controls":"hub-page-editor-section-".concat(r),id:"hub-page-editor-section-".concat(r,"-header"),"data-testid":"".concat(i,"-").concat(e.key),className:"hpe-panel ".concat(e.key," testId-").concat(i,"-").concat(e.key),slotProps:{content:{sx:{alignItems:"center",my:1}}},sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?aU(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aU(Object(n)).forEac
1h(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({px:1.5,bgcolor:"grey.100"},l&&{borderBottom:1,borderColor:"divider"}),children:(0,eI.jsxs)("div",{className:"hpe-section-header",children:[(0,eI.jsx)("div",{className:"hpe-icon",children:(0,eI.jsx)(c,{sx:{fontSize:22,color:"action.active"}})}),(0,eI.jsx)("div",{children:(0,eI.jsx)(M.A,{title:t(e.titleKey),description:t(e.helpKey)})})]})}),(0,eI.jsx)(B.A,{"data-testid":"".concat(i,"-").concat(e.key,"-hpe-section"),sx:{p:2,bgcolor:"common.white"},children:(0,eI.jsx)(s,{})})]})},e.key)})})}),a_=(0,o.Ng)(function(e){return{activeKey:e.hubPageRevision.activeHubPageKey,dataTestId:"admin-hubs-editor-sidebar-hub-page"}},function(e){return(0,i.zH)({changeHubPageSectionKey:er.L1},e)})(aL);var aW=n(50225),aM=n(45911),aK=n(40553),aY=n(66035),aV={styles:(0,eI.jsx)(c(),{id:"2474059597",children:[".container.jsx-2474059597{width:100%;margin-bottom:24px;border:1px solid #e8e8e8;border-radius:8px;position:relative;overflow:hidden;box-shadow:0px 0px 10px 0px rgba(0,0,0,0.25);}",".container.jsx-2474059597:hover{cursor:pointer;border-color:#0e4b70;box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".description.selected.jsx-2474059597{box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".description.selected.jsx-2474059597::after{content:'✓';position:absolute;right:10px;top:8px;color:#fff;background-color:#2e7d32;border-radius:50%;width:25px;height:25px;font-size:18px;padding:0 8px 0 6px;}",".image.jsx-2474059597{height:500px;width:100%;background-size:cover;background-repeat:no-repeat;-webkit-transition:background-position 0.5s ease-in-out 0s;transition:background-position 0.5s ease-in-out 0s;background-position:top center;background-size:100% auto !important;}",".description.jsx-2474059597{padding:12px;background-color:white;text-align:center;font-weight:bold;width:100%;margin:0px;}",".container.jsx-2474059597:hover .image.jsx-2474059597{cursor:pointer;background-position:bottom center !important;-webkit-transition:background-position 5s ease-in-out 0s;transition:background-position 5s ease-in-out 0s;}"]}),className:"jsx-2474059597"},aq=aV.className,aQ=aV.styles;let aZ=(0,m.withTranslation)(["common","editor"])(function(e){var t,o=e.t,i=e.selectTemplate,a=e.currentTemplateId,s=e.showTemplatesDrawer,c=e.isDrawerVisible,l=e.dataTestId,m=(0,u.useState)(),p=m[0],x=m[1],g=(0,u.useState)(!1),f=g[0],b=g[1],j=[{id:"bondi",imageUrl:aO,description:o("editor:editor.themes.bondi")},{id:"whitehaven",imageUrl:aN,description:o("editor:editor.themes.whitehaven2")},{id:"cottesloe",imageUrl:az,description:o("editor:editor.themes.cottesloe")},{id:"burleigh",imageUrl:aD,description:o("editor:editor.themes.burleigh")},{id:"goldcoast",imageUrl:aH,description:o("editor:editor.themes.goldCoast")},{id:"crestview",imageUrl:aF,description:o("editor:editor.themes.crestview")}],v=(t=(0,r.A)(d().mark(function e(){var t;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n(94680)("./".concat(p));case 2:i((t=e.sent).sections,t.meta),b(!1),s(!1);case 6:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,eI.jsxs)(eM.A,{title:o("editor:editor.selectATemplate"),open:c,onClose:function(){return s(!1)},anchor:"right",width:"100vw",contentSx:{backgroundColor:"rgb(235, 236, 239)",minHeight:"calc(100vh - 55px)",overflowY:"auto",p:2},slotProps:{root:{keepMounted:!1}},children:[(0,eI.jsxs)(h.A,{container:!0,spacing:3,children:[j.map(function(e){return(0,eI.jsx)(h.A,{size:{xs:12,md:4},children:(0,eI.jsxs)("div",{role:"button",tabIndex:0,onKeyDown:function(t){("Enter"===t.key||" "===t.key)&&(b(!0),x(e.id))},className:"".concat(aq," container ").concat(a===e.id?"selected":""),onClick:function(){b(!0),x(e.id)},"data-testid":"".concat(l,"-").concat(e.id),children:[(0,eI.jsx)("div",{className:"".concat(aq," image"),style:{backgroundImage:"url(".concat(e.imageUrl,")")}}),(0,eI.jsx)("p",{className:"".concat(aq," description container ").concat(a===e.id?"selected":""),children:e.description})]})},e.id)}),aQ]}),(0,eI.jsxs)(aW.A,{open:f,onClose:function(){return b(!1)},maxWidth:"sm",fullWidth:!0,children:[(0,eI.jsx)(aM.A,{children:o("editor:editor.templateModalHeader")}),(0,eI.jsx)(aK.A,{children:(0,eI.jsxs)("p",{children:[o("editor:editor.templateModalTitle"),(0,eI.jsx)("br",{}),o("editor:editor.templateModalDescription")]})}),(0,eI.jsxs)(aY.A,{children:[(0,eI.jsx)(em.A,{onClick:function(){s(!1),b(!1)},"data-testid":"".concat(l,"-cancelBtn"),children:o("common:common.cancel")}),(0,eI.jsx)(em.A,{variant:"contained",color:"primary",onClick:v,"data-testid":"".concat(l,"-saveBtn"),children:o("common:common.yesImSure")}
1)]})]})]})}),aG=(0,o.Ng)(function(e){return{currentTemplateId:e.hubPageRevision.revision.meta.templateId,isDrawerVisible:e.hubPageRevision.showTemplatesDrawer,dataTestId:"admin-hubs-editor-sidebar-template-gallery"}},function(e){return(0,i.zH)({selectTemplate:er.H0,showTemplatesDrawer:er.Es},e)})(aZ);var aX={styles:(0,eI.jsx)(c(),{id:"2730462349",children:[".sidebar.jsx-2730462349{height:100%;overflow-y:auto;border:1px solid rgb(232,232,232);margin-right:2px;position:relative;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;gap:12px;box-sizing:border-box;}",".drawer-title.jsx-2730462349{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;gap:8px;}",".drawer-title-left-icon.jsx-2730462349{font-size:24px;}",".drawer-title-content.jsx-2730462349{margin-left:8px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;text-transform:capitalize;font-size:18px;font-weight:bold;min-width:0;}",".drawer-title-content-icon.jsx-2730462349{font-size:18px;margin-right:12px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}"]}),className:"jsx-2730462349"},a$=aX.className,aJ=aX.styles;let a0=(0,m.withTranslation)(["common","editor"])((0,I.withRouter)(function(e){e.t;var t=e.router,n=e.hubName,o=(e.currentSectionId,e.setCurrentSectionId,e.dataTestId);return(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsx)(aG,{}),(0,eI.jsxs)("div",{className:"jsx-3316501482 "+"".concat(a$," sidebar"),children:[(0,eI.jsxs)(x.A,{sx:{border:1,borderColor:"divider",borderRadius:1,bgcolor:"rgb(235, 236, 239)",overflow:"hidden",flex:"1 1 auto",minHeight:0,display:"flex",flexDirection:"column"},children:[(0,eI.jsxs)(x.A,{component:"div",className:"".concat(a$," drawer-title"),role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&t.push("/admin/site_hubs")},onClick:function(){t.push("/admin/site_hubs")},"data-testid":o,sx:{px:2,py:1.5,borderBottom:1,borderColor:"divider",flexShrink:0,bgcolor:"background.paper"},children:[(0,eI.jsx)(D.A,{className:"".concat(a$," drawer-title-left-icon"),"data-testid":"hub-page-drawer-left-arrow"}),(0,eI.jsxs)("span",{className:"jsx-3316501482 "+"".concat(a$," drawer-title-content"),children:[(0,eI.jsx)("span",{className:"jsx-3316501482 "+"".concat(a$," drawer-title-content-icon"),children:(0,eI.jsx)(H.A,{sx:{fontSize:30,color:"#40A9FF"}})}),(0,eI.jsx)(z.A,{component:"span",variant:"subtitle1",color:"text.primary",sx:{fontWeight:700,overflow:"hidden",textOverflow:"ellipsis"},children:R()(n,{length:28})})]})]}),(0,eI.jsx)(x.A,{sx:{flex:1,minHeight:0,overflow:"auto",p:1.5},children:(0,eI.jsx)(a_,{})})]}),(0,eI.jsx)(c(),{id:"3316501482",children:[".hpe-card{background-color:#fff;border-radius:8px;margin-bottom:12px;border:1px solid rgba(0,0,0,0.08);}",".hpe-card:hover{cursor:pointer;box-shadow:rgba(0,0,0,0.1) 0px 10px 15px -3px, rgba(0,0,0,0.05) 0px 4px 6px -2px;}",".hpe-section{margin-bottom:-18px;}",".hpe-section-header{padding:8px 4px;margin-left:0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;gap:8px;width:100%;}",".hpe-icon{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;min-width:32px;height:24px;font-size:24px;padding-right:0;}"]}),aJ]})]})})),a1=(0,o.Ng)(function(e){return{currentSectionId:e.hubPageRevision.currentSectionId,hubName:e.hub.hub.name,dataTestId:"admin-hubs-editor-sidebar-root"}},function(e){return(0,i.zH)({setCurrentSectionId:er.Qu},e)})(a0);var a2={minHeight:36,boxSizing:"border-box"};let a3=(0,m.withTranslation)(["editor"])(function(e){var t,n=e.t,o=e.saveHubPageRevision,i=e.updateHubPageRevision,a=e.dataTestId,s=(0,u.useState)(!1),c=s[0],l=s[1],m=(t=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return l(!0),i("published",!1),e.next=4,o();case 4:l(!1);case 5:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,eI.jsx)(em.A,{variant:"outlined",onClick:m,loading:c,loadingPosition:"start",className:"ehq-mr-2.5","data-testid":a,sx:a2,children:n("editor:editor.saveAsDraft")})}),a5=(0,o.Ng)(function(){return{dataTestId:"admin-hubs-editor-save-btn"}},function(e){return(0,i.zH)({saveHubPageRevision:er.F2,updateHubPageRevision:er.NG},e)})(a3);var a4=n(51975);let a9=(0,m.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.lastPublishedRevision,i=e.lastRevision,r=e.setHubPageRevision,a=e.currentRevision,s=e.dataTestId,c=(0,u.useState)(!1),l=c[0],d=c[1],m=function(){return d(!1)};return(t=!i||!!i.published,t=!i||!a||!!a.published,o)?(0,eI.jsxs)(eI.Fragment,{children:[t?(0,eI.jsx)(g.A,{placement:"bottom",title:n("editor.restoreDisabledDescriptionInHubPage"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(em.A,{variant:"outlined",disabled:t,"data-testid":s,sx:a2,children:n("editor:editor.restore")})})}):(0,eI.jsx)(em.A,{variant:"outlined",disabled:t,"data-testid":s,onClick:function(){return d(!0)}
1,sx:a2,children:n("editor:editor.restore")}),(0,eI.jsxs)(aW.A,{open:l,onClose:m,role:"alertdialog","aria-labelledby":"hub-restore-published-title","aria-describedby":"hub-restore-published-description",maxWidth:"xs",fullWidth:!0,children:[(0,eI.jsxs)(aM.A,{id:"hub-restore-published-title",sx:{pr:6,position:"relative"},children:[n("editor:editor.restore"),(0,eI.jsx)(w.A,{"aria-label":n("common:common.close"),onClick:m,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(s,"-closeBtn"),children:(0,eI.jsx)(A.A,{fontSize:"small"})})]}),(0,eI.jsxs)(aK.A,{children:[(0,eI.jsx)(a4.A,{id:"hub-restore-published-description",children:n("editor:editor.confirmRestorePublishInHubPage")}),(0,eI.jsx)(a4.A,{sx:{mt:2.5},children:n("editor:editor.confirmRestore")})]}),(0,eI.jsxs)(aY.A,{sx:{px:3,pb:2},children:[(0,eI.jsx)(em.A,{onClick:m,sx:a2,children:n("editor:editor.no")}),(0,eI.jsx)(em.A,{variant:"contained",color:"primary",disableElevation:!0,onClick:function(){r(o),m()},sx:a2,children:n("editor:editor.yes")})]})]})]}):(0,eI.jsx)(g.A,{placement:"top",title:n("editor:editor.restoreDescription"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(em.A,{variant:"outlined",disabled:!0,"data-testid":s,sx:a2,children:n("editor:editor.restore")})})})});var a6=n(61158),a8=n(2956),a7=n(54162);function se(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function st(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?se(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):se(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var sn=function(e){var t;return t=(0,r.A)(d().mark(function t(n,o){var i,r,a,s;return d().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return i={page:1,per_page:1},r={sort:{id:"desc"},published:!0},a=new a6.A(i,r),n({type:a8.A.FETCH_LAST_PUBLISHED_HUB_PAGE_REVISIONS_REQUEST}),t.prev=4,t.next=7,a7.A.query(a,{hubId:e});case 7:var o;s=t.sent,n({type:a8.A.FETCH_LAST_PUBLISHED_HUB_PAGE_REVISIONS_SUCCESS,revision:null!=(o=s[0])&&"function"==typeof o.attributes?st(st({id:o.id},o.attributes()),o.links||{}):o}),t.next=14;break;case 11:t.prev=11,t.t0=t.catch(4),n({type:a8.A.FETCH_LAST_PUBLISHED_HUB_PAGE_REVISIONS_FAILURE,errorMessage:t.t0.statusText||t.t0.status});case 14:case"end":return t.stop()}},t,null,[[4,11]])})),function(e,n){return t.apply(this,arguments)}};let so=(0,o.Ng)(function(e){return{currentRevision:e.hubPageRevision.revision,lastPublishedRevision:e.hubPageRevisions.lastPublishedRevision,lastRevision:e.hubPageRevisions.lastRevision,dataTestId:"admin-hubs-editor-restore-publsihed-btn"}},function(e){return(0,i.zH)({fetchLastPublishedHubPageRevisions:sn,setHubPageRevision:er.cN},e)})(a9);var si={styles:(0,eI.jsx)(c(),{id:"499528257",children:[".share-link.jsx-499528257{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;margin-top:25px;gap:12px;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".share-link-title.jsx-499528257{font-weight:bold;margin-top:5px;}",".share-link-description.jsx-499528257{margin-top:25px;}"]}),className:"jsx-499528257"},sr=si.className,sa=si.styles;let ss=(0,m.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.currentRevision,o=e.isSiteOnBoardingEnabled,i=e.isSiteBlocked,a=e.lockStatus,s=e.token,c=e.dataTestId,l=(0,u.useState)(!1),m=l[0],h=l[1],p=function(){return h(!1)};return(0,u.useEffect)(function(){function e(){return(e=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a();case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}o&&function(){e.apply(this,arguments)}()},[]),(0,eI.jsxs)(eI.Fragment,{children:[n.published?(0,eI.jsx)(g.A,{placement:"bottom",title:t("editor:editor.shareADraftTooltip"),children:(0,eI.jsx)(C.A,{onClick:function(){return h(!0)},disabled:!!n.published,"data-testid":"".concat(c,"-shareADraft"),children:t("editor:editor.shareADraft")})}):(0,eI.jsx)(C.A,{onClick:function(){return h(!0)},disabled:!!n.published,"data-testid":"".concat(c,"-shareADraft"),children:t("editor:editor.shareADraft")}),(0,eI.jsxs)(aW.A,{open:m,onClose:p,maxWidth:"sm",fullWidth:!0,children:[(0,eI.jsxs)(aM.A,{sx:{pr:6,position:"relative"},children:[t("editor:editor.shareAPreview"),(0,eI.jsx)(w.A,{"aria-label":t("common:common.close"),onClick:p,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(c,"-closeBtn"),children:(0,eI.jsx)(A.A,{fontSize:"small"})})]}),(0,eI.jsxs)(aK.A,{children:[(0,eI.jsx)("p",{className:"".concat(sr," share-link-title"),children:t("editor:editor.shareAPreviewTitle")}),(0,eI.jsx)("p",{className:"".concat(sr," share-link-description"),children:t("editor:editor.shareAPreviewDescription")}),(0,eI.jsxs)("div",{className:"".concat(sr," share-link"),children:[(0,eI.jsx)(es.A,{id:"preview-link",sx:{flex:1,minWidth:220},value:o&&i?"".concat(window.location.href,"/live-preview?draft=true&token=").concat(s):"".concat(window.location.href,"/live-preview?draft=true"),"data-testid":"".concat(c,"-draft-link"),size:"medium",fullWidth:!0,variant:"outlined",slotProps:{htmlInput:{readOnly:!0}}}),(0,eI.jsx)(em.A,{variant:"contained",color:"primary",onClick:function(){document.getElementById("preview-link").select(),document.execCommand("copy")},"data-testid":"".concat(c,"-copy"),sx:a2,startIcon:(0,eI.jsx)(e4.A,{}),children:t("editor:editor.copy")})]})]})]}),sa]})}),sc=(0,o.Ng)(function(e){return{currentRevision:e.hubPageRevision.revision,token:e.currentSite.site.token,isSiteBlocked:e.currentSite.site.blocked,isSiteOnBoardingEnabled:e.features.features.hasOwnProperty("enable_site_onboarding")&&e.features.features.enable_site_onboarding.enabled,dataTestId:"admin-hubs-editor-share-draft-btn"}},function(e){return(0,i.zH)({lockStatus:ea.oj},e)})(ss);var sl={styles:(0,eI.jsx)(c(),{id:"2370514378",children:[".preview-draft-button.jsx-2370514378{border-radius:5px;}"]}),className:"jsx-2370514378"},sd=sl.className,su=sl.styles;let sm=(0,m.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.currentRevision,i=e.isSiteOnBoardingEnabled,a=e.isSiteBlocked,s=e.lockStatus,c=e.token,l=e.permalink,m=e.dataTestId;(0,u.useEffect)(function(){function e(){return(e=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s();case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}i&&function(){e.apply(this,arguments)}()},[]);var h=(t=(0,r.A)(d().mark(function e(t){var n,o;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:t.preventDefault(),i&&a?(n="/hub-page/".concat(l,"?draft=true&token=").concat(c),window.open(n)):(o="/hub-page/".concat(l,"?draft=true"),window.open(o));case 2:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)});return(0,eI.jsxs)(eI.Fragment,{children:[o.published?(0,eI.jsx)(g.A,{placement:"bottom",title:n("editor:editor.previewDraftTooltip"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(em.A,{variant:"outlined",disabled:!0,className:"".concat(sd," preview-draft-button ehq-mr-2.5"),"data-testid":m,sx:a2,children:n("editor:editor.previewDraft")})})}):(0,eI.jsx)(g.A,{placement:"bottom",title:n("editor:editor.previewNoDraftTooltip"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(em.A,{variant:"outlined",disabled:!!o.published,className:"".concat(sd," preview-draft-button ehq-mr-2.5"),onClick:h,"data-testid":m,sx:a2,children:n("editor:editor.previewDraft")})})}),su]})}),sh=(0,o.Ng)(function(e){return{currentRevision:e.hubPageRevision.revision,permalink:e.hub.hub.permalink,token:e.currentSite.site.token,isSiteBlocked:e.currentSite.site.blocked,isSiteOnBoardingEnabled:e.features.features.hasOwnProperty("enable_site_onboarding")&&e.features.features.enable_site_onboarding.enabled,dataTestId:"admin-hubs-editor-preview-draft-btn"}},function(e){return(0,i.zH)({lockStatus:ea.oj},e)})(sm);var sp=n(37375);function sx(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function sg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?sx(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sx(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let sf=(0,m.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.saveHubPageRevision,i=(e.currentUserRole,e.updateHubPageRevision),a=e.fetchLastPublishedHubPageRevisions,s=e.isHomePagePublished,c=e.hubId,l=e.saveHub,m=e.updateHub,h=e.dataTestId,p=(0,u.useState)(!1),x=p[0],f=p[1],b=(0,u.useState)(!1),j=b[0],v=b[1],y=function(){return v(!1)},C=(t=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return v(!1),f(!0),i("published",!0),e.next=5,o();case 5:return e.next=7,m("isNewHub",!0);case 7:return e.next=9,m("state","published");case 9:return e.next=11,l();case 11:return e.next=13,a(c);case 13:f(!1);case 14:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return s?(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(em.A,{variant:"contained",color:"primary",disabled:x,"data-testid":h,onClick:function(){return v(!0)},sx:sg(sg({},a2),{},{mr:2}),startIcon:x?(0,eI.jsx)(ok.A,{color:"inherit",size:18}):null,children:n("editor:editor.publish")}),(0,eI.jsxs)(aW.A,{open:j,onClose:y,role:"alertdialog","aria-labelledby":"publish-hub-title","aria-describedby":"publish-hub-description",maxWidth:"xs",fullWidth:!0,children:[(0,eI.jsxs)(aM.A,{id:"publish-hub-title",sx:{pr:6,position:"relative"},children:[n("editor:editor.publish"),(0,eI.jsx)(w.A,{"aria-label":n("common:common.close"),onClick:y,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(h,"-closeBtn"),children:(0,eI.jsx)(A.A,{fontSize:"small"})})]}),(0,eI.jsxs)(aK.A,{children:[(0,eI.jsx)(a4.A,{id:"publish-hub-description",children:n("editor:editor.confirmPublishTextHubPage")}),(0,eI.jsx)(a4.A,{sx:{my:2.5},children:n("editor:editor.confirmStepHubPage")}),(0,eI.jsx)(a4.A,{children:n("editor:editor.confirmPublish")})]}),(0,eI.jsxs)(aY.A,{sx:{px:3,pb:2},children:[(0,eI.jsx)(em.A,{onClick:y,sx:a2,children:n("editor:editor.no")}),(0,eI.jsx)(em.A,{variant:"contained",color:"primary",disableElevation:!0,onClick:C,sx:a2,children:n("editor:editor.yes")})]})]})]}):(0,eI.jsx)(g.A,{placement:"bottom",title:n("editor:editor.publishDescriptionHubPage"),children:(0,eI.jsx)(em.A,{"data-testid":h,disabled:!0,sx:sg(sg({},a2),{},{mr:2}),children:n("editor:editor.publish")})})}),sb=(0,o.Ng)(function(e){var t;return{currentUserRole:e.currentUser.user.roleName,isHomePagePublished:null==(t=e.homePageRevisions.lastPublishedRevision)?void 0:t.published,hubId:e.hub.hub.id,dataTestId:"admin-hubs-editor-publish-btn"}},function(e){return(0,i.zH)({saveHub:sp.t7,updateHub:sp.nk,saveHubPageRevision:er.F2,updateHubPageRevision:er.NG,fetchLastPublishedHubPageRevisions:sn},e)})(sf);var sj=n(73664),sv=n(83886);function sy(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function sA(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sy(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sy(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var sw=function(){var e;return e=(0,r.A)(d().mark(function e(t,n){var o,i;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t({type:sv.A.ASSOCIATE_HUB_SEGMENTS_REQUEST}),o=n().hubSegments.segments,i=new sj.A(sA(sA({},n().hub.hub),{},{segments:o.map(function(e){return{id:e}})})),e.prev=3,e.next=6,i.associateSegments();case 6:t({type:sv.A.ASSOCIATE_HUB_SEGMENTS_SUCCESS}),e.next=12;break;case 9:e.prev=9,e.t0=e.catch(3),t({type:sv.A.ASSOCIATE_HUB_SEGMENTS_FAILURE,errorMessage:e.t0.message||e.t0.statusText||e.t0.status});case 12:case"end":return e.stop()}},e,null,[[3,9]])})),function(t,n){return e.apply(this,arguments)}},sC=function(e){return{type:sv.A.TOGGLE_HUB_SEGMENT,id:e}},sT=n(99371),sk=n(89082),sS=n(10927),sI=n(67761),sP=n(21045),sO=n(20362),sN=n(96633),sz=n(80818),sD=n(44739),sH=n(30528),sF=n(56272),sR=n(87676),sE=n(68993),sU=n(69307),sB=n(66973),sL=n(69594),s_=n(26796);let sW=(0,m.withTranslation)(["common","project"])(function(e){var t=e.count,n=e.users,o=e.t,i=e.loading,r=e.dataTestId,a=(0,u.useState)(!1),s=a[0],c=a[1],l=(0,u.useState)(""),d=l[0],m=l[1],h=(0,u.useMemo)(function(){return Object.keys(n).map(function(e){return n[e]}).filter(function(e){return e.login.includes(d)||e.email.includes(d)})},[n,d]),p=(0,u.useMemo)(function(){return[{key:"login",label:o("project:project.screenName"),dataIndex:"login"},{key:"email",label:o("common:common.email"),dataIndex:"email"},{key:"createdAt",label:o("common:common.joinedOn"),dataIndex:"createdAt",format:function(e){return e?(0,s_.I3)(e):""}},{key:"lastSeenAt",label:o("common:common.lastSeen"),dataIndex:"lastSeenAt",format:function(e){return e?(0,s_.PI)(e):""}}]},[o]),g=o("project:project.participantsCount",{count:t}),f=function(){t&&c(function(e){return!e})};return(0,eI.jsxs)(x.A,{sx:{mb:2},children:[(0,eI.jsxs)(x.A,{sx:{display:"inline-flex",alignItems:"center",gap:1},children:[i?(0,eI.jsx)(ok.A,{size:20}):null,(0,eI.jsx)(em.A,{type:"button",variant:"text",onClick:f,disabled:!t,"data-testid":"".concat(r,"-open-button"),sx:{p:0,minWidth:0,fontWeight:400,"&:hover":{bgcolor:"transparent",textDecoration:"underline"}},children:g})]}),(0,eI.jsxs)(aW.A,{open:s,onClose:f,maxWidth:"md",fullWidth:!0,"data-testid":"".concat(r,"-dialog"),children:[(0,eI.jsxs)(aM.A,{sx:{pr:6,position:"relative"},children:[g,(0,eI.jsx)(w.A,{"aria-label":o("common:common.close"),onClick:f,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(r,"-closeBtn"),children:(0,eI.jsx)(A.A,{fontSize:"small"})})]}),(0,eI.jsxs)(aK.A,{children:[(0,eI.jsx)(es.A,{placeholder:o("common:common.search"),value:d,onChange:function(e){return m(e.target.value.trim())},"data-testid":"".concat(r,"-search"),fullWidth:!0,size:"medium",sx:{mb:1},slotProps:{input:{startAdornment:(0,eI.jsx)(sH.A,{position:"start",children:(0,eI.jsx)(sD.A,{fontSize:"small"})})}}}),(0,eI.jsx)(sU.A,{children:(0,eI.jsxs)(sF.A,{size:"small",className:"testId-".concat(r,"-table"),"data-testid":"".concat(r,"-table"),children:[(0,eI.jsx)(sB.A,{children:(0,eI.jsx)(sL.A,{children:p.map(function(e){return(0,eI.jsx)(sE.A,{children:e.label},e.key)})})}),(0,eI.jsx)(sR.A,{children:h.map(function(e){return(0,eI.jsx)(sL.A,{children:p.map(function(t){return(0,eI.jsx)(sE.A,{children:t.format?t.format(e[t.dataIndex]):e[t.dataIndex]},t.key)})},e.id||e.login)})})]})})]})]})]})}),sM=(0,o.Ng)(function(e){return{loading:e.usersBySegments.fetching,users:e.usersBySegments.users,count:Object.keys(e.usersBySegments.users).length,dataTestId:"admin-hubs-editor-drawers-hub-settings-applicable-users"}},{})(sW);function sK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function sY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?sK(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let sV=(0,m.withTranslation)(["project","errors"])(function(e){var t=e.t,n=e.value,o=e.options,i=e.toggleHubSegment,r=e.fetchUsers,a=e.segments,s=e.dataTestId,c=(0,u.useRef)(null),l=o.filter(function(e){return n.includes(e.id)}),d=0===a.length;return(0,eI.jsxs)(x.A,{sx:{bgcolor:"grey.100",p:1.25,mt:1.25,borderRadius:1},children:[(0,eI.jsx)(sM,{}),(0,eI.jsx)(x.A,{sx:{mb:0},children:(0,eI.jsx)(tu.A,{size:"medium",multiple:!0,className:"testId-".concat(s,"-selectGroups"),options:o,value:l,onChange:function(e,t){var o=new Set(t.map(function(e){return e.id})),a=new Set(n);a.forEach(function(e){o.has(e)||i(e)}),o.forEach(function(e){a.has(e)||i(e)}),c.current&&clearTimeout(c.current),c.current=setTimeout(function(){r(!0)},1e3)},getOptionLabel:function(e){return e.name},isOptionEqualToValue:function(e,t){return e.id===t.id},filterSelectedOptions:!0,sx:tm.OP,slotProps:tm.HE,renderOption:tm.$S,renderInput:function(e){return(0,eI.jsx)(td.A,sY(sY({},e),{},{placeholder:t("project:project.selectGroups"),error:d,helperText:d?t("errors:errors.codes.blank"):" ",required:!0}))}})})]})});var sq=n(73706),sQ=n(33836),sZ=n.n(sQ);function sG(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function sX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sG(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sG(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let s$=(0,o.Ng)(function(e){return{value:e.hubSegments.segments,options:sZ()(e.participantSegments.segments),fetching:e.participantSegments.fetching,fetchError:e.participantSegments.fetchError,doneFetching:e.participantSegments.doneFetching,segments:e.hubSegments.segments,parentHubVisibility:e.hub.hub.visibilityMode,dataTestId:"admin-hubs-editor-drawers-hub-setttings-group-selctor"}},function(e){return(0,i.zH)({fetchSegments:sz.vR,toggleHubSegment:sC,fetchUsers:sT.h},e)},function(e,t){return sX(sX({},e),{},{fetchData:function(){return Promise.all([t.fetchUsers(!0),t.fetchSegments()])},fetchUsers:t.fetchUsers,toggleHubSegment:t.toggleHubSegment})})((0,sq.A)(sV));var sJ=n(43067);let s0=(0,o.Ng)(function(e){return{fetching:e.hub.fetching,permalink:e.hub.hub.permalink,holdPostRequest:e.hub.hub.holdPostRequest,errors:e.hub.fetchError||e.hub.errors,name:e.hub.hub.name||"",dataTestId:"admin-hubs-editor-drawers-hub-settings-permalink"}},function(e){return(0,i.zH)({disable:sp.nk,generatePermalink:sp.xR},e)})(sJ.A);function s1(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function s2(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s1(Object(n),!0).forEach(function(t){(0,E.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s1(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function s3(e,t){var n="u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e){if(e){if("string"==typeof e)return s5(e,void 0);var t=({}).toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?s5(e,void 0):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}
1}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw r}}}}function s5(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}var s4=(0,sS.Z)();let s9=(0,m.withTranslation)(["editor","common"])((0,I.withRouter)(function(e){var t,n,o,i,s,c,l,m,h,p,g=e.t,f=e.hub,b=e.administrators,j=e.updateHub,v=e.saveHub,y=e.associateHubSegments,C=e.saving,T=e.protectedHubsOnNewAE,k=(e.fetching,e.router),S=e.deleteHub,I=e.deleting,P=e.currentUserRole,O=e.tags,N=e.updateQueries,D=e.authorizeHubAdmin,H=e.unauthorizeHubAdmin,F=e.associatedHubAdmins,R=e.fetchUsers,E=e.dataTestId,U=e.homePageRevision,B=e.updateSectionData,L=e.saveHomePageRevision,_=(0,u.useState)(!1),W=_[0],M=_[1],K=(0,u.useState)(!1),Y=K[0],V=K[1],q=(0,u.useState)("details"),Q=q[0],Z=q[1],G=(0,u.useState)(!1),X=G[0],$=G[1],J=(0,u.useState)(!1),ee=J[0],et=J[1],en=(0,u.useState)(""),eo=en[0],ei=en[1],er=T&&"Protected"===f.visibilityMode,ea=C||ee||I;(0,u.useEffect)(function(){return N({per_page:9999}),F(f.id),er&&R(!0),function(){N({per_page:25,page:1})}},[]);var es=[{name:g("editor:editor.public"),value:"Public",selectedImage:"/static/assets/images/tools/VisibilityIcon-1-Selected.png",text:g("editor:editor.publicVisibilityHelp")},{name:g("editor:editor.protected"),value:"Protected",selectedImage:"/static/assets/images/tools/VisibilityIcon-3-Selected.png",text:g("editor:editor.protectedVisibilityHelp")}],ec=(o=(0,r.A)(d().mark(function e(t){var n,o;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(o=null==(n=t.target.files)?void 0:n[0]){e.next=3;break}return e.abrupt("return");case 3:return V(!0),e.prev=4,e.next=7,eb.A.perform(o);case 7:j("imageUrl",e.sent);case 9:return e.prev=9,V(!1),t.target.value="",e.finish(9);case 13:case"end":return e.stop()}},e,null,[[4,,9,13]])})),function(e){return o.apply(this,arguments)}),el=function(){return b.filter(function(e){return"hub_admin"===e.roleName&&!0!==e.blocked})},eu=(i=(0,r.A)(d().mark(function e(t,n){var o,i,r,a,s,c,l,u,m,h,p;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!ee){e.next=2;break}return e.abrupt("return");case 2:if(o=n.map(function(e){return e.id}),i=f.userIds||[],r=o.filter(function(e){return!i.includes(e)}),a=i.filter(function(e){return!o.includes(e)}),!(!r.length&&!a.length)){e.next=8;break}return e.abrupt("return");
1case 8:s=el(),et(!0),e.prev=10,c=s3(r),e.prev=12,u=d().mark(function e(){var t,n;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t=l.value,!(n=s.find(function(e){return e.id===t}))){e.next=5;break}return e.next=5,D(f.id,n.id);case 5:case"end":return e.stop()}},e)}),c.s();case 15:if((l=c.n()).done){e.next=19;break}return e.delegateYield(u(),"t0",17);case 17:e.next=15;break;case 19:e.next=24;break;case 21:e.prev=21,e.t1=e.catch(12),c.e(e.t1);case 24:return e.prev=24,c.f(),e.finish(24);case 27:m=s3(a),e.prev=28,p=d().mark(function e(){var t,n;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t=h.value,!(n=s.find(function(e){return e.id===t}))){e.next=5;break}return e.next=5,H(f.id,n.id);case 5:case"end":return e.stop()}},e)}),m.s();case 31:if((h=m.n()).done){e.next=35;break}return e.delegateYield(p(),"t2",33);case 33:e.next=31;break;case 35:e.next=40;break;case 37:e.prev=37,e.t3=e.catch(28),m.e(e.t3);case 40:return e.prev=40,m.f(),e.finish(40);case 43:return e.prev=43,et(!1),e.finish(43);case 46:case"end":return e.stop()}},e,null,[[10,,43,46],[12,21,24,27],[28,37,40,43]])})),function(e,t){return i.apply(this,arguments)}),ex=(s=(0,r.A)(d().mark(function e(t){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,S(t);case 2:f.deleteError||($(!1),k.push("/admin/site_hubs"));case 3:case"end":return e.stop()}},e)})),function(e){return s.apply(this,arguments)}),ef=(c=(0,r.A)(d().mark(function e(){var t,n;return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t=f.id,n=f.permalink,U.sections.forEach(function(e,o){var i;null==e||null==(i=e.data)||i.forEach(function(e,i){(null==e?void 0:e.hubId)===t&&B(null!=e&&e.ctaLink?"ctaLink":"permalink",n,o,i)})}),e.next=5,L();case 5:case"end":return e.stop()}},e)})),function(){return c.apply(this,arguments)}),ej=(l=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,v();case 2:return e.next=4,y();case 4:f.permalink&&f.permalink!==k.query.hubPermalink&&k.push("/admin/sites/editors/hub-page/[hubPermalink]","/admin/sites/editors/hub-page/".concat(f.permalink),{shallow:!0}),f.saveError||(ef(),M(!1));case 6:case"end":return e.stop()}},e)})),function(){return l.apply(this,arguments)}),ev=function(){ea||M(!1)};return(0,eI.jsxs)("div",{children:[(0,eI.jsx)(w.A,{"data-testid":"hub-page-settings",onClick:function(){F(f.id),M(!0)},"aria-label":g("editor:editor.settings"),size:"medium",sx:{color:"text.primary"},children:(0,eI.jsx)(sO.A,{})}),(0,eI.jsxs)(ed.A,{title:g("editor:editor.settings"),width:"60%",visible:W,onClose:ev,footer:(0,eI.jsxs)(nZ.A,{direction:"row",spacing:1,flexWrap:"wrap",useFlexGap:!0,children:[(0,eI.jsx)(em.A,{variant:"contained",color:"primary",disabled:ea,onClick:ej,"data-testid":"".concat(E,"-save"),sx:a2,startIcon:C?(0,eI.jsx)(ok.A,{color:"inherit",size:18}):null,children:g("editor:editor.save")}),(0,eI.jsx)(em.A,{variant:"outlined",onClick:ev,disabled:ea,"data-testid":"".concat(E,"-close"),sx:a2,children:g("editor:editor.cancel")}),P!==sN.HubAdmin?(0,eI.jsxs)(eI.Fragment,{children:[(0,eI.jsx)(em.A,{color:"error",variant:"outlined",disabled:I||ea,onClick:function(){return $(!0)},"data-testid":"delete-hub",startIcon:(0,eI.jsx)(te.A,{}),sx:s2(s2({},a2),{},{ml:"auto"}),children:g("editor:editor.deleteHub")}),(0,eI.jsxs)(aW.A,{open:X,onClose:function(){I||$(!1)},maxWidth:"sm",fullWidth:!0,"data-testid":"delete-hub-confirm-dialog",children:[(0,eI.jsxs)(aM.A,{sx:{pr:6,position:"relative"},children:[g("editor:editor.deleteHub"),(0,eI.jsx)(w.A,{"aria-label":g("common:common.close"),onClick:function(){return $(!1)},size:"small",disabled:I,sx:{position:"absolute",right:8,top:8},"data-testid":"delete-hub-closeBtn",children:(0,eI.jsx)(A.A,{fontSize:"small"})})]}),(0,eI.jsxs)(aK.A,{children:[(0,eI.jsx)(z.A,{component:"div",variant:"body1",children:g("editor:editor.confirmHubDeleteText")}),(0,eI.jsx)(z.A,{component:"div",variant:"body1",sx:{my:1.25},children:g("editor:editor.confirmHubDeleteSubText")})]}),(0,eI.jsxs)(aY.A,{sx:{px:3,pb:2},children:[(0,eI.jsx)(em.A,{onClick:function(){return $(!1)},disabled:I,sx:a2,"data-testid":"delete-hub-cancel-button",children:g("editor:editor.cancel")}),(0,eI.jsx)(em.A,{color:"error",variant:"contained",disabled:I,onClick:function(){return ex(f.id)},sx:a2,"data-testid":"delete-hub-confirm-button",startIcon:I?(0,eI.jsx)(ok.A,{color:"inherit",size:18}):null,children:g("editor:editor.delete")})]})]})]}):null]}),disableEnforceFocus:!0,closeDisabled:ea,"data-testid":E,children:[(0,eI.jsxs)(ep.A,{value:Q,onChange:function(e,t){return Z(t)},textColor:"inherit",sx:eA.R,children:[(0,eI.jsx)(eh.A,{value:"details",sx:{textTransform:"capitalize"},label:(0,eI.jsx)("span",{"data-testid":"".concat(E,"-details-tab"),children:g("editor:editor.details")})}),(0,eI.jsx)(eh.A,{value:"visibility",sx:{textTransform:"capitalize"},label:(0,eI.jsx)("span",{"data-testid":"".concat(E,"-visibility-tab"),children:g("editor:editor.visibility")})}),(0,eI.jsx)(eh.A,{value:"hubImage",sx:{textTransform:"capitalize"},label:(0,eI.jsx)("span",{"data-testid":"".concat(E,"-hubImage-tab"),children:g("editor:editor.hubImage")})})]}),(0,eI.jsxs)(x.A,{role:"tabpanel",sx:{pt:2},children:["details"===Q?(h=(m=el()).filter(function(e){return(f.userIds||[]).includes(e.id)}),(0,eI.jsxs)(nZ.A,{spacing:3,children:[(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hubTitle")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hubTitleDescription")}),(0,eI.jsx)(td.A,{size:"medium",fullWidth:!0,placeholder:g("editor:editor.name"),defaultValue:f.name,onChange:function(e){return j("name",e.target.value)},"data-testid":"hub-page-edit-name"})]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hubDescriptionTitle")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hubDescription")}),(0,eI.jsx)(tp.A,{name:"description",value:f.description,onChange:function(e){return j("description",e.target.value)},config:(0,tx.J)("HomePageBanner"),dataTestId:"froala-editor-hub-settings-description"})]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.assignToAdmins")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.assignToAdminsDescription")}),(0,eI.jsx)(tu.A,{size:"medium",multiple:!0,className:"testId-".concat(E,"-assignToAdmins"),"data-testid":"".concat(E,"-assignToAdmins"),options:m,value:h,onChange:eu,getOptionLabel:function(e){return e.login},isOptionEqualToValue:function(e,t){return e.id===t.id},filterSelectedOptions:!0,disabled:ee,loading:ee,renderInput:function(e){return(0,eI.jsx)(td.A,s2(s2({},e),{},{placeholder:g("editor:editor.pleaseSelect"),"data-testid":"".concat(E,"-assignToAdmins-input")}))}})]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hubTags")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hubTagsDescription")}),(0,eI.jsx)(tu.A,{size:"medium",multiple:!0,freeSolo:!0,disableClearable:!0,selectOnFocus:!0,clearOnBlur:!0,handleHomeEndKeys:!0,className:"testId-".concat(E,"-hubTags"),"data-testid":"".concat(E,"-hubTags"),options:O.map(function(e){return e.name}),value:f.platformAnalyticsTagList||[],inputValue:eo,onInputChange:function(e,t,n){"reset"!==n&&ei(t)},onChange:function(e,t){j("platformAnalyticsTagList",t.filter(function(e){return e.trim().length>0})),ei("")},onBlur:function(){var e=eo.trim();if(e){var t=f.platformAnalyticsTagList||[];t.includes(e)||j("platformAnalyticsTagList",[].concat((0,a.A)(t),[e])),ei("")}},filterOptions:function(e,t){var n=s4(e,t),o=t.inputValue.trim(),i=f.platformAnalyticsTagList||[];return!o||n.includes(o)||i.includes(o)||n.push(o),n},renderInput:function(e){return(0,eI.jsx)(td.A,s2(s2({},e),{},{placeholder:(f.platformAnalyticsTagList||[]).length?void 0:g("editor:editor.pleaseSelect"),"data-testid":"".concat(E,"-hubTags-input")}))}})]})]})):null,"visibility"===Q?(p=T&&"Protected"===f.visibilityMode,(0,eI.jsxs)(nZ.A,{spacing:3,children:[(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.visibilityType")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.visibilityTypeDescription")}),(0,eI.jsx)(x.A,{sx:{my:2,py:2,px:2,borderRadius:1,bgcolor:"grey.50",border:1,borderColor:"divider"},children:(t=f.visibilityMode||"Public",(n=tl()(es,function(e){return e.value===t}))?(0,eI.jsxs)(nZ.A,{direction:"row",spacing:1,alignItems:"center",children:[(0,eI.jsx)(x.A,{component:"img",src:n.selectedImage,alt:"",sx:{height:30,width:"auto",display:"block"}}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(z.A,{variant:"body2",color:"text.primary",sx:{lineHeight:"20px",mb:0},children:n.name}),(0,eI.jsx)(eW.A,{sx:{m:0},children:n.text})]})]}):null)}),p?(0,eI.jsx)(s$,{isHubPageEditor:!0}):null]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hub.permalink")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hub.permalinkDescription")}),(0,eI.jsx)(s0,{})]})]})):null,"hubImage"===Q?(0,eI.jsxs)(nZ.A,{spacing:3,children:[(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hub.hubImage")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hub.hubImageDescription")}),(0,eI.jsxs)(x.A,{sx:{width:250},children:[(0,eI.jsxs)(x.A,{sx:{position:"relative"},children:[Y?(0,eI.jsx)(x.A,{sx:{position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center",bgcolor:"action.hover",borderRadius:1,zIndex:1},children:(0,eI.jsx)(ok.A,{})}):null,f.imageUrl?(0,eI.jsx)(x.A,{sx:{width:250,height:200,mb:1.25,borderRadius:1,bgcolor:"grey.200",backgroundImage:"url(".concat(f.imageUrl,")"),backgroundSize:"contain",backgroundRepeat:"no-repeat",backgroundPosition:"center"}}):(0,eI.jsxs)(x.A,{sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:1,width:250,height:150,mb:1.25,px:2,textAlign:"center",bgcolor:"grey.100",borderRadius:1},children:[(0,eI.jsx)(sP.A,{sx:{fontSize:30,color:"action.disabled"}}),(0,eI.jsx)(eW.A,{children:g("editor:editor.image.uploadHint")})]})]}),(0,eI.jsxs)(nZ.A,{direction:"row",spacing:1,alignItems:"center",justifyContent:"space-between",sx:{mt:1,width:1},children:[(0,eI.jsxs)(em.A,{component:"label",variant:"contained",color:"primary",disabled:Y,startIcon:(0,eI.jsx)(sI.A,{}),sx:a2,children:[g("editor:editor.update"),(0,eI.jsx)("input",{type:"file",hidden:!0,accept:"image/*",disabled:Y,onChange:ec})]}),(0,eI.jsx)(eg.A,{size:"small","data-testid":"".concat(E,"-delete-button"),disabled:Y||!f.imageUrl,onClick:function(){j("imageUrl","")}})]})]})]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.hub.imageCaption")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.hub.imageCaptionDescription")}),(0,eI.jsx)(td.A,{size:"medium","data-testid":"".concat(E,"-imageCaption"),placeholder:g("editor:editor.enterAC
1aption"),defaultValue:f.imageCaption,onChange:function(e){return j("imageCaption",e.target.value)},fullWidth:!0})]}),(0,eI.jsxs)(x.A,{children:[(0,eI.jsx)(eZ.A,{label:g("editor:editor.imageDescription")}),(0,eI.jsx)(eW.A,{sx:{mb:1.25},children:g("editor:editor.imageDescriptionHelpText")}),(0,eI.jsx)(td.A,{size:"medium","data-testid":"".concat(E,"-description"),multiline:!0,minRows:3,placeholder:g("editor:editor.hub.description"),defaultValue:f.imageDescription,onChange:function(e){return j("imageDescription",e.target.value)},fullWidth:!0})]})]}):null]})]})]})}));var s6=n(21001);let s8=(0,o.Ng)(function(e){return{hub:e.hub.hub,saving:e.hub.saving,fetching:e.hub.fetching,deleting:e.hub.deleting,administrators:e.administrators.administrators,currentUserRole:e.currentUser.user.roleName,protectedHubsOnNewAE:e.features.features.hasOwnProperty("protected_hubs_on_new_appearance_editor")&&e.features.features.protected_hubs_on_new_appearance_editor.enabled,tags:e.tags.tags,dataTestId:"admin-hubs-editor-drawers-hub-settings",homePageRevision:e.homePageRevision.revision}},function(e){return(0,i.zH)({updateHub:sp.nk,saveHub:sp.t7,associateHubSegments:sw,deleteHub:sp.J4,updateQueries:sk.yg,fetchHubAdmins:sk.SL,authorizeHubAdmin:sp.WV,unauthorizeHubAdmin:sp.TQ,associatedHubAdmins:sp.wE,fetchUsers:sT.h,updateSectionData:s6.pZ,saveHomePageRevision:s6.Z0},e)})(s9);var s7=N()(function(){return Promise.all([n.e(24519),n.e(9653),n.e(45905),n.e(8470)]).then(n.bind(n,90242))},{ssr:!1,loadableGenerated:{webpack:function(){return[90242]}}}),ce={styles:(0,eI.jsx)(c(),{id:"2727620719",children:[".sidebar-container.jsx-2727620719{overflow:hidden;position:relative;height:100%;width:100%;min-width:0;box-sizing:border-box;}",".buttons-container.jsx-2727620719{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;padding:24px 0;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}",".right-content.jsx-2727620719{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".hub-page-viewer-container.jsx-2727620719{box-shadow:0 0 10px 5px rgba(0,21,41,0.14);-webkit-flex:1;-ms-flex:1;flex:1;min-height:0;overflow-y:auto;border-radius:8px;border:1px solid rgba(0,0,0,0.08);}",".hub-page-viewer.jsx-2727620719{height:100%;overflow:auto;box-shadow:0 0 10px 5px rgba(0,21,41,0.14);}",".live-preview-drawer-header.jsx-2727620719{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16px;margin:16px 0 24px;}",".hub-page-live-previewer.jsx-2727620719{height:calc(100vh - 110px);box-shadow:0 0 10px 5px rgba(0,21,41,0.14);margin:0 auto;border-radius:8px;}",".preview-container.jsx-2727620719{padding:0 24px 24px;height:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;box-sizing:border-box;}",".draft-buttons-group-container.jsx-2727620719{margin-right:8px;}",".live-preview-buttons.jsx-2727620719{width:auto;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".hidden-live-preview.jsx-2727620719{display:none;}"]}),className:"jsx-2727620719"},ct=ce.className,cn=ce.styles;let co=(0,m.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.hub,i=(e.updateQuery,e.fetchProjects,e.updateFilters),s=e.hasUnsavedChanges,l=e.fetchHubAdmins,m=e.dataTestId,k=e.nonce,O=(0,u.useState)("100%"),N=O[0],z=O[1],D=(0,u.useState)(!1),H=D[0],F=D[1],R=(0,u.useState)(16),E=R[0],U=R[1],B=(t=(0,r.A)(d().mark(function e(){return d().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return F(!1),e.next=3,i({parent_id:o.id});case 3:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)}),L=function(e){e.preventDefault(),e.returnValue=""},_=(0,u.useCallback)(function(){var e=document.getElementById("hub-page-viewer-container");if(e){var t=e.clientWidth;t>801&&t<1200?U(14):t>601&&t<800?U(12):U(10)}},[]);return(0,u.useEffect)(function(){l()},[]),(0,u.useEffect)(function(){return s&&window.addEventListener("beforeunload",L),_(),P().router.change=function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return s?confirm(n("editor:editor.reloadMessage"))?I.Router.prototype.change.apply(P().router,t):new Promise(function(e){return e(!1)}):I.Router.prototype.change.apply(P().router,t)},function(){s&&(window.removeEventListener("beforeunload",L),delete P().router.change)}},[s,n,_]),(0,eI.jsxs)(u.Fragment,{children:[(0,eI.jsxs)(h.A,{id:"main-content",container:!0,spacing:0,sx:{flexWrap:"nowrap",height:"100vh",overflow:"hidden"},children:[(0,eI.jsx)(h.A,{size:{xs:12,md:4},sx:{height:"100%",flexShrink:0,width:{md:"33.3333%"},maxWidth:{md:"33.3333%"},minWidth:{xs:0,md:320}},children:(0,eI.jsx)("div",{className:"jsx-1097779992 "+"".concat(ct," sidebar-container"),children:(0,eI.jsx)(a1,{})})}),(0,eI.jsx)(h.A,{size:{xs:12,md:8},sx:{minWidth:0,height:"100%",flex:{md:"1 1 0"}},children:(0,eI.jsxs)("div",{className:"jsx-1097779992 "+"".concat(ct," preview-container"),children:[(0,eI.jsxs)("div",{className:"jsx-1097779992 "+"".concat(ct," buttons-container"),children:[(0,eI.jsx)("div",{className:"jsx-1097779992 "+"".concat(ct," left-content"),children:(0,eI.jsx)(so,{})}),(0,eI.jsxs)("div",{className:"jsx-1097779992 "+"".concat(ct," right-content"),children:[(0,eI.jsx)("div",{className:"jsx-1097779992 "+"".concat(ct," draft-buttons-group-container"),children:(0,eI.jsx)(a5,{})}),(0,eI.jsx)("div",{className:"jsx-1097779992 "+"".concat(ct," draft-buttons-group-container"),children:(0,eI.jsx)(g.A,{title:n("editor:editor.previewTooltip"),children:(0,eI.jsx)("span",{className:"jsx-1097779992",children:(0,eI.jsx)(C.A,{onClick:function(){return F(!0)},"data-testid":"".concat(m,"-previewBtn"),children:n("editor:editor.preview")})})})}),(0,eI.jsx)(sb,{}),(0,eI.jsx)(s8,{})]})]}),(0,eI.jsxs)("div",{id:"hub-page-viewer-container",style:{fontSize:E},className:"jsx-1097779992 "+"".concat(ct," hub-page-viewer-container"),children:[(0,eI.jsx)(s7,{isInsideAdminView:!0}),(0,eI.jsx)(p.Ay,{anchor:"right",open:H,onClose:B,slotProps:{paper:{sx:{width:"100vw",maxWidth:"100vw"}},root:{keepMounted:!1}},children:(0,eI.jsxs)(x.A,{sx:{px:2,pb:2},children:[(0,eI.jsxs)("div",{className:"".concat(ct," live-preview-drawer-header"),children:[(0,eI.jsxs)(b.A,{exclusive:!0,value:N,onChange:function(e,t){return null!=t&&z(t)},size:"medium","aria-label":n("editor:editor.viewOnDesktop"),className:"testId-".concat(m,"-devices"),children:[(0,eI.jsx)(f.A,{value:"5
176px","data-testid":"".concat(m,"-viewOnMobile"),"aria-label":n("editor:editor.viewOnMobile"),children:(0,eI.jsx)(g.A,{title:n("editor:editor.viewOnMobile"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(j.A,{fontSize:"small"})})})}),(0,eI.jsx)(f.A,{value:"768px","data-testid":"".concat(m,"-viewOnTablet"),"aria-label":n("editor:editor.viewOnTablet"),children:(0,eI.jsx)(g.A,{title:n("editor:editor.viewOnTablet"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(v.A,{fontSize:"small"})})})}),(0,eI.jsx)(f.A,{value:"100%","data-testid":"".concat(m,"-viewOnDesktop"),"aria-label":n("editor:editor.viewOnDesktop"),children:(0,eI.jsx)(g.A,{title:n("editor:editor.viewOnDesktop"),children:(0,eI.jsx)("span",{children:(0,eI.jsx)(y.A,{fontSize:"small"})})})})]}),(0,eI.jsxs)(x.A,{sx:{display:"flex",alignItems:"center",gap:1},children:[(0,eI.jsxs)("div",{className:"".concat(ct," live-preview-buttons"),children:[(0,eI.jsx)(sh,{}),(0,eI.jsx)(a5,{}),(0,eI.jsx)(sc,{})]}),(0,eI.jsx)(w.A,{"aria-label":"close",onClick:B,"data-testid":"".concat(m,"-previewCloseBtn"),size:"medium",edge:"end",children:(0,eI.jsx)(A.A,{})})]})]}),(0,eI.jsx)("div",{className:"".concat(ct," hub-page-live-previewer"),style:{width:N},children:(0,eI.jsx)(T.Ay,{nonce:k,style:{border:0,width:"100%",height:"100%"},initialContent:"<!DOCTYPE html><html><head></head><style nonce=".concat(k,'>.top-navbar { overflow: hidden } .main-navbar { overflow: hidden } .frame-content { pointer-events: none;} .ehq-participant-header .nav-links__list__list-item__child, .ehq-participant-header .auth-links__list__list-item__child { display: none; }</style><body style="overflow: auto"><div id="iframe"></div></body></html>'),children:(0,eI.jsx)(T.rH,{children:function(e){var t=e.document,n=e.window,o=n.top.document.getElementsByTagName("link"),i=n.top.document.getElementsByTagName("style"),r=t.getElementsByTagName("head").item(0),s=t.createElement("script");s.src="https://platform.twitter.com/widgets.js",s.charset="utf-8",r.appendChild(s);for(var c=0,l=o.length;c<l;c++)if(o[c].rel&&"stylesheet"===o[c].rel){for(var d=t.createElement("link"),u=o[c].attributes,m=0,h=u.length;m<h;m++)d.setAttribute(u[m].nodeName,u[m].nodeValue);r.appendChild(d)}for(var p=0,x=i.length;p<x;p++){var g=t.createElement("style"),f=i[p].innerHTML;g.type="text/css",g.appendChild(t.createTextNode(f)),r.appendChild(g)}var b=S()((0,a.A)(n.top.document.querySelectorAll("[data-emotion]")),function(e){var t=e.sheet;return(0,a.A)(t.cssRules).map(function(e){return e.cssText})}).join("\n"),j=t.createElement("style");return j.type="text/css",j.appendChild(t.createTextNode(b)),r.appendChild(j),(0,eI.jsx)(s7,{isInsideDevicePreview:!0})}})})})]})})]})]})})]}),(0,eI.jsx)(c(),{id:"1097779992",children:["body{overflow-y:hidden;}",".hub-page-viewer-container a,.hub-page-viewer-container .participant-header li,.hub-page-viewer-container .participant-header input,.hub-page-viewer-container .project-finder,.hub-page-viewer-container .faq-accordion button,.hub-page-viewer-container .video-section iframe,.hub-page-viewer-container .ehq-participant-header button,.hub-page-viewer-container .ehq-participant-header .logo,.hub-page-viewer-container .animated-card{pointer-events:none;-webkit-transition:none;transition:none;}",".upload-icon{font-size:30px;}",".image-placeholder{height:200px;border-radius:4px;margin-bottom:12px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;background-color:#f5f5f5;}",".image-info{width:90%;margin:0px auto;line-height:20px;}",".color-box{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".button-popover{width:100px;}",".icon-outlined-style{margin-left:4px;}"]}),cn]})}),ci=(0,o.Ng)(function(e){return{hasUnsavedChanges:e.hubPageRevision.hasUnsavedChanges,hub:e.hub.hub,dataTestId:"admin-hubs-editor-editor",nonce:e.hubPageRevision.nonce}},function(e){return(0,i.zH)({fetchProjects:tA.vj,updateQuery:tA.oR,updateFilters:tA.vm,fetchHubAdmins:sk.SL},e)})(co)},32653:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/recycle-regular-24.1b1c22fdbe9d4a74.png"}
1,33893:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.553393b7196200c6.jpg"},34586:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/link-alt-regular-24.b41b3b028a852d73.png"},37485:(e,t,n)=>{"use strict";n.d(t,{A:()=>i});var o=n(14232);function i(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"home-page-tabs",a=!(arguments.length>4)||void 0===arguments[4]||arguments[4];(0,o.useEffect)(function(){if(a){var o=n(93483),i=document.querySelector(".".concat(r,"-").concat(e," .MuiTabs-flexContainer"));if(i){var s=o([i]);return s.on("drop",function(){for(var n=[],o=0;o<i.children.length;o++){var r=i.children[o];n.push(r.getAttribute("data-id"))}t(n,e)}),function(){return s.destroy()}}}},[e,t,i,r,a])}},38364:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/eleven.2fae81f2f36f376e.jpg"},38597:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.545c4752dc3628f8.jpg"},40523:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.46401e957c313db4.jpg"},41048:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.6e47b2f2655ae03c.jpg"},41657:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.2886ea08baf0295a.jpg"},42205:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/photo-album-solid-24.c5e67bd9ed0d9946.png"},42436:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/eight.607a557efcbd7496.jpg"},43067:(e,t,n)=>{"use strict";n.d(t,{A:()=>I});var o=n(42969),i=n(63857),r=n(60180),a=n.n(r),s=n(98512),c=n(59234),l=n(21471),d=n(71858),u=n(30528),m=n(82803),h=n(34626),p=n(28118),x=n(84227),g=n(4917),f=n.n(g),b=n(40123),j=n.n(b),v=n(98825),y=n.n(v),A=n(14232),w=n(65062),C=n(37876);let T=(0,p.withTranslation)("common")(function(e){var t=e.t,n=e.tooltip||t("common:common.permalink");return(0,C.jsx)(w.A,{required:!0,tooltip:n,"aria-label":n,placement:"top",typographyVariant:"subtitle2",fontWeight:600,mb:0,children:t("common:common.permalink")})});function k(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?k(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):k(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let I=(0,p.withTranslation)(["common","project"])(function(e){var t=e.t,n=e.generatePermalink,o=e.disable,r=e.errors,p=e.permalink,g=e.holdPostRequest,b=e.addonBefore,v=void 0===b?"/":b,w=e.tooltip,k=e.name,I=e.showTooltip,P=void 0!==I&&I,O=e.noFetch,N=void 0!==O&&O,z=e.dataTestId,D=e.disabled,H=void 0!==D&&D,F=(0,A.useState)(!1),R=F[0],E=F[1],U=(0,A.useState)(!1),B=U[0],L=U[1],_=(0,A.useState)(p||""),W=_[0],M=_[1],K=(0,A.useState)({open:!1,message:""}),Y=K[0],V=K[1],q=(0,A.useRef)(0),Q=(0,A.useMemo)(function(){var e;return f()((e=(0,i.A)(a().mark(function e(t){var o;return a().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=q.current,L(!0),e.prev=2,e.next=5,n(t);case 5:return e.prev=5,o===q.current&&L(!1),e.finish(5);case 8:case"end":return e.stop()}},e,null,[[2,,5,8]])})),function(t){return e.apply(this,arguments)}),2e3)},[n]);(0,A.useEffect)(function(){return function(){return Q.cancel()}},[Q]);var Z=(0,A.useCallback)(function(){g||o("holdPostRequest",!0)},[g,o]),G=(0,A.useCallback)(function(e){q.current+=1,L(!1),Q(e),Z()},[Q,Z]);(0,A.useEffect)(function(){if(r){if(y()(r)&&!j()(r))return void V({open:!0,message:Object.keys(r).map(function(e){return(0,x.A)(r[e])}).filter(Boolean).join("\n")});"string"==typeof r&&V({open:!0,message:r})}},[r]),(0,A.useEffect)(function(){P&&!N&&k&&String(k).trim()&&G(k)},[k,P,N]),(0,A.useEffect)(function(){if(k&&!p){var e=setTimeout(function(){E(!0)},1e3);return function(){return clearTimeout(e)}}E(!1)},[k,p]),(0,A.useEffect)(function(){R&&M(p||"")},[R,p]);var X=function(){V(function(e){return S(S({},e),{},{open:!1})})};return(0,C.jsxs)(C.Fragment,{children:[(0,C.jsxs)(c.A,{sx:{display:"flex",flexDirection:"column",gap:.25,width:"100%"},children:[P&&(0,C.jsx)(T,{tooltip:w}),(0,C.jsxs)(c.A,{sx:{display:"flex",alignItems:"center",gap:1.5,width:"100%"},children:[(0,C.jsx)(c.A,{sx:{flex:1,minWidth:0},children:(0,C.jsx)(h.A,{fullWidth:!0,margin:"none",variant:"outlined",size:"small",disabled:H||!R||B,value:R?W:p||"",onChange:function(e){var t=e.target.value;M(t),G(t)},placeholder:t("common:common.permalink"),"data-testid":z,sx:{"& .MuiOutlinedInput-root":{height:40}},slotProps:{htmlInput:{title:p||void 0},input:{startAdornment:v?(0,C.jsx)(u.A,{position:"start",children:v}):void 0,endAdornment:B?(0,C.jsx)(u.A,{position:"end",children:(0,C.jsx)(d.A,{size:20,"aria-hidden":!0})}):void 0}}})}),(0,C.jsx)(l.A,{variant:"outlined",size:"small",color:"primary",disabled:H||B,onClick:function(){R||M(p||""),E(!R)},"data-testid":"".concat(z||k,"-editBtn"),sx:{flexShrink:0,textTransform:"uppercase",fontWeight:600,height:40,minHeight:40,boxSizing:"border-box"},children:t(R&&!B?"common:common.close":"common:common.edit")})]})]}),(0,C.jsx)(m.A,{open:Y.open,autoHideDuration:8e3,onClose:X,anch
1orOrigin:{vertical:"bottom",horizontal:"center"},children:(0,C.jsx)(s.A,{severity:"error",variant:"filled",onClose:X,"data-testid":"".concat(z||k,"-errorAlert"),sx:{width:"100%",maxWidth:480,whiteSpace:"pre-line"},children:Y.message})})]})})},43446:()=>{},46504:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/check-square-regular-24.251b08c1331b3ee2.png"},53045:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var o=n(42969),i=n(59860),r=n(46783),a=n(62631),s=n(37876),c=["sx"];function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let u=function(e){var t=e.sx,n=(0,i.A)(e,c);return(0,s.jsx)(r.A,d({component:"p",variant:"body1",color:"text.primary",sx:d(d({m:0},a.m),t)},n))}},55188:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/info-circle-solid-24.cc0de4da4070f885.png"},56887:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/check-square-solid-24.ee94acdf941bfbf0.png"},57811:()=>{},59934:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/notepad-solid-24.e38a56e40022494e.png"},61761:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var o=n(42969),i=n(14232),r=n(59234),a=n(46783),s=n(37876);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var d={width:32,height:32,p:0,border:1,borderColor:"divider",borderRadius:1,cursor:"pointer",bgcolor:"transparent",flexShrink:0,pointerEvents:"auto",WebkitAppearance:"none",appearance:"none","&::-webkit-color-swatch-wrapper":{p:0},"&::-webkit-color-swatch":{border:1,borderColor:"divider",borderRadius:1},"&::-moz-color-swatch":{border:1,borderColor:"divider",borderRadius:1}};let u=function(e){var t=e.color,n=e.fieldKey,o=e.onChange,c=e["data-testid"],u=e.hideHex,m=void 0!==u&&u,h=(0,i.useRef)(null);return(0,s.jsxs)(r.A,{className:c?"testId-".concat(c):void 0,"data-testid":c,sx:{display:"flex",alignItems:"center",mb:m?0:"5px"},children:[(0,s.jsx)(r.A,{component:"input",ref:h,type:"color","data-key":n,value:t||"#000000",onChange:function(e){return o(e.target.value)},sx:l(l({},d),{},{mr:1.5*!m})}),m?null:(0,s.jsx)(a.A,{component:"span",sx:{fontSize:14,lineHeight:"32px",cursor:"pointer",border:1,borderColor:"divider",borderRadius:1,width:100,textAlign:"center"},onClick:function(){var e;return null==(e=h.current)?void 0:e.click()},children:t})]})}},62631:(e,t,n)=>{"use strict";n.d(t,{m:()=>o});var o={fontSize:"1rem",lineHeight:1.5,letterSpacing:"0.00938em",fontWeight:400}}
1,64529:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.9d62c4bc9537b441.jpg"},64790:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/seven.809cf552d2ce5538.jpg"},64801:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.ee62d03fc24861f1.jpg"},65062:(e,t,n)=>{"use strict";n.d(t,{A:()=>m});var o=n(42969),i=n(44478),r=n(59234),a=n(33713),s=n(46783),c=n(56296),l=n(57459),d=n(37876);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function m(e){var t=e.children,n=e.required,m=e.tooltip,h=e["aria-label"],p=e.htmlFor,x=e.typographyVariant,g=e.fontWeight,f=e.placement,b=e.accessory,j=e.mb,v=e.mt,y=e.sx,A=e["data-testid"],w=null!=m&&!1!==m;return(0,d.jsxs)(a.A,{direction:"row",alignItems:"center",flexWrap:"nowrap",useFlexGap:!0,spacing:0,mt:v,mb:void 0===j?.75:j,"data-testid":A,sx:[{width:"fit-content",maxWidth:"100%",minWidth:0}].concat((0,i.A)(Array.isArray(y)?y:y?[y]:[])),children:[(0,d.jsx)(s.A,{component:p?"label":"span",htmlFor:p,variant:void 0===x?"body2":x,fontWeight:void 0===g?400:g,color:"text.primary",sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({wordBreak:"break-word",lineHeight:1.4,minWidth:0},p?{cursor:"pointer"}:null),children:t}),void 0!==n&&n?(0,d.jsx)(l.A,{}):null,w?(0,d.jsx)(c.A,{tooltip:m,"aria-label":null!=h?h:"string"==typeof m?m:void 0,placement:void 0===f?"top":f}):null,!w&&b?(0,d.jsx)(r.A,{sx:{flexShrink:0,ml:.5},children:b}):null]})}},65824:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/nine.7a237acddd59c457.jpg"},67412:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/link-external-regular-24.e90c272dbc1b4f13.png"},68593:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/six.c69edf498d5a7a58.jpg"},68617:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.8928d271dd14ae62.jpg"},68697:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/notepad-regular-24.b478e5e94aa5c62a.png"},68843:(e,t,n)=>{"use strict";n.d(t,{A:()=>d});var o=n(42969),i=n(59860),r=n(46783),a=n(37876),s=["sx"];function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let d=function(e){var t=e.sx,n=(0,i.A)(e,s);return(0,a.jsx)(r.A,l({component:"p",variant:"body2",color:"text.secondary",sx:l({m:0},t)},n))}},69332:(e,t,n)=>{"use strict";function o(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:400;if(null==e||""===e)return t;switch(e.toString()){case"Light":case"100":return 100;case"Normal":case"400":return 400;case"Bold":case"700":return 700;default:var n=Number(e);return Number.isFinite(n)?n:t}}n.d(t,{f:()=>o})},71847:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.fc8ec112654bcc29.jpg"},71999:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.e676eda5356ba64d.jpg"},74385:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.be5e2872f6bc6d1e.jpg"}
1,75912:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var o=n(59234),i=n(69364),r=n.n(i);n(14232);var a=n(67376),s=n.n(a),c=n(37876),l=function(e,t){return s()(e,{allowedTags:t||["h1","h2","h3","h4","h5","h6","blockquote","p","a","ul","ol","s","u","nl","li","b","i","strong","em","strike","code","hr","br","div","table","thead","caption","tbody","tr","th","td","pre","img","span","style"],allowedAttributes:{span:["class","style"],a:["class","style","href","target"],img:["class","style","src","width","height","alt"],"*":["class","style","src","target","alt","width","height","type","tabindex","role","aria-hidden","id"]},selfClosing:["img","br","hr"]})},d={"& a":{textDecoration:"none","&:hover":{textDecoration:"underline"}}};let u=function(e){var t=e.html,n=e.allowTags,i=e.truncateLength;return t?i?(0,c.jsx)(o.A,{component:"span",sx:d,dangerouslySetInnerHTML:{__html:r()(l(t,n),{length:i})}}):(0,c.jsx)(o.A,{component:"span",sx:d,dangerouslySetInnerHTML:{__html:l(t,n)}}):(0,c.jsx)(c.Fragment,{})}},76159:(e,t,n)=>{"use strict";n.d(t,{A:()=>m});var o=n(42969),i=n(14232),r=n(59234),a=n(92592),s=n(46783),c=n(62631),l=n(37876);function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var u={px:1.5,py:1.5,width:"100%",boxSizing:"border-box"};let m=function(e){var t=e.label,n=e.value,m=e.min,h=e.max,p=e.step,x=e.unit,g=e.onChange,f=e.className,b=e.sx,j=e.id,v=e.disabled,y=e.valueLabelDisplay,A=(0,i.useId)(),w=null!=j?j:"".concat(A,"-slider");return(0,l.jsxs)(r.A,{sx:b,children:[(0,l.jsxs)(r.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:1,flexWrap:"wrap"},children:[(0,l.jsx)(r.A,{component:"label",htmlFor:w,sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({m:0,color:"text.primary"},c.m),children:t}),(0,l.jsxs)(s.A,{component:"span",variant:"body2",sx:{color:"text.secondary",flexShrink:0},children:[n,void 0===x?"px":x]})]}),(0,l.jsx)(a.Ay,{min:m,max:h,step:void 0===p?1:p,value:n,disabled:v,valueLabelDisplay:y,onChange:function(e,t){return g(t)},sx:u,className:f,slotProps:{input:{id:w}}})]})}},76489:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>cR});var o=n(31777),i=n(83129),r=n(44478),a=n(47091),s=n.n(a),c=n(14232),l=n(28118),d=n(52630),u=n(92105),m=n(59234),h=n(65595),p=n(52970),x=n(15969),g=n(5784),f=n(32430),b=n(74570),j=n(86085),v=n(31123),y=n(69692),A=n(64658),w=n(80505),C=n.n(w),T=n(89099),k=n.n(T),S=n(18847),I=n.n(S),P=n(50744),O=n(89003),N=n(54107),z=n(89487),D=n(30731),H=n(10097),F=n(96496),R=n(30092),E=n(796),U=n(88868),B=n(24795),L=n(63857),_=n(60180),W=n.n(_),M=n(71858),K=n(33713),Y=n(68843),V=n(99469),q=n(53045),Q=n(22063),Z=n(21471),G=n(37160),X=n(23937),$=n(52077),J=n(58535),ee=n(56296),et=n(11695),en=n(37876),eo=(0,G.Ay)("input")({clip:"rect(0 0 0 0)",clipPath:"inset(50%)",height:1,overflow:"hidden",position:"absolute",bottom:0,left:0,whiteSpace:"nowrap",width:1});let ei=(0,l.withTranslation)(["common","editor","project"])(function(e){var t,n=e.t,o=e.bannerUrl,i=e.logoUrl,r=e.faviconUrl,a=e.backgroundImageUrl,s=e.uploadFile,l=e.uploading,d=e.updateSite,u=e.bannerCaption,h=e.logoAltText,p=e.displaySiteBanner,x=e.displayProjectBanner,g=e.dataTestId,f=(t=(0,L.A)(W().mark(function e(t,n){var o;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s(t);case 2:(o=e.sent)&&d(n,o);case 4:case"end":return e.stop()}},e)})),function(e,n){return t.apply(this,arguments)}),b=function(e){var t=["logoUrl","faviconUrl"].includes(e.key),o=["backgroundImageUrl","bannerUrl"].includes(e.key);return(0,en.jsxs)(m.A,{sx:{display:"flex",height:200,flexDirection:"column",justifyContent:"center",bgcolor:"grey.100",mx:"auto",mb:1,textAlign:"center"},children:[e.value&&t&&(0,en.jsx)(m.A,{sx:{height:200,borderRadius:1,bgcolor:"grey.200",mx:"auto"},children:(0,en.jsx)(m.A,{component:"img",src:e.value,alt:"",sx:{dis
1play:"block",height:200,maxWidth:1,objectFit:"contain",mx:"auto"}})}),e.value&&o&&(0,en.jsx)(m.A,{sx:{height:200,width:1,borderRadius:1,backgroundImage:"url(".concat(e.value,")"),backgroundSize:"cover",backgroundRepeat:"no-repeat",bgcolor:"grey.200",backgroundPosition:"center center",mx:"auto"}}),!e.value&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(m.A,{children:(0,en.jsx)($.A,{sx:{fontSize:30,color:"action.active"}})}),(0,en.jsx)(Y.A,{children:n("project:project.clickToUpload")}),(0,en.jsx)(Y.A,{children:n("editor:editor.images.banner.uploadImageTypeText")})]})]})};return(0,en.jsx)(c.Fragment,{children:[{key:"logoUrl",value:i},{key:"faviconUrl",value:r},{key:"backgroundImageUrl",value:a},{key:"bannerUrl",value:o}].map(function(e,t){var o;return(0,en.jsx)(V.A,{children:(0,en.jsxs)(m.A,{sx:{bgcolor:"background.paper",pt:2,mb:4},children:[(0,en.jsxs)(m.A,{sx:{ml:2,pr:2,mb:1},children:[(0,en.jsx)(q.A,{sx:{mb:.5},children:n("editor:editor.images.".concat(e.key))}),(0,en.jsx)(Y.A,{children:n("editor:editor.helpTexts.".concat(e.key))})]}),(0,en.jsxs)(m.A,{sx:{position:"relative"},className:"testId-".concat(g,"-").concat(e.key),children:[l?(0,en.jsx)(m.A,{sx:{position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center",bgcolor:"rgba(255,255,255,0.72)",zIndex:1},children:(0,en.jsx)(M.A,{})}):null,(0,en.jsxs)(m.A,{sx:{m:1.5,display:"block",pb:1},children:[(0,en.jsx)(m.A,{component:"label",htmlFor:"hpe-image-upload-".concat(e.key),sx:{display:"block",width:1},children:b(e)}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",children:[(0,en.jsxs)(Z.A,{component:"label",role:void 0,tabIndex:-1,variant:"contained",color:"primary","data-testid":"".concat(g,"-").concat(e.key,"-uploadBtn"),children:[n("common:common.upload"),(0,en.jsx)(eo,{accept:"image/*",id:"hpe-image-upload-".concat(e.key),type:"file",onChange:(o=(0,L.A)(W().mark(function t(n){var o,i;return W().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(!(i=null==(o=n.target.files)?void 0:o[0])){t.next=4;break}return t.next=4,f(i,e.key);case 4:n.target.value="";case 5:case"end":return t.stop()}},t)})),function(e){return o.apply(this,arguments)})})]}),(0,en.jsx)(J.A,{onClick:function(){return d(e.key,"")},"data-testid":"".concat(g,"-").concat(e.key,"-deleteBtn")})]})]})]}),"logoUrl"===e.key&&(0,en.jsx)(m.A,{sx:{mx:2},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:(0,en.jsx)(et.A,{html:n("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":n("common:common.images.imageAltText"),children:n("common:common.images.imageAltText")}),children:(0,en.jsx)(Q.A,{sx:{mb:2},name:"logoAltText",value:h||"",onChange:function(e){return d("logoAltText",e.target.value)},slotProps:{htmlInput:{maxLength:125}},size:"medium",fullWidth:!0,variant:"outlined",error:(null==h?void 0:h.length)===125,helperText:(null==h?void 0:h.length)===125?n("common:common.maxCharactersReached"):"","data-testid":"".concat(g,"-logoUrl-imageAltText")})})}),"bannerUrl"===e.key&&(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(m.A,{sx:{mx:2},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:(0,en.jsx)(et.A,{html:n("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":n("common:common.images.imageAltText"),children:n("common:common.images.imageAltText")}),children:(0,en.jsx)(Q.A,{onChange:function(e){return d("bannerCaption",e.target.value)},value:u,"data-testid":"".concat(g,"-input"),slotProps:{htmlInput:{maxLength:125}},size:"medium",fullWidth:!0,variant:"outlined",error:(null==u?void 0:u.length)===125,helperText:(null==u?void 0:u.length)===125?n("common:common.maxCharactersReached"):""})})}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mx:2},children:[(0,en.jsx)(q.A,{component:"span",children:n("editor:editor.showSiteBannerOnProjectPages")}),(0,en.jsx)(X.A,{name:"displaySiteBanner",checked:p,onChange:function(e){return d("displaySiteBanner",e)},"data-testid":"".concat(g,"-dspSwitch")})]}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mx:2,pb:2},children:[(0,en.jsx)(q.A,{component:"span",children:n("editor:editor.enableCustomProjectPageBanner")}),(0,en.jsx)(X.A,{name:"displayProjectBanner",checked:x,onChange:function(e){return d("displayProjectBanner",e)},"data-testid":"".concat(g,"-dpbSwitch")})]})]})]})},t)})})});var er=n(7194),ea=n(21001);let es=(0,o.Ng)(function(e){return{bannerUrl:e.currentSite.site.bannerUrl,faviconUrl:e.currentSite.site.faviconUrl,backgroundImageUrl:e.currentSite.site.backgroundImageUrl,logoUrl:e.currentSite.site.logoUrl,displaySiteBanner:e.currentSite.site.displaySiteBanner,displayProjectBanner:e.currentSite.site.displayProjectBanner,uploading:e.homePageRevision.uploadingFile,uploadError:e.homePageRevision.fileUploadError,bannerCaption:e.currentSite.site.bannerCaption,logoAltText:e.currentSite.site.logoAltText,dataTestId:"admin-ae-lI&I"}},function(e){return(0,i.zH)({updateSite:er.hj,uploadFile:ea.QM},e)})(ei);var ec=n(42969),el=n(62886),ed=n(58498),eu=n(67872),em=n(26858),eh=n(10805),ep=n(75901),ex=n(45574),eg=n(61761),ef=n(75912),eb=n(17580);let ej=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,i=e.brandColor,r=e.updateTemplateMeta,a=e.updateTheme,s=e.saveTheme,l=e.saving,d=e.dataTestId,u=(0,o.Pj)(),h=(t=(0,L.A)(W().mark(function e(){var t;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s();case 2:(null==(t=u.getState().theme)?void 0:t.saveError)?eb.iU.error(n("common:common.error")):eb.iU.success(n("common:common.saved"));case 5:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(en.Fragment,{children:(0,en.jsx)(V.A,{extra:(0,en.jsxs)(m.A,{sx:{display:"flex",flexDirection:"column",mb:4},children:[(0,en.jsx)(Y.A,{sx:{fontWeight:"500",mb:2},children:n("editor:editor.brandColorImpact")}),(0,en.jsx)(Y.A,{children:n("editor:editor.brandColorOnHomepage")}),(0,en.jsx)(Y.A,{children:(0,en.jsx)(ef.A,{html:n("editor:editor.brandColorDescription")})})]}),children:(0,en.jsxs)(m.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:.625},children:[(0,en.jsx)(q.A,{sx:{mr:.625},children:n("editor:editor.brandColor")}),(0,en.jsx)(eg.A,{color:i||"#1890FF",fieldKey:"brandColor",onChange:function(e){r("brandColor",e),a("brandColor",e)},"data-testid":"".concat(d,"-popover")})]})})}),(0,en.jsx)(V.A,{children:(0,en.jsx)(Z.A,{variant:"contained",color:"primary",loading:l,loadingPosition:"start",onClick:h,"data-testid":"".concat(d,"-saveBtn"),children:n("common:common.save")})})]})});var ev=n(67251),ey=n(23745),eA=n(29898),ew=n(52672),eC=n(76966),eT=n(7379),ek=n.n(eT),eS=n(61851);function eI(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(eI=function(){return!!e})()}var eP=function(e){function t(){var e,n,o,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,ev.default)(this,t),e=t,n=[i],e=(0,ew.default)(e),o=(0,eA.default)(this,eI()?Reflect.construct(e,n||[],(0,ew.default)(this).constructor):e.apply(this,n)),ek().call(o,i),o.brandColor=i.brandColor||null,o.template=i.template||"",o.color1=i.color1||"",o.color2=i.color2||"",o.color3=i.color3||"",o.color4=i.color4||"",o.color5=i.color5||"",o.color6=i.color6||"",o.color7=i.color7||"",o.color8=i.color8||"",o.color9=i.color9||"",o.titleFont=i.titleFont||"",o.contentFont=i.contentFont||"",o}return(0,eC.default)(t,e),(0,ey.default)(t,[{key:"_update",value:function(){var e=this;return this.constructor.adapter.patch(this.constructBaseURL(),this.serialize()).catch(function(t){throw e.errors=new eS.default(t.data),t})}}])}(ek());(0,ec.default)(eP,"_type","themes"),(0,ec.default)(eP,"baseURL","/theme");var eO=n(33663),eN=function(e,t){return{type:eO.A.UPDATE_THEME,key:e,value:t}},ez=function(){var e;return e=(0,L.A)(W().mark(function e(t,n){var o;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t({type:eO.A.SAVE_THEME_REQUEST}),o=new eP(n().theme.theme),e.prev=2,e.next=5,o.save();case 5:t({type:eO.A.SAVE_THEME_SUCCESS}),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(2),t({type:eO.A.SAVE_THEME_FAILURE,errorMessage:e.t0.message||e.t0.statusText||e.t0.status,errors:o.errors.extract()});case 11:case"end":return e.stop()}},e,null,[[2,8]])})),function(t,n){return e.apply(this,arguments)}};let eD=(0,o.Ng)(function(e){return{brandColor:e.theme.theme.brandColor,saving:e.theme.saving,dataTestId:"admin-ae-gs-bc"}},function(e){return(0,i.zH)({updateTemplateMeta:ea.fw,updateTheme:eN,saveTheme:ez},e)})(ej);var eH=n(2708),eF=n(92592),eR=n(34626),eE=n(62631),eU=n(63256);function eB(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function eL(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?eB(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eB(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}let e_=function(e){var t=e.title,n=e.subTitle,o=e.description,i=e.sx,r=e.titleSx,a=e.subTitleHtmlFor,s=e["data-testid"];return(0,en.jsxs)(m.A,{sx:eL({mb:2},i),"data-testid":s,children:[(0,en.jsx)(eU.A,{label:t,sx:eL({mb:n||o?1:0},r)}),n?a?(0,en.jsx)(m.A,{component:"label",htmlFor:a,sx:eL({typography:"body1",color:"text.primary",display:"block",mb:+!!o},eE.m),children:n}):(0,en.jsx)(q.A,{sx:{fontWeight:400,mb:+!!o,display:"block"},children:n}):null,o?(0,en.jsx)(Y.A,{children:o}):null]})};var eW=n(77080),eM=n.n(eW);let eK=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,i=e.updateTemplateMeta,r=e.headingFontSize,a=e.sectionTitleFontSize,s=e.baseFontSize,l=e.titleFont,d=e.contentFont,u=e.updateTheme,h=e.saveTheme,p=e.saving,x=e.dataTestId,g=(0,o.Pj)(),f=(0,c.useId)(),b=(0,c.useId)(),j=(t=(0,L.A)(W().mark(function e(){var t;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,h();case 2:(null==(t=g.getState().theme)?void 0:t.saveError)?eb.iU.error(n("common:common.error")):eb.iU.success(n("common:common.saved"));case 5:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(e_,{title:n("editor:editor.globalFontFamily"),description:n("editor:editor.globalFontFamilyDescription")}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mb:1.5},children:[(0,en.jsx)(q.A,{component:"label",htmlFor:f,sx:{mr:1},children:n("editor:editor.titleFont")}),(0,en.jsx)(eR.A,{id:f,select:!0,className:"testId-".concat(x,"-tf"),sx:{flexShrink:0,width:function(e){return e.spacing(20)}},size:"medium",variant:"outlined",value:l,onChange:function(e){return u("titleFont",e.target.value)},children:eM().map(function(e,t){return(0,en.jsx)(eH.A,{value:e.key,"data-testid":"".concat(x,"-tfOption"),children:e.name},t)})})]}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mb:1.5},children:[(0,en.jsx)(q.A,{component:"label",htmlFor:b,sx:{mr:1},children:n("editor:editor.contentFont")}),(0,en.jsx)(eR.A,{id:b,select:!0,className:"testId-".concat(x,"-cf"),sx:{flexShrink:0,width:function(e){return e.spacing(20)}},size:"medium",variant:"outlined",value:d,onChange:function(e){return u("contentFont",e.target.value)},children:eM().map(function(e,t){return(0,en.jsx)(eH.A,{value:e.key,"data-testid":"".concat(x,"-cfOption"),children:e.name},t)})})]}),(0,en.jsx)(m.A,{sx:{height:function(e){return e.spacing(3.75)}}}),(0,en.jsx)(e_,{title:n("editor:editor.fontSizes"),description:n("editor:editor.fontSizesDescription")}),(0,en.jsxs)(m.A,{sx:{mb:3},children:[(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",spacing:1,sx:{flexWrap:"wrap"},children:[(0,en.jsx)(q.A,{children:n("editor:editor.sectionTitle")}),(0,en.jsxs)(Y.A,{sx:{flexShrink:0},children:[16*a,"px"]})]}),(0,en.jsx)(eF.Ay,{min:10,max:48,onChange:function(e,t){return i("sectionTitleFontSize",t/16)},step:1,className:"testId-".concat(x,"-st"),sx:{mx:.5,mt:1,mb:0},value:16*a}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,mb:0,children:n("editor:editor.sectionTitleFontSizeDescription")})]}),(0,en.jsxs)(m.A,{sx:{mb:3},children:[(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",spacing:1,sx:{flexWrap:"wrap"},children:[(0,en.jsx)(q.A,{children:n("editor:editor.sectionSubHeadingFontSize")}),(0,en.jsxs)(Y.A,{sx:{flexShrink:0},children:[16*r,"px"]})]}),(0,en.jsx)(eF.Ay,{min:10,max:48,onChange:function(e,t){return i("headingFontSize",t/16)},step:1,className:"testId-".concat(x,"-p&wt"),sx:{mx:.5,mt:1,mb:0},value:16*r}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,mb:0,children:n("editor:editor.sectionSubHeadingFontSizeDescription")})]}),(0,en.jsxs)(m.A,{sx:{mb:3},children:[(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",spacing:1,sx:{flexWrap:"wrap"},children:[(0,en.jsx)(q.A,{children:n("editor:editor.contentFontSize")}),(0,en.jsxs)(Y.A,{sx:{flexShrink:0},children:[16*s,"px"]})]}),(0,en.jsx)(eF.Ay,{min:10,max:48,onChange:function(e,t){return i("baseFontSize",t/16)},step:1,className:"testId-".concat(x,"-c&b"),sx:{mx:.5,mt:1,mb:0},value:16*s}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,mb:0,children:n("editor:editor.contentFontSizeDescription")})]}),(0,en.jsx)(V.A,{children:(0,en.jsx)(Z.A,{variant:"contained",color:"primary",loading:p,loadingPosition:"start",onClick:j,"data-testid":"".concat(x,"-saveBtn"),children:n("common:common.save")})})]})}),eY=(0,o.Ng)(function(e){return{sectionTitleFontSize:e.homePageRevision.revision.meta.sectionTitleFontSize,headingFontSize:e.homePageRevision.revision.meta.headingFontSize,baseFontSize:e.homePageRevision.revision.meta.baseFontSize,titleFont:e.theme.theme.titleFont,contentFont:e.theme.theme.contentFont,saving:e.theme.saving,dataTestId:"admin-ae-gs-font"}},function(e){return(0,i.zH)({updateTemplateMeta:ea.fw,updateTheme:eN,saveTheme:ez},e)})(eK);var eV=n(58160),eq=n(15579),eQ=n(52715),eZ=n(29494),eG=n(83995),eX=n.n(eG);function e$(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function eJ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?e$(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):e$(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var e0={position:"relative",p:0,flexShrink:0,borderRadius:0},e1={position:"absolute",top:.625,right:.625,m:.5},e2=function(){return(0,en.jsx)(eZ.A,{fontSize:"small",sx:e1})},e3=function(){return(0,en.jsx)(eQ.A,{fontSize:"small",sx:e1})},e5={styles:(0,en.jsx)(s(),{id:"2633362017",children:[".item.jsx-2633362017{box-sizing:border-box;}",".item.jsx-2633362017:not(:last-child){margin-right:24px;}",".item.is-selected.jsx-2633362017{border:1px solid #0e4b70;}",".preset-text.jsx-2633362017{margin-top:25px;}",".container.jsx-2633362017{margin-top:5px;margin-bottom:10px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;}",".preset-gallery.jsx-2633362017{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;gap:8px;}",".preset-default.jsx-2633362017{display:block;width:97px;height:86px;margin-top:10px;background-repeat:no-repeat;}",".preset-shadow.jsx-2633362017{background-image:url('/static/assets/images/preset-image.svg');}",".preset-corner-1.jsx-2633362017{background-image:url('/static/assets/images/preset-image-1.svg');}",".preset-corner-2.jsx-2633362017{background-image:url('/static/assets/images/preset-image-2.svg');}",".preset-corner-3.jsx-2633362017{background-image:url('/static/assets/images/preset-image-3.svg');}",".save-button.jsx-2633362017{margin-bottom:10px;}"]}),className:"jsx-2633362017"},e4=e5.className,e9=e5.styles;let e6=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.boxShadow,i=e.borderRadius,r=e.updateTemplateMeta,a=e.updateLayout,s=e.saveLayout,l=e.saveHomePageRevision,d=e.saving,u=e.layoutVariables,h=e.dataTestId,p=(0,o.Pj)(),x=[{name:"none",value:"none"},{name:"low",value:"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)"},{name:"high",value:"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)"}],g=[{name:"none",value:"none"},{name:"low",value:"0.25em"},{name:"high",value:"0.5em"}],f=eX()(x,function(e){return e.value===n});f<0&&(f=0);var b=eX()(g,function(e){return e.value===i});return b<0&&(b=0),(0,en.jsxs)(c.Fragment,{children:[(0,en.jsxs)(m.A,{sx:{mb:2},children:[(0,en.jsx)(q.A,{sx:{mb:.5},children:t("editor:editor.shadow")}),(0,en.jsx)(Y.A,{sx:{mb:1},children:t("editor:editor.shadowHelptext")}),(0,en.jsx)("div",{className:"".concat(e4," container"),children:(0,en.jsx)(eq.A,{row:!0,className:"".concat(e4," preset-gallery"),value:x[f].name,onChange:function(e){var t=x.find(function(t){return t.name===e.target.value});if(t){var n=Object.assign({},u,{"box-shadow":t.value,"box-shadow1":t.value,"box-shadow-widget":t.value});r("boxShadow",t.value),a("colorMapping",n)}},children:x.map(function(e,t){return(0,en.jsx)(eV.A,{"data-testid":"".concat(h,"-shadow"),value:e.name,icon:(0,en.jsx)(e2,{}),checkedIcon:(0,en.jsx)(e3,{}),className:"".concat(e4," preset-default preset-shadow"),sx:eJ(eJ({},e0),{},{boxShadow:e.value})},t)})})})]}),(0,en.jsxs)(m.A,{children:[(0,en.jsx)(q.A,{sx:{mt:2.5,mb:.5},children:t("editor:editor.corners")}),(0,en.jsx)(Y.A,{sx:{mb:1},children:t("editor:editor.cornersHelptext")}),(0,en.jsx)("div",{className:"".concat(e4," container"),children:(0,en.jsx)(eq.A,{row:!0,className:"".concat(e4," preset-gallery"),value:g[b].name,onChange:function(e){var t=g.find(function(t){return t.name===e.target.value});if(t){var n=Object.assign({},u,{"border-radius":t.value});r("borderRadius",t.value),a("colorMapping",n)}},children:g.map(function(e,t){return(0,en.jsx)(eV.A,{"data-testid":"".concat(h,"-radius"),value:e.name,icon:(0,en.jsx)(e2,{}),checkedIcon:(0,en.jsx)(e3,{}),className:"".concat(e4," preset-default preset-corner-").concat(t+1),sx:e0},t)})})}),(0,en.jsx)(Z.A,{variant:"contained",color:"primary",disabled:d,"data-testid":"".concat(h,"-saveBtn"),onClick:(0,L.A)(W().mark(function e(){var n,o,i;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s();case 2:return e.next=4,l();case 4:(null==(n=(i=p.getState()).layout)?void 0:n.saveError)||(null==(o=i.homePageRevision)?void 0:o.saveError)?eb.iU.error(t("common:common.error")):eb.iU.success(t("common:common.saved"));case 7:case"end":return e.stop()}},e)})),className:"".concat(e4," save-button"),children:d?(0,en.jsx)(M.A,{color:"inherit",size:22}):t("editor:editor.save")})]}),e9]})});
1var e8=n(32367);let e7=(0,o.Ng)(function(e){return{boxShadow:e.homePageRevision.revision.meta.boxShadow,borderRadius:e.homePageRevision.revision.meta.borderRadius,layoutVariables:e.layout.layout.colorMapping,saving:e.layout.saving,dataTestId:"admin-ae-gs-s&cs"}},function(e){return(0,i.zH)({updateTemplateMeta:ea.fw,saveHomePageRevision:ea.Z0,updateLayout:e8.mR,saveLayout:e8.Q,fetchLayout:e8.Xp},e)})(e6);var te=n(72440),tt=n(33248),tn=n(37902),to=n(17125),ti=n.n(to),tr=n(41946),ta=n.n(tr),ts=n(96633),tc=[{path:"liquid_templates/header",colorPalette:null},{path:"liquid_templates/footer",colorPalette:null},{path:"liquid_templates/css",colorPalette:null},{path:"liquid_templates/css",colorPalette:"corporate"},{path:"liquid_templates/css",colorPalette:"business"}];function tl(e){var t;return"".concat(e.path).concat(null!=(t=e.colorPalette)?t:"")}let td=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,i=e.saving,r=e.liquidTemplates,a=e.updateLiquidTemplate,s=e.saveLiquidTemplates,l=e.currentUserRole,d=e.dataTestId,u=(0,o.Pj)(),h=(0,c.useState)("liquid_templates/header"),p=h[0],x=h[1];if(!([ts.PlatformAdmin].indexOf(l)>-1))return!1;var g=(0,c.useMemo)(function(){return r?r.slice().reverse():[]},[r]);(0,c.useEffect)(function(){var e;(e=(0,L.A)(W().mark(function e(){var t;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:t=r.map(function(e){return{path:e.path,colorPalette:e.colorPalette}}),s(ti()(tc,t,ta()));case 3:case"end":return e.stop()}},e)})),function(){return e.apply(this,arguments)})()},[]),(0,c.useEffect)(function(){g.length&&(new Set(g.map(tl)).has(p)||x(tl(g[0])))},[g,p]);var f=(t=(0,L.A)(W().mark(function e(){var t;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s(r);case 2:(null==(t=u.getState().liquidTemplates)?void 0:t.saveError)?eb.iU.error(n("common:common.error")):eb.iU.success(n("common:common.saved"));case 5:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)}),b=function(e,t){return"liquid_templates/header"===e?n("editor:editor.header"):"liquid_templates/footer"===e?n("editor:editor.footer"):"liquid_templates/css"!==e||t?"liquid_templates/css"===e&&"corporate"===t?n("editor:editor.freshCSS"):"liquid_templates/css"===e&&"business"===t?n("editor:editor.boldCSS"):"":n("editor:editor.classicCSS")},j=g.find(function(e){return tl(e)===p});return(0,en.jsxs)(en.Fragment,{children:[(0,en.jsxs)(V.A,{children:[(0,en.jsx)(tt.A,{value:p,onChange:function(e,t){return x(t)},variant:"scrollable",scrollButtons:"auto",textColor:"inherit",sx:tn.R,children:g.map(function(e,t){var n=tl(e),o=p===n;return(0,en.jsx)(te.A,{value:n,label:(0,en.jsx)(m.A,{component:"span","data-testid":"".concat(d,"-").concat(t),sx:{color:o?"primary.main":"text.secondary"},children:b(e.path,e.colorPalette)})},n)})}),j?(0,en.jsx)(m.A,{sx:{pt:2},children:(0,en.jsx)(Q.A,{multiline:!0,minRows:8,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(d,"-textArea"),value:j.body,onChange:function(e){return a(j.id,"body",e.target.value)}})}):null]}),(0,en.jsx)(V.A,{children:(0,en.jsx)(Z.A,{variant:"contained",color:"primary","data-testid":"".concat(d,"-saveBtn"),onClick:f,loading:i,loadingPosition:"start",children:n("common:common.save")})})]})});var tu=n(24868);function tm(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(tm=function(){return!!e})()}var th=function(e){function t(){var e,n,o,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,ev.default)(this,t),e=t,n=[i],e=(0,ew.default)(e),o=(0,eA.default)(this,tm()?Reflect.construct(e,n||[],(0,ew.default)(this).constructor):e.apply(this,n)),ek().call(o,i),o.path=i.path,o.body=i.body,o.colorPalette=i.colorPalette,o}return(0,eC.default)(t,e),(0,ey.default)(t)}(ek());(0,ec.default)(th,"_type","liquid-templates"),(0,ec.default)(th,"baseURL","/liquid_templates");var tp=function(e,t,n){return{type:tu.A.UPDATE_LIQUID_TEMPLATE,templateId:e,key:t,value:n}},tx=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e=(0,L.A)(W().mark(function e(n,o){var i;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return n({type:tu.A.SAVE_LIQUID_TEMPLATES_REQUEST}),i=t?t.map(function(e){return new th(e).save()}):o().liquidTemplates.liquidTemplates.map(function(e){return new th(e).save()}),e.prev=2,e.next=5,Promise.all(i);case 5:n({type:tu.A.SAVE_LIQUID_TEMPLATES_SUCCESS}),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(2),n({type:tu.A.SAVE_LIQUID_TEMPLATES_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 11:case"end":return e.stop()}},e,null,[[2,8]])})),function(t,n){return e.apply(this,arguments)}};let tg=(0,o.Ng)(function(e){return{saving:e.liquidTemplates.saving,liquidTemplates:e.liquidTemplates.liquidTemplates,currentUserRole:e.currentUser.user.roleName,dataTestId:"admin-ae-gs-ct"}},function(e){return(0,i.zH)({updateLiquidTemplate:tp,saveLiquidTemplates:tx},e)})(td);function tf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var tb=[{key:"color",titleKey:"editor:editor.brandColor",descriptionKey:"editor:editor.colorDescription",icon:em.A,component:eD,isVisibleFor:[ts.PlatformAdmin,ts.SiteAdmin,ts.HubAdmin],dataTestIDSuffix:"brandColor"},{key:"font",titleKey:"editor:editor.font",descriptionKey:"editor:editor.fontDescription",icon:eh.A,component:eY,isVisibleFor:[ts.PlatformAdmin,ts.SiteAdmin,ts.HubAdmin],dataTestIDSuffix:"font"},{key:"preset",titleKey:"editor:editor.shadowsAndCornerStyles",descriptionKey:"editor:editor.shadowsAndCornerStylesDescription",icon:ep.A,component:e7,isVisibleFor:[ts.PlatformAdmin,ts.SiteAdmin,ts.HubAdmin],dataTestIDSuffix:"shadowsAndCornerStyles"},{key:"customTheme",titleKey:"editor:editor.customThemeGallery",descriptionKey:"editor:editor.customThemeGalleryDescription",icon:ex.A,component:tg,isVisibleFor:[ts.PlatformAdmin],dataTestIDSuffix:"customThemeGallery"}];let tj=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.isProjectPageRefreshEnabled,n=e.t,o=e.currentUserRole,i=e.dataTestId,r=(0,c.useState)(!1),a=r[0],s=r[1];return(0,en.jsx)(en.Fragment,{children:tb.map(function(e,r){if(!t&&"layout"===e.key||-1===e.isVisibleFor.indexOf(o))return null;var c,l=e.component,d=e.icon,u="".concat(i,"-").concat(e.dataTestIDSuffix),h=a===e.key;return(0,en.jsx)(m.A,{sx:{mb:1.5,borderRadius:1,border:1,borderColor:"divider",bgcolor:"background.paper",overflow:"hidden",transition:function(e){return e.transitions.create(["box-shadow"],{duration:e.transitions.duration.short})},"&:hover":{boxShadow:function(e){return e.shadows[4]}}},children:(0,en.jsxs)(el.A,{disableGutters:!0,elevation:0,expanded:h,onChange:(c=e.key,function(e,t){t?s(c):a===c&&s(!1)}),slotProps:{transition:{unmountOnExit:!0}},sx:{bgcolor:"background.paper"},children:[(0,en.jsx)(eu.A,{expandIcon:null,id:"home-page-editor-section-".concat(r,"-header"),className:"hpe-panel testId-".concat(u),slotProps:{content:{sx:{alignItems:"center",my:1}}},sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?tf(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tf(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({px:1.5,bgcolor:"grey.100"},h&&{borderBottom:1,borderColor:"divider"}),children:(0,en.jsxs)("div",{className:"hpe-section-header",children:[(0,en.jsx)("div",{className:"hpe-icon",children:(0,en.jsx)(d,{sx:{fontSize:"1em",width:"1em",height:"1em",color:"action.active"}})}),(0,en.jsx)("div",{children:(0,en.jsx)(B.A,{title:n(e.titleKey),description:n(e.descriptionKey)})})]})}),(0,en.jsx)(ed.A,{sx:{pt:2,px:2,pb:2,bgcolor:"common.white"},children:(0,en.jsx)(l,{})})]})},e.key)})})}),tv=(0,o.Ng)(function(e){return{isDrawerVisible:e.homePageRevision.showTemplatesDrawer,isProjectPageRefreshEnabled:e.features.features.hasOwnProperty("project_page_refresh")&&e.features.features.project_page_refresh.enabled,currentUserRole:e.currentUser.user.roleName,dataTestId:"admin-ae-globalStyles"}})(tj);var ty=n(99647),tA=n(74679);let tw=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=(e.updateTemplateMeta,e.updateTheme),o=e.saveTheme,i=e.color1,r=e.color2,a=e.color3,s=e.color4,l=e.color5,d=e.color6,u=e.color7,h=e.color8,p=e.color9,x=e.brandColor,g=e.themeColors,f=e.layoutId,b=e.updateLayout,j=e.saveLayout,v=e.resetLayoutColor,y=e.fetchLayout,A=e.isProjectPageRefreshEnabled,w=e.selectedColorPalette,C=e.saving,T=e.dataTestId,k=(0,c.useState)(!1),S=k[0],I=k[1],P=(0,c.useId)();(0,c.useEffect)(function(){f||y()},[f,y]);var O=function(e,t){f&&(N(e,t),j())},N=function(e,t){A?b("colorMapping",Object.assign({},g||{},(0,ec.default)({},e,t))):n(e,t)},z=function(e){return"$brand-color"===e?x:e},D=function(e,n){return(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",spacing:1,sx:{mb:.625},children:[(0,en.jsxs)(m.A,{sx:{display:"inline-flex",alignItems:"center",minWidth:0,flex:"1 1 auto",maxWidth:"100%"},children:[(0,en.jsx)(q.A,{component:"span",sx:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",minWidth:0},children:t("editor:editor.".concat(e.name))}),(0,en.jsx)(ee.A,{tooltip:t("editor:editor.".concat(e.description)),placement:"top"})]}),(0,en.jsx)(m.A,{sx:{flexShrink:0},"data-testid":"".concat(T,"-").concat(e.name),children:(0,en.jsx)(eg.A,{color:e.value,fieldKey:e.key,onChange:function(t){return O(e.key,t)},"data-testid":"".concat(T,"-").concat(e.name)})})]},n)};return(0,en.jsxs)(c.Fragment,{children:[!w&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(e_,{title:t("editor:editor.projectPrimaryColors"),description:(0,en.jsx)(ef.A,{html:t("editor:editor.helpTexts.primaryColors")}),sx:{mb:2.5},"data-testid":"".concat(T,"-pc-helpTexts")}),(0,en.jsx)(V.A,{children:[i,r,a].map(function(e,i){return(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mb:.625},children:[(0,en.jsxs)(q.A,{sx:{mr:.625},children:[t("editor:editor.primaryColor")," ",i+1]}),(0,en.jsx)(m.A,{"data-testid":"".concat(T,"-primaryColor-").concat(i+1),children:(0,en.jsx)(eg.A,{color:e,fieldKey:"color",onChange:function(e){n("color".concat(i+1),e),o()},"data-testid":"".concat(T,"-primaryColor-").concat(i+1)})})]},i)})})]}),!w&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(e_,{title:t("editor:editor.projectSecondaryColors"),description:(0,en.jsx)(ef.A,{html:t("editor:editor.helpTexts.secondaryColors")}),sx:{mb:2.5},"data-testid":"".concat(T,"-sc-helpTexts")}),(0,en.jsx)(V.A,{children:[s,l,d,u,h,p].map(function(e,n){return(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mb:.625},children:[(0,en.jsxs)(q.A,{sx:{mr:.625},children:[t("editor:editor.secondaryColor")," ",n+1]}),(0,en.jsxs)(m.A,{"data-testid":"".concat(T,"-secondaryColor-").concat(n+1),sx:{display:"inline-flex",alignItems:"center"},children:[(0,en.jsx)(m.A,{"data-name":e.key,sx:{width:24,height:24,borderRadius:1,mr:1.5,mt:.5,border:1,borderColor:"divider",bgcolor:e,cursor:"pointer"}}),(0,en.jsx)(Z.A,{disabled:!0,children:e})]})]},n)})})]}),!!A&&!!w&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(e_,{title:t("editor:editor.projectAndToolPages"),description:t("editor:editor.projectAndToolPagesDescription")}),(0,en.jsx)(V.A,{children:[{name:"breadcrumbLink",key:"breadcrumbLinkColor",value:z(g.breadcrumbLinkColor),description:"breadcrumbLinkDescription"},{name:"link",key:"linkColor",value:z(g.linkColor),description:"linkDescription"}
1,{name:"pageBackground",key:"backgroundColor",value:g.backgroundColor,description:"pageBackgroundDescription"}].map(D)}),(0,en.jsx)(tA.A,{})]}),!!w&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsxs)(m.A,{sx:{mt:2.5,mb:2,display:"flex",alignItems:"center",justifyContent:"space-between",gap:2},children:[(0,en.jsx)(m.A,{sx:{flex:"1 1 auto",minWidth:0},children:(0,en.jsx)(e_,{title:t("editor:editor.buttonColorsTitle"),subTitle:t("editor:editor.buttonColorsSubTitle"),description:t("editor:editor.buttonColorsTitleDescription"),subTitleHtmlFor:P,titleSx:{typography:"subtitle1",fontWeight:700},sx:{mb:0}})}),(0,en.jsx)(m.A,{sx:{flexShrink:0},children:(0,en.jsx)(X.A,{id:P,name:"advancedColour",checked:S,onChange:function(e){return I(e)},"data-testid":"".concat(T,"-switch")})})]}),S&&(0,en.jsxs)(en.Fragment,{children:[!!A&&!!w&&(0,en.jsx)(en.Fragment,{children:(0,en.jsx)(V.A,{label:t("editor:editor.buttons"),children:[{key:"buttonColor",name:"buttonText",value:g.buttonColor,description:"buttonTextDescription"},{key:"primaryButtonBackgroundColor",name:"primaryButton",value:z(g.primaryButtonBackgroundColor),description:"primaryButtonDescription"}].map(D)})}),!!A&&!!w&&(0,en.jsx)(V.A,{label:t("editor:editor.tools"),children:[{key:"toolCardBackgroundColor",name:"toolCardBackground",value:g.toolCardBackgroundColor,description:"toolCardBackgroundDescription"},{key:"toolTitleTextColor",name:"toolTitleText",value:z(g.toolTitleTextColor),description:"toolTitleTextDescription"},{key:"toolMetaTextColor",name:"toolSecondaryText",value:g.toolMetaTextColor,description:"toolSecondaryTextDescription"},{key:"toolBodyTextColor",name:"toolBodyText",value:g.toolBodyTextColor,description:"toolBodyTextDescription"}].map(D)}),!!A&&!!w&&(0,en.jsx)(V.A,{label:t("editor:editor.toolTabs"),children:[{key:"toolTabTextColor",name:"tabText",value:g.toolTabTextColor,description:"toolTabTextColorDescription"},{key:"tabBackgroundColor",name:"tabCardBackground",value:g.tabBackgroundColor,description:"tabBackgroundColorDescription"},{key:"toolTabActiveTextColor",name:"activeTabText",value:g.toolTabActiveTextColor,description:"toolTabActiveTextColorDescription"}
1,{key:"toolTabBackgroundColorActive",name:"activeTabBackground",value:z(g.toolTabBackgroundColorActive),description:"activeTabBackgroundDescription"},{key:"toolTabNavBackgroundColor",name:"tabBackground",value:g.toolTabNavBackgroundColor,description:"tabCardBackgroundDescription"}].map(D)}),!!A&&!!w&&(0,en.jsx)(V.A,{label:t("editor:editor.widgets"),children:[{key:"widgetCardBackgroundColor",name:"widgetCardBackground",value:g.widgetCardBackgroundColor,description:"widgetCardBackgroundDescription"},{key:"widgetTitleTextColor",name:"widgetTitle",value:z(g.widgetTitleTextColor),description:"widgetTitleDescription"},{key:"widgetMetaTextColor",name:"widgetSecondaryText",value:g.widgetMetaTextColor,description:"widgetSecondaryTextDescription"},{key:"widgetBodyTextColor",name:"widgetBodyText",value:g.widgetBodyTextColor,description:"widgetBodyTextDescription"},{key:"widgetIconColor",name:"widgetIconColour",value:z(g.widgetIconColor),description:"widgetIconColourDescription"},{key:"widgetBackgroundColor",name:"widgetColumnBackground",value:g.widgetBackgroundColor,description:"widgetColumnBackgroundDescription"}].map(D)})]})]}),(0,en.jsxs)(K.A,{direction:"row",justifyContent:"space-between",alignItems:"center",sx:{mb:2.5},children:[(0,en.jsx)(Z.A,{variant:"contained",color:"primary",loading:C,loadingPosition:"start",onClick:function(){o(),f&&j()},"data-testid":"".concat(T,"-saveBtn"),children:t("editor:editor.save")}),!!w&&(0,en.jsx)(Z.A,{color:"error",loadingPosition:"start",disabled:C,onClick:(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,v();case 2:return e.next=4,y();case 4:case"end":return e.stop()}},e)})),"data-testid":"".concat(T,"-resetBtn"),children:t("editor:editor.resetColours")})]})]})}),tC=(0,o.Ng)(function(e){var t;return{brandColor:e.theme.theme.brandColor,color1:e.theme.theme.color1,color2:e.theme.theme.color2,color3:e.theme.theme.color3,color4:e.theme.theme.color4,color5:e.theme.theme.color5,color6:e.theme.theme.color6,color7:e.theme.theme.color7,color8:e.theme.theme.color8,color9:e.theme.theme.color9,themeColors:e.layout.layout.colorMapping,layoutId:null==(t=e.layout.layout)?void 0:t.id,isProjectPageRefreshEnabled:e.features.features.hasOwnProperty("project_page_refresh")&&e.features.features.project_page_refresh.enabled,selectedColorPalette:e.layout.layout.selectedColorPalette,saving:e.layout.saving||e.theme.saving,dataTestId:"admin-ae-ps-colors"}},function(e){return(0,i.zH)({updateTemplateMeta:ea.fw,updateTheme:eN,saveTheme:ez,updateLayout:e8.mR,saveLayout:e8.Q,fetchLayout:e8.Xp,resetLayoutColor:e8.b3},e)})(tw);var tT=n(46783),tk=n(38586),tS=["classic-theme","fresh-theme","bold-theme"];let tI=(0,l.withTranslation)(["editor"])(function(e){var t,n,o,i=e.t,r=e.isDrawerVisible,a=e.imageIndex,s=e.onClose,c=e["data-testid"],l=null!=(t=null==(n=tS[a])?void 0:n.split("-")[0])?t:"classic",d=i("editor:editor.layouts.".concat(l)),u=i("editor:editor.layouts.".concat(l,"Description")),h=null!=(o=tS[a])?o:tS[0];return(0,en.jsx)(tk.A,{title:i("editor:editor.layouts.projectThemePreview"),open:r,onClose:s,anchor:"right",width:"70vw",slotProps:{root:{keepMounted:!1}},contentSx:{overflowY:"auto"},children:(0,en.jsxs)(m.A,{"data-testid":c,children:[(0,en.jsx)(q.A,{sx:{mb:1,fontWeight:600},children:d}),(0,en.jsx)(Y.A,{sx:{mb:3},children:u}),(0,en.jsx)(m.A,{component:"img",src:"/static/assets/images/home-page-themes/".concat(h,".jpg"),alt:d,sx:{display:"block",width:"100%",maxWidth:960,height:"auto",mx:"auto"}})]})})}),tP=(0,l.withTranslation)(["common","editor"])(function(e){var t,n,o=e.layout,i=e.saveLayout,r=e.t,a=e.saving,l=e.updateLayout,d=e.resetLayout,u=e.fetchLayout,p=e.disableSaveButton,x=e.dataTestId,g=(0,c.useState)(!1),f=g[0],b=g[1],j=(0,c.useState)(0),v=j[0],y=j[1],A=(0,c.useState)(!1),w=A[0],C=A[1],T=(0,c.useId)(),k=[{id:"",name:r("editor:editor.layouts.classic"),description:r("editor:editor.layouts.classicDescription")},{id:"corporate",name:r("editor:editor.layouts.fresh"),description:r("editor:editor.layouts.freshDescription")},{id:"business",name:r("editor:editor.layouts.bold"),description:r("editor:editor.layouts.boldDescription")}],S={classic:"#f5f5f5",corporate:"#BAE7FF",business:"#EFDBFF"},I=(t=(0,L.A)(W().mark(function e(t){var n;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:""===(n=t.target.value)?(b(!0),l("selectedColorPalette","")):(b(!1),l("selectedColorPalette",n));case 2:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)}),P=(n=(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(f){e.next=5;break}return e.next=3,i();case 3:e.next=7;break;case 5:return e.next=7,d();case 7:return e.next=9,u();case 9:case"end":return e.stop()}},e)})),function(){return n.apply(this,arguments)}),O=function(e){y(e),C(!0)},N=void 0===o.selectedColorPalette||null===o.selectedColorPalette?"":o.selectedColorPalette;return(0,en.jsxs)(V.A,{children:[(0,en.jsx)(eq.A,{className:"themes-group",value:N,onChange:function(e){I(e)},children:k.map(function(e,t){var n=S[e.id||"classic"],o="".concat(T,"-theme-").concat(t);return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsxs)(m.A,{className:"themes-gallery",sx:{dis
1play:"flex",minWidth:0,width:"100%"},children:[(0,en.jsxs)(m.A,{component:"label",htmlFor:o,"data-testid":"".concat(x,"-").concat(e.name),sx:{position:"relative",width:90,height:90,flexShrink:0,m:"5px",mt:"10px",cursor:"pointer",borderRadius:1,bgcolor:n,boxSizing:"border-box"},children:[(0,en.jsx)(m.A,{sx:{position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center",pointerEvents:"none",zIndex:0},children:(0,en.jsx)(tT.A,{component:"span",variant:"body2",sx:{textAlign:"center",lineHeight:1.2,color:"text.primary",m:0,maxWidth:"100%"},children:e.name})}),(0,en.jsx)(eV.A,{id:o,value:e.id,size:"small",slotProps:{input:{"aria-label":e.name}},sx:{position:"absolute",top:2,right:2,p:0,m:.25,zIndex:1}})]}),(0,en.jsxs)(m.A,{sx:{ml:1.25,display:"flex",flexDirection:"column",alignItems:"flex-start",minWidth:0,flex:1},children:[(0,en.jsx)(q.A,{sx:{mt:.625,mb:.5},children:e.name}),(0,en.jsx)(Y.A,{sx:{mb:.5},children:e.description}),e.id?(0,en.jsx)(Z.A,{variant:"text",className:"theme-preview",onClick:function(){return O(t)},"data-testid":"".concat(x,"-").concat(e.name,"-link"),sx:{p:0,minWidth:0,justifyContent:"flex-start",textTransform:"none"},children:r("editor:editor.viewExample")}):null]})]}),(0,en.jsx)(tA.A,{className:"theme-divider"})]},t)})}),(0,en.jsx)(tI,{isDrawerVisible:w,imageIndex:v,onClose:function(){C(!1)},"data-testid":"".concat(x,"-theme-drawer")}),(0,en.jsx)(h.A,{placement:"top",title:p?r("editor:editor.layoutGalleryTooltip"):"",children:(0,en.jsx)("span",{className:"jsx-324702149",children:(0,en.jsx)(Z.A,{variant:"contained",color:"primary",disabled:p,loading:a,loadingPosition:"start",onClick:P,"data-testid":"".concat(x,"-saveBtn"),children:r("editor:editor.save")})})}),(0,en.jsx)(s(),{id:"324702149",children:[".themes-gallery.jsx-324702149{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".theme-divider{margin:12px 0;}",".theme-preview{padding:0;}",".themes-group.jsx-324702149{width:100%;}"]})]})}),tO=(0,o.Ng)(function(e){return{layout:e.layout.layout,saving:e.layout.saving,disableSaveButton:!e.homePageRevisions.lastPublishedRevision,dataTestId:"admin-ae-ps-ppt"}},function(e){return(0,i.zH)({updateLayout:e8.mR,saveLayout:e8.Q,resetLayout:e8.SH,fetchLayout:e8.Xp},e)})(tP);function tN(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var tz=[{key:"color",titleKey:"editor:editor.color",descriptionKey:"editor:editor.colorDescription",icon:em.A,component:tC,dataTestIDSuffix:"color"},{key:"layout",titleKey:"editor:editor.projectPageThemes",descriptionKey:"editor:editor.themesDescription",icon:ty.A,component:tO,dataTestIDSuffix:"projectPageThemes"}];let tD=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.isProjectPageRefreshEnabled,n=e.t,o=e.dataTestId,i=(0,c.useState)("color"),r=i[0],a=i[1];return(0,en.jsx)(en.Fragment,{children:tz.map(function(e,i){if(!t&&"layout"===e.key)return null;var s,c=e.component,l=e.icon,d="".concat(o,"-").concat(e.dataTestIDSuffix),u=r===e.key;return(0,en.jsx)(m.A,{sx:{mb:1.5,borderRadius:1,border:1,borderColor:"divider",bgcolor:"background.paper",overflow:"hidden",transition:function(e){return e.transitions.create(["box-shadow"],{duration:e.transitions.duration.short})},"&:hover":{boxShadow:function(e){return e.shadows[4]}}},children:(0,en.jsxs)(el.A,{disableGutters:!0,elevation:0,expanded:u,onChange:(s=e.key,function(e,t){t?a(s):r===s&&a(!1)}),slotProps:{transition:{unmountOnExit:!0}},sx:{bgcolor:"background.paper"},children:[(0,en.jsx)(eu.A,{expandIcon:null,id:"home-page-editor-section-".concat(i,"-header"),className:"hpe-panel testId-".concat(d),slotProps:{content:{sx:{alignItems:"center",my:1}}},sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tN(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tN(Object(n)).forEac
1h(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({px:1.5,bgcolor:"grey.100"},u&&{borderBottom:1,borderColor:"divider"}),children:(0,en.jsxs)("div",{className:"hpe-section-header",children:[(0,en.jsx)("div",{className:"hpe-icon",children:(0,en.jsx)(l,{sx:{fontSize:22,color:"action.active"}})}),(0,en.jsx)("div",{children:(0,en.jsx)(B.A,{title:n(e.titleKey),description:n(e.descriptionKey)})})]})}),(0,en.jsx)(ed.A,{className:"hpe-section",sx:{pt:2,px:2,pb:2,bgcolor:"common.white"},children:(0,en.jsx)(c,{})})]})},e.key)})})}),tH=(0,o.Ng)(function(e){return{isDrawerVisible:e.homePageRevision.showTemplatesDrawer,isProjectPageRefreshEnabled:e.features.features.hasOwnProperty("project_page_refresh")&&e.features.features.project_page_refresh.enabled,dataTestId:"admin-ae-projectStyles"}})(tD);var tF=n(5714),tR=n(75612),tE=n(63160),tU=n(16765),tB=n(49387),tL=n(74593),t_=n(62069),tW=n(29043),tM=n(54920),tK=n(31314),tY=n(73275),tV=n(12336),tq=n(47172),tQ=n(60858),tZ=n(98512),tG=n(71929),tX=n(65588),t$=n(13434),tJ=n(19058),t0=n(92181),t1=n(83902);let t2=(0,o.Ng)(function(e){return{imageKey:"image",uploading:e.homePageRevision.uploadingFile,uploadError:e.homePageRevision.fileUploadError,dataTestId:"admin-homepage-editor-imagemanager"}},function(e){return(0,i.zH)({uploadImage:ea.QM},e)})(t1.A);var t3=n(94525),t5=n(6899),t4={width:1,mb:3,border:1,borderColor:"divider",borderRadius:1,position:"relative",overflow:"hidden",cursor:"pointer","@keyframes fadein":{from:{opacity:0}
1,to:{opacity:1}},animation:"fadein 3s","&:hover":{borderColor:"primary.main",boxShadow:1,"& .project-image-choose":{mt:"-45px"}}},t9=(0,c.memo)(function(e){var t,n,o,i=e.t,r=e.afterUpdate,a=(e.imageUrl,e.currentImage),s=e.updateSectionData,l=e.sectionId,u=e.projectImages,h=e.tabKey,p=e.updateSite,x=e.isHeader,g=(e.imgixUrl,e.title),f=e.imageSettingsToggler,b=e.activeImageTab,j=e.imgFocusEnabled,v=e.imgFocusX,y=e.imgFocusY,A=e.isProject,w=e.deleteKey,C=e.dataTestId,T=e.uploading,k=void 0!==T&&T,S=e.uploadError,I=void 0===S?"":S,P=(0,c.useState)(!1),O=P[0],N=P[1],z=(0,c.useState)((0,t$.yt)(a)),D=z[0],H=z[1],F=(0,c.useState)(""),R=F[0],E=F[1],U=(0,c.useState)(v),B=U[0],_=U[1],M=(0,c.useState)(y),K=M[0],Y=M[1],V=(0,c.useState)(!1),q=V[0],Q=V[1],G=(0,c.useState)(!1),et=G[0],eo=G[1],ei=(0,c.useState)(""),er=ei[0],ea=ei[1],es=(0,c.useRef)(!1),ec=a?(0,t$.yt)(a,200):"",el=a?(0,t$.yt)(a):"",ed=!D&&!!el,eu=(D||"")!==(el||"")||!!R,em=q||k,eh=et||ed||em,ep=function(e){("cropImage"!==e||D)&&f(e)};(0,c.useEffect)(function(){H((0,t$.yt)(a)),E(""),eo(!1),ea("")},[a]),(0,c.useEffect)(function(){D||"cropImage"!==b||f("upload")},[D,b,f]),(0,c.useEffect)(function(){if(O){if(k){es.current=!1,ea("");return}!es.current&&I&&(ea(String(I)),eo(!1))}},[I,k,O]);var ex=function(){a?f("cropImage"):f("upload"),E(""),eo(!1),ea(""),es.current=!0,N(!0)},eg=(t=(0,L.A)(W().mark(function e(t){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:x?p("logoUrl",t):r(t),f("upload"),E(""),eo(!1),ea(""),N(!1);case 6:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)}),ef=(n=(0,L.A)(W().mark(function e(){var t,n,o;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!em){e.next=2;break}return e.abrupt("return");case 2:if(Q(!0),e.prev=3,"cropImage"!==b){e.next=15;break}return t=(0,t$.JU)(a),e.next=8,tX.A.perform(R);case 8:return n=e.sent,H(o=t?"".concat(n,"/unsplash-").concat(t):n),e.next=13,eg(o);case 13:e.next=18;break;case 15:return e.next=17,eg(D);case 17:s("imgFocusEnabled",!1,l,h);case 18:return e.prev=18,Q(!1),e.finish(18);case 21:case"end":return e.stop()}},e,null,[[3,,18,21]])})),function(){return n.apply(this,arguments)}),eb=function(){em||(H(a?(0,t$.yt)(a):""),E(""),eo(!1),ea(""),es.current=!0,f("upload"),N(!1))},ej=(o=(0,L.A)(W().mark(function e(t){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:H(t),E(""),f("upload");case 3:case"end":return e.stop()}},e)})),function(e){return o.apply(this,arguments)}),ev=function(e){H(e),E("")};return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsxs)(m.A,{sx:{mt:.75,display:"flex",flexDirection:"column"},children:[!a&&(0,en.jsxs)(m.A,{onClick:ex,role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),ex())},"data-testid":"".concat(C,"-imageUpload"),sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:1,height:200,mb:1.5,px:2,cursor:"pointer",border:1,borderStyle:"dashed",borderColor:"divider",borderRadius:1,bgcolor:"grey.100"},children:[(0,en.jsx)($.A,{sx:{fontSize:30,color:"action.active"}}),(0,en.jsx)(tT.A,{component:"p",variant:"body2",color:"text.secondary",align:"center",children:i("project:project.clickToUpload")}),(0,en.jsx)(tT.A,{component:"p",variant:"body2",color:"text.secondary",align:"center",children:i("editor:editor.images.banner.uploadImageTypeText")})]}),!!a&&(j?(0,en.jsx)(t5.A,{url:ec,update:function(e){_(e.x),Y(e.y),void 0===h?(s("imgFocalX",B,l),s("imgFocalY",K,l)):A||w===h||(s("imgFocalX",B,l,h),s("imgFocalY",K,l,h))},positionX:B,positionY:K}):(0,en.jsx)(m.A,{component:"img",src:ec,alt:"",sx:{display:"block",width:1,height:200,mb:1.5,objectFit:"contain",objectPosition:"center",bgcolor:"grey.200"}}))]}),!x&&(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:1,pr:2},children:[(0,en.jsx)(ee.A,{tooltip:i("common:common.imageFocalPointTooltip"),placement:"top","aria-label":i("common:common.imageFocalPoint"),children:(0,en.jsx)("label",{htmlFor:"".concat(C,"-focalPoint"),children:i("common:common.imageFocalPoint")})}),(0,en.jsx)(X.A,{id:"".concat(C,"-focalPoint"),"data-testid":"".concat(C,"-focalPoint"),size:"medium",className:"auto-notify-switch",checked:j&&!!a,onChange:function(e){return s("imgFocusEnabled",e,l,h)}})]}),(0,en.jsxs)(m.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:1},children:[(0,en.jsx)(Z.A,{variant:"contained",color:"primary",onClick:ex,"data-testid":"".concat(C,"-editImageBtn"),children:a?i("editor:editor.update"):i("editor:editor.uploadImage")}),(0,en.jsx)(J.A,{"data-testid":"".concat(C,"-deleteBtn"),onClick:function(){x&&p("logoUrl",""),s("image","",l,h),H("")},disabled:!a})]}),(0,en.jsxs)(tQ.A,{title:i("editor:editor.uploadOrEdit",{title:g}),width:"80vw",visible:O,onClose:eb,closeDisabled:eh,footer:(0,en.jsxs)(t3.A,{children:[(0,en.jsx)(Z.A,{variant:"contained",color:"primary",onClick:ef,loading:q,loadingPosition:"start",disabled:k||!eu,"data-testid":"".concat(C,"-saveBtn"),children:i("common:common.save")}),(0,en.jsx)(Z.A,{onClick:eb,disabled:em,"data-testid":"".concat(C,"-cancelBtn"),children:i("common:common.cancel")})]}),children:[(0,en.jsxs)(tt.A,{value:b,onChange:function(e,t){return ep(t)},textColor:"inherit",sx:tn.R,children:[(0,en.jsx)(te.A,{value:"upload",label:(0,en.jsx)(m.A,{component:"span","data-testid":"".concat(C,"-upload"),children:i("common:common.upload")})}),(0,en.jsx)(te.A,{value:"unsplash",label:(0,en.jsx)(m.A,{component:"span","data-testid":"".concat(C,"-imagesByUnsplash"),children:(0,en.jsxs)(en.Fragment,{children:[i("editor:editor.imagesByUnsplash"),(0,en.jsx)(m.A,{component:"span",sx:{fontSize:10,
1color:"error.main",px:.75,fontWeight:300,borderRadius:1,bgcolor:function(e){return(0,t0.X4)(e.palette.error.main,.08)},ml:1.25,textTransform:"uppercase",textDecoration:"none",border:1,borderColor:"error.main"},children:i("project:project.newIdentifier")})]})})}),(0,en.jsx)(te.A,{value:"cropImage",disabled:!D,label:(0,en.jsx)(m.A,{component:"span","data-testid":"".concat(C,"-editImage"),children:i("editor:editor.imageEditor")})})]}),"upload"===b?(0,en.jsxs)(m.A,{sx:{overflowY:"auto",minHeight:"calc(100vh - 60px)"},children:[(0,en.jsx)(t2,{onActionComplete:function(e,t){if("delete"===e){H(""),E(""),eo(!1),ea("");return}"string"==typeof t&&t&&(H(t),ea(""),eo(!0))},imageUrl:D}),et||ed?(0,en.jsx)(tZ.A,{severity:"info",sx:{mt:1.5,mb:2},"data-testid":"".concat(C,"-clickSaveHint"),children:ed?i("editor:editor.image.clickSaveToApplyDelete"):i("editor:editor.image.clickSaveToApply")}):null,er?(0,en.jsxs)(tZ.A,{severity:"error",sx:{mt:1.5,mb:2},"data-testid":"".concat(C,"-uploadFailedHint"),onClose:function(){ea(""),es.current=!0},children:[D?i("editor:editor.image.uploadFailedKeepPrevious"):i("editor:editor.image.uploadFailed"),er?" (".concat(er,")"):null]}):null,(0,en.jsx)(m.A,{sx:{mt:3},children:(0,en.jsx)(d.A,{container:!0,spacing:3,children:u.map(function(e,t){return(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsxs)(m.A,{onClick:function(t){return ev(e,t)},role:"button","data-testid":"".concat(C,"-chooseThisImage"),sx:t4,children:[(0,en.jsx)(m.A,{sx:{width:1,height:300,backgroundImage:"url(".concat(e,")"),backgroundSize:"cover",backgroundRepeat:"no-repeat"}}),(0,en.jsx)(m.A,{className:"project-image-choose",sx:{mb:0,p:1.5,bgcolor:"primary.main",color:"primary.contrastText",textAlign:"center",fontWeight:"bold",mt:5,position:"absolute",width:1,transition:"margin-top 0.1s ease-in-out"},children:i("editor:editor.chooseThisImage")})]})},t)})})})]}):null,"unsplash"===b?(0,en.jsx)(m.A,{sx:{overflowY:"auto",minHeight:"calc(100vh - 60px)"},children:(0,en.jsx)(tJ.A,{onImageSelect:ej,minHeightOfModal:600})}):null,"cropImage"===b&&D?(0,en.jsx)(m.A,{sx:{width:"91.666%"},children:(0,en.jsx)(tG.A,{src:D,onComplete:function(e){e&&e.toBlob(function(e){e&&(e.name=a&&a.split("/")[4],E(e))})},dataTestId:C})}):null]})]})});let t6=(0,l.withTranslation)(["common","editor","project"])(t9);var t8=n(66689),t7=function(e){var t=e.reduce(function(e,t){return t.imageUrl?e.concat(t.imageUrl):e},[]),n=e.reduce(function(e,t){return t.bannerUrl?e.concat(t.bannerUrl):e},[]);return[].concat((0,r.A)(t),(0,r.A)(n))};let ne=(0,o.Ng)(function(e){return{uploading:e.homePageRevision.uploadingFile,uploadError:e.homePageRevision.fileUploadError,imageUrl:e.homePageRevision.uploadedFileUrl,projectImages:t7(e.projects.projects),activeImageTab:e.project.activeImageTab,dataTestId:"admin-ae-he-drawers-image-manager"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSite:er.hj,imageSettingsToggler:t8.xd},e)})(t6);var nt=(0,c.memo)(function(e){var t=e.t,n=e.updateSectionData,o=e.logoUrl,i=e.data,r=e.sectionId,a=e.updateSite,s=e.dataTestId,l=i.signInText,u=i.signInUrl,m=i.signUpText,h=i.signUpUrl;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.images.logoImage"),children:(0,en.jsx)(ne,{afterUpdate:function(e){return a("logoUrl",e)},currentImage:o,sectionId:r,isHeader:!0,imgixUrl:!0,title:t("editor:editor.images.logoImage")})}),(0,en.jsxs)(d.A,{container:!0,spacing:3,sx:{alignItems:"flex-end"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:t("editor:editor.signInText"),sx:{mb:0,width:"100%"},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-signInText"),name:"signInText",value:"Sign in"===l?t("editor:editor.signIn"):l,onChange:function(e){return n("signInText",e.target.value,r)},onClear:function(){return n("signInText","",r)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{sx:{mb:0,width:"100%"},label:(0,en.jsx)(ee.A,{tooltip:t("editor:editor.helpTexts.signInUrl"),placement:"right",children:t("editor:editor.signInUrl")}),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-signInUrl"),name:"signInUrl",value:u,onChange:function(e){return n("signInUrl",e.target.value,r)},onClear:function(){return n("signInUrl","",r)}})})})]}),(0,en.jsxs)(d.A,{container:!0,spacing:3,sx:{alignItems:"flex-end",mt:2},children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:t("editor:editor.registerText"),sx:{mb:0,width:"100%"},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-registerText"),name:"signUpText",value:"Register"===m?t("editor:editor.register"):m,onChange:function(e){return n("signUpText",e.target.value,r)},onClear:function(){return n("signUpText","",r)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{sx:{mb:0,width:"100%"},label:(0,en.jsx)(ee.A,{tooltip:t("editor:editor.helpTexts.registerUrl"),placement:"right",children:t("editor:editor.registerUrl")}),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-registerUrl"),name:"signUpUrl",value:h,onChange:function(e){return n("signUpUrl",e.target.value,r)},onClear:function(){return n("signUpUrl","",r)}})})})]}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:1.5,mb:1.5,children:t("editor:editor.headerDescription")})]})});let nn=(0,l.withTranslation)(["common","editor"])(nt),no=(0,o.Ng)(function(e,t){return{logoUrl:e.currentSite.site.logoUrl,data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-header-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSite:er.hj},e)})(nn);var ni=(0,c.memo)(function(e){var t=e.t,n=e.updateSectionTheme,o=e.mainNavbarBackgroun
1dColor,i=e.mainNavbarTextColor,r=e.sectionId,a=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.mainNavbarTextColor"),children:(0,en.jsx)(eg.A,{color:i,fieldKey:"mainNavbarTextColor",onChange:function(e){return n("mainNavbarTextColor",e,r)},"data-testid":"".concat(a,"-mainNavbarTextColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.mainNavbarBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o,fieldKey:"mainNavbarBackgroundColor",onChange:function(e){return n("mainNavbarBackgroundColor",e,r)},"data-testid":"".concat(a,"-mainNavbarBackgroundColor")})})]})});let nr=(0,l.withTranslation)(["common","editor"])(ni),na=(0,o.Ng)(function(e,t){return{mainNavbarBackgroundColor:e.homePageRevision.revision.sections[t.sectionId].theme.mainNavbarBackgroundColor,mainNavbarTextColor:e.homePageRevision.revision.sections[t.sectionId].theme.mainNavbarTextColor,dataTestId:"admin-ae-he-sections-header-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(nr);var ns=n(79837),nc=n(60964);let nl=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.content,o=e.updateFilters,i=e.dataTestId,r=(0,c.useState)(!1),a=r[0],s=r[1];return(0,c.useEffect)(function(){o({state:n})}),(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(Z.A,{"data-testid":"".concat(i,"-editLinks"),variant:"contained",color:"primary",onClick:function(){return s(!0)},children:t("editor:editor.editLinks")}),(0,en.jsxs)(tk.A,{width:"80vw",open:a,closeBarOnly:!0,onClose:function(){s(!1)},contentSx:{mx:0,my:0},slotProps:{root:{keepMounted:!1}},children:[(0,en.jsx)(ns.A,{content:n}),(0,en.jsx)(nc.A,{navigation:!0})]})]})});var nd=n(93055);let nu=(0,o.Ng)(function(){return{dataTestId:"admin-ae-he-drawers-nav-links-editor"}},function(e){return(0,i.zH)({updateFilters:nd.v},e)})(nl),nm=(0,l.withTranslation)(["editor"])(function(e){var t=e.t;return(0,en.jsx)(en.Fragment,{children:(0,en.jsxs)(V.A,{children:[(0,en.jsx)(eU.A,{label:t("editor:editor.navigationLinks"),sx:{mt:2}}),(0,en.jsx)(Y.A,{sx:{mb:2.5},children:t("editor:editor.navigationLinksDescription")}),(0,en.jsx)(nu,{content:"header"})]})})});var nh=n(59860),np=n(63065),nx=n(4053),ng=n(46721),nf=n(26555),nb=n(20267),nj=n(42453),nv=n(68959),ny=n(55643),nA=n(44434),nw=n(21014),nC=["title","icon","className","data-testid"];function nT(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function nk(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nT(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nT(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var nS=(0,c.forwardRef)(function(e,t){var n=e.title,o=e.icon,i=e.className,r=e["data-testid"],a=(0,nh.A)(e,nC);return(0,en.jsx)(h.A,{title:n,children:(0,en.jsx)("span",nk(nk({ref:t,className:i},a),{},{style:{display:"inline-flex",alignItems:"center",justifyContent:"center"},children:(0,en.jsx)(o,{"data-testid":r,sx:{fontSize:20,display:"block",color:"inherit"}})}))})});let nI=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.sectionId,o=e.updateSectionMeta,i=e.hidden,r=e.deleteSection,a=e.textTabPane,s=e.colorTabPane,l=e.fontTabPane,d=e.layoutTabPane,u=e.linksTabPane,h=e.canBeHidden,p=void 0===h||h,x=e.canBeDeleted,g=void 0===x||x,f=e.canBeMovedUp,b=e.canBeMovedDown,j=e.moveSection,y=e.dataTestId,A=(0,c.useState)("details"),w=A[0],C=A[1],T=(0,c.useState)(null),k=T[0],S=T[1],I=function(){return S(null)};return(0,en.jsxs)(m.A,{children:[(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",borderBottom:1,borderColor:"divider"},children:[(0,en.jsxs)(tt.A,{value:w,onChange:function(e,t){return C(t)},variant:"scrollable",scrollButtons:"auto",textColor:"inherit",sx:nk({flex:1,alignSelf:"stretch",borderBottom:"none"},tn.i),children:[(0,en.jsx)(te.A,{value:"details","aria-label":t("editor:editor.content"),icon:(0,en.jsx)(nS,{title:t("editor:editor.content"),icon:nf.A,"data-testid":"".concat(y,"
1-content")}),iconPosition:"top"}),(0,en.jsx)(te.A,{value:"color","aria-label":t("editor:editor.color"),icon:(0,en.jsx)(nS,{title:t("editor:editor.color"),icon:em.A,"data-testid":"".concat(y,"-color")}),iconPosition:"top"}),l&&(0,en.jsx)(te.A,{value:"font","aria-label":t("editor:editor.font"),icon:(0,en.jsx)(nS,{title:t("editor:editor.font"),icon:eh.A,"data-testid":"".concat(y,"-font")}),iconPosition:"top"}),d&&(0,en.jsx)(te.A,{value:"layout","aria-label":t("editor:editor.layout"),icon:(0,en.jsx)(nS,{title:t("editor:editor.layout"),icon:D.A,"data-testid":"".concat(y,"-layout")}),iconPosition:"top"}),u&&(0,en.jsx)(te.A,{value:"links","aria-label":t("editor:editor.links"),icon:(0,en.jsx)(nS,{title:t("editor:editor.links"),icon:nb.A,"data-testid":"".concat(y,"-links")}),iconPosition:"top"})]}),(p||g)&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(v.A,{"aria-label":t("common:common.more"),"data-testid":"".concat(y,"-threeDots"),onClick:function(e){return S(e.currentTarget)},size:"medium",sx:{color:"text.primary",ml:.75,flexShrink:0},children:(0,en.jsx)(nj.A,{sx:{fontSize:25}})}),(0,en.jsxs)(np.A,{anchorEl:k,open:!!k,onClose:I,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:[p&&(0,en.jsxs)(eH.A,{onClick:function(){o("hidden",!i,n),I()},"data-testid":"".concat(y,"-hideUnhide"),children:[(0,en.jsx)(nx.A,{children:i?(0,en.jsx)(nv.A,{fontSize:"small"}):(0,en.jsx)(tq.A,{fontSize:"small"})}),(0,en.jsx)(ng.A,{primary:t(i?"editor:editor.unhideThisSection":"editor:editor.hideThisSection")})]}),f&&(0,en.jsxs)(eH.A,{onClick:function(){j(n,"before"),I()},"data-testid":"".concat(y,"-moveSectionUp"),children:[(0,en.jsx)(nx.A,{children:(0,en.jsx)(ny.A,{fontSize:"small"})}),(0,en.jsx)(ng.A,{primary:t("editor:editor.moveSectionUp")})]}),b&&(0,en.jsxs)(eH.A,{onClick:function(){j(n,"after"),I()},"data-testid":"".concat(y,"-moveSectionDown"),children:[(0,en.jsx)(nx.A,{children:(0,en.jsx)(nA.A,{fontSize:"small"})}),(0,en.jsx)(ng.A,{primary:t("editor:editor.moveSectionDown")})]}),g&&(0,en.jsxs)(eH.A,{onClick:function(){r(n),I()},"data-testid":"".concat(y,"-deleteSection"),sx:{color:"error.main"},children:[(0,en.jsx)(nx.A,{children:(0,en.jsx)(nw.A,{sx:{color:"error.main"}})}),(0,en.jsx)(ng.A,{primary:t("editor:editor.deleteSection")})]})]})]})]}),(0,en.jsxs)(m.A,{sx:{pt:2,px:2,pb:2},children:["details"===w&&(0,en.jsx)(a,{sectionId:n}),"color"===w&&(0,en.jsx)(s,{sectionId:n}),l&&"font"===w&&(0,en.jsx)(l,{sectionId:n}),d&&"layout"===w&&(0,en.jsx)(d,{sectionId:n}),u&&"links"===w&&(0,en.jsx)(u,{sectionId:n})]})]})}),nP=(0,o.Ng)(function(e,t){var n=e.homePageRevision.revision.sections,o=t.sectionId;return{hidden:n[t.sectionId].meta.hidden,canBeMovedUp:-1===[0,1,n.length-1].indexOf(o),canBeMovedDown:-1===[0,n.length-2,n.length-1].indexOf(o),dataTestId:"admin-ae-he-section-controls"}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA,moveSection:ea.hB},e)})(nI),nO=function(e){var t=e.sectionId;return(0,en.jsx)(nP,{textTabPane:no,colorTabPane:na,linksTabPane:nm,sectionId:t,hidden:!1,canBeHidden:!1,canBeDeleted:!1})};var nN=n(75564),nz=n(65013),nD=n.n(nz),nH=n(1796),nF=n(55700),nR=n(79834),nE=n(300),nU=n(9948),nB=n(1044);function nL(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function n_(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nL(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nL(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var nW=(0,c.memo)(function(e){var t,n,o,i,r=e.data,a=e.sectionId,s=e.t,l=e.theme,u=e.hubs,h=e.projects,p=e.projectsQuery,x=e.projectsMeta,g=e.fetchingHubs,f=e.isHubEnabled,b=e.isHubAdminEnabled,j=e.fetchHubs,v=e.updateSectionData,y=e.updateSectionTheme,A=e.updateProjectQuery,w=e.updateProjectFilter,C=e.fetchProjects,T=e.resetProjects,k=e.dataTestId,S=b&&f;(0,c.useEffect)(function(){S&&j()},[]),(0,c.useEffect)(function(){(null==r?void 0:r.ctaLinkType)==="signInPage"&&(null==r?void 0:r.ctaLink)!=="/login"&&(null==r?void 0:r.ctaText)!==""&&v("ctaLink","/login",a)},[r]);var I=function(e){switch(v("ctaLinkType",e,a),e){case"signInPage":v("ctaLink","/login",a);break;case"registerPage":v("ctaLink","/register",a);break;case"projects":case"customUrl":case"hubs":v("ctaLink","",a)}},P=function(e){var t=nD()(u,function(t){return t.id===e});v("hubId",t.id,a),v("ctaLink",t.permalink,a),v("title",t.name,a),v("description",t.description,a),v("image",t.imageUrl,a)},O=function(e){v("ctaLink","/".concat(e.permalink),a),v("ctaLinkName",e.name,a)};return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:s("editor:editor.images.bannerImageHelp"),placement:"top",children:s("editor:editor.images.bannerImage")}),children:(0,en.jsx)(ne,{afterUpdate:function(e){return v("image",e,a)},currentImage:r.image,sectionId:a,title:s("editor:editor.images.bannerImage"),imgFocusEnabled:r.imgFocusEnabled,imgFocusX:r.imgFocalX,imgFocusY:r.imgFocalY})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:(0,en.jsx)(et.A,{html:s("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":s("common:common.images.imageAltText"),children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(k,"-imageAltText"),children:s("common:common.images.imageAltText")})}),extra:(null==r||null==(t=r.altText)?void 0:t.length)===125?s("common:common.maxCharactersReached"):void 0,children:(0,en.jsx)(Q.A,{id:"".concat(k,"-imageAltText"),fullWidth:!0,variant:"outlined",name:"bannerAltText",value:r.altText,onChange:function(e){return v("altText",e.target.value,a)},slotProps:{htmlInput:{id:"".concat(k,"-imageAltText"),maxLength:125}},onClear:function(){return v("altText","",a)},"data-testid":"".concat(k,"-imageAltText"),error:(null==r||null==(n=r.altText)?void 0:n.length)===125})}),(0,en.jsx)(nR.A,{label:s("editor:editor.displayFullBannerImage"),control:(0,en.jsx)(X.A,{name:"fullHeight",checked:r.fullHeight,onChange:function(e){v("fullHeight",e,a)},"data-testid":"".concat(k,"-displayFullBannerImage")})}),r.fullHeight&&(0,en.jsx)(ee.A,{textVariant:"body2",mb:3,children:s("editor:editor.helpTexts.fullHeight")}),!r.fullHeight&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(V.A,{sx:{display:"grid",gridTemplateColumns:"1fr auto",alignItems:"center",columnGap:2,"& > :first-of-type":{mb:0},"& > :nth-of-type(2)":{width:"auto"}},label:(0,en.jsx)(ee.A,{tooltip:s("editor:editor.helpTexts.bannerHeight"),placement:"top",children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(k,"-height"),children:s("editor:editor.heightOfBanner")})}),children:(0,en.jsx)(eR.A,{id:"".concat(k,"-height"),type:"number",size:"medium",variant:"outlined",sx:{width:80},value:null!=(o=l.minHeight)?o:"",slotProps:{htmlInput:{id:"".concat(k,"-height"),min:300,max:800,step:50}},onChange:function(e){var t=e.target.value;if(""===t)return void y("minHeight",void 0,a);var n=Number(t);Number.isNaN(n)||y("minHeight",n,a)},onBlur:function(e){var t=e.target.value;if(""!==t){var n=Number(t);if(Number.isNaN(n))return void y("minHeight",void 0,a);var o=Math.min(800,Math.max(300,n));o!==l.minHeight&&y("minHeight",o,a)}},disabled:!(r.title||r.description||r.ctaText),className:"testId-".concat(k,"-height")})}),(0,en.jsx)(V.A,{label:s("common:common.title"),children:(0,en.jsx)(Q.A,{fullWidth:!0,variant:"outlined",name:"title",value:r.title,onChange:function(e){return v("title",e.target.value,a)},"data-testid":"".concat(k,"-title")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(m.A,{component:"label",id:"".concat(k,"-description-label"),htmlFor:"".concat(k,"-description"),children:s("common:common.description")}),className:"testId-".concat(k,"-froala"),children:(0,en.jsx)(nE.A,{id:"".concat(k,"-description"),labelledBy:"".concat(k,"-description-label"),name:"description",value:r.description,onChange:function(e){return v("description",e.target.value,a)},config:(0,nU.J)("HomePageBanner"),dataTestId:"froala-editor-home-banner-description"})}),(0,en.jsxs)(m.A,{sx:{display:"grid",width:"100%",gap:3,gridTemplateColumns:"repeat(2, minmax(0, 1fr))"},children:[(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:s("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(k,"-btnText"),children:s("editor:editor.ctaText")})}),children:(0,en.jsx)(Q.A,{id:"".concat(k,"-btnText"),fullWidth:!0,size:"medium",variant:"outlined",name:"ctaText",value:r.ctaText,onChange:function(e){return v("ctaText",e.target.value,a)},slotProps:{htmlInput:{id:"".concat(k,"-btnText")}},"data-testid":"".concat(k,"-btnText")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:s("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:(0,en.jsx)(m.A,{component:"label",id:"".concat(k,"-btnURL-label"),htmlFor:"".concat(k,"-btnURL"),children:s("editor:editor.ctaLink")})}),children:(0,en.jsxs)(eR.A,{id:"".concat(k,"-btnURL"),select:!0,fullWidth:!0,size:"medium",variant:"outlined",value:r.ctaLinkType,onCh
1ange:function(e){return I(e.target.value)},className:"testId-".concat(k,"-btnURL"),slotProps:{select:{labelId:"".concat(k,"-btnURL-label")}},children:[(0,en.jsx)(eH.A,{value:"signInPage",children:s("common:common.signInPage")}),(0,en.jsx)(eH.A,{value:"registerPage",children:s("common:common.registerPage")}),(0,en.jsx)(eH.A,{value:"projects",children:s("common:common.projects")}),S&&(0,en.jsx)(eH.A,{value:"hubs",children:s("common:common.hubs")}),(0,en.jsx)(eH.A,{value:"customUrl",children:s("common:common.customURL")})]})})]}),"projects"===r.ctaLinkType&&(0,en.jsx)(V.A,{label:s("editor:editor.selectProject"),children:(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(k,"-selectProject"),data:r,options:h,optionLabel:"name",optionValue:"permalink",fetch:C,meta:x,query:p,updateQuery:A,updateFilter:w,reset:T,onSelect:function(e){return O(e)}})}),"hubs"===r.ctaLinkType&&S&&(0,en.jsx)(V.A,{label:s("editor:editor.selectHub"),children:(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(k,"-selectHub"),options:u,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,value:null!=(i=u.find(function(e){return e.id===r.hubId}))?i:null,onChange:function(e,t){t&&P(t.id)},disabled:!u.length||g,renderInput:function(e){return(0,en.jsx)(eR.A,n_(n_({},e),{},{size:"medium",placeholder:s("editor:editor.selectHub"),variant:"outlined"}))}})}),"customUrl"===r.ctaLinkType&&(0,en.jsx)(d.A,{container:!0,spacing:3,sx:{mb:2.5},children:(0,en.jsx)(d.A,{size:{xs:12,md:12},children:(0,en.jsx)(Q.A,{fullWidth:!0,size:"medium",variant:"outlined",name:"ctaCustomTextUrl",value:r.ctaLink,onChange:function(e){v("ctaLink",e.target.value,a)},"data-testid":"".concat(k,"-ctaCustomTextUrl")})})}),(0,en.jsx)(nR.A,{label:s("editor:editor.openInNewTab"),control:(0,en.jsx)(X.A,{name:"openInNewTab",checked:r.openInNewTab,onChange:function(e){return v("openInNewTab",e,a)},"data-testid":"".concat(k,"-openInNewTab")})})]})]})});let nM=(0,l.withTranslation)(["common","editor"])(nW);var nK=n(7073);let nY=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],theme:e.homePageRevision.revision.sections[t.sectionId].theme,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,fetchingHubs:e.hubs.fetching,hubs:e.hubs.hubs,isHubEnabled:e.features.features.hasOwnProperty("self_service_hubs")&&e.features.features.self_service_hubs.enabled,isHubAdminEnabled:e.features.features.hasOwnProperty("hub_admin")&&e.features.features.hub_admin.enabled,dataTestId:"admin-ae-he-sections-banner-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionTheme:ea.oz,updateProjectQuery:nK.oR,updateProjectFilter:nK.vm,fetchProjects:nK.O$,resetProjects:nK.r$,fetchHubs:nN.R5},e)})(nM);var nV=n(76159),nq=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId,a=function(e){return function(n){return i(e,n,t)}};return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:a("textColor"),"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:a("ctaBackgroundColor"),"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:a("ctaBackgroundHoverColor"),"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:a("ctaTextColor"),"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:a("ctaTextHoverColor"),"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:a("backgroundColor"),"data-testid":"".concat(r,"-backgroundColor")})}),(0,en.jsx)(nV.A,{label:n("editor:editor.backgroundColourOpacity"),value:o.bannerOpacity,min:80,max:100,unit:"%",onChange:function(e){return i("bannerOpacity",e,t)},className:"testId-".concat(r,"-backgroundColourOpacity")})]})});let nQ=(0,l.withTranslation)(["common","editor"])(nq),nZ=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-banner-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(nQ);var nG=n(69332);let nX=(0,l.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.titleFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(V.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(nV.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,en.jsx)(nV.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),n$=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-banner-text"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(nX);var nJ=n(92449),n0=n(79711),n1=n(64529),n2=n(81347),n3=n(10359),n5=n(68593),n4=n(74692),n9=n(36345),n6="blue.600",n8={display:"block",width:"100%",height:"auto",borderRadius:1};let n7=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout,dataTestId:"admin-ae-he-tabs-layout"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(function(e){var t=e.updateSectionTheme,n=e.sectionId,o=e.layout,i=e.layouts,r=e.dataTestId,a=(0,l.useTranslation)("editor").t,s=(0,c.useRef)([]);(0,c.useEffect)(function(){var e=s.current;return function(){e.forEach(clearTimeout)}},[]);var d=function(e){document.getElementById("home-page-view-section-".concat(e))&&document.getElementById("home-page-view-section-".concat(e)).scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})};return(0,en.jsx)(c.Fragment,{children:i.map(function(e,i){var c=o===e.id;return(0,en.jsxs)(n4.A,{disableRipple:!0,"aria-pressed":c,"aria-label":"".concat(a("editor:editor.layout")," ").concat(i+1),"data-testid":"".concat(r,"-").concat(e.id),sx:{display:"block",position:"relative",width:"100%",mb:3,p:0,border:1,borderColor:c?n6:"grey.300",borderRadius:1,boxShadow:c?function(e){return e.shadows[2]}:"none",animation:"layoutFadeIn 3s","@keyframes layoutFadeIn":{from:{opacity:0}
1,to:{opacity:1}},"&:last-of-type":{mb:0},"&:hover, &.Mui-focusVisible":{borderColor:n6,boxShadow:function(e){return e.shadows[2]}},"&:hover .layout-check":{opacity:c?1:.6}},onClick:function(){t("layout",e.id,n);var o=setTimeout(function(){d(n)},1e3);s.current.push(o)},children:[(0,en.jsx)(m.A,{component:"img",src:e.imageUrl,alt:"",sx:n8}),(0,en.jsx)(m.A,{className:"layout-check",sx:{position:"absolute",top:6,left:6,width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",border:1,borderColor:"common.white",bgcolor:"success.main",color:"common.white",opacity:+!!c},children:(0,en.jsx)(n9.A,{sx:{fontSize:14}})})]},e.id)})})}),oe=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:nJ},{id:"two",imageUrl:n0},{id:"three",imageUrl:n1},{id:"four",imageUrl:n2},{id:"five",imageUrl:n3},{id:"six",imageUrl:n5}],sectionId:t})}),ot=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:nY,colorTabPane:nZ,fontTabPane:n$,layoutTabPane:oe,sectionId:t,hidden:n})});var on=n(66354),oo=n(22586),oi=n(6471),or=n(80677),oa=n(37485);function os(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function oc(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?os(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):os(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var ol={width:"100%"},od=(0,c.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.fetchingTools,i=e.fetchingHubs,r=e.deleteSectionData,a=e.fetchProject,s=e.fetchTools,l=e.resetTools,u=e.fetchHubs,g=e.meta,f=e.projects,b=e.projectsQuery,j=e.projectsMeta,v=e.tools,y=e.hubs,A=e.projectTags,w=e.sectionId,C=e.selectedProject,T=e.t,k=e.isHubEnabled,S=e.isHubAdminEnabled,I=e.updateProject,P=e.updateSectionData,O=e.updateSectionMeta,N=e.updateProjectQuery,z=e.updateProjectFilter,D=e.fetchProjects,H=e.resetProjects,F=e.reorderHomepageItems,R=e.dataTestId,E=S&&k,U=(0,c.useState)(null),B=U[0],L=U[1],_=(0,c.useState)([])[1],W=(0,c.useState)(String(n[0].id)),M=W[0],K=W[1],Y=(0,c.useState)(!1),q=Y[0],G=Y[1],$=(0,c.useState)(!1),J=$[0],et=$[1];(0,oa.A)(w,F,n.length,"home-page-tabs",!g.autoAddProjects),(0,c.useEffect)(function(){C.id&&null!==B&&(P("image",C.imageUrl||C.bannerUrl,w,B),P("title",C.name,w,B),P("description",C.description,w,B),P("permalink","/".concat(C.permalink),w,B),P("id",C.id,w,B),P("state",C.state,w,B),P("publishedAt",C.publishedAt,w,B),P("isSiteProject",!0,w,B)),L(null),_(n.map(function(e){return e.id}))},[C,n]),(0,c.useEffect)(function(){"tools"!==n[0].ctaLinkType||q||(I("id",n[0].projectId),s(),G(!0))},[v]),(0,c.useEffect)(function(){E&&u()},[E,u]);var eo=function(e,t){P("ctaLinkType",e,w,t),P("permalink","",w,t),P("id",n[0].id+t,w,t),K(String(n[0].id+t)),P("image","",w,t),P("title","",w,t),P("description","",w,t),P("ctaLink","",w,t),P("ctaLinkName","",w,t),P("status","",w,t),l()},ei=function(e,t){var n=f.filter(function(t){return t.id===e.id});if(n.length>0){var o=n[0].imageUrl,i=n[0].bannerUrl;P("image",o||i,w,t)}I("permalink",e.permalink),I("id",e.id),P("projectId",e.id,w,t),P("image",e.imageUrl,w,t),P("ctaLink","/".concat(e.permalink),w,t),P("ctaLinkName",e.name,w,t),s()},er=function(e,t){var n=nD()(v,function(t){return t.id===e});n&&(P("toolId",n.id,w,t),P("title",n.name,w,t),P("description",n.description,w,t),P("permalink","SurveyTool"===n.type?n.path.replace("survey_tools","surveys"):n.path,w,t),P("status",n.state,w,t))},ea=function(e,t){var n=nD()(y,function(t){return t.id===e});n&&(P("hubId",n.id,w,t),P("permalink",n.permalink,w,t),P("title",n.name,w,t),P("description",n.description,w,t),P("image",n.imageUrl,w,t))},es=function(e,t){K(String(e.id)),L(t),a(e.id).then(function(){P("ctaLink","/".concat(e.permalink),w,t),P("ctaLinkName",e.name,w,t)})},ec=g.autoAddProjectsTags||[];return(0,en.jsxs)(m.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,en.jsx)(V.A,{label:T("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(R,"-sectionTitle"),name:"title",value:g.title,onChange:function(e){return O("title",e.target.value,w)}})}),(0,en.jsx)(V.A,{children:(0,en.jsx)(nR.A,{sx:{mb:0},label:(0,en.jsx)(ee.A,{tooltip:T("editor:editor.helpTexts.displayPublishDate"),placement:"top",children:(0,en.jsx)(m.A,{component:"span",title:T("editor:editor.displayPublishDate"),children:T("editor:editor.displayPublishDate")})}),control:(0,en.jsx)(X.A,{"data-testid":"".concat(R,"-displayPublishDate"),name:"showPublishDate",checked:g.showPublishDate,onChange:function(e){return O("showPublishDate",e,w)}})})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,sx:{justifyContent:"space-between",alignItems:"center"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(ee.A,{tooltip:T("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"top",children:(0,en.jsx)(m.A,{component:"label",sx:{dis
1play:"inline",cursor:"default"},title:T("editor:editor.ctaText"),children:T("editor:editor.ctaText")})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(R,"-buttonEmptyCTAText"),name:"ctaText",value:g.ctaText,onChange:function(e){return O("ctaText",e.target.value,w)},sx:ol})})]})}),(0,en.jsx)(tA.A,{sx:{mt:0}}),(0,en.jsx)(V.A,{label:T("editor:editor.helpTexts.projectSelectionMode"),sx:{pt:2},children:(0,en.jsxs)(x.A,{exclusive:!0,value:g.autoAddProjects?"true":"false",onChange:function(e,t){null!=t&&O("autoAddProjects","true"===t,w)},size:"medium",className:"testId-".concat(R,"-projectSelectionMode"),children:[(0,en.jsx)(p.A,{value:"true","data-testid":"".concat(R,"-autoSelect"),children:T("editor:editor.autoSelect")}),(0,en.jsx)(p.A,{value:"false","data-testid":"".concat(R,"-manualSelect"),children:T("editor:editor.manualSelect")})]})}),g.autoAddProjects?(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:T("editor:editor.selectProjectTags"),children:(0,en.jsx)(eR.A,{select:!0,fullWidth:!0,size:"medium",variant:"outlined",className:"testId-".concat(R,"-selectProjectTags"),placeholder:T("editor:editor.selectProjectTags"),value:ec,onChange:function(e){return O("autoAddProjectsTags",e.target.value,w)},slotProps:{select:{multiple:!0,displayEmpty:!0,renderValue:function(e){var t=new Set(("string"==typeof e?[e]:e).map(function(e){return String(e)})),n=A.filter(function(e){return t.has(String(e.id))}).map(function(e){return e.name});return n.length?n.join(", "):""}}},children:A.map(function(e){return(0,en.jsx)(eH.A,{value:e.id,children:e.name},e.id)})})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:2,sx:{justifyContent:"space-between"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:10},children:(0,en.jsx)(m.A,{component:"label",sx:{display:"block",cursor:"default"},title:T("editor:editor.showProjectStatus"),children:T("editor:editor.showProjectStatus")})}),(0,en.jsx)(d.A,{size:{xs:12,md:2},children:(0,en.jsx)(X.A,{"data-testid":"".concat(R,"-showProjectStatus"),name:"showProjectStatus",checked:g.showProjectStatus,onChange:function(e){return O("showProjectStatus",e,w)}})})]})}),(0,en.jsx)(V.A,{label:T("editor:editor.filterByProjectStatus"),children:(0,en.jsxs)(x.A,{exclusive:!0,value:g.autoAddProjectsStatus,onChange:function(e,t){null!=t&&O("autoAddProjectsStatus",t,w)},size:"medium",className:"testId-".concat(R,"-filterByProjectStatus"),children:[(0,en.jsx)(p.A,{value:"all","data-testid":"".concat(R,"-all"),children:T("common:common.all")}),(0,en.jsx)(p.A,{value:"published","data-testid":"".concat(R,"-published"),children:T("common:common.published")}),(0,en.jsx)(p.A,{value:"archived","data-testid":"".concat(R,"-archived"),children:T("common:common.archived")})]})}),(0,en.jsx)(V.A,{label:T("editor:editor.orderProjectsBy"),children:(0,en.jsxs)(x.A,{exclusive:!0,value:g.autoAddProjectsOrder,onChange:function(e,t){null!=t&&O("autoAddProjectsOrder",t,w)},size:"medium",className:"testId-".concat(R,"-orderProjectsBy"),children:[(0,en.jsx)(p.A,{value:"datePublished","data-testid":"".concat(R,"-datePublished"),children:T("common:common.datePublished")}),(0,en.jsx)(p.A,{value:"name","data-testid":"".concat(R,"-title"),children:T("common:common.title")})]})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:2,alignItems:"center",children:[(0,en.jsx)(d.A,{size:{xs:12,md:"auto"},children:(0,en.jsx)(m.A,{component:"label",sx:{display:"block",cursor:"default"},title:T("editor:editor.numberOfProjectsToDisplay"),children:T("editor:editor.numberOfProjectsToDisplay")})}),(0,en.jsx)(d.A,{size:{xs:12,md:"auto"},children:(0,en.jsx)(eR.A,{type:"number",size:"medium",className:"testId-".concat(R,"-numberOfProjectsToDisplay"),style:{width:60},value:g.autoAddProjectsLimit,slotProps:{htmlInput:{min:0}},onChange:function(e){return O("autoAddProjectsLimit",Number(e.target.value),w)}})})]})})]}):(0,en.jsxs)(m.A,{children:[(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(w),value:M,onChange:function(e,t){K(t);var o=n.filter(function(e){return String(e.id)===String(t)});o.length>0&&"tools"===o[0].ctaLinkType&&(I("id",o[0].projectId),s())},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(R,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(T("editor:editor.project")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(oi.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:T("editor:editor.addNewProject"),children:(0,en.jsx)(Z.A,{variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(w,e),K(String(e))},"data-testid":"".concat(R,"-addNewProject"),children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){var a,s;return String(e.id)===M?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsxs)(d.A,{container:!0,spacing:3,sx:{mb:1.25},children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(R,"-cardType-").concat(e.id),sx:{display:"block",typography:"body1",color:"text.primary"},children:T("editor:editor.cardType")})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsxs)(eR.A,{id:"".concat(R,"-cardType-").concat(e.id),select:!0,fullWidth:!0,size:"medium",variant:"outlined",placeholder:T("common:common.select"),className:"testId-".concat(R,"-cardType"),value:e.ctaLinkType,onChange:function(e){return eo(e.target.value,t)},slotProps:{select:{displayEmpty:!0}},children:[(0,en.jsx)(eH.A,{value:"projects",children:T("common:common.projects")}),(0,en.jsx)(eH.A,{value:"tools",children:T("common:common.tools")}),E&&(0,en.jsx)(eH.A,{value:"hubs",children:T("common:common.hubs")}),(0,en.jsx)(eH.A,{value:"customUrl",children:T("common:common.customURL")})]})})]}),"projects"===e.ctaLinkType&&(0,en.jsx)(V.A,{label:T("editor:editor.selectProject"),children:(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(R,"-selectProject"),data:e,options:f,optionLabel:"name",optionValue:"id",fetch:D,meta:j,query:b,updateQuery:N,updateFilter:z,reset:H,onSelect:function(e){return es(e,t)}})}),"tools"===e.ctaLinkType&&(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(V.A,{label:T("editor:editor.selectProject"),children:(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(R,"-selectProjectTools"),data:e,options:f,optionLabel:"name",optionValue:"id",fetch:D,meta:j,query:b,updateQuery:N,updateFilter:z,reset:H,onSelect:function(e){return ei(e,t)}})}),(0,en.jsx)(V.A,{label:T("editor:editor.selectTool"),children:(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(R,"-selectTool"),options:v,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,value:null!=(a=v.find(function(t){return t.id===e.toolId}
1))?a:null,onChange:function(e,n){n&&er(n.id,t)},disabled:!v.length||o,renderInput:function(e){return(0,en.jsx)(eR.A,oc(oc({},e),{},{placeholder:T("editor:editor.selectTool"),size:"medium",variant:"outlined"}))}})})]}),"hubs"===e.ctaLinkType&&E&&(0,en.jsx)(V.A,{label:T("editor:editor.selectHub"),children:(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(R,"-selectHub"),options:y,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,isOptionEqualToValue:function(e,t){return(null==e?void 0:e.id)===(null==t?void 0:t.id)},value:null!=(s=y.find(function(t){return t.id===e.hubId}))?s:null,onChange:function(e,n){n&&ea(n.id,t)},disabled:!y.length||i,renderInput:function(e){return(0,en.jsx)(eR.A,oc(oc({},e),{},{placeholder:T("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}})}),"customUrl"===e.ctaLinkType&&(0,en.jsx)(V.A,{sx:{mb:0},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(R,"-customUrl"),name:"ctaCustomTextUrl",value:e.permalink,placeholder:"https://",onChange:function(e){P("permalink",e.target.value,w,t)}})}),(0,en.jsx)(V.A,{sx:{mt:1.25},label:(0,en.jsx)(ee.A,{tooltip:T("editor:editor.projectImageTooltip"),placement:"top",children:T("editor:editor.images.projectImage")}),children:(0,en.jsx)(ne,{afterUpdate:function(e){return P("image",e,w,t)},currentImage:e.image,sectionId:w,tabKey:t,title:T("editor:editor.images.projectImage"),imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY,isProject:J})}),(0,en.jsx)(V.A,{label:T("common:common.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(R,"-title"),name:"title",value:e.title,onChange:function(e){return P("title",e.target.value,w,t)}})}),(0,en.jsx)(V.A,{label:T("common:common.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(R,"-description"),name:"description",value:(0,or.A)(e.description),onChange:function(e){return P("description",e.target.value,w,t)}})}),(0,en.jsx)(V.A,{children:(0,en.jsx)(nR.A,{sx:{mb:0},label:T("editor:editor.openInNewTab"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(R,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return P("openInNewTab",e,w,t)}})})}),(0,en.jsx)(V.A,{extra:1===n.length?T("editor:editor.helpTexts.needAtleastOneProject"):void 0,children:(0,en.jsx)(Z.A,{variant:"contained",color:"error",onClick:function(){0===t?K(String(n[t+1].id)):K(String(n[t-1].id)),et(!0),r(w,t)},disabled:1===n.length,"data-testid":"".concat(R,"-deleteProject"),children:T("editor:editor.deleteProject")})})]},e.id):null})]})]})});let ou=(0,l.withTranslation)(["common"])(od),om=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,tools:e.tools.tools,selectedProject:e.project.project,projectTags:e.projectTags.tags,fetchingTools:e.tools.fetching,fetchingHubs:e.hubs.fetching,hubs:e.hubs.hubs,isHubEnabled:e.features.features.hasOwnProperty("self_service_hubs")&&e.features.features.self_service_hubs.enabled,isHubAdminEnabled:e.features.features.hasOwnProperty("hub_admin")&&e.features.features.hub_admin.enabled,dataTestId:"admin-ae-he-sections-projects-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,fetchProject:t8.Sw,fetchTools:on.W,fetchHubs:nN.R5,resetTools:on.L,updateProject:t8.vr,updateProjectQuery:nK.oR,updateProjectFilter:nK.vm,fetchProjects:nK.O$,resetProjects:nK.r$,reorderHomepageItems:ea.UN},e)})(ou);var oh={styles:(0,en.jsx)(s(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"},op=(oh.className,oh.styles),ox=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroun
1dColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),op]})});let og=(0,l.withTranslation)(["common","editor"])(ox),of=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-projects-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(og);var ob=n(96757),oj=n(23587),ov=n(13685),oy=n(98943),oA=n(21171),ow=n(27917),oC=n(64790),oT=n(42436),ok=n(65824),oS=n(7648),oI=n(38364);let oP=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:ob},{id:"two",imageUrl:oj},{id:"three",imageUrl:ov},{id:"four",imageUrl:oy},{id:"five",imageUrl:oA},{id:"six",imageUrl:ow},{id:"seven",imageUrl:oC},{id:"eight",imageUrl:oT},{id:"nine",imageUrl:ok},{id:"ten",imageUrl:oS},{id:"eleven",imageUrl:oI}],sectionId:t})}),oO=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(oP),oN=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:om,colorTabPane:of,layoutTabPane:oO,sectionId:t,hidden:n})});function oz(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function oD(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?oz(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oz(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var oH={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},oF=oH.className,oR=oH.styles,oE=(0,c.memo)(function(e){var t,n,o=e.data,i=e.fetchTools,r=e.fetchingTools,a=e.fetchingHubs,s=e.meta,l=(e.project,e.projects),u=e.projectsQuery,h=e.projectsMeta,g=e.resetTools,f=e.sectionId,b=e.t,j=e.tools,v=e.hubs,y=e.fetchHubs,A=e.updateProject,w=e.isHubAdminEnabled,C=e.isHubEnabled,T=e.updateSectionMeta,k=e.updateSectionData,S=e.updateProjectQuery,I=e.updateProjectFilter,P=e.fetchProjects,O=e.resetProjects,N=e.dataTestId,z=(0,c.useState)(!1),D=z[0],H=z[1],F=w&&C;(0,c.useEffect)(function(){C&&w&&y()},[C,w,y]),(0,c.useEffect)(function(){"tool"!==s.contentType||D||(A("id",o.projectId),i(),H(!0))},[j]);var R=function(e){T("contentType",e,f),k("image","",f),k("title","",f),k("description","",f),k("id","",f),k("ctaLink","",f),k("ctaLinkName","",f),k("status","",f),k("hubId","",f),k("projectId","",f),"project"===e?k("ctaText",b("editor:editor.viewProject"),f):k("ctaText",b("editor:editor.viewTool"),f),g()},E=function(e){A("permalink",e.permalink),A("id",e.id),k("projectId",e.id,f),k("image",e.imageUrl,f),k("ctaLink","/".concat(e.permalink),f),k("ctaLinkName",e.name,f),i()},U=function(e){var t=nD()(j,function(t){return t.id===e});t&&(k("title",t.name,f),k("description",t.description,f),k("id",t.id,f),k("ctaLink","SurveyTool"===t.type?t.path.replace("survey_tools","surveys"):t.path,f),k("status",t.state,f))},B=function(e){var t=nD()(v,function(t){return t.id===e});k("hubId",t.id,f),k("ctaLink",t.permalink,f),k("title",t.name,f),k("description",t.description,f),k("image",t.imageUrl,f)},L=function(e){k("image",e.imageUrl,f),k("title",e.name,f),k("description",e.description,f),k("ctaLink","/".concat(e.permalink),f),k("ctaLinkName",e.name,f),k("id",e.id,f),k("status",e.state,f)},_=null!=(t=j.find(function(e){return e.id===o.id}))?t:null;return(0,en.jsxs)("div",{className:"".concat(oF," items"),children:[(0,en.jsx)(V.A,{label:b("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-sectionTitle"),name:"title",value:s.title,onChange:function(e){return T("title",e.target.value,f)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:2,sx:{alignItems:"center",justifyContent:"space-between"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:10},children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(N,"-showProjectStatus"),sx:{display:"block",cursor:"default"},title:b("editor:editor.showProjectStatus"),children:b("editor:editor.showProjectStatus")})}),(0,en.jsx)(d.A,{size:{xs:12,md:2},sx:{display:"flex",justifyContent:"flex-end"},children:(0,en.jsx)(X.A,{id:"".concat(N,"-showProjectStatus"),"data-testid":"".concat(N,"-showProjectStatus"),name:"showCardStatus",checked:s.showCardStatus,onChange:function(e){return T("showCardStatus",e,f)},inputProps:{"aria-label":b("editor:editor.showProjectStatus")}})})]})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:2,sx:{alignItems:"center",justifyContent:"space-between"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:10},children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(N,"-showCtabutton"),sx:{display:"block",cursor:"default"},title:b("editor:editor.showCtabutton"),children:b("editor:editor.showCtabutton")})}),(0,en.jsx)(d.A,{size:{xs:12,md:2},sx:{display:"flex",justifyContent:"flex-end"},children:(0,en.jsx)(X.A,{id:"".concat(N,"-showCtabutton"),"data-testid":"".concat(N,"-showCtabutton"),name:"showCtabutton",checked:s.showCtabutton,onChange:function(e){return T("showCtabutton",e,f)},inputProps:{"aria-label":b("editor:editor.showCtabutton")}})})]})}),(0,en.jsx)(V.A,{label:b("editor:editor.selectContentType"),children:(0,en.jsxs)(x.A,{exclusive:!0,value:s.contentType,onCh
1ange:function(e,t){null!=t&&R(t)},size:"medium",className:"testId-".concat(N,"-selectContentType"),children:[(0,en.jsx)(p.A,{value:"project","data-testid":"".concat(N,"-project"),children:b("editor:editor.project")}),(0,en.jsx)(p.A,{value:"tool","data-testid":"".concat(N,"-tool"),children:b("editor:editor.tool")}),F&&(0,en.jsx)(p.A,{value:"hubs","data-testid":"".concat(N,"-hub"),children:b("common:common.hub")})]})}),(0,en.jsxs)(V.A,{label:b("editor:editor.selectContent"),children:["tool"===s.contentType&&(0,en.jsxs)(m.A,{sx:{display:"flex",flexDirection:"column",gap:1.5,width:"100%"},children:[(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(N,"-selectProjectTool"),data:o,options:l,optionLabel:"name",optionValue:"id",fetch:P,meta:h,query:u,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return E(e)}},"with-tool"),(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(N,"-selectTool"),options:j,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,value:_,onChange:function(e,t){t&&U(t.id)},disabled:!j.length||r,renderInput:function(e){return(0,en.jsx)(eR.A,oD(oD({},e),{},{placeholder:b("editor:editor.selectTool"),size:"medium",variant:"outlined"}))}})]}),"hubs"===s.contentType&&F&&(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(N,"-selectHub"),options:v,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,value:null!=(n=v.find(function(e){return e.id===o.hubId}))?n:null,onChange:function(e,t){t&&B(t.id)},disabled:!v.length||a,renderInput:function(e){return(0,en.jsx)(eR.A,oD(oD({},e),{},{placeholder:b("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}}),"project"===s.contentType&&(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(N,"-selectProject"),data:o,options:l,optionLabel:"name",optionValue:"id",fetch:P,meta:h,query:u,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return L(e)}},"without-tool")]}),(0,en.jsx)(V.A,{label:"project"===s.contentType?(0,en.jsx)(ee.A,{tooltip:b("editor:editor.images.projectImageHelp"),placement:"top",children:b("editor:editor.images.projectImage")}):b("editor:editor.images.image"),children:(0,en.jsx)(ne,{afterUpdate:function(e){return k("image",e,f)},currentImage:o.image,sectionId:f,title:b("editor:editor.images.projectImage"),imgFocusEnabled:o.imgFocusEnabled,imgFocusX:o.imgFocalX,imgFocusY:o.imgFocalY})}),(0,en.jsx)(V.A,{label:b("common:common.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-title"),name:"title",value:o.title,onChange:function(e){return k("title",e.target.value,f)}})}),(0,en.jsx)(V.A,{label:b("common:common.description"),children:(0,en.jsx)(nE.A,{name:"description",value:o.description,onChange:function(e){return k("description",e.target.value,f)},config:(0,nU.J)("HomePageFeatured"),dataTestId:"froala-editor-home-featured-description"})}),(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:b("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:b("editor:editor.ctaText")}),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-ctaText"),name:"ctaText",value:o.ctaText,onChange:function(e){return k("ctaText",e.target.value,f)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:b("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:b("editor:editor.ctaLink")}),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(N,"-ctaLink"),name:"ctaLink",value:o.ctaLink,onChange:function(e){return k("ctaLink",e.target.value,f)}})})})]}),oR]})});let oU=(0,l.withTranslation)(["common"])(oE),oB=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],meta:e.homePageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,project:e.project.project,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,tools:e.tools.tools,fetchingTools:e.tools.fetching,fetchingHubs:e.hubs.fetching,hub
1s:e.hubs.hubs,isHubEnabled:e.features.features.hasOwnProperty("self_service_hubs")&&e.features.features.self_service_hubs.enabled,isHubAdminEnabled:e.features.features.hasOwnProperty("hub_admin")&&e.features.features.hub_admin.enabled,dataTestId:"admin-ae-he-sections-featured-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,updateProjectQuery:nK.oR,updateProjectFilter:nK.vm,fetchProjects:nK.O$,resetProjects:nK.r$,fetchTools:on.W,fetchHubs:nN.R5,resetTools:on.L,updateProject:t8.vr},e)})(oU);var oL={styles:(0,en.jsx)(s(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"},o_=(oL.className,oL.styles),oW=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),o_]})});let oM=(0,l.withTranslation)(["common","editor"])(oW),oK=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-featured-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(oM);var oY=n(18905),oV=n(89671),oq=n(2649);let oQ=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:oY},{id:"two",imageUrl:oV},{id:"three",imageUrl:oq}],sectionId:t})}),oZ=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(oQ),oG=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:oB,colorTabPane:oK,layoutTabPane:oZ,sectionId:t,hidden:n})});var oX=(0,c.memo)(function(e){var t,n,o=e.data,i=e.t,r=e.sectionId,a=e.updateSectionData,s=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:i("editor:editor.images.bannerImage"),children:(0,en.jsx)(ne,{afterUpdate:function(e){return a("image",e,r)},currentImage:o.image,sectionId:r,title:i("editor:editor.images.bannerImage"),imgFocusEnabled:o.imgFocusEnabled,imgFocusX:o.imgFocalX,imgFocusY:o.imgFocalY})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:(0,en.jsx)(et.A,{html:i("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":i("common:common.images.imageAltText"),children:i("common:common.images.imageAltText")}),extra:(null==o||null==(t=o.altText)?void 0:t.length)===125?i("common:common.maxCharactersReached"):void 0,children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-imageAltText"),name:"registerBannerAltText",value:o.altText,onChange:function(e){return a("altText",e.target.value,r)},slotProps:{htmlInput:{maxLength:125}},error:(null==o||null==(n=o.altText)?void 0:n.length)===125})}),(0,en.jsx)(V.A,{label:i("editor:editor.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-title"),name:"title",value:o.title,onChange:function(e){return a("title",e.target.value,r)}})}),(0,en.jsx)(V.A,{label:i("editor:editor.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-description"),name:"description",value:o.description,onChange:function(e){return a("description",e.target.value,r)}})}),(0,en.jsxs)(V.A,{label:i("editor:editor.buttonText"),children:[(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(s,"-ctaText"),name:"ctaText",value:o.ctaText,onChange:function(e){return a("ctaText",e.target.value,r)}}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,mb:1.5,children:i("editor:editor.registerBannerButtonDescription")})]})]})});let o$=(0,l.withTranslation)(["common","editor"])(oX),oJ=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-register-widget-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(o$);var o0={styles:(0,en.jsx)(s(),{id:"1759500438",children:[".color-preview-container.jsx-1759500438{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-1759500438{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-1759500438:hover{cursor:pointer;}",".style-title.jsx-1759500438{margin-right:5px;display:inline-block;margin-top:5px;}",".slider-value.jsx-1759500438{margin-right:10px;float:right;margin-top:5px;}",".color-description.jsx-1759500438{color:#8c8c8c;margin:0px;font-size:12px;line-height:20px;margin-bottom:12px;}"]}),className:"jsx-1759500438"}
1,o1=o0.className,o2=o0.styles,o3=(0,c.memo)(function(e){var t=e.t,n=e.sectionId,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,n)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:t("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:t("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,n)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,n)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,n)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,n)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,n)},"data-testid":"".concat(r,"-backgroundColor")})}),(0,en.jsxs)("div",{children:[(0,en.jsxs)("div",{children:[(0,en.jsx)(q.A,{className:"".concat(o1," style-title"),children:t("editor:editor.backgroundColourOpacity")}),(0,en.jsxs)("span",{className:"".concat(o1," slider-value"),children:[o.bannerOpacity,"%"]})]}),(0,en.jsx)(eF.Ay,{className:"testId-".concat(r,"-backgroundColourOpacity"),value:o.bannerOpacity,max:100,min:80,onChange:function(e,t){return i("bannerOpacity",t,n)}})]}),o2]})});let o5=(0,l.withTranslation)(["common","editor"])(o3),o4=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-register-widget-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(o5),o9=(0,l.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.titleFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(V.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(nV.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,en.jsx)(nV.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),o6=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-register-widget-font"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(o9);var o8=n(11227),o7=n(74385),ie=n(71999);let it=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:o8},{id:"two",imageUrl:o7},{id:"three",imageUrl:ie}],sectionId:t})}),io=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(it),ii=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:oJ,colorTabPane:o4,fontTabPane:o6,layoutTabPane:io,sectionId:t,hidden:n})});function ir(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function ia(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?ir(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ir(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var is={styles:(0,en.jsx)(s(),{id:"3375603841",children:[".items.jsx-3375603841{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".style-title.jsx-3375603841{margin-right:5px;display:inline-block;margin-top:20px;}",".slider-value.jsx-3375603841{margin-right:10px;float:right;margin-top:20px;}",".button-url-row.jsx-3375603841{margin-bottom:20px;}"]}),className:"jsx-3375603841"},ic=is.className,il=is.styles,id=(0,c.memo)(function(e){var t,n,o,i,r=e.addSectionData,a=e.data,s=e.deleteSectionData,l=e.meta,u=e.sectionId,p=e.t,x=e.theme,g=e.hubs,f=e.projects,b=e.projectsQuery,j=e.projectsMeta,v=e.isHubEnabled,y=e.isHubAdminEnabled,A=e.fetchHubs,w=e.fetchingHubs,C=e.updateSectionMeta,T=e.updateSectionData,k=e.updateSectionTheme,S=e.updateProjectQuery,I=e.updateProjectFilter,P=e.fetchProjects,O=e.resetProjects,N=e.reorderHomepageItems,z=e.dataTestId,H=y&&v,F=a&&a[0]&&a[0].id||0,R=(0,c.useState)(String(F)),E=R[0],U=R[1],B=(0,c.useState)(),L=B[0],_=B[1];(0,oa.A)(u,N,a.length),(0,c.useEffect)(function(){H&&A()},[H,A]);var W=function(e,t){switch(T("ctaLinkType",e,u,t),e){case"signInPage":T("ctaLink","/login",u,t);break;case"registerPage":T("ctaLink","/register",u,t);break;case"projects":case"customUrl":case"hubs":T("ctaLink","",u,t)}},M=function(e,t){var n=nD()(g,function(t){return t.id===e});T("hubId",n.id,u,t),T("ctaLink",n.permalink,u,t),T("title",n.name,u,t),T("description",n.description,u,t),T("image",n.imageUrl,u,t)},Y=function(e,t){T("ctaLink","/".concat(e.permalink),u,t),T("ctaLinkName",e.name,u,t)};return(0,en.jsxs)("div",{className:"".concat(ic," items"),children:[(0,en.jsx)(V.A,{label:p("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-sectionTitle"),name:"title",value:null!=(t=l.title)?t:"",onChange:function(e){return C("title",e.target.value,u)}})}),(0,en.jsxs)("div",{children:[(0,en.jsxs)("div",{children:[(0,en.jsx)(q.A,{className:"".concat(ic," style-title"),children:p("editor:editor.sliderSpeed")}),(0,en.jsxs)("span",{className:"".concat(ic," slider-value"),children:[(x.autoplaySpeed||7e3)/1e3," ",p("editor:editor.seconds")]})]}),(0,en.jsx)(eF.Ay,{className:"testId-".concat(z,"-sliderSpeed"),value:(x.autoplaySpeed||7e3)/1e3,max:10,min:2,onChange:function(e,t){return k("autoplaySpeed",1e3*t,u)}})]}),(0,en.jsx)(V.A,{label:p("editor:editor.heightOfSlide"),children:(0,en.jsx)(eR.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-heightOfSlide"),value:null!=(n=x.minHeight)?n:"",slotProps:{htmlInput:{min:400,max:800,step:50}},onChange:function(e){var t=e.target.value;if(""===t)return void k("minHeight",void 0,u);var n=Number(t);Number.isNaN(n)||k("minHeight",n,u)},onBlur:function(e){var t=e.target.value;if(""!==t){var n=Number(t);if(Number.isNaN(n))return void k("minHeight",void 0,u);var o=Math.min(800,Math.max(400,n));o!==x.minHeight&&k("minHeight",o,u)}}})}),(0,en.jsxs)(K.A,{direction:"row",spacing:1.25,sx:{mb:2,alignItems:"flex-end"},children:[(0,en.jsx)(V.A,{label:p("editor:editor.helpTexts.titleTruncate"),sx:{flex:1,minWidth:0,mb:0},children:(0,en.jsx)(eR.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-titleTruncate"),value:null!=(o=x.titleLength)?o:"",slotProps:{htmlInput:{min:0,step:10}},onChange:function(e){return k("titleLength",""===e.target.value?void 0:Number(e.target.value),u)},onBlur:function(e){""===e.target.value&&k("titleLength",50,u)}})}),(0,en.jsx)(V.A,{label:p("editor:editor.helpTexts.descriptionTruncate"),sx:{flex:1,minWidth:0,mb:0},children:(0,en.jsx)(eR.A,{type:"number",size:"medium",variant:"outlined",className:"testId-".concat(z,"-descriptionTruncate"),value:null!=(i=x.descriptionLength)?i:"",slotProps:{htmlInput:{min:0,step:10}
1},onChange:function(e){return k("descriptionLength",""===e.target.value?void 0:Number(e.target.value),u)},onBlur:function(e){""===e.target.value&&k("descriptionLength",90,u)}})})]}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,mb:3,children:p("editor:editor.helpTexts.truncate")}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(u),value:E,onChange:function(e,t){return U(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:a&&a.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(z,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(p("editor:editor.slide")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(D.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:p("editor:editor.addNewSlide"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(z,"-addNewSlide"),variant:"text",onClick:function(){var e=crypto.getRandomValues(new Uint32Array(1))[0]%1e4;r(u,e),U(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),a&&a.map(function(e,t){var n,o,i;return String(e.id)===E?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{label:p("editor:editor.images.sliderImage"),children:(0,en.jsx)(ne,{afterUpdate:function(e){return T("image",e,u,t)},currentImage:e.image,sectionId:u,tabKey:t,title:p("editor:editor.images.sliderImage"),imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY,deleteKey:L})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:(0,en.jsx)(et.A,{html:p("common:common.images.imageAltTextHelp")}),placement:"top","aria-label":p("common:common.images.imageAltText"),children:p("common:common.images.imageAltText")}),extra:(null==e||null==(n=e.altText)?void 0:n.length)===125?p("common:common.maxCharactersReached"):void 0,children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-imageAltText"),name:"sliderAltText",value:e.altText,onChange:function(e){return T("altText",e.target.value,u,t)},slotProps:{htmlInput:{maxLength:125}},error:(null==e||null==(o=e.altText)?void 0:o.length)===125})}),(0,en.jsx)(V.A,{label:p("common:common.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-title"),name:"title",value:e.title,onChange:function(e){return T("title",e.target.value,u,t)}})}),(0,en.jsx)(V.A,{label:p("common:common.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-description"),name:"description",value:e.description,onChange:function(e){return T("description",e.target.value,u,t)}})}),(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:p("editor:editor.helpTexts.buttonEmptyCTAText"),placement:"right",children:p("editor:editor.ctaText")}),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-ctaText"),name:"ctaText",value:e.ctaText,onChange:function(e){return T("ctaText",e.target.value,u,t)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:p("editor:editor.helpTexts.buttonEmptyCtaLink"),placement:"right",children:p("editor:editor.ctaLink")}),children:(0,en.jsxs)(eR.A,{select:!0,fullWidth:!0,size:"medium",variant:"outlined",className:"testId-".concat(z,"-ctaLink"),value:e.ctaLinkType,onChange:function(e){return W(e.target.value,t)},slotProps:{select:{displayEmpty:!0}},children:[(0,en.jsx)(eH.A,{value:"signInPage",children:p("common:common.signInPage")}),(0,en.jsx)(eH.A,{value:"registerPage",children:p("common:common.registerPage")}),(0,en.jsx)(eH.A,{value:"projects",children:p("common:common.projects")}),H&&(0,en.jsx)(eH.A,{value:"hubs",children:p("common:common.hubs")}),(0,en.jsx)(eH.A,{value:"customUrl",children:p("common:common.customURL")})]})})})]}),"projects"===e.ctaLinkType&&(0,en.jsx)(V.A,{label:p("editor:editor.selectProject"),children:(0,en.jsx)(nB.A,{size:"medium",className:"testId-".concat(z,"-selectProject"),data:e,options:f,optionLabel:"name",optionValue:"permalink",fetch:P,meta:j,query:b,updateQuery:S,updateFilter:I,reset:O,onSelect:function(e){return Y(e,t)}})}),"hubs"===e.ctaLinkType&&H&&(0,en.jsx)(V.A,{label:p("editor:editor.selectHub"),children:(0,en.jsx)(nH.A,{size:"medium",className:"testId-".concat(z,"-selectHub"),options:g,getOptionLabel:function(e){return e.name},sx:nF.OP,slotProps:nF.HE,renderOption:nF.$S,value:null!=(i=g.find(function(t){return t.id===e.hubId}
1))?i:null,onChange:function(e,n){n&&M(n.id,t)},disabled:!g.length||w,renderInput:function(e){return(0,en.jsx)(eR.A,ia(ia({},e),{},{placeholder:p("editor:editor.selectHub"),size:"medium",variant:"outlined"}))}})}),"customUrl"===e.ctaLinkType&&(0,en.jsx)(d.A,{container:!0,spacing:3,className:"".concat(ic," button-url-row"),children:(0,en.jsx)(d.A,{size:{xs:12,md:12},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(z,"-customUrl"),name:"ctaCustomTextUrl",value:e.ctaLink,onChange:function(e){T("ctaLink",e.target.value,u,t)}})})}),(0,en.jsx)(V.A,{children:(0,en.jsx)(nR.A,{sx:{mb:0},label:p("editor:editor.openInNewTab"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(z,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return T("openInNewTab",e,u,t)}})})}),(0,en.jsx)(V.A,{extra:1===a.length?p("editor:editor.helpTexts.needAtleastOneSlide"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(z,"-deleteSlide"),variant:"contained",color:"error",onClick:function(){0===t?(U(String(a[t+1].id)),_()):(U(String(a[t-1].id)),_(t)),s(u,t)},disabled:1===a.length,children:p("editor:editor.deleteSlide")})})]},e.id):null}),il]})});let iu=(0,l.withTranslation)(["common","editor"])(id),im=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,theme:e.homePageRevision.revision.sections[t.sectionId].theme,projects:e.projects.projects,projectsQuery:e.projects.query,projectsMeta:e.projects.meta,fetchingHubs:e.hubs.fetching,hubs:e.hubs.hubs,isHubEnabled:e.features.features.hasOwnProperty("self_service_hubs")&&e.features.features.self_service_hubs.enabled,isHubAdminEnabled:e.features.features.hasOwnProperty("hub_admin")&&e.features.features.hub_admin.enabled,dataTestId:"admin-ae-he-sections-slider-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,updateSectionTheme:ea.oz,updateProjectQuery:nK.oR,updateProjectFilter:nK.vm,fetchProjects:nK.O$,resetProjects:nK.r$,fetchHubs:nN.R5,reorderHomepageItems:ea.UN},e)})(iu);var ih={styles:(0,en.jsx)(s(),{id:"541989964",children:[".color-preview-container.jsx-541989964{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-541989964{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-541989964:hover{cursor:pointer;}",".style-title.jsx-541989964{margin-right:5px;display:inline-block;margin-top:5px;}",".slider-value.jsx-541989964{margin-right:10px;float:right;margin-top:5px;}"]}),className:"jsx-541989964"},ip=ih.className,ix=ih.styles,ig=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}
1),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),(0,en.jsxs)("div",{children:[(0,en.jsxs)("div",{children:[(0,en.jsx)(q.A,{className:"".concat(ip," style-title"),children:n("editor:editor.backgroundColourOpacity")}),(0,en.jsxs)("span",{className:"".concat(ip," slider-value"),children:[o.cardOpacity,"%"]})]}),(0,en.jsx)(eF.Ay,{className:"testId-".concat(r,"-backgroundColourOpacity"),value:o.cardOpacity,max:100,min:80,onChange:function(e,n){return i("cardOpacity",n,t)}})]}),ix]})});let ib=(0,l.withTranslation)(["common","editor"])(ig),ij=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-slider-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(ib),iv=(0,l.withTranslation)(["editor"])(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.titleFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-titleFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.titleFontWeight),onChange:function(e){return i("titleFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(V.A,{label:n("editor:editor.descriptionFontWeight"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-descriptionFontWeight"),sx:{width:105},size:"medium",variant:"outlined",value:(0,nG.f)(o.descriptionFontWeight),onChange:function(e){return i("descriptionFontWeight",Number(e.target.value),t)},children:[(0,en.jsx)(eH.A,{value:100,children:n("editor:editor.fonts.light")}),(0,en.jsx)(eH.A,{value:400,children:n("editor:editor.fonts.normal")}),(0,en.jsx)(eH.A,{value:700,children:n("editor:editor.fonts.bold")})]})}),(0,en.jsx)(nV.A,{label:n("editor:editor.titleFontSize"),value:16*o.titleFontSize,min:10,max:32,onChange:function(e){return i("titleFontSize",e/16,t)},className:"testId-".concat(r,"-titleFontSize"),sx:{mb:2}}),(0,en.jsx)(nV.A,{label:n("editor:editor.descriptionFontSize"),value:16*o.descriptionFontSize,min:10,max:24,onChange:function(e){return i("descriptionFontSize",e/16,t)},className:"testId-".concat(r,"-descriptionFontSize")})]})}),iy=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-slider-font"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(iv);var iA=n(38597),iw=n(13939),iC=n(30341);let iT=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:iA},{id:"two",imageUrl:iw},{id:"three",imageUrl:iC}],sectionId:t})}),ik=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(iT),iS=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:im,colorTabPane:ij,fontTabPane:iy,layoutTabPane:ik,sectionId:t,hidden:n})});var iI=n(31810),iP={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},iO=iP.className,iN=iP.styles,iz=(0,c.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,l=e.updateSectionData,u=e.reorderHomepageItems,p=e.dataTestId,x=(0,c.useState)(String(n[0].id)),g=x[0],f=x[1];return(0,oa.A)(r,u,n.length),(0,en.jsxs)("div",{className:"".concat(iO," items"),children:[(0,en.jsx)(V.A,{label:a("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(r),value:g,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(p,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(a("editor:editor.member")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(iI.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:a("editor:editor.addNewMember"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-addNewMember"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===g?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{label:a("editor:editor.images.profilePhoto"),children:(0,en.jsx)(ne,{afterUpdate:function(e){return l("image",e,r,t)},currentImage:e.image,sectionId:r,tabKey:t,title:a("editor:editor.images.profilePhoto"),imgixUrl:!0,imgFocusEnabled:e.imgFocusEnabled,imgFocusX:e.imgFocalX,imgFocusY:e.imgFocalY})}),(0,en.jsx)(V.A,{label:a("common:common.name"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-name"),name:"name",value:e.name,onChange:function(e){return l("name",e.target.value,r,t)}})}),(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.occupation"),sx:{mb:0,width:"100%"},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-occupation"),name:"occupation",value:e.occupation,onChange:function(e){return l("occupation",e.target.value,r,t)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.company"),sx:{mb:0,width:"100%"},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-company"),name:"company",value:e.company,onChange:function(e){return l("company",e.target.value,r,t)}})})})]}),(0,en.jsx)(V.A,{label:a("editor:editor.email"),sx:{mt:1.5},children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-email"),name:"email",value:e.email,onChange:function(e){return l("email",e.target.value,r,t)}})}),(0,en.jsx)(V.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneMember"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-deleteMember"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteMember")})})]},e.id):null}),iN]})});let iD=(0,l.withTranslation)(["common","editor"])(iz),iH=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-ae-he-sections-whos-listening-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,reorderHomepageItems:ea.UN},e)})(iD);var iF=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let iR=(0,l.withTranslation)(["common","editor"])(iF),iE=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-whos-listening-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(iR);var iU=n(89580),iB=n(91846),iL=n(99508),i_=n(21564);let iW=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:iU},{id:"two",imageUrl:iB},{id:"three",imageUrl:iL},{id:"four",imageUrl:i_}],sectionId:t})}),iM=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(iW),iK=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:iH,colorTabPane:iE,layoutTabPane:iM,sectionId:t,hidden:n})});var iY=n(34586),iV=n(67412),iq=n(79712),iQ=n(99612),iZ=n(95980),iG=n(4
16504),iX=n(56887),i$=n(18597),iJ=n(94674),i0=n(21670),i1=n(97330),i2=n(10203),i3=n(19247),i5=n(87996),i4=n(96963),i9=n(68697),i6=n(59934),i8=n(92706),i7=n(42205),re=n(97014),rt=n(32653),rn=n(55188),ro={styles:(0,en.jsx)(s(),{id:"998109262",children:[".image-wrapper.jsx-998109262{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;}",".image.jsx-998109262{width:80px;height:80px;background-color:#fff;margin-bottom:24px;border:1px solid #e8e8e8;border-radius:4px;padding:12px;margin-right:12px;}",".image.jsx-998109262:hover{cursor:pointer;border-color:#0e4b70;box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".content.jsx-998109262{overflow-y:scroll;padding:0 24px;min-height:calc(100vh - 60px);}",".upload-container.jsx-998109262{height:calc(100vh - 110px);display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".preview-container.jsx-998109262{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".preview-image.jsx-998109262{height:32px;width:32px;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;background-color:#fafafa;padding:8px 0;border-radius:4px;margin-right:12px;background-size:contain;background-repeat:no-repeat;}",".preview-image.jsx-998109262:hover{cursor:pointer;}"]}),className:"jsx-998109262"},ri=ro.className,rr=ro.styles,ra=[iY,iV,iq,iQ,iZ,iG,iX,i$,iJ,i0,i1,i2,i3,i5,i4,i9,i6,i8,i7,re,rt,rn],rs=(0,c.memo)(function(e){var t,n,o=e.t,i=e.uploadFile,r=e.afterUpdate,a=e.imageUrl,s=e.uploading,l=e.uploadError,d=e.currentImage,u=e.dataTestId,h=(0,c.useState)(!1),p=h[0],x=h[1],g=(0,c.useState)("icons"),f=g[0],b=g[1],j=(0,c.useRef)(null),v=(0,c.useRef)(!1);return(0,c.useEffect)(function(){if(v.current&&!s){if(l){v.current=!1;return}a&&(v.current=!1,r(a),x(!1))}},[s,l,a,r]),(0,en.jsxs)(c.Fragment,{children:[(0,en.jsxs)("div",{className:"".concat(ri," preview-container"),children:[(0,en.jsx)("div",{className:"".concat(ri," preview-image"),"data-testid":"".concat(u,"-editImage"),style:{backgroundImage:"url(".concat(d,")")},onClick:function(){return x(!0)},role:"button"}),(0,en.jsx)(Z.A,{"data-testid":"".concat(u,"-update"),variant:"contained",color:"primary",size:"small",sx:{px:1.25,py:.25,minHeight:32,flexShrink:0,whiteSpace:"nowrap"},onClick:function(){return x(!0)},children:o("editor:editor.update")})]}),(0,en.jsxs)(tk.A,{open:p,onClose:function(){return x(!1)},title:o("editor:editor.icons"),width:"80vw",slotProps:{root:{keepMounted:!1}},contentSx:{p:0,flex:1,bgcolor:"rgb(235, 236, 239)",overflow:"hidden"},children:[(0,en.jsx)(m.A,{sx:{borderBottom:1,borderColor:"divider",bgcolor:"#fff",px:2},children:(0,en.jsxs)(tt.A,{value:f,onChange:function(e,t){return b(t)},children:[(0,en.jsx)(te.A,{value:"icons",label:(0,en.jsx)("div",{"data-testid":"".concat(u,"-icons"),children:o("editor:editor.icons")})}),(0,en.jsx)(te.A,{value:"upload",label:(0,en.jsx)("div",{"data-testid":"".concat(u,"-upload"),children:o("common:common.upload")})})]})}),(0,en.jsx)("div",{className:"".concat(ri," content"),children:"icons"===f?(0,en.jsx)("div",{className:"".concat(ri," image-wrapper"),children:ra.map(function(e,t){return(0,en.jsx)("img",{"data-testid":"".concat(u,"-").concat(t),role:"button",alt:"",className:"".concat(ri," image"),src:e,onClick:function(){r(e),x(!1)}},t)})}):(t=(0,L.A)(W().mark(function e(t){var n;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.target.files&&t.target.files[0]){e.next=3;break}return e.abrupt("return");case 3:return v.current=!0,e.next=6,i(n);case 6:t.target.value="";case 7:case"end":return e.stop()}},e)})),n=function(e){return t.apply(this,arguments)},(0,en.jsxs)(m.A,{sx:{position:"relative"},className:"".concat(ri," upload-container"),"data-testid":"".concat(u,"-clickOrDragToUpload"),children:[(0,en.jsx)("input",{ref:j,type:"file",name:"file",accept:"image/*",style:{display:"none"},onChange:n}),s?(0,en.jsx)(M.A,{}):(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)($.A,{sx:{fontSize:48,color:"text.secondary",mb:1}}),(0,en.jsx)(tT.A,{color:"text.secondary",children:o("editor:editor.clickOrDragToUpload")}),(0,en.jsx)(Z.A,{variant:"outlined",sx:{mt:2},onClick:function(){return j.current&&j.current.click()},children:o("common:common.upload")})]})]}))})]}),rr]})});let rc=(0,l.withTranslation)(["common","editor"])(rs),rl=(0,o.Ng)(function(e){return{uploading:e.homePageRevision.uploadingFile,uploadError:e.homePageRevision.fileUploadError,imageUrl:e.homePageRevision.uploadedFileUrl,dataTestId:"admin-ae-he-drawers-icon-manager"}},function(e){return(0,i.zH)({uploadFile:ea.QM},e)})(rc);var rd={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},ru=rd.className,rm=rd.styles,rh=(0,c.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,l=e.updateSectionData,u=e.reorderHomepageItems,p=e.dataTestId,x=(0,c.useState)(String(n[0].id)),g=x[0],f=x[1];return(0,oa.A)(r,u,n.length),(0,en.jsxs)("div",{className:"".concat(ru," items"),children:[(0,en.jsx)(V.A,{label:a("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(rl,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(r),value:g,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(p,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(a("editor:editor.link")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(nb.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:a("editor:editor.addNewLink"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-addNewLink"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===g?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("common:common.name"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-name"),name:"name",value:e.name,onChange:function(e){return l("name",e.target.value,r,t)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.url"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-url"),name:"url",value:e.url,onChange:function(e){return l("url",e.target.value,r,t)}})})})]}),(0,en.jsx)(V.A,{children:(0,en.jsx)(nR.A,{sx:{mb:0},label:a("editor:editor.openInNewTab"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(p,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return l("openInNewTab",e,r,t)}})})}),(0,en.jsx)(V.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-deleteLink"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteLink")})})]},e.id):null}),rm]})});let rp=(0,l.withTranslation)(["common","editor"])(rh),rx=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-ae-he-sections-important-links-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,reorderHomepageItems:ea.UN},e)})(rp);var rg=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rf=(0,l.withTranslation)(["common","editor"])(rg),rb=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-important-links-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(rf);var rj=n(13453),rv=n(40523);let ry=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:rj},{id:"two",imageUrl:rv}],sectionId:t})}),rA=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(ry),rw=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:rx,colorTabPane:rb,layoutTabPane:rA,sectionId:t,hidden:n})});var rC=n(99768),rT=n(23876),rk=n(46741),rS={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},rI=rS.className,rP=rS.styles,rO=(0,c.memo)(function(e){var t=e.addSectionData,n=e.deleteSectionData,o=e.data,i=e.meta,r=e.sectionId,a=e.t,l=e.updateSectionData,u=e.updateSectionMeta,g=e.reorderHomepageItems,f=e.lang,b=e.dataTestId,j=(0,c.useState)(String(o[0].id)),v=j[0],y=j[1];return(0,oa.A)(r,g,o.length),(0,en.jsxs)("div",{"data-testid":"homepage-editor-keydates-section-content",className:"jsx-1881360264 "+"".concat(rI," items"),children:[(0,en.jsx)(V.A,{label:a("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(b,"-sectionTitle"),name:"title",value:i.title,onChange:function(e){return u("title",e.target.value,r)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(rl,{afterUpdate:function(e){return u("icon",e,r)},currentImage:i.icon})})]})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(r),value:v,onCh
1ange:function(e,t){return y(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:o.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(b,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(a("editor:editor.date")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(rk.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:a("editor:editor.addNewDate"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(b,"-addNewDate"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),y(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),o.map(function(e,t){return String(e.id)===v?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{label:a("editor:editor.eventType"),children:(0,en.jsxs)(x.A,{exclusive:!0,className:"testId-".concat(b,"-eventType"),value:e.multiDayEvent?"true":"false",onChange:function(e,n){null!=n&&l("multiDayEvent","false"!==n,r,t)},size:"medium",children:[(0,en.jsx)(p.A,{value:"false","data-testid":"".concat(b,"-singleDay"),children:a("editor:editor.singleDay")}),(0,en.jsx)(p.A,{value:"true","data-testid":"".concat(b,"-multiDay"),children:a("editor:editor.multiDay")})]})}),(0,en.jsx)(d.A,{container:!0,spacing:3,children:e.multiDayEvent?(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.startDate"),children:(0,en.jsx)(rC.A,{className:"testId-".concat(b,"-startDate"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.startDate,altFormat:"fr-CA"===f?"j F Y":"F j, Y",dateFormat:"fr-CA"===f?"j F Y":"F j, Y",locale:"fr-CA"===f?rT.French:""},onChange:function(e,n){return l("startDate",n,r,t)},value:e.startDate},"fr-CA"===f?rT.French:"")})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.endDate"),children:(0,en.jsx)(rC.A,{className:"testId-".concat(b,"-endDate"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.endDate,altFormat:"fr-CA"===f?"j F Y":"F j, Y",dateFormat:"fr-CA"===f?"j F Y":"F j, Y",locale:"fr-CA"===f?rT.French:""},onChange:function(e,n){return l("endDate",n,r,t)},value:e.endDate},"fr-CA"===f?rT.French:"")})})]}):(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.startDate"),children:(0,en.jsx)(rC.A,{className:"testId-".concat(b,"-startDateSingle"),options:{altInput:!0,altInputClass:"hpe-flatpickr-alt-input",mode:"single",defaultDate:e.startDate,altFormat:"fr-CA"===f?"j F Y":"F j, Y",dateFormat:"fr-CA"===f?"j F Y":"F j, Y",locale:"fr-CA"===f?rT.French:""},onChange:function(e,n){return l("startDate",n,r,t)},value:e.startDate},"fr-CA"===f?rT.French:"")})})}),(0,en.jsx)(V.A,{label:a("common:common.name"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(b,"-name"),name:"name",value:e.name,onChange:function(e){return l("name",e.target.value,r,t)}})}),(0,en.jsx)(V.A,{label:a("common:common.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(b,"-description"),name:"description",value:e.description,onChange:function(e){return l("description",e.target.value,r,t)}})}),(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.linkText"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(b,"-linkText"),name:"linkText",value:e.linkText,onChange:function(e){return l("linkText",e.target.value,r,t)}})})}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:a("editor:editor.linkUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(b,"-linkUrl"),name:"linkUrl",value:e.linkUrl,onChange:function(e){return l("linkUrl",e.target.value,r,t)}})})})]}),(0,en.jsx)(V.A,{children:(0,en.jsx)(nR.A,{sx:{mb:0},label:a("editor:editor.openInNewTab"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(b,"-openInNewTab"),name:"openInNewTab",checked:e.openInNewTab,onChange:function(e){return l("openInNewTab",e,r,t)}})})}),(0,en.jsx)(V.A,{extra:1===o.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(b,"-deleteDate"),variant:"contained",color:"error",onClick:function(){0===t?y(String(o[t+1].id)):y(String(o[t-1].id)),n(r,t)},disabled:1===o.length,children:a("editor:editor.deleteDate")})})]},e.id):null}),(0,en.jsx)(s(),{id:"1881360264",children:[".hpe-flatpickr-alt-input{box-sizing:border-box;width:100%;min-height:40px;padding:8px 14px;border:1px solid rgba(0,0,0,0.23);border-radius:4px;font:inherit;background:#fff;}",".hpe-flatpickr-alt-input:hover{border-color:rgba(0,0,0,0.87);}",".hpe-flatpickr-alt-input:focus{border-color:#1976d2;outline:0;box-shadow:0 0 0 1px #1976d2;}"]}),rP]})});let rN=(0,l.withTranslation)(["common","editor"])(rO),rz=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,theme:e.homePageRevision.revision.sections[t.sectionId].theme,lang:e.currentSite.site.locale,dataTestId:"admin-ae-he-sections-key-dates-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,reorderHomepageItems:ea.UN},e)})(rN);var rD=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}
1),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rH=(0,l.withTranslation)(["common","editor"])(rD),rF=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-key-dates-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(rH);var rR=n(10326),rE=n(3016),rU=n(11770);let rB=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:rR},{id:"two",imageUrl:rE},{id:"three",imageUrl:rU}],sectionId:t})}),rL=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(rB),r_=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:rz,colorTabPane:rF,layoutTabPane:rL,sectionId:t,hidden:n})});var rW={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},rM=rW.className,rK=rW.styles,rY=(0,c.memo)(function(e){var t,n=e.addSectionData,o=e.data,i=e.deleteSectionData,r=e.meta,a=e.sectionId,s=e.t,l=e.updateSectionMeta,u=e.updateSectionData,g=e.uploadFile,f=e.uploadingFile,b=e.uploadedFileUrl,j=e.reorderHomepageItems,v=e.dataTestId,y=(0,c.useState)(String(o[0].id)),A=y[0],w=y[1],C=(0,c.useRef)(null),T=(0,c.useRef)(null),k=(0,c.useRef)(null),S=(0,c.useRef)(!1);(0,oa.A)(a,j,o.length),(0,c.useEffect)(function(){if(f){S.current=!0;return}if(null!=T.current&&S.current&&b){S.current=!1;var e=T.current;T.current=null,u("url",b,a,e),k.current&&(u("name",k.current,a,e),k.current=null)}},[f,b,a,u]);var I=function(e){T.current=e,C.current&&C.current.click()},P=(t=(0,L.A)(W().mark(function e(t){var n;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.target.files&&t.target.files[0]){e.next=4;break}return T.current=null,e.abrupt("return");case 4:return k.current=n.name,e.next=7,g(n);case 7:t.target.value="";case 8:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)});return(0,en.jsxs)("div",{className:"".concat(rM," items"),children:[(0,en.jsx)("input",{ref:C,type:"file",style:{display:"none"},onChange:P}),(0,en.jsx)(V.A,{label:s("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(v,"-sectionTitle"),name:"title",value:r.title,onChange:function(e){return l("title",e.target.value,a)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:s("editor:editor.images.icon")}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(rl,{afterUpdate:function(e){return l("icon",e,a)},currentImage:r.icon})})]})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(a),value:A,onChange:function(e,t){return w(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:o.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(v,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(s("editor:editor.document")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(tY.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:s("editor:editor.addNewDocument"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(v,"-addNewDocument"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());n(a,e),w(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),o.map(function(e,t){return String(e.id)===A?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{children:(0,en.jsxs)(x.A,{exclusive:!0,value:e.isUploaded?"true":"false",onChange:function(e,n){
1null!=n&&u("isUploaded","false"!==n,a,t)},size:"medium",children:[(0,en.jsx)(p.A,{value:"true",className:"testId-".concat(v,"-uploadDocument"),children:s("editor:editor.uploadDocument")}),(0,en.jsx)(p.A,{value:"false",className:"testId-".concat(v,"-linkDocument"),children:s("editor:editor.linkDocument")})]})}),(0,en.jsx)(d.A,{container:!0,spacing:3,children:e.isUploaded?(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(V.A,{label:s("editor:editor.chooseDocument"),children:(0,en.jsx)(Z.A,{className:"testId-".concat(v,"-chooseDocument"),variant:"contained",color:"primary",sx:{whiteSpace:"nowrap"},disabled:f,onClick:function(){return I(t)},startIcon:f?(0,en.jsx)(M.A,{size:18,color:"inherit"}):(0,en.jsx)($.A,{}),children:e.url?s("editor:editor.changeDocument"):s("editor:editor.chooseDocument")})})}):(0,en.jsx)(d.A,{size:{xs:12,md:12},children:(0,en.jsx)(V.A,{label:s("editor:editor.urlOfExternalDocument"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(v,"-urlOfExternalDocument"),name:"url",value:e.url,onChange:function(e){return u("url",e.target.value,a,t)}})})})}),(0,en.jsx)(V.A,{label:s("common:common.name"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(v,"-name"),name:"name",value:e.name,onChange:function(e){return u("name",e.target.value,a,t)}})}),(0,en.jsx)(V.A,{extra:1===o.length?s("editor:editor.helpTexts.needAtleastOneDocument"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(v,"-deleteDocument"),variant:"contained",color:"error",onClick:function(){0===t?w(String(o[t+1].id)):w(String(o[t-1].id)),i(a,t)},disabled:1===o.length,children:s("editor:editor.deleteDocument")})})]},e.id):null}),rK]})});let rV=(0,l.withTranslation)(["common","editor"])(rY),rq=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,uploadingFile:e.homePageRevision.uploadingFile,uploadedFileUrl:e.homePageRevision.uploadedFileUrl,dataTestId:"admin-ae-he-sections-documents-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,uploadFile:ea.QM,reorderHomepageItems:ea.UN},e)})(rV);var rQ=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let rZ=(0,l.withTranslation)(["common","editor"])(rQ),rG=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-documents-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(rZ);var rX=n(68617),r$=n(82999),rJ=n(82089);let r0=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:rX},{id:"two",imageUrl:r$},{id:"three",imageUrl:rJ}],sectionId:t})}),r1=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(r0),r2=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:rq,colorTabPane:rG,layoutTabPane:r1,sectionId:t,hidden:n})});var r3=n(62446),r5={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},r4=r5.className,r9=r5.styles,r6=(0,c.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,l=e.updateSectionData,u=e.reorderHomepageItems,p=e.dataTestId,x=(0,c.useState)(String(n[0].id)),g=x[0],f=x[1];return(0,oa.A)(r,u,n.length),(0,en.jsxs)("div",{className:"".concat(r4," items"),children:[(0,en.jsx)(V.A,{label:a("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(rl,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(r),value:g,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(p,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(a("editor:editor.stage")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{dis
1play:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(r3.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:a("editor:editor.addNewStage"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-addNewStage"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===g?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{label:a("editor:editor.setCurrentStage"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-setCurrentStage"),variant:"contained",color:"primary",onClick:function(){return s("currentStage",t,r)},disabled:i.currentStage===t,children:a("editor:editor.setCurrentStage")})}),(0,en.jsx)(V.A,{label:a("common:common.name"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-name"),name:"name",value:e.name,onChange:function(e){return l("name",e.target.value,r,t)}})}),(0,en.jsx)(V.A,{label:a("common:common.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-description"),name:"description",value:e.description,onChange:function(e){return l("description",e.target.value,r,t)}})}),(0,en.jsx)(V.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneStage"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-deleteStage"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteStage")})})]},e.id):null}),r9]})});let r8=(0,l.withTranslation)(["common","editor"])(r6),r7=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-ae-he-sections-life-cycle-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,reorderHomepageItems:ea.UN},e)})(r8);var ae=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let at=(0,l.withTranslation)(["common","editor"])(ae),an=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-life-cycle-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(at);var ao=n(26404),ai=n(5454);let ar=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:ao},{id:"two",imageUrl:ai}],sectionId:t})}),aa=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(ar),as=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:r7,colorTabPane:an,layoutTabPane:aa,sectionId:t,hidden:n})});
1var ac=n(87046),al={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},ad=al.className,au=al.styles,am=(0,c.memo)(function(e){var t=e.addSectionData,n=e.data,o=e.deleteSectionData,i=e.meta,r=e.sectionId,a=e.t,s=e.updateSectionMeta,l=e.updateSectionData,u=e.reorderHomepageItems,p=e.dataTestId,x=(0,c.useState)(String(n[0].id)),g=x[0],f=x[1];return(0,oa.A)(r,u,n.length),(0,en.jsxs)("div",{className:"".concat(ad," items"),children:[(0,en.jsx)(V.A,{label:a("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-sectionTitle"),name:"title",defaultValue:i.title,onChange:function(e){return s("title",e.target.value,r)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[(0,en.jsx)(d.A,{size:{xs:12,md:6},children:a("editor:editor.images.icon")}),(0,en.jsx)(d.A,{size:{xs:12,md:6},children:(0,en.jsx)(rl,{afterUpdate:function(e){return s("icon",e,r)},currentImage:i.icon})})]})}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1,borderBottom:1,borderColor:"divider"},children:[(0,en.jsx)(tt.A,{className:"home-page-tabs-".concat(r),value:g,onChange:function(e,t){return f(t)},variant:"scrollable",scrollButtons:"auto",sx:{flex:1,minWidth:0},children:n.map(function(e,t){return(0,en.jsx)(te.A,{value:String(e.id),"data-id":String(t),"data-testid":"".concat(p,"-").concat(e.id),label:(0,en.jsx)(h.A,{title:"".concat(a("editor:editor.question")," ").concat(t+1),children:(0,en.jsxs)(m.A,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[(0,en.jsx)(ac.A,{sx:{fontSize:18}}),t+1]})}),sx:{minHeight:48}},e.id)})}),(0,en.jsx)(h.A,{title:a("editor:editor.addNewFAQ"),children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-addNewFAQ"),variant:"text",onClick:function(){var e=Math.floor(1e4*Math.random());t(r,e),f(String(e))},children:(0,en.jsx)(oo.A,{sx:{fontSize:20}})})})]}),n.map(function(e,t){return String(e.id)===g?(0,en.jsxs)(m.A,{sx:{pt:2},children:[(0,en.jsx)(V.A,{label:a("editor:editor.question"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(p,"-question"),name:"question",value:e.question,onChange:function(e){return l("question",e.target.value,r,t)}})}),(0,en.jsx)(V.A,{label:a("editor:editor.answer"),children:(0,en.jsx)(nE.A,{name:"answer",value:e.answer,onChange:function(e){return l("answer",e.target.value,r,t)},config:(0,nU.J)("HomePageFaq"),dataTestId:"froala-editor-home-faq-answer-".concat(r,"-").concat(t)})}),(0,en.jsx)(V.A,{extra:1===n.length?a("editor:editor.helpTexts.needAtleastOneLink"):void 0,children:(0,en.jsx)(Z.A,{"data-testid":"".concat(p,"-deleteLink"),variant:"contained",color:"error",onClick:function(){0===t?f(String(n[t+1].id)):f(String(n[t-1].id)),o(r,t)},disabled:1===n.length,children:a("editor:editor.deleteLink")})})]},e.id):null}),au]})});let ah=(0,l.withTranslation)(["common","editor"])(am),ap=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,dataTestId:"admin-ae-he-sections-faq-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,reorderHomepageItems:ea.UN},e)})(ah);var ax=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}
1),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let ag=(0,l.withTranslation)(["common","editor"])(ax),af=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-faq-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(ag);var ab=n(82379),aj=n(64801);let av=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:ab},{id:"two",imageUrl:aj}],sectionId:t})}),ay=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(av),aA=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:ap,colorTabPane:af,layoutTabPane:ay,sectionId:t,hidden:n})});var aw={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},aC=aw.className,aT=aw.styles,ak=(0,c.memo)(function(e){var t=e.data,n=e.sectionId,o=e.t,i=e.updateSectionData,r=e.dataTestId;return(0,en.jsxs)("div",{className:"".concat(aC," items"),children:[(0,en.jsx)(V.A,{label:o("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",defaultValue:t.title,onChange:function(e){return i("title",e.target.value,n)}})}),(0,en.jsx)(V.A,{label:o("editor:editor.content"),children:(0,en.jsx)(nE.A,{name:"content",value:t.content,onChange:function(e){var o=e.target.value;(null==t?void 0:t.content)!==o&&i("content",o,n)},config:(0,nU.J)("HomePageCustom"),dataTestId:"froala-editor-home-custom-content"})}),aT]})});let aS=(0,l.withTranslation)(["editor"])(ak),aI=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-free-style-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(aS);var aP=(0,c.memo)(function(e){var t=e.t,n=e.sectionId,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,n)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,n)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,n)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let aO=(0,l.withTranslation)(["common","editor"])(aP),aN=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-free-style-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(aO),az=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:aI,colorTabPane:aN,sectionId:t,hidden:n})});var aD=(0,c.memo)(function(e){var t=e.t,n=e.updateSectionData,o=(e.logoUrl,e.data),i=e.sectionId,r=(e.updateSite,e.saveSite,e.dataTestId),a=o.facebookUrl,s=o.twitterUrl,l=o.googleUrl,d=o.instagramUrl,u=o.linkedinUrl,m=o.youtubeUrl;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.facebookUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-facebookUrl"),name:"facebookUrl",value:a,onChange:function(e){return n("facebookUrl",e.target.value,i)}})}),(0,en.jsx)(V.A,{label:t("editor:editor.twitterUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-twitterUrl"),name:"twitterUrl",value:s,onChange:function(e){return n("twitterUrl",e.target.value,i)}})}),(0,en.jsx)(V.A,{label:t("editor:editor.googleUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-googleUrl"),name:"googleUrl",value:l,onCh
1ange:function(e){return n("googleUrl",e.target.value,i)}})}),(0,en.jsx)(V.A,{label:t("editor:editor.instagramUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-instagramUrl"),name:"instagramUrl",value:d,onChange:function(e){return n("instagramUrl",e.target.value,i)}})}),(0,en.jsx)(V.A,{label:t("editor:editor.linkedinUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-linkedinUrl"),name:"linkedinUrl",value:u,onChange:function(e){return n("linkedinUrl",e.target.value,i)}})}),(0,en.jsx)(V.A,{label:t("editor:editor.youtubeUrl"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-youtubeUrl"),name:"youtubeUrl",value:m,onChange:function(e){return n("youtubeUrl",e.target.value,i)}})})]})});let aH=(0,l.withTranslation)(["common","editor"])(aD),aF=(0,o.Ng)(function(e,t){return{logoUrl:e.currentSite.site.logoUrl,data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-footer-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,updateSite:er.hj,saveSite:er.X8},e)})(aH);var aR=(0,c.memo)(function(e){var t=e.t,n=e.updateSectionTheme,o=e.backgroundColor,i=(e.ctaBackgroundColor,e.ctaTextColor,e.textColor),r=e.sectionId,a=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:t("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:i,fieldKey:"textColor",onChange:function(e){return n("textColor",e,r)},"data-testid":"".concat(a,"-textColor")})}),(0,en.jsx)(V.A,{label:t("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o,fieldKey:"backgroundColor",onChange:function(e){return n("backgroundColor",e,r)},"data-testid":"".concat(a,"-backgroundColor")})})]})});let aE=(0,l.withTranslation)(["common","editor"])(aR),aU=(0,o.Ng)(function(e,t){return{backgroundColor:e.homePageRevision.revision.sections[t.sectionId].theme.backgroundColor,textColor:e.homePageRevision.revision.sections[t.sectionId].theme.textColor,dataTestId:"admin-ae-he-sections-footer-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(aE),aB=(0,l.withTranslation)(["editor"])(function(e){var t=e.t;return(0,en.jsx)(en.Fragment,{children:(0,en.jsxs)(V.A,{children:[(0,en.jsx)(eU.A,{label:t("editor:editor.navigationLinks"),sx:{mt:2}}),(0,en.jsx)(Y.A,{sx:{mb:2.5},children:t("editor:editor.footerLinksDescription")}),(0,en.jsx)(nu,{content:"footer"})]})})}),aL=(0,o.Ng)(function(){return{}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:aF,colorTabPane:aU,linksTabPane:aB,sectionId:t,hidden:n,canBeHidden:!1,canBeDeleted:!1})});var a_={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},aW=a_.className,aM=a_.styles,aK=(0,c.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,en.jsxs)("div",{className:"".concat(aW," items"),children:[(0,en.jsx)(V.A,{label:n("editor:editor.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})}),aM]})});let aY=(0,l.withTranslation)(["common"])(aK),aV=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-title-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(aY);var aq=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let aQ=(0,l.withTranslation)(["common","editor"])(aq),aZ=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-title-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(aQ);var aG=n(41657),aX=n(71847);let a$=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:aG},{id:"two",imageUrl:aX}],sectionId:t})}),aJ=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(a$),a0=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:aV,colorTabPane:aZ,layoutTabPane:aJ,sectionId:t,hidden:n})});var a1=(0,c.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,en.jsx)(m.A,{sx:{display:"flex",flexDirection:"column"},children:(0,en.jsxs)(V.A,{label:n("editor:editor.content"),children:[(0,en.jsx)(Q.A,{multiline:!0,minRows:14,maxRows:14,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-html"),name:"html",value:t.html,onChange:function(e){return i(e.target.name,e.target.value,o)}}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,children:n("editor:editor.htmlHelperText")})]})})});let a2=(0,l.withTranslation)(["common"])(a1),a3=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-html-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(a2);var a5=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let a4=(0,l.withTranslation)(["common","editor"])(a5),a9=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-html-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(a4);var a6=n(41048);let a8=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:a6}],sectionId:t})}),a7=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(a8),se=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:a3,colorTabPane:a9,layoutTabPane:a7,sectionId:t,hidden:n})});var st={styles:(0,en.jsx)(s(),{id:"33924820",children:[".items.jsx-33924820{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),className:"jsx-33924820"},sn=st.className,so=st.styles,si=(0,c.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,en.jsxs)("div",{className:"".concat(sn," items"),children:[(0,en.jsx)(V.A,{label:n("editor:editor.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-title"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})}),(0,en.jsx)(V.A,{label:n("editor:editor.description"),children:(0,en.jsx)(eR.A,{multiline:!0,minRows:3,maxRows:6,size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-description"),name:"description",value:t.description,onChange:function(e){return i("description",e.target.value,o)}})}),so]})});let sr=(0,l.withTranslation)(["common"])(si),sa=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-title-with-description-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(sr);var ss=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.sectionDescriptionColor"),children:(0,en.jsx)(eg.A,{color:o.sectionDescriptionColor,fieldKey:"sectionDescriptionColor",onChange:function(e){return i("sectionDescriptionColor",e,t)},"data-testid":"".concat(r,"-sectionDescriptionColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let sc=(0,l.withTranslation)(["common","editor"])(ss),sl=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-title-with-description-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(sc);var sd=n(33893);let su=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:sd}],sectionId:t})}),sm=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(su),sh=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:sa,colorTabPane:sl,layoutTabPane:sm,sectionId:t,hidden:n})});var sp=(0,c.memo)(function(e){var t=e.data,n=e.t,o=e.sectionId,i=e.updateSectionData,r=e.dataTestId;return(0,en.jsxs)(m.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,en.jsx)(V.A,{label:n("editor:editor.selectVideoType"),children:(0,en.jsxs)(eR.A,{select:!0,className:"testId-".concat(r,"-selectVideoType"),size:"medium",fullWidth:!0,variant:"outlined",value:t.type,onCh
1ange:function(e){return i("type",e.target.value,o)},children:[(0,en.jsx)(eH.A,{value:"Youtube",children:n("editor:editor.youtube")}),(0,en.jsx)(eH.A,{value:"Vimeo",children:n("editor:editor.vimeo")})]})}),(0,en.jsxs)(V.A,{label:n("editor:editor.url"),children:[(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-url"),name:"url",value:t.url,onChange:function(e){return i("url",e.target.value,o)}}),(0,en.jsx)(ee.A,{textVariant:"body2",mt:.5,children:n("editor:editor.youtubeHelpText")})]}),(0,en.jsx)(V.A,{label:n("editor:editor.title"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-title"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,o)}})})]})});let sx=(0,l.withTranslation)(["common","editor"])(sp),sg=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data[0],dataTestId:"admin-ae-he-sections-video-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ},e)})(sx);var sf=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})})]})});let sb=(0,l.withTranslation)(["common","editor"])(sf),sj=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-video-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(sb);var sv=n(11134);let sy=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:sv}],sectionId:t})}),sA=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(sy),sw=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:sg,colorTabPane:sj,layoutTabPane:sA,sectionId:t,hidden:n})});var sC=n(3513);function sT(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var sk=(0,c.memo)(function(e){e.data;var t=e.meta,n=e.sectionId,o=e.t,i=e.updateSectionMeta,r=e.dataTestId,a=(0,c.useState)(!1),s=a[0],l=a[1];return(0,en.jsxs)(m.A,{sx:{display:"flex",flexDirection:"column"},children:[(0,en.jsx)(V.A,{label:o("editor:editor.sectionTitle"),children:(0,en.jsx)(Q.A,{size:"medium",fullWidth:!0,variant:"outlined","data-testid":"".concat(r,"-sectionTitle"),name:"title",value:t.title,onChange:function(e){return i("title",e.target.value,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showSearch"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showSearch"),name:"showSearch",checked:t.showSearch,onChange:function(e){return i("showSearch",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showTagsFilter"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showTagsFilter"),name:"showTagsFilter",checked:t.showTagsFilter,onChange:function(e){return i("showTagsFilter",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showYearFilter"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showYearFilter"),name:"showYearFilter",checked:t.showYearFilter,onChange:function(e){return i("showYearFilter",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showStateFilter"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showStateFilter"),name:"showStateFilter",checked:t.showStateFilter,onChange:function(e){return i("showStateFilter",e,n)}})}),!s&&(0,en.jsx)(V.A,{children:(0,en.jsx)(sC.A,{component:"button",type:"button",onClick:function(){return l(!0)},"data-testid":"".concat(r,"-showMoreOptions"),sx:{cursor:"pointer"},children:o("editor:editor.showMoreOptions")})}),s&&(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(nR.A,{label:o("editor:editor.showResetFilterButton"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showResetFilterButton"),name:"showResetFilterButton",checked:t.showResetFilterButton,onChange:function(e){return i("showResetFilterButton",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showProjectName"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showProjectName"),name:"showProjectName",checked:t.showProjectName,onChange:function(e){return i("showProjectName",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showProjectDescription"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showProjectDescription"),name:"showProjectDescription",checked:t.showProjectDescription,onChange:function(e){return i("showProjectDescription",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.showProjectStatus"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-showProjectStatus"),name:"showProjectStatus",checked:t.showProjectStatus,onChange:function(e){return i("showProjectStatus",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.displayViewProjectButton"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-displayViewProjectButton"),name:"showViewProjectButton",checked:t.showViewProjectButton,onChange:function(e){return i("showViewProjectButton",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.displayPublishDate"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-displayPublishDate"),name:"showProjectTimestamp",checked:t.showProjectTimestamp,onChange:function(e){return i("showProjectTimestamp",e,n)}})}),(0,en.jsx)(nR.A,{label:o("editor:editor.projectPaginationView"),control:(0,en.jsx)(X.A,{"data-testid":"".concat(r,"-projectPaginationView"),name:"projectPaginationView",checked:t.projectPaginationView,onChange:function(e){return i("projectPaginationView",e,n)}})}),(0,en.jsx)(V.A,{children:(0,en.jsxs)(d.A,{container:!0,spacing:2,sx:{justifyContent:"space-between",alignItems:"center"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:8},children:(0,en.jsx)(m.A,{component:"label",htmlFor:"".concat(r,"-projectsPerPage"),sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?sT(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sT(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({display:"block",color:"text.primary"},eE.m),children:o("editor:editor.projectsPerPage")})}),(0,en.jsx)(d.A,{size:{xs:12,md:4},children:(0,en.jsx)(eR.A,{id:"".concat(r,"-projectsPerPage"),type:"number",size:"medium",fullWidth:!0,variant:"outlined",className:"testId-".concat(r,"-projectsPerPage"),disabled:!t.projectPaginationView,value:t.projectsPerPage,slotProps:{htmlInput:{id:"".concat(r,"-projectsPerPage"),min:1}},onChange:function(e){return i("projectsPerPage",Number(e.target.value),n)}})})]})})]})]})});let sS=(0,l.withTranslation)(["common"])(sk),sI=(0,o.Ng)(function(e,t){return{data:e.homePageRevision.revision.sections[t.sectionId].data,meta:e.homePageRevision.revision.sections[t.sectionId].meta,projects:e.projects.projects,selectedProject:e.project.project,projectTags:e.projectTags.tags,dataTestId:"admin-ae-he-sections-project-showcase-text"}},function(e){return(0,i.zH)({updateSectionData:ea.pZ,updateSectionMeta:ea.YS,addSectionData:ea.ZD,deleteSectionData:ea.bL,fetchProject:t8.Sw,reorderHomepageItems:ea.UN},e)})(sS);var sP={styles:(0,en.jsx)(s(),{id:"2985745862",children:[".color-preview-container.jsx-2985745862{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:5px;}",".color-preview.jsx-2985745862{width:32px;height:32px;border-radius:4px;margin-right:12px;border:1px solid #d9d9d9;}",".color-preview.jsx-2985745862:hover{cursor:pointer;}"]}),className:"jsx-2985745862"},sO=(sP.className,sP.styles),sN=(0,c.memo)(function(e){var t=e.sectionId,n=e.t,o=e.theme,i=e.updateSectionTheme,r=e.dataTestId;return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(V.A,{label:n("editor:editor.sectionTitleColor"),children:(0,en.jsx)(eg.A,{color:o.sectionTitleColor,fieldKey:"sectionTitleColor",onChange:function(e){return i("sectionTitleColor",e,t)},"data-testid":"".concat(r,"-sectionTitleColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.textColor"),children:(0,en.jsx)(eg.A,{color:o.textColor,fieldKey:"textColor",onChange:function(e){return i("textColor",e,t)},"data-testid":"".concat(r,"-textColor")})}),(0,en.jsx)(V.A,{label:(0,en.jsx)(ee.A,{tooltip:n("editor:editor.helpTexts.ctaBackgroundColor"),placement:"right",children:n("editor:editor.ctaBackgroundColor")}),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundColor,fieldKey:"ctaBackgroundColor",onChange:function(e){return i("ctaBackgroundColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaBackgroundHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaBackgroundHoverColor,fieldKey:"ctaBackgroundHoverColor",onChange:function(e){return i("ctaBackgroundHoverColor",e,t)},"data-testid":"".concat(r,"-ctaBackgroundHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextColor,fieldKey:"ctaTextColor",onChange:function(e){return i("ctaTextColor",e,t)},"data-testid":"".concat(r,"-ctaTextColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.ctaTextHoverColor"),children:(0,en.jsx)(eg.A,{color:o.ctaTextHoverColor,fieldKey:"ctaTextHoverColor",onChange:function(e){return i("ctaTextHoverColor",e,t)},"data-testid":"".concat(r,"-ctaTextHoverColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.cardBackgroundColor"),children:(0,en.jsx)(eg.A,{color:o.cardBackgroundColor,fieldKey:"cardBackgroundColor",onChange:function(e){return i("cardBackgroundColor",e,t)},"data-testid":"".concat(r,"-cardBackgroundColor")})}),(0,en.jsx)(V.A,{label:n("editor:editor.backgroundColor"),children:(0,en.jsx)(eg.A,{color:o.backgroundColor,fieldKey:"backgroundColor",onChange:function(e){return i("backgroundColor",e,t)},"data-testid":"".concat(r,"-backgroundColor")})}),sO]})});let sz=(0,l.withTranslation)(["common","editor"])(sN),sD=(0,o.Ng)(function(e,t){return{theme:e.homePageRevision.revision.sections[t.sectionId].theme,dataTestId:"admin-ae-he-sections-project-showcase-color"}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(sz);var sH=n(81816),sF=n(88786);let sR=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.sectionId;return(0,en.jsx)(n7,{layouts:[{id:"one",imageUrl:sH},{id:"two",imageUrl:sF}],sectionId:t})}),sE=(0,o.Ng)(function(e,t){return{layout:e.homePageRevision.revision.sections[t.sectionId].theme.layout}},function(e){return(0,i.zH)({updateSectionTheme:ea.oz},e)})(sR),sU=(0,o.Ng)(function(e,t){return{hidden:e.homePageRevision.revision.sections[t.sectionId].meta.hidden}},function(e){return(0,i.zH)({updateSectionMeta:ea.YS,deleteSection:ea.tA},e)})(function(e){var t=e.sectionId,n=e.hidden;return(0,en.jsx)(nP,{textTabPane:sI,colorTabPane:sD,layoutTabPane:sE,sectionId:t,hidden:n})});function sB(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function sL(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?sB(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sB(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var s_={borderRadius:1,border:0,bgcolor:"background.paper","&::before":{display:"none"},"&:hover, &.Mui-expanded":{boxShadow:function(e){return e.shadows[2]}}},sW={fontSize:22,color:"action.active",display:"block",flexShrink:0};let sM=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.sections,o=e.currentSectionId,i=e.setCurrentSectionId,r=e.dataTestId,a=function(e){var t=document.getElementById("home-page-view-section-".concat(e));t&&t.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})},s=function(e,t){switch(e){case"custom":return(0,en.jsx)(az,{sectionId:t});case"whosListening":return(0,en.jsx)(iK,{sectionId:t});case"footer":return(0,en.jsx)(aL,{sectionId:t});case"carousel":return(0,en.jsx)(iS,{sectionId:t});case"navigation":return(0,en.jsx)(nO,{sectionId:t});case"banner":return(0,en.jsx)(ot,{sectionId:t});case"projects":default:return(0,en.jsx)(oN,{sectionId:t});case"projectFinder":return(0,en.jsx)(sU,{sectionId:t});case"featured":return(0,en.jsx)(oG,{sectionId:t});case"registerWidget":return(0,en.jsx)(ii,{sectionId:t});case"importantLinks":return(0,en.jsx)(rw,{sectionId:t});case"keyDates":return(0,en.jsx)(r_,{sectionId:t});case"documents":return(0,en.jsx)(r2,{sectionId:t});case"lifeCycle":return(0,en.jsx)(as,{sectionId:t});case"faq":return(0,en.jsx)(aA,{sectionId:t});case"title":return(0,en.jsx)(a0,{sectionId:t});case"titleWithDescription":return(0,en.jsx)(sh,{sectionId:t});case"video":return(0,en.jsx)(sw,{sectionId:t});case"html":return(0,en.jsx)(se,{sectionId:t})}},c=function(e){switch(e){case"custom":return(0,en.jsx)(tY.A,{sx:sW});case"whosListening":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/who-listen.svg",height:"20px",alt:""});case"footer":return(0,en.jsx)(tK.A,{sx:sW});case"carousel":default:return(0,en.jsx)(tR.A,{sx:sW});case"video":return(0,en.jsx)(t_.A,{sx:sW});case"navigation":return(0,en.jsx)(tE.A,{sx:sW});case"banner":return(0,en.jsx)(E.A,{sx:sW});case"projects":return(0,en.jsx)(tU.A,{sx:sW});case"projectFinder":return(0,en.jsx)(tV.A,{sx:sW});case"featured":return(0,en.jsx)(tB.A,{sx:sW});case"registerWidget":return(0,en.jsx)(tL.A,{sx:sW});case"title":return(0,en.jsx)(tW.A,{sx:sW});case"titleWithDescription":return(0,en.jsx)(tM.A,{sx:sW});case"importantLinks":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/links.svg",height:"20px",alt:""});case"html":return(0,en.jsx)(ex.A,{sx:sW});case"keyDates":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/key-dates.svg",height:"20px",alt:""});case"documents":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/documents.svg",height:"20px",alt:""});case"lifeCycle":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/lifecycle.svg",alt:""});case"faq":return(0,en.jsx)("img",{src:"/static/assets/images/widgets/faq.svg",height:"20px",alt:""})}};return(0,en.jsx)(en.Fragment,{children:n.map(function(e,n){var l=String(o)===String(n);return(0,en.jsx)(m.A,{sx:{mb:1.5},children:(0,en.jsxs)(el.A,{disableGutters:!0,elevation:0,square:!0,expanded:l,onChange:function(e,t){t?(a(n),i(n)):String(o)===String(n)&&i("")},slotProps:{transition:{unmountOnExit:!0}},className:"testId-".concat(r,"-").concat(e.meta.type,"--").concat(n),sx:s_,children:[(0,en.jsxs)(eu.A,{expandIcon:null,id:"home-page-editor-section-".concat(n,"-header"),"data-testid":"".concat(r,"-section-header-").concat(n),slotProps:{content:{sx:{alignItems:"center",gap:1,my:1,width:"100%",mr:0}}},sx:sL({bgcolor:"grey.100",px:1.5},l&&{borderBottom:1,borderColor:"divider"}),children:[(0,en.jsx)(m.A,{sx:{display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,minWidth:32},children:c(e.meta.type)}),(0,en.jsx)(tT.A,{component:"span",variant:"body1",color:"text.primary",sx:sL(sL({},eE.m),{},{flex:1,minWidth:0,textTransform:"capitalize"}),children:t("editor:editor.sectionTypes.".concat(e.meta.type,"Section"))}),e.meta.hidden?(0,en.jsx)(tq.A,{fontSize:"small",color:"action",sx:{flexShrink:0},"aria-label":t("editor:editor.hideThisSection")}):null]}),(0,en.jsx)(ed.A,{sx:{pt:2,px:0,pb:0,bgcolor:"common.white"},children:s(e.meta.type,n)})]})},n)})})}),sK=(0,o.Ng)(function(e){return{sections:e.homePageRevision.revision.sections,currentSectionId:e.homePageRevision.currentSectionId,dataTestId:"admin-ae-he-sections"}},function(e){return(0,i.zH)({setCurrentSectionId:ea.Qu},e)})(sM);var sY=n(16488),sV=n(86169),sq=n(78438),sQ=n(93490),sZ=n(19884),sG=n(78938);let sX=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.currentTemplateId,i=e.showTemplatesDrawer,r=e.dataTestId,a=[{id:"bondi",description:n("editor:editor.themes.bondi")},{id:"whitehaven",description:n("editor:editor.themes.whitehaven2")},{id:"cottesloe",description:n("editor:editor.themes.cottesloe")}
1,{id:"burleigh",description:n("editor:editor.themes.burleigh")},{id:"goldcoast",description:n("editor:editor.themes.goldCoast")},{id:"crestview",description:n("editor:editor.themes.crestview")}],s="torquay"===o?"goldcoast":o,c=nD()(a,function(e){return e.id===s});switch(c.id){case"bondi":default:t=sY;break;case"whitehaven":t=sV;break;case"cottesloe":t=sq;break;case"burleigh":t=sQ;break;case"goldcoast":t=sZ;break;case"crestview":t=sG}return(0,en.jsxs)(en.Fragment,{children:[(0,en.jsxs)(m.A,{sx:{width:"90%",mx:"5%",mt:1.25,mb:3,border:1,borderColor:"primary.main",borderRadius:1,position:"relative",overflow:"hidden","&:hover":{boxShadow:2,"& [data-template-preview-image]":{backgroundPosition:"bottom center",transition:"background-position 5s ease-in-out 0s"}}},children:[(0,en.jsx)(m.A,{"data-template-preview-image":!0,sx:{height:400,width:1,backgroundSize:"100% auto",backgroundRepeat:"no-repeat",backgroundPosition:"top center",transition:"background-position 0.5s ease-in-out 0s",backgroundImage:"url(".concat(t,")")}}),(0,en.jsx)(m.A,{sx:{mb:0,p:1.5,bgcolor:"common.white",textAlign:"center",mt:"-70px",width:1},children:(0,en.jsxs)(q.A,{sx:{fontWeight:"bold"},children:[n("editor:editor.currentTemplate")," - ",c.description]})})]}),(0,en.jsx)(m.A,{sx:{display:"flex",justifyContent:"center",mb:1.25},children:(0,en.jsx)(Z.A,{variant:"contained",color:"primary",onClick:function(){return i(!0)},"data-testid":"".concat(r,"-changeBtn"),children:n("editor:editor.changeTemplate")})}),(0,en.jsx)(m.A,{sx:{display:"flex",justifyContent:"center",mb:1.5},children:(0,en.jsx)(Y.A,{component:"div",sx:{textAlign:"center",lineHeight:1.43},children:(0,en.jsx)(ee.A,{textVariant:"body2",children:n("editor:editor.changeTemplateDescription")})})})]})}),s$=(0,o.Ng)(function(e){return{currentTemplateId:e.homePageRevision.revision.meta.templateId,dataTestId:"admin-ae-he-template"}},function(e){return(0,i.zH)({showTemplatesDrawer:ea.Es},e)})(sX);function sJ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var s0=[{key:"templates",titleKey:"editor:editor.templates",helpKey:"editor:editor.helpText.templates",icon:D.A,component:s$},{key:"sections",titleKey:"editor:editor.sections",helpKey:"editor:editor.helpText.sections",icon:tF.A,component:sK}];let s1=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.activeKey,o=e.changeHomePageSectionKey,i=e.dataTestId;return(0,en.jsx)(en.Fragment,{children:s0.map(function(e,r){var a,s=e.component,c=e.icon,l=n===e.key;return(0,en.jsx)(m.A,{sx:{mb:1.5,borderRadius:1,border:1,borderColor:"divider",bgcolor:"background.paper",overflow:"hidden",transition:function(e){return e.transitions.create(["box-shadow"],{duration:e.transitions.duration.short})},"&:hover":{boxShadow:function(e){return e.shadows[4]}}},children:(0,en.jsxs)(el.A,{disableGutters:!0,elevation:0,expanded:l,onChange:(a=e.key,function(e,t){t?o(a):n===a&&o("")}),slotProps:{transition:{unmountOnExit:!1}},sx:{bgcolor:"background.paper"},children:[(0,en.jsx)(eu.A,{expandIcon:null,"aria-controls":"home-page-editor-section-".concat(r),id:"home-page-editor-section-".concat(r,"-header"),"data-testid":"".concat(i,"-").concat(e.key),className:"hpe-panel ".concat(e.key," testId-").concat(i,"-").concat(e.key),slotProps:{content:{sx:{alignItems:"center",my:1}}},sx:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sJ(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sJ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({px:1.5,bgcolor:"grey.100"},l&&{borderBottom:1,borderColor:"divider"}),children:(0,en.jsxs)("div",{className:"hpe-section-header",children:[(0,en.jsx)("div",{className:"hpe-icon",children:(0,en.jsx)(c,{sx:{fontSize:"1em",width:"1em",height:"1em",color:"action.active"}})}),(0,en.jsx)("div",{children:(0,en.jsx)(B.A,{title:t(e.titleKey),description:t(e.helpKey)})})]})}),(0,en.jsx)(ed.A,{"data-testid":"".concat(i,"-").concat(e.key,"-hpe-section"),sx:{p:2,bgcolor:"common.white"},children:(0,en.jsx)(s,{})})]})},e.key)})})}),s2=(0,o.Ng)(function(e){return{activeKey:e.homePageRevision.activeHomePageKey,dataTestId:"admin-ae-homepage"}},function(e){return(0,i.zH)({changeHomePageSectionKey:ea.zi},e)})(s1);var s3=n(50225),s5=n(45911),s4=n(40553),s9=n(66035),s6={styles:(0,en.jsx)(s(),{id:"2474059597",children:[".container.jsx-2474059597{width:100%;margin-bottom:24px;border:1px solid #e8e8e8;border-radius:8px;position:relative;overflow:hidden;box-shadow:0px 0px 10px 0px rgba(0,0,0,0.25);}",".container.jsx-2474059597:hover{cursor:pointer;border-color:#0e4b70;box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".description.selected.jsx-2474059597{box-shadow:0 2px 8px rgba(0,0,0,0.09);}",".description.selected.jsx-2474059597::after{content:'✓';position:absolute;right:10px;top:8px;color:#fff;background-color:#2e7d32;border-radius:50%;width:25px;height:25px;font-size:18px;padding:0 8px 0 6px;}",".image.jsx-2474059597{height:500px;width:100%;background-size:cover;background-repeat:no-repeat;-webkit-transition:background-position 0.5s ease-in-out 0s;transition:background-position 0.5s ease-in-out 0s;background-position:top center;background-size:100% auto !important;}",".description.jsx-2474059597{padding:12px;background-color:white;text-align:center;font-weight:bold;width:100%;margin:0px;}",".container.jsx-2474059597:hover .image.jsx-2474059597{cursor:pointer;background-position:bottom center !important;-webkit-transition:background-position 5s ease-in-out 0s;transition:background-position 5s ease-in-out 0s;}"]}),className:"jsx-2474059597"},s8=s6.className,s7=s6.styles;let ce=(0,l.withTranslation)(["common","editor"])(function(e){var t,o=e.t,i=e.selectTemplate,r=e.currentTemplateId,a=e.showTemplatesDrawer,s=e.isDrawerVisible,l=e.dataTestId,u=(0,c.useState)(),m=u[0],h=u[1],p=(0,c.useState)(!1),x=p[
10],g=p[1],f=[{id:"bondi",imageUrl:sY,description:o("editor:editor.themes.bondi")},{id:"whitehaven",imageUrl:sV,description:o("editor:editor.themes.whitehaven2")},{id:"cottesloe",imageUrl:sq,description:o("editor:editor.themes.cottesloe")},{id:"burleigh",imageUrl:sQ,description:o("editor:editor.themes.burleigh")},{id:"goldcoast",imageUrl:sZ,description:o("editor:editor.themes.goldCoast")},{id:"crestview",imageUrl:sG,description:o("editor:editor.themes.crestview")}],b=(t=(0,L.A)(W().mark(function e(){var t;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n(80522)("./".concat(m));case 2:i((t=e.sent).sections,m,t.meta),g(!1),a(!1);case 6:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,en.jsxs)(tk.A,{title:o("editor:editor.selectATemplate"),open:s,onClose:function(){return a(!1)},anchor:"right",width:"100vw",contentSx:{backgroundColor:"rgb(235, 236, 239)",minHeight:"calc(100vh - 55px)",overflowY:"auto",p:2},slotProps:{root:{keepMounted:!1}},children:[(0,en.jsxs)(d.A,{container:!0,spacing:3,children:[f.map(function(e){return(0,en.jsx)(d.A,{size:{xs:12,md:4},children:(0,en.jsxs)("div",{role:"button",tabIndex:0,onKeyDown:function(t){("Enter"===t.key||" "===t.key)&&(g(!0),h(e.id))},className:"".concat(s8," container ").concat(r===e.id?"selected":""),onClick:function(){g(!0),h(e.id)},"data-testid":"".concat(l,"-").concat(e.id),children:[(0,en.jsx)("div",{className:"".concat(s8," image"),style:{backgroundImage:"url(".concat(e.imageUrl,")")}}),(0,en.jsx)("p",{className:"".concat(s8," description container ").concat(r===e.id?"selected":""),children:e.description})]})},e.id)}),s7]}),(0,en.jsxs)(s3.A,{open:x,onClose:function(){return g(!1)},maxWidth:"sm",fullWidth:!0,children:[(0,en.jsx)(s5.A,{children:o("editor:editor.templateModalHeader")}),(0,en.jsx)(s4.A,{children:(0,en.jsxs)("p",{children:[o("editor:editor.templateModalTitle"),(0,en.jsx)("br",{}),o("editor:editor.templateModalDescription")]})}),(0,en.jsxs)(s9.A,{children:[(0,en.jsx)(Z.A,{onClick:function(){a(!1),g(!1)},"data-testid":"".concat(l,"-cancelBtn"),children:o("common:common.cancel")}),(0,en.jsx)(Z.A,{variant:"contained",color:"primary",onClick:b,"data-testid":"".concat(l,"-saveBtn"),children:o("common:common.yesImSure")})]})]})]})}),ct=(0,o.Ng)(function(e){return{currentTemplateId:e.homePageRevision.revision.meta.templateId,isDrawerVisible:e.homePageRevision.showTemplatesDrawer,dataTestId:"admin-ae-he-changeTemplate"}},function(e){return(0,i.zH)({selectTemplate:ea.H0,showTemplatesDrawer:ea.Es},e)})(ce);var cn={styles:(0,en.jsx)(s(),{id:"3316384007",children:[".sidebar.jsx-3316384007{height:100%;overflow-y:auto;padding:12px;border:1px solid rgb(232,232,232);margin-right:2px;position:relative;box-sizing:border-box;}",".drawer-title-left-icon.jsx-3316384007{font-size:24px;}",".drawer-title.jsx-3316384007{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".drawer-title.jsx-3316384007:hover{cursor:pointer;}",".drawer-title-content.jsx-3316384007{margin-left:24px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;text-transform:capitalize;font-size:18px;font-weight:bold;color:rgba(0,0,0,0.87);}",".drawer-title-content-icon.jsx-3316384007{font-size:18px;margin-right:12px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}"]}),className:"jsx-3316384007"},co=cn.className,ci=cn.styles,cr=function(e){return{fontSize:30,color:e}};let ca=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.currentSectionId,o=e.setCurrentSectionId,i=e.dataTestId,r=(0,c.useState)(!1),a=r[0],l=r[1],d=(0,c.useState)(""),u=d[0],h=d[1],p=(0,c.useRef)(null),x=(0,c.useCallback)(function(){return p.current},[]);(0,c.useEffect)(function(){""!==n&&(h("homePageEditor"),l(!0))},[n]),(0,c.useEffect)(function(){if(a){var e=function(e){"Escape"===e.key&&(o(""),h(""),l(!1))};return window.addEventListener("keydown",e),function(){return window.removeEventListener("keydown",e)}}},[a]);var g=function(e){switch(e){case"templates":return(0,en.jsx)(F.A,{sx:cr("#44a5d2")});case"styles":return(0,en.jsx)(H.A,{sx:cr("#754498")});case"images":return(0,en.jsx)(E.A,{sx:cr("#e53a32")});case"homePageEditor":default:return(0,en.jsx)(D.A,{sx:cr("#f59233")});
1case"projectStyles":return(0,en.jsx)(U.A,{sx:cr("#F759AB")});case"navigationLinks":return(0,en.jsx)(R.A,{sx:cr("#0f4b70")})}},f=function(){o(""),h(""),l(!1)};return(0,en.jsxs)(c.Fragment,{children:[(0,en.jsx)(ct,{}),(0,en.jsxs)(m.A,{ref:p,sx:{position:"relative",height:"100%",minHeight:0,overflow:"hidden"},children:[(0,en.jsxs)("div",{className:"jsx-244019776 "+"".concat(co," sidebar"),children:[[{key:"styles",title:t("editor:editor.styles"),description:t("editor:editor.helpTexts.styles"),dataTestID:"".concat(i,"-globalStyles")},{key:"homePageEditor",title:t("editor:editor.homePageEditor"),description:t("editor:editor.helpTexts.section"),dataTestID:"".concat(i,"-homePageEditor")},{key:"projectStyles",title:t("editor:editor.projectStyles"),description:t("editor:editor.helpTexts.projectStyles"),dataTestID:"".concat(i,"-projectStyles")},{key:"images",title:t("editor:editor.images"),description:t("editor:editor.helpTexts.images"),dataTestID:"".concat(i,"-images")}].map(function(e){return(0,en.jsx)(m.A,{"data-testid":e.dataTestID,sx:{mb:1.5,borderRadius:1,border:1,borderColor:"divider",bgcolor:"background.paper",overflow:"hidden",transition:function(e){return e.transitions.create(["box-shadow"],{duration:e.transitions.duration.short})},"&:hover":{boxShadow:function(e){return e.shadows[4]}}},children:(0,en.jsx)(P.A,{onClick:function(){h(e.key),l(!0)},sx:{px:1.5,display:"block",bgcolor:"common.white"},children:(0,en.jsxs)(m.A,{className:"hpe-section-header",sx:{my:1},children:[(0,en.jsx)(m.A,{className:"hpe-icon",children:g(e.key)}),(0,en.jsx)(B.A,{title:e.title,description:e.description})]})})},e.key)}),(0,en.jsx)(s(),{id:"244019776",children:[".hpe-section{margin-bottom:-18px;}",".hpe-section-header{padding:8px 4px;margin-left:0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;gap:8px;width:100%;}",".hpe-icon{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;min-width:32px;height:24px;font-size:24px;padding-right:0;}"]}),ci]}),(0,en.jsx)(N.A,{direction:"left",in:a,container:x,mountOnEnter:!0,unmountOnExit:!0,timeout:220,easing:{enter:"cubic-bezier(0, 0, 0.2, 1)",exit:"cubic-bezier(0.4, 0, 1, 1)"},children:(0,en.jsxs)(O.A,{elevation:3,square:!0,"data-testid":i,sx:{position:"absolute",inset:0,zIndex:2,display:"flex",flexDirection:"column",overflow:"hidden",border:"1px solid #e8e8e8",borderRadius:0,bgcolor:"rgb(235, 236, 239)"},children:[(0,en.jsxs)(m.A,{component:"div",className:"".concat(co," drawer-title"),role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&f()},onClick:f,sx:{px:2,py:1.5,borderBottom:1,borderColor:"divider",flexShrink:0,bgcolor:"background.paper"},children:[(0,en.jsx)(z.A,{className:"".concat(co," drawer-title-left-icon")}),u?(0,en.jsxs)("span",{className:"".concat(co," drawer-title-content"),children:[(0,en.jsx)("span",{className:"".concat(co," drawer-title-content-icon"),children:g(u)}),t("editor:editor.".concat(u))]}):null]}),(0,en.jsx)(m.A,{sx:{p:1.5,flex:1,minHeight:0,overflow:"auto"},children:function(e){switch(e){case"styles":default:return(0,en.jsx)(tv,{});case"images":return(0,en.jsx)(es,{});case"projectStyles":return(0,en.jsx)(tH,{});case"homePageEditor":return(0,en.jsx)(s2,{})}}(u)})]})})]})]})}),cs=(0,o.Ng)(function(e){return{currentSectionId:e.homePageRevision.currentSectionId,dataTestId:"admin-ae-sidebar"}},function(e){return(0,i.zH)({setCurrentSectionId:ea.Qu},e)})(ca),cc=(0,l.withTranslation)(["editor"])(function(e){var t,n=e.t,o=e.saveHomePageRevision,i=e.updateHomePageRevision,r=e.saveSite,a=e.dataTestId,s=(0,c.useState)(!1),l=s[0],d=s[1],u=(t=(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return d(!0),r(),i("published",!1),e.next=5,o();case 5:d(!1);case 6:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return(0,en.jsx)(Z.A,{variant:"outlined",onClick:u,loading:l,loadingPosition:"start",className:"ehq-mr-2.5","data-testid":"".concat(a),children:n("editor:editor.saveAsDraft")})}),cl=(0,o.Ng)(function(e){return{dataTestId:"admin-ae-he-preview-saveAsDraftBtn"}},function(e){return(0,i.zH)({saveHomePageRevision:ea.Z0,updateHomePageRevision:ea.jv,saveSite:er.X8},e)})(cc);var cd=n(51975);let cu=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.lastPublishedRevision,i=e.lastRevision,r=e.setHomePageRevision,a=e.currentRevision,s=e.dataTestId,l=(0,c.useState)(!1),d=l[0],u=l[1],m=function(){return u(!1)};return(t=!i||!!i.published,t=!i||!a||!!a.published,o)?(0,en.jsxs)(en.Fragment,{children:[t?(0,en.jsx)(h.A,{placement:"bottom",title:n("editor.restoreDisabledDescription"),children:(0,en.jsx)("span",{children:(0,en.jsx)(Z.A,{variant:"outlined",disabled:t,"data-testid":"".concat(s),children:n("editor:editor.restore")})})}):(0,en.jsx)(Z.A,{variant:"outlined",disabled:t,"data-testid":"".concat(s),onClick:function(){return u(!0)},children:n("editor:editor.restore")}),(0,en.jsxs)(s3.A,{open:d,onClose:m,role:"alertdialog","aria-labelledby":"restore-published-title","aria-describedby":"restore-published-description",maxWidth:"xs",fullWidth:!0,children:[(0,en.jsxs)(s5.A,{id:"restore-published-title",sx:{pr:6,position:"relative"},children:[n("editor:editor.restore"),(0,en.jsx)(v.A,{"aria-label":n("common:common.close"),onClick:m,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(s,"-closeBtn"),children:(0,en.jsx)(j.A,{fontSize:"small"})})]}),(0,en.jsxs)(s4.A,{children:[(0,en.jsx)(cd.A,{id:"restore-published-description",children:n("editor:editor.confirmRestorePublish")}),(0,en.jsx)(cd.A,{sx:{mt:2.5},children:n("editor:editor.confirmRestore")})]}),(0,en.jsxs)(s9.A,{sx:{px:3,pb:2},children:[(0,en.jsx)(Z.A,{onClick:m,children:n("editor:editor.no")}),(0,en.jsx)(Z.A,{variant:"contained",color:"primary",disableElevation:!0,onClick:function(){r(o),m()},children:n("editor:editor.yes")})]})]})]}):(0,en.jsx)(h.A,{placement:"top",title:n("editor:editor.restoreDescription"),children:(0,en.jsx)("span",{children:(0,en.jsx)(Z.A,{variant:"outlined",disabled:!0,"data-testid":"".concat(s),children:n("editor:editor.restore")})})})});var cm=n(61158),ch=n(33292),cp=n(22600);function cx(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function cg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?cx(Object(n),!0).forEach(function(t){(0,ec.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cx(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var cf=function(){var e;return e=(0,L.A)(W().mark(function e(t,n){var o,i,r,a;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o={page:1,per_page:1},i={sort:{id:"desc"},published:!0},r=new cm.A(o,i),t({type:ch.A.FETCH_LAST_PUBLISHED_HOME_PAGE_REVISIONS_REQUEST}),e.prev=4,e.next=7,cp.A.query(r);case 7:var n;a=e.sent,t({type:ch.A.FETCH_LAST_PUBLISHED_HOME_PAGE_REVISIONS_SUCCESS,revision:null!=(n=a[0])&&"function"==typeof n.attributes?cg(cg({id:n.id},n.attributes()),n.links||{}):n}),e.next=14;break;case 11:e.prev=11,e.t0=e.catch(4),t({type:ch.A.FETCH_LAST_PUBLISHED_HOME_PAGE_REVISIONS_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 14:case"end":return e.stop()}},e,null,[[4,11]])})),function(t,n){return e.apply(this,arguments)}};let cb=(0,o.Ng)(function(e){return{currentRevision:e.homePageRevision.revision,lastPublishedRevision:e.homePageRevisions.lastPublishedRevision,lastRevision:e.homePageRevisions.lastRevision,dataTestId:"admin-ae-he-preview-restoreBtn"}},function(e){return(0,i.zH)({fetchLastPublishedHomePageRevisions:cf,setHomePageRevision:ea.C7},e)})(cu);var cj={styles:(0,en.jsx)(s(),{id:"499528257",children:[".share-link.jsx-499528257{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;margin-top:25px;gap:12px;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".share-link-title.jsx-499528257{font-weight:bold;margin-top:5px;}",".share-link-description.jsx-499528257{margin-top:25px;}"]}),className:"jsx-499528257"},cv=cj.className,cy=cj.styles;let cA=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=e.token,o=e.currentRevision,i=e.isSiteOnBoardingEnabled,r=e.isSiteBlocked,a=e.lockStatus,s=e.dataTestId;(0,c.useEffect)(function(){function e(){return(e=(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a();case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}i&&function(){e.apply(this,arguments)}()},[]);var l=(0,c.useState)(!1),d=l[0],u=l[1],m=function(){return u(!1)};return(0,en.jsxs)(en.Fragment,{children:[o.published?(0,en.jsx)(h.A,{placement:"bottom",title:t("editor:editor.shareADraftTooltip"),children:(0,en.jsx)(y.A,{onClick:function(){return u(!0)},disabled:!!o.published,"data-testid":"".concat(s),children:t("editor:editor.shareADraft")})}):(0,en.jsx)(y.A,{onClick:function(){return u(!0)},disabled:!!o.published,"data-testid":"".concat(s),children:t("editor:editor.shareADraft")}),(0,en.jsxs)(s3.A,{open:d,onClose:m,maxWidth:"sm",fullWidth:!0,children:[(0,en.jsxs)(s5.A,{sx:{pr:6,position:"relative"},children:[t("editor:editor.shareAPreview"),(0,en.jsx)(v.A,{"aria-label":t("common:common.close"),onClick:m,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(s,"-closeBtn"),children:(0,en.jsx)(j.A,{fontSize:"small"})})]}),(0,en.jsxs)(s4.A,{children:[(0,en.jsx)("p",{className:"".concat(cv," share-link-title"),children:t("editor:editor.shareAPreviewTitle")}),(0,en.jsx)("p",{className:"".concat(cv," share-link-description"),children:t("editor:editor.shareAPreviewDescription")}),(0,en.jsxs)("div",{className:"".concat(cv," share-link"),children:[(0,en.jsx)(Q.A,{id:"preview-link",sx:{flex:1,minWidth:220},value:i&&r?"".concat(window.location.origin,"/?draft=true&token=").concat(n):"".concat(window.location.origin,"/?draft=true"),"data-testid":"".concat(s,"-input"),size:"medium",fullWidth:!0,variant:"outlined",slotProps:{htmlInput:{readOnly:!0}}}),(0,en.jsx)(Z.A,{variant:"contained",color:"primary",onClick:function(){document.getElementById("preview-link").select(),document.execCommand("copy")},"data-testid":"".concat(s,"-copyBtn"),startIcon:(0,en.jsx)(nb.A,{}),children:t("editor:editor.copy")})]})]})]}),cy]})}),cw=(0,o.Ng)(function(e){return{currentRevision:e.homePageRevision.revision,token:e.currentSite.site.token,isSiteBlocked:e.currentSite.site.blocked,isSiteOnBoardingEnabled:e.features.features.hasOwnProperty("enable_site_onboarding")&&e.features.features.enable_site_onboarding.enabled,dataTestId:"admin-ae-he-preview-shareDraftBtn"}},function(e){return(0,i.zH)({lockStatus:er.oj},e)})(cA);var cC={styles:(0,en.jsx)(s(),{id:"2370514378",children:[".preview-draft-button.jsx-2370514378{border-radius:5px;}"]}),className:"jsx-2370514378"},cT=cC.className,ck=cC.styles;let cS=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.token,i=e.currentRevision,r=e.isSiteBlocked,a=e.isSiteOnBoardingEnabled,s=e.lockStatus,l=e.dataTestId;(0,c.useEffect)(function(){function e(){return(e=(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,s();case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}a&&function(){e.apply(this,arguments)}()},[]);var d=(t=(0,L.A)(W().mark(function e(t){var n;return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:t.preventDefault(),a&&r?(n="".concat(window.location.origin,"/?draft=true&token=").concat(o),window.open(n)):window.open("".concat(window.location.origin,"/?draft=true"));case 2:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)});return(0,en.jsxs)(en.Fragment,{children:[i.published?(0,en.jsx)(h.A,{placement:"bottom",title:n("editor:editor.previewDraftTooltip"),children:(0,en.jsx)("span",{children:(0,en.jsx)(Z.A,{variant:"outlined",disabled:!0,className:"".concat(cT," preview-draft-button ehq-mr-2.5"),"data-testid":"".concat(l),children:n("editor:editor.previewDraft")})})}):(0,en.jsx)(h.A,{placement:"bottom",title:n("editor:editor.previewNoDraftTooltip"),children:(0,en.jsx)("span",{children:(0,en.jsx)(Z.A,{variant:"outlined",disabled:!!i.published,className:"".concat(cT," preview-draft-button ehq-mr-2.5"),onClick:d,"data-testid":"".concat(l),children:n("editor:editor.previewDraft")})})}),ck]})}),cI=(0,o.Ng)(function(e){return{currentRevision:e.homePageRevision.revision,token:e.currentSite.site.token,isSiteBlocked:e.currentSite.site.blocked,isSiteOnBoardingEnabled:e.features.features.hasOwnProperty("enable_site_onboarding")&&e.features.features.enable_site_onboarding.enabled,dataTestId:"admin-ae-he-preview-previewDraftBtn"}},function(e){return(0,i.zH)({lockStatus:er.oj},e)})(cS),cP=(0,l.withTranslation)(["common","editor"])(function(e){var t,n=e.t,o=e.saveHomePageRevision,i=e.currentUserRole,r=e.hasPublishedRevision,a=e.isARebrandSite,s=e.updateHomePageRevision,l=e.fetchLastPublishedHomePageRevisions,d=e.saveSite,u=e.dataTestId,m=(0,c.useState)(!1),p=m[0],x=m[1],g=(0,c.useState)(!1),f=g[0],b=g[1],y=function(){return b(!1)},A=(t=(0,L.A)(W().mark(function e(){return W().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return b(!1),x(!0),s("published",!0),d(),e.next=6,o();case 6:return e.next=8,l();case 8:x(!1);case 9:case"end":return e.stop()}},e)})),function(){return t.apply(this,arguments)});return a&&!r&&!function(){if([ts.PlatformAdmin].indexOf(i)>-1)return!0}()?(0,en.jsx)(h.A,{placement:"bottom",title:n("editor:editor.publishDescription"),children:(0,en.jsx)(Z.A,{disabled:!0,"data-testid":"".concat(u),children:n("editor:editor.publish")})}):(0,en.jsxs)(en.Fragment,{children:[(0,en.jsx)(Z.A,{variant:"contained",color:"primary",disabled:p,"data-testid":"".concat(u),onClick:function(){return b(!0)},startIcon:p?(0,en.jsx)(M.A,{color:"inherit",size:18}):null,children:n("editor:editor.publish")}),(0,en.jsxs)(s3.A,{open:f,onClose:y,role:"alertdialog","aria-labelledby":"publish-home-title","aria-describedby":"publish-home-description",maxWidth:"xs",fullWidth:!0,children:[(0,en.jsxs)(s5.A,{id:"publish-home-title",sx:{pr:6,position:"relative"},children:[n("editor:editor.publish"),(0,en.jsx)(v.A,{"aria-label":n("common:common.close"),onClick:y,size:"small",sx:{position:"absolute",right:8,top:8},"data-testid":"".concat(u,"-closeBtn"),children:(0,en.jsx)(j.A,{fontSize:"small"})})]}),(0,en.jsxs)(s4.A,{children:[(0,en.jsx)(cd.A,{id:"publish-home-description",children:n("editor:editor.confirmPublishText")}),(0,en.jsx)(cd.A,{sx:{mb:2.5},children:n("editor:editor.confirmStep")}),(0,en.jsx)(cd.A,{children:n("editor:editor.confirmPublish")})]}),(0,en.jsxs)(s9.A,{sx:{px:3,pb:2},children:[(0,en.jsx)(Z.A,{onClick:y,children:n("editor:editor.no")}),(0,en.jsx)(Z.A,{variant:"contained",color:"primary",disableElevation:!0,onClick:A,children:n("editor:editor.yes")})]})]})]})}),cO=(0,o.Ng)(function(e){return{currentUserRole:e.currentUser.user.roleName,hasPublishedRevision:!!e.homePageRevisions.lastPublishedRevision,isARebrandSite:!!e.liquidTemplates.liquidTemplates.filter(function(e){return!!e.body}).length,dataTestId:"admin-ae-he-preview-publishBtn"}},function(e){return(0,i.zH)({saveHomePageRevision:ea.Z0,updateHomePageRevision:ea.jv,fetchLastPublishedHomePageRevisions:cf,saveSite:er.X8},e)})(cP);var cN=I()(function(){return Promise.all([n.e(24519),n.e(9653),n.e(45905),n.e(73064)]).then(n.bind(n,18059))},{ssr:!1,loadableGenerated:{webpack:function(){return[18059]}}}),cz={styles:(0,en.jsx)(s(),{id:"2776220356",children:[".sidebar-container.jsx-2776220356{overflow:hidden;position:relative;height:100%;width:100%;min-width:0;box-sizing:border-box;}",".buttons-container.jsx-2776220356{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;
1-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;padding:24px 0;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}",".right-content.jsx-2776220356{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".home-page-viewer-container.jsx-2776220356{box-shadow:0 0 10px 5px rgba(0,21,41,0.14);-webkit-flex:1;-ms-flex:1;flex:1;min-height:0;overflow-y:auto;border-radius:8px;border:1px solid rgba(0,0,0,0.08);}",".home-page-viewer.jsx-2776220356{height:100%;overflow:auto;box-shadow:0 0 10px 5px rgba(0,21,41,0.14);}",".live-preview-drawer-header.jsx-2776220356{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16px;margin:16px 0 24px;}",".home-page-live-previewer.jsx-2776220356{height:calc(100vh - 110px);box-shadow:0 0 10px 5px rgba(0,21,41,0.14);margin:0 auto;border-radius:8px;}",".preview-container.jsx-2776220356{padding:0 24px 24px;height:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;box-sizing:border-box;}",".draft-buttons-group-container.jsx-2776220356{margin-right:8px;}",".live-preview-buttons.jsx-2776220356{width:auto;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}",".hidden-live-preview.jsx-2776220356{display:none;}"]}),className:"jsx-2776220356"},cD=cz.className,cH=cz.styles;let cF=(0,l.withTranslation)(["common","editor"])(function(e){var t=e.t,n=(e.updateQuery,e.fetchProjectsForAE,e.hasUnsavedChanges),o=e.dataTestId,i=e.nonce,a=(0,c.useState)("100%"),l=a[0],w=a[1],S=(0,c.useState)(!1),I=S[0],P=S[1],O=(0,c.useState)(16),N=O[0],z=O[1],D=function(e){e.preventDefault(),e.returnValue=""},H=(0,c.useCallback)(function(){var e=document.getElementById("home-page-viewer-container");if(e){var t=e.clientWidth;t>801&&t<1200?z(14):t>601&&t<800?z(12):z(10)}},[]);return(0,c.useEffect)(function(){return n&&window.addEventListener("beforeunload",D),H(),k().router.change=function(){for(var e=arguments.length,o=Array(e),i=0;i<e;i++)o[i]=arguments[i];return n?confirm(t("editor:editor.reloadMessage"))?T.Router.prototype.change.apply(k().router,o):new Promise(function(e){return e(!1)}):T.Router.prototype.change.apply(k().router,o)},function(){n&&(window.removeEventListener("beforeunload",D),delete k().router.change)}},[n,t,H]),(0,en.jsxs)(c.Fragment,{children:[(0,en.jsxs)(d.A,{id:"main-content",container:!0,spacing:0,sx:{flexWrap:"nowrap",height:"100vh",overflow:"hidden"},children:[(0,en.jsx)(d.A,{size:{xs:12,md:4},sx:{height:"100%",flexShrink:0,width:{md:"33.3333%"},maxWidth:{md:"33.3333%"},minWidth:{xs:0,md:320}},children:(0,en.jsx)("div",{className:"jsx-4095209316 "+"".concat(cD," sidebar-container"),children:(0,en.jsx)(cs,{})})}),(0,en.jsx)(d.A,{size:{xs:12,md:8},sx:{minWidth:0,height:"100%",flex:{md:"1 1 0"}},children:(0,en.jsxs)("div",{className:"jsx-4095209316 "+"".concat(cD," preview-container"),children:[(0,en.jsxs)("div",{className:"jsx-4095209316 "+"".concat(cD," buttons-container"),children:[(0,en.jsx)("div",{className:"jsx-4095209316 "+"".concat(cD," left-content"),children:(0,en.jsx)(cb,{})}),(0,en.jsxs)("div",{className:"jsx-4095209316 "+"".concat(cD," right-content"),children:[(0,en.jsx)("div",{className:"jsx-4095209316 "+"".concat(cD," draft-buttons-group-container"),children:(0,en.jsx)(cl,{})}),(0,en.jsx)("div",{className:"jsx-4095209316 "+"".concat(cD," draft-buttons-group-container"),children:(0,en.jsx)(h.A,{title:t("editor:editor.previewTooltip"),children:(0,en.jsx)("span",{className:"jsx-4095209316",children:(0,en.jsx)(y.A,{onClick:function(){return P(!0)},"data-testid":"".concat(o,"-previewBtn"),children:t("editor:editor.preview")})})})}),(0,en.jsx)(cO,{})]})]}),(0,en.jsxs)("div",{id:"home-page-viewer-container",style:{fontSize:N},className:"jsx-4095209316 "+"".concat(cD," home-page-viewer-container"),children:[(0,en.jsx)(cN,{isInsideAdminView:!0}),(0,en.jsx)(u.Ay,{anchor:"right",open:I,onClose:function(){return P(!1)},slotProps:{paper:{sx:{width:"100vw",maxWidth:"100vw"}},root:{keepMounted:!1}},children:(0,en.jsxs)(m.A,{sx:{px:2,pb:2},children:[(0,en.jsxs)("div",{className:"".concat(cD," live-preview-drawer-header"),children:[(0,en.jsxs)(x.A,{exclusive:!0,value:l,onCh
1ange:function(e,t){return null!=t&&w(t)},size:"medium","aria-label":t("editor:editor.viewOnDesktop"),className:"testId-".concat(o,"-devices"),children:[(0,en.jsx)(p.A,{value:"576px","data-testid":"".concat(o,"-viewOnMobile"),"aria-label":t("editor:editor.viewOnMobile"),children:(0,en.jsx)(h.A,{title:t("editor:editor.viewOnMobile"),children:(0,en.jsx)("span",{children:(0,en.jsx)(g.A,{fontSize:"small"})})})}),(0,en.jsx)(p.A,{value:"768px","data-testid":"".concat(o,"-viewOnTablet"),"aria-label":t("editor:editor.viewOnTablet"),children:(0,en.jsx)(h.A,{title:t("editor:editor.viewOnTablet"),children:(0,en.jsx)("span",{children:(0,en.jsx)(f.A,{fontSize:"small"})})})}),(0,en.jsx)(p.A,{value:"100%","data-testid":"".concat(o,"-viewOnDesktop"),"aria-label":t("editor:editor.viewOnDesktop"),children:(0,en.jsx)(h.A,{title:t("editor:editor.viewOnDesktop"),children:(0,en.jsx)("span",{children:(0,en.jsx)(b.A,{fontSize:"small"})})})})]}),(0,en.jsxs)(m.A,{sx:{display:"flex",alignItems:"center",gap:1},children:[(0,en.jsxs)("div",{className:"".concat(cD," live-preview-buttons"),children:[(0,en.jsx)(cI,{}),(0,en.jsx)(cl,{}),(0,en.jsx)(cw,{})]}),(0,en.jsx)(v.A,{"aria-label":"close",onClick:function(){return P(!1)},"data-testid":"".concat(o,"-previewCloseBtn"),size:"medium",edge:"end",children:(0,en.jsx)(j.A,{})})]})]}),(0,en.jsx)("div",{className:"".concat(cD," home-page-live-previewer"),style:{width:l},children:(0,en.jsx)(A.Ay,{nonce:i,style:{border:0,width:"100%",height:"100%"},initialContent:"<!DOCTYPE html><html><head></head><style nonce=".concat(i,'>.top-navbar { overflow: hidden } .main-navbar { overflow: hidden } .frame-content { pointer-events: none;} .ehq-participant-header .nav-links__list__list-item__child, .ehq-participant-header .auth-links__list__list-item__child { display: none; }</style><body style="overflow: auto"><div id="iframe"></div></body></html>'),children:(0,en.jsx)(A.rH,{children:function(e){var t=e.document,n=e.window,o=n.top.document.getElementsByTagName("link"),i=n.top.document.getElementsByTagName("style"),a=t.getElementsByTagName("head").item(0),s=t.createElement("script");s.src="https://platform.twitter.com/widgets.js",s.charset="utf-8",a.appendChild(s);for(var c=0,l=o.length;c<l;c++)if(o[c].rel&&"stylesheet"===o[c].rel){for(var d=t.createElement("link"),u=o[c].attributes,m=0,h=u.length;m<h;m++)d.setAttribute(u[m].nodeName,u[m].nodeValue);a.appendChild(d)}for(var p=0,x=i.length;p<x;p++){var g=t.createElement("style"),f=i[p].innerHTML;g.type="text/css",g.appendChild(t.createTextNode(f)),a.appendChild(g)}var b=C()((0,r.A)(n.top.document.querySelectorAll("[data-emotion]")),function(e){var t=e.sheet;return(0,r.A)(t.cssRules).map(function(e){return e.cssText})}).join("\n"),j=t.createElement("style");return j.type="text/css",j.appendChild(t.createTextNode(b)),a.appendChild(j),(0,en.jsx)(cN,{isInsideDevicePreview:!0})}})})})]})})]})]})})]}),(0,en.jsx)(s(),{id:"4095209316",children:["body{overflow-y:hidden;}",".home-page-viewer-container a,.home-page-viewer-container .participant-header li,.home-page-viewer-container .participant-header input,.home-page-viewer-container .project-finder,.home-page-viewer-container .faq-accordion button,.home-page-viewer-container .video-section iframe,.home-page-viewer-container .ehq-participant-header button,.home-page-viewer-container .ehq-participant-header .logo,.home-page-viewer-container .animated-card{pointer-events:none;-webkit-transition:none;transition:none;}",".upload-icon{font-size:30px;}",".image-placeholder{height:200px;border-radius:4px;margin-bottom:12px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;background-color:#f5f5f5;}",".image-info{width:90%;margin:0px auto;line-height:20px;}",".color-box{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".button-popover{width:100px;}",".icon-outlined-style{margin-left:4px;}"]}),cH]})}),cR=(0,o.Ng)(function(e){return{hasUnsavedChanges:e.homePageRevision.hasUnsavedChanges,dataTestId:"admin-ae-he-preview-section",nonce:e.homePageRevision.nonce}},function(e){return(0,i.zH)({fetchProjectsForAE:nK.O$,updateQuery:nK.oR},e)})(cF)},77080:e=>
1{e.exports=[{key:"open_sans",name:"Open Sans",src:"https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400;1,500;1,600;1,700;1,800&display=swap"},{key:"roboto",name:"Roboto",src:"https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"},{key:"lato",name:"Lato",src:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap"},{key:"lora_serif",name:"Lora",src:"https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500;1,600;1,700&display=swap"},{key:"source_sans_pro",name:"Source Sans Pro",src:"https://fonts.googleapis.com/css2?family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap"},{key:"ubuntu",name:"Ubuntu",src:"https://fonts.googleapis.com/css2?family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap"},{key:"merriweather_serif",name:"Merriweather",src:"https://fonts.googleapis.com/css2?family=Merriweather:ital,wght@0,300;0,400;0,700;0,900;1,300;1,400;1,700;1,900&display=swap"},{key:"playfair_serif",name:"Playfair Display",src:"https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;0,800;0,900;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"exo_2",name:"Exo 2",src:"https://fonts.googleapis.com/css2?family=Exo+2:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"arial",name:"Arial",src:""},{key:"helvetica",name:"Helvetica",src:""},{key:"montserrat",name:"Montserrat",src:"https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"bree",name:"Bree",src:"https://use.typekit.net/tll6nyp.css"},{key:"fira_sans",name:"Fira Sans",src:"https://fonts.googleapis.com/css2?family=Fira+Sans:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"poppins",name:"Poppins",src:"https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"roboto_slab",name:"Roboto Slab",src:"https://fonts.googleapis.com/css2?family=Roboto+Slab:wght@100;200;300;400;500;600;700;800;900&display=swap"},{key:"questrial",name:"Questrial",src:"https://fonts.googleapis.com/css2?family=Questrial:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"didact_gothic",name:"Didact Gothic",src:"https://fonts.googleapis.com/css2?family=Didact+Gothic:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"ropa_sans",name:"Ropa Sans",src:"https://fonts.googleapis.com/css2?family=Ropa+Sans:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"gudea",name:"Gudea",src:"https://fonts.googleapis.com/css2?family=Gudea:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"varela_round",name:"Varela Round",src:"https://fonts.googleapis.com/css2?family=Varela+Round:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"noto_sans",name:"Noto Sans",src:"https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"roboto_condensed",name:"Roboto Condensed",src:"https://fonts.googleapis.com/css2?family=Roboto+Condensed:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&display=swap"},{key:"oswald",name:"Oswald",src:"https://fonts.googleapis.com/css2?family=Oswald:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"raleway",name:"Raleway",src:"https://fonts.googleapis.com/css2?family=Raleway:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"titillium_web",name:"Titillium Web",src:"https://fonts.googleapis.com/css2?family=Titillium+Web:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700&display=swap"},{key:"yanone_kaffeesatz",name:"Yanone Kaffeesatz",src:"https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"libre_baskerville_serif",name:"Libre Baskerville",src:"https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"knewave",name:"Knewave",src:"https://fonts.googleapis.com/css?family=Knewave:ital,wght@0,100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"assistant",name:"Assistant",src:"https://fonts.googleapis.com/css2?family=Assistant:wght@0, 100;0,400;0,700;0,900;1,100;1,400;1,700;1,900&display=swap"},{key:"cabin",name:"Cabin",src:"https://fonts.googleapis.com/css2?family=Cabin:wght@400;700&display=swap"},{key:"aleo",name:"Aleo",src:"//fonts.googleapis.com/css?family=Aleo:300,400,700&display=swap"},{key:"mulish",name:"Mulish",src:"//fonts.googleapis.com/css?family=Mulish:300,400,700&display=swap"},{key:"red_hat_display",name:"Red Hat Display",src:"https://fonts.googleapis.com/css2?family=Red+Hat+Display:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"barlow_condensed",name:"Barlow Condensed",src:"https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"},{key:"inter",name:"Inter",src:"https://fonts.googleapis.com/css2?family=Inter&display=swap"},{key:"outfit",name:"Outfit",src:"https://fonts.googleapis.com/css2?family=Outfit:wght@400;700&display=swap"},{key:"libre_franklin",name:"Libre Franklin",src:"https://fonts.googleapis.com/css2?family=Libre+Franklin:wght@400;700&display=swap"},{key:"lexend_deca",name:"Lexend Deca",src:"https://fonts.googleapis.com/css2?family=Lexend+Deca:wght@400;700&display=swap"}
1,{key:"alegreya_sans_sc",name:"Alegreya Sans SC",src:"https://fonts.googleapis.com/css2?family=Alegreya+Sans+SC:wght@400;700&display=swap"},{key:"figtree",name:"Figtree",src:"https://fonts.googleapis.com/css2?family=Figtree:wght@400;700&display=swap"},{key:"onest",name:"Onest",src:"https://fonts.googleapis.com/css2?family=Onest:wght@400;700&display=swap"},{key:"merriweather_sans",name:"Merriweather Sans",src:"https://fonts.googleapis.com/css2?family=Merriweather+Sans:wght@400;700&display=swap"}]},78438:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/cottesloe.2c8d4c89cd5f31cc.jpg"},78938:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/crestview.408318ebbeb24df4.jpg"},79711:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.2f7524a819fec552.jpg"},79712:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/link-regular-24.a126a5c1cc28e1a4.png"},79834:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var o=n(42969),i=n(14232),r=n(59234),a=n(33713),s=n(62631),c=n(37876);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function u(e){var t=e.label,n=e.control,o=e.sx,l=e.id,u=(0,i.useId)(),m=l||(0,i.isValidElement)(n)&&n.props.id||"".concat(u,"-control"),h=(0,i.isValidElement)(n)?(0,i.cloneElement)(n,{id:n.props.id||m}):n;return(0,c.jsx)(r.A,{sx:d({mb:2},o),children:(0,c.jsxs)(a.A,{direction:"row",alignItems:"center",justifyContent:"space-between",spacing:2,children:[(0,c.jsx)(r.A,{component:"label",htmlFor:m,sx:d({typography:"body1",color:"text.primary",pr:1,flex:"1 1 auto"},s.m),children:t}),(0,c.jsx)(r.A,{sx:{flexShrink:0},children:h})]})})}},80522:(e,t,n)=>{var o={"./bondi":[9560,9560],"./bondi.js":[9560,9560],"./burleigh":[48710,48710],"./burleigh.js":[48710,48710],"./cottesloe":[68778,68778],"./cottesloe.js":[68778,68778],"./crestview":[83774,83774],"./crestview.js":[83774,83774],"./goldcoast":[89148,89148],"./goldcoast.js":[89148,89148],"./whitehaven":[69355,69355],"./whitehaven.js":[69355,69355]};function i(e){if(!n.o(o,e))return Promise.resolve().then(()=>{var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t});var t=o[e],i=t[0];return n.e(t[1]).then(()=>n.t(i,23))}i.keys=()=>Object.keys(o),i.id=80522,e.exports=i},80677:(e,t,n)=>{"use strict";n.d(t,{A:()=>r});var o=n(67376),i=n.n(o);let r=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e?i()(e,{allowedTags:t,allowedAttributes:n}):""}},80818:(e,t,n)=>{"use strict";n.d(t,{YG:()=>x,d0:()=>p,mb:()=>m,qT:()=>h,vR:()=>u});var o=n(42969),i=n(63857),r=n(60180),a=n.n(r),s=n(5288),c=n(1234);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var u=function(){var e;return e=(0,i.A)(a().mark(function e(t){var n;return a().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t({type:s.A.FETCH_SEGMENTS_REQUEST}),e.prev=1,e.next=4,c.A.query({page:1,per_page:999});case 4:n=e.sent,t({type:s.A.FETCH_SEGMENTS_SUCCESS,segments:n.reduce(function(e,t){return e[t.id]=d(d({id:t.id},t.attributes()),{},{hidden:!1,selected:!1}),e},{})}),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),t({type:s.A.FETCH_SEGMENTS_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 11:case"end":return e.stop()}},e,null,[[1,8]])})),function(t){return e.apply(this,arguments)}},m=function(e){return{type:s.A.TOGGLE_SEGMENT,id:e}},h=function(e){return{type:s.A.TOGGLE_ALL_SEGMENTS,selected:e}},p=function(e){return{type:s.A.FILTER_BY_NAME,search:e}},x=function(){return{type:s.A.RESET_SEGMENTS}}},81347:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/four.b8226cf67f87c4c2.jpg"},81816:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.8cef65510763cf9a.jpg"}
1,82089:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.d8240d53c6a2ff15.jpg"},82379:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.5c0f5c6eb8d59a2f.jpg"},82999:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.22e2e4d54c4c2492.jpg"},86169:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/whitehaven.dbe3ac19daf95102.jpg"},87996:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-txt-solid-24.959e0c1e4c20122a.png"},88786:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.bae6e2a68d269589.jpg"},89082:(e,t,n)=>{"use strict";n.d(t,{DE:()=>k,L0:()=>f,MA:()=>w,SL:()=>A,UT:()=>b,jl:()=>g,sk:()=>j,vm:()=>y,x8:()=>T,yg:()=>v,zX:()=>C});var o=n(63857),i=n(44478),r=n(42969),a=n(60180),s=n.n(a),c=n(85150),l=n.n(c),d=n(65132),u=n(61158);function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach(function(t){(0,r.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var p=function(e){return null!=e&&"function"==typeof e.attributes?h(h({id:e.id},e.attributes()),e.links||{}):e},x=function(e){if(null==e)return e;var t=(0,i.A)(e).map(p);return null!=e.meta&&(t.meta=e.meta),t},g=function(){var e;return e=(0,o.A)(s().mark(function e(t,n){var o,i,r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=h({},n().administrators.filters),i=new u.A(n().administrators.queries,o),t({type:d.A.FETCH_ADMINISTRATORS_REQUEST}),e.prev=3,e.next=6,l().query(i);case 6:r=e.sent,t({type:d.A.FETCH_ADMINISTRATORS_SUCCESS,administrators:x(r),meta:r.meta||{count:10}}),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(3),t({type:d.A.FETCH_ADMINISTRATORS_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 13:case"end":return e.stop()}},e,null,[[3,10]])})),function(t,n){return e.apply(this,arguments)}},f=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.BLOCK_ADMINISTRATOR_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.block();case 5:i=t.sent,n({type:d.A.BLOCK_ADMINISTRATOR_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.BLOCK_ADMINISTRATOR_FAILURE,administrator:p(o),errorMessage:t.t0.statusText||t.t0.status});case 12:case"end":return t.stop()}},t,null,[[2,9]])})),function(e){return t.apply(this,arguments)}},b=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.UNBLOCK_ADMINISTRATOR_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.unblock();case 5:i=t.sent,n({type:d.A.UNBLOCK_ADMINISTRATOR_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.UNBLOCK_ADMINISTRATOR_FAILURE,administrator:p(o),errorMessage:t.t0.statusText||t.t0.status});case 12:case"end":return t.stop()}},t,null,[[2,9]])})),function(e){return t.apply(this,arguments)}},j=function(){return{type:d.A.RESET_ADMINISTRATORS}},v=function(e){return{type:d.A.UPDATE_ADMINISTRATORS_QUERIES,queries:e}},y=function(e){return{type:d.A.UPDATE_ADMINISTRATORS_FILTERS,filters:e}},A=function(){var e;return e=(0,o.A)(s().mark(function e(t,n){var o,i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=new u.A({filterable:!0,page:1,per_page:9999},{filters:{role_id:6}}),t({type:d.A.FETCH_HUB_ADMINISTRATORS_REQUEST}),e.prev=2,e.next=5,l().query(o);case 5:i=e.sent,t({type:d.A.FETCH_HUB_ADMINISTRATORS_SUCCESS,administrators:x(i)}),e.next=12;break;case 9:e.prev=9,e.t0=e.catch(2),t({type:d.A.FETCH_HUB_ADMINISTRATORS_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 12:case"end":return e.stop()}},e,null,[[2,9]])})),function(t,n){return e.apply(this,arguments)}},w=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.UPDATE_TO_PARTICIPANT_ROLE_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.updateToParticipantRole();case 5:i=t.sent,n({type:d.A.UPDATE_TO_PARTICIPANT_ROLE_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.UPDATE_TO_PARTICIPANT_ROLE_FAILURE,id:e,errorMessage:t.t0.statusText||t.t0.status||t.t0.message,errors:o.errors.extract()});case 12:case"end":return t.stop()}},t,null,[[2,9]])}
1)),function(e){return t.apply(this,arguments)}},C=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.UPDATE_TO_PROJECT_ADMIN_ROLE_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.updateToProjectAdminRole();case 5:i=t.sent,n({type:d.A.UPDATE_TO_PROJECT_ADMIN_ROLE_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.UPDATE_TO_PROJECT_ADMIN_ROLE_FAILURE,id:e,errorMessage:t.t0.statusText||t.t0.status||t.t0.message,errors:o.errors.extract()});case 12:case"end":return t.stop()}},t,null,[[2,9]])})),function(e){return t.apply(this,arguments)}},T=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.UPDATE_TO_SITE_ADMIN_ROLE_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.updateToSiteAdminRole();case 5:i=t.sent,n({type:d.A.UPDATE_TO_SITE_ADMIN_ROLE_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.UPDATE_TO_SITE_ADMIN_ROLE_FAILURE,id:e,errorMessage:t.t0.statusText||t.t0.status||t.t0.message,errors:o.errors.extract()});case 12:case"end":return t.stop()}},t,null,[[2,9]])})),function(e){return t.apply(this,arguments)}},k=function(e){var t;return t=(0,o.A)(s().mark(function t(n){var o,i;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n({type:d.A.UPDATE_TO_HUB_ADMIN_ROLE_REQUEST,id:e}),o=l().new({id:e}),t.prev=2,t.next=5,o.updateToHubAdminRole();case 5:i=t.sent,n({type:d.A.UPDATE_TO_HUB_ADMIN_ROLE_SUCCESS,administrator:p(i)}),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(2),n({type:d.A.UPDATE_TO_HUB_ADMIN_ROLE_FAILURE,id:e,errorMessage:t.t0.statusText||t.t0.status||t.t0.message,errors:o.errors.extract()});case 12:case"end":return t.stop()}},t,null,[[2,9]])})),function(e){return t.apply(this,arguments)}}},89580:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.06b48affaee71811.jpg"},89671:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.910de65f28974c42.jpg"},91846:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/two.26a4de0c2c2d4a9a.jpg"},91902:()=>{},92449:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.b5b2cf9809653903.jpg"},92706:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/photo-album-regular-24.73ceaba17eb8a41e.png"},93490:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/burleigh.6bfc7e6ebe2452f2.jpg"},94525:(e,t,n)=>{"use strict";n.d(t,{A:()=>c});var o=n(59860),i=n(47091),r=n.n(i),a=n(37876),s=["marginTop","space","children"];let c=function(e){var t=e.marginTop,n=void 0===t?0:t,i=e.space,c=void 0===i?10:i,l=e.children,d=(0,o.A)(e,s),u=d.className?"spaced-buttons ".concat(d.className):"spaced-buttons";return(0,a.jsxs)("div",{className:r().dynamic([["257308641",[n,c,c]]])+" "+(u||""),children:[l,(0,a.jsx)(r(),{id:"257308641",dynamic:[n,c,c],children:[".spaced-buttons{margin-top:".concat(n,"px;}"),".spaced-buttons>button{margin-left:".concat(c,"px;}"),".spaced-buttons>*{margin-left:".concat(c,"px;}"),".spaced-buttons>button:first-child{margin-left:0;}"]})]})}},94674:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-blank-solid-24.bbbea4b3cf15b2ba.png"},94680:(e,t,n)=>{var o={"./bondi":[32052,32052],"./bondi.js":[32052,32052],"./burleigh":[39922,39922],"./burleigh.js":[39922,39922],"./cottesloe":[19878,19878],"./cottesloe.js":[19878,19878],"./crestview":[61738,61738],"./crestview.js":[61738,61738],"./goldcoast":[46736,46736],"./goldcoast.js":[46736,46736],"./whitehaven":[44775,44775],"./whitehaven.js":[44775,44775]};function i(e){if(!n.o(o,e))return Promise.resolve().then(()=>{var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t});var t=o[e],i=t[0];return n.e(t[1]).then(()=>n.t(i,23))}i.keys=()=>Object.keys(o),i.id=94680,e.exports=i},95980:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/calendar-check-solid-24.5c596a15f5c8d0a4.png"},96757:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/one.12b1087764f1a71a.jpg"},96963:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/image-alt-regular-24.ee2ba709eb0bfd43.png"}
1,97014:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/time-solid-24.2d30eed492061964.png"},97330:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/file-gif-solid-24.094a96276683ade1.png"},98943:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/four.83be5d8307104383.jpg"},99371:(e,t,n)=>{"use strict";n.d(t,{h:()=>m});var o=n(42969),i=n(63857),r=n(60180),a=n.n(r),s=n(99006),c=n.n(s),l=n(61158),d=n(53121);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}var m=function(){var e,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return e=(0,i.A)(a().mark(function e(n,i){var r,s,m,h;return a().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n({type:d.A.FETCH_USERS_REQUEST}),r={per_page:9999,page:1},s="",0!==(s=t?i().hubSegments.segments:i().projectSegments.segments).length){e.next=8;break}n({type:d.A.FETCH_USERS_SUCCESS,users:{}}),e.next=19;break;case 8:return e.prev=8,m=new l.A(r,{participant_segment_ids:s}),e.next=12,c().query(m);case 12:h=e.sent,n({type:d.A.FETCH_USERS_SUCCESS,users:h.reduce(function(e,t){return e[t.id]=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({id:t.id},t.attributes()),e},{})}),e.next=19;break;case 16:e.prev=16,e.t0=e.catch(8),n({type:d.A.FETCH_USERS_FAILURE,errorMessage:e.t0.statusText||e.t0.status});case 19:case"end":return e.stop()}},e,null,[[8,16]])})),function(t,n){return e.apply(this,arguments)}}},99469:(e,t,n)=>{"use strict";n.d(t,{A:()=>b});var o=n(42969),i=n(14232),r=n(59234),a=n(39502),s=n(34626),c=n(1796),l=n(38816),d=n(22063),u=n(62631),m=n(1044),h=n(37876);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach(function(t){(0,o.default)(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var g=new Set([s.A,d.A,c.A,l.A]),f=new Set([s.A,d.A,c.A,l.A,m.A]);function b(e){var t,n,o,d,p,b=e.label,j=e.extra,v=e.children,y=e.size,A=e.sx,w=e.className,C=e.id,T=e.labelId,k=e.labelSx,S=(0,i.useId)(),I=null!=b&&!1!==b,P=I&&("string"==typeof b||"number"==typeof b),O=null!=C?C:I?"".concat(S,"-field"):void 0,N=null!=T?T:I?"".concat(S,"-label"):void 0,z=(n=(t={size:void 0===y?"medium":y,fieldId:O,labelId:N,useHtmlFor:P}).size,o=t.fieldId,d=t.labelId,p=t.useHtmlFor,i.Children.map(v,function(e){if(!(0,i.isValidElement)(e))return e;var t,r,a={};if(null!=n&&(null==(t=e.props)?void 0:t.size)===void 0&&g.has(e.type)&&(a.size=n),o&&d&&f.has(e.type)&&(null==(r=e.props)?void 0:r.id)===void 0){a.id=o;var u,b=p?{id:o}:{id:o,"aria-labelledby":d};if(e.type===c.A){var j=e.props.renderInput;a.renderInput=function(e){var t,n=j?j(e):(0,h.jsx)(s.A,x({},e));return(0,i.isValidElement)(n)?(0,i.cloneElement)(n,{slotProps:x(x({},n.props.slotProps),{},{htmlInput:x(x(x(x({},e.inputProps),null==(t=n.props.slotProps)?void 0:t.htmlInput),n.props.inputProps),b)})}):n}}else e.type===l.A?(p||(a["aria-labelledby"]=d),a.inputProps=x(x({},e.props.inputProps),b)):e.type===m.A?p||(a["aria-labelledby"]=d):a.slotProps=x(x({},e.props.slotProps),{},{htmlInput:x(x(x({},null==(u=e.props.slotProps)?void 0:u.htmlInput),e.props.inputProps),b)})}return Object.keys(a).length>0?(0,i.cloneElement)(e,a):e}));return(0,h.jsxs)(r.A,{className:w,sx:x({mb:2},A),children:[I&&(0,h.jsx)(r.A,x(x({component:P?"label":"div"},P?{htmlFor:O}:{id:N}),{},{sx:x(x({display:"flex",alignItems:"center",flexWrap:"wrap",columnGap:.5,rowGap:.25,mb:.75,typography:"body1",color:"text.primary"},u.m),k),children:b})),null!=v&&!1!==v&&(0,h.jsx)(r.A,{sx:{width:"100%",minWidth:0,"& > .MuiTextField-root":{width:"100%",maxWidth:"100%",minWidth:0},"& > .MuiAutocomplete-root":{width:"100%",maxWidth:"100%",minWidth:0}},children:z}),null!=j&&""!==j&&(0,h.jsx)(a.A,x(x({component:"div",sx:{mt:1,mx:0}},O?{id:"".concat(O,"-helper")}:{}),{},{children:j}))]})}},99508:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/three.8e1b93cf3f64d1d8.jpg"}
1,99612:(e,t,n)=>{"use strict";e.exports=n.p+"static/media/calendar-alt-solid-24.787f72fa904ec271.png"}}]); 2//# sourceMappingURL=Editor.e968a1887f5a09a1.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.