Skip to content

Commit 0b8ec17

Browse files
committed
fix bug with chord card sizing
1 parent d8e5b38 commit 0b8ec17

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

components/ChordCard.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<template>
2-
<div>
3-
42
<div
53
class="flex flex-col items-center bg-white border-green-500 select-none"
64
:class="[
7-
expanded ? 'rounded-lg px-8 py-6' : 'rounded-full min-w-[1.5rem] w-[fit-content] h-6',
5+
expanded ? 'rounded-lg px-8 py-6' : 'rounded-full min-w-[1.5rem] w-[fit-content] h-6',
86
selectedChord.label !== 'N/C' && 'border',
97
]"
108
>
@@ -39,8 +37,6 @@
3937
</div>
4038
</div>
4139
</div>
42-
<div v-if="expanded && alternativeChords.length == 0" class="h-[6rem] flex-none w-full"></div>
43-
</div>
4440
</template>
4541

4642
<script setup lang="ts">

components/SwipeHorizontal.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@
3434
:expanded="true"
3535
:id="[chordData.measure, chordData.beat].join('-')"
3636
name="chord-card"
37-
class="mx-auto shadow-md -translate-y-[10vh] sm:-translate-y-[5vh]"
37+
class="mx-auto shadow-md"
38+
:style="{ transform: `translateY(calc(-8vh - ${chordData.alternativeChords.length == 0 ? 3 : 0}rem))` }"
3839
@click.stop="() => { }"
3940
/>
4041
<button

0 commit comments

Comments
 (0)