From 11390ded587c17ca06535c0826f2d2da94417d93 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Wed, 20 Aug 2014 08:01:20 -0700 Subject: Add links to homepage --- public/css/calculator.less | 3 ++- public/js/calculator.coffee | 10 +++------- public/js/setup.coffee | 1 + views/users/edit.html | 5 +++++ views/users/show.html | 4 ++-- 5 files changed, 13 insertions(+), 10 deletions(-) diff --git a/public/css/calculator.less b/public/css/calculator.less index 2a36be4f..4ba5058a 100644 --- a/public/css/calculator.less +++ b/public/css/calculator.less @@ -15,7 +15,7 @@ div.container-fluid { .navbar-toggle { background-color: #428bca; width: 100%; position: absolute; top: 0px; height: 30px; margin: 0; float: none; z-index: 1; margin-bottom: -30px; } .navbar-toggle .glyphicon { margin-top: -5px; padding-left: 10px; } -.navbar { margin: 0; margin-bottom: 15px; } +.navbar { margin: 0; min-height: 40px; } .navbar-collapse.in { overflow-y: visible; } .nav { margin-top: 30px; } .nav li a { padding: 10px 0 10px 10px; } @@ -34,6 +34,7 @@ div#calculator { strong#total { font-size: 30px; } p#address { padding-top: 10px; } #title { display: none; } + #title a { color: #000; text-decoration: none; } #logo { display: none; padding: 10px 0; margin-bottom: 10px; max-height: 250px; } #error { margin-top: 10px; } } diff --git a/public/js/calculator.coffee b/public/js/calculator.coffee index 700e9903..c90954ab 100644 --- a/public/js/calculator.coffee +++ b/public/js/calculator.coffee @@ -58,16 +58,12 @@ setup = -> g.commission or= 0 g.symbol or= 'quadrigacx' - if g.title - $('#title').html(g.title).show() - if g.logo $('#logo').attr('src', g.logo).show() - else unless g.title - $('#logo').attr('src', '/assets/img/bitcoin.png').show() + else if g.title + $('#title').html("#{g.title}").show() - $('#logo').click -> $(location).attr("href","/#{g.user}/edit") - $('#address').html("#{address} ") + $('#address').html("#{address} ") $('#symbol').html(g.symbol + " bid") $('#currency').html(g.currency) $('#unit').html(g.unit) diff --git a/public/js/setup.coffee b/public/js/setup.coffee index ce6b3963..7daf960f 100644 --- a/public/js/setup.coffee +++ b/public/js/setup.coffee @@ -80,6 +80,7 @@ $(-> $.getJSON("/#{user}.json", (data) -> $('#title').val(data.title) $('#address').val(data.address) + $('#logo').val(data.logo) $("#symbol option[value='#{data.symbol}']").attr('selected', 'selected') $('#commission').val(data.commission) $('#unit').val(data.unit) diff --git a/views/users/edit.html b/views/users/edit.html index 703ef9c0..462a6269 100644 --- a/views/users/edit.html +++ b/views/users/edit.html @@ -12,6 +12,11 @@ +
+ + +
+
diff --git a/views/users/show.html b/views/users/show.html index bbf214b4..328353b6 100644 --- a/views/users/show.html +++ b/views/users/show.html @@ -6,7 +6,7 @@

- +
@@ -37,7 +37,7 @@

Please send 0.0 to

-
+

-- cgit v1.2.3