@peaceroad/markdown-imgattr-to-pcaption
v0.1.0
Published
Change img alt attribute to figure caption paragraph for p7d-markdown-it-p-captions.
Readme
markdown-imgattr-to-pcaption
Change img alt attribute to figure caption paragraph for p7d-markdown-it-p-captions.
import setMarkdownImgAttrToPCaption from '@peaceroad/markdown-imgattr-to-pcaption'
setMarkdownImgAttrToPCaption(markdownCont)[Input]
段落。段落。段落。

段落。段落。段落。
[Output]
段落。段落。段落。
図 キャプション

段落。段落。段落。
[Input]
段落。段落。段落。

段落。段落。段落。
[Output]
段落。段落。段落。
図 キャプション

段落。段落。段落。
[Input]
段落。段落。段落。

段落。段落。段落。
[Output]
段落。段落。段落。
図1 キャプション

段落。段落。段落。Option
imgTitleCaption: true
[Input]
段落。段落。段落。

段落。段落。段落。
[Output]
段落。段落。段落。
図 キャプション

段落。段落。段落。labelLang: 'en'
[Input]
段落。段落。段落。

段落。段落。段落。
[Output]
段落。段落。段落。
Figure. キャプション

段落。段落。段落。