mjml icon indicating copy to clipboard operation
mjml copied to clipboard

mj-table - support the default unset width

Open bladeSk opened this issue 1 year ago • 1 comments

Is your feature request related to a problem? Please describe. <mj-table> can't be used without setting an explicit width in px or %. That means html table's default behavior of fitting the content can't he used without hacks. It would be useful to have an option to unset the width and use the default behavior.

Describe the solution you'd like Support unsetting the width or setting it to auto, ie. <mj-table width=""> or <mj-table width="auto">. While you can do this now, it produces errors and sets the width to NaN.

bladeSk avatar Oct 01 '24 10:10 bladeSk

Hi,

This should be easy to fix 👍

You can also use a plain html table in mj-text for now

iRyusa avatar Oct 01 '24 11:10 iRyusa

Hey @bladeSk, we've added the ability to set auto as the value of the width attribute on a mj-table, which will size the table to the width of the content.

dazgreer avatar Sep 02 '25 15:09 dazgreer