0
リーフレットはダブルタップを認識しません(ただし、ダブルクリックで拡大しても問題ありません - devツールを開き、バグを見るためにモバイルデバイスを選択するだけです)。それは私が別のグローバルラッパーDIVの中にマップDIVを持っているからかもしれませんが、そうではありません。コンソールに 'map'と入力しても表示されます。doubleClickZoom is enabled
手動でダブルタップ機能を追加する必要がありますか、何か不足していますか?リーフレットダブルタップはズームインされません
UPDATE:@Baptisteは右である - 私は、カスタムダブルタップ機能を追加する必要がありました:
var tapped=false
$("#map").on("touchstart",function(e){
if(!tapped){ //if tap is not set, set up single tap
tapped=setTimeout(function(){
tapped=null
//insert things you want to do when single tapped
},300); //wait 300ms then run single click code
} else { //tapped within 300ms of last tap. double tap
clearTimeout(tapped); //stop single tap callback
tapped=null
//insert things you want to do when double tapped
map.zoomIn(1)
}
});