telegram-tt/dist/347.02a002da4d5eaf8abd1e.js

2 lines
256 KiB
JavaScript
Raw Normal View History

2021-08-21 12:34:34 +02:00
"use strict";(self.webpackChunktelegram_t=self.webpackChunktelegram_t||[]).push([[347],{6347:(e,t,n)=>{n.r(t),n.d(t,{ArchivedChats:()=>Ma,AttachMenu:()=>Rs,AttachmentModal:()=>is,BotCommandMenu:()=>Ds,BotCommandTooltip:()=>Bs,CalendarModal:()=>$e,ContactList:()=>ba,ContextMenuContainer:()=>Ga,CustomSendMenu:()=>xs,DeleteMessageModal:()=>De,Dialogs:()=>Ne,DropArea:()=>Os.Z,EmojiTooltip:()=>Xs,ForwardPicker:()=>be,GifSearch:()=>ar,HeaderMenuContainer:()=>za,HistoryCalendar:()=>Be,InlineBotTooltip:()=>qs,LeftSearch:()=>Ft,Management:()=>yr,MediaViewer:()=>me,MentionTooltip:()=>rs,MessageSelectToolbar:()=>ze,MobileSearch:()=>ja,NewChat:()=>ka,NewChatStep1:()=>Ia,NewChatStep2:()=>Na,Notifications:()=>ke,PaymentModal:()=>Yr,PinMessageModal:()=>Ue,PollModal:()=>cs,PollResults:()=>rr,ReceiptModal:()=>Vr,RightSearch:()=>Ws,SafeLinkModal:()=>Te,Settings:()=>fa,StickerSearch:()=>nr,StickerSetModal:()=>Ja,StickerTooltip:()=>Us,SymbolMenu:()=>Ls,TextFormatter:()=>Gs.Z,UnpinAllMessagesModal:()=>xe});var a=n(4050),s=n(5116),r=n(6137),o=n(1713),i=n(3716),l=n(7361),c=n(3858),d=n(4399),m=n(8085),u=n(2858),h=n(782),Z=n(1174),P=n(3989),g=n(396),p=n(5326),v=n(6202),E=n(2761),f=n(2937),C=n(7204),b=n(8674),y=n(935);function I(e,t){const n=document.createElement("div");n.classList.add("ghost");const a=new Image;if("string"==typeof e?a.src=e:e instanceof HTMLVideoElement?a.src=e.poster:a.src=e.src,n.appendChild(a),t===o.bZ.ProfileAvatar||t===o.bZ.SettingsAvatar){n.classList.add("ProfileInfo"),t===o.bZ.SettingsAvatar&&n.classList.add("self");const e=document.querySelector(t===o.bZ.ProfileAvatar?"#RightColumn .ProfileInfo .info":"#Settings .ProfileInfo .info");e&&n.appendChild(e.cloneNode(!0))}return n}function N(e,t){const n=document.querySelector(".active > .MessageList");let a=e.offsetTop+t.closest(".content-inner, .WebPage").offsetTop;return e.id.includes("album-media-")&&(a+=e.parentElement.offsetTop+e.closest(".Message").offsetTop),a>n.scrollTop&&a+t.offsetHeight<n.scrollTop+n.offsetHeight}function w(e,t){Object.assign(e.style,t)}function k(e,t){let n,a;switch(e){case o.bZ.Album:case o.bZ.ScheduledAlbum:n=`.active > .MessageList #album-media-${t.id}`,a=".full-media";break;case o.bZ.SharedMedia:n=`#shared-media${t.id}`,a="img";break;case o.bZ.SearchResult:n=`#search-media${t.id}`,a="img";break;case o.bZ.MiddleHeaderAvatar:n=".MiddleHeader .ChatInfo .Avatar",a="img.avatar-media";break;case o.bZ.SettingsAvatar:n="#Settings .ProfileInfo .active .ProfilePhoto",a="img.avatar-media";break;case o.bZ.ProfileAvatar:n="#RightColumn .ProfileInfo .active .ProfilePhoto",a="img.avatar-media";break;case o.bZ.ScheduledInline:case o.bZ.Inline:default:n=`.active > .MessageList #message${t.id}`,a=".message-content .full-media, .message-content .thumbnail"}const s=document.querySelector(n),r=s&&s.querySelectorAll(a);return{container:s,mediaEl:r&&r[r.length-1]}}function S(e,t){switch(t){case o.bZ.Album:case o.bZ.ScheduledAlbum:case o.bZ.Inline:case o.bZ.ScheduledInline:e.classList.add("rounded-corners");break;case o.bZ.SharedMedia:case o.bZ.SettingsAvatar:case o.bZ.ProfileAvatar:case o.bZ.SearchResult:e.firstChild.style.objectFit="cover";break;case o.bZ.MiddleHeaderAvatar:e.classList.add("circle")}}var M=n(9107),T=n(6590),F=n(9204),A=n(126),L=n(2255),R=n(231),$=n(790),B=n(2340),D=n(172);const U=(0,s.c$)(((e,{chatId:t,messageId:n,isAvatar:a})=>{if(a&&t)return{sender:(0,u.YA)(t)?(0,m.dy)(e,t):(0,m.Z1)(e,t)};if(!n||!t)return{};const s=(0,m.hj)(e,t,n);return{message:s,sender:s&&(0,m.Ur)(e,s)}}),((e,t)=>(0,h.ei)(t,["closeMediaViewer","focusMessage"])))((({chatId:e,messageId:t,sender:n,isAvatar:s,message:r,closeMediaViewer:o,focusMessage:i})=>{const l=(0,a.I4)((()=>{o(),i({chatId:e,messageId:t})}),[e,i,t,o]),c=(0,M.Z)();if(!n||!r&&!s)return;const d=n.id<0,m=(0,u.OU)(c,n);return a.ZP.createElement("div",{className:"SenderInfo",onClick:l},d?a.ZP.createElement(D.Z,{key:n.id,size:"medium",chat:n}):a.ZP.createElement(D.Z,{key:n.id,size:"medium",user:n}),a.ZP.createElement("div",{className:"meta"},a.ZP.createElement("div",{className:"title",dir:"auto"},m&&(0,B.Z)(m)),a.ZP.c
2021-08-21 18:18:46 +02:00
//# sourceMappingURL=347.02a002da4d5eaf8abd1e.js.map