Skip to content

Commit

Permalink
fix: fix wrong spacing for "hover controls"
Browse files Browse the repository at this point in the history
  • Loading branch information
AlejandroAkbal committed Jul 8, 2021
1 parent ab278d7 commit 398b358
Showing 1 changed file with 9 additions and 15 deletions.
24 changes: 9 additions & 15 deletions components/pages/posts/navigation/page/PostsControls.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<div>
<!-- Normal controls -->
<template v-if="!getUserSettings.infiniteLoad.value">
<!-- Normal controls -->
<div
:class="{
'fixed bottom-0 inset-x-0 z-10 max-w-3xl p-2 mx-auto sm:p-4 lg:p-6':
Expand Down Expand Up @@ -43,35 +43,29 @@
</button>
</div>
</div>

<!-- Space below all posts -->
<template v-if="getUserSettings.hoverControls.value">
<div class="mt-6">&nbsp;</div>
</template>
</template>

<template v-else>
<!-- Infinite loading -->
<!-- Infinite loading -->
<template v-else-if="getUserSettings.infiniteLoad.value">
<div
class="py-12 mx-auto"
v-intersect="{
handler: InfiniteLoadHandler,
options: {
threshold: [0, 0.25, 0.5, 0.75, 1.0],
},
}"
class="py-12 mx-auto"
@click="InfiniteLoadHandler"
>
<p class="text-center text-gray-300 animate-pulse">
Stay here to load more posts...
</p>
</div>

<!-- Space below all posts -->
<div
v-if="
!getUserSettings.infiniteLoad.value &&
getUserSettings.hoverControls.value
"
class="mb-2 sm:mb-4 lg:mb-6"
>
&nbsp;
</div>
</template>
</div>
</template>
Expand Down

0 comments on commit 398b358

Please sign in to comment.