Open a ticket
Chat with us
Click or drag to resize

Creating custom CSS theme

If you would like to use yours icons for the buttons or/and change colors of the TWPdfViewer, you can. Take some of the existing CSS themes (like css/light/tw-pdf-viewer-light.css) as a template, change its colors and src to your image buttons files.

On your HTML page, instead of link to:

HTML example
<link rel="stylesheet" id="tw-web-theme" href="/_content/Terminalworks.PdfViewer.AspNetCore/css/tw-pdf-viewer-light-theme.css"

use:

HTML example
<link rel="stylesheet" href="{path_to_your_css}" />
Caution note Caution

You can use multiple instances of the viewer on the same page, but it isn't possible to use different CSS theme. CSS viewer theme is loaded per page and affects all the instances.

See Also
Copyright © 2024 Terminalworks. All Rights Reserved