From 39a01809fc02cc7002b313b6b1658aae1e2d0a42 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 26 Nov 2012 23:22:53 -0800 Subject: Static pages --- app.coffee | 8 +++ public/css/calculator.less | 35 ++++++++--- public/css/common.less | 13 ---- public/css/index.less | 1 + public/js/index.coffee | 29 --------- public/js/setup.coffee | 29 +++++++++ views/about.html | 151 +++++++++++++++++++++++++++++++++++++++++++++ views/index.html | 75 +++++++++++++--------- views/login.html | 2 +- views/setup.html | 43 +++++++++++++ 10 files changed, 304 insertions(+), 82 deletions(-) delete mode 100644 public/css/common.less create mode 100644 public/css/index.less delete mode 100644 public/js/index.coffee create mode 100644 public/js/setup.coffee create mode 100644 views/about.html create mode 100644 views/setup.html diff --git a/app.coffee b/app.coffee index 1dca452b..518831f4 100644 --- a/app.coffee +++ b/app.coffee @@ -45,6 +45,14 @@ app.get('/', (req, res) -> res.render('index', js: (-> global.js), css: (-> global.css)) ) +app.get('/setup', (req, res) -> + res.render('setup', js: (-> global.js), css: (-> global.css)) +) + +app.get('/about', (req, res) -> + res.render('about', js: (-> global.js), css: (-> global.css)) +) + app.get('/bcrypt', (req, res) -> salt = "$2a$10$3R8tUtIoU/fllQD9zEgTZe" hash = bcrypt.hashSync("chelsea", salt) diff --git a/public/css/calculator.less b/public/css/calculator.less index bdacbd0c..203205f8 100644 --- a/public/css/calculator.less +++ b/public/css/calculator.less @@ -1,11 +1,26 @@ -@import "common"; +@import "bootstrap.min.css"; +@import "bootstrap-responsive.min.css"; -p, span, input[type="text"] { font-size: 1.4em; } -input[type="text"] { height: 1.4em; } -#exchange, #amount { width: 5em; } -span.btn { font-size: 1.4em; width: 80%; } -small, label { color: #999; font-size: 1.2em; } -strong#total { font-size: 2em; } -#title { display: none; } -#logo { display: none; padding: 10px 0; } -#error { margin-top: 10px; } +body { text-align: center; } +body { font-size: 100%; line-height: 100%; } +h1 { width: 100%; } + +div.container-fluid { + width: 600px; + margin-left: auto; + margin-right: auto; + text-align:left; +} + + +div#calculator { + p, span, input[type="text"] { font-size: 1.4em; } + input[type="text"] { height: 1.4em; } + #exchange, #amount { width: 5em; } + span.btn { font-size: 1.4em; width: 80%; } + small, label { color: #999; font-size: 1.2em; } + strong#total { font-size: 2em; } + #title { display: none; } + #logo { display: none; padding: 10px 0; } + #error { margin-top: 10px; } +} diff --git a/public/css/common.less b/public/css/common.less deleted file mode 100644 index 05af2492..00000000 --- a/public/css/common.less +++ /dev/null @@ -1,13 +0,0 @@ -@import "/css/bootstrap.min.css"; -@import "/css/bootstrap-responsive.min.css"; - -body { text-align: center; } -body { font-size: 100%; line-height: 100%; } -h1 { width: 100%; } - -div.container-fluid { - width: 600px; - margin-left: auto; - margin-right: auto; - text-align:left; -} diff --git a/public/css/index.less b/public/css/index.less new file mode 100644 index 00000000..ba828bf5 --- /dev/null +++ b/public/css/index.less @@ -0,0 +1 @@ +@import "bootstrap.min.css"; diff --git a/public/js/index.coffee b/public/js/index.coffee deleted file mode 100644 index d53a4e48..00000000 --- a/public/js/index.coffee +++ /dev/null @@ -1,29 +0,0 @@ -#= require jquery-1.8.2.min.js -#= require 2.5.3-crypto-sha256.js -#= require jsbn.js -#= require jsbn2.js -#= require check_address.js - -$(-> - symbols = ['mtgoxUSD', 'btceUSD', 'bitstampUSD', 'virwoxSLL', 'btcdeEUR', 'mtgoxEUR', 'btc24EUR', 'mtgoxAUD', 'cryptoxAUD', 'mtgoxGBP', 'btcnCNY', 'intrsngEUR', 'virtexCAD', 'mtgoxPLN', 'cbxUSD', 'bitcurexPLN', 'bitmarketEUR', 'bitfloorUSD', 'mrcdBRL', 'bcEUR'] - - $.each(symbols, (i, v) -> - $('#symbol').append("") - ) - - $('#address').change(-> - if check_address($(this).val()) - $(this).css('color', 'black') - else - $(this).css('color', 'red') - ) - - if $('#login').val() != "" - $.getJSON('/' + $('#login').val() + '.json', (data) -> - $('#name').val(data.name) - $('#image').val(data.image) - $('#address').val(data.address) - $('#symbol option[value=' + data.symbol + ']').attr('selected', 'selected') - $('#commission').val(data.commission) - ) -) diff --git a/public/js/setup.coffee b/public/js/setup.coffee new file mode 100644 index 00000000..d53a4e48 --- /dev/null +++ b/public/js/setup.coffee @@ -0,0 +1,29 @@ +#= require jquery-1.8.2.min.js +#= require 2.5.3-crypto-sha256.js +#= require jsbn.js +#= require jsbn2.js +#= require check_address.js + +$(-> + symbols = ['mtgoxUSD', 'btceUSD', 'bitstampUSD', 'virwoxSLL', 'btcdeEUR', 'mtgoxEUR', 'btc24EUR', 'mtgoxAUD', 'cryptoxAUD', 'mtgoxGBP', 'btcnCNY', 'intrsngEUR', 'virtexCAD', 'mtgoxPLN', 'cbxUSD', 'bitcurexPLN', 'bitmarketEUR', 'bitfloorUSD', 'mrcdBRL', 'bcEUR'] + + $.each(symbols, (i, v) -> + $('#symbol').append("") + ) + + $('#address').change(-> + if check_address($(this).val()) + $(this).css('color', 'black') + else + $(this).css('color', 'red') + ) + + if $('#login').val() != "" + $.getJSON('/' + $('#login').val() + '.json', (data) -> + $('#name').val(data.name) + $('#image').val(data.image) + $('#address').val(data.address) + $('#symbol option[value=' + data.symbol + ']').attr('selected', 'selected') + $('#commission').val(data.commission) + ) +) diff --git a/views/about.html b/views/about.html new file mode 100644 index 00000000..592bd917 --- /dev/null +++ b/views/about.html @@ -0,0 +1,151 @@ + + + + + + Vancouver Bitcoin + + {{#css}}index{{/css}} + + + + +
+ +
+
+
+

What are bitcoins?

+ Bitcoins are units of digital currency that can be + transferred over the Internet. They get stored at a + unique address which is like an online wallet or + bank account that you can access with a + password. Registering a new address is free and + is as easy as signing up for an email account. + Transactions between bitcoin addresses are + recorded in a public record that's published on + the Internet and keeps track of what amounts are + stored at every address. Fifty new bitcoins are + generated by a mathematical algorithm every ten + minutes and are distributed to people who + contribute computing power to the network. The + software to participate in the network is free so + anyone can run it. Over time, fewer and fewer + bitcoins will be created until there are a total of + 21 million of them by the year 2040. Each bitcoin + is divisible up to 8 decimal places, making + it possible to transact tiny amounts. +
+
+

Why use them?

+ They're free, fast, secure, and global. Merchants + don't get charged for accepting them and you don't + get charged for transferring them, even + internationally. There are no fees, prerequisites, or + limits. You can register addresses anonymously and + create as many accounts as you like. They can + never be frozen because no central authority + controls them. Whether you're sending a fraction of + a cent or a million dollars, the network doesn't + discriminate. You can use bitcoins to securely store + and backup your savings and gain access to them + from anywhere that has Internet. Bitcoins tend to + appreciate in value over time because of their + limited supply so they make a good investment. + Unlike dollars and other national currencies, no + government or issuing authority can print more of + them. +
+
+ + +
+
+

What can I buy with them?

+ The number of companies accepting bitcoins is + growing quickly but their immediate utility still isn't + so much as a VISA/Mastercard/Debit competitor for + retail commerce but as an alternative to Western + Union, PayPal and the Big Banks as a means of + transferring value. They enable you to send free, + immediate payments to your friends and family + from a phone or laptop so you can pay a co-worker + back for coffee, transfer wages to family overseas, + or donate to organizations like WikiLeaks who have + been cut off by the major payment companies. + We're working to get more stores accepting them in + Vancouver though because we believe it'll be in + their best interest to avoid the transaction fees + charged by the credit card companies. Transaction + fees end up getting built into the prices we pay for + goods and services across the board so we're all + subsidizing the big banks and credit card + companies indirectly whether we use their services + or not. +
+ +
+

How is their price set?

+ Most merchants accepting bitcoin will use an + exchange rate from one of the online markets + like cavirtex.com to determine their equivalent + dollar value. The exchange rate is simply the last + price that some seller was able to charge some + buyer for bitcoins in the free market and is + governed by supply and demand. + Bitcoins aren't backed by any underlying + commodity or insured by any authority. They + have an intrinsic value however as a superior + form of currency due to their mathematically + guaranteed scarcity, security, ease of use, + distributed nature, lack of fees, divisibility, and + global recognition. + At vanbtc.ca we offer to pay cash to local + merchants in exchange for bitcoins they receive + as payment. We also offer to sell bitcoins for cash + in person at various locations. We peg our rates + to cavirtex.com and don't take any commission. +
+
+ +
+
+

Where can I get some?

+ Sign up for a free account at blockchain.info/wallet and find someone who will send you some in + exchange for goods, services, or cash. Local merchants and enthusiasts in Vancouver can be found at + vanbtc.ca. There are also several bitcoin exchange markets operating online. The largest one in Canada + is cavirtex.com and is run out of Calgary. They link up buyers and sellers and facilitate trades by + allowing you to deposit and withdraw Canadian dollars directly from your bank account. A list of other + online exchanges and their rates can be found at bitcoincharts.comvanbtc.ca +
+ +
+

Where can I learn more?

+

+ Check out vanbtc.ca and get a wallet at blockchain.info. Come to our monthly meetup group + (meetup.com/bitcoinvan) or send me an email at asoltys@gmail.com. I'm a local software + developer and I've made a bitcoin payment app that's running in stores around town. I'd be happy to + send you some bitcoins and teach you more about them. +

+
+
+ +
+ +
+

© VanBTC 2012

+
+
+ + diff --git a/views/index.html b/views/index.html index fa2cd0c3..d6fac3d8 100644 --- a/views/index.html +++ b/views/index.html @@ -3,41 +3,58 @@ - Bitcoin Payment Calculator + Vancouver Bitcoin - {{#css}}common{{/css}} - {{#js}}index{{/js}} + {{#css}}index{{/css}} -
-
-

Calculator Setup

- - - - - - - - - - - - + - - +
+
+
+
+

Vancouver Bitcoin

+

Bitcoins are units of digital currency that can be transferred over the Internet. We are a community of merchants, exchangers, and enthusiasts in Vancouver, British Columbia who are passionate about this technology.

+

Learn more »

+
+
+
+

Learn

+

Are you new to bitcoins? Find out all about them here. We'll explain why you might want to use them and point you to some useful resources.

+

View details »

+
+
+

Spend

+

You can spend your bitcoins in town to support local merchants. Want to accept bitcoins in your store? Check out our Point of Sale application.

+

View details »

+
+
+

Exchange

+

Looking to buy or sell bitcoins in town? Our network of local, accredited exchangers are trained to give you a fair price and a professional experience.

+

View details »

+
+
+ +
+
- - - - - +
-
- - +
+

© VanBTC 2012

+
diff --git a/views/login.html b/views/login.html index f451db39..613762e9 100644 --- a/views/login.html +++ b/views/login.html @@ -5,7 +5,7 @@ Bitcoin Payment Calculator - {{#css}}common{{/css}} + {{#css}}calculator{{/css}}
diff --git a/views/setup.html b/views/setup.html new file mode 100644 index 00000000..72fbd944 --- /dev/null +++ b/views/setup.html @@ -0,0 +1,43 @@ + + + + + + Bitcoin Payment Calculator + + {{#css}}calculator{{/css}} + {{#js}}setup{{/js}} + + +
+
+

Calculator Setup

+ + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ + -- cgit v1.2.3