"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4125],{GvnZ:function(e,t,a){a.d(t,{H:function(){return HealthToolCardWrapper},T:function(){return ToolsBannerCard}});var n=a("6eqW"),r=a("q1tI"),l=a("/npG"),o=a("mYVa"),i=a("8vDj"),s=a("Eso5"),c=a("SPK5"),d=a("vaps"),u=a("CmQM"),p=a("UlxI"),m=a("ZQ3V"),g=a("LeBD"),h=a("ZKGu"),v=a("K2Xj"),f=a("yjyv");let E=(0,l.k)((e,{isRevamp:t,isPregTool:a,bannerColor:n,isMarryBaby:r})=>({wrapper:{position:"relative",width:"100%",height:"100%",display:"flex",gap:(0,o.h)(24),alignItems:"center",justifyContent:"space-between",padding:(0,o.h)(16),[e.fn.smallerThan("sm")]:{gap:(0,o.h)(12)}},container:{width:"100%",backgroundColor:n||(r?e.colors.mb[1]:a?e.colors.pink[1]:e.colors.blue[1]),position:"relative",display:"flex",gap:24,alignItems:"center",justifyContent:"space-between",padding:(0,o.h)(16),[e.fn.smallerThan("sm")]:{padding:`${(0,o.h)(12)} ${(0,o.h)(16)}`},a:{textDecoration:"none",color:"inherit"},'&[data-site="marryBaby"]':{a:{textDecoration:"underline"},[v.M.mbDown]:{paddingBottom:0}},[v.M.tdDown]:{height:"auto",".hhgcomp-toolbanner-wrapper":{".hhgcomp-toolbanner-inner":{display:"flex",alignItems:"center",[v.M.mbDown]:{justifyContent:"space-between"},".hhgcomp-toolbanner-iconcontainer":{position:"relative",right:(0,o.h)(-50),bottom:(0,o.h)(-20),width:(0,o.h)(110),minWidth:0,height:"auto",minHeight:0,alignSelf:"flex-end",marginBottom:(0,o.h)(-20),[v.M.mbDown]:{right:"unset"}}}}},".embedded-review":{gap:(0,o.h)(12),display:"flex",alignItems:"center"},".embedded-review__avatar":{position:"relative",minWidth:(0,o.h)(32),img:{width:(0,o.h)(32),height:(0,o.h)(32),display:"block",borderRadius:"100%"},svg:{bottom:0,right:0,position:"absolute"}}},headingWrapper:{display:"flex",flexDirection:"column",gap:t?(0,o.h)(8):0,[e.fn.smallerThan("sm")]:{gap:4}},avatarWrapper:{position:"relative",img:{maxWidth:(0,o.h)(48),maxHeight:(0,o.h)(48)},".embedded-review__avatar":{position:"relative"}},reviewText:{a:{textDecoration:"underline",textUnderlineOffset:"2px"}},iconWrapper:{display:"flex",justifyContent:"center",alignItems:"center",width:(0,o.h)(80),height:(0,o.h)(80),borderRadius:"50%",backgroundColor:"#fff",flexShrink:0,img:{maxWidth:(0,o.h)(48),maxHeight:(0,o.h)(48)},[e.fn.smallerThan("sm")]:{width:(0,o.h)(64),height:(0,o.h)(64),img:{maxWidth:(0,o.h)(40),maxHeight:(0,o.h)(40)}}},heading:{},disclaimerIcon:{flexShrink:0}})),ToolsBannerCard=e=>{var{className:t,classNames:a,heading:l,bannerColor:o,medicalReview:d={link:"#",reviewer:"",date:""},icon:g,style:v,isPregTool:f,isRevamp:b,disclaimer:x,styles:y}=e,w=(0,n._)(e,["className","classNames","heading","bannerColor","medicalReview","icon","style","isPregTool","isRevamp","disclaimer","styles"]);let{t:C}=(0,h.u)(),T=(0,i.rZ)(),k="mb"===T.other.template,S=k?"marryBaby":"helloSites",{classes:N,cx:_}=E({isRevamp:b,isPregTool:f,bannerColor:o,isMarryBaby:k},{name:"ToolsBannerCard",styles:y,classNames:a}),I=(null==d?void 0:d.reviewer)?r.createElement(m.T,{size:"label2",as:"div",className:N.reviewText},d.avatar&&r.createElement("div",{className:"embedded-review__avatar"},r.createElement(s.x,{className:N.avatarWrapper},r.createElement("img",{src:d.avatar,alt:d.reviewer,loading:"lazy"}),r.createElement(p.Z,{size:14}))),r.createElement("div",{dangerouslySetInnerHTML:{__html:C("toolPage.toolReviewer",{expert_name:`${d.reviewer.trim()}`,date:d.date})}})):null;return r.createElement(s.x,Object.assign({className:_(t,N.container),style:v,"data-site":S},w),r.createElement(c.k,{className:N.headingWrapper},r.createElement(m.T,{className:_(N.heading,"heading"),size:"h4",as:"h2"},l),I&&r.createElement(m.T,{size:"n1"},I),x&&r.createElement(c.k,{gap:4},r.createElement(u.Z,{size:16,color:T.colors.yellow[8],className:N.disclaimerIcon}),r.createElement(m.T,{size:"c1",variant:"secondary"},x))),r.createElement(c.k,{className:N.iconWrapper},g))};var b=(0,l.k)(()=>({root:{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}})),x=(0,l.k)(e=>({root:{paddingTop:16,borderRadius:"inherit",[e.fn.smallerThan("sm")]:{paddingTop:8}}})),y=(0,l.k)((e,{isPregTool:t,variant:a})=>{let n="mb"===e.other.template;return{root:Object.assign(Object.assign(Object.assign({display:"flex",flexDirection:"column",borderRadius:(0,o.h)(n?16:8)},"default"===a&&{backgroundColor:"#fff",border:`1px solid ${n?e.colors.mb[2]:t?e.colors.pink[1]:e.colors.blue[2]}`}),"gray"===a&&{backgroundColor:e.colors.neutral[0]}),"violet"===a&&{backgroundColor:e.colors.violet[0]}),submitBtn:{},bodyWrapper:{},scrollAreaWrapper:{},bannerWrapper:Object.assign(Object.assign({},"gray"===a&&{backgroundColor:"transparent",padding:`${(0,o.h)(16)} ${(0,o.h)(16)} 0`}),"violet"===a&&{backgroundColor:"transparent",padding:`${(0,o.h)(16)} ${(0,o.h)(16)} 0`}),bannerHeading:Object.assign({},("gray"===a||"violet"===a)&&{fontSize:(0,o.h)(20),lineHeight:(0,o.h)(28),fontWeight:g.F.semiBold,[e.fn.smallerThan("sm")]:{fontSize:(0,o.h)(17),lineHeight:(0,o.h)(24)}}),bannerReviewText:Object.assign({},("gray"===a||"violet"===a)&&{fontSize:(0,o.h)(14),lineHeight:(0,o.h)(22),[e.fn.smallerThan("sm")]:{fontSize:(0,o.h)(12),lineHeight:(0,o.h)(18)}}),submitWrapper:Object.assign(Object.assign({[e.fn.smallerThan("sm")]:{button:{width:"100%"}},[e.fn.largerThan("sm")]:{textAlign:"right"}},"gray"===a&&{backgroundColor:e.colors.neutral[0],button:{marginTop:10}}),"violet"===a&&{backgroundColor:e.colors.violet[0],button:{marginTop:10}}),newsletterBlock:Object.assign(Object.assign({},"gray"===a&&{backgroundColor:e.colors.neutral[0]}),"violet"===a&&{backgroundColor:e.colors.violet[0]})}});let HealthToolCardWrapper=e=>{var{children:t,styles:a,classNames:l,className:o,isPregTool:i,variant:c="default",hasBodyScroll:d}=e,u=(0,n._)(e,["children","styles","classNames","className","isPregTool","variant","hasBodyScroll"]);let{classes:p,cx:m}=y({isPregTool:i,variant:c},{name:"HealthToolCardWrapper",styles:a,classNames:l});return r.createElement(g.T,{variant:g.C.LEADGEN},r.createElement(f.C.Provider,{value:{isPregTool:i,classes:p,variant:c,hasBodyScroll:d}},r.createElement(s.x,Object.assign({className:m(o,p.root)},u),t)))};HealthToolCardWrapper.Body=e=>{var{children:t,className:a,styles:l,classNames:o}=e,i=(0,n._)(e,["children","className","styles","classNames"]);let{classes:c,hasBodyScroll:u}=(0,r.useContext)(f.C),{classes:p,cx:m}=x(void 0,{name:"HealthToolCardWrapper__Body",styles:l,classNames:o});return r.createElement(s.x,Object.assign({className:m(a,p.root,c.bodyWrapper)},i),u?r.createElement(d.x,{h:"100%",type:"auto",scrollbarSize:8,className:c.scrollAreaWrapper},t):t)},HealthToolCardWrapper.Banner=e=>{var{className:t,classNames:a,styles:l}=e,o=(0,n._)(e,["className","classNames","styles"]);let{classes:i}=(0,r.useContext)(f.C),{isPregTool:s}=(0,r.useContext)(f.C),{classes:c,cx:d}=b(void 0,{name:"HealthToolCardWrapper__Banner",classNames:a,styles:l});return r.createElement(ToolsBannerCard,Object.assign({isPregTool:s,classNames:{container:i.bannerWrapper,heading:i.bannerHeading,reviewText:i.bannerReviewText},className:d(t,c.root)},o))}},CDlW:function(e,t,a){a.d(t,{A:function(){return Alert},B:function(){return Badge},C:function(){return CardCollapse},D:function(){return DragFreeCarousel},F:function(){return FileDropdown},G:function(){return Grid},H:function(){return HtmlContent},I:function(){return IconHeading},R:function(){return Radio},S:function(){return StepRenderer},T:function(){return Tag},U:function(){return Upload},a:function(){return BorderHeading},b:function(){return RateStars},c:function(){return Toggle},d:function(){return F},e:function(){return Y},f:function(){return l},g:function(){return o}});var n,r,l,o,i=a("q1tI"),s=a("ZQ3V"),c=a("rBCA"),d=a("iBNF"),u=a("K2Xj"),p=a("4JiQ"),m=a("mYVa"),g=a("iuhU"),h=a("Iblh"),v=a("Pc0s"),f=a("TH2c"),E=a("6eqW"),b=a("fNCy"),x=a("gEnE"),y=a("yVya"),w=a("OGdO"),C=a("p5f+"),T=a("ZKGu"),k=a("Zdfy");let Upload=e=>i.createElement("svg",Object.assign({width:"1em",height:"1em",viewBox:"0 0 18 18",fill:"none"},e),i.createElement("path",{d:"M9.82324 8.7033L10.8228 9.70287C10.9267 9.80662 11.056 9.8573 11.2107 9.85493C11.3655 9.85255 11.4948 9.79943 11.5987 9.69555C11.7026 9.59168 11.7545 9.46074 11.7545 9.30274C11.7545 9.14474 11.7026 9.01462 11.5987 8.91237L9.7353 7.04899C9.59968 6.91337 9.44149 6.84555 9.26074 6.84555C9.07999 6.84555 8.9218 6.91337 8.78618 7.04899L6.91549 8.91968C6.81174 9.02355 6.75987 9.15287 6.75987 9.30762C6.75987 9.46237 6.81174 9.59168 6.91549 9.69555C7.01937 9.79943 7.1503 9.85137 7.3083 9.85137C7.4663 9.85137 7.59643 9.79943 7.69868 9.69555L8.69824 8.7033L8.69824 11.5576C8.69824 11.717 8.75218 11.8506 8.86005 11.9583C8.96793 12.0662 9.10156 12.1201 9.26093 12.1201C9.42043 12.1201 9.55399 12.0662 9.66162 11.9583C9.76937 11.8506 9.82324 11.717 9.82324 11.5576L9.82324 8.7033ZM16.3857 9.3063C16.3857 10.2918 16.1987 11.2181 15.8247 12.0852C15.4507 12.9524 14.9432 13.7066 14.3021 14.348C13.6609 14.9894 12.907 15.4972 12.0402 15.8714C11.1735 16.2456 10.2474 16.4326 9.26205 16.4326C8.27655 16.4326 7.35024 16.2456 6.48312 15.8716C5.61599 15.4976 4.86174 14.9901 4.22037 14.3489C3.57899 13.7078 3.07118 12.9539 2.69693 12.0871C2.3228 11.2204 2.13574 10.2943 2.13574 9.30893C2.13574 8.32343 2.32274 7.39712 2.69674 6.52999C3.07074 5.66287 3.5783 4.90862 4.21943 4.26724C4.86055 3.62587 5.61449 3.11805 6.48124 2.7438C7.34799 2.36968 8.27405 2.18262 9.25943 2.18262C10.2449 2.18262 11.1712 2.36962 12.0384 2.74362C12.9055 3.11762 13.6597 3.62518 14.3011 4.2663C14.9425 4.90743 15.4503 5.66137 15.8246 6.52812C16.1987 7.39487 16.3857 8.32093 16.3857 9.3063ZM15.2607 9.30762C15.2607 7.63262 14.6795 6.21387 13.517 5.05137C12.3545 3.88887 10.9357 3.30762 9.26074 3.30762C7.58574 3.30762 6.16699 3.88887 5.00449 5.05137C3.84199 6.21387 3.26074 7.63262 3.26074 9.30762C3.26074 10.9826 3.84199 12.4014 5.00449 13.5639C6.16699 14.7264 7.58574 15.3076 9.26074 15.3076C10.9357 15.3076 12.3545 14.7264 13.517 13.5639C14.6795 12.4014 15.2607 10.9826 15.2607 9.30762Z",fill:"#595959"})),Alert=({style:e,onClose:t,text:a,type:n,contentIcon:r,closeIcon:l,className:o,description:c})=>i.createElement("div",{className:`CHw-fZZ ${o||""}`,style:e,"data-alert-type":n},i.createElement("div",{className:"_03U6VRS"},i.createElement("div",{className:"icon-title"},r,i.createElement(s.T,{weight:"bold",size:"label1"},a)),i.createElement(s.T,{weight:"regular",size:"p3"},c)),i.createElement("div",{className:"EO828Vv",onClick:t},l)),renderNotificationStyles=(e,t,a,n)=>{let r,l="";if("numeric"===e)switch(t){case"medium":l=`
height: 16px;
font-size: 11px;
padding: 1px 6px;
`;case"large":l=`
height: 24px;
font-size: 13px;
padding: 1px 10px;
`}let o="";a&&(o=`
position: absolute;
top: 0;
left: 75%;
`),a&&(r=`
left: 70%;
${"large"===t?`
top: -7px;
`:"medium"===t?`
top: -2px;
width: 16px;
height: 16px;
`:""}
`);let i="";switch(n){case"primary":i=`
background: ${d.r.colors.primary50};
color: ${d.r.colors.primary600};
`;break;case"error":i=`
background: ${d.r.colors.error};
color: white;
`}switch(e){case"dot":return`
${o}
width: 8px;
height: 8px;
font-size: 0px;
border-radius: 50%;
${i}
`;case"numeric":return`
${o}
width: max-content;
border-radius: 32px;
${l}
${r}
${i}
`}},S=c.Z.div`
position: relative;
> div {
width: max-content;
position: relative;
}
span {
font-weight: ${d.r.sizes.fwBold};
display: flex;
justify-content: center;
align-items: center;
${e=>renderNotificationStyles(e.notificationType,e.notificationSize,e.hasIcon,e.notificationColor)}
}
${e=>e.hasIcon&&`
svg {
width: 40px;
height: 40px;
}
`}
`,Badge=({amount:e,type:t,size:a="medium",color:n="primary",icon:r,className:l})=>i.createElement(S,{"data-notification-type":t,"data-notification-size":a,"data-notification-color":n,"data-has-icon":!!r||void 0,notificationType:t,notificationSize:a,notificationColor:n,hasIcon:!!r,className:l},i.createElement("div",null,e&&i.createElement("span",null,e)," ",r&&i.createElement("div",null,r))),N=c.Z.h4`
position: relative;
line-height: 18px;
&:after {
position: absolute;
top: 1px;
left: 0;
width: 4px;
height: 18px;
background-color: ${d.r.colors.primaryBase};
content: '';
}
&[data-size='lg'] {
font-size: 18px;
padding-left: 12px;
}
&[data-size='sm'] {
font-size: 14px;
padding-left: 8px;
&::after {
width: 2px;
height: 15px;
}
}
&[data-type='bold'] {
font-weight: ${d.r.sizes.fwBold};
}
&[data-type='semiBold'] {
font-weight: ${d.r.sizes.fwSemiBold};
}
&[data-uppercase] {
text-transform: uppercase;
}
${u.M.mbDown} {
&[data-size='lg'] {
font-size: 16px;
}
}
`,BorderHeading=({style:e,children:t,className:a,size:n="lg",type:r="bold",upperCase:l,as:o="h4",color:s})=>i.createElement(N,{style:Object.assign({color:s},e),className:a,"data-size":n,"data-type":r,"data-uppercase":l,as:o},t),_=(0,c.Z)(v.S)`
flex-shrink: 0;
color: ${d.r.colors.neutral800};
width: 16px;
height: 16px;
transition: transform 0.2s ease-in-out;
transform: rotate(-180deg);
&[data-is-collapsed='true'] {
transform: rotate(0deg);
}
`,I=c.Z.div`
background-color: white;
.icon {
width: 20px;
height: 20px;
flex-shrink: 0;
color: ${d.r.colors.neutral800};
}
.title-collapse {
color: #111111;
font-weight: var(--fwSemiBold);
font-size: 1.0625rem;
line-height: 1.5rem;
flex-grow: 1;
}
.box-collapse {
display: flex;
padding: 1.5rem 1rem 1rem 1rem;
gap: 0.75rem;
align-items: center;
}
`;function CardCollapse({children:e,title:t,icon:a,defaultOpened:n=!0,haveCollapse:r=!0,id:l,className:o,as:c="h2"}){let[d,{toggle:u}]=(0,h.q)(n);return i.createElement(I,{id:l,className:o},i.createElement("div",{className:"box-collapse",onClick:()=>{r&&u()}},r&&a,i.createElement(s.T,{as:c,className:"title-collapse"},t),r&&i.createElement(_,{"data-is-collapsed":d})),i.createElement(p.U,{in:!r||d,transitionDuration:200,transitionTimingFunction:"ease"},e))}let A=c.Z.div`
position: relative;
box-sizing: border-box;
border: 1px solid ${d.r.colors.gray200};
background: url('../../../public/bgSvg/arrow-down.svg') no-repeat;
background-position: right 16px center;
border-radius: ${d.r.borderRadius};
&[data-has-icons='true'] {
border: none;
background: ${d.r.colors.gray100};
img,
svg {
display: inline-block;
max-width: 16px;
margin-right: 6px;
}
span {
vertical-align: middle;
display: inline-block;
}
&:hover {
box-shadow: none;
}
> div {
position: relative;
width: 100%;
display: flex;
align-items: center;
box-sizing: border-box;
}
> div::after {
content: '';
right: 12px;
top: 50%;
background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%23595959' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
width: 10px;
height: 8px;
position: absolute;
background-repeat: no-repeat;
transform: translateY(-50%);
}
}
&:hover {
box-shadow: 0 0 2px 2px ${d.r.colors.primary200};
}
`,M=c.Z.div`
padding: 12px 18px 12px 16px;
cursor: pointer;
&[data-dropdown-open] {
padding: 11px 15px 11px 15px;
border: 1px solid ${d.r.colors.primaryBase};
border-radius: ${d.r.borderRadius};
box-shadow: 0 0 2px 2px ${d.r.colors.primary200};
}
& > svg {
height: 16px;
width: 16px;
}
`,O=c.Z.ul`
position: absolute;
top: 100%;
right: 0;
left: 0;
display: block;
margin-top: 4px;
background: ${d.r.colors.white};
border-radius: ${d.r.borderRadius};
box-shadow: -1px 1px 2px rgba(67, 70, 74, 0.0001),
-2px 2px 5px rgba(67, 86, 100, 0.123689);
cursor: pointer;
&[data-has-icons='true'] {
background: white;
box-shadow: none;
border: 1px solid ${d.r.colors.gray200};
filter: drop-shadow(0px 10px 16px rgba(0, 0, 0, 0.04));
}
`,$=c.Z.li`
margin: 8px;
padding: 12px 18px 12px 16px;
border-radius: ${d.r.borderRadius};
display: flex;
&:hover,
:active {
background: ${d.r.colors.gray100};
}
`,P=c.Z.div`
display: flex;
align-items: center;
margin-right: 8px;
& > svg {
height: 16px;
width: 16px;
}
`,ShareIconPathStyle=()=>i.createElement("style",null,".file-dropdown-path{fill:none;stroke:#595959;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px}"),DefaultFileIcon=()=>i.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 12.17 14.83"},i.createElement("defs",null,i.createElement("clipPath",{id:"prefix__clip-path",transform:"translate(-1.92 -1.54)"},i.createElement("path",{fill:"none",d:"M0 .96h16v16H0z"}))),i.createElement("title",null,"File"),i.createElement("g",{clipPath:"url(#prefix__clip-path)"},i.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29H4a1.33 1.33 0 00-1.33 1.33v10.67A1.33 1.33 0 004 15.62h8a1.33 1.33 0 001.33-1.33V7z",transform:"translate(-1.92 -1.54)"}),i.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29V7h4.66",transform:"translate(-1.92 -1.54)"}))),DownloadIcon=()=>i.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},i.createElement("title",null,"download"),i.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M4.67 7.62L8 11l3.33-3.34M8 11V3",transform:"translate(-1.25 -2.21)"})),UploadIcon=()=>i.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},i.createElement("title",null,"upload"),i.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M11.33 6.29L8 3 4.67 6.29M8 3v8",transform:"translate(-1.25 -2.21)"})),FileDropdown=({className:e,value:t,options:a,onUploadSelected:n,id:r,placeholderIcon:l,placeholder:o,style:s})=>{let[c,d]=(0,i.useState)(!1),showDropdown=()=>d(!c),u=(0,i.useRef)(a.map(e=>"upload"===e.type&&i.createElement("input",{id:"uploader-dropdown-input-"+r+"-"+e.value,key:"uploader-dropdown-input-"+r+"-"+e.value,accept:e.fileAcceptedType,multiple:e.multiple,type:"file",style:{display:"none"},onChange:e=>{console.log("change"),n(e.target.files)}}))),onUpload=e=>{var t;null===(t=document.querySelector(e))||void 0===t||t.click()},onDownload=e=>{e&&window.open(e,"_blank")};return i.createElement(A,{className:e,"data-dropdown-open":!!c,id:r,"data-has-icons":!0,style:s,onBlur:()=>d(!1),tabIndex:0},i.createElement(ShareIconPathStyle,null),i.createElement(M,{onClick:showDropdown},l||i.createElement(DefaultFileIcon,null)," ",i.createElement("span",null,t&&t.value?t.label:o)),c&&i.createElement(O,{onClick:showDropdown,"data-has-icons":!0},a.map(e=>i.createElement($,{key:`${r}-${e.value}`,"data-selected":t&&t.value===e.value||void 0,onClick:()=>"upload"===e.type?onUpload("#uploader-dropdown-input-"+r+"-"+e.value):onDownload(e.url)},i.createElement(P,null,e.icon||"download"===e.type?i.createElement(DownloadIcon,null):i.createElement(UploadIcon,null)),e.label))),i.createElement(i.Fragment,null,u.current))},B=c.Z.div`
--columns: var(--grid-template-columns, repeat(var(--columns-count), 1fr));
--columns-desktop: var(
--grid-template-columns-desktop,
repeat(var(--columns-count-desktop), 1fr)
);
display: grid;
grid-template-columns: var(--columns);
grid-gap: var(--grid-gap);
align-items: var(--align-items);
${u.M.tdUp} {
grid-template-columns: var(--columns-desktop);
}
> * {
justify-self: var(--justify-children);
}
`,Grid=({className:e,columns:t,columnsDesktop:a,gridTemplateColumns:n,gridTemplateColumnsDesktop:r,gap:l,children:o,justifyChildren:s,style:c,alignItems:d})=>i.createElement(B,{className:e,style:Object.assign({"--columns-count":t,"--columns-count-desktop":a,"--grid-template-columns":n,"--grid-template-columns-desktop":r,"--justify-children":s,"--grid-gap":l,"--align-items":d},c)},o),Radio=({size:e="small",label:t,name:a,checked:n,value:r,className:l,isDisabled:o=!1,onChange:s,dataEventCategory:c,dataEventAction:d,dataEventLabel:u})=>{let p=!!d&&!!c&&!!u,m=p?{"data-event-category":c,"data-event-action":d,"data-event-label":u}:{};return i.createElement(f.R,Object.assign({size:"small"===e?"md":"lg",label:t,name:a,checked:n,value:r,className:l,disabled:o,onChange:e=>null==s?void 0:s(e.target.value)},m))},D=c.Z.div`
display: inline-flex;
gap: calc(var(--gap) * 1px);
> svg {
width: calc(var(--star-size) * 1px);
height: calc(var(--star-size) * 1px);
}
&[data-selectable='true'] {
> svg {
cursor: pointer;
}
}
`,StarHalfIcon=e=>i.createElement("svg",Object.assign({},e,{viewBox:"0 0 24 24",fill:"none"}),i.createElement("path",{d:"m139.287 144.772 5.17 3.12c.38.23.85-.11.75-.54l-1.37-5.88 4.56-3.95c.33-.29.16-.84-.29-.88l-6.01-.51-2.35-5.54a.498.498 0 0 0-.92 0l-2.35 5.54-6.01.51a.499.499 0 0 0-.28.88l4.56 3.95-1.37 5.88c-.1.43.37.77.75.54z",fill:"#E4E8EC"}),i.createElement("path",{d:"M139.289 144.771s.013-14.488 0-14.488a.49.49 0 0 0-.46.308l-2.35 5.54-6.01.51a.499.499 0 0 0-.28.88l4.56 3.95-1.37 5.88c-.1.43.37.77.75.54z",fill:"#FFC326"})),StarIcon=e=>{var{isFull:t}=e,a=(0,E._)(e,["isFull"]);return i.createElement("svg",Object.assign({},a,{viewBox:"0 0 32 32",fill:"none"}),i.createElement("path",{d:"m16 23.027 6.893 4.16c.507.306 1.134-.147 1-.72l-1.826-7.84 6.08-5.267a.67.67 0 0 0-.387-1.173l-8.013-.68-3.134-7.387a.664.664 0 0 0-1.226 0l-3.133 7.387-8.014.68a.668.668 0 0 0-.373 1.173l6.08 5.267-1.827 7.84c-.133.573.493 1.026 1 .72z",fill:t?"#FFC326":"#D2D6DC"}))},RateStars=({gap:e=2,size:t=24,star:a,totalStars:n=5,onSelect:r,hideEmptyStars:l,style:o,className:s})=>{let c=Math.floor(a),d=a-c>=.5?1:0,[u,p]=(0,i.useState)(null),m=u||c,g=u?0:d;return i.createElement(D,{"data-selectable":!!r,style:Object.assign({"--gap":e,"--star-size":t},o),className:s},Array.from({length:l?c+d:n}).map((e,t)=>{let onMouseOver=()=>!!r&&p(t+1),onMouseLeave=()=>!!r&&p(null);return t+1<=m?i.createElement(StarIcon,{key:t,onClick:()=>null==r?void 0:r(t+1),onMouseOver:onMouseOver,onMouseLeave:onMouseLeave,isFull:!0}):t+1===m+g?i.createElement(StarHalfIcon,{key:t,onClick:()=>null==r?void 0:r(t+1),onMouseOver:onMouseOver,onMouseLeave:onMouseLeave}):i.createElement(StarIcon,{key:t,onClick:()=>null==r?void 0:r(t+1),onMouseOver:onMouseOver,onMouseLeave:onMouseLeave})}))},getTag=(e,t)=>{switch(e){case"yellow":{let e=t?d.r.colors.yellow50:d.r.colors.yellow600;return`
background: ${e};
p {
color: var(
--text-props-color,
${d.r.colors.gray800}
);
}
`}case"standard":return`
background: ${d.r.colors.white};
border: 1px solid ${d.r.colors.gray200};
p {
color: var(
--text-props-color,
${d.r.colors.gray800}
);
}
&:hover {
background: ${d.r.colors.gray100};
}
`;case"red":{let e=t?d.r.colors.red50:d.r.colors.red500;return`
background: ${e};
`}case"green":{let e=t?d.r.colors.green50:d.r.colors.green500;return`
background: ${e};
`}case"blue":{let e=t?d.r.colors.primary50:d.r.colors.primaryBase;return`
background: ${e};
`}case"teal":{let e=t?d.r.colors.teal100:d.r.colors.teal600;return`
background: ${e};
`}case"pink":{let e=t?d.r.colors.pink200:d.r.colors.pink800;return`
background: ${e};
`}case"violet":{let e=t?d.r.colors.violet100:d.r.colors.violet500;return`
background: ${e};
`}case"grey":{let e=t?d.r.colors.gray100:d.r.colors.gray600;return`
background: ${e};
`}}},R=c.Z.div`
--padding-horizontal: 8px;
--pading-vertical: 2px;
display: flex;
align-items: center;
justify-content: center;
padding: var(--pading-vertical) var(--padding-horizontal);
border-radius: 24px;
${e=>"sponsored"===e.tagType&&`
--offset-size: 4px;
display: flex;
align-items: center;
justify-content: center;
box-sizing: content-box;
position: relative;
box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.08);
border-radius: 0 4px 18px 0;
height: 24px;
width: 90px;
border-left: var(--offset-size) solid ${d.r.colors.accentLight};
padding: 0;
margin-left: calc(var(--offset-size) * -1);
p {
font-weight: ${d.r.sizes.fwBold};
color: var(
--text-props-color,
${d.r.colors.secondaryDark}
);
font-size: 11px;
margin-left: calc(var(--offset-size) * -1);
}
&::after {
width: calc(var(--offset-size) * 2);
height: var(--offset-size);
background: ${d.r.colors.accentMain};
position: absolute;
left: calc(var(--offset-size) * -1);
bottom: calc(var(--offset-size) * -1);
clip-path: polygon(0 1%, 100% 0%, 100% 100%);
content: '';
}
`}
${e=>e.isInline&&`
display: inline-block;
`}
${e=>e.tagHasMorePadding&&`
&[data-has-more-padding] {
padding: calc(var(--pading-vertical) + 5px) var(--padding-horizontal);
}
`}
p {
${e=>e.tagIsLight?`
color: var(--text-props-color, #000);
`:`
color: var(--text-props-color, ${d.r.colors.white});
`}
}
${e=>getTag(e.tagType,e.tagIsLight)}
${e=>e.tagIsSquared&&"sponsored"!==e.tagType&&`
border-radius: 4px;
`}
${e=>e.tagIsALink&&`
cursor: pointer;
`}
&[data-is-selected],
&:active {
background: ${d.r.colors.primary50};
}
`,Tag=({type:e,children:t,style:a,isInline:n,isSquared:r=!1,className:l,isLight:o,hasMorePadding:s,isLink:c,isSelected:d,textProps:u={size:"sm"}})=>{let p=u.color?{"--text-props-color":u.color}:{};return i.createElement(R,{"data-is-squared":r||void 0,"data-tag-type":e,"data-is-light":o||void 0,"data-has-more-padding":s||void 0,"data-is-inline":n||void 0,style:Object.assign(Object.assign({},a),p),className:l,"data-is-selected":d||void 0,"data-is-link":c||void 0,tagType:e,isInline:n,tagHasMorePadding:s,tagIsLight:o,tagIsSquared:r,tagIsALink:c},i.createElement(b.T,Object.assign({},u),t))},U="24px",z=(0,x.Z)(c.Z.span`
position: relative;
display: block;
width: 40px;
height: ${U};
background: #c3cbd4;
border-radius: 100px;
cursor: pointer;
&:after {
position: absolute;
top: 2px;
left: 2px;
width: 20px;
height: 20px;
background: #fff;
border-radius: 90px;
content: '';
transition: 0.3s;
}
`,"hhgcomp-toggle-icon"),L=c.Z.span`
padding-left: 15px;
`,j=c.Z.div`
height: ${U};
input[type='checkbox'] {
width: 0;
height: 0;
visibility: hidden;
}
label {
cursor: pointer;
display: inline-flex;
color: ${d.r.colors.gray600};
}
input:checked + label ${z.classSelector} {
background: ${d.r.colors.primaryBase};
&:after {
left: calc(100% - 2px);
transform: translateX(-100%);
}
}
`,Toggle=({className:e,id:t,onChange:a,checked:n,style:r,label:l})=>i.createElement(j,{className:e,style:r},i.createElement("input",{type:"checkbox",id:t,onChange:a,checked:n}),i.createElement("label",{htmlFor:t},i.createElement(z,null),l&&i.createElement(L,null,l))),F=(0,i.createContext)({currentStep:0,setCurrentStep:()=>!1,setMaxStep:()=>!1,nextStep:()=>!1,prevStep:()=>!1}),StepRenderer=({children:e,onStepChange:t})=>{let[a,n]=(0,i.useState)(0),[r,l]=(0,i.useState)(0),o=i.Children.count(e);return(0,i.useEffect)(()=>{l(o-1)},[o]),(0,i.useEffect)(()=>{null==t||t(a)},[a]),i.createElement(F.Provider,{value:{currentStep:a,setCurrentStep:n,setMaxStep:l,nextStep:()=>a+1<=r&&n(a+1),prevStep:()=>a-1>=0&&n(a-1)}},(0,y.Z)(e).map((e,t)=>{let n=t===a;return i.createElement(i.Fragment,{key:t},i.isValidElement(e)?e.props.alwaysRender||n?i.cloneElement(e,{isActive:t===a,stepIndex:t}):null:n?e:null)}))},H=c.Z.div`
display: flex;
align-items: center;
gap: 8px;
`,Z=(0,c.Z)(w.H)`
font-weight: var(--fwBold);
`,IconHeading=({icon:e,title:t,className:a,style:n})=>i.createElement(H,{className:a,style:n},e,i.createElement(Z,{tag:"h6",color:"var(--secondaryDark)"},t)),sanitizeHtml=e=>{if(!e)return"";let t=e.replace(/\n$/,"").replace(/\n/g,"
");return t},HtmlContent=({htmlContent:e,className:t})=>{let a=sanitizeHtml(e);return i.createElement("div",{className:t,dangerouslySetInnerHTML:{__html:a}})};(n=l||(l={})).ONE_TO_ONE="1:1",n.THREE_TO_ONE="3:1",(r=o||(o={})).PNG=".png",r.JPG=".jpg",r.JPEG=".jpeg";let getBase64=e=>new Promise((t,a)=>{let n=new FileReader;n.onload=()=>t(n.result),n.onerror=a,n.readAsDataURL(e)}),handleMultipleImageFiles=e=>(0,E.a)(void 0,void 0,void 0,function*(){if(0===e.length)return[];let t=yield Promise.all(e.map(e=>getBase64(e)));return t}),G=c.Z.div`
display: flex;
flex-direction: column;
.image-upload-input-error {
margin-top: ${(0,m.h)(12)};
display: flex;
flex-direction: column;
gap: ${(0,m.h)(4)};
}
`,W=c.Z.div`
display: flex;
flex-direction: column;
gap: ${(0,m.h)(4)};
margin-top: ${(0,m.h)(4)};
span {
color: ${d.r.colors.neutral500};
}
`,V=c.Z.div`
position: relative;
width: fit-content;
padding: ${(0,m.h)(8)} ${(0,m.h)(12)};
border-radius: ${(0,m.h)(12)};
border: ${(0,m.h)(1)} solid ${d.r.colors.neutral200};
cursor: pointer;
display: flex;
align-items: center;
gap: ${(0,m.h)(8)};
margin-top: ${(0,m.h)(18)};
&.image-upload-dragover {
border-color: ${d.r.colors.primaryBase};
}
&.image-upload-error {
border-color: ${d.r.colors.error};
}
&.image-upload-disabled {
cursor: not-allowed;
background-color: ${d.r.colors.gray100};
color: ${d.r.colors.gray400};
border-color: ${d.r.colors.gray200};
}
svg {
width: ${(0,m.h)(18)};
height: ${(0,m.h)(18)};
}
input {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
opacity: 0;
cursor: pointer;
z-index: -1;
}
`,q=c.Z.div`
position: relative;
width: ${(0,m.h)(90)};
height: ${(0,m.h)(90)};
border-radius: ${(0,m.h)(12)};
overflow: hidden;
background-color: ${d.r.colors.gray100};
display: flex;
align-items: center;
justify-content: center;
img {
width: 100%;
height: 100%;
object-fit: contain;
}
svg {
width: ${(0,m.h)(14)};
height: ${(0,m.h)(14)};
color: ${d.r.colors.white};
}
.image-upload-remove-button {
cursor: pointer;
position: absolute;
top: ${(0,m.h)(6)};
right: ${(0,m.h)(6)};
background: ${d.r.colors.black};
border-radius: ${(0,m.h)(12)};
padding: ${(0,m.h)(2)};
display: flex;
&:hover {
opacity: 0.8;
}
}
`,K=c.Z.div`
display: flex;
gap: ${(0,m.h)(8)};
margin-top: ${(0,m.h)(18)};
`,Y=(0,i.forwardRef)(({label:e,name:t,error:a,acceptedTypes:n=[o.PNG,o.JPG,o.JPEG],maxSize:r=1,acceptedRatios:l,multiple:c=!1,disabled:u=!1,id:p,className:h,onChange:v,value:f,showValidationRules:b=!1,description:x,useBase64:y=!1,placeholder:w},k)=>{let{t:S}=(0,T.u)(),[N,_]=(0,i.useState)(!1),[I,A]=(0,i.useState)([]),M=(0,i.useRef)(null),O=!!a||I.length>0,$=(0,i.useMemo)(()=>f?Array.isArray(f)?f:[f]:[],[f]),P=(0,i.useCallback)(e=>{var t;let a=[],l="."+(null===(t=e.name.split(".").pop())||void 0===t?void 0:t.toLowerCase());n.includes(l)||a.push(`Unsupported file format. Please upload a ${n.join(", ")} file.`);let o=e.size/1048576;return o>r&&a.push(`File too large. Please upload an image smaller than ${r}MB.`),{file:e,isValid:0===a.length,errors:a}},[n,r]),B=(0,i.useCallback)(e=>new Promise(t=>{if(!l||!l.length||!e.type.startsWith("image/")){t([]);return}let a=new Image;a.onload=()=>{let e=a.width/a.height,n=`${e.toFixed(1)}:1`,r=l.some(t=>{let[a,n]=t.split(":"),r=parseInt(a)/parseInt(n);return .1>Math.abs(e-r)});t(r?[]:[`Image ratio ${n} is not accepted.`])},a.onerror=()=>t(["Invalid image file"]),a.src=URL.createObjectURL(e)}),[l]),D=(0,i.useMemo)(()=>$.map(e=>"string"==typeof e?e:e instanceof File?URL.createObjectURL(e):"").filter(Boolean),[$]),R=(0,i.useCallback)(e=>(0,E.a)(void 0,void 0,void 0,function*(){let a=Array.from(e),n=[],r=[];for(let e of a){let t=P(e),a=yield B(e),l=[...t.errors,...a];0===l.length?r.push(e):n.push(...l)}if(A(n),0===r.length)return;let l=y?yield handleMultipleImageFiles(r):r;v({target:{name:t,value:c?[...$,...l]:l.slice(0,1)}})}),[P,B,c,v,t,$]),removeFile=e=>{let a=$.filter((t,a)=>a!==e);A([]),v({target:{name:t,value:c?a:""}})},U=(0,i.useCallback)(e=>{M.current=e,"function"==typeof k?k(e):k&&(k.current=e)},[k]),z=(0,i.useCallback)(()=>{!u&&M.current&&M.current.click()},[u]),L=(0,i.useCallback)(e=>{e.preventDefault(),e.stopPropagation(),_(!0)},[]),j=(0,i.useCallback)(e=>{e.preventDefault(),e.stopPropagation(),_(!1)},[]),F=(0,i.useCallback)(e=>{e.preventDefault(),e.stopPropagation()},[]),H=(0,i.useCallback)(e=>{e.preventDefault(),e.stopPropagation(),_(!1);let t=e.dataTransfer.files;t.length>0&&R(t)},[R]);return i.createElement(G,{className:h},i.createElement("label",{htmlFor:p||t},"string"==typeof e?i.createElement(s.T,{size:"title2"},e):e,x&&i.createElement(s.T,{size:"p3",mt:(0,m.h)(4),color:d.r.colors.gray700},x)),b&&i.createElement(W,null,i.createElement(s.T,{size:"p3"},"Formats: ",n.join("/")),l&&i.createElement(s.T,{size:"p3"},"Max size: ",r,"MB - Accepted ratios:"," ",l.join("/"))),(c||0===$.length)&&i.createElement(V,{className:(0,g.default)(N&&"image-upload-dragover",O&&"image-upload-error",u&&"image-upload-disabled"),onDragEnter:L,onDragLeave:j,onDragOver:F,onDrop:H,onClick:z},i.createElement("input",{ref:U,type:"file",id:p||t,name:t,accept:n.join(","),multiple:c,onChange:e=>{let t=e.target.files;t&&t.length>0&&R(t)},disabled:u}),i.createElement(Upload,null),i.createElement(s.T,{size:"p3",fw:500},w||S("common.btn.uploadPhoto"))),$.length>0&&i.createElement(K,null,D.map((e,t)=>i.createElement(q,{key:t},i.createElement("img",{src:e,alt:`Uploaded file ${t+1}`,className:"image-upload-preview-image"}),i.createElement("button",{onClick:e=>{e.stopPropagation(),removeFile(t)},className:"image-upload-remove-button"},i.createElement(C.C,null))))),O&&i.createElement("div",{className:"image-upload-input-error"},[...I,a].map(e=>i.createElement(s.T,{key:e,className:"error-text",size:"c1",color:d.r.colors.red600},e))))}),X=(0,c.Z)(k.l)`
& .mantine-Carousel-control {
width: auto;
}
`,DragFreeCarousel=e=>{var{children:t,gapItem:a=8,slideSize:n="auto",withControls:r=!1,withIndicators:l=!1,dragFree:o=!0,align:s="start"}=e,c=(0,E._)(e,["children","gapItem","slideSize","withControls","withIndicators","dragFree","align"]);return i.createElement(X,Object.assign({slideSize:n,slideGap:a,withControls:r,withIndicators:l,dragFree:o,align:s,containScroll:"trimSnaps"},c),i.Children.map(t,(e,t)=>i.createElement(k.l.Slide,{key:t},e)))}},cphq:function(e,t,a){a.d(t,{C:function(){return CardAuthor},P:function(){return PopupExpert},a:function(){return PopupDoctor},b:function(){return PopupHospital},c:function(){return ProfileDetailModal},d:function(){return CardAuthor$1}});var n=a("q1tI"),r=a("Frvz"),l=a("daqB"),o=a("/npG"),i=a("Eso5"),s=a("SPK5"),c=a("mAfZ"),d=a("mYVa"),u=a("Wgwc"),p=a.n(u),m=a("QgiU"),g=a.n(m),h=a("ZKGu"),v=a("K2Xj"),f=a("B6Ol"),E=a("V2lD"),b=a("6eqW"),x=a("XaQQ"),y=a("EDn0"),w=a("i2MM"),C=a("4fTT"),T=a("Jn/A"),k=a("ZQ3V"),S=a("iBNF"),N=a("rBCA"),_=a("IQVP"),I=a("WpsW"),A=a("OGdO"),M=a("gOIo"),O=a("xrdX");let MainText=({children:e,className:t=""})=>n.createElement("div",{className:`tMiOKib ${t}`},e),SubText=({children:e,className:t=""})=>n.createElement("div",{className:`uDcqD-2 ${t}`},e);var $={container:"sTU4T4I",info:"tCql9Je",avatarWrapper:"_3j7uYhH",avatarIcon:"PHABgoT"};let CardAuthor$1=({avatarProps:e,title:t,subTitle:a,children:r,className:l="",style:o,onAvatarClick:i,avatarIcon:s,dataEventCategory:c,dataEventAction:d,dataEventLabel:u})=>n.createElement("div",{className:`${$.container} ${l}`,style:o},n.createElement("div",{className:$.avatarWrapper,onClick:i,"data-event-category":c,"data-event-action":d,"data-event-label":u},n.createElement(x.U,Object.assign({},e)),s&&n.createElement("div",{className:$.avatarIcon},s)),n.createElement("div",{className:`${$.info} ${l}`,style:{minHeight:`${(null==e?void 0:e.size)||40}px`}},r||n.createElement(n.Fragment,null,t&&n.createElement(MainText,null,t),a&&n.createElement(SubText,null,a))));CardAuthor$1.MainText=MainText,CardAuthor$1.SubText=SubText,CardAuthor$1.SubDivider=({className:e=""})=>n.createElement("span",{className:`m-HVXw1 ${e}`}),CardAuthor$1.Row=({children:e,className:t=""})=>n.createElement("div",{className:`dZWeHns ${t} row`},e),CardAuthor$1.ColLeft=({children:e,className:t=""})=>n.createElement("div",{className:`${t} col-left`},e),CardAuthor$1.ColRight=({children:e,className:t=""})=>n.createElement("div",{className:`${t} col-right`},e),CardAuthor$1.SubTextRow=e=>{var{children:t,className:a=""}=e,r=(0,b._)(e,["children","className"]);return n.createElement("div",Object.assign({className:`pDlsows ${a}`},r),t)};var P=(0,o.k)(()=>({root:{verticalAlign:"bottom"}}));let B=(0,n.createContext)({}),AuthorBadgeItem=({styles:e,className:t,classNames:a})=>{let{role:r,siteType:l,title:o}=(0,n.useContext)(B),{cx:i,classes:s}=P(void 0,{name:"AuthorBadgeItem",styles:e,classNames:a});return r?n.createElement(f.A,{className:i(s.root,t),siteType:l,role:r,title:o}):null};var D=(0,o.k)(()=>({root:{}}));let R=N.Z.div`
position: fixed;
left: 50%;
width: 343px;
background-color: ${S.r.colors.white};
border-radius: ${S.r.borderRadius};
box-shadow: 0px 0px 4px ${S.r.colors.gray200};
transform: translate(-50%, -50%);
transition: all 0.5s ease-in-out;
${v.M.tdUp} {
width: 750px;
}
&[data-animation='true'] {
transition: all 0.5s ease-in-out;
}
&[data-open='true'] {
z-index: 400;
top: 50%;
opacity: 1;
visibility: visible;
}
&[data-open='false'] {
top: -50%;
}
.popup-content {
${v.M.mbDown} {
display: block;
}
display: flex;
position: relative;
z-index: 111;
height: 100%;
.button-see-more {
margin: 32px 0;
padding: 0;
> * {
display: inline-block;
}
}
.close-button {
position: absolute;
z-index: 100;
top: 10px;
right: 10px;
cursor: pointer;
width: unset;
height: unset;
img {
width: 100%;
height: 100%;
border-radius: 50%;
}
}
}
.main-info {
padding-bottom: 32px;
background-color: ${S.r.colors.primary50};
border-radius: ${S.r.borderRadius};
.btn-booking {
display: flex;
margin: 12px auto;
}
.avatar-title {
position: relative;
width: 100%;
padding-top: 46px;
text-align: center;
}
}
`,U=N.Z.div`
position: fixed;
z-index: 110;
top: 0;
left: 0;
width: 100%;
height: 100%;
align-items: center;
background: rgba(38, 38, 38, 0.3);
&[data-open='false'] {
display: none;
}
`,z=N.Z.div`
.image-container {
.badge-avatar {
position: absolute;
right: 0;
bottom: 0;
top: 0;
}
}
display: flex;
justify-content: center;
padding-bottom: 15px;
text-align: center;
.profile-image {
width: 100px;
min-width: 100px;
height: 100px;
min-height: 100px;
border-radius: 50%;
object-fit: cover;
}
.badge-avatar {
width: 24px;
height: 24px;
}
`,L=N.Z.div`
position: relative;
z-index: 9;
.specialty {
display: flex;
flex-wrap: wrap;
justify-content: center;
}
padding: 0px 16px;
text-align: center;
.specialty {
justify-content: center;
}
.experience {
padding: 16px 0px 32px;
text-align: left;
.btn-wrapper {
margin-top: 24px;
}
}
p {
max-width: 100%;
-webkit-line-clamp: 4;
-webkit-box-orient: vertical;
text-overflow: ellipsis;
overflow: hidden;
}
`,j=N.Z.ul`
padding-left: 18px;
li {
list-style-type: disc;
}
`;var F="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none'%3e%3cpath stroke='%23262626' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M18 6 6 18M6 6l12 12'/%3e%3c/svg%3e",H="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none'%3e%3cpath fill='white' stroke='%23E4E8EC' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.75' d='M9 17A8 8 0 1 0 9 1a8 8 0 0 0 0 16'/%3e%3cpath fill='%23FF5331' d='M10.333 7.667V5H7.667v2.667H5v2.667h2.667V13h2.666v-2.666H13V7.667z'/%3e%3c/svg%3e";let PopupDoctor=({isOpen:e=!0,onClose:t,enableAnimation:a=!0,doctorId:r,locale:l,isMobile:o,overwriteProfileProps:i,avatarFallback:s=w.C.getAssetPath("avatar.jpg"),trackingCategory:c="Together"})=>{var d,u,p;let{t:m}=(0,h.u)(),[g,v]=(0,n.useState)(null),[f,E]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(e&&r&&String(null==g?void 0:g.id)!==String(r)){E(!0);try{v(null),(0,C.c)((0,C.b)(_.tC.GET_DOCTOR_INFO,{doctorId:r,website_url:C.m[l]}),"get").then(e=>{v(Object.assign(Object.assign({},null==e?void 0:e._data.doctor),i))})}catch(e){console.error(e)}E(!1)}},[e,r,null==g?void 0:g.id]);let b=(null==g?void 0:g.experiences)||[],x=(null==g?void 0:g.specialties)||[],N=x.map(e=>(null==e?void 0:e.name)||e).join(" • "),A=b.map(e=>{try{return JSON.parse(e.description)}catch(t){return e.description}}).filter(e=>e.content),renderExperienceText=e=>(null==e?void 0:e.year)?`${e.year} ${null==e?void 0:e.content}`:(null==e?void 0:e.content)?e.content:"string"==typeof e?e:"";return n.createElement(n.Fragment,null,n.createElement(R,{"data-open":e,"data-animation":a,onClick:e=>e.stopPropagation()},f||!g?n.createElement(I.L,null):n.createElement("div",{className:"popup-content"},n.createElement("div",{className:"close-button",onClick:t},n.createElement("img",{src:F,style:{width:20,height:20},alt:"close-icon",loading:"lazy"})),n.createElement("div",{className:"main-info"},n.createElement("div",{className:"border-banner"}),n.createElement("div",{className:"avatar-title"},n.createElement(z,null,n.createElement("div",{className:"image-container"},n.createElement("div",{style:{position:"relative"}},n.createElement(y.I,{src:null==g?void 0:g.avatar,backupSrc:s,className:"profile-image",alt:"avatar"}),n.createElement("img",{className:"badge-avatar",src:H,alt:"badge",loading:"lazy"})))),n.createElement(L,null,n.createElement(k.T,{size:"s3",weight:"semiBold",className:"full-name"},null==g?void 0:g.name),n.createElement("div",{className:"specialty"},N&&n.createElement(n.Fragment,null,n.createElement(k.T,{size:"p4",color:S.r.colors.gray800},N," • ")),n.createElement("a",{href:(0,C.n)({id:null===(d=null==g?void 0:g.organization)||void 0===d?void 0:d.id,name:null===(u=null==g?void 0:g.organization)||void 0===u?void 0:u.name,slug:null===(p=null==g?void 0:g.organization)||void 0===p?void 0:p.slug,locale:l}),className:"organisation",target:"_blank",rel:"noreferrer"},n.createElement(k.T,{size:"p4",className:"organisation",color:S.r.colors.gray800,style:{textDecoration:"underline"}},null==g?void 0:g.organization.name))))),!o&&n.createElement("div",{className:"btn-wrapper"},n.createElement("a",{href:(0,C.o)({name:g.name,id:g.id,locale:l})},n.createElement(T.B,{color:"primary",size:"md",className:"btn-booking"},m("careBooking.bookAnAppointment"))))),A&&n.createElement(L,null,n.createElement("div",{className:"experience"},n.createElement(k.T,{weight:"bold",size:"s3",color:S.r.colors.gray800,style:{paddingBottom:16}},m("expert.content.description").toUpperCase()),n.createElement(j,null,A.map((e,t)=>n.createElement("li",{key:t},n.createElement(k.T,{size:"p2"},renderExperienceText(e))))),o?n.createElement("div",{className:"btn-wrapper"},n.createElement("a",{href:(0,C.o)({name:g.name,id:g.id,locale:l})},n.createElement(T.B,{color:"primary",size:"md",className:"btn-booking"},m("careBooking.bookAnAppointment")))):n.createElement("a",{href:(0,C.o)({name:g.name,id:g.id,locale:l})},n.createElement(k.T,{size:"s4",color:"#2D87F3",style:{paddingTop:24},"data-event-category":c,"data-event-action":"See Full Doctor Profile","data-event-label":(0,C.l)(l)+(0,C.o)({name:g.name,id:g.id,locale:l})},m("home.seeExpert"))))))),n.createElement(U,{"data-open":e,onClick:e=>{e.stopPropagation(),t()}}))},Z=N.Z.div`
position: fixed;
left: 50%;
width: 343px;
background-color: ${S.r.colors.white};
border-radius: ${S.r.borderRadius};
box-shadow: 0px 0px 4px ${S.r.colors.gray200};
transform: translate(-50%, -50%);
transition: all 0.5s ease-in-out;
${v.M.tdUp} {
width: 750px;
}
&[data-animation='true'] {
transition: all 0.5s ease-in-out;
}
&[data-open='true'] {
z-index: 400;
top: 50%;
opacity: 1;
visibility: visible;
}
&[data-open='false'] {
top: -50%;
}
.popup-content {
${v.M.mbDown} {
display: block;
}
display: flex;
position: relative;
z-index: 111;
height: 100%;
.button-see-more {
margin: 32px 0;
padding: 0;
> * {
display: inline-block;
}
}
.close-button {
position: absolute;
z-index: 100;
top: 10px;
right: 10px;
cursor: pointer;
width: unset;
height: unset;
img {
width: 100%;
height: 100%;
border-radius: 50%;
}
}
}
.main-info {
padding-bottom: 32px;
background-color: ${S.r.colors.primary50};
border-radius: ${S.r.borderRadius};
.avatar-title {
position: relative;
width: 100%;
padding-top: 46px;
text-align: center;
}
}
`,G=N.Z.div`
position: fixed;
z-index: 110;
top: 0;
left: 0;
width: 100%;
height: 100%;
align-items: center;
background: rgba(38, 38, 38, 0.3);
&[data-open='false'] {
display: none;
}
`,W=N.Z.div`
.image-container {
.badge-avatar {
position: absolute;
right: 0;
bottom: 0;
top: 0;
}
}
display: flex;
justify-content: center;
padding-bottom: 15px;
text-align: center;
.profile-image {
width: 100px;
min-width: 100px;
height: 100px;
min-height: 100px;
border-radius: 50%;
object-fit: cover;
}
.badge-avatar {
width: 24px;
height: 24px;
}
`,V=N.Z.div`
position: relative;
z-index: 9;
.specialty {
display: flex;
flex-wrap: wrap;
justify-content: center;
}
padding: 0px 16px;
text-align: center;
.specialty {
justify-content: center;
}
.experience {
padding: 16px 0px 32px;
text-align: left;
.btn-wrapper {
margin-top: 24px;
}
}
p {
max-width: 100%;
-webkit-line-clamp: 4;
-webkit-box-orient: vertical;
text-overflow: ellipsis;
overflow: hidden;
}
`,q=N.Z.div`
display: flex;
margin-top: 8px;
.bullet-point {
width: 24px;
height: 24px;
}
`;var K="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none'%3e%3cpath fill='%2345A4FF' d='M12 24c6.627 0 12-5.373 12-12S18.627 0 12 0 0 5.373 0 12s5.373 12 12 12'/%3e%3cpath fill='%232D87F3' d='M24 12a12 12 0 0 0-.128-1.758l-5.077-5.077L5.041 18.958l4.858 4.858c.682.12 1.384.184 2.1.184 6.628 0 12-5.373 12-12Z'/%3e%3cpath fill='white' d='M9.014 17.824 5.04 18.959l1.135-3.973 2.368.47z'/%3e%3cpath fill='%23F7F9FC' d='M8.544 15.456 5.041 18.96l3.972-1.135z'/%3e%3cpath fill='%23E4E8EC' d='M6.467 18.552 5.45 17.533l-.41 1.427 1.426-.407Z'/%3e%3cpath fill='%23D2D6DC' d='m5.957 18.043-.916.916 1.426-.407z'/%3e%3cpath fill='%23FFD658' d='m15.828 5.331 2.837 2.837-9.651 9.652-2.838-2.837z'/%3e%3cpath fill='%23FFC326' d='m7.594 16.404 9.651-9.651 1.419 1.418-9.652 9.652z'/%3e%3cpath fill='%23FF5331' d='m18.312 8.525-2.837-2.838 1.123-1.123c.44-.44 1.154-.44 1.595 0l1.243 1.243c.44.44.44 1.154 0 1.594z'/%3e%3cpath fill='%23F44D2C' d='m18.816 5.186-1.921 1.92 1.418 1.419 1.124-1.124c.44-.44.44-1.154 0-1.594l-.622-.621Z'/%3e%3c/svg%3e";let Y={author:K,edtior:K,expert:"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none'%3e%3ccircle cx='12' cy='12' r='12' fill='%23FFCB37'/%3e%3ccircle cx='12' cy='12' r='10.5' fill='%23FE921D'/%3e%3cpath fill='white' d='M11.443 5.137a.6.6 0 0 1 1.114 0l1.436 3.577a.6.6 0 0 0 .516.375l3.846.26a.6.6 0 0 1 .344 1.06l-2.958 2.471a.6.6 0 0 0-.197.607l.94 3.738a.6.6 0 0 1-.9.655l-3.265-2.05a.6.6 0 0 0-.638 0l-3.265 2.05a.6.6 0 0 1-.9-.655l.94-3.738a.6.6 0 0 0-.198-.607L5.3 10.41a.6.6 0 0 1 .344-1.06l3.846-.26a.6.6 0 0 0 .517-.375z'/%3e%3c/svg%3e","fact-check":"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none'%3e%3cpath fill='%2300C076' d='M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16'/%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.75' d='m11.946 5.466-5.28 4.8-2.4-2.182'/%3e%3c/svg%3e",medical:H},PopupExpert=({trackingCategory:e="Together",locale:t,isOpen:a=!0,onClose:r,enableAnimation:l=!0,expertId:o,overwriteProfileProps:i,avatarFallback:s=w.C.getAssetPath("avatar.jpg")})=>{let{t:c}=(0,h.u)(),[d,u]=(0,n.useState)(null),[p,m]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{if(a&&o&&String(null==d?void 0:d.user_id)!==String(o)){m(!0);try{u(null),(0,C.c)((0,C.g)(_.D9.GET_EXPERT_BY_ID,{id:o}),"get").then(e=>{u(Object.assign(Object.assign({},null==e?void 0:e.data),i))})}catch(e){console.error(e)}m(!1)}},[a,o,null==d?void 0:d.user_id]),n.createElement(n.Fragment,null,n.createElement(Z,{"data-open":a,"data-animation":l,onClick:e=>e.stopPropagation()},p||!d?n.createElement(I.L,null):n.createElement("div",{className:"popup-content"},n.createElement("div",{className:"close-button",onClick:r},n.createElement("img",{src:F,style:{width:20,height:20},alt:"close-icon",loading:"lazy"})),n.createElement("div",{className:"main-info"},n.createElement("div",{className:"border-banner"}),n.createElement("div",{className:"avatar-title"},n.createElement(W,null,n.createElement("div",{className:"image-container"},n.createElement("div",{style:{position:"relative"}},n.createElement(y.I,{src:null==d?void 0:d.avatar,className:"profile-image",alt:"avatar",backupSrc:s}),n.createElement("img",{className:"badge-avatar",src:Y[null==d?void 0:d.role],alt:"badge",loading:"lazy"})))),n.createElement(V,null,n.createElement(k.T,{size:"s3",className:"full-name",weight:"semiBold"},null==d?void 0:d.display_name),n.createElement("div",null,n.createElement(k.T,{size:"p4",color:S.r.colors.gray800},null==d?void 0:d.specialty," • "),n.createElement("a",{href:null==d?void 0:d.organisation_url,className:"organisation",target:"_blank",rel:"noreferrer"},n.createElement(k.T,{size:"p4",className:"organisation",color:S.r.colors.gray800,style:{textDecoration:"underline"}},null==d?void 0:d.organisation)))))),n.createElement(V,null,n.createElement("div",{className:"experience"},n.createElement(k.T,{weight:"bold",size:"p4",color:S.r.colors.gray800,style:{paddingBottom:16}},c("expert.content.description").toUpperCase()),n.createElement("div",{className:"list-items"},null!=d&&!!d.experiences&&d.experiences.filter(e=>!!(e&&(e.title||e.organization))).slice(0,3).map((e,t)=>n.createElement(q,{key:t},n.createElement("img",{className:"bullet-point",src:"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none'%3e%3ccircle cx='12' cy='12' r='2' fill='%232D87F3'/%3e%3c/svg%3e",alt:"point",loading:"lazy"}),n.createElement("div",{className:"text-contain"},n.createElement(A.H,{tag:"h6",color:S.r.colors.gray800},null==e?void 0:e.title),n.createElement(k.T,{size:"p2",color:S.r.colors.gray500},null==e?void 0:e.organization))))),n.createElement("a",{href:null==d?void 0:d.profile_url,style:{display:"inline-block",paddingTop:24}},n.createElement(k.T,{as:"span",size:"s4",color:"#2D87F3","data-event-category":e,"data-event-action":"See Full Doctor Profile","data-event-label":(0,C.l)(t)+(null==d?void 0:d.profile_url)},c("home.seeExpert"))))))),n.createElement(G,{"data-open":a,onClick:e=>{e.stopPropagation(),r()}}))},X=N.Z.div`
position: fixed;
left: 50%;
width: 343px;
background-color: ${S.r.colors.white};
border-radius: ${S.r.borderRadius};
box-shadow: 0px 0px 4px ${S.r.colors.gray200};
transform: translate(-50%, -50%);
transition: all 0.5s ease-in-out;
${v.M.tdUp} {
width: 750px;
}
&[data-animation='true'] {
transition: all 0.5s ease-in-out;
}
&[data-open='true'] {
z-index: 400;
top: 50%;
opacity: 1;
visibility: visible;
}
&[data-open='false'] {
top: -50%;
}
.popup-content {
${v.M.mbDown} {
display: block;
}
display: flex;
position: relative;
z-index: 111;
height: 100%;
.button-see-more {
margin: 32px 0;
padding: 0;
> * {
display: inline-block;
}
}
.close-button {
position: absolute;
z-index: 100;
top: 10px;
right: 10px;
cursor: pointer;
width: unset;
height: unset;
img {
width: 100%;
height: 100%;
border-radius: 50%;
}
}
}
.main-info {
padding-bottom: 32px;
background-color: ${S.r.colors.primary50};
border-radius: ${S.r.borderRadius};
.btn-booking {
display: flex;
margin: 12px auto;
}
.avatar-title {
position: relative;
width: 100%;
padding-top: 46px;
text-align: center;
}
}
`,Q=N.Z.div`
position: fixed;
z-index: 110;
top: 0;
left: 0;
width: 100%;
height: 100%;
align-items: center;
background: rgba(38, 38, 38, 0.3);
&[data-open='false'] {
display: none;
}
`,J=N.Z.div`
.image-container {
.badge-avatar {
position: absolute;
right: 0;
bottom: 0;
top: 0;
}
}
display: flex;
justify-content: center;
padding-bottom: 15px;
text-align: center;
.profile-image {
width: 100px;
min-width: 100px;
height: 100px;
min-height: 100px;
border-radius: 50%;
object-fit: cover;
}
.badge-avatar {
width: 24px;
height: 24px;
}
`,ee=N.Z.div`
position: relative;
z-index: 9;
.specialty {
display: block;
min-width: 240px;
}
padding: 0px 16px;
text-align: center;
.specialty {
justify-content: center;
}
.experience {
padding: 16px 0px 32px;
text-align: left;
.btn-wrapper {
margin-top: 24px;
}
}
p {
max-width: 100%;
}
`,PopupHospital=({isOpen:e=!0,onClose:t,enableAnimation:a=!0,hospitalId:r,locale:l,isMobile:o,overwriteProfileProps:i,avatarFallback:s=w.C.getAssetPath("avatar.jpg"),trackingCategory:c="Together"})=>{let{t:d}=(0,h.u)(),[u,p]=(0,n.useState)(null),[m,g]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(e&&r&&String(null==u?void 0:u.id)!==String(r)){g(!0);try{p(null),(0,C.c)((0,C.b)(_.tC.GET_HOSPITAL_INFO,{hospital_branch_id:r,website_url:C.m[l]}),"get").then(e=>{p(Object.assign(Object.assign({},null==e?void 0:e._data.branch),i))})}catch(e){console.error(e)}g(!1)}},[e,r,null==u?void 0:u.id]);let v=(null==u?void 0:u.specialties)||[],f=(0,n.useMemo)(()=>v.map(e=>e.name),[v]);return n.createElement(n.Fragment,null,n.createElement(X,{"data-open":e,"data-animation":a,onClick:e=>e.stopPropagation()},m||!u?n.createElement(I.L,null):n.createElement("div",{className:"popup-content"},n.createElement("div",{className:"close-button",onClick:t},n.createElement("img",{src:F,style:{width:20,height:20},alt:"close-icon",loading:"lazy"})),n.createElement("div",{className:"main-info"},n.createElement("div",{className:"border-banner"}),n.createElement("div",{className:"avatar-title"},n.createElement(J,null,n.createElement("div",{className:"image-container"},n.createElement("div",{style:{position:"relative"}},n.createElement(y.I,{src:null==u?void 0:u.logo,className:"profile-image",alt:"avatar",backupSrc:s}),n.createElement("img",{className:"badge-avatar",src:H,alt:"badge",loading:"lazy"})))),n.createElement(ee,null,n.createElement(k.T,{size:"s3",weight:"semiBold",className:"full-name"},null==u?void 0:u.name),n.createElement("div",{className:"specialty"},v&&n.createElement(k.T,{size:"p4",color:S.r.colors.gray800},f.join(" • "),"•"),n.createElement("a",{href:(0,C.n)({id:u.id,name:u.name,slug:u.slug,locale:l}),className:"organisation",target:"_blank",rel:"noreferrer"},n.createElement(k.T,{size:"p4",className:"organisation",color:S.r.colors.gray800,style:{textDecoration:"underline"}},null==u?void 0:u.name))))),!o&&n.createElement("a",{href:(0,C.n)({id:u.id,name:u.name,slug:u.slug,locale:l})},n.createElement("div",{className:"btn-wrapper"},n.createElement(T.B,{color:"primary",size:"md",className:"btn-booking"},d("careBooking.bookAnAppointment"))))),n.createElement(ee,null,n.createElement("div",{className:"experience"},n.createElement(k.T,{weight:"bold",size:"s3",color:S.r.colors.gray800,style:{paddingBottom:16}},d("hospital.content.description").toUpperCase()),n.createElement(k.T,{size:"p2",color:S.r.colors.gray500},u.about),o?n.createElement("a",{href:(0,C.n)({id:u.id,name:u.name,slug:u.slug,locale:l})},n.createElement("div",{className:"btn-wrapper"},n.createElement(T.B,{color:"primary",size:"md",className:"btn-booking"},d("careBooking.bookAnAppointment")))):n.createElement("a",{href:(0,C.n)({id:u.id,name:u.name,slug:u.slug,locale:l})},n.createElement(k.T,{size:"s4",color:"#2D87F3",as:"span","data-event-category":c,"data-event-action":"See Full Hospital Profile","data-event-label":(0,C.l)(l)+(0,C.n)({id:u.id,name:u.name,slug:u.slug,locale:l})},d("home.seeHospital"))))))),n.createElement(Q,{"data-open":e,onClick:e=>{e.stopPropagation(),t()}}))},ProfileDetailModal=({open:e,onClose:t,children:a,profileModalProps:r})=>{let{t:l}=(0,h.u)();return n.createElement(M.M,Object.assign({title:l("profilePanel.modal.heading"),titleProps:!0,className:"_2UKyiK1",opened:e,onClose:t,overlayOpacity:.2,overflow:"inside",transitionProps:{transition:"slide-left"},styles:{header:{borderBottom:0},inner:{padding:0,justifyContent:"flex-end"},modal:{height:"100%",borderRadius:0},body:{maxHeight:"100%"},content:{maxHeight:"100%",height:"100%",borderRadius:0}}},r),a)};p().extend(g());let CardAuthor=e=>{let{className:t="",community:o,name:u,username:p,url:m,avatar:g,role:b,title:x,userType:T="user",expertId:k,specialty:N,organisation:_,isMarryBaby:I,doctorId:A,hospitalId:M,hasQuickBooking:$,handleMakeAppointment:P,communityTrackingAttr:R,isAnonymous:U,showDetailPopup:z,showChatbotButton:L=!1,subLine:j,authActionWrapper:F,profileProps:H,profileModalProps:Z,extendEle:G,avatarProps:W,hideInfo:V,timeText:q,onCloseFromPost:K,onChatWithBot:Y,avatarIcon:X,badgeIconSize:Q,hideBackground:J,children:ee,styles:et,dataEventCategory:ea,dataEventAction:en,dataEventLabel:er}=e,{data:{locale:el,router:eo,env:{isMarryBaby:ei,togetherBasePath:es}}}=(0,n.useContext)(C.T),{isMobile:ec}=(0,y.u)(),{t:ed}=(0,h.u)(),{classes:eu}=D(void 0,{name:"CardAuthor",styles:et}),ep="boolean"==typeof I?I:ei,em=ep?"marryBaby":"helloSites",eg=U?ed("cardPost.anonymous"):u||p||"",eh=U?w.C.getAssetPath("avatar.jpg"):g,ev=U?void 0:b,[ef,eE]=(0,n.useState)(!1),{asPath:eb}=eo||{},ex=`https://${O.v[el]}${eb}`,onAuthorClick=()=>{if(U)return!1;z?ew(!0):m&&(window.location.href=m)};(0,n.useEffect)(()=>{(0,v.t)(ef)},[ef]);let[ey,ew]=(0,n.useState)(!1),eC=(null==e?void 0:e.role)==="expert",eT=!!(A||M),ek=["expert"===ev&&_&&n.createElement("span",null,_),"expert"===ev&&N&&n.createElement("span",null,N),!("expert"===ev&&N&&_)&&(null==o?void 0:o.name)&&n.createElement("a",Object.assign({href:(null==o?void 0:o.slug)&&o.isActive&&!o.isHidden?`${es}/${null==o?void 0:o.slug}/`:void 0,className:"author-community-name"},R),`${null==o?void 0:o.name}`),q&&n.createElement("span",null,q)].filter(Boolean),[eS,eN]=(0,n.useState)(null);return(0,n.useEffect)(()=>{ey&&!eS&&("chatbot"===T?Promise.all([a.e(5231),a.e(7797),a.e(5454),a.e(106),a.e(9803),a.e(5349),a.e(4148),a.e(2509),a.e(1533),a.e(1108),a.e(9124),a.e(4190),a.e(4447),a.e(6509),a.e(8674),a.e(4125),a.e(9557),a.e(5207),a.e(7730),a.e(137),a.e(4414),a.e(7613),a.e(8098),a.e(3416),a.e(2500),a.e(1570),a.e(3506),a.e(1413)]).then(a.bind(a,"NKjB")).then(e=>{eN(()=>e.ProfileChatbot)}):Promise.all([a.e(9409),a.e(6259),a.e(1818),a.e(7519),a.e(761),a.e(2189),a.e(5231),a.e(7797),a.e(5454),a.e(106),a.e(9803),a.e(5349),a.e(4148),a.e(2509),a.e(1533),a.e(1108),a.e(9124),a.e(4190),a.e(4447),a.e(6509),a.e(8674),a.e(4125),a.e(9557),a.e(5207),a.e(7730),a.e(137),a.e(4414),a.e(7613),a.e(8098),a.e(3416),a.e(2500),a.e(1570),a.e(3506),a.e(1413)]).then(a.bind(a,"aUqw")).then(e=>{eN(()=>e.ProfileDetail)}))},[ey,T]),n.createElement(B.Provider,{value:{displayName:eg,title:x,role:ev,siteType:em,handleMakeAppointment:P,doctorId:A,hospitalId:M,currentUrl:ex}},n.createElement(ProfileDetailModal,{open:ey,onClose:()=>ew(!1),profileModalProps:Z},eS&&n.createElement(eS,Object.assign({currentPageUrl:er,authActionWrapper:F,onCloseFromPost:()=>{ew(!1),null==K||K()},onChatWithBot:Y},H,{authorProps:Object.assign({userId:null==e?void 0:e.userId,avatar:eh,name:null==e?void 0:e.name,role:null==e?void 0:e.role,title:null==e?void 0:e.title,doctorId:A,hospitalId:M,hasQuickBooking:$,userType:T},null==H?void 0:H.authorProps)}))),"expert"===ev&&k?n.createElement(PopupExpert,{isOpen:ef,onClose:()=>eE(!1),expertId:k}):null,"expert"===ev&&A?n.createElement(PopupDoctor,{isOpen:ef,onClose:()=>eE(!1),doctorId:A,locale:el}):null,"expert"===ev&&M?n.createElement(PopupHospital,{isOpen:ef,onClose:()=>eE(!1),hospitalId:M,locale:el}):null,n.createElement("div",{className:`hhg-card-author ${eu.root} ${t} ${eC?"expert-author":""}`,"data-background":!J&&eC,"data-is-marrybaby":ep},n.createElement(CardAuthor$1,{dataEventCategory:ea,dataEventAction:en,dataEventLabel:er,onAvatarClick:onAuthorClick,avatarProps:Object.assign(Object.assign({avatar:U?w.C.getAssetPath(ep?"anomyous-avatar-1.svg":"anomyous-avatar.svg"):eh,username:eg},W),{style:{cursor:!U&&(m||z)?"pointer":"default"}}),avatarIcon:X||eC&&n.createElement(r.Z,{size:Q||15})},ee?n.createElement("div",{onClick:onAuthorClick},ee):!V&&n.createElement(CardAuthor$1.Row,null,n.createElement(CardAuthor$1.ColLeft,null,n.createElement(s.k,{align:"center",onClick:onAuthorClick},n.createElement(CardAuthor$1.MainText,{onClick:onAuthorClick},eg,"chatbot"===T?n.createElement(n.Fragment,null," ",n.createElement(l.Z,{color:S.r.colors.primaryBase,size:16,style:{display:"inline-block",transform:"translate(0, 2px)"}}),L&&n.createElement("div",{style:{marginTop:"8px"}},n.createElement(c.z,{color:"primary",size:"xs",variant:"filled",type:"button",leftIcon:n.createElement(E.I.App,{size:16}),onClick:()=>{null==Y||Y()}},ed("chatbot.with.me")))):n.createElement(AuthorBadgeItem,null))),j||n.createElement(CardAuthor$1.SubTextRow,{style:$?{position:"relative"}:{}},ek.map((e,t)=>n.createElement(n.Fragment,null,0!==t&&n.createElement(CardAuthor$1.SubDivider,null),n.createElement(CardAuthor$1.SubText,null,e))),$&&eT&&n.createElement(i.x,{sx:{marginTop:(0,d.h)(5)}},n.createElement(f.B,{bookingId:A||M,bookingType:A?"doctor":M?"hospital":void 0,size:ec?"xs":"sm"})))))),G&&G))};CardAuthor.MainText=CardAuthor$1.MainText,CardAuthor.SubText=CardAuthor$1.SubText,CardAuthor.SubTextRow=CardAuthor$1.SubTextRow,CardAuthor.SubDivider=CardAuthor$1.SubDivider,CardAuthor.AuthorBadge=AuthorBadgeItem,CardAuthor.DisplayName=()=>{let{displayName:e}=(0,n.useContext)(B);return n.createElement(i.x,null,e)}},EiU1:function(e,t,a){a.d(t,{F:function(){return Footer}});var n=a("q1tI"),r=a("zggI"),l=a("Wgwc"),o=a.n(l),i=a("SPK5"),s=a("OAL+"),c=a("Eso5"),d=a("ZQ3V"),u=a("K2Xj"),p=a("EDn0"),m=a("rBCA"),g=a("iBNF"),h=a("xrdX"),v=a("rXLr"),f=a("sknb");let E=m.Z.footer`
background-color: #1b3250;
.inner {
padding: 64px 24px 98px 24px;
margin: 0 auto;
}
.newsletter {
padding: 24px 0;
}
.footer-logo {
max-width: 132px;
max-height: 32px;
&[data-is-sehat='true'] {
max-width: 250px;
}
img {
object-fit: contain;
}
}
.social {
margin-top: 24px;
display: flex;
align-items: center;
gap: 16px;
flex-wrap: wrap;
> .icons {
display: flex;
gap: 16px;
}
}
hr {
height: 1px;
border: none;
margin: 16px 0 16px 0;
background: ${g.r.colors.neutral500};
opacity: 0.1;
outline: none;
}
.footer-menu-column {
min-width: 168px;
}
.footer-menu-title {
margin-bottom: 16px;
}
.footer-menu-link {
display: block;
}
.footer-menu-link-wrapper {
display: flex;
flex-direction: column;
gap: 12px;
}
.copyright {
display: flex;
flex-direction: column;
gap: 16px;
padding-top: 8px;
.copyright-content {
color: ${g.r.colors.neutral500};
font-size: 12px;
}
.copyright-image-wrapper {
flex-shrink: 0;
flex-wrap: wrap;
display: flex;
gap: 16px;
justify-content: flex-end;
.copyright-image {
align-self: flex-start;
img {
height: 32px;
}
}
}
}
.otherSites {
display: flex;
gap: 16px;
align-items: center;
padding: 19px 0;
border-top: 1px solid ${g.r.colors.neutral100}1a;
border-bottom: 1px solid ${g.r.colors.neutral100}1a;
.flags {
display: flex;
gap: 12px;
}
}
.signupButton {
display: none;
border: none;
margin-top: 16px;
outline: none;
text-transform: uppercase;
}
${u.M.mbDown} {
.inner {
padding: 64px 0;
}
.social {
flex-direction: column;
gap: 10px;
align-items: start;
}
hr {
margin-top: 0px;
}
.copyright {
align-items: center;
text-align: center;
}
.copyright-image-wrapper {
justify-content: center;
max-width: unset;
}
.otherSites {
flex-direction: column;
padding: 24px 0;
.linkTitle {
text-align: center;
}
.flags {
flex-wrap: wrap;
justify-content: center;
}
}
.footer-menu-title {
margin-bottom: 12px;
}
.footer-menu {
display: grid;
grid-template-columns: repeat(2, 1fr);
> .footer-menu-column {
padding: 24px 0;
}
> .footer-menu-column:first-child {
grid-column-start: 1;
grid-column-end: 3;
border-top: 1px solid ${g.r.colors.neutral100}1a;
border-bottom: 1px solid ${g.r.colors.neutral100}1a;
> .footer-menu-link-wrapper {
display: grid;
grid-template-columns: repeat(2, 1fr);
}
}
}
.otherSites {
margin-bottom: 24px;
}
}
${u.M.mbUp} {
.newsletter > p {
max-width: 360px;
}
.hrMobile {
display: none;
}
.copyright {
gap: 24px;
flex-direction: row-reverse;
align-items: center;
justify-content: space-between;
}
.otherSites {
margin-bottom: 40px;
}
.columns {
display: flex;
flex-direction: row;
width: 100%;
gap: 16px;
margin-bottom: 40px;
> div:nth-child(1) {
display: flex;
flex-direction: column;
flex: 1;
}
> div:nth-child(2) {
display: flex;
flex-direction: row;
gap: 24px;
}
}
}
`,b=m.Z.img`
width: 32px;
height: 32px;
${u.M.mbDown} {
width: 24px;
height: 24px;
}
.country-flag {
width: 100%;
height: 100%;
}
`,Flag=({url:e,dataEventCategory:t,dataEventAction:a,dataEventLabel:r})=>n.createElement(b,{loading:"lazy",className:"country-flag",src:e,alt:"Country Flag","data-event-category":t,"data-event-action":a,"data-content-label":r}),FooterMenuColumn=({title:e,items:t,locale:a,index:r})=>{let{isMobile:l}=(0,p.u)();return n.createElement("div",{className:"footer-menu-column"},e?n.createElement(d.T,{size:l?"s4":"s3",className:"footer-menu-title",weight:l?"regular":"semiBold",color:"neutral.6"},e):null,n.createElement("div",{className:"footer-menu-link-wrapper"},null==t?void 0:t.map((e,t)=>n.createElement(d.T,{size:l?"p3":"p4",as:"a","data-event-category":"Footer","data-event-action":e.title,"data-event-label":`https://${h.v[a]}${e.url}`,className:"footer-menu-link",href:e.url,key:t,color:"#fff",weight:l&&0===r?"semiBold":"regular"},e.title))))},DiscoverFooter=({className:e,footerInfo:t,locale:a})=>{var l,i,s,c,u,m,g,h,v,f,b;let{isMobile:x}=(0,p.u)(),y=null==t?void 0:t.menu,w=(null===(i=null===(l=null==t?void 0:t.general)||void 0===l?void 0:l.verified)||void 0===i?void 0:i.filter(Boolean))||[];return n.createElement(E,{className:e},n.createElement(r.C,null,n.createElement("div",{className:"inner"},n.createElement("a",{href:"/"},n.createElement("img",{loading:"lazy",className:"footer-logo",src:null===(s=null==t?void 0:t.general)||void 0===s?void 0:s.logo,alt:"Logo","data-is-sehat":"id-ID"===a})),n.createElement("div",{className:"columns"},n.createElement("div",{className:"newsletter"},n.createElement(d.T,{size:x?"s3":"s4",weight:"semiBold",color:"neutral.0"},null===(c=null==t?void 0:t.general)||void 0===c?void 0:c.content),n.createElement("div",{className:"social"},n.createElement(d.T,{size:"p4",color:"neutral.6"},null===(u=null==t?void 0:t.social)||void 0===u?void 0:u.title),n.createElement("div",{className:"icons"},null===(g=null===(m=null==t?void 0:t.social)||void 0===m?void 0:m.socials)||void 0===g?void 0:g.map((e,t)=>n.createElement("a",{key:t,"data-event-category":"Footer","data-event-action":`Follow us - ${e.name}`,"data-content-label":e.url,href:e.url},n.createElement("img",{loading:"lazy","data-event-category":"Footer","data-event-action":`Follow us - ${e.name}`,"data-content-label":e.url,src:e.icon,alt:"Logo Social",className:"social-icon",width:"24",height:"24"})))))),n.createElement("div",{className:"footer-menu"},y&&n.createElement(n.Fragment,null,null==y?void 0:y.map((e,t)=>n.createElement(FooterMenuColumn,{title:e.menu_title,items:e.items,locale:a,key:t,index:t}))))),n.createElement("div",{className:"otherSites"},n.createElement(d.T,{size:"p4",className:"linkTitle",color:"neutral.6",weight:"regular"},null===(h=null==t?void 0:t.branch)||void 0===h?void 0:h.title),n.createElement("div",{className:"flags"},null===(f=null===(v=null==t?void 0:t.branch)||void 0===v?void 0:v.branch)||void 0===f?void 0:f.map((e,t)=>n.createElement("a",{href:e.url,key:t,"data-event-category":"Footer","data-event-action":e.name,"data-event-label":e.url},n.createElement(Flag,{url:e.flag,dataEventCategory:"Footer",dataEventAction:e.name,dataEventLabel:e.url}))))),n.createElement("div",{className:"copyright"},n.createElement("div",{className:"copyright-image-wrapper"},w.length?w.map((e,t)=>n.createElement("a",{href:e.url,key:t,className:"copyright-image"},n.createElement("img",{loading:"lazy",src:e.image,alt:"DMCA Icon"}))):null),n.createElement(d.T,{size:"n1",className:"copyright-content",as:"div",color:"neutral.6",weight:"regular"},n.createElement("div",{dangerouslySetInnerHTML:{__html:null===(b=null==t?void 0:t.general)||void 0===b?void 0:b.copyright.replace(/{currentYear}/gi,o()().get("year").toString())}}))))))},x=m.Z.footer`
position: relative;
overflow: hidden;
.icons {
margin-top: 12px;
margin-bottom: 20px;
> a:not(:last-child) {
margin-right: 16px;
}
}
a {
text-decoration: none;
}
`,y=m.Z.div`
position: relative;
padding: 80px 0 40px;
margin: auto 68px;
display: flex;
justify-content: space-between;
align-items: flex-start;
border-bottom: 1px solid ${g.r.colors.neutral200};
${u.M.tdDown} {
margin: auto 16px;
flex-wrap: wrap;
row-gap: 32px;
column-gap: 16px;
}
${u.M.mbDown} {
margin: auto 0;
}
`,w=m.Z.div`
display: flex;
justify-content: space-between;
gap: 12px;
flex-direction: column;
${u.M.mbDown} {
flex: 1 1 160px;
}
.title {
padding-bottom: 4px;
}
`,C=m.Z.div`
display: flex;
justify-content: space-between;
gap: 12px;
flex-direction: column;
`,T=m.Z.div`
background-color: #{map-get($mbColors, 'dark')};
padding: 16px 0;
position: relative;
img {
width: 89px;
height: 32px;
}
.content {
display: flex;
align-items: center;
justify-content: space-between;
gap: 174px;
margin: auto 68px;
${u.M.tdDown} {
margin: auto 16px;
}
${u.M.mbDown} {
flex-direction: column-reverse;
gap: 16px;
align-items: flex-start;
margin: auto 0;
}
}
.verify {
display: flex;
align-items: flex-start;
gap: 8px;
}
`,k=m.Z.div`
padding: 40px 0;
${u.M.mbUp} {
margin: auto 68px;
}
`,S=m.Z.div`
display: flex;
gap: 16px;
.social-logo {
width: 28px;
}
`,MarryBabyFooter=({logoType:e="marryBaby",footerMenu:t,background:a})=>{var l;if(!t)return null;let{general:u,menu:p,socials:m}=t;return n.createElement(x,{style:{backgroundColor:a||"none"}},n.createElement(r.C,null,n.createElement(y,null,null==p?void 0:p.map(({menu_title:e,items:t},a)=>n.createElement(w,{key:`mbf${a}`},n.createElement(f.M,{className:"title",type:"subtitle-1",color:g.r.mbColors.pink},e),null==t?void 0:t.map(({title:e,url:t},a)=>n.createElement("a",{"data-event-category":"Footer","data-event-action":"Click","data-event-label":`${t}`,className:"link",href:t,key:`footer-links-${a}`},n.createElement(C,{key:`mbitem${a}`},n.createElement(f.M,{type:"bodytext-2",color:g.r.mbColors.gray},e)))))))),n.createElement(r.C,null,n.createElement(k,null,n.createElement(i.k,{gap:"24px",sx:e=>({[e.fn.largerThan("sm")]:{".info-item":{flexGrow:1,width:"50%"}},[e.fn.smallerThan("sm")]:{flexDirection:"column"}})},n.createElement(s.K,{spacing:"24px",className:"info-item"},n.createElement(v.L,{className:"logo",type:e}),n.createElement(d.T,{size:"p4",as:"div"},n.createElement("div",{dangerouslySetInnerHTML:{__html:null==u?void 0:u.content}})),n.createElement(S,null,null==m?void 0:m.map(({icon:e,name:t,url:a},r)=>n.createElement("a",{key:`social${r}`,target:"_blank",rel:"noreferrer","data-event-category":"Footer","data-event-action":`Follow us - ${t}`,"data-content-label":t,href:a},n.createElement("img",{className:"social-logo",loading:"lazy",src:e,alt:t}))))),n.createElement(c.x,{className:"info-item",sx:{paddingTop:"7px"}},n.createElement(d.T,{size:"p4",as:"div"},n.createElement("div",{dangerouslySetInnerHTML:{__html:null==u?void 0:u.information}})))))),n.createElement(T,null,n.createElement(r.C,null,n.createElement("div",{className:"content"},n.createElement(d.T,{size:"p5",color:"#fff",as:"div"},n.createElement("div",{dangerouslySetInnerHTML:{__html:null==u?void 0:u.copyright.replace(/{currentYear}/gi,o()().get("year").toString())}})),n.createElement("div",{className:"verify"},null===(l=null==u?void 0:u.verified)||void 0===l?void 0:l.map(({image:e,url:t},a)=>n.createElement("img",{loading:"lazy",key:`imgMbFt${a}`,src:e,alt:t})))))))},Footer=({locale:e,footerInfo:t,siteType:a,background:r})=>"helloSites"===a?n.createElement(DiscoverFooter,{locale:e,footerInfo:t||{}}):n.createElement(MarryBabyFooter,{footerMenu:t,background:r})},"8Jy2":function(e,t,a){a.d(t,{C:function(){return g},I:function(){return ImagePreviewPopup},P:function(){return PostSingleImageViewPopup},a:function(){return PostImagePreview},b:function(){return h}});var n=a("q1tI"),r=a("OGdO"),l=a("K2Xj"),o=a("ZKGu"),i=a("4fTT"),s=a("t/pd"),c=a("ZQ3V"),d=a("rBCA"),u=a("6eqW"),p=a("iBNF"),m=a("gEnE"),g="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none'%3e%3cpath stroke='%23262626' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M18 6 6 18M6 6l12 12'/%3e%3c/svg%3e",h="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='25' fill='none'%3e%3cpath stroke='%23262626' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.75' d='M10.05 18.06 4 12.038l6.05-6.025M4.002 12.035h15'/%3e%3c/svg%3e";let v=d.Z.div`
padding: 14px 16px 14px 17px;
background: ${e=>e.bgColor};
border-left: 3px solid ${e=>e.highlight};
${l.M.mbUp} {
padding: 12px 12px 12px 17px;
}
`,f=d.Z.div`
display: flex;
`,E=d.Z.div`
font-size: 12px;
line-height: 18px;
&[data-has-icon='true'] {
margin-left: 10px;
}
`,b=d.Z.div`
flex-shrink: 0;
`,x=d.Z.div`
display: grid;
grid-gap: 3px;
grid-template-columns: 1fr 1fr;
grid-template-rows: auto;
.img-wrapper {
position: relative;
overflow: hidden;
width: 100%;
padding-top: 56.25%;
grid-column: auto;
& > img {
cursor: zoom-in;
}
.img-preview-blur {
position: absolute;
top: 50%;
left: 50%;
width: 110%;
height: 110%;
/* Add the blur effect */
-webkit-filter: blur(8px);
filter: blur(8px);
object-fit: cover;
object-position: center;
opacity: 0.8;
transform: translate(-50%, -50%);
}
.img-preview {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
object-fit: contain;
object-position: center;
}
.img-more-overlay {
position: absolute;
top: 0;
left: 0;
display: flex;
width: 100%;
height: 100%;
align-items: center;
justify-content: center;
background: rgba(0, 0, 0, 0.5);
z-index: 4;
}
}
&[data-image-count='1'] {
.img-wrapper {
/* padding-top: 100%; */
grid-column: 1/3;
}
}
&[data-image-count='2'] {
.img-wrapper {
/* padding-top: 100%; */
}
}
&[data-image-count='3'] {
.img-wrapper {
&:first-child {
grid-column: 1/3;
}
}
}
&[data-image-count='4'] {
.img-wrapper {
/* padding-top: 100%; */
}
}
&[data-image-count='5'] {
grid-template-columns: repeat(6, 1fr);
.img-wrapper {
/* padding-top: 100%; */
grid-column: auto/ span 2;
&:first-child {
padding-top: 56.25%;
grid-column: 1/4;
}
&:nth-child(2) {
padding-top: 56.25%;
grid-column: 4/7;
}
}
}
&[data-is-marrybaby='true'] {
grid-gap: 8px;
.img-wrapper {
padding-top: 66.66%;
border-radius: 1rem;
.img-preview {
object-fit: cover;
}
}
&[data-image-count='3'] {
grid-template-columns: 1fr 1fr 1fr;
.img-wrapper {
&:first-child {
padding-top: 100%;
grid-column: 1/3;
grid-row: 1/3;
}
}
}
}
`,y=d.Z.div`
position: fixed;
z-index: 999;
top: 0;
left: 0;
display: flex;
overflow: hidden;
width: 100vw;
height: 100vh;
flex-direction: column;
background: white;
opacity: 0;
pointer-events: none;
transition: opacity 0.2s linear;
&[data-open='true'] {
opacity: 1;
pointer-events: auto;
}
.top-bar {
position: relative;
padding: 20px 40px;
.icon-arrow-left {
position: absolute;
top: 50%;
left: 20px;
height: 24px;
width: 24px;
cursor: pointer;
transform: translateY(-50%);
}
}
.container {
flex: 1;
overflow-y: auto;
.img-preview {
width: 100%;
min-width: 100%;
margin-bottom: 0.5rem;
cursor: pointer;
max-height: 100%;
object-fit: cover;
}
}
`,w=(0,d.Z)(e=>{var{icon:t,bgColor:a=p.r.colors.yellow50,highlightColor:r=p.r.colors.yellow800,message:l}=e,o=(0,u._)(e,["icon","bgColor","highlightColor","message"]);return n.createElement(v,Object.assign({bgColor:a,highlight:r},o),n.createElement(f,null,t&&n.createElement(b,null,t),n.createElement(E,{"data-has-icon":!!t},l)))})`
margin-bottom: 16px;
&.noti-bottom {
border-left: none;
margin-top: 4px;
padding: 4px 8px;
margin-left: 16px;
margin-right: 16px;
border-radius: 4px;
}
`,ImagePreviewPopup=({className:e,style:t,authorName:a,images:r,onClose:l,onOpenSingleView:i,alt:d})=>{let{t:u}=(0,o.u)(),[p,m]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{setTimeout(()=>{m(!0)},0)},[]),n.createElement(s.h,null,n.createElement(y,{className:e,style:t,"data-open":p},n.createElement("div",{className:"top-bar"},n.createElement("img",{className:"icon-arrow-left",src:h,onClick:l,alt:"go back",loading:"lazy"}),n.createElement(c.T,{size:"p2",weight:"bold",style:{textAlign:"center"}},u("previewPhotos.title",{name:a}))),n.createElement("div",{className:"container"},r.map((e,t)=>n.createElement("img",{className:"img-preview",key:t,src:e,onClick:()=>null==i?void 0:i(t),alt:d,loading:"lazy"})))),",")},C=d.Z.div`
position: fixed;
z-index: 999;
top: 0;
left: 0;
display: flex;
width: 100%;
height: 100%;
flex-direction: column;
background: black;
opacity: 0;
pointer-events: none;
transition: opacity 0.2s linear;
&[data-open='true'] {
opacity: 1;
pointer-events: auto;
}
`,T=d.Z.div`
padding: 1rem;
background: white;
.icon-close {
width: 26px;
height: 26px;
cursor: pointer;
}
`,k=d.Z.div`
position: relative;
flex: 1;
overflow: hidden;
> img {
height: 100%;
width: 100%;
object-fit: contain;
object-position: center;
}
`,S=d.Z.div`
--inner-padding: max(16px, 20%);
height: 100%;
position: absolute;
left: 0;
padding: 8px;
padding-right: var(--inner-padding);
display: flex;
align-items: center;
top: 0;
cursor: pointer;
&[data-right] {
padding-right: 8px;
padding-left: var(--inner-padding);
left: unset;
right: 0;
}
&[data-disabled='true'] {
cursor: not-allowed;
}
`,N=d.Z.div`
border-radius: 50%;
background: rgba(0, 0, 0, 0.3);
display: flex;
align-items: center;
justify-content: center;
padding: 4px;
> img {
width: 16px;
height: 16px;
&[data-disabled='true'] {
opacity: 0.5;
}
}
${l.M.tdUp} {
padding: 8px;
> img {
width: 30px;
height: 30px;
}
}
`;var _="data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='17' fill='none'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.75' d='m6 12.813 4-4-4-4'/%3e%3c/svg%3e";let PostSingleImageViewPopup=({initialViewIndex:e,images:t,onClose:a,alt:r})=>{let[l,o]=(0,n.useState)(e),[i,c]=(0,n.useState)(!1);(0,n.useEffect)(()=>{setTimeout(()=>{c(!0)},0)},[]);let d=null==t?void 0:t[l],u=0===l,p=!(null==t?void 0:t.length)||l===(null==t?void 0:t.length)-1;return n.createElement(s.h,null,n.createElement(C,{"data-open":i&&!!d},n.createElement(T,null,n.createElement("img",{src:g,className:"icon-close",onClick:a,alt:"close",loading:"lazy"})),d&&l>=0&&n.createElement(n.Fragment,null,n.createElement(k,null,n.createElement("img",{className:"img-preview",src:d,alt:r,loading:"lazy"}),n.createElement(S,{"data-disabled":u,onClick:()=>!u&&o(l-1)},n.createElement(N,null,n.createElement("img",{src:_,style:{transform:"rotate(180deg)"},alt:"left arrow","data-disabled":u,loading:"lazy"}))),n.createElement(S,{"data-right":!0,"data-disabled":p,onClick:()=>!p&&o(l+1)},n.createElement(N,null,n.createElement("img",{src:_,alt:"right arrow","data-disabled":p,loading:"lazy"})))))))},I=(0,m.Z)(d.Z.div`
position: absolute;
top: 0;
right: 0;
left: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.4);
color: white;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
`,"hhgcomp-sensitivemask-inner"),A=d.Z.div``,M=d.Z.div`
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 3;
background: white;
cursor: pointer;
&,
* {
// transition: all 300ms;
transform-origin: bottom left;
}
img {
transition: none;
}
.img-preview {
width: 100%;
}
&[data-is-blurred='true'] {
.img-preview {
/* Add the blur effect */
-webkit-filter: blur(24px);
filter: blur(24px);
}
}
&[data-is-blurred='false'] {
background: transparent;
cursor: zoom-in;
${I.classSelector} {
top: auto;
right: auto;
left: 8px;
bottom: 8px;
background: rgba(0, 0, 0, 0);
align-items: flex-end;
justify-content: flex-start;
}
}
`,SensitiveMask=({image:e,showIcon:t=!0})=>{let[a,r]=(0,n.useState)(!0);return n.createElement(M,{"data-is-blurred":a,onClick:e=>a&&e.stopPropagation()},n.createElement("img",{loading:"lazy",className:"img-preview",src:e}),n.createElement(I,{onClick:e=>{e.stopPropagation(),r(!a)}},t&&n.createElement(A,null,a?n.createElement("svg",{width:"22",height:"20",viewBox:"0 0 22 20",fill:"none"},n.createElement("path",{d:"M1.71 2.54a.996.996 0 0 1 0-1.41c.39-.39 1.03-.39 1.42 0l16.31 16.33a.996.996 0 1 1-1.41 1.41l-2.72-2.72c-1.34.52-2.79.82-4.31.82-5 0-9.27-3.11-11-7.5C.77 7.5 2.06 5.8 3.68 4.51zM16 9.47c0-2.76-2.24-5-5-5-.51 0-1 .1-1.47.24L7.36 2.54c1.15-.37 2.37-.57 3.64-.57 5 0 9.27 3.11 11 7.49-.69 1.76-1.79 3.3-3.18 4.53l-3.06-3.06c.14-.46.24-.95.24-1.46m-5 5c-2.76 0-5-2.24-5-5 0-.77.18-1.5.49-2.14L8.06 8.9c-.03.18-.06.37-.06.57 0 1.66 1.34 3 3 3 .2 0 .38-.03.57-.07l1.57 1.57c-.65.32-1.37.5-2.14.5m2.97-5.33a2.97 2.97 0 0 0-2.64-2.64z",fill:"#fff"})):n.createElement("svg",{width:"23",height:"16",viewBox:"0 0 23 16",fill:"none"},n.createElement("path",{d:"M12 0C5.142 0 1.886 5.879 1.096 7.557c-.132.28-.132.604 0 .884C1.886 10.121 5.142 16 12 16c6.834 0 10.092-5.837 10.896-7.54a1.08 1.08 0 0 0 0-.92C22.092 5.836 18.834 0 12 0m0 3a5 5 0 1 1-.001 10.001 5 5 0 0 1 0-10.001m0 2a3 3 0 1 0 0 6 3 3 0 0 0 0-6",fill:"#2D87F3"})))))},PostImagePreview=({className:e,images:t=[],style:a,authorName:s,isSensitive:c=!1,alt:d,positionAlert:u="top"})=>{let{data:{env:{isMarryBaby:p}}}=(0,n.useContext)(i.T),{t:m}=(0,o.u)(),g=`+ ${(t.length||0)-4}`,[h,v]=(0,n.useState)(!1),[f,E]=(0,n.useState)(-1),b=t.length>5,y=(0,n.useRef)(!1);return(0,n.useEffect)(()=>()=>{y.current&&(0,l.t)(!1)},[]),(0,n.useEffect)(()=>{h||f>=0?((0,l.t)(!0),y.current=!0):((0,l.t)(!1),y.current=!1)},[h,f]),n.createElement(n.Fragment,null,c&&"top"===u&&n.createElement(w,{message:m("sensitiveMask.contentWarningDescription"),icon:n.createElement("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none"},n.createElement("path",{d:"M9 .667A8.336 8.336 0 0 0 .667 9c0 4.6 3.733 8.333 8.333 8.333S17.333 13.6 17.333 9 13.6.667 9 .667m0 9.166A.836.836 0 0 1 8.167 9V5.667c0-.459.375-.834.833-.834s.833.375.833.834V9A.836.836 0 0 1 9 9.833M8.167 11.5v1.667h1.666V11.5z",fill:"#FE921D"}))}),n.createElement(x,{className:e,style:a,"data-image-count":b?5:t.length||0,"data-is-marrybaby":p,"data-cursor-pointer":!c},null==t?void 0:t.slice(0,5).map((e,t)=>{let a=4===t&&b;return n.createElement("div",{className:"img-wrapper",key:t,onClick:()=>{t>=4&&b?v(!0):E(t)}},c&&n.createElement(SensitiveMask,{image:e,showIcon:!a}),!p&&n.createElement("img",{loading:"lazy",className:"img-preview-blur",src:e,alt:d}),n.createElement("img",{loading:"lazy",className:"img-preview",src:e,alt:d}),a&&n.createElement("div",{className:"img-more-overlay"},n.createElement(r.H,{tag:"h1",as:"h2",color:"white"},g)))})),h&&n.createElement(ImagePreviewPopup,{authorName:s||"",images:t,onClose:()=>v(!1),onOpenSingleView:E,alt:d}),f>=0&&n.createElement(PostSingleImageViewPopup,{images:t,initialViewIndex:f,onClose:()=>E(-1),alt:d}),c&&"bottom"===u&&n.createElement(w,{message:m("sensitiveMask.contentWarningDescription.community"),className:"noti-bottom",icon:n.createElement("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none"},n.createElement("path",{d:"M9 .667A8.336 8.336 0 0 0 .667 9c0 4.6 3.733 8.333 8.333 8.333S17.333 13.6 17.333 9 13.6.667 9 .667m0 9.166A.836.836 0 0 1 8.167 9V5.667c0-.459.375-.834.833-.834s.833.375.833.834V9A.836.836 0 0 1 9 9.833M8.167 11.5v1.667h1.666V11.5z",fill:"#FE921D"}))}))}},FZN7:function(e,t,a){a.d(t,{C:function(){return CartCareButton},S:function(){return ShoppingCartCare}});var n=a("q1tI"),r=a("xXM3"),l=a.n(r),o=a("rBCA"),i=a("Eso5"),s=a("K2Xj"),c=a("iBNF"),d=a("ZKGu"),u=a("ZQ3V");let ShoppingCartCare=e=>n.createElement("svg",Object.assign({width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"none"},e),n.createElement("path",{d:"M1.94434 1.94434L3.44545 2.31989C3.88211 2.42878 4.20989 2.791 4.27545 3.23656L5.55656 11.9454",stroke:"currentColor",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}),n.createElement("path",{d:"M16.9444 14.7218H4.99997C4.23331 14.7218 3.61108 14.0996 3.61108 13.3329C3.61108 12.5662 4.23331 11.944 4.99997 11.944H14.4766C14.9544 11.944 15.38 11.6385 15.5311 11.184L17.0122 6.73957C17.2522 6.01957 16.7166 5.27734 15.9578 5.27734H4.57553",stroke:"currentColor",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}),n.createElement("path",{d:"M4.16648 18.8891C4.93354 18.8891 5.55537 18.2673 5.55537 17.5002C5.55537 16.7332 4.93354 16.1113 4.16648 16.1113C3.39941 16.1113 2.77759 16.7332 2.77759 17.5002C2.77759 18.2673 3.39941 18.8891 4.16648 18.8891Z",fill:"currentColor"}),n.createElement("path",{d:"M15.8332 18.8891C16.6003 18.8891 17.2221 18.2673 17.2221 17.5002C17.2221 16.7332 16.6003 16.1113 15.8332 16.1113C15.0662 16.1113 14.4443 16.7332 14.4443 17.5002C14.4443 18.2673 15.0662 18.8891 15.8332 18.8891Z",fill:"currentColor"})),p=(0,o.Z)(i.x)`
display: flex;
align-items: center;
justify-content: center;
gap: 8px;
border: 1px solid #ffffff33;
position: relative;
flex-shrink: 0;
cursor: pointer;
/* Desktop: Square layout */
border-radius: 28px;
max-height: 40px;
padding: 9px 1rem;
background-color: inherit;
white-space: nowrap;
.cart-care-icon {
width: 20px;
height: 20px;
color: ${c.r.colors.white};
flex-shrink: 0;
}
.cart-care-button-text {
display: block;
font-size: 14px;
font-weight: 500;
line-height: 22px;
}
/* Mobile: Circle layout */
${s.M.mbDown} {
border-radius: 100%;
aspect-ratio: 1/1;
width: 32px;
height: 32px;
padding: auto;
background-color: ${c.r.colors.white};
max-height: none;
padding: 0;
.cart-care-icon {
width: 20px;
height: 20px;
color: ${c.r.colors.blue900};
flex-shrink: 0;
}
.cart-care-button-text {
display: none;
}
}
`,m=(0,o.Z)(i.x)`
min-width: 20px;
min-height: 20px;
aspect-ratio: 1/1;
border-radius: 100%;
background-color: ${c.r.colors.red500};
color: ${c.r.colors.white};
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
position: absolute;
top: -4px;
right: -4px;
${s.M.mbDown} {
top: -8px;
right: -8px;
}
`,CartCareButton=e=>{let{count:t=0,href:a,classes:r,boxProps:o,anchorProps:i,tracking:s}=e,{t:g}=(0,d.u)();return n.createElement("a",Object.assign({className:l()("cart-care-button"),href:a,"data-testid":"cart-care-button","data-event-category":"Hamburger Navigation","data-event-action":"Cart Click","data-event-label":a},s,i),n.createElement(p,Object.assign({className:l()("cart-care-button-box",null==r?void 0:r.box)},o),n.createElement(ShoppingCartCare,{className:"cart-care-icon"}),n.createElement(u.T,{size:"label1",color:c.r.colors.white,fw:500,className:"cart-care-button-text"},g("navigation.button.cartCareService")),t>0&&n.createElement(m,{className:l()("cart-care-button-count-box",null==r?void 0:r.count)},n.createElement(u.T,{size:t>99?"label2":"c1",color:c.r.colors.white,fw:600,className:"cart-care-button-count-text"},t>99?"99+":t))))}},JjKH:function(e,t,a){a.d(t,{B:function(){return v},C:function(){return O},E:function(){return A},F:function(){return I},G:function(){return h},N:function(){return w},S:function(){return S},V:function(){return k},a:function(){return f},c:function(){return x},d:function(){return y},e:function(){return _},f:function(){return C},g:function(){return T},h:function(){return M},i:function(){return $}});var n,r,l,o,i,s,c,d,u,p,m,g,h,v,f,E,b,x,y,w,C,T,k,S,N=a("PmKk");(n=h||(h={})).Boy="boy",n.Girl="girl",(r=v||(v={}))[r.Height=0]="Height",r[r.Weight=1]="Weight",r[r.Head=2]="Head",r[r.BMI=3]="BMI",(l=f||(f={}))[l.Weekly=0]="Weekly",l[l.Monthly=1]="Monthly",l[l.Yearly=2]="Yearly",(o=E||(E={}))[o.Height=0]="Height",o[o.Weight=1]="Weight",o[o.Head=2]="Head",o[o.BMI=3]="BMI",o[o.Record=4]="Record",(i=b||(b={}))[i.Phone=0]="Phone",i[i.OTP=1]="OTP",i[i.OTPEmail=2]="OTPEmail",i[i.PersonalInfo=3]="PersonalInfo",i[i.UpdatePassword=4]="UpdatePassword",i[i.Result=5]="Result",i[i.DynamicForm=6]="DynamicForm",(s=x||(x={}))[s.HEAD=0]="HEAD",s[s.TAIL=1]="TAIL",s[s.MIDDLE=2]="MIDDLE",s[s.CONNECT=3]="CONNECT",s[s.SSO=4]="SSO",s[s.MULTIPLE=5]="MULTIPLE",(c=y||(y={}))[c.UNDEFINED=-1]="UNDEFINED",c[c.TEXT=0]="TEXT",c[c.IMAGE=1]="IMAGE",c[c.FORM=2]="FORM",c[c.CONDITION=3]="CONDITION",c[c.POLL=4]="POLL",c[c.FINAL_STANDARD=5]="FINAL_STANDARD",c[c.FINAL=6]="FINAL",c[c.FINAL_THANK_YOU=7]="FINAL_THANK_YOU",c[c.RATING=8]="RATING",c[c.REACTION=9]="REACTION",c[c.REVIEW=10]="REVIEW",c[c.RESULT_POLL=11]="RESULT_POLL",c[c.RESULT_RATING=12]="RESULT_RATING",c[c.RESULT_REACTION=13]="RESULT_REACTION",c[c.OTP=14]="OTP";let _=[y.FINAL,y.FINAL_STANDARD,y.FINAL_THANK_YOU];(d=w||(w={})).BOT_TEXT="bot-text",d.BOT_IMAGE="bot-image",d.BOT_BACKGROUND_IMAGE="bot-background-image",d.BOT_BUTTON="bot-button",d.BOT_URL="bot-url",d.BOT_RECALCULATE="bot-recalculate",d.BOT_BOOKING="bot-booking",d.BOT_MAIN_TITLE="bot-main-title",d.BOT_MAIN_IMAGE="bot-main-image",d.BOT_MAIN_BODY="bot-main-body",d.BOT_MAIN_BUTTON="bot-main-button",d.BOT_SUB_TITLE="bot-sub-title",d.BOT_SUB_BODY="bot-sub-body",d.BOT_LANDING_PAGE_URL="bot-landing-page-url",d.BOT_LANDING_PAGE_BUTTON="bot-landing-page-button",d.BOT_RISK_SCREEN="bot-risk-screen",d.BOT_RELATED_ARTICLE="bot-related-article",d.THANK_YOU_IMAGE="thank-you-image",d.THANK_YOU_TITLE="thank-you-title",d.THANK_YOU_BODY="thank-you-body",d.TOTAL_LINE="total-line",d.BOT_SUBMISSION="bot-submission",d.BOT_EVENT_SUBMISSION="bot-event-submission",d.BOT_SUGGESTED_SERVICE="bot-suggested-service",d.SSO_INTENT="sso-intent",(u=C||(C={})).ACTION_CONDITION="action-condition",u.ACTION_INTERNAL="action-internal",u.ACTION_EXTERNAL="action-external",u.ACTION_SSO_REDIRECT="action-sso-redirect",u.ACTION_MULTIPLE_BUTTON="action-multiple-button",u.USER_CHOICE_TEXT="user-choice-text",u.USER_CHOICE_TEXT_BY_INPUT="user-choice-text-by-input",u.USER_CHOICE_NEXT="user-choice-next",u.USER_CHOICE_IMAGE="user-choice-image",u.USER_SUBMIT_TEXT="user-submit-text",u.USER_SUBMIT_NUMBER="user-submit-number",u.USER_SUBMIT_NAME="user-submit-name",u.USER_SUBMIT_PHONE="user-submit-phone",u.USER_SUBMIT_EMAIL="user-submit-email",u.USER_SUBMIT_DROPDOWN="user-submit-dropdown",u.USER_SUBMIT_DATE="user-submit-date",u.USER_SUBMIT_DOB="user-submit-dob",u.USER_SUBMIT_CONFIRM="user-submit-confirm",u.USER_SUBMIT_SEND="user-submit-send",u.USER_SUBMIT_RESEND="user-submit-resend",u.USER_SUBMIT_ADDRESS="user-submit-address",u.USER_SUBMIT_ADDRESS_PROVINCE="user-submit-address-province",u.USER_SUBMIT_ADDRESS_DISTRICT="user-submit-address-district",u.USER_SUBMIT_ADDRESS_COMMUNE="user-submit-address-commune",u.USER_SUBMIT_BMI="user-submit-bmi",u.USER_SUBMIT_BMI_HIDDEN="user-submit-bmi-hidden",u.USER_SUBMIT_TERMS="user-submit-terms",u.USER_SUBMIT_GENDER="user-submit-gender",u.USER_SUBMIT_OTP="user-submit-otp",u.USER_SUBMIT_WHATSAPP="user-submit-whatsapp",u.POLL_CHOICE="poll-choice",u.POLL_CHOICE_TEXT_BY_INPUT="poll-choice-text-by-input",u.POLL_CHOICE_IMAGE="poll-choice-image",u.POLL_BUTTON="poll-button",u.RATING_STAR="rating-star",u.RATING_DESCRIPTION="rating-description",u.RATING_BUTTON="rating-button",u.LIKE_CHOICE="like-choice",u.DISLIKE_CHOICE="dislike-choice",u.REVIEW_CHOICE="review-choice",u.REVIEW_DESCRIPTION="review-description",u.REVIEW_BUTTON="review-button",u.RESULT_BUTTON="result-button",u.POLL_RESULT="poll-result",u.USER_SUBMIT_GOOGLE_API_ADDRESS="user-submit-google-api-address";let I=[C.USER_SUBMIT_ADDRESS_PROVINCE,C.USER_SUBMIT_ADDRESS_DISTRICT,C.USER_SUBMIT_ADDRESS_COMMUNE,C.USER_SUBMIT_ADDRESS];(p=T||(T={}))[p.UNLIMITED=0]="UNLIMITED",p[p.EXACT_NUMBER=1]="EXACT_NUMBER",p[p.RANGE=2]="RANGE";let A={[C.USER_SUBMIT_EMAIL]:"email",[C.USER_SUBMIT_TEXT]:"text",[C.USER_SUBMIT_DROPDOWN]:"text",[C.USER_SUBMIT_NAME]:"name",[C.USER_SUBMIT_NUMBER]:"number",[C.USER_SUBMIT_ADDRESS]:"address",[C.USER_SUBMIT_PHONE]:"tel",[C.USER_SUBMIT_OTP]:"tel",[C.USER_SUBMIT_WHATSAPP]:"tel",[C.USER_SUBMIT_DATE]:"date",[C.USER_SUBMIT_CONFIRM]:"confirm",[C.USER_SUBMIT_SEND]:"submit",[C.USER_SUBMIT_TERMS]:"terms",[C.USER_SUBMIT_ADDRESS_PROVINCE]:"province",[C.USER_SUBMIT_ADDRESS_DISTRICT]:"district",[C.USER_SUBMIT_ADDRESS_COMMUNE]:"commune",[C.USER_SUBMIT_BMI]:"bmi",[C.USER_SUBMIT_GENDER]:"gender",[C.POLL_CHOICE]:"poll",[C.POLL_CHOICE_TEXT_BY_INPUT]:"poll",[C.POLL_CHOICE_IMAGE]:"poll",[C.RATING_STAR]:"rating",[C.RATING_DESCRIPTION]:"text",[C.LIKE_CHOICE]:"like",[C.DISLIKE_CHOICE]:"dislike",[C.REVIEW_CHOICE]:"review",[C.USER_SUBMIT_GOOGLE_API_ADDRESS]:"google-api-address",[C.USER_SUBMIT_DOB]:"dob"},M={FRU:"FRU",survey:"Survey",ristScreener:"risk_screener",voucherAcuvue:"ACUVUE"};(m=k||(k={})).VIDEO="video",m.SHORTS="short",m.PODCAST="podcast",m.LIVESTREAM="live-stream",(g=S||(S={})).Facebook="facebook",g.Zalo="zalo",g.Twitter="twitter",g.WhatsApp="whatsApp",g.Line="line",g.Instagram="instagram",g.LinkedIn="linkedin",g.Youtube="youtube",g.Tiktok="tiktok",g.Telegram="telegram",g.Viber="viber";let O={DD:{id:"common.day",defaultMessage:"Day"},MM:{id:"common.month",defaultMessage:"Month"},YYYY:{id:"common.year",defaultMessage:"Year"}};var $=Object.freeze({__proto__:null,get SocialType(){return S},COMMON_DATE_TRANSLATE_KEY:O,get Gender(){return h},get BabyGrowthChartType(){return v},get BabyGrowthChartDuration(){return f},get BabyGrowthResultTab(){return E},get LOCALE(){return N.L},get OnboardingStep(){return b},get NodePosition(){return x},get NodeType(){return y},NodeFinalTypes:_,get NodeIntentType(){return w},get NodeActionType(){return C},FULL_KEY_ADDRESS:I,get NodeMultipleOptions(){return T},ELEMENT_CONTROL_INPUT_TYPE:A,SubotType:M,get VideoType(){return k}})},sx9v:function(e,t,a){a.d(t,{P:function(){return PostContent},T:function(){return l},U:function(){return o},a:function(){return ProfileDetail},b:function(){return V}});var n,r,l,o,i=a("6eqW"),s=a("q1tI"),c=a("Wgwc"),d=a.n(c),u=a("qM2N"),p=a("A0Xv"),m=a("OQNV"),g=a("IQVP"),h=a("4fTT"),v=a("vWP/"),f=a("/npG"),E=a("eito"),b=a("bpvy"),x=a("SPK5"),y=a("8vDj"),w=a("i2MM"),C=a("EDn0"),T=a("cphq"),k=a("JjKH"),S=a("ZKGu"),N=a("iBNF"),_=a("Frvz"),I=a("h84G"),A=a("TH2c"),M=a("ZQ3V"),O=a("p3w3"),$=a("rBCA"),P=a("aZjv"),B=a("SfG2"),D=a("Jn/A");let R=$.Z.div`
padding: 0.5rem 1rem 1rem;
line-height: 1.5;
word-break: break-word;
.post-content-replying {
margin-right: 5px;
cursor: pointer;
display: inline-block;
&.tag-only {
margin-right: 0;
}
}
.post-content {
display: inline;
white-space: pre-wrap;
/* > *:first-child, */
> mention:first-child ~ * {
&:not(ul),
&:not(ol) {
display: inline-block;
}
}
> mention:first-child {
margin-right: 5px;
}
&.has-see-more {
*:last-child {
&:not(ul),
&:not(ol) {
display: inline;
}
}
}
img {
width: 100%;
height: unset;
}
ul,
ol {
list-style-position: inside;
padding-left: 1rem;
display: block;
}
ol {
list-style-type: decimal;
}
ul {
list-style-type: disc;
}
mention {
color: ${e=>e.mentionColor||"#1890ff"};
padding-right: 4px;
:hover {
text-decoration: underline;
}
}
.markdown {
white-space: normal;
p,
ul,
ol {
margin-top: 1em;
&:first-child {
margin-top: 0;
}
}
li {
margin-top: 0.5em;
&:first-child {
margin-top: 0;
}
}
}
}
`,U=$.Z.span`
overflow: hidden;
text-overflow: ellipsis;
-webkit-line-clamp: ${e=>e.line||1};
display: -webkit-box;
-webkit-box-orient: vertical;
&.post-content-show-all {
display: block;
}
`,z=$.Z.span`
padding-left: 2px;
background-color: ${N.r.colors.white};
bottom: 8px;
position: absolute;
right: 0;
z-index: 10;
cursor: pointer;
`;var L=(0,f.k)(e=>({root:{mention:{color:e.fn.primaryColor()},a:{"&,&:visited,&:focus":{color:e.fn.primaryColor()}},".create-post-link":{display:"inline",color:e.fn.primaryColor(),cursor:"pointer"}}}));let PostContent=e=>{var{trackingCategory:t,url:a,className:n,style:r,replyingTo:l,mentionedUser:o,description:c,disableShortenContent:d,mentions:u=[],maxChars:p=1e3,maxLines:m,hideShowAllBtn:g,styles:v,onClickCreatePostLink:f}=e,b=(0,i._)(e,["trackingCategory","url","className","style","replyingTo","mentionedUser","description","disableShortenContent","mentions","maxChars","maxLines","hideShowAllBtn","styles","onClickCreatePostLink"]);let{classes:x,theme:y}=L(void 0,{name:"PostContent",styles:v}),[w,C]=(0,s.useState)(!1),[k,N]=(0,s.useState)(!1),{t:_}=(0,S.u)(),{authActionWrapper:I}=(0,P.iV)(),[A,M]=(0,s.useState)(!1),O=(0,B.d)((0,B.b)(c||"","display"),u),{action:{sanitizeFunction:$}}=(0,s.useContext)(h.T),D=(0,s.useMemo)(()=>{let e=$(O||"");if(d||w)return{showContent:e,hasSeeMore:!1};let t=e.slice(0,p),a=p-((t.match(/<\/div>/g)||[]).length-1)*27,n=(t||"").slice(0,a<40?40:a),r=$(n.replace(/(<|<\/)( +|[a-zA-Z]*)$/gi,"")),l=r.lengths.createElement(s.Fragment,null,"... ",!g&&s.createElement(E.e,Object.assign({onClick:e=>{e.preventDefault(),e.stopPropagation(),I(()=>C(!0))},className:"see-more-text"},t?{"data-event-category":t,"data-event-action":"See More Post Click","data-event-label":a}:{}),_("post.seeMore"))),[g,a,t]),handleCreatePostClick=e=>{e.preventDefault(),null==f||f()},isEllipsisActive=e=>e.scrollHeight>e.clientHeight;return(0,s.useEffect)(()=>{var e;return null===(e=null==H?void 0:H.current)||void 0===e||e.querySelectorAll("[data-create-post]").forEach(e=>{e.addEventListener("click",handleCreatePostClick,{passive:!0})}),()=>{var e;null===(e=null==H?void 0:H.current)||void 0===e||e.querySelectorAll("[data-create-post]").forEach(e=>{e.removeEventListener("click",handleCreatePostClick,!1)})}},[d,w,O]),(0,s.useEffect)(()=>{Z.current&&O&&m&&(isEllipsisActive(Z.current)?N(!0):N(!1))},[O,m]),s.createElement(s.Fragment,null,F&&s.createElement(T.P,{isOpen:A,onClose:()=>M(!1),expertId:String(null==o?void 0:o.partnerId)}),s.createElement(R,Object.assign({ref:H,className:`${x.root} ${n} no-replace-click`,style:r,mentionColor:y.fn.primaryColor()},b),j&&s.createElement(E.e,{onClick:()=>F&&M(!0),className:"post-content-replying"},"@",j),(null==c?void 0:c.startsWith("[mention+id="))&&s.createElement("span",{className:"post-content-replying tag-only",style:{color:y.fn.primaryColor()}},"@"),m?s.createElement(s.Fragment,null,s.createElement(U,{dangerouslySetInnerHTML:{__html:O},className:`post-content-line ${w?"post-content-show-all":""}`,line:m,ref:Z}),k&&!w&&s.createElement(z,null,G())):s.createElement(s.Fragment,null,s.createElement("span",{dangerouslySetInnerHTML:{__html:D.showContent},className:`post-content ${D.hasSeeMore?"has-see-more":""}`}),D.hasSeeMore&&!w&&s.createElement("span",null,G()))))},CategoryText=({children:e,className:t=""})=>s.createElement("div",{className:`l5fL1xL ${t}`},e),Title=({children:e,className:t=""})=>s.createElement("div",{className:`L-aGKo7 ${t}`},e),Thumbnail=({src:e,defaultSrc:t=w.C.getAssetPath("logo/logomark.png"),ratio:a=1,size:n=80,radius:r=8,alt:l,className:o=""})=>s.createElement("div",{className:o},s.createElement("div",{className:"DZmf3s7",style:{width:`${n}px`,height:`${n*a}px`,borderRadius:`${r}px`}},s.createElement(C.I,{src:e,backupSrc:t,alt:l}))),CardArticle=({category:e,title:t,src:a,children:n,className:r=""})=>s.createElement("div",{className:`eaR8ATZ ${r}`},s.createElement(Thumbnail,{src:a}),s.createElement("div",{className:"xM-7K0a"},n||s.createElement("div",null,e&&s.createElement(CategoryText,null,e),t&&s.createElement(Title,null,t))));CardArticle.CategoryText=CategoryText,CardArticle.Title=Title;let ArticleCard=({featureImage:e,postTitle:t,author:a,categories:n,isReview:r,className:l=""})=>{var o;return s.createElement(CardArticle,{src:e,className:l},s.createElement(s.Fragment,null,s.createElement(CardArticle.CategoryText,null,null===(o=null==n?void 0:n[0])||void 0===o?void 0:o.name),s.createElement(CardArticle.Title,null,t),s.createElement(T.d,{avatarProps:Object.assign(Object.assign({},a),{size:32}),subTitle:s.createElement(s.Fragment,null,r?"Medically reviewed by Jobelle Ann Dela Cruz Bigalbal, MD":"Written by Jobelle Ann Dela Cruz Bigalbal, MD",s.createElement(T.d.SubDivider,null),"Dec 12, 2022")})))};var j={container:"SFSgnOz",header:"Tf3aoVa",heading:"TOt4QXl",headingIcon:"_5XYN1KT",accBodyGroup:"yE-tZRj",accBodyGroupItem:"LXiGuGT",accBodyGroupDesc:"r4rx-6v",subTitle:"XrHh8-C",subIcon:"c5-Yecd",group:"UBj6nWr",groupBody:"_2vptVBd",articleCardLink:"ZPDAwiR",relatedList:"_6wJn-NR",socialItem:"_21XDdFv",mbChevronWrapper:"LSyr3Zo"};let F=(0,s.createContext)({}),About=({className:e=""})=>{var t,a,n,r,l;let{t:o}=(0,S.u)(),{info:i,isMarryBaby:c,currentPageUrl:d}=(0,s.useContext)(F),u=null==i?void 0:i.data,p=[{type:k.S.LinkedIn,icon:w.C.getAssetPath("linkedin.svg"),url:null===(t=null==i?void 0:i.contact)||void 0===t?void 0:t.linkedin,eventAction:"Doctor Profile - Linkedin"},{type:k.S.Instagram,icon:w.C.getAssetPath("instagram.svg"),url:null===(a=null==i?void 0:i.contact)||void 0===a?void 0:a.instagram,eventAction:"Doctor Profile - Instagram"},{type:k.S.Facebook,icon:w.C.getAssetPath("facebook.svg"),url:null===(n=null==i?void 0:i.contact)||void 0===n?void 0:n.facebook,eventAction:"Doctor Profile - Facebook"},{type:k.S.Youtube,icon:w.C.getAssetPath("youtube.svg"),url:null===(r=null==i?void 0:i.contact)||void 0===r?void 0:r.youtube,eventAction:"Doctor Profile - Youtube"},{type:k.S.Tiktok,icon:w.C.getAssetPath("tiktok.svg"),url:null===(l=null==i?void 0:i.contact)||void 0===l?void 0:l.tiktok,eventAction:"Doctor Profile - TikTok"}],m=[...((null==i?void 0:i.experiences)||[]).length>0?[{key:"experience",heading:o("profilePanel.experience"),iconSrc:w.C.getAssetPath(c?"award-doc-mb.svg":"award-doc.svg"),eventAction:"Doctor Experience Click",panel:s.createElement("div",{className:j.accBodyGroup},null==i?void 0:i.experiences.map((e,t)=>s.createElement("div",{className:j.accBodyGroupItem,key:String(t)},s.createElement("div",{className:j.accBodyGroupTitle},e.title),s.createElement("div",{className:j.accBodyGroupDesc},s.createElement("p",null,e.organization),s.createElement("p",null,e.duration)))))}]:[],...((null==i?void 0:i.educations)||[]).length>0?[{key:"education",heading:o("profilePanel.education"),iconSrc:w.C.getAssetPath(c?"book-mb.svg":"book.svg"),eventAction:"Doctor Degree Click",panel:s.createElement("div",{className:j.accBodyGroup},null==i?void 0:i.educations.map((e,t)=>s.createElement("div",{className:j.accBodyGroupItem,key:String(t)},s.createElement("div",{className:j.accBodyGroupTitle},e.schoolName),s.createElement("div",{className:j.accBodyGroupDesc},s.createElement("p",null,e.study),s.createElement("p",null,e.completedYear)))))}]:[],...((null==i?void 0:i.awards)||[]).length>0?[{key:"awards",heading:o("profilePanel.awards"),iconSrc:w.C.getAssetPath(c?"award-mb.svg":"award.svg"),eventAction:"Doctor Award Click",panel:s.createElement("div",{className:j.accBodyGroup},null==i?void 0:i.awards.map((e,t)=>s.createElement("div",{className:j.accBodyGroupTitle,key:t},e.title)))}]:[]],g=(null==i?void 0:i.relatedPosts)||[],h=p.filter(e=>e.url);return s.createElement("div",{className:`${j.container} ${e}`,"data-is-marrybaby":c},m.length>0&&s.createElement(b.U,{defaultValue:m[0].key,chevron:c?s.createElement("div",{className:j.mbChevronWrapper},s.createElement(v.Z,{size:12,color:N.r.mbColors.midGray})):s.createElement(v.Z,{color:N.r.colors.gray400}),styles:{chevron:{"&[data-rotate]":{".minus-path":{display:"block"},".plus-path":{display:"none"}}},content:{display:"flex",flexDirection:"column",gap:"16px",padding:"0"},item:{border:0},control:{paddingLeft:0,"&:hover":{background:"transparent"},"*":{pointerEvents:"none"}}}},m.map(e=>s.createElement(b.U.Item,{key:e.key,value:e.key},s.createElement(b.U.Control,{"data-event-category":"Together","data-event-action":e.eventAction,"data-event-label":d},s.createElement("div",{className:j.header},s.createElement("div",{className:j.headingIcon},s.createElement("img",{src:e.iconSrc,loading:"lazy"})),s.createElement("div",{className:j.heading},e.heading))),s.createElement(b.U.Panel,null,e.panel)))),g.length>0&&s.createElement("div",{className:j.group},s.createElement("div",{className:j.subTitle},s.createElement("img",{className:j.subIcon,src:w.C.getAssetPath(c?"mb-logo.svg":"logo/circle-solid.svg"),loading:"lazy"}),o("profilePanel.publishedArticles")),s.createElement("div",{className:`${j.relatedList}`},null==i?void 0:i.relatedPosts.map(e=>s.createElement("a",{key:String(e.id),href:`${window.location.origin}${null==e?void 0:e.permalink}`,className:j.articleCardLink},s.createElement(ArticleCard,Object.assign({className:"article-card"},Object.assign(Object.assign({},e),!e.author&&{author:{displayName:null==u?void 0:u.name,avatar:null==u?void 0:u.avatar}}),{isReview:!0})))))),h.length>0&&s.createElement("div",{className:j.group},s.createElement("div",{className:j.subTitle},s.createElement("img",{className:j.subIcon,src:w.C.getAssetPath(c?"social-mb.svg":"social.svg"),loading:"lazy"}),o("profilePanel.socialLinks")),s.createElement("div",{className:j.groupBody},s.createElement(x.k,null,p.map((e,t)=>e.url&&s.createElement("div",{className:j.socialItem,key:t},s.createElement("a",{href:e.url,target:"_blank",rel:"noreferrer"},s.createElement("img",{src:e.icon,loading:"lazy",width:"32px","data-event-category":"Together","data-event-action":e.eventAction,"data-event-label":d}))))))))};var H={container:"GYUElSy",question:"_3C6QpT1",questionTitle:"_9M9VYL6",community:"_1RuSyv3",questionCard:"_1IG-eEp"};let PostCard$1=({post:e,className:t=""})=>{var a,n,r,l,o,i,c,d;let{t:u}=(0,S.u)(),{data:{userInfo:p,env:{togetherBasePath:m}}}=(0,s.useContext)(h.T),{authActionWrapper:g,authorProps:v,currentPageUrl:f}=(0,s.useContext)(F),E=`${window.location.origin}${m}/${null===(a=null==e?void 0:e.community)||void 0===a?void 0:a.slug}/${null==e?void 0:e.slug}/`;return s.createElement("div",{className:`${H.container} ${t}`},s.createElement("div",{className:H.header},s.createElement("div",{className:H.question},u("profilePanel.question")," ",s.createElement(A.b,{className:H.questionTitle,href:"#",onClick:()=>{(null==p?void 0:p.id)||null==g||g(()=>window.location.href=E,{_location:E})}},"#",null==e?void 0:e.title)),s.createElement("div",{className:H.community},null===(n=null==e?void 0:e.community)||void 0===n?void 0:n.name," - ",null==e?void 0:e.createdTime)),s.createElement("div",{className:H.questionCard},s.createElement(T.C,Object.assign({className:"card-author"},v,{role:"user",avatarIcon:s.createElement(_.Z,null),subLine:s.createElement(T.C.SubTextRow,null,s.createElement(T.C.SubText,null,null===(o=null===(l=null===(r=null==e?void 0:e.expertAnswer)||void 0===r?void 0:r.answer)||void 0===l?void 0:l[0])||void 0===o?void 0:o.createdTime))})),s.createElement(PostContent,{className:"post-content-wrapper",description:(null===(d=null===(c=null===(i=null==e?void 0:e.expertAnswer)||void 0===i?void 0:i.answer)||void 0===c?void 0:c[0])||void 0===d?void 0:d.content)||"",mentions:null==e?void 0:e.mentions,"data-testid":"Content of the Post"})),s.createElement(O.B,{variant:"secondary","data-event-category":"Together","data-event-action":"Doctor Reply Click","data-event-label":f,size:"md",onClick:()=>{(null==p?void 0:p.id)?window.location.href=E:null==g||g(()=>window.location.href=E,{_location:E})}},u("profilePanel.anserwing.viewFull")))};var Z={container:"_8fd7YMs",thumb:"DomiQfw",content:"-b2qnfL"};let EmptyMessage=({message:e,buttonTxt:t,imgSrc:a,onBtnClick:n})=>{let{siteType:r,isMarryBaby:l}=(0,s.useContext)(F);return s.createElement("div",{className:Z.container},s.createElement("div",{className:Z.thumb},s.createElement("img",{src:a||w.C.getAssetPath(l?"comments-mb.svg":"comments.svg"),loading:"lazy"})),e&&s.createElement("div",{className:Z.content},e),t&&s.createElement(D.B,{size:"md",theme:r,color:"secondary",onClick:n},t))},Answering=({id:e})=>{let{t}=(0,S.u)(),{data:{locale:a}}=(0,s.useContext)(h.T),{authorProps:n}=(0,s.useContext)(F),[r,l]=(0,s.useState)(null),[o,c]=(0,s.useState)(!1);return(0,s.useEffect)(()=>{e&&(0,i.a)(void 0,void 0,void 0,function*(){var t;c(!0);let n=yield(0,h.c)((0,h.f)(g.yy.USER.LIST_ANSWERS,{_locale:a,id:e}),"GET"),r=((null===(t=null==n?void 0:n.data)||void 0===t?void 0:t.replies)||[]).map(m.a);l(r),c(!1)})},[]),s.createElement("div",{className:"MrdoES3"},o?s.createElement(p.L,null):null!==r&&(r.length>0?r.map(e=>s.createElement(PostCard$1,{className:"post-card",key:e.id,post:e})):s.createElement(EmptyMessage,{message:t("profilePanel.emptyPostMess.content",{name:(null==n?void 0:n.name)||(null==n?void 0:n.username)})})))},QuestionCard=e=>{var t,a,n,r,{post:l}=e,o=(0,i._)(e,["post"]);let{data:{env:{togetherBasePath:c}}}=(0,s.useContext)(h.T);return s.createElement(s.Fragment,null,s.createElement("div",Object.assign({},o,{className:`toEutn7 ${(null==o?void 0:o.className)||""}`}),s.createElement(T.C,{className:"card-author",avatar:null===(t=null==l?void 0:l.author)||void 0===t?void 0:t.avatar,name:(null===(a=null==l?void 0:l.author)||void 0===a?void 0:a.name)||(null===(n=null==l?void 0:l.author)||void 0===n?void 0:n.username),isAnonymous:!!(null==l?void 0:l.isAnonymous),subLine:s.createElement(T.C.SubTextRow,null,s.createElement(T.C.SubText,null,null==l?void 0:l.createdTime))}),s.createElement(A.b,{href:`${window.location.origin}${c}/${null===(r=null==l?void 0:l.community)||void 0===r?void 0:r.slug}/${null==l?void 0:l.slug}/`,className:"drdisHs",rel:"noreferrer"},null==l?void 0:l.title)))};var G={accordion:"I-uIJ6E",header:"_41WRsj2",heading:"AcOGL93",headingIcon:"JD3dWJN",chevron:"L2Q9T6m",container:"h-pSmhX"};let Care=()=>{var e,t;let{t:a}=(0,S.u)(),{data:{locale:n,userInfo:r}}=(0,s.useContext)(h.T),{onSkipQuestion:l,countValues:o,setCountValues:c}=(0,s.useContext)(F),[d,u]=(0,s.useState)(),[v,f]=(0,s.useState)([]),[E,x]=(0,s.useState)(!1),y=null==r?void 0:r.id;(0,s.useEffect)(()=>{y&&(0,i.a)(void 0,void 0,void 0,function*(){var e;x(!0);let t=yield(0,h.e)((0,h.f)(g.yy.USER.LIST_QUESTION_NEED_REPLY,{_locale:n}),"GET"),a=[],r=Object.create({});((null===(e=null==t?void 0:t.data)||void 0===e?void 0:e.communities)||[]).filter(e=>((null==e?void 0:e.question)||[]).length>0).map(e=>{r[e.id]=e.question.map(m.a),delete e.question,a.push((0,m.f)(e))}),f(a),u(r),x(!1)})},[]);let handleSkipQuestion=({id:e,communityId:t})=>{if(e&&t&&d){let a=Object.assign(Object.assign({},d),{[t]:[...((null==d?void 0:d[t])||[]).filter(t=>t.id!==e)]}),n=0;Object.keys(a).map(e=>n+=a[e].length||0),u(a),c(Object.assign(Object.assign({},o),{total_question:n})),null==l||l(n)}};return s.createElement("div",{className:G.container},E?s.createElement(p.L,null):(null==o?void 0:o.total_question)>0?v.length>0&&s.createElement(b.U,{className:G.accordion,defaultValue:String((null===(t=v[null===(e=Object.keys(v))||void 0===e?void 0:e[0]])||void 0===t?void 0:t.id)||""),styles:e=>({control:{padding:"16px",border:`1px solid ${e.colors.neutral[1]}`,borderTopLeftRadius:"8px",borderTopRightRadius:"8px",'&[aria-expanded="false"]':{borderBottom:0}},chevron:{width:"32px",height:"32px"},content:{padding:0,border:`1px solid ${e.colors.neutral[1]}`,borderTop:0,borderBottom:0},label:{padding:0},item:{marginBottom:"16px"}}),chevron:s.createElement("div",{className:G.chevron},s.createElement(I.Z,{color:N.r.colors.gray600,size:20}))},v.map(e=>{let t=d&&(null==d?void 0:d[e.id])||[];return t.length>0&&s.createElement(b.U.Item,{key:e.id,value:String(e.id)},s.createElement(b.U.Control,null,s.createElement("div",{className:G.header},s.createElement("div",{className:G.headingIcon},s.createElement("img",{src:e.thumbnail,loading:"lazy"})),s.createElement("div",{className:G.heading},e.name))),s.createElement(b.U.Panel,null,s.createElement("div",{className:G.body},t.map(e=>s.createElement(QuestionCard,{className:"question-card",key:e.id,post:e,onSkip:handleSkipQuestion})))))})):s.createElement(EmptyMessage,{message:a("profilePanel.emptyCareMess.content"),imgSrc:w.C.getAssetPath("questions.svg")}))},PostCard=({post:e,className:t=""})=>{var a;let{data:{userInfo:n,env:{togetherBasePath:r}}}=(0,s.useContext)(h.T),{t:l}=(0,S.u)(),o=(0,y.rZ)(),{authActionWrapper:i,authorProps:c}=(0,s.useContext)(F),d=`${window.location.origin}${r}/${null===(a=null==e?void 0:e.community)||void 0===a?void 0:a.slug}/${null==e?void 0:e.slug}/`;return s.createElement("div",{className:`GA-zc-O ${t}`},s.createElement("div",{className:"IB049vj"},s.createElement("a",{"data-event-category":"Together","data-event-action":"Click Post","data-event-label":d,className:"_8I--vEV",href:d,onClick:e=>{(null==n?void 0:n.id)||(e.preventDefault(),null==i||i(()=>window.location.href=d,{_location:d}))}}),s.createElement(T.d,{className:"card-author",avatarProps:{avatar:null==c?void 0:c.avatar,size:32}},s.createElement(T.C.MainText,{className:"A18McWD"},null==e?void 0:e.title),s.createElement(T.C.SubTextRow,null,s.createElement(T.C.SubText,null,null==e?void 0:e.createdTime))),s.createElement(PostContent,{className:"post-content-wrapper",description:null==e?void 0:e.description,mentions:null==e?void 0:e.mentions,maxChars:200,"data-testid":"Content of the Post",hideShowAllBtn:!0}),s.createElement(M.T,{size:"p3",color:o.fn.primaryColor()},l("post.seeMore"))))},Posts=()=>{let{t:e}=(0,S.u)(),{data:{locale:t}}=(0,s.useContext)(h.T),{authorId:a,authorProps:n,isAuthorLogin:r,onCloseFromPost:l}=(0,s.useContext)(F),[o,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(!1);return(0,s.useEffect)(()=>{a&&(0,i.a)(void 0,void 0,void 0,function*(){var e;u(!0);let n=yield(0,h.c)((0,h.f)(g.yy.USER.LIST_POST,{_locale:t,id:a,isAnonymous:0}),"GET"),r=((null===(e=null==n?void 0:n.data)||void 0===e?void 0:e.posts)||[]).map(m.a);c(r),u(!1)})},[a]),s.createElement("div",{className:"TSMHoEM"},d?s.createElement(p.L,null):null!==o&&(o.length>0?o.map(e=>s.createElement(PostCard,{className:"post-card",key:e.id,post:e})):s.createElement(EmptyMessage,{message:e("profilePanel.emptyPostMess.content",{name:(null==n?void 0:n.name)||(null==n?void 0:n.username)||""}),buttonTxt:r&&e("profilePanel.createPost"),onBtnClick:()=>{null==l||l()}})))};var W={container:"_4Vekw96",info:"DIJdGcB",body:"aQSt4-Q"};let formatExperience=e=>e?{title:null==e?void 0:e.title,organization:null==e?void 0:e.organization,duration:e.duration}:{},formatEducation=e=>e?{completedYear:null==e?void 0:e.completed_year,schoolName:e.school_name,study:e.study}:{};(n=l||(l={}))[n.About=0]="About",n[n.Care=1]="Care",n[n.Answer=2]="Answer",n[n.Posts=3]="Posts",(r=o||(o={}))[r.Expert=0]="Expert",r[r.User=1]="User";let V={experiences:[],relatedPosts:[],educations:[],awards:[],contact:{},data:{}},ProfileDetail=e=>{var t,{authorProps:a,selectedTab:n,authActionWrapper:r,onSkipQuestion:o,onCloseFromPost:c,hideQuestionTab:v,hideAnswerTab:f,showSkipQuestionTag:E,rolesToShowQuestionsTab:b=["expert"],currentPageUrl:x}=e,y=(0,i._)(e,["authorProps","selectedTab","authActionWrapper","onSkipQuestion","onCloseFromPost","hideQuestionTab","hideAnswerTab","showSkipQuestionTag","rolesToShowQuestionsTab","currentPageUrl"]);let{data:{locale:w,userInfo:C,env:{isMarryBaby:k}}}=(0,s.useContext)(h.T),{t:N}=(0,S.u)(),_=null==a?void 0:a.role,I=null==C?void 0:C.role,A=String(null==a?void 0:a.userId),[M,O]=(0,s.useState)(),[$,P]=(0,s.useState)(!1),[B,D]=(0,s.useState)(),R=(null==C?void 0:C._togetherUserId)===(null==a?void 0:a.userId),U=[...-1!==b.indexOf(_)?[{value:l.About,text:N("profilePanel.tabs.highlight"),content:s.createElement(About,{id:A,info:B}),dataEventCategory:"Together",dataEventAction:"Doctor Profile Click",dataEventLabel:x}]:[],{value:l.Posts,text:N("profilePanel.tabs.posts"),content:s.createElement(Posts,null),hasCountResult:!0,keyOfCountApi:"post",keyOfResult:"total_post"},...v||-1===b.indexOf(I)||(null==C?void 0:C._togetherUserId)!==(null==a?void 0:a.userId)?[]:[{value:l.Care,text:`${N("profilePanel.tabs.care")}`,content:s.createElement(Care,null),hasCountResult:!0,keyOfCountApi:"question",keyOfResult:"total_question",dataEventCategory:"Together",dataEventAction:"Doctor Questions Click",dataEventLabel:x}],...f||-1===b.indexOf(_)?[]:[{value:l.Answer,text:`${N("profilePanel.tabs.expertAnswer")}`,content:s.createElement(Answering,{id:A}),hasCountResult:!0,keyOfCountApi:"reply",keyOfResult:"total_reply",dataEventCategory:"Together",dataEventAction:"Doctor Reply Tab Click",dataEventLabel:x}]],[z,L]=(0,s.useState)(null),[j,H]=(0,s.useState)(null),Z={value:String(j),dataList:z,onTabChange:e=>H(Number(e))},G=null==U?void 0:U.filter(e=>null==e?void 0:e.hasCountResult);(0,s.useEffect)(()=>{(0,i.a)(void 0,void 0,void 0,function*(){var e,t,a,r,o,i,s,c,d,u;P(!0);let p=yield Promise.all([(0,h.c)((0,h.f)(g.yy.USER.DETAIL,{_locale:w,id:A}),"GET"),...G.map(e=>(0,h.c)((0,h.f)(g.yy.USER.COUNT_TABS,{_locale:w,id:A,[e.keyOfCountApi]:1}),"GET"))]),[v]=p,f={data:null==v?void 0:v.data,experiences:((null===(t=null===(e=null==v?void 0:v.data)||void 0===e?void 0:e.fields)||void 0===t?void 0:t.experiences)||[]).map(formatExperience),relatedPosts:((null===(a=null==v?void 0:v.data)||void 0===a?void 0:a.related_post)||[]).map(e=>(0,m.b)(e.post)),educations:((null===(o=null===(r=null==v?void 0:v.data)||void 0===r?void 0:r.fields)||void 0===o?void 0:o.educations)||[]).map(formatEducation),awards:(null===(s=null===(i=null==v?void 0:v.data)||void 0===i?void 0:i.fields)||void 0===s?void 0:s.awards_accreditations)||[],contact:(null===(d=null===(c=null==v?void 0:v.data)||void 0===c?void 0:c.fields)||void 0===d?void 0:d.contact)||{}};(null==v?void 0:v.status)===1&&D(f);let E=(null==f?void 0:f.relatedPosts)||[],b=Object.keys(f.contact).map(e=>{var t;return(null===(t=null==f?void 0:f.contact)||void 0===t?void 0:t[e])!==""}),x=[...(null==f?void 0:f.experiences)||[],...(null==f?void 0:f.educations)||[],...(null==f?void 0:f.awards)||[]],y=E.length>0||b.length>0||x.length>0,C={},T=G.map((e,t)=>{var a,n,r;let o=(null===(r=null===(n=null===(a=p[t+1])||void 0===a?void 0:a.data)||void 0===n?void 0:n.counting)||void 0===r?void 0:r[e.keyOfResult])||0;return o>0?(C[e.keyOfResult]=o,e):-1!==[l.Care,l.Posts].indexOf(e.value)?e:void 0}).filter(Boolean).map(e=>e.value),k=U.map(e=>{let t=Object.assign(Object.assign({},e),{text:e.text+(e.keyOfResult?` (${(null==C?void 0:C[e.keyOfResult])||"0"})`:"")});return t.hasCountResult?-1!==T.indexOf(t.value)?t:void 0:t.value===l.About?y&&t:t}).filter(Boolean);L(k),H(n||(null===(u=null==k?void 0:k[0])||void 0===u?void 0:u.value)),O(C),P(!1)})},[]);let V=null==B?void 0:B.data;return s.createElement(F.Provider,{value:{isMarryBaby:k,siteType:k?"marryBaby":"helloSites",authorId:String((null==a?void 0:a.userId)||""),authActionWrapper:r,onSkipQuestion:o,info:B,authorProps:a,onCloseFromPost:c,countValues:M,setCountValues:O,isAuthorLogin:R,showSkipQuestionTag:E,currentPageUrl:x}},s.createElement("div",Object.assign({},y,{className:`${W.container} ${(null==y?void 0:y.className)||""}`,"data-is-marrybaby":k}),$?s.createElement(p.L,null):s.createElement(s.Fragment,null,s.createElement(T.C,Object.assign({},a,{className:"card-author",showDetailPopup:!1,subLine:(null==a?void 0:a.role)==="expert"?(null==V?void 0:V.specialty)&&(null==V?void 0:V.organisation)&&s.createElement(T.C.SubTextRow,null,(null==V?void 0:V.specialty)&&s.createElement(s.Fragment,null,s.createElement(T.C.SubText,null,null==V?void 0:V.specialty),s.createElement(T.C.SubDivider,null)),s.createElement(T.C.SubText,null,null==V?void 0:V.organisation)):(null==V?void 0:V.created_at)&&s.createElement(T.C.SubTextRow,null,s.createElement(T.C.SubText,null,N("profilePanel.joined")," ",d()(null==V?void 0:V.created_at).toNow(!0)))})),"expert"===_&&s.createElement("div",{className:W.info,dangerouslySetInnerHTML:{__html:null===(t=null==B?void 0:B.data)||void 0===t?void 0:t.description}}),null!==z&&null!==j&&(z.length>0?s.createElement("div",{className:W.body},s.createElement(u.T,Object.assign({},Z))):s.createElement(EmptyMessage,{message:N("profilePanel.emptyPostMess.content",{text:(null==a?void 0:a.name)||(null==a?void 0:a.username)||""})})))))}},jhhs:function(e,t,a){a.d(t,{c:function(){return s}});var n=Object.prototype.toString,r=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/,l=/^("?)[\u0021\u0023-\u002B\u002D-\u003A\u003C-\u005B\u005D-\u007E]*\1$/,o=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,i=/^[\u0020-\u003A\u003D-\u007E]*$/;function startIndex(e,t,a){do{var n=e.charCodeAt(t);if(32!==n&&9!==n)return t}while(++ta;){var n=e.charCodeAt(--t);if(32!==n&&9!==n)return t+1}return a}function decode(e){return -1!==e.indexOf("%")?decodeURIComponent(e):e}var s={parse:function(e,t){if("string"!=typeof e)throw TypeError("argument str must be a string");var a={},n=e.length;if(n<2)return a;var r=t&&t.decode||decode,l=0,o=0,i=0;do{if(-1===(o=e.indexOf("=",l)))break;if(-1===(i=e.indexOf(";",l)))i=n;else if(o>i){l=e.lastIndexOf(";",o-1)+1;continue}var s=startIndex(e,l,o),c=endIndex(e,o,s),d=e.slice(s,c);if(!a.hasOwnProperty(d)){var u=startIndex(e,o+1,i),p=endIndex(e,i,u);34===e.charCodeAt(u)&&34===e.charCodeAt(p-1)&&(u++,p--);var m=e.slice(u,p);a[d]=function(e,t){try{return t(e)}catch(t){return e}}(m,r)}l=i+1}while(l{a=function(e,t,a){let r=[];return e.forEach(e=>{if("string"==typeof e){let l=RegExp(`\\{${a}\\}`,"gi");if("string"==typeof t||"number"==typeof t)r.push(e.replace(l,`${t}`));else{let a=e.split(l);a.forEach((e,l)=>{e&&(function(e){let t=[],a=!1,r=!1;return e.match(/^\s+/gi)&&(e=e.replace(/^\s+/gi,""),a=!0),e.match(/\s+$/gi)&&(e=e.replace(/\s+$/gi,""),r=!0),a&&t.push(n.createElement(n.Fragment,null,"\xa0")),t.push(e),r&&t.push(n.createElement(n.Fragment,null,"\xa0")),t})(e).forEach(e=>r.push(e)),l+1"string"==typeof e)?a.join(""):n.createElement(n.Fragment,null,a.map((e,t)=>n.createElement(n.Fragment,{key:t},e)))}function useTranslations(){let{values:e,locale:t}=(0,n.useContext)(r.T)||{locale:"en-PH"};return(0,n.useMemo)(()=>({t:(t,a)=>e?e[t]?a?format(e[t]||t,a):e[t]||t:a?format(t,a):t:t,locale:t}),[e,t])}},"Jn/A":function(e,t,a){a.d(t,{B:function(){return Button}});var n=a("6eqW"),r=a("q1tI"),l=a("p3w3");let Button=e=>{var{size:t,color:a="primary",isDisabled:o,isBlock:i,title:s,onClick:c,icon:d,iconPosition:u="left",children:p,isLoading:m=!1,loadingText:g,dataEventCategory:h,dataEventAction:v,dataEventLabel:f,dataProductChannel:E,dataProductSku:b,dataProductBrand:x,dataProductName:y,dataProductPrice:w,dataProductCategory:C,dataProductPosition:T,type:k}=e,S=(0,n._)(e,["size","color","isDisabled","isBlock","title","onClick","icon","iconPosition","children","isLoading","loadingText","dataEventCategory","dataEventAction","dataEventLabel","dataProductChannel","dataProductSku","dataProductBrand","dataProductName","dataProductPrice","dataProductCategory","dataProductPosition","type"]);return r.createElement(l.B,Object.assign({},{"data-event-category":h,"data-event-action":v,"data-event-label":f,"data-product-channel":E,"data-product-sku":b,"data-product-brand":x,"data-product-name":y,"data-product-price":w,"data-product-category":C,"data-product-position":T},{size:t,variant:"transparent"===a?"white":"danger"===a?"error":a,disabled:o,onClick:e=>{m||o||!c||c(e)},title:s,loading:m,type:k||"submit",leftIcon:"left"===u?d:void 0,rightIcon:"right"===u?d:void 0,w:i?"100%":void 0,p:i?"12px auto":void 0,"data-color":a,"data-size":t,"data-block":i,"data-has-icon":!!d||void 0,"data-theme":S.theme,"data-is-loading":m},S),m&&g||p)}},IJN9:function(e,t,a){a.d(t,{L:function(){return Loading}});var n=a("q1tI"),r=a("V2lD"),l=a("ZKGu");let Loading=({className:e,theme:t,hideText:a})=>{let{t:o}=(0,l.u)();return n.createElement("div",{className:`tliWyii ${e}`},n.createElement(r.I.Spinner,{isMarryBaby:"marryBaby"===t}),!a&&o("loading"))}}}]);