I have an MAUI blazor project. I am running it on an iPad using MAC. In that project, I am performing the drag operation based on the browser name present on the browser userAgent(Type navigator.userAgent in the browser developer tools). Normally the userAgent property contains the name of the browser in it. However, upon running the MAUI blazor project on an iPad device. If I check the browser developer tools in Safari browser it doesn’t contain the browser name. Because of that, I am having trouble handling the drag operation. Can anyone help me find out why the browser name is missing? Also, let me know if it’s possible to set the userAgent manually in the MAUI Blazor project.
userAgent string upon running the MAUI Blazor project on iPad:
“Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko)”
userAgent string upon a webpage opened in the browser:
“Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.6.6 Safari/605.1.15”
I am binding the touch or pointer events for handle drag operation based on the userAgent browser name. But, when running the MAUI Blazor project on iPad the browser developer tool userAgent property is missing. I am expecting that the browser name should be present in the userAgent. So, based on that I can handle the drag operation.
MAUI Blazor Developer is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.