telegram-tt/dist/126.56949b6fb714b8786c3b.js

2 lines
316 KiB
JavaScript
Raw Normal View History

2022-02-20 12:49:20 +01:00
"use strict";(self.webpackChunktelegram_t=self.webpackChunktelegram_t||[]).push([[126],{9126:(e,t,n)=>{n.r(t),n.d(t,{ArchivedChats:()=>ts,AttachMenu:()=>Er,AttachmentModal:()=>zs,BotCommandMenu:()=>br,BotCommandTooltip:()=>fr,CalendarModal:()=>je,ChatFolderModal:()=>as,ContactList:()=>Va,ContextMenuContainer:()=>Is,CustomSendMenu:()=>yr,DeleteMessageModal:()=>We,Dialogs:()=>Oe,DropArea:()=>Nr.Z,EmojiInteractionAnimation:()=>ut,EmojiTooltip:()=>wr,ForwardPicker:()=>$e,GifSearch:()=>Xr,HeaderMenuContainer:()=>ks,HistoryCalendar:()=>Ke,InlineBotTooltip:()=>Br,LeftSearch:()=>tn,Management:()=>bl,MediaViewer:()=>be,MentionTooltip:()=>Js,MessageSelectToolbar:()=>rt,MobileSearch:()=>Ms,NewChat:()=>Qa,NewChatStep1:()=>ja,NewChatStep2:()=>Ka,Notifications:()=>Ge,PaymentModal:()=>Vl,PinMessageModal:()=>Qe,PollModal:()=>Ys,PollResults:()=>_r,ReactorListModal:()=>ct,ReceiptModal:()=>Kl,RightSearch:()=>Dr,SafeLinkModal:()=>ze,SeenByModal:()=>lt,SendAsMenu:()=>$r,Settings:()=>Ya,StickerSearch:()=>Jr,StickerSetModal:()=>ys,StickerTooltip:()=>Ir,SymbolMenu:()=>pr,TextFormatter:()=>kr.Z,UnpinAllMessagesModal:()=>et});var a=n(4050),s=n(5116),r=n(6137),l=n(1713),o=n(3716),i=n(7361),c=n(2937),d=n(5326),m=n(8674),u=n(6590),h=n(9107),Z=n(6202),v=n(2566),P=n(7204),g=n(8415),p=n(9066),E=n(396),C=n(3989),f=n(1174),b=n(3858),I=n(4399),y=n(996),N=n(3227);function k(e,t){const n=document.createElement("div");n.classList.add("ghost");const a=new Image;if(a.draggable=!1,a.oncontextmenu=N.Z,"string"==typeof e?a.src=e:e instanceof HTMLVideoElement?a.src=e.poster:a.src=e.src,n.appendChild(a),t===l.bZ.ProfileAvatar||t===l.bZ.SettingsAvatar){n.classList.add("ProfileInfo"),t===l.bZ.SettingsAvatar&&n.classList.add("self");const e=document.querySelector(t===l.bZ.ProfileAvatar?"#RightColumn .ProfileInfo .info":"#Settings .ProfileInfo .info");e&&n.appendChild(e.cloneNode(!0))}return n}function S(e,t){const n=document.querySelector(".Transition__slide--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 M(e,t){let n,a;switch(e){case l.bZ.Album:case l.bZ.ScheduledAlbum:n=`.Transition__slide--active > .MessageList #album-media-${t.id}`,a=".full-media";break;case l.bZ.SharedMedia:n=`#shared-media${t.id}`,a="img";break;case l.bZ.SearchResult:n=`#search-media${t.id}`,a="img";break;case l.bZ.MiddleHeaderAvatar:n=".MiddleHeader .Transition__slide--active .ChatInfo .Avatar",a="img.avatar-media";break;case l.bZ.SettingsAvatar:n="#Settings .ProfileInfo .Transition__slide--active .ProfilePhoto",a="img.avatar-media";break;case l.bZ.ProfileAvatar:n="#RightColumn .ProfileInfo .Transition__slide--active .ProfilePhoto",a="img.avatar-media";break;case l.bZ.ScheduledInline:case l.bZ.Inline:default:n=`.Transition__slide--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:null==r?void 0:r[r.length-1]}}function T(e,t){switch(t){case l.bZ.Album:case l.bZ.ScheduledAlbum:case l.bZ.Inline:case l.bZ.ScheduledInline:e.classList.add("rounded-corners");break;case l.bZ.SharedMedia:case l.bZ.SettingsAvatar:case l.bZ.ProfileAvatar:case l.bZ.SearchResult:e.firstChild.style.objectFit="cover";break;case l.bZ.MiddleHeaderAvatar:e.classList.add("circle")}}var R=n(231),A=n(126),L=n(2255),F=n(3106),B=n(8964),$=n(9196);const x=(0,a.X$)((0,s.c$)(((e,t)=>{let{message:n}=t;return{isDownloading:!!n&&(0,p.te)(e,n),isProtected:(0,p.EV)(e,n)}}))((e=>{let{mediaData:t,isVideo:n,isZoomed:r,message:l,fileName:o,isAvatar:c,isDownloading:d,isProtected:m,onCloseMediaViewer:u,onForward:Z,onZoomToggle:P}=e;const{downloadMessageMedia:p,cancelMessageMediaDownload:E}=(0,s.uC)(),{loadProgress:C}=(0,v.Z)(l&&(0,g.Ti)(l,"download"),!d),f=(0,a.I4)((()=>{d?E({message:l}):p({message:l})}),[E,p,d,l]),b=(0,h.Z)(),I=(0,a.Ye)((()=>e=>{let{onTrigger:t
//# sourceMappingURL=126.56949b6fb714b8786c3b.js.map