Support Markdown table alignment

Created on 19 June 2025, 25 days ago

Based on #3493938-30: Support additional extensions (and some follow-on comments), we need to add proper support for table cell alignment.

Based on that discussion, I'd rather not use the deprecated align, nor do I think inline style is the best idea, so it seems like a Markdown Easy CSS library is going to be necessary. More info on #3493938-35: Support additional extensions

-mike

📌 Task
Status

Active

Version

2.0

Component

Code

Created by

🇺🇸United States ultimike Florida, USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @ultimike
  • First commit to issue fork.
  • Pipeline finished with Success
    25 days ago
    Total: 323s
    #526662
  • Pipeline finished with Success
    25 days ago
    Total: 330s
    #526661
  • Pipeline finished with Success
    25 days ago
    #526666
  • 🇮🇪Ireland lostcarpark

    I've added the config to generate the correct HTML to use a CSS class. Also added a test case to verify.

    Still need to add the library and link to the output HTML.

  • Pipeline finished with Success
    12 days ago
    Total: 184s
    #537463
  • Pipeline finished with Success
    11 days ago
    Total: 193s
    #537829
  • Pipeline finished with Success
    11 days ago
    Total: 235s
    #538592
  • Pipeline finished with Failed
    11 days ago
    Total: 350s
    #538638
  • Pipeline finished with Failed
    11 days ago
    Total: 337s
    #538648
  • Pipeline finished with Success
    11 days ago
    Total: 390s
    #538652
  • 🇮🇪Ireland lostcarpark

    Added a library with CSS classes for left, centre, and right table cells.

    It seems a waste to always load this, since it will only be required by a minority of markdown that makes use of tables.

    To prevent this, I have added a regex check for table cells with relevant classes, in the converted text, and only load the library if needed.

    I check for the presence of the CSS file, and table cells in FilterTest.

    Ready for review.

  • Pipeline finished with Skipped
    10 days ago
    #538979
  • Pipeline finished with Skipped
    10 days ago
    #538989
  • 🇺🇸United States ultimike Florida, USA

    Looks good, @lostcarpark!

    I especially like the bit about only loading the library when the proper alignment syntax is present! 🤘🏼

    Also, thanks for consolidating some of the test strings into constants.

    Merged.

    thank you!
    -mike

Production build 0.71.5 2024