diff --git a/src/lib/utils.ts b/src/lib/utils.ts index a0841b2..e9f09f2 100644 --- a/src/lib/utils.ts +++ b/src/lib/utils.ts @@ -14,7 +14,7 @@ export function get_price(dl: number): number { } else if (dl === 9) { return 420; } else if (dl > 9) { - return 1;//190; + return 190; } else { return 99999; //currently <4 length domains not buyable, but just in case... } diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte index 860201c..8d57e5d 100644 --- a/src/routes/+page.svelte +++ b/src/routes/+page.svelte @@ -92,15 +92,34 @@
+

Buy a .ban Domain

- .ban + .ban
{price} {error}

Supported by:

- Bananostand + Bananostand +
+ Creeper +
+ Kuyumucu (banano.trade) +
+ Banano Sports Pools +
+ Gorilla Nation +
+ Monke42.link +
+ BanXNO Faucet +
+ faucet.prussia.dev +
+ Banfts (search) +
+ And more in the near future!

.ban is the first publicly available top level domain (TLD) for the Banano Name Service protocol (BNS)

@@ -150,6 +169,9 @@ hr { margin: 1px 0; + border-style: solid; + border-color: var(--grey1); + width: 100%; } .thickest { @@ -193,14 +215,14 @@ #input-container input[type="text"] { padding-left: 3px; - width: calc(65% - 3px); + width: calc(63% - 3px); border-top-left-radius: 10px; border-bottom-left-radius: 10px; } #input-container span { display: inline-block; - width: 10%; + width: 12%; text-align: center; } @@ -218,4 +240,23 @@ width: 16px; margin-top: 2px; } + + #mobile-title { + display: none; + } + + @media only screen and (max-width: 900px) { + #pitch { + display: none; + } + + #front { + grid-template-columns: 100vw; + } + + #mobile-title { + display: block; + margin-bottom: 19px; + } + } diff --git a/src/routes/api/start_payment/+server.ts b/src/routes/api/start_payment/+server.ts index 32bdee3..2d422e5 100644 --- a/src/routes/api/start_payment/+server.ts +++ b/src/routes/api/start_payment/+server.ts @@ -11,8 +11,8 @@ export const POST: RequestHandler = async ({ request }) => { const { domain, send_to_pub_key } = await request.json(); if (!domain || !send_to_pub_key) { return error(400, "Missing one or more of the required fields `domain` and `send_to_pub_key`"); - } else if (!is_domain_name_allowed(domain) || domain.length < 4) { - return error(400, "Domain name has disallowed characters or is shorter than 4 characters"); + } else if (!is_domain_name_allowed(domain) || domain.length < 4 || domain.length > 32) { + return error(400, "Domain name has disallowed characters, is shorter than 4 characters, or is longer than 32 characters"); } else if (!is_valid_public_key(send_to_pub_key)) { return error(400, "`send_to_pub_key` is invalid"); } diff --git a/static/global.css b/static/global.css index a84eb2b..3de87b7 100644 --- a/static/global.css +++ b/static/global.css @@ -38,3 +38,7 @@ background-color: #eacf1e; } +code { + word-wrap: break-word; +} +