PageSourceSearch

https://cybershoke.net/assets/ProfileFriends-Bi4VxGJe.js

js cybershoke.net collected 2026-10-04 05:23:42 UTC 8,384 bytes, 204 lines download raw bytes

1import{r as E,j as n}from"./vendor-react-BGN68_Lp.js";import{E as B,g as $,N as d,I as D,b as P,S as A,G as f,dH as L,dI as N,m as U,A as G,s as M}from"./index-uear5Vpj.js";import{a as T,u as h}from"./vendor-redux-D8sX5Eqv.js";import{g as K}from"./MatchIcons-CVn1p0ME.js";import{g as o}from"./vendor-styled-pkIKgjgv.js";import{u as Y}from"./vendor-i18n-BWleq_Sd.js";import"./vendor-socket-DSYo_sTV.js";import"./vendor-router-CYD8mbvC.js";const m=$("/img/p_background/small/de_dust2_b.jpg"),W=o.div`
2    margin: 1vw;
3    display: block;
4`,H=o.div`
5    width: 100%;
6    display: block;
7    float: right;
8
9    @media (max-width: 650px) {
10        float: none;
11        padding: 6px;
12    }
13`,u=o.div`
14    h4 {
15        margin-bottom: 6px;
16        text-transform: none;
17        font-family: 'Roboto';
18        font-weight: 500;
19        font-size: 12px;
20        letter-spacing: -0.02em;
21        color: #748297;
22    }
23`,b=o.div`
24    display: grid;
25    width: 100%;
26    grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)) !important;
27    gap: 0.8rem;
28    overflow: initial;
29    align-content: flex-start;
30    margin-bottom: 24px;
31`,v=o.div`
32    position: relative;
33    transition: 0.3s;
34    height: 50px;
35    display: flex;
36    border-radius: 5px;
37    opacity: ${({$offline:t})=>t?.7:1};
38    background:
39        linear-gradient(to right, rgba(31, 37, 53, 0.8) 0%, #1d212d 100%),
40        url(${({$background:t})=>t}) no-repeat center center / cover;
41    overflow: hidden;
42
43    &::after {
44        content: '';
45        display: ${({$banned:t})=>t?"block":"none"};
46        position: absolute;
47        top: 0;
48        left: 0;
49        width: 100%;
50        height: 100%;
51        pointer-events: none;
52        background: radial-gradient(
53            100% 100% at 0% 50%,
54            rgba(229, 0, 39, 0.22) 0%,
55            rgba(229, 0, 39, 0.08) 44%,
56            rgba(229, 0, 39, 0) 100%
57        );
58        z-index: 0;
59    }
60
61    > a {
62        display: flex;
63        min-width: 0;
64        color: inherit;
65        text-decoration: none;
66        z-index: 1;
67    }
68
69    > a:first-of-type {
70        flex-shrink: 0;
71    }
72
73    > a:nth-of-type(2) {
74        flex: 1;
75        padding-right: 45px;
76    }
77
78    &:hover {
79        cursor: pointer;
80        opacity: 1;
81        transform: translateY(3px) !important;
82        z-index: 101 !important;
83    }
84`,J=({$status:t,$banned:s})=>s?"#e50027":t==="online"?"#3999de":t==="ingame"?"#33ff7b":"#636772",y=o.div`
85    display: flex;
86    align-items: center;
87    padding-left: 12px;
88    padding-right: 10px;
89    z-index: 1;
90
91    &::before {
92        content: '';
93        position: absolute;
94        width: 10px;
95        height: 10px;
96        display: block;
97        border-radius: 50%;
98        background: ${J};
99        border: 2px solid #0f141b;
100        box-sizing: border-box;
101        top: 10px;
102        left: 8px;
103        z-index: 1;
104    }
105
106    img {
107        height: 31px;
108        width: 31px;
109        border-radius: 50%;
110        object-fit: cover;
111    }
112`,j=o.div`
113    text-overflow: ellipsis;
114    width: 100%;
115    padding-right: ${({$action:t})=>t?"45px":"0"};
116    white-space: nowrap;
117    display: flex;
118    flex-direction: column;
119    justify-content: center;
120    z-index: 1;
121`,V=o.div`
122    display: flex;
123    align-items: center;
124    gap: 6px;
125    min-width: 0;
126`,Q=o.div`
127    text-overflow: ellipsis;
128    overflow: hidden;
129    max-width: 70%;
130    font-family: 'Roboto';
131    font-weight: bold;
132    font-size: 14px;
133    color: ${({$status:t})=>t==="online"?"#57cbde":t==="ingame"?"#e3ffc2":"#818fa3"};
134`,X=o.span`
135    flex-shrink: 0;
136    height: 15px;
137    padding: 0 5px;
138    border: 1px solid #e53935;
139    border-radius: 4px;
140    color: #e53935;
141    font-family: 'Roboto Condensed';
142    font-size: 9px;
143    font-weight: 700;
144    line-height: 13px;
145`,w=o.div`
146    text-overflow: ellipsis;
147    font-family: 'Roboto';
148    font-weight: 500;
149    font-size: 11px;
150    margin-top: 2px;
151    width: ${({$status:t})=>t==="ingame"?"85%":"auto"};
152    white-space: ${({$status:t})=>t==="ingame"?"nowrap":"normal"};
153    overflow: ${({$status:t})=>t==="ingame"?"hidden":"visible"};
154    color: ${({$status:t})=>t==="ingame"?"#a3cf06":t==="offline"?"#586577":"inherit"};
155`,z=o.span`
156    border-bottom-right-radius: 5px;
157    border-top-right-radius: 5px;
158    background: #11172121;
159    transition: 0.3s;
160    z-index: 25;
161    position: absolute;
162    opacity: 1;
163    top: 0;
164    height: 100%;
165    right: 0;
166    text-decoration: none;
167    color: #aecce4;
168    display: flex;
169    padding: 0 13px;
170    align-items: center;
171    text-align: center;
172
173    img {
174        height: 19px;
175    }
176
177    p {
178        display: none;
179        position: absolute;
180        right: 120%;
181        white-space: nowrap;
182        opacity: 1;
183        border-radius: 4px;
184        padding: 0px 8px;
185        font-size: 12px;
186        background-color: #1c2130;
187        outline: 0;
188        height: 28px;
189        font-family: 'Roboto';
190        color: #8f96ac;
191        justify-content: center;
192        align-items: center;
193        transition: 0.3s;
194    }
195
196    &:hover p {
197        display: inline-flex;
198    }
199`,Z=o(z)`
200    &[aria-disabled='true'] {
201        opacity: 0.45;
202        pointer-events: none;
203    }
204`,le=({list:t})=>{const{t:s}=Y(),S=T(),c=h(e=>e.matches.currentLobby),k=h(e=>e.auth.currentServer),C=h(e=>String(e.auth.steamid64)===String(e.profilePage.profileInfo.steamid)),[_,F]=E.useState({}),I=C&&!!(c||k),O=(e,a)=>{if(e.preventDefault(),e.stopPropagation(),_[a])return;F(x=>({...x,[a]:!0})),(c?U.inviteFriend(c.id_lobby,a):G.inviteFriend(k.id,a)).then(x=>
204{if(x?.result==="success")return M(s("InvitationSent"));F(q=>({...q,[a]:!1}))})};let i=t.friends_all,r=t.friends_servers_online,l=[];const R=e=>e?.status!=2?null:e?.mute||e?.is_muted||e?.ban_type==="mute"||e?.type===1||e?.type===3?"mute":"ban",p=(e,a)=>{const g=R(e);return n.jsxs(V,{children:[n.jsx(Q,{$status:a,children:N(e?.name)}),g&&n.jsx(X,{children:s(g).toUpperCase()})]})};return t.friends_site_online.forEach(e=>{typeof r[e]>"u"&&l.push(e)}),!i||!Object.keys(i).length?n.jsx(B,{icon:$("/pages/profile/empty/friends.svg"),text:"FRIENDS-LIST-EMPTY"}):n.jsx(W,{children:n.jsxs(H,{children:[Object.keys(r).length>0&&n.jsxs(u,{children:[n.jsx("h4",{children:s("InGame")}),n.jsx(b,{children:Object.keys(r).map(e=>n.jsxs(v,{$banned:i[e]?.status==2,$background:f(r[e]?.background)||m,children:[n.jsx(d,{to:r[e].name_unique?`/id/${r[e].name_unique}`:`/profile/${e}`,children:n.jsx(y,{$status:"ingame",$banned:i[e]?.status==2,children:n.jsx("img",{loading:"lazy",src:r[e].avatar,alt:""})})}),n.jsx(d,{to:r[e].name_unique?`/id/${r[e].name_unique}`:`/profile/${e}`,children:n.jsxs(j,{children:[p(i[e],"ingame"),n.jsxs(w,{$status:"ingame",children:[s("PlayOn")," ",r[e].name]})]})}),n.jsxs(z,{onClick:()=>S(P(A[r[e].id_games],{ip:r[e].server.split(":")[0],port:r[e].server.split(":")[1],source:"profile friends"})),children:[n.jsx("img",{loading:"lazy",src:D("/storage/images/icons-svg/play-circle-outline.svg"),alt:""}),n.jsx("p",{children:s("Join")})]})]},e))})]}),l.length>0&&n.jsxs(u,{children:[n.jsx("h4",{children:s("OnSite")}),n.jsx(b,{children:l.map(e=>r[e]!=null?null:n.jsxs(v,{as:d,$status:"online",$banned:i[e].status==2,$background:f(i[e]?.background)||m,to:i[e].name_unique?`/id/${i[e].name_unique}`:`/profile/${e}`,children:[n.jsx(y,{$status:"online",$banned:i[e].status==2,children:n.jsx("img",{loading:"lazy",src:i[e]&&i[e].avatar,alt:""})}),n.jsxs(j,{$action:I,children:[p(i[e],"online"),n.jsx(w,{})]}),I&&n.jsxs(Z,{role:"button","aria-disabled":!!_[e],onClick:a=>O(a,e),children:[n.jsx(K,{}),n.jsx("p",{children:s("InviteFriend")})]})]},e))})]}),!Object.keys(i).length||i==0?null:n.jsxs(u,{children:[n.jsx("h4",{children:s("Offline")}),n.jsx(b,{children:Object.keys(i).map((e,a)=>r[e]==null&&l.indexOf(e)===-1?n.jsxs(v,{as:d,$offline:!0,$banned:i[e].status==2,$background:f(i[e]?.background)||m,to:i[e].name_unique?`/id/${i[e].name_unique}`:`/profile/${e}`,children:[n.jsx(y,{$status:"offline",$banned:i[e].status==2,children:i[e].avatar?n.jsx("img",{loading:"lazy",src:i[e].avatar,alt:""}):n.jsx("img",{loading:"lazy",src:$("/img/png/ava.png"),alt:""})}),n.jsxs(j,{children:[p(i[e],"offline"),i[e].lastconnect!=0&&n.jsxs(w,{$status:"offline",children:[s("WasIn")," -"," ",L(i[e].lastconnect)]})]})]},e):null)})]})]})})};export{y as FriendAvatar,v as FriendCard,j as FriendContent,Q as FriendName,w as FriendServer,le as default};

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.