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

feat: ld-tooltip horizontal position adjustment #1101

Open
3 tasks done
Timy78 opened this issue Jun 20, 2024 · 0 comments
Open
3 tasks done

feat: ld-tooltip horizontal position adjustment #1101

Timy78 opened this issue Jun 20, 2024 · 0 comments
Labels
feature Issues that describe new features. triage An issue that needs assessment to determine its validity and urgency

Comments

@Timy78
Copy link

Timy78 commented Jun 20, 2024

Prerequisites

Describe the feature request

I'm not sure if it's a bug in the current implementation or a not yet implemented feature, so let's start with a feature request 😄

Currently, the ld-tooltip component can adjust its own position based on the vertical position of its triggen on the screen. This ensures it is displayed under the trigger if the top border of the window is too close. It would be nice to have the same functionality for the X-axis as well. At present, the tooltip overflows the window horizontally, making the text unreadable.

Describe the use case

When you have a paragraph with long text and you want to make a word the trigger for a tooltip, the word could be near the right or left border of the window depending on the device width. In such cases, the tooltip should adjust its position horizontally to ensure it remains within the viewport and the text is fully readable.

Describe preferred solution

No response

Describe alternatives

No response

Related code

https://codesandbox.io/p/sandbox/ld-tooltip-bug-repro-2xm6g8

Additional information

No response

@Timy78 Timy78 added feature Issues that describe new features. triage An issue that needs assessment to determine its validity and urgency labels Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Issues that describe new features. triage An issue that needs assessment to determine its validity and urgency
Projects
None yet
Development

No branches or pull requests

1 participant