ionic-team / ionic-team/ionic-framework

feat: generic touch gestures (press, pinch, etc)

Đang mở
#19,183 35 bình luận 16 reaction 0 người được giao Xem trên GitHub
package: core type: feature request
Ngôn ngữ chính
TypeScript
Star
52.7k
Fork
13.3k
Merge trung bình
1 ngày 15 giờ
Pull request đã merge (30 ngày)
51

Mô tả

# Feature Request

**Ionic version:**
ionic v4
ionic/angular: 4.7.1
ionic-cli: 5.2.5

**Describe the Feature Request**
Since Ionic 4 there are no more touch gestures like press (long press).
For a mobile framework, this is a very important part.
This have to be an official supported feature in such a UI.
The developer of Ionic should not hack for this feature.
Like [this](https://medium.com/madewithply/ionic-4-long-press-gestures-96cf1e44098b) or [this](https://stackoverflow.com/a/41322757/9251185).

**Describe Preferred Solution**
Ionic should provide this feature in an official way. No hacks. No polyfills.
I can not say which solution would be the best.
Maybe use Angular with Hammerjs. Or build an own touch lib.

**Related Code**
Ionic 3:

```html
Press me long.
```

```ts
import { Gesture } from 'ionic-angular/gestures/gesture';
// ...
this.pressGesture = new Gesture(this.nativeElement);
this.pressGesture.listen();
this.pressGesture.on('press', event => {/*...*/});
// ...
```

In Ionic 4 this is not possible anymore. 😢 Or did I miss something?
Any questions? I'm glad if I can help.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.