Patch #30730 » 0001_add_css_class_option_to_toggle_links.diff
| app/helpers/application_helper.rb | ||
|---|---|---|
|
onclick << (options[:focus] ? "$('##{options[:focus]}').focus(); " : "this.blur(); ")
|
||
|
onclick << "$(window).scrollTop($('##{options[:focus]}').position().top); " if options[:scroll]
|
||
|
onclick << "return false;"
|
||
|
link_to(name, "#", :onclick => onclick)
|
||
|
link_to(name, "#", :onclick => onclick, :class => options[:class])
|
||
|
end
|
||
|
# Used to format item titles on the activity view
|
||