Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-24014

I can make the first column a header but it doesn't get saved

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • 18.0.1
    • Blocknote
    • None
    • Unknown

    Description

      Follow these steps to reproduce:

      • create a new empty page
      • insert a table
      • fill the table cells with some values
      • open the menu for the first column
      • click on "Header column"
      • save

      Even if the table looks fine in edit mode, and I can also make both the first column and the first row headers, which is nice, on save this information is lost. Only the first row remains as header, but I'm not surprised given XWIKI-24013.

      Note that fixing this issue will require some changes to the UniAst syntax and its parser / renderer on the server side. Currently, UniAst defines tables like this:

      {
        type: "table";
        columns: TableColumn[];
        rows: TableCell[][];
        styles: BlockStyles;
      }
      
      type TableColumn = { headerCell?: TableCell; widthPx?: number };
      
      type TableCell = {
        content: InlineContent[];
        styles: BlockStyles;
        rowSpan?: number;
        colSpan?: number;
      };
      

      Which means UniAst supports a single table header, and you can't specify if it's a row or column. It's a row, the first one, all the time. But it looks like BlockNote supports having both a header column and a header row. If that is the case then we'll have to update UniAst.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              mflorea Marius Dumitru Florea
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: