fix scroll view activation in tests

This commit is contained in:
Hakim El Hattab committed 2023-10-25 14:13:51 +02:00
1 parent c23964274c
commit 942be4ee42
5 files changed
+5 -5

No files matched your search

+1 -1
View File
@@ -1021,7 +1021,7 @@ export default function( revealElement, options ) {
// width configured. Ignore if we're configured to always be in
// scroll mode.
if( typeof config.scrollActivationWidth === 'number' && config.view !== 'scroll' ) {
if( size.presentationWidth <= config.scrollActivationWidth ) {
if( size.presentationWidth > 0 && size.presentationWidth <= config.scrollActivationWidth ) {
if( !scrollView.isActive() ) scrollView.activate();
}
else {