On balance, it was. But there’s an interesting wrinkle. Law 19 (Boundaries) and Law 33 (Caught) are the relevant laws in this case. Law 19.5 specifies when a fielder is considered to be ‘grounded beyond the boundary’.
19.5.2 A fielder who is not in contact with the ground is considered to be grounded beyond the boundary if his/her final contact with the ground, before his/her first contact with the ball after it has been delivered by the bowler, was not entirely within the boundary.
This is not relevant in Deol’s case because the highlighted portion of 19.5.2 is not satisfied. Deol was within the field of play when the ball was delivered and her first contact was from within the field of play.
The doubtful part lies in a requirement specified in the MCC’s explanation of the law. Explanations are important because they reveal what is intended by a particular law. The explanation (narrated by Stephen Fry) says that the fielder “can then step back into the field of play to complete the catch”. Deol did not do this. But Law 19 and Law 33 do not explicitly prohibit what she did (dive back into the field of play from outside the boundary, but catch the ball before she landed back into the field of play)
Here’s another interesting case. This case does not have the problem which Deol’s case has, because the fielder who completes the catch (and who will be credited with the catch) is within the field of play.
So was Deol’s catch legal? On balance, within the letter of the law, yes it was.
The fact that explanation explicitly says that the fielder must step back into the field of play to complete the catch suggests that even though the Laws are silent on Deol’s specific case, they did not intend that it be allowed.
The ICC ought to either amend the explanation (ideally, using Deol’s brilliant example to illustrate the point), or amend the law.