History

ruby: fix "show source"

Fixes #1922.

Simon Legner committed 3 years ago

Commit 5c6d93f1 parent abf659f1 file · +1 −1Browse files

Showing the changes to assets/javascripts (1 of 1 file). Show all

Unified · Split

assets/javascripts/views/pages/rdoc.coffee+1−1
@@ -8,7 +8,7 @@ class app.views.RdocPage extends app.views.BasePage · 7 unmodified lines
88 return unless event.target.classList.contains 'method-click-advice'
99 $.stopEvent(event)
1010
11− source = $ '.method-source-code', event.target.parentNode.parentNode
11+ source = $ '.method-source-code', event.target.closest('.method-detail')
1212 isShown = source.style.display is 'block'
1313
1414 source.style.display = if isShown then 'none' else 'block'

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t