Media playback is unsupported on your device Media caption What happened in British politics over Brexit on Tuesday?

It's been a very big day in British politics.

The government has suffered a major defeat, with potentially significant consequences for Brexit - specifically when it happens and how it happens.

An early general election is now also on the cards.

Here's your guide to the bruising face-off between parliament and Prime Minister Boris Johnson.

This is all about who's driving Brexit ahead of the 31 October deadline for the UK to leave the EU.

Mr Johnson has been determined to leave by that date with or without a deal.

On Tuesday, politicians opposed to "no-deal" grabbed the steering wheel to block this outcome. They voted to seize control of the parliamentary agenda on Wednesday.

They plan to pass a law to force Mr Johnson to delay Brexit until 31 January unless MPs approve a new deal.

However Mr Johnson won't ask the EU for more time. He said the government would instead seek an early election.

But it's unclear if two-thirds of MPs will agree, as required.

How did we get here?

The British public voted to leave the EU well over three years ago.

In order to do that, the last prime minister, Theresa May, negotiated a deal with the EU covering the terms on which the "divorce" would happen. Break-up day was meant to be 29 March 2019.

Then, as now, parliament disagreed with the government. Mrs May couldn't get her deal through and was forced to ask for Brexit to be delayed. Eventually she stepped down.

Boris Johnson was voted in as the new leader by members of the Conservative Party and became prime minister in late July.

He vowed to take Britain out of the EU by the new deadline of 31 October, "no ifs or buts".

But like her, he now finds himself defeated in Parliament, including by some of his fellow Conservative politicians.

Why can't he do what he wants?

It's all about numbers. Boris Johnson, on Tuesday morning, had a working majority in parliament of one.

By late afternoon this razor-thin majority vanished when a Conservative MP defected to the pro-EU Liberal Democrats.

The arithmetic meant it was always going to be hard for the government to defeat a motion supported by a large group of MPs from many parties opposed to a no-deal Brexit.

Media playback is unsupported on your device Media caption The moment Tory MP Phillip Lee defects to Lib Dems

A major headache for Mr Johnson was that a group of his own MPs had made clear they were likely to rebel and vote for the motion.

This "rebel alliance", which in the end numbered 21 lawmakers, agrees with a cross-section of MPs that a no-deal Brexit would cause economic chaos.

So they helped to take the parliamentary agenda out of the government's hands - the first step in passing a law to block no-deal.

Such are the bitter divisions in the Conservative Party that they did this despite being warned they would be effectively kicked out of the party.

It's worth noting that Nicholas Soames - the grandson of Boris Johnson's political hero Winston Churchill - is among them.

I thought time was tight?

It is. Big Ben is undergoing repairs but the minutes are still ticking away in Westminster.

This is because of Mr Johnson's decision to ask the Queen to suspend parliament from sometime next week - squeezing the amount of time that MPs have to avert no-deal.

They will kick off the process on Wednesday by introducing legislation that could become law next week if it passes all hurdles.

If it does, this would tie Mr Johnson's hands and compel the government ask for another Brexit delay.

Please upgrade your browser Your guide to Brexit jargon Enter the word or phrase you are looking for Search

So where does the election come in?

Mr Johnson has said there is no way he will ask the EU for another Brexit delay.

He has also said many times that by taking no-deal off the table, MPs will torpedo the UK's negotiations with the EU.

After the government lost the vote, he said he was ready to call for an October election.

Why would Boris Johnson do this? We talked about numbers. Mr Johnson will hope his party could win a new majority in parliament that would make his Brexit plans much easier. Polls currently put the Conservatives at a healthy lead over Labour.

But many Conservatives fear that any election in an unpredictable political environment risks a hard-left government led by Jeremy Corbyn, the leader of the opposition Labour Party.

Some Westminster watchers believe that Mr Johnson actually doesn't want an early election at all. Two-thirds of MPs would need to vote for one and while Labour has long called for an election, Mr Corbyn said it would only back one once a no-deal Brexit is ruled out in law.

Some MPs are worried Mr Johnson could call an election and later change the date to after 31 October, the current Brexit deadline.

If that happened he could tell voters he achieved Brexit, no ifs or buts.