diff --git a/.github/workflows/dev-build.yaml b/.github/workflows/dev-build.yaml index b2d21bf0..143f229e 100644 --- a/.github/workflows/dev-build.yaml +++ b/.github/workflows/dev-build.yaml @@ -6,7 +6,7 @@ concurrency: on: push: - branches: ['agentic-streaming'] # put your current branch to create a build. Core team only. + branches: ['4499-tooltips'] # put your current branch to create a build. Core team only. paths-ignore: - '**.md' - 'cloud-deployments/*' diff --git a/frontend/src/components/Sidebar/ActiveWorkspaces/ThreadContainer/ThreadItem/index.jsx b/frontend/src/components/Sidebar/ActiveWorkspaces/ThreadContainer/ThreadItem/index.jsx index c25e4a61..be9b6762 100644 --- a/frontend/src/components/Sidebar/ActiveWorkspaces/ThreadContainer/ThreadItem/index.jsx +++ b/frontend/src/components/Sidebar/ActiveWorkspaces/ThreadContainer/ThreadItem/index.jsx @@ -91,6 +91,8 @@ export default function ThreadItem({ href={ window.location.pathname === linkTo || ctrlPressed ? "#" : linkTo } + data-tooltip-id="workspace-thread-name" + data-tooltip-content={thread.name} className="w-full pl-2 py-1 overflow-hidden" aria-current={isActive ? "page" : ""} > diff --git a/frontend/src/components/Sidebar/ActiveWorkspaces/index.jsx b/frontend/src/components/Sidebar/ActiveWorkspaces/index.jsx index 545bd6c4..47a39530 100644 --- a/frontend/src/components/Sidebar/ActiveWorkspaces/index.jsx +++ b/frontend/src/components/Sidebar/ActiveWorkspaces/index.jsx @@ -106,6 +106,8 @@ export default function ActiveWorkspaces() { ? null : paths.workspace.chat(workspace.slug) } + data-tooltip-id="workspace-name" + data-tooltip-content={workspace.name} aria-current={isActive ? "page" : ""} className={` transition-all duration-[200ms] diff --git a/frontend/src/components/Sidebar/index.jsx b/frontend/src/components/Sidebar/index.jsx index 1ffe870d..34a2e443 100644 --- a/frontend/src/components/Sidebar/index.jsx +++ b/frontend/src/components/Sidebar/index.jsx @@ -13,6 +13,8 @@ import paths from "@/utils/paths"; import { useTranslation } from "react-i18next"; import { useSidebarToggle, ToggleSidebarButton } from "./SidebarToggle"; import SearchBox from "./SearchBox"; +import { Tooltip } from "react-tooltip"; +import { createPortal } from "react-dom"; export default function Sidebar() { const { user } = useUser(); @@ -24,7 +26,6 @@ export default function Sidebar() { showModal: showNewWsModal, hideModal: hideNewWsModal, } = useNewWorkspaceModal(); - const { t } = useTranslation(); return ( <> @@ -72,6 +73,7 @@ export default function Sidebar() { {showingNewWsModal && } + ); } @@ -87,7 +89,6 @@ export function SidebarMobileHeader() { hideModal: hideNewWsModal, } = useNewWorkspaceModal(); const { user } = useUser(); - const { t } = useTranslation(); useEffect(() => { // Darkens the rest of the screen @@ -203,3 +204,23 @@ function NewWorkspaceButton({ user, showNewWsModal }) { ); } + +function WorkspaceAndThreadTooltips() { + return createPortal( + + + + , + document.body + ); +}