Many things are possible.
I still prefer the supply under the fill valve on the toilet. (left side)
They make some toilet supplies 24" long.
You can take a lav supply and a 1/2"x7/8" toilet supply and join them with a brass nipple and make it work too.