How to disable and enable h5 page events?

on the h5 page, there is a list, and each item in the list has a click event. When you click on an item, a details page comes in from the right transform, covering the list page.
the current problem is this: first click an item, to trigger the details page to enter, and transform is set to 1 second to fully come over. In this process, the entries in the list are still visible and clickable. If the user clicks on other items before the details page is fully pushed in, it will trigger multiple detail pages to advance layer by layer.
my current idea is: when the user clicks on a list item, Disable all click and tap events, and then enable all click and tap events when the details page is fully pushed in.
at present, it is not clear how to disable and enable all click and tap events. Please help us understand

.

if you have any other ideas, please let me know, thank you!

Mar.03,2021

  1. Add a class, to

    css, for example, call it .stop-click . Style:

      

    learn about throttling and anti-shaking

Menu