tweb/public/index.bundle.js

20 lines
580 KiB
JavaScript
Raw Normal View History

2020-08-18 19:39:57 +02:00
!function(e){function t(t){for(var i,o,r=t[0],l=t[1],d=t[2],u=0,h=[];u<r.length;u++)o=r[u],Object.prototype.hasOwnProperty.call(n,o)&&n[o]&&h.push(n[o][0]),n[o]=0;for(i in l)Object.prototype.hasOwnProperty.call(l,i)&&(e[i]=l[i]);for(c&&c(t);h.length;)h.shift()();return a.push.apply(a,d||[]),s()}function s(){for(var e,t=0;t<a.length;t++){for(var s=a[t],i=!0,r=1;r<s.length;r++){var l=s[r];0!==n[l]&&(i=!1)}i&&(a.splice(t--,1),e=o(o.s=s[0]))}return e}var i={},n={0:0},a=[];function o(t){if(i[t])return i[t].exports;var s=i[t]={i:t,l:!1,exports:{}};return e[t].call(s.exports,s,s.exports,o),s.l=!0,s.exports}o.m=e,o.c=i,o.d=function(e,t,s){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:s})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var s=Object.create(null);if(o.r(s),Object.defineProperty(s,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)o.d(s,i,function(t){return e[t]}.bind(null,i));return s},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="";var r=window.webpackJsonp=window.webpackJsonp||[],l=r.push.bind(r);r.push=t,r=r.slice();for(var d=0;d<r.length;d++)t(r[d]);var c=l;a.push([62,1,2,4]),s()}([function(e,t,s){"use strict";s.r(t),s.d(t,"dT",(function(){return n})),s.d(t,"isInDOM",(function(){return a})),s.d(t,"checkDragEvent",(function(){return o})),s.d(t,"cancelEvent",(function(){return r})),s.d(t,"getRichValue",(function(){return l})),s.d(t,"placeCaretAtEnd",(function(){return d})),s.d(t,"getRichElementValue",(function(){return c})),s.d(t,"$rootScope",(function(){return u})),s.d(t,"generatePathData",(function(){return p})),s.d(t,"langPack",(function(){return f})),s.d(t,"_",(function(){return m})),s.d(t,"isObject",(function(){return g})),s.d(t,"tsNow",(function(){return v})),s.d(t,"safeReplaceObject",(function(){return b})),s.d(t,"numberWithCommas",(function(){return y})),s.d(t,"findUpClassName",(function(){return _})),s.d(t,"findUpTag",(function(){return w})),s.d(t,"findUpAttribute",(function(){return S})),s.d(t,"whichChild",(function(){return L})),s.d(t,"copy",(function(){return M})),s.d(t,"formatBytes",(function(){return D})),s.d(t,"formatNumber",(function(){return E})),s.d(t,"deepEqual",(function(){return I})),s.d(t,"listMergeSorted",(function(){return P})),s.d(t,"escapeRegExp",(function(){return C})),s.d(t,"encodeEntities",(function(){return T})),s.d(t,"fillPropertyValue",(function(){return k})),s.d(t,"calcImageInBox",(function(){return X})),s.d(t,"emojiUnicode",(function(){return A})),s.d(t,"getEmojiToneIndex",(function(){return x}));
/*!
* Webogram v0.7.0 - messaging web application for MTProto
* https://github.com/zhukov/webogram
* Copyright (C) 2014 Igor Zhukov <igor.beatle@gmail.com>
* https://github.com/zhukov/webogram/blob/master/LICENSE
*/
2020-08-18 19:39:57 +02:00
var i=Date.now();function n(){return"["+((Date.now()-i)/1e3).toFixed(3)+"]"}function a(e,t){return!!e&&(e==(t=t||document.body)||a(e.parentNode,t))}function o(e){if(!e||e.target&&("IMG"==e.target.tagName||"A"==e.target.tagName))return!1;if(!e.dataTransfer||!e.dataTransfer.types)return!0;for(var t=0;t<e.dataTransfer.types.length;t++)if("Files"==e.dataTransfer.types[t])return!0;return!1}function r(e){if(e=e||window.event){e=e.originalEvent||e;try{e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault(),e.returnValue=!1,e.cancelBubble=!0}catch(e){}}return!1}function l(e){if(!e)return"";var t=[],s=[];c(e,t,s),s.length&&t.push(s.join(""));var i=t.join("\n");return i=i.replace(/\u00A0/g," ")}function d(e){if(e.focus(),void 0!==window.getSelection&&void 0!==document.createRange){var t=document.createRange();t.selectNodeContents(e),t.collapse(!1);var s=window.getSelection();s.removeAllRanges(),s.addRange(t)}else if(void 0!==document.body.createTextRange){var i=document.body.createTextRange();i.moveToElementText(e),i.collapse(!1),i.select()}}function c(e,t,s,i,n){if(3!=e.nodeType){if(1==e.nodeType){var a=i===e,o="DIV"==e.tagName||"P"==e.tagName;o&&s.length||"BR"==e.tagName?(t.push(s.join("")),s.splice(0,s.length)):"IMG"==e.tagName&&e.alt&&s.push(e.alt),a&&!n&&s.push("");for(var r=e.firstChild;r;)c(r,t,s,i,n),r=r.nextSibling;a&&n&&s.push(""),o&&s.length&&(t.push(s.join("")),s.splice(0,s.length))}}else if(i===e){var l=e.nodeValue;s.push(l.substr(0,n)+""+l.substr(n))}else s.push(e.nodeValue)}const u={$broadcast:(e,t)=>{let s=new CustomEvent(e,{detail:t});document.dispatchEvent(s)},$on:(e,t)=>{document.addEventListener(e,t)},selectedPeerID:0,myID:0,idle:{isIDLE:!1}};var h=function(e,t,s,i,n,a,o){return[e,",",t," ",s," ",i,",",n," ",a,",",o].join("")};function p(e,t,s,i,n,a,o,r){var l=[];return l.push("M"+(e+s/2)+","+t),l.push("H"+(e+s-a)),a>0&&l.push("A"+h(a,a,0,0,1,e+s,t+a)),l.push("V"+(t+i-o)),o>0&&l.push("A"+h(o,o,0,0,1,e+s-o,t+i)),l.push("H"+(e+r)),r>0&&l.push("A"+h(r,r,0,0,1,e+0,t+i-r)),l.push("V"+(t+n)),n>0&&l.push("A"+h(n,n,0,0,1,e+n,t+0)),l.push("Z"),l.join(" ")}const f={messageActionChatCreate:"created the group",messageActionChatEditTitle:"changed group name",messageActionChatEditPhoto:"changed group photo",messageActionChatDeletePhoto:"removed group photo",messageActionChatReturn:"returned to group",messageActionChatJoined:"joined the group",messageActionChatAddUser:"invited {user}",messageActionChatAddUsers:"invited {} users",messageActionChatLeave:"left the group",messageActionChatDeleteUser:"removed user",messageActionChatJoinedByLink:"joined the group",messageActionPinMessage:"pinned message",messageActionContactSignUp:"joined Telegram",messageActionChannelCreate:"Channel created",messageActionChannelEditTitle:"Channel renamed",messageActionChannelEditPhoto:"Channel photo updated",messageActionChannelDeletePhoto:"Channel photo removed",messageActionHistoryClear:"History cleared","messageActionPhoneCall.in_ok":"Incoming Call","messageActionPhoneCall.out_ok":"Outgoing Call","messageActionPhoneCall.in_missed":"Missed Call","messageActionPhoneCall.out_missed":"Cancelled Call"},m=e=>(e=e.replace("_raw",""),f[e]?f[e]:e);function g(e){return"object"==typeof e&&null!==e}function v(e){var t=+new Date;return e?Math.floor(t/1e3):t}function b(e,t){for(var s in e)t.hasOwnProperty(s)||"$"==s.charAt(0)||delete e[s];for(var s in t)e[s]=t[s]}function y(e){var t=e.toString().split(".");return t[0]=t[0].replace(/\B(?=(\d{3})+(?!\d))/g,","),t.join(".")}function _(e,t){if(e.classList.contains(t))return e;for(;e.parentElement;)if((e=e.parentElement).classList.contains(t))return e;return null}function w(e,t){if(e.tagName==t)return e;for(;e.parentElement;)if((e=e.parentElement).tagName===t)return e;return null}function S(e,t){if(null!=e.getAttribute(t))return e;for(;e.parentElement;)if(null!=(e=e.parentElement).getAttribute(t))return e;return null}function L(e){let t=0;for(;null!=(e=e.previousElementSibling);)++t;return t}function M(e){if(null===e||"object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTi
/*!
* Webogram v0.7.0 - messaging web application for MTProto
* https://github.com/zhukov/webogram
* Copyright (C) 2014 Igor Zhukov <igor.beatle@gmail.com>
* https://github.com/zhukov/webogram/blob/master/LICENSE
2020-08-18 19:39:57 +02:00
*/Object.defineProperty(t,"__esModule",{value:!0}),t.isSafari=t.isAndroid=t.isApple=t.touchSupport=t.mediaSizes=t.LatinizeMap=t.TLD=t.Countries=t.Emoji=void 0,t.Emoji={"#":6365,"*":6366,"0":6367,"1":6368,"2":6369,"3":6370,"4":6371,"5":6372,"6":6373,"7":6374,"8":6375,"9":6376,"©":6362,"®":6363,"🀄":573,"🃏":572,"🅰":6383,"🅱":6385,"🅾":6394,"🅿":6396,"🆎":6384,"🆑":6386,"🆒":6387,"🆓":6388,"🆔":6390,"🆕":6392,"🆖":6393,"🆗":6395,"🆘":6397,"🆙":6398,"🆚":6399,"🇦🇨":78,"🇦🇩":79,"🇦🇪":710,"🇦🇫":711,"🇦🇬":712,"🇦🇮":713,"🇦🇱":714,"🇦🇲":715,"🇦🇴":716,"🇦🇶":717,"🇦🇷":718,"🇦🇸":719,"🇦🇹":720,"🇦🇺":721,"🇦🇼":722,"🇦🇽":723,"🇦🇿":724,"🇧🇦":725,"🇧🇧":726,"🇧🇩":727,"🇧🇪":728,"🇧🇫":729,"🇧🇬":730,"🇧🇭":731,"🇧🇮":732,"🇧🇯":733,"🇧🇱":734,"🇧🇲":735,"🇧🇳":736,"🇧🇴":737,"🇧🇶":738,"🇧🇷":739,"🇧🇸":740,"🇧🇹":741,"🇧🇻":742,"🇧🇼":743,"🇧🇾":744,"🇧🇿":745,"🇨🇦":746,"🇨🇨":747,"🇨🇩":748,"🇨🇫":749,"🇨🇬":750,"🇨🇭":751,"🇨🇮":752,"🇨🇰":753,"🇨🇱":754,"🇨🇲":755,"🇨🇳":756,"🇨🇴":757,"🇨🇵":758,"🇨🇷":759,"🇨🇺":760,"🇨🇻":761,"🇨🇼":762,"🇨🇽":763,"🇨🇾":764,"🇨🇿":765,"🇩🇪":766,"🇩🇬":767,"🇩🇯":768,"🇩🇰":769,"🇩🇲":770,"🇩🇴":771,"🇩🇿":772,"🇪🇦":773,"🇪🇨":774,"🇪🇪":775,"🇪🇬":776,"🇪🇭":777,"🇪🇷":778,"🇪🇸":779,"🇪🇹":780,"🇪🇺":781,"🇫🇮":782,"🇫🇯":783,"🇫🇰":784,"🇫🇲":785,"🇫🇴":786,"🇫🇷":787,"🇬🇦":788,"🇬🇧":789,"🇬🇩":790,"🇬🇪":791,"🇬🇫":792,"🇬🇬":793,"🇬🇭":794,"🇬🇮":795,"🇬🇱":796,"🇬🇲":797,"🇬🇳":798,"🇬🇵":799,"🇬🇶":7100,"🇬🇷":7101,"🇬🇸":7102,"🇬🇹":7103,"🇬🇺":7104,"🇬🇼":7105,"🇬🇾":7106,"🇭🇰":7107,"🇭🇲":7108,"🇭🇳":7109,"🇭🇷":7110,"🇭🇹":7111,"🇭🇺":7112,"🇮🇨":7113,"🇮🇩":7114,"🇮🇪":7115,"🇮🇱":7116,"🇮🇲":7117,"🇮🇳":7118,"🇮🇴":7119,"🇮🇶":7120,"🇮🇷":7121,"🇮🇸":7122,"🇮🇹":7123,"🇯🇪":7124,"🇯🇲":7125,"🇯🇴":7126,"🇯🇵":7127,"🇰🇪":7128,"🇰🇬":7129,"🇰🇭":7130,"🇰🇮":7131,"🇰🇲":7132,"🇰🇳":7133,"🇰🇵":7134,"🇰🇷":7135,"🇰🇼":7136,"🇰🇾":7137,"🇰🇿":7138,"🇱🇦":7139,"🇱🇧":7140,"🇱🇨":7141,"🇱🇮":7142,"🇱🇰":7143,"🇱🇷":7144,"🇱🇸":7145,"🇱🇹":7146,"🇱🇺":7147,"🇱🇻":7148,"🇱🇾":7149,"🇲🇦":7150,"🇲🇨":7151,"🇲🇩":7152,"🇲🇪":7153,"🇲🇫":7154,"🇲🇬":7155,"🇲🇭":7156,"🇲🇰":7157,"🇲🇱":7158,"🇲🇲":7159,"🇲🇳":7160,"🇲🇴":7161,"🇲🇵":7162,"🇲🇶":7163,"🇲🇷":7164,"🇲🇸":7165,"🇲🇹":7166,"🇲🇺":7167,"🇲🇻":7168,"🇲🇼":7169,"🇲🇽":7170,"🇲🇾":7171,"🇲🇿":7172,"🇳🇦":7173,"🇳🇨":7174,"🇳🇪":7175,"🇳🇫":7176,"🇳🇬":7177,"🇳🇮":7178,"🇳🇱":7179,"🇳🇴":7180,"🇳🇵":7181,"🇳🇷":7182,"🇳🇺":7183,"🇳🇿":7184,"🇴🇲":7185,"🇵🇦":7186,"🇵🇪":7187,"🇵🇫":7188,"🇵🇬":7189,"🇵🇭":7190,"🇵🇰":7191,"🇵🇱":7192,"🇵🇲":7193,"🇵🇳":7194,"🇵🇷":7195,"🇵🇸":7196,"🇵🇹":7197,"🇵🇼":7198,"🇵🇾":7199,"🇶🇦":7200,"🇷🇪":7201,"🇷🇴":7202,"🇷🇸":7203,"🇷🇺":7204,"🇷🇼":7205,"🇸🇦":7206,"🇸🇧":7207,"🇸🇨":7208,"🇸🇩":7209,"🇸🇪":7210,"🇸🇬":7211,"🇸🇭":7212,"🇸🇮":7213,"🇸🇯":7214,"🇸🇰":7215,"🇸🇱":7216,"🇸🇲":7217,"🇸🇳":7218,"🇸🇴":7219,"🇸🇷":7220,"🇸🇸":7221,"🇸🇹":7222,"🇸🇻":7223,"🇸🇽":7224,"🇸🇾":7225,"🇸🇿":7226,"🇹🇦":7227,"🇹🇨":7228,"🇹🇩":7229,"🇹🇫":7230,"🇹🇬":7231,"🇹🇭":7232,
/*!
* Webogram v0.7.0 - messaging web application for MTProto
* https://github.com/zhukov/webogram
* Copyright (C) 2014 Igor Zhukov <igor.beatle@gmail.com>
* https://github.com/zhukov/webogram/blob/master/LICENSE
2020-08-18 19:39:57 +02:00
*/Object.defineProperty(t,"__esModule",{value:!0}),t.nextRandomInt=t.addPadding=t.longFromInts=t.longToBytes=t.bytesToWordss=t.bytesFromWordss=t.bytesFromWords=t.longToInts=t.bufferConcats=t.bufferConcat=t.bytesFromArrayBuffer=t.convertToByteArray=t.convertToUint8Array=t.convertToArrayBuffer=t.bytesToArrayBuffer=t.bytesFromBigInt=t.bytesXor=t.bytesCmp=t.blobSafeMimeType=t.blobConstruct=t.dataUrlToBlob=t.base64ToBlob=t.uint6ToBase64=t.bytesToBase64=t.bytesFromHex=t.bytesToHex=t.bigStringInt=t.bigint=t.isObject=t.dT=void 0;const i=s(43);var n=Date.now();function a(e){return new i.BigInteger(e.toString(16),16)}function o(e){return new i.BigInteger(e,10)}function r(e){return e<26?e+65:e<52?e+71:e<62?e-4:62===e?43:63===e?47:65}function l(e,t){for(var s=atob(e),i=s.length,n=Math.ceil(i/1024),a=new Array(n),o=0;o<n;++o){for(var r=1024*o,l=Math.min(r+1024,i),c=new Array(l-r),u=r,h=0;u<l;++h,++u)c[h]=s[u].charCodeAt(0);a[o]=new Uint8Array(c)}return d(a,t)}function d(e,t=""){var s,i=c(t);try{s=new Blob(e,{type:i})}catch(t){var n=new BlobBuilder;e.forEach((function(e){n.append(e)})),s=n.getBlob(i)}return s}function c(e){return-1===["image/jpeg","image/png","image/gif","image/webp","image/bmp","video/mp4","video/webm","video/quicktime","audio/ogg","audio/mpeg","audio/mp4"].indexOf(e)?"application/octet-stream":e}function u(e){return new Uint8Array(e).buffer}function h(e){return void 0!==e.buffer?e:new Uint8Array(e)}function p(e,t){var s=e.byteLength||e.length,i=t.byteLength||t.length,n=new Uint8Array(s+i);return n.set(e instanceof ArrayBuffer?new Uint8Array(e):e,0),n.set(t instanceof ArrayBuffer?new Uint8Array(t):t,s),n.buffer}function f(e){var t=o(e).divideAndRemainder(a(4294967296));return[t[0].intValue(),t[1].intValue()]}function m(e){for(var t=e.words,s=e.sigBytes,i=[],n=0;n<s;n++)i.push(t[n>>>2]>>>24-n%4*8&255);return i}t.dT=function(){return"["+((Date.now()-n)/1e3).toFixed(3)+"]"},t.isObject=function(e){return"object"==typeof e&&null!==e},t.bigint=a,t.bigStringInt=o,t.bytesToHex=function(e){e=e||[];for(var t=[],s=0;s<e.length;s++)t.push((e[s]<16?"0":"")+(e[s]||0).toString(16));return t.join("")},t.bytesFromHex=function(e){var t,s=e.length,i=0,n=[];for(e.length%2&&(n.push(parseInt(e.charAt(0),16)),i++),t=i;t<s;t+=2)n.push(parseInt(e.substr(t,2),16));return n},t.bytesToBase64=function(e){for(var t,s="",i=e.length,n=0,a=0;a<i;a++)t=a%3,n|=e[a]<<(16>>>t&24),2!==t&&i-a!=1||(s+=String.fromCharCode(r(n>>>18&63),r(n>>>12&63),r(n>>>6&63),r(63&n)),n=0);return s.replace(/A(?=A$|$)/g,"=")},t.uint6ToBase64=r,t.base64ToBlob=l,t.dataUrlToBlob=function(e){var t=e.split(",");return l(t[1],t[0].split(":")[1].split(";")[0])},t.blobConstruct=d,t.blobSafeMimeType=c,t.bytesCmp=function(e,t){var s=e.length;if(s!=t.length)return!1;for(var i=0;i<s;i++)if(e[i]!=t[i])return!1;return!0},t.bytesXor=function(e,t){for(var s=e.length,i=[],n=0;n<s;++n)i[n]=e[n]^t[n];return i},t.bytesFromBigInt=function(e,t){var s=e.toByteArray();if(t&&s.length<t){for(var i=[],n=0,a=t-s.length;n<a;n++)i[n]=0;s=s instanceof ArrayBuffer?p(i,s):i.concat(s)}else for(;!s[0]&&(!t||s.length>t);)s=s.slice(1);return s},t.bytesToArrayBuffer=u,t.convertToArrayBuffer=function(e){return e instanceof ArrayBuffer?e:void 0!==e.buffer&&e.buffer.byteLength==e.length*e.BYTES_PER_ELEMENT?e.buffer:u(e)},t.convertToUint8Array=h,t.convertToByteArray=function(e){if(Array.isArray(e))return e;for(var t=[],s=0,i=(e=h(e)).length;s<i;s++)t.push(e[s]);return t},t.bytesFromArrayBuffer=function(e){for(var t=e.byteLength,s=new Uint8Array(e),i=[],n=0;n<t;++n)i[n]=s[n];return i},t.bufferConcat=p,t.bufferConcats=function(...e){let t=0;e.forEach(e=>t+=e.byteLength||e.length);var s=new Uint8Array(t);let i=0;return e.forEach(e=>{s.set(e instanceof ArrayBuffer?new Uint8Array(e):e,i),i+=e.byteLength||e.length}),s},t.longToInts=f,t.bytesFromWords=m,t.bytesFromWordss=function(e){for(var t=[],s=0;s<4*e.length;s++)t.push(e[s>>>2]>>>24-s%4*8&255);return t},t.bytesToWordss=function(e){let t;t=e instanceof ArrayBuffer?new Uint8Array(e):e;var s,i=t.length,n=[];for(s=0;s<i;s++)n[s>>>2]|=t[s]<<24-s%4*8;return new Uint32Array