Problem with block input event

Hello,
I’ve attached BlockInputEvents to a node. During runtime, when resizing this node, the BlockInputEvents functionality stops working. To address this issue, I currently toggle the BlockInputEvents component off and then on again after resizing the node:

commUI.panel.getComponent(BlockInputEvents).enabled = true;
commUI.panel.getComponent(BlockInputEvents).enabled = false;

Is there a more efficient way to handle this?

Which platform are you using, I’ve never been in your situation before. It works perfect.

In Cocos Creator version 3.8.2, there is a white panel attached to the bottom of the screen. At the top of this panel, there is an upward arrow button that allows users to expand the panel upwards, increasing its size. This resizing action triggers the issue described.

I tried 3 methods, all fo them working normally.

    start() {
        let isShow = true;
        let uit = this.panel.getComponent(UITransform);
        this.hidAndShowBtn.on(Input.EventType.TOUCH_END, ()=>{
            if(!isShow){
                // uit.contentSize = size(400, 400);
                // tween(uit).to(0.5, {contentSize: size(400, 400)}).start();
                tween(this.panel).to(0.5, {scale: v3(1,1,1)}).start();
                
                isShow = true;
            }else{
                // uit.contentSize = size(400, 0);
                // tween(uit).to(0.5, {contentSize: size(400, 0)}).start();
                tween(this.panel).to(0.5, {scale: v3(1,0.1,1)}).start();
                
                isShow = false;
            }
        }, this);
    }