I had the same problem. I mentioned it on the Mendix slack community. Mendix responded that in Mendix 10.6 there will be some dependency updates. https://mendixcommunity.slack.com/archives/CMVNKFMC0/p1695125805643379
For now I ended up removing the dependency and workaround the broken parts.
But maybe using NPM package aliases is a valid option? https://medium.com/weekly-webtips/how-to-install-multiple-versions-of-the-same-package-in-npm-71c29b12e253
Please let me know if this helps.