The France-Italy case is actually a good one to look at. What we now call the “French Riviera” used to be a possession of the then-city state of Genoa. Italians still refer to Nice by its Italian name “Nizza” (rhymes with pizza) and Italian independence hero Giuseppe Garibaldi was born there.
As part of a deal to secure French support for the unification project being pushed by the then-Kingdom of Piedmont-Sardinia, the would-be King of Italy bartered away Nice and its hinterland. Folks there might speak Italian now, but as a second language.
You could probably ride a bike from Malaga to Muggia (Spain to the eastern Italian border) along the Mediterranean coast and you will see that the cultures blend into one another. The Catalans are linguistic kin to the Genoese. The dialects spoken in Venice are more similar to Spanish and Portuguese than those spoken in Florence and Milan. It’s all the detritus of history.
This is why I tend to favor decentralization and cantonal government— to give people the most power to determine how they interact with each other and their government. The Catalans wanted to leave Spain, right up until they discovered that their new republic might have some difficulty with EU membership. Now there’s tons of history there. Some of it recent, some of it much less recent. Catalan resentment stems from the 1930’s Spanish Civil War, but also what the fascist winner of that war did to them after he won, and some of it with James of Aragon did in the 1200's.
But, to the original point, the Catalans and the Chinese have had greater opportunity to exercise their own sovereignty than the Iraqis for the last 500 or so years. Iraq has been ruled by outsiders from the fall of the Abbasids around 1400 right up until pretty much the present day (given that the imported Hashemi king and the subsequent Ba’athist dictators weren’t really very legitimate either).