For one on my forum, I got rid of this message simply by moving my JS script to the new JS customization tab.
On my other forum, it doesn’t work that easily.
It’s an old override that shows the composer’s tag field only in categories that accept tags:
This script was heavily based on a similar (and old, 2019 or older) modification posted on meta, but I can’t find the original post anymore.
Anyway, there are two questions in one:
How to properly move this in the JS tab? Is it possible, or should I create a theme component?
Is there a more elegant way to hide/show the composer’s tag selector only in certain categories? I use tags for only 1 category on my forum (an ads category with #search and #offer tags)
It doesn’t solve it for staff [1], but if you set the tags as restricted to that category, they won’t be usable (by non-staff) on other categories. From a category /edit/tags:
Tags and tag groups specified above will only be available in this category and other categories that also specify them. They won’t be available for use in other categories.
It should be possible to just copy/paste it. Stuff in the JS tab is run in exactly the same way as <script type='text/discourse-plugin>. If it’s not working, can you share the code?