The Tabs block is a parent–child pair: the Tabs block holds the tab bar and manages state, while each Tab Panel holds any inner blocks you want to show when that tab is active. Both blocks are server-side rendered — the active tab is baked into the HTML and animated client-side by a lightweight script with no jQuery dependency.
How to add
Open the block inserter, switch to the Axiom Blocks category, and click Tabs. The block drops in with one panel ready to edit. Add more from the sidebar.
The sidebar at a glance
The block sidebar is split into two tabs. Settings is what the block does — the tabs themselves and how they behave. Styles is how it looks, organised by the parts you can see rather than one long list of options.
| Tab | Section | Covers |
|---|---|---|
| Settings | Tabs | Manage tabs, orientation, alignment, full-width |
| Settings | Advanced | Visibility, Position, anchor, CSS class |
| Styles | Tab bar | The strip behind the row of tabs |
| Styles | Tab | An individual tab button |
| Styles | Panel | The content area below (or beside) the bar |
| Styles | Spacing | Padding and margin on the outer wrapper |
Managing tabs
The Tabs section in Settings is the repeater that controls every tab in the set.
- Rename — click the text field next to any tab row and type a new label
- Add — click + Add tab at the bottom of the list
- Reorder — use the up/down arrow buttons on each row
- Remove — click the trash icon (disabled when only one tab remains)
Setting the default-open tab
The star button on each row controls which tab is open when the page first loads. The filled star marks the current default. Click an unfilled star to promote that tab. This is saved to the block and reflected on the frontend — it is not the same as which tab you last clicked in the editor.
Orientation & alignment
Both live in Settings → Tabs.
Orientation switches between horizontal (the default row of tabs above the content) and vertical (tabs stacked on the left, content on the right).
Alignment — Left, Center, or Right — controls how the tab buttons are distributed along the bar. This applies in horizontal mode only; in vertical mode the column fills the available width. Alignment can be set per device.
Full-width tabs stretches each tab button to fill an equal share of the bar, regardless of label length.
Tab bar fits content shrinks the bar to hug its tabs instead of spanning the block, which is what you want for a pill or segmented-control look.
Styling the tab bar
Styles → Tab bar is the strip that sits behind every tab — one element, so it has no hover or active state of its own.
| Row | What it does |
|---|---|
| Background | Solid color or gradient behind the whole row |
| Border | Per-side width, style, and color |
| Radius | Per-corner rounding, up to a fully round bar |
| Padding | Per-side, per-device |
Styling a tab
Styles → Tab is an individual tab button. Text, background, and border each carry Normal / Hover / Active states — pick the state at the top of the row and set a value for it.
| Row | What it does |
|---|---|
| Text | Label color, per state |
| Background | Tab's own background, per state |
| Typography | Font family, weight, size, line height, letter spacing, transform, decoration |
| Border | Per-side width, style, and color, per state |
| Radius | Per-corner rounding |
| Gap | Space between one tab and the next, per device |
| Icon gap | Space between a tab's icon and its label, per device |
Styling the panel
Styles → Panel is the content area.
| Row | What it does |
|---|---|
| Background | Solid color or gradient |
| Border | Per-side width, style, and color |
| Radius | Per-corner rounding |
| Shadow | Preset or custom shadow |
| Padding | Per-side, per-device |
| Gap | Space between the tab bar and the panel, per device |
Spacing
Styles → Spacing sets per-side padding and margin on the outer block wrapper. Use this to control how the Tabs block sits in relation to surrounding content rather than adding wrapper Groups.
Block alignment
The Tabs block supports Wide and Full alignment from the toolbar. This expands the outer wrapper beyond the content column width — the tab bar and panels follow.
HTML output
The block renders a <div> wrapper with ARIA tab roles. The active tab button carries aria-selected="true" and its panel is the only one visible on load; the client-side script handles switching without a full page load.
is-full-width and is-bar-fit are added to the wrapper when those Settings options are on.
CSS custom properties
Target these on .axiom-blocks-tabs to style tabs from your theme stylesheet or theme.json. The original four are still emitted, so existing theme overrides keep working.
| Property | Controls |
|---|---|
--axiom-blocks-tab-active | Active tab label and indicator color |
--axiom-blocks-tab-inactive | Inactive tab label color |
--axiom-blocks-tab-bg | Tab bar background |
--axiom-blocks-tab-content-bg | Content panel background |
--axiom-blocks-tabs-content-gap | Gap between tab bar and content panel |
The Styles rows emit a finer-grained set, named --ab-tabs-<part>-<property>:
| Prefix | Part |
|---|---|
--ab-tabs-bar-* | Tab bar — bg, bc, bs, bw-*, radius-*, p* |
--ab-tabs-tab-* | Tab — bg, bc, bs, bw-*, radius-*, p*, shadow, icon-gap |
--ab-tabs-panel-* | Panel — bg, bc, bs, bw-*, radius-*, p*, shadow |
--ab-tabs-gap | Space between adjacent tabs |
Tab-part properties take a -h suffix for hover and -a for active — for example --ab-tabs-tab-bg-h and --ab-tabs-tab-bc-a.