I have a dog and an extendable lead - admittedly he (the dog - not sure about the lead

) is quite barmy so always keep the lead locked when faced with two wheels (motorised or not) as Otis has a particular passion for cylists - he says it's called playing but I'm not sure.
You did extremely well not to hit the dog, drop the bike, or give her a mouthful. Her response is known as guilt. In my experience dogs (at least Airedales) are like children - you never know when they'll do something quite (barking?) mad; unfortunately putting children on leads is generally regarded as extreme...