Fix weird bug where popover would blink on normal pages, and show up forever on pdfs