Skip to content

Commit

Permalink
πŸ’„ Use default scroll event for mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
AuroraHuang22 committed Jan 9, 2025
1 parent 4686c82 commit abad359
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions src/components/ScrollingList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
:class="[
'relative',
'flex',
'overflow-x-auto laptop:overflow-x-hidden',
'overflow-x-scroll laptop:overflow-x-hidden',
'hover-animate',
'select-none',
Expand All @@ -13,15 +13,11 @@
:style="{
'--animation-duration': durationTime,
}"
@mousedown="startDrag"
@mousemove="onDrag"
@mouseup="endDrag"
@mouseleave="endDrag"
@touchstart="startDrag"
@touchmove="onDrag"
@touchend="endDrag"
>
<ul class="flex animate-scroll">
<ul class="flex laptop:hidden">
<slot name="item" />
</ul>
<ul class="hidden laptop:flex animate-scroll">
<slot name="item" />
</ul>
<ul class="hidden laptop:flex animate-scroll delay">
Expand Down

0 comments on commit abad359

Please sign in to comment.