add a credits line for each routing service

This commit is contained in:
Dan Stowell 2014-02-23 21:56:39 +00:00
parent f383fe2793
commit acf7cf5738
6 changed files with 15 additions and 0 deletions

View file

@ -211,6 +211,8 @@ OSM.Routing=function(map,name,jqSearch) {
$('#turnbyturn').append(row);
cumulative+=step[3];
}
$('#sidebar_content').append('<p id="routing_credit">' + r.chosenEngine.creditline + '</p>');
};
r.clickTurn=function(num,latlng) {
r.popup=L.popup().setLatLng(latlng).setContent("<p>"+(num+1)+"</p>").openOn(r.map);

View file

@ -5,6 +5,7 @@
OSM.RoutingEngines.list.push({
name: "javascripts.directions.engines.cloudmade_foot",
creditline: 'Directions courtesy of <a href="http://cloudmade.com/products/routing" target="_blank">Cloudmade</a>',
draggable: false,
CM_SPRITE_MAP: {
"C": 1,

View file

@ -2,6 +2,7 @@
OSM.RoutingEngines.list.push({
name: "javascripts.directions.engines.graphhopper_bike",
creditline: 'Directions courtesy of <a href="http://graphhopper.com/routing/" target="_blank">Graphhopper</a>',
draggable: true,
_hints: {},
getRoute: function(isFinal, points) {

View file

@ -7,6 +7,7 @@
OSM.RoutingEngines.list.push({
name: "javascripts.directions.engines.mapquest_bike",
creditline: 'Directions courtesy of <a href="http://www.mapquest.com/" target="_blank">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png">',
draggable: false,
_hints: {},
MQ_SPRITE_MAP: {

View file

@ -4,6 +4,7 @@
OSM.RoutingEngines.list.push({
name: "javascripts.directions.engines.osrm_car",
creditline: 'Directions courtesy of <a href="http://project-osrm.org/" target="_blank">OSRM</a>',
draggable: true,
_hints: {},
getRoute: function(isFinal,points) {

View file

@ -1217,6 +1217,15 @@ tr.turn:hover {
}
}
/* Rules for the routing sidebar */
#sidebar_content {
#routing_credit {
text-align: center;
padding: 0.5em;
}
}
/* Rules for edit pages */
.site-edit {