Skip to content

Conversation

@schultek
Copy link
Contributor

@schultek schultek commented Oct 27, 2025

Shows a tooltip for all glossary links with their term and definition. Glossary links are styled differently than normal links to give a visual indication to the visitor.

  • On non-touch devices: shows the tooltip on hover.
  • On touch devices: toggles the tooltip on click.

Always positions the tooltip inside the content container with no horizontal overflow.

Bildschirmfoto 2025-10-27 um 14 48 08

@parlough parlough self-requested a review October 27, 2025 14:20
@dart-github-bot
Copy link
Collaborator

dart-github-bot commented Oct 27, 2025

Visit the preview URL for this PR (updated for commit 837fab7):

https://dart-dev--pr6969-feat-glossary-tooltip-aq2t2rdr.web.app

@parlough
Copy link
Member

I love the functionality @schultek! Thanks :D

What about keyboard only users though? Would it make sense to also show the tooltip if the link is focused?

@schultek
Copy link
Contributor Author

Good catch, I will add focus support as well

@schultek schultek force-pushed the feat/glossary-tooltip branch 2 times, most recently from 594b3eb to 35fbc1d Compare October 28, 2025 11:23
@parlough
Copy link
Member

/gcbrun

Copy link
Member

@parlough parlough left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is super exciting. Thanks for working on this @schultek!

Works super well! I just have some small suggestions and questions.

@schultek schultek force-pushed the feat/glossary-tooltip branch from 6f5382e to 7b112cb Compare October 28, 2025 14:00
@parlough parlough self-requested a review October 28, 2025 15:15
Copy link
Member

@parlough parlough left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for making those adjustments @schultek! Looks good to me after some small suggestions:

@schultek
Copy link
Contributor Author

@parlough all done

@schultek schultek force-pushed the feat/glossary-tooltip branch from 0e2732c to bbcd9bc Compare October 29, 2025 14:26
@parlough
Copy link
Member

parlough commented Oct 29, 2025

@schultek This still looks good to me, but before we land it, can you investigate a pre-existing issue? It seems navigating to the full glossary terms scrolls to the wrong section of the page (which is a bit confusing from the learn more links). Without looking, I'm guessing because they are being closed on load and the location of the fragment is changing?

@schultek
Copy link
Contributor Author

It seems navigating to the full glossary terms scrolls to the wrong section of the page (which is a bit confusing from the learn more links). Without looking, I'm guessing because they are being closed on load and the location of the fragment is changing?

Fixed

@parlough parlough changed the title feat: add glossary tooltip feat: Add tooltip to glossary term links with their definition Oct 30, 2025
@parlough parlough changed the title feat: Add tooltip to glossary term links with their definition feat: Add tooltips to glossary term links with their definition Oct 30, 2025
@parlough
Copy link
Member

Thanks for making that adjustment! Everything looks great :D

@parlough parlough merged commit 1224648 into dart-lang:main Oct 30, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants