I can recall being boy-crazy as far back as preschool.
When my inclination was to chase male attention rather than academic excellence and I was caught in this act, it was met with chastisement. An understandable and completely justifiable response.
But there is a better response.
These situations can be better utilized as a teachable moment about her value. She is worth more than the attention of a boy and thus she should be able to act like it. She should have high expectations for a future partner just as she should have high expectations for herself.
Teach her to value the correct kind of attention. Teach her that she must have her own best interest at heart because not everyone she meets will.
That has to start with you.
When she stumbles across love, let it be because this love truly benefits her, admires who she is, and respects her. Rather than love simply being whoever was around when she was looking.
Put understanding and care before the inclination to punish in these situations. If her mistakes and actions are always met with punishment or perhaps even anger, she’ll stop coming to you completely.