In yesterday's Brexit vote, the 30,000 or so residents of the tiny British territory of Gibraltar voted overwhelmingly to remain in the European Union, with 95.9% casting their ballots to stay in the EU. But, of course, that was not what the rest of the UK ultimately decided.

For Gibraltarians, the UK's vote to leave the EU is an unmitigated disaster. It has reignited a centuries-old fight between Britain and Spain that has the potential to alter the lives — and national identities — of the people of Gibraltar.

That's because Spain believes that Gibraltar is rightfully its territory, and the Spanish government warned that if the UK voted to leave the EU, Spain would immediately push to try to reclaim control over Gibraltar.

And, as promised, shortly after the vote results were announced, the Spanish government called for joint sovereignty over Gibraltar.

Gibraltar has been a British territory for 300 years

Gibraltar is a 2.5 square mile peninsula at the tip of Spain that has been under British control for more than 300 years. And Spain really wants it back.

British and Dutch forces captured Gibraltar from Spain in 1704 during the War of the Spanish Succession, and Spain ceded Gibraltar to Britain in the 1713 Treaty of Utrecht at the end of the war. Gibraltar has remained under British control ever since, despite Spain’s multiple attempts to take it back.

The majority of Gibraltarians, however, are British citizens who hold British passports and who adamantly do not want to be part of Spain.

In a referendum held in 1967, Gibraltarians voted overwhelmingly to remain a British dependency. The subsequent UK grant of autonomy in 1969 led Spain to close its border with Gibraltar and sever all communication links. It wasn’t until 1985, ahead of Spain’s accession to the EU, that Spain finally reopened the border.

In 2002, the people of Gibraltar voted in a referendum on whether the UK and Spain should share sovereignty — and again, Gibraltarians overwhelmingly voted to remain under the sole control of the Brits.

Gibraltarians want to be part of the UK and the EU

The vast majority of Gibraltarians were in favor of the UK staying in the EU in large part because of the economic prosperity being part of the EU has brought them.

But they also wanted the UK to stay in the EU because they feared if the UK voted to leave, Spain would immediately try to reassert its claim to Gibraltar. Indeed, those fears seem to have been justified. Spain’s acting Foreign Minister José Manuel García-Margallo warned that his country would demand control of Gibraltar the "very next day" after a British exit from the EU. And that's precisely what Spain did.

Gibraltar's Chief Minister Fabian Picardo said that Gibraltar’s political leaders had "fought to ensure that Gibraltar is able to vote in the Brexit referendum so that we can influence that decision." Unfortunately, it seems their influence wasn't quite as influential as they'd hoped it would be.