# DiscoTOC mobile view does not work with Docs

**URL:** https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329
**Category:** Bug
**Tags:** docs
**Created:** [February 16, 2022, 8:12am UTC](https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329 "2022-02-16T08:12:02Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)
#### Post date: [February 16, 2022, 8:12am UTC](https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329/1 "2022-02-16T08:12:02Z")

</div>

The DiscoTOC theme component does not use the mobile view correctly when the topic is shown via Discourse Docs.

This is what the ToC of a topic looks if viewed normally on mobile (button on bottom): [Administrative Bulk Operations](https://meta.discourse.org/t/administrative-bulk-operations/118349?mobile_view=1)

 ![image](https://global.discourse-cdn.com/meta/original/3X/f/0/f0e5bba7d802a8dae959f0c79027f819dc10a149.png)

And this is how it looks if viewed through the docs plugin on mobile (just like desktop): [Administrative Bulk Operations - Self-Hosting - Discourse Meta](https://meta.discourse.org/docs?category=55&topic=118349&mobile_view=1)

 ![image](https://global.discourse-cdn.com/meta/original/3X/7/3/7356514a1bff325c312f5fcdb1bcc152cf88ea2e.png)

---

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [February 16, 2022, 2:53pm UTC](https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329/2 "2022-02-16T14:53:26Z")

</div>

Good catch! I am able to repro this here on meta with the same topic as in screenshots above. @pmusaraj you reworked DiscoTOC recently so may have ideas on how to fix this.

---

<div class="post-metadata">

### Author: ![pmusaraj](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pmusaraj/32/119489_2.png) [@pmusaraj](https://meta.discourse.org/u/pmusaraj)
#### Post date: [February 27, 2022, 2:55pm UTC](https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329/4 "2022-02-27T14:55:01Z")

</div>

It’s not quick to add mobile support for TOC in docs pages, because a bunch of layout pieces from core would need to be rebuilt. For now, we can just hide TOC on docs mobile topics. Here’s a PR for that: [UX: Hide TOC on mobile docs topics by pmusaraj · Pull Request #32 · discourse/DiscoTOC · GitHub](https://github.com/discourse/DiscoTOC/pull/32)

---

<div class="post-metadata">

### Author: ![pmusaraj](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pmusaraj/32/119489_2.png) [@pmusaraj](https://meta.discourse.org/u/pmusaraj)
#### Post date: [March 12, 2022, 7:00am UTC](https://meta.discourse.org/t/discotoc-mobile-view-does-not-work-with-docs/218329/7 "2022-03-12T07:00:39Z")

</div>

This topic was automatically closed after 2 days. New replies are no longer allowed.
