-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
209 lines (198 loc) · 7.09 KB
/
index.html
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />
<!-- Instagram Browser Handling -->
<script>
(function() {
// Initial setup with fallbacks
window.__TB = { ready: false };
var html = document.documentElement;
var ua = navigator.userAgent || '';
var isIOS = /iPad|iPhone|iPod/.test(ua);
var isInstagram = /Instagram/.test(ua) ||
(isIOS && (/FBAN/.test(ua) || /FBAV/.test(ua) || /FBIOS/.test(ua)));
// Set a placeholder for Instagram browser
if (isInstagram) {
// Create a basic UI that works without React
var style = document.createElement('style');
style.textContent = `
.ig-overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: #f8fafc;
z-index: 99998;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
text-align: center;
font-family: system-ui;
padding: 20px;
}
.ig-heading {
font-size: 20px;
text-align: center;
font-weight: 600;
margin-bottom: 4px;
color: #0f172a;
}
.ig-message {
max-width: 320px;
text-align: left;
margin-bottom: 24px;
font-size: 16px;
line-height: 1.5;
color: #0f172a;
}
.ig-steps {
max-width: 280px;
text-align: left;
color: #475569;
font-size: 15px;
line-height: 1.6;
}
.ig-step {
display: flex;
gap: 12px;
margin-bottom: 12px;
}
.ig-step-number {
color: #0EA5E9;
font-weight: 600;
font-size: 14px;
padding-top: 2px;
}
`;
document.head.appendChild(style);
var div = document.createElement('div');
div.className = 'ig-overlay';
div.innerHTML = `
<div class="ig-message">
<div class="ig-heading">TouchBase cannot run in Instagram's browser</div>
<br><br>
Please follow the steps below to open in your phone's browser:
</div>
<div class="ig-steps">
<div class="ig-step">
<div class="ig-step-number">1.</div>
<div>Look for the ${isIOS ? "⋯" : "⋮"} menu button in the top right corner</div>
</div>
<div class="ig-step">
<div class="ig-step-number">2.</div>
<div>Tap '${isIOS ? "Open in external browser" : "Open in browser"}'</div>
</div>
</div>
`;
// Add banner when DOM is ready
document.addEventListener('DOMContentLoaded', function() {
document.body.appendChild(div);
});
// Store detection results
html.setAttribute('data-ig-browser', 'true');
html.setAttribute('data-ig-platform', isIOS ? 'ios' : 'android');
}
// Handle app initialization
window.__TB.ready = true;
})();
</script>
<meta name="theme-color" content="#0EA5E9" />
<meta name="description" content="TouchBase — Stay connected with the people who matter most." />
<!-- PWA -->
<link rel="manifest" href="/manifest.json" />
<link rel="apple-touch-icon" href="/icon-192.png" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="default" />
<meta name="apple-mobile-web-app-title" content="TouchBase" />
<!-- Open Graph -->
<meta property="og:type" content="website" />
<meta property="og:title" content="TouchBase" />
<meta property="og:description" content="Stay connected with the people who matter most." />
<meta property="og:image" content="/og.png" />
<!-- Twitter -->
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="TouchBase" />
<meta name="twitter:description" content="Stay connected with the people who matter most." />
<meta name="twitter:image" content="/og.png" />
<!-- Schema.org markup -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@graph": [
{
"@type": "WebApplication",
"@id": "https://touchbase.site/#webapp",
"name": "TouchBase",
"url": "https://touchbase.site",
"applicationCategory": "LifestyleApplication",
"browserRequirements": "Requires JavaScript. Requires HTML5.",
"description": "Stay connected with the people who matter most. TouchBase helps you nurture meaningful relationships with gentle reminders and personalised suggestions.",
"offers": {
"@type": "Offer",
"price": "5",
"priceCurrency": "USD",
"availability": "https://schema.org/InStock"
},
"featureList": [
"Contact Management",
"Interaction Tracking",
"Smart Reminders",
"Relationship Analytics",
"Personalised Suggestions",
"Conversation Prompt Generator",
"Cross-platform Support"
],
"operatingSystem": "Any",
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "4.8",
"ratingCount": "100"
}
},
{
"@type": "SoftwareApplication",
"name": "TouchBase",
"applicationCategory": "LifestyleApplication",
"operatingSystem": "Any",
"offers": {
"@type": "Offer",
"price": "5",
"priceCurrency": "USD"
},
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "4.8",
"ratingCount": "100"
}
},
{
"@type": "Organization",
"@id": "https://touchbase.site/#organization",
"name": "TouchBase",
"url": "https://touchbase.site",
"logo": {
"@type": "ImageObject",
"url": "https://touchbase.site/icon-512.png",
"width": "512",
"height": "512"
},
"sameAs": [
"mailto:[email protected]"
]
}
]
}
</script>
<title>TouchBase</title>
</head>
<body class="bg-gray-50">
<div id="root"></div>
<script type="module" src="/src/index.tsx"></script>
</body>
</html>