-
-
Notifications
You must be signed in to change notification settings - Fork 518
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 copy button to Markdown codeblocks #7451
Conversation
Would be so great for chat and many other use cases. |
One feature that I really like about ChatGPT is how the "Copy Code" follows the scroll position, up to the end of the code, so users don't have to scroll all the way up to copy. Is it easy to implement that feature? Screen.Recording.2024-10-30.at.9.24.55.AM.mov |
a957106
to
30dd111
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #7451 +/- ##
==========================================
+ Coverage 82.08% 82.24% +0.16%
==========================================
Files 337 337
Lines 50680 50680
==========================================
+ Hits 41599 41684 +85
+ Misses 9081 8996 -85 ☔ View full report in Codecov by Sentry. |
If the "follow" functionality is tricky to implement, maybe simply put an instance of the copy button at the end of the code block, as well as the beginning? Would also be a little less busy than a "following" button. |
Will skip the following behavior for now. Adding two buttons is definitely too busy. |
Implements #6209