Module 829963

1,474 characters · in 2f9baa53e1c5e105.js
Dependencies
Required by (1)
Lazily required by (0)none
Lazily requires (0)none
Source Raw
function(e,t,n){n.d(t,{A:()=>p}),n(321073);var i=n(627968),a=n(64700),l=n(397927),r=n(572211),s=n(354287),o=n(693879),d=n(353411),c=n(882171),u=n(206589),_=n(768349),m=n(985018),h=n(193018);function p(e){let{application:t,message:n,header:p,presenceActivity:g,hideParty:A,partyStatusElement:x,currentUserPresenceActivity:f,onClickContent:C,onView:E,guildId:I}=e,v=(0,u.w)(f,g),b=(0,d.Gq)(g,n.author,"Invite Embed"),T=a.useMemo(()=>{let e=[];return v||e.push({label:b.label??m.intl.string(m.t.VJlc0S),trackingArea:s.kY.SYNC,onClick:()=>{b.onClick()},disabled:b.disabled,disabledReason:b.disabled?b.tooltip:void 0}),e},[v,b]),y=null!=g&&null!=g.details&&null!=g.state?m.intl.formatToPlainString(m.t.JCvHtx,{track:g.details,artist:g.state}):t.name,S=g?.timestamps?.start??g?.created_at,N=a.useMemo(()=>null!=S?(0,i.jsxs)("div",{className:h.Ym,children:[(0,i.jsx)(l.T7G,{size:"xxs",color:"currentColor"}),(0,i.jsx)(o.z,{entry:{start:S,end:g?.timestamps?.end},textColor:"currentColor",textTabularNumbers:!1,textFontCode:!1})]}):null,[S,g?.timestamps?.end]),j=a.useMemo(()=>(0,i.jsxs)("div",{className:h.pq,children:[(0,i.jsx)(l.Text,{variant:"text-xs/normal",className:h.dS,color:"none",lineClamp:1,children:N}),A?null:x]}),[N,A,x]);return(0,i.jsx)(r.h,{header:p,title:y,iconSrc:(0,c.A)(g,t.id)??void 0,info:j,actions:T,onClickContent:C,trackingConfig:{id:t.id,linkType:_.J.RICH_PRESENCE_INVITE,onView:E,referrerId:n.author.id,guildId:I,channelId:n.channel_id,messageId:n.id}})}}