生娃计算器一句话答案补充月嫂+托班区间;计算器/补剂页插画换成主色调
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 27 KiB |
@@ -194,7 +194,7 @@ b{color:var(--h)}
|
|||||||
<h1>叶酸、DHA、铁、钙<br><span class="hl">要不要补</span>?</h1>
|
<h1>叶酸、DHA、铁、钙<br><span class="hl">要不要补</span>?</h1>
|
||||||
<p class="sub">一张卡看懂:补不补、补多少、从几周开始</p>
|
<p class="sub">一张卡看懂:补不补、补多少、从几周开始</p>
|
||||||
</section>
|
</section>
|
||||||
<div class="pic"><img src="img/hero.webp" alt="孕妈妈坐在窗边,桌上有牛奶、绿叶菜和鱼"></div>
|
<div class="pic"><img src="img/hero.webp" alt="孕妈妈坐在窗边,桌上有牛奶、补剂、绿叶菜和鱼"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="answer">
|
<div class="answer">
|
||||||
<span class="pill">一句话答案</span>
|
<span class="pill">一句话答案</span>
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 25 KiB |
@@ -725,7 +725,12 @@ h1{margin-top:10px;font-size:28px;font-weight:800;line-height:1.32;color:var(--h
|
|||||||
// 一句话答案:用常见选择现算,县城到新一线
|
// 一句话答案:用常见选择现算,县城到新一线
|
||||||
var lo = calc(withCity(3)).reduce(function (a, x) { return a + x.t[0]; }, 0);
|
var lo = calc(withCity(3)).reduce(function (a, x) { return a + x.t[0]; }, 0);
|
||||||
var hi = calc(withCity(1)).reduce(function (a, x) { return a + x.t[1]; }, 0);
|
var hi = calc(withCity(1)).reduce(function (a, x) { return a + x.t[1]; }, 0);
|
||||||
$('#ansTxt').innerHTML = '按常见选择,从怀孕到宝宝 3 岁,县城到省会大约花 <em>' + Math.round(lo / 10000) + '~' + Math.round(hi / 10000) + ' 万</em>;差距最大的是坐月子和谁带娃。';
|
// 补一句:请月嫂 + 2 岁送托班(省会到一线)
|
||||||
|
var up = withCity(1); up.yz = 2; up.care = 1;
|
||||||
|
var lo2 = calc(up).reduce(function (a, x) { return a + x.t[0]; }, 0);
|
||||||
|
up.city = 0;
|
||||||
|
var hi2 = calc(up).reduce(function (a, x) { return a + x.t[1]; }, 0);
|
||||||
|
$('#ansTxt').innerHTML = '按常见选择,从怀孕到宝宝 3 岁,县城到省会大约花 <em>' + Math.round(lo / 10000) + '~' + Math.round(hi / 10000) + ' 万</em>;请月嫂、送托班会到 <em>' + Math.round(lo2 / 10000) + '~' + Math.round(hi2 / 10000) + ' 万</em>。';
|
||||||
$('#goLast').classList.toggle('on', hasResult);
|
$('#goLast').classList.toggle('on', hasResult);
|
||||||
}
|
}
|
||||||
function withCity(c) { var s = {}; for (var k in DEF) s[k] = DEF[k]; s.city = c; return s; }
|
function withCity(c) { var s = {}; for (var k in DEF) s[k] = DEF[k]; s.city = c; return s; }
|
||||||
|
|||||||
Reference in New Issue
Block a user