1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
| <!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewprot" content="width=device-width, initial-scale=1.0"/>
<meta http-equiv="X-UA-Compatible" content="ie=edge"/>
<title>dddd</title>
<style type="text/css">
div{
position: absolute;
width: 100px;
height: 100px;
border-left: none;
border-right: none;
left: 50%;
top: 50%;
transform: translate(-50%,-50%);
}
div:before{
content: '';
display: block;
position: absolute;
width: 50px;
height: 100px;
left: -50px;
top: -1px;
border-right: none;
border-radius: 50px 0px 0px 50px;
}
div:after{
content: '';
display: block;
position: absolute;
width: 50px;
height: 100px;
top: -1px;
right: -50px;
border-left: none;
border-radius: 0px 50px 50px 0px;
}
#item1{
transform-origin: top;
transform: rotateZ(45deg);
background-color: rgba(156,123,200,0.5);
}
#item1:before{
background-color: rgba(156,123,200,0.5);
}
#item1:after{
background-color: rgba(156,123,200,0.5);
}
#item2{
transform-origin: top;
transform: rotateZ(-45deg);
background-color: rgba(19,195,20,0.5);
}
#item2:before{
background-color: rgba(19,195,20,0.5);
}
#item2:after{
background-color: rgba(19,195,20,0.5);
}
</style>
</head>
<body>
<div id="item1"></div>
<div id="item2"></div>
<script src="http://libs.baidu.com/jquery/2.0.0/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script type="text/javascript">
</script>
</body>
</html>
|