Slider Fill Area deactivate after jump

I have a slider that shows the force of my characters jump. The longer you hold the mouse the higher he jumps. When he jumps and is in air I have the force disabled so the character won’t dubble jump. But the slider Fill Area still visually increases when holding the mouse down. How can I disable this?

powerBar.interactable = false; doesn’t seem to work

powerBar.enable doesn’t seem to work either.

powerBar.SetActive(false);

@ArmanDoesStuff What .SetActive does is hide the whole Slider. I would like to only have the fill area of the slider not working anymore after jumping, so you won’t be able to increase the fill while in mid air.