This commit is contained in:
grngxd 2024-12-25 22:53:59 +00:00
parent c8491e3074
commit 552c412c17
2 changed files with 27 additions and 26 deletions

View file

@ -2,7 +2,7 @@ import prologue, prologue/middlewares/staticfile, prologue/middlewares/cors, std
const key_len = 128
const refer_len = 16
const debug = false
const debug = true
let db = open("real.db", "", "", "")

View file

@ -49,6 +49,7 @@ export const Home = () => {
return (
<div class="flex flex-col gap-6 w-full h-full justify-center items-center">
<h1 class="text-6xl font-bold animate-pulse">???</h1>
<p>time left here</p>
<div class="flex flex-col justify-center items-center gap-4">
<span>
<p class="opacity-100 hover:opacity-75 transition-opacity">
@ -74,32 +75,32 @@ export const Home = () => {
</div>
</span>
<div>
{
!entryBody.err && (
<>
<h2>Key: {entryBody?.key}</h2>
<h2>Referral: {entryBody?.referral}</h2>
</>
)
}
</div>
{
!entryBody.err ? (
<div class="flex flex-col gap-1.5 mt-3 justify-center items-center">
<p class="text-green-700">tip: click to copy.</p>
<h2 onClick={() => navigator.clipboard.writeText(entryBody?.key)}>Key: <code class="cursor-pointer bg-green-800 hover:bg-green-900 active:bg-green-700 transition-colors py-1 px-2 rounded-lg text-white">{entryBody?.key}</code></h2>
<h2 onClick={() => navigator.clipboard.writeText(entryBody?.referral)}>Referral: <code class="cursor-pointer bg-green-800 hover:bg-green-900 active:bg-green-700 transition-colors py-1 px-2 rounded-lg text-white">{entryBody?.referral}</code></h2>
<p class="text-green-700">good luck. keep note of these, if you lose them, you can't reroll.</p>
</div>
) : (
<div class="w-2/3 text-center flex flex-col gap-2">
<div>
<b>What is this?</b>
<p>At exactly 00:00 CET on 1 Jan, the system will choose a random entry. Their referral key shall be publically
displayed on this page. The person associated to this referral key shall contact us with their private key.
They shall win a little prize. To have one's entry weigh more than the rest, one shall have to spread their
referral key amongst the people. Every referral shall increase their chance of getting selected.
</p>
</div>
<div class="w-2/3 text-center flex flex-col gap-2">
<div>
<b>What is this?</b>
<p>At exactly 00:00 CET on 1 Jan, the system will choose a random entry. Their referral key shall be publically
displayed on this page. The person associated to this referral key shall contact us with their private key.
They shall win a little prize. To have one's entry weigh more than the rest, one shall have to spread their
referral key amongst the people. Every referral shall increase their chance of getting selected.
</p>
</div>
<div>
<b>How does one enter?</b>
<p>One needs a referral key to enter.</p>
</div>
</div>
<div>
<b>How does one enter?</b>
<p>One needs a referral key to enter.</p>
</div>
</div>
)
}
</div>
</div>
)