Tencent / Tencent/tdesign-miniprogram

[SwipeCell] 在列表中opened 无法跟随列表变化

Open
#2,546 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

💪🏻 enhancement
Dominant language
Vue
Stars
1.8k
Forks
337
Avg merge
1d 21h
Merged PRs (30d)
19

Description

tdesign-miniprogram 版本

1.2.6

重现链接

No response

重现步骤

由于SwipeCell都是针对item的操作, 所以很需要这个功能.
假如我有个list页面
list = [
SwipeCell(),
SwipeCell(),
SwipeCell(),
SwipeCell(),
SwipeCell(),
SwipeCell(),
SwipeCell(),
]
当我左滑打开list[1] 时, 此时再在list头部插入一个新的SwipeCell() 会导致用户打开的SwipeCell并不是实际他需要的那一项, 显示打开的的还是list[1] ,实际上应该变成list[2]了

期望结果

增加 open, close status event 让开发者自行处理 或者 增加列表绑定

实际结果

No response

基础库版本

2.25.4

补充说明

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Start by locating the SwipeCell component and tracing how its open state is associated with list items; compare that with the list update scenario described here. Done means inserting an item preserves the intended opened item, or exposes a documented open/close event or binding that lets callers handle it.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, mobile-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.