File tree Expand file tree Collapse file tree 4 files changed +4
-7
lines changed
packages/uikit-workshop/src/scripts/lit-components Expand file tree Collapse file tree 4 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -104,15 +104,14 @@ class Drawer extends LitElement {
104
104
: 300
105
105
: 0 ;
106
106
107
- const coverStyles = { display : this . isMouseDown ? 'block' : 'none' } ;
108
107
const drawerStyles = {
109
108
height : `${ renderedHeight } px` ,
110
109
transitionDuration : this . isMouseDown ? '0ms' : '300ms' ,
111
110
} ;
112
111
113
112
return html `
114
113
< div >
115
- < div class ="pl-c-drawer__cover " style ="${ styleMap ( coverStyles ) } "> </ div >
114
+ < div class ="pl-c-drawer__cover " ?hidden ="${ ! this . isMouseDown } "> </ div >
116
115
< div style ="${ styleMap ( drawerStyles ) } " class ="pl-c-drawer__wrapper ">
117
116
< div class ="pl-c-drawer__resizer " @mousedown ="${ this . onMouseDown } ">
118
117
< svg
Original file line number Diff line number Diff line change @@ -144,7 +144,6 @@ pl-drawer {
144
144
height : 100% ;
145
145
top : 0 ;
146
146
left : 0 ;
147
- display : none ;
148
147
position : fixed ;
149
148
z-index : 20 ;
150
149
cursor : move ;
Original file line number Diff line number Diff line change @@ -405,7 +405,7 @@ class IFrame extends BaseLitComponent {
405
405
406
406
return html `
407
407
< div class ="pl-c-viewport pl-js-viewport ">
408
- < div class ="pl-c-viewport__cover pl-js-viewport-cover "> </ div >
408
+ < div class ="pl-c-viewport__cover pl-js-viewport-cover " hidden > </ div >
409
409
< div
410
410
class ="pl-c-viewport__iframe-wrapper pl-js-vp-iframe-container "
411
411
style ="width: ${ initialWidth } "
@@ -450,7 +450,7 @@ class IFrame extends BaseLitComponent {
450
450
this . fullMode = false ;
451
451
452
452
// show the cover
453
- this . iframeCover . style . display = 'block' ;
453
+ this . iframeCover . hidden = false ;
454
454
455
455
function handleIframeCoverResize ( e ) {
456
456
const viewportWidth = origViewportWidth + 2 * ( e . clientX - origClientX ) ;
@@ -476,7 +476,7 @@ class IFrame extends BaseLitComponent {
476
476
'mousemove' ,
477
477
handleIframeCoverResize
478
478
) ;
479
- self . iframeCover . style . display = 'none' ;
479
+ self . iframeCover . hidden = true ;
480
480
self
481
481
. querySelector ( '.pl-js-resize-handle' )
482
482
. classList . remove ( 'is-resizing' ) ;
Original file line number Diff line number Diff line change @@ -57,7 +57,6 @@ pl-iframe {
57
57
.pl-c-viewport__cover {
58
58
width : 100% ;
59
59
height : 100% ;
60
- display : none ;
61
60
position : fixed ;
62
61
top : 0 ;
63
62
left : 0 ;
You can’t perform that action at this time.
0 commit comments