X-Git-Url: https://git.openstreetmap.org./nominatim-ui.git/blobdiff_plain/f2633dcc2939466943d2257439c12775fb712a11..a6e3425fd49331782c847b18668ad12ee5984d08:/src/pages/DetailsPage.svelte

diff --git a/src/pages/DetailsPage.svelte b/src/pages/DetailsPage.svelte
index bbf2bf5..500c5c3 100644
--- a/src/pages/DetailsPage.svelte
+++ b/src/pages/DetailsPage.svelte
@@ -16,7 +16,7 @@
   import Map from '../components/Map.svelte';
 
   let aPlace;
-  let base_url = window.location.search;
+  let base_url;
   let api_request_params;
   let api_request_finished = false;
 
@@ -57,6 +57,7 @@
     let pageinfo = $page;
     if (pageinfo.tab === 'details') {
       loaddata(pageinfo.params);
+      base_url = window.location.search;
     }
   }
 </script>
@@ -80,7 +81,7 @@
     </div>
     <div class="row">
       <div class="col-md-6">
-        <table id="locationdetails" class="table table-striped">
+        <table id="locationdetails" class="table table-striped table-responsive">
           <tbody>
             <InfoRow title="Name"><InfoRowList items={aPlace.names} /></InfoRow>
             <InfoRow title="Type">{aPlace.category}:{aPlace.type}</InfoRow>
@@ -138,14 +139,14 @@
           <tbody>
             {#if aPlace.address}
               {#each aPlace.address as addressLine}
-                <DetailsOneRow addressLine={addressLine} bDistanceInMeters=false />
+                <DetailsOneRow addressLine={addressLine} bMarkUnusedLines=true bDistanceInMeters=false />
               {/each}
             {/if}
 
             {#if aPlace.linked_places}
               <tr class="all-columns"><td colspan="6"><h2>Linked Places</h2></td></tr>
               {#each aPlace.linked_places as addressLine}
-                <DetailsOneRow addressLine={addressLine} bDistanceInMeters=true />
+                <DetailsOneRow addressLine={addressLine} bMarkUnusedLines=true bDistanceInMeters=true />
               {/each}
             {/if}
 
@@ -161,15 +162,17 @@
                 </tr>
               {/each}
 
-              <tr class="all-columns"><td colspan="6"><h3>Address Keywords</h3></td></tr>
-              {#each aPlace.keywords.address as keyword}
-                <tr>
-                  <td>{formatKeywordToken(keyword.token)}</td>
-                  {#if keyword.id}
-                    <td>word id: {keyword.id}</td>
-                  {/if}
-              </tr>
-              {/each}
+              {#if aPlace.keywords.address}
+                <tr class="all-columns"><td colspan="6"><h3>Address Keywords</h3></td></tr>
+                {#each aPlace.keywords.address as keyword}
+                  <tr>
+                    <td>{formatKeywordToken(keyword.token)}</td>
+                    {#if keyword.id}
+                      <td>word id: {keyword.id}</td>
+                    {/if}
+                  </tr>
+                {/each}
+              {/if}
             {:else}
               <tr>
                 <td>
@@ -241,9 +244,6 @@
     padding-left: 0 !important;
   }
 
-  .table {
-    width: 100%;
-  }
   #map-wrapper {
     width:100%;
     min-height: auto;
