How does better-scroll enable scrolling dynamically?

there are two scrolls on a page. As shown in the following figure, the blue box can scroll up for some distance, and the red box also needs to scroll. Now the better-sroll, requirement is that the red box can only scroll when the blue box scrolls to the top, and when the blue box suddenly stops, the momentum should be transferred to the red box (this requirement has nothing to do with the problem, and it is better to solve it by the way). The effect is similar to that of ele.me ordering page

Apr.11,2021

Big Brother, have you solved it? I also encountered this problem

Menu