Permalink
Browse files

Remove the Decaf Sucks brown from the login buttons. Restructure the …

…CSS so that the buttons can be used anywhere, not just in the #auth div.
  • Loading branch information...
1 parent 1d66d17 commit 7faf09121a7c80fe887f56d36ea27dfd971e71d4 @timriley timriley committed Oct 10, 2010
View
@@ -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)
@@ -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
@@ -1,4 +1,4 @@
-<div id="oauth">
+<div id="omnisocial-login">
<% if flash[:error] -%>
<div class="error">
<p>
@@ -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; }
+#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;
+}

0 comments on commit 7faf091

Please sign in to comment.