Skip to content

Tabs

Switch between views. Underlined, boxed (segmented), pill and vertical variants; full WAI-ARIA keyboard support.

CSS + mian.js JSON Markdown Registry item

Underlined

Make changes to your account here.
Change your password here.
Choose what we email you about.

Boxed

Daily figures.
Weekly figures.
Monthly figures.
Yearly figures.

Pills with icons

Overview content.
Analytics content.
Reports content.

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/tabs.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-tabsContainer.
mn-tab-list · mn-tab · mn-tab-panelParts. mian.js adds the roles and ids.
mn-tabs-boxed · mn-tabs-pills · mn-tabs-verticalVariants.

Accessibility

  • role="tablist", "tab", "tabpanel" with aria-controls, aria-labelledby and aria-selected. Arrow keys, Home and End move and activate; Tab moves into the panel.
Choose a noodle

Minimal

Flat

Pixel

Linear

Thin

Glass

Textured

Bold

Elegant

Rounded

On this page