How to achieve a side by side layout for topic posts like this?

I would love to achieve a side-by-side layout for my Discourse instance (see attached image). Could anyone please guide me on how to do this? I appreciate any help you can provide!

2 Likes

CSS Flexboxes, perhaps? Just from the top of my head. Then perhaps using the API/requests to fetch some other data like the post count.

What you want is basically replace horizontal bars with vertical bars?
They could be done with a theme component, and can’t be done with css only.
It would require care to not break anything, and might not be trivial to do :thinking:

1 Like

I’ve tried some basic flex box tinkering but it only broke the layout.

Hello @Canapin! basically i want the post author details on the left and post content on the right instead of them being one on top of the other like the stock discourse layout.
Would be helpful if there are any mods for it.

1 Like

I’d agree, you can’t re-position these items in a clean way with CSS. The avatar and the default metadata are arranged separately on the template:

I wonder how it’s actually done on the Epic forums. Is this a template override? I don’t see any plugin outlet at this location:

1 Like

From what I see, they re-added the data (username, etc.) after the post-avatar widget content, added some width to .topic-avatar, and they hide everything else with CSS except the date. Let me see If I can reproduce it.

1 Like

You can try this basic theme component: GitHub - Arkshine/discourse-topic-avatar-vertical-layout.

Let me know if you see issues.


  1. It moves the poster-name widget under the post-avatar widget. No other changes apart from CSS adjustments. ↩︎

8 Likes

That worked like a charm! Thanks a lot, buddy.

2 Likes