public
Created

Carto stylesheet for our census map

  • Download Gist
popluation-change.mss
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117
/*
Our favorite new tool: http://tilemill.com/
See the results here: http://media.apps.chicagotribune.com/census-2010/population-change/index.html
*/
 
@sans-bold:"Arial Bold";
 
#tracts[name = "Census Tract 9900"] {
polygon-opacity:0;
}
 
#tracts {
/* more than 100%, default */
polygon-fill: #4A1486;
polygon-opacity: 0.75;
}
 
#tracts[popchgpct < 1.0] {
polygon-fill: #6A51A3;
}
 
#tracts[popchgpct < 0.50] {
polygon-fill: #807DBA;
}
 
#tracts[popchgpct < 0.25] {
polygon-fill: #9E9AC8;
}
 
#tracts[popchgpct < 0.10] {
polygon-fill: #BCBDDC;
}
 
#tracts[popchgpct < 0.05] {
polygon-fill: #DADAEB;
}
 
#tracts[popchgpct = 0] {
polygon-fill: #F7F7F7;
}
 
#tracts[popchgpct < 0] {
polygon-fill: #FEE0B6;
}
 
#tracts[popchgpct < -0.05] {
polygon-fill: #F1A340;
}
 
#tracts[popchgpct < -0.1] {
polygon-fill: #B35806;
}
 
#tracts[zoom >= 11] {
line-color:#ccc;
line-width: 2;
}
 
#tracts_labels [zoom > 11] {
text-name:"[label]";
text-face-name:@sans-bold;
text-fill:#fff;
#tracts_labels[zoom = 12] {
text-size:2;
text-line-spacing:0;
#tracts_labels[totsqmi > 3] {
text-size:10;
text-line-spacing:6;
}
#tracts_labels[totsqmi > 2] {
text-size:6;
text-line-spacing:3;
}
}
 
#tracts_labels[zoom = 13] {
text-size:4;
text-line-spacing:2;
#tracts_labels[totsqmi > 3] {
text-size:10;
text-line-spacing:6;
}
#tracts_labels[totsqmi > 2] {
text-size:12;
text-line-spacing:7;
}
}
 
#tracts_labels[zoom = 14] {
text-size:10;
text-line-spacing:4;
#tracts_labels[totsqmi > 3] {
text-size:12;
text-line-spacing:7;
}
#tracts_labels[totsqmi > 2] {
text-size:14;
text-line-spacing:8;
}
}
 
#tracts_labels[zoom > 14] {
text-size:14;
text-line-spacing:6;
text-halo-radius:1;
text-halo-fill:rgba(0,0,0,1);
}
 
#tracts_labels[zoom > 15] {
text-size:16;
text-line-spacing:8;
}
}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.