Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions components/brain/left-sidebar/web/WebBrainLeftSidebarWave.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import BrainLeftSidebarWaveDropTime from "../waves/BrainLeftSidebarWaveDropTime"
import { MinimalWave } from "../../../../contexts/wave/hooks/useEnhancedWavesList";
import BrainLeftSidebarWavePin from "../waves/BrainLeftSidebarWavePin";
import { formatAddress, isValidEthAddress } from "../../../../helpers/Helpers";
import { Tooltip } from "react-tooltip";
import useDeviceInfo from "@/hooks/useDeviceInfo";

interface WebBrainLeftSidebarWaveProps {
readonly wave: MinimalWave;
Expand All @@ -29,6 +31,7 @@ const WebBrainLeftSidebarWave: React.FC<WebBrainLeftSidebarWaveProps> = ({
const searchParams = useSearchParams();
const prefetchWaveData = usePrefetchWaveData();
const isDropWave = wave.type !== ApiWaveType.Chat;
const { hasTouchScreen } = useDeviceInfo();

const getHref = (waveId: string) => {
const currentWaveId = searchParams?.get("wave") ?? undefined;
Expand Down Expand Up @@ -76,6 +79,8 @@ const WebBrainLeftSidebarWave: React.FC<WebBrainLeftSidebarWaveProps> = ({
};

const isActive = wave.id === (searchParams?.get("wave") ?? undefined);
const tooltipId = `wave-condensed-${wave.id}`;
const showTooltip = condensed && !hasTouchScreen;

if (condensed) {
return (
Expand All @@ -90,6 +95,7 @@ const WebBrainLeftSidebarWave: React.FC<WebBrainLeftSidebarWaveProps> = ({
href={getHref(wave.id)}
onMouseEnter={() => onWaveHover(wave.id)}
className="tw-flex tw-items-center tw-justify-center tw-no-underline"
{...(showTooltip ? { "data-tooltip-id": tooltipId } : {})}
>
<div className="tw-relative">
<div
Expand Down Expand Up @@ -127,6 +133,27 @@ const WebBrainLeftSidebarWave: React.FC<WebBrainLeftSidebarWaveProps> = ({
</div>
</div>
</Link>
{showTooltip && (
<Tooltip
id={tooltipId}
place="right"
positionStrategy="fixed"
style={{
background: "#37373E",
color: "white",
padding: "6px 10px",
fontSize: "12px",
fontWeight: 500,
borderRadius: "6px",
boxShadow: "0 4px 12px rgba(0, 0, 0, 0.3)",
zIndex: 10000,
}}
>
<span className="tw-text-xs">
{formattedWaveName}
</span>
</Tooltip>
)}
Comment thread
ragnep marked this conversation as resolved.
</div>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -308,4 +308,4 @@ const WebUnifiedWavesListWaves = forwardRef<
);

WebUnifiedWavesListWaves.displayName = "WebUnifiedWavesListWaves";
export default WebUnifiedWavesListWaves;
export default WebUnifiedWavesListWaves;
1 change: 0 additions & 1 deletion components/messages/MessagesView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ const MessagesView: React.FC = () => {
{content}
</BrainContent>

{/* Create Direct Message Modal */}
{connectedProfile && (
<CreateDirectMessageModal
isOpen={isDirectMessageModalOpen}
Expand Down
1 change: 0 additions & 1 deletion components/shared/WavesMessagesWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,6 @@ const WavesMessagesWrapper: React.FC<WavesMessagesWrapperProps> = ({
</div>
</div>

{/* Overlay backdrop when right sidebar is open - moved outside motion container */}
{rightVariant === "overlay" && (
<BrainRightSidebar
variant="overlay"
Expand Down