minor improvements

This commit is contained in:
daniel31x13
2024-02-07 09:48:40 -05:00
parent 2d0093172a
commit daed2d82f4
2 changed files with 37 additions and 38 deletions
@@ -67,8 +67,9 @@ export default function LinkActions({
return (
<>
<div
className={`dropdown dropdown-left dropdown-end absolute ${position || "top-3 right-3"
} z-20`}
className={`dropdown dropdown-left dropdown-end absolute ${
position || "top-3 right-3"
} z-20`}
>
<div
tabIndex={0}
@@ -79,22 +80,20 @@ export default function LinkActions({
<i title="More" className="bi-three-dots text-xl" />
</div>
<ul className="dropdown-content z-[20] menu shadow bg-base-200 border border-neutral-content rounded-box w-44 mr-1 translate-y-10">
{permissions ? (
<li>
<div
role="button"
tabIndex={0}
onClick={() => {
(document?.activeElement as HTMLElement)?.blur();
pinLink();
}}
>
{link?.pinnedBy && link.pinnedBy[0]
? "Unpin"
: "Pin to Dashboard"}
</div>
</li>
) : undefined}
<li>
<div
role="button"
tabIndex={0}
onClick={() => {
(document?.activeElement as HTMLElement)?.blur();
pinLink();
}}
>
{link?.pinnedBy && link.pinnedBy[0]
? "Unpin"
: "Pin to Dashboard"}
</div>
</li>
{linkInfo !== undefined && toggleShowInfo ? (
<li>
<div