flinker-markdown 1.1.19 → 1.1.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/md.js +7 -3
- package/dist/types/md.d.ts +1 -0
- package/package.json +1 -1
package/dist/esm/md.js
CHANGED
|
@@ -83,6 +83,10 @@ export class MDGrammar {
|
|
|
83
83
|
this.quote.matcher = [/^> (.*)$/, '<blockquote><p>$1</p></blockquote>'];
|
|
84
84
|
this.quote.childrenInlineRules = this.globalRule.childrenInlineRules;
|
|
85
85
|
this.quote.preProccessing = defLinePreproccessing;
|
|
86
|
+
this.quoteFooter = new MDLineGrammarRule();
|
|
87
|
+
this.quoteFooter.matcher = [/^>> (.*)$/, '<footer>$1</footer>'];
|
|
88
|
+
this.quoteFooter.childrenInlineRules = this.globalRule.childrenInlineRules;
|
|
89
|
+
this.quoteFooter.preProccessing = defLinePreproccessing;
|
|
86
90
|
this.tilde = new MDLineGrammarRule();
|
|
87
91
|
this.tilde.matcher = [/^~ (.*)$/, '<p><strong>$1</strong></p>'];
|
|
88
92
|
this.tilde.childrenInlineRules = this.globalRule.childrenInlineRules;
|
|
@@ -124,7 +128,7 @@ export class MDGrammar {
|
|
|
124
128
|
this.p.matcher = [/^(.*)$/, '<p>$1</p>'];
|
|
125
129
|
this.p.childrenInlineRules = this.globalRule.childrenInlineRules;
|
|
126
130
|
this.p.preProccessing = defLinePreproccessing;
|
|
127
|
-
this.globalRule.childrenLineRules = [this.header, this.quote, this.alignCenter, this.alignRight, this.tilde, this.audio, this.video, this.horRule, this.stars, this.br, this.p];
|
|
131
|
+
this.globalRule.childrenLineRules = [this.header, this.quote, this.quoteFooter, this.alignCenter, this.alignRight, this.tilde, this.audio, this.video, this.horRule, this.stars, this.br, this.p];
|
|
128
132
|
//
|
|
129
133
|
// MULTILINE GRAMMAR RULES
|
|
130
134
|
//
|
|
@@ -154,8 +158,8 @@ export class MDGrammar {
|
|
|
154
158
|
this.div.startMatcher = [/^```([a-zA-Z]+) */, '<div class="$1"><div>'];
|
|
155
159
|
this.div.endMatcher = [/^``` *$/, '</div></div>'];
|
|
156
160
|
this.div.childrenInlineRules = this.globalRule.childrenInlineRules;
|
|
157
|
-
this.div.childrenLineRules = [this.quote, this.alignCenter, this.alignRight, this.tilde, this.horRule, this.br, this.p];
|
|
158
|
-
this.div.childrenMultilineRules = [this.
|
|
161
|
+
this.div.childrenLineRules = [this.quote, this.quoteFooter, this.alignCenter, this.alignRight, this.tilde, this.horRule, this.br, this.p];
|
|
162
|
+
this.div.childrenMultilineRules = [this.ol, this.ul, this.table, this.div];
|
|
159
163
|
this.globalRule.childrenMultilineRules = [this.ol, this.ul, this.table, this.div];
|
|
160
164
|
}
|
|
161
165
|
}
|
package/dist/types/md.d.ts
CHANGED
|
@@ -38,6 +38,7 @@ export declare class MDGrammar {
|
|
|
38
38
|
readonly link: MDInlineGrammarRule;
|
|
39
39
|
readonly header: MDLineGrammarRule;
|
|
40
40
|
readonly quote: MDLineGrammarRule;
|
|
41
|
+
readonly quoteFooter: MDLineGrammarRule;
|
|
41
42
|
readonly alignRight: MDLineGrammarRule;
|
|
42
43
|
readonly tilde: MDLineGrammarRule;
|
|
43
44
|
readonly alignCenter: MDLineGrammarRule;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flinker-markdown",
|
|
3
3
|
"description": "Free TypeScript library for parsing markdown text (customisable, not standardized).",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.21",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "git+https://github.com/Dittner/FlinkerMD.git"
|