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",
|
||||
|
||||
+7
-1
@@ -361,7 +361,9 @@
|
||||
* 实测 62.4 = 2 行 48 + p margin 14.4 一致),p 下外距 0.9em(原站 hello 环境 14.4px)。
|
||||
*/
|
||||
.el-col > div > [data-el]:not(.el-w-auto) { width: 100%; }
|
||||
.el-col > div > [data-el]:not(:last-child):not(.el-w-auto) { margin-bottom: 20px; }
|
||||
/* kit-spacing 20px 只挂 widget(.elementor-widget:not(:last-child)),内嵌 section 无此间距
|
||||
* (H14 两行卡间实测 0 间距,section 曾被误加 20px 致行距 +20) */
|
||||
.el-col > div > [data-el]:not(:last-child):not(.el-w-auto):not(section) { margin-bottom: 20px; }
|
||||
.el-texteditor { display: flow-root; }
|
||||
/* 0.9rem 固定值(原站 hello-elementor p 边距 14.4px @16 根字号;em 会随 widget 字号 20px 放大成 18px) */
|
||||
.el-texteditor p { margin: 0 0 0.9rem; }
|
||||
@@ -405,6 +407,10 @@
|
||||
}
|
||||
.eael-infobox.icon-on-left .infobox-content .title { line-height: 1; margin: 0 0 10px 0; }
|
||||
.eael-infobox .infobox-content p { margin: 0 0 15px; }
|
||||
/* 内容里的 ul/ol:hello-elementor 主题 reset(H14 药丸列表实测 margin 0,
|
||||
* UA 默认 1em 上下外距会撑高内容 16px);列表样式与内边距由节点 custom_css 定义 */
|
||||
.eael-infobox .infobox-content ul,
|
||||
.eael-infobox .infobox-content ol { margin: 0; }
|
||||
|
||||
/* ===== 首页 H4 硬件与服务系列 ×5(post-18.css 对应块;1436px 实测 2026-11-01)
|
||||
* 卡列:渐变 #F4F5F9→透明 + 1px #E0E5F9 边框 + 4px 圆角 + 列间 margin(ColumnNode 由 settings 渲染);
|
||||
|
||||
Reference in New Issue
Block a user