Skip to content
Extraits de code Groupes Projets
Valider 45223fd6 rédigé par Florian Staudacher's avatar Florian Staudacher
Parcourir les fichiers

Merge pull request #3520 from movilla/new_mobile_resgistrations_

New mobile page registrations, add an error message to registrations page, friendlier design, add placeholders and ().upcase
parents 8b793400 6c6be3e2
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -773,3 +773,9 @@ textarea#conversation_text { ...@@ -773,3 +773,9 @@ textarea#conversation_text {
-o-transition: background-position 0.1s linear; -o-transition: background-position 0.1s linear;
transition: background-position 0.1s linear; transition: background-position 0.1s linear;
} }
.registrations_error,
.registrations_notice {
color: #DF0101;
text-shadow: 1px 1px 5px #666;
}
...@@ -19,7 +19,7 @@ class RegistrationsController < Devise::RegistrationsController ...@@ -19,7 +19,7 @@ class RegistrationsController < Devise::RegistrationsController
else else
@user.errors.delete(:person) @user.errors.delete(:person)
flash[:error] = @user.errors.full_messages.join(";") flash[:error] = @user.errors.full_messages.join(" - ")
Rails.logger.info("event=registration status=failure errors='#{@user.errors.full_messages.join(', ')}'") Rails.logger.info("event=registration status=failure errors='#{@user.errors.full_messages.join(', ')}'")
render :new render :new
end end
......
...@@ -4,39 +4,47 @@ ...@@ -4,39 +4,47 @@
= javascript_include_tag "validation" = javascript_include_tag "validation"
= stylesheet_link_tag :mobile
:css
div.navbar.navbar-fixed-top{ display:none;}
body{ padding: 10px;}
legend{ background-image: url(/assets/header-bg-long.jpg); color: #939393;}
.stream .stream
- flash.each do |name, msg|
%p{:class => "registrations_#{name}"}= msg
#login_form #login_form
.login-container .login-container
= form_for(resource, :as => resource_name, :html => {:class => 'new_user_form'}, :url => registration_path(resource_name), :validate => true) do |f| = form_for(resource, :as => resource_name, :html => {:class => 'new_user_form'}, :url => registration_path(resource_name), :validate => true) do |f|
%fieldset %fieldset
%legend %legend
= t('welcome') = image_tag('branding/header-logo2x.png', :height => 40, :width => 40)
= t('aspects.aspect_stream.make_something').upcase
.control-group .control-group
= f.label :username, t('username') = f.label :username, t('username').upcase
.controls .controls
= f.text_field :username = f.text_field :username, :placeholder => "jedi_guy"
%span.host_uri
= diaspora_id_host
.control-group .control-group
= f.label :email, t('email') = f.label :email, t('email').upcase
.controls .controls
= f.text_field :email = f.text_field :email, :placeholder => "luke@hoth.net"
.control-group .control-group
= f.label :password, t('password') = f.label :password, t('password').upcase
.controls .controls
= f.password_field :password = f.password_field :password, :placeholder => "••••••••"
.control-group .control-group
= f.label :password_confirmation, t('password_confirmation') = f.label :password_confirmation, t('password_confirmation').upcase
.controls .controls
= f.password_field :password_confirmation = f.password_field :password_confirmation, :placeholder => "••••••••"
.controls .controls
= f.submit t('registrations.new.create_my_account'), :class => 'btn primary' = f.submit t('registrations.new.create_my_account'), :class => 'btn primary'
= link_to t('devise.sessions.new.sign_in'), new_user_session_path() = link_to t('devise.sessions.new.sign_in'), new_user_session_path(), :class => 'btn primary', :style => "float: right;"
%footer %footer
= link_to t('layouts.application.toggle'), toggle_mobile_path = link_to t('layouts.application.toggle'), toggle_mobile_path
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter