For AI agents: the complete documentation index is available at /next/zh/llms.txt, the full documentation bundle is available at /next/zh/llms-full.txt, and this page is available as Markdown at /next/zh/api/css/properties/row-gap.md.
Lynx
  • 简体中文
  • row-gap (grid-row-gap)

    介绍

    row-gap/grid-row-gap 属性用来设置弹性布局网格布局行元件之间的间隙(gutter)大小。

    为了兼容性,可使用 row-gapgrid-row-gap

    使用示例

    取值

    <length>

    <length> 表示弹性布局网格布局行之间的间隙宽度。

    <percentage>

    行之间直接的间隙宽度,<percentage> 相对容器自身 content area 纵向大小的百分比。

    形式语法

    row-gap = <length-percentage [0,∞]>
    
    <length-percentage> = <length> | <percentage>

    语法

    /* <length> values */
    row-gap: 20px;
    grid-row-gap: 20px;
    row-gap: 1em;
    grid-row-gap: 1em;
    
    /* <percentage> value */
    row-gap: 10%;
    grid-row-gap: 10%;
    
    /* calc() values */
    row-gap: calc(10% + 20px);
    grid-row-gap: calc(10% + 20px);

    形式定义

    初始值0
    适用元素弹性容器和网格容器
    是否支持继承
    是否支持动画
    百分比refer to vertical dimension of its own content area

    与 Web 的区别

    mdn: row-gap

    1. 不支持 normal

    兼容性

    LCD tables only load in the browser

    常见问题

    除非另有说明,本项目采用知识共享署名 4.0 国际许可协议进行许可,代码示例采用 Apache License 2.0 许可协议进行许可。