Skip to content

Typst rule does not work on markdown table #10875

Closed Answered by gordonwoodhull
oliviermeslin asked this question in Q&A
Discussion options

You must be logged in to vote

This happens because you have specified left alignment for all columns with :----

This causes Pandoc to add column alignment

align: (left,left,left,left,),

to the table, and this takes precedence over your show rule.

One way to get the effect you want is to remove the alignment specification from your markdown table and instead set default left cell alignment via a show rule instead:


```{=typst}
#show table.cell: set align(left)
#show table.cell.where(y: 0): set align(center)
```


| Month    | Title                  | Author              | Genre         |
|----------|------------------------|---------------------|---------------|
| January  | The Great Gatsby       | F. Scott Fitzgeral…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@oliviermeslin
Comment options

Comment options

You must be logged in to vote
1 reply
@oliviermeslin
Comment options

Answer selected by oliviermeslin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
typst themes Related to HTML theming or any other style related issue (like highlight-style)
3 participants
Converted from issue

This discussion was converted from issue #10872 on September 24, 2024 16:23.