Permalink
Browse files

Merge branch 'gh-pages' of github.com:mapbox/weekend-picks-template i…

…nto gh-pages
  • Loading branch information...
2 parents faa43eb + dad888e commit f24fef449e638c64fbe3892a87f881370d1b66d0 Will White committed Jun 15, 2012
Showing with 14 additions and 23 deletions.
  1. +4 −3 markers.js
  2. +10 −20 style.css
View
@@ -22,7 +22,9 @@ picks.start = function(url) {
var all = document.getElementById('null');
all.onclick = function() {
if (picks.selected) {
+ // Deselect other button
document.getElementById(picks.selected).className = 'markerfilter';
+ // Select all button
all.className = 'markerfilter selected';
picks.selected = null;
picks.show(picks.selected);
@@ -33,9 +35,8 @@ picks.start = function(url) {
var container = document.getElementById('about');
_.each(picks.symbols, function(s) {
- var img = document.createElement('div');
- img.style.backgroundImage = 'url(http://a.tiles.mapbox.com/v3/marker/pin-l-'+s+'+000000.png)';
- img.className = 'inner';
+ img = document.createElement('img');
+ img.src = 'http://a.tiles.mapbox.com/v3/marker/pin-l-'+s+'+000000.png';
var div = document.createElement('div');
div.className = 'markerfilter';
View
@@ -402,41 +402,31 @@ a.zoomer {
@-o-keyframes fade-in { from { opacity:0; } to { opacity:1; } }
+/* Filter button styles */
.markerfilter {
+ font-size: 18px;
+ text-align: center;
+ font-weight: bold;
margin: 5px;
padding: 10px;
- height: 24px;
width: 35px;
height: 35px;
- display: inline-block;
background: black;
color: white;
+ overflow: hidden;
+ display: block;
+ float: left;
}
-.symbolfilter {
- margin: 5px;
- padding: 10px;
- background:#eee;
+.markerfilter:hover {
+ background: white;
+ cursor: pointer;
}
.selected {
background: white;
color: black;
}
-.symbolfilter:hover {
- background: #bbb;
- cursor: pointer;
-}
-
-.selected:hover {
- background: #fff;
-}
-
-.inner {
- width: 34px;
- height: 44px;
-}
-
strong { font-weight:bold; }

0 comments on commit f24fef4

Please sign in to comment.