]> git.openstreetmap.org Git - nominatim-ui.git/blobdiff - src/pages/DeletablePage.svelte
test-suite: remove httpbin HTTP calls, server is unreliable
[nominatim-ui.git] / src / pages / DeletablePage.svelte
index 247c4c4965a63c6c7dd731571ae9c5c07a5d7bb7..6bc80ce98d34c32b671475c4c79ef2b6092833a6 100644 (file)
@@ -1,12 +1,15 @@
 <script>
   import { onMount } from 'svelte';
   import { fetch_from_api, update_html_title } from '../lib/api_utils.js';
-  import { detailsURL, osmLink } from '../lib/helpers.js';
+  import { osmLink } from '../lib/helpers.js';
+
+  import Header from '../components/Header.svelte';
+  import DetailsLink from '../components/DetailsLink.svelte';
 
   let aPolygons = [];
 
   function loaddata() {
-    fetch_from_api('deletable', {format: 'json'}, function(data){
+    fetch_from_api('deletable', { format: 'json' }, function (data) {
       aPolygons = data;
     });
     update_html_title('Deletable objects');
@@ -14,6 +17,7 @@
   onMount(loaddata);
 </script>
 
+<Header/>
 <div class="container">
   <div class="row">
     <div class="col-sm-12">
@@ -36,7 +40,7 @@
         <tbody>
           {#each aPolygons as polygon}
           <tr>
-            <td><a href="{detailsURL(polygon)}">{polygon.place_id}</a></td>
+            <td><DetailsLink feature={polygon}>{polygon.place_id}</DetailsLink></td>
             <td>{polygon.country_code}</td>
             <td>{polygon.name}</td>
             <td>{@html osmLink(polygon)}</td>