Enable automatic brightness
If your computer has an integrated light sensor, it can be used to automatically control screen brightness. This ensures that the screen is always easy to see in different ambient light conditions, and helps to reduce battery consumption.
Go to the Desktop and start typing Power.
Click Power to open the panel.
In the Power Saving section, ensure that the Automatic brightness switch is set to on.
To disable automatic screen brightness, switch it to off.