How do I get more critical captures?

I'm not sure what the technical terms are, but whenever I've played pokemon games and successfully threw a ball to catch one, the ball always wiggled three times before clicking and confirming the catch.
Now, I'm playing Pokemon Violet and this weekend I noticed that some of the balls I throw, the animation is slightly different and it only happens to wiggle once before clicking. Of course, I much prefer this, as I've had no pokemon escape between the wiggle and the click. But I'm not sure what I was doing that caused these, I haven't been able to determine a pattern.
Is this a random thing, or can I take specific steps to get more of these onewiggle catches?

What you are describing is the Critical Capture mechanic that was added in Generation V (Black and White). It is a special type of capture mechanic that is much more likely to catch a Pokemon. There is a chance that the Pokemon can escape from the ball however I personally have never seen a Critical Capture fail.
The chance of it occuring is as follows:
Species Caught In Pokedex Multiplier >600 2.5 451  600 2 301  450 1.5 151  300 1 31  150 0.5 < 31 0 (Please note, this equation is for Generation VIII. I cannot find the equation for Generation IX but it will be similar)
First, get the modified catch rate (result of equation above) of the pokemon you are catching and multiply it by the multiplier from the table above based on how many Pokemon you have caught in your Pokedex
If you own the Catching Charm, multiply the value by 2
Divide the result by 6 and round down to the nearest integer
A random number between 0 and 255 is generated. If this random number is less than the value calculated, a critical capture occurs
So, to answer your original question. You can make critical captures more likely by filling up your pokedex and obtaining the Catching Charm. Do note, I have only found one site that claims the Catching Charm is in Scarlet and Violet so at this stage, it appears as if it is not a part of the game.
Source: https://bulbapedia.bulbagarden.net/wiki/Catch_rate#Critical_capture