If one of Facebook's users (anywhere in the world) posts a piece of copyrighted material, and that material is served to a European user, then the copyright owner can take Facebook to court for copyright infringement under this legislation. I'm not even sure the owner has to be a European entity.
European law considers the offence to occur in the browser's country, not the server's country (hence Yahoo having to block all references to Nazi memorabilia as a result of a French court case held in France under French law despite Yahoo not being a French company).
Mind you, the US takes the same viewpoint, hence them suing to extradite Mr Dotcom from New Zealand for trial in the US for transgressing US law. The fact that he wasn't a US citizen, MegaUpload wasn't a US company, and he had committed no crime according to New Zealand law didn't matter. The US still considered his breach of copyright to have occurred on US soil, so he had committed a crime on US soil.
At least that's how I read it... I am not a lawyer.
But in this scenario, Facebook would be blocking all EU users, based on IP address, DNS lookup, and so on. Just like Netflix blocks non-US users from accessing US-licensed media.
So EU users could only access Facebook through Tor, or VPN services. And Facebook could still argue (and make sure that it held no conflicting data) that it knowingly served no users in the EU.
I set up ublock/pi-hole for a reason :) If they GTFO EU then even better as EU pages won't load their spy scripts.
So anyway, Facebook was just an example. To show how social media etc providers could work around the EU Copyright Directive. By blocking access to all users known to be in the EU. If there are no apparent EU users, arguably the law doesn't apply. But then, IANAL.
Thankfully foreign laws don't magically propagate over the internet, even if a citizen of a country happens to point their web browser at your server.
Facebook does have a business establishment within the EU. They are selling ads in Europe that are delivered to EU users. There is no way that Facebook can claim not to be a European company in some sense.
Maybe that seems extreme and unlikely. But consider. What would Facebook be left with, if users couldn't share anything?
The problem is that not many have the clout of Facebook and Google to work out arrangements that won't kill them or fight the whole thing effectively.