Hello! Self-esteem is having pride in yourself or respecting yourself. Showing you have confidence within yourself! So, when another judges you that can play a role in how YOU chose to look at your self-esteem, your self-esteem can be changed if something thinks badly of you, but you can decide to change it if you'd like. So, it is not nesesarily based on what people think of you.
I hope this helped!
I am, yours most sincerely,
SuperHelperThingy