下面的网格演示了 24 列的等宽分布。每个数字标签对应一列。报纸排版偏好 24 列是因为它能整除 2 / 3 / 4 / 6 / 8 / 12,足够灵活地实现 1/3、2/3、1/4、3/4 这类常见栏宽组合。
Layout 是顶层容器,提供 LayoutContext。Section 通过
useLayout 读取列数上限并自动 clamp。
Section 是栅格容器,
display: grid; grid-template-columns: repeat(N, 1fr)
。子 Article 通过 grid-column span 占位。
Article 在 Section 栅格内用 grid-column span N 占位。
span 缺省时占满 Section 全宽。