diff --git a/README.md b/README.md index 5310644..1db3c6c 100644 --- a/README.md +++ b/README.md @@ -34,16 +34,16 @@ see [https://spothole.app/apidocs](https://spothole.app/apidocs) for the API det This is a Progressive Web App, so you can also "install" it to your Android or iOS device by accessing it in Chrome or Safari respectively, and following the menu-driven process for installing PWAs. -You are more than welcome to use the data and the API that Spothole provides to power your own software, to run your -own Spothole server, or to modify it in any way. More details can be found in the following sections: +You are more than welcome to use the data and the API that Spothole provides to power your own software, to run your own +Spothole server, or to modify it in any way. More details can be found in the following sections: * [Embedding Spothole in another website](docs/embedding.md) * [Writing your own client](docs/clients.md) * [Running your own copy](docs/running.md) - * [nginx reverse proxy configuration](docs/nginx.md) - * [systemd service file](docs/systemd.md) - * [Running in Docker](docs/docker.md) - * [Use of multiple cluster logins](docs/multicluster.md) + * [nginx reverse proxy configuration](docs/nginx.md) + * [systemd service file](docs/systemd.md) + * [Running in Docker](docs/docker.md) + * [Use of multiple cluster logins](docs/multicluster.md) * [Modifying the source code](docs/modifying.md) ## Thanks @@ -54,8 +54,8 @@ The project contains GeoJSON files for CQ and ITU zones, in the `/datafiles/` di my knowledge, created by HA8TKS for his CQ and ITU zone layers for Leaflet. `/datafiles` also contains a `MUNICIPIOS.csv` file, from the "Nomenclátor Geográfico de Municipios y Entidades de Población" data set sourced from [el Centro Nacional de Información Geográfica](https://centrodedescargas.cnig.es/CentroDescargas/home). -`didbase-stations.csv` and the TOTA file were created by me based on publicly available data from GIRO and from -maps of conference centres. +`didbase-stations.csv` and the TOTA file were created by me based on publicly available data from GIRO and from maps of +conference centres. The project contains a set of flag icons generated using the "Noto Color Emoji" font on a Debian system, in the `/static/img/flags/` directory. @@ -65,12 +65,14 @@ This project would not have been possible without these libraries, so many thank ### Third Party Libraries -A number of third-party libraries are self-hosted in the `/static/vendor/` directory. These files are subject to -their own licences and are not covered by the overall licence declared in the `LICENSE` file. +A number of third-party libraries are self-hosted in the `/static/vendor/` directory. These files are subject to their +own licences and are not covered by the overall licence declared in the `LICENSE` file. A number of third-party libraries are self-hosted in the `/webassets/vendor/` directory. These files are subject to their own licences and are not covered by the overall licence declared in the `LICENSE` file. +Sound effects are CC0-licenced and sourced from [Pixabay](https://pixabay.com). + Particular thanks go to country-files.com for providing country lookup data for amateur radio, to K0SWE for [this JSON-formatted DXCC data](https://github.com/k0swe/dxcc-json/), and to the developers of `pyhamtools` for making it easy to use country-files.com data as well as QRZ.com and Clublog lookup. diff --git a/static/audio/bell.mp3 b/static/audio/bell.mp3 new file mode 100644 index 0000000..e2b974f Binary files /dev/null and b/static/audio/bell.mp3 differ diff --git a/static/css/style.css b/static/css/style.css index 97fbe09..c0d262d 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -206,6 +206,15 @@ div.band-spot-wanted { animation: wantedanim 1.5s ease-in-out alternate infinite; } +@keyframes wantedanim { + 0% { + background-color: #cf9e3d; + } + 100% { + background-color: #e1b655; + } +} + .leaflet-marker-icon.marker-icon-wanted::after { content: ""; width: 20px; @@ -217,14 +226,17 @@ div.band-spot-wanted { position: absolute; z-index: -1; border-radius: 1000%; + animation: wantedanimshadow 1.5s ease-in-out alternate infinite; } -@keyframes wantedanim { +@keyframes wantedanimshadow { 0% { background-color: #cf9e3d; + box-shadow: 0px 0px 10px 15px #cf9e3d; } 100% { background-color: #e1b655; + box-shadow: 0px 0px 10px 15px #e1b655; } } diff --git a/static/js/spots.js b/static/js/spots.js index 2fe0f59..902a94e 100644 --- a/static/js/spots.js +++ b/static/js/spots.js @@ -83,7 +83,11 @@ function startSSEConnection() { // Ping if we need to if ($("#pingOnNewSpots")[0].checked) { - new Audio("/audio/ping.mp3").play(); + if (callWanted(newSpot["dx_call"])) { + new Audio("/static/audio/bell.mp3").play(); + } else { + new Audio("/static/audio/ping.mp3").play(); + } } }, onerror(err) { diff --git a/static/service-worker.js b/static/service-worker.js index 8340792..b3e833a 100644 --- a/static/service-worker.js +++ b/static/service-worker.js @@ -1,6 +1,7 @@ const CACHE_NAME = 'Spothole'; const CACHE_URLS = [ 'static/apidocs/openapi.yml', + 'static/audio/bell.mp3', 'static/audio/ping.mp3', 'static/css/style.css', 'static/js/add-spot.js', @@ -50,6 +51,9 @@ const CACHE_URLS = [ 'static/vendor/js/leaflet-1.9.4.min.js', 'static/vendor/js/leaflet-geodesic-2.7.2.umd.min.js', 'static/vendor/js/leaflet-maidenhead.js', + 'static/vendor/js/fetch-event-source-2.0.1/fetch.js', + 'static/vendor/js/fetch-event-source-2.0.1/index.js', + 'static/vendor/js/fetch-event-source-2.0.1/parse.js', 'static/vendor/webfonts/fa-solid-900.ttf', 'static/vendor/webfonts/fa-solid-900.woff2' ]; diff --git a/templates/add_spot.html b/templates/add_spot.html index 98c0c5f..b30f288 100644 --- a/templates/add_spot.html +++ b/templates/add_spot.html @@ -76,7 +76,7 @@ - + diff --git a/templates/alerts.html b/templates/alerts.html index e51e07c..a15ebea 100644 --- a/templates/alerts.html +++ b/templates/alerts.html @@ -84,7 +84,7 @@ - + diff --git a/templates/bands.html b/templates/bands.html index cbaeb29..92dcdb9 100644 --- a/templates/bands.html +++ b/templates/bands.html @@ -76,8 +76,8 @@ - - + + diff --git a/templates/base.html b/templates/base.html index 7b221db..9d02f97 100644 --- a/templates/base.html +++ b/templates/base.html @@ -1,6 +1,6 @@ {% extends "skeleton.html" %} {% block head_extra %} - + @@ -15,10 +15,10 @@ window.fetchEventSource = fetchEventSource; - - - - + + + + {% end %} {% block body %}