You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When placing a mj-raw tag alongside of a mj-column, the raw content counts as a column and the mj-column finds itself with a class which does not represent the number of columns present in the section.
In all logic, it should only take into account the columns in sections and not the mj-raw.
And after many hours of reading the docs, I found nowhere that it was forbidden to use mj-raw in a section. Only thing I can notice is (in mj-section): "Also, any content in a section should also be wrapped in a column. "
The use I have in placing mj-raw tags alongside of mj-column is that we generate a template and use the mj-raw to insert loops. I also think that mj-raw should be allowed to be placed everywhere and not directly interfere with the layout.
Hi @ChrisRast thanks for reporting this, after discussing it we decided to only ignore raw elements in this width calculation, all other elements will be counted. We'll update the doc accordingly
When placing a
mj-raw
tag alongside of amj-column
, the raw content counts as a column and themj-column
finds itself with a class which does not represent the number of columns present in the section.The doc states (emphasis by me):
In all logic, it should only take into account the columns in sections and not the
mj-raw
.And after many hours of reading the docs, I found nowhere that it was forbidden to use
mj-raw
in a section. Only thing I can notice is (in mj-section): "Also, any content in a section should also be wrapped in a column. "The use I have in placing
mj-raw
tags alongside ofmj-column
is that we generate a template and use themj-raw
to insert loops. I also think that mj-raw should be allowed to be placed everywhere and not directly interfere with the layout.Reproduction Steps:
mjml.js
file:yarn add mjml
, verify that you run the latest:yarn list --pattern mjml
node mjml.js
Expected behavior:
The HTML (div) generated from mj-column should have the class
mj-column-per-100
.Observed behavior:
The HTML (div) generated from
mj-colum
has the classmj-column-per-33
.Generated file (redacted for lisibility):
MJML version:
yarn list --pattern mjml
Thank you all for this amazing tool by the way! 👏
The text was updated successfully, but these errors were encountered: