It depends on the situation and why they're doing it. It's hard for me to say because I don't generally interact with people who are super serious or heavy. Oftentimes I showcase a stronger fun element (make some jokes, smile a bit more, just some stuff to try and get them to join the rest of us in having a good time), and a lot of the time they liven at least a little bit up. If they don't, I usually stop trying and avoid them. Don't need that negativity bringing me down. If I do circle back to them - like if it's a customer of mine or someone I see regularly - I might reduce it a little bit as if to say "hey I get it, you're in one of your moods or whatever, I won't annoy you with a good time" but it's typically a milder version of my previous state, not a kowtow to theirs.
Usually there are two reasons people will do this. They might be naturally low-energy, stoic, and/or emotionally down. In those cases, there's only so much you can do before you realize they won't budge on their state. The other reason is that they're testing your frame. Usually when I've had that happen it's in an expression of opinion. A good example was when I was at the coffee shop the other day, I was talking to the barista about which coffee blends and styles we preferred. I mentioned how much I love Italian coffee, and he said he can't stand the typical light-roasted robusta blends they use. I agreed with him that the roasts and blends weren't as good as South American or African ones, but the style and quality of brewing was excellent. He quickly changed his previous statement and said that it wasn't that bad but he doesn't particularly like it (in reference to the part of his statement I agreed with). In this situation, he stated an opinion contrary to mine, and I expanded upon mine to where it wasn't contradictory to his any longer, and he altered his previous statement to make it contradictory again. I don't know if he did this consciously or not (I tend to think most people don't do this consciously, but maybe I'm being naive), but the effect was visible: he was testing how firmly I believed in what I was saying and if I would stick to it when challenged.
State can be the same way, and girls do this far more often than guys do. If you come at someone with an upbeat, lively attitude and they either don't like it or doubt its authenticity, they might hit you with a persistent lower state in order to see if they can suck the wind out of your sails. They can then gauge whether or not you're just running on swayable emotion or whether that's actually your nature. Needless to say, in this situation you never want to cave into their frame. Guy or girl, if you hold up against their frame tests - regardless of whether they change their frame - you look better to everyone who sees it.