While you can generally restrict new ones, you can't eliminate existing ones without basically paying out the lost revenue+etc to whoever is running it.
There's been a moratorium on new billboards in SF for a long time already. No new ones are getting built. Given the reliable revenue they provide, will be a long time before they naturally go extinct.
You can actually just eliminate existing ones. The government can just do things and absolutely already does whenever politicians really want something to happen (data centers, etc.). There's no law of nature that billboards must be allowed to remain where they are.