Minor RFE: "hashtag" tag style

Right now, tags can be “simple”, “bullet”, or “box”. It’d be nice to have a mode where they’re displayed as #tag — after all, that’s how you can use them in post text (like, #tagging).

My current solution is:

/* hash before tags :) */
.discourse-tag.simple::before {
  content: "#";
}

/* defaults to comma */
.discourse-tags .discourse-tag.simple:not(:last-child)::after, .list-tags .discourse-tag.simple:not(:last-child)::after, .search-category .discourse-tag.simple:not(:last-child)::after {
	content: " ";
	margin-left: 1px;
}

/* keep from tagging votes! */
.list-vote-count::before {
  content: "" !important;
}

/* hash before tags in header */
.tag-title-header span::before {
  content: "#";
}

… however, that

  • doesn’t show in up in the filter dropdown — or rather, it does for every one but the selected tag, which offends my sense of Everything Must Be Perfectly Slick.
  • Does not work with tag intersections with Discourse Tag Banners, since the "& " is part of the actual text in that case. (So I get something like
    #silverblue# & gaming

Actually, in testing, I realized that the first post is true with the other tag decoration styles too — even though category color boxes are shown. Now my sense is doubly offended. :slight_smile:

1 Like

~~But, #foo is auto completed and auto marked up, as a category. ~~

It would be neat to have some special char for tags – like @ for users and groups, and # for categories …

hmm, I just learned something about tagging. :thinking:

As it is right now, # refers to both tags and categories. Try it! (Example: #tagging)

(I personally would prefer a different character for categories. I dunno, % or something.)