Clearly, some people do not feel the same way as you, Maisymoomoo, so what's the point of this thread other than to say "I wouldn't wear pjs, and I judge people who do"
The head is clearly free to judge people and think her own private thoughts.
Just as people are free to dress as smartly or as slovenly as they wish in their own private lives.
If you are an employer you have a right to demand a certain dress code of your employees, and if they don't comply then sanctions are available. An agreement is in place.
Headteachers have zero authority to dictate dress code over anyone who isn't a member of staff or a pupil. I can't begin to imagine why this head thought it appropriate to comment on the clothing of other adults.