Skip to content
v0.2.10

Inline

A wrapping horizontal group for related content and actions.

Preview

Use Inline

Inline is a named export of @flood-md/react. Connect the package once, then import what you use.

First time here? Connect Flood
Example import style
inline.tsxTSX
"use client";

import { FloodRoot, Inline, Button } from "@flood-md/react";
import "@flood-md/react/styles.css";

export function Example() {
  return (
    <FloodRoot>
      <Inline gap="2" align="center">
        <Button>Save changes</Button>
        <Button variant="subtle">Cancel</Button>
      </Inline>
    </FloodRoot>
  );
}

Design notes

  • Inline wraps when its children need more space.
  • Use the same control size for neighboring actions of the same level.
  • Rows center items by default. Use gap="4" between independent choices; gap="2" remains available for tightly related content.

API reference

PropValuesDefault
gap"0" | "1" | "2" | "3" | "4" | "6" | "8" | "12""2"
align"start" | "center" | "end" | "baseline""center"
Native HTML propsHTMLAttributes<HTMLDivElement>Forwarded
View TypeScript source