v0.10.15: H14 Why Choose Dusun IoT(9f202ea)完成,审计 0 差异
- EaelInfoBoxWidget: 标题排版/颜色设置驱动(eael_infobox_title_typography_* 与 _title_color 进 slim 白名单),内容改 div 直出(原站无 p 包裹,药丸列表不再被 p 包裹/UA margin 撑高);infobox 内容 ul/ol margin 0(hello-elementor reset) - kit-spacing 20px 排除内嵌 section(只挂 widget,H14 两行卡间距归零) - populated 宽 100%→auto:块级填充自动扣除水平 margin(H14 680-8=672、H11 同理), 替代 H11 时代的 per-section !important 覆写 - 双端节内相对几何 0 差异(sec 772 全等),全页 H0-H14 高度回归零差异
This commit is contained in:
@@ -431,10 +431,11 @@ function ColumnNode({ el, gapPad }: { el: ElElement; gapPad?: string }) {
|
||||
} else inner.borderWidth = "1px";
|
||||
}
|
||||
return (
|
||||
// 内层 width:100% 与列同宽(H4 卡 margin 内含、向右溢出,原站实测一致);
|
||||
// H11 等少数列在 app.css 用 !important 覆写为 auto(原站 populated 扣除水平外边距 443.33)
|
||||
// 内层(populated)宽 auto:块级填充自动扣除自身水平 margin(原站实测 H14 680-8=672、
|
||||
// H11 453.33-10=443.33;负 margin 反向加宽与原站一致);此前 width:100% 会使
|
||||
// 有水平 margin 的列溢出 margin 宽度
|
||||
<div className="el-col min-w-0" style={outer} data-el={el.id}>
|
||||
<div style={{ display: "flex", flexWrap: "wrap", alignContent: "flex-start", width: "100%", ...inner }}>
|
||||
<div style={{ display: "flex", flexWrap: "wrap", alignContent: "flex-start", width: "auto", ...inner }}>
|
||||
{(el.elements || []).map((c, i) => (
|
||||
<ElementNode key={c.id || i} el={c} gapPad={gapPad} />
|
||||
))}
|
||||
@@ -986,6 +987,11 @@ function EaelInfoBoxWidget({ settings }: { settings: Record<string, unknown> })
|
||||
const Tag = (["h1", "h2", "h3", "h4", "h5", "h6", "div"].includes(tag) ? tag : "div") as "div";
|
||||
const left = s(settings.eael_infobox_img_type) === "img-on-left" || s(settings.eael_infobox_img_type) === "icon-on-left";
|
||||
const cls = "eael-infobox" + (left ? " icon-on-left" : "");
|
||||
// 标题排版/颜色(H14 实测 fs 1.25rem/700/#0D152E;内容排版 hover 键原站未生效,不采用)
|
||||
const titleStyle: CSSProperties = {
|
||||
...typographyCss(settings, "eael_infobox_title_typography"),
|
||||
...(s(settings.eael_infobox_title_color) ? { color: s(settings.eael_infobox_title_color) as string } : {}),
|
||||
};
|
||||
return (
|
||||
<div className={cls}>
|
||||
{img?.url ? (
|
||||
@@ -996,13 +1002,13 @@ function EaelInfoBoxWidget({ settings }: { settings: Record<string, unknown> })
|
||||
<div className="infobox-content">
|
||||
{title ? (
|
||||
<div className="infobox-title-section">
|
||||
<Tag className="title" dangerouslySetInnerHTML={{ __html: title }} />
|
||||
<Tag className="title" style={Object.keys(titleStyle).length ? titleStyle : undefined} dangerouslySetInnerHTML={{ __html: title }} />
|
||||
{s(settings.eael_infobox_sub_title) && s(settings.eael_infobox_sub_title) !== "This is a sub title" ? (
|
||||
<div className="sub_title" dangerouslySetInnerHTML={{ __html: s(settings.eael_infobox_sub_title) }} />
|
||||
) : null}
|
||||
</div>
|
||||
) : null}
|
||||
{desc ? <p dangerouslySetInnerHTML={{ __html: desc }} /> : null}
|
||||
{desc ? <div dangerouslySetInnerHTML={{ __html: desc }} /> : null}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -129,6 +129,10 @@ const SETTING_KEYS = new Set([
|
||||
"eael_infobox_title_margin_mobile",
|
||||
"eael_infobox_title_typography_typography",
|
||||
"eael_infobox_title_typography_font_size",
|
||||
"eael_infobox_title_typography_font_size_mobile",
|
||||
"eael_infobox_title_typography_font_size_tablet",
|
||||
"eael_infobox_title_typography_font_weight",
|
||||
"eael_infobox_title_color",
|
||||
"hover_animation",
|
||||
// widget 高级盒模型(如 eael-info-box 边框卡:_border_* + _padding/_margin)
|
||||
"_margin",
|
||||
|
||||
Reference in New Issue
Block a user