From ef2c7665ec0c87743b7a5633991506da1d5882a2 Mon Sep 17 00:00:00 2001
From: sight <26325820+Sight-wcg@users.noreply.github.com>
Date: Fri, 12 Sep 2025 23:58:58 +0800
Subject: [PATCH] =?UTF-8?q?docs:=20=E6=9B=B4=E6=96=B0=20table=20=E6=96=87?=
=?UTF-8?q?=E6=A1=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
docs/table/detail/options.md | 10 ++++++++++
src/modules/table.js | 2 +-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/docs/table/detail/options.md b/docs/table/detail/options.md
index f9053930..39a77810 100644
--- a/docs/table/detail/options.md
+++ b/docs/table/detail/options.md
@@ -254,6 +254,16 @@ height: function(){
string |
+- |
+
+
+syncFixedRowHeight 2.12+ 实验性 |
+
+
+是否强制计算表格主区域的行高度并同步到固定列区域。开启后会对表格性能有一定的影响,仅适用于行高度自适应的场景。
+
+ |
+boolean |
- |
diff --git a/src/modules/table.js b/src/modules/table.js
index 088fae2d..82219a47 100644
--- a/src/modules/table.js
+++ b/src/modules/table.js
@@ -2993,7 +2993,7 @@ layui.define(['lay', 'i18n', 'laytpl', 'laypage', 'form', 'util'], function(expo
// 同步固定列表格和主表格高度
var lineStyle = that.config.lineStyle;
- var isAutoHeight = lineStyle && (/\bheight\s*:\s*auto\b/g.test(lineStyle) || lineStyle.indexOf('max-height') !== -1);
+ var isAutoHeight = lineStyle && /\bheight\s*:\s*auto\b/g.test(lineStyle);
// 只重载数据时需要主动同步高度,因为 tbody 大小可能不变
var needSyncFixedColHeight = that.needSyncFixedColHeight = (that.layBody.length > 1) && (that.config.syncFixedRowHeight || (that.config.syncFixedRowHeight !== false && isAutoHeight));