Sticky New Topic Banner

AI-generated summary

The Sticky New Topic Banner theme component by Don ensures the new topic notification banner remains visible — sticking to the top on desktop and optionally fixed to the bottom on mobile, even with Discourse Tab Bar for mobile. It supports text alignment customization and works with iOS footer navigation. Decorbuz suggests it should be part of Discourse core. davidkingham reported a deprecation warning related to controller:discovery/topics, which Don promptly fixed in a commit. The component is available on GitHub: VaperinaDEV/discourse-sticky-new-topic-banner, with installation guidance linked to official Discourse theme docs. Credit is given to @Johani for the original concept here.

Hello :wave: With this component the new topic banner will stick to the top of the page under header or on mobile fixed to the bottom of the page. So you can see always wherever you on topic list if there is a new or updated topic.

On Desktop view

On Mobile view (both position top and bottom with Discourse Tab Bar for mobile)

There are two position on mobile and one on desktop.

  • Sticky (top) works on desktop and mobile
  • Fixed (bottom) works on mobile

On fixed to bottom position also support footer nav on iPhone / iPad and Discourse Tab Bar for mobile.

You can also change the new topic banner text alignment to center.

Theme Settings

Credit :heart: This theme component is made from @Johani perfect solution: Sticky see new or updated topic notification - #2 by Johani | Thank you Joe!

21 Likes

Honestly, that belongs in the core version of Discourse.

4 Likes

I don’t know if this really needs to be fixed, but I’m seeing this warning in the console:

[Warning] [THEME 203 'Sticky New Topic Banner'] (chunk.c299dadf3652266cf24c.d41d8cd9.br.js, line 47)
"Deprecation notice: controller:discovery/topics no longer exists, and this shim will eventually be removed. To fetch information about the current discovery route, use the discovery service instead. [deprecation id: discourse.discovery-topics-controller]"
1 Like

Thanks @davidkingham! I’ve merged an update to fix this: DEV: Modernize modifyClass · VaperinaDEV/discourse-sticky-new-topic-banner@1cea3ed · GitHub

2 Likes