From 799fd1e3acdaf202e5043ba041fb6bd25ab462e2 Mon Sep 17 00:00:00 2001 From: Christophe Vilayphiou Date: Fri, 27 Apr 2012 15:27:59 +0800 Subject: [PATCH] Fix css bugs (opacity=) and changes in sign_in page --- app/assets/fonts/widget.css | 79 -------------------------- app/assets/stylesheets/widgets.css | 30 +++++----- app/views/devise/sessions/new.html.erb | 4 +- 3 files changed, 17 insertions(+), 96 deletions(-) delete mode 100644 app/assets/fonts/widget.css diff --git a/app/assets/fonts/widget.css b/app/assets/fonts/widget.css deleted file mode 100644 index fe83b22d..00000000 --- a/app/assets/fonts/widget.css +++ /dev/null @@ -1,79 +0,0 @@ -.widget-size-300 { - width:298px; -} -.widget-box { - background-color: #FFF; - overflow: hidden; - min-width: 300px; - border: 1px solid #DDD; - border-radius: 5px; - -moz-border-radius: 5px; - -webkit-border-radius: 5px; - margin: 0 0 5px 5px; - position:relative; -} -.widget-box .widget-title { - background: #999; - color: #FFF; - padding-left: 5px; - border-radius: 5px 5px 0 0; - -moz-border-radius: 5px 5px 0 0; - -webkit-border-radius: 5px 5px 0 0; -} -.widget-box .widget-content { - padding: 10px; -} -.widget-box .form-horizontal .control-group > label { - width: 50px; -} -.widget-box .form-horizontal .controls { - margin-left: 60px; -} -.widget-action { - position:absolute; - right:1px; - top:6px; -} -.action { - float: left; - display:inline-block; - margin-right: 5px; - opacity: 0.8; - filter: alpha(opacity=80); -} -.action:hover { - opacity: 1; - filter: alpha(opacity=100); - cursor: pointer; -} -.select-role { - display:none; - padding: 10px 0 0; -} -.file-upload { - position:relative; -} -.file-upload .file-name { - display: inline-block; - margin: 0 0 5px 5px; - white-space: nowrap; - width: 140px; -} -.file-upload .upload { - margin:0; - padding:0; - position:absolute; - top:0; - left:0; - opacity:.0; - filter: alpha(opacity=100); -} -.file-upload .upload:focus { - position:absolute; -} -.upload-picture { - margin-right: 5px; -} -#widget-link table { - margin-bottom:0 -} \ No newline at end of file diff --git a/app/assets/stylesheets/widgets.css b/app/assets/stylesheets/widgets.css index 04273d5b..86088fee 100644 --- a/app/assets/stylesheets/widgets.css +++ b/app/assets/stylesheets/widgets.css @@ -53,11 +53,11 @@ display:inline-block; margin-right: 5px; opacity: 0.8; - filter: alpha(opacity:80); + filter: alpha(opacity=80); } .action:hover { opacity: 1; - filter: alpha(opacity:100); + filter: alpha(opacity=100); cursor: pointer; } .select-role { @@ -95,23 +95,23 @@ opacity:.0; font-size: 60px; left: -595px/9; - filter: alpha(opacity: 0); + filter: alpha(opacity= 0); outline: none; } .file-upload .upload:focus { position:absolute; -} -.file-upload .input-medium { - border-radius: 3px 3px 3px 3px !important; - width: 267px; - position: relative; - z-index: 5; - display: block; - clear: both; -} -.file-upload .control-label { - margin-top: 0; - margin-bottom: 5px; +} +.file-upload .input-medium { + border-radius: 3px 3px 3px 3px !important; + width: 267px; + position: relative; + z-index: 5; + display: block; + clear: both; +} +.file-upload .control-label { + margin-top: 0; + margin-bottom: 5px; } .upload-picture { margin-bottom: 5px; diff --git a/app/views/devise/sessions/new.html.erb b/app/views/devise/sessions/new.html.erb index 8d9cbfb8..ea18d8d8 100644 --- a/app/views/devise/sessions/new.html.erb +++ b/app/views/devise/sessions/new.html.erb @@ -3,8 +3,8 @@

<%= t(:login) %>

- <% flash.each do |key, msg| %> - <%= content_tag :spen, msg, :class => [key, "notice label label-warning"] %> + <% flash.each do |key, msg| %> + <%= content_tag :span, msg, :class => [key, "notice label label-warning"] %> <% end%> <%= form_for :user, :url => user_session_path, :html => {:class => 'user_new form-horizontal'} do |f| %>