Closed sander76 closed 5 years ago
You can modify your download link/icon/button using a theme_handler
. For example:
def modify_html(html: str, href: str) -> str:
soup = BeautifulSoup(html, 'html.parser')
sm_wrapper = soup.new_tag('small')
a = soup.new_tag('a', href=href, title='PDF Export', download=None)
a['class'] = 'pdf-download'
a.string = 'Download PDF'
sm_wrapper.append(a)
soup.body.footer.insert(0, sm_wrapper)
return str(soup)
Alright. Wasn't aware of that.. Thanks !
Great plugin !
I'd like to see the option to change the download icon. (Which I experience is not always clear to users, who are looking for the "pdf download" button)
For example, have the option to change it to: https://fontawesome.com/icons/file-pdf?style=solid
Or just have it change to text: "download pdf"