# Inline PDF Previews

**URL:** https://meta.discourse.org/t/inline-pdf-previews/157649
**Category:** Theme component
**Tags:** official, desktop, pdf-previews
**Created:** [July 13, 2020, 9:18pm UTC](https://meta.discourse.org/t/inline-pdf-previews/157649 "2020-07-13T21:18:10Z")
**Posts on this page:** 1
**Showing post:** 166

<div class="post-metadata">

### Author: ![shortmort37](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/shortmort37/32/538876_2.png) [@shortmort37](https://meta.discourse.org/u/shortmort37)
#### Post date: [March 24, 2026, 8:46pm UTC](https://meta.discourse.org/t/inline-pdf-previews/157649/166 "2026-03-24T20:46:31Z")

</div>

I submitted a PR adding mobile support and PDF.js integration to this component  
5+ weeks ago, but haven’t received any feedback yet. Since others might find it  
useful, I’m sharing my enhanced fork:

[https://github.com/shortmort37/discourse-pdf-previews](https://github.com/shortmort37/discourse-pdf-previews)

Key improvements:

- Mobile device support (removes the mobile block)
- PDF.js rendering with page navigation and zoom controls
- Thumbnail previews in “New Tab” mode
- Works with PDFs lacking .attachment class (great for migrations)
- Pinch-to-zoom on mobile

I’ve been running this on [59plymouth.net](https://59plymouth.net) for 2+ months with  
converted phpBB content - works great on both desktop and mobile.

Installation: Admin → Appearance → Themes → Install from Git → paste the URL above

PR is still open if the maintainers want to review: [Add PDF.js integration with mobile support by shortmort37 · Pull Request #49 · discourse/discourse-pdf-previews · GitHub](https://github.com/discourse/discourse-pdf-previews/pull/49)

---

_[View the full topic](https://meta.discourse.org/t/inline-pdf-previews/157649)._
