A clearly has the right of way.
I use common sense to figure out what rider B is going to do. As motorcyclist you are always scanning the road and have an exit plan for dumb as. like rider B.
If I see children, pets or a jogger with headphones on running in the middle I always slow down. I have seen a noob jogger with giant head phones just make a random u-turn without looking right in front of me. The fast serious joggers that always stay right or left or predicable and never do anything dumb.
What I hate is the same scenario you have in post one but TWO bike side by side B&B will pass the pedestrians at the same time. Like WTF dude.