"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1899],{26481:function(e,i,t){t.d(i,{Z:function(){return w}});var n=t(85893),o=t(36465),a=t.n(o),s=t(45697),l=t.n(s),r=t(19063),d=t(9143),c=t(79545),u=t(54303),m=t(41664),p=t.n(m),x=t(50178),g=t(9779),v=t(37887),b=t(73552),h=t(52107),f=t(17279),y=t(2232),j=t(78993);function w(e){var i,t;let{tributeInlineJson:o,className:s="",preview:l=!1,tab:m}=e,w=(0,x.Ph)("siteId"),{isSignedIn:T}=(0,g.SE)(),{data:S,loading:I}=(0,v.a)(b.j,{skip:!T}),{page:N}=(0,r.bh)(),k=null!==(t=null==N?void 0:N.tributeInline)&&void 0!==t?t:o,E=(0,c.Fb)(null==k?void 0:k.rules)||l,_=(0,f.ew)(null==k?void 0:k[({feed:"splitCodeFeed",posts:"splitCodePosts"})[m]],"");if(!k||!E||I)return null;let{headline:M,body:A,buttonText:P,rules:D,daysSinceDonation:C}=k,B=(0,j.$)(C,null==S?void 0:null===(i=S.me)||void 0===i?void 0:i.mySites,w,T);return B?null:(0,n.jsx)("div",{className:"".concat(s),children:(0,n.jsxs)(d.Z,{className:"tributeInlineCard paddingTopBottom--24 marginBottom--12 paddingLeftRight--48",isForModal:!0,children:[(0,n.jsxs)("section",{className:a().dynamic([["6d0230096bf7e69e",[y.Bs.MEDIUM]]])+" ",children:[(0,n.jsxs)("div",{className:a().dynamic([["6d0230096bf7e69e",[y.Bs.MEDIUM]]])+" textColumn",children:[(0,n.jsx)("h1",{className:a().dynamic([["6d0230096bf7e69e",[y.Bs.MEDIUM]]])+" h6 marginTop--0 marginBottom--6",children:(0,c.C9)(M)}),(0,n.jsx)(c.Nq,{json:A.json,rules:D||void 0})]}),(0,n.jsx)(p(),{href:_,legacyBehavior:!0,children:(0,n.jsx)(u.Z,{className:"tributeInlineDonateButton",size:h.i.SMALL,"data-qa":"tributeAction",children:P})})]}),(0,n.jsx)(a(),{id:"6d0230096bf7e69e",dynamic:[y.Bs.MEDIUM],children:".tributeInlineCard{margin-bottom:24px}section.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-moz-box-orient:horizontal;-moz-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:justify;-webkit-justify-content:space-between;-moz-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center}.textColumn.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.tributeInlineDonateButton{height:44px;background-color:var(--yellow)!important;color:var(--body-text)!important}.tributeInlineDonateButton:hover{background-color:var(--yellow-hover)!important}@media(max-width:".concat(y.Bs.MEDIUM,"){section.__jsx-style-dynamic-selector{text-align:center;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.tributeInlineDonateButton{margin-top:12px}}")})]})})}w.propTypes={tributeInlineJson:l().object,className:l().string,preview:l().bool,previewTributeCount:l().number,tab:l().string}},81899:function(e,i,t){t.r(i),t.d(i,{__N_SSG:function(){return e3},default:function(){return e4}});var n=t(85893),o=t(45697),a=t.n(o),s=t(50178),l=t(36465),r=t.n(l),d=t(1283),c=t(67294),u=t(45977),m=t(816),p=t(35297),x=t(88514),g=t(50319),v=t(96491);function b(){let e=(0,d.fm)(),i=(0,d.Ei)(),t=i.mode,[o,a]=(0,c.useState)(!1),[s,l]=(0,c.useState)(!1),[b,h]=(0,c.useState)(""),f=(0,v.Pe)(),y=(0,c.useCallback)(()=>{e({type:d.Ir.RESET}),a(!1),l(!1)},[e]),[j]=(0,g.D)(x.Qp,{onCompleted:()=>{f({event:v.kM.POST_PINNED}),a(!0)},onError:e=>{h(e.message)},refetchQueries:[x.fo.GET_FEED]}),[w]=(0,g.D)(x.BP,{onCompleted:()=>{f({event:v.kM.POST_UNPINNED}),l(!0)},onError:e=>{h(e.message)},refetchQueries:[x.fo.GET_FEED]});return(0,c.useEffect)(()=>{o||t!==d.oS.PIN||j({variables:{input:{id:i.feedId}}}),s||t!==d.oS.UNPIN||w({variables:{input:{id:i.feedId}}})},[o,s,t,i,j,w]),(0,c.useEffect)(()=>{if(o&&t===d.oS.PIN||s&&t===d.oS.UNPIN||b.length){let e=setTimeout(()=>{h(""),y()},5e3);return()=>clearTimeout(e)}},[o,s,t,b,y]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"jsx-c05704330d19e2e1 notificationWrapper",children:(0,n.jsx)(u.N,{style:{bottom:"8px",right:"185px"},children:(0,n.jsxs)(p.p,{children:[o&&t===d.oS.PIN&&(0,n.jsx)(m.P,{type:{style:"success",icon:!0},closable:!0,onClose:()=>y(),children:(0,n.jsx)("span",{className:"jsx-c05704330d19e2e1",children:"Your post has been pinned."})}),s&&t===d.oS.UNPIN&&(0,n.jsx)(m.P,{type:{style:"success",icon:!0},closable:!0,onClose:()=>y(),children:(0,n.jsx)("span",{className:"jsx-c05704330d19e2e1",children:"Your post has been unpinned."})}),b&&(0,n.jsx)(m.P,{type:{style:"error",icon:!0},closable:!0,onClose:()=>y(),children:(0,n.jsx)("span",{className:"jsx-c05704330d19e2e1",children:b})})]})})}),(0,n.jsx)(r(),{id:"c05704330d19e2e1",children:".notificationWrapper.jsx-c05704330d19e2e1{position:fixed;bottom:8px;right:8px;z-index:999;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}"})]})}var h=t(50668),f=t(9151),y=t(22148),j=t(2232),w=t(2900),T=t(13301),S=t(80325),I=t(37887),N=t(49638),k=t(48683),E=t(9143),_=t(54303);let M={heading:()=>"Create your first post to share",paragraph:"This is a great time to inform family and friends the page is now live.",buttonText:"Create a Post"};function A(e){let{onClick:i}=e;return(0,n.jsx)(P,{heading:M.heading(),paragraph:M.paragraph,buttonText:M.buttonText,onClick:i})}function P(e){let{heading:i,paragraph:t,buttonText:o,onClick:a}=e;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(E.Z,{isForModal:!0,className:"ctaCard",children:(0,n.jsxs)("div",{className:r().dynamic([["de55cd2d8e1f791a",[44,-44,88,88,44]]])+" content paddingTopBottom--48",children:[(0,n.jsx)("div",{className:r().dynamic([["de55cd2d8e1f791a",[44,-44,88,88,44]]])+" iconContainer",children:(0,n.jsx)("i",{className:r().dynamic([["de55cd2d8e1f791a",[44,-44,88,88,44]]])+" fa-pen fa-light"})}),(0,n.jsx)("h1",{className:r().dynamic([["de55cd2d8e1f791a",[44,-44,88,88,44]]])+" h4 marginTop--0",children:i}),(0,n.jsx)("p",{className:r().dynamic([["de55cd2d8e1f791a",[44,-44,88,88,44]]]),children:t}),(0,n.jsx)(_.Z,{"data-qa":"create-post",onClick:a,children:o})]})}),(0,n.jsx)(r(),{id:"de55cd2d8e1f791a",dynamic:[44,-44,88,88,44],children:".ctaCard{margin-left:".concat(44,"px}.iconContainer.__jsx-style-dynamic-selector{position:absolute;top:50%;left:").concat(-44,"px;-webkit-transform:translatey(-50%);-moz-transform:translatey(-50%);-ms-transform:translatey(-50%);-o-transform:translatey(-50%);transform:translatey(-50%);width:").concat(88,"px;height:").concat(88,"px;background-color:var(--button-blue-500);color:white;-webkit-border-radius:50%;-moz-border-radius:50%;border-radius:50%;border:12px solid var(--body-bg);display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-moz-box-pack:center;-ms-flex-pack:center;justify-content:center}i.__jsx-style-dynamic-selector{font-size:24px}.content.__jsx-style-dynamic-selector{padding-left:").concat(44,"px}")})]})}A.propTypes={onClick:a().func.isRequired},a().func.isRequired,a().string.isRequired,P.propTypes={heading:a().string.isRequired,paragraph:a().string.isRequired,buttonText:a().string.isRequired,onClick:a().func.isRequired};var D=t(44441),C=t(28216),B=t(32376),L=t(91),R=t(52107),U=t(25675),z=t.n(U);function O(e){let{sortDirection:i,...t}=e,[o,a]=(0,c.useState)(window.innerWidth),s=i===S.Sr.ASCENDING;(0,c.useEffect)(()=>{let e=()=>a(window.innerWidth);return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)},[]);let l=o<=Number.parseInt(j.Bs.SMALL)?"Sort":s?"Sort by: Oldest":"Sort by: Newest";return(0,n.jsx)(k.Z,{icon:(0,n.jsx)(z(),{src:"/img/icons/filter-sort-icon.svg",alt:"",width:10,height:14}),size:R.i.SMALL,...t,children:l})}O.propTypes={sortDirection:a().oneOf(Object.values(S.Sr)).isRequired,onClick:a().func.isRequired,"data-qa":a().string.isRequired,className:a().string};let F={ALL:"All Activity",UPDATES:"Updates",TRIBUTES:"Tributes"};function Z(e){let{pushButtonState:i,options:t,...o}=e,[a,s]=i,l=(0,c.useId)(),d=e=>{switch(e){case F.UPDATES:return(0,n.jsx)(z(),{src:"/img/icons/filter-update.svg",alt:"",width:16,height:12});case F.TRIBUTES:return(0,n.jsx)(z(),{src:"/img/icons/filter-tribute.svg",alt:"",width:18.233,height:16});default:return null}};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("fieldset",{...o,className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]])+" flexbox",children:[(0,n.jsx)("span",{className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]])+" "+"pushBtn pushBtn".concat(t.findIndex(e=>e.value===a))}),t.map((e,i)=>(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("span",{className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]]),children:[(0,n.jsx)("input",{type:"radio",name:l+"name",id:"".concat(l,"-").concat(e.value),checked:e.value===a,value:e.value,onChange:e=>{s(e.target.value)},"data-qa":"".concat(o["data-qa"]).concat(i),className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]])+" sr-only"}),(0,n.jsxs)("label",{htmlFor:"".concat(l,"-").concat(e.value),"data-qa":"label-".concat(e["data-qa"]),className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]])+" center",children:[d(e.label),e.label]})]},"".concat(l,"-").concat(e.value)),i!==t.length-1&&(0,n.jsx)("div",{className:r().dynamic([["26545892ac555d7",[j.Bs.X_SMALL]]])+" spacer"})]}))]}),(0,n.jsx)(r(),{id:"26545892ac555d7",dynamic:[j.Bs.X_SMALL],children:"fieldset.__jsx-style-dynamic-selector{border:none;padding:0;-webkit-margin-start:0;-moz-margin-start:0;margin-inline-start:0;-webkit-margin-end:0;-moz-margin-end:0;margin-inline-end:0}.spacer.__jsx-style-dynamic-selector{width:12px;@media(max-width:".concat(j.Bs.X_SMALL,'){width:4px}}span.__jsx-style-dynamic-selector>input.__jsx-style-dynamic-selector+label.__jsx-style-dynamic-selector{-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;height:36px;padding:8px;-o-text-overflow:inherit;text-overflow:inherit;gap:8px;-webkit-border-radius:var(--Base,6px)var(--Base,6px)0px 0px;-moz-border-radius:var(--Base,6px)var(--Base,6px)0px 0px;border-radius:var(--Base,6px)var(--Base,6px)0px 0px;border:1px solid var(--gray-300);border-bottom:none}span.__jsx-style-dynamic-selector>input.__jsx-style-dynamic-selector+label.__jsx-style-dynamic-selector:hover{-webkit-transition:color linear var(--speed-on-hover);-moz-transition:color linear var(--speed-on-hover);-o-transition:color linear var(--speed-on-hover);transition:color linear var(--speed-on-hover);border:thin solid var(--berry-bridge-200);border-bottom:none}label.__jsx-style-dynamic-selector{color:var(--indigo);leading-trim:both;font-family:Figtree;font-size:14px;font-style:normal;font-weight:500;line-height:24px;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;color:var(--body-text)}input.__jsx-style-dynamic-selector:checked+label.__jsx-style-dynamic-selector{color:var(--berry-bridge-500);-webkit-transition:color linear var(--speed-on-hover);-moz-transition:color linear var(--speed-on-hover);-o-transition:color linear var(--speed-on-hover);transition:color linear var(--speed-on-hover);height:36px;padding:8px var(--spacing-md,16px);-webkit-box-pack:center;-webkit-justify-content:center;-moz-box-pack:center;-ms-flex-pack:center;justify-content:center;gap:8px;border:1px solid var(gray-300);position:relative}input.__jsx-style-dynamic-selector:checked+label.__jsx-style-dynamic-selector::after{background-color:var(--gray-50);content:"";position:absolute;bottom:-1px;height:1px;width:100%;z-index:2}[data-whatinput="mouse"] input.__jsx-style-dynamic-selector:focus+label.__jsx-style-dynamic-selector,[data-whatinput="touch"] input.__jsx-style-dynamic-selector:focus+label.__jsx-style-dynamic-selector{outline:none}')})]})}function q(e){let{sortDirection:i,handleNewSort:t}=e,{activeTab:o}=(0,d.Ei)(),a=(0,d.fm)(),s=[{value:"ALL",label:F.ALL},{value:S.u5.POST,label:F.UPDATES},{value:S.u5.TRIBUTE,label:F.TRIBUTES}];return(0,n.jsxs)("div",{className:r().dynamic([["640e17af8fde6a2e",[j.Bs.X_SMALL]]])+" filterSortBox",children:[(0,n.jsxs)("div",{className:r().dynamic([["640e17af8fde6a2e",[j.Bs.X_SMALL]]])+" filterSortBtns flexbox",children:[(0,n.jsx)(Z,{pushButtonState:[o,e=>a({type:d.Ir.SET_VALUE,activeTab:e})],options:s,"data-qa":"filter"}),(0,n.jsx)(O,{"data-qa":"sortBtn",sortDirection:i,onClick:t,className:"sortBtn"})]}),(0,n.jsx)("div",{className:r().dynamic([["640e17af8fde6a2e",[j.Bs.X_SMALL]]])+" dividerLine"}),(0,n.jsx)(r(),{id:"640e17af8fde6a2e",dynamic:[j.Bs.X_SMALL],children:".filterSortBox.__jsx-style-dynamic-selector{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.filterSortBtns.__jsx-style-dynamic-selector{-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-webkit-justify-content:space-between;-moz-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.sortBtn.tertiaryButton:hover{@media(max-width:".concat(j.Bs.X_SMALL,"){color:var(--btnTert-text)}}")})]})}Z.propTypes={pushButtonState:a().array.isRequired,options:a().arrayOf(a().object).isRequired,"data-qa":a().string.isRequired},q.propTypes={sortDirection:a().string.isRequired,handleNewSort:a().func.isRequired};var H=t(65874),W=t(26481),G=t(85991);let V={INITIAL:20,SUBSEQUENT:30};function Y(){var e,i,t,o,a,l,u;let m=(0,s.Ph)("siteId"),[p,g]=(0,c.useState)(S.Sr.DESCENDING),{isDirtyPosts:v}=(0,d.Ei)(),b=(0,d.fm)(),{draftsData:h}=(0,G.f)(),f=(0,C.Z)(),[y,j]=(0,c.useState)(),w=e=>{j(e),f.setIsShowing(!0)},{data:E,loading:_,fetchMore:M}=(0,I.a)(x.ug,{variables:{siteId:m,nextToken:"",sortDirection:p,limit:V.INITIAL},fetchPolicy:v?"cache-and-network":"cache-first",onCompleted(){v&&b({type:d.Ir.SET_VALUE,isDirtyPosts:!1})}}),P=null==E?void 0:null===(e=E.getSite)||void 0===e?void 0:null===(i=e.postConnection)||void 0===i?void 0:i.posts,R=null!==(l=null==E?void 0:null===(t=E.getSite)||void 0===t?void 0:null===(o=t.postConnection)||void 0===o?void 0:o.nextToken)&&void 0!==l&&l,U=null!==(u=null==E?void 0:null===(a=E.getSite)||void 0===a?void 0:a.isAuthor)&&void 0!==u&&u;return _?(0,n.jsx)("div",{className:"center marginTop--84",children:(0,n.jsx)(L.U,{children:(0,n.jsx)(N.ZP,{})})}):(null==P?void 0:P.length)?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(q,{sortDirection:p,handleNewSort:()=>{let e=p===S.Sr.ASCENDING?S.Sr.DESCENDING:S.Sr.ASCENDING;g(e)}}),(0,n.jsx)(H.Z,{tab:"posts"}),P.map((e,i)=>{var t,o;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"jsx-88be641eb2be555f postsList",children:(0,n.jsx)(T.Z,{post:e,isAuthor:null==E?void 0:null===(t=E.getSite)||void 0===t?void 0:t.isAuthor,canShare:null==E?void 0:null===(o=E.getSite)||void 0===o?void 0:o.isShareableByVisitor,sharePost:w,enablePinning:!1,showCommentField:0===i})},e.id),4===i?(0,n.jsx)(W.Z,{className:"postsList",tab:"posts"},"inlineTribute"):null]})}),R&&(0,n.jsx)("div",{className:"jsx-88be641eb2be555f center marginTop--48",children:(0,n.jsxs)(k.Z,{"data-qa":"showMoreBtn",onClick:()=>{R&&!_&&M({variables:{siteId:m,nextToken:E.getSite.postConnection.nextToken,limit:V.SUBSEQUENT,sortDirection:p}})},children:["Read more posts\xa0\xa0",(0,n.jsx)("i",{className:"jsx-88be641eb2be555f pi-chevron-down icon-6"})]})}),(0,n.jsx)(D.Z,{modalController:f,siteId:m,postDetails:y,origin:B.Y.POST}),(0,n.jsx)(r(),{id:"88be641eb2be555f",children:".postsList{padding-top:max(30px,min((100vw*.0192 + 23.1px),48px));padding-top:clamp(30px,(100vw*.0192 + 23.1px),48px);padding-bottom:12px}.postsList+.postsList{border-top:thin solid var(--gray-300)}"})]}):(0,n.jsxs)(n.Fragment,{children:[U&&(0,n.jsx)(A,{onClick:()=>{var e,i;let t=null==h?void 0:null===(e=h.getDrafts)||void 0===e?void 0:null===(i=e.drafts)||void 0===i?void 0:i[0];b({type:d.Ir.SET_VALUE,mode:d.oS.DRAFT,post:t})}}),U||(0,n.jsx)("div",{children:"No posts yet"})]})}var Q=t(68862),X=t(35879);function K(e){var i,t;let{donor:o,createdAt:a,signature:s,message:l}=e;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("header",{className:"jsx-50a7abfcbb14ee96 marginTop--0 marginBottom--12",children:[(0,n.jsx)(X.Z,{width:56,photoId:null==o?void 0:null===(i=o.photo)||void 0===i?void 0:i.publicId,legacyPath:null==o?void 0:null===(t=o.photo)||void 0===t?void 0:t.legacyPath,buttonLocation:X.e.topLeft,iconCenteredOnCircumference:!0,children:(0,n.jsx)("img",{src:"/img/icons/posts/Tribute.svg",width:32,height:32,alt:"tribute","aria-hidden":!0,className:"jsx-50a7abfcbb14ee96"})}),(0,n.jsxs)("div",{className:"jsx-50a7abfcbb14ee96 tributeTitle",children:[(0,n.jsx)("div",{className:"jsx-50a7abfcbb14ee96 tributeSignature",children:s}),(0,n.jsx)("div",{className:"jsx-50a7abfcbb14ee96 tributeDate",children:(0,Q.p6)(Q.yi.LONG,new Date(a))})]})]}),(0,n.jsx)("div",{"data-qa":"tribute-summary-message",className:"jsx-50a7abfcbb14ee96 tributeMessage",children:l}),(0,n.jsx)(r(),{id:"50a7abfcbb14ee96",children:"header.jsx-50a7abfcbb14ee96{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;gap:20px}header.jsx-50a7abfcbb14ee96>*.jsx-50a7abfcbb14ee96{-webkit-box-flex:0;-webkit-flex:0 0 auto;-moz-box-flex:0;-ms-flex:0 0 auto;flex:0 0 auto}.tributeTitle.jsx-50a7abfcbb14ee96{-webkit-box-flex:1;-webkit-flex:1 1 auto;-moz-box-flex:1;-ms-flex:1 1 auto;flex:1 1 auto}.tributeSignature.jsx-50a7abfcbb14ee96{color:var(--body-text);font-weight:600;font-size:18px;line-height:24px}.tributeDate.jsx-50a7abfcbb14ee96{color:var(--gray-500);font-size:16px}.tributeMessage.jsx-50a7abfcbb14ee96{margin-bottom:12px;font-size:18px;color:var(--body-text)}"})]})}K.propTypes={donor:a().object.isRequired,createdAt:a().string,signature:a().string,message:a().string};let $={INITIAL:20,SUBSEQUENT:30};function J(){var e,i,t,o,a;let l=(0,s.Ph)("siteId"),[d,u]=(0,c.useState)(S.Sr.DESCENDING),{data:m,loading:p,fetchMore:g}=(0,I.a)(x.L8,{variables:{siteId:l,nextToken:"",sortDirection:d,limit:$.INITIAL},fetchPolicy:"cache-first"}),v=null==m?void 0:null===(e=m.getSite)||void 0===e?void 0:null===(i=e.tributeConnection)||void 0===i?void 0:i.tributes,b=null!==(a=null==m?void 0:null===(t=m.getSite)||void 0===t?void 0:null===(o=t.tributeConnection)||void 0===o?void 0:o.nextToken)&&void 0!==a&&a;return p?(0,n.jsx)("div",{className:"center marginTop--84",children:(0,n.jsx)(L.U,{children:(0,n.jsx)(N.ZP,{})})}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(q,{sortDirection:d,handleNewSort:()=>{let e=d===S.Sr.ASCENDING?S.Sr.DESCENDING:S.Sr.ASCENDING;u(e)}}),(0,n.jsx)(H.Z,{tab:"tributes"}),v.map(e=>{let{id:i,donor:t,createdAt:o,signature:a,message:s}=e;return(0,n.jsx)("div",{className:"jsx-1db6df309693f617 list",children:(0,n.jsx)(K,{donor:t,createdAt:o,signature:a,message:s})},i)}),b&&(0,n.jsx)("div",{className:"jsx-1db6df309693f617 center marginTop--48",children:(0,n.jsxs)(k.Z,{"data-qa":"showMoreBtn",onClick:()=>{b&&!p&&g({variables:{siteId:l,nextToken:m.getSite.tributeConnection.nextToken,limit:$.SUBSEQUENT,sortDirection:d}})},children:["See more tributes\xa0\xa0",(0,n.jsx)("i",{className:"jsx-1db6df309693f617 pi-chevron-down icon-6"})]})}),(0,n.jsx)(r(),{id:"1db6df309693f617",children:".list.jsx-1db6df309693f617{padding-top:max(30px,min((100vw*.0192 + 23.1px),48px));padding-top:clamp(30px,(100vw*.0192 + 23.1px),48px)}.list.jsx-1db6df309693f617+.list.jsx-1db6df309693f617{border-top:thin solid var(--gray-300)}"})]})}var ee=t(75544),ei=t(31057),et=t(9779),en=t(46243),eo=t(67304),ea=t(81537),es=t(91992),el=t(41664),er=t.n(el);let ed={ACTIVE:"ACTIVE",INACTIVE:"INACTIVE"};function ec(e){var i,t,o,a;let{className:l="",...r}=e,d=(0,s.Ph)("siteId"),u=(0,ea.c)(ea.T.GO_FUND_ME),m=(0,ea.c)(ea.T.MEAL_TRAIN),{data:p,loading:x}=(0,eo.Z)(d),{data:v,loading:b}=(0,I.a)(es.m$,{variables:{siteId:d},fetchPolicy:"network-only"}),[h]=(0,g.D)(es.OU),[f,y]=(0,c.useState)(null),[j,w]=(0,c.useState)(null),[T,k]=(0,c.useState)(null),[E,_]=(0,c.useState)(null),[M,A]=(0,c.useState)(!1),P=(null==f?void 0:null===(i=f.campaign)||void 0===i?void 0:i.status)===ed.INACTIVE,D=null==p?void 0:null===(t=p.getSite)||void 0===t?void 0:t.isAuthor,C="".concat((0,s.G3)(s.Z6.SITE_WAYS_TO_HELP,d)),B=null!==(a=M||(null==v?void 0:null===(o=v.getSite)||void 0===o?void 0:o.hideWaysToHelpWidget))&&void 0!==a&&a;return((0,c.useEffect)(()=>{if(!x&&v){var e,i;null==v||null===(e=v.getSite)||void 0===e||null===(i=e.waysToHelps)||void 0===i||i.forEach(e=>{var i,t;e.type===S._Q.GO_FUND_ME&&((null===(i=e.item)||void 0===i?void 0:i.fundUrl)&&y(e.item),k(e.showOnSite)),e.type===S._Q.MEAL_TRAIN&&((null===(t=e.item)||void 0===t?void 0:t.shareLink)&&w(e.item),_(e.showOnSite))})}},[x,v]),(0,c.useEffect)(()=>{(null==r?void 0:r.setIsShowing)&&(null==r||r.setIsShowing((u||m)&&!D&&P&&(f||j)&&!B))},[u,m,P,f,j,B,D,r]),(u||m)&&D&&(!P||j))?x||b?(0,n.jsx)("div",{className:" center",children:(0,n.jsx)(N.ZP,{})}):f||j?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(ep,{className:l,mealTrainItem:j,showOnSite:E}),(0,n.jsx)(em,{className:l,goFundMeItem:f,showOnSite:T})]}):(0,n.jsx)(eu,{className:l,waysToHelpUrl:C,hideWaysToHelpWidget:B,handleCloseWaysToHelpWidget:()=>{A(!0),h({variables:{siteId:d,waysToHelpSettings:{hideWaysToHelpWidget:!0}}})}}):null}ec.propTypes={className:a().string,setIsShowing:a().func};let eu=e=>{let{className:i,waysToHelpUrl:t,hideWaysToHelpWidget:o,handleCloseWaysToHelpWidget:a}=e;return o?null:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" "+"".concat(i," smallViewOnly marginBottom--6"),children:[(0,n.jsxs)("div",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" row",children:[(0,n.jsx)("span",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" waysToHelpIconWrapper",children:(0,n.jsx)("i",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" fa-heart-circle-plus fa-solid"})}),(0,n.jsx)("h6",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" navHeadline",children:"Ways to get help"})]}),(0,n.jsx)("p",{className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]]),children:"A question people often ask, 'How can I help?' Your 'Ways to get help' page lets friends and family know additional ways they can provide you with support."}),(0,n.jsx)(_.Z,{className:"center",href:t,"data-qa":"gfmGetStartedButton",fullWidth:!0,children:"Get Started"}),(0,n.jsx)("button",{"data-qa":"gfmCloseButton",onClick:a,className:r().dynamic([["aef8ae19e01d5283",[j.Bs.MEDIUM]]])+" marginTop--12 button--isClear button--asLink",children:"Close"})]}),(0,n.jsx)(r(),{id:"aef8ae19e01d5283",dynamic:[j.Bs.MEDIUM],children:".row.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-webkit-justify-content:flex-start;-moz-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center}.waysToHelpIconWrapper.__jsx-style-dynamic-selector{width:36px;height:36px;-webkit-border-radius:18px;-moz-border-radius:18px;border-radius:18px;background-color:var(--berry-bridge-200);font-size:18px;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-moz-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;color:var(--color-primary);margin-right:8px}.navHeadline.__jsx-style-dynamic-selector{font-size:18px}@media(min-width:".concat(j.Bs.MEDIUM,"){.smallViewOnly.__jsx-style-dynamic-selector{display:none}}")})]})};eu.propTypes={className:a().string,waysToHelpUrl:a().string,hideWaysToHelpWidget:a().bool,handleCloseWaysToHelpWidget:a().func};let em=e=>{var i,t,o,a,s,l,d,c,u,m,p,x,g,v,b,h,f,y,w,T,S,I,N,k,E,_,M,A,P,D,C,B,L,R,U,O,F,Z,q,H,W;let{className:G,goFundMeItem:V,showOnSite:Y}=e;return Y&&V?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(i=V.campaign)||void 0===i?void 0:i.amountRaised)/(null==V?void 0:null===(t=V.campaign)||void 0===t?void 0:t.goalAmount)*100,j.Bs.MEDIUM]]])+" "+"".concat(G," smallViewOnly"),children:(0,n.jsxs)("div",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(o=V.campaign)||void 0===o?void 0:o.amountRaised)/(null==V?void 0:null===(a=V.campaign)||void 0===a?void 0:a.goalAmount)*100,j.Bs.MEDIUM]]])+" mealTrainSection marginBottom--6",children:[(0,n.jsx)(z(),{src:"/logos/goFundMeLogo.svg",alt:"",width:155,height:54,style:{width:"80%"}}),(0,n.jsxs)("p",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(s=V.campaign)||void 0===s?void 0:s.amountRaised)/(null==V?void 0:null===(l=V.campaign)||void 0===l?void 0:l.goalAmount)*100,j.Bs.MEDIUM]]])+" marginTop--6 marginBottom--6",children:[(0,n.jsxs)("span",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(d=V.campaign)||void 0===d?void 0:d.amountRaised)/(null==V?void 0:null===(c=V.campaign)||void 0===c?void 0:c.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",null==V?void 0:null===(u=V.campaign)||void 0===u?void 0:u.amountRaised]})," ","raised of"," ",(0,n.jsxs)("span",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(m=V.campaign)||void 0===m?void 0:m.amountRaised)/(null==V?void 0:null===(p=V.campaign)||void 0===p?void 0:p.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",null==V?void 0:null===(x=V.campaign)||void 0===x?void 0:x.goalAmount]})," goal"]}),(0,n.jsx)("div",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(g=V.campaign)||void 0===g?void 0:g.amountRaised)/(null==V?void 0:null===(v=V.campaign)||void 0===v?void 0:v.goalAmount)*100,j.Bs.MEDIUM]]])+" goalBarOuter",children:(0,n.jsx)("div",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(b=V.campaign)||void 0===b?void 0:b.amountRaised)/(null==V?void 0:null===(h=V.campaign)||void 0===h?void 0:h.goalAmount)*100,j.Bs.MEDIUM]]])+" goalBarInner"})}),(null==V?void 0:null===(f=V.campaign)||void 0===f?void 0:null===(y=f.recentDonations)||void 0===y?void 0:y.length)?(0,n.jsxs)("div",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(w=V.campaign)||void 0===w?void 0:w.amountRaised)/(null==V?void 0:null===(T=V.campaign)||void 0===T?void 0:T.goalAmount)*100,j.Bs.MEDIUM]]])+" donationsSection",children:[(0,n.jsx)("p",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(S=V.campaign)||void 0===S?void 0:S.amountRaised)/(null==V?void 0:null===(I=V.campaign)||void 0===I?void 0:I.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow callout",children:"Recent Donations:"}),(null==V?void 0:null===(N=V.campaign)||void 0===N?void 0:N.recentDonations.length)&&(null===(k=Object.keys(V.campaign.recentDonations[0]))||void 0===k?void 0:k.length)?(0,n.jsxs)("p",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(E=V.campaign)||void 0===E?void 0:E.amountRaised)/(null==V?void 0:null===(_=V.campaign)||void 0===_?void 0:_.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow",children:[(0,n.jsxs)("span",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(M=V.campaign)||void 0===M?void 0:M.amountRaised)/(null==V?void 0:null===(A=V.campaign)||void 0===A?void 0:A.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",V.campaign.recentDonations[0].amount]})," ","from ",V.campaign.recentDonations[0].donorName]}):null,(null==V?void 0:null===(P=V.campaign)||void 0===P?void 0:P.recentDonations.length)>1&&(null===(D=Object.keys(V.campaign.recentDonations[1]))||void 0===D?void 0:D.length)?(0,n.jsxs)("p",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(C=V.campaign)||void 0===C?void 0:C.amountRaised)/(null==V?void 0:null===(B=V.campaign)||void 0===B?void 0:B.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow",children:[(0,n.jsxs)("span",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(L=V.campaign)||void 0===L?void 0:L.amountRaised)/(null==V?void 0:null===(R=V.campaign)||void 0===R?void 0:R.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",V.campaign.recentDonations[1].amount]})," ","from ",V.campaign.recentDonations[1].donorName]}):null]}):null,(0,n.jsx)("p",{className:r().dynamic([["d22055eaef063e80",[(null==V?void 0:null===(U=V.campaign)||void 0===U?void 0:U.amountRaised)/(null==V?void 0:null===(O=V.campaign)||void 0===O?void 0:O.goalAmount)*100,j.Bs.MEDIUM]]])+" amountUpdateDiscalimer",children:"*Amount updated hourly"}),(0,n.jsx)(er(),{href:null==V?void 0:null===(F=V.campaign)||void 0===F?void 0:F.fundUrl,children:"View my GoFundMe"})]})}),(0,n.jsx)(r(),{id:"d22055eaef063e80",dynamic:[(null==V?void 0:null===(Z=V.campaign)||void 0===Z?void 0:Z.amountRaised)/(null==V?void 0:null===(q=V.campaign)||void 0===q?void 0:q.goalAmount)*100,j.Bs.MEDIUM],children:".mealTrainSection.__jsx-style-dynamic-selector{width:50%}.goalBarOuter.__jsx-style-dynamic-selector{width:100%;height:20px;border:1px solid var(--gray-300);-webkit-border-radius:30px;-moz-border-radius:30px;border-radius:30px;overflow:hidden;margin-bottom:8px}.goalBarInner.__jsx-style-dynamic-selector{height:20px;width:".concat((null==V?void 0:null===(H=V.campaign)||void 0===H?void 0:H.amountRaised)/(null==V?void 0:null===(W=V.campaign)||void 0===W?void 0:W.goalAmount)*100,"%;background-color:#02a95c}.amountUpdateDiscalimer.__jsx-style-dynamic-selector{color:var(--btnTert-text-disabled);font-style:italic;margin:0}.callout.__jsx-style-dynamic-selector{font-weight:600;font-size:16px}.donationsSection.__jsx-style-dynamic-selector{margin-top:0px;margin-bottom:0px}.donatorRow.__jsx-style-dynamic-selector{margin:0}@media(min-width:").concat(j.Bs.MEDIUM,"){.smallViewOnly.__jsx-style-dynamic-selector{display:none}}")})]}):null};em.propTypes={className:a().string,goFundMeItem:a().object,showOnSite:a().bool};let ep=e=>{let{className:i,mealTrainItem:t,showOnSite:o}=e;return o&&t?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:r().dynamic([["da7827947607dccf",[j.Bs.MEDIUM]]])+" "+"".concat(i," smallViewOnly mealTrainSection marginBottom--6"),children:[(0,n.jsx)(z(),{src:"/logos/mealTrainLogo.svg",alt:"",width:155,height:54,style:{width:"80%"}}),(0,n.jsx)(er(),{href:t.shareLink,children:"View my Meal Train"})]}),(0,n.jsx)(r(),{id:"da7827947607dccf",dynamic:[j.Bs.MEDIUM],children:".mealTrainSection.__jsx-style-dynamic-selector{width:50%;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column}@media(min-width:".concat(j.Bs.MEDIUM,"){.smallViewOnly.__jsx-style-dynamic-selector{display:none}}")})]}):null};ep.propTypes={className:a().string,mealTrainItem:a().object,showOnSite:a().bool};var ex=t(57747),eg=t(14e3),ev=t(93717);let eb={ACTIVE:"ACTIVE",INACTIVE:"INACTIVE"};function eh(e){var i,t;let{className:o="",setIsShowing:a,postItems:l={},initializedPostsShared:r={},dismissPostPreview:d,postPreview:u,loading:m,isAuthor:p,updateWaysToHelpPostLoading:x}=e,g=(0,s.Ph)("siteId"),{data:v}=(0,eo.Z)(g),b=(0,et.SE)(),h=(0,ea.c)(ea.T.GO_FUND_ME),f=l[S._Q.GO_FUND_ME],y=r[S._Q.GO_FUND_ME],j=(null==f?void 0:null===(i=f.campaign)||void 0===i?void 0:i.status)===eb.INACTIVE,w=null==f?void 0:null===(t=f.campaign)||void 0===t?void 0:t.fundUrl,I={firstName:v.getSite.firstName},k={firstName:b.firstName,id:b.id,lastName:b.lastName,photo:b.photo},E={id:"preview",createdAt:new Date,title:"".concat(I.firstName,"'s GoFundMe"),body:"<p>A GoFundMe has been created to support ".concat(I.firstName,'. To learn more and show your support, visit <a href="').concat(w,"\" target=\"_blank\" title=\"GoFundMe.\"><span style=\"color: '#495dba';\">GoFundMe.</span></a></p><Image src='/logos/goFundMeLogo.svg' alt='' width='112px' />"),author:k,commentCount:{totalDescendentCount:0}};return((0,c.useEffect)(()=>{a&&a(y===S.NS.PENDING)},[y,a]),p&&h&&y===S.NS.PENDING&&!j)?m?(0,n.jsx)(N.ZP,{}):(0,n.jsxs)(ex.xu,{className:o,position:"relative","data-qa":"go-fund-me-post-preview",children:[(0,n.jsx)(ex.xu,{pointerEvents:"none",children:(0,n.jsx)(T.Z,{post:E,isAuthor:p,canShare:!1,isPinned:!0,sharePost:()=>{},enablePinning:!0,showCommentField:!1,"data-qa":"go-fund-me-post-preview-post-summary"})}),(0,n.jsx)(ex.xu,{position:"absolute",top:0,right:"50%",transform:"translate(0,-75%)",children:(0,n.jsxs)(ex.xu,{bgColor:"white",borderRadius:"6px",boxShadow:"base",p:"16px",w:"fit-content",position:"relative",children:[(0,n.jsxs)(eg.x,{fontWeight:500,fontSize:"18px",color:"#02A95C","data-qa":"go-fund-me-post-preview-success",children:[(0,n.jsx)("i",{className:"fa-sharp fa-solid fa-circle-check"}),"Success!"]}),(0,n.jsx)(eg.x,{children:"Your GoFundMe is now created. Share the news with friends and family."}),(0,n.jsxs)(ev.k,{justifyContent:"space-between",alignItems:"baseline",children:[x?(0,n.jsx)(N.ZP,{}):(0,n.jsx)("button",{className:"marginTop--12 button--isClear button--asLink",onClick:()=>{d(S._Q.GO_FUND_ME)},disabled:x,"data-qa":"go-fund-me-post-preview-dont-post-button",children:"Don't Post"}),(0,n.jsx)(_.Z,{onClick:()=>{u(S._Q.GO_FUND_ME)},size:R.i.EXTRA_SMALL,disabled:x,"data-qa":"go-fund-me-post-preview-post-button",children:"Post"})]})]})})]}):null}function ef(e){let{className:i="",setIsShowing:t,postItems:o={},initializedPostsShared:a={},dismissPostPreview:l,postPreview:r,loading:d,isAuthor:u,updateWaysToHelpPostLoading:m}=e,p=(0,s.Ph)("siteId"),{data:x}=(0,eo.Z)(p),g=(0,et.SE)(),v=(0,ea.c)(ea.T.MEAL_TRAIN),b=o[S._Q.MEAL_TRAIN],h=a[S._Q.MEAL_TRAIN],f={firstName:x.getSite.firstName},y={firstName:g.firstName,id:g.id,lastName:g.lastName,photo:g.photo},j={id:"preview",createdAt:new Date,title:"".concat(f.firstName,"'s Meal Train"),body:"<p>A Meal Train has been created to support ".concat(f.firstName,'. To learn more and show your support, visit <a href="').concat(null==b?void 0:b.shareLink,"\" target=\"_blank\" title=\"Meal Train.\"><span style=\"color: '#495dba';\">Meal Train.</span></a></p><Image src='/logos/mealTrainLogo.svg' alt='' width='112px' />"),author:y,commentCount:{totalDescendentCount:0}};return((0,c.useEffect)(()=>{t&&t(h===S.NS.PENDING)},[h,t]),u&&v&&h===S.NS.PENDING)?d?(0,n.jsx)(N.ZP,{}):(0,n.jsxs)(ex.xu,{className:i,position:"relative","data-qa":"meal-train-post-preview",children:[(0,n.jsx)(ex.xu,{pointerEvents:"none",children:(0,n.jsx)(T.Z,{post:j,isAuthor:u,canShare:!1,isPinned:!0,sharePost:()=>{},enablePinning:!0,showCommentField:!1,"data-qa":"meal-train-post-preview-post-summary"})}),(0,n.jsx)(ex.xu,{position:"absolute",top:0,right:"50%",transform:"translate(0,-75%)",children:(0,n.jsxs)(ex.xu,{bgColor:"white",borderRadius:"6px",boxShadow:"base",p:"16px",w:"fit-content",position:"relative",children:[(0,n.jsxs)(eg.x,{fontWeight:500,fontSize:"18px",color:"#02A95C","data-qa":"meal-train-post-preview-success",children:[(0,n.jsx)("i",{className:"fa-sharp fa-solid fa-circle-check"}),"Success!"]}),(0,n.jsx)(eg.x,{children:"Your Meal Train is now created. Share the news with friends and family."}),(0,n.jsxs)(ev.k,{justifyContent:"space-between",alignItems:"baseline",children:[m?(0,n.jsx)(N.ZP,{}):(0,n.jsx)("button",{className:"marginTop--12 button--isClear button--asLink",onClick:()=>{l(S._Q.MEAL_TRAIN)},disabled:m,"data-qa":"meal-train-post-preview-dont-post-button",children:"Don't Post"}),(0,n.jsx)(_.Z,{onClick:()=>{r(S._Q.MEAL_TRAIN)},size:R.i.EXTRA_SMALL,disabled:m,"data-qa":"meal-train-post-preview-post-button",children:"Post"})]})]})})]}):null}eh.propTypes={className:a().string,setIsShowing:a().func,postItems:a().object,initializedPostsShared:a().object,dismissPostPreview:a().func,postPreview:a().func,loading:a().bool,isAuthor:a().bool,updateWaysToHelpPostLoading:a().bool},ef.propTypes={className:a().string,setIsShowing:a().func,postItems:a().object,initializedPostsShared:a().object,dismissPostPreview:a().func,postPreview:a().func,loading:a().bool,isAuthor:a().bool,updateWaysToHelpPostLoading:a().bool};var ey=t(70758);let ej={INITIAL:10,SUBSEQUENT:30};function ew(){var e,i,t,o,a,l,u,m;let p=(0,s.Ph)("siteId"),g=(0,ey.q)(),[v,b]=(0,c.useState)(S.Sr.DESCENDING),[h,f]=(0,c.useState)([]),[y,j]=(0,c.useState)(!1),[w,E]=(0,c.useState)(!1),[_,M]=(0,c.useState)(!1),P=0,{isDirtyFeed:R}=(0,d.Ei)(),U=(0,d.fm)(),z=(0,C.Z)(),[O,F]=(0,c.useState)(),Z=e=>{F(e),z.setIsShowing(!0)},{data:V,loading:Y,fetchMore:Q}=(0,I.a)(x._u,{variables:{siteId:p,nextToken:"",sortDirection:v,limit:ej.INITIAL},fetchPolicy:R?"cache-and-network":"cache-first",onCompleted(){R&&U({type:d.Ir.SET_VALUE,isDirtyFeed:!1})}}),{draftsData:X}=(0,G.f)(),$=null==V?void 0:null===(e=V.getSite)||void 0===e?void 0:null===(i=e.feedConnection)||void 0===i?void 0:i.pinnedFeeds,J=null==V?void 0:null===(t=V.getSite)||void 0===t?void 0:null===(o=t.feedConnection)||void 0===o?void 0:o.feeds,ee=null==V?void 0:null===(a=V.getSite)||void 0===a?void 0:null===(l=a.feedConnection)||void 0===l?void 0:l.totalCount,ei=($?$.length:0)+(J?J.length:0)<ee,et=null!==(m=null==V?void 0:null===(u=V.getSite)||void 0===u?void 0:u.isAuthor)&&void 0!==m&&m;return((0,c.useEffect)(()=>{if($){let e=$.slice().sort((e,i)=>{let t=new Date(e.item.createdAt).getTime(),n=new Date(i.item.createdAt).getTime();return n-t});f(e)}},[$]),Y||g.loading)?(0,n.jsx)("div",{className:"center marginTop--84",children:(0,n.jsx)(L.U,{children:(0,n.jsx)(N.ZP,{})})}):(null==J?void 0:J.length)||(null==$?void 0:$.length)?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(q,{sortDirection:v,handleNewSort:()=>{let e=v===S.Sr.ASCENDING?S.Sr.DESCENDING:S.Sr.ASCENDING;b(e)}}),(0,n.jsx)(H.Z,{tab:"feed"}),(0,n.jsx)(eh,{className:"feedList",setIsShowing:j,postItems:g.postItems,initializedPostsShared:g.initializedPostsShared,dismissPostPreview:g.dismissPostPreview,postPreview:g.postPreview,loading:g.loading,isAuthor:et}),(0,n.jsx)(ef,{className:"feedList",setIsShowing:E,postItems:g.postItems,initializedPostsShared:g.initializedPostsShared,dismissPostPreview:g.dismissPostPreview,postPreview:g.postPreview,loading:g.loading,isAuthor:et}),[...h,...J].map((e,i)=>{var t,o,a,s;let l;if(e.type===S.u5.POST)(null==e?void 0:e.isPinned)||(P+=1),l=(0,n.jsx)("div",{className:"jsx-a331cc0c0f6f74f1 feedList",children:(0,n.jsx)(T.Z,{post:e.item,isAuthor:null==V?void 0:null===(t=V.getSite)||void 0===t?void 0:t.isAuthor,canShare:null==V?void 0:null===(o=V.getSite)||void 0===o?void 0:o.isShareableByVisitor,sharePost:Z,isPinned:null==e?void 0:e.isPinned,feedId:e.id,showCommentField:1===P})},"".concat(e.id,"-postSummary-").concat(i));else if(e.type===S.u5.TRIBUTE){let{id:t,donor:o,createdAt:a,signature:s,message:r}=e.item;l=(0,n.jsx)("div",{className:"jsx-a331cc0c0f6f74f1 feedList",children:(0,n.jsx)(K,{donor:o,createdAt:a,signature:s,message:r},t)},"".concat(e.id,"-tributeSummary-").concat(i))}else e.type===S.u5.WAYS_TO_HELP_POST&&((null==e?void 0:e.isPinned)||(P+=1),l=(0,n.jsx)("div",{className:"jsx-a331cc0c0f6f74f1 feedList",children:(0,n.jsx)(en.Z,{waysToHelpPost:e.item,postItems:g.postItems,isAuthor:null==V?void 0:null===(a=V.getSite)||void 0===a?void 0:a.isAuthor,canShare:null==V?void 0:null===(s=V.getSite)||void 0===s?void 0:s.isShareableByVisitor,sharePost:Z,isPinned:null==e?void 0:e.isPinned,feedId:e.id,showCommentField:1===P})},"".concat(e.id,"-").concat(e.type,"-").concat(i)));return(0,n.jsxs)(n.Fragment,{children:[l,1===i?(0,n.jsx)(ec,{className:"feedList"}):null,4===i?(0,n.jsx)(W.Z,{className:"feedList",tab:"feed"},"".concat(e.id,"-inlineTribute-").concat(i)):null]})}),[...h,...J].length<2?(0,n.jsx)(ec,{className:"feedList"}):null,ei&&(0,n.jsx)("div",{className:"jsx-a331cc0c0f6f74f1 right marginTop--48",children:(0,n.jsx)(k.Z,{"data-qa":"showMoreBtn",className:"viewMore",icon:(0,n.jsx)("i",{className:"jsx-a331cc0c0f6f74f1 fa fa-angle-double-down"}),iconOnRight:"true",onClick:()=>{ei&&!Y&&Q({variables:{siteId:p,nextToken:V.getSite.feedConnection.nextToken,limit:ej.SUBSEQUENT,sortDirection:v},updateQuery:(e,i)=>{let{fetchMoreResult:t}=i;if(!t)return e;let n=[...e.getSite.feedConnection.pinnedFeeds,...t.getSite.feedConnection.pinnedFeeds],o=new Map;n.forEach(e=>o.set(e.id,e));let a={...t,getSite:{...t.getSite,feedConnection:{...t.getSite.feedConnection,feeds:[...e.getSite.feedConnection.feeds,...t.getSite.feedConnection.feeds],pinnedFeeds:Array.from(o.values())}}};return a}})},children:"View More"})}),(0,n.jsx)(D.Z,{modalController:z,siteId:p,postDetails:O,origin:B.Y.POST}),(0,n.jsx)(r(),{id:"a331cc0c0f6f74f1",children:".feedList{padding-top:max(24px,min((100vw*.0192 + 23.1px),36px));padding-top:clamp(24px,(100vw*.0192 + 23.1px),36px);padding-bottom:12px}.feedList+.feedList{border-top:thin solid var(--gray-300)}.tertiaryButton.viewMore{color:#495dba}.tertiaryButton.viewMore .underline{color:#495dba}.tertiaryButton.viewMore .underline:hover{color:#963862}"})]}):(0,n.jsxs)(n.Fragment,{children:[(!y||!w)&&!_&&(0,n.jsxs)(n.Fragment,{children:[et&&(0,n.jsx)(A,{onClick:()=>{var e,i;let t=null==X?void 0:null===(e=X.getDrafts)||void 0===e?void 0:null===(i=e.drafts)||void 0===i?void 0:i[0];U({type:d.Ir.SET_VALUE,mode:d.oS.DRAFT,post:t})}}),et||(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("h1",{className:"jsx-c872217fec59c4e0 h3",children:"Hi. We’re glad you are here."}),(0,n.jsx)("p",{className:"jsx-c872217fec59c4e0",children:"The author of this site is just getting started so there are no posts quite yet. Please check back later."})]})]}),(0,n.jsxs)("div",{className:"jsx-c872217fec59c4e0 marginTop--36 paddingLeftRight--48",children:[(0,n.jsx)(eh,{className:"feedList",setIsShowing:j,postItems:g.postItems,initializedPostsShared:g.initializedPostsShared,dismissPostPreview:g.dismissPostPreview,postPreview:g.postPreview,loading:g.loading,isAuthor:et}),(0,n.jsx)(ef,{className:"feedList",setIsShowing:E,postItems:g.postItems,initializedPostsShared:g.initializedPostsShared,dismissPostPreview:g.dismissPostPreview,postPreview:g.postPreview,loading:g.loading,isAuthor:et}),(0,n.jsx)(ec,{className:"feedList",setIsShowing:M})]}),(0,n.jsx)(r(),{id:"c872217fec59c4e0",children:".feedList{padding-top:max(24px,min((100vw*.0192 + 23.1px),36px));padding-top:clamp(24px,(100vw*.0192 + 23.1px),36px);padding-bottom:12px}.feedList+.feedList{border-top:thin solid var(--gray-300)}"})]})}var eT=t(45394),eS=t(69880),eI=t(11163),eN=t(33532);let ek={ACTIVE:"ACTIVE",INACTIVE:"INACTIVE"};function eE(){var e,i,t,o;let a=(0,s.Ph)("siteId"),l=(0,ea.c)(ea.T.GO_FUND_ME),r=(0,ea.c)(ea.T.MEAL_TRAIN),{data:d,loading:u}=(0,eo.Z)(a),{data:m,loading:p}=(0,I.a)(es.m$,{variables:{siteId:a},fetchPolicy:"network-only"}),[x,v]=(0,c.useState)(null),[b,h]=(0,c.useState)(null),[f,y]=(0,c.useState)(null),[j,w]=(0,c.useState)(null),[T,k]=(0,c.useState)(!1),E=(null==x?void 0:null===(e=x.campaign)||void 0===e?void 0:e.status)===ek.INACTIVE,_=null==d?void 0:null===(i=d.getSite)||void 0===i?void 0:i.isAuthor,M="".concat((0,s.G3)(s.Z6.SITE_WAYS_TO_HELP,a)),A=null!==(o=T||(null==m?void 0:null===(t=m.getSite)||void 0===t?void 0:t.hideWaysToHelpWidget))&&void 0!==o&&o,[P]=(0,g.D)(es.OU);return((0,c.useEffect)(()=>{if(!u&&m){var e,i;null==m||null===(e=m.getSite)||void 0===e||null===(i=e.waysToHelps)||void 0===i||i.forEach(e=>{var i,t;e.type===S._Q.GO_FUND_ME&&((null===(i=e.item)||void 0===i?void 0:i.fundUrl)&&v(e.item),y(e.showOnSite)),e.type===S._Q.MEAL_TRAIN&&((null===(t=e.item)||void 0===t?void 0:t.shareLink)&&h(e.item),w(e.showOnSite))})}},[u,m]),(l||r)&&_&&(!E||b))?u||p?(0,n.jsx)("div",{className:" center",children:(0,n.jsx)(N.ZP,{})}):x||b?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(eA,{mealTrainItem:b,showOnSite:j}),(0,n.jsx)(eM,{goFundMeItem:x,showOnSite:f})]}):(0,n.jsx)(e_,{waysToHelpUrl:M,hideWaysToHelpWidget:A,handleCloseWaysToHelpWidget:()=>{k(!0),P({variables:{siteId:a,waysToHelpSettings:{hideWaysToHelpWidget:!0}}})}}):null}let e_=e=>{let{waysToHelpUrl:i,hideWaysToHelpWidget:t,handleCloseWaysToHelpWidget:o}=e;return t?null:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" largeViewOnly marginTop--48",children:[(0,n.jsxs)("div",{className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" row",children:[(0,n.jsx)("span",{className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" waysToHelpIconWrapper",children:(0,n.jsx)("i",{className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" fa-heart-circle-plus fa-solid"})}),(0,n.jsx)("h6",{"data-qa":"waysToGetHelpWidgetTitle",className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" navHeadline",children:"Ways to get help"})]}),(0,n.jsx)("p",{"data-qa":"waysToGetHelpWidgetText",className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]]),children:"A question people often ask, 'How can I help?' Your 'Ways to get help' page lets friends and family know additional ways they can provide you with support."}),(0,n.jsx)(_.Z,{className:"center",href:i,"data-qa":"gfmGetStartedButton",fullWidth:!0,children:"Get Started"}),(0,n.jsx)("button",{"data-qa":"gfmCloseButton",onClick:o,className:r().dynamic([["a2a0f0638f4d08cc",[j.Bs.MEDIUM]]])+" marginTop--12 button--isClear button--asLink",children:"Close"})]}),(0,n.jsx)(r(),{id:"a2a0f0638f4d08cc",dynamic:[j.Bs.MEDIUM],children:".row.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-webkit-justify-content:flex-start;-moz-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center}.waysToHelpIconWrapper.__jsx-style-dynamic-selector{width:32px;height:32px;-webkit-border-radius:16px;-moz-border-radius:16px;border-radius:16px;background-color:var(--berry-bridge-200);font-size:16px;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-moz-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;color:var(--color-primary);margin-right:8px}.navHeadline.__jsx-style-dynamic-selector{font-size:16px}@media(max-width:".concat(j.Bs.MEDIUM,"){.largeViewOnly.__jsx-style-dynamic-selector{display:none}}")})]})};e_.propTypes={waysToHelpUrl:a().string,hideWaysToHelpWidget:a().bool,handleCloseWaysToHelpWidget:a().func};let eM=e=>{var i,t,o,a,s,l,d,c,u,m,p,x,g,v,b,h,f,y,w,T,S,I,N,k,E,_,M,A,P,D,C,B,L,R,U,O,F,Z,q;let{goFundMeItem:H,showOnSite:W}=e;return W&&H?(0,n.jsxs)("div",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(i=H.campaign)||void 0===i?void 0:i.amountRaised)/(null==H?void 0:null===(t=H.campaign)||void 0===t?void 0:t.goalAmount)*100,j.Bs.MEDIUM]]])+" largeViewOnly marginTop--48",children:[(0,n.jsx)(z(),{src:"/logos/goFundMeLogo.svg",alt:"",width:155,height:54,style:{width:"80%"}}),(0,n.jsxs)("p",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(o=H.campaign)||void 0===o?void 0:o.amountRaised)/(null==H?void 0:null===(a=H.campaign)||void 0===a?void 0:a.goalAmount)*100,j.Bs.MEDIUM]]]),children:[(0,n.jsxs)("span",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(s=H.campaign)||void 0===s?void 0:s.amountRaised)/(null==H?void 0:null===(l=H.campaign)||void 0===l?void 0:l.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",null==H?void 0:null===(d=H.campaign)||void 0===d?void 0:d.amountRaised]})," raised of"," ",(0,n.jsxs)("span",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(c=H.campaign)||void 0===c?void 0:c.amountRaised)/(null==H?void 0:null===(u=H.campaign)||void 0===u?void 0:u.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",null==H?void 0:null===(m=H.campaign)||void 0===m?void 0:m.goalAmount]})," goal"]}),(0,n.jsx)("div",{"data-qa":"siteActionsGoFundMeGoalBar",className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(p=H.campaign)||void 0===p?void 0:p.amountRaised)/(null==H?void 0:null===(x=H.campaign)||void 0===x?void 0:x.goalAmount)*100,j.Bs.MEDIUM]]])+" goalBarOuter",children:(0,n.jsx)("div",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(g=H.campaign)||void 0===g?void 0:g.amountRaised)/(null==H?void 0:null===(v=H.campaign)||void 0===v?void 0:v.goalAmount)*100,j.Bs.MEDIUM]]])+" goalBarInner"})}),(0,n.jsx)("p",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(b=H.campaign)||void 0===b?void 0:b.amountRaised)/(null==H?void 0:null===(h=H.campaign)||void 0===h?void 0:h.goalAmount)*100,j.Bs.MEDIUM]]])+" amountUpdateDiscalimer",children:"*Amount updated hourly"}),(null==H?void 0:null===(f=H.campaign)||void 0===f?void 0:null===(y=f.recentDonations)||void 0===y?void 0:y.length)?(0,n.jsxs)("div",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(w=H.campaign)||void 0===w?void 0:w.amountRaised)/(null==H?void 0:null===(T=H.campaign)||void 0===T?void 0:T.goalAmount)*100,j.Bs.MEDIUM]]])+" donationsSection",children:[(0,n.jsx)("p",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(S=H.campaign)||void 0===S?void 0:S.amountRaised)/(null==H?void 0:null===(I=H.campaign)||void 0===I?void 0:I.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow callout",children:"Recent Donations:"}),(null==H?void 0:null===(N=H.campaign)||void 0===N?void 0:N.recentDonations.length)&&(null===(k=Object.keys(H.campaign.recentDonations[0]))||void 0===k?void 0:k.length)?(0,n.jsxs)("p",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(E=H.campaign)||void 0===E?void 0:E.amountRaised)/(null==H?void 0:null===(_=H.campaign)||void 0===_?void 0:_.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow",children:[(0,n.jsxs)("span",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(M=H.campaign)||void 0===M?void 0:M.amountRaised)/(null==H?void 0:null===(A=H.campaign)||void 0===A?void 0:A.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",H.campaign.recentDonations[0].amount]})," ","from ",H.campaign.recentDonations[0].donorName]}):null,(null==H?void 0:null===(P=H.campaign)||void 0===P?void 0:P.recentDonations.length)>1&&(null===(D=Object.keys(H.campaign.recentDonations[1]))||void 0===D?void 0:D.length)?(0,n.jsxs)("p",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(C=H.campaign)||void 0===C?void 0:C.amountRaised)/(null==H?void 0:null===(B=H.campaign)||void 0===B?void 0:B.goalAmount)*100,j.Bs.MEDIUM]]])+" donatorRow",children:[(0,n.jsxs)("span",{className:r().dynamic([["a9282006e51741bb",[(null==H?void 0:null===(L=H.campaign)||void 0===L?void 0:L.amountRaised)/(null==H?void 0:null===(R=H.campaign)||void 0===R?void 0:R.goalAmount)*100,j.Bs.MEDIUM]]])+" callout",children:["$",H.campaign.recentDonations[1].amount]})," ","from ",H.campaign.recentDonations[1].donorName]}):null]}):null,(0,n.jsx)(er(),{href:null==H?void 0:null===(U=H.campaign)||void 0===U?void 0:U.fundUrl,target:"_blank","data-qa":"siteActionsViewGoFundMeCTA",children:"View my GoFundMe"}),(0,n.jsx)(r(),{id:"a9282006e51741bb",dynamic:[(null==H?void 0:null===(O=H.campaign)||void 0===O?void 0:O.amountRaised)/(null==H?void 0:null===(F=H.campaign)||void 0===F?void 0:F.goalAmount)*100,j.Bs.MEDIUM],children:".goalBarOuter.__jsx-style-dynamic-selector{width:100%;height:20px;border:1px solid var(--gray-300);-webkit-border-radius:30px;-moz-border-radius:30px;border-radius:30px;overflow:hidden}.goalBarInner.__jsx-style-dynamic-selector{height:20px;width:".concat((null==H?void 0:null===(Z=H.campaign)||void 0===Z?void 0:Z.amountRaised)/(null==H?void 0:null===(q=H.campaign)||void 0===q?void 0:q.goalAmount)*100,"%;background-color:#02a95c}.amountUpdateDiscalimer.__jsx-style-dynamic-selector{color:var(--btnTert-text-disabled);font-style:italic}.callout.__jsx-style-dynamic-selector{font-weight:600;font-size:16px}.donationsSection.__jsx-style-dynamic-selector{margin-bottom:16px}.donatorRow.__jsx-style-dynamic-selector{margin:0}@media(max-width:").concat(j.Bs.MEDIUM,"){.largeViewOnly.__jsx-style-dynamic-selector{display:none}}")})]}):null};eM.propTypes={goFundMeItem:a().object,showOnSite:a().bool};let eA=e=>{let{mealTrainItem:i,showOnSite:t}=e;return t&&i?(0,n.jsxs)("div",{className:r().dynamic([["b7875f22fa1e17d3",[j.Bs.MEDIUM]]])+" largeViewOnly flexColumn marginTop--48",children:[(0,n.jsx)(z(),{src:"/logos/mealTrainLogo.svg",alt:"",width:155,height:54,style:{width:"80%"}}),(0,n.jsx)(er(),{href:i.shareLink,target:"_blank",children:"View my Meal Train"}),(0,n.jsx)(r(),{id:"b7875f22fa1e17d3",dynamic:[j.Bs.MEDIUM],children:".flexColumn.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.goalBarOuter.__jsx-style-dynamic-selector{width:100%;height:20px;border:1px solid var(--gray-300);-webkit-border-radius:30px;-moz-border-radius:30px;border-radius:30px;overflow:hidden}.donationsSection.__jsx-style-dynamic-selector{margin-bottom:16px}.donatorRow.__jsx-style-dynamic-selector{margin:0}@media(max-width:".concat(j.Bs.MEDIUM,"){.largeViewOnly.__jsx-style-dynamic-selector{display:none}}")})]}):null};eA.propTypes={mealTrainItem:a().object,showOnSite:a().bool};var eP=t(5152),eD=t.n(eP);let eC={INITIATE:"INITIATE",PARTICIPATE:"PARTICIPATE",COMPLETE:"COMPLETE",DISMISS:"DISMISS"},eB=e=>{let i=new Date(e),t=new Date,n=new Date(t.getTime()-864e5);return i>n&&i<t},eL={PROMPT:{content:{headline:"Your journey is evolving, and so are we!",body:"We invite you to share your insights. Your insights guide us in refining resources and tools, ensuring a supportive and meaningful experience every step of the way."},actions:{button:{buttonText:"Accept Invitation",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.COMPLETE},dismiss:{dismissText:"No thanks"}},image:null,order:["image","content","actions"]},THANKS:{content:{headline:"Thank you for participating",body:"We are dedicated to ensuring no one goes through a health journey alone. We thank you for taking the time to let us know how you are feeling."},image:"/img/woman-holding-heart.svg",order:["content","image"]}},eR={PROMPT_PHASE_1:{content:{headline:"Hello",body:"Understanding your journey helps us improve the experience we provide you. Please help by answering four quick questions."},actions:{button:{buttonText:"Participate Now",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"Not at this time"}},image:"/img/people-back-shoulder-holding.svg",order:["content","actions","image"]},PROMPT_PHASE_2:{content:{headline:"Thank you for your previous input",body:"Your initial response has been invaluable. Please provide a new response to help us support you where you are."},actions:{button:{buttonText:"Participate Again",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"Maybe later"}},image:"/img/welcome-group-of-people.svg",order:["content","actions","image"]},PROMPT_PHASE_3:{content:{headline:"A soft nudge of gratitude",body:"Take a moment to revisit our brief 4 questions and let us know how you're doing. Your feedback is a powerful tool in refining our services."},actions:{button:{buttonText:"Yes - Answer Again",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"No thanks"}},image:"/img/people-back-shoulder-holding-another.svg",order:["content","actions","image"]},PROMPT_PHASE_4:{content:{headline:"Your journey is pivotal to us!",body:"You've already played a crucial role by completing our 4 questions, and now we invite you to continue influencing positive change."},actions:{button:{buttonText:"Provide My Response",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"Skip for now"}},image:"/img/arms-holding-heart.svg",order:["content","actions","image"]},PROMPT_PHASE_5:{content:{headline:"Thank you for continuing to share with us",body:"Your insights into feelings of loneliness, overwhelm, and isolation are instrumental in our commitment to improving CaringBridge."},actions:{button:{buttonText:"Accept Invitation",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"Not interested"}},image:"/img/group-holding-hearts.svg",order:["content","actions","image"]},PROMPT_PHASE_6:{content:{headline:"You have our gratitude",body:"Share your thoughts once more, and let's shape a community that truly understands and supports you."},actions:{button:{buttonText:"Share Once More",buttonTarget:"https://www.surveymonkey.com/r/RDK9BN9",buttonAction:eC.PARTICIPATE},dismiss:{dismissText:"Please do not show"}},image:"/img/group-with-trees.svg",order:["content","actions","image"]},THANKS:{content:{headline:"Thank you for participating!",body:"Your feedback is essential in helping us develop solutions that truly support you and those you care about."},image:"/img/group-holding-hearts-morepp.svg",order:["content","image"]}},eU=(e,i)=>{let{surveyType:t}=e;switch(t){case"IRB":{let{lastDismissedAt:t}=e;if(i)return eL.THANKS;if(null!==t&&eB(t))return null;return eL.PROMPT}case"UCLA":{let{status:i,surveyCompletedCount:t}=e;if("ACTIVE"==i&&t>=0&&t<7)switch(t){case 0:default:return eR.PROMPT_PHASE_1;case 1:return eR.PROMPT_PHASE_2;case 2:return eR.PROMPT_PHASE_3;case 3:return eR.PROMPT_PHASE_4;case 4:return eR.PROMPT_PHASE_5;case 5:return eR.PROMPT_PHASE_6;case 6:return eR.THANKS}return null}default:return null}};var ez=t(13990),eO=t(40607),eF=t(96702),eZ=t(22757),eq=t(69692);let eH=e=>{let{survey:i,onInteraction:t,siteId:o}=e,[a,l]=(0,c.useState)(eU(i,!1)),d=(0,eq.Z)(),u=(0,eI.useRouter)(),[m,p]=(0,c.useState)(!1),{firstName:x}=(0,et.SE)(),g=e=>{if("UCLA"===i.surveyType){if("PARTICIPATE"===e)t(i,e);else if("DISMISS"===e){setTimeout(()=>{t(i,e),p(!0)},500);return}let n=new URLSearchParams({siteId:o,surveyId:i.id,surveyPhase:i.surveyCompletedCount+1});u.push("".concat(s.Z6.SURVEYS,"?").concat(n))}else"COMPLETE"===e&&l(eU(i,!0)),"DISMISS"===e&&l(null),t(i,e)};return!a||m?null:(0,n.jsxs)(ez.Z,{minWidth:275,width:"90%",direction:"column",alignItems:"center",justifyContent:"center",textAlign:"center",className:"survey-card ".concat("UCLA"===i.surveyType?"uclaCard":""),style:{marginBottom:"10px"},children:[(0,n.jsx)(eO.e,{paddingBottom:"image"===a.order.at(-1)?0:4,children:(0,n.jsx)(eF.K,{spacing:4,direction:"column",alignItems:"center",children:a.order.map(e=>{switch(e){case"image":if("UCLA"===i.surveyType)return(0,n.jsx)("div",{style:{backgroundImage:"url(".concat(a.image,")")},className:"jsx-b186d33b98517c9f uclaCardImage"});if(!(d>j.aV.MEDIUM))return;if("UCLA"===i.surveyType)return(0,n.jsx)("div",{className:"jsx-b186d33b98517c9f uclaCardImage",children:(0,n.jsx)(z(),{src:a.image,width:210,height:145,alt:"survey"},"{surveyType}-image")});return(0,n.jsx)(eG,{image:a.image},"{surveyType}-image");case"content":return(0,n.jsx)(eV,{surveyType:i.surveyType,headline:eW(i,a,x),body:a.content.body},"{surveyType}-content");case"actions":return(0,n.jsx)(eY,{surveyType:i.surveyType,buttonData:a.actions.button,dismissData:a.actions.dismiss,handleClick:g},"{surveyType}-actions");default:return null}})})}),(0,n.jsx)(r(),{id:"b186d33b98517c9f",children:".uclaCard{-webkit-transition:opacity.5s ease-in-out,visibility.9s ease-in-out;-moz-transition:opacity.5s ease-in-out,visibility.9s ease-in-out;-o-transition:opacity.5s ease-in-out,visibility.9s ease-in-out;transition:opacity.5s ease-in-out,visibility.9s ease-in-out;padding-top:15px}.fade-out.jsx-b186d33b98517c9f{opacity:0;visibility:hidden}.uclaCardImage.jsx-b186d33b98517c9f{width:100%;max-width:200px;height:100px;min-height:100px;-webkit-background-size:contain;-moz-background-size:contain;-o-background-size:contain;background-size:contain;background-repeat:no-repeat;background-position:bottom;margin:0 auto}"})]})};eH.propTypes={survey:a().object.isRequired,onInteraction:a().func.isRequired,siteId:a().string};let eW=(e,i,t)=>{let{surveyType:n}=e;if("UCLA"===n){let{surveyCompletedCount:n}=e;if(0===n)return i.content.headline+" "+t+"!"}return i.content.headline},eG=e=>{let{image:i}=e;return i?(0,n.jsx)(z(),{src:i,alt:"survey",width:150,height:150}):(0,n.jsx)(y.Z,{variant:y.P.STACKED,width:180})};eG.propTypes={image:a().string};let eV=e=>{let{surveyType:i,headline:t,body:o}=e;return(0,n.jsxs)(eF.K,{direction:"column",children:[t&&(0,n.jsx)(eZ.X,{size:"md",fontFamily:"Figtree",fontWeight:"medium",margin:0,"data-qa":"survey-".concat(i,"-prompt-heading"),children:t}),o&&(0,n.jsx)(eg.x,{margin:0,"data-qa":"survey-".concat(i,"-prompt-body"),children:o})]})};eV.propTypes={surveyType:a().string.isRequired,headline:a().string,body:a().string};let eY=e=>{let{surveyType:i,buttonData:t,dismissData:o,handleClick:a}=e,{emailAddress:s}=(0,et.SE)();return(0,n.jsxs)(eF.K,{spacing:2,direction:"column",marginBlockStart:"4px",children:[t&&(0,n.jsx)(_.Z,{size:R.i.MEDIUM,onClick:()=>a(t.buttonAction),"data-qa":"survey-".concat(i,"-button"),..."IRB"===i&&{href:"".concat(t.buttonTarget,"?c=").concat(s),target:"_blank"},children:t.buttonText}),o&&(0,n.jsx)("button",{className:"button--asLink button--isClear displayBlock","data-qa":"survey-".concat(i,"-dismiss"),onClick:()=>a(eC.DISMISS),children:o.dismissText})]})};eY.propTypes={surveyType:a().string.isRequired,buttonData:a().object,dismissData:a().object,handleClick:a().func.isRequired};var eQ=t(1884),eX=t(6469),eK=t(5921),e$=()=>{let{activeSurveys:e,refetchSurveys:i}=(0,eQ.y)(),[t,o]=(0,c.useState)([]),[a,l]=(0,c.useState)(!1),r=(0,s.Ph)("siteId"),[d]=(0,g.D)(eX.Z,{onCompleted:i}),[u]=(0,g.D)(eX.RR,{onCompleted:i}),m=(0,ea.c)(ea.T.IRB_SURVEY),p=(0,v.Pe)(),x=(0,c.useCallback)((e,i,t)=>{p({event:v.kM.SURVEY_ACTION,siteId:r,surveyType:e,action:i,surveyPhase:t})},[p,r]),b=(0,c.useCallback)((i,t)=>{if("IRB"===i.surveyType)d({variables:{input:{id:i.id,action:t,siteId:r}}}),"COMPLETE"===t&&o(e),x(i.surveyType,t);else if("UCLA"===i.surveyType){let e="DISMISS"===t?"DISMISS":"INITIATE",n=i.surveyCompletedCount+1;x(i.surveyType,"DISMISS"===t?"DISMISS":"PARTICIPATE",n),u({variables:{input:{id:i.id,action:e,siteId:r,surveyPhase:n}}})}},[r,d,u,e,x]);return((0,c.useEffect)(()=>{e&&e.length&&!a&&(l(!0),o(e))},[e,t,a]),t&&t.length)?(0,n.jsx)(eK.J,{children:(0,n.jsx)(ex.xu,{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",children:t.map(e=>"IRB"===e.surveyType&&m||"UCLA"===e.surveyType?(0,n.jsx)(eH,{survey:e,onInteraction:b,siteId:r},e.id):null)})}):null},eJ=t(3214);let e0=eD()(()=>t.e(3563).then(t.bind(t,43563)),{loadableGenerated:{webpack:()=>[43563]}});function e1(){let{activeTab:e}=(0,d.Ei)(),i=(0,s.Ph)("siteId"),t=!!parseInt((0,s.Ph)(s.Tx.SHARE_MODAL)),o="true"===(0,s.Ph)(s.Tx.COAUTHOR_ACCEPT),a=(0,C.Z)(t),l=(0,C.Z)(o),{data:u}=(0,eo.Z)(i),{id:m}=(0,et.SE)(),p=u.getSite.patientId===m?"your":"".concat(u.getSite.firstName,"’s"),{pathname:x}=(0,eI.useRouter)(),g=(0,d.fm)();return(0,c.useEffect)(()=>{x===s.Z6.SITE_TRIBUTES&&g({type:d.Ir.SET_VALUE,activeTab:S.u5.TRIBUTE})},[g,x]),(0,n.jsxs)(eJ.Z,{children:[(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" standardLayout wider",children:[(0,n.jsx)(ei.Z,{}),(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" siteLayout marginTop--84",children:[(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" siteActionsWrapper",children:[(0,n.jsx)(ee.Z,{}),(0,n.jsx)(eE,{})]}),(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" mainContent",children:["ALL"===e&&(0,n.jsx)(ew,{}),e===S.u5.POST&&(0,n.jsx)(Y,{}),e===S.u5.TRIBUTE&&(0,n.jsx)(J,{})]}),(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" tributeThanksWidgetWrapper",children:[(0,n.jsx)(eN.Z,{}),u.getSite.isAuthor&&(0,n.jsx)(e$,{})]})]})]}),(0,n.jsx)(w.Z,{}),(0,n.jsx)(D.Z,{modalController:a,siteId:i,origin:B.Y.START,children:(0,n.jsxs)("div",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" center shareContent",children:[(0,n.jsx)(y.Z,{variant:y.P.STACKED,width:213}),(0,n.jsxs)("h1",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]])+" h5",children:[(0,eS.G8)(p)," CaringBridge has been created"]}),(0,n.jsxs)("p",{className:r().dynamic([["bf667e505ef63ce6",[j.Bs.MEDIUM,j.Bs.SMALL]]]),children:["Share ",p," CaringBridge with family and friends to keep everyone updated in a safe and private space."]})]})}),(0,n.jsx)(e0,{modalController:l,siteId:i,isAccepted:!0}),(0,n.jsx)(eT.Z,{}),(0,n.jsx)(r(),{id:"bf667e505ef63ce6",dynamic:[j.Bs.MEDIUM,j.Bs.SMALL],children:".siteLayout.__jsx-style-dynamic-selector{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column;gap:6vw}.siteLayout.__jsx-style-dynamic-selector>.__jsx-style-dynamic-selector:first-child{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center}.siteActionsWrapper.__jsx-style-dynamic-selector{-webkit-box-flex:0;-webkit-flex:0 1 auto;-moz-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;-webkit-box-ordinal-group:2;-webkit-order:1;-moz-box-ordinal-group:2;-ms-flex-order:1;order:1}.mainContent.__jsx-style-dynamic-selector{-webkit-box-flex:9;-webkit-flex:9 1 auto;-moz-box-flex:9;-ms-flex:9 1 auto;flex:9 1 auto;-webkit-box-ordinal-group:4;-webkit-order:3;-moz-box-ordinal-group:4;-ms-flex-order:3;order:3}.tributeThanksWidgetWrapper.__jsx-style-dynamic-selector{-webkit-box-flex:3;-webkit-flex:3 1 auto;-moz-box-flex:3;-ms-flex:3 1 auto;flex:3 1 auto;-webkit-box-ordinal-group:3;-webkit-order:2;-moz-box-ordinal-group:3;-ms-flex-order:2;order:2}.shareContent.__jsx-style-dynamic-selector{padding-top:44px}.shareContent.__jsx-style-dynamic-selector>.h5{margin-top:21px}@media(min-width:".concat(j.Bs.MEDIUM,"){.siteLayout.__jsx-style-dynamic-selector{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-moz-box-orient:horizontal;-moz-box-direction:normal;-ms-flex-direction:row;flex-direction:row;gap:4vw}.siteLayout.__jsx-style-dynamic-selector>.__jsx-style-dynamic-selector:first-child{-webkit-align-self:flex-start;-ms-flex-item-align:start;align-self:flex-start}.siteActionsWrapper.__jsx-style-dynamic-selector{-webkit-box-ordinal-group:2;-webkit-order:1;-moz-box-ordinal-group:2;-ms-flex-order:1;order:1;-webkit-box-flex:0;-webkit-flex:0 0 168px;-moz-box-flex:0;-ms-flex:0 0 168px;flex:0 0 168px}.mainContent.__jsx-style-dynamic-selector{-webkit-box-ordinal-group:3;-webkit-order:2;-moz-box-ordinal-group:3;-ms-flex-order:2;order:2;-webkit-box-flex:9;-webkit-flex:9 1 auto;-moz-box-flex:9;-ms-flex:9 1 auto;flex:9 1 auto}.tributeThanksWidgetWrapper.__jsx-style-dynamic-selector{-webkit-box-ordinal-group:4;-webkit-order:3;-moz-box-ordinal-group:4;-ms-flex-order:3;order:3;-webkit-box-flex:0;-webkit-flex:0 0 275px;-moz-box-flex:0;-ms-flex:0 0 275px;flex:0 0 275px}}@media(max-width:").concat(j.Bs.SMALL,"){.siteLayout.__jsx-style-dynamic-selector{gap:2vw;margin-top:0}}")})]})}var e5=t(19063),e6=t(58172),e2=t(72831),e8=t(41548),e3=!0;function e4(e){var i;let{page:t}=e,{isSignedIn:o}=(0,et.SE)(),a=(0,s.Ph)("siteId"),l=!!(0,s.Ph)(s.Tx.FOLLOW),r=(0,eI.useRouter)(),{data:u,error:m,loading:p,refetch:x}=(0,eo.Z)(a);if((0,c.useEffect)(()=>{var e;(null==u?void 0:null===(e=u.getSite)||void 0===e?void 0:e.isAuthor)&&l&&(0,s.aX)()},[l,null==u?void 0:null===(i=u.getSite)||void 0===i?void 0:i.isAuthor]),(0,c.useEffect)(()=>{if(a){let e=setTimeout(()=>{x({siteId:a})},0);return u&&clearTimeout(e),()=>clearTimeout(e)}},[u,a]),m&&!o){let e;let i=(0,s.Ph)(s.Tx.FROM_URL),t=(0,s.Ph)(s.Tx.FIRST_NAME);i===s.Z6.SEARCH&&(e={[s.Tx.FROM_URL]:i,[s.Tx.FIRST_NAME]:t}),(0,s.Eu)(void 0,!0,e);return}if(p)return null;let g=(0,e6.Jl)(null==m?void 0:m.graphQLErrors);if(g){if(g===e6.PX.ON_BLOCK_LIST||g===e6.PX.HIGH_INVITE_ONLY)return(0,n.jsx)(e2.Z,{});if(g===e6.PX.HIGH_CAN_REQUEST)return(0,n.jsx)(e8.Z,{})}return m?((0,s.Eh)((0,s.G3)(s.Z6.FOUR_04,{[s.Tx.FROM_URL]:r.pathname}),!0),null):u?(0,n.jsx)(e5.fc,{value:{page:t},children:(0,n.jsx)(f.ZN,{children:(0,n.jsxs)(d.J6,{children:[(0,n.jsx)(e1,{}),(0,n.jsx)(b,{}),(0,n.jsx)(h.Z,{})]})})}):null}e4.propTypes={page:a().object}}}]);