]> gerrit.simantics Code Review - simantics/district.git/blob - org.simantics.maps.server/server/tm2/mapbox-studio-light.tm2/roads.mss
Adding integrated tile server
[simantics/district.git] / org.simantics.maps.server / server / tm2 / mapbox-studio-light.tm2 / roads.mss
1 // dummy styles to set ordering (case below fill)
2 #transportation {
3   ::case { opacity: 1; }
4   ::fill { opacity: 1; }
5
6
7 // consistent case size
8 @case: 2;
9
10 // Road & Railway Fills //
11 #transportation[brunnel='tunnel'] { opacity: 0.5; }
12
13 #transportation[zoom<11] {
14     line-color: @road;
15     line-width: 0.5;
16   [class='motorway'] { line-width: 1;}
17 }
18
19 #transportation::fill[zoom>=11] {
20   ['mapnik::geometry_type'=2] {
21     line-color: @road;
22     line-width: 0.5;
23     [zoom>=15] { line-width: 1; } 
24     [class='path'] { line-dasharray: 2,2;}
25     [class='major_rail'],
26     [class='minor_rail'] { line-dasharray: 3,3; }
27     [class='motorway'] { 
28       [zoom>=11] { line-width: 2; }
29       [zoom>=12] { line-width: 3; }
30       [zoom>=14] { line-width: 4; }
31       [zoom>=16] { line-width: 7; }
32       [zoom>=18] { line-width: 10; }
33     }
34     [class='motorway'][ramp=1],
35     [class='trunk'], [class='primary'], [class='secondary'], [class='tertiary'] {
36       [zoom>=11] { line-width: 1; }
37       [zoom>=12] { line-width: 2; }
38       [zoom>=14] { line-width: 3; }
39       [zoom>=16] { line-width: 5; }
40       [zoom>=18] { line-width: 7; }
41     }
42     [class='minor'],
43     [class='service'] {
44       [zoom>=14] { line-width: 1; }
45       [zoom>=16] { line-width: 2; }
46       [zoom>=18] { line-width: 4; }
47     }
48     [class='service'] { line-dasharray: 4,2; }
49   }
50 }
51
52 // Casing for high-zoom roads //
53 #transportation::case[zoom>=11] {
54   ['mapnik::geometry_type'=2] {
55     line-color: @land;
56     line-width: 1;
57     [class='motorway'] { 
58       [zoom>=11] { line-width: 2 + @case; }
59       [zoom>=12] { line-width: 3 + @case; }
60       [zoom>=14] { line-width: 4 + @case; }
61       [zoom>=16] { line-width: 7 + @case; }
62       [zoom>=18] { line-width: 10 + @case; }
63     }
64     [class='motorway'][ramp=1],
65     [class='trunk'], [class='primary'], [class='secondary'], [class='tertiary'] {
66       [zoom>=11] { line-width: 1 + @case; }
67       [zoom>=12] { line-width: 2 + @case; }
68       [zoom>=14] { line-width: 3 + @case; }
69       [zoom>=16] { line-width: 5 + @case; }
70       [zoom>=18] { line-width: 7 + @case; }
71     }
72     [class='minor'],
73     [class='service'] {
74       [zoom>=14] { line-width: 1 + @case; }
75       [zoom>=16] { line-width: 2 + @case; }
76       [zoom>=18] { line-width: 4 + @case; }
77     }
78     [class='service'] { line-dasharray: 4,2; }
79   }
80 }