CSS3 - 垂直 Angular 80% 外部框阴影

标签 css shadow

我知道如何使框阴影沿着元素向下延伸,但是是否可以让它向下延伸到元素的 80% 而不是元素的整个高度?

还有如何使阴影 Angular 变大(这是我最纠结的事情)

enter image description here

最佳答案

是这样的吗?

jsFiddle here

有很多方法可以实现这一点。我只是设置了阴影,并覆盖了一个三 Angular 形。

enter image description here

这是没有模糊阴影的替代方案.. http://jsfiddle.net/bHEaZ/1/

HTML - 非常简单

<div></div>

CSS

div {
    width: 100px;
    height: 200px;
    position: relative;
    border: 1px solid black;
    box-shadow: 20px -10px 30px black;
    margin: 40px;
}

div:after {
    position: absolute;
    left: 102px;
    top: 100px;
    content: "\A";
    width: 0;
    height: 0;
    border-bottom: 90px solid white;
    border-right: 50px solid white;
    border-top: 90px solid transparent;
}

关于CSS3 - 垂直 Angular 80% 外部框阴影,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19217788/

相关文章:

html - 替换网站移动版本中的图标

graphics - 核心图形中的内阴影

qt - 如何在 Qt 中为无框窗口添加阴影

android - 如何在左右侧 View 上创建阴影?

jquery - 找到关键字 "id"并以内联样式更改其值

jquery - 日期选择器奇怪的位置

html - 我的 div 高度中的边框高度 50% 如何使用 css?

html - 边框不包围框

delphi - 隐藏窗口阴影

ios - 为什么我的阴影层位置不正确?