Jump to content

Stop Text from Wrapping for Scrolling Text on Mobile Version

Recommended Posts

Hi there!

I currently have scrolling text animation on my website , however, both the desktop and mobile version wraps the text as seen in below photos. Can someone please help me to modify the below code so that the text stops wrapping all together on all screens? 

Thanks so much! 🙂

.scroll{font-family:Milestone; font-size:2.7rem; color: transparent!important; -webkit-text-stroke-width:
1px; -webkit-text-stroke-color: #FFFFFF; overflow: hidden!important;
position: relative!important;
 -moz-transform:translateX(100%);
 -webkit-transform:translateX(100%);  
 transform:translateX(100%);
 -moz-animation: scroll 15s linear infinite;
 -webkit-animation: scroll 15s linear infinite;
  animation: scroll 15s linear infinite;}

@-moz-keyframes scroll {
 0%   { -moz-transform: translateX(100%); }
 100% { -moz-transform: translateX(-100%); }

}
@-webkit-keyframes scroll  {
 0%   { -webkit-transform: translateX(100%); }
 100% { -webkit-transform: translateX(-100%); }
}
#page {overflow-x:hidden}

1106053358_ScreenShot2021-04-16at3_50_22pm.thumb.png.f743eade2a6322cb9481d8346f766c24.png1662278919_ScreenShot2021-04-16at3_52_34pm.thumb.png.66e8558fac1e3c5c1ffe6f95256bbbce.png

Link to comment
On 4/16/2021 at 8:53 PM, Ruby-Rose said:

Hi there!

I currently have scrolling text animation on my website , however, both the desktop and mobile version wraps the text as seen in below photos. Can someone please help me to modify the below code so that the text stops wrapping all together on all screens? 

Thanks so much! 🙂


.scroll{font-family:Milestone; font-size:2.7rem; color: transparent!important; -webkit-text-stroke-width:
1px; -webkit-text-stroke-color: #FFFFFF; overflow: hidden!important;
position: relative!important;
 -moz-transform:translateX(100%);
 -webkit-transform:translateX(100%);  
 transform:translateX(100%);
 -moz-animation: scroll 15s linear infinite;
 -webkit-animation: scroll 15s linear infinite;
  animation: scroll 15s linear infinite;}

@-moz-keyframes scroll {
 0%   { -moz-transform: translateX(100%); }
 100% { -moz-transform: translateX(-100%); }

}
@-webkit-keyframes scroll  {
 0%   { -webkit-transform: translateX(100%); }
 100% { -webkit-transform: translateX(-100%); }
}
#page {overflow-x:hidden}

1106053358_ScreenShot2021-04-16at3_50_22pm.thumb.png.f743eade2a6322cb9481d8346f766c24.png1662278919_ScreenShot2021-04-16at3_52_34pm.thumb.png.66e8558fac1e3c5c1ffe6f95256bbbce.png

Whatis your site url?

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date format)
💫 Animated Buttons (Referral URL)
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment
On 4/19/2021 at 4:07 PM, Ruby-Rose said:

Hello! Thanks so much for getting back to me. 

https://casamaria.uk/ 

Password: Mooncake444

Let me know if you need anything else 🙂

Ruby

Add to Design > Custom CSS

/* stop scrolling text wrap */
[data-section-id="607974dc60a5d11519835e5c"] .content {
    width: 100% !Important;
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

Link to comment
19 hours ago, Ruby-Rose said:

Hello! 

Thanks so much for your help however once the code has been inserted the desktop version still has one word that is wrapping and it hasn't worked at all for mobile version .. 😞  any other ideas? 

Thanks again 🙂
 

You can reduce text size, with this CSS

/* Animated text size */
.scroll {
    font-size: 2.2em !important;
}

You mean all text on same line on mobile? They will be very small

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

Link to comment

Hello! 

Thanks again for getting back to me. Your code helps me to make the text smaller however the text still wraps as seen in the screen shot below.... any other ideas? or do you think it's a fault with the original code? 
Thank you for your help so far 🙂
1006423489_ScreenShot2021-04-24at11_15_02am.thumb.png.a4c9420c1474ad4d5038ad30c916e05a.png

Link to comment
17 hours ago, Ruby-Rose said:

Hello! 

Thanks again for getting back to me. Your code helps me to make the text smaller however the text still wraps as seen in the screen shot below.... any other ideas? or do you think it's a fault with the original code? 
Thank you for your help so far 🙂
1006423489_ScreenShot2021-04-24at11_15_02am.thumb.png.a4c9420c1474ad4d5038ad30c916e05a.png

Use this to prevent wrap

/* Scrolling text */
.scroll {
    white-space: nowrap !important;
    font-size: 1.2em !important;
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • 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.