The solution:
traitOverrides.horizontalSizeClass = .compact
does seem to work on iPads. However, it does not seem to work for iPad apps running on MacOS unfortunately.
On MacOS, it will show both the old traditional bottom tabbar, as well as the new one on top. And in my case at least, they can get out of sync with each other which is a mess.