diff --git a/TODO.md b/TODO.md index 04b5678..01ef4d9 100644 --- a/TODO.md +++ b/TODO.md @@ -1,9 +1,5 @@ # TODO -* Change the colours of the big login buttons (make them blue-ish) -* Make the CSS less heirarchy specific (so the buttons can work outside the #oauth div) -* Publish to rubygems.org - * Do I need a Gemfile in this project? * Add a USAGE file to the generator * Perhaps add a generator option to skip the migration (or split the generator into tasks for initializer, migration and file copies) diff --git a/app/helpers/omnisocial/auth_helper.rb b/app/helpers/omnisocial/auth_helper.rb index bb4a1c5..3d06191 100644 --- a/app/helpers/omnisocial/auth_helper.rb +++ b/app/helpers/omnisocial/auth_helper.rb @@ -5,11 +5,11 @@ def auth_request_path(options = {}) end def big_twitter_login_button - content_tag(:a, content_tag(:span, 'Sign in with Twitter'), :class => 'twitter', :href => auth_request_path(:service => 'twitter')) + content_tag(:a, content_tag(:span, 'Sign in with Twitter'), :class => 'omnisocial-button twitter', :href => auth_request_path(:service => 'twitter')) end def big_facebook_login_button - content_tag(:a, content_tag(:span, 'Sign in with Facebook'), :class => 'facebook', :href => auth_request_path(:service => 'facebook')) + content_tag(:a, content_tag(:span, 'Sign in with Facebook'), :class => 'omnisocial-button facebook', :href => auth_request_path(:service => 'facebook')) end def twitter_login_button diff --git a/app/views/omnisocial/auth/new.html.erb b/app/views/omnisocial/auth/new.html.erb index 8bb910f..f842040 100644 --- a/app/views/omnisocial/auth/new.html.erb +++ b/app/views/omnisocial/auth/new.html.erb @@ -1,4 +1,4 @@ -
+
<% if flash[:error] -%>

diff --git a/lib/generators/omnisocial/templates/assets/stylesheets/omnisocial.css b/lib/generators/omnisocial/templates/assets/stylesheets/omnisocial.css index 7b96495..7b89ee0 100644 --- a/lib/generators/omnisocial/templates/assets/stylesheets/omnisocial.css +++ b/lib/generators/omnisocial/templates/assets/stylesheets/omnisocial.css @@ -1,57 +1,68 @@ -/*----- Auth ------------------------ */ -#oauth { - overflow: hidden; } - #oauth a { - text-decoration: none; } - #oauth a:hover span { - text-shadow: rgba(0, 0, 0, 0.4) 0 -1px 0px; - background: #413e31; - background: -webkit-gradient(linear, left top, left bottom, from(#535044), to(#413e31)); - border-color: #343125; - color: #e4d9ac; - -o-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; - -webkit-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; - -moz-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; - box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; } - #oauth span { - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-width: 1px; - border-style: solid; - font-weight: bold; - font-family: "proxima-nova-condensed-1", "proxima-nova-condensed-2", Helvetica, Arial, Verdana, sans-serif; - font-size: 16px; - cursor: pointer; - display: inline-block; - line-height: 1; - margin-top: 1px; - padding: 8px 10px 9px; - position: relative; - text-decoration: none; - text-shadow: rgba(0, 0, 0, 0.4) 0 -1px 0px; - background: #847539; - background: -webkit-gradient(linear, left top, left bottom, from(#9c8a46), to(#847539)); - border-color: #5f5324; - color: white; - float: none; - font-size: 18px; - position: absolute; } - #oauth .information { - float: left; - margin-right: 40px; - width: 450px; } - #oauth .twitter { - background: url(/images/omnisocial/twitter.gif) center center no-repeat; - float: left; - height: 255px; - width: 200px; } - #oauth .twitter span { - margin: 240px 0 0 25px; } - #oauth .facebook { - background: url(/images/omnisocial/facebook.png) center center no-repeat; - float: left; - margin-left: 40px; - height: 255px; - width: 200px; } - #oauth .facebook span { - margin: 240px 0 0 11px; } \ No newline at end of file +#omnisocial-login { + overflow: hidden; +} + +#omnisocial-login .information { + float: left; + margin-right: 40px; + width: 450px; +} + +a.omnisocial-button { + text-decoration: none; +} +a.omnisocial-button span { + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-width: 1px; + border-style: solid; + font-weight: bold; + font-family: "proxima-nova-condensed-1", "proxima-nova-condensed-2", Helvetica, Arial, Verdana, sans-serif; + font-size: 16px; + cursor: pointer; + display: inline-block; + line-height: 1; + margin-top: 1px; + padding: 8px 10px 9px; + position: relative; + text-decoration: none; + text-shadow: rgba(0, 0, 0, 0.4) 0 -1px 0px; + background: #3583cf; + background: -webkit-gradient(linear, left top, left bottom, from(#629ed9), to(#3583cf)); + border-color: #bbe2f8; + color: white; + float: none; + font-size: 18px; + position: absolute; +} +a:hover.omnisocial-button span { + text-shadow: rgba(0, 0, 0, 0.4) 0 -1px 0px; + background: #6ca520; + background: -webkit-gradient(linear, left top, left bottom, from(#90bb58), to(#6ca520)); + border-color: #dcf1bf; + -o-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; + -webkit-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; + -moz-box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; + box-shadow: rgba(0, 0, 0, 0.5) 0 0 5px 0; +} + +a.omnisocial-button.twitter { + background: url(/images/omnisocial/twitter.gif) center center no-repeat; + float: left; + height: 255px; + width: 200px; +} +a.omnisocial-button.twitter span { + margin: 240px 0 0 25px; +} + +a.omnisocial-button.facebook { + background: url(/images/omnisocial/facebook.png) center center no-repeat; + float: left; + margin-left: 40px; + height: 255px; + width: 200px; +} +a.omnisocial-button.facebook span { + margin: 240px 0 0 11px; +} \ No newline at end of file