Skip to content

Commit

Permalink
chore: add tooltip to buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
boojack committed May 9, 2024
1 parent ad65c66 commit a79b1e8
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions frontend/web/src/components/CollectionView.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { Tooltip } from "@mui/joy";
import classNames from "classnames";
import copy from "copy-to-clipboard";
import { useState } from "react";
Expand Down Expand Up @@ -75,12 +76,19 @@ const CollectionView = (props: Props) => {
<p className="text-sm text-gray-500">{collection.description}</p>
</div>
<div className="flex flex-row justify-end items-center shrink-0 gap-2">
<Link className="w-full text-gray-400 cursor-pointer hover:text-gray-500" to={`/c/${collection.name}`} target="_blank">
<Icon.Share className="w-4 h-auto" />
</Link>
<button className="w-full text-gray-400 cursor-pointer hover:text-gray-500" onClick={() => handleOpenAllShortcutsButtonClick()}>
<Icon.ArrowUpRight className="w-4 h-auto" />
</button>
<Tooltip title="Share" placement="top" arrow>
<Link className="w-auto text-gray-400 cursor-pointer hover:text-gray-500" to={`/c/${collection.name}`} target="_blank">
<Icon.Share className="w-4 h-auto" />
</Link>
</Tooltip>
<Tooltip title="Open all" placement="top" arrow>
<button
className="w-auto text-gray-400 cursor-pointer hover:text-gray-500"
onClick={() => handleOpenAllShortcutsButtonClick()}
>
<Icon.ArrowUpRight className="w-5 h-auto" />
</button>
</Tooltip>
{showAdminActions && (
<Dropdown
trigger={
Expand Down

0 comments on commit a79b1e8

Please sign in to comment.