@icebreakers/eslint-config 1.0.3 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,15 +2,72 @@ import {
2
2
  __dirname,
3
3
  __export,
4
4
  __require
5
- } from "./chunk-4JACZTJG.js";
5
+ } from "./chunk-CLGPHZON.js";
6
6
 
7
- // ../../node_modules/.pnpm/eslint-mdx@3.2.0_eslint@9.22.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/index.es2015.mjs
8
- var index_es2015_exports = {};
9
- __export(index_es2015_exports, {
7
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/index.js
8
+ var lib_exports2 = {};
9
+ __export(lib_exports2, {
10
+ DEFAULT_LANGUAGE_MAPPER: () => DEFAULT_LANGUAGE_MAPPER,
11
+ base: () => base,
12
+ cjsRequire: () => cjsRequire3,
13
+ codeBlocks: () => codeBlocks,
14
+ configs: () => configs,
15
+ createRemarkProcessor: () => createRemarkProcessor,
16
+ flat: () => flat,
17
+ flatCodeBlocks: () => flatCodeBlocks,
18
+ getGlobals: () => getGlobals,
19
+ getShortLang: () => getShortLang,
20
+ meta: () => meta2,
21
+ overrides: () => overrides,
22
+ processorOptions: () => processorOptions,
23
+ processors: () => processors,
24
+ recommended: () => recommended,
25
+ remark: () => remark2,
26
+ rules: () => rules
27
+ });
28
+
29
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/base.js
30
+ var base = {
31
+ parser: "eslint-mdx",
32
+ parserOptions: {
33
+ sourceType: "module",
34
+ ecmaVersion: "latest"
35
+ },
36
+ plugins: ["mdx"],
37
+ processor: "mdx/remark",
38
+ rules: {
39
+ "mdx/remark": "warn",
40
+ "no-unused-expressions": "error"
41
+ }
42
+ };
43
+
44
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/code-blocks.js
45
+ var codeBlocks = {
46
+ parserOptions: {
47
+ ecmaFeatures: {
48
+ impliedStrict: true
49
+ }
50
+ },
51
+ rules: {
52
+ "eol-last": "off",
53
+ "no-undef": "off",
54
+ "no-unused-expressions": "off",
55
+ "no-unused-vars": "off",
56
+ "@typescript-eslint/no-unused-vars": "off",
57
+ "padded-blocks": "off",
58
+ strict: "off",
59
+ "unicode-bom": "off"
60
+ }
61
+ };
62
+
63
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/index.js
64
+ var lib_exports = {};
65
+ __export(lib_exports, {
10
66
  DEFAULT_EXTENSIONS: () => DEFAULT_EXTENSIONS,
11
67
  MARKDOWN_EXTENSIONS: () => MARKDOWN_EXTENSIONS,
12
68
  Parser: () => Parser,
13
69
  arrayify: () => arrayify,
70
+ cjsRequire: () => cjsRequire,
14
71
  getPhysicalFilename: () => getPhysicalFilename,
15
72
  getPositionAtFactory: () => getPositionAtFactory,
16
73
  last: () => last,
@@ -24,8 +81,89 @@ __export(index_es2015_exports, {
24
81
  performSyncWork: () => performSyncWork,
25
82
  prevCharOffsetFactory: () => prevCharOffsetFactory
26
83
  });
27
- import fs3 from "node:fs";
28
- import path3 from "node:path";
84
+
85
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/helpers.js
86
+ import fs from "node:fs";
87
+ import { createRequire } from "node:module";
88
+ import path from "node:path";
89
+ var last = (items) => items && items[items.length - 1];
90
+ var arrayify = (...args) => args.reduce((arr, curr) => {
91
+ arr.push(...Array.isArray(curr) ? curr : curr == null ? [] : [curr]);
92
+ return arr;
93
+ }, []);
94
+ var getPhysicalFilename = (filename, child) => {
95
+ try {
96
+ if (fs.statSync(filename).isDirectory()) {
97
+ return child || filename;
98
+ }
99
+ } catch (err) {
100
+ const { code } = err;
101
+ if (code === "ENOTDIR" || code === "ENOENT") {
102
+ return getPhysicalFilename(path.dirname(filename), filename);
103
+ }
104
+ }
105
+ return filename;
106
+ };
107
+ var loadEsmModule = (modulePath) => new Function("modulePath", `return import(modulePath);`)(modulePath);
108
+ var getPositionAtFactory = (text) => {
109
+ const lines = text.split("\n");
110
+ return (offset) => {
111
+ let currOffset = 0;
112
+ for (const [index, line_] of lines.entries()) {
113
+ const line = index + 1;
114
+ const nextOffset = currOffset + line_.length;
115
+ if (nextOffset >= offset) {
116
+ return {
117
+ line,
118
+ column: offset - currOffset
119
+ };
120
+ }
121
+ currOffset = nextOffset + 1;
122
+ }
123
+ };
124
+ };
125
+ var normalizePosition = ({ start, end, text }) => {
126
+ const startOffset = start.offset;
127
+ const endOffset = end.offset;
128
+ const range = [startOffset, endOffset];
129
+ const getPositionAt = text == null ? null : getPositionAtFactory(text);
130
+ return {
131
+ start: startOffset,
132
+ end: endOffset,
133
+ loc: {
134
+ start: "line" in start ? start : getPositionAt(startOffset),
135
+ end: "line" in end ? end : getPositionAt(endOffset)
136
+ },
137
+ range
138
+ };
139
+ };
140
+ var prevCharOffsetFactory = (text) => (offset) => {
141
+ for (let i = offset; i >= 0; i--) {
142
+ const char = text[i];
143
+ if (/^\S$/.test(char)) {
144
+ return i;
145
+ }
146
+ }
147
+ };
148
+ var nextCharOffsetFactory = (text) => {
149
+ const total = text.length;
150
+ return (offset) => {
151
+ for (let i = offset; i <= total; i++) {
152
+ const char = text[i];
153
+ if (/^\S$/.test(char)) {
154
+ return i;
155
+ }
156
+ }
157
+ };
158
+ };
159
+ var cjsRequire = typeof __require === "undefined" ? createRequire(import.meta.url) : __require;
160
+
161
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/meta.js
162
+ var pkg = cjsRequire("../package.json");
163
+ var meta = { name: pkg.name, version: pkg.version };
164
+
165
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/parser.js
166
+ import path4 from "node:path";
29
167
 
30
168
  // ../../node_modules/.pnpm/tslib@2.8.1/node_modules/tslib/tslib.es6.mjs
31
169
  function __rest(s, e) {
@@ -40,37 +178,38 @@ function __rest(s, e) {
40
178
  return t;
41
179
  }
42
180
 
43
- // ../../node_modules/.pnpm/synckit@0.9.2/node_modules/synckit/lib/index.js
181
+ // ../../node_modules/.pnpm/synckit@0.10.3/node_modules/synckit/lib/index.js
44
182
  import { createHash } from "node:crypto";
45
- import fs2 from "node:fs";
46
- import module from "node:module";
47
- import path2 from "node:path";
183
+ import fs3 from "node:fs";
184
+ import path3 from "node:path";
48
185
  import { fileURLToPath, pathToFileURL } from "node:url";
49
186
  import { MessageChannel, Worker, parentPort, receiveMessageOnPort, workerData } from "node:worker_threads";
50
187
 
51
- // ../../node_modules/.pnpm/@pkgr+core@0.1.1/node_modules/@pkgr/core/lib/constants.js
52
- import { createRequire } from "node:module";
188
+ // ../../node_modules/.pnpm/@pkgr+core@0.2.0/node_modules/@pkgr/core/lib/constants.js
189
+ import { createRequire as createRequire2 } from "node:module";
53
190
  var CWD = process.cwd();
54
- var cjsRequire = typeof __require === "undefined" ? createRequire(import.meta.url) : __require;
55
- var EXTENSIONS = [".ts", ".tsx", ...Object.keys(cjsRequire.extensions)];
191
+ var cjsRequire2 = typeof __require === "undefined" ? createRequire2(import.meta.url) : __require;
192
+ var EXTENSIONS = [".ts", ".tsx", ...Object.keys(cjsRequire2.extensions)];
56
193
 
57
- // ../../node_modules/.pnpm/@pkgr+core@0.1.1/node_modules/@pkgr/core/lib/helpers.js
58
- import fs from "node:fs";
59
- import path from "node:path";
60
- var tryPkg = (pkg) => {
194
+ // ../../node_modules/.pnpm/@pkgr+core@0.2.0/node_modules/@pkgr/core/lib/helpers.js
195
+ import fs2 from "node:fs";
196
+ import path2 from "node:path";
197
+ var tryPkg = (pkg3) => {
61
198
  try {
62
- return cjsRequire.resolve(pkg);
63
- } catch (_a2) {
199
+ return cjsRequire2.resolve(pkg3);
200
+ } catch (_a) {
64
201
  }
65
202
  };
66
- var isPkgAvailable = (pkg) => !!tryPkg(pkg);
67
- var tryFile = (filePath, includeDir = false) => {
68
- if (typeof filePath === "string") {
69
- return fs.existsSync(filePath) && (includeDir || fs.statSync(filePath).isFile()) ? filePath : "";
203
+ var isPkgAvailable = (pkg3) => !!tryPkg(pkg3);
204
+ var tryFile = (filename, includeDir = false, base2 = CWD) => {
205
+ if (typeof filename === "string") {
206
+ const filepath = path2.resolve(base2, filename);
207
+ return fs2.existsSync(filepath) && (includeDir || fs2.statSync(filepath).isFile()) ? filepath : "";
70
208
  }
71
- for (const file of filePath !== null && filePath !== void 0 ? filePath : []) {
72
- if (tryFile(file, includeDir)) {
73
- return file;
209
+ for (const file of filename !== null && filename !== void 0 ? filename : []) {
210
+ const filepath = tryFile(file, includeDir, base2);
211
+ if (filepath) {
212
+ return filepath;
74
213
  }
75
214
  }
76
215
  return "";
@@ -80,36 +219,67 @@ var tryExtensions = (filepath, extensions = EXTENSIONS) => {
80
219
  return ext == null ? "" : filepath + ext;
81
220
  };
82
221
  var findUp = (searchEntry, searchFileOrIncludeDir, includeDir) => {
83
- console.assert(path.isAbsolute(searchEntry));
84
- if (!tryFile(searchEntry, true) || searchEntry !== CWD && !searchEntry.startsWith(CWD + path.sep)) {
222
+ console.assert(path2.isAbsolute(searchEntry));
223
+ if (!tryFile(searchEntry, true) || searchEntry !== CWD && !searchEntry.startsWith(CWD + path2.sep)) {
85
224
  return "";
86
225
  }
87
- searchEntry = path.resolve(fs.statSync(searchEntry).isDirectory() ? searchEntry : path.resolve(searchEntry, ".."));
226
+ searchEntry = path2.resolve(fs2.statSync(searchEntry).isDirectory() ? searchEntry : path2.resolve(searchEntry, ".."));
88
227
  const isSearchFile = typeof searchFileOrIncludeDir === "string";
89
228
  const searchFile = isSearchFile ? searchFileOrIncludeDir : "package.json";
90
229
  do {
91
- const searched = tryFile(path.resolve(searchEntry, searchFile), isSearchFile && includeDir);
230
+ const searched = tryFile(path2.resolve(searchEntry, searchFile), isSearchFile && includeDir);
92
231
  if (searched) {
93
232
  return searched;
94
233
  }
95
- searchEntry = path.resolve(searchEntry, "..");
96
- } while (searchEntry === CWD || searchEntry.startsWith(CWD + path.sep));
234
+ searchEntry = path2.resolve(searchEntry, "..");
235
+ } while (searchEntry === CWD || searchEntry.startsWith(CWD + path2.sep));
97
236
  return "";
98
237
  };
99
238
 
100
- // ../../node_modules/.pnpm/synckit@0.9.2/node_modules/synckit/lib/index.js
239
+ // ../../node_modules/.pnpm/synckit@0.10.3/node_modules/synckit/lib/index.js
101
240
  var INT32_BYTES = 4;
102
241
  var TsRunner = {
242
+ Node: "node",
243
+ Bun: "bun",
103
244
  TsNode: "ts-node",
104
245
  EsbuildRegister: "esbuild-register",
105
246
  EsbuildRunner: "esbuild-runner",
106
247
  SWC: "swc",
107
248
  TSX: "tsx"
108
249
  };
109
- var { NODE_OPTIONS, SYNCKIT_EXEC_ARGV, SYNCKIT_GLOBAL_SHIMS, SYNCKIT_TIMEOUT, SYNCKIT_TS_RUNNER } = process.env;
110
- var IS_NODE_20 = Number(process.versions.node.split(".")[0]) >= 20;
250
+ var { NODE_OPTIONS: NODE_OPTIONS_ = "", SYNCKIT_EXEC_ARGV = "", SYNCKIT_GLOBAL_SHIMS, SYNCKIT_TIMEOUT, SYNCKIT_TS_RUNNER } = process.env;
251
+ var MTS_SUPPORTED_NODE_VERSION = "16";
252
+ var LOADER_SUPPORTED_NODE_VERSION = "20";
253
+ var STRIP_TYPES_NODE_VERSION = "22.6";
254
+ var TRANSFORM_TYPES_NODE_VERSION = "22.7";
255
+ var FEATURE_TYPESCRIPT_NODE_VERSION = "22.10";
256
+ var DEFAULT_TYPES_NODE_VERSION = "23.6";
257
+ var STRIP_TYPES_FLAG = "--experimental-strip-types";
258
+ var TRANSFORM_TYPES_FLAG = "--experimental-transform-types";
259
+ var NO_STRIP_TYPES_FLAG = "--no-experimental-strip-types";
260
+ var NODE_OPTIONS = NODE_OPTIONS_.split(/\s+/);
261
+ var hasFlag = (flag) => NODE_OPTIONS.includes(flag) || process.argv.includes(flag);
262
+ var parseVersion = (version) => version.split(".").map(Number.parseFloat);
263
+ var compareVersion = (version1, version2) => {
264
+ const versions1 = parseVersion(version1);
265
+ const versions2 = parseVersion(version2);
266
+ const length = Math.max(versions1.length, versions2.length);
267
+ for (let i = 0; i < length; i++) {
268
+ const v1 = versions1[i] || 0;
269
+ const v2 = versions2[i] || 0;
270
+ if (v1 > v2) {
271
+ return 1;
272
+ }
273
+ if (v1 < v2) {
274
+ return -1;
275
+ }
276
+ }
277
+ return 0;
278
+ };
279
+ var NODE_VERSION = process.versions.node;
280
+ var NO_STRIP_TYPES = compareVersion(NODE_VERSION, FEATURE_TYPESCRIPT_NODE_VERSION) >= 0 ? process.features.typescript === false : hasFlag(NO_STRIP_TYPES_FLAG) && !hasFlag(STRIP_TYPES_FLAG) && !hasFlag(TRANSFORM_TYPES_FLAG);
111
281
  var DEFAULT_TIMEOUT = SYNCKIT_TIMEOUT ? +SYNCKIT_TIMEOUT : void 0;
112
- var DEFAULT_EXEC_ARGV = (SYNCKIT_EXEC_ARGV === null || SYNCKIT_EXEC_ARGV === void 0 ? void 0 : SYNCKIT_EXEC_ARGV.split(",")) || [];
282
+ var DEFAULT_EXEC_ARGV = SYNCKIT_EXEC_ARGV.split(",");
113
283
  var DEFAULT_TS_RUNNER = SYNCKIT_TS_RUNNER;
114
284
  var DEFAULT_GLOBAL_SHIMS = ["1", "true"].includes(SYNCKIT_GLOBAL_SHIMS);
115
285
  var DEFAULT_GLOBAL_SHIMS_PRESET = [
@@ -123,35 +293,36 @@ var DEFAULT_GLOBAL_SHIMS_PRESET = [
123
293
  named: "performance"
124
294
  }
125
295
  ];
126
- var MTS_SUPPORTED_NODE_VERSION = 16;
127
296
  var syncFnCache;
128
- function createSyncFn(workerPath2, timeoutOrOptions) {
297
+ function createSyncFn(workerPath, timeoutOrOptions) {
129
298
  syncFnCache !== null && syncFnCache !== void 0 ? syncFnCache : syncFnCache = /* @__PURE__ */ new Map();
130
- const cachedSyncFn = syncFnCache.get(workerPath2);
299
+ if (typeof workerPath !== "string" || workerPath.startsWith("file://")) {
300
+ workerPath = fileURLToPath(workerPath);
301
+ }
302
+ const cachedSyncFn = syncFnCache.get(workerPath);
131
303
  if (cachedSyncFn) {
132
304
  return cachedSyncFn;
133
305
  }
134
- if (!path2.isAbsolute(workerPath2)) {
306
+ if (!path3.isAbsolute(workerPath)) {
135
307
  throw new Error("`workerPath` must be absolute");
136
308
  }
137
- const syncFn = startWorkerThread(workerPath2, typeof timeoutOrOptions === "number" ? { timeout: timeoutOrOptions } : timeoutOrOptions);
138
- syncFnCache.set(workerPath2, syncFn);
309
+ const syncFn = startWorkerThread(workerPath, typeof timeoutOrOptions === "number" ? { timeout: timeoutOrOptions } : timeoutOrOptions);
310
+ syncFnCache.set(workerPath, syncFn);
139
311
  return syncFn;
140
312
  }
141
- var cjsRequire2 = typeof __require === "undefined" ? module.createRequire(import.meta.url) : __require;
142
313
  var dataUrl = (code) => new URL(`data:text/javascript,${encodeURIComponent(code)}`);
143
- var isFile = (path5) => {
144
- var _a2;
314
+ var isFile = (path6) => {
315
+ var _a;
145
316
  try {
146
- return !!((_a2 = fs2.statSync(path5, { throwIfNoEntry: false })) === null || _a2 === void 0 ? void 0 : _a2.isFile());
317
+ return !!((_a = fs3.statSync(path6, { throwIfNoEntry: false })) === null || _a === void 0 ? void 0 : _a.isFile());
147
318
  } catch (_b) {
148
319
  return false;
149
320
  }
150
321
  };
151
- var setupTsRunner = (workerPath2, { execArgv, tsRunner }) => {
152
- let ext = path2.extname(workerPath2);
153
- if (!/[/\\]node_modules[/\\]/.test(workerPath2) && (!ext || /^\.[cm]?js$/.test(ext))) {
154
- const workPathWithoutExt = ext ? workerPath2.slice(0, -ext.length) : workerPath2;
322
+ var setupTsRunner = (workerPath, { execArgv, tsRunner }) => {
323
+ let ext = path3.extname(workerPath);
324
+ if (!/([/\\])node_modules\1/.test(workerPath) && (!ext || /^\.[cm]?js$/.test(ext))) {
325
+ const workPathWithoutExt = ext ? workerPath.slice(0, -ext.length) : workerPath;
155
326
  let extensions;
156
327
  switch (ext) {
157
328
  case ".cjs": {
@@ -170,26 +341,57 @@ var setupTsRunner = (workerPath2, { execArgv, tsRunner }) => {
170
341
  const found = tryExtensions(workPathWithoutExt, extensions);
171
342
  let differentExt;
172
343
  if (found && (!ext || (differentExt = found !== workPathWithoutExt))) {
173
- workerPath2 = found;
344
+ workerPath = found;
174
345
  if (differentExt) {
175
- ext = path2.extname(workerPath2);
346
+ ext = path3.extname(workerPath);
176
347
  }
177
348
  }
178
349
  }
179
- const isTs = /\.[cm]?ts$/.test(workerPath2);
180
- let jsUseEsm = workerPath2.endsWith(".mjs");
181
- let tsUseEsm = workerPath2.endsWith(".mts");
350
+ const isTs = /\.[cm]?ts$/.test(workerPath);
351
+ let jsUseEsm = workerPath.endsWith(".mjs");
352
+ let tsUseEsm = workerPath.endsWith(".mts");
182
353
  if (isTs) {
183
354
  if (!tsUseEsm) {
184
- const pkg = findUp(workerPath2);
185
- if (pkg) {
186
- tsUseEsm = cjsRequire2(pkg).type === "module";
355
+ const pkg3 = findUp(workerPath);
356
+ if (pkg3) {
357
+ tsUseEsm = cjsRequire2(pkg3).type === "module";
187
358
  }
188
359
  }
189
- if (tsRunner == null && isPkgAvailable(TsRunner.TsNode)) {
190
- tsRunner = TsRunner.TsNode;
360
+ const stripTypesIndex = execArgv.indexOf(STRIP_TYPES_FLAG);
361
+ const transformTypesIndex = execArgv.indexOf(TRANSFORM_TYPES_FLAG);
362
+ const noStripTypesIndex = execArgv.indexOf(NO_STRIP_TYPES_FLAG);
363
+ const execArgvNoStripTypes = noStripTypesIndex > stripTypesIndex || noStripTypesIndex > transformTypesIndex;
364
+ const noStripTypes = execArgvNoStripTypes || stripTypesIndex === -1 && transformTypesIndex === -1 && NO_STRIP_TYPES;
365
+ if (tsRunner == null) {
366
+ if (process.versions.bun) {
367
+ tsRunner = TsRunner.Bun;
368
+ } else if (!noStripTypes && compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) >= 0) {
369
+ tsRunner = TsRunner.Node;
370
+ } else if (isPkgAvailable(TsRunner.TsNode)) {
371
+ tsRunner = TsRunner.TsNode;
372
+ }
191
373
  }
192
374
  switch (tsRunner) {
375
+ case TsRunner.Bun: {
376
+ break;
377
+ }
378
+ case TsRunner.Node: {
379
+ if (compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) < 0) {
380
+ throw new Error("type stripping is not supported in this node version");
381
+ }
382
+ if (noStripTypes) {
383
+ throw new Error("type stripping is disabled explicitly");
384
+ }
385
+ if (compareVersion(NODE_VERSION, DEFAULT_TYPES_NODE_VERSION) >= 0) {
386
+ break;
387
+ }
388
+ if (compareVersion(NODE_VERSION, TRANSFORM_TYPES_NODE_VERSION) >= 0 && !execArgv.includes(TRANSFORM_TYPES_FLAG)) {
389
+ execArgv = [TRANSFORM_TYPES_FLAG, ...execArgv];
390
+ } else if (compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) >= 0 && !execArgv.includes(STRIP_TYPES_FLAG)) {
391
+ execArgv = [STRIP_TYPES_FLAG, ...execArgv];
392
+ }
393
+ break;
394
+ }
193
395
  case TsRunner.TsNode: {
194
396
  if (tsUseEsm) {
195
397
  if (!execArgv.includes("--loader")) {
@@ -229,25 +431,24 @@ var setupTsRunner = (workerPath2, { execArgv, tsRunner }) => {
229
431
  }
230
432
  }
231
433
  } else if (!jsUseEsm) {
232
- const pkg = findUp(workerPath2);
233
- if (pkg) {
234
- jsUseEsm = cjsRequire2(pkg).type === "module";
434
+ const pkg3 = findUp(workerPath);
435
+ if (pkg3) {
436
+ jsUseEsm = cjsRequire2(pkg3).type === "module";
235
437
  }
236
438
  }
237
439
  let resolvedPnpLoaderPath;
238
440
  if (process.versions.pnp) {
239
- const nodeOptions = NODE_OPTIONS === null || NODE_OPTIONS === void 0 ? void 0 : NODE_OPTIONS.split(/\s+/);
240
441
  let pnpApiPath;
241
442
  try {
242
443
  pnpApiPath = cjsRequire2.resolve("pnpapi");
243
- } catch (_a2) {
444
+ } catch (_a) {
244
445
  }
245
- if (pnpApiPath && !(nodeOptions === null || nodeOptions === void 0 ? void 0 : nodeOptions.some((option, index) => ["-r", "--require"].includes(option) && pnpApiPath === cjsRequire2.resolve(nodeOptions[index + 1]))) && !execArgv.includes(pnpApiPath)) {
446
+ if (pnpApiPath && !NODE_OPTIONS.some((option, index) => ["-r", "--require"].includes(option) && pnpApiPath === cjsRequire2.resolve(NODE_OPTIONS[index + 1])) && !execArgv.includes(pnpApiPath)) {
246
447
  execArgv = ["-r", pnpApiPath, ...execArgv];
247
- const pnpLoaderPath = path2.resolve(pnpApiPath, "../.pnp.loader.mjs");
448
+ const pnpLoaderPath = path3.resolve(pnpApiPath, "../.pnp.loader.mjs");
248
449
  if (isFile(pnpLoaderPath)) {
249
450
  resolvedPnpLoaderPath = pathToFileURL(pnpLoaderPath).toString();
250
- if (!IS_NODE_20) {
451
+ if (compareVersion(NODE_VERSION, LOADER_SUPPORTED_NODE_VERSION) < 0) {
251
452
  execArgv = [
252
453
  "--experimental-loader",
253
454
  resolvedPnpLoaderPath,
@@ -263,7 +464,7 @@ var setupTsRunner = (workerPath2, { execArgv, tsRunner }) => {
263
464
  jsUseEsm,
264
465
  tsRunner,
265
466
  tsUseEsm,
266
- workerPath: workerPath2,
467
+ workerPath,
267
468
  pnpLoaderPath: resolvedPnpLoaderPath,
268
469
  execArgv
269
470
  };
@@ -271,7 +472,7 @@ var setupTsRunner = (workerPath2, { execArgv, tsRunner }) => {
271
472
  var md5Hash = (text) => createHash("md5").update(text).digest("hex");
272
473
  var encodeImportModule = (moduleNameOrGlobalShim, type = "import") => {
273
474
  const { moduleName, globalName, named, conditional } = typeof moduleNameOrGlobalShim === "string" ? { moduleName: moduleNameOrGlobalShim } : moduleNameOrGlobalShim;
274
- const importStatement = type === "import" ? `import${globalName ? " " + (named === null ? "* as " + globalName : (named === null || named === void 0 ? void 0 : named.trim()) ? `{${named}}` : globalName) + " from" : ""} '${path2.isAbsolute(moduleName) ? String(pathToFileURL(moduleName)) : moduleName}'` : `${globalName ? "const " + ((named === null || named === void 0 ? void 0 : named.trim()) ? `{${named}}` : globalName) + "=" : ""}require('${moduleName.replace(/\\/g, "\\\\")}')`;
475
+ const importStatement = type === "import" ? `import${globalName ? " " + (named === null ? "* as " + globalName : (named === null || named === void 0 ? void 0 : named.trim()) ? `{${named}}` : globalName) + " from" : ""} '${path3.isAbsolute(moduleName) ? String(pathToFileURL(moduleName)) : moduleName}'` : `${globalName ? "const " + ((named === null || named === void 0 ? void 0 : named.trim()) ? `{${named}}` : globalName) + "=" : ""}require('${moduleName.replace(/\\/g, "\\\\")}')`;
275
476
  if (!globalName) {
276
477
  return importStatement;
277
478
  }
@@ -281,12 +482,15 @@ var encodeImportModule = (moduleNameOrGlobalShim, type = "import") => {
281
482
  var _generateGlobals = (globalShims, type) => globalShims.reduce((acc, shim) => `${acc}${acc ? ";" : ""}${encodeImportModule(shim, type)}`, "");
282
483
  var globalsCache;
283
484
  var tmpdir;
284
- var _dirname = typeof __dirname === "undefined" ? path2.dirname(fileURLToPath(import.meta.url)) : __dirname;
485
+ var _dirname = typeof __dirname === "undefined" ? path3.dirname(fileURLToPath(import.meta.url)) : __dirname;
285
486
  var sharedBuffer;
286
487
  var sharedBufferView;
287
- var generateGlobals = (workerPath2, globalShims, type = "import") => {
488
+ var generateGlobals = (workerPath, globalShims, type = "import") => {
489
+ if (globalShims.length === 0) {
490
+ return "";
491
+ }
288
492
  globalsCache !== null && globalsCache !== void 0 ? globalsCache : globalsCache = /* @__PURE__ */ new Map();
289
- const cached = globalsCache.get(workerPath2);
493
+ const cached = globalsCache.get(workerPath);
290
494
  if (cached) {
291
495
  const [content2, filepath2] = cached;
292
496
  if (type === "require" && !filepath2 || type === "import" && filepath2 && isFile(filepath2)) {
@@ -298,22 +502,22 @@ var generateGlobals = (workerPath2, globalShims, type = "import") => {
298
502
  let filepath;
299
503
  if (type === "import") {
300
504
  if (!tmpdir) {
301
- tmpdir = path2.resolve(findUp(_dirname), "../node_modules/.synckit");
505
+ tmpdir = path3.resolve(findUp(_dirname), "../node_modules/.synckit");
302
506
  }
303
- fs2.mkdirSync(tmpdir, { recursive: true });
304
- filepath = path2.resolve(tmpdir, md5Hash(workerPath2) + ".mjs");
507
+ fs3.mkdirSync(tmpdir, { recursive: true });
508
+ filepath = path3.resolve(tmpdir, md5Hash(workerPath) + ".mjs");
305
509
  content = encodeImportModule(filepath);
306
- fs2.writeFileSync(filepath, globals);
510
+ fs3.writeFileSync(filepath, globals);
307
511
  }
308
- globalsCache.set(workerPath2, [content, filepath]);
512
+ globalsCache.set(workerPath, [content, filepath]);
309
513
  return content;
310
514
  };
311
- function startWorkerThread(workerPath2, { timeout = DEFAULT_TIMEOUT, execArgv = DEFAULT_EXEC_ARGV, tsRunner = DEFAULT_TS_RUNNER, transferList = [], globalShims = DEFAULT_GLOBAL_SHIMS } = {}) {
515
+ function startWorkerThread(workerPath, { timeout = DEFAULT_TIMEOUT, execArgv = DEFAULT_EXEC_ARGV, tsRunner = DEFAULT_TS_RUNNER, transferList = [], globalShims = DEFAULT_GLOBAL_SHIMS } = {}) {
312
516
  const { port1: mainPort, port2: workerPort } = new MessageChannel();
313
- const { isTs, ext, jsUseEsm, tsUseEsm, tsRunner: finalTsRunner, workerPath: finalWorkerPath, pnpLoaderPath, execArgv: finalExecArgv } = setupTsRunner(workerPath2, { execArgv, tsRunner });
517
+ const { isTs, ext, jsUseEsm, tsUseEsm, tsRunner: finalTsRunner, workerPath: finalWorkerPath, pnpLoaderPath, execArgv: finalExecArgv } = setupTsRunner(workerPath, { execArgv, tsRunner });
314
518
  const workerPathUrl = pathToFileURL(finalWorkerPath);
315
519
  if (/\.[cm]ts$/.test(finalWorkerPath)) {
316
- const isTsxSupported = !tsUseEsm || Number.parseFloat(process.versions.node) >= MTS_SUPPORTED_NODE_VERSION;
520
+ const isTsxSupported = !tsUseEsm || compareVersion(NODE_VERSION, MTS_SUPPORTED_NODE_VERSION) >= 0;
317
521
  if (!finalTsRunner) {
318
522
  throw new Error("No ts runner specified, ts worker path is not supported");
319
523
  } else if ([
@@ -331,7 +535,7 @@ function startWorkerThread(workerPath2, { timeout = DEFAULT_TIMEOUT, execArgv =
331
535
  const useEval = isTs ? !tsUseEsm : !jsUseEsm && useGlobals;
332
536
  const worker = new Worker(jsUseEsm && useGlobals || tsUseEsm && finalTsRunner === TsRunner.TsNode ? dataUrl(`${generateGlobals(finalWorkerPath, finalGlobalShims)};import '${String(workerPathUrl)}'`) : useEval ? `${generateGlobals(finalWorkerPath, finalGlobalShims, "require")};${encodeImportModule(finalWorkerPath, "require")}` : workerPathUrl, {
333
537
  eval: useEval,
334
- workerData: { sharedBuffer, workerPort, pnpLoaderPath },
538
+ workerData: { sharedBufferView, workerPort, pnpLoaderPath },
335
539
  transferList: [workerPort, ...transferList],
336
540
  execArgv: finalExecArgv
337
541
  });
@@ -348,7 +552,7 @@ function startWorkerThread(workerPath2, { timeout = DEFAULT_TIMEOUT, execArgv =
348
552
  port.postMessage(abortMsg);
349
553
  throw new Error("Internal error: Atomics.wait() failed: " + status);
350
554
  }
351
- const _a2 = receiveMessageOnPort(mainPort).message, { id } = _a2, message = __rest(_a2, ["id"]);
555
+ const _a = receiveMessageOnPort(mainPort).message, { id } = _a, message = __rest(_a, ["id"]);
352
556
  if (id < expectedId) {
353
557
  const waitingTime = Date.now() - start;
354
558
  return receiveMessageWithId(port, expectedId, waitingTimeout ? waitingTimeout - waitingTime : void 0);
@@ -362,7 +566,10 @@ function startWorkerThread(workerPath2, { timeout = DEFAULT_TIMEOUT, execArgv =
362
566
  const id = nextID++;
363
567
  const msg = { id, args };
364
568
  worker.postMessage(msg);
365
- const { result, error, properties } = receiveMessageWithId(mainPort, id, timeout);
569
+ const { result, error, properties, stdio } = receiveMessageWithId(mainPort, id, timeout);
570
+ for (const { type, chunk, encoding } of stdio) {
571
+ process[type].write(chunk, encoding);
572
+ }
366
573
  if (error) {
367
574
  throw Object.assign(error, properties);
368
575
  }
@@ -372,122 +579,10 @@ function startWorkerThread(workerPath2, { timeout = DEFAULT_TIMEOUT, execArgv =
372
579
  return syncFn;
373
580
  }
374
581
 
375
- // ../../node_modules/.pnpm/eslint-mdx@3.2.0_eslint@9.22.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/index.es2015.mjs
376
- var last = (items) => (
377
- // eslint-disable-next-line unicorn/prefer-at -- FIXME: Node 16.6+ required
378
- items && items[items.length - 1]
379
- );
380
- var arrayify = (...args) => args.reduce((arr, curr) => {
381
- arr.push(...Array.isArray(curr) ? curr : curr == null ? [] : [curr]);
382
- return arr;
383
- }, []);
384
- var getPhysicalFilename = (filename, child) => {
385
- try {
386
- if (fs3.statSync(filename).isDirectory()) {
387
- return child || filename;
388
- }
389
- } catch (err) {
390
- const { code } = err;
391
- if (code === "ENOTDIR" || code === "ENOENT") {
392
- return getPhysicalFilename(path3.dirname(filename), filename);
393
- }
394
- }
395
- return filename;
396
- };
397
- var loadEsmModule = (modulePath) => (
398
- // eslint-disable-next-line @typescript-eslint/no-implied-eval, no-new-func
399
- new Function("modulePath", `return import(modulePath);`)(
400
- modulePath
401
- )
402
- );
403
- var getPositionAtFactory = (text) => {
404
- const lines = text.split("\n");
405
- return (offset) => {
406
- let currOffset = 0;
407
- for (const [index, line_] of lines.entries()) {
408
- const line = index + 1;
409
- const nextOffset = currOffset + line_.length;
410
- if (nextOffset >= offset) {
411
- return {
412
- line,
413
- column: offset - currOffset
414
- };
415
- }
416
- currOffset = nextOffset + 1;
417
- }
418
- };
419
- };
420
- var normalizePosition = ({
421
- start,
422
- end,
423
- text
424
- }) => {
425
- const startOffset = start.offset;
426
- const endOffset = end.offset;
427
- const range = [startOffset, endOffset];
428
- const getPositionAt = text == null ? null : (
429
- /* istanbul ignore next -- used in worker */
430
- getPositionAtFactory(text)
431
- );
432
- return {
433
- start: startOffset,
434
- end: endOffset,
435
- loc: {
436
- start: (
437
- /* istanbul ignore next -- used in worker */
438
- "line" in start ? start : getPositionAt(startOffset)
439
- ),
440
- end: (
441
- /* istanbul ignore next -- used in worker */
442
- "line" in end ? end : getPositionAt(endOffset)
443
- )
444
- },
445
- range
446
- };
447
- };
448
- var prevCharOffsetFactory = (text) => (offset) => {
449
- for (let i = offset; i >= 0; i--) {
450
- const char = text[i];
451
- if (/^\S$/.test(char)) {
452
- return i;
453
- }
454
- }
455
- };
456
- var nextCharOffsetFactory = (text) => {
457
- const total = text.length;
458
- return (offset) => {
459
- for (let i = offset; i <= total; i++) {
460
- const char = text[i];
461
- if (/^\S$/.test(char)) {
462
- return i;
463
- }
464
- }
465
- };
466
- };
467
- var name = "eslint-mdx";
468
- var version = "3.2.0";
469
- var meta = { name, version };
470
- var workerPath = __require.resolve("./worker");
471
- var performSyncWork = createSyncFn(workerPath);
472
- var __defProp = Object.defineProperty;
473
- var __defProps = Object.defineProperties;
474
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
475
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
476
- var __hasOwnProp = Object.prototype.hasOwnProperty;
477
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
478
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
479
- var __spreadValues = (a, b) => {
480
- for (var prop in b || (b = {}))
481
- if (__hasOwnProp.call(b, prop))
482
- __defNormalProp(a, prop, b[prop]);
483
- if (__getOwnPropSymbols)
484
- for (var prop of __getOwnPropSymbols(b)) {
485
- if (__propIsEnum.call(b, prop))
486
- __defNormalProp(a, prop, b[prop]);
487
- }
488
- return a;
489
- };
490
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
582
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/sync.js
583
+ var performSyncWork = createSyncFn(cjsRequire.resolve("./worker.js"));
584
+
585
+ // ../../node_modules/.pnpm/eslint-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-mdx/lib/parser.js
491
586
  var DEFAULT_EXTENSIONS = [".mdx"];
492
587
  var MARKDOWN_EXTENSIONS = [".md"];
493
588
  var Parser = class {
@@ -498,25 +593,15 @@ var Parser = class {
498
593
  parse(code, options) {
499
594
  return this.parseForESLint(code, options).ast;
500
595
  }
501
- parseForESLint(code, {
502
- filePath,
503
- sourceType,
504
- ignoreRemarkConfig,
505
- extensions,
506
- markdownExtensions
507
- }) {
508
- const extname = path3.extname(filePath);
509
- const isMdx = [...DEFAULT_EXTENSIONS, ...arrayify(extensions)].includes(
510
- extname
511
- );
596
+ parseForESLint(code, { filePath, sourceType, ignoreRemarkConfig, extensions, markdownExtensions }) {
597
+ const extname = path4.extname(filePath);
598
+ const isMdx = [...DEFAULT_EXTENSIONS, ...arrayify(extensions)].includes(extname);
512
599
  const isMarkdown = [
513
600
  ...MARKDOWN_EXTENSIONS,
514
601
  ...arrayify(markdownExtensions)
515
602
  ].includes(extname);
516
603
  if (!isMdx && !isMarkdown) {
517
- throw new Error(
518
- "Unsupported file extension, make sure setting the `extensions` or `markdownExtensions` option correctly."
519
- );
604
+ throw new Error("Unsupported file extension, make sure setting the `extensions` or `markdownExtensions` option correctly.");
520
605
  }
521
606
  const physicalFilename = getPhysicalFilename(filePath);
522
607
  let result;
@@ -536,349 +621,156 @@ var Parser = class {
536
621
  }
537
622
  const { message, line, column, place } = err;
538
623
  const point = place && ("start" in place ? place.start : place);
539
- throw Object.assign(
540
- new SyntaxError(message, {
541
- cause: err
542
- }),
543
- {
544
- lineNumber: line,
545
- column,
546
- index: (
547
- /* istanbul ignore next */
548
- point == null ? void 0 : point.offset
549
- )
550
- }
551
- );
624
+ throw Object.assign(new SyntaxError(message, {
625
+ cause: err
626
+ }), {
627
+ lineNumber: line,
628
+ column,
629
+ index: point?.offset
630
+ });
552
631
  }
553
632
  const { root, body, comments, tokens } = result;
554
633
  return {
555
- ast: __spreadProps(__spreadValues({}, normalizePosition(root.position)), {
634
+ ast: {
635
+ ...normalizePosition(root.position),
556
636
  type: "Program",
557
637
  sourceType,
558
638
  body,
559
639
  comments,
560
640
  tokens
561
- })
641
+ }
562
642
  };
563
643
  }
564
644
  };
565
645
  var parser = new Parser();
566
646
  var { parse, parseForESLint } = parser;
567
647
 
568
- // ../../node_modules/.pnpm/eslint-plugin-mdx@3.2.0_eslint@9.22.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/index.es2015.mjs
569
- import path4 from "node:path";
570
- import { createRequire as createRequire2 } from "node:module";
571
- var mdx = /* @__PURE__ */ Object.freeze({
572
- __proto__: null,
573
- get DEFAULT_LANGUAGE_MAPPER() {
574
- return DEFAULT_LANGUAGE_MAPPER;
575
- },
576
- get base() {
577
- return base;
578
- },
579
- get codeBlocks() {
580
- return codeBlocks;
581
- },
582
- get configs() {
583
- return configs;
584
- },
585
- get createRemarkProcessor() {
586
- return createRemarkProcessor;
587
- },
588
- get flat() {
589
- return flat;
590
- },
591
- get flatCodeBlocks() {
592
- return flatCodeBlocks;
593
- },
594
- get getGlobals() {
595
- return getGlobals;
596
- },
597
- get getShortLang() {
598
- return getShortLang;
599
- },
600
- get meta() {
601
- return meta2;
602
- },
603
- get overrides() {
604
- return overrides$1;
605
- },
606
- get processorOptions() {
607
- return processorOptions;
608
- },
609
- get processors() {
610
- return processors;
611
- },
612
- get recommended() {
613
- return recommended;
614
- },
615
- get remark() {
616
- return remark;
617
- },
618
- get rules() {
619
- return rules;
620
- }
621
- });
622
- var base = {
623
- parser: "eslint-mdx",
624
- parserOptions: {
625
- sourceType: "module",
626
- ecmaVersion: "latest"
627
- },
628
- plugins: ["mdx"],
629
- processor: "mdx/remark",
630
- rules: {
631
- "mdx/remark": "warn",
632
- "no-unused-expressions": "error"
633
- }
634
- };
635
- var codeBlocks = {
636
- parserOptions: {
637
- ecmaFeatures: {
638
- // Adding a "use strict" directive at the top of
639
- // every code block is tedious and distracting, so
640
- // opt into strict mode parsing without the
641
- // directive.
642
- impliedStrict: true
643
- }
644
- },
645
- rules: {
646
- // The Markdown parser automatically trims trailing
647
- // newlines from code blocks.
648
- "eol-last": "off",
649
- // In code snippets and examples, these rules are often
650
- // counterproductive to clarity and brevity.
651
- "no-undef": "off",
652
- "no-unused-expressions": "off",
653
- "no-unused-vars": "off",
654
- "padded-blocks": "off",
655
- // Adding a "use strict" directive at the top of every
656
- // code block is tedious and distracting. The config
657
- // opts into strict mode parsing without the directive.
658
- strict: "off",
659
- // The processor will not receive a Unicode Byte Order
660
- // Mark from the Markdown parser.
661
- "unicode-bom": "off"
662
- }
663
- };
664
- var __defProp$6 = Object.defineProperty;
665
- var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;
666
- var __hasOwnProp$6 = Object.prototype.hasOwnProperty;
667
- var __propIsEnum$6 = Object.prototype.propertyIsEnumerable;
668
- var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
669
- var __spreadValues$6 = (a, b) => {
670
- for (var prop in b || (b = {}))
671
- if (__hasOwnProp$6.call(b, prop))
672
- __defNormalProp$6(a, prop, b[prop]);
673
- if (__getOwnPropSymbols$6)
674
- for (var prop of __getOwnPropSymbols$6(b)) {
675
- if (__propIsEnum$6.call(b, prop))
676
- __defNormalProp$6(a, prop, b[prop]);
677
- }
678
- return a;
679
- };
680
- var __objRest = (source, exclude) => {
681
- var target = {};
682
- for (var prop in source)
683
- if (__hasOwnProp$6.call(source, prop) && exclude.indexOf(prop) < 0)
684
- target[prop] = source[prop];
685
- if (source != null && __getOwnPropSymbols$6)
686
- for (var prop of __getOwnPropSymbols$6(source)) {
687
- if (exclude.indexOf(prop) < 0 && __propIsEnum$6.call(source, prop))
688
- target[prop] = source[prop];
689
- }
690
- return target;
691
- };
648
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/flat.js
692
649
  var flat = {
693
650
  files: ["**/*.{md,mdx}"],
694
651
  languageOptions: {
695
652
  sourceType: "module",
696
653
  ecmaVersion: "latest",
697
- parser: index_es2015_exports,
654
+ parser: lib_exports,
698
655
  globals: {
699
656
  React: false
700
657
  }
701
658
  },
702
659
  plugins: {
703
- mdx
660
+ mdx: lib_exports2
704
661
  },
705
662
  rules: {
706
663
  "mdx/remark": "warn",
707
664
  "no-unused-expressions": "error",
708
- "react/react-in-jsx-scope": 0
665
+ "react/react-in-jsx-scope": "off"
709
666
  }
710
667
  };
711
- var _a = codeBlocks;
712
- var { parserOptions } = _a;
713
- var restConfig = __objRest(_a, ["parserOptions"]);
714
- var flatCodeBlocks = __spreadValues$6({
715
- files: ["**/*.{md,mdx}/*"],
668
+ var { parserOptions, ...restConfig } = codeBlocks;
669
+ var flatCodeBlocks = {
670
+ files: ["**/*.{md,mdx}/**"],
716
671
  languageOptions: {
717
672
  parserOptions
718
- }
719
- }, restConfig);
720
- var __defProp$5 = Object.defineProperty;
721
- var __defProps$3 = Object.defineProperties;
722
- var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;
723
- var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;
724
- var __hasOwnProp$5 = Object.prototype.hasOwnProperty;
725
- var __propIsEnum$5 = Object.prototype.propertyIsEnumerable;
726
- var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
727
- var __spreadValues$5 = (a, b) => {
728
- for (var prop in b || (b = {}))
729
- if (__hasOwnProp$5.call(b, prop))
730
- __defNormalProp$5(a, prop, b[prop]);
731
- if (__getOwnPropSymbols$5)
732
- for (var prop of __getOwnPropSymbols$5(b)) {
733
- if (__propIsEnum$5.call(b, prop))
734
- __defNormalProp$5(a, prop, b[prop]);
735
- }
736
- return a;
673
+ },
674
+ ...restConfig
737
675
  };
738
- var __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));
676
+
677
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/helpers.js
678
+ import { createRequire as createRequire3 } from "node:module";
679
+ var getGlobals = (sources, initialGlobals = {}) => (Array.isArray(sources) ? sources : Object.keys(sources)).reduce((globals, source) => Object.assign(globals, {
680
+ [source]: false
681
+ }), initialGlobals);
682
+ var cjsRequire3 = typeof __require === "undefined" ? createRequire3(import.meta.url) : __require;
683
+
684
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/overrides.js
739
685
  var isReactPluginAvailable = false;
740
686
  try {
741
- __require.resolve("eslint-plugin-react");
687
+ cjsRequire3.resolve("eslint-plugin-react");
742
688
  isReactPluginAvailable = true;
743
- } catch (e) {
689
+ } catch {
744
690
  }
745
- var overrides$1 = __spreadProps$3(__spreadValues$5({}, base), {
691
+ var overrides = {
692
+ ...base,
746
693
  globals: {
747
694
  React: false
748
695
  },
749
- plugins: arrayify(
750
- base.plugins,
751
- /* istanbul ignore next */
752
- isReactPluginAvailable ? "react" : null
753
- ),
696
+ plugins: arrayify(base.plugins, isReactPluginAvailable ? "react" : null),
754
697
  rules: {
755
- "react/jsx-no-undef": (
756
- /* istanbul ignore next */
757
- isReactPluginAvailable ? [
758
- 2,
759
- {
760
- allowGlobals: true
761
- }
762
- ] : 0
763
- ),
698
+ "react/jsx-no-undef": isReactPluginAvailable ? [
699
+ 2,
700
+ {
701
+ allowGlobals: true
702
+ }
703
+ ] : 0,
764
704
  "react/react-in-jsx-scope": 0
765
705
  }
766
- });
767
- var __defProp$4 = Object.defineProperty;
768
- var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;
769
- var __hasOwnProp$4 = Object.prototype.hasOwnProperty;
770
- var __propIsEnum$4 = Object.prototype.propertyIsEnumerable;
771
- var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
772
- var __spreadValues$4 = (a, b) => {
773
- for (var prop in b || (b = {}))
774
- if (__hasOwnProp$4.call(b, prop))
775
- __defNormalProp$4(a, prop, b[prop]);
776
- if (__getOwnPropSymbols$4)
777
- for (var prop of __getOwnPropSymbols$4(b)) {
778
- if (__propIsEnum$4.call(b, prop))
779
- __defNormalProp$4(a, prop, b[prop]);
780
- }
781
- return a;
782
706
  };
783
- var overrides = [
784
- __spreadValues$4({
707
+
708
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/recommended.js
709
+ var overrides2 = [
710
+ {
785
711
  files: ["*.md", "*.mdx"],
786
- extends: "plugin:mdx/overrides"
787
- }, base),
712
+ extends: "plugin:mdx/overrides",
713
+ ...base
714
+ },
788
715
  {
789
716
  files: "**/*.{md,mdx}/**",
790
717
  extends: "plugin:mdx/code-blocks"
791
718
  }
792
719
  ];
793
720
  var recommended = {
794
- overrides
721
+ overrides: overrides2
795
722
  };
796
- var getImportMetaUrl = () => {
797
- try {
798
- return new Function("return import.meta.url")();
799
- } catch (e) {
800
- return path4.resolve(process.cwd(), "__test__.js");
801
- }
802
- };
803
- var cjsRequire3 = typeof __require === "undefined" ? createRequire2(getImportMetaUrl()) : __require;
804
723
  var addPrettierRules = () => {
805
724
  try {
806
725
  cjsRequire3.resolve("prettier");
807
726
  const { meta: meta3 } = cjsRequire3("eslint-plugin-prettier");
808
- const version3 = (meta3 == null ? void 0 : meta3.version) || "";
809
- const [major, minor, patch] = version3.split(".");
810
- if (
811
- /* istanbul ignore next */
812
- +major > 5 || +major === 5 && (+minor > 1 || +minor === 1 && Number.parseInt(patch) >= 2)
813
- ) {
727
+ const version = meta3?.version || "";
728
+ const [major, minor, patch] = version.split(".");
729
+ if (+major > 5 || +major === 5 && (+minor > 1 || +minor === 1 && Number.parseInt(patch) >= 2)) {
814
730
  return;
815
731
  }
816
- overrides.push(
817
- {
818
- files: "*.md",
819
- rules: {
820
- "prettier/prettier": [
821
- "error",
822
- {
823
- parser: "markdown"
824
- }
825
- ]
826
- }
827
- },
828
- {
829
- files: "*.mdx",
830
- rules: {
831
- "prettier/prettier": [
832
- "error",
833
- {
834
- parser: "mdx"
835
- }
836
- ]
837
- }
732
+ overrides2.push({
733
+ files: "*.md",
734
+ rules: {
735
+ "prettier/prettier": [
736
+ "error",
737
+ {
738
+ parser: "markdown"
739
+ }
740
+ ]
741
+ }
742
+ }, {
743
+ files: "*.mdx",
744
+ rules: {
745
+ "prettier/prettier": [
746
+ "error",
747
+ {
748
+ parser: "mdx"
749
+ }
750
+ ]
838
751
  }
839
- );
840
- } catch (e) {
752
+ });
753
+ } catch {
841
754
  }
842
755
  };
843
756
  addPrettierRules();
757
+
758
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/configs/index.js
844
759
  var configs = {
845
760
  base,
846
761
  "code-blocks": codeBlocks,
847
762
  codeBlocks,
848
763
  flat,
849
764
  flatCodeBlocks,
850
- overrides: overrides$1,
765
+ overrides,
851
766
  recommended
852
767
  };
853
- var getGlobals = (sources, initialGlobals = {}) => (Array.isArray(sources) ? (
854
- // eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
855
- sources
856
- ) : Object.keys(sources)).reduce(
857
- (globals, source) => Object.assign(globals, {
858
- [source]: false
859
- }),
860
- // eslint-disable-next-line @typescript-eslint/prefer-reduce-type-parameter
861
- initialGlobals
862
- );
863
- var name2 = "eslint-plugin-mdx";
864
- var version2 = "3.2.0";
865
- var meta2 = { name: name2, version: version2 };
866
- var __defProp$3 = Object.defineProperty;
867
- var __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;
868
- var __hasOwnProp$3 = Object.prototype.hasOwnProperty;
869
- var __propIsEnum$3 = Object.prototype.propertyIsEnumerable;
870
- var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
871
- var __spreadValues$3 = (a, b) => {
872
- for (var prop in b || (b = {}))
873
- if (__hasOwnProp$3.call(b, prop))
874
- __defNormalProp$3(a, prop, b[prop]);
875
- if (__getOwnPropSymbols$3)
876
- for (var prop of __getOwnPropSymbols$3(b)) {
877
- if (__propIsEnum$3.call(b, prop))
878
- __defNormalProp$3(a, prop, b[prop]);
879
- }
880
- return a;
881
- };
768
+
769
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/meta.js
770
+ var pkg2 = cjsRequire3("../package.json");
771
+ var meta2 = { name: pkg2.name, version: pkg2.version };
772
+
773
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/processors/helpers.js
882
774
  var DEFAULT_LANGUAGE_MAPPER = {
883
775
  javascript: "js",
884
776
  javascriptreact: "jsx",
@@ -893,37 +785,18 @@ function getShortLang(filename, languageMapper) {
893
785
  if (languageMapper === false) {
894
786
  return language;
895
787
  }
896
- languageMapper = __spreadValues$3(__spreadValues$3({}, DEFAULT_LANGUAGE_MAPPER), languageMapper);
788
+ languageMapper = { ...DEFAULT_LANGUAGE_MAPPER, ...languageMapper };
897
789
  const lang = language.toLowerCase();
898
790
  return languageMapper[language] || languageMapper[lang] || lang;
899
791
  }
900
- var fromMarkdown = createSyncFn(
901
- __require.resolve("./worker")
902
- );
903
- var __defProp$2 = Object.defineProperty;
904
- var __defProps$2 = Object.defineProperties;
905
- var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;
906
- var __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;
907
- var __hasOwnProp$2 = Object.prototype.hasOwnProperty;
908
- var __propIsEnum$2 = Object.prototype.propertyIsEnumerable;
909
- var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
910
- var __spreadValues$2 = (a, b) => {
911
- for (var prop in b || (b = {}))
912
- if (__hasOwnProp$2.call(b, prop))
913
- __defNormalProp$2(a, prop, b[prop]);
914
- if (__getOwnPropSymbols$2)
915
- for (var prop of __getOwnPropSymbols$2(b)) {
916
- if (__propIsEnum$2.call(b, prop))
917
- __defNormalProp$2(a, prop, b[prop]);
918
- }
919
- return a;
920
- };
921
- var __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));
792
+
793
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/from-markdown.js
794
+ var fromMarkdown = createSyncFn(cjsRequire3.resolve("./worker.js"));
795
+
796
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/processors/markdown.js
922
797
  var UNSATISFIABLE_RULES = /* @__PURE__ */ new Set([
923
798
  "eol-last",
924
- // The Markdown parser strips trailing newlines in code fences
925
799
  "unicode-bom"
926
- // Code blocks will begin in the middle of Markdown files
927
800
  ]);
928
801
  var SUPPORTS_AUTOFIX = true;
929
802
  var BOM = "\uFEFF";
@@ -959,19 +832,14 @@ function getBeginningOfLineOffset(node) {
959
832
  return node.position.start.offset - node.position.start.column + 1;
960
833
  }
961
834
  function getIndentText(text, node) {
962
- return leadingWhitespaceRegex.exec(
963
- text.slice(getBeginningOfLineOffset(node))
964
- )[0];
835
+ return leadingWhitespaceRegex.exec(text.slice(getBeginningOfLineOffset(node)))[0];
965
836
  }
966
837
  function getBlockRangeMap(text, node, comments) {
967
838
  const startOffset = getBeginningOfLineOffset(node);
968
839
  const code = text.slice(startOffset, node.position.end.offset);
969
840
  const lines = code.split("\n");
970
841
  const baseIndent = getIndentText(text, node).length;
971
- const commentLength = comments.reduce(
972
- (len, comment) => len + comment.length + 1,
973
- 0
974
- );
842
+ const commentLength = comments.reduce((len, comment) => len + comment.length + 1, 0);
975
843
  const rangeMap = [
976
844
  {
977
845
  indent: baseIndent,
@@ -988,9 +856,6 @@ function getBlockRangeMap(text, node, comments) {
988
856
  rangeMap.push({
989
857
  indent: trimLength,
990
858
  js: jsOffset,
991
- // Advance `trimLength` character from the beginning of the Markdown
992
- // line to the beginning of the equivalent JS line, then compute the
993
- // delta.
994
859
  md: mdOffset + trimLength - jsOffset
995
860
  });
996
861
  mdOffset += line.length + 1;
@@ -1000,8 +865,7 @@ function getBlockRangeMap(text, node, comments) {
1000
865
  }
1001
866
  var codeBlockFileNameRegex = /filename=(["']).*?\1/u;
1002
867
  function fileNameFromMeta(block) {
1003
- var _a2, _b;
1004
- return (_b = (_a2 = block.meta) == null ? void 0 : _a2.match(codeBlockFileNameRegex)) == null ? void 0 : _b.groups.filename.replaceAll(/\s+/gu, "_");
868
+ return codeBlockFileNameRegex.exec(block.meta)?.groups.filename.replaceAll(/\s+/gu, "_");
1005
869
  }
1006
870
  var languageToFileExtension = {
1007
871
  javascript: "js",
@@ -1019,11 +883,6 @@ function preprocess(sourceText, filename) {
1019
883
  "*"() {
1020
884
  htmlComments = [];
1021
885
  },
1022
- /**
1023
- * Visit a code node.
1024
- * @param {CodeNode} node The visited node.
1025
- * @returns {void}
1026
- */
1027
886
  code(node) {
1028
887
  if (node.lang) {
1029
888
  const comments = [];
@@ -1035,18 +894,14 @@ function preprocess(sourceText, filename) {
1035
894
  comments.push(`/*${comment}*/`);
1036
895
  }
1037
896
  htmlComments = [];
1038
- blocks.push(__spreadProps$2(__spreadValues$2({}, node), {
897
+ blocks.push({
898
+ ...node,
1039
899
  baseIndentText: getIndentText(text, node),
1040
900
  comments,
1041
901
  rangeMap: getBlockRangeMap(text, node, comments)
1042
- }));
902
+ });
1043
903
  }
1044
904
  },
1045
- /**
1046
- * Visit an HTML node.
1047
- * @param {HtmlNode} node The visited node.
1048
- * @returns {void}
1049
- */
1050
905
  html(node) {
1051
906
  const comment = getComment(node.value);
1052
907
  if (comment) {
@@ -1057,11 +912,10 @@ function preprocess(sourceText, filename) {
1057
912
  }
1058
913
  });
1059
914
  return blocks.map((block, index) => {
1060
- var _a2;
1061
915
  const [language] = block.lang.trim().split(" ");
1062
916
  const fileExtension = Object.hasOwn(languageToFileExtension, language) ? languageToFileExtension[language] : language;
1063
917
  return {
1064
- filename: (_a2 = fileNameFromMeta(block)) != null ? _a2 : `${index}.${fileExtension}`,
918
+ filename: fileNameFromMeta(block) ?? `${index}.${fileExtension}`,
1065
919
  text: [...block.comments, block.value, ""].join("\n")
1066
920
  };
1067
921
  });
@@ -1080,17 +934,15 @@ ${block.baseIndentText}`)
1080
934
  };
1081
935
  }
1082
936
  function adjustBlock(block) {
1083
- const leadingCommentLines = block.comments.reduce(
1084
- (count, comment) => count + comment.split("\n").length,
1085
- 0
1086
- );
937
+ const leadingCommentLines = block.comments.reduce((count, comment) => count + comment.split("\n").length, 0);
1087
938
  const blockStart = block.position.start.line;
1088
939
  return function adjustMessage(message) {
1089
940
  if (!Number.isInteger(message.line)) {
1090
- return __spreadProps$2(__spreadValues$2({}, message), {
941
+ return {
942
+ ...message,
1091
943
  line: blockStart,
1092
944
  column: block.position.start.column
1093
- });
945
+ };
1094
946
  }
1095
947
  const lineInCode = message.line - leadingCommentLines;
1096
948
  if (lineInCode < 1 || lineInCode >= block.rangeMap.length) {
@@ -1104,7 +956,8 @@ function adjustBlock(block) {
1104
956
  out.endLine = message.endLine - leadingCommentLines + blockStart;
1105
957
  }
1106
958
  if (Array.isArray(message.suggestions)) {
1107
- out.suggestions = message.suggestions.map((suggestion) => __spreadProps$2(__spreadValues$2({}, suggestion), {
959
+ out.suggestions = message.suggestions.map((suggestion) => ({
960
+ ...suggestion,
1108
961
  fix: adjustFix(block, suggestion.fix)
1109
962
  }));
1110
963
  }
@@ -1112,7 +965,7 @@ function adjustBlock(block) {
1112
965
  if (message.fix) {
1113
966
  adjustedFix.fix = adjustFix(block, message.fix);
1114
967
  }
1115
- return __spreadValues$2(__spreadValues$2(__spreadValues$2({}, message), out), adjustedFix);
968
+ return { ...message, ...out, ...adjustedFix };
1116
969
  };
1117
970
  }
1118
971
  function excludeUnsatisfiableRules(message) {
@@ -1135,59 +988,38 @@ var markdownProcessor = {
1135
988
  postprocess,
1136
989
  supportsAutofix: SUPPORTS_AUTOFIX
1137
990
  };
991
+
992
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/processors/options.js
1138
993
  var processorOptions = {};
1139
- var linterPath = Object.keys(__require.cache).find(
1140
- (path5) => /([/\\])eslint\1lib(?:\1linter){2}\.js$/.test(path5)
1141
- );
994
+ var linterPath = Object.keys(cjsRequire3.cache).find((path6) => /([/\\])eslint\1lib(?:\1linter){2}\.js$/.test(path6));
1142
995
  if (!linterPath) {
1143
996
  throw new Error("Could not find ESLint Linter in require cache");
1144
997
  }
1145
- var ESLinter = __require(linterPath).Linter;
998
+ var ESLinter = cjsRequire3(linterPath).Linter;
1146
999
  var { verify } = ESLinter.prototype;
1147
1000
  ESLinter.prototype.verify = function(code, config, options) {
1148
- const settings = config && (typeof config.extractConfig === "function" ? config.extractConfig(
1149
- /* istanbul ignore next */
1150
- // eslint-disable-next-line unicorn/no-typeof-undefined
1151
- typeof options === "undefined" || typeof options === "string" ? options : options.filename
1152
- ) : config).settings || {};
1001
+ const settings = (config.extractConfig?.(typeof options === "undefined" || typeof options === "string" ? options : options.filename) ?? config).settings ?? {};
1153
1002
  processorOptions.lintCodeBlocks = settings["mdx/code-blocks"] === true;
1154
1003
  processorOptions.languageMapper = settings["mdx/language-mapper"];
1155
1004
  return verify.call(this, code, config, options);
1156
1005
  };
1157
- var __defProp$1 = Object.defineProperty;
1158
- var __defProps$1 = Object.defineProperties;
1159
- var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;
1160
- var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
1161
- var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
1162
- var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
1163
- var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1164
- var __spreadValues$1 = (a, b) => {
1165
- for (var prop in b || (b = {}))
1166
- if (__hasOwnProp$1.call(b, prop))
1167
- __defNormalProp$1(a, prop, b[prop]);
1168
- if (__getOwnPropSymbols$1)
1169
- for (var prop of __getOwnPropSymbols$1(b)) {
1170
- if (__propIsEnum$1.call(b, prop))
1171
- __defNormalProp$1(a, prop, b[prop]);
1172
- }
1173
- return a;
1174
- };
1175
- var __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));
1176
- var createRemarkProcessor = (processorOptions$1 = processorOptions) => ({
1006
+
1007
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/processors/remark.js
1008
+ var createRemarkProcessor = (processorOptions2 = processorOptions) => ({
1177
1009
  meta: {
1178
1010
  name: "mdx/remark",
1179
1011
  version: meta2.version
1180
1012
  },
1181
1013
  supportsAutofix: true,
1182
1014
  preprocess(text, filename) {
1183
- if (!processorOptions$1.lintCodeBlocks) {
1015
+ if (!processorOptions2.lintCodeBlocks) {
1184
1016
  return [text];
1185
1017
  }
1186
1018
  return [
1187
1019
  text,
1188
1020
  ...markdownProcessor.preprocess(text, filename).map(({ text: text2, filename: filename2 }) => ({
1189
1021
  text: text2,
1190
- filename: filename2.slice(0, filename2.lastIndexOf(".")) + "." + getShortLang(filename2, processorOptions$1.languageMapper)
1022
+ filename: filename2.slice(0, filename2.lastIndexOf(".")) + "." + getShortLang(filename2, processorOptions2.languageMapper)
1191
1023
  }))
1192
1024
  ];
1193
1025
  },
@@ -1196,47 +1028,28 @@ var createRemarkProcessor = (processorOptions$1 = processorOptions) => ({
1196
1028
  ...mdxMessages,
1197
1029
  ...markdownProcessor.postprocess(markdownMessages, filename)
1198
1030
  ].sort((a, b) => a.line - b.line || a.column - b.column).map((lintMessage) => {
1199
- const {
1200
- message,
1201
- ruleId: eslintRuleId,
1202
- severity: eslintSeverity
1203
- } = lintMessage;
1031
+ const { message, ruleId: eslintRuleId, severity: eslintSeverity } = lintMessage;
1204
1032
  if (eslintRuleId !== "mdx/remark") {
1205
1033
  return lintMessage;
1206
1034
  }
1207
- const { source, ruleId, reason, severity } = JSON.parse(
1208
- message
1209
- );
1210
- return __spreadProps$1(__spreadValues$1({}, lintMessage), {
1035
+ const { source, ruleId, reason, severity } = JSON.parse(message);
1036
+ return {
1037
+ ...lintMessage,
1211
1038
  ruleId: `${source}-${ruleId}`,
1212
1039
  message: reason,
1213
1040
  severity: Math.max(eslintSeverity, severity)
1214
- });
1041
+ };
1215
1042
  });
1216
1043
  }
1217
1044
  });
1218
- var remark$1 = createRemarkProcessor();
1219
- var processors = { remark: remark$1 };
1220
- var __defProp2 = Object.defineProperty;
1221
- var __defProps2 = Object.defineProperties;
1222
- var __getOwnPropDescs2 = Object.getOwnPropertyDescriptors;
1223
- var __getOwnPropSymbols2 = Object.getOwnPropertySymbols;
1224
- var __hasOwnProp2 = Object.prototype.hasOwnProperty;
1225
- var __propIsEnum2 = Object.prototype.propertyIsEnumerable;
1226
- var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1227
- var __spreadValues2 = (a, b) => {
1228
- for (var prop in b || (b = {}))
1229
- if (__hasOwnProp2.call(b, prop))
1230
- __defNormalProp2(a, prop, b[prop]);
1231
- if (__getOwnPropSymbols2)
1232
- for (var prop of __getOwnPropSymbols2(b)) {
1233
- if (__propIsEnum2.call(b, prop))
1234
- __defNormalProp2(a, prop, b[prop]);
1235
- }
1236
- return a;
1237
- };
1238
- var __spreadProps2 = (a, b) => __defProps2(a, __getOwnPropDescs2(b));
1239
- var remark = {
1045
+ var remark = createRemarkProcessor();
1046
+
1047
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/processors/index.js
1048
+ var processors = { remark };
1049
+
1050
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/rules/remark.js
1051
+ import path5 from "node:path";
1052
+ var remark2 = {
1240
1053
  meta: {
1241
1054
  type: "layout",
1242
1055
  docs: {
@@ -1248,7 +1061,7 @@ var remark = {
1248
1061
  },
1249
1062
  create(context) {
1250
1063
  const filename = context.getFilename();
1251
- const extname = path4.extname(filename);
1064
+ const extname = path5.extname(filename);
1252
1065
  const sourceCode = context.getSourceCode();
1253
1066
  const options = context.parserOptions;
1254
1067
  const isMdx = [
@@ -1260,7 +1073,6 @@ var remark = {
1260
1073
  ...options.markdownExtensions || []
1261
1074
  ].includes(extname);
1262
1075
  return {
1263
- // eslint-disable-next-line sonarjs/cognitive-complexity
1264
1076
  Program(node) {
1265
1077
  if (!isMdx && !isMarkdown) {
1266
1078
  return;
@@ -1272,7 +1084,6 @@ var remark = {
1272
1084
  fileOptions: {
1273
1085
  path: physicalFilename,
1274
1086
  value: sourceText,
1275
- // eslint-disable-next-line sonar/deprecation -- FIXME: ESLint 8.40+ required
1276
1087
  cwd: context.getCwd()
1277
1088
  },
1278
1089
  physicalFilename,
@@ -1281,15 +1092,7 @@ var remark = {
1281
1092
  ignoreRemarkConfig
1282
1093
  });
1283
1094
  let fixed = 0;
1284
- for (const {
1285
- source,
1286
- reason,
1287
- ruleId,
1288
- fatal,
1289
- line,
1290
- column,
1291
- place
1292
- } of messages) {
1095
+ for (const { source, reason, ruleId, fatal, line, column, place } of messages) {
1293
1096
  const severity = fatal ? 2 : fatal == null ? 0 : 1;
1294
1097
  if (!severity) {
1295
1098
  continue;
@@ -1302,19 +1105,15 @@ var remark = {
1302
1105
  };
1303
1106
  const point = {
1304
1107
  line,
1305
- // ! eslint ast column is 0-indexed, but unified is 1-indexed
1306
1108
  column: column - 1
1307
1109
  };
1308
1110
  context.report({
1309
- // related to https://github.com/eslint/eslint/issues/14198
1310
1111
  message: JSON.stringify(message),
1311
- loc: (
1312
- /* istanbul ignore next */
1313
- place && "start" in place ? __spreadProps2(__spreadValues2({}, point), {
1314
- start: __spreadProps2(__spreadValues2({}, place.start), { column: place.start.column - 1 }),
1315
- end: __spreadProps2(__spreadValues2({}, place.end), { column: place.end.column - 1 })
1316
- }) : point
1317
- ),
1112
+ loc: place && "start" in place ? {
1113
+ ...point,
1114
+ start: { ...place.start, column: place.start.column - 1 },
1115
+ end: { ...place.end, column: place.end.column - 1 }
1116
+ } : point,
1318
1117
  node,
1319
1118
  fix: fixedText === sourceText ? null : () => fixed++ ? null : {
1320
1119
  range: [0, sourceText.length],
@@ -1326,10 +1125,13 @@ var remark = {
1326
1125
  };
1327
1126
  }
1328
1127
  };
1329
- var rules = { remark };
1128
+
1129
+ // ../../node_modules/.pnpm/eslint-plugin-mdx@3.3.1_eslint@9.23.0_jiti@2.4.2_/node_modules/eslint-plugin-mdx/lib/rules/index.js
1130
+ var rules = { remark: remark2 };
1330
1131
  export {
1331
1132
  DEFAULT_LANGUAGE_MAPPER,
1332
1133
  base,
1134
+ cjsRequire3 as cjsRequire,
1333
1135
  codeBlocks,
1334
1136
  configs,
1335
1137
  createRemarkProcessor,
@@ -1338,10 +1140,10 @@ export {
1338
1140
  getGlobals,
1339
1141
  getShortLang,
1340
1142
  meta2 as meta,
1341
- overrides$1 as overrides,
1143
+ overrides,
1342
1144
  processorOptions,
1343
1145
  processors,
1344
1146
  recommended,
1345
- remark,
1147
+ remark2 as remark,
1346
1148
  rules
1347
1149
  };