101 lines
4.3 KiB
HTML
101 lines
4.3 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en" translate="no" class="notranslate">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
|
|
<title>
|
|
<%= htmlWebpackPlugin.options.appTitle %>
|
|
</title>
|
|
|
|
<meta name="title" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta name="description"
|
|
content="Telegram is a cloud-based mobile and desktop messaging app with a focus on security and speed.">
|
|
<meta name="viewport"
|
|
content="width=device-width, initial-scale=1, maximum-scale=1.0, user-scalable=no, shrink-to-fit=no, viewport-fit=cover">
|
|
<meta name="mobile-web-app-capable" content="yes">
|
|
<meta name="mobile-web-app-title" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
|
<meta name="apple-mobile-web-app-title" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta name="application-name" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta name="msapplication-TileColor" content="#2b5797">
|
|
<meta name="msapplication-config" content="./browserconfig.xml">
|
|
<meta name="theme-color" content="#ffffff">
|
|
<meta name="google" content="notranslate">
|
|
|
|
<!-- Open Graph / Facebook -->
|
|
<meta property="og:type" content="website">
|
|
<meta property="og:url" content="<%= htmlWebpackPlugin.options.baseUrl %>">
|
|
<meta property="og:title" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta property="og:description"
|
|
content="Telegram is a cloud-based mobile and desktop messaging app with a focus on security and speed.">
|
|
<meta property="og:image" content="./<%= htmlWebpackPlugin.options.mainIcon %>.png">
|
|
|
|
<!-- Twitter -->
|
|
<meta property="twitter:card" content="summary_large_image">
|
|
<meta property="twitter:url" content="<%= htmlWebpackPlugin.options.baseUrl %>">
|
|
<meta property="twitter:title" content="<%= htmlWebpackPlugin.options.appTitle %>">
|
|
<meta property="twitter:description"
|
|
content="Telegram is a cloud-based mobile and desktop messaging app with a focus on security and speed.">
|
|
<meta property="twitter:image" content="./<%= htmlWebpackPlugin.options.mainIcon %>.png">
|
|
|
|
<link rel="canonical" href="https://web.telegram.org/">
|
|
<link rel="apple-touch-icon" sizes="180x180" href="./<%= htmlWebpackPlugin.options.appleIcon %>.png">
|
|
<link rel="icon" href="./favicon.svg" type="image/svg+xml">
|
|
<link rel="icon" type="image/png" sizes="16x16" href="./favicon-16x16.png">
|
|
<link rel="icon" type="image/png" sizes="32x32" href="./favicon-32x32.png">
|
|
<link rel="icon" type="image/png" sizes="192x192" href="./<%= htmlWebpackPlugin.options.mainIcon %>.png">
|
|
<link rel="alternate icon" href="./favicon.ico" type="image/x-icon">
|
|
<link rel="manifest" id="the-manifest-placeholder" href="./<%= htmlWebpackPlugin.options.manifest %>">
|
|
|
|
<script>
|
|
const { pathname, hostname, href } = window.location;
|
|
|
|
if (pathname.startsWith('/z')) {
|
|
window.location.href = href.replace('/z', '/a');
|
|
}
|
|
|
|
if ((hostname === 'weba.telegram.org' || hostname === 'webz.telegram.org') && !localStorage.getItem('tt-global-state')) {
|
|
window.location.href = 'https://web.telegram.org/a';
|
|
}
|
|
</script>
|
|
</head>
|
|
|
|
<body id="root">
|
|
<noscript>
|
|
<video src="./nojs.mp4" class="nojs-video" muted loop autoplay playsinline disablePictureInPicture></video>
|
|
<h1>Telegram Web</h1>
|
|
<p>Please, enable JavaScript to open the app.</p>
|
|
</noscript>
|
|
<div id="portals"></div>
|
|
<script>
|
|
function compatTest() {
|
|
var hasPromise = typeof Promise !== 'undefined';
|
|
var hasWebSockets = typeof WebSocket !== 'undefined';
|
|
var hasWebCrypto = window.crypto && typeof window.crypto.subtle !== 'undefined';
|
|
var hasObjectFromEntries = typeof Object.fromEntries !== 'undefined';
|
|
|
|
var isCompatible = hasPromise && hasWebSockets && hasWebCrypto && hasObjectFromEntries;
|
|
|
|
if (isCompatible || (window.localStorage && window.localStorage.getItem('tt-ignore-compat'))) {
|
|
window.isCompatTestPassed = true;
|
|
return;
|
|
}
|
|
|
|
if (window.console && console.warn) {
|
|
console.warn('Compatibility test report:');
|
|
console.warn('Promise', hasPromise);
|
|
console.warn('WebSocket', hasWebSockets);
|
|
console.warn('WebCrypto', hasWebCrypto);
|
|
console.warn('Object.fromEntries', hasObjectFromEntries);
|
|
}
|
|
|
|
document.body.innerHTML = '<iframe src="./unsupported.html" width="100%" height="100%">';
|
|
}
|
|
|
|
compatTest();
|
|
</script>
|
|
</body>
|
|
|
|
</html>
|