Right-click an image, and it’s already a PDF.
A Chrome extension that adds a “Save image as PDF” item to the context menu. It works on any page, everything happens locally in the browser, and images are never uploaded. It is available in the Chrome Web Store and has a website.
Key Features
- One click: right-click an image on any page and pick “Save image as PDF”.
- No uploads: the PDF is built locally in the browser.
- Settings in the side panel: all settings live in the extension’s side panel. It reminds you about itself a few times and stays out of the way once you’ve met it.
Technical Approach
The extension runs on Manifest V3, and a service worker listens for context menu clicks. Chrome lets an extension open its side panel only in response to a user action, which means before the first await in the click handler. So the state that decides whether to show the panel lives right in the context menu item’s id. Details are in the article A Right-Click with a Memory: Why I Store a Counter in a Chrome Menu Item’s id.
Links
- Chrome Web Store - extension
- pdf-to-png.app/png-to-pdf - website
- PDF to PNG - the reverse: PDF to images