1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3368],{3368:(e,n,t)=>{t.d(n,{A:()=>R});var r=t(42969),o=t(63857),i=t(27925),s=t(43081),l=t.n(s),a=t(14232),c=t(77662),u=t(23147),d=t(39386),p=t(39548),x=t(20852),f=t(81490),m=t(65484),h=t(44254),g=t(53747),w=t(97304),A=t(3412),v=t(48230),j=t.n(v),k=t(12619),S=t(59823),b=t(31866),y=t(84091),N=t(75741),C=t(26741),U=t(8257),E=t(57683),P=t(21911),T=t(45793),B=(0,E.Ay)(P.A)(function(e){var n=e.theme;return{".upperSectionContainer":(0,r.A)({justifyContent:"space-between",flexDirection:"row"},n.breakpoints.down("sm"),{flexDirection:"column-reverse"}),".picNameSection":{display:"flex",alignItems:"center"},".profilePicContainer":{display:"inline-block"},".nameContainer":{display:"inline-block",verticalAlign:"middle"},".activityScoreContainer":{marginTop:"5px",fontWeight:400,fontSize:"14px",color:n.palette.grey[800]},".menuSection":(0,r.A)({marginLeft:"auto",marginBottom:0},n.breakpoints.down("sm"),{marginBottom:"19px"}),".editButton":{marginTop:"-3px"},".menuButton":{borderRadius:"4px",border:"1px solid ".concat(n.palette.primary.main)},".menuIcon":{color:n.palette.primary.main},".bioText":(0,r.A)({fontSize:"16px",marginTop:"26px",marginBottom:"30px"},n.breakpoints.down("sm"),{marginTop:"19px"}),".sectionDivider":{borderBottom:"1px solid ".concat(T.A2)}}}),D=t(94555),I=t(37876);let R=function(e){var n,t,s,v,E,P,T,R,z,F,O,W,_,K,Q,V=e.username,q=e.userPic,H=e.firstName,L=e.lastName,G=e.displayName,J=e.userBio,M=e.userRole,X=e.isOwner,Y=e.setShareDialogOpen,Z=void 0===Y?function(){}:Y,$=e.setEditDialogOpen,ee=void 0===$?function(){}:$,en=e.setReportDialogOpen,et=void 0===en?function(){}:en,er=e.ownerId,eo=e.ownerEmail,ei=void 0===eo?"":eo,es=e.suspended,el=e.externalActivityScore,ea=void 0===el?-1:el,ec=(0,p.A)(),eu=(0,D.S)().user,ed=null==eu||null==(z=eu.getUser)?void 0:z.id,ep=null==eu||null==(F=eu.getUser)?void 0:F.email,ex=(0,U.VK)(null==eu||null==(O=eu.getUser)?void 0:O.firstName,null==eu||null==(W=eu.getUser)?void 0:W.lastName,null==eu||null==(_=eu.getUser)?void 0:_.displayName),ef=null!=eu&&null!=(K=eu.getUser)&&null!=(K=K.usernames)&&K.items&&0!==eu.getUser.usernames.items.length&&eu.getUser.usernames.items[0]?eu.getUser.usernames.items[0].id:"undefined",em=(null==eu||null==(Q=eu.getUser)?void 0:Q.userRole)||"",eh=(0,a.useState)(q),eg=eh[0],ew=eh[1],eA=a.useState(null),ev=(0,i.A)(eA,2),ej=ev[0],ek=ev[1];(0,a.useEffect)(function(){ew(q)},[q]);var eS=(0,a.useState)(0),eb=eS[0],ey=eS[1],eN=(0,a.useState)(0),eC=eN[0],eU=eN[1];(0,a.useEffect)(function(){-1!==ea&&ey(ea)},[ea]);var eE=(t=(0,o.A)(l().mark(function e(n){var t,r;return l().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,N.dW)(n,0);case 2:if((t=e.sent).success?ey(JSON.parse(t.data).activityScore||0):console.log("error getting activity score",t),!er){e.next=9;break}return e.next=7,(0,y.hQ6)(er,"followUser");case 7:(r=e.sent)&&eU(r.length);case 9:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)});(0,a.useEffect)(function(){er&&eE(er)},[er]);var eP=void 0!==J,eT=(0,a.useState)(null),eB=eT[0],eD=eT[1],eI=(s=(0,o.A)(l().mark(function e(){return l().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(!X&&ed&&er)){e.next=11;break}return e.next=3,(0,y.hQ6)(er,"followUser",1e3,ed);case 3:return eD(e.sent),e.next=7,(0,y.hQ6)(er,"newFollower",1e3,er);case 7:if(e.sent){e.next=11;break}return e.next=11,(0,y.H8j)(er,"newFollower",er,ei,(0,U.VK)(H,L,G),H);case 11:case"end":return e.stop()}},e)})),function(){return s.apply(this,arguments)});(0,a.useEffect)(function(){eI()},[ed]);var eR=(v=(0,o.A)(l().mark(function e(){var n,t,r;return l().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(ed&&er)){e.next=25;break}if(!eB){e.next=12;break}return(0,y.GS4)(eB.id,eB._version),eD(null),e.next=6,(0,S.o9)(er,"acquireFollower",!0);case 6:ey(e.sent),(0,S.o9)(ed,"followUser",!0),eU(eC-1),e.next=25;break;case 12:if(!ep){e.next=25;break}return e.next=15,(0,y.H8j)(er,"followUser",ed,ep,ex,(null==eu||null==(n=eu.getUser)?void 0:n.firstName)||ex);case 15:return eD(e.sent),r=(0,C.U0)({followerId:ed,followerName:ex,followerUsername:ef,date:new Date().toISOString()}),null!=eu&&null!=(t=eu.getUser)&&t.suspended||(0,C.WI)("newFollower",er,r,ed,ed),eU(eC+1),e.next=22,(0,S.o9)(er,"acquireFollower");case 22:ey(e.sent),(0,S.o9)(ed,"followUser");case 25:case"end":return e.stop()}},e)})),function(){return v.apply(this,arguments)}),ez=!!ej,eF=function(){ek(null)},eO=function(e){switch(e){case"share":Z(!0);break;case"edit":ee(!0);break;case"follow":eR();break;case"report":et(!0)}eF()};return(0,I.jsxs)(B,{children:[(0,I.jsxs)(f.A,{container:!0,className:"upperSectionContainer",children:[(E=(0,r.A)({fontWeight:700,fontSize:eP?"34px":"18px"},ec.breakpoints.down("sm"),{fontSize:eP?"24px":"18px"}),P={fontWeight:400,fontSize:"14px",color:ec.palette.grey[800]}
1,T="".concat(V?"@".concat(V):"").concat(V&&M?" | ":"").concat(M?"".concat(M):"").concat(void 0!==es&&es&&((0,U.f6)(em)||(0,U.rc)(em))?" (suspended)":""),R=(0,I.jsxs)(f.A,{className:"picNameSection",sx:{cursor:eP?"default":"pointer","&:hover":{textDecoration:eP?"none":"underline"}},children:[(0,I.jsx)("div",{className:"profilePicContainer",children:(n=(0,r.A)({width:eP?"157px":"50px",height:eP?"157px":"50px",marginRight:eP?"23px":"9px"},ec.breakpoints.down("sm"),{width:eP?"94px":"50px",height:eP?"94px":"50px",marginRight:"9px"}),eg===b.ez?(0,I.jsx)(x.A,{sx:n,alt:"Profile Picture",children:(0,I.jsx)("div",{style:{marginTop:"-23px"},children:(0,I.jsx)(k.A,{withWedge:!1})})}):(0,I.jsx)(x.A,{sx:n,src:eg,alt:"Profile Picture"}))}),(0,I.jsxs)("div",{className:"nameContainer",children:[(0,I.jsx)(m.A,{sx:E,children:(0,U.VK)(H,L,G)}),(0,I.jsx)(m.A,{sx:P,children:T}),(0,I.jsxs)(m.A,{className:"activityScoreContainer",children:[(0,I.jsx)(d.A,{sx:{position:"absolute",marginTop:"-2px",width:"20px",color:"gold"}}),(0,I.jsx)("span",{style:{paddingLeft:"22px"},children:eb})]}),(0,I.jsxs)(m.A,{className:"activityScoreContainer",children:[eC," follower",1===eC?"":"s"]})]})]}),eP?R:(0,I.jsx)(j(),{href:"/users/".concat(V),children:R})),(0,I.jsxs)(f.A,{className:"menuSection",children:[eP&&(0,I.jsx)(h.A,{className:"menuButton",onClick:function(e){ek(e.currentTarget)},children:(0,I.jsx)(u.A,{className:"menuIcon"})}),X?(0,I.jsxs)(g.A,{anchorEl:ej,open:ez,onClose:eF,children:[(0,I.jsx)(w.A,{onClick:function(){return eO("share")},children:"Share Profile"}),(0,I.jsx)(w.A,{onClick:function(){return eO("edit")},children:"Edit Profile"})]}):ed?(0,I.jsxs)(g.A,{anchorEl:ej,open:ez,onClose:eF,children:[(0,I.jsx)(w.A,{onClick:function(){return eO("share")},children:"Share Profile"}),(0,I.jsxs)(w.A,{onClick:function(){return eO("follow")},children:[eB?"Unfollow":"Follow"," User"]}),(0,I.jsx)(w.A,{onClick:function(){return eO("report")},children:"Report Profile"})]}):(0,I.jsx)(g.A,{anchorEl:ej,open:ez,onClose:eF,children:(0,I.jsx)(w.A,{onClick:function(){return eO("share")},children:"Share Profile"})})]})]}),(0,I.jsx)(f.A,{className:"bioText",sx:{color:J?"#000000":ec.palette.grey[800]},children:J||(X&&eP?(0,I.jsxs)(f.A,{children:["Tell us about yourself ..."," ",(0,I.jsx)(h.A,{className:"editButton",onClick:function(){return eO("edit")},children:(0,I.jsx)(c.A,{})})]}):"This user does not have a bio yet.")}),eP&&(0,I.jsx)(A.A,{className:"sectionDivider"})]})}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.