marktext/docs/dev/code/BLOCK_ADDITION_PROPERTY.md
Ran Luo 5b8da2cdf4
Optimization of code block (#1445)
* duplicate css rule

* remove all codeLine

* Fix: #1446

* Fix #942 #1310

* Fix copy paste will add one more empty line in code block

* remove debug codes

* Fix update thematic break error

* fix: #1447

* Update octokit/rest and url-loader

* Fix: CI test error

* Fix comment issue1

* Fix: escape charachters in code block
2019-10-08 14:12:51 +08:00

1.8 KiB
Raw Blame History

Block addition properties and its value

1. span
  • functionType

    • languageInput

    • codeContent (used in code block)

    • atxLine (can not contain soft line break and hard line break use in atx heading)

    • thematicBreakLine (can not contain soft line break and hard line break use in thematic break)

    • paragraphContent (defaultValue use in paragraph and setext heading)

  • lang - only when it's functionType is codeContent

    • All prismjs support language or empty string
2. div

used for preview block math, mermaid, flowchart, vega-lite, sequence and html block.

  • functionType

    • multiplemath

    • mermaid

    • flowchart

    • vega-lite

    • sequence

    • html

3. figure

The container block of table, html, block math, mermaid,flowchart,vega-lite,sequence.

  • functionType

    • table

    • html

    • multiplemath

    • mermaid

    • flowchart

    • vega-lite

    • sequence

4. pre

Used for html,block math,mermaid,flowchart,vega-lite,sequence code block.

  • functionType

    • html

    • multiplemath

    • mermaid

    • flowchart

    • vega-lite

    • sequence

    • fencecode

    • indentcode

    • frontmatter

  • lang

    • all prismjs support language or empty string
5. code
  • lang

    • all prismjs support language or empty string
ul
  • listType

    • bullet

    • task

ol
  • listType

    • order
  • start

    • 0-999999999
li
  • listItemType

    • order

    • bullet

    • task

  • isLooseListItem

    • true

    • false

  • bulletMarkerOrDelimiter

    • bulletMarker-, +, *

    • Delimiter ), .

h1~6
  • headingStyle

    • atx

    • setext

  • marker - only setext heading has marker

input
  • checked

    • true

    • false

table
  • row

  • column

th/td
  • align

  • column