收藏
回答

滑动删除同时标签带有点击事件,点击的时候滑块也移动,如何解决呢?

<movable-view class="itmem_wrap" direction="horizontal" inertia="true" out-of-bounds="true" x="{{item.x}}" damping="300" data-index="{{index}}" bind:touchstart="touchMoveStartHandle" bind:touchend="touchMoveEndHandle" wx:key='{{index}}' data-id='{{item.id}}' bindtap='goDetail'>
回答关注问题邀请回答
收藏

2 个回答

  • 卢霄霄
    卢霄霄
    2020-06-28

    内层把touch事件catch掉,或者点击也用touch来实现,看touchend的时候touchmove的距离

    2020-06-28
    有用 1
    回复 1
    • Limlin
      Limlin
      2020-06-30
      按照答主建议查看了逻辑层代码,发现touchend内部判断泛化,没判断滑动距离为零的情况,修正后问题解决。
      2020-06-30
      回复
  • _天马行空_ᯤ⁶ᴳ
    _天马行空_ᯤ⁶ᴳ
    2020-06-28

    放个效果图看看

    2020-06-28
    有用
    回复
登录 后发表内容
问题标签