Afaik the idea behind elected prosecutors and judges is to make sure that the law represents what the people want, since a prosecutor or judge that fails to convict when the people want a conviction won't get re-elected.
So yes, they are politicians, and I'm not convinced that's a good thing.
Of course, being north of the border, I'm not exactly versed in American state politics.
This is actually a big deal in America and a fundamental change in how our government operates. Your idea is right, but since the 1960s judicial authority has grown in a way that increases their responsibility to the point where they're almost legislators themselves.
Because there's a lot of different ways to interpret laws, judges have a fair amount of flexibility in sentencing, and elected judges aren't by default just cronies of whoever appointed them.
I believe that's the idea, yes. However it's very easy to see that it doesn't actually work that way. Unseating an incumbent candidate in local governments is damn near impossible, barring "scandals" or obvious extremes (but not even then, depending on the area we're talking about).