Centering image in 'Image with text'

Solved

Centering image in 'Image with text'

SoarMusic
Tourist
6 0 1

Hey there, 

 

I'm trying to center the image within the 'Image with text' section of my homepage. Here is a link to the store: https://portal.soarmusicgroup.com

 

I would like to center it only on mobile, as it is now overlapping the right corner of the screen (as pictured in the screenshot). I would like the image to stay centered and within the boundaries of the screen. image_2024-10-03_150307535.png

 

Thanks in advance for any help!

Accepted Solution (1)

Tech_Coding
Shopify Partner
514 132 131

This is an accepted solution.

Hello @SoarMusic 

You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid
<style>
@media screen and (max-width: 767px){
    [data-aos=fade-left] {
       transform: unset !important;
    }
}
</style>

Tech_Coding_0-1727961723571.png

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.
Shopify UI Developer
Your Coffee Tips adds a little sweetness to my day.

View solution in original post

Replies 3 (3)

Mehedi06
Shopify Partner
27 3 4

Hi @SoarMusic
Can you please follow these steps?

 

1. Go to the 'Edit Code' Section.
2. Find 'theme.liquid'.

3. Search (ctrl+f) '.image-with-text__media-item' class.
4. add 'transform: none' (like in the below screenshot).

Mehedi06_0-1727961311868.png

 

Then, it should look like this:

Mehedi06_1-1727961424313.png

 

Made4uo-Ribe
Shopify Partner
10119 2400 3033

Hi @SoarMusic 

check this one. 

From you Admin page, go to Online Store > Themes

Select the theme you want to edit

Under the Asset folder, open the main.css(base.css, style.css or theme.css)

Then place the code below at the very bottom of the file.

 

@media only screen and (max-width: 749px) {
  .image-with-text [data-aos=fade-left] {
    transform: none;
  }
}

 

And Save.

Result:

 

Made4uoRibe_0-1727961664422.png

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.

Tech_Coding
Shopify Partner
514 132 131

This is an accepted solution.

Hello @SoarMusic 

You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid
<style>
@media screen and (max-width: 767px){
    [data-aos=fade-left] {
       transform: unset !important;
    }
}
</style>

Tech_Coding_0-1727961723571.png

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.
Shopify UI Developer
Your Coffee Tips adds a little sweetness to my day.