Jump to content

Need Help To Place Mobile Buttons Side-By-Side

Go to solution Solved by Web_Solutions,

Recommended Posts

Posted

Site URL: www.sggonewild.com/tags

Currently, the buttons are stacked when viewed on mobile. I'd like to change the buttons to be displayed side-by-side, with the same width.

image.thumb.png.55ee39ee6e1baa52d89d19c9697a92ea.png

Posted (edited)

Try inserting this into custom CSS:

@media screen and (max-width: 640px) {
.col.sqs-col-4.span-4 {
    width: 33.33%!important;
    display: inline-block;
}

.small-button-style-outline .sqs-block-button .sqs-block-button-element--small {
    width: 95px;
    padding-left: 2px;
    padding-right: 2px;
    font-size: 9px;
    color: #000;
}


}

 

Edited by DPruitt
  • 2 weeks later...
  • Solution
Posted
9 minutes ago, nataniellam said:

Hi @DPruitt, thanks for the reply. It works but is it possible to align the buttons to the center, and not let it go out of the screen? Thanks

image.png.706c42570f4c6b4bbb2707798a6245b5.png

 

Replace the previous code with the code below

@media screen and (max-width: 640px) {
  #collection-64cf42bd08338832a9d40ec0 {
    .sqs-col-12 > .sqs-row {
      display: flex !important;
      justify-content: center;
      #block-yui_3_17_2_1_1691304644309_1821, #block-yui_3_17_2_1_1691304644309_2944 {
        padding-left: 0 !important;
        padding-right: 0 !important;
      }
      #block-yui_3_17_2_1_1691304644309_2357 {
        padding-left: 5px !important;
        padding-right: 5px !important;
        a.sqs-block-button-element--small {
          padding: 13px 15px !important;
          font-size: 9px !important;
        }
      }
    }
  }
}

 

Screenshot_144.png

If my comments are useful, please like and mark my solution as answer. It will encourage me. Thanks

MD Rofik
Website Designer and Digital Marketer

Am I helpful? Want to offer me a coffee?
Send me a message if needed any help. I'll try to reply as soon as possible.


 

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.