mirror of
https://git.verdigado.com/NB-Public/simple-wkd.git
synced 2024-10-30 03:05:51 +01:00
Improve webpage
This commit is contained in:
parent
625d9302d0
commit
5919c55808
6 changed files with 32 additions and 6 deletions
9
src/components/cursor-catcher.astro
Normal file
9
src/components/cursor-catcher.astro
Normal file
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
export interface Props {
|
||||
id: string;
|
||||
}
|
||||
|
||||
const { id } = Astro.props;
|
||||
---
|
||||
|
||||
<div class="absolute hidden h-full w-full cursor-wait" id={id}></div>
|
|
@ -15,7 +15,10 @@ const { title } = Astro.props;
|
|||
<meta name="generator" content={Astro.generator} />
|
||||
<title>{title}</title>
|
||||
</head>
|
||||
<body class="h-full font-mono dark:bg-neutral-800 dark:text-neutral-300">
|
||||
<body
|
||||
class="h-full font-mono dark:bg-neutral-800 dark:text-neutral-300"
|
||||
id="body"
|
||||
>
|
||||
<slot />
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -1,15 +1,19 @@
|
|||
---
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import CenterXy from "../components/center-xy.astro";
|
||||
import CursorCatcher from "../components/cursor-catcher.astro";
|
||||
|
||||
import "../styles/global.css";
|
||||
---
|
||||
|
||||
<Layout title="Delete a key">
|
||||
<CursorCatcher id="cursor-catcher" />
|
||||
<CenterXy>
|
||||
<form
|
||||
action="((%u))api/delete"
|
||||
method="get"
|
||||
class="flex max-w-full flex-col"
|
||||
onsubmit="document.getElementById('submit-button').classList.add('cursor-wait'); document.getElementById('cursor-catcher').classList.remove('hidden')"
|
||||
>
|
||||
<label for="email" class="mt-3 text-xl font-bold"
|
||||
>Request key deletion:</label
|
||||
|
@ -23,7 +27,9 @@ import "../styles/global.css";
|
|||
class="input mt-3 focus:rounded-lg"
|
||||
required
|
||||
/>
|
||||
<button type="submit" class="button mt-4 self-end">Delete</button>
|
||||
<button type="submit" id="submit-button" class="button mt-4 self-end"
|
||||
>Delete</button
|
||||
>
|
||||
</form>
|
||||
</CenterXy>
|
||||
</Layout>
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
---
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import "../styles/global.css";
|
||||
import CenterXy from "../components/center-xy.astro";
|
||||
|
||||
import "../styles/global.css";
|
||||
---
|
||||
|
||||
<Layout title="Manage keys">
|
||||
|
|
|
@ -3,7 +3,7 @@ import Layout from "../layouts/Layout.astro";
|
|||
import CenterXy from "../components/center-xy.astro";
|
||||
---
|
||||
|
||||
<Layout title="Success!">
|
||||
<Layout title="((%s))">
|
||||
<CenterXy>
|
||||
<h1 class="text-4xl font-bold">((%m))</h1>
|
||||
</CenterXy>
|
|
@ -1,15 +1,19 @@
|
|||
---
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import "../styles/global.css";
|
||||
import CenterXy from "../components/center-xy.astro";
|
||||
import CursorCatcher from "../components/cursor-catcher.astro";
|
||||
|
||||
import "../styles/global.css";
|
||||
---
|
||||
|
||||
<Layout title="Submit a key">
|
||||
<CursorCatcher id="cursor-catcher" />
|
||||
<CenterXy>
|
||||
<form
|
||||
action="((%u))api/submit"
|
||||
method="post"
|
||||
class="flex max-w-full flex-col"
|
||||
onsubmit="document.getElementById('submit-button').classList.add('cursor-wait'); document.getElementById('cursor-catcher').classList.remove('hidden')"
|
||||
>
|
||||
<label for="key" class="text-xl font-bold"
|
||||
>Paste your pgp keyblock here:</label
|
||||
|
@ -21,8 +25,11 @@ import CenterXy from "../components/center-xy.astro";
|
|||
rows="20"
|
||||
class="input mt-3 resize-none"
|
||||
placeholder="-----BEGIN PGP PUBLIC KEY BLOCK-----"
|
||||
spellcheck="false"
|
||||
required></textarea>
|
||||
<button type="submit" class="button mt-6 self-end">Submit</button>
|
||||
<button type="submit" id="submit-button" class="button mt-6 self-end"
|
||||
>Submit</button
|
||||
>
|
||||
</form>
|
||||
</CenterXy>
|
||||
</Layout>
|
||||
|
|
Loading…
Reference in a new issue