This commit is contained in:
Andrea
2026-03-20 17:01:20 +01:00
parent 0a501a97c4
commit d5a2e490f0

View File

@@ -10,13 +10,14 @@
</script> </script>
<svelte:window <svelte:window
onclick={() => {
}}
onkeydown={(e) => { onkeydown={(e) => {
if (e.key === "n" && e.metaKey) { if (e.key === "n" && e.metaKey) {
expanded = true; expanded = true;
return;
}
if( e.key === "Escape") {
expanded = false;
return;
} }
}} }}
/> />
@@ -24,5 +25,7 @@
{#if !expanded} {#if !expanded}
<div>Scrivi una nota...</div> <div>Scrivi una nota...</div>
{:else} {:else}
<NoteEditor note={undefined} onSubmit={onCreate} /> <div class="note-editor-container">
<NoteEditor note={undefined} onSubmit={onCreate} />
</div>
{/if} {/if}