Jump to content

Cant Scroll on Android

Recommended Posts

Site URL: https://www.recaprabbithole.com/recap/human-viruses

I cant scroll on android phones. I am using some custom CSS, that @tuanphan helped create (thank you!),  to make images stretch across the entire screen on my blog posts, here:

@media screen and (max-width:767px) {
/*This stretches the everything across the screen on the blog posts*/
/* make image fullwidth */
.blog-item-wrapper article.entry {
    padding-left: 0;
    padding-right: 0;
}
/* Add padding around text blocks, both sides, leaving out, image/gallery/embed - blocks */
.blog-item-wrapper .sqs-layout>.row>.col>div:not(.image-block, .gallery-block, .embed-block) {
    padding-left: 9vw;
    padding-right: 9vw;
}
/*This code fixes the iphone horizontal scrolling, but stops all scrolling on androids*/
 html, body {
   overflow: hidden;
}
}

I know the piece of code that is causing the issue:

/*This code fixes the iphone horizontal scrolling, but stops all scrolling on androids*/
 html, body {
   overflow: hidden;
}

But without this code above, the mobile site has a black bar on the right-hand side, allowing strange horizontal scrolling on iPhones, see attached video for issue without red code.

How should I revise this code, to allow scrolling on android phones?

@paul2009 Do you have any thoughts?

 

 

Link to comment
  • Replies 2
  • Views 936
  • Created
  • Last Reply

If you are experiencing overflow (the extra black area to the right) you are usually better off finding the cause, than adding workarounds. That said, the code above is incorrect and the cause of the no-scroll issue. It should be 

overflow-x: hidden

not 

overflow: hidden

 

About me: I've been a SQSP User for 18 yrs. I was invited to join the Circle when it launched in 2016. I have been a Circle Leader since 2017. I don't work for Squarespace. I value honesty, transparency, diversity and good design ♥.
Work: I founded and run SF.DIGITAL, building Squarespace Extensions to supercharge your commerce website. 
Content: Views and opinions are my own. Links in my posts may refer to SF.DIGITAL products or may be affiliate links.
Forum advice is free. You can thank me by clicking one of the feedback emojis below. Coffee is optional.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.