In desktop, Instance is showing in Mobile View by default

saurabhshinde
Tera Contributor

Instance is showing in Mobile View by default even though I'm using desktop/laptop. For all users whom are using this instance it is showing like that. How to change the view to Desktop-view again?

I tried adding ?sysparm_device=desktop in url and it is changing to desktop view but when I open something from Nav Bar then it is opening in mobile view. Also portals are showing in Mobile view.

Can someone please provide a solution for this? 

Thanks! 

9 REPLIES 9

@Hampus1 

We are also stuck at this point, did you get around this issue ?>

 

We talked with ServiceNow support and they told us that they couldn't help us since it would mean that we would have to customize our instance. We haven't decided which way to go yet but I think our best options are to either remove some buttons from the header (or combine them) such as the "my activities, tasks, favorites" OR to try and make the search bar in the header shorter.

 

I'll update this thread if we come to any conclusion that solves the issue.

@Hampus1 , 

If you are fine with customizing your header (Employee Center Header) for the employee center, clone and change the code in the link part of the header widget

condition for font size currentFontSize, as shown in bold code

This will fix the issue

 

 var currentFontSize  = parseInt($('body').css('font-size'));
    var constantOffset = 50;
    var flexOffsetWidth = constantOffset * (currentFontSize / 16);
    if(currentFontSize < 30) { //changed from 16 to 30 to handle mobile menu
      scope.$apply(function() {
        scope.mobileDevice = controller.data.isMobile || (window.innerWidth <= controller.MOBILE_DEVICE_SCREEN_WIDTH);
      });
      return;
    }
Revert incase of any other queries 🙂 
 
If you find this helpful, mark as helpful. 
 

Thank you for posting this! This issue has been plaguing our instance for a long time, this adjustment to link code worked

NicolasQ
Tera Contributor

Hi !  To canceled showing Mobile View > Click on your profile avatar >Go to > Accessibility > switch OFF "Enable accessibility in classic".