Markdown OKF-Schema Studio

Behaviour SwRS-MDOKFSTUDIO-MYST-063

Table directives render as ordinary tables

When a document holds a `{list-table}`, `{csv-table}` or `{table}` directive, the extension SHALL render it as an ordinary table with the table styles, with its caption, header rows, widths and alignment as the directive options give them, and offer the table palette action.

Step 1 of path 2 in StRS-MDOKFSTUDIO-MYST-017: from “A document holds a list-table, csv-table or table directive” to “A document holds a raw HTML table”.

Scenarios 8

The situations the tests check; open one to read it.

nominalA list-table renders like a pipe table
Givena `{list-table}` with title, two header rows and widths `30 70`
Whenthe preview renders
Thena caption, two header rows and 30/70 column proportions appear, with `:align:` and inline Markdown cells, as one source block with no overflow, and cell, header and border styles match a pipe table
boundaryList-table header rows
InputOutcome
`:header-rows: 1`The first row is in `thead` with `th`
`:header-rows: 0`No header cells are made
refusalInvalid list-table widths are ignored
InputOutcome
`:widths: auto`No column group exists
`:widths: grid`No column group exists
Non numeric widthsNo column group exists
Three widths for two columnsNo column group exists
Valid widthsApplied as percent
nominalA list-table is edited as one block
Givena `{list-table}` and a Markdown table
Whena cell is clicked in edit mode
Thenthe whole list-table opens in one editor, because its cell paragraphs carry no source line, while a Markdown table opens its cell editor
nominalThe table directive keeps caption, id and alignment
Givena `{table}` with caption, `:label:` and `:align: center` around a pipe table with aligned columns
Whenthe preview renders
Thena captioned table has the label as id, is aligned and keeps each column's GFM alignment on every cell; palette-written captioned tables render a caption
boundaryA table directive around a raw HTML table
Givena `{table}` with `:align:` around a raw HTML table
Whenthe preview renders
Thenthe HTML table takes the alignment
nominalThe csv-table directive renders a table
InputOutcome
A `{csv-table}` with `:header:` and a quoted cell spanning two linesThe header row is made and the quoted cell holds both lines
A `{csv-table}` with a caption and `:align: right` and no `:header:`The table has the caption and alignment and no header cells
nominalThe table directive family shares the table styles and palette action
InputOutcome
A `{list-table}`Table styles apply and the table palette action is offered
A `{csv-table}`The same table styles
A `{table}`The same table styles

Implemented in 2

Tested by 3

Replaces

SwRS-MDOKFSTUDIO-CORE-057Render list-table headers, widths and alignment superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file
SwRS-MDOKFSTUDIO-CORE-058Edit a list-table as one block superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file
SwRS-MDOKFSTUDIO-MYST-064Invalid list-table widths are ignored superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file
SwRS-MDOKFSTUDIO-MYST-065The table directive renders a table with caption, id and alignment superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file
SwRS-MDOKFSTUDIO-MYST-088The csv-table directive renders a table superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file
SwRS-MDOKFSTUDIO-MYST-092The table directive family renders with its own styles and actions superseded superseded by SwRS-MDOKFSTUDIO-MYST-063 Markdown file