The publii-2pdf
plugin adds a floating PDF download button to Publii posts, enabling users to convert the post content into downloadable PDF files. This enhances user engagement and content accessibility, allowing readers to save or print articles for offline reading.
- Easy PDF Conversion: Converts any post into a PDF with just one click.
- Customizable Button Position: Users can configure the button to appear on the left or right side of the screen.
- User-friendly Design: Includes a hover effect for transparency and an intuitive close button for minimal intrusion.
- Download the plugin from the Release page.
- In Publii, go to "Plugins" > "Add new" and select the downloaded ZIP file
- Activate the plugin.
- Go to the "Plugins" section in the Publii app and enable the "Content to PDF Convert".
Navigate to the plugin's settings within Publii to customize:
- PDF Icon Position: Choose whether the PDF download icon should appear on the left or right side of the screen.
- Button Background Color: Customize the background color of the close button.
- Text Color: Set the color of the text within the close button.
After installation and configuration, the PDF download button will automatically appear on all your posts. Clicking the button will generate a PDF of the post content, ready for download.
After installation, the plugin allows for further customization to better fit your site's design and user experience preferences. For advanced styling or functionality adjustments, web developers can directly modify the source code or simply override the CSS for the following classes:
.pdf-download-button
: Controls the appearance of the PDF download button, including its position, background, and hover effects..pdf-download-button-close
: Adjusts the style of the close button, including its size, color, and positioning.
To customize the style, add your own CSS rules for these classes in Custom CSS
Publii section.
This plugin is released under the MIT License. See the LICENSE file for more details.