diff --git a/src/routes/events/[event_id]/(badges)/badges/ae_comp__badge_search.svelte b/src/routes/events/[event_id]/(badges)/badges/ae_comp__badge_search.svelte index 204328e3..5e977da6 100644 --- a/src/routes/events/[event_id]/(badges)/badges/ae_comp__badge_search.svelte +++ b/src/routes/events/[event_id]/(badges)/badges/ae_comp__badge_search.svelte @@ -12,7 +12,10 @@ import { LoaderCircle, QrCode, RemoveFormatting, - Search + Search, + + StepForward + } from '@lucide/svelte'; import { ae_loc, ae_api } from '$lib/stores/ae_stores'; import { events_sess } from '$lib/stores/ae_events_stores'; @@ -92,82 +95,115 @@ function handle_qr_scan_result(event: { handle_search_trigger(); })} autocomplete="off" - class="search_form bg-primary-50-950 border-primary-100-900 flex w-full max-w-7xl flex-col sm:flex-row flex-wrap items-center justify-center gap-2 rounded-lg px-2 py-2 shadow-md md:px-12"> + class="search_form bg-primary-50-950 border-primary-100-900 flex w-full max-w-4xl flex-col sm:flex-row flex-wrap items-center justify-center gap-2 rounded-lg px-2 py-2 shadow-lg md:px-12 outline">
+ class="flex grow flex-col xl:flex-row flex-wrap items-center justify-center gap-2"> {#if ($ae_loc.trusted_access && $ae_loc.edit_mode) || $ae_loc.manager_access} - - +
+ + - + - - + + + { + if ( + e.key === 'Enter' || + (badges_loc.current.qry_affiliations?.length ?? + 0) >= 3 + ) { + handle_search_trigger(); + } + }} + class="input input-sm max-w-fit px-1 text-xs" /> +
+ {/if} + +
+ + + + + { - if ( - e.key === 'Enter' || - (badges_loc.current.qry_affiliations?.length ?? - 0) >= 3 - ) { + if (e.key === 'Enter') { handle_search_trigger(); } }} - class="input input-sm max-w-fit px-1 text-xs" /> - {/if} + title="Search by name, email, etc. Press Enter." /> - { - if (e.key === 'Enter') { - handle_search_trigger(); - } - }} - title="Search by name, email, etc. Press Enter." /> +
{#if (badges_loc.current.fulltext_search_qry_str ?? '').trim().length < effective_min_chars} @@ -202,6 +238,8 @@ function handle_qr_scan_result(event: { badges_loc.current.qry_printed_status = 'all'; badges_loc.current.qry_affiliations = ''; handle_search_trigger(); + + document.getElementById('badge_fulltext_search_qry_str')?.focus(); }} class=" hover:text-tertiary-800-200 hover:bg-tertiary-200-800 active:bg-surface-200-700 flex items-center justify-center gap-1 px-3 py-2 text-sm font-bold transition-all duration-1000 hover:duration-300 min-w-0 preset-outlined-tertiary rounded-lg border border-tertiary-200-800