Skip to content

Commit

Permalink
cancel name edits when the input loses focus (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
ashlsun authored Jun 23, 2024
1 parent ed3ab42 commit 796a2cd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/routes/Item.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,10 @@
itemNameInput.blur();
}
}}
on:blur={() => {
draftName = item.name;
editingName = false;
}}
>
<div class="flex justify-between">
<span>
Expand Down

0 comments on commit 796a2cd

Please sign in to comment.