最新消息:20210816 当前crifan.com域名已被污染,为防止失联,请关注(页面右下角的)公众号

【间接解决】Gitbook的markdown中如何实现表格内组合单元格

gitbook crifan 9314浏览 0评论

gitbook中,希望用markdown实现这种的表格:

即:表格中某些单元格是组合在一起的

此处表头的1,2列,3,4列分别组合(后居中对齐)

markdown table cell merge

github markdown colspan – Stack Overflow

只能内嵌html

Does the markdown table support colspan? – TestRail Discussion – Gurock Community & TestRail Forum

Tables in pure Markdown – Extensions – CommonMark Discussion

Advanced tables (colspan / rowspan / multi-paragraph)? · Issue #87 · gettalong/kramdown

Tables

how can I merge cells in a table?

【总结】

最后用内嵌html代码:

<table>

  <tr>

    <td colspan=”2″ >总部库存</td>

    <td colspan=”2″ >经销商库存</td>

  </tr>

  <tr>

    <td>(在产线上)生产中</td>

    <td>已下线(到总部的库存中)</td>

    <td>(用大卡车从总部)在途中(运往经销商4S店)</td>

    <td>已到店(进去4S店的库存)</td>

  </tr>

</table>

效果:

然后再去设置对齐和表头的背景色:

    <td colspan=”2″ align=”center” style=”background-color:#2674BA; color:white; font-weight:700;”>总部库存</td>

    <td colspan=”2″ align=”center” style=”background-color:#2674BA; color:white; font-weight:700;”>经销商库存</td>

效果:

转载请注明:在路上 » 【间接解决】Gitbook的markdown中如何实现表格内组合单元格

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
82 queries in 0.174 seconds, using 22.16MB memory