Can couples living in different states CA/IL & earn their respective income in those states file joint federal&state return but split the income when filing the 2 states?

The system recognizes that I am a resident of CA and my spouse is resident of IL. We filed a joint federal return and when I got to the state, the  CA state allowed me to input the income solely generated from CA from our total income and calculated my CA refund based on that amount (which kind of makes sense to me). The IL tax was also calculated based on the income from IL only. I’m wondering if this is a new feature recently added to Turbotax or I’m doing something wrong. This is because all what I have seen from online search is that we might have to do MFJ for federal and MFS for the states.
Thanks for your input.