It's not so much selective as dependent on (probably) temperature. If the dragonfire is above (to put an arbitrary number on it) say 700 Kelvin, whatever is inside the flame has enough energy that the teleportation can happen.
Oh, also, if it's the scrolls , why don't we see them getting thrown into a fireplace instead?