Compare commits
No commits in common. "0.5.0" and "0.4.4" have entirely different histories.
10
CHANGELOG.md
10
CHANGELOG.md
@ -2,18 +2,8 @@
|
|||||||
|
|
||||||
All notable changes to this project will be documented in this file. Dates are displayed in UTC.
|
All notable changes to this project will be documented in this file. Dates are displayed in UTC.
|
||||||
|
|
||||||
#### [0.5.0](https://git.odit.services/lfk/kiosk/compare/0.4.4...0.5.0)
|
|
||||||
|
|
||||||
- feat(registration): autofocus input fields + done button [`cbfbd92`](https://git.odit.services/lfk/kiosk/commit/cbfbd92d0e4f9735a2192125f267f651ed36c9b1)
|
|
||||||
- feat(registration): disabled done button for 7.5s [`5f5b03a`](https://git.odit.services/lfk/kiosk/commit/5f5b03a8a086799543cf675ccc3a973b781d1987)
|
|
||||||
- feat(registration): support next input element with ENTER key [`066e67c`](https://git.odit.services/lfk/kiosk/commit/066e67c64f48b00673f2de7727acb230c94c3c13)
|
|
||||||
- feat(registration): disable text select [`418fe77`](https://git.odit.services/lfk/kiosk/commit/418fe7773fbc981186909a1f7c262c3c1fa1ece2)
|
|
||||||
|
|
||||||
#### [0.4.4](https://git.odit.services/lfk/kiosk/compare/0.4.3...0.4.4)
|
#### [0.4.4](https://git.odit.services/lfk/kiosk/compare/0.4.3...0.4.4)
|
||||||
|
|
||||||
> 19 April 2023
|
|
||||||
|
|
||||||
- 🚀Bumped version to 0.4.4 [`4b6e11d`](https://git.odit.services/lfk/kiosk/commit/4b6e11d8d271c638b3c2e4cd3dc887680023dd5e)
|
|
||||||
- fix(registration): Added missing dark styling [`0698038`](https://git.odit.services/lfk/kiosk/commit/06980385230e32dffe1083ceb4f88e86a9197aef)
|
- fix(registration): Added missing dark styling [`0698038`](https://git.odit.services/lfk/kiosk/commit/06980385230e32dffe1083ceb4f88e86a9197aef)
|
||||||
|
|
||||||
#### [0.4.3](https://git.odit.services/lfk/kiosk/compare/0.4.2...0.4.3)
|
#### [0.4.3](https://git.odit.services/lfk/kiosk/compare/0.4.2...0.4.3)
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@lfk/kiosk",
|
"name": "@lfk/kiosk",
|
||||||
"version": "0.5.0",
|
"version": "0.4.4",
|
||||||
"private": false,
|
"private": false,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "https://git.odit.services/lfk/kiosk",
|
"repository": "https://git.odit.services/lfk/kiosk",
|
||||||
|
@ -2,34 +2,15 @@
|
|||||||
import { RunnerService, type ResponseRunner } from '@odit/lfk-client-js';
|
import { RunnerService, type ResponseRunner } from '@odit/lfk-client-js';
|
||||||
import bwipjs from 'bwip-js';
|
import bwipjs from 'bwip-js';
|
||||||
import lfkbackground from './background.png';
|
import lfkbackground from './background.png';
|
||||||
import { onMount } from 'svelte';
|
|
||||||
|
|
||||||
$: firstname = '';
|
$: firstname = '';
|
||||||
$: lastname = '';
|
$: lastname = '';
|
||||||
$: doneButtonEnabled = false;
|
|
||||||
$: showResult = false;
|
$: showResult = false;
|
||||||
$: showError = false;
|
$: showError = false;
|
||||||
|
|
||||||
let response: ResponseRunner;
|
let response: ResponseRunner;
|
||||||
const group = 1; //Default to Bürgerlauf
|
const group = 1; //Default to Bürgerlauf
|
||||||
|
|
||||||
function focusFirstName() {
|
|
||||||
setTimeout(() => {
|
|
||||||
document.getElementById('firstname')?.focus();
|
|
||||||
}, 50);
|
|
||||||
setTimeout(() => {
|
|
||||||
document.getElementById('firstname')?.focus();
|
|
||||||
}, 100);
|
|
||||||
}
|
|
||||||
function focusDoneButton() {
|
|
||||||
setTimeout(() => {
|
|
||||||
document.getElementById('done')?.focus();
|
|
||||||
}, 50);
|
|
||||||
setTimeout(() => {
|
|
||||||
document.getElementById('done')?.focus();
|
|
||||||
}, 100);
|
|
||||||
}
|
|
||||||
|
|
||||||
async function register() {
|
async function register() {
|
||||||
try {
|
try {
|
||||||
response = (await RunnerService.runnerControllerPost({
|
response = (await RunnerService.runnerControllerPost({
|
||||||
@ -39,12 +20,6 @@
|
|||||||
})) as ResponseRunner;
|
})) as ResponseRunner;
|
||||||
showError = false;
|
showError = false;
|
||||||
showResult = true;
|
showResult = true;
|
||||||
setTimeout(() => {
|
|
||||||
doneButtonEnabled = true;
|
|
||||||
setTimeout(() => {
|
|
||||||
focusDoneButton();
|
|
||||||
}, 25);
|
|
||||||
}, 7500);
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
showError = true;
|
showError = true;
|
||||||
@ -71,14 +46,10 @@
|
|||||||
});
|
});
|
||||||
return canvas.toDataURL('image/png');
|
return canvas.toDataURL('image/png');
|
||||||
}
|
}
|
||||||
|
|
||||||
onMount(() => {
|
|
||||||
focusFirstName();
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
class="dark:bg-slate-900 bg-gray-100 flex h-full items-center py-16 select-none"
|
class="dark:bg-slate-900 bg-gray-100 flex h-full items-center py-16"
|
||||||
style="background: url({lfkbackground});background-position: center center!important;background-size: contain!important;background-repeat: no-repeat!important;"
|
style="background: url({lfkbackground});background-position: center center!important;background-size: contain!important;background-repeat: no-repeat!important;"
|
||||||
>
|
>
|
||||||
<div class="w-full max-w-md mx-auto p-6">
|
<div class="w-full max-w-md mx-auto p-6">
|
||||||
@ -101,11 +72,6 @@
|
|||||||
<label for="firstname" class="block text-lg font-bold mb-2 sr-only">Vorname</label>
|
<label for="firstname" class="block text-lg font-bold mb-2 sr-only">Vorname</label>
|
||||||
<div class="relative">
|
<div class="relative">
|
||||||
<input
|
<input
|
||||||
on:keydown={(e) => {
|
|
||||||
if (e.keyCode === 13) {
|
|
||||||
document.getElementById('lastname')?.focus();
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
type="text"
|
type="text"
|
||||||
id="firstname"
|
id="firstname"
|
||||||
name="firstname"
|
name="firstname"
|
||||||
@ -212,13 +178,8 @@
|
|||||||
|
|
||||||
<div class="mx-auto text-center items-center">
|
<div class="mx-auto text-center items-center">
|
||||||
<button
|
<button
|
||||||
class:opacity-50={!doneButtonEnabled}
|
|
||||||
disabled={!doneButtonEnabled}
|
|
||||||
id="done"
|
|
||||||
on:click={() => {
|
on:click={() => {
|
||||||
doneButtonEnabled = false;
|
|
||||||
showResult = false;
|
showResult = false;
|
||||||
focusFirstName();
|
|
||||||
}}
|
}}
|
||||||
class="w-full py-3 px-4 inline-flex justify-center items-center gap-2 rounded-md border border-transparent font-semibold bg-blue-500 text-white hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 transition-all text-sm dark:focus:ring-offset-gray-800"
|
class="w-full py-3 px-4 inline-flex justify-center items-center gap-2 rounded-md border border-transparent font-semibold bg-blue-500 text-white hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 transition-all text-sm dark:focus:ring-offset-gray-800"
|
||||||
>Fertig</button
|
>Fertig</button
|
||||||
@ -230,7 +191,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="fixed bottom-0 w-full text-center text-xl p-4 dark:text-white select-none">
|
<div class="fixed bottom-0 w-full text-center text-xl p-4 dark:text-white">
|
||||||
<a
|
<a
|
||||||
rel="noopener noreferrer"
|
rel="noopener noreferrer"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user