add password to frontend

This commit is contained in:
2023-05-23 09:39:19 +02:00
parent 6da28a701e
commit fdc2722fb9
8 changed files with 124 additions and 70 deletions

View File

@@ -1,7 +1,7 @@
<script lang="ts" context="module">
export type NoteResult = {
password: string
id: string
password?: string
}
</script>
@@ -14,7 +14,8 @@
export let result: NoteResult
$: url = `${window.location.origin}/note/${result.id}#${result.password}`
let url = `${window.location.origin}/note/${result.id}`
if (result.password) url += `#${result.password}`
function reset() {
window.location.reload()