]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/index.js
Merge remote-tracking branch 'upstream/pull/4977'
[rails.git] / app / assets / javascripts / index.js
index 706647ef51ff4415694c1f035cc58febaec42f6a..8ffa05c53e41ebcf88b58acd19e77f36950cf334 100644 (file)
@@ -355,6 +355,16 @@ $(document).ready(function () {
     return page;
   };
 
+  OSM.OldBrowse = function () {
+    var page = {};
+
+    page.pushstate = page.popstate = function (path) {
+      OSM.loadSidebarContent(path);
+    };
+
+    return page;
+  };
+
   var history = OSM.History(map);
 
   OSM.router = OSM.Router(map, {
@@ -369,8 +379,11 @@ $(document).ready(function () {
     "/user/:display_name/history": history,
     "/note/:id": OSM.Note(map),
     "/node/:id(/history)": OSM.Browse(map, "node"),
+    "/node/:id/history/:version": OSM.OldBrowse(),
     "/way/:id(/history)": OSM.Browse(map, "way"),
+    "/way/:id/history/:version": OSM.OldBrowse(),
     "/relation/:id(/history)": OSM.Browse(map, "relation"),
+    "/relation/:id/history/:version": OSM.OldBrowse(),
     "/changeset/:id": OSM.Changeset(map),
     "/query": OSM.Query(map)
   });