אייקוני קטגוריות

Try this:

.select-kit .category-badge-icon {
    display: none;
}
לייק 1

That did it. Thank you for the help! I think Discourse navigation is fine as-is but for now I have to implement this small feature for these users and hopefully I can remove it at some point in the future. It’s more of a stop gap fix for the moment.

2 לייקים

Hi,

Is it just me, or does this component not recognize name changes in slugs?

I doesn’t seem to recognize category slugs with changed names in my case, not right away anyway.

לייק 1

I use the dark mode component as well.

So that makes it a bit difficult to use this for the main categories. Because the icon shows up next to the main category. I now use “categoryColor”, which is red. That works for both the dark and light mode on my forum. But then the icon is not visible in the category selection menu. Because it has the same color as it. So there is just a blank space. Is there a way to fix this? Use an alternative color for the category dropdown menu? Because when “categoryColor” is used, the icon is not visible anymore. Would be great to have a white color for the icon there.

לייק 1

Ah, well, #cfcfcf works fine in both dark and light mode. Other option is also to use emojis of course :slight_smile:

לייק 1

I’d like to use an icon that is only available with a Font Awesome Pro subscription (specifically this icon). How can I do so with this theme component?

לייק 1

You need to first install this plugin:

FontAwesome Pro icons

And then the pro icons should be available for use for you, including for this component.

3 לייקים

Thank you, Penar, I’ll take a look at this. I’m having some unrelated trouble rebuilding the forum, and haven’t been able to test this out yet.

2 לייקים

I’ve noticed that this only works on Categories, not Sub-categories.

3 לייקים

Further to this, it works everywhere except where sub-categories are displayed as boxes above a category list. It works fine as rows above a category list.

For some reason categoryTitleLink isn’t being applied to the boxes.

Any idea why this is the case? I suspect that it might be a (small) problem in core.


later…

This has been fixed by the wonderful Discourse team. For some reason you need to remove and re-install this Theme Component for it to work though:

3 לייקים

I actually would love if this let me also put emojis instead of just FontAwesome icons. Is this currently possible?

The example is I want to have a Welcome category and I think the :wave:t2: emoji seems to be a more and more standard way to do it.

2 לייקים

You can add an emoji to the category name using your native emoji picker in your OS.

4 לייקים

Ah, that seems simple enough :relaxed: Thank you!

2 לייקים

Where to set it? Modify the code or function toggle switch

לייק 1

Would it be possible to use uploaded pics with url link?

לייק 1

No, I don’t think so.

3 לייקים

I’ve specified a Font Awesome icon to replace the default padlock icon. Curiously, it appears to be smaller than the other icons… Makes for wonky alignment of the text (in addition to the icon itself being extra-tiny) in category dropdowns and in the ≡ menu’s category listing…

לייק 1

How can i change the color for this from orange to blue ?
Screenshot at 2022-02-13 14-22-33

לייק 1

Discourse-team gave me a little work-around that can be added to Theme CSS:

// FIX - New lock icon on private categories
svg.fa.d-icon.d-icon-user-plus.svg-icon.svg-string {
    font-size: 1.3em;
    align-self: center;
}
2 לייקים

I’m experiencing a problem where the category slug doesn’t seem to respect hyphens in exact names.
For example if I have category slugs:

beta-testing
beta-testing-bugs
beta-testing-features

Then I add the following theme component entires:

beta-testing,trash-alt,categoryColour
beta-testing-bugs,trash-alt,categoryColour
beta-testing-features,trash-alt,categoryColour

Only the first category takes the “trash-alt” icon and the others don’t display any icon
If I remove the hyphens it seems to work

categories:
beta-testing
betatestingbugs
betatestingfeatures

theme component entries

beta-testing,trash-alt,categoryColour
betatestingbugs,trash-alt,categoryColour
betatestingfeatures,trash-alt,categoryColour

This is a work around but it kinda breaks the naming convention for slugs. Am I doing something wrong or is this a bug?

2 לייקים