Cannons appeared before rifles because a large, round stone has a 100% chance of killing, but in a fantasy setting, a simple cannon is easily countered by magic, and it's also inconvenient for dwarves to shoot in caves. Therefore, the pinnacle of firearms should be a handheld cannon, similar to a gremlin-style one (surprisingly), and its predecessor should be a shotgun (dwarves-gangsters approve and sponsor!).
A weapon with a single, small bullet can only become widespread on the surface (for hunting). This raises the question: will anyone even consider firearms as a ranged weapon? Probably, heavy crossbows will be used at long distances.
Of course, a gnome enthusiast might develop long-range rifles, but it will likely be a rare case, like the rapid-fire crossbow "Bianca" from Dragon Age.