React OAuth/OIDC in both host and remote microfrontends

We are working on a host/container microfrontend which has its own OIDC auth using PKCE flow. We are trying to integrate with another child microfrontend hosted in another domain and its also has its own auth in PKCE flow. We are using webpack module federation for integration and it loads the remote app at run time. The problem arises with the redirection of the child app which tends to redirect to its own domain. We tried using routing method to login first and redirect to container by registering container callback url but we have issues loading the routes from the child app.

Any help on how to achieve this will be helpful