Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[ENG-4012]Fix shiki copy button animation firing off after clicking copy button #4252

Merged
merged 1 commit into from
Oct 30, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions reflex/components/datadisplay/shiki_code_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ def copy_script() -> Any:
f"""
// Event listener for the parent click
document.addEventListener('click', function(event) {{
// Find the closest div (parent element)
const parent = event.target.closest('div');
// Find the closest button (parent element)
const parent = event.target.closest('button');
// If the parent is found
if (parent) {{
// Find the SVG element within the parent
Expand Down
Loading