@diplodoc/yfmlint 1.3.3 → 1.3.5

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/build/index.js CHANGED
@@ -387,8 +387,7 @@ var require_patterns = __commonJS({
387
387
  */
388
388
  transform: (tokens, i) => {
389
389
  let idx = i - 2;
390
- while (idx > 0 && "tbody_open" !== tokens[--idx].type)
391
- ;
390
+ while (idx > 0 && "tbody_open" !== tokens[--idx].type) ;
392
391
  const calc = tokens[idx].meta.colsnum >> 0;
393
392
  if (calc < 2) {
394
393
  return;
@@ -840,6 +839,7 @@ var require_markdown_it_attrs = __commonJS({
840
839
  }
841
840
  break;
842
841
  }
842
+ // fall through for objects !== arrays of functions
843
843
  default:
844
844
  throw new Error(`Unknown type of pattern test (key: ${key}). Test should be of type boolean, number, string, function or array of functions.`);
845
845
  }
@@ -1187,10 +1187,10 @@ var require_isMasked = __commonJS({
1187
1187
  "node_modules/lodash/_isMasked.js"(exports2, module2) {
1188
1188
  "use strict";
1189
1189
  var coreJsData = require_coreJsData();
1190
- var maskSrcKey = function() {
1190
+ var maskSrcKey = (function() {
1191
1191
  var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
1192
1192
  return uid ? "Symbol(src)_1." + uid : "";
1193
- }();
1193
+ })();
1194
1194
  function isMasked(func) {
1195
1195
  return !!maskSrcKey && maskSrcKey in func;
1196
1196
  }
@@ -1576,14 +1576,14 @@ var require_defineProperty = __commonJS({
1576
1576
  "node_modules/lodash/_defineProperty.js"(exports2, module2) {
1577
1577
  "use strict";
1578
1578
  var getNative = require_getNative();
1579
- var defineProperty = function() {
1579
+ var defineProperty = (function() {
1580
1580
  try {
1581
1581
  var func = getNative(Object, "defineProperty");
1582
1582
  func({}, "", {});
1583
1583
  return func;
1584
1584
  } catch (e) {
1585
1585
  }
1586
- }();
1586
+ })();
1587
1587
  module2.exports = defineProperty;
1588
1588
  }
1589
1589
  });
@@ -1735,7 +1735,7 @@ var require_baseCreate = __commonJS({
1735
1735
  "use strict";
1736
1736
  var isObject2 = require_isObject();
1737
1737
  var objectCreate = Object.create;
1738
- var baseCreate = /* @__PURE__ */ function() {
1738
+ var baseCreate = /* @__PURE__ */ (function() {
1739
1739
  function object() {
1740
1740
  }
1741
1741
  return function(proto) {
@@ -1750,7 +1750,7 @@ var require_baseCreate = __commonJS({
1750
1750
  object.prototype = void 0;
1751
1751
  return result;
1752
1752
  };
1753
- }();
1753
+ })();
1754
1754
  module2.exports = baseCreate;
1755
1755
  }
1756
1756
  });
@@ -1839,9 +1839,9 @@ var require_isArguments = __commonJS({
1839
1839
  var objectProto = Object.prototype;
1840
1840
  var hasOwnProperty2 = objectProto.hasOwnProperty;
1841
1841
  var propertyIsEnumerable = objectProto.propertyIsEnumerable;
1842
- var isArguments = baseIsArguments(/* @__PURE__ */ function() {
1842
+ var isArguments = baseIsArguments(/* @__PURE__ */ (function() {
1843
1843
  return arguments;
1844
- }()) ? baseIsArguments : function(value) {
1844
+ })()) ? baseIsArguments : function(value) {
1845
1845
  return isObjectLike(value) && hasOwnProperty2.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
1846
1846
  };
1847
1847
  module2.exports = isArguments;
@@ -2013,7 +2013,7 @@ var require_nodeUtil = __commonJS({
2013
2013
  var freeModule = freeExports && typeof module2 == "object" && module2 && !module2.nodeType && module2;
2014
2014
  var moduleExports = freeModule && freeModule.exports === freeExports;
2015
2015
  var freeProcess = moduleExports && freeGlobal.process;
2016
- var nodeUtil = function() {
2016
+ var nodeUtil = (function() {
2017
2017
  try {
2018
2018
  var types = freeModule && freeModule.require && freeModule.require("util").types;
2019
2019
  if (types) {
@@ -2022,7 +2022,7 @@ var require_nodeUtil = __commonJS({
2022
2022
  return freeProcess && freeProcess.binding && freeProcess.binding("util");
2023
2023
  } catch (e) {
2024
2024
  }
2025
- }();
2025
+ })();
2026
2026
  module2.exports = nodeUtil;
2027
2027
  }
2028
2028
  });
@@ -2538,9 +2538,9 @@ var import_node_fs, import_node_os, import_node_path, fs, os, path;
2538
2538
  var init_node_imports_node = __esm({
2539
2539
  "node_modules/markdownlint/lib/node-imports-node.mjs"() {
2540
2540
  "use strict";
2541
- import_node_fs = require("fs");
2542
- import_node_os = require("os");
2543
- import_node_path = require("path");
2541
+ import_node_fs = require("node:fs");
2542
+ import_node_os = require("node:os");
2543
+ import_node_path = require("node:path");
2544
2544
  fs = { access: import_node_fs.access, accessSync: import_node_fs.accessSync, readFile: import_node_fs.readFile, readFileSync: import_node_fs.readFileSync };
2545
2545
  os = { EOL: import_node_os.EOL, homedir: import_node_os.homedir };
2546
2546
  path = { dirname: import_node_path.dirname, resolve: import_node_path.resolve };
@@ -2551,8 +2551,8 @@ var init_node_imports_node = __esm({
2551
2551
  var require_shared = __commonJS({
2552
2552
  "node_modules/markdownlint/helpers/shared.cjs"(exports2, module2) {
2553
2553
  "use strict";
2554
- module2.exports.flatTokensSymbol = Symbol("flat-tokens");
2555
- module2.exports.htmlFlowSymbol = Symbol("html-flow");
2554
+ module2.exports.flatTokensSymbol = /* @__PURE__ */ Symbol("flat-tokens");
2555
+ module2.exports.htmlFlowSymbol = /* @__PURE__ */ Symbol("html-flow");
2556
2556
  module2.exports.newLineRe = /\r\n?|\n/g;
2557
2557
  module2.exports.nextLinesRe = /[\r\n][\s\S]*$/;
2558
2558
  }
@@ -3041,14 +3041,14 @@ function filterByTypesCached(types, htmlFlow2) {
3041
3041
  function getReferenceLinkImageData() {
3042
3042
  return getCached(
3043
3043
  getReferenceLinkImageData.name,
3044
- () => (0, import_helpers.getReferenceLinkImageData)(params.parsers.micromark.tokens)
3044
+ () => (0, import_helpers8.getReferenceLinkImageData)(params.parsers.micromark.tokens)
3045
3045
  );
3046
3046
  }
3047
- var import_helpers, import_micromark_helpers, map, params;
3047
+ var import_helpers8, import_micromark_helpers, map, params;
3048
3048
  var init_cache = __esm({
3049
3049
  "node_modules/markdownlint/lib/cache.mjs"() {
3050
3050
  "use strict";
3051
- import_helpers = __toESM(require_helpers(), 1);
3051
+ import_helpers8 = __toESM(require_helpers(), 1);
3052
3052
  import_micromark_helpers = __toESM(require_micromark_helpers(), 1);
3053
3053
  map = /* @__PURE__ */ new Map();
3054
3054
  params = void 0;
@@ -3065,9 +3065,9 @@ var init_constants = __esm({
3065
3065
  }
3066
3066
  });
3067
3067
 
3068
- // node_modules/mdurl/build/index.cjs.js
3068
+ // node_modules/markdownlint/node_modules/mdurl/build/index.cjs.js
3069
3069
  var require_index_cjs = __commonJS({
3070
- "node_modules/mdurl/build/index.cjs.js"(exports2) {
3070
+ "node_modules/markdownlint/node_modules/mdurl/build/index.cjs.js"(exports2) {
3071
3071
  "use strict";
3072
3072
  var decodeCache = {};
3073
3073
  function getDecodeCache(exclude) {
@@ -3264,8 +3264,7 @@ var require_index_cjs = __commonJS({
3264
3264
  "file:": true
3265
3265
  };
3266
3266
  function urlParse(url, slashesDenoteHost) {
3267
- if (url && url instanceof Url)
3268
- return url;
3267
+ if (url && url instanceof Url) return url;
3269
3268
  const u = new Url();
3270
3269
  u.parse(url, slashesDenoteHost);
3271
3270
  return u;
@@ -3413,9 +3412,9 @@ var require_index_cjs = __commonJS({
3413
3412
  }
3414
3413
  });
3415
3414
 
3416
- // node_modules/uc.micro/build/index.cjs.js
3415
+ // node_modules/markdownlint/node_modules/uc.micro/build/index.cjs.js
3417
3416
  var require_index_cjs2 = __commonJS({
3418
- "node_modules/uc.micro/build/index.cjs.js"(exports2) {
3417
+ "node_modules/markdownlint/node_modules/uc.micro/build/index.cjs.js"(exports2) {
3419
3418
  "use strict";
3420
3419
  var regex$5 = /[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;
3421
3420
  var regex$4 = /[\0-\x1F\x7F-\x9F]/;
@@ -3528,9 +3527,8 @@ var require_decode_codepoint = __commonJS({
3528
3527
  var require_decode = __commonJS({
3529
3528
  "node_modules/entities/lib/decode.js"(exports2) {
3530
3529
  "use strict";
3531
- var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
3532
- if (k2 === void 0)
3533
- k2 = k;
3530
+ var __createBinding = exports2 && exports2.__createBinding || (Object.create ? (function(o, m, k, k2) {
3531
+ if (k2 === void 0) k2 = k;
3534
3532
  var desc = Object.getOwnPropertyDescriptor(m, k);
3535
3533
  if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
3536
3534
  desc = { enumerable: true, get: function() {
@@ -3538,24 +3536,20 @@ var require_decode = __commonJS({
3538
3536
  } };
3539
3537
  }
3540
3538
  Object.defineProperty(o, k2, desc);
3541
- } : function(o, m, k, k2) {
3542
- if (k2 === void 0)
3543
- k2 = k;
3539
+ }) : (function(o, m, k, k2) {
3540
+ if (k2 === void 0) k2 = k;
3544
3541
  o[k2] = m[k];
3545
- });
3546
- var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
3542
+ }));
3543
+ var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? (function(o, v) {
3547
3544
  Object.defineProperty(o, "default", { enumerable: true, value: v });
3548
- } : function(o, v) {
3545
+ }) : function(o, v) {
3549
3546
  o["default"] = v;
3550
3547
  });
3551
3548
  var __importStar = exports2 && exports2.__importStar || function(mod) {
3552
- if (mod && mod.__esModule)
3553
- return mod;
3549
+ if (mod && mod.__esModule) return mod;
3554
3550
  var result = {};
3555
3551
  if (mod != null) {
3556
- for (var k in mod)
3557
- if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
3558
- __createBinding(result, mod, k);
3552
+ for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
3559
3553
  }
3560
3554
  __setModuleDefault(result, mod);
3561
3555
  return result;
@@ -3628,7 +3622,7 @@ var require_decode = __commonJS({
3628
3622
  })(DecodingMode = exports2.DecodingMode || (exports2.DecodingMode = {}));
3629
3623
  var EntityDecoder = (
3630
3624
  /** @class */
3631
- function() {
3625
+ (function() {
3632
3626
  function EntityDecoder2(decodeTree, emitCodePoint, errors) {
3633
3627
  this.decodeTree = decodeTree;
3634
3628
  this.emitCodePoint = emitCodePoint;
@@ -3790,6 +3784,7 @@ var require_decode = __commonJS({
3790
3784
  case EntityDecoderState.NamedEntity: {
3791
3785
  return this.result !== 0 && (this.decodeMode !== DecodingMode.Attribute || this.result === this.treeIndex) ? this.emitNotTerminatedNamedEntity() : 0;
3792
3786
  }
3787
+ // Otherwise, emit a numeric entity if we have one.
3793
3788
  case EntityDecoderState.NumericDecimal: {
3794
3789
  return this.emitNumericEntity(0, 2);
3795
3790
  }
@@ -3806,7 +3801,7 @@ var require_decode = __commonJS({
3806
3801
  }
3807
3802
  };
3808
3803
  return EntityDecoder2;
3809
- }()
3804
+ })()
3810
3805
  );
3811
3806
  exports2.EntityDecoder = EntityDecoder;
3812
3807
  function getDecoder(decodeTree) {
@@ -4160,9 +4155,9 @@ var require_lib = __commonJS({
4160
4155
  }
4161
4156
  });
4162
4157
 
4163
- // node_modules/linkify-it/build/index.cjs.js
4158
+ // node_modules/markdownlint/node_modules/linkify-it/build/index.cjs.js
4164
4159
  var require_index_cjs3 = __commonJS({
4165
- "node_modules/linkify-it/build/index.cjs.js"(exports2, module2) {
4160
+ "node_modules/markdownlint/node_modules/linkify-it/build/index.cjs.js"(exports2, module2) {
4166
4161
  "use strict";
4167
4162
  var uc_micro = require_index_cjs2();
4168
4163
  function reFactory(opts) {
@@ -4521,14 +4516,11 @@ var require_index_cjs3 = __commonJS({
4521
4516
  LinkifyIt.prototype.matchAtStart = function matchAtStart(text4) {
4522
4517
  this.__text_cache__ = text4;
4523
4518
  this.__index__ = -1;
4524
- if (!text4.length)
4525
- return null;
4519
+ if (!text4.length) return null;
4526
4520
  const m = this.re.schema_at_start.exec(text4);
4527
- if (!m)
4528
- return null;
4521
+ if (!m) return null;
4529
4522
  const len = this.testSchemaAt(text4, m[2], m[0].length);
4530
- if (!len)
4531
- return null;
4523
+ if (!len) return null;
4532
4524
  this.__schema__ = m[2];
4533
4525
  this.__index__ = m.index + m[1].length;
4534
4526
  this.__last_index__ = m.index + m[0].length + len;
@@ -4801,9 +4793,9 @@ var require_punycode = __commonJS({
4801
4793
  }
4802
4794
  });
4803
4795
 
4804
- // node_modules/markdown-it/dist/index.cjs.js
4796
+ // node_modules/markdownlint/node_modules/markdown-it/dist/index.cjs.js
4805
4797
  var require_index_cjs4 = __commonJS({
4806
- "node_modules/markdown-it/dist/index.cjs.js"(exports2, module2) {
4798
+ "node_modules/markdownlint/node_modules/markdown-it/dist/index.cjs.js"(exports2, module2) {
4807
4799
  "use strict";
4808
4800
  var mdurl = require_index_cjs();
4809
4801
  var ucmicro = require_index_cjs2();
@@ -4964,10 +4956,15 @@ var require_index_cjs4 = __commonJS({
4964
4956
  }
4965
4957
  switch (code3) {
4966
4958
  case 9:
4959
+ // \t
4967
4960
  case 10:
4961
+ // \n
4968
4962
  case 11:
4963
+ // \v
4969
4964
  case 12:
4965
+ // \f
4970
4966
  case 13:
4967
+ // \r
4971
4968
  case 32:
4972
4969
  case 160:
4973
4970
  case 5760:
@@ -5789,117 +5786,112 @@ var require_index_cjs4 = __commonJS({
5789
5786
  let text5 = token.content;
5790
5787
  let pos = 0;
5791
5788
  let max = text5.length;
5792
- OUTER:
5793
- while (pos < max) {
5794
- QUOTE_RE.lastIndex = pos;
5795
- const t = QUOTE_RE.exec(text5);
5796
- if (!t) {
5789
+ OUTER: while (pos < max) {
5790
+ QUOTE_RE.lastIndex = pos;
5791
+ const t = QUOTE_RE.exec(text5);
5792
+ if (!t) {
5793
+ break;
5794
+ }
5795
+ let canOpen = true;
5796
+ let canClose = true;
5797
+ pos = t.index + 1;
5798
+ const isSingle = t[0] === "'";
5799
+ let lastChar = 32;
5800
+ if (t.index - 1 >= 0) {
5801
+ lastChar = text5.charCodeAt(t.index - 1);
5802
+ } else {
5803
+ for (j = i - 1; j >= 0; j--) {
5804
+ if (tokens[j].type === "softbreak" || tokens[j].type === "hardbreak") break;
5805
+ if (!tokens[j].content) continue;
5806
+ lastChar = tokens[j].content.charCodeAt(tokens[j].content.length - 1);
5797
5807
  break;
5798
5808
  }
5799
- let canOpen = true;
5800
- let canClose = true;
5801
- pos = t.index + 1;
5802
- const isSingle = t[0] === "'";
5803
- let lastChar = 32;
5804
- if (t.index - 1 >= 0) {
5805
- lastChar = text5.charCodeAt(t.index - 1);
5806
- } else {
5807
- for (j = i - 1; j >= 0; j--) {
5808
- if (tokens[j].type === "softbreak" || tokens[j].type === "hardbreak")
5809
- break;
5810
- if (!tokens[j].content)
5811
- continue;
5812
- lastChar = tokens[j].content.charCodeAt(tokens[j].content.length - 1);
5813
- break;
5814
- }
5815
- }
5816
- let nextChar = 32;
5817
- if (pos < max) {
5818
- nextChar = text5.charCodeAt(pos);
5819
- } else {
5820
- for (j = i + 1; j < tokens.length; j++) {
5821
- if (tokens[j].type === "softbreak" || tokens[j].type === "hardbreak")
5822
- break;
5823
- if (!tokens[j].content)
5824
- continue;
5825
- nextChar = tokens[j].content.charCodeAt(0);
5826
- break;
5827
- }
5809
+ }
5810
+ let nextChar = 32;
5811
+ if (pos < max) {
5812
+ nextChar = text5.charCodeAt(pos);
5813
+ } else {
5814
+ for (j = i + 1; j < tokens.length; j++) {
5815
+ if (tokens[j].type === "softbreak" || tokens[j].type === "hardbreak") break;
5816
+ if (!tokens[j].content) continue;
5817
+ nextChar = tokens[j].content.charCodeAt(0);
5818
+ break;
5828
5819
  }
5829
- const isLastPunctChar = isMdAsciiPunct(lastChar) || isPunctChar(String.fromCharCode(lastChar));
5830
- const isNextPunctChar = isMdAsciiPunct(nextChar) || isPunctChar(String.fromCharCode(nextChar));
5831
- const isLastWhiteSpace = isWhiteSpace(lastChar);
5832
- const isNextWhiteSpace = isWhiteSpace(nextChar);
5833
- if (isNextWhiteSpace) {
5820
+ }
5821
+ const isLastPunctChar = isMdAsciiPunct(lastChar) || isPunctChar(String.fromCharCode(lastChar));
5822
+ const isNextPunctChar = isMdAsciiPunct(nextChar) || isPunctChar(String.fromCharCode(nextChar));
5823
+ const isLastWhiteSpace = isWhiteSpace(lastChar);
5824
+ const isNextWhiteSpace = isWhiteSpace(nextChar);
5825
+ if (isNextWhiteSpace) {
5826
+ canOpen = false;
5827
+ } else if (isNextPunctChar) {
5828
+ if (!(isLastWhiteSpace || isLastPunctChar)) {
5834
5829
  canOpen = false;
5835
- } else if (isNextPunctChar) {
5836
- if (!(isLastWhiteSpace || isLastPunctChar)) {
5837
- canOpen = false;
5838
- }
5839
5830
  }
5840
- if (isLastWhiteSpace) {
5831
+ }
5832
+ if (isLastWhiteSpace) {
5833
+ canClose = false;
5834
+ } else if (isLastPunctChar) {
5835
+ if (!(isNextWhiteSpace || isNextPunctChar)) {
5841
5836
  canClose = false;
5842
- } else if (isLastPunctChar) {
5843
- if (!(isNextWhiteSpace || isNextPunctChar)) {
5844
- canClose = false;
5845
- }
5846
5837
  }
5847
- if (nextChar === 34 && t[0] === '"') {
5848
- if (lastChar >= 48 && lastChar <= 57) {
5849
- canClose = canOpen = false;
5850
- }
5838
+ }
5839
+ if (nextChar === 34 && t[0] === '"') {
5840
+ if (lastChar >= 48 && lastChar <= 57) {
5841
+ canClose = canOpen = false;
5851
5842
  }
5852
- if (canOpen && canClose) {
5853
- canOpen = isLastPunctChar;
5854
- canClose = isNextPunctChar;
5843
+ }
5844
+ if (canOpen && canClose) {
5845
+ canOpen = isLastPunctChar;
5846
+ canClose = isNextPunctChar;
5847
+ }
5848
+ if (!canOpen && !canClose) {
5849
+ if (isSingle) {
5850
+ token.content = replaceAt(token.content, t.index, APOSTROPHE);
5855
5851
  }
5856
- if (!canOpen && !canClose) {
5857
- if (isSingle) {
5858
- token.content = replaceAt(token.content, t.index, APOSTROPHE);
5852
+ continue;
5853
+ }
5854
+ if (canClose) {
5855
+ for (j = stack.length - 1; j >= 0; j--) {
5856
+ let item = stack[j];
5857
+ if (stack[j].level < thisLevel) {
5858
+ break;
5859
5859
  }
5860
- continue;
5861
- }
5862
- if (canClose) {
5863
- for (j = stack.length - 1; j >= 0; j--) {
5864
- let item = stack[j];
5865
- if (stack[j].level < thisLevel) {
5866
- break;
5860
+ if (item.single === isSingle && stack[j].level === thisLevel) {
5861
+ item = stack[j];
5862
+ let openQuote;
5863
+ let closeQuote;
5864
+ if (isSingle) {
5865
+ openQuote = state.md.options.quotes[2];
5866
+ closeQuote = state.md.options.quotes[3];
5867
+ } else {
5868
+ openQuote = state.md.options.quotes[0];
5869
+ closeQuote = state.md.options.quotes[1];
5867
5870
  }
5868
- if (item.single === isSingle && stack[j].level === thisLevel) {
5869
- item = stack[j];
5870
- let openQuote;
5871
- let closeQuote;
5872
- if (isSingle) {
5873
- openQuote = state.md.options.quotes[2];
5874
- closeQuote = state.md.options.quotes[3];
5875
- } else {
5876
- openQuote = state.md.options.quotes[0];
5877
- closeQuote = state.md.options.quotes[1];
5878
- }
5879
- token.content = replaceAt(token.content, t.index, closeQuote);
5880
- tokens[item.token].content = replaceAt(tokens[item.token].content, item.pos, openQuote);
5881
- pos += closeQuote.length - 1;
5882
- if (item.token === i) {
5883
- pos += openQuote.length - 1;
5884
- }
5885
- text5 = token.content;
5886
- max = text5.length;
5887
- stack.length = j;
5888
- continue OUTER;
5871
+ token.content = replaceAt(token.content, t.index, closeQuote);
5872
+ tokens[item.token].content = replaceAt(tokens[item.token].content, item.pos, openQuote);
5873
+ pos += closeQuote.length - 1;
5874
+ if (item.token === i) {
5875
+ pos += openQuote.length - 1;
5889
5876
  }
5877
+ text5 = token.content;
5878
+ max = text5.length;
5879
+ stack.length = j;
5880
+ continue OUTER;
5890
5881
  }
5891
5882
  }
5892
- if (canOpen) {
5893
- stack.push({
5894
- token: i,
5895
- pos: t.index,
5896
- single: isSingle,
5897
- level: thisLevel
5898
- });
5899
- } else if (canClose && isSingle) {
5900
- token.content = replaceAt(token.content, t.index, APOSTROPHE);
5901
- }
5902
5883
  }
5884
+ if (canOpen) {
5885
+ stack.push({
5886
+ token: i,
5887
+ pos: t.index,
5888
+ single: isSingle,
5889
+ level: thisLevel
5890
+ });
5891
+ } else if (canClose && isSingle) {
5892
+ token.content = replaceAt(token.content, t.index, APOSTROPHE);
5893
+ }
5894
+ }
5903
5895
  }
5904
5896
  }
5905
5897
  function smartquotes(state) {
@@ -5918,8 +5910,7 @@ var require_index_cjs4 = __commonJS({
5918
5910
  const blockTokens = state.tokens;
5919
5911
  const l = blockTokens.length;
5920
5912
  for (let j = 0; j < l; j++) {
5921
- if (blockTokens[j].type !== "inline")
5922
- continue;
5913
+ if (blockTokens[j].type !== "inline") continue;
5923
5914
  const tokens = blockTokens[j].children;
5924
5915
  const max = tokens.length;
5925
5916
  for (curr = 0; curr < max; curr++) {
@@ -6025,11 +6016,9 @@ var require_index_cjs4 = __commonJS({
6025
6016
  StateBlock.prototype.push = function(type, tag, nesting) {
6026
6017
  const token = new Token(type, tag, nesting);
6027
6018
  token.block = true;
6028
- if (nesting < 0)
6029
- this.level--;
6019
+ if (nesting < 0) this.level--;
6030
6020
  token.level = this.level;
6031
- if (nesting > 0)
6032
- this.level++;
6021
+ if (nesting > 0) this.level++;
6033
6022
  this.tokens.push(token);
6034
6023
  return token;
6035
6024
  };
@@ -6221,10 +6210,8 @@ var require_index_cjs4 = __commonJS({
6221
6210
  return false;
6222
6211
  }
6223
6212
  columns = escapedSplit(lineText);
6224
- if (columns.length && columns[0] === "")
6225
- columns.shift();
6226
- if (columns.length && columns[columns.length - 1] === "")
6227
- columns.pop();
6213
+ if (columns.length && columns[0] === "") columns.shift();
6214
+ if (columns.length && columns[columns.length - 1] === "") columns.pop();
6228
6215
  const columnCount = columns.length;
6229
6216
  if (columnCount === 0 || columnCount !== aligns.length) {
6230
6217
  return false;
@@ -6278,10 +6265,8 @@ var require_index_cjs4 = __commonJS({
6278
6265
  break;
6279
6266
  }
6280
6267
  columns = escapedSplit(lineText);
6281
- if (columns.length && columns[0] === "")
6282
- columns.shift();
6283
- if (columns.length && columns[columns.length - 1] === "")
6284
- columns.pop();
6268
+ if (columns.length && columns[0] === "") columns.shift();
6269
+ if (columns.length && columns[columns.length - 1] === "") columns.pop();
6285
6270
  autocompletedCells += columnCount - columns.length;
6286
6271
  if (autocompletedCells > MAX_AUTOCOMPLETED_CELLS) {
6287
6272
  break;
@@ -6643,16 +6628,14 @@ var require_index_cjs4 = __commonJS({
6643
6628
  isOrdered = true;
6644
6629
  start = state.bMarks[nextLine] + state.tShift[nextLine];
6645
6630
  markerValue = Number(state.src.slice(start, posAfterMarker - 1));
6646
- if (isTerminatingParagraph && markerValue !== 1)
6647
- return false;
6631
+ if (isTerminatingParagraph && markerValue !== 1) return false;
6648
6632
  } else if ((posAfterMarker = skipBulletListMarker(state, nextLine)) >= 0) {
6649
6633
  isOrdered = false;
6650
6634
  } else {
6651
6635
  return false;
6652
6636
  }
6653
6637
  if (isTerminatingParagraph) {
6654
- if (state.skipSpaces(posAfterMarker) >= state.eMarks[nextLine])
6655
- return false;
6638
+ if (state.skipSpaces(posAfterMarker) >= state.eMarks[nextLine]) return false;
6656
6639
  }
6657
6640
  if (silent) {
6658
6641
  return true;
@@ -6867,8 +6850,7 @@ var require_index_cjs4 = __commonJS({
6867
6850
  max = str.length;
6868
6851
  nextLine++;
6869
6852
  }
6870
- } else if (isSpace(ch))
6871
- ;
6853
+ } else if (isSpace(ch)) ;
6872
6854
  else {
6873
6855
  break;
6874
6856
  }
@@ -6894,8 +6876,7 @@ var require_index_cjs4 = __commonJS({
6894
6876
  max = str.length;
6895
6877
  nextLine++;
6896
6878
  }
6897
- } else if (isSpace(ch))
6898
- ;
6879
+ } else if (isSpace(ch)) ;
6899
6880
  else {
6900
6881
  break;
6901
6882
  }
@@ -6903,8 +6884,7 @@ var require_index_cjs4 = __commonJS({
6903
6884
  let titleRes = state.md.helpers.parseLinkTitle(str, pos, max);
6904
6885
  while (titleRes.can_continue) {
6905
6886
  const lineContent = getNextLine(nextLine);
6906
- if (lineContent === null)
6907
- break;
6887
+ if (lineContent === null) break;
6908
6888
  str += lineContent;
6909
6889
  pos = max;
6910
6890
  max = str.length;
@@ -7213,8 +7193,7 @@ var require_index_cjs4 = __commonJS({
7213
7193
  break;
7214
7194
  }
7215
7195
  }
7216
- if (!ok)
7217
- throw new Error("none of the block rules matched");
7196
+ if (!ok) throw new Error("none of the block rules matched");
7218
7197
  state.tight = !hasEmptyLines;
7219
7198
  if (state.isEmpty(state.line - 1)) {
7220
7199
  hasEmptyLines = true;
@@ -7356,34 +7335,24 @@ var require_index_cjs4 = __commonJS({
7356
7335
  }
7357
7336
  var SCHEME_RE = /(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;
7358
7337
  function linkify(state, silent) {
7359
- if (!state.md.options.linkify)
7360
- return false;
7361
- if (state.linkLevel > 0)
7362
- return false;
7338
+ if (!state.md.options.linkify) return false;
7339
+ if (state.linkLevel > 0) return false;
7363
7340
  const pos = state.pos;
7364
7341
  const max = state.posMax;
7365
- if (pos + 3 > max)
7366
- return false;
7367
- if (state.src.charCodeAt(pos) !== 58)
7368
- return false;
7369
- if (state.src.charCodeAt(pos + 1) !== 47)
7370
- return false;
7371
- if (state.src.charCodeAt(pos + 2) !== 47)
7372
- return false;
7342
+ if (pos + 3 > max) return false;
7343
+ if (state.src.charCodeAt(pos) !== 58) return false;
7344
+ if (state.src.charCodeAt(pos + 1) !== 47) return false;
7345
+ if (state.src.charCodeAt(pos + 2) !== 47) return false;
7373
7346
  const match = state.pending.match(SCHEME_RE);
7374
- if (!match)
7375
- return false;
7347
+ if (!match) return false;
7376
7348
  const proto = match[1];
7377
7349
  const link2 = state.md.linkify.matchAtStart(state.src.slice(pos - proto.length));
7378
- if (!link2)
7379
- return false;
7350
+ if (!link2) return false;
7380
7351
  let url = link2.url;
7381
- if (url.length <= proto.length)
7382
- return false;
7352
+ if (url.length <= proto.length) return false;
7383
7353
  url = url.replace(/\*+$/, "");
7384
7354
  const fullUrl = state.md.normalizeLink(url);
7385
- if (!state.md.validateLink(fullUrl))
7386
- return false;
7355
+ if (!state.md.validateLink(fullUrl)) return false;
7387
7356
  if (!silent) {
7388
7357
  state.pending = state.pending.slice(0, -proto.length);
7389
7358
  const token_o = state.push("link_open", "a", 1);
@@ -7410,8 +7379,7 @@ var require_index_cjs4 = __commonJS({
7410
7379
  if (pmax >= 0 && state.pending.charCodeAt(pmax) === 32) {
7411
7380
  if (pmax >= 1 && state.pending.charCodeAt(pmax - 1) === 32) {
7412
7381
  let ws = pmax - 1;
7413
- while (ws >= 1 && state.pending.charCodeAt(ws - 1) === 32)
7414
- ws--;
7382
+ while (ws >= 1 && state.pending.charCodeAt(ws - 1) === 32) ws--;
7415
7383
  state.pending = state.pending.slice(0, ws);
7416
7384
  state.push("hardbreak", "br", 0);
7417
7385
  } else {
@@ -7439,11 +7407,9 @@ var require_index_cjs4 = __commonJS({
7439
7407
  function escape(state, silent) {
7440
7408
  let pos = state.pos;
7441
7409
  const max = state.posMax;
7442
- if (state.src.charCodeAt(pos) !== 92)
7443
- return false;
7410
+ if (state.src.charCodeAt(pos) !== 92) return false;
7444
7411
  pos++;
7445
- if (pos >= max)
7446
- return false;
7412
+ if (pos >= max) return false;
7447
7413
  let ch1 = state.src.charCodeAt(pos);
7448
7414
  if (ch1 === 10) {
7449
7415
  if (!silent) {
@@ -7452,8 +7418,7 @@ var require_index_cjs4 = __commonJS({
7452
7418
  pos++;
7453
7419
  while (pos < max) {
7454
7420
  ch1 = state.src.charCodeAt(pos);
7455
- if (!isSpace(ch1))
7456
- break;
7421
+ if (!isSpace(ch1)) break;
7457
7422
  pos++;
7458
7423
  }
7459
7424
  state.pos = pos;
@@ -7496,8 +7461,7 @@ var require_index_cjs4 = __commonJS({
7496
7461
  const marker = state.src.slice(start, pos);
7497
7462
  const openerLength = marker.length;
7498
7463
  if (state.backticksScanned && (state.backticks[openerLength] || 0) <= start) {
7499
- if (!silent)
7500
- state.pending += marker;
7464
+ if (!silent) state.pending += marker;
7501
7465
  state.pos += openerLength;
7502
7466
  return true;
7503
7467
  }
@@ -7521,8 +7485,7 @@ var require_index_cjs4 = __commonJS({
7521
7485
  state.backticks[closerLength] = matchStart;
7522
7486
  }
7523
7487
  state.backticksScanned = true;
7524
- if (!silent)
7525
- state.pending += marker;
7488
+ if (!silent) state.pending += marker;
7526
7489
  state.pos += openerLength;
7527
7490
  return true;
7528
7491
  }
@@ -7927,13 +7890,10 @@ var require_index_cjs4 = __commonJS({
7927
7890
  const start = state.pos;
7928
7891
  const max = state.posMax;
7929
7892
  for (; ; ) {
7930
- if (++pos >= max)
7931
- return false;
7893
+ if (++pos >= max) return false;
7932
7894
  const ch = state.src.charCodeAt(pos);
7933
- if (ch === 60)
7934
- return false;
7935
- if (ch === 62)
7936
- break;
7895
+ if (ch === 60) return false;
7896
+ if (ch === 62) break;
7937
7897
  }
7938
7898
  const url = state.src.slice(start + 1, pos);
7939
7899
  if (AUTOLINK_RE.test(url)) {
@@ -8006,10 +7966,8 @@ var require_index_cjs4 = __commonJS({
8006
7966
  if (!silent) {
8007
7967
  const token = state.push("html_inline", "", 0);
8008
7968
  token.content = match[0];
8009
- if (isLinkOpen(token.content))
8010
- state.linkLevel++;
8011
- if (isLinkClose(token.content))
8012
- state.linkLevel--;
7969
+ if (isLinkOpen(token.content)) state.linkLevel++;
7970
+ if (isLinkClose(token.content)) state.linkLevel--;
8013
7971
  }
8014
7972
  state.pos += match[0].length;
8015
7973
  return true;
@@ -8019,10 +7977,8 @@ var require_index_cjs4 = __commonJS({
8019
7977
  function entity(state, silent) {
8020
7978
  const pos = state.pos;
8021
7979
  const max = state.posMax;
8022
- if (state.src.charCodeAt(pos) !== 38)
8023
- return false;
8024
- if (pos + 1 >= max)
8025
- return false;
7980
+ if (state.src.charCodeAt(pos) !== 38) return false;
7981
+ if (pos + 1 >= max) return false;
8026
7982
  const ch = state.src.charCodeAt(pos + 1);
8027
7983
  if (ch === 35) {
8028
7984
  const match = state.src.slice(pos).match(DIGITAL_RE);
@@ -8058,8 +8014,7 @@ var require_index_cjs4 = __commonJS({
8058
8014
  function processDelimiters(delimiters) {
8059
8015
  const openersBottom = {};
8060
8016
  const max = delimiters.length;
8061
- if (!max)
8062
- return;
8017
+ if (!max) return;
8063
8018
  let headerIdx = 0;
8064
8019
  let lastTokenIdx = -2;
8065
8020
  const jumps = [];
@@ -8071,8 +8026,7 @@ var require_index_cjs4 = __commonJS({
8071
8026
  }
8072
8027
  lastTokenIdx = closer.token;
8073
8028
  closer.length = closer.length || 0;
8074
- if (!closer.close)
8075
- continue;
8029
+ if (!closer.close) continue;
8076
8030
  if (!openersBottom.hasOwnProperty(closer.marker)) {
8077
8031
  openersBottom[closer.marker] = [-1, -1, -1, -1, -1, -1];
8078
8032
  }
@@ -8081,8 +8035,7 @@ var require_index_cjs4 = __commonJS({
8081
8035
  let newMinOpenerIdx = openerIdx;
8082
8036
  for (; openerIdx > minOpenerIdx; openerIdx -= jumps[openerIdx] + 1) {
8083
8037
  const opener = delimiters[openerIdx];
8084
- if (opener.marker !== closer.marker)
8085
- continue;
8038
+ if (opener.marker !== closer.marker) continue;
8086
8039
  if (opener.open && opener.end < 0) {
8087
8040
  let isOddMatch = false;
8088
8041
  if (opener.close || closer.open) {
@@ -8126,11 +8079,9 @@ var require_index_cjs4 = __commonJS({
8126
8079
  const tokens = state.tokens;
8127
8080
  const max = state.tokens.length;
8128
8081
  for (curr = last = 0; curr < max; curr++) {
8129
- if (tokens[curr].nesting < 0)
8130
- level--;
8082
+ if (tokens[curr].nesting < 0) level--;
8131
8083
  tokens[curr].level = level;
8132
- if (tokens[curr].nesting > 0)
8133
- level++;
8084
+ if (tokens[curr].nesting > 0) level++;
8134
8085
  if (tokens[curr].type === "text" && curr + 1 < max && tokens[curr + 1].type === "text") {
8135
8086
  tokens[curr + 1].content = tokens[curr].content + tokens[curr + 1].content;
8136
8087
  } else {
@@ -8677,11 +8628,11 @@ var require_resolve_module = __commonJS({
8677
8628
  });
8678
8629
 
8679
8630
  // node_modules/markdownlint/lib/md001.mjs
8680
- var import_helpers2, import_micromark_helpers2, md001_default;
8631
+ var import_helpers9, import_micromark_helpers2, md001_default;
8681
8632
  var init_md001 = __esm({
8682
8633
  "node_modules/markdownlint/lib/md001.mjs"() {
8683
8634
  "use strict";
8684
- import_helpers2 = __toESM(require_helpers(), 1);
8635
+ import_helpers9 = __toESM(require_helpers(), 1);
8685
8636
  import_micromark_helpers2 = __toESM(require_micromark_helpers(), 1);
8686
8637
  init_cache();
8687
8638
  md001_default = {
@@ -8694,7 +8645,7 @@ var init_md001 = __esm({
8694
8645
  for (const heading of filterByTypesCached(["atxHeading", "setextHeading"])) {
8695
8646
  const level = (0, import_micromark_helpers2.getHeadingLevel)(heading);
8696
8647
  if (level > prevLevel) {
8697
- (0, import_helpers2.addErrorDetailIf)(
8648
+ (0, import_helpers9.addErrorDetailIf)(
8698
8649
  onError,
8699
8650
  heading.startLine,
8700
8651
  `h${prevLevel + 1}`,
@@ -8709,11 +8660,11 @@ var init_md001 = __esm({
8709
8660
  });
8710
8661
 
8711
8662
  // node_modules/markdownlint/lib/md003.mjs
8712
- var import_helpers3, import_micromark_helpers3, md003_default;
8663
+ var import_helpers10, import_micromark_helpers3, md003_default;
8713
8664
  var init_md003 = __esm({
8714
8665
  "node_modules/markdownlint/lib/md003.mjs"() {
8715
8666
  "use strict";
8716
- import_helpers3 = __toESM(require_helpers(), 1);
8667
+ import_helpers10 = __toESM(require_helpers(), 1);
8717
8668
  import_micromark_helpers3 = __toESM(require_micromark_helpers(), 1);
8718
8669
  init_cache();
8719
8670
  md003_default = {
@@ -8739,7 +8690,7 @@ var init_md003 = __esm({
8739
8690
  } else if (style === "setext_with_atx_closed") {
8740
8691
  expected = h12 ? "setext" : "atx_closed";
8741
8692
  }
8742
- (0, import_helpers3.addErrorDetailIf)(
8693
+ (0, import_helpers10.addErrorDetailIf)(
8743
8694
  onError,
8744
8695
  heading.startLine,
8745
8696
  expected,
@@ -8754,11 +8705,11 @@ var init_md003 = __esm({
8754
8705
  });
8755
8706
 
8756
8707
  // node_modules/markdownlint/lib/md004.mjs
8757
- var import_helpers4, import_micromark_helpers4, markerToStyle, styleToMarker, differentItemStyle, validStyles, md004_default;
8708
+ var import_helpers11, import_micromark_helpers4, markerToStyle, styleToMarker, differentItemStyle, validStyles, md004_default;
8758
8709
  var init_md004 = __esm({
8759
8710
  "node_modules/markdownlint/lib/md004.mjs"() {
8760
8711
  "use strict";
8761
- import_helpers4 = __toESM(require_helpers(), 1);
8712
+ import_helpers11 = __toESM(require_helpers(), 1);
8762
8713
  import_micromark_helpers4 = __toESM(require_micromark_helpers(), 1);
8763
8714
  init_cache();
8764
8715
  markerToStyle = {
@@ -8813,7 +8764,7 @@ var init_md004 = __esm({
8813
8764
  }
8814
8765
  const column = listItemMarker.startColumn;
8815
8766
  const length = listItemMarker.endColumn - listItemMarker.startColumn;
8816
- (0, import_helpers4.addErrorDetailIf)(
8767
+ (0, import_helpers11.addErrorDetailIf)(
8817
8768
  onError,
8818
8769
  listItemMarker.startLine,
8819
8770
  expectedStyle,
@@ -8835,11 +8786,11 @@ var init_md004 = __esm({
8835
8786
  });
8836
8787
 
8837
8788
  // node_modules/markdownlint/lib/md005.mjs
8838
- var import_helpers5, md005_default;
8789
+ var import_helpers12, md005_default;
8839
8790
  var init_md005 = __esm({
8840
8791
  "node_modules/markdownlint/lib/md005.mjs"() {
8841
8792
  "use strict";
8842
- import_helpers5 = __toESM(require_helpers(), 1);
8793
+ import_helpers12 = __toESM(require_helpers(), 1);
8843
8794
  init_cache();
8844
8795
  md005_default = {
8845
8796
  "names": ["MD005", "list-indent"],
@@ -8857,7 +8808,7 @@ var init_md005 = __esm({
8857
8808
  const actualIndent = listItemPrefix.startColumn - 1;
8858
8809
  const range = [1, listItemPrefix.endColumn - 1];
8859
8810
  if (list2.type === "listUnordered") {
8860
- (0, import_helpers5.addErrorDetailIf)(
8811
+ (0, import_helpers12.addErrorDetailIf)(
8861
8812
  onError,
8862
8813
  lineNumber,
8863
8814
  expectedIndent,
@@ -8878,7 +8829,7 @@ var init_md005 = __esm({
8878
8829
  const detail = endMatching ? `Expected: (${expectedEnd}); Actual: (${actualEnd})` : `Expected: ${expectedIndent}; Actual: ${actualIndent}`;
8879
8830
  const expected = endMatching ? expectedEnd - markerLength : expectedIndent;
8880
8831
  const actual = endMatching ? actualEnd - markerLength : actualIndent;
8881
- (0, import_helpers5.addError)(
8832
+ (0, import_helpers12.addError)(
8882
8833
  onError,
8883
8834
  lineNumber,
8884
8835
  detail,
@@ -8901,11 +8852,11 @@ var init_md005 = __esm({
8901
8852
  });
8902
8853
 
8903
8854
  // node_modules/markdownlint/lib/md007.mjs
8904
- var import_helpers6, import_micromark_helpers5, unorderedListTypes, unorderedParentTypes, md007_default;
8855
+ var import_helpers13, import_micromark_helpers5, unorderedListTypes, unorderedParentTypes, md007_default;
8905
8856
  var init_md007 = __esm({
8906
8857
  "node_modules/markdownlint/lib/md007.mjs"() {
8907
8858
  "use strict";
8908
- import_helpers6 = __toESM(require_helpers(), 1);
8859
+ import_helpers13 = __toESM(require_helpers(), 1);
8909
8860
  import_micromark_helpers5 = __toESM(require_micromark_helpers(), 1);
8910
8861
  init_cache();
8911
8862
  unorderedListTypes = ["blockQuotePrefix", "listItemPrefix", "listUnordered"];
@@ -8956,7 +8907,7 @@ var init_md007 = __esm({
8956
8907
  "deleteCount": Math.max(actualIndent - expectedIndent, 0),
8957
8908
  "insertText": "".padEnd(Math.max(expectedIndent - actualIndent, 0))
8958
8909
  };
8959
- (0, import_helpers6.addErrorDetailIf)(
8910
+ (0, import_helpers13.addErrorDetailIf)(
8960
8911
  onError,
8961
8912
  startLine,
8962
8913
  expectedIndent,
@@ -8975,11 +8926,11 @@ var init_md007 = __esm({
8975
8926
  });
8976
8927
 
8977
8928
  // node_modules/markdownlint/lib/md009.mjs
8978
- var import_helpers7, import_micromark_helpers6, md009_default;
8929
+ var import_helpers14, import_micromark_helpers6, md009_default;
8979
8930
  var init_md009 = __esm({
8980
8931
  "node_modules/markdownlint/lib/md009.mjs"() {
8981
8932
  "use strict";
8982
- import_helpers7 = __toESM(require_helpers(), 1);
8933
+ import_helpers14 = __toESM(require_helpers(), 1);
8983
8934
  import_micromark_helpers6 = __toESM(require_micromark_helpers(), 1);
8984
8935
  init_cache();
8985
8936
  md009_default = {
@@ -9041,7 +8992,7 @@ var init_md009 = __esm({
9041
8992
  const trailingSpaces = line.length - line.trimEnd().length;
9042
8993
  if (trailingSpaces && !codeBlockLineNumbers.has(lineNumber) && !listItemLineNumbers.has(lineNumber) && (expected !== trailingSpaces || strict && (!paragraphLineNumbers.has(lineNumber) || codeInlineLineNumbers.has(lineNumber)))) {
9043
8994
  const column = line.length - trailingSpaces + 1;
9044
- (0, import_helpers7.addError)(
8995
+ (0, import_helpers14.addError)(
9045
8996
  onError,
9046
8997
  lineNumber,
9047
8998
  "Expected: " + (expected === 0 ? "" : "0 or ") + expected + "; Actual: " + trailingSpaces,
@@ -9060,11 +9011,11 @@ var init_md009 = __esm({
9060
9011
  });
9061
9012
 
9062
9013
  // node_modules/markdownlint/lib/md010.mjs
9063
- var import_helpers8, import_micromark_helpers7, tabRe, md010_default;
9014
+ var import_helpers15, import_micromark_helpers7, tabRe, md010_default;
9064
9015
  var init_md010 = __esm({
9065
9016
  "node_modules/markdownlint/lib/md010.mjs"() {
9066
9017
  "use strict";
9067
- import_helpers8 = __toESM(require_helpers(), 1);
9018
+ import_helpers15 = __toESM(require_helpers(), 1);
9068
9019
  import_micromark_helpers7 = __toESM(require_micromark_helpers(), 1);
9069
9020
  init_cache();
9070
9021
  tabRe = /\t+/g;
@@ -9114,8 +9065,8 @@ var init_md010 = __esm({
9114
9065
  const column = match.index + 1;
9115
9066
  const length = match[0].length;
9116
9067
  const range = { "startLine": lineNumber, "startColumn": column, "endLine": lineNumber, "endColumn": column + length - 1 };
9117
- if (!codeRanges.some((codeRange) => (0, import_helpers8.hasOverlap)(codeRange, range))) {
9118
- (0, import_helpers8.addError)(
9068
+ if (!codeRanges.some((codeRange) => (0, import_helpers15.hasOverlap)(codeRange, range))) {
9069
+ (0, import_helpers15.addError)(
9119
9070
  onError,
9120
9071
  lineNumber,
9121
9072
  "Column: " + column,
@@ -9136,11 +9087,11 @@ var init_md010 = __esm({
9136
9087
  });
9137
9088
 
9138
9089
  // node_modules/markdownlint/lib/md011.mjs
9139
- var import_helpers9, import_micromark_helpers8, reversedLinkRe, md011_default;
9090
+ var import_helpers16, import_micromark_helpers8, reversedLinkRe, md011_default;
9140
9091
  var init_md011 = __esm({
9141
9092
  "node_modules/markdownlint/lib/md011.mjs"() {
9142
9093
  "use strict";
9143
- import_helpers9 = __toESM(require_helpers(), 1);
9094
+ import_helpers16 = __toESM(require_helpers(), 1);
9144
9095
  import_micromark_helpers8 = __toESM(require_micromark_helpers(), 1);
9145
9096
  init_cache();
9146
9097
  reversedLinkRe = /(^|[^\\])\(([^()]+)\)\[([^\]^][^\]]*)\](?!\()/g;
@@ -9165,8 +9116,8 @@ var init_md011 = __esm({
9165
9116
  const column = match.index + preChar.length + 1;
9166
9117
  const length = match[0].length - preChar.length;
9167
9118
  const range = { "startLine": lineNumber, "startColumn": column, "endLine": lineNumber, "endColumn": column + length - 1 };
9168
- if (!codeTexts.some((codeText2) => (0, import_helpers9.hasOverlap)(codeText2, range))) {
9169
- (0, import_helpers9.addError)(
9119
+ if (!codeTexts.some((codeText2) => (0, import_helpers16.hasOverlap)(codeText2, range))) {
9120
+ (0, import_helpers16.addError)(
9170
9121
  onError,
9171
9122
  lineNumber,
9172
9123
  reversedLink.slice(preChar.length),
@@ -9189,11 +9140,11 @@ var init_md011 = __esm({
9189
9140
  });
9190
9141
 
9191
9142
  // node_modules/markdownlint/lib/md012.mjs
9192
- var import_helpers10, import_micromark_helpers9, md012_default;
9143
+ var import_helpers17, import_micromark_helpers9, md012_default;
9193
9144
  var init_md012 = __esm({
9194
9145
  "node_modules/markdownlint/lib/md012.mjs"() {
9195
9146
  "use strict";
9196
- import_helpers10 = __toESM(require_helpers(), 1);
9147
+ import_helpers17 = __toESM(require_helpers(), 1);
9197
9148
  import_micromark_helpers9 = __toESM(require_micromark_helpers(), 1);
9198
9149
  init_cache();
9199
9150
  md012_default = {
@@ -9213,7 +9164,7 @@ var init_md012 = __esm({
9213
9164
  const inCode = codeBlockLineNumbers.has(lineIndex + 1);
9214
9165
  count = inCode || line.trim().length > 0 ? 0 : count + 1;
9215
9166
  if (maximum < count) {
9216
- (0, import_helpers10.addErrorDetailIf)(
9167
+ (0, import_helpers17.addErrorDetailIf)(
9217
9168
  onError,
9218
9169
  lineIndex + 1,
9219
9170
  maximum,
@@ -9233,11 +9184,11 @@ var init_md012 = __esm({
9233
9184
  });
9234
9185
 
9235
9186
  // node_modules/markdownlint/lib/md013.mjs
9236
- var import_helpers11, import_micromark_helpers10, longLineRePrefix, longLineRePostfixRelaxed, longLineRePostfixStrict, sternModeRe, md013_default;
9187
+ var import_helpers18, import_micromark_helpers10, longLineRePrefix, longLineRePostfixRelaxed, longLineRePostfixStrict, sternModeRe, md013_default;
9237
9188
  var init_md013 = __esm({
9238
9189
  "node_modules/markdownlint/lib/md013.mjs"() {
9239
9190
  "use strict";
9240
- import_helpers11 = __toESM(require_helpers(), 1);
9191
+ import_helpers18 = __toESM(require_helpers(), 1);
9241
9192
  init_cache();
9242
9193
  import_micromark_helpers10 = __toESM(require_micromark_helpers(), 1);
9243
9194
  longLineRePrefix = "^.{";
@@ -9303,7 +9254,7 @@ var init_md013 = __esm({
9303
9254
  const length = inCode ? codeLineLength : isHeading ? headingLineLength : lineLength;
9304
9255
  const lengthRe = inCode ? longCodeLineRe : isHeading ? longHeadingLineRe : longLineRe;
9305
9256
  if ((includeCodeBlocks || !inCode) && (includeTables || !inTable) && (includeHeadings || !isHeading) && !definitionLineIndices.has(lineIndex) && (strict || !(stern && sternModeRe.test(line)) && !linkOnlyLineNumbers.has(lineNumber)) && lengthRe.test(line)) {
9306
- (0, import_helpers11.addErrorDetailIf)(
9257
+ (0, import_helpers18.addErrorDetailIf)(
9307
9258
  onError,
9308
9259
  lineNumber,
9309
9260
  length,
@@ -9320,11 +9271,11 @@ var init_md013 = __esm({
9320
9271
  });
9321
9272
 
9322
9273
  // node_modules/markdownlint/lib/md014.mjs
9323
- var import_helpers12, dollarCommandRe, md014_default;
9274
+ var import_helpers19, dollarCommandRe, md014_default;
9324
9275
  var init_md014 = __esm({
9325
9276
  "node_modules/markdownlint/lib/md014.mjs"() {
9326
9277
  "use strict";
9327
- import_helpers12 = __toESM(require_helpers(), 1);
9278
+ import_helpers19 = __toESM(require_helpers(), 1);
9328
9279
  init_cache();
9329
9280
  dollarCommandRe = /^(\s*)(\$\s+)/;
9330
9281
  md014_default = {
@@ -9345,7 +9296,7 @@ var init_md014 = __esm({
9345
9296
  for (const dollarMatch of dollarMatches) {
9346
9297
  const column = dollarMatch.startColumn + dollarMatch.result[1].length;
9347
9298
  const length = dollarMatch.result[2].length;
9348
- (0, import_helpers12.addErrorContext)(
9299
+ (0, import_helpers19.addErrorContext)(
9349
9300
  onError,
9350
9301
  dollarMatch.startLine,
9351
9302
  dollarMatch.text,
@@ -9366,11 +9317,11 @@ var init_md014 = __esm({
9366
9317
  });
9367
9318
 
9368
9319
  // node_modules/markdownlint/lib/md018.mjs
9369
- var import_helpers13, import_micromark_helpers11, md018_default;
9320
+ var import_helpers20, import_micromark_helpers11, md018_default;
9370
9321
  var init_md018 = __esm({
9371
9322
  "node_modules/markdownlint/lib/md018.mjs"() {
9372
9323
  "use strict";
9373
- import_helpers13 = __toESM(require_helpers(), 1);
9324
+ import_helpers20 = __toESM(require_helpers(), 1);
9374
9325
  import_micromark_helpers11 = __toESM(require_micromark_helpers(), 1);
9375
9326
  init_cache();
9376
9327
  md018_default = {
@@ -9387,7 +9338,7 @@ var init_md018 = __esm({
9387
9338
  for (const [lineIndex, line] of lines.entries()) {
9388
9339
  if (!ignoreBlockLineNumbers.has(lineIndex + 1) && /^#+[^# \t]/.test(line) && !/#\s*$/.test(line) && !line.startsWith("#\uFE0F\u20E3")) {
9389
9340
  const hashCount = /^#+/.exec(line)[0].length;
9390
- (0, import_helpers13.addErrorContext)(
9341
+ (0, import_helpers20.addErrorContext)(
9391
9342
  onError,
9392
9343
  lineIndex + 1,
9393
9344
  line.trim(),
@@ -9418,7 +9369,7 @@ function validateHeadingSpaces(onError, heading, delta) {
9418
9369
  if ((headingSequence == null ? void 0 : headingSequence.type) === "atxHeadingSequence" && (whitespace == null ? void 0 : whitespace.type) === "whitespace" && whitespace.text.length > 1) {
9419
9370
  const column = whitespace.startColumn + 1;
9420
9371
  const length = whitespace.endColumn - column;
9421
- (0, import_helpers14.addErrorContext)(
9372
+ (0, import_helpers21.addErrorContext)(
9422
9373
  onError,
9423
9374
  startLine,
9424
9375
  text4.trim(),
@@ -9432,11 +9383,11 @@ function validateHeadingSpaces(onError, heading, delta) {
9432
9383
  );
9433
9384
  }
9434
9385
  }
9435
- var import_helpers14, import_micromark_helpers12, md019_md021_default;
9386
+ var import_helpers21, import_micromark_helpers12, md019_md021_default;
9436
9387
  var init_md019_md021 = __esm({
9437
9388
  "node_modules/markdownlint/lib/md019-md021.mjs"() {
9438
9389
  "use strict";
9439
- import_helpers14 = __toESM(require_helpers(), 1);
9390
+ import_helpers21 = __toESM(require_helpers(), 1);
9440
9391
  import_micromark_helpers12 = __toESM(require_micromark_helpers(), 1);
9441
9392
  init_cache();
9442
9393
  md019_md021_default = [
@@ -9470,11 +9421,11 @@ var init_md019_md021 = __esm({
9470
9421
  });
9471
9422
 
9472
9423
  // node_modules/markdownlint/lib/md020.mjs
9473
- var import_helpers15, import_micromark_helpers13, md020_default;
9424
+ var import_helpers22, import_micromark_helpers13, md020_default;
9474
9425
  var init_md020 = __esm({
9475
9426
  "node_modules/markdownlint/lib/md020.mjs"() {
9476
9427
  "use strict";
9477
- import_helpers15 = __toESM(require_helpers(), 1);
9428
+ import_helpers22 = __toESM(require_helpers(), 1);
9478
9429
  import_micromark_helpers13 = __toESM(require_micromark_helpers(), 1);
9479
9430
  init_cache();
9480
9431
  md020_default = {
@@ -9515,7 +9466,7 @@ var init_md020 = __esm({
9515
9466
  line.length - trailSpaceLength - rightHashLength,
9516
9467
  rightHashLength + 1
9517
9468
  ];
9518
- (0, import_helpers15.addErrorContext)(
9469
+ (0, import_helpers22.addErrorContext)(
9519
9470
  onError,
9520
9471
  lineIndex + 1,
9521
9472
  line.trim(),
@@ -9538,11 +9489,11 @@ var init_md020 = __esm({
9538
9489
  });
9539
9490
 
9540
9491
  // node_modules/markdownlint/lib/md022.mjs
9541
- var import_helpers16, import_micromark_helpers14, defaultLines, getLinesFunction, md022_default;
9492
+ var import_helpers23, import_micromark_helpers14, defaultLines, getLinesFunction, md022_default;
9542
9493
  var init_md022 = __esm({
9543
9494
  "node_modules/markdownlint/lib/md022.mjs"() {
9544
9495
  "use strict";
9545
- import_helpers16 = __toESM(require_helpers(), 1);
9496
+ import_helpers23 = __toESM(require_helpers(), 1);
9546
9497
  import_micromark_helpers14 = __toESM(require_micromark_helpers(), 1);
9547
9498
  init_cache();
9548
9499
  defaultLines = 1;
@@ -9573,10 +9524,10 @@ var init_md022 = __esm({
9573
9524
  const linesAbove = getLinesAbove(heading);
9574
9525
  if (linesAbove >= 0) {
9575
9526
  let actualAbove = 0;
9576
- for (let i = 0; i < linesAbove && (0, import_helpers16.isBlankLine)(lines[startLine - 2 - i]); i++) {
9527
+ for (let i = 0; i < linesAbove && (0, import_helpers23.isBlankLine)(lines[startLine - 2 - i]); i++) {
9577
9528
  actualAbove++;
9578
9529
  }
9579
- (0, import_helpers16.addErrorDetailIf)(
9530
+ (0, import_helpers23.addErrorDetailIf)(
9580
9531
  onError,
9581
9532
  startLine,
9582
9533
  linesAbove,
@@ -9596,10 +9547,10 @@ var init_md022 = __esm({
9596
9547
  const linesBelow = getLinesBelow(heading);
9597
9548
  if (linesBelow >= 0) {
9598
9549
  let actualBelow = 0;
9599
- for (let i = 0; i < linesBelow && (0, import_helpers16.isBlankLine)(lines[endLine + i]); i++) {
9550
+ for (let i = 0; i < linesBelow && (0, import_helpers23.isBlankLine)(lines[endLine + i]); i++) {
9600
9551
  actualBelow++;
9601
9552
  }
9602
- (0, import_helpers16.addErrorDetailIf)(
9553
+ (0, import_helpers23.addErrorDetailIf)(
9603
9554
  onError,
9604
9555
  startLine,
9605
9556
  linesBelow,
@@ -9624,11 +9575,11 @@ var init_md022 = __esm({
9624
9575
  });
9625
9576
 
9626
9577
  // node_modules/markdownlint/lib/md023.mjs
9627
- var import_helpers17, md023_default;
9578
+ var import_helpers24, md023_default;
9628
9579
  var init_md023 = __esm({
9629
9580
  "node_modules/markdownlint/lib/md023.mjs"() {
9630
9581
  "use strict";
9631
- import_helpers17 = __toESM(require_helpers(), 1);
9582
+ import_helpers24 = __toESM(require_helpers(), 1);
9632
9583
  init_cache();
9633
9584
  md023_default = {
9634
9585
  "names": ["MD023", "heading-start-left"],
@@ -9641,7 +9592,7 @@ var init_md023 = __esm({
9641
9592
  if (headings[i].type === "linePrefix" && headings[i + 1].type !== "linePrefix" && headings[i].startLine === headings[i + 1].startLine) {
9642
9593
  const { endColumn, startColumn, startLine } = headings[i];
9643
9594
  const length = endColumn - startColumn;
9644
- (0, import_helpers17.addErrorContext)(
9595
+ (0, import_helpers24.addErrorContext)(
9645
9596
  onError,
9646
9597
  startLine,
9647
9598
  params2.lines[startLine - 1],
@@ -9661,11 +9612,11 @@ var init_md023 = __esm({
9661
9612
  });
9662
9613
 
9663
9614
  // node_modules/markdownlint/lib/md024.mjs
9664
- var import_helpers18, import_micromark_helpers15, md024_default;
9615
+ var import_helpers25, import_micromark_helpers15, md024_default;
9665
9616
  var init_md024 = __esm({
9666
9617
  "node_modules/markdownlint/lib/md024.mjs"() {
9667
9618
  "use strict";
9668
- import_helpers18 = __toESM(require_helpers(), 1);
9619
+ import_helpers25 = __toESM(require_helpers(), 1);
9669
9620
  import_micromark_helpers15 = __toESM(require_micromark_helpers(), 1);
9670
9621
  init_cache();
9671
9622
  md024_default = {
@@ -9693,7 +9644,7 @@ var init_md024 = __esm({
9693
9644
  knownContent = knownContents[newLevel];
9694
9645
  }
9695
9646
  if (knownContent.includes(headingText)) {
9696
- (0, import_helpers18.addErrorContext)(
9647
+ (0, import_helpers25.addErrorContext)(
9697
9648
  onError,
9698
9649
  heading.startLine,
9699
9650
  headingText.trim()
@@ -9708,11 +9659,11 @@ var init_md024 = __esm({
9708
9659
  });
9709
9660
 
9710
9661
  // node_modules/markdownlint/lib/md025.mjs
9711
- var import_helpers19, import_micromark_helpers16, md025_default;
9662
+ var import_helpers26, import_micromark_helpers16, md025_default;
9712
9663
  var init_md025 = __esm({
9713
9664
  "node_modules/markdownlint/lib/md025.mjs"() {
9714
9665
  "use strict";
9715
- import_helpers19 = __toESM(require_helpers(), 1);
9666
+ import_helpers26 = __toESM(require_helpers(), 1);
9716
9667
  import_micromark_helpers16 = __toESM(require_micromark_helpers(), 1);
9717
9668
  init_cache();
9718
9669
  md025_default = {
@@ -9722,7 +9673,7 @@ var init_md025 = __esm({
9722
9673
  "parser": "micromark",
9723
9674
  "function": function MD025(params2, onError) {
9724
9675
  const level = Number(params2.config.level || 1);
9725
- const foundFrontMatterTitle = (0, import_helpers19.frontMatterHasTitle)(
9676
+ const foundFrontMatterTitle = (0, import_helpers26.frontMatterHasTitle)(
9726
9677
  params2.frontMatterLines,
9727
9678
  params2.config.front_matter_title
9728
9679
  );
@@ -9732,7 +9683,7 @@ var init_md025 = __esm({
9732
9683
  if (headingLevel === level) {
9733
9684
  if (hasTopLevelHeading || foundFrontMatterTitle) {
9734
9685
  const headingText = (0, import_micromark_helpers16.getHeadingText)(heading);
9735
- (0, import_helpers19.addErrorContext)(
9686
+ (0, import_helpers26.addErrorContext)(
9736
9687
  onError,
9737
9688
  heading.startLine,
9738
9689
  headingText
@@ -9748,11 +9699,11 @@ var init_md025 = __esm({
9748
9699
  });
9749
9700
 
9750
9701
  // node_modules/markdownlint/lib/md026.mjs
9751
- var import_helpers20, md026_default;
9702
+ var import_helpers27, md026_default;
9752
9703
  var init_md026 = __esm({
9753
9704
  "node_modules/markdownlint/lib/md026.mjs"() {
9754
9705
  "use strict";
9755
- import_helpers20 = __toESM(require_helpers(), 1);
9706
+ import_helpers27 = __toESM(require_helpers(), 1);
9756
9707
  init_cache();
9757
9708
  md026_default = {
9758
9709
  "names": ["MD026", "no-trailing-punctuation"],
@@ -9762,18 +9713,18 @@ var init_md026 = __esm({
9762
9713
  "function": function MD026(params2, onError) {
9763
9714
  let punctuation = params2.config.punctuation;
9764
9715
  punctuation = String(
9765
- punctuation === void 0 ? import_helpers20.allPunctuationNoQuestion : punctuation
9716
+ punctuation === void 0 ? import_helpers27.allPunctuationNoQuestion : punctuation
9766
9717
  );
9767
- const trailingPunctuationRe = new RegExp("\\s*[" + (0, import_helpers20.escapeForRegExp)(punctuation) + "]+$");
9718
+ const trailingPunctuationRe = new RegExp("\\s*[" + (0, import_helpers27.escapeForRegExp)(punctuation) + "]+$");
9768
9719
  const headings = filterByTypesCached(["atxHeadingText", "setextHeadingText"]);
9769
9720
  for (const heading of headings) {
9770
9721
  const { endColumn, endLine, text: text4 } = heading;
9771
9722
  const match = trailingPunctuationRe.exec(text4);
9772
- if (match && !import_helpers20.endOfLineHtmlEntityRe.test(text4) && !import_helpers20.endOfLineGemojiCodeRe.test(text4)) {
9723
+ if (match && !import_helpers27.endOfLineHtmlEntityRe.test(text4) && !import_helpers27.endOfLineGemojiCodeRe.test(text4)) {
9773
9724
  const fullMatch = match[0];
9774
9725
  const length = fullMatch.length;
9775
9726
  const column = endColumn - length;
9776
- (0, import_helpers20.addError)(
9727
+ (0, import_helpers27.addError)(
9777
9728
  onError,
9778
9729
  endLine,
9779
9730
  `Punctuation: '${fullMatch}'`,
@@ -9792,11 +9743,11 @@ var init_md026 = __esm({
9792
9743
  });
9793
9744
 
9794
9745
  // node_modules/markdownlint/lib/md027.mjs
9795
- var import_helpers21, md027_default;
9746
+ var import_helpers28, md027_default;
9796
9747
  var init_md027 = __esm({
9797
9748
  "node_modules/markdownlint/lib/md027.mjs"() {
9798
9749
  "use strict";
9799
- import_helpers21 = __toESM(require_helpers(), 1);
9750
+ import_helpers28 = __toESM(require_helpers(), 1);
9800
9751
  init_cache();
9801
9752
  md027_default = {
9802
9753
  "names": ["MD027", "no-multiple-space-blockquote"],
@@ -9814,7 +9765,7 @@ var init_md027 = __esm({
9814
9765
  const { startColumn, startLine, text: text4 } = token;
9815
9766
  const { length } = text4;
9816
9767
  const line = params2.lines[startLine - 1];
9817
- (0, import_helpers21.addErrorContext)(
9768
+ (0, import_helpers28.addErrorContext)(
9818
9769
  onError,
9819
9770
  startLine,
9820
9771
  line,
@@ -9834,11 +9785,11 @@ var init_md027 = __esm({
9834
9785
  });
9835
9786
 
9836
9787
  // node_modules/markdownlint/lib/md028.mjs
9837
- var import_helpers22, ignoreTypes, md028_default;
9788
+ var import_helpers29, ignoreTypes, md028_default;
9838
9789
  var init_md028 = __esm({
9839
9790
  "node_modules/markdownlint/lib/md028.mjs"() {
9840
9791
  "use strict";
9841
- import_helpers22 = __toESM(require_helpers(), 1);
9792
+ import_helpers29 = __toESM(require_helpers(), 1);
9842
9793
  init_cache();
9843
9794
  ignoreTypes = /* @__PURE__ */ new Set(["lineEnding", "listItemIndent", "linePrefix"]);
9844
9795
  md028_default = {
@@ -9859,7 +9810,7 @@ var init_md028 = __esm({
9859
9810
  } else if (ignoreTypes.has(type)) {
9860
9811
  } else if (type === "blockQuote") {
9861
9812
  for (const lineNumber of errorLineNumbers) {
9862
- (0, import_helpers22.addError)(onError, lineNumber);
9813
+ (0, import_helpers29.addError)(onError, lineNumber);
9863
9814
  }
9864
9815
  break;
9865
9816
  } else {
@@ -9876,11 +9827,11 @@ var init_md028 = __esm({
9876
9827
  function getOrderedListItemValue(listItemPrefix) {
9877
9828
  return Number((0, import_micromark_helpers17.getDescendantsByType)(listItemPrefix, ["listItemValue"])[0].text);
9878
9829
  }
9879
- var import_helpers23, import_micromark_helpers17, listStyleExamples, md029_default;
9830
+ var import_helpers30, import_micromark_helpers17, listStyleExamples, md029_default;
9880
9831
  var init_md029 = __esm({
9881
9832
  "node_modules/markdownlint/lib/md029.mjs"() {
9882
9833
  "use strict";
9883
- import_helpers23 = __toESM(require_helpers(), 1);
9834
+ import_helpers30 = __toESM(require_helpers(), 1);
9884
9835
  import_micromark_helpers17 = __toESM(require_micromark_helpers(), 1);
9885
9836
  init_cache();
9886
9837
  listStyleExamples = {
@@ -9919,7 +9870,7 @@ var init_md029 = __esm({
9919
9870
  }
9920
9871
  for (const listItemPrefix of listItemPrefixes) {
9921
9872
  const actual = getOrderedListItemValue(listItemPrefix);
9922
- (0, import_helpers23.addErrorDetailIf)(
9873
+ (0, import_helpers30.addErrorDetailIf)(
9923
9874
  onError,
9924
9875
  listItemPrefix.startLine,
9925
9876
  expected,
@@ -9939,11 +9890,11 @@ var init_md029 = __esm({
9939
9890
  });
9940
9891
 
9941
9892
  // node_modules/markdownlint/lib/md030.mjs
9942
- var import_helpers24, md030_default;
9893
+ var import_helpers31, md030_default;
9943
9894
  var init_md030 = __esm({
9944
9895
  "node_modules/markdownlint/lib/md030.mjs"() {
9945
9896
  "use strict";
9946
- import_helpers24 = __toESM(require_helpers(), 1);
9897
+ import_helpers31 = __toESM(require_helpers(), 1);
9947
9898
  init_cache();
9948
9899
  md030_default = {
9949
9900
  "names": ["MD030", "list-marker-space"],
@@ -9976,7 +9927,7 @@ var init_md030 = __esm({
9976
9927
  "deleteCount": actualSpaces,
9977
9928
  "insertText": "".padEnd(expectedSpaces)
9978
9929
  };
9979
- (0, import_helpers24.addErrorDetailIf)(
9930
+ (0, import_helpers31.addErrorDetailIf)(
9980
9931
  onError,
9981
9932
  startLine,
9982
9933
  expectedSpaces,
@@ -10003,7 +9954,7 @@ function addError7(onError, lines, lineNumber, top) {
10003
9954
  "insertText": `${prefix.replace(/[^>]/g, " ").trim()}
10004
9955
  `
10005
9956
  };
10006
- (0, import_helpers25.addErrorContext)(
9957
+ (0, import_helpers32.addErrorContext)(
10007
9958
  onError,
10008
9959
  lineNumber,
10009
9960
  line.trim(),
@@ -10013,11 +9964,11 @@ function addError7(onError, lines, lineNumber, top) {
10013
9964
  fixInfo
10014
9965
  );
10015
9966
  }
10016
- var import_helpers25, import_micromark_helpers18, codeFencePrefixRe, md031_default;
9967
+ var import_helpers32, import_micromark_helpers18, codeFencePrefixRe, md031_default;
10017
9968
  var init_md031 = __esm({
10018
9969
  "node_modules/markdownlint/lib/md031.mjs"() {
10019
9970
  "use strict";
10020
- import_helpers25 = __toESM(require_helpers(), 1);
9971
+ import_helpers32 = __toESM(require_helpers(), 1);
10021
9972
  import_micromark_helpers18 = __toESM(require_micromark_helpers(), 1);
10022
9973
  init_cache();
10023
9974
  codeFencePrefixRe = /^(.*?)[`~]/;
@@ -10032,10 +9983,10 @@ var init_md031 = __esm({
10032
9983
  const { lines } = params2;
10033
9984
  for (const codeBlock of filterByTypesCached(["codeFenced"])) {
10034
9985
  if (includeListItems || !(0, import_micromark_helpers18.getParentOfType)(codeBlock, ["listOrdered", "listUnordered"])) {
10035
- if (!(0, import_helpers25.isBlankLine)(lines[codeBlock.startLine - 2])) {
9986
+ if (!(0, import_helpers32.isBlankLine)(lines[codeBlock.startLine - 2])) {
10036
9987
  addError7(onError, lines, codeBlock.startLine, true);
10037
9988
  }
10038
- if (!(0, import_helpers25.isBlankLine)(lines[codeBlock.endLine]) && !(0, import_helpers25.isBlankLine)(lines[codeBlock.endLine - 1])) {
9989
+ if (!(0, import_helpers32.isBlankLine)(lines[codeBlock.endLine]) && !(0, import_helpers32.isBlankLine)(lines[codeBlock.endLine - 1])) {
10039
9990
  addError7(onError, lines, codeBlock.endLine, false);
10040
9991
  }
10041
9992
  }
@@ -10046,11 +9997,11 @@ var init_md031 = __esm({
10046
9997
  });
10047
9998
 
10048
9999
  // node_modules/markdownlint/lib/md032.mjs
10049
- var import_helpers26, import_micromark_helpers19, isList, md032_default;
10000
+ var import_helpers33, import_micromark_helpers19, isList, md032_default;
10050
10001
  var init_md032 = __esm({
10051
10002
  "node_modules/markdownlint/lib/md032.mjs"() {
10052
10003
  "use strict";
10053
- import_helpers26 = __toESM(require_helpers(), 1);
10004
+ import_helpers33 = __toESM(require_helpers(), 1);
10054
10005
  import_micromark_helpers19 = __toESM(require_micromark_helpers(), 1);
10055
10006
  init_cache();
10056
10007
  isList = (token) => token.type === "listOrdered" || token.type === "listUnordered";
@@ -10069,8 +10020,8 @@ var init_md032 = __esm({
10069
10020
  );
10070
10021
  for (const list2 of topLevelLists) {
10071
10022
  const firstLineNumber = list2.startLine;
10072
- if (!(0, import_helpers26.isBlankLine)(lines[firstLineNumber - 2])) {
10073
- (0, import_helpers26.addErrorContext)(
10023
+ if (!(0, import_helpers33.isBlankLine)(lines[firstLineNumber - 2])) {
10024
+ (0, import_helpers33.addErrorContext)(
10074
10025
  onError,
10075
10026
  firstLineNumber,
10076
10027
  lines[firstLineNumber - 1].trim(),
@@ -10092,8 +10043,8 @@ var init_md032 = __esm({
10092
10043
  endLine = flattenedChildren[flattenedChildren.length - 1].endLine;
10093
10044
  }
10094
10045
  const lastLineNumber = endLine;
10095
- if (!(0, import_helpers26.isBlankLine)(lines[lastLineNumber])) {
10096
- (0, import_helpers26.addErrorContext)(
10046
+ if (!(0, import_helpers33.isBlankLine)(lines[lastLineNumber])) {
10047
+ (0, import_helpers33.addErrorContext)(
10097
10048
  onError,
10098
10049
  lastLineNumber,
10099
10050
  lines[lastLineNumber - 1].trim(),
@@ -10113,11 +10064,11 @@ var init_md032 = __esm({
10113
10064
  });
10114
10065
 
10115
10066
  // node_modules/markdownlint/lib/md033.mjs
10116
- var import_helpers27, import_micromark_helpers20, md033_default;
10067
+ var import_helpers34, import_micromark_helpers20, md033_default;
10117
10068
  var init_md033 = __esm({
10118
10069
  "node_modules/markdownlint/lib/md033.mjs"() {
10119
10070
  "use strict";
10120
- import_helpers27 = __toESM(require_helpers(), 1);
10071
+ import_helpers34 = __toESM(require_helpers(), 1);
10121
10072
  import_micromark_helpers20 = __toESM(require_micromark_helpers(), 1);
10122
10073
  init_cache();
10123
10074
  md033_default = {
@@ -10134,9 +10085,9 @@ var init_md033 = __esm({
10134
10085
  if (htmlTagInfo && !htmlTagInfo.close && !allowedElements.includes(htmlTagInfo.name.toLowerCase())) {
10135
10086
  const range = [
10136
10087
  token.startColumn,
10137
- token.text.replace(import_helpers27.nextLinesRe, "").length
10088
+ token.text.replace(import_helpers34.nextLinesRe, "").length
10138
10089
  ];
10139
- (0, import_helpers27.addError)(
10090
+ (0, import_helpers34.addError)(
10140
10091
  onError,
10141
10092
  token.startLine,
10142
10093
  "Element: " + htmlTagInfo.name,
@@ -10151,11 +10102,11 @@ var init_md033 = __esm({
10151
10102
  });
10152
10103
 
10153
10104
  // node_modules/markdownlint/lib/md034.mjs
10154
- var import_helpers28, import_micromark_helpers21, md034_default;
10105
+ var import_helpers35, import_micromark_helpers21, md034_default;
10155
10106
  var init_md034 = __esm({
10156
10107
  "node_modules/markdownlint/lib/md034.mjs"() {
10157
10108
  "use strict";
10158
- import_helpers28 = __toESM(require_helpers(), 1);
10109
+ import_helpers35 = __toESM(require_helpers(), 1);
10159
10110
  import_micromark_helpers21 = __toESM(require_micromark_helpers(), 1);
10160
10111
  md034_default = {
10161
10112
  "names": ["MD034", "no-bare-urls"],
@@ -10216,7 +10167,7 @@ var init_md034 = __esm({
10216
10167
  "deleteCount": range[1],
10217
10168
  "insertText": `<${token.text}>`
10218
10169
  };
10219
- (0, import_helpers28.addErrorContext)(
10170
+ (0, import_helpers35.addErrorContext)(
10220
10171
  onError,
10221
10172
  token.startLine,
10222
10173
  token.text,
@@ -10232,11 +10183,11 @@ var init_md034 = __esm({
10232
10183
  });
10233
10184
 
10234
10185
  // node_modules/markdownlint/lib/md035.mjs
10235
- var import_helpers29, md035_default;
10186
+ var import_helpers36, md035_default;
10236
10187
  var init_md035 = __esm({
10237
10188
  "node_modules/markdownlint/lib/md035.mjs"() {
10238
10189
  "use strict";
10239
- import_helpers29 = __toESM(require_helpers(), 1);
10190
+ import_helpers36 = __toESM(require_helpers(), 1);
10240
10191
  init_cache();
10241
10192
  md035_default = {
10242
10193
  "names": ["MD035", "hr-style"],
@@ -10251,7 +10202,7 @@ var init_md035 = __esm({
10251
10202
  if (style === "consistent") {
10252
10203
  style = text4;
10253
10204
  }
10254
- (0, import_helpers29.addErrorDetailIf)(onError, startLine, style, text4);
10205
+ (0, import_helpers36.addErrorDetailIf)(onError, startLine, style, text4);
10255
10206
  }
10256
10207
  }
10257
10208
  };
@@ -10259,11 +10210,11 @@ var init_md035 = __esm({
10259
10210
  });
10260
10211
 
10261
10212
  // node_modules/markdownlint/lib/md036.mjs
10262
- var import_helpers30, import_micromark_helpers22, emphasisTypes, md036_default;
10213
+ var import_helpers37, import_micromark_helpers22, emphasisTypes, md036_default;
10263
10214
  var init_md036 = __esm({
10264
10215
  "node_modules/markdownlint/lib/md036.mjs"() {
10265
10216
  "use strict";
10266
- import_helpers30 = __toESM(require_helpers(), 1);
10217
+ import_helpers37 = __toESM(require_helpers(), 1);
10267
10218
  import_micromark_helpers22 = __toESM(require_micromark_helpers(), 1);
10268
10219
  init_cache();
10269
10220
  emphasisTypes = [
@@ -10277,7 +10228,7 @@ var init_md036 = __esm({
10277
10228
  "parser": "micromark",
10278
10229
  "function": function MD036(params2, onError) {
10279
10230
  let punctuation = params2.config.punctuation;
10280
- punctuation = String(punctuation === void 0 ? import_helpers30.allPunctuation : punctuation);
10231
+ punctuation = String(punctuation === void 0 ? import_helpers37.allPunctuation : punctuation);
10281
10232
  const punctuationRe = new RegExp("[" + punctuation + "]$");
10282
10233
  const paragraphTokens = filterByTypesCached(["paragraph"]).filter(
10283
10234
  (token) => {
@@ -10289,7 +10240,7 @@ var init_md036 = __esm({
10289
10240
  const textTokens = (0, import_micromark_helpers22.getDescendantsByType)(paragraphTokens, emphasisType);
10290
10241
  for (const textToken of textTokens) {
10291
10242
  if (textToken.children.length === 1 && textToken.children[0].type === "data" && !punctuationRe.test(textToken.text)) {
10292
- (0, import_helpers30.addErrorContext)(onError, textToken.startLine, textToken.text);
10243
+ (0, import_helpers37.addErrorContext)(onError, textToken.startLine, textToken.text);
10293
10244
  }
10294
10245
  }
10295
10246
  }
@@ -10299,11 +10250,11 @@ var init_md036 = __esm({
10299
10250
  });
10300
10251
 
10301
10252
  // node_modules/markdownlint/lib/md037.mjs
10302
- var import_helpers31, import_micromark_helpers23, md037_default;
10253
+ var import_helpers38, import_micromark_helpers23, md037_default;
10303
10254
  var init_md037 = __esm({
10304
10255
  "node_modules/markdownlint/lib/md037.mjs"() {
10305
10256
  "use strict";
10306
- import_helpers31 = __toESM(require_helpers(), 1);
10257
+ import_helpers38 = __toESM(require_helpers(), 1);
10307
10258
  import_micromark_helpers23 = __toESM(require_micromark_helpers(), 1);
10308
10259
  md037_default = {
10309
10260
  "names": ["MD037", "no-space-in-emphasis"],
@@ -10343,7 +10294,7 @@ var init_md037 = __esm({
10343
10294
  if (startMatch) {
10344
10295
  const [startSpaceCharacter] = startMatch;
10345
10296
  const startContext = `${marker}${startSpaceCharacter}`;
10346
- (0, import_helpers31.addError)(
10297
+ (0, import_helpers38.addError)(
10347
10298
  onError,
10348
10299
  startToken.startLine,
10349
10300
  void 0,
@@ -10362,7 +10313,7 @@ var init_md037 = __esm({
10362
10313
  if (endMatch) {
10363
10314
  const [endSpaceCharacter] = endMatch;
10364
10315
  const endContext = `${endSpaceCharacter}${marker}`;
10365
- (0, import_helpers31.addError)(
10316
+ (0, import_helpers38.addError)(
10366
10317
  onError,
10367
10318
  endToken.startLine,
10368
10319
  void 0,
@@ -10383,11 +10334,11 @@ var init_md037 = __esm({
10383
10334
  });
10384
10335
 
10385
10336
  // node_modules/markdownlint/lib/md038.mjs
10386
- var import_helpers32, import_micromark_helpers24, leftSpaceRe, rightSpaceRe, trimCodeText, md038_default;
10337
+ var import_helpers39, import_micromark_helpers24, leftSpaceRe, rightSpaceRe, trimCodeText, md038_default;
10387
10338
  var init_md038 = __esm({
10388
10339
  "node_modules/markdownlint/lib/md038.mjs"() {
10389
10340
  "use strict";
10390
- import_helpers32 = __toESM(require_helpers(), 1);
10341
+ import_helpers39 = __toESM(require_helpers(), 1);
10391
10342
  import_micromark_helpers24 = __toESM(require_micromark_helpers(), 1);
10392
10343
  init_cache();
10393
10344
  leftSpaceRe = /^\s(?:[^`]|$)/;
@@ -10457,7 +10408,7 @@ var init_md038 = __esm({
10457
10408
  }
10458
10409
  if (range) {
10459
10410
  const context = params2.lines[lineNumber - 1].substring(range[0] - 1, range[0] - 1 + range[1]);
10460
- (0, import_helpers32.addErrorContext)(
10411
+ (0, import_helpers39.addErrorContext)(
10461
10412
  onError,
10462
10413
  lineNumber,
10463
10414
  context,
@@ -10482,7 +10433,7 @@ function addLabelSpaceError(onError, label4, labelText, isStart) {
10482
10433
  isStart ? labelText.startColumn : labelText.endColumn - match[0].length,
10483
10434
  match[0].length
10484
10435
  ] : void 0;
10485
- (0, import_helpers33.addErrorContext)(
10436
+ (0, import_helpers40.addErrorContext)(
10486
10437
  onError,
10487
10438
  isStart ? labelText.startLine + (match ? 0 : 1) : labelText.endLine - (match ? 0 : 1),
10488
10439
  label4.text.replace(/\s+/g, " "),
@@ -10495,11 +10446,11 @@ function addLabelSpaceError(onError, label4, labelText, isStart) {
10495
10446
  } : void 0
10496
10447
  );
10497
10448
  }
10498
- var import_helpers33, md039_default;
10449
+ var import_helpers40, md039_default;
10499
10450
  var init_md039 = __esm({
10500
10451
  "node_modules/markdownlint/lib/md039.mjs"() {
10501
10452
  "use strict";
10502
- import_helpers33 = __toESM(require_helpers(), 1);
10453
+ import_helpers40 = __toESM(require_helpers(), 1);
10503
10454
  init_cache();
10504
10455
  md039_default = {
10505
10456
  "names": ["MD039", "no-space-in-links"],
@@ -10528,11 +10479,11 @@ var init_md039 = __esm({
10528
10479
  });
10529
10480
 
10530
10481
  // node_modules/markdownlint/lib/md040.mjs
10531
- var import_helpers34, import_micromark_helpers25, md040_default;
10482
+ var import_helpers41, import_micromark_helpers25, md040_default;
10532
10483
  var init_md040 = __esm({
10533
10484
  "node_modules/markdownlint/lib/md040.mjs"() {
10534
10485
  "use strict";
10535
- import_helpers34 = __toESM(require_helpers(), 1);
10486
+ import_helpers41 = __toESM(require_helpers(), 1);
10536
10487
  import_micromark_helpers25 = __toESM(require_micromark_helpers(), 1);
10537
10488
  init_cache();
10538
10489
  md040_default = {
@@ -10551,12 +10502,12 @@ var init_md040 = __esm({
10551
10502
  const { startLine, text: text4 } = openingFence;
10552
10503
  const info = (_a = (0, import_micromark_helpers25.getDescendantsByType)(openingFence, ["codeFencedFenceInfo"])[0]) == null ? void 0 : _a.text;
10553
10504
  if (!info) {
10554
- (0, import_helpers34.addErrorContext)(onError, startLine, text4);
10505
+ (0, import_helpers41.addErrorContext)(onError, startLine, text4);
10555
10506
  } else if (allowed.length > 0 && !allowed.includes(info)) {
10556
- (0, import_helpers34.addError)(onError, startLine, `"${info}" is not allowed`);
10507
+ (0, import_helpers41.addError)(onError, startLine, `"${info}" is not allowed`);
10557
10508
  }
10558
10509
  if (languageOnly && (0, import_micromark_helpers25.getDescendantsByType)(openingFence, ["codeFencedFenceMeta"]).length > 0) {
10559
- (0, import_helpers34.addError)(onError, startLine, `Info string contains more than language: "${text4}"`);
10510
+ (0, import_helpers41.addError)(onError, startLine, `Info string contains more than language: "${text4}"`);
10560
10511
  }
10561
10512
  }
10562
10513
  }
@@ -10565,11 +10516,11 @@ var init_md040 = __esm({
10565
10516
  });
10566
10517
 
10567
10518
  // node_modules/markdownlint/lib/md041.mjs
10568
- var import_helpers35, import_micromark_helpers26, md041_default;
10519
+ var import_helpers42, import_micromark_helpers26, md041_default;
10569
10520
  var init_md041 = __esm({
10570
10521
  "node_modules/markdownlint/lib/md041.mjs"() {
10571
10522
  "use strict";
10572
- import_helpers35 = __toESM(require_helpers(), 1);
10523
+ import_helpers42 = __toESM(require_helpers(), 1);
10573
10524
  import_micromark_helpers26 = __toESM(require_micromark_helpers(), 1);
10574
10525
  md041_default = {
10575
10526
  "names": ["MD041", "first-line-heading", "first-line-h1"],
@@ -10578,7 +10529,7 @@ var init_md041 = __esm({
10578
10529
  "parser": "micromark",
10579
10530
  "function": function MD041(params2, onError) {
10580
10531
  const level = Number(params2.config.level || 1);
10581
- if (!(0, import_helpers35.frontMatterHasTitle)(params2.frontMatterLines, params2.config.front_matter_title)) {
10532
+ if (!(0, import_helpers42.frontMatterHasTitle)(params2.frontMatterLines, params2.config.front_matter_title)) {
10582
10533
  params2.parsers.micromark.tokens.filter((token) => !import_micromark_helpers26.nonContentTokens.has(token.type) && !(0, import_micromark_helpers26.isHtmlFlowComment)(token)).every((token) => {
10583
10534
  let isError = true;
10584
10535
  if (token.type === "atxHeading" || token.type === "setextHeading") {
@@ -10589,7 +10540,7 @@ var init_md041 = __esm({
10589
10540
  isError = !tagInfo || tagInfo.name.toLowerCase() !== `h${level}`;
10590
10541
  }
10591
10542
  if (isError) {
10592
- (0, import_helpers35.addErrorContext)(onError, token.startLine, params2.lines[token.startLine - 1]);
10543
+ (0, import_helpers42.addErrorContext)(onError, token.startLine, params2.lines[token.startLine - 1]);
10593
10544
  }
10594
10545
  return false;
10595
10546
  });
@@ -10600,11 +10551,11 @@ var init_md041 = __esm({
10600
10551
  });
10601
10552
 
10602
10553
  // node_modules/markdownlint/lib/md042.mjs
10603
- var import_helpers36, import_micromark_helpers27, md042_default;
10554
+ var import_helpers43, import_micromark_helpers27, md042_default;
10604
10555
  var init_md042 = __esm({
10605
10556
  "node_modules/markdownlint/lib/md042.mjs"() {
10606
10557
  "use strict";
10607
- import_helpers36 = __toESM(require_helpers(), 1);
10558
+ import_helpers43 = __toESM(require_helpers(), 1);
10608
10559
  import_micromark_helpers27 = __toESM(require_micromark_helpers(), 1);
10609
10560
  init_cache();
10610
10561
  md042_default = {
@@ -10641,7 +10592,7 @@ var init_md042 = __esm({
10641
10592
  error = true;
10642
10593
  }
10643
10594
  if (error) {
10644
- (0, import_helpers36.addErrorContext)(
10595
+ (0, import_helpers43.addErrorContext)(
10645
10596
  onError,
10646
10597
  link.startLine,
10647
10598
  link.text,
@@ -10657,11 +10608,11 @@ var init_md042 = __esm({
10657
10608
  });
10658
10609
 
10659
10610
  // node_modules/markdownlint/lib/md043.mjs
10660
- var import_helpers37, import_micromark_helpers28, md043_default;
10611
+ var import_helpers44, import_micromark_helpers28, md043_default;
10661
10612
  var init_md043 = __esm({
10662
10613
  "node_modules/markdownlint/lib/md043.mjs"() {
10663
10614
  "use strict";
10664
- import_helpers37 = __toESM(require_helpers(), 1);
10615
+ import_helpers44 = __toESM(require_helpers(), 1);
10665
10616
  import_micromark_helpers28 = __toESM(require_micromark_helpers(), 1);
10666
10617
  init_cache();
10667
10618
  md043_default = {
@@ -10701,7 +10652,7 @@ var init_md043 = __esm({
10701
10652
  } else if (matchAny) {
10702
10653
  i--;
10703
10654
  } else {
10704
- (0, import_helpers37.addErrorDetailIf)(
10655
+ (0, import_helpers44.addErrorDetailIf)(
10705
10656
  onError,
10706
10657
  heading.startLine,
10707
10658
  expected,
@@ -10713,7 +10664,7 @@ var init_md043 = __esm({
10713
10664
  }
10714
10665
  const extraHeadings = requiredHeadings.length - i;
10715
10666
  if (!hasError && (extraHeadings > 1 || extraHeadings === 1 && requiredHeadings[i] !== "*") && (anyHeadings || !requiredHeadings.every((heading) => heading === "*"))) {
10716
- (0, import_helpers37.addErrorContext)(
10667
+ (0, import_helpers44.addErrorContext)(
10717
10668
  onError,
10718
10669
  params2.lines.length,
10719
10670
  requiredHeadings[i]
@@ -11043,8 +10994,7 @@ function factoryLabel(effects, ok, nok, type, markerType, stringType, disallowEo
11043
10994
  contentType: "text",
11044
10995
  previous: previous4
11045
10996
  });
11046
- if (previous4)
11047
- previous4.next = token;
10997
+ if (previous4) previous4.next = token;
11048
10998
  previous4 = token;
11049
10999
  return data(code2);
11050
11000
  }
@@ -11212,8 +11162,7 @@ function tokenizeDirectiveContainer(effects, ok, nok) {
11212
11162
  contentType: "document",
11213
11163
  previous: previous4
11214
11164
  });
11215
- if (previous4)
11216
- previous4.next = token;
11165
+ if (previous4) previous4.next = token;
11217
11166
  previous4 = token;
11218
11167
  return contentContinue(code2);
11219
11168
  }
@@ -11254,8 +11203,7 @@ function tokenizeDirectiveContainer(effects, ok, nok) {
11254
11203
  size++;
11255
11204
  return closingSequence;
11256
11205
  }
11257
- if (size < sizeOpen)
11258
- return nok2(code2);
11206
+ if (size < sizeOpen) return nok2(code2);
11259
11207
  effects2.exit("directiveContainerSequence");
11260
11208
  return factorySpace(effects2, closingSequenceEnd, "whitespace")(code2);
11261
11209
  }
@@ -13943,10 +13891,8 @@ var init_syntax2 = __esm({
13943
13891
  while (code < 123) {
13944
13892
  text[code] = emailAutolink;
13945
13893
  code++;
13946
- if (code === 58)
13947
- code = 65;
13948
- else if (code === 91)
13949
- code = 97;
13894
+ if (code === 58) code = 65;
13895
+ else if (code === 91) code = 97;
13950
13896
  }
13951
13897
  text[43] = emailAutolink;
13952
13898
  text[45] = emailAutolink;
@@ -13983,8 +13929,7 @@ function splice(list2, start, remove, items) {
13983
13929
  parameters.unshift(start, remove);
13984
13930
  list2.splice(...parameters);
13985
13931
  } else {
13986
- if (remove)
13987
- list2.splice(start, remove);
13932
+ if (remove) list2.splice(start, remove);
13988
13933
  while (chunkStart < items.length) {
13989
13934
  parameters = items.slice(chunkStart, chunkStart + 1e4);
13990
13935
  parameters.unshift(start, 0);
@@ -14910,8 +14855,7 @@ var init_splice_buffer = __esm({
14910
14855
  if (index < 0 || index >= this.left.length + this.right.length) {
14911
14856
  throw new RangeError("Cannot access index `" + index + "` in a splice buffer of size `" + (this.left.length + this.right.length) + "`");
14912
14857
  }
14913
- if (index < this.left.length)
14914
- return this.left[index];
14858
+ if (index < this.left.length) return this.left[index];
14915
14859
  return this.right[this.right.length - index + this.left.length - 1];
14916
14860
  }
14917
14861
  /**
@@ -14977,8 +14921,7 @@ var init_splice_buffer = __esm({
14977
14921
  const count = deleteCount || 0;
14978
14922
  this.setCursor(Math.trunc(start));
14979
14923
  const removed = this.right.splice(this.right.length - count, Number.POSITIVE_INFINITY);
14980
- if (items)
14981
- chunkedPush(this.left, items);
14924
+ if (items) chunkedPush(this.left, items);
14982
14925
  return removed.reverse();
14983
14926
  }
14984
14927
  /**
@@ -15058,8 +15001,7 @@ var init_splice_buffer = __esm({
15058
15001
  * Nothing.
15059
15002
  */
15060
15003
  setCursor(n) {
15061
- if (n === this.left.length || n > this.left.length && this.right.length === 0 || n < 0 && this.left.length === 0)
15062
- return;
15004
+ if (n === this.left.length || n > this.left.length && this.right.length === 0 || n < 0 && this.left.length === 0) return;
15063
15005
  if (n < this.left.length) {
15064
15006
  const removed = this.left.splice(n, Number.POSITIVE_INFINITY);
15065
15007
  chunkedPush(this.right, removed.reverse());
@@ -15458,8 +15400,7 @@ function factoryLabel2(effects, ok, nok, type, markerType, stringType) {
15458
15400
  return atBreak(code2);
15459
15401
  }
15460
15402
  effects.consume(code2);
15461
- if (!seen)
15462
- seen = !markdownSpace(code2);
15403
+ if (!seen) seen = !markdownSpace(code2);
15463
15404
  return code2 === 92 ? labelEscape : labelInside;
15464
15405
  }
15465
15406
  function labelEscape(code2) {
@@ -17337,8 +17278,7 @@ function tokenizeGfmFootnoteCall(effects, ok, nok) {
17337
17278
  return callStart;
17338
17279
  }
17339
17280
  function callStart(code2) {
17340
- if (code2 !== 94)
17341
- return nok(code2);
17281
+ if (code2 !== 94) return nok(code2);
17342
17282
  effects.enter("gfmFootnoteCallMarker");
17343
17283
  effects.consume(code2);
17344
17284
  effects.exit("gfmFootnoteCallMarker");
@@ -17636,10 +17576,8 @@ function tokenizeTable(effects, ok, nok) {
17636
17576
  while (index > -1) {
17637
17577
  const type = self2.events[index][1].type;
17638
17578
  if (type === "lineEnding" || // Note: markdown-rs uses `whitespace` instead of `linePrefix`
17639
- type === "linePrefix")
17640
- index--;
17641
- else
17642
- break;
17579
+ type === "linePrefix") index--;
17580
+ else break;
17643
17581
  }
17644
17582
  const tail = index > -1 ? self2.events[index][1].type : null;
17645
17583
  const next = tail === "tableHead" || tail === "tableRow" ? bodyRowStart : headRowBefore;
@@ -18342,8 +18280,7 @@ function syntaxExtension(all, extension) {
18342
18280
  let code2;
18343
18281
  if (right) {
18344
18282
  for (code2 in right) {
18345
- if (!hasOwnProperty.call(left, code2))
18346
- left[code2] = [];
18283
+ if (!hasOwnProperty.call(left, code2)) left[code2] = [];
18347
18284
  const value = right[code2];
18348
18285
  constructs(
18349
18286
  // @ts-expect-error Looks like a list.
@@ -18491,8 +18428,7 @@ function initializeDocument(effects) {
18491
18428
  return effects.check(containerConstruct, thereIsANewContainer, thereIsNoNewContainer)(code2);
18492
18429
  }
18493
18430
  function thereIsANewContainer(code2) {
18494
- if (childFlow)
18495
- closeFlow();
18431
+ if (childFlow) closeFlow();
18496
18432
  exitContainers(continued);
18497
18433
  return documentContinued(code2);
18498
18434
  }
@@ -18512,8 +18448,7 @@ function initializeDocument(effects) {
18512
18448
  }
18513
18449
  function flowStart(code2) {
18514
18450
  if (code2 === null) {
18515
- if (childFlow)
18516
- closeFlow();
18451
+ if (childFlow) closeFlow();
18517
18452
  exitContainers(0);
18518
18453
  effects.consume(code2);
18519
18454
  return;
@@ -18545,11 +18480,9 @@ function initializeDocument(effects) {
18545
18480
  }
18546
18481
  function writeToChild(token, endOfFile) {
18547
18482
  const stream = self2.sliceStream(token);
18548
- if (endOfFile)
18549
- stream.push(null);
18483
+ if (endOfFile) stream.push(null);
18550
18484
  token.previous = childToken;
18551
- if (childToken)
18552
- childToken.next = token;
18485
+ if (childToken) childToken.next = token;
18553
18486
  childToken = token;
18554
18487
  childFlow.defineSkip(token.start);
18555
18488
  childFlow.write(stream);
@@ -18761,8 +18694,7 @@ function resolveAllLineSuffixes(events, context) {
18761
18694
  size++;
18762
18695
  bufferIndex--;
18763
18696
  }
18764
- if (bufferIndex)
18765
- break;
18697
+ if (bufferIndex) break;
18766
18698
  bufferIndex = -1;
18767
18699
  } else if (chunk === -2) {
18768
18700
  tabs = true;
@@ -19188,34 +19120,32 @@ function serializeChunks(chunks, expandTabs) {
19188
19120
  let value;
19189
19121
  if (typeof chunk === "string") {
19190
19122
  value = chunk;
19191
- } else
19192
- switch (chunk) {
19193
- case -5: {
19194
- value = "\r";
19195
- break;
19196
- }
19197
- case -4: {
19198
- value = "\n";
19199
- break;
19200
- }
19201
- case -3: {
19202
- value = "\r\n";
19203
- break;
19204
- }
19205
- case -2: {
19206
- value = expandTabs ? " " : " ";
19207
- break;
19208
- }
19209
- case -1: {
19210
- if (!expandTabs && atTab)
19211
- continue;
19212
- value = " ";
19213
- break;
19214
- }
19215
- default: {
19216
- value = String.fromCharCode(chunk);
19217
- }
19123
+ } else switch (chunk) {
19124
+ case -5: {
19125
+ value = "\r";
19126
+ break;
19127
+ }
19128
+ case -4: {
19129
+ value = "\n";
19130
+ break;
19131
+ }
19132
+ case -3: {
19133
+ value = "\r\n";
19134
+ break;
19135
+ }
19136
+ case -2: {
19137
+ value = expandTabs ? " " : " ";
19138
+ break;
19139
+ }
19140
+ case -1: {
19141
+ if (!expandTabs && atTab) continue;
19142
+ value = " ";
19143
+ break;
19218
19144
  }
19145
+ default: {
19146
+ value = String.fromCharCode(chunk);
19147
+ }
19148
+ }
19219
19149
  atTab = chunk === -2;
19220
19150
  result.push(value);
19221
19151
  }
@@ -19334,8 +19264,7 @@ function preprocess() {
19334
19264
  case 9: {
19335
19265
  next = Math.ceil(column / 4) * 4;
19336
19266
  chunks.push(-2);
19337
- while (column++ < next)
19338
- chunks.push(-1);
19267
+ while (column++ < next) chunks.push(-1);
19339
19268
  break;
19340
19269
  }
19341
19270
  case 10: {
@@ -19352,10 +19281,8 @@ function preprocess() {
19352
19281
  startPosition = endPosition + 1;
19353
19282
  }
19354
19283
  if (end) {
19355
- if (atCarriageReturn)
19356
- chunks.push(-5);
19357
- if (buffer)
19358
- chunks.push(buffer);
19284
+ if (atCarriageReturn) chunks.push(-5);
19285
+ if (buffer) chunks.push(buffer);
19359
19286
  chunks.push(null);
19360
19287
  }
19361
19288
  return chunks;
@@ -19581,11 +19508,11 @@ var init_micromark_parse = __esm({
19581
19508
  });
19582
19509
 
19583
19510
  // node_modules/markdownlint/lib/md044.mjs
19584
- var import_helpers38, import_micromark_helpers30, ignoredChildTypes, md044_default;
19511
+ var import_helpers45, import_micromark_helpers30, ignoredChildTypes, md044_default;
19585
19512
  var init_md044 = __esm({
19586
19513
  "node_modules/markdownlint/lib/md044.mjs"() {
19587
19514
  "use strict";
19588
- import_helpers38 = __toESM(require_helpers(), 1);
19515
+ import_helpers45 = __toESM(require_helpers(), 1);
19589
19516
  import_micromark_helpers30 = __toESM(require_micromark_helpers(), 1);
19590
19517
  init_micromark_parse();
19591
19518
  ignoredChildTypes = /* @__PURE__ */ new Set(
@@ -19624,7 +19551,7 @@ var init_md044 = __esm({
19624
19551
  const exclusions = [];
19625
19552
  const scannedTokens = /* @__PURE__ */ new Set();
19626
19553
  for (const name of names) {
19627
- const escapedName = (0, import_helpers38.escapeForRegExp)(name);
19554
+ const escapedName = (0, import_helpers45.escapeForRegExp)(name);
19628
19555
  const startNamePattern = /^\W/.test(name) ? "" : "\\b_*";
19629
19556
  const endNamePattern = /\W$/.test(name) ? "" : "_*\\b";
19630
19557
  const namePattern = `(${startNamePattern})(${escapedName})${endNamePattern}`;
@@ -19642,7 +19569,7 @@ var init_md044 = __esm({
19642
19569
  "endLine": lineNumber,
19643
19570
  "endColumn": column + length - 1
19644
19571
  };
19645
- if (!names.includes(nameMatch) && !exclusions.some((exclusion) => (0, import_helpers38.hasOverlap)(exclusion, nameRange))) {
19572
+ if (!names.includes(nameMatch) && !exclusions.some((exclusion) => (0, import_helpers45.hasOverlap)(exclusion, nameRange))) {
19646
19573
  let autolinkRanges = [];
19647
19574
  if (!scannedTokens.has(token)) {
19648
19575
  autolinkRanges = (0, import_micromark_helpers30.filterByTypes)(parse2(token.text), ["literalAutolink"]).map((tok) => ({
@@ -19654,8 +19581,8 @@ var init_md044 = __esm({
19654
19581
  exclusions.push(...autolinkRanges);
19655
19582
  scannedTokens.add(token);
19656
19583
  }
19657
- if (!autolinkRanges.some((autolinkRange) => (0, import_helpers38.hasOverlap)(autolinkRange, nameRange))) {
19658
- (0, import_helpers38.addErrorDetailIf)(
19584
+ if (!autolinkRanges.some((autolinkRange) => (0, import_helpers45.hasOverlap)(autolinkRange, nameRange))) {
19585
+ (0, import_helpers45.addErrorDetailIf)(
19659
19586
  onError,
19660
19587
  token.startLine,
19661
19588
  name,
@@ -19681,14 +19608,14 @@ var init_md044 = __esm({
19681
19608
  });
19682
19609
 
19683
19610
  // node_modules/markdownlint/lib/md045.mjs
19684
- var import_helpers39, import_micromark_helpers31, altRe, md045_default;
19611
+ var import_helpers46, import_micromark_helpers31, altRe, md045_default;
19685
19612
  var init_md045 = __esm({
19686
19613
  "node_modules/markdownlint/lib/md045.mjs"() {
19687
19614
  "use strict";
19688
- import_helpers39 = __toESM(require_helpers(), 1);
19615
+ import_helpers46 = __toESM(require_helpers(), 1);
19689
19616
  import_micromark_helpers31 = __toESM(require_micromark_helpers(), 1);
19690
19617
  init_cache();
19691
- altRe = (0, import_helpers39.getHtmlAttributeRe)("alt");
19618
+ altRe = (0, import_helpers46.getHtmlAttributeRe)("alt");
19692
19619
  md045_default = {
19693
19620
  "names": ["MD045", "no-alt-text"],
19694
19621
  "description": "Images should have alternate text (alt text)",
@@ -19700,7 +19627,7 @@ var init_md045 = __esm({
19700
19627
  const labelTexts = (0, import_micromark_helpers31.getDescendantsByType)(image, ["label", "labelText"]);
19701
19628
  if (labelTexts.some((labelText) => labelText.text.length === 0)) {
19702
19629
  const range = image.startLine === image.endLine ? [image.startColumn, image.endColumn - image.startColumn] : void 0;
19703
- (0, import_helpers39.addError)(
19630
+ (0, import_helpers46.addError)(
19704
19631
  onError,
19705
19632
  image.startLine,
19706
19633
  void 0,
@@ -19716,9 +19643,9 @@ var init_md045 = __esm({
19716
19643
  if (htmlTagInfo && !htmlTagInfo.close && htmlTagInfo.name.toLowerCase() === "img" && !altRe.test(text4)) {
19717
19644
  const range = [
19718
19645
  startColumn,
19719
- text4.replace(import_helpers39.nextLinesRe, "").length
19646
+ text4.replace(import_helpers46.nextLinesRe, "").length
19720
19647
  ];
19721
- (0, import_helpers39.addError)(
19648
+ (0, import_helpers46.addError)(
19722
19649
  onError,
19723
19650
  startLine,
19724
19651
  void 0,
@@ -19733,11 +19660,11 @@ var init_md045 = __esm({
19733
19660
  });
19734
19661
 
19735
19662
  // node_modules/markdownlint/lib/md046.mjs
19736
- var import_helpers40, tokenTypeToStyle, md046_default;
19663
+ var import_helpers47, tokenTypeToStyle, md046_default;
19737
19664
  var init_md046 = __esm({
19738
19665
  "node_modules/markdownlint/lib/md046.mjs"() {
19739
19666
  "use strict";
19740
- import_helpers40 = __toESM(require_helpers(), 1);
19667
+ import_helpers47 = __toESM(require_helpers(), 1);
19741
19668
  init_cache();
19742
19669
  tokenTypeToStyle = {
19743
19670
  "codeFenced": "fenced",
@@ -19755,7 +19682,7 @@ var init_md046 = __esm({
19755
19682
  if (expectedStyle === "consistent") {
19756
19683
  expectedStyle = tokenTypeToStyle[type];
19757
19684
  }
19758
- (0, import_helpers40.addErrorDetailIf)(
19685
+ (0, import_helpers47.addErrorDetailIf)(
19759
19686
  onError,
19760
19687
  startLine,
19761
19688
  expectedStyle,
@@ -19768,11 +19695,11 @@ var init_md046 = __esm({
19768
19695
  });
19769
19696
 
19770
19697
  // node_modules/markdownlint/lib/md047.mjs
19771
- var import_helpers41, md047_default;
19698
+ var import_helpers48, md047_default;
19772
19699
  var init_md047 = __esm({
19773
19700
  "node_modules/markdownlint/lib/md047.mjs"() {
19774
19701
  "use strict";
19775
- import_helpers41 = __toESM(require_helpers(), 1);
19702
+ import_helpers48 = __toESM(require_helpers(), 1);
19776
19703
  md047_default = {
19777
19704
  "names": ["MD047", "single-trailing-newline"],
19778
19705
  "description": "Files should end with a single newline character",
@@ -19781,8 +19708,8 @@ var init_md047 = __esm({
19781
19708
  "function": function MD047(params2, onError) {
19782
19709
  const lastLineNumber = params2.lines.length;
19783
19710
  const lastLine = params2.lines[lastLineNumber - 1];
19784
- if (!(0, import_helpers41.isBlankLine)(lastLine)) {
19785
- (0, import_helpers41.addError)(
19711
+ if (!(0, import_helpers48.isBlankLine)(lastLine)) {
19712
+ (0, import_helpers48.addError)(
19786
19713
  onError,
19787
19714
  lastLineNumber,
19788
19715
  void 0,
@@ -19808,11 +19735,11 @@ function fencedCodeBlockStyleFor(markup) {
19808
19735
  return "backtick";
19809
19736
  }
19810
19737
  }
19811
- var import_helpers42, import_micromark_helpers32, md048_default;
19738
+ var import_helpers49, import_micromark_helpers32, md048_default;
19812
19739
  var init_md048 = __esm({
19813
19740
  "node_modules/markdownlint/lib/md048.mjs"() {
19814
19741
  "use strict";
19815
- import_helpers42 = __toESM(require_helpers(), 1);
19742
+ import_helpers49 = __toESM(require_helpers(), 1);
19816
19743
  import_micromark_helpers32 = __toESM(require_micromark_helpers(), 1);
19817
19744
  init_cache();
19818
19745
  md048_default = {
@@ -19830,7 +19757,7 @@ var init_md048 = __esm({
19830
19757
  if (expectedStyle === "consistent") {
19831
19758
  expectedStyle = fencedCodeBlockStyleFor(text4);
19832
19759
  }
19833
- (0, import_helpers42.addErrorDetailIf)(
19760
+ (0, import_helpers49.addErrorDetailIf)(
19834
19761
  onError,
19835
19762
  startLine,
19836
19763
  expectedStyle,
@@ -19851,11 +19778,11 @@ function emphasisOrStrongStyleFor(markup) {
19851
19778
  return "underscore";
19852
19779
  }
19853
19780
  }
19854
- var import_helpers43, import_micromark_helpers33, intrawordRe, impl, md049_md050_default;
19781
+ var import_helpers50, import_micromark_helpers33, intrawordRe, impl, md049_md050_default;
19855
19782
  var init_md049_md050 = __esm({
19856
19783
  "node_modules/markdownlint/lib/md049-md050.mjs"() {
19857
19784
  "use strict";
19858
- import_helpers43 = __toESM(require_helpers(), 1);
19785
+ import_helpers50 = __toESM(require_helpers(), 1);
19859
19786
  import_micromark_helpers33 = __toESM(require_micromark_helpers(), 1);
19860
19787
  intrawordRe = /^\w$/;
19861
19788
  impl = (params2, onError, type, typeSequence, asterisk, underline, style = "consistent") => {
@@ -19882,7 +19809,7 @@ var init_md049_md050 = __esm({
19882
19809
  ));
19883
19810
  if (!underscoreIntraword) {
19884
19811
  for (const sequence of [startSequence, endSequence]) {
19885
- (0, import_helpers43.addError)(
19812
+ (0, import_helpers50.addError)(
19886
19813
  onError,
19887
19814
  sequence.startLine,
19888
19815
  `Expected: ${style}; Actual: ${markupStyle}`,
@@ -19956,15 +19883,15 @@ function convertHeadingToHTMLFragment(headingText) {
19956
19883
  function unescapeStringTokenText(token) {
19957
19884
  return (0, import_micromark_helpers34.filterByTypes)(token.children, ["characterEscapeValue", "data"]).map((child) => child.text).join("");
19958
19885
  }
19959
- var import_helpers44, import_micromark_helpers34, idRe, nameRe, anchorRe, lineFragmentRe, childrenExclude, tokensInclude, md051_default;
19886
+ var import_helpers51, import_micromark_helpers34, idRe, nameRe, anchorRe, lineFragmentRe, childrenExclude, tokensInclude, md051_default;
19960
19887
  var init_md051 = __esm({
19961
19888
  "node_modules/markdownlint/lib/md051.mjs"() {
19962
19889
  "use strict";
19963
- import_helpers44 = __toESM(require_helpers(), 1);
19890
+ import_helpers51 = __toESM(require_helpers(), 1);
19964
19891
  import_micromark_helpers34 = __toESM(require_micromark_helpers(), 1);
19965
19892
  init_cache();
19966
- idRe = (0, import_helpers44.getHtmlAttributeRe)("id");
19967
- nameRe = (0, import_helpers44.getHtmlAttributeRe)("name");
19893
+ idRe = (0, import_helpers51.getHtmlAttributeRe)("id");
19894
+ nameRe = (0, import_helpers51.getHtmlAttributeRe)("name");
19968
19895
  anchorRe = /\{(#[a-z\d]+(?:[-_][a-z\d]+)*)\}/gu;
19969
19896
  lineFragmentRe = /^#(?:L\d+(?:C\d+)?-L\d+(?:C\d+)?|L\d+)$/;
19970
19897
  childrenExclude = /* @__PURE__ */ new Set(["image", "reference", "resource"]);
@@ -20035,7 +19962,7 @@ var init_md051 = __esm({
20035
19962
  if (mixedCaseKey) {
20036
19963
  (fixInfo || {}).insertText = mixedCaseKey;
20037
19964
  if (!ignoreCase && mixedCaseKey !== text4) {
20038
- (0, import_helpers44.addError)(
19965
+ (0, import_helpers51.addError)(
20039
19966
  onError,
20040
19967
  link.startLine,
20041
19968
  `Expected: ${mixedCaseKey}; Actual: ${text4}`,
@@ -20045,7 +19972,7 @@ var init_md051 = __esm({
20045
19972
  );
20046
19973
  }
20047
19974
  } else {
20048
- (0, import_helpers44.addError)(
19975
+ (0, import_helpers51.addError)(
20049
19976
  onError,
20050
19977
  link.startLine,
20051
19978
  void 0,
@@ -20063,11 +19990,11 @@ var init_md051 = __esm({
20063
19990
  });
20064
19991
 
20065
19992
  // node_modules/markdownlint/lib/md052.mjs
20066
- var import_helpers45, md052_default;
19993
+ var import_helpers52, md052_default;
20067
19994
  var init_md052 = __esm({
20068
19995
  "node_modules/markdownlint/lib/md052.mjs"() {
20069
19996
  "use strict";
20070
- import_helpers45 = __toESM(require_helpers(), 1);
19997
+ import_helpers52 = __toESM(require_helpers(), 1);
20071
19998
  init_cache();
20072
19999
  md052_default = {
20073
20000
  "names": ["MD052", "reference-links-images"],
@@ -20085,7 +20012,7 @@ var init_md052 = __esm({
20085
20012
  for (const data of datas) {
20086
20013
  const [lineIndex, index, length] = data;
20087
20014
  const context = lines[lineIndex].slice(index, index + length);
20088
- (0, import_helpers45.addError)(
20015
+ (0, import_helpers52.addError)(
20089
20016
  onError,
20090
20017
  lineIndex + 1,
20091
20018
  `Missing link or image reference definition: "${label4}"`,
@@ -20101,11 +20028,11 @@ var init_md052 = __esm({
20101
20028
  });
20102
20029
 
20103
20030
  // node_modules/markdownlint/lib/md053.mjs
20104
- var import_helpers46, linkReferenceDefinitionRe, md053_default;
20031
+ var import_helpers53, linkReferenceDefinitionRe, md053_default;
20105
20032
  var init_md053 = __esm({
20106
20033
  "node_modules/markdownlint/lib/md053.mjs"() {
20107
20034
  "use strict";
20108
- import_helpers46 = __toESM(require_helpers(), 1);
20035
+ import_helpers53 = __toESM(require_helpers(), 1);
20109
20036
  init_cache();
20110
20037
  linkReferenceDefinitionRe = /^ {0,3}\[([^\]]*[^\\])\]:/;
20111
20038
  md053_default = {
@@ -20125,11 +20052,11 @@ var init_md053 = __esm({
20125
20052
  const [label4, [lineIndex]] = definition2;
20126
20053
  if (!ignored.has(label4) && !references.has(label4) && !shortcuts.has(label4)) {
20127
20054
  const line = lines[lineIndex];
20128
- (0, import_helpers46.addError)(
20055
+ (0, import_helpers53.addError)(
20129
20056
  onError,
20130
20057
  lineIndex + 1,
20131
20058
  `Unused link or image reference definition: "${label4}"`,
20132
- (0, import_helpers46.ellipsify)(line),
20059
+ (0, import_helpers53.ellipsify)(line),
20133
20060
  [1, line.length],
20134
20061
  singleLineDefinition(line) ? deleteFixInfo : void 0
20135
20062
  );
@@ -20139,11 +20066,11 @@ var init_md053 = __esm({
20139
20066
  const [label4, lineIndex] = duplicateDefinition;
20140
20067
  if (!ignored.has(label4)) {
20141
20068
  const line = lines[lineIndex];
20142
- (0, import_helpers46.addError)(
20069
+ (0, import_helpers53.addError)(
20143
20070
  onError,
20144
20071
  lineIndex + 1,
20145
20072
  `Duplicate link or image reference definition: "${label4}"`,
20146
- (0, import_helpers46.ellipsify)(line),
20073
+ (0, import_helpers53.ellipsify)(line),
20147
20074
  [1, line.length],
20148
20075
  singleLineDefinition(line) ? deleteFixInfo : void 0
20149
20076
  );
@@ -20155,11 +20082,11 @@ var init_md053 = __esm({
20155
20082
  });
20156
20083
 
20157
20084
  // node_modules/markdownlint/lib/md054.mjs
20158
- var import_helpers47, import_micromark_helpers35, backslashEscapeRe, removeBackslashEscapes, autolinkDisallowedRe, autolinkAble, md054_default;
20085
+ var import_helpers54, import_micromark_helpers35, backslashEscapeRe, removeBackslashEscapes, autolinkDisallowedRe, autolinkAble, md054_default;
20159
20086
  var init_md054 = __esm({
20160
20087
  "node_modules/markdownlint/lib/md054.mjs"() {
20161
20088
  "use strict";
20162
- import_helpers47 = __toESM(require_helpers(), 1);
20089
+ import_helpers54 = __toESM(require_helpers(), 1);
20163
20090
  import_micromark_helpers35 = __toESM(require_micromark_helpers(), 1);
20164
20091
  init_cache();
20165
20092
  backslashEscapeRe = /\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g;
@@ -20248,10 +20175,10 @@ var init_md054 = __esm({
20248
20175
  };
20249
20176
  }
20250
20177
  }
20251
- (0, import_helpers47.addErrorContext)(
20178
+ (0, import_helpers54.addErrorContext)(
20252
20179
  onError,
20253
20180
  startLine,
20254
- text4.replace(import_helpers47.nextLinesRe, ""),
20181
+ text4.replace(import_helpers54.nextLinesRe, ""),
20255
20182
  void 0,
20256
20183
  void 0,
20257
20184
  range,
@@ -20265,11 +20192,11 @@ var init_md054 = __esm({
20265
20192
  });
20266
20193
 
20267
20194
  // node_modules/markdownlint/lib/md055.mjs
20268
- var import_helpers48, whitespaceTypes, ignoreWhitespace, firstOrNothing, lastOrNothing, makeRange, md055_default;
20195
+ var import_helpers55, whitespaceTypes, ignoreWhitespace, firstOrNothing, lastOrNothing, makeRange, md055_default;
20269
20196
  var init_md055 = __esm({
20270
20197
  "node_modules/markdownlint/lib/md055.mjs"() {
20271
20198
  "use strict";
20272
- import_helpers48 = __toESM(require_helpers(), 1);
20199
+ import_helpers55 = __toESM(require_helpers(), 1);
20273
20200
  init_cache();
20274
20201
  whitespaceTypes = /* @__PURE__ */ new Set(["linePrefix", "whitespace"]);
20275
20202
  ignoreWhitespace = (tokens) => tokens.filter(
@@ -20303,7 +20230,7 @@ var init_md055 = __esm({
20303
20230
  expectedTrailingPipe = actualTrailingPipe;
20304
20231
  }
20305
20232
  if (actualLeadingPipe !== expectedLeadingPipe) {
20306
- (0, import_helpers48.addErrorDetailIf)(
20233
+ (0, import_helpers55.addErrorDetailIf)(
20307
20234
  onError,
20308
20235
  firstCell.startLine,
20309
20236
  expectedStyle,
@@ -20314,7 +20241,7 @@ var init_md055 = __esm({
20314
20241
  );
20315
20242
  }
20316
20243
  if (actualTrailingPipe !== expectedTrailingPipe) {
20317
- (0, import_helpers48.addErrorDetailIf)(
20244
+ (0, import_helpers55.addErrorDetailIf)(
20318
20245
  onError,
20319
20246
  lastCell.endLine,
20320
20247
  expectedStyle,
@@ -20331,11 +20258,11 @@ var init_md055 = __esm({
20331
20258
  });
20332
20259
 
20333
20260
  // node_modules/markdownlint/lib/md056.mjs
20334
- var import_helpers49, import_micromark_helpers36, makeRange2, md056_default;
20261
+ var import_helpers56, import_micromark_helpers36, makeRange2, md056_default;
20335
20262
  var init_md056 = __esm({
20336
20263
  "node_modules/markdownlint/lib/md056.mjs"() {
20337
20264
  "use strict";
20338
- import_helpers49 = __toESM(require_helpers(), 1);
20265
+ import_helpers56 = __toESM(require_helpers(), 1);
20339
20266
  import_micromark_helpers36 = __toESM(require_micromark_helpers(), 1);
20340
20267
  init_cache();
20341
20268
  makeRange2 = (start, end) => [start, end - start + 1];
@@ -20366,7 +20293,7 @@ var init_md056 = __esm({
20366
20293
  detail = "Too many cells, extra data will be missing";
20367
20294
  range = makeRange2(cells[expectedCount].startColumn, row.endColumn - 1);
20368
20295
  }
20369
- (0, import_helpers49.addErrorDetailIf)(
20296
+ (0, import_helpers56.addErrorDetailIf)(
20370
20297
  onError,
20371
20298
  row.endLine,
20372
20299
  expectedCount,
@@ -20382,11 +20309,11 @@ var init_md056 = __esm({
20382
20309
  });
20383
20310
 
20384
20311
  // node_modules/markdownlint/lib/md058.mjs
20385
- var import_helpers50, import_micromark_helpers37, md058_default;
20312
+ var import_helpers57, import_micromark_helpers37, md058_default;
20386
20313
  var init_md058 = __esm({
20387
20314
  "node_modules/markdownlint/lib/md058.mjs"() {
20388
20315
  "use strict";
20389
- import_helpers50 = __toESM(require_helpers(), 1);
20316
+ import_helpers57 = __toESM(require_helpers(), 1);
20390
20317
  import_micromark_helpers37 = __toESM(require_micromark_helpers(), 1);
20391
20318
  init_cache();
20392
20319
  md058_default = {
@@ -20400,8 +20327,8 @@ var init_md058 = __esm({
20400
20327
  const tables = filterByTypesCached(["table"]);
20401
20328
  for (const table of tables) {
20402
20329
  const firstLineNumber = table.startLine;
20403
- if (!(0, import_helpers50.isBlankLine)(lines[firstLineNumber - 2])) {
20404
- (0, import_helpers50.addErrorContext)(
20330
+ if (!(0, import_helpers57.isBlankLine)(lines[firstLineNumber - 2])) {
20331
+ (0, import_helpers57.addErrorContext)(
20405
20332
  onError,
20406
20333
  firstLineNumber,
20407
20334
  lines[firstLineNumber - 1].trim(),
@@ -20414,8 +20341,8 @@ var init_md058 = __esm({
20414
20341
  );
20415
20342
  }
20416
20343
  const lastLineNumber = table.endLine;
20417
- if (!(0, import_helpers50.isBlankLine)(lines[lastLineNumber])) {
20418
- (0, import_helpers50.addErrorContext)(
20344
+ if (!(0, import_helpers57.isBlankLine)(lines[lastLineNumber])) {
20345
+ (0, import_helpers57.addErrorContext)(
20419
20346
  onError,
20420
20347
  lastLineNumber,
20421
20348
  lines[lastLineNumber - 1].trim(),
@@ -21333,15 +21260,15 @@ var init_exports_promise = __esm({
21333
21260
  });
21334
21261
 
21335
21262
  // src/index.ts
21336
- var src_exports = {};
21337
- __export(src_exports, {
21263
+ var index_exports = {};
21264
+ __export(index_exports, {
21338
21265
  LogLevels: () => LogLevels,
21339
21266
  getLogLevel: () => getLogLevel,
21340
21267
  log: () => log,
21341
21268
  normalizeConfig: () => normalizeConfig,
21342
21269
  yfmlint: () => yfmlint
21343
21270
  });
21344
- module.exports = __toCommonJS(src_exports);
21271
+ module.exports = __toCommonJS(index_exports);
21345
21272
  var import_markdown_it_attrs = __toESM(require_markdown_it_attrs());
21346
21273
 
21347
21274
  // src/utils.ts
@@ -21555,6 +21482,93 @@ var yfm001 = {
21555
21482
  }
21556
21483
  };
21557
21484
 
21485
+ // src/rules/helpers.ts
21486
+ function validateLineNumberAndGetFilePath(params2, rawLineNumber) {
21487
+ const linesCount = params2.lines.length;
21488
+ const lineNumber = Math.min(Math.max(1, rawLineNumber || 1), linesCount);
21489
+ const env = params2.parsers.markdownit.env;
21490
+ const filePath = (env == null ? void 0 : env.path) || params2.name;
21491
+ return { lineNumber, filePath };
21492
+ }
21493
+ function createContextWithFileInfo(baseContext, filePath, paramsName) {
21494
+ const parts = [baseContext];
21495
+ if (filePath !== paramsName) {
21496
+ parts.push(`File: ${filePath}`);
21497
+ }
21498
+ return parts.filter(Boolean).join("; ");
21499
+ }
21500
+ function findLinksInInlineTokens(params2, ruleName, onError, handler) {
21501
+ params2.parsers.markdownit.tokens.filter((token) => token.type === "inline").forEach((inline) => {
21502
+ var _a;
21503
+ (_a = inline.children) == null ? void 0 : _a.filter((child) => child && child.type === "link_open").forEach((link) => {
21504
+ const linkToken = link;
21505
+ if (linkToken.attrGet(ruleName)) {
21506
+ if (handler) {
21507
+ handler(linkToken, inline);
21508
+ } else {
21509
+ const rawLineNumber = link.lineNumber || inline.lineNumber;
21510
+ const { lineNumber, filePath } = validateLineNumberAndGetFilePath(
21511
+ params2,
21512
+ rawLineNumber
21513
+ );
21514
+ const context = createContextWithFileInfo(
21515
+ link.line || inline.line,
21516
+ filePath,
21517
+ params2.name
21518
+ );
21519
+ onError({
21520
+ lineNumber,
21521
+ context
21522
+ });
21523
+ }
21524
+ }
21525
+ });
21526
+ });
21527
+ }
21528
+ function findImagesInInlineTokens(params2, ruleName, onError, handler) {
21529
+ params2.parsers.markdownit.tokens.filter((token) => token.type === "inline").forEach((inline) => {
21530
+ var _a;
21531
+ (_a = inline.children) == null ? void 0 : _a.filter((child) => child && child.type === "image").forEach((image) => {
21532
+ const imageToken = image;
21533
+ if (imageToken.attrGet(ruleName)) {
21534
+ if (handler) {
21535
+ handler(imageToken, inline);
21536
+ } else {
21537
+ const rawLineNumber = image.lineNumber || inline.lineNumber;
21538
+ const { lineNumber, filePath } = validateLineNumberAndGetFilePath(
21539
+ params2,
21540
+ rawLineNumber
21541
+ );
21542
+ const context = createContextWithFileInfo(
21543
+ image.line || inline.line,
21544
+ filePath,
21545
+ params2.name
21546
+ );
21547
+ onError({
21548
+ lineNumber,
21549
+ context
21550
+ });
21551
+ }
21552
+ }
21553
+ });
21554
+ });
21555
+ }
21556
+ function findYfmLintTokens(params2, ruleName, onError, handler) {
21557
+ params2.parsers.markdownit.tokens.filter((token) => token.type === "__yfm_lint").forEach((token) => {
21558
+ const yfmLintToken = token;
21559
+ if (yfmLintToken.attrGet(ruleName)) {
21560
+ if (handler) {
21561
+ handler(yfmLintToken);
21562
+ } else {
21563
+ onError({
21564
+ lineNumber: token.lineNumber,
21565
+ context: token.line
21566
+ });
21567
+ }
21568
+ }
21569
+ });
21570
+ }
21571
+
21558
21572
  // src/rules/yfm002.ts
21559
21573
  var yfm002 = {
21560
21574
  names: ["YFM002", "no-header-found-for-link"],
@@ -21566,21 +21580,7 @@ var yfm002 = {
21566
21580
  if (!config) {
21567
21581
  return;
21568
21582
  }
21569
- params2.parsers.markdownit.tokens.filter((token) => {
21570
- return token.type === "inline";
21571
- }).forEach((inline) => {
21572
- var _a;
21573
- (_a = inline.children) == null ? void 0 : _a.filter((child) => {
21574
- return child.type === "link_open";
21575
- }).forEach((link) => {
21576
- if (link.attrGet("YFM002")) {
21577
- onError({
21578
- lineNumber: link.lineNumber,
21579
- context: link.line
21580
- });
21581
- }
21582
- });
21583
- });
21583
+ findLinksInInlineTokens(params2, "YFM002", onError);
21584
21584
  }
21585
21585
  };
21586
21586
 
@@ -21600,28 +21600,27 @@ var yfm003 = {
21600
21600
  if (!config) {
21601
21601
  return;
21602
21602
  }
21603
- params2.parsers.markdownit.tokens.filter((token) => {
21604
- return token.type === "inline";
21605
- }).forEach((inline) => {
21606
- var _a;
21607
- (_a = inline.children) == null ? void 0 : _a.filter((child) => {
21608
- return child && child.type === "link_open";
21609
- }).forEach((link) => {
21610
- const linkToken = link;
21611
- const reason = linkToken.attrGet("YFM003");
21612
- if (reason) {
21613
- const reasonDescription = typeof reason === "string" && REASON_DESCRIPTION[reason] ? `Reason: ${REASON_DESCRIPTION[reason]}` : "";
21614
- const context = [
21615
- `Unreachable link: "${linkToken.attrGet("href")}"`,
21616
- reasonDescription,
21617
- `Line: ${link.line || inline.line}`
21618
- ].filter(Boolean).join("; ");
21619
- onError({
21620
- lineNumber: link.lineNumber || inline.lineNumber,
21621
- context
21622
- });
21623
- }
21624
- });
21603
+ findLinksInInlineTokens(params2, "YFM003", onError, (linkToken, inline) => {
21604
+ const reason = linkToken.attrGet("YFM003");
21605
+ if (reason) {
21606
+ const reasonDescription = typeof reason === "string" && REASON_DESCRIPTION[reason] ? `Reason: ${REASON_DESCRIPTION[reason]}` : "";
21607
+ const rawLineNumber = linkToken.lineNumber || inline.lineNumber;
21608
+ const { lineNumber, filePath } = validateLineNumberAndGetFilePath(
21609
+ params2,
21610
+ rawLineNumber
21611
+ );
21612
+ const baseContext = [
21613
+ `Unreachable link: "${linkToken.attrGet("href")}"`,
21614
+ reasonDescription,
21615
+ `Line: ${rawLineNumber}`
21616
+ // Show original line number for debugging
21617
+ ].filter(Boolean).join("; ");
21618
+ const context = createContextWithFileInfo(baseContext, filePath, params2.name);
21619
+ onError({
21620
+ lineNumber,
21621
+ context
21622
+ });
21623
+ }
21625
21624
  });
21626
21625
  }
21627
21626
  };
@@ -21637,16 +21636,7 @@ var yfm004 = {
21637
21636
  if (!config) {
21638
21637
  return;
21639
21638
  }
21640
- params2.parsers.markdownit.tokens.filter((token) => {
21641
- return token.type === "__yfm_lint";
21642
- }).forEach((table) => {
21643
- if (table.attrGet("YFM004")) {
21644
- onError({
21645
- lineNumber: table.lineNumber,
21646
- context: table.line
21647
- });
21648
- }
21649
- });
21639
+ findYfmLintTokens(params2, "YFM004", onError);
21650
21640
  }
21651
21641
  };
21652
21642
 
@@ -21661,13 +21651,12 @@ var yfm005 = {
21661
21651
  if (!config) {
21662
21652
  return;
21663
21653
  }
21664
- params2.parsers.markdownit.tokens.filter((token) => {
21665
- return token.type === "paragraph_open";
21666
- }).forEach((table) => {
21667
- if (table.attrGet("YFM005")) {
21654
+ params2.parsers.markdownit.tokens.filter((token) => token.type === "paragraph_open").forEach((token) => {
21655
+ const tokenWithAttrs = token;
21656
+ if (tokenWithAttrs.attrGet("YFM005")) {
21668
21657
  onError({
21669
- lineNumber: table.lineNumber,
21670
- context: table.line
21658
+ lineNumber: token.lineNumber,
21659
+ context: token.line
21671
21660
  });
21672
21661
  }
21673
21662
  });
@@ -21685,16 +21674,7 @@ var yfm006 = {
21685
21674
  if (!config) {
21686
21675
  return;
21687
21676
  }
21688
- params2.parsers.markdownit.tokens.filter((token) => {
21689
- return token.type === "__yfm_lint";
21690
- }).forEach((term) => {
21691
- if (term.attrGet("YFM006")) {
21692
- onError({
21693
- lineNumber: term.lineNumber,
21694
- context: term.line
21695
- });
21696
- }
21697
- });
21677
+ findYfmLintTokens(params2, "YFM006", onError);
21698
21678
  }
21699
21679
  };
21700
21680
 
@@ -21712,10 +21692,9 @@ var yfm007 = {
21712
21692
  params2.parsers.markdownit.tokens.forEach(
21713
21693
  (el) => {
21714
21694
  var _a;
21715
- return (_a = el.children) == null ? void 0 : _a.filter((token) => {
21716
- return token.type === "__yfm_lint";
21717
- }).forEach((term) => {
21718
- if (term.attrGet("YFM007")) {
21695
+ return (_a = el.children) == null ? void 0 : _a.filter((token) => token.type === "__yfm_lint").forEach((term) => {
21696
+ const termToken = term;
21697
+ if (termToken.attrGet("YFM007")) {
21719
21698
  onError({
21720
21699
  lineNumber: term.lineNumber,
21721
21700
  context: term.line
@@ -21738,16 +21717,7 @@ var yfm008 = {
21738
21717
  if (!config) {
21739
21718
  return;
21740
21719
  }
21741
- params2.parsers.markdownit.tokens.filter((token) => {
21742
- return token.type === "__yfm_lint";
21743
- }).forEach((term) => {
21744
- if (term.attrGet("YFM008")) {
21745
- onError({
21746
- lineNumber: term.lineNumber,
21747
- context: term.line
21748
- });
21749
- }
21750
- });
21720
+ findYfmLintTokens(params2, "YFM008", onError);
21751
21721
  }
21752
21722
  };
21753
21723
 
@@ -21758,6 +21728,7 @@ var yfm009 = {
21758
21728
  tags: ["term"],
21759
21729
  parser: "markdownit",
21760
21730
  function: function YFM009(params2, onError) {
21731
+ var _a, _b;
21761
21732
  const { config } = params2;
21762
21733
  if (!config) {
21763
21734
  return;
@@ -21766,23 +21737,23 @@ var yfm009 = {
21766
21737
  const tokens = params2.parsers.markdownit.tokens;
21767
21738
  const size = tokens.length;
21768
21739
  for (let i = 0; i < size; i++) {
21769
- if (tokens[i].type === "template_close") {
21740
+ if (tokens[i].type === "dfn_close") {
21770
21741
  lastCloseIndex = i;
21771
21742
  }
21772
- if (tokens[i].type !== "template_close") {
21743
+ if (tokens[i].type !== "dfn_close") {
21773
21744
  continue;
21774
21745
  }
21775
21746
  if (i === size - 1) {
21776
21747
  continue;
21777
21748
  }
21778
- if (tokens[i + 1].type === "template_open") {
21749
+ if (tokens[i + 1].type === "dfn_open") {
21779
21750
  continue;
21780
21751
  }
21781
- if (i < size - 2 && tokens[i + 2].type === "template_open") {
21752
+ if (i < size - 2 && tokens[i + 2].type === "dfn_open") {
21782
21753
  continue;
21783
21754
  }
21784
21755
  onError({
21785
- lineNumber: tokens[i + 1].lineNumber,
21756
+ lineNumber: ((_a = tokens[i + 1]) == null ? void 0 : _a.lineNumber) || tokens[i].lineNumber || 1,
21786
21757
  detail: "There is a content between term definition. All term defitions should be placed at the end of file."
21787
21758
  });
21788
21759
  }
@@ -21791,7 +21762,7 @@ var yfm009 = {
21791
21762
  }
21792
21763
  if (lastCloseIndex !== size - 1) {
21793
21764
  onError({
21794
- lineNumber: tokens[lastCloseIndex + 1].lineNumber,
21765
+ lineNumber: ((_b = tokens[lastCloseIndex + 1]) == null ? void 0 : _b.lineNumber) || tokens[lastCloseIndex].lineNumber || 1,
21795
21766
  detail: "The file must end with term only."
21796
21767
  });
21797
21768
  }
@@ -21809,20 +21780,15 @@ var yfm010 = {
21809
21780
  if (!config) {
21810
21781
  return;
21811
21782
  }
21812
- params2.parsers.markdownit.tokens.filter((token) => {
21813
- return token.type === "inline";
21814
- }).forEach((inline) => {
21815
- var _a;
21816
- (_a = inline.children) == null ? void 0 : _a.filter((child) => {
21817
- return child.type === "link_open";
21818
- }).forEach((link) => {
21819
- if (link.attrGet("YFM010")) {
21820
- const autotitleAnchorError = `[Unreachable autotitle anchor: "${link.attrGet("href")}"]`;
21821
- onError({
21822
- lineNumber: link.lineNumber,
21823
- context: autotitleAnchorError + link.line
21824
- });
21825
- }
21783
+ findLinksInInlineTokens(params2, "YFM010", onError, (linkToken, inline) => {
21784
+ const autotitleAnchorError = `[Unreachable autotitle anchor: "${linkToken.attrGet("href")}"]`;
21785
+ const rawLineNumber = linkToken.lineNumber || inline.lineNumber;
21786
+ const { lineNumber, filePath } = validateLineNumberAndGetFilePath(params2, rawLineNumber);
21787
+ const baseContext = [autotitleAnchorError, linkToken.line || ""].join(" ");
21788
+ const context = createContextWithFileInfo(baseContext, filePath, params2.name);
21789
+ onError({
21790
+ lineNumber,
21791
+ context
21826
21792
  });
21827
21793
  });
21828
21794
  }
@@ -21839,20 +21805,11 @@ var yfm011 = {
21839
21805
  if (!config) {
21840
21806
  return;
21841
21807
  }
21842
- params2.parsers.markdownit.tokens.filter((token) => {
21843
- return token.type === "inline";
21844
- }).forEach((inline) => {
21845
- var _a;
21846
- (_a = inline.children) == null ? void 0 : _a.filter((child) => {
21847
- return child.type === "image";
21848
- }).forEach((link) => {
21849
- if (link.attrGet("YFM011")) {
21850
- const svgSizeError = link.attrGet("YFM011");
21851
- onError({
21852
- lineNumber: link.lineNumber,
21853
- context: svgSizeError + " " + link.line
21854
- });
21855
- }
21808
+ findImagesInInlineTokens(params2, "YFM011", onError, (imageToken) => {
21809
+ const svgSizeError = imageToken.attrGet("YFM011");
21810
+ onError({
21811
+ lineNumber: imageToken.lineNumber,
21812
+ context: (svgSizeError || "") + " " + (imageToken.line || "")
21856
21813
  });
21857
21814
  });
21858
21815
  }
@@ -21870,10 +21827,14 @@ async function yfmlint(content3, path3, opts) {
21870
21827
  pluginOptions.isLintRun = true;
21871
21828
  const config = normalizeConfig(config_default, lintConfig);
21872
21829
  const plugins = customPlugins && customPlugins.length && [import_markdown_it_attrs.default, ...customPlugins] || void 0;
21873
- const preparedPlugins = plugins && plugins.map((plugin) => [plugin, pluginOptions]);
21830
+ const preparedPlugins = plugins && plugins.map(
21831
+ (plugin) => [plugin, pluginOptions]
21832
+ );
21874
21833
  const errors = await lint({
21875
21834
  strings: { [path3]: content3 },
21876
21835
  markdownItPlugins: preparedPlugins,
21836
+ // Continue processing even if a rule throws an error
21837
+ // This prevents one failing rule from stopping the entire lint process
21877
21838
  handleRuleFailures: true,
21878
21839
  frontMatter,
21879
21840
  config,