It’s kind of an old fashioned word. A second use of “dear” is when strangers or people you don’t know well call you “dear” to sound friendly. It can sound condescending, and some people are offended by it, so you have to be careful about using it this way.
You can call someone dear as a sign of affection. You’re a lot like me, dear.