@podlite/schema 0.0.75 → 0.0.76

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.
Files changed (102) hide show
  1. package/CHANGELOG.podlite +44 -0
  2. package/esm/ast-helpers.d.ts +2 -1
  3. package/esm/ast-helpers.js +19 -2
  4. package/esm/ast-helpers.js.map +1 -1
  5. package/esm/codes/place.d.ts +13 -0
  6. package/esm/codes/place.js +105 -0
  7. package/esm/codes/place.js.map +1 -0
  8. package/esm/codes/read.d.ts +21 -0
  9. package/esm/codes/read.js +365 -0
  10. package/esm/codes/read.js.map +1 -0
  11. package/esm/codes/scan.d.ts +41 -0
  12. package/esm/codes/scan.js +332 -0
  13. package/esm/codes/scan.js.map +1 -0
  14. package/esm/exportHtml.js +44 -13
  15. package/esm/exportHtml.js.map +1 -1
  16. package/esm/exportMarkdown.js +32 -9
  17. package/esm/exportMarkdown.js.map +1 -1
  18. package/esm/guard.d.ts +9 -0
  19. package/esm/guard.js +100 -0
  20. package/esm/guard.js.map +1 -1
  21. package/esm/helpers/blockName.d.ts +1 -0
  22. package/esm/helpers/blockName.js +28 -2
  23. package/esm/helpers/blockName.js.map +1 -1
  24. package/esm/helpers/configPropagation.js +3 -1
  25. package/esm/helpers/configPropagation.js.map +1 -1
  26. package/esm/helpers/handlers.d.ts +3 -0
  27. package/esm/helpers/handlers.js +23 -0
  28. package/esm/helpers/handlers.js.map +1 -1
  29. package/esm/helpers/headingKeys.d.ts +2 -0
  30. package/esm/helpers/headingKeys.js +45 -0
  31. package/esm/helpers/headingKeys.js.map +1 -0
  32. package/esm/helpers/ids.js +1 -1
  33. package/esm/helpers/ids.js.map +1 -1
  34. package/esm/helpers/numberedShorthand.d.ts +1 -0
  35. package/esm/helpers/numberedShorthand.js +32 -0
  36. package/esm/helpers/numberedShorthand.js.map +1 -0
  37. package/esm/helpers/stripMarker.d.ts +1 -0
  38. package/esm/helpers/stripMarker.js +24 -0
  39. package/esm/helpers/stripMarker.js.map +1 -0
  40. package/esm/index.d.ts +5 -4
  41. package/esm/index.js +6 -5
  42. package/esm/index.js.map +1 -1
  43. package/esm/pluggableParser.js +35 -4
  44. package/esm/pluggableParser.js.map +1 -1
  45. package/esm/plugin-formatting-codes.js +44 -12
  46. package/esm/plugin-formatting-codes.js.map +1 -1
  47. package/esm/plugin-heading.js +3 -11
  48. package/esm/plugin-heading.js.map +1 -1
  49. package/esm/plugin-items.js +3 -32
  50. package/esm/plugin-items.js.map +1 -1
  51. package/esm/plugin-vmargin.js +16 -3
  52. package/esm/plugin-vmargin.js.map +1 -1
  53. package/esm/selectors.d.ts +3 -2
  54. package/esm/selectors.js +35 -4
  55. package/esm/selectors.js.map +1 -1
  56. package/esm/types.d.ts +30 -6
  57. package/esm/version.d.ts +1 -1
  58. package/esm/version.js +1 -1
  59. package/lib/ast-helpers.d.ts +2 -1
  60. package/lib/ast-helpers.js +19 -2
  61. package/lib/codes/place.d.ts +13 -0
  62. package/lib/codes/place.js +111 -0
  63. package/lib/codes/read.d.ts +21 -0
  64. package/lib/codes/read.js +369 -0
  65. package/lib/codes/scan.d.ts +41 -0
  66. package/lib/codes/scan.js +336 -0
  67. package/lib/exportHtml.js +43 -12
  68. package/lib/exportMarkdown.js +31 -8
  69. package/lib/guard.d.ts +9 -0
  70. package/lib/guard.js +104 -1
  71. package/lib/helpers/blockName.d.ts +1 -0
  72. package/lib/helpers/blockName.js +30 -3
  73. package/lib/helpers/configPropagation.js +3 -1
  74. package/lib/helpers/handlers.d.ts +3 -0
  75. package/lib/helpers/handlers.js +25 -1
  76. package/lib/helpers/headingKeys.d.ts +2 -0
  77. package/lib/helpers/headingKeys.js +50 -0
  78. package/lib/helpers/ids.js +1 -1
  79. package/lib/helpers/numberedShorthand.d.ts +1 -0
  80. package/lib/helpers/numberedShorthand.js +36 -0
  81. package/lib/helpers/stripMarker.d.ts +1 -0
  82. package/lib/helpers/stripMarker.js +28 -0
  83. package/lib/index.d.ts +5 -4
  84. package/lib/index.js +13 -3
  85. package/lib/pluggableParser.js +35 -4
  86. package/lib/plugin-formatting-codes.js +44 -45
  87. package/lib/plugin-heading.js +3 -11
  88. package/lib/plugin-items.js +4 -33
  89. package/lib/plugin-vmargin.js +16 -3
  90. package/lib/selectors.d.ts +3 -2
  91. package/lib/selectors.js +37 -5
  92. package/lib/types.d.ts +30 -6
  93. package/lib/version.d.ts +1 -1
  94. package/lib/version.js +1 -1
  95. package/package.json +2 -2
  96. package/schema/AstTree.json +174 -27
  97. package/schema/PodliteDocument.json +174 -27
  98. package/esm/grammarfc.d.ts +0 -14
  99. package/esm/grammarfc.js +0 -9824
  100. package/esm/grammarfc.js.map +0 -1
  101. package/lib/grammarfc.d.ts +0 -14
  102. package/lib/grammarfc.js +0 -9824
@@ -147,6 +147,15 @@
147
147
  {
148
148
  "$ref": "#/definitions/FormattingCodeS"
149
149
  },
150
+ {
151
+ "$ref": "#/definitions/FormattingCodeM"
152
+ },
153
+ {
154
+ "$ref": "#/definitions/FormattingCodeP"
155
+ },
156
+ {
157
+ "$ref": "#/definitions/FormattingCodeReserved"
158
+ },
150
159
  {
151
160
  "$ref": "#/definitions/FormattingCodeAny"
152
161
  },
@@ -952,6 +961,9 @@
952
961
  "number"
953
962
  ]
954
963
  },
964
+ "headingKey": {
965
+ "type": "string"
966
+ },
955
967
  "type": {
956
968
  "type": "string",
957
969
  "const": "block"
@@ -1287,6 +1299,15 @@
1287
1299
  {
1288
1300
  "$ref": "#/definitions/FormattingCodeS"
1289
1301
  },
1302
+ {
1303
+ "$ref": "#/definitions/FormattingCodeM"
1304
+ },
1305
+ {
1306
+ "$ref": "#/definitions/FormattingCodeP"
1307
+ },
1308
+ {
1309
+ "$ref": "#/definitions/FormattingCodeReserved"
1310
+ },
1290
1311
  {
1291
1312
  "$ref": "#/definitions/FormattingCodeAny"
1292
1313
  },
@@ -1470,6 +1491,15 @@
1470
1491
  {
1471
1492
  "$ref": "#/definitions/FormattingCodeS"
1472
1493
  },
1494
+ {
1495
+ "$ref": "#/definitions/FormattingCodeM"
1496
+ },
1497
+ {
1498
+ "$ref": "#/definitions/FormattingCodeP"
1499
+ },
1500
+ {
1501
+ "$ref": "#/definitions/FormattingCodeReserved"
1502
+ },
1473
1503
  {
1474
1504
  "$ref": "#/definitions/FormattingCodeAny"
1475
1505
  },
@@ -1645,6 +1675,15 @@
1645
1675
  {
1646
1676
  "$ref": "#/definitions/FormattingCodeS"
1647
1677
  },
1678
+ {
1679
+ "$ref": "#/definitions/FormattingCodeM"
1680
+ },
1681
+ {
1682
+ "$ref": "#/definitions/FormattingCodeP"
1683
+ },
1684
+ {
1685
+ "$ref": "#/definitions/FormattingCodeReserved"
1686
+ },
1648
1687
  {
1649
1688
  "$ref": "#/definitions/FormattingCodeAny"
1650
1689
  },
@@ -1861,6 +1900,13 @@
1861
1900
  "code": {
1862
1901
  "enum": [
1863
1902
  "directive-unreadable",
1903
+ "markup-code-entity-in-code",
1904
+ "markup-code-foreign-closer",
1905
+ "markup-code-longer-run",
1906
+ "markup-code-reserved",
1907
+ "markup-code-unclosed",
1908
+ "markup-code-unreadable",
1909
+ "markup-code-unsupported",
1864
1910
  "table-cell-outside-row",
1865
1911
  "table-mixed-separators",
1866
1912
  "table-row-cells",
@@ -2776,6 +2822,9 @@
2776
2822
  "$ref": "#/definitions/ConfigItem"
2777
2823
  }
2778
2824
  },
2825
+ "headingRef": {
2826
+ "type": "string"
2827
+ },
2779
2828
  "content": {
2780
2829
  "anyOf": [
2781
2830
  {
@@ -2783,13 +2832,9 @@
2783
2832
  },
2784
2833
  {
2785
2834
  "type": "array",
2786
- "items": [
2787
- {
2788
- "$ref": "#/definitions/Text"
2789
- }
2790
- ],
2791
- "minItems": 1,
2792
- "maxItems": 1
2835
+ "items": {
2836
+ "$ref": "#/definitions/Text"
2837
+ }
2793
2838
  },
2794
2839
  {
2795
2840
  "type": "string"
@@ -2913,14 +2958,10 @@
2913
2958
  "const": "Z"
2914
2959
  },
2915
2960
  "content": {
2916
- "anyOf": [
2917
- {
2918
- "$ref": "#/definitions/Text"
2919
- },
2920
- {
2921
- "type": "string"
2922
- }
2923
- ]
2961
+ "type": "array",
2962
+ "items": {
2963
+ "$ref": "#/definitions/PodNode"
2964
+ }
2924
2965
  }
2925
2966
  },
2926
2967
  "required": [
@@ -2940,14 +2981,10 @@
2940
2981
  "const": "V"
2941
2982
  },
2942
2983
  "content": {
2943
- "anyOf": [
2944
- {
2945
- "$ref": "#/definitions/Text"
2946
- },
2947
- {
2948
- "type": "string"
2949
- }
2950
- ]
2984
+ "type": "array",
2985
+ "items": {
2986
+ "$ref": "#/definitions/PodNode"
2987
+ }
2951
2988
  }
2952
2989
  },
2953
2990
  "required": [
@@ -2967,19 +3004,129 @@
2967
3004
  "const": "S"
2968
3005
  },
2969
3006
  "content": {
2970
- "anyOf": [
3007
+ "type": "array",
3008
+ "items": {
3009
+ "$ref": "#/definitions/PodNode"
3010
+ }
3011
+ }
3012
+ },
3013
+ "required": [
3014
+ "name",
3015
+ "type"
3016
+ ]
3017
+ },
3018
+ "FormattingCodeM": {
3019
+ "type": "object",
3020
+ "properties": {
3021
+ "type": {
3022
+ "type": "string",
3023
+ "const": "fcode"
3024
+ },
3025
+ "name": {
3026
+ "type": "string",
3027
+ "const": "M"
3028
+ },
3029
+ "module": {
3030
+ "type": [
3031
+ "null",
3032
+ "string"
3033
+ ]
3034
+ },
3035
+ "config": {},
3036
+ "content": {
3037
+ "type": "array",
3038
+ "items": {
3039
+ "$ref": "#/definitions/PodNode"
3040
+ }
3041
+ }
3042
+ },
3043
+ "required": [
3044
+ "config",
3045
+ "content",
3046
+ "module",
3047
+ "name",
3048
+ "type"
3049
+ ]
3050
+ },
3051
+ "FormattingCodeP": {
3052
+ "type": "object",
3053
+ "properties": {
3054
+ "type": {
3055
+ "type": "string",
3056
+ "const": "fcode"
3057
+ },
3058
+ "name": {
3059
+ "type": "string",
3060
+ "const": "P"
3061
+ },
3062
+ "content": {
3063
+ "type": "array",
3064
+ "items": {
3065
+ "type": "object",
3066
+ "properties": {
3067
+ "type": {
3068
+ "type": "string",
3069
+ "const": "image"
3070
+ },
3071
+ "src": {
3072
+ "type": "string"
3073
+ },
3074
+ "alt": {
3075
+ "type": "string"
3076
+ }
3077
+ },
3078
+ "required": [
3079
+ "src",
3080
+ "type"
3081
+ ]
3082
+ }
3083
+ }
3084
+ },
3085
+ "required": [
3086
+ "content",
3087
+ "name",
3088
+ "type"
3089
+ ]
3090
+ },
3091
+ "FormattingCodeReserved": {
3092
+ "type": "object",
3093
+ "properties": {
3094
+ "type": {
3095
+ "type": "string",
3096
+ "const": "fcode"
3097
+ },
3098
+ "name": {
3099
+ "enum": [
3100
+ "Q",
3101
+ "Y"
3102
+ ],
3103
+ "type": "string"
3104
+ },
3105
+ "written": {
3106
+ "type": "array",
3107
+ "items": [
2971
3108
  {
2972
- "$ref": "#/definitions/Text"
3109
+ "type": "string"
2973
3110
  },
2974
3111
  {
2975
3112
  "type": "string"
2976
3113
  }
2977
- ]
3114
+ ],
3115
+ "minItems": 2,
3116
+ "maxItems": 2
3117
+ },
3118
+ "content": {
3119
+ "type": "array",
3120
+ "items": {
3121
+ "$ref": "#/definitions/PodNode"
3122
+ }
2978
3123
  }
2979
3124
  },
2980
3125
  "required": [
3126
+ "content",
2981
3127
  "name",
2982
- "type"
3128
+ "type",
3129
+ "written"
2983
3130
  ]
2984
3131
  },
2985
3132
  "FormattingCodeAny": {
@@ -1,14 +0,0 @@
1
- declare function peg$SyntaxError(message: any, expected: any, found: any, location: any): void;
2
- declare class peg$SyntaxError {
3
- constructor(message: any, expected: any, found: any, location: any);
4
- message: any;
5
- expected: any;
6
- found: any;
7
- location: any;
8
- name: string;
9
- }
10
- declare namespace peg$SyntaxError {
11
- function buildMessage(expected: any, found: any): string;
12
- }
13
- declare function peg$parse(input: any, options: any): any[];
14
- export { peg$SyntaxError as SyntaxError, peg$parse as parse };