]> git.openstreetmap.org Git - nominatim-ui.git/commitdiff
on status page allow admins to set a custom HTML message (#317)
authormtmail <mtmail@gmx.net>
Sun, 30 Nov 2025 22:00:02 +0000 (23:00 +0100)
committerGitHub <noreply@github.com>
Sun, 30 Nov 2025 22:00:02 +0000 (23:00 +0100)
dist/theme/status-help.html [new file with mode: 0644]
src/pages/StatusPage.svelte

diff --git a/dist/theme/status-help.html b/dist/theme/status-help.html
new file mode 100644 (file)
index 0000000..ade782d
--- /dev/null
@@ -0,0 +1,7 @@
+<!--
+<div class="p-4">
+  The Nominatim service is run by administrator@example.com.
+
+  If you see connection failures first check <a href="http://example.com/status">the status page</a>.
+</div>
+ -->
\ No newline at end of file
index c5d2d65e053b33199d106697d6037623721c3aac..3588be55f34b0ae3f7f0b8e73216dc78f55f7280 100644 (file)
@@ -1,6 +1,6 @@
 <script>
   import { onMount } from 'svelte';
-  import { update_html_title } from '../lib/api_utils.js';
+  import { update_html_title, fetch_content_into_element } from '../lib/api_utils.js';
   import { appState } from '../state/AppState.svelte.js';
 
   import Header from '../components/Header.svelte';
     update_html_title('Server status');
   }
   onMount(loaddata);
+
+  onMount(() => {
+    fetch_content_into_element('theme/status-help.html', document.getElementById('status-help'));
+  });
 </script>
 
 <Header/>
@@ -27,6 +31,8 @@
     <div class="col-sm-12">
       <h1>Server status</h1>
 
+      <div id="status-help" class="bg-secondary-subtle"></div>
+
       <dl>
         <dt>API Endpoint</dt>
         <dd><a href={endpoint_url}>{endpoint_url}</a></dd>
@@ -43,3 +49,9 @@
     </div>
   </div>
 </div>
+
+<style>
+  #status-help {
+    margin: 2em 0;
+  }
+</style>
\ No newline at end of file