1
0
Fork 0
mirror of synced 2024-10-04 03:54:37 +13:00

fix issue with user searching

This commit is contained in:
Peter Clement 2023-03-02 14:30:04 +00:00
parent 2bc0e988af
commit aa02c0ca30
4 changed files with 8 additions and 2 deletions

View file

@ -15,6 +15,7 @@
export let sort = false
export let autoWidth = false
export let fetchTerm = null
export let useFetch = false
export let customPopoverHeight
const dispatch = createEventDispatcher()
@ -86,6 +87,7 @@
isPlaceholder={!value?.length}
{autocomplete}
bind:fetchTerm
{useFetch}
{isOptionSelected}
{getOptionLabel}
{getOptionValue}

View file

@ -33,6 +33,7 @@
export let autocomplete = false
export let sort = false
export let fetchTerm = null
export let useFetch = false
export let customPopoverHeight
export let align = "left"
export let footer = null
@ -150,9 +151,9 @@
>
{#if autocomplete}
<Search
value={fetchTerm ? fetchTerm : searchTerm}
value={useFetch ? fetchTerm : searchTerm}
on:change={event =>
fetchTerm ? (fetchTerm = event.detail) : (searchTerm = event.detail)}
useFetch ? (fetchTerm = event.detail) : (searchTerm = event.detail)}
{disabled}
placeholder="Search"
/>

View file

@ -17,6 +17,7 @@
export let autoWidth = false
export let autocomplete = false
export let fetchTerm = null
export let useFetch = false
export let customPopoverHeight
const dispatch = createEventDispatcher()
@ -41,6 +42,7 @@
{autocomplete}
{customPopoverHeight}
bind:fetchTerm
{useFetch}
on:change={onChange}
on:click
/>

View file

@ -257,6 +257,7 @@
<div class="select">
<Multiselect
bind:fetchTerm={userSearchTerm}
useFetch
placeholder="All users"
label="Users"
autocomplete