0
A
回答
0
添加overflow:hidden
您steps
类。
@function pow($number, $exp) {
$value: 1;
@if $exp > 0 {
@for $i from 1 through $exp {
$value: $value * $number;
}
}
@else if $exp < 0 {
@for $i from 1 through -$exp {
$value: $value/$number;
}
}
@return $value;
}
@function fact($number) {
$value: 1;
@if $number > 0 {
@for $i from 1 through $number {
$value: $value * $i;
}
}
@return $value;
}
@function pi() {
@return 3.14159265359;
}
@function rad($angle) {
$unit: unit($angle);
$unitless: $angle/($angle * 0 + 1);
// If the angle has 'deg' as unit, convert to radians.
@if $unit == deg {
$unitless: $unitless/180 * pi();
}
@return $unitless;
}
@function cos($angle) {
$cos: 0;
$angle: rad($angle);
// Iterate a bunch of times.
@for $i from 0 through 10 {
$cos: $cos + pow(-1, $i) * pow($angle, 2 * $i)/fact(2 * $i);
}
@return $cos;
}
.steps {
display: inline-flex;
width: 500px;
height: 50px;
border: 1px solid #D9D9D9;
border-radius: 2px;
overflow-x:hidden;
}
.step {
position: relative;
display: flex;
align-items: center;
white-space: nowrap;
padding: 0 15px;
box-sizing: border-box;
background-color: #FAFAFA;
&:hover {
background-color: #EDEDED;
cursor: pointer;
}
&::after {
position: absolute;
top: -2px;
right: -23px;
content: '';
width: 27px;
height: 27px;
background-color: inherit;
transform: rotate(67.5deg) skewX(45deg) scaleY(cos(45deg));
transform-origin: left;
border-top: 1px solid #D9D9D9;
border-right: 1px solid #D9D9D9;
z-index: 1;
}
}
<div class="steps">
<div class="step">Very very very long text</div>
<div class="step">Very very very long text</div>
<div class="step">Very very very long text</div>
<div class="step">Very very very long text</div>
<div class="step">Very very very long text</div>
</div>
相关问题
- 1. 自定义构建步骤中的自动版本文件步骤
- 2. 基本步骤17.04
- 3. 获取今天的所有步骤,但从Health kit中使用swift截取手动添加的步骤
- 4. BFS算法 - 在约束步骤的网格上最短步行
- 5. 更改向导步骤按钮文本
- 6. 步骤使用RazorGenerator.MsBuild
- 7. 黄瓜步骤上错误的步骤
- 8. ISampleGrabberFilter一次一个步骤的步骤
- 9. 1步骤中的特定本地文件的rsync列表
- 10. 上传Bonita步骤中的文件
- 11. 使用jquery步骤的Summernote
- 12. 如何使用从右到左的步骤jquery步骤向导
- 13. 在Ant脚本中创建Java步骤
- 14. shell脚本在步骤中执行
- 15. 步骤
- 16. 在匹配之前修改黄瓜中的步骤文本
- 17. 黄瓜栏|定义描述数据库中更改的步骤
- 18. 黄瓜栏中的通用点击步骤(含和不含硒)
- 19. 在Angular2中使用FormGroup的jquery步骤
- 20. 在Java中使用JavaBuilder的步骤
- 21. Rspec中的命令步骤和说明步骤
- 22. 在android中使用MQTT的基本步骤
- 23. Buildbot中的分组步骤
- 24. sqlite3_create_function_v2中的步骤错误
- 25. 如何使用SAS中的数据步骤排序数据步骤
- 26. 通过Twilio REST API检索短信/彩信的传送步骤
- 27. 为`Given`和`Then`定义相同的短语步骤
- 28. Javascript:在几个步骤中显示文本
- 29. 缩短地址栏中缩短的URL
- 30. 如何截断文本中的文本