PdfBrowserViewer open PDF in new navigator tab

Hi how to open a pdf with PdfBrowserViewer, in a new navigator tab?

Hi.

Are you using the Vaadin10 add-on [PDF-browser]
(https://vaadin.com/directory/component/pdf-browser)?

I would suggest having a link that opens a new tab to a Route that contains the pdf viewer.
Or programmatically use for instance UI.getCurrent().getPage().executeJavaScript("window.open(\"http://vaadin.com/\", \"_blank\");"); to open the pdf view in its own tab.

  • Mikael

Hi,
I’m using PDF-browser.
Yes, the solution is to create a dedicated view containing the pdf viewer.
I used ([browser-opener]
(https://vaadin.com/directory/component/browser-opener/overview)) wrapped to a button, to open the view that contains the pdf viewer.
Thanks,
Jose