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

Add tooltip to sorted columns #3163

Closed
adrianthedev opened this issue Aug 21, 2024 · 5 comments · Fixed by #3454
Closed

Add tooltip to sorted columns #3163

adrianthedev opened this issue Aug 21, 2024 · 5 comments · Fixed by #3454
Assignees
Labels
Enhancement Not necessarily a feature, but something has improved Good first issue Good for newcomers Help wanted We could use some help with this Javascript Pull requests that update Javascript code

Comments

@adrianthedev
Copy link
Collaborator

Feature

CleanShot 2024-08-21 at 12 32 21@2x

Approach

Let's add the necessary attributes to the th elements to show a tooltip using tippy.

data-tippy="tooltip" title="SORTING_TITLE_VALUE"

@adrianthedev adrianthedev added Help wanted We could use some help with this Good first issue Good for newcomers Javascript Pull requests that update Javascript code labels Aug 21, 2024
@adrianthedev adrianthedev added the Enhancement Not necessarily a feature, but something has improved label Aug 21, 2024
@enderahmetyurt
Copy link
Contributor

@adrianthedev 🙋 May I :)

@adrianthedev
Copy link
Collaborator Author

Go for it @enderahmetyurt!
Thanks!

@enderahmetyurt
Copy link
Contributor

Hello @adrianthedev I couldn't reproduce it. I guess we don't want to add that tool_tip to every sorted column, right?

@adrianthedev
Copy link
Collaborator Author

The issue is that the icon does not have a label to display what it does "Sort records", "Records sorted descending", "Records sorted ascending".

Avo uses tippy to do that here.
In order to display a tooltip the element has to have the title attribute and data-tippy="tooltip" set.

Ex:

<a href="..." title="Sort records" data-tippy="tooltip">...</a>

Image

Did I answer your question?

@enderahmetyurt
Copy link
Contributor

Yes man. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Not necessarily a feature, but something has improved Good first issue Good for newcomers Help wanted We could use some help with this Javascript Pull requests that update Javascript code
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants