Skip to content

Commit

Permalink
Rename option contentType to contentLevel
Browse files Browse the repository at this point in the history
  • Loading branch information
Witiko committed Feb 12, 2024
1 parent 3ce4083 commit ca98e03
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
22 changes: 11 additions & 11 deletions markdown.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -5209,25 +5209,25 @@ defaultOptions.contentBlocks = false
%</lua,lua-cli>
%<*manual-options>

#### Option `contentType`
#### Option `contentLevel`

`contentType` (default value: `block`)
`contentLevel` (default value: `block`)

% \fi
% \begin{markdown}
%
% \Optitem[block]{contentType}{\opt{block}, \opt{inline}}
% \Optitem[block]{contentLevel}{\opt{block}, \opt{inline}}
%
: block

: Treat content as a sequence of blocks.
``` md
- this is a list
- it contains two items
``````

: inline

: Treat all content as inline content.
``` md
- this is a text
Expand All @@ -5243,7 +5243,7 @@ Using a text editor, create a text document named `document.tex` with the
following content:
``` tex
\input markdown
\def\markdownOptionContentType{inline}
\def\markdownOptionContentLevel{inline}
\markdownBegin
- this is
- a text
Expand Down Expand Up @@ -5273,7 +5273,7 @@ following content:
- a list
\end{markdown}

\begin{markdown}[contentType=inline]
\begin{markdown}[contentLevel=inline]
- this is
- a text
\end{markdown}
Expand Down Expand Up @@ -5305,7 +5305,7 @@ following content:
- a list
\stopmarkdown

\setupmarkdown[contentType = inline]
\setupmarkdown[contentLevel = inline]
\startmarkdown
- this is
- a text
Expand All @@ -5330,7 +5330,7 @@ following text:
% \fi
% \begin{macrocode}
\@@_add_lua_option:nnn
{ contentType }
{ contentLevel }
{ string }
{ block }
% \end{macrocode}
Expand All @@ -5339,7 +5339,7 @@ following text:
%<*lua,lua-cli>
% \fi
% \begin{macrocode}
defaultOptions.contentType = "block"
defaultOptions.contentLevel = "block"
% \end{macrocode}
% \par
% \iffalse
Expand Down Expand Up @@ -29436,7 +29436,7 @@ end
syntax.AutoLinkRelativeReference = parsers.fail
end

if options.contentType == "inline" then
if options.contentLevel == "inline" then
syntax[1] = "Inlines"
syntax.Inlines = V("InitializeState")
* parsers.Inline^0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
\markdownSetup{contentType=block}
\markdownSetup{contentLevel=block}
<<<
This test ensures that the Lua `contentType` option correctly propagates
through the plain TeX interface. Setting the `contentType` option to the
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
\markdownSetup{contentType=inline}
\markdownSetup{contentLevel=inline}
<<<
This test ensures that the Lua `contentType` option correctly propagates
through the plain TeX interface. Setting the `contentType` option to the
Expand Down

0 comments on commit ca98e03

Please sign in to comment.