It doesn't work that way. First, Catalonia is a Spanish region. Second, Article 2 of the Spanish Constitution does not give any Spanish region the right of self-determination. Article 155 gives the Spanish Government the right to take over a regional, autonomic government if they act outside of the Constitution, which is currently the case in Catalonia. Incidentally, over 90% of the Catalans voted in favour of the Spanish Constitution in 1978, a higher percentage than in the rest of Spain.