[gnomeweb-wml] [wgo] Update ruler for new Friends of GNOME campaign
- From: Lucas Rocha <lucasr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnomeweb-wml] [wgo] Update ruler for new Friends of GNOME campaign
- Date: Fri, 7 Jan 2011 15:55:25 +0000 (UTC)
commit d3c53a3dff37e807232dd36e9d7b43482ab0807b
Author: Lucas Rocha <lucasr litl com>
Date: Fri Jan 7 15:33:56 2011 +0000
[wgo] Update ruler for new Friends of GNOME campaign
www.gnome.org/friends/ruler/ruler.js | 1 +
www.gnome.org/friends/ruler/update-ruler | 37 +++++++++---------------------
2 files changed, 12 insertions(+), 26 deletions(-)
---
diff --git a/www.gnome.org/friends/ruler/ruler.js b/www.gnome.org/friends/ruler/ruler.js
index e69de29..aee5935 100644
--- a/www.gnome.org/friends/ruler/ruler.js
+++ b/www.gnome.org/friends/ruler/ruler.js
@@ -0,0 +1 @@
+document.write(' <style type="text/css"> #gnome-fog-ruler { background: #237100 url(http://www.gnome.org/friends/ruler/ruler-bg.jpg) center no-repeat; padding: 16px 0px 16px 0px; color: #fff; font-family: "Lucida Grande", "DejaVu Sans", "Bitstream Vera Sans", Verdana, sans-serif; font-size: 12px; z-index: 200; float: left; width: 100%; position: relative; } #gnome-fog-ruler * { margin: 0; padding: 0; } #gnome-fog-ruler .fog-center { width: 960px; margin: 0 auto; text-align: left; } #gnome-fog-ruler a { color: #fff; } #gnome-fog-ruler .fog-intro { width: 570px; float: left; margin-right: 25px; } #gnome-fog-ruler .fog-intro h4 { margin-bottom: 6px; color: #fff; font-size: 13px; text-shadow: 0 1px 2px #346704; } #gnome-fog-ruler .fog-ruler { background: #fff; overflow: hidd
en; -moz-border-radius: 4px; -webkit-border-radius: 4px; padding: 2px; -moz-box-shadow: 0 1px 2px #346704; -webkit-box-shadow: 0 1px 2px #346704; } #gnome-fog-ruler .fog-ruler .fog-bar { display: block; float: left; font-size: 5px; height: 14px; line-height: 12px; } #gnome-fog-ruler .green { background: #66bb14; } #gnome-fog-ruler .orange { background: #f57900; } #gnome-fog-ruler .blue { background: #729fcf; } #gnome-fog-ruler .yellow { background: #fce94f; } #gnome-fog-ruler .white { background: #fff; } #gnome-fog-ruler .green { background: #8ae234; } #gnome-fog-ruler .purple { background: #9a32cd; } #gnome-fog-ruler .fog-description { margin-top: 8px; overflow: hidden; text-align: center; } #gnome-fog-ruler .fog-description .fog-item { margin-right: 12px; display
: block; float: left; overflow: hidden; text-align: left; } #gnome-fog-ruler .fog-description .fog-item .fog-box { display: block; float: left; width: 12px; height: 12px; border: 1px solid #fff; margin: 0 6px 6px 0; -moz-border-radius: 3px; -webkit-border-radius: 3px; border-radius: 3px; -moz-box-shadow: 0 1px 2px #346704; -webkit-box-shadow: 0 1px 2px #346704; } #gnome-fog-ruler .fog-description .fog-item .fog-details { font-style: italic; display: block; margin-left: 20px; } #gnome-fog-ruler .fog-donate { float: right; margin-top: 8px; } #gnome-fog-ruler .fog-donate a { display: block; padding: 6px 8px; background: #fff; color: #333; font-weight: bold; text-decoration: none; font-size: 14px; -moz-box-shadow: 0 1px 2px #346704, inset 0 -3px 10px #ccc; -webki
t-box-shadow: 0 1px 2px #346704, inset 0 -3px 10px #ccc; -moz-border-radius: 4px; -webkit-border-radius: 4px; } #gnome-fog-ruler .fog-donate a:hover { color: #204a87; text-decoration: underline; }</style><div id="gnome-fog-ruler"> <div class="fog-center"> <div class="fog-intro"> <h4>Become a Friend of GNOME!</h4> <p>Help the GNOME Foundation by donating today. GNOME is looking to grow to 400 subcribers. Join for only $10 per month and get a free LWN subscription, t-shirt and more!</p> </div> <div class="fog-data"> <div class="fog-ruler"><span style="width: 3.25%;" class="fog-bar orange"> </span> </div> <div class="fog-donate"> <a href="http://www.gnome.org/friends/">Donate now!</a> </div> <div class="fog-description"><div class="fog-item"><span class="fog-box orange"> </span><strong>Friends of GNOME</str
ong><span class="fog-details">13 subscribers. 387 to go!</span></div> </div> </div> <div style="clear: both;"></div> </div></div>')
diff --git a/www.gnome.org/friends/ruler/update-ruler b/www.gnome.org/friends/ruler/update-ruler
index c9c0c66..0f03b6c 100755
--- a/www.gnome.org/friends/ruler/update-ruler
+++ b/www.gnome.org/friends/ruler/update-ruler
@@ -23,31 +23,16 @@ def split_thousands(s):
if len(s) <= 3: return s
return split_thousands(s[:-3]) + ',' + s[-3:]
-TARGET_AMOUNT = 57000.00;
+TARGET_AMOUNT = 400;
# Colors should have a matching CSS style
DONORS = [
-{ 'name': 'Canonical',
- 'color': 'orange',
- 'donation': 10000.00 },
-
-{ 'name': 'Google',
- 'color': 'blue',
- 'donation': 5000.00 },
-
-{ 'name': 'Nokia',
- 'color': 'yellow',
- 'donation': 5000.00 },
-
-{ 'name': 'Collabora',
- 'color': 'purple',
- 'donation': 5000.00 },
-
{ 'name': 'Friends of GNOME',
- 'color': 'green',
- 'donation': 32000.00,
- 'show-still-needed': 1 }]
+ 'color': 'orange',
+ 'donation': 13.0,
+ 'show-still-needed': 1 }
+]
TOTAL_DONATIONS = 0
@@ -134,9 +119,9 @@ CSS = ' \
color: #fff;\
}\
#gnome-fog-ruler .fog-intro {\
- width: 300px;\
+ width: 570px;\
float: left;\
- margin-right: 12px;\
+ margin-right: 25px;\
}\
#gnome-fog-ruler .fog-intro h4 {\
margin-bottom: 6px;\
@@ -213,7 +198,7 @@ CSS = ' \
}\
#gnome-fog-ruler .fog-donate {\
float: right;\
- margin-top: 11px;\
+ margin-top: 8px;\
}\
#gnome-fog-ruler .fog-donate a {\
display: block;\
@@ -239,8 +224,8 @@ HTML = '\
<div class="fog-center">\
<div class="fog-intro">\
<h4>Become a Friend of GNOME!</h4>\
- <p>Help the GNOME Foundation by donating today and becoming a Friend of GNOME. GNOME is looking to grow to
- 400 subcribers - join today for only $10 per motnh and get a free LWN subscription, t-shirt and more!.</p>\
+ <p>Help the GNOME Foundation by donating today. GNOME is looking to grow to\
+ 400 subcribers. Join for only $10 per month and get a free LWN subscription, t-shirt and more!</p>\
</div>\
<div class="fog-data">\
<div class="fog-ruler">'
@@ -266,7 +251,7 @@ for donor in DONORS:
if 'show-still-needed' in donor:
still_needed_str = "%.0f" % STILL_NEED
still_needed = split_thousands(still_needed_str)
- HTML += '<div class="fog-item"><span class="fog-box %s"> </span><strong>%s</strong><span class="fog-details">$%s. $%s to go!</span></div>' % (color, donor_name, donation, still_needed)
+ HTML += '<div class="fog-item"><span class="fog-box %s"> </span><strong>%s</strong><span class="fog-details">%s subscribers. %s to go!</span></div>' % (color, donor_name, donation, still_needed)
else:
HTML += '<div class="fog-item"><span class="fog-box %s"> </span><strong>%s</strong><span class="fog-details">$%s</span></div>' % (color, donor_name, donation)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]