]> git.openstreetmap.org Git - nominatim-ui.git/commitdiff
add a button to display keywords on the details page
authorSarah Hoffmann <lonvia@denofr.de>
Wed, 2 Dec 2020 14:49:14 +0000 (15:49 +0100)
committermtmail <mtmail@gmx.net>
Wed, 2 Dec 2020 16:43:14 +0000 (17:43 +0100)
dist/deletable.html
dist/details.html
dist/polygons.html
dist/reverse.html
dist/search.html
src/templates/detailspage.hbs

index 16ebbc2415f9561f52f82ba771669aaf214a5aa5..d110cb3c5782342af1c11364c33fe2a41d464155 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}
index 16ebbc2415f9561f52f82ba771669aaf214a5aa5..d110cb3c5782342af1c11364c33fe2a41d464155 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}
index 16ebbc2415f9561f52f82ba771669aaf214a5aa5..d110cb3c5782342af1c11364c33fe2a41d464155 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}
index 16ebbc2415f9561f52f82ba771669aaf214a5aa5..d110cb3c5782342af1c11364c33fe2a41d464155 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}
index 16ebbc2415f9561f52f82ba771669aaf214a5aa5..d110cb3c5782342af1c11364c33fe2a41d464155 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}
index 85ad950f2ff862c918927cc7fb01e06479fd7010..d572eaa1320497f26490e6e3131eefbe462534f1 100644 (file)
             {{/each}}
           {{/if}}
 
+          {{> partial_h2 'Keywords'}}
           {{#if aPlace.keywords}}
-            {{> partial_h2 'Name Keywords'}}
+            {{> partial_h3 'Name Keywords'}}
             {{#each aPlace.keywords.name}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
 
-            {{> partial_h2 'Address Keywords'}}
+            {{> partial_h3 'Address Keywords'}}
             {{#each aPlace.keywords.address}}
               {{> partial_details_keyword_one_row}}
             {{/each}}
+          {{else}}
+            <tr>
+              <td>
+                <a class="btn btn-outline-secondary btn-sm"
+                  href="{{base_url}}&keywords=1">display keywords</a>
+              </td>
+            </tr>
           {{/if}}
 
           {{> partial_h2 'Parent Of'}}