@incremark/core 0.3.1 → 0.3.2
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/{MarkedAstBuildter-DDP1An5M.d.ts → MarkedAstBuildter-B2QhLKKy.d.ts} +2 -2
- package/dist/engines/marked/index.d.ts +4 -4
- package/dist/engines/marked/index.js +1 -1
- package/dist/engines/marked/index.js.map +1 -1
- package/dist/engines/micromark/index.d.ts +4 -4
- package/dist/engines/micromark/index.js +2 -2
- package/dist/engines/micromark/index.js.map +1 -1
- package/dist/index.d.ts +33 -6
- package/dist/index.js +151 -16
- package/dist/index.js.map +1 -1
- package/dist/{types-N1b99kYB.d.ts → types-B7GTGJc2.d.ts} +2 -1
- package/dist/utils/index.d.ts +8 -1
- package/dist/utils/index.js +15 -1
- package/dist/utils/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Root, RootContent } from 'mdast';
|
|
2
2
|
import { C as ContainerConfig, H as HtmlTreeExtensionOptions, B as BlockStatus, P as ParsedBlock } from './index-CWuosVAK.js';
|
|
3
|
-
import { I as IAstBuilder, E as EngineParserOptions } from './types-
|
|
3
|
+
import { I as IAstBuilder, E as EngineParserOptions } from './types-B7GTGJc2.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Marked AST 构建器(极速模式)
|
|
@@ -62,7 +62,7 @@ declare class MarkedAstBuilder implements IAstBuilder {
|
|
|
62
62
|
/**
|
|
63
63
|
* 将 AST 节点转换为 ParsedBlock
|
|
64
64
|
*/
|
|
65
|
-
nodesToBlocks(nodes: RootContent[], startOffset: number, rawText: string, status: BlockStatus, generateBlockId: () => string): ParsedBlock[];
|
|
65
|
+
nodesToBlocks(nodes: RootContent[], startOffset: number, rawText: string, status: BlockStatus, generateBlockId: (startOffset: number) => string): ParsedBlock[];
|
|
66
66
|
/**
|
|
67
67
|
* 更新配置选项
|
|
68
68
|
* @param options 部分配置选项
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { M as MarkedAstBuilder } from '../../MarkedAstBuildter-
|
|
2
|
-
export { A as AstBuilder } from '../../MarkedAstBuildter-
|
|
3
|
-
import { E as EngineParserOptions } from '../../types-
|
|
4
|
-
export { I as IAstBuilder, b as IncremarkPlugin, M as MarkedEngineExtension } from '../../types-
|
|
1
|
+
import { M as MarkedAstBuilder } from '../../MarkedAstBuildter-B2QhLKKy.js';
|
|
2
|
+
export { A as AstBuilder } from '../../MarkedAstBuildter-B2QhLKKy.js';
|
|
3
|
+
import { E as EngineParserOptions } from '../../types-B7GTGJc2.js';
|
|
4
|
+
export { I as IAstBuilder, b as IncremarkPlugin, M as MarkedEngineExtension } from '../../types-B7GTGJc2.js';
|
|
5
5
|
import 'mdast';
|
|
6
6
|
import '../../index-CWuosVAK.js';
|
|
7
7
|
import 'micromark-util-types';
|
|
@@ -1563,7 +1563,7 @@ var MarkedAstBuilder = class {
|
|
|
1563
1563
|
const absoluteStart = startOffset + relativeStart;
|
|
1564
1564
|
const absoluteEnd = startOffset + relativeEnd;
|
|
1565
1565
|
blocks.push({
|
|
1566
|
-
id: generateBlockId(),
|
|
1566
|
+
id: generateBlockId(absoluteStart),
|
|
1567
1567
|
status,
|
|
1568
1568
|
node,
|
|
1569
1569
|
startOffset: absoluteStart,
|