Skip to content

Commit

Permalink
feat(Select): fixed collision issues
Browse files Browse the repository at this point in the history
  • Loading branch information
N00nDay committed May 11, 2023
1 parent 28a38e7 commit 45f183e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/lib/components/select/Options.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { scale } from 'svelte/transition';
import { twMerge } from 'tailwind-merge';
import { get_current_component, onMount, getContext } from 'svelte/internal';
import { forwardEventsBuilder, useActions, type ActionArray } from '../../actions';
import { floatingUI, forwardEventsBuilder, useActions, type ActionArray } from '../../actions';
export let use: ActionArray = [];
import { exclude } from '../../utils/exclude';
const forwardEvents = forwardEventsBuilder(get_current_component());
Expand Down Expand Up @@ -31,7 +31,7 @@
}
const defaultClass =
'origin-top-right absolute z-10 border border-border left-0 right-0 w-full mt-1 p-1 rounded-md shadow-xl py-1 bg-surface';
'origin-top-right absolute z-10 border border-border left-0 right-0 w-full p-1 rounded-md shadow-xl py-1 bg-surface';
$: finalClass = twMerge(defaultClass, $$props.class);
onMount(() => {
Expand All @@ -49,6 +49,7 @@
out:scale={{ start: 0.95, duration: 75 }}
use:useActions={use}
use:forwardEvents
use:floatingUI={{ placement: 'bottom-start', offset: 8 }}
{...exclude($$props, ['use', 'class'])}
role="listbox"
>
Expand Down

0 comments on commit 45f183e

Please sign in to comment.