aboutsummaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2020-04-17 10:04:39 -0700
committerGitHub <noreply@github.com>2020-04-17 10:04:39 -0700
commit906305de789c83f9fdcc2c7d30044acf97e89582 (patch)
treef359e991e60e7324f11e73a40259ed9dc3e4b91b /data
parentf0f3cc14beeea51f703f7cfc8b40ebf3de2d0a05 (diff)
parentd1521af8fb0d3e8ee4104224e4d5e0b6e6bfad8c (diff)
downloadpandoc-906305de789c83f9fdcc2c7d30044acf97e89582.tar.gz
Merge pull request #6224 from despresc/better-tables
Diffstat (limited to 'data')
-rw-r--r--data/pandoc.lua27
1 files changed, 14 insertions, 13 deletions
diff --git a/data/pandoc.lua b/data/pandoc.lua
index d1c88d0a1..e9b6209c3 100644
--- a/data/pandoc.lua
+++ b/data/pandoc.lua
@@ -556,26 +556,27 @@ M.RawBlock = M.Block:create_constructor(
--- Creates a table element.
-- @function Table
--- @tparam {Inline,...} caption table caption
--- @tparam {AlignDefault|AlignLeft|AlignRight|AlignCenter,...} aligns alignments
--- @tparam {int,...} widths column widths
--- @tparam {Block,...} headers header row
--- @tparam {{Block,...}} rows table rows
--- @treturn Block table element
+-- @tparam Attr attr attributes
+-- @tparam Caption caption table caption
+-- @tparam {ColSpec,...} colspecs column alignments and widths
+-- @tparam TableHead head table head
+-- @tparam {TableBody,..} bodies table bodies
+-- @treturn TableFoot foot table foot
M.Table = M.Block:create_constructor(
"Table",
- function(caption, aligns, widths, headers, rows)
+ function(attr, caption, colspecs, head, bodies, foot)
return {
c = {
- ensureInlineList(caption),
- List:new(aligns),
- List:new(widths),
- List:new(headers),
- List:new(rows)
+ attr,
+ caption,
+ List:new(colspecs),
+ head,
+ List:new(bodies),
+ foot
}
}
end,
- {"caption", "aligns", "widths", "headers", "rows"}
+ {"attr", "caption", "colspecs", "head", "bodies", "foot"}
)