How to Justify Heading Text for Equal Width on Both Sides

Solved

How to Justify Heading Text for Equal Width on Both Sides

Sheeks
Pathfinder
109 1 16

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
1972 564 568

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 !!

 

 

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

View solution in original post

Replies 7 (7)

BSS-TekLabs
Shopify Partner
2401 695 835

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


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now
Sheeks
Pathfinder
109 1 16

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
2401 695 835

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.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now
Sheeks
Pathfinder
109 1 16

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

BSS-TekLabs
Shopify Partner
2401 695 835
@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.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now
Sheeks
Pathfinder
109 1 16

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
1972 564 568

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 !!

 

 

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now