Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tooltip shape distortion upon card hover with scale: 1.1+ applied. #1215

Closed
haiderhossain10 opened this issue Jul 27, 2024 · 1 comment
Closed
Labels

Comments

@haiderhossain10
Copy link

Tooltip Distortion on Scaled Card Hover

Problem: Tooltip appears distorted when hovering over a card that has been scaled by 1.1 or more.

  • JSX code snippets:
<div className="flex items-center justify-between w-full">
    <div>
        <p className="text-sm leading-[191%] text-ui-theme-2 font-normal">
            {data.name}
        </p>
        <h4 className="text-[12px] leading-[191%] text-ui-theme-2 font-semibold">
            {data.netflix}
        </h4>
    </div>
    <div
        data-tooltip-id="testimonial-tooltip"
        data-tooltip-content={data.feedbackForm}
                        >
        <Image
            height={40}
            width={40}
            className="h-10 w-10"
            src={data.iconUrl}
            alt="icon"
                            />
    </div>
</div>
<Tooltip
    id="testimonial-tooltip"
    className="font-normal font-neue !bg-ui-theme-2 "
/>
  • CSS code snippets:
.ui-testimonial-2 .swiper-slide-active {
    transition: all 0.4s ease-in-out;
}
.ui-testimonial-2 .swiper-slide-active:hover {
    scale: 1.1;
}

image

@gabrieljablonski
Copy link
Member

Try putting the <Tooltip /> component inside of a portal.

We already have plans to do this internally (see #1163), but currently you're going to need to do it manually.

Please let us know if that solves the problem for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants