Using <NuxtImg> everywhere :)
All checks were successful
pipeline / build-and-push-images (push) Successful in 33s
pipeline / deploy (push) Successful in 7s

This commit is contained in:
2024-12-06 19:27:42 +01:00
parent 1bdf87c6af
commit 80c7f20eb7
7 changed files with 22 additions and 8 deletions

View File

@@ -23,11 +23,13 @@ function handleStateChange(newState : string, newLane: number) {
<div class="navbar-container">
<NuxtLink style="display: flex; width: fit-content; text-decoration: none; align-items: center; margin-left: 10px;" to="/">
<img id="navbar-logo-img" src="/buildpath-high-resolution-logo-transparent.png" />
<NuxtImg format="webp" id="navbar-logo-img"
src="/buildpath-high-resolution-logo-transparent.png" />
</NuxtLink>
<div v-for="(lane, i) in championLanes" style="display: flex; align-items: center; margin-left: 20px;">
<img width="40" height="40" :src="LANE_IMAGES[lanePositionToIndex(lane.data)]" />
<NuxtImg format="webp" width="40" height="40"
:src="LANE_IMAGES[lanePositionToIndex(lane.data)]" />
<div>
<h2 :class="'navbar-link ' + (state == 'runes' && laneState == i ? 'navbar-link-selected' : '')"
@click="handleStateChange('runes', i)" >

View File

@@ -34,7 +34,9 @@ const {data: stats}: {data: Ref<{patch: number, count: number}>} = await useFetc
<div style="display: flex; align-items: center; margin-top: 30px; padding-right: 10px; overflow: hidden;">
<h1 style="font-size: 2.4rem; padding-left: 20px;">{{ championName }}</h1>
<img style="margin-left: 10px;" width="40" height="40" :src="LANE_IMAGES[lanePositionToIndex(lane.data)]" />
<NuxtImg format="webp" style="margin-left: 10px;"
width="40" height="40"
:src="LANE_IMAGES[lanePositionToIndex(lane.data)]" />
<h2 v-if="championName != null && championName != undefined && championName.length < 8"
style="margin-left: 5px; font-size: 1.8rem; font-weight: 200;">
{{ POSITIONS_STR[lanePositionToIndex(lane.data.toLowerCase())] }}

View File

@@ -14,7 +14,9 @@ if(route.path.startsWith("/tierlist/")) {
<NuxtLink style="margin-top: 5px; margin-bottom: 5px;" v-for="(pos, i) in POSITIONS" :to="'/tierlist/' + pos">
<div :class="selected == pos ? 'sidebar-link-selected' : ''"
class="sidebar-link" style="padding-left: 35px; display: flex; align-items: center;">
<img width="40" height="40" :src="LANE_IMAGES[i]" :alt="POSITIONS_STR[i]" />
<NuxtImg format="webp"
width="40" height="40"
:src="LANE_IMAGES[i]" :alt="POSITIONS_STR[i]" />
<h3 style="font-size: 2.1rem; font-weight: 200; margin-left: 10px;">{{ POSITIONS_STR[i] }}</h3>
</div>
</NuxtLink>