mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-29 19:35:20 +02:00
feat(web): enhance inline mention editor and thread components with suggestion trigger info and anchor rect
This commit is contained in:
parent
0d65a2e4e3
commit
d445974838
3 changed files with 162 additions and 39 deletions
|
|
@ -10,7 +10,8 @@ import { cn } from "@/lib/utils";
|
|||
function ComposerSuggestionPopoverContent({
|
||||
className,
|
||||
align = "start",
|
||||
sideOffset = 8,
|
||||
sideOffset = 6,
|
||||
collisionPadding = 12,
|
||||
onOpenAutoFocus,
|
||||
onCloseAutoFocus,
|
||||
...props
|
||||
|
|
@ -19,6 +20,7 @@ function ComposerSuggestionPopoverContent({
|
|||
<PopoverContent
|
||||
align={align}
|
||||
sideOffset={sideOffset}
|
||||
collisionPadding={collisionPadding}
|
||||
onOpenAutoFocus={(event) => {
|
||||
event.preventDefault();
|
||||
onOpenAutoFocus?.(event);
|
||||
|
|
@ -28,7 +30,7 @@ function ComposerSuggestionPopoverContent({
|
|||
onCloseAutoFocus?.(event);
|
||||
}}
|
||||
className={cn(
|
||||
"w-[280px] overflow-hidden rounded-xl border border-popover-border bg-popover p-0 text-popover-foreground shadow-2xl sm:w-[320px]",
|
||||
"w-[280px] overflow-hidden rounded-md border border-popover-border bg-popover p-0 text-popover-foreground shadow-md sm:w-[320px]",
|
||||
className
|
||||
)}
|
||||
{...props}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue