Triplanar mapping from Local Space - problem when scaling. How to make it work?

Bounds based stuff is no good, I know that much. If you rotate a cube, the bounds are all over the place!

bounds

The thing is, the standard nodes do work with rotation, it’s just that you want the texture to rotate with the object. ( right? ). Which is a UV thing, which is local.