-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
fix: Text selection in code blocks #8301
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds text selection capability to twoslash hover elements by introducing the user-select: text CSS property.
Key Changes:
- Added
user-select: textproperty to.twoslash-hoverclass to enable text selection in hover elements
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8301 +/- ##
==========================================
+ Coverage 76.60% 76.62% +0.02%
==========================================
Files 117 117
Lines 9746 9751 +5
Branches 328 328
==========================================
+ Hits 7466 7472 +6
+ Misses 2278 2277 -1
Partials 2 2 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On safari it's still work as expect i didn't have Firefox to test but LGTM !
|
On the URL you gave me, it seems works perfectly on Zen. I'll try to push further my tests this weekend or Monday. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, tested on Firefox.
|
I can't say whether it's the right thing to do (preventing selection in tooltips), but it works. |




Description
With this PR aim to resolve the issue with code selection mentioned in #8292
Validation
Double / Triple click on symbols with tooltip should work
Start selection into symbol with tooltip should work
Symbols with tooltip should be selected
Related Issues
Fixes #8292