Amazing, works perfectly Steven, thank you so much!
PSA, it looks like something on this broke recently. I’m now getting:
[Admin Notice] Theme ‘Created Topic Sort’ contains code which needs updating. (id:discourse.modify-class-model)
And this in my console logs:
DEPRECATION NOTICE: Using api.modifyClass on `model:topic` is deprecated. Use the `addModelField`, `addModelAccessor`/`addModelGetter`/`addModelSetter`, `addModelMethod`, `addModelSaveProperty` and `addModelCallback` APIs instead. [deprecated since Discourse 2026.8] [deprecation id: discourse.modify-class-model]
Updated! Thank you for letting me know!
As far as I can tell, nothing is broken, just a deprecation notice. If you’re running on Discourse v2026.7 or later, you should be able to update the theme component and the warning will be cleared.
This is great, thanks! Could it be forked or updated to allow A-Z ordering, or is that a completely different thing?
Hope you don’t mind the direct ask – I’m not a coder. Right now I’m using a clunky vibe-coded workaround to get that ordering on our ‘glossary’ category.
That’s out of scope of this TC, and I don’t think that’s currently possible to do cleanly as one either. This TC relies on the available order= options in TopicQuery, which includes options such as likes, views, participant count, but nothing like “title” for alphabetical order.
I think /filter supports order:title, in which case you might be able to do something like adding a quick link at the top of the category that links out to the filter will the query already filled
You could also consider using the Discourse Doc Categories plugin to help with indexing your category. It’ll only affect the sidebar though.