The easiest way would be to put required expression, Time between Sunrise and 10 PM on the "Garage Door Auto Close" rule. This would accomplish the same goal.
That said, the auto close rule in general is not a good idea, for the reasons you stated that already occured.
If you are going to have such a rule, think of EVERYTHING that can go wrong and put some logic in place to prevent it.
Biggest one I can see, someone stops halfway in/out of the garage door for some unknown reason, leaves it and forgets it and the sensors don't see the car. Or worse, a person standing in the line of the door, but isn't in line with the sensors. IMHO, the best thing you could do is just have it alert you at the 30 minute mark that the garage door is open. Then, you can verify that the door is not blocked and then close it using switch on wall or in app(I do this with a 10 minute timer, and verify by camera, or stepping into the garage and physically seeing myself)
Just two days ago, (True story) we were coming home, as we pulled into the driveway, we heard screams. We have foxes in the area, and they can sound like a baby or lady screaming. We did not initially see anything. But, just as we pulled into the garage, we heard the scream again, with a distinct "HELP!!" Shut the car down where it sat, got out, and saw the neighbors dogs around the back of her car. That is where the sound was coming from. Ran over to find her fingertips trapped in her hatch. We got her hand out and waited for EMS help to show up. The whole time, the car was halfway in the garage. I got no less than six alerts on my phone that I had left the garage open. Had I used an auto close, it would have at least tried to close on my car. I am pretty sure that our SUV sits high enough that the sensors run below the car. But, they have to be that low to prevent closure on small children. It would only catch it if the tires were in the sensor zone or for a vehicle with a much lower base. The touch sensor should work. But, I would rather not test it on my car.
PS - Her hatch had "autoclosed" on her hand (finger tips). It is supposed to have sensors to stop that. But, they did not work for whatever reason. She was stuck for an hour, waiting on someone to come rescue her. So, even where we think things are safety gated, they can fail. I was actually shocked that the automanufacturers had not made that foolproof.