From 7674a34e1f3e5976c202e20222232ab5d2323e1e Mon Sep 17 00:00:00 2001 From: Marko Mikulicic Date: Tue, 5 Jun 2012 18:44:45 +0200 Subject: [PATCH] Implemented basic input box to jump to a specific user (no real search) --- www/assets/%version/gittip.css | 4 ++++ www/assets/%version/gittip.js | 14 ++++++++++++++ www/index.html | 9 +++++++++ 3 files changed, 27 insertions(+) diff --git a/www/assets/%version/gittip.css b/www/assets/%version/gittip.css index 0988e94df8..7e57bfba66 100644 --- a/www/assets/%version/gittip.css +++ b/www/assets/%version/gittip.css @@ -291,3 +291,7 @@ BUTTON:active { 1px 1px 0 rgba(255,255,255,.25) inset, -1px -1px 0 rgba(255,255,255,.25) inset; } + +#jumpToPersonBox { + display: none; +} diff --git a/www/assets/%version/gittip.js b/www/assets/%version/gittip.js index 683383e2d0..87d7793f10 100644 --- a/www/assets/%version/gittip.js +++ b/www/assets/%version/gittip.js @@ -312,3 +312,17 @@ Gittip.initTipButtons = function() ); }); }; + +Gittip.initJumpToPerson = function() +{ + $('#jumpToPersonButton').click(function() + { + $('#jumpToPersonBox').show(); + $('#jumpToPersonButton').hide(); + }); + + $('#jumpToPersonBox').change(function() + { + window.location = '/github/' + $('#jumpToPersonBox').value; + }); +} diff --git a/www/index.html b/www/index.html index 70e7a3c23e..45a68a8d14 100644 --- a/www/index.html +++ b/www/index.html @@ -9,6 +9,10 @@

Gittip is a gift economy.

Set up recurring tips to people who do great work. Learn more ...

+ + {% end %} {% block body %} {% if user.ANON %} @@ -52,4 +56,9 @@

Tip someone!

+

Or perhaps somebody + else ... + +

+ {% end %}