@modality-counter/core 2.9.0 → 2.9.3

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.
@@ -0,0 +1 @@
1
+ export {};
@@ -14,12 +14,6 @@ export { toCounterCLIHelp, toCounterMethodHelp, type HelpFormat } from "./toCoun
14
14
  export { validateMethodFile, MethodFileSchema } from "./schemas/methodology-validation.js";
15
15
  export { validateTemplateFile, TemplateFileSchema } from "./schemas/template-validation.js";
16
16
  export { validateProtocolFile } from "./schemas/protocol-validation.js";
17
- export { extractCodeBlocks, extractYamlBlocks, readMdxPrompt, readMdxYaml, readPrompt, } from "./util_prompts";
18
- export { readMdx, importMdx } from "./util_mdx";
19
- /**
20
- * Test setup helpers live in a separate entry point to keep bun:test
21
- * out of the main bundle: import from "@modality-counter/core/testing".
22
- */
23
17
  /**
24
18
  * Protocols
25
19
  */
@@ -0,0 +1,2 @@
1
+ export { readMdx, importMdx } from "./util_mdx";
2
+ export { extractCodeBlocks, extractYamlBlocks, readMdxPrompt, readMdxYaml, readPrompt, } from "./util_prompts";
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Parsed YAML frontmatter. `name` and `description` are the conventional
3
+ * fields every consumer reads; any other key may appear, so it is `unknown`
4
+ * and must be narrowed before use.
5
+ */
6
+ export interface Frontmatter {
7
+ name?: string;
8
+ description?: string;
9
+ [key: string]: unknown;
10
+ }
11
+ /**
12
+ * Parse YAML frontmatter from markdown/mdx content. Light dependency (yaml only)
13
+ * so it can be imported without pulling the heavy MDX/bun-plugin stack.
14
+ * Returns object with parsed frontmatter data and remaining content
15
+ * Handles both Unix (\n) and Windows (\r\n) line endings
16
+ */
17
+ export declare function parseFrontmatter(content: string): Frontmatter;
@@ -1,21 +1,6 @@
1
1
  import React from "react";
2
- /**
3
- * Parsed YAML frontmatter. `name` and `description` are the conventional
4
- * fields every consumer reads; any other key may appear, so it is `unknown`
5
- * and must be narrowed before use.
6
- */
7
- export interface Frontmatter {
8
- name?: string;
9
- description?: string;
10
- [key: string]: unknown;
11
- }
12
- /**
13
- * Parse YAML frontmatter from markdown/mdx content
14
- * Returns object with parsed frontmatter data and remaining content
15
- * Handles both Unix (\n) and Windows (\r\n) line endings
16
- */
17
- export declare function parseFrontmatter(content: string): Frontmatter;
18
2
  export declare const readMdx: (Component: React.ReactElement) => string;
19
3
  export declare const importMdx: (filePath: string) => Promise<any>;
20
4
  export declare const getDirName: () => string;
21
5
  export declare const importAbsoluteMdx: (absoluteFilePath: string) => Promise<any>;
6
+ export { parseFrontmatter, type Frontmatter } from "./util_frontmatter.js";
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "2.9.0",
2
+ "version": "2.9.3",
3
3
  "name": "@modality-counter/core",
4
4
  "repository": {
5
5
  "type": "git",
@@ -46,6 +46,11 @@
46
46
  "types": "./dist/types/testing.d.ts",
47
47
  "require": "./dist/testing.js",
48
48
  "import": "./dist/testing.js"
49
+ },
50
+ "./mdx": {
51
+ "types": "./dist/types/mdx.d.ts",
52
+ "require": "./dist/mdx.js",
53
+ "import": "./dist/mdx.js"
49
54
  }
50
55
  },
51
56
  "types": "./dist/types/index.d.ts",