From 1b7064a41cc5ed35a02402aac63668aca4734774 Mon Sep 17 00:00:00 2001 From: guy Date: Thu, 8 Apr 2021 10:25:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B8=83=E5=B1=80=E5=A4=A7=E4=B8=80=E7=BB=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/wrapper/layout/layout.inline.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/wrapper/layout/layout.inline.js b/src/core/wrapper/layout/layout.inline.js index 182cf8157..d75f7c9a4 100644 --- a/src/core/wrapper/layout/layout.inline.js +++ b/src/core/wrapper/layout/layout.inline.js @@ -58,6 +58,11 @@ BI.InlineLayout = BI.inherit(BI.Layout, { w.element.css("max-width", "calc(100% - " + ((left + right) / BI.pixRatio + BI.pixUnit) + ")"); } } + if (o.verticalAlign === BI.VerticalAlign.Stretch) { + var top = o.vgap + (item.tgap || 0) + (item.vgap || 0), + bottom = o.vgap + (item.bgap || 0) + (item.vgap || 0); + w.element.css("height", "calc(100% - " + ((top + bottom) / BI.pixRatio + BI.pixUnit) + ")"); + } if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) { w.element.css({ "margin-top": (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0)) / BI.pixRatio + BI.pixUnit