Skip to content

Social post

A post in a feed: author, time, text, media and like / reply / repost / share actions with counts.

CSS + mian.js JSON Markdown Registry item

Post

Ilinca Sava@ilinca

Spent a month on a stool at a noodle counter. The cook decides once how far apart his hands go, and every strand follows. Best design system I have ever seen.

Installation

Everything ships in one stylesheet and one small script. There is nothing to import per component.

<link rel="stylesheet" href="https://mian.ro/dist/mian.css">
<script src="https://mian.ro/dist/mian.js" defer></script>

Prefer to own the files? /r/post.json is a registry item with this component's CSS and example markup, ready to copy into your project with any tool that reads the open registry-item format.

Class reference

Class / attributeDescription
mn-postThe post. Add mn-card for the noodle’s surface.
mn-post-headName, handle and <time>.
mn-post-bodyThe text.
mn-post-actionsThe action row.
mn-post-actionAn action button. aria-pressed makes it a toggle (like, repost); data-mn-count keeps its number in step; data-kind="repost" colours it green.

Accessibility

  • Wrap each post in <article> with an accessible name (the author).
  • Toggles use aria-pressed; a visually hidden word before the count gives each a full name, e.g. “Like, 128”.
Choose a noodle

Minimal

Flat

Pixel

Linear

Thin

Glass

Textured

Bold

Elegant

Rounded

On this page