Catalysis of the reaction: S-adenosyl-L-methionine + tRNA = S-adenosyl-L-homocysteine + tRNA containing thymine at position U54 of a transfer RNA. This occurs in most Gram-negative bacteria, some archae, and eukaryotes.