From 6ed1893bedcc7d4094573809eb3114039d8c7cfc Mon Sep 17 00:00:00 2001 From: Hayden <64056131+hay-kot@users.noreply.github.com> Date: Fri, 6 Oct 2023 16:32:49 -0500 Subject: [PATCH] feat: make selectables clearable (#572) Former-commit-id: db16d3fb23cf824e04c840d877861801d80297bf --- frontend/components/Form/Autocomplete2.vue | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/frontend/components/Form/Autocomplete2.vue b/frontend/components/Form/Autocomplete2.vue index b71c30e..9b20758 100644 --- a/frontend/components/Form/Autocomplete2.vue +++ b/frontend/components/Form/Autocomplete2.vue @@ -10,6 +10,14 @@ class="w-full input input-bordered" @change="search = $event.target.value" /> + @@ -86,6 +94,10 @@ multiple: false, }); + function clear() { + emit("update:modelValue", null); + } + const search = ref(""); const value = useVModel(props, "modelValue", emit);