Skip to content

Commit

Permalink
can add new name after error
Browse files Browse the repository at this point in the history
  • Loading branch information
lovincyrus committed Dec 10, 2024
1 parent 8adc63a commit d588375
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import Input from "@rilldata/web-common/components/forms/Input.svelte";
import { getCurrentEnvironment, isDuplicateKey } from "./utils";
import { onMount } from "svelte";
import { debounce } from "lodash";
export let open = false;
export let id: string;
Expand Down Expand Up @@ -261,6 +262,14 @@
$: if (open) {
handleDialogOpen();
}
const debouncedCheckForExistingKeys = debounce(() => {
checkForExistingKeys();
}, 500);
$: if ($form.key) {
debouncedCheckForExistingKeys();
}
</script>

<Dialog
Expand Down

0 comments on commit d588375

Please sign in to comment.