File tree Expand file tree Collapse file tree 2 files changed +17
-4
lines changed Expand file tree Collapse file tree 2 files changed +17
-4
lines changed Original file line number Diff line number Diff line change @@ -165,7 +165,7 @@ export default class Renderer {
165
165
! container . style . background . backgroundColor . isTransparent ( ) ||
166
166
container . style . background . backgroundImage . length ;
167
167
168
- const renderableBorders = container . style . border . filter (
168
+ const hasRenderableBorders = container . style . border . some (
169
169
border =>
170
170
border . borderStyle !== BORDER_STYLE . NONE && ! border . borderColor . isTransparent ( )
171
171
) ;
@@ -186,12 +186,17 @@ export default class Renderer {
186
186
} ) ;
187
187
}
188
188
189
- renderableBorders . forEach ( ( border , side ) => {
190
- this . renderBorder ( border , side , container . curvedBounds ) ;
189
+ container . style . border . forEach ( ( border , side ) => {
190
+ if (
191
+ border . borderStyle !== BORDER_STYLE . NONE &&
192
+ ! border . borderColor . isTransparent ( )
193
+ ) {
194
+ this . renderBorder ( border , side , container . curvedBounds ) ;
195
+ }
191
196
} ) ;
192
197
} ;
193
198
194
- if ( HAS_BACKGROUND || renderableBorders . length ) {
199
+ if ( HAS_BACKGROUND || hasRenderableBorders ) {
195
200
const paths = container . parent ? container . parent . getClipPaths ( ) : [ ] ;
196
201
if ( paths . length ) {
197
202
this . target . clip ( paths , callback ) ;
Original file line number Diff line number Diff line change 12
12
margin : 10px ;
13
13
background : # 6F428C ;
14
14
border-style : solid;
15
+ border-width : 0 ;
15
16
}
16
17
17
18
.box1 {
33
34
border-color : green;
34
35
}
35
36
37
+ .box5 {
38
+ border-style : none;
39
+ border-bottom : 50px solid # 807d32 ;
40
+ border-bottom-width : 50px ;
41
+ }
42
+
36
43
html {
37
44
background : # 3a84c3 ;
38
45
}
43
50
< div class ="box2 "> </ div >
44
51
< div class ="box3 "> </ div >
45
52
< div class ="box4 "> </ div >
53
+ < div class ="box5 "> </ div >
46
54
</ body >
47
55
</ html >
You can’t perform that action at this time.
0 commit comments