Re: How to Justify Heading Text for Equal Width on Both Sides

Solved

How to Justify Heading Text for Equal Width on Both Sides

Sheeks
Explorer
95 1 11

Can anyone teach me how to justify heading text so that it has equal width on both the right and left sides? Usually, you can set the alignment to right, left, or center, but I want the text to be evenly distributed across the width. Does anyone know how to do this?

https://sheeksorority.com/

Sheeks_0-1722004146697.png

 

Accepted Solution (1)

BSSCommerce-B2B
Shopify Partner
1197 311 368

This is an accepted solution.

Hi @Sheeks ,

Long time no see,

I haved checked your website on mobile view, you can try add css script in base.css : 

 

 

.slideshow-heading {
    text-align: justify;
    font-size: 21px !important;
    padding-left: 10px !important;
}

 

 

If you want the text on the slideshow to have equal width on both the right and left sides, you need to use the text-align: justify property. However, when using this property, it will automatically justify the text on both the left and right sides, adjusting the spacing based on the font size and the available space. Therefore, I added the font size attribute to display it properly.

As a result, the text displayed on the slideshow will become smaller.

The result will be: 

BSSCommerceB2B_0-1722079726950.png

We hope my suggestions will solved your issue.

 

If it is helpful, can you kindly give us likes and mark the solution for us? 

'Have a nice day sir !!

 

 

If our suggestions are useful, please let us know by giving it a like, marking it as a solution.


BSS: B2B Wholesale Solution |BSS: B2B Portal, Quote, Net 30 | B: B2B Lock Password Protect


Need help from our expert? Kindly share your request with us via community@bsscommerce.com


BSS Commerce - Full-service eCommerce Agency

View solution in original post

Replies 7 (7)

BSS-TekLabs
Shopify Partner
1842 526 612

- Here is the solution for you @Sheeks 
- Please follow these steps:

step.png

- Then find the base.css or theme.css file.
- Then add the following code at the end of the file and press 'Save' to save it.

.text-reveal-content span {
     text-align: center !important;
}

- Here is the result you will achieve:

BSSTekLabs_0-1722005114418.png

 

 

- Please press 'Like' and mark it as 'Solution' if you find it helpful. Thank you.

If our suggestions are useful, please let us know by giving it a like or marking it as a solution .
Need help from our expert? Kindly share your request with us via community@bsscommerce.com
BSS Commerce - Full-service eCommerce Agency

For give Gift to customers and Upsell in Cart, check out Salepify: Free Gifts with purchase


Post purchase upsell, downsell offers to improve sales and AOV
Salemate Post Purchase Upsell

Sheeks
Explorer
95 1 11

Owh like that. but no
i dont want it to simply be center
i want it to set the alignment to right, left, or center, but I want the text to be evenly distributed across the width.

BSS-TekLabs
Shopify Partner
1842 526 612

you can try it @Sheeks 

@media only screen and (max-width: 600px) {
.text-reveal-content span {
         text-align: justify !important;
    font-size: 36px !important;
}
}

BSSTekLabs_0-1722006300456.png

 

- Please press 'Like' and mark it as 'Solution' if you find it helpful. Thank you.

 

If our suggestions are useful, please let us know by giving it a like or marking it as a solution .
Need help from our expert? Kindly share your request with us via community@bsscommerce.com
BSS Commerce - Full-service eCommerce Agency

For give Gift to customers and Upsell in Cart, check out Salepify: Free Gifts with purchase


Post purchase upsell, downsell offers to improve sales and AOV
Salemate Post Purchase Upsell

Sheeks
Explorer
95 1 11

Nice! But i wish the right gap n left gap is same. Can?

BSS-TekLabs
Shopify Partner
1842 526 612
@media only screen and (max-width: 600px) {
.text-reveal-content span {
         text-align: justify !important;
    font-size: 36px !important;
}
.slideshow-content {
    max-width: 100% !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
}
.slideshow-content-wrapper .m-bottom-left {
        left: 0 !important;
    }
}

BSSTekLabs_0-1722050706098.png

 

Can you try this code @Sheeks 

- Please press 'Like' and mark it as 'Solution' if you find it helpful. Thank you.

If our suggestions are useful, please let us know by giving it a like or marking it as a solution .
Need help from our expert? Kindly share your request with us via community@bsscommerce.com
BSS Commerce - Full-service eCommerce Agency

For give Gift to customers and Upsell in Cart, check out Salepify: Free Gifts with purchase


Post purchase upsell, downsell offers to improve sales and AOV
Salemate Post Purchase Upsell

Sheeks
Explorer
95 1 11

I am sorry but it look weirdly like that

WhatsApp Image 2024-07-27 at 16.17.51.jpeg

WhatsApp Image 2024-07-27 at 16.17.51 (1).jpeg

  

BSSCommerce-B2B
Shopify Partner
1197 311 368

This is an accepted solution.

Hi @Sheeks ,

Long time no see,

I haved checked your website on mobile view, you can try add css script in base.css : 

 

 

.slideshow-heading {
    text-align: justify;
    font-size: 21px !important;
    padding-left: 10px !important;
}

 

 

If you want the text on the slideshow to have equal width on both the right and left sides, you need to use the text-align: justify property. However, when using this property, it will automatically justify the text on both the left and right sides, adjusting the spacing based on the font size and the available space. Therefore, I added the font size attribute to display it properly.

As a result, the text displayed on the slideshow will become smaller.

The result will be: 

BSSCommerceB2B_0-1722079726950.png

We hope my suggestions will solved your issue.

 

If it is helpful, can you kindly give us likes and mark the solution for us? 

'Have a nice day sir !!

 

 

If our suggestions are useful, please let us know by giving it a like, marking it as a solution.


BSS: B2B Wholesale Solution |BSS: B2B Portal, Quote, Net 30 | B: B2B Lock Password Protect


Need help from our expert? Kindly share your request with us via community@bsscommerce.com


BSS Commerce - Full-service eCommerce Agency