Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion claim-db-worker/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,15 @@ export default {
blobs: ['database_claimed'],
indexes: ['claim_db'],
});
await sendPosthogEvent('create_db:claim_successful', {
'project-id': projectID,
});
return new Response(getClaimSuccessHtml(projectID), {
headers: { 'Content-Type': 'text/html' },
});
} else {
const responseText = await transferResponse.text();
await sendPosthogEvent('create_db:claim_successful', {
await sendPosthogEvent('create_db:claim_failed', {
'project-id': projectID,
status: transferResponse.status,
error: responseText,
Expand Down
10 changes: 7 additions & 3 deletions claim-db-worker/src/templates/claim-success-template.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { footer } from "./footer-template";
import { navbar } from "./navbar-template";
import { footer } from './footer-template';
import { navbar } from './navbar-template';

export function getClaimSuccessHtml(projectID: string) {
return `
Expand All @@ -16,7 +16,11 @@ export function getClaimSuccessHtml(projectID: string) {
margin: 0;
padding: 0;
min-height: 100vh;
background: url('/hero-background.svg') no-repeat center center, linear-gradient(180deg, #090A15 0%, rgba(9, 10, 21, 0.5) 19.02%, rgba(9, 10, 21, 0.5) 74%, rgba(9, 10, 21, 0.95) 100%);
backdrop-filter: blur(12px);
background: radial-gradient(circle at 30% 30%, rgba(0, 128, 128, 0.2), transparent 50%),
radial-gradient(circle at 70% 70%, rgba(0, 128, 128, 0.2), transparent 50%),
#050d0f;
background-size: cover;
background-size: cover;
color: #fff;
font-family: 'Barlow', system-ui, sans-serif;
Expand Down
6 changes: 5 additions & 1 deletion claim-db-worker/src/templates/claim-template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ export function getClaimHtml(projectID: string, authUrl: string) {
@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;700&display=swap');
body {
font-family: 'Barlow', system-ui, sans-serif;
background: url('/hero-background.svg') no-repeat center center fixed;
backdrop-filter: blur(12px);
background: radial-gradient(circle at 30% 30%, rgba(0, 128, 128, 0.2), transparent 50%),
radial-gradient(circle at 70% 70%, rgba(0, 128, 128, 0.2), transparent 50%),
#050d0f;
background-size: cover;
background-size: cover;
margin: 0;
padding: 0;
Expand Down
7 changes: 5 additions & 2 deletions claim-db-worker/src/templates/error-template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@ export function getErrorHtml(title: string, message: string, details?: string) {
body {
margin: 0;
padding: 0;
background: url('/hero-background.svg') no-repeat center center fixed;
background-size: cover;
backdrop-filter: blur(12px);
background: radial-gradient(circle at 30% 30%, rgba(0, 128, 128, 0.2), transparent 50%),
radial-gradient(circle at 70% 70%, rgba(0, 128, 128, 0.2), transparent 50%),
#050d0f;
background-size: cover;
color: #fff;
font-family: 'Barlow', system-ui, sans-serif;
display: flex;
Expand Down
6 changes: 5 additions & 1 deletion claim-db-worker/src/templates/homepage-template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@ export function getHomepageHtml() {
box-sizing: border-box;
}
body {
background: url('/hero-background.svg') no-repeat center center, linear-gradient(180deg, #090A15 0%, rgba(9, 10, 21, 0.5) 19.02%, rgba(9, 10, 21, 0.5) 74%, rgba(9, 10, 21, 0.95) 100%);
backdrop-filter: blur(12px);
background: radial-gradient(circle at 30% 30%, rgba(0, 128, 128, 0.2), transparent 50%),
radial-gradient(circle at 70% 70%, rgba(0, 128, 128, 0.2), transparent 50%),
#050d0f;
background-size: cover;
background-size: cover;
font-family: 'Barlow', system-ui, sans-serif;
color: #e2e8f0;
Expand Down