@jxsuite/parser 0.26.2 → 0.28.0

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.
@@ -1,94 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://jxsuite.com/schemas/MarkdownFile.class.json",
4
- "title": "MarkdownFile",
5
- "description": "Load and parse a single Markdown file",
6
- "$prototype": "Class",
7
- "extends": "Object",
8
- "$implementation": "./md.js",
9
-
10
- "$defs": {
11
- "parameters": {
12
- "src": {
13
- "identifier": "src",
14
- "type": { "type": "string" },
15
- "description": "Path to markdown file",
16
- "examples": ["./content/about.md"]
17
- },
18
- "directives": {
19
- "identifier": "directives",
20
- "type": { "type": "boolean", "default": false },
21
- "description": "Enable remark-directive plugin"
22
- },
23
- "basePath": {
24
- "identifier": "basePath",
25
- "type": { "type": "string" },
26
- "description": "Base path for resolving src"
27
- }
28
- },
29
-
30
- "returnTypes": {
31
- "MarkdownFileResult": {
32
- "type": "object",
33
- "description": "Parsed markdown file result",
34
- "properties": {
35
- "slug": { "type": "string", "description": "Filename without extension" },
36
- "path": { "type": "string", "description": "Absolute file path" },
37
- "frontmatter": { "type": "object", "description": "YAML frontmatter key-value pairs" },
38
- "$children": { "type": "array", "description": "JX node tree" },
39
- "$excerpt": { "type": "string", "description": "First paragraph as plain text" },
40
- "$toc": {
41
- "type": "array",
42
- "description": "Table of contents entries",
43
- "items": {
44
- "type": "object",
45
- "properties": {
46
- "depth": { "type": "integer" },
47
- "text": { "type": "string" },
48
- "id": { "type": "string" }
49
- }
50
- }
51
- },
52
- "$readingTime": { "type": "integer", "description": "Estimated reading time in minutes" },
53
- "$wordCount": { "type": "integer", "description": "Total word count" }
54
- }
55
- }
56
- },
57
-
58
- "fields": {
59
- "config": {
60
- "role": "field",
61
- "access": "private",
62
- "scope": "instance",
63
- "identifier": "config",
64
- "type": { "type": "object" },
65
- "description": "Raw configuration object passed to the constructor"
66
- }
67
- },
68
-
69
- "constructor": {
70
- "role": "constructor",
71
- "$prototype": "Function",
72
- "parameters": [
73
- { "$ref": "#/$defs/parameters/src" },
74
- { "$ref": "#/$defs/parameters/directives" },
75
- { "$ref": "#/$defs/parameters/basePath" }
76
- ],
77
- "body": ["this.config = config;"],
78
- "description": "Stores the configuration for deferred resolution"
79
- },
80
-
81
- "methods": {
82
- "resolve": {
83
- "role": "method",
84
- "$prototype": "Function",
85
- "access": "public",
86
- "scope": "instance",
87
- "identifier": "resolve",
88
- "parameters": [],
89
- "returnType": { "$ref": "#/$defs/returnTypes/MarkdownFileResult" },
90
- "description": "Parse and resolve the markdown file into a MarkdownFileResult"
91
- }
92
- }
93
- }
94
- }