For AI agents: the complete documentation index is available at /ooui-react/llms.txt, the full documentation bundle is available at /ooui-react/llms-full.txt, and this page is available as Markdown at /ooui-react/components/horizontal-layout/index.md.
  • 中文
  • HorizontalLayout 横向布局

    源代码 | 原版组件

    横向容器:仅输出 oo-ui-horizontalLayout 根类,排布交由主题 CSS;需要精确控制间距时自己写样式或换用普通 div。

    基本用法

    import { Button, HorizontalLayout, TextInput } from "ooui-react";
    
    function App() {
      return (
        <HorizontalLayout>
          <TextInput placeholder="搜索…" />
          <Button flags="primary">搜索</Button>
        </HorizontalLayout>
      );
    }
    
    export default App;

    API

    继承 Layout 的全部属性(含 hidden 三态)。

    另见

    • 基类的 hidden 三态语义:Layout