ecmarkdown
Advanced tools
Comparing version 5.1.1 to 5.1.2
@@ -93,3 +93,3 @@ "use strict"; | ||
let name = kind === 'ol' ? 'ordered-list-item' : 'unordered-list-item'; | ||
return this.finish({ name, contents, sublist, id }); | ||
return this.finish({ name, contents, sublist, id: id == null ? null : id.value }); | ||
} | ||
@@ -96,0 +96,0 @@ parseFragment(opts, closingFormatKind) { |
@@ -1,2 +0,2 @@ | ||
import type { Token, Position } from './node-types'; | ||
import type { Token, IdToken, Position } from './node-types'; | ||
import type { Options } from './ecmarkdown'; | ||
@@ -23,3 +23,3 @@ export declare class Tokenizer { | ||
tryScanComment(): string | undefined; | ||
tryScanId(): string | null; | ||
tryScanId(): IdToken | null; | ||
matchToken(): void; | ||
@@ -32,3 +32,3 @@ getLocation(): Position; | ||
next(): Token; | ||
locate(tok: Token, startPos: Position): void; | ||
locate(tok: Token | IdToken, startPos: Position): void; | ||
} |
@@ -148,4 +148,7 @@ "use strict"; | ||
} | ||
const start = this.getLocation(); | ||
this.pos += match[0].length; | ||
return match[1]; | ||
let token = { name: 'id', value: match[1] }; | ||
this.locate(token, start); | ||
return token; | ||
} | ||
@@ -152,0 +155,0 @@ // Attempts to match any of the tokens at the given index of str |
{ | ||
"name": "ecmarkdown", | ||
"version": "5.1.1", | ||
"version": "5.1.2", | ||
"description": "A compiler for \"Ecmarkdown\" algorithm shorthand into HTML.", | ||
@@ -5,0 +5,0 @@ "main": "dist/ecmarkdown.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
50348
1196