Data shared by reference through distributed collaboration from ArcGIS Enterprise (AGE) to ArcGIS Online (AGO) should not prompt for credentials when being accessed in AGO when the AGE item is not shared with Everyone.
There should be some kind of backend authentication that happens when AGE is joined to ArcGIS Online through a distributed collaboration. Then when someone in AGO has permission to access the item on the AGO side they are not prompted for AGE credentials.
The lack of this makes me question what the point of distributed collaboration is for shared by reference data.