在web 中類似的情況的都被成為點擊穿透事件
在flutter中 ,組件的嵌套 也存在類似情況,flutter中的所有點擊事件 一層一層源碼找 最終都是
有興趣可以去看官方文檔
https://flutterchina.club/gestures/

GestureDetector點擊 組件的源碼中的behavior 屬性

三個內容 枚舉 值

//方法1
...
InkWell(
onTap: () {},
child: GestureDetector(
behavior:HitTestBehavior.translucent,
onTap:(){
print("___test");
print("---");
},
child: Text("點擊",
),
),
);
...
//方法2 ... InkWell( onTap:(){}, child: Container( color:Colors.transparent,//透明顏色 child: GestureDetector( onTap:(){ print("___test"); print("---"); }, child: Text("點擊", style:TextStyleConstant().blue_16, ), ), ), ) ....
