mjmlio / mjml

MJML: the only framework that makes responsive-email easy

Home Page:https://mjml.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Columns are aligning Vertically in desktop mode, when applying border using css class

TejasGupta31 opened this issue · comments

Describe the bug
When applying border using css-class, columns are getting aligned vertically instead of horizontally.
I am applying border using css-class because of border-radius.
Screenshot 2024-01-09 at 5 13 57 PM

To Reproduce

<mjml>
    <mj-head>
    <mj-style>
      .red-text {
      	border: 5px solid red;
      }
    </mj-style>
  </mj-head>
  <mj-body>
    <mj-section>
      <mj-column css-class="red-text">
        <mj-text font-size="20px" color="#F45E43" font-family="helvetica">Hello World</mj-text>

      </mj-column>
      <mj-column>
        <mj-text font-size="20px" color="#F45E43" font-family="helvetica">Hello World</mj-text>

      </mj-column>
    </mj-section>
  </mj-body>
</mjml>

This is how HTML works here https://developer.mozilla.org/en-US/docs/Web/CSS/box-sizing
You can subtract manually the border size to your column width and define them as px instead of %