(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3905],{91720:function(e,t,n){"use strict";n.d(t,{cP:function(){return c},_g:function(){return l}});var i=n(809),o=n.n(i),r=n(92447),a=n(2810),s=n(24169),c=function(){var e=(0,r.Z)(o().mark((function e(t,n){var i,r,c=arguments;return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=c.length>2&&void 0!==c[2]&&c[2],r=(0,s.cN)(a.yy.TOPIC.LIST,{website_url:t,communityId:n}),e.next=4,i?(0,s.cA)(r,"GET"):(0,s.Jl)(r,"GET");case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),l=function(){var e=(0,r.Z)(o().mark((function e(t,n){var i,r=arguments;return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r.length>2&&void 0!==r[2]&&r[2],i=(0,s.cN)(a.yy.COMMENT.DETAIL,{website_url:t,id:n}),e.next=4,(0,s.cA)(i,"GET");case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}()},78849:function(e,t,n){"use strict";n.d(t,{Y:function(){return z}});var i=n(85893),o=n(26265),r=n(38347),a=n(67294),s=n(93692),c=n(48337),l=n(89708),d=n(48560),u=n(75529),p=n(89212),m=n(93178),f=n(32951),g=n(19827),h=n(11163),v=n(86896),x=n(24169),y=n(82408),b=n(13195),C=n(21124),j=n(95983),w=n(18833),O=n(43196),P=n(38987),_=n(30759),k=n(29874),S=n(89814),N=n(91256),I=n(56632),Z=N.ZP.a.withConfig({displayName:"indexstyled__StyledInfoWrapper",componentId:"sc-3929vo-0"})(["*{pointer-events:none;}"]),D=(0,N.ZP)(I.j).withConfig({displayName:"indexstyled__StyledBtn",componentId:"sc-3929vo-1"})(["&[data-size='sm']{padding-left:10px;padding-right:10px;}"]),T=N.ZP.div.withConfig({displayName:"indexstyled__StyledCardTopic",componentId:"sc-3929vo-2"})(["padding:1rem;a{text-decoration:none;}.button-icon-image{width:100%;height:100%;}","{min-width:80px;}&[data-size='medium']{display:flex;width:100%;align-items:center;margin-bottom:1rem;> ","{display:flex;flex:1;align-items:center;}.name-text{flex:1;margin-right:0.5rem;margin-left:10px;word-break:break-word;}}&[data-size='small']{display:flex;width:160px;height:160px;flex-direction:column;align-items:center;padding:0.5rem 1.3rem;text-align:center;.name-text{overflow:hidden;margin-top:12px;margin-bottom:12px;word-break:break-word;}}&[data-size='large']{.name-text{flex:1;margin-right:0.5rem;word-break:break-word;}.top-container{margin-bottom:1rem;.avatar-container{display:flex;align-items:center;text-decoration:none;.name-wrapper{display:flex;flex-direction:column;flex:1;margin-left:2rem;gap:1rem;}.info-wrapper{display:flex;flex-wrap:wrap;margin-right:0.5rem;.info-text{display:flex;&.info-post{margin-right:1.5rem;}}}}.button-container{margin-top:1rem;","{","{width:calc(100% - 60px);}}","{width:100%;}.button-create-post{flex:1;border:none;margin-left:0.5rem;}.button-more{.popover-menu__btn{margin-left:0.5rem;}}}}","{.top-container{display:flex;gap:2rem;.avatar-container{flex:1;}.button-container{margin:0;","{width:unset;}.button-create-post{display:none;}}}}}",""],D,Z,D,S.M.mbDown,D,S.M.mbUp,D,j.fn&&(0,N.iv)(["&[data-size='medium']{margin-bottom:0;",",","{height:unset;padding:8px 12px;}}&[data-size='large']{border:none;","{border-bottom:1px solid #f3f3f3;}",",","{flex:1;}.top-container{.avatar-container{margin-bottom:24px;","{margin-bottom:0;}.info-wrapper{.info-text{align-items:center;.info-text-icon{width:18px;height:18px;margin-right:6px;}}}}}.description-text{margin-bottom:24px;&.mid-position{","{display:none;}}&.bottom-position{margin-bottom:0.5rem;","{display:none;}}}}"],D,D,S.M.mbUp,D,D,S.M.mbUp,S.M.mbUp,S.M.mbDown));function M(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function E(e){for(var t=1;t0?(0,i.jsx)(E,{slidesToShow:1,align:"start",slideGap:"md",breakpoints:[{maxWidth:"sm",slideSize:"100%",slideGap:2}],withControls:!1,withIndicators:tt.length>1,styles:{indicator:{width:8,height:8,borderRadius:"50%",border:"1px solid #9495A0",boxShadow:"none",background:"#9495A0",opacity:1,"&[data-active]":{borderColor:j.fn?s.t.mbColors.pink:s.t.colors.primaryBase,background:j.fn?s.t.mbColors.pink:s.t.colors.primaryBase}}},children:tt.map((function(e,t){return(0,i.jsx)(d.n.Slide,{children:(0,i.jsx)("a",{href:e.url||"#",target:"_blank",children:(0,i.jsx)(it,{image:e.image,mobileImage:e.mobileImage})})},t)}))}):(0,i.jsx)(it,{image:j.YS}):(0,i.jsx)(m.o,{ratio:750/422,children:(0,i.jsx)("img",{src:(null===nt||void 0===nt?void 0:nt.mobileImage)||(null===nt||void 0===nt?void 0:nt.image),alt:be,loading:"lazy"})}),rt=(0,i.jsx)(I,se(se(se({},!Ce&&{dataEventCategory:j.UN,dataEventAction:"Join Community",dataEventLabel:Te+Ye}),{},{variant:Ce?"light":"primary",color:Ce?"green":void 0,onClick:function(e){e.preventDefault(),e.stopPropagation(),Be((function(){var e;(e=!Ce)?We({names:[be],ids:[Se],isJoin:e,callbackFn:me}):qe(!0)}),{action:"follow"}),null===fe||void 0===fe||fe()},className:"button-following",size:"miniHorizontal"===o?"sm":"md",loading:He,leftIcon:Ce?j.fn?(0,i.jsx)(u.Z,{size:24,color:"currentColor"}):(0,i.jsx)(p.Z,{color:"currentColor"}):j.fn?(0,i.jsx)(y.Z,{size:24}):void 0,"data-testid":Ce?"Button Unfollow":"Button Follow"},he),{},{children:Ce?ue||Me({id:"horizontal"===o?"cardCommunity.following":"cardCommunity.joined"}):de||Me({id:"cardCommunity.join"})})),at=(0,i.jsxs)(D,{className:"actions-bar",onClick:function(e){e.preventDefault(),e.stopPropagation()},children:[Ce&&(0,i.jsx)("div",{className:"button-more homepage",children:(0,i.jsx)(re.M,{url:Ye,buttonProps:{color:"transparent",size:"md",leftIcon:(0,i.jsx)(x.Z,{})},hasNotification:ze,hasJoined:Ce,onClickJoined:function(){return We({names:[be],ids:[Se],isJoin:!Ce})},onClickNotification:function(){return Be((function(){return Le((function(e){return!e}))}))},onClickShare:function(){return Ge(!0)}})}),!P&&rt]}),st=function(){return(0,i.jsxs)(H,{className:"count-item",children:[(0,i.jsxs)(B,{className:"count-label",children:[(0,c.a)(Pe),"\xa0"]}),(0,i.jsx)(W,{className:"count-value",children:Me({id:"card.topics"})})]})},ct=function(){return(0,i.jsxs)(H,{children:[j.fn&&(0,i.jsx)(A,{src:(0,w.k3)("/svg/marrybaby/note.svg"),className:"info-text-icon",alt:""}),(0,i.jsxs)(B,{children:[(0,c.a)(we),"\xa0"]}),(0,i.jsx)(W,{children:Me({id:"card.interaction",defaultMessage:"interaction"})})]})},lt=ke>=1e3&&(0,i.jsxs)(H,{className:"info-text info-text-last",children:[j.fn&&(0,i.jsx)(A,{src:(0,w.k3)("/svg/marrybaby/group.svg"),className:"info-text-icon",alt:""}),(0,i.jsxs)(B,{children:[(0,c.a)(ke),"\xa0"]}),(0,i.jsx)(W,{children:Me({id:"card.members"})})]}),dt=function(){return(0,i.jsxs)(F,{children:[(0,i.jsx)(st,{}),(0,i.jsx)(ct,{}),lt]})};return(0,i.jsxs)(C.Mv,{defaultParams:t.slug?{_joinCommunityIds:[t.id],_location:"/".concat(t.slug)}:void 0,children:[Ve&&(0,i.jsx)(l.S,{trackingCategory:j.UN,url:Fe,avatar:t.thumbnail,text:Me({id:"share.letsJoinCommunity"},{name:t.name}),onClose:function(){return Ge(!1)}}),Ue&&(0,i.jsx)(l.P,{thumbnail:j.fn?(0,w.k3)("/svg/marrybaby/logout.svg"):(0,w.k3)("/images/leave-community.png"),isThumbnailIcon:j.fn,title:Me({id:"actionPopover.leaveCommunity.title"}),description:Me({id:"actionPopover.leaveCommunity.description"}),acceptText:Me({id:"actionPopover.leaveCommunity.accept"}),cancelText:Me({id:"actionPopover.leaveCommunity.cancel"}),onAccept:function(){return We({names:[be],ids:[Se],isJoin:!1})},acceptBtnTracking:{"data-event-category":j.UN,"data-event-action":"Leave Community","data-event-label":(0,h.mg)(Ze)+Ye},onClose:function(){return qe(!1)}}),"banner"===o?(0,i.jsxs)(K,se(se(se({},Ke),ve),{},{children:[(0,i.jsxs)(M,{children:[ot,O&&(0,i.jsx)(T,{href:(0,w.k3)("/"),children:(0,i.jsx)(v.H,{})})]}),(0,i.jsxs)(Q,{children:[(0,i.jsxs)(X,{children:[$e,(0,i.jsxs)(Y,{children:[et,(0,i.jsx)(dt,{})]})]}),at]})]})):"horizontal"===o?(0,i.jsxs)(ne,se(se(se({},Ke),ve),{},{children:[(0,i.jsx)("a",se(se(se({className:"link-wrapper"},Xe),Qe),{},{children:(0,i.jsxs)(N,{children:[$e,(0,i.jsx)(X,{children:(0,i.jsxs)(Y,{children:[et,(0,i.jsx)(dt,{})]})})]})})),at]})):"vertical"===o?(0,i.jsxs)(ie,se(se(se({},Ke),ve),{},{children:[(0,i.jsxs)(Z,se(se(se({},Xe),Qe),{},{children:[(0,i.jsxs)(ee,{children:[ot,$e]}),(0,i.jsx)(Y,{className:"sm-info",children:et}),(0,i.jsx)(Y,{children:(0,i.jsx)(dt,{})})]})),(0,i.jsx)($,{children:at})]})):"miniHorizontal"===o?(0,i.jsxs)(te,se(se(se({},Ke),ve),{},{children:[(0,i.jsxs)(X,{children:[(0,i.jsx)(Z,se(se(se({},Xe),Qe),{},{children:$e})),(0,i.jsx)(Z,se(se(se({},Xe),Qe),{},{children:(0,i.jsxs)(L,{children:[et,(0,i.jsx)(st,{})]})}))]}),at]})):"miniHorizontalWithoutBtn"===o?(0,i.jsx)(te,se(se(se({},Ke),ve),{},{children:(0,i.jsx)(Z,se(se(se({},Xe),Qe),{},{children:(0,i.jsxs)(X,{children:[$e,(0,i.jsxs)(L,{children:[et,(0,i.jsx)(st,{})]})]})}))})):"onlyButton"===o?(0,i.jsx)(oe,se(se({},ve),{},{children:at})):"toggleButton"===o?Ce?pe&&pe:(0,i.jsx)(oe,se(se({},ve),{},{children:at})):(0,i.jsx)(i.Fragment,{})]})}},82408:function(e,t,n){"use strict";n.d(t,{M:function(){return y}});var i=n(85893),o=n(26265),r=n(28140),a=n(38347),s=n(67294),c=n(93692),l=n(48560),d=n(19827),u=n(11163),p=n(86896),m=n(24169),f=n(22028),g=n(95983),h=n(43196);function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function x(e){for(var t=1;t img{width:16px;height:16px;margin-top:1.5px;margin-right:8px;}}.input-click{> *{pointer-events:none;}}.tag-list{}}.submit-btn{width:100%;}"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray600}),(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray600})),ne=(0,m.ZP)(Q.n).withConfig({displayName:"indexstyled__StyledPopupFrame",componentId:"sc-4ohwi-4"})(["[data-type='confirm']{","{width:100vw;height:100%;transition:all 0.3s ease-in-out 0s;&[data-open='true']{z-index:500;}}height:80vh;overflow-y:auto;}"],r.M.mbDown),ie=m.ZP.div.withConfig({displayName:"indexstyled__StyledIsQuestion",componentId:"sc-4ohwi-5"})(["display:flex;width:100%;align-items:center;justify-content:space-between;padding:12px 16px;border-radius:8px;background:",";.switch-label{display:flex;align-items:center;gap:12px;}margin-bottom:12px;"],(function(e){return e.color})),oe=m.ZP.div.withConfig({displayName:"indexstyled__StyledError",componentId:"sc-4ohwi-6"})(["margin-bottom:12px;color:",";svg{margin-right:5px;}svg,span{vertical-align:middle;}"],b.t.colors.red700),re=(0,n(44036).k)((function(e){return{root:{}}}));function ae(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function se(e){for(var t=1;tt.name?1:e.name0&&Le&&(!ge||ge.length<=l.O_)&&!(null!==Re&&void 0!==Re&&Re.length);(0,o.useEffect)((function(){if((0,y.Z)(x().mark((function e(){var t,n,i;return x().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,Z.cA)((0,Z.cN)(I.yy.COMMUNITY.LIST,{_locale:D,pageSize:100}),"GET");case 2:n=e.sent,i=null===n||void 0===n||null===(t=n.data)||void 0===t?void 0:t.communities,Array.isArray(i)&&Ee({type:U.m.updateMultiple,payload:{dataArr:null===i||void 0===i?void 0:i.map(N.yf)}});case 5:case"end":return e.stop()}}),e)})))(),null!==a&&void 0!==a&&a.editPost){var e=a.editPost;A(e.title||""),ae((0,J.Tn)((0,J.rz)(e.description||"","edit"),e.mentions)),de({label:e.community.name,value:e.community.id}),me(e.topics||[]),he(e.photos||[]),je(!!e.isAnonymous||!1),Pe(!!e.isAskDoctor||!1),null!==e&&void 0!==e&&e.introUrl&&Ve({url:e.introUrl,banner:e.bannerImage})}else null!==a&&void 0!==a&&a.defaultCommunity&&de({label:null===a||void 0===a?void 0:a.defaultCommunity.name,value:null===a||void 0===a?void 0:a.defaultCommunity.id}),null!==a&&void 0!==a&&a.defaultTopics&&me(null===a||void 0===a?void 0:a.defaultTopics)}),[]),(0,o.useEffect)((function(){Ze(""!==B&&!/[a-zA-Z]/.test(B))}),[B]);var Ye=function(e){var t;r&&(Ee({type:U.m.updateMultiple,payload:{dataArr:[{id:e.community.id,joined:!0}],ignoreNotFound:!0}}),(null===(t=e.topics)||void 0===t?void 0:t.length)&&Ee({type:q.Q.updateMultiple,payload:{dataArr:e.topics.map((function(e){return{id:e.id,joined:!0}})),ignoreNotFound:!0}}),r((0,N.W1)(e),v));m&&m()},Xe=(0,o.useState)(!1),Qe=Xe[0],Ke=Xe[1],$e=function(){var e=(0,y.Z)(x().mark((function e(){var t,n,i,o,r,s,c,l,u,g,h,y,b,C,j,w,O,P;return x().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!p||"undefined"!==typeof Oe){e.next=3;break}return Se(!0),e.abrupt("return",!1);case 3:if(t={title:B,description:ne,communityId:(null===Le||void 0===Le?void 0:Le.id)||"",topicIds:null===pe||void 0===pe?void 0:pe.map((function(e){return String(e.id)})),previewUrl:We||void 0,locale:D,isAnonymous:Ce?1:0,isAskDoctor:Oe?1:0,introUrl:null===Je||void 0===Je?void 0:Je.url,bannerUrl:null!==Je&&void 0!==Je&&Je.url&&(null===Je||void 0===Je?void 0:Je.banner)||"",imageFiles:ge},!(0,S.isEqual)(((null===t||void 0===t?void 0:t.title)||"").normalize(),((null===d||void 0===d?void 0:d.title)||"").normalize())||!(0,S.isEqual)(((null===t||void 0===t?void 0:t.description)||"").normalize(),((null===d||void 0===d?void 0:d.description)||"").normalize())){e.next=7;break}return E({title:M({id:"createPost.popup.duplicateMessage",defaultMessage:"Duplicate message"}),message:M({id:"createPost.popup.canNotCreate",defaultMessage:"The post cannot be created"}),type:"danger"}),e.abrupt("return",!1);case 7:return Ke(!0),e.prev=8,e.next=11,Promise.all(ge.map((function(e,t){return new Promise((function(n){return setTimeout((function(){return n((0,J.tx)(e,D))}),2e3*t)}))})));case 11:return c=e.sent,he(c),e.next=15,(0,H.rJ)(se(se({},t),{},{imageFiles:c}));case 15:if(l=e.sent,!v){e.next=23;break}if(null===a||void 0===a||null===(u=a.editPost)||void 0===u||!u.id){e.next=21;break}return e.next=20,(0,H.dq)({id:a.editPost.id,locale:D,dispatch:Ee,formData:l});case 20:s=e.sent;case 21:e.next=26;break;case 23:return e.next=25,(0,H.qb)({locale:D,dispatch:Ee,formData:l});case 25:s=e.sent;case 26:g=null===(n=s)||void 0===n?void 0:n.data,h=null!==(i=s)&&void 0!==i&&i.messages&&!Array.isArray(null===(o=s)||void 0===o?void 0:o.messages)?null===(r=s)||void 0===r?void 0:r.messages.moderation:void 0,null===g||void 0===g||!g.id||null!==h&&void 0!==h&&h.type?"banned"===(null===h||void 0===h?void 0:h.type)?(E({title:M({id:"notification.post.blocked.title"}),message:M({id:"notification.post.blocked.message"}),type:"danger"}),h.words&&ye(h.words)):"suspect"===(null===h||void 0===h?void 0:h.type)?(E({title:M({id:"notification.post.suspect.title"}),message:M({id:"notification.post.suspect.message"}),type:"warning"}),m&&m()):Array.isArray(null===(y=s)||void 0===y?void 0:y.messages)&&null!==(b=s)&&void 0!==b&&null!==(C=b.messages)&&void 0!==C&&null!==(j=C.find)&&void 0!==j&&j.call(C,(function(e){var t;return!(null===e||void 0===e||null===(t=e.includes)||void 0===t||!t.call(e,"suspend"))}))?(E({message:M({id:"notification.suspend.message"}),type:"danger"}),null===m||void 0===m||m()):E({message:(Array.isArray(null===(w=s)||void 0===w?void 0:w.messages)?null===(O=s)||void 0===O||null===(P=O.messages)||void 0===P?void 0:P[0]:"")||M({id:"notification.failure"}),type:"danger"}):(E({message:M({id:"createPost.popup.success"}),type:"success"}),Ye(g),null===f||void 0===f||f(t,(0,N.W1)(g))),e.next=34;break;case 31:e.prev=31,e.t0=e.catch(8),console.error(e.t0);case 34:Ke(!1);case 35:case"end":return e.stop()}}),e,null,[[8,31]])})));return function(){return e.apply(this,arguments)}}();return(0,i.jsx)(te,{className:t,style:n,children:(0,i.jsxs)(K,{children:[(0,i.jsx)($,{className:"input-group-container","data-is-fullscreen":u,children:(0,i.jsxs)(ee,{children:[(0,i.jsx)(Y.Y,{className:"input-group",bannedWords:xe,value:B,onChange:A}),Ie&&(0,i.jsxs)(oe,{children:[(0,i.jsx)(z,{color:b.t.colors.red700,size:14}),(0,i.jsx)(O.T,{size:"p3",as:"span",color:b.t.colors.red700,children:M({id:"createPost.popup.specialCharErr",defaultMessage:"The title you entered is invalid. Titles must contain letters."})})]}),(0,i.jsx)(G.R,{heading:M({id:"createPost.popup.description"}),className:"input-group",isFullscreen:u,bannedWords:xe,value:ne,onChange:function(e){ae(e)},onPreviewUrlChange:He,onInvalidUrlsChange:Ue,onImageFilesChange:he,onSocialLinkChanged:Ve,socialLinkData:Je,imageFiles:ge}),p&&(0,i.jsxs)(ie,{color:h[String(g.primaryColor)][0],children:[(0,i.jsxs)("div",{className:"switch-label",children:[(0,i.jsx)(W,{isMarryBaby:l.fn,size:l.fn?32:24,color:g.fn.primaryColor(),className:"label-icon"}),(0,i.jsx)("span",{className:"label-txt",children:M({id:"createPost.askDoctor",defaultMessage:"Ask Doctor"})})]}),(0,i.jsx)(C.B,{value:Oe,choices:[{label:M({id:"createPost.askDoctorChoice.yes",defaultMessage:"Yes"}),value:!0,dataEventCategory:"Together",dataEventAction:"Write Post Click - Ask Doctor",dataEventLabel:(0,Z.Ow)(D,T)},{label:M({id:"createPost.askDoctorChoice.no",defaultMessage:"No"}),value:!1}],onChange:function(e){"boolean"===typeof e&&(Se(!1),Pe(e))}})]}),p&&ke&&(0,i.jsxs)(oe,{children:[(0,i.jsx)(z,{color:b.t.colors.red700,size:14}),(0,i.jsx)(O.T,{size:"p3",as:"span",color:b.t.colors.red700,children:M({id:"createPost.popup.askDoctorRequireMess",defaultMessage:"Would you like to ask a question to our doctor?"})})]}),(0,i.jsxs)("div",{className:"input-group",children:[(0,i.jsx)(O.T,{size:"p4",className:"input-group-label",children:M({id:"admin.community"})}),(0,i.jsx)(j.D,{disabled:v,options:(null===Be||void 0===Be?void 0:Be.map((function(e){return{label:e.name,value:e.id||""}})))||[],dropdownLabelTrackingAttributes:{"data-event-category":"Together","data-event-action":"Write Post Click - Choose Community","data-event-label":(0,Z.Ow)(D,T)},id:"community-picker",placeholder:M({id:"community.choose"}),value:le,onChange:function(e){de({label:e.label,value:String(e.value)}),me([])},style:{zIndex:1}})]}),(0,i.jsx)("div",{className:"input-group",children:Le&&(0,i.jsx)(X.w,{className:"tag-list",communityId:Le.id,onChange:function(e){return me(e)},selectedTopics:pe,dataEventCategory:"Together",dataEventAction:"Write Post Click - Choose Community/Topic",dataEventLabel:(0,Z.Ow)(D,T)})})]})}),(0,i.jsx)("div",{className:"form-action",children:(0,i.jsxs)(ee,{children:[(0,i.jsx)("div",{className:"input-group",children:(0,i.jsx)(P.d,{className:"swich-input-group",labelPosition:"left",name:"PostAnonymous",checked:Ce,"data-event-category":"Together","data-event-action":"Write Post Click - Incognito","data-event-label":(0,Z.Ow)(D,T),label:(0,i.jsxs)("div",{className:"switch-label",children:[(0,i.jsx)("img",{className:"label-icon",src:w.C.getAssetPath("anomyous-avatar.svg"),alt:"anomyous avatar"}),(0,i.jsx)("span",{className:"label-txt",children:M({id:"createPost.postAnonymous",defaultMessage:"Post Anonymous"})})]}),value:"Post Anonymous",onChange:function(e){return je(e.currentTarget.checked)}})}),(0,i.jsx)(c.j,{className:"submit-btn",size:"lg",onClick:function(){Ge&&$e()},disabled:!Ge||Qe,loading:Qe,"data-testid":"Button Post",children:M({id:"createPost.popup.submit"})})]})})]})})},le=function(e){var t=e.className,n=e.style,u=e.isMobile,p=e.onPostCreatedEdited,m=e.defaultCommunity,f=e.defaultTopics,h=e.onClose,v=e.editPost,x=e.lastFormData,y=e.onPostSuccess,b=(0,o.useState)(!1),C=b[0],j=b[1],w=(0,s.Z)().formatMessage,O=(0,o.useState)(!1),P=O[0],_=O[1];return(0,o.useEffect)((function(){return(0,d.nP)(!0),setTimeout((function(){_(!0)}),0),function(){return(0,d.nP)(!1)}}),[]),a.createPortal((0,i.jsx)(ne,{heading:w({id:"popup.startANewPost"}),className:"create-post-popup-frame",isOpen:P,onClose:h,hasFullscreen:!u,children:function(e){return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(ce,{className:t,style:n,onPostCreatedEdited:p,data:{defaultCommunity:m,defaultTopics:f,editPost:v},isFullscreen:e,lastFormData:x,onClose:h,onPostSuccess:y,showAskDotorOpts:-1!==l.MN.indexOf(l.Vi.NEXT_PUBLIC_DEPLOY_LOCALE||"")}),(0,i.jsx)(g,{isShow:C,setIsShow:j,thumbnail:(0,d.k3)("/svg/icon-cancel.svg"),title:w({id:"popup.createPost.confirmCloseTitle"}),description:w({id:"popup.createPost.confirmCloseDescription"}),btnGroup:(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c.j,{size:"lg",color:"secondary",onClick:function(){j(!1),null===h||void 0===h||h()},children:w({id:v?"popup.discardPostEdit":"popup.discardPost"})}),(0,i.jsx)(c.j,{size:"lg",onClick:function(){return j(!1)},children:w({id:"popup.keepEditing"})})]})})]})}}),(0,r.a)())}},65557:function(e,t,n){"use strict";n.d(t,{B:function(){return L}});var i=n(85893),o=n(26265),r=n(38347),a=n(48560),s=n(75529),c=n(86896),l=n(24169),d=n(26381),u=n(67294),p=n(15393),m=n(89708),f=n(99784),g=n(88547),h=n(11163),v=n(21124),x=n(95983),y=n(5886),b=n(44036),C=(0,b.k)((function(e){return{root:{display:"flex",flexDirection:"column",textDecoration:"none",rowGap:e.spacing.sm,"*":{pointerEvents:"none"}},content:{display:"flex",alignItems:"center",columnGap:e.spacing.sm},thumbnail:{flexShrink:0},title:{},react:{display:"flex",columnGap:"26px"},reactItem:{display:"flex",alignItems:"center",columnGap:"4px"}}})),j=function(e){var t=((0,u.useContext)(y.I).state||{}).isLoggedIn,n=e.title,o=e.slug,r=e.community,a=e.photos,c=e.likeCount,d=e.commentCount,b=e.className,j=e.topics,w=(0,h.useRouter)().locale,O=void 0===w?"vi-VN":w,P=C(void 0,{name:"HotDiscussionPost"}),_=P.classes,k=P.cx,S=(0,v.h0)(null!==r&&void 0!==r&&r.slug?{_joinCommunityIds:[r.id],_joinTopicIds:null===j||void 0===j?void 0:j.map((function(e){return e.id})),_location:"/".concat(r.slug,"/").concat(o)}:void 0).authActionWrapper,N="".concat((0,l.mg)(O)).concat(x.GW,"/").concat(null===r||void 0===r?void 0:r.slug,"/").concat(o);return(0,i.jsxs)("a",{className:k(_.root,b),href:N,title:n,"data-event-category":"Together","data-event-action":"Post Click","data-event-label":N,onClick:function(e){t||(e.preventDefault(),S((function(){return window.location.href=N})))},children:[(0,i.jsxs)("div",{className:_.content,children:[(0,i.jsx)(p.a,{avatarUrl:(null===a||void 0===a?void 0:a[0])||x.YS,size:"medium",type:"rounded",className:_.thumbnail}),(0,i.jsx)("div",{className:_.title,children:(0,i.jsx)(s.T,{as:"h5",size:"s4",weight:"bold",children:n})})]}),(0,i.jsxs)("div",{className:_.react,children:[(0,i.jsxs)("div",{className:_.reactItem,children:[(0,i.jsx)(g.Z,{size:20,color:"red"}),(0,i.jsx)(s.T,{size:"s4",children:(0,m.a)(c||0)})]}),(0,i.jsxs)("div",{className:_.reactItem,children:[(0,i.jsx)(f.Z,{size:20}),(0,i.jsx)(s.T,{size:"s4",children:(0,m.a)(d||0)})]})]})]})},w=(0,b.k)((function(e){return{root:{display:"flex",flexDirection:"column",gap:e.spacing.lg},item:{}}}));function O(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}var P=function(e){var t=e.data,n=e.className,r=w(void 0,{name:"HotDiscussion"}),a=r.classes,s=r.cx;return t.length>0?(0,i.jsx)("div",{className:s(a.root,n),children:t.map((function(e){return(0,i.jsx)(j,function(e){for(var t=1;t0?(0,i.jsx)("div",{className:s(a.root,n),children:t.map((function(e){return(0,i.jsx)(Z,function(e){for(var t=1;t0&&m.length>0?(0,i.jsx)("div",z(z({className:C(b.root,t)},f),{},{children:(0,i.jsxs)(a.T,{defaultValue:u.length>0?"popular":"discussion",styles:{root:{display:"flex",flexDirection:"column",gap:j.spacing.sm},tab:{width:"auto",paddingBottom:"4px",marginBottom:"-0.1rem"},tabsList:{borderBottom:"1px solid ".concat(j.colors.gray[2])}},children:[(0,i.jsx)("div",{style:{paddingBottom:"0.7rem",overflow:"auto",marginBottom:"-0.5rem"},children:(0,i.jsxs)(a.T.List,{children:[(0,i.jsx)(a.T.Tab,z(z({value:"popular"},{dataEventCategory:"Together",dataEventAction:"Popular Topic Click",dataEventLabel:(0,l.Ow)(h,v)}),{},{children:(0,i.jsx)(s.T,{size:"p3",weight:"bold",color:"inherit",children:x({id:"feedBlock.popularTopics.heading",defaultMessage:"Popular topics"})})})),(0,i.jsx)(a.T.Tab,z(z({value:"discussion"},{dataEventCategory:"Together",dataEventAction:"Trending Topic Click",dataEventLabel:(0,l.Ow)(h,v)}),{},{children:(0,i.jsx)(s.T,{size:"p3",weight:"bold",color:"inherit",children:x({id:"feedBlock.Hot discussion.heading",defaultMessage:"Hot discussion"})})}))]})}),(0,i.jsx)(a.T.Panel,{value:"popular",pt:"xs",children:(0,i.jsx)(M,{data:u})}),(0,i.jsx)(a.T.Panel,{value:"discussion",pt:"xs",children:(0,i.jsx)(P,{data:m})})]})})):null}},58633:function(e,t,n){"use strict";n.d(t,{g:function(){return C}});var i=n(26265),o=n(85893),r=n(38347),a=n(67294),s=n(63096),c=n(75529),l=n(48560),d=n(11163),u=n(86896),p=n(43196),m=n(91256),f=m.ZP.div.withConfig({displayName:"indexstyled__StyledWrapper",componentId:"sc-wa9av5-0"})(["&[data-is-shortcut='true']{background:",";padding:8px 16px;}&[data-is-shortcut='false']{border-radius:8px;border:1px solid ",";background:white;padding:16px;}"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.blue50}),(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.neutral100})),g=m.ZP.div.withConfig({displayName:"indexstyled__StyledInner",componentId:"sc-wa9av5-1"})(["display:flex;justify-content:space-between;gap:10px;"]),h=m.ZP.div.withConfig({displayName:"indexstyled__StyledContent",componentId:"sc-wa9av5-2"})([""]),v=m.ZP.div.withConfig({displayName:"indexstyled__StyledIcon",componentId:"sc-wa9av5-3"})([""]),x=(m.ZP.div.withConfig({displayName:"indexstyled__StyledHeading",componentId:"sc-wa9av5-4"})(["font-weight:600;font-size:16px;line-height:24px;color:",";"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray800})),m.ZP.div.withConfig({displayName:"indexstyled__StyledDesc",componentId:"sc-wa9av5-5"})(["font-size:14px;line-height:18px;"]),m.ZP.div.withConfig({displayName:"indexstyled__StyledClose",componentId:"sc-wa9av5-6"})(["position:absolute;top:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center;width:40px;"]));m.ZP.a.withConfig({displayName:"indexstyled__StyledReadMore",componentId:"sc-wa9av5-7"})(["text-decoration:none;color:",";"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.primaryBase}));function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function b(e){for(var t=1;t0)}};return document.addEventListener("scroll",e),function(){document.removeEventListener("scroll",e)}}),[D.current]),(0,a.useEffect)((function(){null===C||void 0===C||C(I)}),[I]),k?(0,o.jsx)(f,b(b({},j),{},{"data-is-shortcut":m,ref:D,children:(0,o.jsxs)(g,{children:[(0,o.jsxs)(h,{children:[!m&&(0,o.jsx)(c.T,{size:"s3",weight:"bold",children:P({id:"guideForNewMem.title",defaultMessage:"For new member"})}),(0,o.jsxs)(c.T,{size:"p4",color:"#595959",children:[P({id:"guideForNewMem.content",defaultMessage:"Our guide recommend."})," ",(0,o.jsx)(l.A,{target:"_blank",href:(0,s.g)(O)+(0,p.k3)("/guideline"),"data-event-category":"Together","data-event-action":"Guide Recommend Click","data-event-label":(0,s.g)(O)+(0,p.k3)("/guideline"),children:P({id:"guideForNewMem.readMore",defaultMessage:"Read now"})})]})]}),!m&&(0,o.jsx)(v,{children:(0,o.jsxs)("svg",{width:"50",height:"47",viewBox:"0 0 50 47",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)("circle",{cx:"30",cy:"20",r:"20",fill:"#E3F2FF"}),(0,o.jsx)("path",{d:"M13.5221 33.9187C13.4771 34.224 10.3787 31.9015 10.3787 31.9015H7.4412C5.7164 31.8818 4.0687 31.1838 2.8546 29.9585C1.64049 28.7332 0.957613 27.0792 0.953701 25.3543C0.948701 25.059 0.948701 24.7687 0.953701 24.4734C0.958034 22.7492 1.64113 21.096 2.85516 19.8717C4.06919 18.6474 5.71649 17.9504 7.44058 17.9315C9.05745 17.9265 10.669 17.9265 12.2859 17.9315C14.01 17.9504 15.6573 18.6474 16.8713 19.8717C18.0853 21.096 18.7684 22.7492 18.7728 24.4734V25.3543C18.7672 26.9471 18.1836 28.4838 17.1304 29.6788C16.0772 30.8738 14.626 31.6458 13.0465 31.8515C13.0465 31.8515 13.5937 33.458 13.5221 33.9187Z",fill:"#FF6F4D"}),(0,o.jsx)("path",{d:"M23.1606 43.4139C23.1606 43.4139 22.6556 45.6926 22.7293 46.1767C22.7765 46.4976 26.1437 44.0039 26.1437 44.0039C28.0805 44.0022 29.9473 43.28 31.3812 41.978C32.815 40.676 33.7132 38.8872 33.9011 36.9596C34.0891 35.032 33.5532 33.1033 32.3979 31.5489C31.2425 29.9945 29.5503 28.9254 27.6503 28.5496C25.7503 28.1739 23.7785 28.5183 22.1184 29.5159C20.4584 30.5134 19.2287 32.0929 18.6687 33.9469C18.1087 35.801 18.2583 37.797 19.0886 39.5468C19.9188 41.2966 21.3703 42.675 23.1606 43.4139Z",fill:"#00CB8A"}),(0,o.jsx)("path",{d:"M23.797 25.875C23.8495 26.2313 27.8695 23.1028 27.8695 23.1028L32.5913 23.0509C33.6933 23.052 34.7593 22.6588 35.5966 21.9424C36.4339 21.2259 36.9873 20.2336 37.1567 19.1447L38.0317 13.5197C38.1343 12.8609 38.0932 12.1877 37.9111 11.5463C37.7291 10.9049 37.4104 10.3105 36.9769 9.80396C36.5434 9.29738 36.0054 8.89061 35.3999 8.61159C34.7943 8.33256 34.1356 8.18789 33.4688 8.1875H23.9651C23.3219 8.18773 22.6859 8.32221 22.0976 8.58234C21.5094 8.84247 20.982 9.22252 20.5491 9.69818C20.1161 10.1738 19.7873 10.7346 19.5835 11.3447C19.3797 11.9547 19.3056 12.6006 19.3657 13.2409L19.8873 18.8622C19.9892 19.9483 20.4721 20.9634 21.2505 21.7277C22.0289 22.492 23.0526 22.9563 24.1404 23.0384C24.1404 23.0384 23.7151 25.3384 23.797 25.875Z",fill:"#45A4FF"}),(0,o.jsx)("path",{d:"M7.76003 25.2666C8.23223 25.2666 8.61503 24.8838 8.61503 24.4116C8.61503 23.9394 8.23223 23.5566 7.76003 23.5566C7.28783 23.5566 6.90503 23.9394 6.90503 24.4116C6.90503 24.8838 7.28783 25.2666 7.76003 25.2666Z",fill:"#D84023"}),(0,o.jsx)("path",{d:"M13.6092 25.2666C14.0814 25.2666 14.4642 24.8838 14.4642 24.4116C14.4642 23.9394 14.0814 23.5566 13.6092 23.5566C13.1369 23.5566 12.7542 23.9394 12.7542 24.4116C12.7542 24.8838 13.1369 25.2666 13.6092 25.2666Z",fill:"#D84023"}),(0,o.jsx)("path",{d:"M21.95 34.915C22.4461 34.915 22.8484 34.5128 22.8484 34.0166C22.8484 33.5204 22.4461 33.1182 21.95 33.1182C21.4538 33.1182 21.0515 33.5204 21.0515 34.0166C21.0515 34.5128 21.4538 34.915 21.95 34.915Z",fill:"#008C50"}),(0,o.jsx)("path",{d:"M27.3416 34.915C27.8377 34.915 28.24 34.5128 28.24 34.0166C28.24 33.5204 27.8377 33.1182 27.3416 33.1182C26.8454 33.1182 26.4431 33.5204 26.4431 34.0166C26.4431 34.5128 26.8454 34.915 27.3416 34.915Z",fill:"#008C50"}),(0,o.jsx)("path",{d:"M25.596 15.5869C25.5089 15.5875 25.4229 15.6071 25.3442 15.6444C25.2654 15.6817 25.1957 15.7357 25.14 15.8027C25.0843 15.8697 25.0439 15.948 25.0216 16.0323C24.9993 16.1165 24.9957 16.2046 25.011 16.2904C25.2116 17.4872 25.9657 18.5057 27.5991 18.5057C29.2326 18.5057 29.9863 17.4872 30.1869 16.2904C30.2022 16.2046 30.1986 16.1165 30.1763 16.0323C30.154 15.948 30.1136 15.8697 30.0579 15.8027C30.0022 15.7357 29.9325 15.6817 29.8538 15.6444C29.775 15.6071 29.6891 15.5875 29.6019 15.5869H25.596Z",fill:"white"}),(0,o.jsx)("path",{d:"M10.82 27.1594C10.479 27.1732 10.1455 27.0578 9.8859 26.8364C9.62631 26.615 9.45981 26.3038 9.41964 25.965C9.40938 25.9043 9.41118 25.8421 9.42494 25.7821C9.43869 25.7221 9.46414 25.6654 9.49981 25.6152C9.53549 25.565 9.58071 25.5223 9.63287 25.4896C9.68504 25.4569 9.74314 25.4348 9.80386 25.4245C9.86457 25.4143 9.92672 25.4161 9.98674 25.4298C10.0468 25.4436 10.1035 25.469 10.1537 25.5047C10.2039 25.5404 10.2465 25.5856 10.2792 25.6378C10.3119 25.6899 10.3341 25.748 10.3443 25.8087C10.3609 25.923 10.4182 26.0275 10.5055 26.1031C10.5928 26.1786 10.7045 26.2202 10.82 26.2202C10.9354 26.2202 11.0471 26.1786 11.1344 26.1031C11.2218 26.0275 11.279 25.923 11.2956 25.8087C11.3058 25.748 11.328 25.6899 11.3607 25.6378C11.3934 25.5856 11.4361 25.5404 11.4862 25.5047C11.5364 25.469 11.5931 25.4436 11.6532 25.4298C11.7132 25.4161 11.7753 25.4143 11.836 25.4245C11.8968 25.4348 11.9549 25.4569 12.007 25.4896C12.0592 25.5223 12.1044 25.565 12.1401 25.6152C12.1758 25.6654 12.2012 25.7221 12.215 25.7821C12.2287 25.8421 12.2305 25.9043 12.2203 25.965C12.1801 26.3038 12.0136 26.615 11.754 26.8364C11.4944 27.0578 11.1609 27.1732 10.82 27.1594Z",fill:"white"}),(0,o.jsx)("path",{d:"M23.5313 36.5244C23.4852 36.5247 23.4398 36.5351 23.3982 36.5548C23.3566 36.5745 23.3198 36.6031 23.2903 36.6385C23.2609 36.6739 23.2395 36.7154 23.2278 36.7599C23.216 36.8044 23.2141 36.851 23.2222 36.8963C23.2731 37.2225 23.439 37.5198 23.6898 37.7345C23.9406 37.9492 24.2599 38.0672 24.59 38.0672C24.9202 38.0672 25.2395 37.9492 25.4903 37.7345C25.7411 37.5198 25.9069 37.2225 25.9578 36.8963C25.9659 36.851 25.964 36.8044 25.9523 36.7599C25.9405 36.7154 25.9192 36.6739 25.8897 36.6385C25.8603 36.6031 25.8235 36.5745 25.7819 36.5548C25.7403 36.5351 25.6948 36.5247 25.6488 36.5244H23.5313Z",fill:"white"}),(0,o.jsx)("path",{d:"M26.0648 13.488C26.0009 13.488 25.9376 13.475 25.8789 13.4496C25.8203 13.4243 25.7674 13.3873 25.7235 13.3408C25.5454 13.2007 25.3311 13.114 25.1057 13.0907C24.8802 13.0675 24.6528 13.1087 24.4498 13.2095C24.4011 13.2482 24.3452 13.2768 24.2853 13.2937C24.2254 13.3106 24.1628 13.3153 24.101 13.3078C24.0393 13.3002 23.9797 13.2804 23.9257 13.2495C23.8717 13.2186 23.8243 13.1773 23.7864 13.128C23.7485 13.0787 23.7209 13.0223 23.705 12.9621C23.6891 12.902 23.6854 12.8393 23.694 12.7777C23.7026 12.7161 23.7233 12.6568 23.7551 12.6033C23.7868 12.5498 23.8289 12.5032 23.8788 12.4661C24.4176 12.0517 25.7163 11.9661 26.4057 12.6977C26.4685 12.7643 26.5104 12.8478 26.5263 12.9379C26.5422 13.028 26.5313 13.1209 26.4951 13.2049C26.4588 13.2889 26.3987 13.3605 26.3223 13.4108C26.2458 13.4611 26.1563 13.4879 26.0648 13.488Z",fill:"#2B62CD"}),(0,o.jsx)("path",{d:"M29.5057 13.4886C29.4142 13.4885 29.3247 13.4617 29.2483 13.4113C29.1719 13.361 29.1119 13.2894 29.0756 13.2054C29.0394 13.1214 29.0286 13.0286 29.0445 12.9385C29.0604 12.8484 29.1023 12.7649 29.165 12.6983C29.8544 11.9674 31.1532 12.0527 31.6922 12.4667C31.7908 12.5425 31.8553 12.6543 31.8714 12.7776C31.8876 12.9008 31.8541 13.0255 31.7783 13.1241C31.7026 13.2227 31.5908 13.2871 31.4675 13.3033C31.3442 13.3194 31.2196 13.2859 31.121 13.2102C30.9179 13.1096 30.6904 13.0685 30.465 13.0917C30.2395 13.1149 30.0252 13.2015 29.8469 13.3414C29.8031 13.3879 29.7502 13.425 29.6915 13.4503C29.6328 13.4756 29.5696 13.4886 29.5057 13.4886Z",fill:"#2B62CD"}),(0,o.jsx)("path",{d:"M13.3733 8.76784L13.0136 9.42565C12.8773 9.67502 12.6723 9.88002 12.423 10.0163L11.7667 10.376C11.7365 10.3925 11.7112 10.4168 11.6936 10.4465C11.676 10.4761 11.6667 10.5099 11.6667 10.5444C11.6667 10.5789 11.676 10.6127 11.6936 10.6423C11.7112 10.672 11.7365 10.6963 11.7667 10.7128L12.423 11.0725C12.6723 11.2088 12.8773 11.4138 13.0136 11.6631L13.3733 12.3194C13.3898 12.3497 13.4141 12.3749 13.4438 12.3925C13.4734 12.4101 13.5073 12.4194 13.5417 12.4194C13.5762 12.4194 13.61 12.4101 13.6397 12.3925C13.6693 12.3749 13.6937 12.3497 13.7102 12.3194L14.0699 11.6631C14.2064 11.4136 14.4117 11.2086 14.6614 11.0725L15.3177 10.7128C15.3479 10.6963 15.3732 10.672 15.3908 10.6423C15.4084 10.6127 15.4176 10.5789 15.4176 10.5444C15.4176 10.5099 15.4084 10.4761 15.3908 10.4465C15.3732 10.4168 15.3479 10.3925 15.3177 10.376L14.6614 10.0163C14.412 9.88002 14.207 9.67502 14.0708 9.42565L13.7111 8.76784C13.6947 8.73735 13.6703 8.71188 13.6406 8.69412C13.6108 8.67637 13.5768 8.66699 13.5422 8.66699C13.5076 8.66699 13.4736 8.67637 13.4438 8.69412C13.4141 8.71188 13.3897 8.73735 13.3733 8.76784Z",fill:"#FFCB37"}),(0,o.jsx)("path",{d:"M9.33188 13.7253L9.12157 14.11C9.04156 14.2551 8.92175 14.3744 8.77626 14.4537L8.39157 14.6641C8.37391 14.6738 8.35918 14.688 8.34892 14.7054C8.33866 14.7227 8.33325 14.7425 8.33325 14.7627C8.33325 14.7828 8.33866 14.8026 8.34892 14.8199C8.35918 14.8373 8.37391 14.8515 8.39157 14.8612L8.77626 15.0716C8.92206 15.1514 9.0419 15.2713 9.12157 15.4172L9.33188 15.8016C9.34159 15.8192 9.35586 15.834 9.3732 15.8442C9.39055 15.8545 9.41033 15.8599 9.43048 15.8599C9.45063 15.8599 9.47041 15.8545 9.48775 15.8442C9.5051 15.834 9.51937 15.8192 9.52907 15.8016L9.73938 15.4172C9.81908 15.2712 9.93905 15.1513 10.085 15.0716L10.4694 14.8612C10.487 14.8515 10.5018 14.8373 10.512 14.8199C10.5223 14.8026 10.5277 14.7828 10.5277 14.7627C10.5277 14.7425 10.5223 14.7227 10.512 14.7054C10.5018 14.688 10.487 14.6738 10.4694 14.6641L10.085 14.4537C9.93936 14.3745 9.81943 14.2552 9.73938 14.11L9.52907 13.7253C9.51937 13.7077 9.5051 13.6929 9.48775 13.6827C9.47041 13.6724 9.45063 13.667 9.43048 13.667C9.41033 13.667 9.39055 13.6724 9.3732 13.6827C9.35586 13.6929 9.34159 13.7077 9.33188 13.7253Z",fill:"#FFCB37"}),(0,o.jsx)("path",{d:"M36.3699 40.4132L36.0814 40.9407C35.9721 41.1407 35.8076 41.3051 35.6077 41.4144L35.0802 41.7029C35.0559 41.7161 35.0357 41.7356 35.0216 41.7594C35.0074 41.7831 35 41.8102 35 41.8379C35 41.8655 35.0074 41.8926 35.0216 41.9164C35.0357 41.9401 35.0559 41.9596 35.0802 41.9729L35.6077 42.2613C35.8077 42.3708 35.9721 42.5353 36.0814 42.7354L36.3699 43.2626C36.3831 43.2868 36.4026 43.3071 36.4264 43.3212C36.4501 43.3353 36.4772 43.3427 36.5049 43.3427C36.5325 43.3427 36.5596 43.3353 36.5834 43.3212C36.6071 43.3071 36.6266 43.2868 36.6399 43.2626L36.9283 42.7354C37.0378 42.5353 37.2023 42.3708 37.4024 42.2613L37.9295 41.9729C37.9538 41.9596 37.9741 41.9401 37.9882 41.9164C38.0023 41.8926 38.0097 41.8655 38.0097 41.8379C38.0097 41.8102 38.0023 41.7831 37.9882 41.7594C37.9741 41.7356 37.9538 41.7161 37.9295 41.7029L37.4024 41.4144C37.2023 41.3051 37.0378 41.1407 36.9283 40.9407L36.6399 40.4132C36.6266 40.3889 36.6071 40.3687 36.5834 40.3546C36.5596 40.3405 36.5325 40.333 36.5049 40.333C36.4772 40.333 36.4501 40.3405 36.4264 40.3546C36.4026 40.3687 36.3831 40.3889 36.3699 40.4132Z",fill:"#FFCB37"}),(0,o.jsx)("path",{d:"M11.157 37.0677L10.9133 37.513C10.8208 37.682 10.6819 37.8209 10.5129 37.9133L10.0676 38.1567C10.0472 38.1679 10.0301 38.1844 10.0182 38.2045C10.0063 38.2246 10 38.2475 10 38.2708C10 38.2941 10.0063 38.317 10.0182 38.3371C10.0301 38.3572 10.0472 38.3737 10.0676 38.3849L10.5129 38.6283C10.6819 38.7207 10.8208 38.8596 10.9133 39.0286L11.157 39.4739C11.1682 39.4944 11.1846 39.5115 11.2047 39.5234C11.2247 39.5353 11.2476 39.5416 11.2709 39.5416C11.2942 39.5416 11.3171 39.5353 11.3372 39.5234C11.3572 39.5115 11.3737 39.4944 11.3848 39.4739L11.6286 39.0286C11.7209 38.8597 11.8597 38.7207 12.0286 38.6283L12.4742 38.3849C12.4947 38.3737 12.5117 38.3572 12.5236 38.3371C12.5355 38.317 12.5418 38.2941 12.5418 38.2708C12.5418 38.2475 12.5355 38.2246 12.5236 38.2045C12.5117 38.1844 12.4947 38.1679 12.4742 38.1567L12.0286 37.9133C11.8597 37.8209 11.7209 37.682 11.6286 37.513L11.3848 37.0677C11.3737 37.0472 11.3572 37.0301 11.3372 37.0182C11.3171 37.0063 11.2942 37 11.2709 37C11.2476 37 11.2247 37.0063 11.2047 37.0182C11.1846 37.0301 11.1682 37.0472 11.157 37.0677Z",fill:"#FFB521"})]})}),m&&(0,o.jsx)(x,{onClick:function(){S(!1),null===y||void 0===y||y()},children:(0,o.jsx)("svg",{width:12,height:12,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)("path",{d:"M1.99007 0.990181C1.79114 0.990233 1.59674 1.04961 1.43173 1.16073C1.26672 1.27184 1.1386 1.42964 1.06374 1.61395C0.988886 1.79826 0.970697 2.00071 1.0115 2.19542C1.05231 2.39012 1.15025 2.56823 1.29281 2.70698L6.58578 7.99995L1.29281 13.2929C1.19684 13.3851 1.12021 13.4954 1.06743 13.6176C1.01464 13.7397 0.986757 13.8711 0.985403 14.0042C0.98405 14.1372 1.00926 14.2692 1.05954 14.3924C1.10983 14.5155 1.1842 14.6274 1.27827 14.7215C1.37235 14.8156 1.48426 14.89 1.60743 14.9402C1.73061 14.9905 1.86259 15.0157 1.99563 15.0144C2.12867 15.013 2.2601 14.9851 2.38223 14.9324C2.50436 14.8796 2.61473 14.803 2.70687 14.707L7.99984 9.41401L13.2928 14.707C13.385 14.803 13.4953 14.8796 13.6175 14.9324C13.7396 14.9851 13.871 15.013 14.0041 15.0144C14.1371 15.0157 14.2691 14.9905 14.3922 14.9402C14.5154 14.89 14.6273 14.8156 14.7214 14.7215C14.8155 14.6274 14.8899 14.5155 14.9401 14.3924C14.9904 14.2692 15.0156 14.1372 15.0143 14.0042C15.0129 13.8711 14.985 13.7397 14.9323 13.6176C14.8795 13.4954 14.8028 13.3851 14.7069 13.2929L9.4139 7.99995L14.7069 2.70698C14.8514 2.56652 14.9501 2.38567 14.99 2.18815C15.03 1.99063 15.0093 1.78565 14.9308 1.60007C14.8523 1.41448 14.7195 1.25695 14.5499 1.14812C14.3803 1.03929 14.1817 0.98424 13.9803 0.990181C13.7205 0.997922 13.4739 1.1065 13.2928 1.29292L7.99984 6.58589L2.70687 1.29292C2.61368 1.19712 2.50224 1.12098 2.37912 1.06898C2.25601 1.01698 2.12372 0.990189 1.99007 0.990181Z",fill:"#595959"})})})]})})):null}},22028:function(e,t,n){"use strict";n.d(t,{m:function(){return u}});var i=n(85893),o=n(67294),r=n(48337),a=n(46784),s=n(75529),c=n(91256),l=n(95983),d=(c.ZP.div.withConfig({displayName:"indexstyled__StyledPopoverMenu",componentId:"sc-967pc3-0"})(["position:relative;display:content;.popover-menu__btn{> span{width:100%;height:100%;> img{width:100%;height:100%;}}}.popover-menu__content{position:absolute;z-index:10;width:320px;padding:8px;border:none;background:#fff;border-radius:8px;box-shadow:3px 3px 20px rgba(0,0,0,0.1);&::before{position:absolute;width:16px;height:8px;background:#fff;content:'';}&.--position{&-top{bottom:calc(100% + 8px);&.--align{&-start{left:0;&::before{top:100%;left:16px;clip-path:polygon(0 0,50% 100%,100% 0);}}&-end{left:100%;transform:translateX(calc(-100% + 1rem));&::before{top:100%;right:16px;clip-path:polygon(0 0,50% 100%,100% 0);}}}}&-right{left:calc(100% + 8px);&.--align{&-start{top:0;&::before{top:16px;left:0;width:8px;height:16px;clip-path:polygon(0 50%,100% 0%,100% 100%);transform:translateX(-100%);}}&-end{top:100%;transform:translateX(calc(-100% + 1rem));&::before{bottom:16px;left:0;width:8px;height:16px;clip-path:polygon(0 50%,100% 0%,100% 100%);transform:translateX(-100%);}}}}&-bottom{top:calc(100% + 8px);&.--align{&-start{left:0;&::before{bottom:100%;left:16px;clip-path:polygon(50% 0%,0% 100%,100% 100%);}}&-end{left:100%;transform:translateX(calc(-100% + 1rem));&::before{right:16px;bottom:100%;clip-path:polygon(50% 0%,0% 100%,100% 100%);}}}}&-left{left:-8px;transform:translateX(-100%);&.--align{&-start{top:0;&::before{top:16px;left:100%;width:8px;height:16px;clip-path:polygon(0 0%,100% 50%,0% 100%);transform:translateX(0);}}&-end{bottom:0;&::before{bottom:16px;left:100%;width:8px;height:16px;clip-path:polygon(0 0%,100% 50%,0% 100%);transform:translateX(0);}}}}}}",""],l.fn?(0,c.iv)([".popover-menu__content{padding:0;border-radius:12px;}"]):""),c.ZP.div.withConfig({displayName:"indexstyled__StyledTree",componentId:"sc-967pc3-1"})(["display:flex;flex-direction:column;cursor:default;.__header{position:relative;display:flex;align-items:center;justify-content:center;padding:1rem 0;margin-bottom:8px;.__back-btn{position:absolute;top:50%;left:8px;width:16px;height:16px;cursor:pointer;transform:translateY(-50%);}}.tree-text-description{padding-right:8px;padding-left:8px;margin-top:-8px;margin-bottom:8px;font-size:14px;font-weight:400;line-height:22px;text-align:left;}.__content{overflow:auto;flex:1;}.__list{.__item{position:relative;&.bold-item{font-weight:700;}&:last-child{.__btn{margin-bottom:0;}}.__btn{position:relative;display:flex;width:100%;height:40px;align-items:center;padding:0 1rem;border:none;margin-bottom:8px;color:",";cursor:pointer;text-align:left;transition:background 0.3s;*{pointer-events:none;}&.--checked{color:",";pointer-events:none;}&:hover{background:",";}.__icon{width:16px;height:16px;margin-right:0.4rem;}& > span{position:relative;& > img{width:16px;height:16px;margin-right:0.4rem;}}}.__toggle{position:absolute;top:50%;right:16px;width:16px;height:16px;pointer-events:none;transform:translateY(-50%);}}}",""],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray800}),(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray500}),(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray100}),l.fn?(0,c.iv)([".__header{padding:1rem;}.tree-text-description{padding:0 1rem;}.__list{.__item{&:first-child{.__btn{border-top-left-radius:12px;border-top-right-radius:12px;}}&:last-child{.__btn{border-bottom-left-radius:12px;border-bottom-right-radius:12px;}}.__btn{height:unset;padding:1rem;margin-bottom:0;&:hover{background:",";}}}}"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.mbColors.lightPink})):"")),u=(c.ZP.div.withConfig({displayName:"indexstyled__StyledAction",componentId:"sc-967pc3-2"})(["display:flex;flex-direction:column;cursor:default;.action__content{overflow:auto;flex:1;}.action__list{.action__item{position:relative;.action__btn{width:100%;height:40px;padding:0 1rem;border:none;border-radius:4px;color:",";transition:background 0.3s;&:hover{background:",";}& > span{position:relative;display:flex;align-items:center;& > img{width:16px;height:16px;margin-right:0.4rem;}}*{pointer-events:none;}}.action__toggle{position:absolute;top:50%;right:16px;width:16px;height:16px;pointer-events:none;transform:translateY(-50%);}}}",""],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray800}),(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.colors.gray100}),l.fn?(0,c.iv)([".action__list{.action__item{&:first-child{.action__btn{border-top-left-radius:12px;border-top-right-radius:12px;}}&:last-child{.action__btn{border-bottom-left-radius:12px;border-bottom-right-radius:12px;}}.action__btn{height:unset;padding:1rem;margin-bottom:0;font-weight:normal;&:hover{background:",";}}}}"],(function(e){var t;return null===(t=e.theme)||void 0===t?void 0:t.mbColors.lightPink})):""),function(e){var t,n=e.data,c=e.setShow,l=(0,o.useState)(""),u=l[0],p=l[1],m=(0,o.useMemo)((function(){return n&&function(e,t){var n=t.split("."),i=e;return n.forEach((function(e){var t,n,o,r;e&&i&&"list"===(null===(t=i)||void 0===t?void 0:t.type)&&(i=null===(n=i)||void 0===n||null===(o=n.list)||void 0===o||null===(r=o[Number(e)])||void 0===r?void 0:r.subTree)})),i}(n,u)}),[n,u]);if(!n)return null;if(!m)return null;return(0,i.jsxs)(d,{children:[m.isShowheader?(0,i.jsxs)("div",{className:"__header",children:[u?(0,i.jsx)("img",{alt:"back",className:"__back-btn",src:"./svg/icon-chevron-left-dark.svg",onClick:function(){return p((function(e){return e.split(".").slice(0,-1).join(".")}))}}):null,m.title?(0,i.jsx)(r.H,{className:"__title",tag:"h6",children:m.title}):null]}):null,m.description?(0,i.jsx)(s.T,{className:"tree-text-description",color:a.t.colors.gray600,size:"p3",children:m.description}):null,(0,i.jsxs)("div",{className:"__content",children:["jsx"===m.type?null===m||void 0===m||null===(t=m.jsxRenderer)||void 0===t?void 0:t.call(m,c):null,"list"===m.type?(0,i.jsx)("ul",{className:"__list",children:Array.isArray(m.list)?m.list.map((function(e,t){return(0,i.jsxs)("li",{style:e.style,className:"__item ".concat(e.className),children:[(0,i.jsxs)("div",{className:"__btn ".concat(e.selected?"--checked":""),onClick:function(){return function(e,t){var n=t.subTree,i=t.onClick,o=void 0===i?function(){return null}:i;o&&o(),n?p((function(t){return t.split(".").concat(String(e)).join(".")})):c&&c(!1)}(t,e)},"data-event-category":e.dataEventCategory,"data-event-action":e.dataEventAction,"data-event-label":e.dataEventLabel,children:[e.icon&&(0,i.jsx)("img",{className:"__icon",src:e.icon,alt:e.label}),(0,i.jsx)("span",{children:e.label})]}),e.subTree?(0,i.jsx)("img",{className:"__toggle",src:"./svg/icon-chevron-right-dark.svg",alt:"check"}):null,e.selected?(0,i.jsx)("img",{className:"__toggle",src:"./svg/icon-check-gray.svg",alt:"selected"}):null]},t)})):null}):null]})]})})},24211:function(e,t,n){"use strict";n.d(t,{I:function(){return _}});var i=n(85893),o=n(28140),r=n(26265),a=n(38347),s=n(67294),c=n(48560),l=n(91938),d=n(96486),u=n(24169);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function m(e){for(var t=1;t0?(z||[]).filter((function(e){return 0===(null===e||void 0===e?void 0:e.dueDateMonth)})).map((function(e,t){return(0,i.jsx)(h,{bg:B.fn.primaryColor(),"data-is-selected":w&&e.id===(null===j||void 0===j?void 0:j.id),children:(0,i.jsx)(v,{className:"card-topic",size:"medium",topic:e,headingStyle:{fontSize:14,lineHeight:"18px"},buttonStyle:{fontSize:12},avatarSize:b,checkCommunityOutside:!0,showJoinState:!0})},t)})):(0,i.jsx)(x,{children:_({id:"topicCardList.notFound",defaultMessage:"Topics not found"})})})})})}},3905:function(e,t,n){"use strict";n.d(t,{x:function(){return ce}});var i=n(85893),o=n(26265),r=n(67294),a=n(63096),s=n(92351),c=n(15393),l=n(94412),d=n(46784),u=n(72090),p=n(36808),m=n.n(p),f=n(9008),g=n(24169),h=n(48560),v=n(91527),x=n(26381),y=n(50572),b=n(5886),C=n(44036),j=n(2566),w=(0,C.k)((function(e){return{root:{position:"fixed",bottom:e.spacing.lg,right:(0,j.h)(25),zIndex:100,background:e.fn.primaryColor(),borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",width:"48px",height:"48px","&:hover":{cursor:"pointer",background:e.fn.darken(e.fn.primaryColor(),.5)}}}})),O=function(){var e=(0,x.h)(),t=e.locale,n=e.asPath,o=(0,r.useContext)(b.I).dispatch,a=w(void 0,{name:"CreatePostSticky"}),s=a.classes,c=a.cx;return(0,i.jsx)(h.B,{unstyled:!0,leftIcon:(0,i.jsx)(v.Z,{color:"#fff",size:18}),className:c(s.root,"create-post-sticky"),"data-event-category":"Together","data-event-action":"Write Post Click","data-event-label":(0,g.Ow)(t,n),onClick:function(){return o({type:y.H.SHOW_CREATE_NEW_POST_POPUP,payload:!0})}})},P=n(32680),_=n(23577),k=n(29828),S=n(59701),N=n(50794),I=n(47146),Z=n(88547),D=n(68648),T=n(19864),M=n(11163),E=n(86896),z=n(87841),L=n(24211),B=n(21124),A=n(95983),W=n(65557),H=n(91256),F=n(83272),R=n(58633),U=(0,H.ZP)(c.M).withConfig({displayName:"indexstyled__StyledBottomBar",componentId:"sc-1f62i52-0"})([".mobile-navigation-icon,.mobile-navigation-label{pointer-events:none;}a *{pointer-events:none;}border-left:0;border-right:0;grid-template-columns:repeat(5,1fr);z-index:10;&[data-is-community-sticky='true']{grid-template-columns:repeat(3,1fr);}"]),q=((0,H.ZP)(R.g).withConfig({displayName:"indexstyled__StyledGuideForNewMem",componentId:"sc-1f62i52-1"})(["position:absolute;bottom:100%;left:0;right:0;"]),(0,H.ZP)(F.O).withConfig({displayName:"indexstyled__StyledFullscreenModal",componentId:"sc-1f62i52-2"})(["z-index:349;"])),J=H.ZP.div.withConfig({displayName:"indexstyled__StyledCardTopicDesc",componentId:"sc-1f62i52-3"})(["font-size:14px;line-height:22px;margin-bottom:24px;"]),V=(0,C.k)((function(e){return{root:{}}})),G=function(e){var t,n=e.onCreatePostClick,o=e.extend,a=e.topics,s=void 0===a?[]:a,l=e.isCommunitySticky,d=void 0!==l&&l,u=e.isHomeCommunity,p=void 0!==u&&u,m=e.communityId,f=e.communities,h=e.selectedTopic,v=V(void 0,{name:"BottomBar"}).theme,x=(0,M.useRouter)(),C=x.locale,j=void 0===C?"vi-VN":C,w=(x.pathname,x.asPath),O=(0,E.Z)().formatMessage,H=(0,r.useContext)(b.I),F=H.state,R=F.userInfo,G=F.questionForExpert,Y=F.showFeedMenu,X=H.dispatch,Q=(0,r.useMemo)((function(){return(0,g.Ow)(j,w)}),[j,w]),K=(0,r.useMemo)((function(){return(0,g.mg)(j)}),[j,w]),$=(0,r.useMemo)((function(){return A.kJ.includes(j)}),[j]),ee=(0,B.h0)(),te=ee.authActionWrapper,ne=(ee.params,(0,r.useState)(!1)),ie=ne[0],oe=ne[1],re=(0,r.useState)(!1),ae=re[0],se=re[1],ce=(0,r.useState)(!1),le=(ce[0],ce[1],(0,r.useMemo)((function(){return-1!==A.MN.indexOf(A.Vi.NEXT_PUBLIC_DEPLOY_LOCALE||"")}),[])),de=(0,r.useMemo)((function(){return-1!==A.$x.indexOf(A.Vi.NEXT_PUBLIC_DEPLOY_LOCALE||"")}),[]),ue=le&&A.vA.includes((null===R||void 0===R?void 0:R.role)||""),pe=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(z.C,{disableDot:0===G}),label:O({id:"mobileBar.questions",defaultMessage:"Questions"}),onClick:function(){return X({type:y.H.SHOW_QUESTION_FOR_EXPERT_POPUP,payload:!0})},"data-event-category":"Sticky Bottom","data-event-action":"Write Post Click","data-event-label":Q})},me=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(_.Z,{}),label:O({id:"mobileBar.home",defaultMessage:"Home"}),onClick:function(e){e.preventDefault(),window.location.href=K},"data-event-category":"Sticky Bottom","data-event-action":"Home Click","data-event-label":K})},fe=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(k.Z,{}),label:O({id:"mobileBar.healthTools",defaultMessage:"Health Tools"}),onClick:function(e){e.preventDefault(),window.location.href=K+"/health-tools"},"data-event-category":"Sticky Bottom","data-event-action":"Engage Click","data-event-label":K+"/health-tools"})},ge=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(S.Z,{color:v.fn.primaryColor(),style:{transform:"translate(0, -4px)"}}),label:O(le?{id:"createPost.askDoctor",defaultMessage:"Ask Doctor"}:{id:"mobileBar.newPost",defaultMessage:"New Post"}),onClick:function(){return te((function(){return null===n||void 0===n?void 0:n()}),{_location:w,action:"create-post"})},"data-event-category":"Sticky Bottom","data-event-action":"Write Post Click","data-event-label":Q})},he=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(N.Z,{isActive:p}),label:O({id:"mobileBar.community",defaultMessage:"Community"}),isActive:p,onClick:function(e){e.preventDefault(),window.location.href=K+"/community"},"data-event-category":"Sticky Bottom","data-event-action":"Together Click","data-event-label":K+"/community"})},ve=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)("img",{src:P.C.getAssetPath("ai/bottom-bar-icon.jpg"),style:{height:"24px"},alt:O({id:"mobileBar.chatWithMe",defaultMessage:"Nh\u1eafn tin"})}),label:O({id:"mobileBar.chatWithMe",defaultMessage:"Nh\u1eafn tin"}),onClick:function(e){e.preventDefault(),window.location.href=A.nw},"data-event-category":"Sticky Bottom","data-event-action":"Chat Bot Click","data-event-label":K+"/community"})},xe=function(){return $?(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(I.Z,{}),label:O({id:"mobileBar.care",defaultMessage:"Care"}),onClick:function(e){e.preventDefault(),window.location.href=K+"/care"},"data-event-category":"Sticky Bottom","data-event-action":"Care Click","data-event-label":K+"/care"}):(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(Z.Z,{}),label:O({id:"mobileBar.myHealth",defaultMessage:"My Health"}),onClick:function(e){e.preventDefault(),window.location.href="".concat(A.Vi.NEXT_PUBLIC_SSO).concat(A.YP.MY_HEALTH_TRACKER)},"data-event-category":"Sticky Bottom","data-event-action":"User Profile Click","data-event-label":"".concat(A.Vi.NEXT_PUBLIC_SSO).concat(A.YP.MY_HEALTH_TRACKER)})},ye=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(D.Z,{isActive:ie}),label:O({id:"channelCommunity.topics",defaultMessage:"Feed"}),isActive:ie,onClick:function(e){e.preventDefault(),oe(!ie)},"data-event-category":"Sticky Bottom","data-event-action":"Topic Click","data-event-label":(0,g.Ow)(j,w)})},be=function(){return(0,i.jsx)(c.M.Icon,{icon:(0,i.jsx)(T.Z,{isActive:ie,size:24}),label:O({id:"bottomBar.feed",defaultMessage:"Feeds"}),isActive:ae,onClick:function(e){e.preventDefault(),se(!ae)},"data-event-category":"Sticky Bottom","data-event-action":"Highlight Click","data-event-label":(0,g.Ow)(j,w)})};return(0,r.useEffect)((function(){oe(!1),se(!1)}),[w]),(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(U,{"data-is-community-sticky":d,children:[d?de?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(he,{}),(0,i.jsx)(ye,{}),(0,i.jsx)(ge,{}),ue?(0,i.jsx)(pe,{}):(0,i.jsx)(ve,{}),(0,i.jsx)(fe,{})]}):(0,i.jsxs)(i.Fragment,{children:[ue?(0,i.jsx)(pe,{}):(0,i.jsx)(me,{}),(0,i.jsx)(he,{}),(0,i.jsx)(ge,{}),(0,i.jsx)(fe,{}),(0,i.jsx)(ye,{})]}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(me,{}),(0,i.jsx)(he,{}),(0,i.jsx)(ge,{}),(0,i.jsx)(fe,{}),ue?(0,i.jsx)(pe,{}):(0,i.jsx)(xe,{})]}),Y&&(0,i.jsx)(be,{}),o&&o]}),(0,i.jsxs)(q,{show:ie,title:O({id:"cardList.findYourCommunities"}),onClose:function(){oe(!1),se(!1)},children:[(0,i.jsx)(J,{children:O({id:"cardList.description",defaultMessage:"Explore our range of communities based on the health topics that matter to you the most."})}),(0,i.jsx)(L.I,{selectedCommunity:null===(t=(f||[]).filter((function(e){return e.id===m})))||void 0===t?void 0:t[0],communities:f||[],topicsBySelectedCommunity:s,selectedTopic:h,showActiveTopic:!0})]}),(0,i.jsx)(q,{show:ae,title:O({id:"bottomBar.feed",defaultMessage:"Feeds"}),onClose:function(){oe(!1),se(!1)},children:(0,i.jsx)(W.B,{isEmptyWrapperStyle:!0})})]})},Y=n(24107),X=n(43370),Q=n(13199),K=n(89814),$=H.ZP.div.withConfig({displayName:"indexstyled__StyledContent",componentId:"sc-1fywnpa-0"})(["display:flex;align-items:center;","{flex:1;}"],K.M.mbDown),ee=H.ZP.a.withConfig({displayName:"indexstyled__StyledContainer",componentId:"sc-1fywnpa-1"})(["position:relative;display:flex;align-items:center;justify-content:space-between;background-color:#284a75;background-position:center;background-size:cover;overflow:hidden;padding:0 11px;text-decoration:none;","{justify-content:center;}&[data-is-marry='true']{background-color:#ffe7ef;}&[data-is-collapse='false']{height:64px;transition:height 0.25s;}&[data-is-collapse='true']{height:0;transition:height 0.25s;}.content{display:-webkit-box;overflow:hidden;padding-right:16px;-webkit-box-orient:vertical;font-size:16px;font-weight:600;-webkit-line-clamp:2;line-height:24px;text-overflow:ellipsis;&,a{color:white;}","{font-size:14px;}}&[data-is-marry='true']{.content{&,a{color:#404040;}}}.close-icon{display:flex;align-items:center;justify-content:center;cursor:pointer;padding:5px;}&[data-is-marry='true']{.close-icon{background:white;border-radius:50%;width:32px;height:32px;padding:0px;}}"],K.M.mbUp,K.M.mbDown),te=H.ZP.img.withConfig({displayName:"indexstyled__StyledIcon",componentId:"sc-1fywnpa-2"})(["max-width:100px;margin-right:16px;max-height:64px;"]),ne=(H.ZP.a.withConfig({displayName:"indexstyled__StyledLink",componentId:"sc-1fywnpa-3"})([""]),function(e){var t,n=e.link,o=e.icon,a=e.content,s=e.onClose,c=(0,x.h)().locale,l=(0,r.useState)(!1),d=l[0],u=l[1],p=(0,X.U)(),m=a,f=null===(t=/]*href=["']([^"']*)["']/g.exec(m))||void 0===t?void 0:t[1],h=new URL(n,(0,g.mg)(c)),v=Q.aD.some((function(e){return h.origin.endsWith(e)}));return(0,i.jsx)(i.Fragment,{children:m&&(0,i.jsxs)(ee,{"data-is-marry":A.fn,"data-is-collapse":d,id:"sitewide-container",className:"no-replace-click","data-event-category":"Header Banner","data-event-action":"Link Click","data-event-label":p,href:n||f,target:v?"_self":"_blank",children:[(0,i.jsxs)($,{children:[o&&(0,i.jsx)(te,{alt:"",src:o,className:"icon lazy"},o||""),m&&(0,i.jsx)("p",{className:"content",dangerouslySetInnerHTML:{__html:m}})]}),(0,i.jsx)("div",{"data-event-category":"Header Banner","data-event-action":"Close Click","data-vars-event-label":p,className:"close-icon",onClick:function(e){e.preventDefault(),e.stopPropagation(),u(!0),null===s||void 0===s||s()},children:(0,i.jsx)("svg",{width:A.fn?"11":"16",height:A.fn?"11":"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,i.jsx)("path",{d:"M1.99007 0.990181C1.79114 0.990233 1.59674 1.04961 1.43173 1.16073C1.26672 1.27184 1.1386 1.42964 1.06374 1.61395C0.988886 1.79826 0.970697 2.00071 1.0115 2.19542C1.05231 2.39012 1.15025 2.56823 1.29281 2.70698L6.58578 7.99995L1.29281 13.2929C1.19684 13.3851 1.12021 13.4954 1.06743 13.6176C1.01464 13.7397 0.986757 13.8711 0.985403 14.0042C0.98405 14.1372 1.00926 14.2692 1.05954 14.3924C1.10983 14.5155 1.1842 14.6274 1.27827 14.7215C1.37235 14.8156 1.48426 14.89 1.60743 14.9402C1.73061 14.9905 1.86259 15.0157 1.99563 15.0144C2.12867 15.013 2.2601 14.9851 2.38223 14.9324C2.50436 14.8796 2.61473 14.803 2.70687 14.707L7.99984 9.41401L13.2928 14.707C13.385 14.803 13.4953 14.8796 13.6175 14.9324C13.7396 14.9851 13.871 15.013 14.0041 15.0144C14.1371 15.0157 14.2691 14.9905 14.3922 14.9402C14.5154 14.89 14.6273 14.8156 14.7214 14.7215C14.8155 14.6274 14.8899 14.5155 14.9401 14.3924C14.9904 14.2692 15.0156 14.1372 15.0143 14.0042C15.0129 13.8711 14.985 13.7397 14.9323 13.6176C14.8795 13.4954 14.8028 13.3851 14.7069 13.2929L9.4139 7.99995L14.7069 2.70698C14.8514 2.56652 14.9501 2.38567 14.99 2.18815C15.03 1.99063 15.0093 1.78565 14.9308 1.60007C14.8523 1.41448 14.7195 1.25695 14.5499 1.14812C14.3803 1.03929 14.1817 0.98424 13.9803 0.990181C13.7205 0.997922 13.4739 1.1065 13.2928 1.29292L7.99984 6.58589L2.70687 1.29292C2.61368 1.19712 2.50224 1.12098 2.37912 1.06898C2.25601 1.01698 2.12372 0.990189 1.99007 0.990181Z",fill:A.fn?"#404040":"white"})})})]})})}),ie=n(76278),oe=n(4266),re=n(34155);function ae(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function se(e){for(var t=1;tQ.currentPage&&(0,i.jsx)("link",{rel:"next",href:"".concat((0,a.g)($)).concat(A.GW).concat(ae,"?page=").concat(Q.nextPage)}),Q.prevPage>0&&(0,i.jsx)("link",{rel:"prev",href:"".concat((0,a.g)($)).concat(A.GW).concat(ae,"?page=").concat(Q.prevPage)})]})]})},siteType:be,seoCustom:D,userId:null===me||void 0===me||null===(h=me.userInfo)||void 0===h?void 0:h.id}),w,he&&(0,i.jsx)(Y.T,{isMobile:ce,onClose:function(){fe({type:y.H.SHOW_CREATE_NEW_POST_POPUP,payload:!1}),window.history.pushState({},"",(0,a.g)($)+window.location.pathname)},onPostCreatedEdited:R,lastFormData:U,onPostSuccess:F,defaultCommunity:q,defaultTopics:J}),(0,i.jsx)(l.F,{siteType:be,locale:$,type:"main",footerInfo:I,basePath:xe,background:d.t.colors.neutral50}),!ce&&V&&(0,i.jsx)(O,{}),ce&&(0,i.jsx)(G,{isHomeCommunity:L,isCommunitySticky:z,onCreatePostClick:function(){return null===M||void 0===M?void 0:M()},topics:E,selectedTopic:H,communities:B,communityId:W})]})})}},43370:function(e,t,n){"use strict";n.d(t,{U:function(){return a}});var i=n(67294),o=n(76278),r=n(11163);var a=function(){var e=(0,r.useRouter)(),t=e.locale,n=e.asPath;return(0,i.useMemo)((function(){return"https://".concat(o.domainLocales[t]).concat(n)}),[n])}},3055:function(e,t,n){"use strict";n.d(t,{g:function(){return i.g}});var i=n(48253)},48253:function(e,t,n){"use strict";n.d(t,{g:function(){return a}});var i=n(67294),o=function(){return window.innerWidth<768},r=function(){return window.innerWidth>=768&&window.innerWidth<1112},a=function(e){var t=(0,i.useState)(e),n=t[0],a=t[1],s=function(){var e=(0,i.useState)(o()),t=e[0],n=e[1],a=(0,i.useState)(r()),s=a[0],c=a[1];return(0,i.useEffect)((function(){var e=function(){n(o()),c(r())};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}}),[]),{isMobile:t,isLargeMobile:s}}().isMobile;return(0,i.useEffect)((function(){a(s)}),[s,e]),n}},4266:function(e,t,n){"use strict";n.d(t,{d:function(){return a}});var i=n(67294),o=n(3055),r=n(5886),a=function(){var e=(0,i.useContext)(r.I).state.isMobileSsr;return(0,o.g)(e)}}}]);