48 lines
2.4 KiB
HTML
48 lines
2.4 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />
|
|
<title>Changemaker Lite</title>
|
|
<!-- Default OG meta tags (overridden by nginx bot detection → /api/og/* for specific pages) -->
|
|
<meta property="og:title" content="Changemaker Lite" />
|
|
<meta property="og:description" content="Take action. Make a difference." />
|
|
<meta property="og:type" content="website" />
|
|
<meta name="twitter:card" content="summary" />
|
|
<meta name="twitter:title" content="Changemaker Lite" />
|
|
<meta name="twitter:description" content="Take action. Make a difference." />
|
|
</head>
|
|
<body style="margin:0;background:#1a1025">
|
|
<div id="root"></div>
|
|
<noscript>
|
|
<div style="display:flex;align-items:center;justify-content:center;height:100vh;color:#e0e0e0;font-family:sans-serif">
|
|
<p>JavaScript is required to run this application.</p>
|
|
</div>
|
|
</noscript>
|
|
<script>
|
|
// Fallback: if the main module fails to load entirely (stale deployment),
|
|
// show a reload prompt after a timeout. The main app replaces #root content on success.
|
|
setTimeout(function() {
|
|
var root = document.getElementById('root');
|
|
if (root && root.children.length === 0) {
|
|
var key = 'cm_chunk_reload';
|
|
var last = sessionStorage.getItem(key);
|
|
var now = Date.now();
|
|
if (!last || now - parseInt(last, 10) > 10000) {
|
|
sessionStorage.setItem(key, String(now));
|
|
window.location.reload();
|
|
} else {
|
|
root.innerHTML = '<div style="display:flex;flex-direction:column;align-items:center;justify-content:center;height:100vh;color:#e0e0e0;font-family:sans-serif;text-align:center;padding:0 24px">'
|
|
+ '<div style="font-size:48px;margin-bottom:16px">↻</div>'
|
|
+ '<h2 style="margin:0 0 8px;font-size:20px">Application Updated</h2>'
|
|
+ '<p style="margin:0 0 24px;color:#999;max-width:400px;line-height:1.5">A new version has been deployed. Please refresh to load the latest version.</p>'
|
|
+ '<button onclick="window.location.reload()" style="padding:10px 24px;font-size:14px;border:none;border-radius:6px;background:#9d4edd;color:#fff;cursor:pointer">Refresh Page</button>'
|
|
+ '</div>';
|
|
}
|
|
}
|
|
}, 5000);
|
|
</script>
|
|
<script type="module" src="/src/main.tsx"></script>
|
|
</body>
|
|
</html>
|