# Theme components issue

**URL:** https://meta.discourse.org/t/theme-components-issue/305761
**Category:** Support
**Created:** [April 28, 2024, 7:51am UTC](https://meta.discourse.org/t/theme-components-issue/305761 "2024-04-28T07:51:30Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![Genisis](https://avatars.discourse-cdn.com/v4/letter/g/f475e1/32.png) [@Genisis](https://meta.discourse.org/u/Genisis)
#### Post date: [April 28, 2024, 7:51am UTC](https://meta.discourse.org/t/theme-components-issue/305761/1 "2024-04-28T07:51:30Z")

</div>

I tried adding the theme selector to my instance but it doesn’t show up, I’ve updated, disabled it and re-added it, cleared cf cache, rebuilt instance. First one I added was dark mode switcher, worked for a few days then Idr what I did then it stopped working, I remember this being a thing some years ago but shocked it’s still happening.

---

<div class="post-metadata">

### Author: ![ondrej](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ondrej/32/198804_2.png) [@ondrej](https://meta.discourse.org/u/ondrej)
#### Post date: [April 28, 2024, 9:03am UTC](https://meta.discourse.org/t/theme-components-issue/305761/2 "2024-04-28T09:03:17Z")

</div>

Are you using this TC?

> [@Sidebar Theme Toggle](https://meta.discourse.org/t/sidebar-theme-toggle/242802):
>
> discourse2Summary Sidebar Theme Toggle adds a theme selector in the sidebar menu’s footer provided there is more than 1 user selectable theme. This selector works with both logged-on users and anonymous users. Be sure to add this to all your user-selectable themes for easy toggling.hammer_and_wrenchRepository Link [https://github.com/discourse/discourse-sidebar-theme-toggle](https://github.com/discourse/discourse-sidebar-theme-toggle)open_bookNew to Discourse Themes? [Beginner’s guide to using Discourse Themes](https://meta.discourse.org/t/beginners-guide-to-using-discourse-themes/91966) Install this them…

---

<div class="post-metadata">

### Author: ![Genisis](https://avatars.discourse-cdn.com/v4/letter/g/f475e1/32.png) [@Genisis](https://meta.discourse.org/u/Genisis)
#### Post date: [April 28, 2024, 12:23pm UTC](https://meta.discourse.org/t/theme-components-issue/305761/3 "2024-04-28T12:23:51Z")

</div>

That’s correct, even tried this tc and it worked for a dew days and I think I disabled it to try the theme selector and it stopped working when I enabled it back

> [@Dark/Light Mode Toggle](https://meta.discourse.org/t/dark-light-mode-toggle/215585):
>
> discourse2Summary Dark/Light Mode Toggle adds a clickable toggle color scheme button in the hamburger menu. The toggle switches between a light or dark color scheme for one theme.hammer_and_wrenchRepository Link [https://github.com/discourse/discourse-color-scheme-toggle](https://github.com/discourse/discourse-color-scheme-toggle)open_bookNew to Discourse Themes? [Beginner’s guide to using Discourse Themes](https://meta.discourse.org/t/beginners-guide-to-using-discourse-themes/91966) Install this theme component Features This component allows a dark/light mode toggle icon on your Discourse forum. It…

---

<div class="post-metadata">

### Author: ![jenmck](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jenmck/32/332487_2.png) [@jenmck](https://meta.discourse.org/u/jenmck)
#### Post date: [April 29, 2024, 10:25am UTC](https://meta.discourse.org/t/theme-components-issue/305761/4 "2024-04-29T10:25:21Z")

</div>

Have you tried using it with different themes? What theme are you using?

---

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [April 29, 2024, 11:50am UTC](https://meta.discourse.org/t/theme-components-issue/305761/5 "2024-04-29T11:50:34Z")

</div>

Can you check if the theme component is attached to your theme?

Also, do you see any error in the browser’s console?

---

<div class="post-metadata">

### Author: ![awesomerobot](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/awesomerobot/32/142900_2.png) [@awesomerobot](https://meta.discourse.org/u/awesomerobot)
#### Post date: [April 29, 2024, 1:35pm UTC](https://meta.discourse.org/t/theme-components-issue/305761/6 "2024-04-29T13:35:26Z")

</div>

A few things to check. First I’d make sure that Discourse and the theme component are up to date.

I would then try using the preview button at the bottom of the theme component’s setting page — this will show the theme component in isolation.

If the preview works, there’s likely a conflict with another theme. If it’s not working in preview I would check if you have `Theme can be selected by users` enabled on at least 2 themes, which is a requirement for the component to work.

If it’s still not working, maybe right click the page, select inspect, and check for any errors in the console.

---

<div class="post-metadata">

### Author: ![Genisis](https://avatars.discourse-cdn.com/v4/letter/g/f475e1/32.png) [@Genisis](https://meta.discourse.org/u/Genisis)
#### Post date: [April 29, 2024, 3:42pm UTC](https://meta.discourse.org/t/theme-components-issue/305761/7 "2024-04-29T15:42:34Z")

</div>

Turns out it was me. I didn’t add another theme to the site, I assumed color pallets were “another theme of my default theme”, but still doesn’t explain why the dark mode switcher stopped working. Yes I did everything correctly.

---

<div class="post-metadata">

### Author: ![Genisis](https://avatars.discourse-cdn.com/v4/letter/g/f475e1/32.png) [@Genisis](https://meta.discourse.org/u/Genisis)
#### Post date: [April 29, 2024, 3:43pm UTC](https://meta.discourse.org/t/theme-components-issue/305761/8 "2024-04-29T15:43:11Z")

</div>

Turns out I didn’t do this! I feel so stupid

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [May 29, 2024, 3:43pm UTC](https://meta.discourse.org/t/theme-components-issue/305761/9 "2024-05-29T15:43:55Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
