# CHANGES
-* version 3.0.4 - 2021-03-12
+* version 3.0.5 - 2021-04-14
+
+ * Details page: better indicate places having no name, thanks darkshredder
+ * Last updated: avoid race conditions, make less API requests
+
+* version 3.0.4 - 2021-04-12
* Search page: when clicking to reverse page keep the map position
* Search page: automatically switch to structured form when URL contains structured fields
{
"name": "nominatim-ui",
"description": "Debug web interface for Nominatim geocoder",
- "version": "3.0.4",
+ "version": "3.0.5",
"license": "GPL-2.0",
"scripts": {
"build": "rollup -c",
.notused {
color:#ddd;
}
- .noname{
- color:#800;
- }
td {
padding: 2px 8px;
let last_updated_date;
let last_api_request_url;
+ let fetch_running = false; // prevent multiple parallel fetch runs
last_api_request_url_store.subscribe(url => {
+ if (fetch_running || last_updated_date) return;
+
+ fetch_running = true;
+
last_api_request_url = url;
fetch_from_api('status', { format: 'json' }, function (data) {
last_updated_date = data.data_updated;
+ fetch_running = false;
});
});
</script>
import {
osmLink, wikipediaLink, coverageType, isAdminBoundary,
- formatAddressRank, formatKeywordToken
+ formatAddressRank, formatKeywordToken, formatOSMType
} from '../lib/helpers.js';
import Header from '../components/Header.svelte';
import MapIcon from '../components/MapIcon.svelte';
<div class="row">
<div class="col-sm-10">
<h1>
- {aPlace.localname}
+ {aPlace.localname || `${formatOSMType(aPlace.osm_type)} ${aPlace.osm_id}` }
<small><DetailsLink feature={aPlace}>link to this page</DetailsLink></small>
</h1>
</div>
<div class="col-md-6">
<table id="locationdetails" class="table table-striped table-responsive">
<tbody>
- <InfoRow title="Name"><InfoRowList items={aPlace.names} /></InfoRow>
+ <InfoRow title="Name">
+ {#if (Array.isArray(aPlace.names)) }
+ <span class="noname font-weight-bold">No Name</span>
+ {:else}
+ <InfoRowList items={aPlace.names} />
+ {/if}
+ </InfoRow>
<InfoRow title="Type">{aPlace.category}:{aPlace.type}</InfoRow>
<InfoRow title="Last Updated">{aPlace.indexed_date}</InfoRow>
{#if (isAdminBoundary(aPlace)) }
border-top: none !important;
padding-left: 0 !important;
}
+ :global(span.noname){
+ color:#800;
+ }
#map-wrapper {
width:100%;
estree-walker "^0.6.1"
rollup@^2.3.4:
- version "2.45.1"
- resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.45.1.tgz#eae2b94dc2088b4e0a3b7197a5a1ee0bdd589d5c"
- integrity sha512-vPD+JoDj3CY8k6m1bLcAFttXMe78P4CMxoau0iLVS60+S9kLsv2379xaGy4NgYWu+h2WTlucpoLPAoUoixFBag==
+ version "2.45.2"
+ resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.45.2.tgz#8fb85917c9f35605720e92328f3ccbfba6f78b48"
+ integrity sha512-kRRU7wXzFHUzBIv0GfoFFIN3m9oteY4uAsKllIpQDId5cfnkWF2J130l+27dzDju0E6MScKiV0ZM5Bw8m4blYQ==
optionalDependencies:
fsevents "~2.3.1"
integrity sha512-TRF30F4W4+d+Jr2KzUUL1j8Mrpns/WM/WacxYlo5MMb2E5Qy2Pk1Guj6GylxsW9OnKQl1tnF8q3hG/hQ3h6VUA==
table@^6.0.4:
- version "6.0.9"
- resolved "https://registry.yarnpkg.com/table/-/table-6.0.9.tgz#790a12bf1e09b87b30e60419bafd6a1fd85536fb"
- integrity sha512-F3cLs9a3hL1Z7N4+EkSscsel3z55XT950AvB05bwayrNg5T1/gykXtigioTAjbltvbMSJvvhFCbnf6mX+ntnJQ==
+ version "6.1.0"
+ resolved "https://registry.yarnpkg.com/table/-/table-6.1.0.tgz#676a0cfb206008b59e783fcd94ef8ba7d67d966c"
+ integrity sha512-T4G5KMmqIk6X87gLKWyU5exPpTjLjY5KyrFWaIjv3SvgaIUGXV7UEzGEnZJdTA38/yUS6f9PlKezQ0bYXG3iIQ==
dependencies:
ajv "^8.0.1"
is-boolean-object "^1.1.0"