Commit 084b6fda1d6ea5094298609eef0b5bf6b5c61ee2
1 parent
f01bd86c
Exists in
master
and in
23 other branches
ActionItem74: implementing help system
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@603 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
2 changed files
with
5 additions
and
2 deletions
Show diff stats
app/helpers/application_helper.rb
| @@ -53,9 +53,10 @@ module ApplicationHelper | @@ -53,9 +53,10 @@ module ApplicationHelper | ||
| 53 | 53 | ||
| 54 | # TODO: implement this button, and add style='display: none' to the help | 54 | # TODO: implement this button, and add style='display: none' to the help |
| 55 | # message DIV | 55 | # message DIV |
| 56 | - button = link_to_function(_('Help'), "alert('change me, Leandro!')") | 56 | + button = link_to_function(_('Help'), "Element.show('help_message')", :class => 'help_button' ) |
| 57 | + close_button = content_tag("div", link_to_function(_("Close"), "Element.hide('help_message')", :id => 'close_help_button')) | ||
| 57 | 58 | ||
| 58 | - text = content_tag('div', button + content_tag('div', content, :class => 'help_message', :style => 'display: none;'), :class => 'help_box') | 59 | + text = content_tag('div', button + content_tag('div', content_tag('div', content) + close_button, :id => 'help_message', :style => 'display: none;'), :class => 'help_box') |
| 59 | 60 | ||
| 60 | unless block.nil? | 61 | unless block.nil? |
| 61 | concat(text, block.binding) | 62 | concat(text, block.binding) |
app/views/layouts/application.rhtml
| @@ -41,6 +41,8 @@ | @@ -41,6 +41,8 @@ | ||
| 41 | <%= stylesheet_link_tag 'common' %> | 41 | <%= stylesheet_link_tag 'common' %> |
| 42 | 42 | ||
| 43 | <%= stylesheet_link_tag 'menu' %> | 43 | <%= stylesheet_link_tag 'menu' %> |
| 44 | + <%= stylesheet_link_tag 'help' %> | ||
| 45 | + | ||
| 44 | <%= javascript_include_tag 'menu' %> | 46 | <%= javascript_include_tag 'menu' %> |
| 45 | 47 | ||
| 46 | </head> | 48 | </head> |