diff --git a/app/assets/stylesheets/map/map.css.scss b/app/assets/stylesheets/map/map.css.scss
index d0bb71e4ece7..e80876147421 100644
--- a/app/assets/stylesheets/map/map.css.scss
+++ b/app/assets/stylesheets/map/map.css.scss
@@ -125,7 +125,7 @@ div.map {
div.dropdown.basemap {
- width: 648px;
+ width: 861px;
border: 1px solid #999999;
.custom {
@@ -154,6 +154,17 @@ div.map {
&:hover { background: none; }
+ &.add_basemap > a {
+ small, &:hover small {
+ color: #397DB8;
+ @include opacity(.5);
+ }
+ }
+
+ &.map_background > a .name {
+ margin: 5px 0 0 5px;
+ }
+
& > a {
display:block;
padding: 11px 10px 11px 0;
@@ -161,11 +172,17 @@ div.map {
line-height: normal;
@include clearfix();
+ small { display:block; margin: 0 0 0 29px; font-size: 9px; color: #AAAAAA; }
+
+ &:hover small {
+ color: #AAAAAA;
+ }
+
.name {
float:left;
font-size:13px;
width: 150px;
- margin: 5px 0 0 5px;
+ margin: 0 0 0 5px;
text-overflow:ellipsis;
white-space: nowrap;
diff --git a/config/custom_basemaps/basemap-dark.json b/config/custom_basemaps/basemap-dark.json
new file mode 100644
index 000000000000..05069b845ecd
--- /dev/null
+++ b/config/custom_basemaps/basemap-dark.json
@@ -0,0 +1 @@
+{"id":"88826ca6-3d56-11e3-bbff-0f80769a2491","version":"0.1.0","title":"dark","description":null,"url":null,"map_provider":"leaflet","bounds":[[25.64152637306577,-109.423828125],[45.67548217560647,-53.876953125]],"center":"[36.29741818650811, -81.650390625]","zoom":5,"updated_at":"2013-11-04T14:06:12+00:00","layers":[{"options":{"type":"Plain","base_type":"plain","className":"plain","color":"#111111","image":"","maxZoom":28,"id":516421,"order":0},"infowindow":null,"id":516421,"order":0,"type":"background"},{"type":"layergroup","options":{"user_name":"basemaps01","tiler_protocol":"http","tiler_domain":"cartodb.com","tiler_port":"80","sql_api_protocol":"https","sql_api_domain":"cartodb.com","sql_api_endpoint":"/api/v1/sql","sql_api_port":443,"cdn_url":{"http":"api.cartocdn.com","https":"cartocdn.global.ssl.fastly.net"},"layer_definition":{"stat_tag":"88826ca6-3d56-11e3-bbff-0f80769a2491","version":"1.0.1","layers":[{"id":516446,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"
\n"},"legend":{"type":null,"show_title":false,"title":""},"order":1,"options":{"sql":"select * from bkgpolygon","layer_name":"background","cartocss":"/** simple visualization */\n\n#bkgpolygon{\n polygon-fill: #111111;\n polygon-opacity: 1;\n line-width: 1;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516422,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":2,"options":{"sql":"select * from ne_10m_bathymetry_l_0","layer_name":"ne 10m bathymetry","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_l_0{\n polygon-fill: #111111;\n polygon-opacity: 1;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-comp-op: multiply;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516423,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":3,"options":{"sql":"select * from ne_10m_bathymetry_j_1000","layer_name":"ne_10m_bathymetry_j_1000","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_j_1000{\n polygon-fill: #FFFFFF;\n polygon-opacity: 0.01;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516424,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":4,"options":{"sql":"select * from ne_10m_bathymetry_h_3000","layer_name":"ne_10m_bathymetry_h_3000","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_h_3000{\n polygon-fill: #FFFFFF;\n polygon-opacity: 0.01;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516425,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":5,"options":{"sql":"select * from ne_10m_admin_0_countries_lakes","layer_name":"ne_10m_admin_0_countries_lakes","cartocss":"#ne_10m_admin_0_countries_lakes{\n polygon-fill: #222;\n polygon-opacity: 1;\n line-width: 0.7;\n line-color: #070707;\n line-opacity: 1;\n\n [zoom >=1]{\n line-width: 0.3; \t\n }\n \n [zoom >= 4]{\n\t::glow{\n\t line-width: 3.2;\n\t line-color:#fff;\n line-opacity: 0.03;\n ::line{\n line-color: #070707;\n\t line-width: 1.2;\n \t }\n }\n }\n \n [zoom >= 5]{\n\t::glow{\n\t line-width: 4;\n\t line-color:#fff;\n line-opacity: 0.03;\n ::line{\n line-color: #070707;\n\t line-width: 1.6;\n \t }\n }\n }\n \n [zoom >= 6]{\n ::glow{\n\t line-width: 4;\n\t line-color:#ffffff;\n line-opacity: 0.03;\n ::line{\n line-color: #070707;\n\t line-width: 1.8;\n \t }\n }\n }\n\n [zoom >= 7]{\n ::glow{\n\t line-width: 4;\n\t line-color:#ffffff;\n line-opacity: 0.04;\n ::line{\n line-color: #070707;\n\t line-width: 2;\n \t }\n }\n }\n \n [zoom >= 8]{\n ::glow{\n\t line-width: 5.4;\n\t line-color:#ffffff;\n line-opacity: 0.04; \n ::line{\n line-color: #070707;\n\t line-width: 3;\n \t }\n }\n }\n}\n\n#ne_10m_admin_0_countries_lakes::labels{\n [zoom <= 5]{\n text-name: [name];\n text-face-name: 'DejaVu Sans Book';\n text-size: 10;\n text-fill: #666;\n text-allow-overlap: false;\n text-halo-fill: #111;\n text-halo-radius: 1.3;\n text-min-path-length: 26;\n [zoom = 5]{\n \t text-size: 12; \n }\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516426,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":6,"options":{"sql":"select * from ne_10m_urban_areas","layer_name":"ne_10m_urban_areas","cartocss":"/** simple visualization */\n\n#ne_10m_urban_areas{\n [zoom >= 5]{\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-opacity: 0;\n polygon-comp-op: multiply;\n polygon-pattern-file: url(https://s3.amazonaws.com/com.cartodb.users-assets.production/production/basemaps01/assets/20131016101601Unknown.png); \n polygon-pattern-opacity: 0.8;\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516427,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":7,"options":{"sql":"select * from ne_10m_rivers_lake_centerlines","layer_name":"ne_10m_rivers_lake_centerlines","cartocss":"/** simple visualization */\n\n#ne_10m_rivers_lake_centerlines{\n [zoom >= 7]{\n ::glow{\n line-width: .8;\n line-color: #fff;\n line-opacity: 0.02; \n }\n ::line{\n line-width: 0.7;\n line-color: #070707;\n line-opacity: 0.6; \n }\n }\n [zoom >= 8]{\n ::glow{\n line-width: 2;\n line-color: #fff;\n line-opacity: 0.02; \n }\n ::line{\n line-width: 0.8;\n line-color: #070707;\n line-opacity: 1; \n }\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516428,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":8,"options":{"sql":"select * from ne_10m_lakes","layer_name":"ne_10m_lakes","cartocss":"/** simple visualization */\n\n#ne_10m_lakes{\n polygon-fill: #191919;\n line-opacity: 0;\n polygon-opacity: 0; \n [zoom >= 7]{\n line-opacity: 1;\n line-width: 0.6;\n line-color: #070707;\n polygon-opacity: 1;\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516429,"type":"CartoDB","infowindow":{"fields":[],"template_name":"table/views/infowindow_light","template":"\n","alternative_names":{}},"legend":{"type":null,"show_title":false,"title":""},"order":9,"options":{"sql":"SELECT * FROM ne_10m_roads WHERE type IN ('Unknown','Road','Major Highway','Secondary Highway','Ferry Route','Beltway','Track') OR type IS NULL","layer_name":"ne_10m_roads","cartocss":"/** simple visualization */\n\n#ne_10m_roads::roads{\n [zoom >= 6]{\n [type = 'Major Highway']{\n line-width: .8;\n line-color: #191919;\n }\n }\n [zoom >= 7]{\n [type = 'Major Highway']{\n line-width: 1;\n line-color: #151515;\n }\n [type = 'Secondary Highway']{\n line-width: 0.5;\n line-color: #151515;\n }\n }\n [zoom >= 8]{\n [type = 'Major Highway']{\n ::glow{\n line-width: 4;\n line-color: #fff;\n line-opacity: 0.1;\n }\n ::line{\n line-width: 2.8;\n line-color: #111; \n }\n }\n [type = 'Secondary Highway']{\n ::glow{\n line-width: 2.8;\n line-color: #fff;\n line-opacity: 0.1;\n }\n ::line{\n line-width: 2;\n line-color: #111; \n }\n }\n }\n [zoom >= 9]{\n [type = 'Major Highway']{\n ::glow{\n line-width: 4.2;\n line-color: #fff;\n line-opacity: 0.15;\n }\n ::line{\n line-width: 3.6;\n line-color: #111; \n }\n }\n [type = 'Secondary Highway']{\n ::glow{\n line-width: 3;\n line-color: #fff;\n line-opacity: 0.1;\n }\n ::line{\n line-width: 2.4;\n line-color: #111; \n }\n }\n }\n [zoom >= 10]{\n [type = 'Major Highway']{\n ::glow{\n line-width: 4.6;\n line-color: #fff;\n line-opacity: 0.1;\n }\n ::line{\n line-width: 3.2;\n line-color: #111; \n }\n }\n [type = 'Secondary Highway']{\n ::glow{\n line-width: 3.4;\n line-color: #fff;\n line-opacity: 0.1;\n }\n ::line{\n line-width: 2.4;\n line-color: #111; \n }\n }\n }\n}\n#ne_10m_roads::ferry{\n [zoom >= 7]{\n [type = 'Ferry Route']{\n line-width: 1;\n line-color: #ABABAB;\n line-dasharray: 5,5;\n line-opacity: 0.15;\n } \n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516430,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":"none","show_title":false,"title":""},"order":10,"options":{"sql":"select * from ne_10m_populated_places_simple","layer_name":"ne_10m_populated_places_simple","cartocss":"\n\n#ne_10m_populated_places_simple::labels{\n [zoom >= 6]{\n text-name: [name];\n text-face-name: 'DejaVu Sans Book';\n text-size: 12; \n text-fill: #666;\n text-allow-overlap: true;\n text-halo-fill: #070707;\n text-halo-radius: 1.3;\n [scalerank > 2]{\n text-opacity: 0;\n }\n }\n [zoom >= 7]{\n text-allow-overlap: false;\n text-min-distance: 20; \n text-halo-radius: 1.5;\n [scalerank > 2]{\n text-opacity: 1;\n text-size: 10;\n }\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}}]}}}],"overlays":[{"type":"zoom","order":null,"options":null,"template":"+-"},{"type":"loader","order":null,"options":null,"template":""}]}
\ No newline at end of file
diff --git a/config/custom_basemaps/basemap-flatblue.json b/config/custom_basemaps/basemap-flatblue.json
new file mode 100644
index 000000000000..867bf0bb3d64
--- /dev/null
+++ b/config/custom_basemaps/basemap-flatblue.json
@@ -0,0 +1 @@
+{"id":"5c0b0e62-4549-11e3-b95d-2b0f956401ef","version":"0.1.0","title":"flat blue","description":null,"url":null,"map_provider":"leaflet","bounds":[[-20.797201434307,-136.93359375],[61.438767493682825,110.91796875]],"center":"[27.449790329784214, -13.0078125]","zoom":3,"updated_at":"2013-11-04T12:43:37+00:00","layers":[{"options":{"type":"Plain","base_type":"plain","className":"plain","color":"#2c388d","image":"","maxZoom":28,"id":516449,"order":0},"infowindow":null,"id":516449,"order":0,"type":"background"},{"type":"layergroup","options":{"user_name":"basemaps01","tiler_protocol":"http","tiler_domain":"cartodb.com","tiler_port":"80","sql_api_protocol":"https","sql_api_domain":"cartodb.com","sql_api_endpoint":"/api/v1/sql","sql_api_port":443,"cdn_url":{"http":"api.cartocdn.com","https":"cartocdn.global.ssl.fastly.net"},"layer_definition":{"stat_tag":"5c0b0e62-4549-11e3-b95d-2b0f956401ef","version":"1.0.1","layers":[{"id":516450,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":1,"options":{"sql":"select * from bkgpolygon","layer_name":"bkgpolygon","cartocss":"/** simple visualization */\n\n#bkgpolygon{\n polygon-fill: #2c388d;\n polygon-opacity: 0.7;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516451,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":2,"options":{"sql":"select * from ne_10m_bathymetry_l_0","layer_name":"ne_10m_bathymetry_l_0","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_l_0{\n polygon-fill: #2c388d;\n polygon-opacity: 1;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516453,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":3,"options":{"sql":"select * from ne_10m_admin_0_countries_lakes","layer_name":"ne_10m_admin_0_countries_lakes","cartocss":"/** simple visualization */\n\n#ne_10m_admin_0_countries_lakes::shdw{\n line-color: #000;\n line-opacity: .2;\n line-width: 1; \n}\n\n#ne_10m_admin_0_countries_lakes{\n polygon-fill: #445CC7;\n polygon-opacity: 0.7;\n line-color: #2c388d;\n line-opacity: 1;\n}\n\n#ne_10m_admin_0_countries_lakes[zoom >= 1]{\n line-width: 0.5; \n}\n\n#ne_10m_admin_0_countries_lakes[zoom >= 4]{\n line-width: 0.6; \n}\n#ne_10m_admin_0_countries_lakes[zoom >= 5]{\n line-width: 0.8; \n}\n#ne_10m_admin_0_countries_lakes[zoom >= 6]{\n line-width: 1; \n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516452,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":4,"options":{"sql":"select * from ne_10m_urban_areas","layer_name":"ne_10m_urban_areas","cartocss":"/** simple visualization */\n\n#ne_10m_urban_areas{\n polygon-fill: #FF6600;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-pattern-file: url(https://s3.amazonaws.com/com.cartodb.users-assets.production/production/basemaps01/assets/20131104121605ptt.png);\n polygon-pattern-opacity: 0.2;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}}]}}}],"overlays":[{"type":"zoom","order":null,"options":null,"template":"+-"},{"type":"loader","order":null,"options":null,"template":""}]}
\ No newline at end of file
diff --git a/config/custom_basemaps/basemap-light.json b/config/custom_basemaps/basemap-light.json
new file mode 100644
index 000000000000..6d1f68242041
--- /dev/null
+++ b/config/custom_basemaps/basemap-light.json
@@ -0,0 +1 @@
+{"id":"c175c018-35cb-11e3-b403-ebf901e768c8","version":"0.1.0","title":"grey","description":null,"url":null,"map_provider":"leaflet","bounds":[[-10.487811882056683,-139.39453125],[66.16051056018838,113.73046875]],"center":"[36.527294814546245, -12.83203125]","zoom":3,"updated_at":"2013-11-04T14:06:50+00:00","layers":[{"options":{"type":"Plain","base_type":"plain","className":"plain","color":"#e0e7f2","image":"","maxZoom":28,"id":516388,"order":0},"infowindow":null,"id":516388,"order":0,"type":"background"},{"type":"layergroup","options":{"user_name":"basemaps01","tiler_protocol":"http","tiler_domain":"cartodb.com","tiler_port":"80","sql_api_protocol":"https","sql_api_domain":"cartodb.com","sql_api_endpoint":"/api/v1/sql","sql_api_port":443,"cdn_url":{"http":"api.cartocdn.com","https":"cartocdn.global.ssl.fastly.net"},"layer_definition":{"stat_tag":"c175c018-35cb-11e3-b403-ebf901e768c8","version":"1.0.1","layers":[{"id":516445,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":1,"options":{"sql":"select * from bkgpolygon","layer_name":"bkg","cartocss":"/** simple visualization */\n\n#bkgpolygon{\n polygon-fill: #e0e7f2;\n polygon-opacity: 1;\n line-width: 1;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516390,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":2,"options":{"sql":"select * from ne_10m_bathymetry_l_0","layer_name":"ne 10m bathymetry","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_l_0{\n polygon-fill: #e0e7f2;\n polygon-opacity: 1;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516394,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":3,"options":{"sql":"select * from ne_10m_bathymetry_j_1000","layer_name":"ne_10m_bathymetry_j_1000","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_j_1000{\n polygon-fill: #f1f4f8;\n polygon-opacity: 0.25;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-comp-op: multiply;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516397,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":4,"options":{"sql":"select * from ne_10m_bathymetry_h_3000","layer_name":"ne_10m_bathymetry_h_3000","cartocss":"/** simple visualization */\n\n#ne_10m_bathymetry_h_3000{\n polygon-fill: #f1f4f8;\n polygon-opacity: 0.25;\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-comp-op: multiply;\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516389,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":5,"options":{"sql":"select * from ne_10m_admin_0_countries_lakes","layer_name":"ne_10m_admin_0_countries_lakes","cartocss":"#ne_10m_admin_0_countries_lakes{\n polygon-fill: #f0f0f0;\n polygon-opacity: 1;\n line-width: 0.7;\n line-color: #ABABAB;\n line-opacity: 1;\n\n [zoom >=1]{\n line-width: 0.4; \t\n }\n \n [zoom >= 4]{\n\t::glow{\n\t line-width: 2.5;\n\t line-color:#ffffff;\n ::line{\n line-color: #ABABAB;\n\t line-width: 1;\n \t }\n }\n }\n \n [zoom >= 6]{\n ::glow{\n\t line-width: 3.2;\n\t line-color:#ffffff;\n ::line{\n line-color: #ABABAB;\n\t line-width: 1.6;\n \t }\n }\n }\n\n [zoom >= 7]{\n ::glow{\n\t line-width: 4;\n\t line-color:#ffffff;\n ::line{\n line-color: #ABABAB;\n\t line-width: 2;\n \t }\n }\n }\n \n [zoom >= 8]{\n ::glow{\n\t line-width: 4.5;\n\t line-color:#ffffff;\n ::line{\n line-color: #ABABAB;\n\t line-width: 2;\n \t }\n }\n }\n}\n\n#ne_10m_admin_0_countries_lakes::labels{\n [zoom <= 5]{\n text-name: [name];\n text-face-name: 'DejaVu Sans Book';\n text-size: 10;\n text-fill: #888;\n text-allow-overlap: false;\n text-halo-fill: #FFF;\n text-halo-radius: 1.3;\n text-min-path-length: 26;\n [zoom = 5]{\n \t text-size: 12; \n }\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516400,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":6,"options":{"sql":"select * from ne_10m_urban_areas","layer_name":"ne_10m_urban_areas","cartocss":"/** simple visualization */\n\n#ne_10m_urban_areas{\n [zoom >= 5]{\n line-width: 0;\n line-color: #FFF;\n line-opacity: 1;\n polygon-opacity: 0;\n polygon-comp-op: multiply;\n polygon-pattern-file: url(https://s3.amazonaws.com/com.cartodb.users-assets.production/production/basemaps01/assets/20131016101601Unknown.png);\n polygon-pattern-opacity: 0.3;\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516410,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":7,"options":{"sql":"select * from ne_10m_rivers_lake_centerlines","layer_name":"ne_10m_rivers_lake_centerlines","cartocss":"/** simple visualization */\n\n#ne_10m_rivers_lake_centerlines{\n [zoom >= 7]{\n ::glow{\n line-width: .8;\n line-color: #fff;\n line-opacity: 1; \n }\n ::line{\n line-width: 0.7;\n line-color: #DAE3EF;\n line-opacity: 1; \n }\n }\n [zoom >= 8]{\n ::glow{\n line-width: 3;\n line-color: #fff;\n line-opacity: 1; \n }\n ::line{\n line-width: 2;\n line-color: #DAE3EF;\n line-opacity: 1; \n }\n }\n \n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516413,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":null,"show_title":false,"title":""},"order":8,"options":{"sql":"select * from ne_10m_lakes","layer_name":"ne_10m_lakes","cartocss":"/** simple visualization */\n\n#ne_10m_lakes{\n polygon-fill: #DAE3EF;\n line-color: #fff;\n line-opacity: 0;\n polygon-opacity: 0; \n [zoom >= 7]{\n line-width: .3;\n line-opacity: 1;\n polygon-opacity: 1;\n }\n [zoom >= 8]{\n line-width: .5;\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516407,"type":"CartoDB","infowindow":{"fields":[],"template_name":"table/views/infowindow_light","template":"\n","alternative_names":{}},"legend":{"type":null,"show_title":false,"title":""},"order":9,"options":{"sql":"SELECT * FROM ne_10m_roads WHERE type IN ('Unknown','Road','Major Highway','Secondary Highway','Ferry Route','Beltway','Track') OR type IS NULL","layer_name":"ne_10m_roads","cartocss":"/** simple visualization */\n\n#ne_10m_roads::roads{\n [zoom >= 6]{\n [type = 'Major Highway']{\n line-width: .8;\n line-color: #E1E1E1;\n }\n }\n [zoom >= 7]{\n [type = 'Major Highway']{\n line-width: 1.2;\n line-color: #E1E1E1;\n }\n [type = 'Secondary Highway']{\n line-width: 0.6;\n line-color: #E1E1E1;\n }\n }\n [zoom >= 8]{\n [type = 'Major Highway']{\n ::glow{\n line-width: 3.6;\n line-color: #D7D7D7;\n }\n ::line{\n line-width: 1.8;\n line-color: #fff; \n }\n }\n [type = 'Secondary Highway']{\n ::glow{\n line-width: 2.8;\n line-color: #D7D7D7;\n }\n ::line{\n line-width: 1.4;\n line-color: #fff; \n }\n }\n }\n [zoom >= 10]{\n [type = 'Major Highway']{\n ::glow{\n line-width: 4;\n line-color: #D7D7D7;\n }\n ::line{\n line-width: 2.4;\n line-color: #fff; \n }\n }\n [type = 'Secondary Highway']{\n ::glow{\n line-width: 3.4;\n line-color: #D7D7D7;\n }\n ::line{\n line-width: 1.8;\n line-color: #fff; \n }\n }\n }\n}\n#ne_10m_roads::ferry{\n [zoom >= 7]{\n [type = 'Ferry Route']{\n line-width: 1;\n line-color: #ABABAB;\n line-dasharray: 5,5;\n line-opacity: 0.4;\n } \n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}},{"id":516403,"type":"CartoDB","infowindow":{"template_name":"table/views/infowindow_light","fields":[],"template":"\n"},"legend":{"type":"none","show_title":false,"title":""},"order":10,"options":{"sql":"select * from ne_10m_populated_places_simple","layer_name":"ne 10m populated places simple","cartocss":"\n\n#ne_10m_populated_places_simple::labels{\n [zoom >= 6]{\n text-name: [name];\n text-face-name: 'DejaVu Sans Book';\n text-size: 12;\n text-fill: #777;\n text-allow-overlap: true;\n text-halo-fill: #FFF;\n text-halo-radius: 1.3;\n [scalerank > 2]{\n text-opacity: 0;\n }\n }\n [zoom >= 7]{\n text-allow-overlap: false;\n text-min-distance: 20; \n text-halo-radius: 1.5;\n [scalerank > 2]{\n text-opacity: 1;\n text-size: 10;\n }\n }\n}","cartocss_version":"2.1.1","interactivity":"cartodb_id"}}]}}}],"overlays":[{"type":"zoom","order":null,"options":null,"template":"+-"},{"type":"loader","order":null,"options":null,"template":""}]}
\ No newline at end of file
diff --git a/lib/assets/javascripts/cartodb/common/dropdown_basemap.js b/lib/assets/javascripts/cartodb/common/dropdown_basemap.js
index 144720741a9f..b41b79a48969 100644
--- a/lib/assets/javascripts/cartodb/common/dropdown_basemap.js
+++ b/lib/assets/javascripts/cartodb/common/dropdown_basemap.js
@@ -46,7 +46,7 @@ cdb.admin.GMapsBaseView = cdb.admin.BaseLayerButton.extend({
},
render: function() {
- var $e = $(" " + this.model.get("name") + "
" );
+ var $e = $(" " + this.model.get("name") + "
Max zoom: " + this.model.get("maxZoom") + "" );
var $a = this.make("a", {"class": this.model.get('base_type') }, $e);
this.$el.html($a);
this.elder('render');
@@ -100,7 +100,7 @@ cdb.admin.BaseMapView = cdb.admin.BaseLayerButton.extend({
.replace("{x}", this.options.x)
.replace("{y}", this.options.y);
- var $e = $(" " + this.model.get("name") + "
" );
+ var $e = $(" " + this.model.get("name") + "
Max zoom: " + this.model.get("maxZoom") + "" );
var $a = $(this.make("a", { "class": this.model.get('className') }, $e));
if (!this.model.get('read_only')) {
@@ -519,7 +519,7 @@ cdb.admin.DropdownBasemap = cdb.ui.common.Dropdown.extend({
},
_addAddlink: function() {
- var $a = $(' Add yours
');
+ var $a = $(' Add yours
MapBox, WMS, TMS,...');
this._appendUserBaseLayerButton($a);
},
@@ -623,6 +623,15 @@ cdb.admin.DropdownBasemap = cdb.ui.common.Dropdown.extend({
dark_roadmap: "GMaps Dark"
},
+ maxZoom = {
+ roadmap: 21,
+ terrain: 15,
+ hybrid: 19,
+ satellite: 17,
+ gray_roadmap: 21,
+ dark_roadmap: 21
+ },
+
styles = {
roadmap: [],
terrain: [],
@@ -635,7 +644,7 @@ cdb.admin.DropdownBasemap = cdb.ui.common.Dropdown.extend({
for (var i in available) {
var layer_name = available[i];
- var base = new cdb.admin.GMapsBaseLayer({ base_type: layer_name, className: layer_name, style: styles[layer_name], name: names[layer_name] });
+ var base = new cdb.admin.GMapsBaseLayer({ base_type: layer_name, className: layer_name, style: styles[layer_name], name: names[layer_name], maxZoom: maxZoom[layer_name] });
var v = new cdb.admin.GMapsBaseView({
model: base,
diff --git a/lib/assets/javascripts/cartodb/table/default_layers.js b/lib/assets/javascripts/cartodb/table/default_layers.js
index 3c814e0d91a2..acd0bd5d88db 100644
--- a/lib/assets/javascripts/cartodb/table/default_layers.js
+++ b/lib/assets/javascripts/cartodb/table/default_layers.js
@@ -1,9 +1,26 @@
cdb.admin.DEFAULT_LAYERS = [
{
- url: 'https://maps.nlp.nokia.com/maptiler/v2/maptile/newest/normal.day/{z}/{x}/{y}/256/png8?lg=eng&token=A7tBPacePg9Mj_zghvKt9Q&app_id=KuYppsdXZznpffJsKT24',
- maxZoom: 21,
- name: 'Nokia Day',
- className: "nokia_day",
- attribution: "©2012 Nokia Terms of use"
- }
-];
+ url: 'https://maps.nlp.nokia.com/maptiler/v2/maptile/newest/normal.day/{z}/{x}/{y}/256/png8?lg=eng&token=A7tBPacePg9Mj_zghvKt9Q&app_id=KuYppsdXZznpffJsKT24',
+ maxZoom: 21,
+ name: 'Nokia Day',
+ className: "nokia_day",
+ attribution: "©2012 Nokia Terms of use"
+}, {
+ url: 'http://{s}.api.cartocdn.com/base-light/{z}/{x}/{y}.png',
+ maxZoom: 10,
+ name: 'CartoDB Light',
+ className: "light_cartodb",
+ attribution: "©2013 CartoDB Terms of use"
+}, {
+ url: 'http://{s}.api.cartocdn.com/base-dark/{z}/{x}/{y}.png',
+ maxZoom: 10,
+ name: 'CartoDB Dark',
+ className: "dark_cartodb",
+ attribution: "©2013 CartoDB Terms of use"
+}, {
+ url: 'http://{s}.api.cartocdn.com/base-flatblue/{z}/{x}/{y}.png',
+ maxZoom: 10,
+ name: 'CartoDB Flat Blue',
+ className: "flat_blue",
+ attribution: "©2013 CartoDB Terms of use"
+} ];