That automation waits for the temperature sensor to pass from below 19°C to above 19°C. It then checks to make sure the fan is on, and if is it, switches it off. There is nothing in this code that will switch it back the other way when the temperature drops again.
That seems like the wrong way around to me, but you may have deliberately done that to work around a peculiarity of your switch.
When you run an automation manually, it is expected behaviour for it to ignore the trigger and condition, and just run the action.
Personally, I’d rewrite with entity_id instead of device for ease, although I never use the UI. This rewrite still has the on/off what I suspect to be the wrong way around:
- alias: Garage - Turn on the inverter fan
- platform: numeric_state
- condition: state
- service: switch.turn_off