Oddly enough, there are screen-sharing and/or remote-display protocols which ... are limited to sharing screen-drawing properties and aren't wholesale data vacuums. X11 and remote desktop come particularly to mind.
Several of those can be limited to specific applications, e.g., by setting the $DISPLAY value (X11). For remote desktop that's a bit more challenging but can be managed to an extent using Group Policy settings under MS Windows:
> CarPlay is just your phone using the car’s screen
Then why does iOS warn me that my car will receive data from my phone when enabling car play? Does this just mean the screen, or does it get the texts/calls too?
Not sure on what exactly this is referring to, but I know contact names are exposed, at least when there’s an active phone call. My vehicle shows the contact’s name on the driver display (which CarPlay doesn’t control)