Search code examples
jsfprimefacesvertical-scrollingprimefaces-gmap

Primefaces Googlemap Marker Infowindow : Disable vertical scroll bar


I am using Primefaces google map component. I have some markers and info windows for those markers. The problem I am facing is it is showing the vertical scroll bar. But I don't need the vertical scroll bar. How can I hide the vertical scrollbar?


Update: in the first screenshot you can see that the vertical scroll is not needed as all data vertically is already visible.

enter image description here

In the second screenshot you can see the horizontal scrollbar, we have to scroll down. I just want that the vertical scrollbar disappears and only the horizontal scrollbar remains, which should be always visible.

enter image description here


Solution

  • Add a min-height to your infoWindow class element.

    That will resolve the issue if your infoWindows are all the same size.

    If not, add this line of jQuery to your click function for the infoWindow:

    //remove overflow scrollbars
    $('#myDiv').parent().css('overflow','');