fix(web): style sidebar action tooltips (#6371)
Co-authored-by: t3-code[bot] <269035359+t3-code[bot]@users.noreply.github.com> Co-authored-by: Utkarsh Patil <[email protected]>
This commit is contained in:
1 parent
c9063f03ea
commit
196c8ea0d6
1 file changed
+51
-31
@@ -366,19 +366,26 @@ function SnoozePopoverButton(props: {
|
||||
);
|
||||
return (
|
||||
<Popover open={open} onOpenChange={onOpenChange}>
|
||||
<PopoverTrigger
|
||||
render={
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Snooze thread"
|
||||
onClick={(event) => event.stopPropagation()}
|
||||
onDoubleClick={(event) => event.stopPropagation()}
|
||||
className="inline-flex h-full cursor-pointer items-center gap-0.5 rounded-md bg-transparent px-1.5 text-xs text-muted-foreground hover:text-foreground"
|
||||
/>
|
||||
}
|
||||
>
|
||||
<ClockIcon className="size-3" />
|
||||
</PopoverTrigger>
|
||||
<Tooltip>
|
||||
<TooltipTrigger
|
||||
render={
|
||||
<PopoverTrigger
|
||||
render={
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Snooze thread"
|
||||
onClick={(event) => event.stopPropagation()}
|
||||
onDoubleClick={(event) => event.stopPropagation()}
|
||||
className="inline-flex h-full cursor-pointer items-center gap-0.5 rounded-md bg-transparent px-1.5 text-xs text-muted-foreground hover:text-foreground"
|
||||
/>
|
||||
}
|
||||
/>
|
||||
}
|
||||
>
|
||||
<ClockIcon className="size-3" />
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>Snooze thread</TooltipPopup>
|
||||
</Tooltip>
|
||||
<PopoverPopup side="bottom" align="end" className="w-56" viewportClassName="p-1">
|
||||
{presets.map((preset) => (
|
||||
<button
|
||||
@@ -1312,15 +1319,21 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: {
|
||||
)}
|
||||
{props.isPinned ? (
|
||||
props.pinningSupported ? (
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Unpin thread"
|
||||
title="Unpin thread"
|
||||
onClick={handleUnpinClick}
|
||||
className="inline-flex cursor-pointer items-center rounded-sm text-muted-foreground/65 outline-none transition-colors hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring"
|
||||
>
|
||||
<PinIcon aria-hidden className="size-3 shrink-0" />
|
||||
</button>
|
||||
<Tooltip>
|
||||
<TooltipTrigger
|
||||
render={
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Unpin thread"
|
||||
onClick={handleUnpinClick}
|
||||
className="inline-flex cursor-pointer items-center rounded-sm text-muted-foreground/65 outline-none transition-colors hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring"
|
||||
/>
|
||||
}
|
||||
>
|
||||
<PinIcon aria-hidden className="size-3 shrink-0" />
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>Unpin thread</TooltipPopup>
|
||||
</Tooltip>
|
||||
) : (
|
||||
<PinIcon
|
||||
aria-label="Pinned"
|
||||
@@ -1409,15 +1422,22 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: {
|
||||
/>
|
||||
) : null}
|
||||
{props.settlementSupported ? (
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Settle thread"
|
||||
onClick={handleSettleClick}
|
||||
className="-mr-1 inline-flex cursor-pointer items-center gap-1 rounded-md bg-transparent px-1.5 text-xs text-muted-foreground hover:text-foreground"
|
||||
>
|
||||
<CheckIcon className="size-3.5" />
|
||||
Settle
|
||||
</button>
|
||||
<Tooltip>
|
||||
<TooltipTrigger
|
||||
render={
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Settle thread"
|
||||
onClick={handleSettleClick}
|
||||
className="-mr-1 inline-flex cursor-pointer items-center gap-1 rounded-md bg-transparent px-1.5 text-xs text-muted-foreground hover:text-foreground"
|
||||
/>
|
||||
}
|
||||
>
|
||||
<CheckIcon className="size-3.5" />
|
||||
Settle
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>Settle thread</TooltipPopup>
|
||||
</Tooltip>
|
||||
) : null}
|
||||
</span>
|
||||
) : null}
|
||||
|
||||
Reference in new issue
Block a user