Skip to content
Calm motion: animations on this site only fade, with no movement

Forum topics ​

Topics of a forum with replies, views, the last post, and pinned topics

The list page of a forum or a community board. To show one topic with its replies, use the thread.

Basic
  • topics is a list of topics. Each topic has an id, a title, an author, and the number of replies. It can also have an href, views, and tags. last is the last post, with its author and time. pinned, locked, and solved mark the state.
  • Pinned topics come first and have a light tint. The rest keep their order.
  • Pinned, solved, and locked each show as a mark and a word, such as "✓ Solved". Screen readers hear only the word.
  • The counts show in short form, such as "1.5K replies", in the locale.
  • On a narrow screen, the counts go under the title.
  • Change the words with labels or a label pack: title, pinned, locked, solved, and the functions by, replies, views, and last.

Usage ​

ts
import { BlessForumTopics } from "blessing-ui";

API ​

Props

NameTypeDefaultDescription
topics*BlessForumTopic[]—
localestring"en"
labelsPartial<{ title: string; pinned: string; locked: string; solved: string; by: (name: string) => string; replies: (count: string) => string; views: (count: string) => string; last: (name: string, time: string) => string; }>—

Released under the MIT License. Character names and artwork belong to their owners.