Commit Graph

6 Commits

Author SHA1 Message Date
Angus McLeod ff09b877f1
Add category targeting (#4)
Co-authored-by: Dan Ungureanu <dan@ungureanu.me>
2021-04-14 13:16:37 +03:00
tshenry 8e24b2ceca
REFACTOR: Simplify logic and use Category.findBySlugPathWithID (#9)
This change swaps out `Category.findById` with `Category.findBySlugPathWithID`. It ends up reducing the necessary code and handles the scenario of using a link without a numeric ID (e.g. `/tags/c/some-category/some-tag` instead of `/tags/c/some-category/4/some-tag`).

This also simplifies the routing logic in line with what was discussed in https://github.com/discourse/discourse-category-banners/pull/8. There's no need to create an `isCategoryTopicList` variable, especially now that the code is a little less busy.
2021-02-01 12:17:26 -08:00
tshenry 93f0a1f556
FEATURE: Support filtering by tag (#8)
Ensure the banner will remain visible when filtering a category by a tag.
2021-01-21 18:07:30 -08:00
Renato Atilio eeced5b1c4
Setting to show category icon from discourse-category-icons theme component (#7) 2020-11-30 09:46:44 -05:00
Joffrey JAFFEUX 9be0d88905
FEATURE: adds a setting to choose which connector to use (#5)
above_site_header or below_site_header, default is below_site_header
2020-09-28 13:26:06 +02:00
jjaffeux ac66be7948 REFACTOR: full component refactoring
- drops jquery
- uses new codelayout structure
- more explicit site setting
- apply code standards
- various cleanups
- do not show an empty category-title-desription if we don't show the category description
2020-09-27 11:26:40 +02:00