app/views/iugu/sessions/new.html.haml in iugusdk-1.0.0.alpha.5 vs app/views/iugu/sessions/new.html.haml in iugusdk-1.0.0.alpha.7
- old
+ new
@@ -1,11 +1,56 @@
-%h2
- = I18n.t("iugu.sign_in")
-- if IuguSDK::enable_signup_form
- = simple_form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f|
- .inputs
- = f.input :email, :required => false, :autofocus => true
- = f.input :password, :required => false, :label => I18n.t("activerecord.attributes.password")
- = f.input :remember_me, :as => :boolean, :label => I18n.t("activerecord.attributes.remember_me") if devise_mapping.rememberable?
- .actions
- = f.button :submit, I18n.t("iugu.sign_in")
-= render :partial => "iugu/shared/links"
+- content_for :title do I18n.t("iugu.sign_in") + " - " + IuguSDK::application_title end
+
+.responsive-dialog
+ .container.no-padding
+
+ = render :partial => "iugu/shared/responsive-dialog.header"
+
+
+ .padding
+ %h6.no-bottom-margin
+ = I18n.t("iugu.sign_in")
+
+ - unless flash[:social] || flash[:group]
+ - flash.each do |name, msg|
+ - if msg.is_a? String
+ .notice.notice-red{ :class => name }
+ %button.close{ :'data-dismiss' => "notice" }
+ ×
+ %h4.notice-heading
+ = msg
+
+ - if IuguSDK::enable_signup_form
+ = simple_form_for(resource, :as => resource_name, :url => session_path(resource_name), :html => { :class => "no-bottom-margin" }) do |f|
+ .inputs
+ = f.input :email, :required => false, :autofocus => true, :placeholder => "E-Mail", :label => false
+
+ = f.input :password, :required => false, :placeholder => I18n.t("activerecord.attributes.password"), :label => false
+ // = f.input :remember_me, :as => :boolean, :label => I18n.t("activerecord.attributes.remember_me") if devise_mapping.rememberable?
+ .actions
+ = f.button :submit, I18n.t("iugu.sign_in"), :class => "full-width default"
+
+ - if devise_mapping.recoverable? && controller_name != 'passwords'
+ = link_to I18n.t("iugu.forgot_your_password?"), new_password_path(resource_name), :class => "button full-width no-bottom-margin"
+
+ - if IuguSDK::enable_social_login
+ .social
+ .text
+ = I18n.t("iugu.or_sign_up_with")
+ - if devise_mapping.omniauthable?
+ - resource_class.omniauth_providers.each do |provider|
+ = link_to "#{provider.to_s.titleize}", omniauth_authorize_path(resource_name, provider), :class => "full-width button no-bottom-margin default #{provider.to_s}"
+
+
+ - if IuguSDK::enable_user_confirmation
+ - if devise_mapping.confirmable? && controller_name != 'confirmations'
+ .text
+ = link_to I18n.t("iugu.did_not_receive_confirmation_instructions?"), new_confirmation_path(resource_name)
+
+ - if IuguSDK::enable_signup_form
+ .container
+ %a.button.no-bottom-margin{ :href => new_registration_path(resource_name) }
+ = I18n.t("iugu.no_account")
+ %span.more-text
+ = I18n.t("iugu.no_account_action")
+
+