mirror of
https://github.com/ae-utbm/sith.git
synced 2026-08-26 07:09:16 +00:00
Move image click to frame and remove image selection
This commit is contained in:
@@ -48,6 +48,9 @@
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
object-fit: contain;
|
object-fit: contain;
|
||||||
|
// Prevent ugly selection when
|
||||||
|
// clicking to change the image
|
||||||
|
user-select: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,13 +82,16 @@
|
|||||||
|
|
||||||
<div class="container" id="pict">
|
<div class="container" id="pict">
|
||||||
<div class="main">
|
<div class="main">
|
||||||
<div class="photo" :aria-busy="currentPicture.imageLoading">
|
<div
|
||||||
|
class="photo"
|
||||||
|
:aria-busy="currentPicture.imageLoading"
|
||||||
|
@click="currentPicture = (($event.offsetX > $event.target.getBoundingClientRect().width / 2) ? nextPicture : previousPicture) ?? currentPicture"
|
||||||
|
>
|
||||||
<img
|
<img
|
||||||
:src="currentPicture.compressedUrl"
|
:src="currentPicture.compressedUrl"
|
||||||
:alt="currentPicture.name"
|
:alt="currentPicture.name"
|
||||||
id="main-picture"
|
id="main-picture"
|
||||||
x-ref="mainPicture"
|
x-ref="mainPicture"
|
||||||
@click="currentPicture = (($event.offsetX > $el.offsetWidth / 2) ? nextPicture : previousPicture) ?? currentPicture"
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user