Skip to content

Commit

Permalink
base solution
Browse files Browse the repository at this point in the history
  • Loading branch information
alextaing committed Oct 26, 2023
1 parent f19478a commit bae74e2
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions packages/studio-ui/src/components/common/TooltipIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ import { Tooltip } from "react-tooltip";
import { v4 } from "uuid";
import { ReactComponent as Info } from "../../icons/info.svg";

const tooltipCssStyle = {
"maxWidth": "23.5%",
}

export interface TooltipIconProps {
content: string;
}
Expand All @@ -12,12 +16,15 @@ export default function TooltipIcon({ content }: TooltipIconProps) {

return (
<div>
<Info id={tooltipId} className="ml-3 pb-1" data-testid="prop-tooltip" />
<Info id={tooltipId} className="ml-1 pb-1 mr-4" data-testid="prop-tooltip" />
<Tooltip
className="bg-black z-20"
anchorId={tooltipId}
content={content}
place="left"
place="top"
closeOnScroll={true}
positionStrategy="fixed"
style={tooltipCssStyle}
/>
</div>
);
Expand Down

0 comments on commit bae74e2

Please sign in to comment.