【发布时间】:2012-10-30 20:25:21
【问题描述】:
我已经创建了一个按钮,HTML 如下所示:
<div class="blue_text"><button class="blue_small" id="blue_small"></button> View this video instead.</div>
CSS 如下。文本垂直对齐而不改变现有标记:
#blue_text{ color:#48c4d2; font-size:15px; font-family:opensansitalic;}
用于垂直对齐按钮而不更改现有标记。
button {
vertical-align:middle;
}
按钮CSS总数:
.blue_small {
height: 40px;
width: 40px;
margin-left:16px;
margin-bottom:1px;
background-color:#fff;
-moz-border-radius: 50%;
-webkit-border-radius: 50%;
border-radius: 50%;
border: 3px solid #fff;
background:url(../images/index_video_small2.svg) no-repeat 5px 7px;
-webkit-box-shadow: 0px 2px 6px rgba(64,80,85,0.8);
-moz-box-shadow: 0px 2px 6px rgba(64,80,85,0.8);
box-shadow: 0px 2px 6px rgba(64,80,85,0.8);
color:#48c4d2; font-size:15px;
font-family:opensansitalic;}
我想将以上所有内容结合到 CSS 中,如下所示,并带有青色阴影框?我从来没有试过这个。
align top http://www.kerrydeaf.com/shade2.png
更新:我在另一个容器的底部有这个 div >,但是有可见的间隙并试图缩小间隙但没有成功?我正在使用当前的 div >,如下所示。
<div class="blue_text"><button class="blue_small" id="blue_small"></button> View this video instead.</div>
这是一个可见的间隙,如下所示:
align top http://www.kerrydeaf.com/shade4.png
我希望用这个 查看这个视频来代替。
align top http://www.kerrydeaf.com/shade3.png
周五下午 2 点更新:谢谢,它很有效。它转到浏览器窗口的底部。我希望蓝色框关闭在 DIV 标签之间,例如下面的这个 DIV 标签。这个 div class="toogle_wrap" 是一个 DIV 容器,我在其中突出显示了要关闭的间隙,如下所示。将至少有五个 div class="toogle_wrap",这是一个 div class="toogle_wrap",因此需要将每个差距缩小。 p>
<div class="toogle_wrap">
<div class="trigger"><a href="#"><span class="trig">1.</span> Deaf person's attention</a></div>
<div class="toggle_container">
<ul class="lists">
<li>Learn <span class="bold">how to get</span> a Deaf person's attention.</li>
<li>Take a step-by-step process.</li>
<li>Approaching a Deaf and your approach may suggest your intention to communicate.</li>
<li>You can also <span class="bold">wave</span> to get eye contact or <span class="bold">tap</span> the person gently on the shoulder.</li>
<!--<li><span class="bold">Watch a video instead:</span> <span class="typicons">Z</span> <span class="typicn"<h5>Z</h5></span> </li>-->
</ul>
<div class="blue_text"><button class="blue_small" id="blue_small"></button> Available in video.</div>
<<<<<<<<<< The gap is here to close here >>>>>>>>.
<<<<<<<<<< The gap is here to close here >>>>>>>>.
<<<<<<<<<< The gap is here to close here >>>>>>>>.
<<<<<<<<<< The gap is here to close here >>>>>>>>.
<<<<<<<<<< The gap is here to close here >>>>>>>>.
</div>
</div>
周五晚上 10 点更新。这是 DIV 的示例。 position: relative应该进入哪个DIV?
align top http://www.kerrydeaf.com/div.png