fix: camera scaling on scan

This commit is contained in:
Julian Krauser 2025-07-26 12:13:21 +02:00
parent 0af32e72ed
commit bd4b08a67d
4 changed files with 41 additions and 39 deletions

View file

@ -3,19 +3,20 @@
<RouterLink :to="{ name: 'public-scanner-select' }" class="text-primary" @click="leave">
Zurück zur Sessionauswahl
</RouterLink>
<div class="relative flex flex-col gap-2 w-full grow overflow-hidden max-w-md mx-auto">
<div class="relative flex flex-col gap-2 w-full grow overflow-hidden mx-auto">
<Spinner v-if="selectedCamera == undefined" class="absolute top-3 left-1/2 -translate-y-1/2" />
<qrcode-stream
class="grow"
:constraints="selectedCamera?.constraints"
:track="trackFunctionOptions[4].value"
:formats="barcodeFormats"
:paused="paused"
@error="onError"
@detect="onDetect"
@camera-on="onCameraReady"
/>
<br />
<div class="grow w-full overflow-hidden">
<qrcode-stream
class="h-full w-full"
:constraints="selectedCamera?.constraints"
:track="trackFunctionOptions[4].value"
:formats="barcodeFormats"
:paused="paused"
@error="onError"
@detect="onDetect"
@camera-on="onCameraReady"
/>
</div>
<select v-model="selectedCamera">
<option v-for="c in selecteableCameras" :value="c">{{ c.label }}</option>
</select>