Module: DeviseLayoutHelper

Defined in:
lib/devise_layout_helper.rb

Instance Method Summary collapse

Instance Method Details

#devise_page_titleObject



4
5
6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/devise_layout_helper.rb', line 4

def devise_page_title
  return content_for(:title) if content_for?(:title)

  case [controller_name, action_name]
  when %w[sessions new] then "Sign in"
  when %w[registrations new] then "Sign up"
  when %w[registrations edit] then "Edit account"
  when %w[passwords new] then "Forgot password"
  when %w[passwords edit] then "Change password"
  when %w[confirmations new] then "Resend confirmation"
  when %w[unlocks new] then "Resend unlock"
  else "Account"
  end
end