Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding onLongPress to ListItem #1533

Merged
merged 1 commit into from
Jul 13, 2017
Merged

Adding onLongPress to ListItem #1533

merged 1 commit into from
Jul 13, 2017

Conversation

lxwbr
Copy link

@lxwbr lxwbr commented Jul 5, 2017

Added functionality for listening for long press on a ListItem.

  • Make sure that you follow antd's code convention.
  • Run npm run lint and fix those errors before submitting in order to keep consistent code style.
  • Rebase before creating a PR to keep commit history clear.
  • Add some descriptions and refer relative issues for you PR.

Extra checklist:

  • Update API docs for the component.
  • Update/Add demo to demonstrate new feature.
  • Update TypeScript definition for the component.
  • Add unit tests for the feature.

This change is Reviewable

@pingan1927
Copy link
Contributor

仅支持rn的话,文档需要更新下

@silentcloud
Copy link
Contributor

silentcloud commented Jul 6, 2017

@Zunder 把 web 的也加上吧 https://github.com/react-component/touchable#api

要保持 API 一致性

@paranoidjk
Copy link
Contributor

ping @Zunder

@paranoidjk
Copy link
Contributor

先合掉,web 和 文档我来更新。

@paranoidjk paranoidjk merged commit 2a852d9 into ant-design:master Jul 13, 2017
paranoidjk added a commit that referenced this pull request Jul 13, 2017
plowsirius pushed a commit to koubei-fe/ant-design-mobile that referenced this pull request Jul 24, 2017
plowsirius pushed a commit to koubei-fe/ant-design-mobile that referenced this pull request Jul 24, 2017
@laukaichung
Copy link

laukaichung commented Mar 5, 2018

@paranoidjk @silentcloud
Does List.Item support onLongPress in 2.16?
I couldn't find any mention of it in the typescript definition files.

@laukaichung
Copy link

Any progress on this?

@paranoidjk
Copy link
Contributor

@stonecold123 onLongPress api is removed in antd-mobile@2, you can use below 2 components to wrap your List.Item children to implement long press feature.

  • you can use rc-gesture, which have onPress, onPressOut api.
  • you can use rc-touchable, which have onLongPress API

cc @silentcloud

lixiaoyang1992 pushed a commit to lixiaoyang1992/ant-design-mobile that referenced this pull request Apr 26, 2018
lixiaoyang1992 pushed a commit to lixiaoyang1992/ant-design-mobile that referenced this pull request Apr 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants