高度有问题,还有无法跳转
两个问题:第一;给sectionhe其父元素高度设置100%,无法起到作用。所有的section里的内容全部在一个区域内,哪怕你加了overflow:hidden,第二,点击锚链接无法进行跳转,每个a链接的#panner-1无法对应跳转到对应的section
两个问题:第一;给sectionhe其父元素高度设置100%,无法起到作用。所有的section里的内容全部在一个区域内,哪怕你加了overflow:hidden,第二,点击锚链接无法进行跳转,每个a链接的#panner-1无法对应跳转到对应的section
2016-04-25
无法实现切换的小伙伴一定是html代码有问题:
<div class="container">
<div class="st-container">
<input type="radio" name="radio-set" checked="checked" id="st-control-1">
<a href="#st-panel-1">Serendipity</a>
<input type="radio" name="radio-set" id="st-control-2">
<a href="#st-panel-2">Happiness</a>
<input type="radio" name="radio-set" id="st-control-3">
<a href="#st-panel-3">Tranquallity</a>
<input type="radio" name="radio-set" id="st-control-4">
<a href="#st-panel-4">Positivity</a>
<input type="radio" name="radio-set" id="st-control-5">
<a href="#st-panel-5">Passion</a>
<div class="st-scroll">
<section class="st-panel" id="st-panel-1">
<div class="st-desc" data-icon=“H”></div>
<h2>Serendipity</h2>
<p>Banksy adipisicing eiusmod banh mi sed...</p>
</section>
<section class="st-panel" id="st-panel-2">
<div class="st-desc st-color" data-icon=“2”></div>
<h2>Happiness</h2>
<p>Banksy adipisicing eiusmod banh mi sed...</p>
</section>
<section class="st-panel" id="st-panel-3">
<div class="st-desc" data-icon=“B”></div>
<h2>Tranquallity</h2>
<p>Banksy adipisicing eiusmod banh mi sed...</p>
</section>
<section class="st-panel st-color" id="st-panel-4">
<div class="st-desc" data-icon=“X”></div>
<h2>Positivity</h2>
<p>Banksy adipisicing eiusmod banh mi sed...</p>
</section>
<section class="st-panel" id="st-panel-5">
<div class="st-desc " data-icon=“C”></div>
<h2>Passion</h2>
<p>Banksy adipisicing eiusmod banh mi sed...</p>
</section>
</div>
</div>
</div>
举报