Skip to content

Commit

Permalink
Merge pull request #4892 from yshirai-joolen/add_cart_modal_close_cancel
Browse files Browse the repository at this point in the history
カート追加時モーダル枠の白い部分をクリックした時は何も反応させない
  • Loading branch information
okazy committed Feb 17, 2021
2 parents 7e1cf17 + 47c1c20 commit c36a87d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/Eccube/Resource/template/default/Product/detail.twig
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,11 @@ file that was distributed with this source code.
});
});
$('.ec-modal-overlay, .ec-modal .ec-inlineBtn--cancel').on('click', function() {
$('.ec-modal-wrap').on('click', function(e) {
// モーダル内の処理は外側にバブリングさせない
e.stopPropagation();
});
$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
$('.ec-modal').hide()
});
</script>
Expand Down
6 changes: 5 additions & 1 deletion src/Eccube/Resource/template/default/Product/list.twig
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,11 @@ file that was distributed with this source code.
});
});
$('.ec-modal-overlay, .ec-modal .ec-inlineBtn--cancel').on('click', function() {
$('.ec-modal-wrap').on('click', function(e) {
// モーダル内の処理は外側にバブリングさせない
e.stopPropagation();
});
$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
$('.ec-modal').hide()
});
</script>
Expand Down

0 comments on commit c36a87d

Please sign in to comment.