Sam's Simple Theme

@sam would it be possible to export this customisation as a gist or something? Would make it easier to reference and see when there are updates. As this is pretty great!

1 Like
  {{raw "topic-list-header-column" sortable='true' number='true' order='posts' forceName='Replies'}}
  {{raw "topic-list-header-column" sortable='true' order='activity' forceName='Last Post'}}

@sam, is there a way to make these work with localization? Our forum defaults to Finnish, but tech savvy people generally prefer English. One of these user groups is going to get these labels in a wrong language, depending on what I have there as a hard coded solution.

2 Likes

It is tricky, we would need a core change for that

how can is Use the kind of Styling for only one category?

preface every selector with .categoryname, so instead of

.topic-list td {
    padding-bottom: 10px;
}

you have

.categoryname .topic-list td {
    padding-bottom: 10px;
}

you can discover the .categoryname of a category by viewing the topic list in that category and inspect the source. The main <body> tag for that page will have a class like “category-foobar”

EDIT: Ah I missed that there was custom JS. That’s outside my knowledge I’m afraid!

Thanks for your answer Tom :slight_smile: I found the body tag <body class="docked category-features-vorschlagen">

But I want to use @sam’s style just for one category. But if I paste the code inside my custom </head> it changes the style of every category. Is there a possibility to handle this?

It sounds like you used the “docked” selector instead of only the category specific selector.

Is there a way to turn on showTopicPostBadges?

This post got me to where I could imagine answering this question, and I did manage to turn on showOpLikes, but I don’t see shopTopicPostBadges anywhere in the serializers.

This is in the, can be done but extremely complicated department and would probably require some core changes.

i just want to use the category part of this topic-list, that’s to show the categories in a de-emphasize way beneath the topic (with the same style you used in the main image, i.e. using tag image as the visualization.

would you mind guiding me which part of the code to use?

p.s: i used the shared code, and everything has been implemented but not the category part! don’t know why.

thanks in advance,

Just tested it and noticed the same. Categories don’t show up on /latest anymore. Using the preview here or on another site. Probably a bug from a recent update or is it not added to the OP @sam?

Edit: Also seems that it breaks the moderation tools. (Hides them, even if forced, still hides the check boxes for example inside a category to mass edit threads.)

The avatars and usernames of last poster are missing from Suggested topics list when using this theme:

Steps to reproduce:

  1. Open Sam's personal "minimal" topic list design
  2. Notice the (all/some/none) missing info. Change to private tab/different browser if necessary.

Is there an easy way to fix this? Should I open a #bug #feature or #support topic? This affects every site that uses some variation of the minimal theme that I know of.

Hm… I’m getting a Error: Could not find module discourse/views/topic-list-item- both here on Meta, and on my own site. I rely on the part

(function(){ var TopicListItemView = require('discourse/views/topic-list-item').default; TopicListItemView.reopen({
…which does not work any more on the latest beta. Does anyone have any insight in this? Grepping around did not produce any useable TopicListView or ShowCategory methods.

1 Like

Yeah just change the word view to component

3 Likes

Theme appears to be broken with the last few updates. Any clues?

3 Likes

Confirmed, I will have a look at sorting this out

2 Likes

The theme is actually fine, the issue is that our transpiler changed so you need to invalidate a cache.

@eviltrout will fix it so it happens automatically, but in the mean time just add a space into the HEAD section with all the customizations and save, then it will work.

2 Likes

Oops, fixed that here:

https://github.com/discourse/discourse/commit/a69b897545a3a7d21414d3b8957a0a20bfe2af28

4 Likes

me too :slight_smile:

1 Like

This is awesome. Helps a lot since I have the Sidebar Blocks plugin enabled.