From 35985aecaa84f281fda9c96c901d0256571b728c Mon Sep 17 00:00:00 2001 From: Connor Turland Date: Tue, 10 Jun 2014 12:59:19 -0400 Subject: [PATCH] fixed styling of many of the user forms --- app/assets/stylesheets/application.css | 110 ++++++++++++-------- app/views/layouts/_switchmetacodes.html.erb | 4 +- app/views/users/passwords/edit.html.erb | 5 +- app/views/users/passwords/new.html.erb | 4 +- app/views/users/registrations/new.html.erb | 6 +- app/views/users/sessions/new.html.erb | 9 +- 6 files changed, 87 insertions(+), 51 deletions(-) diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index 6bb0b6d6..d8f0f838 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -218,31 +218,61 @@ input[type="submit"]:hover { margin: -720px auto 0; } .new_session, -.new_user { +.new_user, +.edit_user, +.forgotPassword { display: block; - width: 350px; + width: 250px; position: absolute; left: 50%; top: 0; - margin: 200px 0 0 -195px; - background: url('bg.png'); + margin: 100px 0 0 -145px; + background: url(bg.png); padding: 20px; border-radius: 5px; - color: #000; + color: black; border: 1px solid #000; box-shadow: 6px 6px 8px rgba(0, 0, 0, 0.4); } -.edit_user { - display: block; - width: 225px; - position: absolute; - left: 70%; - top: 25%; - margin: 50px 0 0 -420px; - padding: 20px; - border-radius: 15px; - color: #000; - border: 2px solid #000; +.centerGreyForm input[type="text"], +.centerGreyForm input[type="email"], +.centerGreyForm input[type="password"] { + width: 250px; + height: 32px; + font-size: 15px; + direction: ltr; + -webkit-appearance: none; + appearance: none; + display: inline-block; + margin: 0; + padding: 0 8px; + background: #fff; + border: 1px solid #d9d9d9; + border-top: 1px solid #c0c0c0; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + -webkit-border-radius: 1px; + -moz-border-radius: 1px; + border-radius: 1px; + font: -webkit-small-control; + color: initial; + letter-spacing: normal; + word-spacing: normal; + text-transform: none; + text-indent: 0px; + text-shadow: none; + display: inline-block; + text-align: start; +} +.centerGreyForm input[type="text"]:hover, +.centerGreyForm input[type="email"]:hover, +.centerGreyForm input[type="password"]:hover { + border: 1px solid #b9b9b9; + border-top: 1px solid #a0a0a0; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); } #closenewtopic, #closenewsynapse { @@ -1676,35 +1706,35 @@ div.mapInfoStat { width: 55em; } .ui-tabs-vertical .ui-tabs-nav { - padding: .2em .1em .2em .2em !important; float: left; - width: 120px; + width: 93px; + background: none; + border: none; + font-size: 15px; + padding: 0 !important; } .ui-tabs-vertical .ui-tabs-nav li { clear: left; width: 100%; - border-bottom-width: 1px !important; - border-right-width: 0 !important; - margin: 0 -1px .2em 0 !important; + border-top: none !important; + border-left: none !important; + border-bottom: none !important; + background: none !important; + margin: 0 0 .2em 0 !important; + white-space: normal !important; +} +.ui-tabs-vertical .ui-tabs-nav li.ui-state-active, .ui-tabs-vertical .ui-tabs-nav li.ui-state-hover { + border-right:1px solid #000; } .ui-tabs-vertical .ui-tabs-nav li a { display: block; - white-space: nowrap; - text-overflow: ellipsis; - overflow: hidden; - width: 113px; - padding: 2px 4px !important; -} -.ui-tabs-vertical .ui-tabs-nav li.ui-tabs-active { - padding-bottom: 0; - padding-right: .1em; - border-right-width: 1px; - border-right-width: 1px; + width: 92%; + padding: 4% !important; } .ui-tabs-vertical .ui-tabs-panel { padding: 5px !important; float: right; - width: 365px; + width: 400px; } /* switch metacode set */ @@ -1713,20 +1743,18 @@ div.mapInfoStat { font-family: LatoLight, Arial, Sans-Serif; font-size: 17px; line-height: 21px; + border: none; } #metacodeSwitchTabs .setTitle { font-family: Lato, Arial, sans-serif; } -.metacodeSetList { - max-height: 167px; - overflow: hidden; - margin: 10px 0; - border-bottom: 1px solid #BBB; +#metacodeSwitchTabs .setDesc { + margin-bottom:5px; } -.customMetacodeList { +.customMetacodeList, .metacodeSetList { height: 301px; overflow: hidden; - margin: 15px 0; + margin: 5px 0 15px 0; border-bottom: 1px solid #BBB; } .customMetacodeList ul li { @@ -1736,7 +1764,7 @@ div.mapInfoStat { list-style-type: none; display: block; padding: 0px; - width: 110px; + width: 93px; height: 70px; float: left; text-align: center; diff --git a/app/views/layouts/_switchmetacodes.html.erb b/app/views/layouts/_switchmetacodes.html.erb index 67f68992..fcddc7f7 100644 --- a/app/views/layouts/_switchmetacodes.html.erb +++ b/app/views/layouts/_switchmetacodes.html.erb @@ -25,12 +25,12 @@

<%= m.name %>

-

<%= m.desc %>

<% @list = '' %> <% m.metacodes.sort{|x,y| x.name <=> y.name }.each_with_index do |m, index| %> <% @list += '
  • ' + m.name + '

    ' + m.name.downcase + '

  • ' %> <% end %>
    +

    <%= m.desc %>

      <%= @list.html_safe %>
    @@ -40,7 +40,7 @@
    <% end %>
    -

    Pick Your Own Metacodes

    +

    Pick Your Own Metacodes

    <% @list = '' %> <% Metacode.order("name").all.each_with_index do |m, index| %> <% if selectedSet == "custom" %> diff --git a/app/views/users/passwords/edit.html.erb b/app/views/users/passwords/edit.html.erb index 136b6366..a62d33f4 100644 --- a/app/views/users/passwords/edit.html.erb +++ b/app/views/users/passwords/edit.html.erb @@ -1,6 +1,8 @@ +<% content_for :title, "Change Password | Metamaps" %> +

    Change Password

    -<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put }) do |f| %> +<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :class => "forgotPassword centerGreyForm" }) do |f| %> <%= devise_error_messages! %> <%= f.hidden_field :reset_password_token %> @@ -14,7 +16,6 @@
    <%= f.submit "Change my password" %>
    - <%= render "devise/shared/links" %> <% end %> diff --git a/app/views/users/passwords/new.html.erb b/app/views/users/passwords/new.html.erb index be292b4e..2fa7b099 100644 --- a/app/views/users/passwords/new.html.erb +++ b/app/views/users/passwords/new.html.erb @@ -1,6 +1,8 @@ +<% content_for :title, "Password Reset | Metamaps" %> +

    Password Reset

    -<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :class => "new_user forgotPassword" }) do |f| %> +<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :class => "forgotPassword centerGreyForm" }) do |f| %> <%= devise_error_messages! %>

    Forgot your password?

    diff --git a/app/views/users/registrations/new.html.erb b/app/views/users/registrations/new.html.erb index ee8371a8..ec61da36 100644 --- a/app/views/users/registrations/new.html.erb +++ b/app/views/users/registrations/new.html.erb @@ -1,6 +1,8 @@ +<% content_for :title, "Sign Up | Metamaps" %> +

    Sign Up

    -<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f| %> +<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :post, :class => "new_user centerGreyForm" }) do |f| %> <%= devise_error_messages! %>

    Sign Up

    @@ -22,7 +24,7 @@
    <%= f.submit "Sign up" %>
    -

    Don't have an access code? Request an Invite
    +

    Don't have an access code?
    Request an Invite
    <% end %> diff --git a/app/views/users/sessions/new.html.erb b/app/views/users/sessions/new.html.erb index d821f1ec..ef9866f5 100644 --- a/app/views/users/sessions/new.html.erb +++ b/app/views/users/sessions/new.html.erb @@ -1,6 +1,8 @@ +<% content_for :title, "Sign In | Metamaps" %> +

    Sign In

    -<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %> +<%= form_for(resource, :as => resource_name, :url => session_path(resource_name), :html => { :method => :post, :class => "new_user centerGreyForm" }) do |f| %>

    Sign in

    <%= f.label :email %> @@ -15,11 +17,12 @@
    <%= f.submit "Sign in" %>
    -
    +
    <%- if devise_mapping.recoverable? && controller_name != 'passwords' %> <%= link_to "Forgot your password?", new_password_path(resource_name) %>
    <% end -%> -
    Don't have an account? Request an Invite
    +
    +
    Don't have an account?
    Request an Invite
    <% end %>