FLUTTER ECOSYSTEM

malikwang/expand_tap_area

बिना उसके आकार या लेआउट को बदले एक विजेट के टैप क्षेत्र को हाथ से बढ़ाएं। iOS विकास में hitTest के समान।

expand_tap_area प्रोजेक्ट कवर
Stars
38
Forks
6
अंतिम पुश (UTC)
1 मई 2024
प्रोजेक्ट स्थिति
सक्रिय
malikwang GitHub avatar
GITHUB User

malikwang ↗

भाषाएँDartObjective-CRubyJavaSwiftKotlin

इस रिपॉज़िटरी के पैकेज

उपयोग की गई निर्भरताएँ

निर्भरता सूची 2 आइटम
  • flutter{"sdk":"flutter"}
  • flutter_testडेवलपमेंट{"sdk":"flutter"}

मूल README

यह अंग्रेज़ी मूल स्नैपशॉट है। नवीनतम सामग्री GitHub पर देखें।

README खोलें / बंद करें

ExpandTapArea

Manually expand the tap area of a widget without changing its size or layout. Similar with the hitTest in iOS development.

Context

In the Human Interface Guidelines, Apple recommends a minimum target size of 44 x 44 px. 
In the Android Material Design Guidelines, it’s suggested that touch targets should be at least 48 x 48 dp.

Inspired by issue

Usage

ExpandTapWidget(
  onTap: () {},
  tapPadding: EdgeInsets.all(25.0),
  child: smallWidget(),
),

Demo

Attention

  1. ExpandTapWidget can be wrapped inside/outside GestureDetector: To avoid the conflict of gesture, it is better to apply on the innermost/smallest widget.
  2. The expanded area wouldn't exceed the boundary of the Parent Box. You can set debugPaintExpandAreaEnabled = true to display the actual expanded area.