Frontend: Vibration pattern adjustments
Signed-off-by: Fred Boniface <fred@fjla.uk>
This commit is contained in:
parent
1beeaa592a
commit
ee6fcae38f
@ -47,7 +47,7 @@
|
|||||||
<form action="board.html">
|
<form action="board.html">
|
||||||
<input class="lookup-box" type="text" id="crs-lookup" name="stn" placeholder="Enter CRS/TIPLOC" autocomplete="off"/>
|
<input class="lookup-box" type="text" id="crs-lookup" name="stn" placeholder="Enter CRS/TIPLOC" autocomplete="off"/>
|
||||||
<br>
|
<br>
|
||||||
<input type="submit" value="Lookup Board" class="lookup-button">
|
<input type="submit" value="Lookup Board" class="lookup-button" onclick="vibe()">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<h2>Quick Links</h2>
|
<h2>Quick Links</h2>
|
||||||
@ -62,7 +62,7 @@
|
|||||||
|
|
||||||
<!-- Footer -->
|
<!-- Footer -->
|
||||||
<footer>
|
<footer>
|
||||||
<p>Created by <a href="https://fredboniface.co.uk" target="_blank" rel="noreferrer noopener">Fred Boniface</a> - 0.0.1-dev-2023013107</p>
|
<p>Created by <a href="https://fredboniface.co.uk" target="_blank" rel="noreferrer noopener">Fred Boniface</a> - 0.0.1-dev-2023013109</p>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
@ -19,6 +19,7 @@ async function fetchEntry(){ // This can be condensed
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function parseData(values){
|
async function parseData(values){
|
||||||
|
vibe()
|
||||||
if (values.crs != ""){
|
if (values.crs != ""){
|
||||||
setLoadingDesc(`Searching\n${values.crs.toUpperCase()}`)
|
setLoadingDesc(`Searching\n${values.crs.toUpperCase()}`)
|
||||||
var data = await getData("crs", values.crs)
|
var data = await getData("crs", values.crs)
|
||||||
|
@ -11,6 +11,7 @@ async function pageInit() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function gotoBoard(station){
|
async function gotoBoard(station){
|
||||||
|
vibe()
|
||||||
window.location.assign(`${window.location.origin}/board.html?stn=${station}`);
|
window.location.assign(`${window.location.origin}/board.html?stn=${station}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,10 +121,10 @@ async function vibe(type) {
|
|||||||
}
|
}
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case "err":
|
case "err":
|
||||||
navigator.vibrate([300,200,300])
|
navigator.vibrate([300])
|
||||||
break;
|
break;
|
||||||
case "ok":
|
case "ok":
|
||||||
navigator.vibrate([50,150,50])
|
navigator.vibrate([50,50,50])
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
navigator.vibrate(30)
|
navigator.vibrate(30)
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Service Worker */
|
/* Service Worker */
|
||||||
|
|
||||||
const appVersion = "0.0.1-dev-2023013107"
|
const appVersion = "0.0.1-dev-2023013109"
|
||||||
const cacheName = `owlboard-${appVersion}`
|
const cacheName = `owlboard-${appVersion}`
|
||||||
const cacheIDs = [cacheName]
|
const cacheIDs = [cacheName]
|
||||||
const cacheFiles = [
|
const cacheFiles = [
|
||||||
|
Reference in New Issue
Block a user