Fix tippy falling off the page

This commit is contained in:
Jon Staab
2026-01-29 10:56:44 -08:00
parent 16cd90f7b7
commit e74f922e8d
3 changed files with 9 additions and 3 deletions
+6
View File
@@ -362,6 +362,12 @@
@apply !h-full !w-full !rounded-lg !border-none !bg-inherit !px-4 !text-inherit;
}
/* tippy popover */
.tippy-box {
@apply shadow-xl;
}
/* emoji picker */
emoji-picker {
@@ -18,6 +18,6 @@
})
</script>
<EmojiButton {onEmoji} class="btn join-item btn-xs">
<EmojiButton {onEmoji} class="btn join-item btn-xs" tippyParams={{placement: "bottom-end"}}>
<Icon icon={SmileCircle} size={4} />
</EmojiButton>
+2 -2
View File
@@ -6,7 +6,7 @@
import Tippy from "@lib/components/Tippy.svelte"
import EmojiPicker from "@lib/components/EmojiPicker.svelte"
const {...props} = $props()
const {tippyParams = {}, ...props} = $props()
const open = () => popover?.show()
@@ -34,7 +34,7 @@
bind:popover
component={EmojiPicker}
props={{onClick}}
params={{trigger: "manual", interactive: true}}>
params={{trigger: "manual", interactive: true, ...tippyParams}}>
<Button onclick={open} class={props.class}>
{@render props.children?.()}
</Button>