• <small id='LWQM6'></small><noframes id='LWQM6'>

        <bdo id='LWQM6'></bdo><ul id='LWQM6'></ul>
      <i id='LWQM6'><tr id='LWQM6'><dt id='LWQM6'><q id='LWQM6'><span id='LWQM6'><b id='LWQM6'><form id='LWQM6'><ins id='LWQM6'></ins><ul id='LWQM6'></ul><sub id='LWQM6'></sub></form><legend id='LWQM6'></legend><bdo id='LWQM6'><pre id='LWQM6'><center id='LWQM6'></center></pre></bdo></b><th id='LWQM6'></th></span></q></dt></tr></i><div id='LWQM6'><tfoot id='LWQM6'></tfoot><dl id='LWQM6'><fieldset id='LWQM6'></fieldset></dl></div>
      <tfoot id='LWQM6'></tfoot><legend id='LWQM6'><style id='LWQM6'><dir id='LWQM6'><q id='LWQM6'></q></dir></style></legend>

      1. 盒子内 CSS 中的三角形

        时间:2023-09-07

      2. <tfoot id='l01cZ'></tfoot>
          <i id='l01cZ'><tr id='l01cZ'><dt id='l01cZ'><q id='l01cZ'><span id='l01cZ'><b id='l01cZ'><form id='l01cZ'><ins id='l01cZ'></ins><ul id='l01cZ'></ul><sub id='l01cZ'></sub></form><legend id='l01cZ'></legend><bdo id='l01cZ'><pre id='l01cZ'><center id='l01cZ'></center></pre></bdo></b><th id='l01cZ'></th></span></q></dt></tr></i><div id='l01cZ'><tfoot id='l01cZ'></tfoot><dl id='l01cZ'><fieldset id='l01cZ'></fieldset></dl></div>

          <small id='l01cZ'></small><noframes id='l01cZ'>

              • <bdo id='l01cZ'></bdo><ul id='l01cZ'></ul>

              • <legend id='l01cZ'><style id='l01cZ'><dir id='l01cZ'><q id='l01cZ'></q></dir></style></legend>
                  <tbody id='l01cZ'></tbody>

                  本文介绍了盒子内 CSS 中的三角形的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  嗯,我不知道如何正确解释.在这里,检查此屏幕截图,其中包含我想要制作的内容.我的设计师给了我这个.如果我找不到解决方案,我将使用图像而不使用代码.可以用 CSS3 做到这一点吗?

                  .

                  或此处的完整集成示例.

                  Well I don't know how to explain it correctly. Here, check this screenshot which has what I want to make. My designer gave me this. If I don't find a solution i'll use images and no code. Is it possible to do this with CSS3?

                  Here is the image

                  See the triangle inside that box? I want to do this. Thank you!

                  解决方案

                  Creative use of borders to achieve this effect, no images were harmed in the following sample and you can even set the position of the arrow on the element itself - becomes more straightforward if you can hardcode it for your design.

                  HTML

                  <div class="top">
                      <span class="arrow" style="left:40%"></span>
                  </div>
                  

                  CSS

                  .top {
                      background:url(http://blog.positscience.com/wp-content/uploads/2013/08/ice-cream3.jpg);
                      background-size:cover;
                      width:300px;
                      height:300px;
                      border:1px solid #888;
                      position:relative;
                      overflow:hidden;
                  }
                  .arrow {
                      border:30px solid #aaa;
                      border-bottom:none;
                      border-color:transparent #aaa transparent #aaa;
                      position:absolute;
                      left:0;
                      bottom:0;
                  }
                  .arrow:before, .arrow:after {
                      content:'';
                      position:absolute;
                      width:5000px;
                      bottom:0;
                      height:30px;
                      background:#aaa;
                  }
                  .arrow:before {
                      right:30px;
                  }
                  .arrow:after {
                      left:30px;
                  }
                  

                  Working JSfiddle sample.

                  Or the full integrated sample here.

                  这篇关于盒子内 CSS 中的三角形的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:JavaScript中直线和圆之间的碰撞检测 下一篇:如何在css中的矩形顶部制作曲线?仅在顶部边缘

                  相关文章

                  最新文章

                      <bdo id='eNwLk'></bdo><ul id='eNwLk'></ul>

                  1. <legend id='eNwLk'><style id='eNwLk'><dir id='eNwLk'><q id='eNwLk'></q></dir></style></legend>

                    <i id='eNwLk'><tr id='eNwLk'><dt id='eNwLk'><q id='eNwLk'><span id='eNwLk'><b id='eNwLk'><form id='eNwLk'><ins id='eNwLk'></ins><ul id='eNwLk'></ul><sub id='eNwLk'></sub></form><legend id='eNwLk'></legend><bdo id='eNwLk'><pre id='eNwLk'><center id='eNwLk'></center></pre></bdo></b><th id='eNwLk'></th></span></q></dt></tr></i><div id='eNwLk'><tfoot id='eNwLk'></tfoot><dl id='eNwLk'><fieldset id='eNwLk'></fieldset></dl></div>
                    <tfoot id='eNwLk'></tfoot>

                      <small id='eNwLk'></small><noframes id='eNwLk'>