mdast2docx logo Md2Docx
Version 0.0.10API DocsFunctions

createLevels()

Updated 5 min ago

createLevels(levelFormats, indent?, indentStep?): object[]

Defined in: index.ts:55

Generates a list of numbering levels for ordered lists.

Parameters

levelFormats

("none" | "bullet" | "hex" | "decimal" | "upperRoman" | "lowerRoman" | "upperLetter" | "lowerLetter" | "ordinal" | "cardinalText" | "ordinalText" | "chicago" | "ideographDigital" | "japaneseCounting" | "aiueo" | "iroha" | "decimalFullWidth" | "decimalHalfWidth" | "japaneseLegal" | "japaneseDigitalTenThousand" | "decimalEnclosedCircle" | "decimalFullWidth2" | "aiueoFullWidth" | "irohaFullWidth" | "decimalZero" | "ganada" | "chosung" | "decimalEnclosedFullstop" | "decimalEnclosedParen" | "decimalEnclosedCircleChinese" | "ideographEnclosedCircle" | "ideographTraditional" | "ideographZodiac" | "ideographZodiacTraditional" | "taiwaneseCounting" | "ideographLegalTraditional" | "taiwaneseCountingThousand" | "taiwaneseDigital" | "chineseCounting" | "chineseLegalSimplified" | "chineseCountingThousand" | "koreanDigital" | "koreanCounting" | "koreanLegal" | "koreanDigital2" | "vietnameseCounting" | "russianLower" | "russianUpper" | "numberInDash" | "hebrew1" | "hebrew2" | "arabicAlpha" | "arabicAbjad" | "hindiVowels" | "hindiConsonants" | "hindiNumbers" | "hindiCounting" | "thaiLetters" | "thaiNumbers" | "thaiCounting" | "bahtText" | "dollarText" | "custom")[]

An array of level formats defining the numbering style at each level.

indent?

number = 0.4

The starting indentation in inches for the first level.

indentStep?

number = 0.25

The incremental indentation added for each subsequent level.

Returns

object[]

An array of ILevelsOptions defining the hierarchical numbering style.

Example:

  • Level 1: "1."
  • Level 2: "1.1."
  • Level 3: "1.1.1."
  • Level 4: "A."
  • Level 5: "a."

On this page