タググループごとにタグを並べ替える

Hi,

How can multiple tags in a topic be ordered? I have two tag groups: “Verified” and “Other Tags”. Can I order them from verified to other in topics?

image

I’d like it to be ordered like the 2nd topic in the picture. Right now tags are ordered by the order the user selects them when creating a topic.

It’s not possible because we don’t add any classes or attributes to designate which tag-group a tag belongs to.

We already have data-tag-name='example-tag'… it might also be useful to have data-tag-group='example-group'if a tag is in a group (I’m not sure how difficult that change would be though). Then you’d be able to target tag groups with CSS.

@awesomerobot

CSSでタグ名をターゲットにする場合、その達成に最適な方法は何でしょうか?

単純な float: left を使用しましたが、押し出されたタグのアライメントが崩れてしまい、異なる場所で不自然なピクセル調整を行わないと整列させることができませんでした。

特定のタグを先頭に並べ替えるには、以下のように設定しました:

.discourse-tags .discourse-tag[data-tag-name=yourtag] {
    order: -1;
}