diff --git a/schema.sql b/schema.sql
index 191c498812..45452e9be4 100644
--- a/schema.sql
+++ b/schema.sql
@@ -671,3 +671,19 @@ BEGIN;
, mtime DESC;
END;
+
+
+-------------------------------------------------------------------------------
+-- https://github.com/gittip/www.gittip.com/issues/7
+-- https://github.com/gittip/www.gittip.com/issues/145
+
+CREATE TABLE toots
+( id bigserial PRIMARY KEY
+, ctime timestamp with time zone NOT NULL
+ DEFAULT CURRENT_TIMESTAMP
+, tooter text NOT NULL REFERENCES participants
+ ON UPDATE CASCADE ON DELETE RESTRICT
+, tootee text NOT NULL REFERENCES participants
+ ON UPDATE CASCADE ON DELETE RESTRICT
+, toot text NOT NULL
+ );
diff --git a/templates/gittip.scss b/templates/gittip.scss
index d3eec1de00..0ebce3bd07 100644
--- a/templates/gittip.scss
+++ b/templates/gittip.scss
@@ -989,6 +989,71 @@ UL.community-memberships {
}
+#horn {
+ textarea {
+ width: 100%;
+ height: 40px;
+ font: normal 16px/20px $Helvetica;
+ }
+ .help {
+ font: normal 10px/12px $Helvetica;
+ color: $brown;
+ text-transform: uppercase;
+ display: block;
+
+ span {
+ display: inline-block;
+ white-space: nowrap;
+ padding: 2pt 0;
+ }
+ }
+ .datetime {
+ display: block;
+ padding: 0 0 3pt;
+ }
+ button#toot-button {
+ float: right;
+ }
+ li {
+ margin: 0;
+ padding: 0 0 2pt;
+
+ &.me.theirs {
+ font: bold 18px/19px $Helvetica;
+ }
+ &.them {
+ font: normal 12px/13px $Helvetica;
+ }
+ &.them.own {
+ font-weight: bold;
+ }
+ .meta {
+ text-align: right;
+ text-transform: none;
+ font: normal 11px/13px $Helvetica;
+ color: $light-brown;
+
+ span {
+ display: inline-block;
+ white-space: nowrap;
+ padding: 2pt 0;
+ }
+
+ .re {
+ text-align: left;
+ padding-right: 3pt;
+ }
+ .tootee {
+ font-weight: bold;
+ }
+ .time {
+ font-style: italic;
+ }
+ }
+ }
+}
+
+
#history {
th {
padding: 0 3pt;
diff --git a/templates/profile.html b/templates/profile.html
index 2695c92b75..f17badf5df 100644
--- a/templates/profile.html
+++ b/templates/profile.html
@@ -17,7 +17,7 @@
{% if participant == user or user.ADMIN %}
Navigation
- {% set pages = [('/', 'Profile'), ('/giving/', 'Giving'), ('/history/', 'History'), ('/widgets/', 'Widgets')] %}
+ {% set pages = [('/', 'Profile'), ('/horn/', 'Horn'), ('/giving/', 'Giving'), ('/history/', 'History'), ('/widgets/', 'Widgets')] %}
{% for slug, name in pages %}
{% end %}
@@ -29,7 +29,14 @@
Navigation
+{% else %}
+
{% end %}
{% end %}
diff --git a/www/%username/horn/index.html b/www/%username/horn/index.html
new file mode 100644
index 0000000000..c1f8f34c5c
--- /dev/null
+++ b/www/%username/horn/index.html
@@ -0,0 +1,41 @@
+from aspen import Response
+from gittip.utils import get_participant
+from gittip import AMOUNTS
+# ========================================================================== ^L
+
+participant = get_participant(request, restrict=False)
+hero = "Horn"
+title = "%s - %s" % (participant.username, hero)
+locked = False
+
+# ========================================================================== ^L
+{% extends templates/profile.html %}
+{% block page %}
+
+
+ {% if not user.ANON %}
+ {% if user == participant %}
+
Toot your own horn!
+ {% else %}
+
Toot their horn!
+ {% end %}
+
+ {% end %}
+
Toots
+
+
+{% end %}
diff --git a/www/%username/horn/toot.json b/www/%username/horn/toot.json
new file mode 100644
index 0000000000..07dbf99ce3
--- /dev/null
+++ b/www/%username/horn/toot.json
@@ -0,0 +1,16 @@
+from aspen import Response
+from gittip import db
+
+# ============================= ^L
+
+if user.ANON:
+ raise Response(400)
+tooter = user.username
+tootee = path['username']
+toot= body['toot']
+if len(toot) > 140:
+ raise Response(400)
+db.execute( "INSERT INTO toots (tooter, tootee, toot) VALUES (%s, %s, %s)"
+ , (tooter, tootee, toot)
+ )
+response.code = 204
diff --git a/www/%username/horn/toots.json b/www/%username/horn/toots.json
new file mode 100644
index 0000000000..d60a2529b7
--- /dev/null
+++ b/www/%username/horn/toots.json
@@ -0,0 +1,61 @@
+"""Return an array of toots for this participant.
+
+If the user is the participant, then the toot stream will include toots
+referring to people they gave money to last week.
+
+"""
+from gittip import db
+from gittip.utils import get_participant
+
+SQL_SELF = """
+
+ SELECT id, ctime, %s as horn, tootee, tooter = tootee AS own, toot
+ FROM toots
+ WHERE ( tootee = %s
+ OR tootee IN ( SELECT tippee
+ FROM transfers
+ WHERE tipper=%s
+ AND "timestamp" < (now() - interval '8 days')
+ )
+ )
+ AND id > %s
+ AND id <= %s
+ ORDER BY id DESC
+ LIMIT %s
+
+"""
+
+SQL_OTHER = """
+
+ SELECT id, ctime, %s as horn, tootee, tooter = tootee AS own, toot
+ FROM toots
+ WHERE tootee = %s
+ AND id > %s
+ AND id <= %s
+ ORDER BY id DESC
+ LIMIT %s
+
+"""
+
+DEFAULT_LIMIT = 200
+# =========================== ^L
+participant = get_participant(request, restrict=False)
+username = participant.username
+try:
+ limit = min(int(qs.get('limit', DEFAULT_LIMIT)), DEFAULT_LIMIT)
+ since_id = long(qs.get('since_id', 0))
+ if user == participant:
+ SQL = SQL_SELF
+ args = [username, username, username, since_id, limit]
+ else:
+ SQL = SQL_OTHER
+ args = [username, username, since_id, limit]
+
+ max_id = qs.get('max_id')
+ if max_id is None:
+ SQL = SQL.replace("AND id <= %s", "")
+ else:
+ args.insert(-1, long(max_id))
+except ValueError: # cast to int/long failed
+ raise Response(400)
+response.body = list(db.fetchall(SQL, tuple(args)))
diff --git a/www/assets/%version/gittip.css b/www/assets/%version/gittip.css
index e19f3b8ff0..f5def2ab16 100644
--- a/www/assets/%version/gittip.css
+++ b/www/assets/%version/gittip.css
@@ -1 +1 @@
-@font-face{font-family:'Mensch';src:url("../fonts/mensch.eot");src:url("../fonts/mensch.eot?#iefix") format("embedded-opentype"),url("../fonts/mensch.woff") format("woff"),url("../fonts/mensch.ttf") format("truetype"),url("../fonts/mensch.svg#Mensch") format("svg");font-weight:normal;font-style:normal}html,body{background:#FFF}body{color:#231f20;font:normal 16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-rendering:optimizeLegibility}.main-padding{width:960px;margin:0 auto;position:relative}*{box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}a{color:#2a8f79;text-decoration:none;font-weight:bold}a img{border:0}p,dd{margin:0;padding:0 0 1em;line-height:130%}dt{font-weight:bold;margin:1em 0 0.25em}pre{font:9pt/13pt monospace;margin:0 0 1em 1em;padding:0;overflow:auto}li{margin:0;margin:0 0 1em 1.5em}ol{margin:1em 0 0}ol li{list-style:outside decimal}.group:after{content:".";display:block;height:0;clear:both;visibility:hidden}.hidden{display:none}input{box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box}.clear{clear:both}.centered{margin:0 auto}.highlight{background:#FFFE26}.mini-user{background:white;display:block;float:left;width:100%;overflow:hidden;border:4px solid #DEE0E0;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box}.mini-user span.inner{border:1px solid #B6B7B9;display:block;min-height:50px;padding:5px}.mini-user span.inner span.avatar{background:transparent url("avatar-default.gif") center center no-repeat;background-size:cover;display:block;min-height:70px;position:relative}.mini-user span.inner span.avatar span.rank{background:#614c3e;bottom:4px;color:white;display:block;font:normal 12px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;left:4px;padding:3px 5px 3px 6px;position:absolute;text-align:center;-webkit-background-clip:padding-box;-webkit-border-radius:2px;-moz-background-clip:padding-box;-moz-border-radius:2px;border-radius:2px;background-clip:padding-box}.mini-user span.inner span.age,.mini-user span.inner span.money{color:#231f20;display:block;font:bold 18px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:7px 0 5px 0;white-space:nowrap}.mini-user span.inner span.age span.unit,.mini-user span.inner span.money span.unit{font:normal 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}.mini-user span.inner span.name{display:block;font:normal 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:3px 0;white-space:nowrap}.mini-user.anonymous{opacity:0.33}a.mini-user span.name{color:#2a8f79}span.mini-user{border-color:white}span.mini-user span.name{color:#231f20}a.mini-user:hover{border:4px solid #b2a196;text-decoration:none}a.mini-user:hover span.inner{border-color:#614c3e}button::-moz-focus-inner{border:0;padding:0}button{background:#58595b;border:3px solid rgba(88,89,91,0.33);color:white;font:bold 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;margin:0 0 0 1px;padding:4px 10px;text-transform:uppercase;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box;cursor:pointer;display:inline}button:hover{border-color:#58595b;background:#e6e6e6;color:#58595b}button.selected{border-color:rgba(255,255,255,0.9);background:#2a8f79;color:white}button.selected:hover{border-color:rgba(42,143,121,0.5);background:#e6e6e6;color:#58595b}#header{background:white;padding:10px 0;position:relative}#header td{text-align:center;vertical-align:middle}#header h1{line-height:100%}#header .logo{padding-right:18px}#header .motto{border-left:2px solid #d0d2d3;font:bold 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;padding-left:18px;text-align:left}#header div.login{padding-top:18px;position:absolute;top:0;right:0;font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#hero{background:transparent url("hero-bg.png") top left repeat;border:1px solid #d0d2d3;border-style:solid none;padding-bottom:100px;text-align:center;position:relative;z-index:1}#hero .main-padding{color:#231f20}#hero h2 span{background:transparent url("hero-bg.png") top left repeat;display:inline-block;padding:0 10px}#hero p{padding:0 20%}#hero h2.top{letter-spacing:-2px;font:normal 35px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;padding:50px 0 35px 0}#hero h2.top span{background:transparent url("hero-bg.png") top left repeat;display:inline-block;padding:0 10px}#hero h2.top:after{background:#231f20;content:"";display:block;height:1px;margin-top:-17px}#hero h1{letter-spacing:-3px;font:normal 64px/64px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;padding-bottom:20px}#hero h2.bottom{padding-bottom:20px}#hero h2.bottom span.button-container{display:inline-block;padding:0 10px}#hero h2.bottom span.button-container button{font-size:14px}#hero h2.bottom:after{background:#231f20;content:"";display:block;height:1px;margin-top:-16px}#box{text-align:center;background:white;margin:-80px auto 0;border:5px solid rgba(97,76,62,0.5);width:480px;min-width:240px;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box;position:relative;z-index:2}#box h1{font:bold 22px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#614c3e}#box h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#614c3e}#box .help{font:normal 14px/18px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#231f20}#box .help.with-padding{padding:10px}#box .as-content{padding:20px}#box .as-content.left{text-align:left}#box .as-content h1{padding-bottom:15px}#box .as-content input{width:8em}#box .is-suspicious-indicator{display:block;position:absolute;top:5px;right:5px;font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#231f20}#box label.is-suspicious-knob{display:block;position:absolute;top:2px;right:5px;font:normal 9px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#231f20}#box label.is-suspicious-knob input{position:relative;top:3px}#box .ready{padding-left:15px}#box .number{font:bold 56px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .unit{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .on-community{padding:10px}#box .on-elsewhere{width:100%}#box .on-elsewhere .offset{width:138px;height:138px}#box .on-elsewhere .picture{width:138px;height:138px}#box .on-elsewhere .picture img{width:128px;height:128px;display:block;margin:5px}#box .on-profile{width:100%}#box .on-profile.is-suspicious{background:#f99}#box .on-profile .picture{width:138px;height:138px}#box .on-profile .picture img{width:128px;height:128px;display:block;margin:5px}#box .on-profile td{text-align:left}#box .on-profile .pad-sign{padding-left:36px}#box .nav{padding:5px}#box .nav h2{color:#231f20;font:bold 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;margin:0 0 3px}#box .nav button.larger{font-size:14px}#box .nav.level-1{border-top:1px solid rgba(97,76,62,0.2);background:#e6e6e6}#box .nav.level-1 #payment-prompt{display:none;margin:10px 0 5px}#box .nav.level-1 #payment-prompt.needed{display:block}#box .nav.level-1 #payment-prompt.really-needed{display:block}#box .nav.level-2{border-top:1px solid rgba(97,76,62,0.5);background:#d0d2d3}#box .nav.level-3{background:black;text-align:center;padding:5px;color:white}#box .nav.level-3 a{display:block;color:white}#box .on-confirm{padding:35px 0 0}#box .on-confirm h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;margin:35px 0 8px}#box .on-confirm .nav{margin:35px 0 0}#box .on-confirm .nav h2{margin:8px 0}#box .on-confirm .scenario{margin:0 auto}#box .on-confirm .scenario TD{padding:6pt;width:33%}#box .on-confirm #nix{position:absolute;top:50%;left:50%;margin:-16px 0 0 -16px}#box .on-confirm .participant{position:relative;width:96pt;display:inline-block;border:2px solid #614c3e;border-radius:6pt;font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#614c3e;background:#fff url("/assets/clipped-heart.gif") bottom right no-repeat;text-align:left;overflow:hidden}#box .on-confirm .participant-padding{display:block;padding:6pt 0 6pt 9pt}#box .on-confirm .participant IMG,#box .on-confirm IMG.platform-icon{margin-bottom:-1pt}#box .on-confirm .participant B{font-size:11pt}#box .on-confirm .participant TD{padding:0}#box .on-confirm .participant TH{font-weight:normal}#box .on-confirm .other,#box .on-confirm .abandoned{font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .on-confirm .abandoned{text-align:center;overflow:hidden}#box .on-confirm .nix{border-color:#b2a196}#box .on-confirm .other B{font-size:9pt}#box .on-form{text-align:left}#box .on-form .constrain-width{margin:0 auto 35px;width:300px}#box .on-form form h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;margin:35px 0 8px}#box .on-form .half{width:150px}#box .on-form .full{clear:both;text-align:right;padding-top:5px}#box .on-form #other{font:normal 9pt/14pt Arial,sans-serif;color:#00E;cursor:pointer;margin-right:1em}#box .on-form #other:hover{text-decoration:underline}#box .on-form .left{float:left}#box .on-form .right{float:left}#box .on-form LABEL{display:block;font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:8px 0 0;padding:0;text-transform:uppercase}#box .on-form INPUT{font:normal 11pt/14pt "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;width:292px;margin:0;padding:3px;border:1px solid #b2a196;outline:none}#box .on-form INPUT.disabled{color:#b2a196}#box .on-form .half INPUT{width:137px}#box .on-form .right.half LABEL,#box .on-form .right.half INPUT{margin-left:5px}#box .on-form INPUT:focus{border-color:#2a8f79}#box .on-form .float{float:left}#box .on-form .city INPUT{width:137px}#box .on-form .state INPUT{width:43px}#box .on-form .zip INPUT{width:75px}#box .on-form .card_number INPUT{width:137px}#box .on-form .cvv INPUT{width:43px}#box .on-form INPUT.expiration_month{width:24px}#box .on-form INPUT.expiration_year{width:39px;margin-left:1px !important}#box .on-form .not-first LABEL,#box .on-form .not-first INPUT{margin-left:10px}#box .on-form .nav{text-align:center}#box .on-form #feedback .details li{margin:0;padding:0 0 0 2em;text-indent:-2em;font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}.payment-footer{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-align:center}#page #leaderboard{overflow:hidden;margin:0 auto;width:870px}#page #leaderboard ul{margin:0 0 20px 0;overflow:hidden;margin:0 auto}#page #leaderboard ul li{display:block;float:left;margin:0;min-width:90px;padding:2px;width:10%}#page #leaderboard>*{width:270px;float:left;margin-right:30px}#page #leaderboard>*:last-child{margin-right:0}#page{padding:20px 0 0;background:white}#page h1{color:#2a8f79;font:normal 35px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:-2px;margin:35px 0 20px 0;text-transform:uppercase}#page h2{color:#614c3e;font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;margin:35px 0 8px}#page .col{width:auto;margin:0 auto}#page .col0{width:460px;margin:0 auto}#page .col1{width:460px;float:left}#page .col2{width:460px;float:right}#footer{margin:4em 0 1em;border-top:1px solid #231f20;padding:0.5em 0 0;text-align:right;font:normal 12px/16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#footer .social{float:left}#accounts{margin-bottom:12pt}#accounts td{text-align:left;vertical-align:middle;line-height:100%}#accounts td.account-type{border-right:1pt solid #B2A196;padding:6pt 6pt 6pt 0}#accounts td.account-type IMG{width:36pt;height:36pt}#accounts DIV.account-type{font-size:x-small;clear:both;color:#b2a196}#accounts .account-details{padding-left:6pt}#accounts IMG.avatar{width:24pt;height:24pt;float:left;margin-right:3pt}#members{list-style:none;margin-bottom:12pt;margin:0 auto}#members TD{padding:0 0 0.5em 0;text-align:left}#members IMG{width:18pt;height:18pt;margin-right:6pt;float:left}.tip-distribution .dollar-sign{padding:0 2pt 0 24pt;text-align:right}.tip-distribution .amount{padding:0 6pt 0 0;text-align:right}.tip-distribution .amount-change{padding:6pt 0 6pt 24pt;text-align:left}.tip-distribution .count{text-align:left;white-space:nowrap}.tip-distribution .count SPAN.number{font-size:8pt}.tip-distribution .count SPAN.bar{background:#b2a196;display:inline-block;margin-right:3pt;height:9pt}.tip-distribution .count SPAN.bar.green{background:#2a8f79}UL.community-memberships{margin:1em 0;padding:0}UL.community-memberships LI{padding:0;margin:0}UL.community-memberships LI DIV.fine{display:block;font-size:9pt;line-height:9pt;padding-bottom:6pt}UL.community-memberships LI DIV.fine SPAN.leave{cursor:pointer;color:#2a8f79;text-decoration:underline}.communities SELECT{width:98%}#profile-edit BUTTON.save,#profile-edit BUTTON.cancel{display:none}#profile-edit .username INPUT{width:6em;display:none}#profile-edit .username .warning{margin-top:5px;display:block;color:red;display:none}#profile-edit .statement DIV.edit{display:none}#profile-edit .statement TEXTAREA{width:98%;height:126pt;padding:1%}#profile-edit .statement .help{font:normal 12px/12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#profile-edit .goal TABLE.edit{display:none}#profile-edit .goal TD{text-align:left}#profile-edit .goal #goal-custom{text-align:right;width:6pc}#profile-edit .goal LI{margin-bottom:1em}#history th{padding:0 3pt}#history th b{font-weight:300;font-size:9pt}#history td{padding:1pt 3pt;font-size:9pt;line-height:10pt;text-align:right}#history td h2{text-align:left}#history .head td{font-size:9pt;white-space:normal;text-align:left;border-bottom:1px solid #614c3e}#history td.card,#history td.fees,#history td.debits{color:red}#history .head td.card,#history .head td.fees,#history .head td.debits{color:#614c3e}#history td.notes{text-align:left}#history .fees{border-right:1px solid #614c3e;text-align:right}#history .outside{border-right:1px solid #614c3e;text-align:right !important}#open_group .fine{font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase}#open_group TD{padding-right:0.5em}#open_group #identifications{width:250px;float:right;position:relative}#open_group #identifications ::-webkit-input-placeholder{color:#b2a196}#open_group #identifications ::-moz-placeholder{color:#b2a196}#open_group #identifications :-ms-input-placeholder{color:#b2a196}#open_group #identifications input:-moz-placeholder{color:#b2a196}#open_group #identifications #query{width:170px;padding:2px 5px;z-index:1;position:relative;top:1px;outline:none;border:none}#open_group #identifications .weight{background:#2a8f79;display:inline-block}#open_group #identifications .weight.a{height:24px;width:24px}#open_group #identifications .weight.b{height:12px;width:12px}#open_group #identifications .weight.c{height:6px;width:6px}#open_group #identifications .weight.d{height:3px;width:3px}#open_group #identifications .weight.e{height:1px;width:1px}#open_group #identifications .weight.f{height:0.25px;width:0.25px}#open_group #identifications .weight.g{background:red;width:1px;height:1px}#open_group #identifications #lookup-container{position:relative;vertical-align:middle}#open_group #identifications #lookup-container #lookup-results{width:188px;min-height:30px;position:absolute;bottom:-1px;left:-4px;background:white;margin:0;padding:2px 0;border:4px solid rgba(97,76,62,0.5);color:#b2a196;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box}#open_group #identifications #lookup-container #lookup-results li{font:normal 16px/16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;white-space:nowrap;margin:0;padding:3px 5px;overflow:hidden}#open_group #split{width:180px;float:left}#open_group #split .percentage{text-align:right}@media (max-width: 1029px){.main-padding{width:auto;padding:0 35px}#page .col,#page .col1,#page .col2{width:460px;float:none;margin:0 auto}#page #leaderboard{width:600px}#page #leaderboard>*{width:180px}}@media (max-width: 680px){#page #leaderboard{width:375px}#page #leaderboard>*{width:auto;margin:0;float:none}#page #leaderboard ul li.luxury{display:none}}@media (max-width: 670px){.main-padding{padding:0 34px}}@media (max-width: 660px){.main-padding{padding:0 32px}}@media (max-width: 640px){.main-padding{padding:0 30px}}@media (max-width: 620px){.main-padding{padding:0 28px}}@media (max-width: 600px){.main-padding{padding:0 26px}}@media (max-width: 580px){.main-padding{padding:0 24px}}@media (max-width: 560px){.main-padding{padding:0 22px}}@media (max-width: 540px){.main-padding{padding:0 20px}body{font:normal 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#header div.login{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}}@media (max-width: 530px){.main-padding{padding:0 18px}}@media (max-width: 520px){.main-padding{padding:0 16px}}@media (max-width: 510px){.main-padding{padding:0 14px}}@media (max-width: 500px){.main-padding{padding:0 12px}}@media (max-width: 494px){#box{width:auto}}@media (max-width: 490px){.main-padding{padding:0 10px}}@media (max-width: 480px){.main-padding{padding:0 8px}#header{text-align:center}#header div.login{position:static}#header table{margin:0 auto}body{font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box #jump .luxury{display:none}#page .col,#page .col0,#page .col1,#page .col2{width:auto}}@media (max-width: 470px){.main-padding{padding:0 6px}}@media (max-width: 460px){.main-padding{padding:0 4px}}@media (max-width: 600px){#hero h2.top{font-size:35px;line-height:35px;padding:50px 0 35px}#hero h2.top:after{margin-top:-17px}#hero h1{font-size:64px;line-height:64px;letter-spacing:-3px;padding:0 0 20px}}@media (max-width: 550px){#hero h2.top{font-size:31px;line-height:31px;padding:43px 0 29px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:57px;line-height:57px;letter-spacing:-1px;padding:0 0 15px}}@media (max-width: 500px){#hero h2.top{font-size:27px;line-height:27px;padding:36px 0 23px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:50px;line-height:50px;letter-spacing:-1px;padding:0 0 10px}}@media (max-width: 450px){#hero h2.top{font-size:23px;line-height:23px;padding:29px 0 17px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:43px;line-height:43px;letter-spacing:-1px;padding:0 0 5px}}@media (max-width: 400px){#hero h2.top{font-size:19px;line-height:19px;padding:22px 0 11px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:36px;line-height:36px;letter-spacing:-1px;padding:0}}@media (max-width: 350px){#hero h2.top{font-size:15px;line-height:15px;padding:15px 0 5px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:29px;line-height:29px;letter-spacing:0px;padding:0}}@media (max-width: 360px){#box{border-radius:0;border-left-width:1px;border-right-width:1px}}@media (max-width: 460px){#box table h2{font-size:14px;line-height:14px}#box table .pad-sign{padding-left:36px !important}#box table .number{font-size:56px;line-height:56px}#box table .unit{font-size:12px;line-height:12px}}@media (max-width: 420px){#box table h2{font-size:13px;line-height:13px}#box table .pad-sign{padding-left:30px !important}#box table .number{font-size:48px;line-height:48px}#box table .unit{font-size:11px;line-height:11px}}@media (max-width: 380px){#box table h2{font-size:13px;line-height:12px}#box table .pad-sign{padding-left:24px !important}#box table .number{font-size:40px;line-height:40px}}@media (max-width: 340px){#box table h2{font-size:11px;line-height:11px}#box table .pad-sign{padding-left:18px !important}#box table .number{font-size:32px;line-height:32px}#box table .unit{font-size:10px;line-height:10px}}@media (max-width: 300px){#box table h2{font-size:10px;line-height:10px}#box table .pad-sign{padding-left:12px !important}#box table .number{font-size:24px;line-height:24px}#box table .unit{font-size:9px;line-height:9px}}@media (max-width: 320px){body{font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}}@media (max-width: 240px){#header .logo{padding-right:0}#header .motto.luxury{display:none}#header .login .luxury{display:none}}@media (max-width: 200px){#box #jump input{width:80%}}
+@font-face{font-family:'Mensch';src:url("../fonts/mensch.eot");src:url("../fonts/mensch.eot?#iefix") format("embedded-opentype"),url("../fonts/mensch.woff") format("woff"),url("../fonts/mensch.ttf") format("truetype"),url("../fonts/mensch.svg#Mensch") format("svg");font-weight:normal;font-style:normal}html,body{background:#FFF}body{color:#231f20;font:normal 16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-rendering:optimizeLegibility}.main-padding{width:960px;margin:0 auto;position:relative}*{box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}a{color:#2a8f79;text-decoration:none;font-weight:bold}a img{border:0}p,dd{margin:0;padding:0 0 1em;line-height:130%}dt{font-weight:bold;margin:1em 0 0.25em}pre{font:9pt/13pt monospace;margin:0 0 1em 1em;padding:0;overflow:auto}li{margin:0;margin:0 0 1em 1.5em}ol{margin:1em 0 0}ol li{list-style:outside decimal}.group:after{content:".";display:block;height:0;clear:both;visibility:hidden}.hidden{display:none}input{box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box}.clear{clear:both}.centered{margin:0 auto}.highlight{background:#FFFE26}.mini-user{background:white;display:block;float:left;width:100%;overflow:hidden;border:4px solid #dee0e0;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box}.mini-user span.inner{border:1px solid #b6b7b9;display:block;min-height:50px;padding:5px}.mini-user span.inner span.avatar{background:transparent url("avatar-default.gif") center center no-repeat;background-size:cover;display:block;min-height:70px;position:relative}.mini-user span.inner span.avatar span.rank{background:#614c3e;bottom:4px;color:white;display:block;font:normal 12px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;left:4px;padding:3px 5px 3px 6px;position:absolute;text-align:center;-webkit-background-clip:padding-box;-webkit-border-radius:2px;-moz-background-clip:padding-box;-moz-border-radius:2px;border-radius:2px;background-clip:padding-box}.mini-user span.inner span.age,.mini-user span.inner span.money{color:#231f20;display:block;font:bold 18px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:7px 0 5px 0;white-space:nowrap}.mini-user span.inner span.age span.unit,.mini-user span.inner span.money span.unit{font:normal 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}.mini-user span.inner span.name{display:block;font:normal 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:3px 0;white-space:nowrap}.mini-user.anonymous{opacity:0.33}a.mini-user span.name{color:#2a8f79}span.mini-user{border-color:white}span.mini-user span.name{color:#231f20}a.mini-user:hover{border:4px solid #b2a196;text-decoration:none}a.mini-user:hover span.inner{border-color:#614c3e}button::-moz-focus-inner{border:0;padding:0}button{background:#58595b;border:3px solid rgba(88,89,91,0.33);color:white;font:bold 11px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;margin:0 0 0 1px;padding:4px 10px;text-transform:uppercase;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box;cursor:pointer;display:inline}button:hover{border-color:#58595b;background:#e6e6e6;color:#58595b}button.selected{border-color:rgba(255,255,255,0.9);background:#2a8f79;color:white}button.selected:hover{border-color:rgba(42,143,121,0.5);background:#e6e6e6;color:#58595b}#header{background:white;padding:10px 0;position:relative}#header td{text-align:center;vertical-align:middle}#header h1{line-height:100%}#header .logo{padding-right:18px}#header .motto{border-left:2px solid #d0d2d3;font:bold 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;padding-left:18px;text-align:left}#header div.login{padding-top:18px;position:absolute;top:0;right:0;font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#hero{background:transparent url("hero-bg.png") top left repeat;border:1px solid #d0d2d3;border-style:solid none;padding-bottom:100px;text-align:center;position:relative;z-index:1}#hero .main-padding{color:#231f20}#hero h2 span{background:transparent url("hero-bg.png") top left repeat;display:inline-block;padding:0 10px}#hero p{padding:0 20%}#hero h2.top{letter-spacing:-2px;font:normal 35px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;padding:50px 0 35px 0}#hero h2.top span{background:transparent url("hero-bg.png") top left repeat;display:inline-block;padding:0 10px}#hero h2.top:after{background:#231f20;content:"";display:block;height:1px;margin-top:-17px}#hero h1{letter-spacing:-3px;font:normal 64px/64px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;padding-bottom:20px}#hero h2.bottom{padding-bottom:20px}#hero h2.bottom span.button-container{display:inline-block;padding:0 10px}#hero h2.bottom span.button-container button{font-size:14px}#hero h2.bottom:after{background:#231f20;content:"";display:block;height:1px;margin-top:-16px}#box{text-align:center;background:white;margin:-80px auto 0;border:5px solid rgba(97,76,62,0.5);width:480px;min-width:240px;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box;position:relative;z-index:2}#box h1{font:bold 22px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#614c3e}#box h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#614c3e}#box .help{font:normal 14px/18px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#231f20}#box .help.with-padding{padding:10px}#box .as-content{padding:20px}#box .as-content.left{text-align:left}#box .as-content h1{padding-bottom:15px}#box .as-content input{width:8em}#box .is-suspicious-indicator{display:block;position:absolute;top:5px;right:5px;font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#231f20}#box label.is-suspicious-knob{display:block;position:absolute;top:2px;right:5px;font:normal 9px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;color:#231f20}#box label.is-suspicious-knob input{position:relative;top:3px}#box .ready{padding-left:15px}#box .number{font:bold 56px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .unit{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .on-community{padding:10px}#box .on-elsewhere{width:100%}#box .on-elsewhere .offset{width:138px;height:138px}#box .on-elsewhere .picture{width:138px;height:138px}#box .on-elsewhere .picture img{width:128px;height:128px;display:block;margin:5px}#box .on-profile{width:100%}#box .on-profile.is-suspicious{background:#f99}#box .on-profile .picture{width:138px;height:138px}#box .on-profile .picture img{width:128px;height:128px;display:block;margin:5px}#box .on-profile td{text-align:left}#box .on-profile .pad-sign{padding-left:36px}#box .nav{padding:5px}#box .nav h2{color:#231f20;font:bold 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;margin:0 0 3px}#box .nav button.larger{font-size:14px}#box .nav.level-1{border-top:1px solid rgba(97,76,62,0.2);background:#e6e6e6}#box .nav.level-1 #payment-prompt{display:none;margin:10px 0 5px}#box .nav.level-1 #payment-prompt.needed{display:block}#box .nav.level-1 #payment-prompt.really-needed{display:block}#box .nav.level-2{border-top:1px solid rgba(97,76,62,0.5);background:#d0d2d3}#box .nav.level-3{background:black;text-align:center;padding:5px;color:white}#box .nav.level-3 a{display:block;color:white}#box .on-confirm{padding:35px 0 0}#box .on-confirm h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;margin:35px 0 8px}#box .on-confirm .nav{margin:35px 0 0}#box .on-confirm .nav h2{margin:8px 0}#box .on-confirm .scenario{margin:0 auto}#box .on-confirm .scenario TD{padding:6pt;width:33%}#box .on-confirm #nix{position:absolute;top:50%;left:50%;margin:-16px 0 0 -16px}#box .on-confirm .participant{position:relative;width:96pt;display:inline-block;border:2px solid #614c3e;border-radius:6pt;font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#614c3e;background:#fff url("/assets/clipped-heart.gif") bottom right no-repeat;text-align:left;overflow:hidden}#box .on-confirm .participant-padding{display:block;padding:6pt 0 6pt 9pt}#box .on-confirm .participant IMG,#box .on-confirm IMG.platform-icon{margin-bottom:-1pt}#box .on-confirm .participant B{font-size:11pt}#box .on-confirm .participant TD{padding:0}#box .on-confirm .participant TH{font-weight:normal}#box .on-confirm .other,#box .on-confirm .abandoned{font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box .on-confirm .abandoned{text-align:center;overflow:hidden}#box .on-confirm .nix{border-color:#b2a196}#box .on-confirm .other B{font-size:9pt}#box .on-form{text-align:left}#box .on-form .constrain-width{margin:0 auto 35px;width:300px}#box .on-form form h2{font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase;margin:35px 0 8px}#box .on-form .half{width:150px}#box .on-form .full{clear:both;text-align:right;padding-top:5px}#box .on-form #other{font:normal 9pt/14pt Arial,sans-serif;color:#00E;cursor:pointer;margin-right:1em}#box .on-form #other:hover{text-decoration:underline}#box .on-form .left{float:left}#box .on-form .right{float:left}#box .on-form LABEL{display:block;font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;margin:8px 0 0;padding:0;text-transform:uppercase}#box .on-form INPUT{font:normal 11pt/14pt "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;width:292px;margin:0;padding:3px;border:1px solid #b2a196;outline:none}#box .on-form INPUT.disabled{color:#b2a196}#box .on-form .half INPUT{width:137px}#box .on-form .right.half LABEL,#box .on-form .right.half INPUT{margin-left:5px}#box .on-form INPUT:focus{border-color:#2a8f79}#box .on-form .float{float:left}#box .on-form .city INPUT{width:137px}#box .on-form .state INPUT{width:43px}#box .on-form .zip INPUT{width:75px}#box .on-form .card_number INPUT{width:137px}#box .on-form .cvv INPUT{width:43px}#box .on-form INPUT.expiration_month{width:24px}#box .on-form INPUT.expiration_year{width:39px;margin-left:1px !important}#box .on-form .not-first LABEL,#box .on-form .not-first INPUT{margin-left:10px}#box .on-form .nav{text-align:center}#box .on-form #feedback .details li{margin:0;padding:0 0 0 2em;text-indent:-2em;font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}.payment-footer{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-align:center}#page #leaderboard{overflow:hidden;margin:0 auto;width:870px}#page #leaderboard ul{margin:0 0 20px 0;overflow:hidden;margin:0 auto}#page #leaderboard ul li{display:block;float:left;margin:0;min-width:90px;padding:2px;width:10%}#page #leaderboard>*{width:270px;float:left;margin-right:30px}#page #leaderboard>*:last-child{margin-right:0}#page{padding:20px 0 0;background:white}#page h1{color:#2a8f79;font:normal 35px "Mensch","Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:-2px;margin:35px 0 20px 0;text-transform:uppercase}#page h2{color:#614c3e;font:bold 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;letter-spacing:1px;text-transform:uppercase;margin:35px 0 8px}#page .col{width:auto;margin:0 auto}#page .col0{width:460px;margin:0 auto}#page .col1{width:460px;float:left}#page .col2{width:460px;float:right}#footer{margin:4em 0 1em;border-top:1px solid #231f20;padding:0.5em 0 0;text-align:right;font:normal 12px/16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#footer .social{float:left}#accounts{margin-bottom:12pt}#accounts td{text-align:left;vertical-align:middle;line-height:100%}#accounts td.account-type{border-right:1pt solid #b2a196;padding:6pt 6pt 6pt 0}#accounts td.account-type IMG{width:36pt;height:36pt}#accounts DIV.account-type{font-size:x-small;clear:both;color:#b2a196}#accounts .account-details{padding-left:6pt}#accounts IMG.avatar{width:24pt;height:24pt;float:left;margin-right:3pt}#members{list-style:none;margin-bottom:12pt;margin:0 auto}#members TD{padding:0 0 0.5em 0;text-align:left}#members IMG{width:18pt;height:18pt;margin-right:6pt;float:left}.tip-distribution .dollar-sign{padding:0 2pt 0 24pt;text-align:right}.tip-distribution .amount{padding:0 6pt 0 0;text-align:right}.tip-distribution .amount-change{padding:6pt 0 6pt 24pt;text-align:left}.tip-distribution .count{text-align:left;white-space:nowrap}.tip-distribution .count SPAN.number{font-size:8pt}.tip-distribution .count SPAN.bar{background:#b2a196;display:inline-block;margin-right:3pt;height:9pt}.tip-distribution .count SPAN.bar.green{background:#2a8f79}UL.community-memberships{margin:1em 0;padding:0}UL.community-memberships LI{padding:0;margin:0}UL.community-memberships LI DIV.fine{display:block;font-size:9pt;line-height:9pt;padding-bottom:6pt}UL.community-memberships LI DIV.fine SPAN.leave{cursor:pointer;color:#2a8f79;text-decoration:underline}.communities SELECT{width:98%}#profile-edit BUTTON.save,#profile-edit BUTTON.cancel{display:none}#profile-edit .username INPUT{width:6em;display:none}#profile-edit .username .warning{margin-top:5px;display:block;color:red;display:none}#profile-edit .statement DIV.edit{display:none}#profile-edit .statement TEXTAREA{width:98%;height:126pt;padding:1%}#profile-edit .statement .help{font:normal 12px/12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#profile-edit .goal TABLE.edit{display:none}#profile-edit .goal TD{text-align:left}#profile-edit .goal #goal-custom{text-align:right;width:6pc}#profile-edit .goal LI{margin-bottom:1em}#horn textarea{width:100%;height:40px;font:normal 16px/20px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#horn .help{font:normal 10px/12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#614c3e;text-transform:uppercase;display:block}#horn .help span{display:inline-block;white-space:nowrap;padding:2pt 0}#horn .datetime{display:block;padding:0 0 3pt}#horn button#toot-button{float:right}#horn li{margin:0;padding:0 0 2pt}#horn li.me.theirs{font:bold 18px/19px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#horn li.them{font:normal 12px/13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#horn li.them.own{font-weight:bold}#horn li .meta{text-align:right;text-transform:none;font:normal 11px/13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;color:#b2a196}#horn li .meta span{display:inline-block;white-space:nowrap;padding:2pt 0}#horn li .meta .re{text-align:left;padding-right:3pt}#horn li .meta .tootee{font-weight:bold}#horn li .meta .time{font-style:italic}#history th{padding:0 3pt}#history th b{font-weight:300;font-size:9pt}#history td{padding:1pt 3pt;font-size:9pt;line-height:10pt;text-align:right}#history td h2{text-align:left}#history .head td{font-size:9pt;white-space:normal;text-align:left;border-bottom:1px solid #614c3e}#history td.card,#history td.fees,#history td.debits{color:red}#history .head td.card,#history .head td.fees,#history .head td.debits{color:#614c3e}#history td.notes{text-align:left}#history .fees{border-right:1px solid #614c3e;text-align:right}#history .outside{border-right:1px solid #614c3e;text-align:right !important}#open_group .fine{font:normal 10px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;text-transform:uppercase}#open_group TD{padding-right:0.5em}#open_group #identifications{width:250px;float:right;position:relative}#open_group #identifications ::-webkit-input-placeholder{color:#b2a196}#open_group #identifications ::-moz-placeholder{color:#b2a196}#open_group #identifications :-ms-input-placeholder{color:#b2a196}#open_group #identifications input:-moz-placeholder{color:#b2a196}#open_group #identifications #query{width:170px;padding:2px 5px;z-index:1;position:relative;top:1px;outline:none;border:none}#open_group #identifications .weight{background:#2a8f79;display:inline-block}#open_group #identifications .weight.a{height:24px;width:24px}#open_group #identifications .weight.b{height:12px;width:12px}#open_group #identifications .weight.c{height:6px;width:6px}#open_group #identifications .weight.d{height:3px;width:3px}#open_group #identifications .weight.e{height:1px;width:1px}#open_group #identifications .weight.f{height:0.25px;width:0.25px}#open_group #identifications .weight.g{background:red;width:1px;height:1px}#open_group #identifications #lookup-container{position:relative;vertical-align:middle}#open_group #identifications #lookup-container #lookup-results{width:188px;min-height:30px;position:absolute;bottom:-1px;left:-4px;background:white;margin:0;padding:2px 0;border:4px solid rgba(97,76,62,0.5);color:#b2a196;-webkit-background-clip:padding-box;-webkit-border-radius:3px;-moz-background-clip:padding-box;-moz-border-radius:3px;border-radius:3px;background-clip:padding-box}#open_group #identifications #lookup-container #lookup-results li{font:normal 16px/16px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif;white-space:nowrap;margin:0;padding:3px 5px;overflow:hidden}#open_group #split{width:180px;float:left}#open_group #split .percentage{text-align:right}@media (max-width: 1029px){.main-padding{width:auto;padding:0 35px}#page .col,#page .col1,#page .col2{width:460px;float:none;margin:0 auto}#page #leaderboard{width:600px}#page #leaderboard>*{width:180px}}@media (max-width: 680px){#page #leaderboard{width:375px}#page #leaderboard>*{width:auto;margin:0;float:none}#page #leaderboard ul li.luxury{display:none}}@media (max-width: 670px){.main-padding{padding:0 34px}}@media (max-width: 660px){.main-padding{padding:0 32px}}@media (max-width: 640px){.main-padding{padding:0 30px}}@media (max-width: 620px){.main-padding{padding:0 28px}}@media (max-width: 600px){.main-padding{padding:0 26px}}@media (max-width: 580px){.main-padding{padding:0 24px}}@media (max-width: 560px){.main-padding{padding:0 22px}}@media (max-width: 540px){.main-padding{padding:0 20px}body{font:normal 14px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#header div.login{font:normal 12px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}}@media (max-width: 530px){.main-padding{padding:0 18px}}@media (max-width: 520px){.main-padding{padding:0 16px}}@media (max-width: 510px){.main-padding{padding:0 14px}}@media (max-width: 500px){.main-padding{padding:0 12px}}@media (max-width: 494px){#box{width:auto}}@media (max-width: 490px){.main-padding{padding:0 10px}}@media (max-width: 480px){.main-padding{padding:0 8px}#header{text-align:center}#header div.login{position:static}#header table{margin:0 auto}body{font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}#box #jump .luxury{display:none}#page .col,#page .col0,#page .col1,#page .col2{width:auto}}@media (max-width: 470px){.main-padding{padding:0 6px}}@media (max-width: 460px){.main-padding{padding:0 4px}}@media (max-width: 600px){#hero h2.top{font-size:35px;line-height:35px;padding:50px 0 35px}#hero h2.top:after{margin-top:-17px}#hero h1{font-size:64px;line-height:64px;letter-spacing:-3px;padding:0 0 20px}}@media (max-width: 550px){#hero h2.top{font-size:31px;line-height:31px;padding:43px 0 29px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:57px;line-height:57px;letter-spacing:-1px;padding:0 0 15px}}@media (max-width: 500px){#hero h2.top{font-size:27px;line-height:27px;padding:36px 0 23px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:50px;line-height:50px;letter-spacing:-1px;padding:0 0 10px}}@media (max-width: 450px){#hero h2.top{font-size:23px;line-height:23px;padding:29px 0 17px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:43px;line-height:43px;letter-spacing:-1px;padding:0 0 5px}}@media (max-width: 400px){#hero h2.top{font-size:19px;line-height:19px;padding:22px 0 11px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:36px;line-height:36px;letter-spacing:-1px;padding:0}}@media (max-width: 350px){#hero h2.top{font-size:15px;line-height:15px;padding:15px 0 5px}#hero h2.top:after{margin-top:-9px}#hero h1{font-size:29px;line-height:29px;letter-spacing:0px;padding:0}}@media (max-width: 360px){#box{border-radius:0;border-left-width:1px;border-right-width:1px}}@media (max-width: 460px){#box table h2{font-size:14px;line-height:14px}#box table .pad-sign{padding-left:36px !important}#box table .number{font-size:56px;line-height:56px}#box table .unit{font-size:12px;line-height:12px}}@media (max-width: 420px){#box table h2{font-size:13px;line-height:13px}#box table .pad-sign{padding-left:30px !important}#box table .number{font-size:48px;line-height:48px}#box table .unit{font-size:11px;line-height:11px}}@media (max-width: 380px){#box table h2{font-size:13px;line-height:12px}#box table .pad-sign{padding-left:24px !important}#box table .number{font-size:40px;line-height:40px}}@media (max-width: 340px){#box table h2{font-size:11px;line-height:11px}#box table .pad-sign{padding-left:18px !important}#box table .number{font-size:32px;line-height:32px}#box table .unit{font-size:10px;line-height:10px}}@media (max-width: 300px){#box table h2{font-size:10px;line-height:10px}#box table .pad-sign{padding-left:12px !important}#box table .number{font-size:24px;line-height:24px}#box table .unit{font-size:9px;line-height:9px}}@media (max-width: 320px){body{font:normal 13px "Helvetica Neue",Helvetica,Arial,"Liberation Sans",FreeSans,sans-serif}}@media (max-width: 240px){#header .logo{padding-right:0}#header .motto.luxury{display:none}#header .login .luxury{display:none}}@media (max-width: 200px){#box #jump input{width:80%}}
diff --git a/www/assets/%version/gittip.js b/www/assets/%version/gittip.js
index 3b8111b3f3..a85af64178 100644
--- a/www/assets/%version/gittip.js
+++ b/www/assets/%version/gittip.js
@@ -79,6 +79,28 @@ if(!Array.prototype.remove)
}
};
+function prettyDate(time) {
+ // http://ejohn.org/blog/javascript-pretty-date/
+ var munged = (time || "").replace(/-\d\d:\d\d$/,"")
+ .replace(/-/g,"/")
+ .replace(/[TZ]/g," "),
+ date = new Date(munged),
+ diff = (((new Date()).getTime() - date.getTime()) / 1000),
+ day_diff = Math.floor(diff / 86400);
+ console.log(time, munged, date, diff, day_diff);
+ if ( isNaN(day_diff) || day_diff < 0 || day_diff >= 31 )
+ return;
+
+ return day_diff == 0 && (
+ diff < 60 && "just now" ||
+ diff < 120 && "1 minute" ||
+ diff < 3600 && Math.floor( diff / 60 ) + " minutes" ||
+ diff < 7200 && "1 hour" ||
+ diff < 86400 && Math.floor( diff / 3600 ) + " hours") ||
+ day_diff == 1 && "Yesterday" ||
+ day_diff < 7 && day_diff + " days" ||
+ day_diff < 31 && Math.ceil( day_diff / 7 ) + " weeks";
+}
// Main namespace.
// ===============
@@ -729,3 +751,78 @@ Gittip.communities.leave = function(name, callback)
Gittip.communities.update(name, false, callback);
}
+
+
+// Horns
+// =====
+
+Gittip.horn = {};
+
+Gittip.horn.init = function()
+{
+ Gittip.horn.since_id = undefined;
+ $('#toot-form').submit(Gittip.horn.toot);
+ Gittip.horn.update({limit: 20});
+};
+
+Gittip.horn.update = function(data)
+{
+ clearTimeout(Gittip.horn.handle);
+ data = data || {};
+ if (Gittip.horn.since_id !== undefined)
+ data.since_id = Gittip.horn.since_id;
+ jQuery.ajax(
+ { type: "GET"
+ , url: "toots.json"
+ , data: data
+ , success: Gittip.horn.draw
+ });
+};
+
+Gittip.horn.draw = function(toots)
+{
+ for (var i=toots.length-1, toot; toot = toots[i]; i--)
+ {
+ Gittip.horn.since_id = toot.id;
+ Gittip.horn.drawOne(toot);
+ }
+ Gittip.horn.handle = setTimeout(Gittip.horn.update, 1000)
+};
+
+Gittip.horn.drawOne = function(toot)
+{
+ var escaped = $('
').text(toot.toot).html();
+ var html = '
'
+ + ( toot.tootee !== toot.horn && !toot.own
+ ? 're: ' + toot.tootee + ': '
+ : ''
+ )
+ + escaped
+ + ( toot.tootee !== toot.horn && toot.own
+ ? '—' + toot.tootee
+ : ''
+ )
+ + ''
+ + ''
+ + ''
+ $('#toots').prepend(html)
+};
+
+Gittip.horn.toot = function(e)
+{
+ e.preventDefault();
+ e.stopPropagation();
+ var toot = $('#toot').val();
+
+ jQuery.ajax(
+ { type: "POST"
+ , url: "toot.json"
+ , data: {toot: toot}
+ , success: Gittip.horn.update
+ });
+ return false;
+};