-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathindex.html
More file actions
49 lines (46 loc) · 1.71 KB
/
Copy pathindex.html
File metadata and controls
49 lines (46 loc) · 1.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, initial-scale=1, maximum-scale=1">
<title>Mars App| Ethereum</title>
<script src="https://telegram.org/js/telegram-web-app.js"></script>
<link rel="stylesheet" href="/src/index.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Sixtyfour&display=swap" rel="stylesheet">
<script>
// Disable pull-down to refresh/minimize on mobile browsers
document.addEventListener('touchmove', function(event) {
const taskList = document.querySelector('.task-list');
if (taskList && taskList.contains(event.target)) {
// Allow scrolling inside task-list
return;
}
if (event.touches.length === 1) {
event.preventDefault();
}
}, { passive: false });
document.addEventListener('gesturestart', function(event) {
event.preventDefault();
});
// Telegram specific adjustment
if (window.Telegram && window.Telegram.WebApp) {
Telegram.WebApp.onEvent('viewportChanged', function() {
if (!Telegram.WebApp.isExpanded) {
Telegram.WebApp.expand();
}
});
// Ensure the app is expanded to the maximum height on load
Telegram.WebApp.ready();
if (!Telegram.WebApp.isExpanded) {
Telegram.WebApp.expand();
}
}
</script>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>