Hi
This is what IFAB Q&A says
""
Q6 Why is an offence against someone who is not an opponent now a direct free kick? Does this include dissent/offensive language?
If, for example, a player strikes a team-‐mate, substitute, team official or, perhaps even worse, a match official this is serious...