GuaccO's picture
Please allow to Send attachment files like: javascript, typescript, SQL etc.
e0b6e4d verified
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>GitHub Auth Callback</title>
<script src="../components/file-uploader.js"></script>
<script>
// Process the GitHub callback
const urlParams = new URLSearchParams(window.location.search);
const code = urlParams.get('code');
const error = urlParams.get('error');
if (code) {
// Store the code temporarily (will be exchanged for token in main script)
localStorage.setItem('githubCode', code);
window.location.href = '/';
} else if (error) {
alert('GitHub authentication failed: ' + error + ' - ' + urlParams.get('error_description'));
window.location.href = '/';
}
</script>
</head>
<body>
<div class="flex items-center justify-center h-screen">
<div class="text-center">
<h1 class="text-2xl font-bold mb-4">Processing GitHub Authentication...</h1>
<div class="animate-spin rounded-full h-12 w-12 border-t-2 border-b-2 border-primary mx-auto"></div>
<!-- File Upload Section -->
<div class="mt-8 p-6 max-w-md mx-auto bg-white rounded-lg shadow-md">
<h2 class="text-xl font-semibold mb-4">Upload Files</h2>
<file-uploader></file-uploader>
<button id="upload-submit" class="mt-4 px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700">
Upload Files
</button>
</div>
</div>
</div>
</body>
</html>