File tree Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Original file line number Diff line number Diff line change 37
37
"iron-component-page" : " ^3.0.0" ,
38
38
"iron-test-helpers" : " ^2.0.0" ,
39
39
"vaadin-button" : " vaadin/vaadin-button#^2.4.0-alpha1" ,
40
+ "vaadin-text-field" : " vaadin/vaadin-text-field#~2.7.0-alpha6" ,
40
41
"webcomponentsjs" : " ^1.0.0" ,
41
42
"web-component-tester" : " ^6.1.5" ,
42
43
"vaadin-demo-helpers" : " vaadin/vaadin-demo-helpers#^3.1.0-alpha1"
Original file line number Diff line number Diff line change 401
401
}
402
402
403
403
Object . assign ( overlay . style , parsedBounds ) ;
404
+
405
+ // Force reflow in Safari 13 to recalculate height
406
+ overlay . style . display = 'block' ;
407
+ window . requestAnimationFrame ( ( ) => {
408
+ overlay . style . display = '' ;
409
+ } ) ;
404
410
}
405
411
406
412
/** @private */
Original file line number Diff line number Diff line change 7
7
< link rel ="import " href ="../../test-fixture/test-fixture.html ">
8
8
< link rel ="import " href ="../../iron-test-helpers/iron-test-helpers.html ">
9
9
< link rel ="import " href ="../src/vaadin-dialog.html ">
10
+ < link rel ="import " href ="../../vaadin-text-field/vaadin-text-area.html ">
10
11
</ head >
11
12
12
13
< body >
756
757
overlay . $ . overlay . setAttribute ( 'style' , '' ) ;
757
758
expect ( overlay . $ . overlay . offsetHeight ) . to . equal ( overlay . $ . resizerContainer . offsetHeight ) ;
758
759
} ) ;
760
+
761
+ it ( 'should not overflow when using vaadin-textarea in the content' , ( done ) => {
762
+ const textarea = document . createElement ( 'vaadin-text-area' ) ;
763
+ textarea . value = Array ( 20 ) . join ( 'Lorem ipsum dolor sit amet' ) ;
764
+ const overlay = dialog . $ . overlay ;
765
+ overlay . content . appendChild ( textarea ) ;
766
+ overlay . $ . content . style . padding = '20px' ;
767
+ // emulate resizing the dialog
768
+ dialog . _setBounds ( { height : 50 } ) ;
769
+
770
+ window . requestAnimationFrame ( ( ) => {
771
+ expect ( getComputedStyle ( overlay . $ . overlay ) . height ) . to . equal ( getComputedStyle ( overlay . $ . resizerContainer ) . height ) ;
772
+ done ( ) ;
773
+ } ) ;
774
+ } ) ;
759
775
} ) ;
760
776
</ script >
761
777
</ body >
You can’t perform that action at this time.
0 commit comments