refactoring branch, tatort page-svelte, Datenaktualisierung durch api, page.ts, choose better names
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
onDelete = () => {}
|
||||
} = $props();
|
||||
|
||||
let names = list.map((l: ListItem) => l.name);
|
||||
let localName = $state(currentName);
|
||||
let wasCancelled = $state(false);
|
||||
|
||||
@@ -46,6 +45,8 @@
|
||||
function commitIfValid() {
|
||||
if (!error && !wasCancelled && localName != currentName) {
|
||||
editedName = localName.trim();
|
||||
inputRef?.blur();
|
||||
isEditing = false;
|
||||
onSave(editedName, currentName);
|
||||
} else {
|
||||
localName = currentName;
|
||||
|
||||
Reference in New Issue
Block a user